/* ────────────────────────────────────────────────────────────────────────
   Grounded Wellness Centre — storefront theme styles.

   Self-contained: no build step, no framework. Every visual token is a CSS
   custom property under --sf-*, so a tenant restyles the site by overriding
   variables (or editing this file) without touching markup.

   Type is loaded deliberately per page (Cormorant + Montserrat via a <link>
   in each <head>) with a local serif/sans fallback here, so pages still read
   correctly if the font request is blocked.
   ──────────────────────────────────────────────────────────────────────── */

:root {
  /* palette — cream, olive, clay */
  --sf-bg: #f5f1ea;
  --sf-surface: #fbf9f5;
  --sf-text: #3f4338;
  --sf-muted: #716353;
  --sf-border: rgba(63, 67, 56, .2);
  --sf-accent: #a8795e;
  /* deeper clay for small text: --sf-accent is decorative (3.3:1 on cream) */
  --sf-accent-ink: #8a5b3f;
  --sf-accent-contrast: #fbf9f5;
  --sf-accent-soft: #ebe4d8;
  --sf-danger: #8e4b38;
  --sf-warn-soft: #f3e7dc;
  --sf-warn-text: #7b4630;

  /* form */
  --sf-radius: 2px;
  --sf-radius-sm: 2px;
  --sf-shadow: none;

  /* type */
  --sf-font: "Montserrat", "Helvetica Neue", Arial, sans-serif;
  --sf-mono: "Montserrat", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  /* rhythm */
  --sf-wrap: 1320px;
  --sf-gap: clamp(20px, 2.5vw, 32px);
  --sf-pad: clamp(20px, 4vw, 56px);
  --sf-header-h: 88px;

  /* brand extras (safe to override) */
  --gw-serif: "Cormorant", Georgia, "Times New Roman", serif;
  --gw-deep: #2e3129;
  --gw-sand: #ebe4d8;
  --gw-sand-2: #e8e1d5;
  --gw-plate: #f7f4ee;
  --gw-on-dark: #e8e1d5;
  --gw-accent-dark: #c9a68c;
  --gw-hair: rgba(63, 67, 56, .2);
  --gw-hair-light: rgba(245, 241, 234, .18);
  --gw-ink-soft: rgba(245, 241, 234, .78);
  --gw-pill: 999px;
}

* { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }

body {
  background: var(--sf-bg);
  color: var(--sf-text);
  font-family: var(--sf-font);
  font-size: 15px;
  font-weight: 400;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-text-size-adjust: 100%;
}

a { color: var(--sf-text); text-decoration: none; }
a:hover { color: var(--sf-accent-ink); }

h1, h2, h3 {
  font-family: var(--gw-serif);
  font-weight: 400;
  line-height: 1.02;
  letter-spacing: -.01em;
  margin: 0 0 10px;
  text-wrap: balance;
}

h1 { font-size: clamp(38px, 5.6vw, 76px); letter-spacing: -.015em; }
h2 { font-size: clamp(28px, 3.8vw, 52px); }
h3 { font-size: clamp(20px, 2vw, 26px); font-weight: 500; line-height: 1.15; }

h1 em, h2 em, h3 em { font-style: italic; }

p { margin: 0 0 14px; text-wrap: pretty; }
p:last-child { margin-bottom: 0; }

img { max-width: 100%; display: block; }

hr { border: 0; border-top: 1px solid var(--gw-hair); margin: 0; }

a:focus-visible,
button:focus-visible,
input:focus-visible,
summary:focus-visible {
  outline: 1px solid currentColor;
  outline-offset: 3px;
}

.sf-skip {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  background: var(--sf-text);
  color: var(--sf-accent-contrast);
  padding: 12px 20px;
  font-size: 11px;
  letter-spacing: .18em;
  text-transform: uppercase;
}

.sf-skip:focus { left: 12px; top: 12px; color: var(--sf-accent-contrast); }

/* ── layout ─────────────────────────────────────────────────────────── */

.sf-wrap {
  width: 100%;
  max-width: var(--sf-wrap);
  margin: 0 auto;
  padding-left: var(--sf-pad);
  padding-right: var(--sf-pad);
}

.sf-main {
  display: flex;
  flex-direction: column;
  padding: 0;
  min-height: 55vh;
}

/* full-bleed section band; put a .sf-wrap inside for the measure */
.sf-band { padding: clamp(44px, 6vw, 84px) 0; }
.sf-band--sand { background: var(--gw-sand); }
.sf-band--plate { background: var(--gw-plate); }
.sf-band--deep { background: var(--gw-deep); color: var(--gw-on-dark); }
.sf-band--tight { padding: clamp(18px, 3vw, 28px) 0; }
.sf-band--flush { padding-top: 0; }

.sf-band--deep h1,
.sf-band--deep h2,
.sf-band--deep h3 { color: var(--gw-on-dark); }

.sf-band--deep .sf-muted,
.sf-band--deep .sf-meta { color: var(--gw-ink-soft); }

.sf-band--deep .sf-lede,
.sf-band--deep p { color: var(--gw-ink-soft); }

.sf-band--deep h2 { color: var(--gw-on-dark); }

.sf-band--deep .sf-btn {
  background: #f5f1ea;
  border-color: #f5f1ea;
  color: var(--sf-text);
}

.sf-band--deep .sf-btn:hover { background: #fff; border-color: #fff; color: var(--sf-text); }

.sf-band--deep .sf-btn-ghost {
  background: transparent;
  border-color: var(--gw-hair-light);
  color: var(--gw-on-dark);
}

.sf-band--deep .sf-btn-ghost:hover {
  background: rgba(245, 241, 234, .1);
  border-color: rgba(245, 241, 234, .5);
  color: var(--gw-on-dark);
}

/* ── type helpers ───────────────────────────────────────────────────── */

.sf-eyebrow {
  margin: 0 0 18px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .3em;
  text-transform: uppercase;
  color: var(--sf-accent-ink);
}

.sf-band--deep .sf-eyebrow { color: var(--gw-accent-dark); }

.sf-lede {
  max-width: 48ch;
  font-size: 15px;
  line-height: 1.75;
  color: var(--sf-muted);
}

.sf-muted { color: var(--sf-muted); }
.sf-meta { color: var(--sf-muted); font-size: 12.5px; line-height: 1.6; margin: 0; }
.sf-fine { font-size: 12px; letter-spacing: .01em; }

.sf-tagline {
  font-family: var(--gw-serif);
  font-style: italic;
  font-size: clamp(20px, 1.8vw, 24px);
  line-height: 1.3;
  margin: 0;
}

.sf-section-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 24px;
  flex-wrap: wrap;
  margin-bottom: clamp(28px, 4vw, 52px);
}

.sf-panel + .sf-section-head,
.sf-plans + .sf-section-head { margin-top: clamp(32px, 4vw, 52px); }

.sf-page-head { display: flex; flex-direction: column; gap: 6px; }
.sf-toolbar { display: flex; flex-direction: column; gap: 14px; }

/* hidden must win over any layout rule below (blocks, grids, badges) */
[hidden] { display: none !important; }

/* an empty hydrated block leaves no margin behind */
[data-sf-block]:empty { display: none !important; }

/* ── header ─────────────────────────────────────────────────────────── */

.sf-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(245, 241, 234, .94);
  backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid var(--gw-hair);
}

.sf-head {
  min-height: var(--sf-header-h);
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: clamp(16px, 2vw, 32px);
  padding-top: 14px;
  padding-bottom: 14px;
}

.sf-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--sf-text);
  justify-self: start;
}

.sf-brand:hover { color: var(--sf-text); }

.sf-mark { width: 52px; height: 52px; flex: none; }

.sf-wordmark {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .2em;
  text-transform: uppercase;
  line-height: 1.4;
  max-width: 12ch;
}

.sf-nav {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: clamp(10px, 1.5vw, 26px);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .18em;
  text-transform: uppercase;
  line-height: 1.4;
}

.sf-nav a {
  color: var(--sf-text);
  white-space: nowrap;
  padding-bottom: 3px;
  border-bottom: 1px solid transparent;
}

.sf-nav a:hover { color: var(--sf-accent-ink); border-bottom-color: var(--sf-accent-ink); }

.sf-nav a[aria-current="page"] { border-bottom-color: currentColor; }

.sf-nav-cart { display: inline-flex; align-items: center; gap: 6px; }

.sf-count,
.sf-cart-count {
  display: inline-block;
  min-width: 18px;
  padding: 0 5px;
  border-radius: var(--gw-pill);
  background: var(--sf-accent);
  color: var(--sf-accent-contrast);
  font-size: 10px;
  font-weight: 600;
  line-height: 17px;
  letter-spacing: .04em;
  text-align: center;
}

.sf-account {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-self: end;
}

.sf-auth { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

.sf-user {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.sf-user-name {
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--sf-muted);
}

/* the account summary hangs under the header instead of widening its cell */
.sf-account-panel {
  position: absolute;
  top: calc(100% + 14px);
  right: 0;
  z-index: 50;
  width: min(360px, calc(100vw - 32px));
  background: var(--sf-surface);
  border: 1px solid var(--gw-hair);
  border-radius: var(--sf-radius);
  box-shadow: 0 18px 40px rgba(46, 49, 41, .18);
  padding: 16px 18px;
  font-size: 13px;
  line-height: 1.6;
}

.sf-account-panel dl {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 6px 18px;
  margin: 0;
}

.sf-account-panel dt {
  font-size: 10px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--sf-muted);
  align-self: center;
}

.sf-account-panel dd { margin: 0; font-weight: 600; text-align: right; }

/* ── buttons ────────────────────────────────────────────────────────── */

.sf-btn {
  font: inherit;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .2em;
  text-transform: uppercase;
  line-height: 1.2;
  border-radius: var(--gw-pill);
  border: 1px solid var(--sf-text);
  background: var(--sf-text);
  color: var(--sf-accent-contrast);
  padding: 16px 26px;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  white-space: nowrap;
  transition: background .25s ease, color .25s ease, border-color .25s ease;
}

.sf-btn:hover { background: var(--gw-deep); border-color: var(--gw-deep); color: var(--sf-accent-contrast); }

.sf-btn-primary { background: var(--sf-text); border-color: var(--sf-text); color: var(--sf-accent-contrast); }
.sf-btn-primary:hover { background: var(--gw-deep); border-color: var(--gw-deep); }

.sf-btn-ghost {
  background: transparent;
  color: var(--sf-text);
  border-color: var(--gw-hair);
}

.sf-btn-ghost:hover {
  background: var(--gw-sand);
  border-color: var(--gw-hair);
  color: var(--sf-text);
}

.sf-btn-danger {
  background: transparent;
  color: var(--sf-danger);
  border-color: rgba(142, 75, 56, .45);
}

.sf-btn-danger:hover { background: var(--sf-danger); border-color: var(--sf-danger); color: #fff; }

.sf-btn-sm { font-size: 10px; letter-spacing: .18em; padding: 11px 18px; }

.sf-btn[disabled],
.sf-btn[aria-disabled="true"] {
  background: transparent;
  border-color: var(--gw-hair);
  color: var(--sf-muted);
  opacity: 1;
  cursor: not-allowed;
}

.sf-btn[disabled]:hover,
.sf-btn[aria-disabled="true"]:hover {
  background: transparent;
  border-color: var(--gw-hair);
  color: var(--sf-muted);
}

.sf-btn-ghost[disabled]:hover {
  background: transparent;
  border-color: var(--gw-hair);
  color: var(--sf-text);
}

/* ── hero (home) ────────────────────────────────────────────────────── */

.sf-hero {
  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: min(88vh, 880px);
  padding: clamp(56px, 8vw, 96px) 0 clamp(36px, 5vw, 64px);
  color: #f5f1ea;
  overflow: hidden;
  background: var(--gw-deep);
}

.sf-hero-media {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
}

.sf-hero-shade {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(180deg, rgba(30, 32, 26, .58) 0%, rgba(30, 32, 26, .3) 26%, rgba(30, 32, 26, .46) 58%, rgba(30, 32, 26, .88) 100%),
    linear-gradient(90deg, rgba(30, 32, 26, .62) 0%, rgba(30, 32, 26, .46) 40%, rgba(30, 32, 26, .32) 70%, rgba(30, 32, 26, .14) 100%);
}

.sf-hero-inner {
  width: 100%;
  max-width: var(--sf-wrap);
  margin: 0 auto;
  padding-left: var(--sf-pad);
  padding-right: var(--sf-pad);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 400px);
  gap: clamp(24px, 4vw, 64px);
  align-items: end;
}

.sf-hero h1,
.sf-hero h2 {
  color: #f5f1ea;
  font-size: clamp(44px, 8.4vw, 124px);
  font-weight: 400;
  line-height: .92;
  letter-spacing: -.015em;
  margin: 0;
}

.sf-hero .sf-eyebrow { color: #f5f1ea; font-weight: 500; }

.sf-hero-body { display: flex; flex-direction: column; gap: 22px; }

.sf-hero-sub {
  font-family: var(--gw-serif);
  font-style: italic;
  font-size: clamp(22px, 2.6vw, 30px);
  line-height: 1.25;
  margin: 0;
  color: #f5f1ea;
}

.sf-hero-meta {
  margin: 0;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .18em;
  text-transform: uppercase;
  line-height: 1.8;
  color: rgba(245, 241, 234, .76);
}

.sf-hero-meta:empty { display: none; }

.sf-hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 4px; }

.sf-hero .sf-btn {
  background: #f5f1ea;
  border-color: #f5f1ea;
  color: var(--sf-text);
}

.sf-hero .sf-btn:hover { background: #fff; border-color: #fff; color: var(--sf-text); }

.sf-hero .sf-btn-ghost {
  background: transparent;
  border-color: rgba(245, 241, 234, .55);
  color: #f5f1ea;
}

.sf-hero .sf-btn-ghost:hover {
  background: rgba(245, 241, 234, .12);
  border-color: rgba(245, 241, 234, .8);
  color: #f5f1ea;
}

/* ── page hero (module pages) ───────────────────────────────────────── */

.sf-page-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
  gap: clamp(28px, 5vw, 72px);
  align-items: center;
  padding-top: clamp(36px, 5vw, 72px);
  padding-bottom: clamp(32px, 5vw, 64px);
}

.sf-page-hero--plain {
  grid-template-columns: minmax(0, 1fr);
  max-width: 780px;
  margin-left: 0;
}

.sf-page-hero h1 {
  font-size: clamp(38px, 6.2vw, 88px);
  line-height: .96;
  margin: 0 0 20px;
}

.sf-figure {
  margin: 0;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border-radius: var(--sf-radius);
  background: var(--gw-sand-2);
}

.sf-page-hero .sf-figure { max-height: min(64vh, 560px); }

.sf-figure--wide { aspect-ratio: 4 / 3; }

.sf-figure img { width: 100%; height: 100%; object-fit: cover; }

.sf-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(28px, 5vw, 72px);
  align-items: center;
}

.sf-split--media-right .sf-figure { order: 2; }

/* ── notice (error / empty / disabled / sign-in states) ─────────────── */

.sf-notice {
  border: 1px solid var(--gw-hair);
  background: var(--sf-surface);
  border-radius: var(--sf-radius);
  padding: 14px 20px;
  margin-bottom: clamp(20px, 3vw, 32px);
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 13.5px;
  line-height: 1.6;
}

.sf-notice[hidden] { display: none; }
.sf-notice-text { margin: 0; flex: 1 1 260px; }

/* notice slot sits directly under the header, above the page hero */
.sf-notice-slot .sf-notice { margin-top: clamp(18px, 2.5vw, 28px); margin-bottom: 0; }

.sf-notice.is-error {
  background: var(--sf-warn-soft);
  border-color: rgba(142, 75, 56, .3);
  color: var(--sf-warn-text);
}

.sf-notice.is-empty .sf-notice-text,
.sf-notice.is-disabled .sf-notice-text,
.sf-notice.is-signin .sf-notice-text,
.sf-notice.is-loading .sf-notice-text { color: var(--sf-muted); }

/* ── chips / categories ─────────────────────────────────────────────── */

.sf-chips { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 6px; }

.sf-chip {
  font: inherit;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--sf-text);
  background: transparent;
  border: 1px solid var(--gw-hair);
  border-radius: var(--gw-pill);
  padding: 9px 16px;
  cursor: pointer;
  transition: background .2s ease, color .2s ease, border-color .2s ease;
}

.sf-chip:hover { background: var(--gw-sand-2); }

.sf-chip.is-on {
  background: var(--sf-text);
  border-color: var(--sf-text);
  color: var(--sf-accent-contrast);
}

/* ── grids & cards ──────────────────────────────────────────────────── */

.sf-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: var(--sf-gap);
}

.sf-card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: transparent;
  border: 0;
  border-radius: 0;
}

.sf-card-media {
  aspect-ratio: 1 / 1;
  background: var(--gw-plate);
  border-radius: var(--sf-radius);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  color: var(--sf-muted);
  font-size: 12px;
  letter-spacing: .16em;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.sf-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  mix-blend-mode: multiply;
  transition: transform .9s cubic-bezier(.2, .7, .2, 1);
}

.sf-card:hover .sf-card-media img { transform: scale(1.03); }

.sf-card-body {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
  min-width: 0;
  padding: 0;
}

.sf-card-body h3 { margin: 0; overflow-wrap: anywhere; }
.sf-card-body h3 a { color: inherit; text-decoration: none; }
.sf-card-body h3 a:hover { color: var(--sf-accent-ink); }

.sf-card-desc {
  color: var(--sf-muted);
  font-size: 13px;
  line-height: 1.65;
  margin: 0;
  overflow-wrap: anywhere;
  display: -webkit-box;
  -webkit-line-clamp: 5;
  line-clamp: 5;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.sf-card-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 14px;
  align-items: center;
}

/* product buttons sit on the card floor so a row of cards lines up */
.sf-card-body > .sf-card-actions { margin-top: auto; padding-top: 16px; }

.sf-price {
  font-family: var(--sf-font);
  font-size: 15px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  letter-spacing: .01em;
}

.sf-price-was {
  font-size: 12.5px;
  color: var(--sf-muted);
  text-decoration: line-through;
  margin-left: 8px;
}

.sf-tag {
  align-self: flex-start;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--sf-accent-ink);
  margin-bottom: 2px;
}

/* a sale tag rides on the product plate, so titles stay in one line across a row */
.sf-card-body > .sf-tag {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 2;
  margin: 0;
  padding: 5px 11px;
  border-radius: var(--gw-pill);
  background: rgba(247, 244, 238, .92);
}

.sf-badge {
  align-self: flex-start;
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: .2em;
  text-transform: uppercase;
  background: var(--sf-accent-ink);
  color: var(--sf-accent-contrast);
  border-radius: var(--gw-pill);
  padding: 6px 12px;
}

/* home module tiles read as editorial entries, not product cards */
[data-sf-block="home.modules"] { gap: clamp(24px, 3vw, 44px); }

[data-sf-block="home.modules"] .sf-card {
  border-top: 1px solid var(--gw-hair);
  padding-top: 20px;
  gap: 10px;
}

[data-sf-block="home.modules"] .sf-card h3 { font-size: clamp(26px, 2.6vw, 34px); }
[data-sf-block="home.modules"] .sf-card-desc { font-size: 14px; max-width: 34ch; }

/* product actions stay quiet so the plate leads */
[data-sf-block="shop.products"] .sf-card-actions .sf-btn {
  background: transparent;
  border-color: var(--gw-hair);
  color: var(--sf-text);
}

[data-sf-block="shop.products"] .sf-card-actions .sf-btn:hover {
  background: var(--sf-text);
  border-color: var(--sf-text);
  color: var(--sf-accent-contrast);
}

/* ── schedule lists ─────────────────────────────────────────────────── */

.sf-day-group { margin-bottom: clamp(28px, 3.5vw, 44px); }
.sf-day-group:last-child { margin-bottom: 0; }

.sf-day-label {
  font-family: var(--sf-font);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: var(--sf-accent-ink);
  margin: 0 0 4px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--gw-hair);
}

.sf-row {
  display: flex;
  align-items: center;
  gap: clamp(12px, 2vw, 28px);
  flex-wrap: wrap;
  padding: 20px 0;
  border-bottom: 1px solid var(--gw-hair);
  background: transparent;
}

.sf-row-time {
  flex: none;
  min-width: 84px;
  font-family: var(--gw-serif);
  font-size: 20px;
  font-weight: 500;
  line-height: 1;
  letter-spacing: .01em;
  color: var(--sf-text);
  font-variant-numeric: tabular-nums;
}

.sf-row-main { flex: 1 1 240px; min-width: 0; }

.sf-row-main h3 {
  margin: 0 0 4px;
  font-size: clamp(20px, 2vw, 26px);
  overflow-wrap: anywhere;
}

.sf-row-side {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.sf-spots {
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--sf-muted);
  white-space: nowrap;
}

.sf-spots.is-full { color: var(--sf-danger); font-weight: 600; }

/* ── panels ─────────────────────────────────────────────────────────── */

.sf-panel {
  position: relative;
  background: var(--sf-surface);
  border: 1px solid var(--gw-hair);
  border-radius: var(--sf-radius);
  padding: clamp(20px, 3vw, 34px);
}

.sf-panel > h2:first-child { font-size: clamp(24px, 2.4vw, 32px); margin-bottom: 18px; }

/* ── cart ───────────────────────────────────────────────────────────── */

.sf-cart {
  background: var(--sf-surface);
  border: 1px solid var(--gw-hair);
  border-radius: var(--sf-radius);
  padding: clamp(20px, 3vw, 34px);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sf-cart h2 { font-size: clamp(22px, 2.2vw, 30px); margin: 0 0 6px; }

/* the shop page's mini cart sits under the grid and needs air above it */
[data-sf-page="shop"] .sf-cart { margin-top: clamp(32px, 4vw, 56px); }

/* an empty cart page collapses its panel instead of leaving a hollow box */
[data-sf-page="cart"] .sf-cart:has(> [data-sf-block]:empty) { display: none; }

.sf-line {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  padding: 16px 0;
  border-bottom: 1px solid var(--gw-hair);
}

.sf-line:last-child { border-bottom: 0; }

.sf-line-name {
  flex: 1 1 180px;
  min-width: 0;
  font-family: var(--gw-serif);
  font-size: 20px;
  font-weight: 500;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.sf-line-total {
  font-size: 14px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  min-width: 72px;
  text-align: right;
}

.sf-stepper { display: flex; align-items: center; gap: 6px; }

.sf-stepper button {
  font: inherit;
  font-size: 13px;
  width: 30px;
  height: 30px;
  border-radius: var(--gw-pill);
  border: 1px solid var(--gw-hair);
  background: transparent;
  color: var(--sf-text);
  cursor: pointer;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background .2s ease, color .2s ease;
}

.sf-stepper button:hover { background: var(--gw-sand); }

.sf-stepper output {
  min-width: 26px;
  text-align: center;
  font-size: 13px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.sf-cart-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  border-top: 1px solid var(--gw-hair);
  padding-top: 20px;
  margin-top: 8px;
}

.sf-cart-total {
  font-family: var(--gw-serif);
  font-size: clamp(22px, 2.2vw, 28px);
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}

.sf-cart-foot .sf-card-actions { margin-top: 0; }

/* ── plans / memberships ────────────────────────────────────────────── */

.sf-plans,
.sf-plans-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: var(--sf-gap);
}

.sf-plan {
  position: relative;
  background: transparent;
  border: 1px solid var(--gw-hair);
  border-radius: var(--sf-radius);
  padding: clamp(22px, 2.5vw, 30px);
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 0;
}

/* badges sit on the card's top edge so plan titles share a baseline;
   a second badge (current plan + popular) moves to the right corner */
.sf-plan > .sf-badge {
  position: absolute;
  top: -11px;
  left: clamp(22px, 2.5vw, 30px);
  margin: 0;
}

.sf-plan > .sf-badge ~ .sf-badge {
  left: auto;
  right: clamp(22px, 2.5vw, 30px);
}

.sf-plan h3 { margin: 0; font-size: clamp(22px, 2vw, 28px); }

.sf-plan.is-hot { border-color: var(--sf-accent); }

.sf-plan.is-current {
  background: var(--gw-sand);
  border-color: var(--sf-text);
}

.sf-plan-price {
  font-family: var(--gw-serif);
  font-size: clamp(34px, 3.4vw, 44px);
  font-weight: 500;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.sf-plan-price span {
  font-family: var(--sf-font);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--sf-muted);
  margin-left: 8px;
}

.sf-plan-feats {
  list-style: none;
  margin: 4px 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--sf-muted);
}

.sf-plan-feats li { padding-left: 18px; position: relative; }

.sf-plan-feats li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .72em;
  width: 8px;
  height: 1px;
  background: var(--sf-accent);
}

.sf-plan .sf-card-actions { margin-top: auto; padding-top: 14px; }

/* ── forms: sign in / register / checkout ───────────────────────────── */

.sf-form { display: flex; flex-direction: column; gap: 18px; }

.sf-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--sf-muted);
}

.sf-input {
  font: inherit;
  font-size: 14px;
  font-weight: 400;
  letter-spacing: 0;
  text-transform: none;
  color: var(--sf-text);
  background: var(--sf-bg);
  border: 1px solid var(--gw-hair);
  border-radius: var(--sf-radius);
  padding: 13px 14px;
  min-width: 0;
  transition: border-color .2s ease, background .2s ease;
}

.sf-input::placeholder { color: rgba(117, 102, 83, .6); }
.sf-input:focus { outline: none; border-color: var(--sf-text); background: var(--sf-surface); }
.sf-input:focus-visible { outline: none; border-color: var(--sf-text); }

.sf-field .sf-input { width: 100%; }

.sf-field-row { display: flex; gap: 14px; flex-wrap: wrap; }
.sf-field-row .sf-field { flex: 1 1 140px; }

.sf-auth-panel {
  width: 100%;
  max-width: 460px;
  margin: 0;
  background: transparent;
  border: 0;
  padding: 0;
}

.sf-auth-panel .sf-page-head { margin-bottom: 26px; }
.sf-auth-panel h1 { font-size: clamp(34px, 4.4vw, 56px); margin-bottom: 14px; }

.sf-form .sf-card-actions { margin-top: 4px; }

/* ── checkout ───────────────────────────────────────────────────────── */

.sf-checkout {
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: var(--sf-gap);
  align-items: start;
}

.sf-summary { display: flex; flex-direction: column; gap: 10px; }

.sf-summary-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--gw-hair);
  font-size: 13.5px;
}

.sf-summary-row:last-child { border-bottom: 0; padding-bottom: 0; }

.sf-summary-row span {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--sf-muted);
}

.sf-summary-row strong {
  font-family: var(--gw-serif);
  font-size: 19px;
  font-weight: 500;
  text-align: right;
  overflow-wrap: anywhere;
}

.sf-panel .sf-plan-feats { margin-top: 16px; }

.sf-result { display: flex; flex-direction: column; gap: 12px; align-items: flex-start; }
.sf-result h2 { margin: 0; }

/* ── footer & toast ─────────────────────────────────────────────────── */

.sf-footer {
  background: var(--gw-deep);
  color: var(--gw-on-dark);
  padding: clamp(52px, 7vw, 88px) 0 32px;
}

.sf-footer a { color: var(--gw-on-dark); }
.sf-footer a:hover { color: var(--gw-accent-dark); }

.sf-foot-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 190px), 1fr));
  gap: clamp(28px, 4vw, 48px);
}

.sf-foot-brand { display: flex; flex-direction: column; gap: 18px; }
.sf-foot-brand img { width: 88px; height: 88px; }

.sf-foot-col { display: flex; flex-direction: column; gap: 10px; font-size: 13.5px; }

.sf-foot-title {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .24em;
  text-transform: uppercase;
  color: var(--gw-accent-dark);
  margin-bottom: 6px;
}

.sf-foot-bottom {
  margin-top: clamp(36px, 4vw, 56px);
  padding-top: 22px;
  border-top: 1px solid var(--gw-hair-light);
  font-size: 11.5px;
  letter-spacing: .02em;
  color: rgba(232, 225, 213, .66);
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.sf-footer .sf-muted,
.sf-footer .sf-meta { color: var(--gw-ink-soft); }

.sf-toast {
  position: fixed;
  left: 50%;
  bottom: 26px;
  transform: translateX(-50%) translateY(14px);
  background: var(--gw-deep);
  color: #f5f1ea;
  padding: 13px 24px;
  border-radius: var(--gw-pill);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s ease, transform .2s ease;
  z-index: 60;
  max-width: calc(100vw - 32px);
  text-align: center;
}

.sf-toast.is-show { opacity: 1; transform: translateX(-50%) translateY(0); }
.sf-toast.is-error { background: var(--sf-danger); color: #fff; }

/* ── skeleton ───────────────────────────────────────────────────────── */

.sf-skel { animation: sf-pulse 1.4s ease-in-out infinite; }

@keyframes sf-pulse {
  0%, 100% { opacity: .45; }
  50% { opacity: .9; }
}

/* ── responsive ─────────────────────────────────────────────────────── */

@media (max-width: 1080px) {
  .sf-head {
    grid-template-columns: auto auto;
    justify-content: space-between;
    row-gap: 14px;
  }

  .sf-brand { grid-column: 1; grid-row: 1; }
  .sf-account { grid-column: 2; grid-row: 1; }

  .sf-nav {
    grid-column: 1 / -1;
    grid-row: 2;
    justify-content: flex-start;
    gap: 10px 20px;
  }

  .sf-hero-inner { grid-template-columns: minmax(0, 1fr); }
  .sf-hero-body { max-width: 420px; }
}

@media (max-width: 900px) {
  .sf-page-hero,
  .sf-split {
    grid-template-columns: minmax(0, 1fr);
  }

  .sf-split--media-right .sf-figure { order: 0; }
  .sf-figure { aspect-ratio: 3 / 2; }
  .sf-checkout { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  :root { --sf-pad: 18px; --sf-gap: 18px; --sf-header-h: 76px; }

  .sf-head {
    grid-template-columns: auto 1fr;
    align-items: center;
    row-gap: 12px;
  }

  .sf-mark { width: 44px; height: 44px; }
  .sf-wordmark { display: none; }

  .sf-account { grid-column: 2; grid-row: 1; justify-self: end; }
  .sf-nav {
    grid-column: 1 / -1;
    grid-row: 2;
    justify-content: flex-start;
    gap: 6px 10px;
    font-size: 10px;
    letter-spacing: .1em;
  }

  .sf-auth { gap: 6px; }
  .sf-auth .sf-btn,
  .sf-account .sf-btn-sm { padding: 10px 13px; font-size: 9px; letter-spacing: .12em; }

  .sf-hero { min-height: min(78vh, 640px); }

  .sf-hero h1,
  .sf-hero h2 { font-size: clamp(38px, 12vw, 64px); }

  .sf-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
  .sf-plans, .sf-plans-grid { grid-template-columns: 1fr; }

  .sf-row { gap: 10px; }
  .sf-row-time { min-width: 72px; font-size: 18px; }
  .sf-row-side { flex-basis: 100%; justify-content: space-between; }

  .sf-cart-foot { flex-direction: column; align-items: flex-start; }

  .sf-auth { width: 100%; justify-content: flex-end; }
  .sf-account-panel { font-size: 12.5px; }

  .sf-figure { aspect-ratio: 4 / 3; }
}

/* ── product page (/shop?product=…) ──────────────────────────────────── */

/* The product view renders into the products block, which is a card grid on the
   listing. One block is not a grid: flatten the host while the view is up. */
.sf-grid.sf-pd-host { display: block; }

/* A product page is its own view — suppress the listing hero and its section
   heading (the shop page's "The range / Stocked at reception." band). */
body[data-sf-view="product"] .sf-page-hero,
body[data-sf-view="product"] .sf-section-head { display: none; }

.sf-card-link { color: inherit; text-decoration: none; }
.sf-card-link:hover h3 { text-decoration: underline; text-underline-offset: 3px; }
a.sf-card-media { color: inherit; text-decoration: none; }

.sf-back {
  display: inline-block;
  margin-bottom: clamp(16px, 2vw, 26px);
  font-size: 11px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--sf-muted);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  padding-bottom: 2px;
}

.sf-back:hover { color: var(--sf-accent-ink); border-bottom-color: var(--gw-hair); }

.sf-pd {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(24px, 4vw, 64px);
  align-items: start;
}

.sf-pd-media { background: var(--gw-plate); border-radius: var(--sf-radius); padding: clamp(12px, 2vw, 28px); }

.sf-pd-media img { width: 100%; height: auto; object-fit: cover; display: block; }

.sf-pd-thumbs { display: flex; gap: 10px; margin-top: 12px; flex-wrap: wrap; }

.sf-pd-thumbs img {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: var(--sf-radius);
  border: 1px solid var(--gw-hair);
  cursor: pointer;
  background: var(--sf-surface);
}

.sf-pd-info { display: flex; flex-direction: column; gap: 16px; }

.sf-pd-info h1 {
  font-family: var(--gw-serif);
  font-weight: 400;
  font-size: clamp(28px, 3.2vw, 44px);
  line-height: 1.1;
  letter-spacing: -.01em;
  margin: 0;
}

.sf-pd-desc {
  color: var(--sf-muted);
  font-size: 14px;
  line-height: 1.75;
  margin: 0;
  white-space: pre-line;
  max-width: 62ch;
}

.sf-pd-buy { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 4px; }

@media (max-width: 820px) {
  .sf-pd { grid-template-columns: minmax(0, 1fr); }
}

/* Price and the stock note on one line: price left, note right (SAH-5357).
   The note never breaks mid-phrase; the row wraps as a whole on a narrow card. */
.sf-price-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.sf-price-row .sf-stock {
  margin-left: auto;
  text-align: right;
  white-space: nowrap;
}
