:root {
  --primary: #173f5f;
  --accent: #f2a900;
  --ink: #18212b;
  --muted: #66717d;
  --paper: #fff;
  --wash: #f4f7f9;
  --line: #dfe5ea;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { min-height: 100vh; margin: 0; display: flex; flex-direction: column; color: var(--ink); background: var(--wash); font-family: Arial, Helvetica, sans-serif; line-height: 1.55; }
body > main { flex: 1 0 auto; }
.shell { width: min(1120px, calc(100% - 40px)); margin-inline: auto; }
.site-header { background: var(--paper); border-bottom: 1px solid var(--line); }
.brand-row { display: flex; align-items: center; justify-content: space-between; gap: 20px; min-height: 76px; }
.brand { color: var(--primary); font-size: 1.25rem; font-weight: 800; text-decoration: none; }
.brand-logo img { display: block; width: min(300px, 60vw); height: auto; }
.tenant-header-logo { padding: 10px 0 6px; }
.tenant-header-logo img { display: block; max-width: min(230px, 58vw); max-height: 100px; width: auto; height: auto; object-fit: contain; }
.phase-note { color: var(--muted); font-size: .86rem; font-weight: 700; }
.hero { color: #fff; background: linear-gradient(135deg, var(--primary), color-mix(in srgb, var(--primary) 76%, #000)); }
.hero-inner { padding: 72px 0; }
.eyebrow { margin: 0 0 10px; color: var(--accent); font-size: .82rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.eyebrow.dark { color: var(--primary); }
h1 { max-width: 820px; margin: 0; font-size: clamp(2.1rem, 5vw, 4.2rem); line-height: 1.05; }
.shop-hero h1 { font-size: clamp(1.9rem, 4vw, 3.2rem); }
h2 { color: var(--primary); }
.lead { max-width: 700px; margin: 22px 0 0; font-size: 1.2rem; }
.notice { max-width: 700px; margin-top: 28px; padding: 16px 18px; border-left: 5px solid var(--accent); background: rgba(255, 255, 255, .12); }
.content-card { margin-block: 38px; padding: 32px; background: var(--paper); border-radius: 14px; box-shadow: 0 8px 25px rgba(26, 45, 61, .07); }
.content-card h2 { margin-top: 0; }
.site-footer { margin-top: auto; padding: 30px 0; color: var(--muted); font-size: .9rem; }
.shop-footer { padding: 18px 0; border-top: 3px solid var(--accent); color: #fff; background: linear-gradient(135deg, var(--primary), color-mix(in srgb, var(--primary) 76%, #000)); font-size: .88rem; }
.powered-by { display: inline-flex; align-items: center; gap: 10px; }
.powered-by > span { white-space: nowrap; }
.powered-by a { display: inline-flex; align-items: center; }
.powered-by img { display: block; width: 96px; max-height: 28px; object-fit: contain; }
.product-section { padding-block: 42px; }
.section-heading { margin-bottom: 22px; }
.section-heading h2 { margin: 0; font-size: 2rem; }
.product-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
.product-card { background: transparent; }
.product-card a { display: block; color: inherit; text-decoration: none; }
.product-image { display: grid; place-items: center; aspect-ratio: 1; overflow: hidden; background: #eef2f5; border: 1px solid var(--line); border-radius: 14px; color: var(--muted); box-shadow: 0 7px 22px rgba(23, 63, 95, .06); }
.product-image img { width: 100%; height: 100%; object-fit: contain; }
.product-copy { display: grid; gap: 5px; padding: 14px 4px 0; }
.product-copy strong { color: var(--primary); font-size: 1.12rem; }
.product-copy > span:last-child { font-weight: 700; }
.empty { text-align: center; }
.product-page { padding-block: 30px; }
.back-link { margin: 0 0 24px; }
.product-layout { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(320px, .9fr); grid-template-areas: "gallery summary" "gallery purchase"; gap: 18px 30px; align-items: start; }
.gallery, .product-summary, .product-purchase { background: #fff; border: 1px solid var(--line); border-radius: 14px; }
.gallery { grid-area: gallery; }
.product-summary { grid-area: summary; }
.product-purchase { grid-area: purchase; }
.gallery { padding: 20px; }
.gallery-stage { display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: 12px; align-items: start; }
.gallery-stage:has(.gallery-thumbnails[hidden]) { grid-template-columns: minmax(0, 1fr); }
.gallery-thumbnails[hidden], .gallery-arrow[hidden], .main-image img[hidden], .main-image span[hidden] { display: none; }
.gallery-thumbnails { display: grid; gap: 10px; align-content: start; }
.gallery-thumbnails button { width: 72px; aspect-ratio: 1; padding: 3px; overflow: hidden; border: 2px solid transparent; border-radius: 8px; background: #f2f5f7; cursor: pointer; }
.gallery-thumbnails button.active { border-color: var(--primary); }
.gallery-thumbnails img { display: block; width: 100%; height: 100%; object-fit: contain; }
.main-image { position: relative; display: grid; place-items: center; aspect-ratio: 1; background: #f2f5f7; border-radius: 10px; overflow: hidden; color: var(--muted); }
.main-image img { grid-area: 1 / 1; width: 100%; height: 100%; object-fit: contain; }
.main-image span { grid-area: 1 / 1; }
.gallery-arrow { position: absolute; z-index: 2; top: 50%; width: 42px; height: 42px; padding: 0; border: 1px solid var(--line); border-radius: 50%; color: var(--primary); background: rgba(255,255,255,.92); font: 700 2rem/1 Arial,sans-serif; cursor: pointer; transform: translateY(-50%); box-shadow: 0 3px 12px rgba(0,0,0,.12); }
.gallery-arrow-prev { left: 12px; }
.gallery-arrow-next { right: 12px; }
.product-summary, .product-purchase { padding: 24px; }
.product-summary h1 { font-size: clamp(1.55rem, 2.35vw, 1.95rem); line-height: 1.12; }
.product-summary > :last-child { margin-bottom: 0; }
.colour-picker { margin-top: 18px; }
.colour-picker > strong { color: var(--primary); }
.colour-picker > [data-colour-name] { margin-left: 5px; }
.colour-swatches { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 9px; }
.colour-swatch { padding: 7px 11px; border: 0; border-radius: 999px; background: var(--swatch); color: var(--swatch-text); font: inherit; font-size: .82rem; font-weight: 700; cursor: pointer; }
.colour-swatch:focus-visible { outline: 2px solid var(--primary); outline-offset: 3px; }
.product-purchase h2 { margin: 0 0 12px; font-size: 1.15rem; }
.size-options { max-width: 100%; overflow-x: auto; }
.size-options table { width: 100%; border-collapse: collapse; }
.size-options th, .size-options td { padding: 8px 6px; text-align: center; border: 1px solid #bdc8d0; font-size: .82rem; white-space: nowrap; }
.size-options th { color: var(--primary); background: #edf2f5; font-size: .7rem; text-transform: uppercase; }
.size-options th:first-child, .size-options td:first-child { width: 34px; }
.size-options input[type="radio"] { width: 17px; height: 17px; margin: 0; accent-color: var(--primary); }
.optional-print-label { display: block; margin-top: 18px; color: var(--primary); font-size: .86rem; font-weight: 700; }
.optional-print-label span { color: var(--muted); font-weight: 400; }
.optional-print-label input { display: block; width: 100%; min-height: 47px; margin-top: 6px; padding: 11px 12px; border: 1px solid #bdc8d0; border-radius: 6px; color: var(--ink); background: #fff; font: inherit; }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.shipping-note, .phase-callout { padding: 13px 15px; border-radius: 8px; background: var(--wash); }
.phase-callout { border-left: 4px solid var(--accent); font-weight: 700; }

button, .button-link { border: 0; border-radius: 7px; padding: 11px 17px; color: #fff; background: var(--primary); font: inherit; font-weight: 700; cursor: pointer; text-decoration: none; text-align: center; }
button:disabled { cursor: not-allowed; opacity: .55; }
.cart-link { display: inline-flex; align-items: center; gap: 7px; color: var(--primary); font-weight: 800; text-decoration: none; }
.cart-link span { display: grid; place-items: center; min-width: 25px; height: 25px; padding: 0 7px; border-radius: 999px; color: #fff; background: var(--primary); font-size: .78rem; }
.store-message, .checkout-error { margin-top: 18px; padding: 13px 16px; border-radius: 8px; background: #e5f5eb; color: #175c34; font-weight: 700; }
.checkout-error { margin: 0 0 20px; background: #fde8e7; color: #8b211d; }
.add-row { display: flex; align-items: end; gap: 12px; margin-top: 16px; }
.add-row label { color: var(--primary); font-size: .82rem; font-weight: 700; }
.add-row input, .cart-item input { display: block; width: 78px; margin-top: 5px; padding: 10px; border: 1px solid #bdc8d0; border-radius: 6px; font: inherit; }
.add-row button { flex: 1; }
.commerce-page { padding-block: 32px; min-height: 65vh; }
.commerce-page > h1 { margin-bottom: 26px; color: var(--primary); font-size: clamp(2rem, 4vw, 3rem); }
.cart-layout, .checkout-layout { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 28px; align-items: start; }
.cart-lines, .checkout-sections { display: grid; gap: 16px; }
.cart-item { display: grid; grid-template-columns: 110px minmax(0,1fr) auto auto; gap: 16px; align-items: center; padding: 16px; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.cart-item h2 { margin: 0 0 5px; font-size: 1.1rem; }
.cart-item p { margin: 2px 0; color: var(--muted); font-size: .86rem; }
.cart-thumb { display: grid; place-items: center; width: 110px; aspect-ratio: 1; overflow: hidden; border-radius: 8px; background: #f2f5f7; }
.cart-thumb img { width: 100%; height: 100%; object-fit: contain; }
.text-button { grid-column: 3 / 5; justify-self: end; padding: 0; color: #8b211d; background: transparent; font-size: .84rem; }
.order-summary { position: sticky; top: 18px; display: grid; gap: 13px; padding: 22px; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.order-summary h2 { margin: 0 0 5px; }
.order-summary > div { display: flex; justify-content: space-between; gap: 15px; padding-bottom: 11px; border-bottom: 1px solid var(--line); }
.order-summary p { margin: 0; color: var(--muted); font-size: .85rem; }
.order-summary .button-link { display: block; }
.checkout-card { padding: 24px; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.checkout-card h2 { margin: 0 0 18px; }
.field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.field-grid .span-2 { grid-column: 1 / -1; }
.field-grid label { color: var(--primary); font-size: .86rem; font-weight: 700; }
.field-grid label { min-width: 0; }
.field-grid label span { color: var(--muted); font-weight: 400; }
.field-grid input, .field-grid select {
  display: block; width: 100%; min-width: 0; min-height: 47px;
  margin-top: 6px; padding: 11px 12px;
  border: 1px solid #bdc8d0; border-radius: 6px;
  color: var(--ink); background: #fff; font: inherit;
}
.field-grid input:focus-visible, .field-grid select:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.fulfillment-options { display: flex; flex-wrap: wrap; gap: 12px 22px; margin-bottom: 18px; }
.fulfillment-options label { font-weight: 700; }
.shipping-fields.is-hidden { display: none; }
.pickup-location { display: none; padding: 14px 16px; border-radius: 8px; background: var(--wash); color: var(--ink); margin-bottom: 18px; white-space: normal; }
.fulfillment-options:has(input[value="pickup"]:checked) + .pickup-location { display: block; }
.pickup-location[hidden] { display: none; }
.checkout-summary small { display: block; margin-top: 5px; color: var(--muted); }
.setup-note, .payment-note { padding: 14px 16px; border-radius: 8px; background: var(--wash); }
.setup-note p, .payment-note { margin-bottom: 0; }
.summary-total { font-size: 1.08rem; }
.order-success { max-width: 700px; margin-inline: auto; text-align: center; }
.order-success h1 { margin-inline: auto; color: var(--primary); font-size: 2.6rem; }
.order-success .button-link { display: inline-block; margin-top: 12px; }
#card-container { min-height: 90px; }

@media (max-width: 980px) {
  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 800px) {
  .product-layout { grid-template-columns: minmax(0, 1fr); grid-template-areas: "summary" "gallery" "purchase"; }
  .phase-note { display: none; }
  .cart-layout, .checkout-layout { grid-template-columns: 1fr; }
  .order-summary { position: static; }
}

@media (max-width: 600px) {
  .shell { width: min(100% - 24px, 1120px); }
  .product-grid { grid-template-columns: 1fr; }
  .hero-inner { padding: 48px 0; }
  .product-page { padding-block: 18px; }
  .back-link { margin-bottom: 14px; }
  .content-card, .product-summary, .product-purchase { padding: 18px; }
  .gallery { padding: 12px; }
  .product-summary h1 { font-size: 1.45rem; }
  .gallery-stage { grid-template-columns: 1fr; }
  .gallery-thumbnails { grid-row: 2; display: flex; gap: 8px; overflow-x: auto; }
  .gallery-thumbnails button { flex: 0 0 60px; width: 60px; }
  .colour-swatch { padding: 6px 9px; }
  .size-options th, .size-options td { padding: 7px 4px; font-size: .76rem; }
  .brand-row { min-height: 68px; }
  .cart-item { grid-template-columns: 80px minmax(0,1fr); }
  .cart-thumb { width: 80px; }
  .cart-item > label, .cart-item > strong { grid-column: auto; }
  .text-button { grid-column: 2; }
  .field-grid { grid-template-columns: 1fr; }
  .field-grid .span-2 { grid-column: auto; }
  .checkout-card { padding: 18px; }
}
