:root {
  /* TOP colours (theonlineprinter): blue for action, charcoal + greys for the rest. */
  --brand: #CFE5F0;        /* TOP's main blue — bars, headers, big areas */
  --brand-pale: #E8F2F8;
  --teal: #2B8FD4;         /* TOP's darker blue — buttons, links, highlights only */
  --teal-dark: #1F7BBE;
  --ink: #2B3235;
  --muted: #6B7578;
  --line: #DAE2E6;
  --bg: #F7F9FA;
}
* { box-sizing: border-box; }
body { margin: 0; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; color: var(--ink); background: var(--bg); }
a { color: var(--teal); text-decoration: none; }
a:hover { text-decoration: underline; }
.sf-wrap { max-width: 960px; margin: 0 auto; padding: 0 1rem; }

.sf-header { background: var(--brand); border-bottom: 1px solid #B8D8E8; }
.sf-header-inner { display: flex; align-items: center; justify-content: space-between; min-height: 58px; gap: .75rem; }
.sf-brand { font-weight: 800; color: var(--teal-dark); font-size: 1.15rem; }
.sf-header-right { display: flex; align-items: center; gap: 1.1rem; font-size: .9rem; }
.sf-child { color: var(--muted); }
.sf-cart-link { font-weight: 600; }
.sf-badge { background: var(--teal); color: #fff; border-radius: 99px; padding: .05rem .45rem; font-size: .75rem; }
.sf-signout { color: var(--muted); }

.sf-main { padding: 1.75rem 1rem 3rem; }
h1 { font-size: 1.5rem; margin: 0 0 .5rem; }
.sf-lead { color: var(--muted); margin: 0 0 1.25rem; }
.sf-muted { color: var(--muted); }

.sf-card { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 1.25rem; }
.sf-alert { padding: .7rem 1rem; border-radius: 8px; margin-bottom: 1rem; font-size: .9rem; }
.sf-alert-error { background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; }
.sf-alert-success { background: #ecfdf5; color: #065f46; border: 1px solid #a7f3d0; }

.sf-btn { display: inline-block; padding: .6rem 1.1rem; border-radius: 8px; border: 1px solid var(--line); background: #fff; color: var(--ink); font-weight: 600; font-size: .92rem; cursor: pointer; }
.sf-btn:hover { text-decoration: none; background: #f3f4f6; }
.sf-btn-primary { background: var(--teal); border-color: var(--teal); color: #fff; }
.sf-btn-primary:hover { background: var(--teal-dark); }
.sf-btn:disabled { opacity: .5; cursor: not-allowed; }
.sf-link-btn { background: none; border: none; color: var(--muted); cursor: pointer; text-decoration: underline; font-size: .85rem; }

/* Sign-in */
.sf-signin { max-width: 420px; margin: 2rem auto; text-align: center; }
.sf-signin-form { text-align: left; margin-top: 1.25rem; }
.sf-field { margin-bottom: 1rem; }
.sf-field label { display: block; font-weight: 600; font-size: .85rem; margin-bottom: .35rem; }
.sf-field input { width: 100%; padding: .6rem .7rem; border: 1.5px solid #cbd5d1; border-radius: 8px; font-size: 1rem; }
.sf-field input:focus { outline: none; border-color: var(--teal); }
/* A stand-alone input or select at the same size as .sf-field and .sf-btn (filters, search). */
.sf-input { padding: .6rem .7rem; border: 1.5px solid #cbd5d1; border-radius: 8px; background: #fff; font: inherit; font-size: 1rem; color: var(--ink); }
.sf-input:focus { outline: none; border-color: var(--teal); }
.sf-signin-form .sf-btn { width: 100%; }
.sf-btn-cancel { display: block; margin-top: .75rem; text-align: center; color: #b91c1c; border-color: #fecaca; }
.sf-btn-cancel:hover { background: #fef2f2; color: #991b1b; }

/* Products */
.sf-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 1.25rem; }
.sf-product { background: #fff; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.sf-preview { position: relative; width: 100%; aspect-ratio: 1 / 1; background: #fff; overflow: hidden; }
.sf-preview.landscape { aspect-ratio: 4 / 3; }
.sf-product-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.sf-art-overlay { position: absolute; top: 50%; left: 50%; width: 60%; transform: translate(-50%, -50%); }
.sf-product-body { padding: .85rem 1rem 1rem; background: #f1f5f4; border-top: 1px solid var(--line); }
.sf-product-name { font-weight: 600; }
.sf-product-desc { margin: .25rem 0 0; font-size: .85rem; line-height: 1.35; color: #4b5563; }
.sf-product-desc strong { color: #111827; }
.sf-product-price { color: var(--teal-dark); font-weight: 700; margin: .15rem 0 .6rem; }
.sf-add-form { display: flex; gap: .5rem; flex-wrap: wrap; }
.sf-select { padding: .4rem; border: 1.5px solid #cbd5d1; border-radius: 6px; background: #fff; font: inherit; flex: 1 1 100%; }
.sf-error { background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; border-radius: 8px; padding: .6rem .9rem; margin: 0 0 1rem; }
.sf-qty { width: 64px; padding: .4rem; border: 1.5px solid #cbd5d1; border-radius: 6px; }

/* Cart */
.sf-cart-table { width: 100%; border-collapse: collapse; }
.sf-cart-table th, .sf-cart-table td { text-align: left; padding: .6rem .4rem; border-bottom: 1px solid var(--line); font-size: .92rem; }
.sf-cart-table th { color: var(--muted); font-size: .75rem; text-transform: uppercase; letter-spacing: .03em; }
.sf-cart-item { display: flex; gap: .7rem; align-items: center; }
.sf-order-line { display: inline-flex; gap: .6rem; align-items: center; }
.sf-cart-thumb { width: 64px; height: 64px; object-fit: contain; border: 1px solid var(--line); border-radius: 6px; background: #fff; flex: none; }
.sf-inline { margin: 0; }
.sf-totals { margin-top: 1.25rem; margin-left: auto; max-width: 280px; }
.sf-totals > div { display: flex; justify-content: space-between; padding: .3rem 0; font-size: .92rem; }
.sf-grand { border-top: 1px solid var(--line); margin-top: .35rem; padding-top: .6rem !important; font-weight: 700; font-size: 1.05rem !important; }
.sf-gst { color: var(--muted); font-size: .8rem !important; }
.sf-cart-actions { display: flex; justify-content: space-between; margin-top: 1.5rem; }

.sf-footer { color: var(--muted); font-size: .8rem; text-align: center; padding: 1.5rem 0 2rem; }

/* Signup wizard */
.sf-hint { color: var(--muted); font-weight: 400; font-size: .8rem; }
.wz { max-width: 640px; margin: 0 auto; }
/* Break the slot picker out of the 960px .sf-wrap so the full window + plan panel fit.
   Full-bleed to the viewport, then re-centre the content at a comfortable cap. */
.wz-wide { max-width: none; width: auto; margin-left: calc(50% - 50vw); margin-right: calc(50% - 50vw); padding-inline: clamp(1rem, 4vw, 3rem); }
.wz-wide > * { max-width: 1280px; margin-inline: auto; }
.wz-steps { display: flex; gap: .4rem; list-style: none; padding: 0; margin: 0 0 1.5rem; font-size: .8rem; flex-wrap: wrap; }
.wz-steps li { color: var(--muted); display: flex; align-items: center; gap: .35rem; padding: .25rem .6rem; border-radius: 99px; background: #eef2f1; }
.wz-steps li.is-current { background: var(--teal); color: #fff; font-weight: 600; }
.wz-steps li.is-done { background: #d1faf3; color: var(--teal-dark); }
.wz-num { display: inline-flex; width: 18px; height: 18px; align-items: center; justify-content: center; border-radius: 50%; background: rgba(0,0,0,.08); font-size: .72rem; }
.wz-steps li.is-current .wz-num { background: rgba(255,255,255,.3); }

.wz-timeline { margin-top: 1.25rem; }
.wz-tl { list-style: none; padding: 0; margin: 0 0 1rem; }
.wz-tl li { display: flex; justify-content: space-between; padding: .5rem .25rem; border-bottom: 1px solid var(--line); }
.wz-tl li span { color: var(--muted); }
.wz-tl-final strong { color: var(--teal-dark); }

/* Timeline list rows tinted to match the Gantt phase bands (band styles live in the
   _timeline_gantt.html.twig partial so they render on the admin layout too). */
.wz-tl li[class*="wz-tl-"] { padding-left: .5rem; border-left: 3px solid transparent; }
.wz-tl-prep { border-left-color: #cdd4da !important; }
.wz-tl-order { border-left-color: #74c9b8 !important; }
.wz-tl-prod { border-left-color: #eaad5b !important; }
.wz-tl-deliver { border-left-color: #66c07d !important; }
.wz-tl-total { border-bottom: none; font-weight: 600; }
.wz-tl-total span { color: var(--ink, inherit) !important; }

.wz-check { display: flex; gap: .7rem; align-items: flex-start; padding: .6rem 0; }
.wz-check input { margin-top: .25rem; }
.wz-summary { list-style: none; padding: 0; margin: 0; }
.wz-summary li { display: flex; justify-content: space-between; padding: .4rem .25rem; border-bottom: 1px solid var(--line); }
.wz-summary li span { color: var(--muted); }

.wz-done { text-align: center; }
.wz-tick { width: 56px; height: 56px; margin: 1rem auto; border-radius: 50%; background: var(--teal); color: #fff; font-size: 1.8rem; display: flex; align-items: center; justify-content: center; }

/* Siblings: one tab per child on the products page. */
.sf-tabs { display: flex; flex-wrap: wrap; gap: .25rem; border-bottom: 2px solid var(--line); margin-bottom: 1.25rem; }
.sf-tab { display: inline-block; background: none; border: none; border-bottom: 3px solid transparent; margin-bottom: -2px; padding: .6rem 1rem; font-size: .95rem; font-weight: 600; color: var(--muted); cursor: pointer; }
.sf-tab:hover { color: var(--ink); text-decoration: none; }
.sf-tab.is-active { color: var(--teal-dark); border-bottom-color: var(--teal); }
.sf-tab-add { font-weight: 500; color: var(--teal); margin-left: auto; }

/* Checkout */
.sf-checkout { display: grid; grid-template-columns: 1.4fr 1fr; gap: 1.25rem; align-items: start; }
.sf-checkout h2 { font-size: 1.05rem; margin: 1.1rem 0 .6rem; }
.sf-checkout h2:first-of-type { margin-top: 0; }
.sf-field-row { display: grid; grid-template-columns: 2fr 1fr; gap: .75rem; }
.sf-check { display: flex; gap: .5rem; align-items: center; font-size: .9rem; margin: .25rem 0 1rem; }
.sf-pay-btn { width: 100%; margin-top: 1rem; padding: .8rem; font-size: 1rem; }
.sf-small { font-size: .8rem; margin-top: .5rem; }
.sf-summary-lines { list-style: none; padding: 0; margin: 0 0 .75rem; font-size: .9rem; }
.sf-summary-lines li { display: flex; justify-content: space-between; gap: .75rem; padding: .35rem 0; border-bottom: 1px solid var(--line); }
.sf-done { max-width: 560px; margin: 0 auto; text-align: center; }
@media (max-width: 720px) {
  .sf-checkout { grid-template-columns: 1fr; }
  .sf-summary { order: -1; }
  .sf-header-right { gap: .6rem; flex-wrap: wrap; }
}
.sf-sibling-prompt { background: var(--brand-pale); border: 1px solid #B8D8E8; color: #0C2D4A; border-radius: 8px; padding: .6rem 1rem; margin-bottom: 1rem; font-size: .92rem; }

/* Add to cart: the note that stays on the products page, and the badge bump */
.sf-cart-note { position: fixed; left: 50%; bottom: 1.25rem; transform: translateX(-50%); z-index: 50;
  max-width: calc(100% - 2rem); padding: .75rem 1rem; border-radius: 8px; font-size: .9rem;
  background: #ecfdf5; color: #065f46; border: 1px solid #a7f3d0; box-shadow: 0 6px 20px rgba(0,0,0,.12); }
.sf-cart-note-error { background: #fef2f2; color: #991b1b; border-color: #fecaca; }
.sf-cart-note a { color: inherit; font-weight: 600; text-decoration: underline; margin-left: .25rem; }
.sf-cart-bump .sf-badge { animation: sf-bump .4s ease-out; }
@keyframes sf-bump { 0% { transform: scale(1); } 40% { transform: scale(1.35); } 100% { transform: scale(1); } }
@media (prefers-reduced-motion: reduce) { .sf-cart-bump .sf-badge { animation: none; } }

/* Mock-up zoom: tap the picture for a full-size view. */
.sf-zoom { position: absolute; inset: 0; padding: 0; border: 0; background: none; cursor: zoom-in; }
.sf-zoom-hint { position: absolute; right: .5rem; bottom: .5rem; padding: .2rem .5rem; border-radius: 999px; background: rgba(43,50,53,.75); color: #fff; font-size: .75rem; }
.sf-lightbox { max-width: 96vw; max-height: 96vh; padding: 0; border: 0; border-radius: 8px; background: #fff; cursor: zoom-out; }
.sf-lightbox::backdrop { background: rgba(0,0,0,.8); }
.sf-lightbox img { display: block; max-width: 96vw; max-height: 96vh; object-fit: contain; }
.sf-lightbox-close { position: absolute; top: .4rem; right: .4rem; width: 2.2rem; height: 2.2rem; border: 0; border-radius: 50%; background: rgba(43,50,53,.8); color: #fff; font-size: 1.4rem; line-height: 1; cursor: pointer; }
