/* Shared styles for the redesigned order experiences (/a/ guided flow, /b/ single page).
   Loaded after styles.css — reuses its palette and form primitives. */

:root { --page-w: 760px; }
.wrap { padding-bottom: 140px; max-width: var(--page-w); }

/* when we jump to the first missing field, leave breathing room above it */
#order-form .field { scroll-margin-top: 84px; }

/* keep the fixed bottom bars aligned with the page column */
.totalbar, .flowbar {
  max-width: var(--page-w);
  left: 0;
  right: 0;
  margin: 0 auto;
  border-radius: 14px 14px 0 0;
}

/* hero */
.hero { margin: 0 0 22px; }
.hero h1 { font-size: 24px; }
.hero .subtitle { font-size: 15px; }

/* ---- package tier chooser ---- */
.tiers {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  align-items: stretch;
}
@media (max-width: 680px) { .tiers { grid-template-columns: 1fr; } }

.tier {
  position: relative;
  border: 2px solid var(--line);
  border-radius: 14px;
  padding: 16px 14px 14px;
  background: #fff;
  display: flex;
  flex-direction: column;
  gap: 10px;
  cursor: pointer;
  transition: border-color 0.15s, box-shadow 0.15s, transform 0.15s;
}
.tier:hover { border-color: var(--cyan); }
.tier.selected {
  border-color: var(--teal);
  background: #f0fbfc;
  box-shadow: 0 4px 18px rgba(11, 143, 148, 0.22);
}
.tier .badge { top: -11px; left: 50%; transform: translateX(-50%); }
.tier img.thumb {
  width: 100%;
  height: 190px;
  object-fit: contain;
  border-radius: 8px;
  background: #fff;
}
.tier .t-body { display: flex; flex-direction: column; gap: 10px; flex: 1; min-width: 0; }
.tier .t-name { font-weight: 700; font-size: 16px; letter-spacing: 0.3px; }
.tier .t-price { font-weight: 700; font-size: 26px; color: var(--teal); display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.tier .t-value {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.5px;
  color: var(--orange);
  background: #fff1e8;
  border-radius: 999px;
  padding: 3px 9px;
  white-space: nowrap;
}
.tier ul.feats {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12.5px;
  color: #444;
  flex: 1;
}
.tier ul.feats li { display: flex; gap: 7px; align-items: baseline; line-height: 1.35; }
.tier ul.feats li::before { content: "✓"; color: var(--teal); font-weight: 700; flex: none; }
.tier ul.feats li.plus { font-weight: 600; color: var(--ink); }
.tier ul.feats li.plus::before { content: "+"; color: var(--orange); }
.tier ul.feats li b { font-weight: 400; }
.tier ul.feats li b.up { font-weight: 700; color: var(--orange); }
.tier .t-cta {
  border: 1px solid var(--teal);
  background: #fff;
  color: var(--teal);
  font-family: inherit;
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 1px;
  padding: 11px 10px;
  border-radius: 8px;
  cursor: pointer;
  width: 100%;
}
.tier.selected .t-cta { background: var(--teal); color: #fff; }
/* digital-only package: full-width but short — image left, details right */
.tier.wide {
  grid-column: 1 / -1;
  flex-direction: row;
  align-items: center;
  gap: 16px;
  background: #fffaf6;
  border-color: #ffd9c7;
}
.tier.wide img.thumb { width: 120px; height: 120px; flex: none; }
.tier.wide .t-cta { max-width: 240px; }
.tier.wide.selected { background: #f0fbfc; }
@media (max-width: 680px) {
  .tier.wide { flex-direction: column; align-items: stretch; }
  .tier.wide img.thumb { width: 100%; }
  .tier.wide .t-cta { max-width: none; }
}
.tier.unavail { opacity: 0.6; cursor: default; }
.tier.unavail:hover { border-color: #ffd9c7; }
.tier.unavail .t-cta { border-color: #bbb; color: #888; cursor: default; }
.tier .t-stepper { display: none; justify-content: center; }
.tier.selected .t-stepper { display: flex; }

.skiprow { text-align: center; margin: 16px 0 4px; }
.skiprow a, .skiprow button {
  background: none;
  border: none;
  font-family: inherit;
  color: var(--muted);
  font-size: 13px;
  text-decoration: underline;
  cursor: pointer;
}

/* ---- add-on rows ---- */
.addons { display: grid; gap: 10px; }
.addon {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 10px 12px;
  display: flex;
  gap: 12px;
  align-items: center;
  background: #fff;
}
.addon.selected { background: #f0fbfc; border-color: var(--teal); }
.addon .thumb {
  width: 76px;
  height: 76px;
  flex: none;
  border-radius: 6px;
  object-fit: cover;
  background: #f5f6f7;
}
.addon .info { flex: 1; min-width: 0; }
.addon .name { font-weight: 700; font-size: 14px; }
.addon .desc { font-size: 12px; color: #777; line-height: 1.4; }
.addon .price { font-weight: 700; font-size: 15px; color: var(--teal); flex: none; margin-right: 4px; }
.addon .stepper button { width: 32px; height: 32px; font-size: 16px; }
.addon .stepper .qty { width: 34px; height: 32px; font-size: 14px; }

.group-title {
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  color: var(--teal);
  margin: 22px 0 10px;
}
.group-title small { color: #999; font-weight: 600; letter-spacing: 0.4px; text-transform: none; margin-left: 8px; }

/* ---- step flow (variant A) ---- */
.steps {
  display: flex;
  gap: 0;
  margin: 4px 0 22px;
  counter-reset: step;
}
.steps .st {
  flex: 1;
  text-align: center;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  color: #b5b5b5;
  position: relative;
  padding-top: 30px;
}
.steps .st::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #e6e6e6;
  color: #999;
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.steps .st::after {
  content: "";
  position: absolute;
  top: 11px;
  left: calc(50% + 14px);
  right: calc(-50% + 14px);
  height: 2px;
  background: #e6e6e6;
}
.steps .st:last-child::after { display: none; }
.steps .st.active { color: var(--ink); }
.steps .st.active::before { background: var(--teal); color: #fff; }
.steps .st.done { color: var(--teal); }
.steps .st.done::before { background: var(--cyan); color: var(--ink); content: "✓"; }
.steps .st.done::after { background: var(--cyan); }

.step-panel { display: none; }
.step-panel.active { display: block; animation: panein 0.25s ease; }
@keyframes panein { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.step-h { font-size: 19px; font-weight: 700; margin: 0 0 4px; letter-spacing: 0.4px; }
.step-sub { color: var(--muted); font-size: 13.5px; margin: 0 0 16px; }

/* flow footer bar */
.flowbar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--ink);
  color: #fff;
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
  display: flex;
  align-items: center;
  gap: 12px;
  z-index: 10;
}
.flowbar .totals { flex: 1; min-width: 0; }
.flowbar .label { font-size: 10px; letter-spacing: 2px; color: #aaa; }
.flowbar .amount { font-size: 20px; font-weight: 700; color: var(--cyan); }
.flowbar .back-btn {
  background: none;
  border: 1px solid #555;
  color: #ccc;
  font-family: inherit;
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 1px;
  padding: 13px 16px;
  border-radius: 8px;
  cursor: pointer;
}
.flowbar .next-btn {
  background: var(--teal);
  color: #fff;
  border: none;
  font-family: inherit;
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 1px;
  padding: 14px 22px;
  border-radius: 8px;
  cursor: pointer;
  white-space: nowrap;
}
.flowbar .next-btn:hover { background: #0a7d81; }
.flowbar .next-btn:disabled { background: #555; cursor: not-allowed; }

/* ---- review / order summary ---- */
.summary {
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
  margin: 6px 0 18px;
  background: #fff;
}
.summary .row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 14px;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}
.summary .row:last-child { border-bottom: none; }
.summary .row .n { color: #333; }
.summary .row .v { font-weight: 700; white-space: nowrap; }
.summary .row.total { background: #f0fbfc; font-size: 16px; }
.summary .row.total .v { color: var(--teal); }
.summary .row.bhead {
  background: #fafafa;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--teal);
}
.summary .empty { padding: 18px 14px; color: #999; font-size: 14px; text-align: center; }

.recap {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px;
  margin: 0 0 18px;
  font-size: 13.5px;
  line-height: 1.7;
  background: #fff;
}
.recap b { font-size: 14px; }
.edit-link {
  background: none;
  border: none;
  font-family: inherit;
  color: var(--teal);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-decoration: underline;
  cursor: pointer;
  float: right;
}

/* trust strip */
.trust {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: center;
  font-size: 11.5px;
  color: #888;
  margin: 18px 0 0;
}
.trust span { display: flex; align-items: center; gap: 5px; }

/* ---- running cart panel ---- */
.cartpanel {
  position: fixed;
  left: 0;
  right: 0;
  margin: 0 auto;
  max-width: var(--page-w);
  /* sit fully above the fixed footer bar so the last rows are never covered */
  bottom: calc(86px + env(safe-area-inset-bottom));
  background: #fff;
  border: 1px solid var(--line);
  border-bottom: none;
  border-radius: 14px 14px 0 0;
  box-shadow: 0 -10px 30px rgba(0, 0, 0, 0.16);
  padding: 14px 18px 20px;
  z-index: 9;
  max-height: 62vh;
  overflow-y: auto;
  transform: translateY(108%);
  visibility: hidden;
  transition: transform 0.25s ease, visibility 0.25s;
}
.cartpanel.open { transform: none; visibility: visible; }
.cartpanel .cp-h {
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--teal);
  margin-bottom: 10px;
}
.cp-row {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 6px 0;
  border-bottom: 1px solid #f2f2f2;
  font-size: 13.5px;
}
.cp-row:last-child { border-bottom: none; }
.cp-count {
  min-width: 28px;
  height: 24px;
  padding: 0 7px;
  border-radius: 12px;
  background: #f0fbfc;
  color: var(--teal);
  font-weight: 700;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: none;
}
.cp-empty { color: #999; font-size: 13px; line-height: 1.5; }

/* desktop-only checkout button inside the sidebar cart */
.cp-checkout {
  display: none;
  width: 100%;
  margin-top: 14px;
  background: var(--teal);
  color: #fff;
  border: none;
  font-family: inherit;
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 1px;
  padding: 13px 14px;
  border-radius: 10px;
  cursor: pointer;
  transition: background 0.15s;
}
.cp-checkout:hover { background: #0a7d81; }
.cp-checkout:disabled { background: #bcc6c6; cursor: not-allowed; }

/* priced item lines + running total in the cart panel */
.cp-item {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 6px 2px;
  border-bottom: 1px solid #f2f2f2;
  font-size: 13px;
}
.cp-item .p { font-weight: 700; white-space: nowrap; }
.cp-total {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 9px 2px 4px;
  font-weight: 700;
  font-size: 14.5px;
  border-top: 2px solid var(--ink);
}
.cp-total .p { color: var(--teal); }
.cp-sub {
  margin: 14px 0 4px;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #999;
}

/* digital deliverables stand out from the prints */
.cp-row.cp-digital .cp-count { background: #fff1e8; color: var(--orange); }
.cp-row.cp-digital span:last-child { color: var(--orange); font-weight: 600; }

/* newly added / changed rows flash so the eye lands on them */
@keyframes cpflash {
  0% { background: #ffdfc7; }
  100% { background: transparent; }
}
.cp-flash { animation: cpflash 1.6s ease-out; border-radius: 6px; }
.cp-hint {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: var(--cyan);
  margin-top: 3px;
}
#cart-toggle { cursor: pointer; }

/* wide desktop: persistent sidebar instead of bottom sheet */
@media (min-width: 1100px) {
  .wrap, .totalbar, .flowbar { margin-left: calc(50% - 550px); margin-right: auto; }
  .cartpanel {
    left: auto;
    right: calc(50% - 550px);
    margin: 0;
    width: 320px;
    top: 24px;
    bottom: auto;
    max-height: calc(100vh - 60px);
    transform: none;
    visibility: visible;
    border: 1px solid var(--line);
    border-radius: 14px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    padding-bottom: 14px;
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
  }
  .cp-hint { display: none; }
  #cart-toggle { cursor: default; }
  .cp-checkout { display: block; }
  /* hand off to the inline Review & Pay summary as it scrolls into view */
  .cartpanel.handoff { opacity: 0; visibility: hidden; transform: translateX(16px); pointer-events: none; }
}

/* numbered section headers (variant B) */
.numbered { display: flex; align-items: center; gap: 10px; margin: 34px 0 4px; }
.numbered .n {
  width: 28px;
  height: 28px;
  flex: none;
  border-radius: 50%;
  background: var(--teal);
  color: #fff;
  font-weight: 700;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.numbered h2 {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 0.5px;
  margin: 0;
  text-transform: uppercase;
}
.numbered-sub { color: var(--muted); font-size: 13px; margin: 4px 0 14px 38px; }
