/* Yoga & Pilates — calm studio UI with clearer depth & type */
:root {
  --ink: #241820;
  --muted: #6f5864;
  --line: #ebd8e0;
  --bg: #faf3f6;
  --surface: #ffffff;
  /* Primary — rose */
  --accent: #c93d72;
  --accent-deep: #a02c59;
  --accent-soft: #f8e4ec;
  /* Secondary — sea-glass teal */
  --secondary: #357370;
  --secondary-deep: #285956;
  --secondary-soft: #e4f0ef;
  --warn: #b84f32;
  --clay: #b84f32;
  --radius: 12px;
  --radius-sm: 8px;
  --font: "Manrope", system-ui, -apple-system, sans-serif;
  --font-display: "Fraunces", "Times New Roman", serif;
  --max: 980px;
  /* Page side gutter (each side). Keep nav / .container / full-bleed panels on this token. */
  --gutter: 1rem;
  --nav-h: 64px;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  overflow-x: hidden;
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background:
    radial-gradient(900px 420px at 8% -8%, rgba(201, 61, 114, 0.09), transparent 55%),
    radial-gradient(780px 380px at 96% 4%, rgba(53, 115, 112, 0.08), transparent 50%),
    linear-gradient(180deg, #fdf7fa 0%, var(--bg) 38%, #f6eef2 100%);
  background-attachment: fixed;
  line-height: 1.62;
  font-size: 16px;
  letter-spacing: -0.01em;
  -webkit-font-smoothing: antialiased;
}
body.nav-open {
  overflow: hidden;
  touch-action: none;
}
/* Mobile menu lives inside .site-nav's stacking context — lift above dock/scrim peers. */
body.nav-open .site-nav {
  z-index: 60;
}
body.nav-open .mobile-dock,
body.nav-open .reserve-bar {
  visibility: hidden;
  pointer-events: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

a:hover {
  color: var(--ink);
}

h1, h2, h3 {
  font-family: var(--font-display);
  line-height: 1.2;
  letter-spacing: -0.025em;
  font-weight: 600;
  color: var(--ink);
}

h1 { font-size: clamp(1.9rem, 4.2vw, 2.45rem); margin: 0 0 0.75rem; }
h2 { font-size: clamp(1.45rem, 3.2vw, 1.85rem); margin: 0 0 0.5rem; }
h3 { font-size: 1.12rem; margin: 0 0 0.35rem; font-weight: 550; }

p { margin: 0 0 1rem; color: var(--muted); }
p:last-child { margin-bottom: 0; }

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--ink);
  color: #fff;
  padding: 0.5rem 1rem;
  z-index: 100;
}
.skip-link:focus {
  left: 0.5rem;
  top: 0.5rem;
}

.container {
  width: min(calc(100% - (var(--gutter) * 2)), var(--max));
  margin-inline: auto;
  padding-left: env(safe-area-inset-left, 0);
  padding-right: env(safe-area-inset-right, 0);
}

/* Nav */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 40;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  background: rgba(253, 247, 250, 0.86);
  border-bottom: 1px solid color-mix(in srgb, var(--line) 85%, transparent);
  backdrop-filter: blur(14px) saturate(1.15);
}
body.admin-bar .site-nav {
  top: 32px;
}
@media screen and (max-width: 782px) {
  body.admin-bar .site-nav {
    top: 46px;
  }
}

.site-nav .inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  width: min(calc(100% - (var(--gutter) * 2)), var(--max));
  margin-inline: auto;
  padding-left: env(safe-area-inset-left, 0);
  padding-right: env(safe-area-inset-right, 0);
}

.brand {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.18rem;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: -0.03em;
  min-width: 0;
  flex: 1 1 auto;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.brand span { color: var(--accent); font-weight: 500; font-style: italic; }

.nav-tools {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  flex: 0 0 auto;
}
.lang-switch {
  display: inline-grid;
  grid-template-columns: 1fr 1fr;
  align-items: stretch;
  flex: 0 0 auto;
  margin-right: 0.2rem;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: color-mix(in srgb, var(--surface) 70%, var(--accent-soft));
  gap: 2px;
  overflow: hidden;
}
.lang-switch__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  color: var(--muted);
  text-decoration: none;
  min-width: 2.1rem;
  height: 1.7rem;
  min-height: 1.7rem;
  padding: 0 0.55rem;
  margin: 0;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  line-height: 1;
  text-align: center;
  white-space: nowrap;
  transition: background 0.18s ease, color 0.18s ease;
}
.lang-switch__btn.is-active {
  background: var(--accent);
  color: #fff;
}
.lang-switch__btn:not(.is-active):hover {
  color: var(--ink);
  background: color-mix(in srgb, var(--surface) 55%, transparent);
}
.nav-notify {
  position: relative;
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 10px;
  color: var(--ink);
  text-decoration: none;
}
.nav-notify:hover,
.nav-notify.is-current {
  background: color-mix(in srgb, var(--ink) 5%, transparent);
  color: var(--accent-deep);
}
.nav-notify svg {
  width: 1.25rem;
  height: 1.25rem;
  stroke-width: 1.75;
}
.nav-notify__badge {
  position: absolute;
  top: 0.35rem;
  right: 0.3rem;
  min-width: 1rem;
  height: 1rem;
  padding: 0 0.22rem;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-size: 0.62rem;
  font-weight: 700;
  line-height: 1rem;
  text-align: center;
}
@media (min-width: 861px) {
  .brand { order: 1; flex: 0 1 auto; }
  .nav-links { order: 2; margin-left: auto; }
  .nav-tools { order: 3; margin-left: 0.5rem; }
  .nav-toggle { display: none !important; }
}
@media (max-width: 860px) {
  .site-nav .inner {
    align-items: center;
    gap: 0.4rem;
  }
  .brand-wrap {
    display: inline-flex;
    align-items: center;
    min-width: 0;
  }
  .brand {
    font-size: 1.05rem;
    max-width: min(42vw, 9.5rem);
    line-height: 1.15;
  }
  .nav-tools {
    gap: 0.2rem;
    align-items: center;
  }
  .lang-switch {
    margin-right: 0.05rem;
    padding: 2px;
    gap: 1px;
  }
  .lang-switch__btn {
    min-width: 2rem;
    height: 1.85rem;
    min-height: 1.85rem;
    padding: 0 0.5rem;
    font-size: 0.68rem;
  }
  .nav-notify,
  .nav-toggle {
    width: 44px;
    height: 44px;
    min-width: 44px;
    min-height: 44px;
  }
}

.nav-links {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: 0.1rem;
}
.nav-links > .nav-link,
.nav-flyout__btn {
  padding: 0.4rem 0.65rem;
  border-radius: 6px;
  font-size: 0.9rem;
  font-weight: 550;
  color: var(--ink);
  text-decoration: none;
  white-space: nowrap;
}
.nav-links > .nav-link:hover,
.nav-links > .nav-link[aria-current="page"],
.nav-flyout.is-current > .nav-flyout__btn,
.nav-flyout[open] > .nav-flyout__btn {
  color: var(--accent);
  background: var(--accent-soft);
}
.nav-links a.admin-link,
.nav-flyout__link.admin-link { color: var(--warn); }
.nav-link--cta {
  background: var(--accent-soft);
  color: var(--accent-deep) !important;
  font-weight: 650;
}
.nav-unread {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.1rem;
  height: 1.1rem;
  margin-left: 0.2rem;
  padding: 0 0.28rem;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 700;
  line-height: 1;
  vertical-align: middle;
}

/* Compact flyouts: More / Account */
.nav-flyout {
  position: relative;
}
.nav-flyout__btn {
  list-style: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.28rem;
  user-select: none;
  font: inherit;
}
.nav-flyout__btn::-webkit-details-marker { display: none; }
.nav-flyout__caret {
  width: 0;
  height: 0;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 5px solid currentColor;
  opacity: 0.55;
  translate: 0 1px;
}
.nav-flyout[open] .nav-flyout__caret { rotate: 180deg; }
.nav-flyout__panel {
  position: absolute;
  top: calc(100% + 0.35rem);
  right: 0;
  min-width: 12.5rem;
  padding: 0.45rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: 0 12px 32px rgba(42, 31, 36, 0.12);
  z-index: 60;
  display: grid;
  gap: 0.1rem;
}
/* Author `display` overrides UA hiding of closed <details> content — hide explicitly. */
.nav-flyout:not([open]) > .nav-flyout__panel {
  display: none;
}
.nav-flyout__label {
  margin: 0.15rem 0.55rem 0.35rem;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--muted);
}
.nav-flyout__link {
  display: block;
  padding: 0.55rem 0.65rem;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 550;
  color: var(--ink);
  text-decoration: none;
}
.nav-flyout__link:hover,
.nav-flyout__link[aria-current="page"] {
  background: var(--accent-soft);
  color: var(--accent-deep);
}
.nav-flyout__link--muted { color: var(--muted); }
.nav-flyout__divider {
  height: 1px;
  margin: 0.3rem 0.4rem;
  background: var(--line);
}

.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  border: 0;
  background: transparent;
  border-radius: 10px;
  padding: 0;
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  cursor: pointer;
  color: var(--ink);
  -webkit-tap-highlight-color: transparent;
}
.nav-toggle:hover,
.nav-toggle:focus-visible {
  background: color-mix(in srgb, var(--ink) 5%, transparent);
}
.nav-toggle:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--accent) 55%, transparent);
  outline-offset: 1px;
}
.nav-toggle__bars {
  position: relative;
  display: block;
  width: 1.2rem;
  height: 0.72rem;
}
.nav-toggle__bars span {
  position: absolute;
  left: 0;
  height: 1.5px;
  border-radius: 999px;
  background: currentColor;
  transition: transform 0.2s ease, opacity 0.16s ease, top 0.2s ease, width 0.2s ease;
}
.nav-toggle__bars span:nth-child(1) { top: 0; width: 100%; }
.nav-toggle__bars span:nth-child(2) { top: 50%; width: 72%; margin-top: -0.75px; }
.nav-toggle__bars span:nth-child(3) { bottom: 0; top: auto; width: 100%; }
body.nav-open .nav-toggle__bars span:nth-child(1) {
  top: 50%;
  width: 100%;
  margin-top: -0.75px;
  transform: rotate(45deg);
}
body.nav-open .nav-toggle__bars span:nth-child(2) {
  opacity: 0;
  width: 100%;
  transform: scaleX(0.35);
}
body.nav-open .nav-toggle__bars span:nth-child(3) {
  top: 50%;
  bottom: auto;
  width: 100%;
  margin-top: -0.75px;
  transform: rotate(-45deg);
}
@media (prefers-reduced-motion: reduce) {
  .nav-toggle__bars span { transition: none; }
}
.nav-scrim {
  display: none;
  position: fixed;
  inset: var(--nav-h) 0 0;
  background: rgba(42, 31, 36, 0.35);
  z-index: 45;
  border: 0;
  padding: 0;
  cursor: pointer;
}
body.nav-open .nav-scrim {
  display: block;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.78rem 1.25rem;
  min-height: 46px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  font-weight: 700;
  font-size: 0.9rem;
  font-family: var(--font);
  letter-spacing: 0.01em;
  cursor: pointer;
  text-decoration: none;
  line-height: 1.2;
  -webkit-tap-highlight-color: transparent;
}
.btn-primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.18) inset;
}
.btn-primary:hover { background: var(--accent-deep); color: #fff; }
.btn-secondary {
  background: color-mix(in srgb, var(--surface) 88%, var(--accent-soft));
  border-color: color-mix(in srgb, var(--line) 70%, var(--accent));
  color: var(--ink);
}
.btn-secondary:hover {
  background: var(--secondary-soft);
  border-color: #c5dedc;
  color: var(--secondary-deep);
}
.btn:focus-visible,
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--secondary);
  outline-offset: 2px;
}
.btn-block { width: 100%; }
.btn-sm {
  padding: 0.5rem 0.9rem;
  min-height: 40px;
  font-size: 0.85rem;
}
.booking-row .class-side {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.45rem;
}
.booking-row h3 a {
  color: inherit;
  text-decoration: none;
}
.booking-row h3 a:hover {
  color: var(--accent);
}
.btn:disabled,
.btn[aria-disabled="true"] {
  opacity: 0.45;
  cursor: not-allowed;
}

/* Hero — full-bleed visual (studio sites lead with photo) */
.hero-visual {
  position: relative;
  min-height: calc(100vh - var(--nav-h));
  min-height: min(92vh, 820px);
  display: grid;
  align-items: end;
  overflow: hidden;
  color: #f7faf8;
  border-bottom: 0;
}
.hero-media {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 28%;
  animation: heroDrift 22s ease-in-out infinite alternate;
}
.hero-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(105deg, rgba(22, 8, 14, 0.72) 0%, rgba(22, 8, 14, 0.42) 34%, rgba(22, 8, 14, 0.08) 58%, transparent 74%),
    linear-gradient(180deg, rgba(42, 20, 30, 0.2) 0%, rgba(42, 20, 30, 0.18) 28%, rgba(16, 6, 12, 0.88) 100%);
}
.hero-content {
  position: relative;
  z-index: 1;
  padding: 3.25rem 0 3.75rem;
}
/* Keep .container gutter alignment — constrain copy, not the whole box */
.hero-content.container {
  max-width: var(--max);
}
.hero-content > :is(.hero-brand, h1, .hero-lead, .hero-actions) {
  max-width: 34rem;
}
@media (max-width: 640px) {
  .hero-content {
    padding: 1.65rem 0 calc(5.25rem + env(safe-area-inset-bottom, 0px));
  }
  .hero-brand {
    /* Keep brand strong but leave room for H1 + CTAs above the fold */
    font-size: clamp(1.7rem, 8.5vw, 2.1rem);
  }
  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }
  .hero-actions .btn {
    width: 100%;
    justify-content: center;
    min-height: 48px;
  }
}
.hero-brand {
  margin: 0 0 0.65rem;
  font-family: var(--font-display);
  font-size: clamp(2.55rem, 7vw, 4.4rem);
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1.02;
  color: #fffafc;
  text-shadow: 0 1px 24px rgba(20, 8, 14, 0.35);
}
.hero-visual h1 {
  color: #fffafc;
  font-family: var(--font);
  font-size: clamp(1.12rem, 2.4vw, 1.35rem);
  font-weight: 600;
  letter-spacing: -0.015em;
  max-width: 28rem;
  margin: 0 0 0.85rem;
  text-shadow: 0 1px 16px rgba(20, 8, 14, 0.3);
}
.hero-lead {
  max-width: 28rem;
  font-size: 1.05rem;
  color: rgba(255, 250, 252, 0.9);
  margin: 0 0 1.5rem;
  text-shadow: 0 1px 12px rgba(20, 8, 14, 0.25);
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}
.btn-ghost-light {
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.62);
  color: #fff;
  backdrop-filter: blur(8px);
}
.btn-ghost-light:hover {
  background: rgba(255, 255, 255, 0.26);
  color: #fff;
}
.hero-actions--types .btn-primary {
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.2) inset,
    0 10px 28px rgba(20, 8, 14, 0.28);
}
.tldr {
  border-left: 3px solid var(--accent);
  padding: 0.85rem 1rem;
  background: var(--accent-soft);
  border-radius: 0 6px 6px 0;
  margin: 0;
  max-width: none;
  width: 100%;
  box-sizing: border-box;
}
.tldr-wide { max-width: none; }
.tldr strong {
  display: block;
  color: var(--ink);
  margin-bottom: 0.25rem;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.tldr p {
  margin: 0;
  color: var(--ink);
  font-size: 0.95rem;
  max-width: none;
}

.section-tight { padding-top: 1.5rem; }

.day-group { margin-bottom: 1.35rem; }
.day-group:last-child { margin-bottom: 0; }
.day-label {
  margin: 0 0 0.65rem;
  font-family: var(--font);
  font-size: 0.78rem;
  font-weight: 750;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--secondary-deep);
}
.schedule-more {
  margin: 1.25rem 0 0;
  text-align: center;
}

.instructor-strip {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 0.85rem 1.25rem;
}
.instructor-strip li {
  padding: 1.15rem 1.2rem;
  background:
    linear-gradient(165deg, color-mix(in srgb, var(--secondary-soft) 55%, #fff) 0%, var(--surface) 70%);
  border: 1px solid var(--line);
  border-bottom: 3px solid var(--secondary);
  border-radius: var(--radius) var(--radius) 0 0;
}
.instructor-strip strong {
  display: block;
  font-family: var(--font-display);
  color: var(--ink);
  font-size: 1.15rem;
  letter-spacing: -0.02em;
  margin-bottom: 0.25rem;
}
.instructor-strip span {
  color: var(--muted);
  font-size: 0.88rem;
}

.price-band {
  background:
    radial-gradient(700px 280px at 12% 20%, rgba(201, 61, 114, 0.12), transparent 60%),
    radial-gradient(640px 260px at 90% 80%, rgba(53, 115, 112, 0.1), transparent 55%),
    linear-gradient(135deg, var(--accent-soft) 0%, #fff 52%, var(--secondary-soft) 100%);
  border-block: 1px solid var(--line);
  padding: 3rem 0;
}
.price-band-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  justify-content: space-between;
  gap: 1.25rem 2rem;
}
.price-band .eyebrow {
  margin: 0 0 0.4rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}
.price-band h2 { margin: 0 0 0.5rem; max-width: 22rem; }
.price-band p { margin: 0; max-width: 34rem; }
.price-band-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.visit-band {
  padding: 2.25rem 0;
  background: var(--surface);
  border-bottom: 1px solid var(--line);
}
.visit-band-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem 2rem;
}
.visit-band .eyebrow {
  margin: 0 0 0.35rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--secondary);
}
.visit-band h2 { margin: 0 0 0.35rem; }
.visit-band p { margin: 0; max-width: 32rem; }
.visit-hours {
  margin-top: 0.45rem !important;
  color: var(--muted);
  font-size: 0.9rem;
}
.visit-meta {
  margin-top: 0.65rem !important;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
}

.screen-reader-text {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.photo-band {
  width: 100%;
  max-height: 420px;
  overflow: hidden;
  border-block: 1px solid var(--line);
}
.photo-band img {
  width: 100%;
  height: 420px;
  object-fit: cover;
}

.hero-actions--types {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.65rem;
  width: min(100%, 28rem);
}
.hero-actions--types .btn {
  width: 100%;
  text-align: center;
  justify-content: center;
}
.hero-actions--types .hero-actions__price {
  grid-column: 1 / -1;
}
.offer-card--link {
  color: inherit;
  text-decoration: none;
}
.offer-card--link:hover { color: inherit; }
.offer-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}
.offer-grid.offer-grid--two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
@media (max-width: 720px) {
  .offer-grid.offer-grid--two {
    grid-template-columns: 1fr;
  }
  .hero-actions--types {
    grid-template-columns: 1fr;
    width: 100%;
  }
}
.offer-card {
  background: var(--surface);
  border: 1px solid color-mix(in srgb, var(--line) 80%, var(--accent));
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.offer-media {
  margin: 0;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  position: relative;
}
.offer-media::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 42%;
  background: linear-gradient(180deg, transparent, rgba(36, 24, 32, 0.18));
  pointer-events: none;
}
.offer-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.7s var(--ease-out);
}
.offer-card:hover .offer-media img {
  transform: scale(1.06);
}
.offer-body {
  padding: 1.2rem 1.2rem 1.35rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  flex: 1;
}
.offer-body h3 {
  font-family: var(--font-display);
  font-size: 1.35rem;
  letter-spacing: -0.03em;
}
.offer-body p { margin: 0; font-size: 0.94rem; }
.offer-body .text-link {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.88rem;
  font-weight: 750;
  text-decoration: none;
  color: var(--secondary-deep);
  letter-spacing: 0.02em;
  padding-top: 0.35rem;
  border-top: 1px solid var(--line);
}
.offer-body .text-link::after {
  content: "→";
  transition: transform 0.22s var(--ease-out);
}
.offer-body .text-link:hover { color: var(--accent); }
.offer-card:hover .offer-body .text-link::after {
  transform: translateX(3px);
}

.split-story {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  min-height: 500px;
  border-bottom: 1px solid var(--line);
  background:
    linear-gradient(120deg, #fff 0%, color-mix(in srgb, var(--secondary-soft) 40%, #fff) 100%);
}
.split-media {
  overflow: hidden;
  min-height: 320px;
  position: relative;
}
.split-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 1.1s var(--ease-out);
}
.split-story:hover .split-media img {
  transform: scale(1.04);
}
.split-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 2.75rem 2.15rem;
  gap: 0.95rem;
}
.split-copy .eyebrow {
  margin: 0;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}
.split-copy h2 { margin: 0; }
.split-copy p { margin: 0 0 0.5rem; max-width: 28rem; }
.split-copy .btn { align-self: flex-start; }

@keyframes heroDrift {
  from { transform: scale(1.02); }
  to { transform: scale(1.08) translateY(-1.2%); }
}
@keyframes riseIn {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Hero: staggered presence */
.hero-content .hero-brand,
.hero-content h1,
.hero-content .hero-lead,
.hero-content .hero-actions {
  animation: fadeUp 0.7s ease-out both;
}
.hero-content .hero-brand { animation-delay: 0.05s; }
.hero-content h1 { animation-delay: 0.18s; }
.hero-content .hero-lead { animation-delay: 0.3s; }
.hero-content .hero-actions { animation-delay: 0.42s; }

/* Scroll reveal */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition:
    opacity 0.65s ease,
    transform 0.65s ease;
  transition-delay: var(--reveal-delay, 0ms);
}
.reveal.is-in {
  opacity: 1;
  transform: translateY(0);
}

/* Soft interactive motion */
.btn {
  transition:
    background 0.22s var(--ease-out),
    color 0.22s ease,
    border-color 0.22s ease,
    transform 0.22s var(--ease-out),
    box-shadow 0.22s ease;
}
.btn:hover:not(:disabled):not([aria-disabled="true"]) {
  transform: translateY(-2px);
}
.btn:active:not(:disabled):not([aria-disabled="true"]) {
  transform: translateY(0);
}
.offer-card,
.detail-panel,
.balance-block,
.topup-block,
.history-block,
.session-card {
  transition: transform 0.35s var(--ease-out), box-shadow 0.35s ease, border-color 0.25s ease;
}
.offer-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 34px rgba(36, 24, 32, 0.09);
  border-color: color-mix(in srgb, var(--accent) 28%, var(--line));
}
.session-card:hover {
  transform: translateY(-2px);
  border-color: color-mix(in srgb, var(--secondary) 35%, var(--line));
  box-shadow: 0 10px 26px rgba(36, 24, 32, 0.06);
}
.chip {
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}
.chip:hover { transform: translateY(-1px); }
.page-hero {
  animation: fadeUp 0.55s ease-out both;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .reveal {
    opacity: 1;
    transform: none;
  }
  .hero-media img {
    animation: none;
  }
}

/* Sections */
.section {
  padding: 3.25rem 0;
  border-bottom: 1px solid color-mix(in srgb, var(--line) 75%, transparent);
}
.section:last-of-type { border-bottom: 0; }
.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.75rem;
}
.section-head h2 {
  position: relative;
  padding-bottom: 0.55rem;
}
.section-head h2::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 2.25rem;
  height: 2px;
  background: var(--accent);
  border-radius: 2px;
}
.section-head p { max-width: 36rem; margin: 0; }

.filters { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.chip {
  border: 1px solid var(--line);
  background: color-mix(in srgb, var(--surface) 80%, var(--accent-soft));
  color: var(--muted);
  border-radius: 999px;
  padding: 0.45rem 0.95rem;
  min-height: 44px;
  font-size: 0.84rem;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  letter-spacing: 0.01em;
  display: inline-flex;
  align-items: center;
}
.chip[aria-pressed="true"],
.chip:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  box-shadow: 0 6px 16px rgba(201, 61, 114, 0.22);
}

/* Class list */
.class-list { display: grid; gap: 0.75rem; }
.class-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 1rem;
  align-items: center;
  padding: 1.1rem 1.15rem;
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--surface) 90%, var(--accent-soft)) 0%, var(--surface) 100%);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  text-decoration: none;
  color: inherit;
  transition: border-color 0.2s ease, transform 0.3s var(--ease-out), box-shadow 0.3s ease;
}
.class-row h3 {
  font-family: var(--font-display);
  font-size: 1.12rem;
  letter-spacing: -0.02em;
}
.class-row:hover {
  border-color: color-mix(in srgb, var(--accent) 45%, var(--line));
  color: inherit;
  transform: translateY(-3px);
  box-shadow: 0 12px 30px rgba(36, 24, 32, 0.08);
}
.class-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem 0.75rem;
  align-items: center;
  margin-bottom: 0.25rem;
}
.tag {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0.2rem 0.45rem;
  border-radius: 4px;
  background: var(--accent-soft);
  color: var(--accent-deep);
}
.tag.pilates {
  background: var(--secondary-soft);
  color: var(--secondary-deep);
}
.class-row .sub,
.sub { margin: 0; color: var(--muted); font-size: 0.9rem; }
.class-side {
  text-align: right;
  display: grid;
  gap: 0.25rem;
  justify-items: end;
}
.price {
  font-weight: 650;
  font-size: 1.05rem;
  color: var(--ink);
}
.seats { font-size: 0.85rem; color: var(--muted); }
.seats.low { color: var(--warn); font-weight: 600; }
.seats.full { color: #7a3030; font-weight: 700; }

/* Page header */
.page-hero { padding: 2.35rem 0 1.25rem; }
.page-hero--flush {
  padding-left: 0;
  padding-right: 0;
}
.page-hero .eyebrow {
  font-size: 0.72rem;
  font-weight: 750;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 0.45rem;
}
.page-hero h1 {
  max-width: 18ch;
}
.page-hero p { max-width: 38rem; }
.page-hero .tldr,
.page-hero .tldr p {
  max-width: none;
}

.breadcrumbs {
  padding: 0.85rem 0 0;
  font-size: 0.85rem;
}
.breadcrumbs ol {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  color: var(--muted);
}
.breadcrumbs li:not(:last-child)::after {
  content: "/";
  margin-left: 0.35rem;
  color: var(--line);
}
.breadcrumbs a { color: var(--muted); text-decoration: none; }
.breadcrumbs a:hover { color: var(--accent); }
.breadcrumbs [aria-current="page"] { color: var(--ink); }

/* Content / prose */
.prose { max-width: 40rem; }
.prose ul, .prose ol { color: var(--muted); padding-left: 1.2rem; }
.prose li { margin-bottom: 0.4rem; }
.steps {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.85rem;
}
.steps li {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.95rem;
  align-items: start;
  padding: 1.15rem 1.2rem;
  background:
    linear-gradient(145deg, color-mix(in srgb, var(--accent-soft) 40%, #fff) 0%, var(--surface) 55%);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.steps .num {
  width: 1.9rem;
  height: 1.9rem;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 750;
  font-size: 0.85rem;
  box-shadow: 0 4px 12px rgba(201, 61, 114, 0.28);
}
.steps strong { display: block; color: var(--ink); margin-bottom: 0.2rem; }
.steps p { margin: 0; font-size: 0.92rem; }

.simple-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 0.85rem;
}
.simple-card {
  padding: 1.15rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.simple-card h2 {
  font-size: 1.15rem;
  margin: 0 0 0.35rem;
}
.simple-card h3 { margin-bottom: 0.4rem; }
.simple-card p { margin: 0; font-size: 0.92rem; }
.pricing-grid {
  align-items: stretch;
}
.plan-card {
  border-color: #f0c9d8;
  background:
    linear-gradient(180deg, var(--accent-soft) 0%, var(--surface) 42%);
  box-shadow: 0 8px 24px rgba(42, 31, 36, 0.05);
}
.plan-eyebrow {
  margin: 0 0 0.35rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}
.plan-eyebrow-muted { color: var(--muted); }
.plan-price {
  margin: 0.15rem 0 0.85rem !important;
  font-size: 1.75rem !important;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--ink) !important;
  line-height: 1.15;
}
.plan-price span {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--muted);
}
.plan-perks {
  margin: 0.85rem 0 1.1rem !important;
}
.plan-presets {
  margin: 0.75rem 0 1rem !important;
  font-weight: 650;
  color: var(--ink) !important;
}
.policy-warn {
  color: var(--warn);
  font-size: 0.88rem;
  margin: 0 0 0.85rem;
  padding: 0.65rem 0.75rem;
  background: #fff5f2;
  border-radius: 8px;
  border: 1px solid #f0d2c8;
}

/* FAQ — full container width */
.faq-list {
  display: grid;
  gap: 0.75rem;
  width: 100%;
  max-width: none;
}
.faq-page .page-hero .tldr,
.faq-page .page-hero p {
  max-width: none;
}
.faq-item {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background:
    linear-gradient(160deg, color-mix(in srgb, var(--accent-soft) 35%, #fff) 0%, var(--surface) 58%);
  padding: 1.25rem 1.35rem;
}
.faq-item h2,
.faq-item h3 {
  font-family: var(--font-display);
  font-size: 1.12rem;
  letter-spacing: -0.02em;
  margin: 0 0 0.45rem;
}
.faq-item p {
  margin: 0;
  font-size: 0.98rem;
  max-width: none;
  color: var(--muted);
}

/* Detail / wallet (keep functional) */
.class-detail-hero .class-lead {
  max-width: 40rem;
  margin: 0 0 1rem;
  color: var(--muted);
  font-size: 1.05rem;
}
.class-chip-row {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}
.class-chip-row li {
  font-size: 0.82rem;
  font-weight: 600;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-deep);
}
.class-chip-row li.is-full {
  background: #fff4f1;
  color: #7a3030;
}
.detail-grid {
  display: grid;
  grid-template-columns: 1.35fr 0.85fr;
  gap: 1.5rem;
  padding-bottom: 3rem;
  align-items: start;
}
.detail-main {
  display: grid;
  gap: 1.25rem;
}
.detail-visual {
  width: 100%;
  max-width: 100%;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  aspect-ratio: 16 / 10;
  background: var(--line);
}
.detail-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.detail-panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.25rem;
  position: sticky;
  top: calc(var(--nav-h) + 0.75rem);
  scroll-margin-top: calc(var(--nav-h) + 0.75rem);
}
#reserve-panel {
  scroll-margin-top: calc(var(--nav-h) + 0.75rem);
  scroll-margin-bottom: 6rem;
}
.class-about,
.class-aside-info {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.25rem 1.35rem;
}
.class-about h2,
.class-aside-info h2 {
  margin: 0 0 0.65rem;
  font-size: 1.15rem;
}
.class-about .prose {
  margin-bottom: 1.15rem;
}
.class-about .prose p {
  color: var(--ink);
  max-width: 40rem;
}
.class-specs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.85rem 1rem;
  margin: 0;
}
.class-specs div {
  padding-top: 0.75rem;
  border-top: 1px solid var(--line);
}
.class-specs dt {
  margin: 0 0 0.2rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}
.class-specs dd {
  margin: 0;
  color: var(--ink);
  font-weight: 600;
  font-size: 0.95rem;
}
.class-aside-info {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}
.plain-list {
  margin: 0;
  padding-left: 1.1rem;
  color: var(--muted);
}
.plain-list li { margin-bottom: 0.35rem; }
.plain-list li:last-child { margin-bottom: 0; }
.fact-list {
  list-style: none;
  padding: 0;
  margin: 0 0 1rem;
  display: grid;
  gap: 0.55rem;
}
.fact-list li {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 0.55rem;
  border-bottom: 1px solid var(--line);
  font-size: 0.92rem;
}
.fact-list li span:first-child { color: var(--muted); }
.pay-options { display: grid; gap: 0.5rem; margin: 1rem 0; }
.pay-option {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.75rem 0.9rem;
  border-radius: 6px;
  border: 1px solid var(--line);
  background: var(--bg);
  cursor: pointer;
  font-size: 0.92rem;
}
.pay-option:has(input:checked) {
  border-color: var(--accent);
  background: var(--accent-soft);
}
.pay-option.is-disabled {
  opacity: 0.55;
  cursor: not-allowed;
}
.pay-option strong {
  display: inline-block;
  color: var(--ink);
  font-size: 0.95rem;
}
.pay-option small {
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.35;
}
.book-step-label {
  margin: 0 0 0.5rem;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}
.book-status {
  padding: 0.85rem 1rem;
  border-radius: 6px;
  margin-bottom: 0.85rem;
  border: 1px solid var(--line);
  background: var(--bg);
}
.book-status-ok {
  border-color: #a8d0ce;
  background: var(--secondary-soft);
}
.book-status-full {
  border-color: #f0c9c0;
  background: #fff4f1;
}
.paypal-slot {
  margin-top: 0.75rem;
  min-height: 45px;
}
#book-credit-btn[hidden],
.paypal-slot[hidden],
[hidden] {
  display: none !important;
}
.note { font-size: 0.85rem; color: var(--muted); margin: 0.75rem 0 0; }

.wallet-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  padding-bottom: 3rem;
}
.balance-block {
  background: var(--accent);
  color: #fff;
  border-radius: var(--radius);
  padding: 1.35rem;
}
.balance-block p,
.balance-block .label,
.balance-block .amount {
  color: #fff;
}
.balance-block .label {
  margin: 0;
  opacity: 0.9;
  font-size: 0.9rem;
}
.balance-block .amount {
  font-size: clamp(1.8rem, 4vw, 2.4rem);
  font-weight: 650;
  margin: 0.35rem 0 1rem;
  letter-spacing: -0.02em;
  opacity: 1;
}
.balance-block .btn-secondary {
  background: #fff;
  color: var(--ink);
  border-color: transparent;
}
.balance-block .btn-secondary:hover {
  background: var(--secondary-soft);
  color: var(--secondary-deep);
  border-color: transparent;
}
.topup-block,
.history-block,
.admin-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.25rem;
}
.history-block { grid-column: 1 / -1; }
.amount-picks {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.45rem;
  margin-bottom: 0.85rem;
}
.amount-picks button {
  border: 1px solid var(--line);
  background: var(--bg);
  border-radius: 6px;
  padding: 0.65rem 0.4rem;
  min-height: 44px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
}
.amount-picks button[aria-pressed="true"] {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
.field { display: grid; gap: 0.3rem; margin-bottom: 0.85rem; }
.field label { font-size: 0.85rem; font-weight: 600; color: var(--muted); }
.field label:has(input[type="checkbox"]) {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  min-height: 44px;
  font-weight: 550;
  color: var(--ink);
  cursor: pointer;
}
.field label:has(input[type="checkbox"]) input {
  width: 1.15rem;
  height: 1.15rem;
  min-height: 0;
  flex: 0 0 auto;
}
.field input,
.field select,
.field textarea {
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0.7rem 0.85rem;
  min-height: 44px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 16px; /* avoid iOS input zoom */
  width: 100%;
  max-width: 100%;
}
.field textarea {
  min-height: 6.5rem;
}
.history-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.5rem; }
.history-list li {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.65rem 0;
  border-bottom: 1px solid var(--line);
  font-size: 0.92rem;
}
.history-list .pos { color: var(--secondary); font-weight: 700; }
.history-list .neg { color: var(--warn); font-weight: 700; }

.notif-list { display: grid; gap: 0.65rem; padding-bottom: 3rem; }
.notif-item {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 0.75rem;
  align-items: start;
  padding: 1rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: inherit;
  text-decoration: none;
}
a.notif-item.is-link {
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease, transform 0.15s ease;
}
a.notif-item.is-link:hover {
  border-color: color-mix(in srgb, var(--accent) 40%, var(--line));
  background: color-mix(in srgb, var(--accent) 6%, var(--surface));
  transform: translateY(-1px);
}
a.notif-item.is-link h3 {
  color: var(--accent-deep);
}
.notif-item.unread {
  border-color: #b7d0c5;
  background: var(--accent-soft);
}
.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  margin-top: 0.45rem;
}
.notif-item:not(.unread) .dot {
  background: transparent;
  border: 1px solid var(--line);
}
.notif-item h3 { margin: 0 0 0.2rem; font-size: 0.98rem; }
.notif-item p { margin: 0; font-size: 0.9rem; }
.notif-item time { font-size: 0.8rem; color: var(--muted); white-space: nowrap; }

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  padding-bottom: 3rem;
}
.contact-block {
  padding: 1.25rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.contact-block dt {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  margin: 0 0 0.2rem;
}
.contact-block dd {
  margin: 0 0 1rem;
  color: var(--ink);
}
.contact-block dd:last-child { margin-bottom: 0; }

.toast {
  position: fixed;
  bottom: calc(1.25rem + env(safe-area-inset-bottom, 0px));
  left: 50%;
  right: auto;
  max-width: min(92vw, 22rem);
  transform: translateX(-50%) translateY(calc(100% + 1.5rem));
  background: var(--ink);
  color: #fff;
  padding: 0.75rem 1.15rem;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.3;
  text-align: center;
  z-index: 70;
  pointer-events: none;
  transition: transform 0.25s ease;
  box-sizing: border-box;
}
.toast.show { transform: translateX(-50%) translateY(0); }

.demo-teacher-card {
  display: block;
  margin-bottom: 1rem;
  padding: 1rem 1.05rem;
  background: color-mix(in srgb, var(--secondary-deep) 6%, #fff);
  border: 1px solid var(--line);
  border-radius: 12px;
}
.demo-teacher-card__label {
  margin: 0 0 0.2rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.demo-teacher-card .note { margin: 0 0 0.75rem; }
@media (max-width: 860px) {
  /* Sit above mobile dock — never cover Chat / nav icons */
  .toast {
    bottom: calc(4.15rem + env(safe-area-inset-bottom, 0px));
  }
  body:has(.reserve-bar.is-visible) .toast {
    bottom: calc(7.5rem + env(safe-area-inset-bottom, 0px));
  }
}

.site-footer {
  border-top: 1px solid var(--line);
  padding: 2.5rem 0 2.75rem;
  background:
    radial-gradient(700px 240px at 10% 0%, rgba(201, 61, 114, 0.06), transparent 55%),
    linear-gradient(180deg, #fff 0%, #faf3f6 100%);
  margin-top: 1.25rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 1.5rem;
}
.site-footer h2 {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin: 0 0 0.75rem;
  color: var(--muted);
}
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 0.4rem; }
.site-footer a { color: var(--ink); text-decoration: none; font-size: 0.92rem; }
.site-footer a:hover { color: var(--accent); }
.footer-copy {
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
  font-size: 0.85rem;
  color: var(--muted);
}

@media (max-width: 900px) {
  .offer-grid {
    grid-template-columns: 1fr;
  }
  .split-story {
    grid-template-columns: 1fr;
  }
  .split-media {
    min-height: 260px;
    max-height: 320px;
  }
  .photo-band img {
    height: 260px;
  }
  .hero-visual {
    min-height: 72vh;
  }
}

/* Teacher desk (frontend) */
.teacher-hero__row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
}
.teacher-hero__row h1 { margin: 0; }
.teacher-chat-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}
.teacher-chat-link__badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.2rem;
  height: 1.2rem;
  padding: 0 0.3rem;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  line-height: 1;
}
.teacher-desk {
  padding-bottom: 3rem;
}
.teacher-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
  margin-bottom: 1.25rem;
}
.teacher-metric {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.85rem 0.95rem;
  display: grid;
  gap: 0.2rem;
}
.teacher-metric__label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.teacher-metric__value {
  font-size: 1.45rem;
  font-weight: 750;
  letter-spacing: -0.03em;
  line-height: 1.1;
}
.teacher-metric__sub {
  font-size: 0.78rem;
  color: var(--muted);
}
.teacher-metric--actions {
  align-content: center;
}
.teacher-promo {
  margin-bottom: 1.5rem;
}
.teacher-promo-list {
  list-style: none;
  margin: 1rem 0 0;
  padding: 0;
  display: grid;
  gap: 0.45rem;
}
.teacher-promo-list li {
  display: flex;
  gap: 0.75rem;
  align-items: baseline;
  padding: 0.55rem 0.7rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
}
@media (max-width: 720px) {
  .teacher-metrics {
    grid-template-columns: 1fr;
  }
}
.teacher-desk .teacher-create {
  margin-bottom: 1.75rem;
}
.teacher-desk .detail-panel,
.teacher-desk .class-row {
  /* Avoid hover translate fighting touch scroll on this dense page */
  transform: none !important;
}
/* detail-panel is sticky for class-detail sidebar — never on teacher desk
   or Create class + Discount forms stack/overlap while scrolling. */
.teacher-desk .detail-panel {
  position: static;
  top: auto;
}
.teacher-block {
  margin-top: 1.75rem;
  padding-top: 0.25rem;
}
.teacher-create-head,
.teacher-section-head {
  margin-bottom: 1rem;
}
.teacher-create-head h2,
.teacher-section-head h2 {
  margin: 0 0 0.25rem;
  font-size: 1.25rem;
}
.teacher-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.35rem 1rem;
}
.teacher-field-full {
  grid-column: 1 / -1;
}
.teacher-form-actions {
  margin-top: 0.5rem;
}
.teacher-roster-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
}
.roster-list {
  display: grid;
  gap: 0.65rem;
}
.roster-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 1rem;
  align-items: center;
  padding: 1rem 1.1rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.roster-row h3 {
  margin: 0 0 0.15rem;
  font-size: 1.05rem;
}
.roster-side {
  display: grid;
  gap: 0.45rem;
  justify-items: end;
  text-align: right;
}
.roster-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  justify-content: flex-end;
}
.roster-row[data-attendance="present"] {
  border-color: #b7d0c5;
  background: var(--accent-soft);
}
.roster-row[data-attendance="noshow"] {
  border-color: #e8c4b8;
  background: #fbf4f1;
}
.roster-row h3 a {
  color: inherit;
  text-decoration: none;
}
.roster-row h3 a:hover {
  color: var(--accent-deep);
  text-decoration: underline;
}

/* Teacher students list + detail */
.teacher-students-preview .teacher-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.65rem;
}
.teacher-students {
  padding-bottom: 2rem;
}
.teacher-students__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.55rem;
}
.teacher-students__list--compact {
  margin-bottom: 0.25rem;
}
.teacher-students__item {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.75rem;
  align-items: center;
  padding: 0.9rem 1rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  text-decoration: none;
  color: var(--ink);
  transition: border-color 0.15s ease, background 0.15s ease;
}
.teacher-students__list--compact .teacher-students__item {
  grid-template-columns: 1fr;
}
.teacher-students__item:hover {
  border-color: color-mix(in srgb, var(--secondary-deep) 28%, var(--line));
}
.teacher-students__avatar {
  width: 2.35rem;
  height: 2.35rem;
  border-radius: 11px;
  display: grid;
  place-items: center;
  font-size: 0.78rem;
  font-weight: 750;
  color: var(--secondary-deep);
  background: color-mix(in srgb, var(--secondary-deep) 12%, white);
}
.teacher-students__body {
  min-width: 0;
  display: grid;
  gap: 0.15rem;
}
.teacher-students__top {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  align-items: baseline;
}
.teacher-students__top strong {
  font-size: 0.98rem;
}
.teacher-students__top time,
.teacher-students__top .sub {
  font-size: 0.72rem;
  color: var(--muted);
  white-space: nowrap;
}
.teacher-students__email,
.teacher-students__meta {
  font-size: 0.84rem;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.teacher-student {
  display: grid;
  gap: 1.15rem;
  padding-bottom: 2.75rem;
}
.teacher-student__actions {
  margin: 0.85rem 0 0;
}
.page-hero .teacher-student__actions {
  margin-top: 0.75rem;
}

@media (max-width: 560px) {
  .teacher-metric--actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
  }
}

@media (max-width: 860px) {
  :root {
    --nav-h: 56px;
    --gutter: 0.75rem;
  }

  .page-hero {
    padding: 1.35rem 0 0.85rem;
  }
  .page-hero h1 {
    font-size: clamp(1.45rem, 7vw, 1.85rem);
    overflow-wrap: anywhere;
  }
  .page-hero p,
  .class-lead {
    font-size: 0.95rem;
  }

  .breadcrumbs {
    padding-top: 0.55rem;
  }
  .breadcrumbs ol {
    gap: 0.2rem 0.35rem;
  }
  .breadcrumbs li {
    max-width: 100%;
    overflow-wrap: anywhere;
  }

  .section {
    padding-block: 2rem;
  }

  .hero-visual {
    min-height: min(68vh, 560px);
    min-height: min(68dvh, 560px);
  }
  .hero-media img {
    object-position: center 22%;
  }
  .hero-media::after {
    background:
      linear-gradient(180deg, rgba(28, 12, 20, 0.28) 0%, rgba(28, 12, 20, 0.45) 38%, rgba(18, 8, 14, 0.82) 100%);
  }
  .hero-content {
    /* Clear sticky dock so Yoga / Pilates / Pricing CTAs stay tappable */
    padding: 1.5rem 0 calc(5.25rem + env(safe-area-inset-bottom, 0px));
  }
  .hero-brand {
    font-size: clamp(1.65rem, 8vw, 2.05rem);
    margin-bottom: 0.4rem;
  }
  .hero-visual h1 {
    font-size: clamp(1.08rem, 4.6vw, 1.28rem);
    max-width: none;
    margin-bottom: 0.55rem;
  }
  .hero-lead {
    font-size: 0.92rem;
    max-width: none;
    margin-bottom: 1rem;
  }

  .filters {
    display: flex;
    flex-wrap: nowrap;
    gap: 0.45rem;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    margin: 0 0 0.85rem;
    padding: 0.15rem 0 0.35rem;
  }
  .filters::-webkit-scrollbar {
    display: none;
  }
  .filters .chip {
    flex: 0 0 auto;
    min-height: 44px;
    padding: 0.45rem 0.95rem;
  }

  .class-row {
    grid-template-columns: 1fr;
    gap: 0.75rem;
    padding: 0.95rem 1rem;
  }
  .class-row:hover {
    transform: none;
  }
  .class-side {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 0.55rem;
    width: 100%;
    text-align: left;
    justify-items: start;
    padding-top: 0.65rem;
    border-top: 1px solid var(--line);
  }
  .class-side .btn {
    flex: 1 1 auto;
    min-width: calc(50% - 0.35rem);
  }
  .booking-row .class-side {
    align-items: stretch;
  }
  .booking-row .class-side .btn {
    width: 100%;
  }

  .price-band-inner,
  .visit-band-inner {
    flex-direction: column;
    align-items: stretch;
  }
  .price-band-actions {
    display: grid;
    gap: 0.55rem;
  }
  .price-band-actions .btn,
  .visit-band-inner > .btn {
    width: 100%;
  }

  .instructor-strip {
    grid-template-columns: 1fr 1fr;
  }

  .teacher-fields {
    grid-template-columns: 1fr;
  }
  .roster-row {
    grid-template-columns: 1fr;
  }
  .roster-side {
    justify-items: stretch;
    text-align: left;
    width: 100%;
  }
  .roster-btns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.45rem;
    width: 100%;
  }
  .roster-btns .btn {
    width: 100%;
  }
  .teacher-roster-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }
  .teacher-roster-actions .btn {
    width: 100%;
    text-align: center;
  }
  .teacher-form-actions .btn {
    width: 100%;
  }

  .detail-grid {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding-bottom: calc(5.5rem + env(safe-area-inset-bottom, 0px));
  }
  .detail-panel {
    /* Keep booking card in normal flow — never sticky-over content on mobile. */
    order: 0;
    position: static !important;
    top: auto !important;
    z-index: auto !important;
    padding: 1.1rem;
    box-shadow: none;
  }
  /* Reserve a seat — edge-to-edge on mobile */
  #reserve-panel.detail-panel {
    width: 100vw;
    max-width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    border-radius: 0;
    border-left: 0;
    border-right: 0;
    padding: 1.15rem max(var(--gutter), env(safe-area-inset-left, 0px))
      1.25rem max(var(--gutter), env(safe-area-inset-right, 0px));
  }
  #reserve-panel .btn-block,
  #reserve-panel .pay-options,
  #reserve-panel .fact-list {
    width: 100%;
  }
  .detail-main {
    order: -1; /* story / about first; reserve follows without covering */
    gap: 1rem;
  }
  .detail-visual {
    aspect-ratio: 16 / 11;
  }
  .wallet-grid,
  .contact-grid,
  .footer-grid,
  .class-aside-info,
  .class-specs {
    grid-template-columns: 1fr;
  }
  .class-specs {
    grid-template-columns: 1fr 1fr;
  }
  .class-aside-info {
    gap: 1rem;
  }
  .fact-list li {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.15rem;
  }
  .fact-list li span:last-child {
    font-weight: 650;
    color: var(--ink);
  }
  .pay-option {
    align-items: flex-start;
    min-height: 52px;
  }
  .class-chip-row {
    gap: 0.4rem;
  }
  .class-chip-row li {
    font-size: 0.78rem;
    padding: 0.4rem 0.65rem;
  }

  .notif-item {
    grid-template-columns: auto 1fr;
  }
  .amount-picks {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.45rem;
  }
  .amount-picks button {
    min-height: 44px;
    width: 100%;
  }

  .site-footer {
    padding-bottom: calc(1.5rem + env(safe-area-inset-bottom, 0px));
  }

  .breadcrumbs {
    display: none;
  }

  .nav-toggle { display: inline-flex; }
  .nav-links {
    display: none;
    position: fixed;
    top: var(--nav-h);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    flex-wrap: nowrap;
    gap: 0.1rem;
    padding: 0.65rem max(var(--gutter), env(safe-area-inset-left, 0px)) calc(1.15rem + env(safe-area-inset-bottom, 0px)) max(var(--gutter), env(safe-area-inset-right, 0px));
    background: #fff;
    border-bottom: 1px solid var(--line);
    box-shadow: 0 16px 32px rgba(42, 31, 36, 0.12);
    z-index: 50;
    max-height: calc(100dvh - var(--nav-h));
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
  }
  body.admin-bar .nav-links {
    top: calc(var(--nav-h) + 46px);
    max-height: calc(100dvh - var(--nav-h) - 46px);
  }
  body.admin-bar .nav-scrim {
    inset: calc(var(--nav-h) + 46px) 0 0;
  }
  .nav-links.open { display: flex; }
  .nav-links > .nav-link,
  .nav-flyout__btn {
    padding: 0.85rem 0.9rem;
    min-height: 48px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    font-size: 1rem;
    width: 100%;
  }
  .nav-flyout { width: 100%; }
  .nav-flyout__panel {
    position: static;
    top: auto;
    right: auto;
    left: auto;
    min-width: 0;
    width: 100%;
    margin: 0.15rem 0 0.35rem;
    box-shadow: none;
    border-radius: 10px;
    background: color-mix(in srgb, var(--bg) 70%, white);
    z-index: auto;
  }
  .nav-flyout[open] > .nav-flyout__panel {
    display: grid;
  }
  .nav-flyout__link {
    min-height: 44px;
    display: flex;
    align-items: center;
    font-size: 0.95rem;
  }
}

@media (max-width: 420px) {
  .class-specs {
    grid-template-columns: 1fr;
  }
  .instructor-strip {
    grid-template-columns: 1fr;
  }
  .teacher-roster-actions {
    grid-template-columns: 1fr;
  }
}

/* ========== Studio hub schedule ========== */
.studio-hub {
  /* Body already clears the dock on ≤860px — keep a light page pad only */
  padding-bottom: 1.5rem;
}
@media (max-width: 860px) {
  .studio-hub {
    padding-bottom: 0.75rem;
  }
}
.studio-hub__hero {
  background:
    radial-gradient(700px 280px at 8% 0%, rgba(201, 61, 114, 0.1), transparent 55%),
    radial-gradient(560px 240px at 92% 20%, rgba(53, 115, 112, 0.08), transparent 50%),
    linear-gradient(180deg, #fdf7fa 0%, var(--bg) 100%);
  padding: 1.5rem 0 1.25rem;
  border-bottom: 1px solid var(--line);
}
.studio-hub__hero-inner {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem 1.5rem;
  flex-wrap: wrap;
}
@media (max-width: 860px) {
  .studio-hub__hero {
    padding: 0.85rem 0 0.7rem;
  }
  .studio-hub__hero-inner {
    flex-direction: column;
    align-items: stretch;
    gap: 0.65rem;
  }
  .studio-hub__title {
    font-size: clamp(1.45rem, 6.5vw, 1.75rem);
    margin: 0.1rem 0 0.2rem;
  }
  .studio-hub__invite-btn {
    align-self: flex-start;
    padding: 0.45rem 0.75rem;
    font-size: 0.8rem;
    min-height: 40px;
  }
  .studio-tabs__btn {
    min-height: 44px;
    padding: 0.7rem 0;
    font-size: 0.86rem;
  }
  .studio-panel {
    padding: 0.75rem 0 1.5rem;
  }
  .cal-day {
    min-height: 3.4rem;
  }
}
.studio-hub__copy {
  min-width: 0;
  flex: 1 1 14rem;
}
.studio-hub__eyebrow {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 750;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}
.studio-hub__title {
  margin: 0.2rem 0 0.35rem;
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 4.5vw, 2.15rem);
  font-weight: 600;
  letter-spacing: -0.03em;
  color: var(--ink);
}
.studio-hub__location {
  margin: 0;
  font-size: 0.95rem;
  color: var(--muted);
}
.studio-hub__invite-btn {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.55rem 0.95rem;
  border-radius: var(--radius-sm);
  border: 1px solid color-mix(in srgb, var(--line) 70%, var(--accent));
  background: var(--surface);
  color: var(--ink);
  text-decoration: none;
  font-size: 0.86rem;
  font-weight: 700;
}
.studio-hub__credits {
  margin: 0.55rem 0 0;
  font-size: 0.86rem;
  font-weight: 650;
  color: var(--secondary-deep);
}
.studio-hub__invite-btn:hover {
  color: var(--accent-deep);
  border-color: var(--accent);
  background: var(--accent-soft);
}

.studio-tabs {
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--surface) 92%, var(--accent-soft));
  position: sticky;
  top: var(--nav-h);
  z-index: 25;
}
body.admin-bar .studio-tabs {
  top: calc(var(--nav-h) + 32px);
}
@media screen and (max-width: 782px) {
  body.admin-bar .studio-tabs {
    top: calc(var(--nav-h) + 46px);
  }
}
.studio-tabs__track {
  display: flex;
  align-items: stretch;
  gap: 1rem;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.studio-tabs__track::-webkit-scrollbar { display: none; }
.studio-tabs__btn {
  flex: 0 0 auto;
  appearance: none;
  border: 0;
  background: transparent;
  font: inherit;
  font-size: 0.88rem;
  font-weight: 650;
  color: var(--muted);
  /* No side padding — track sits in .container, so labels share the page gutter */
  padding: 0.85rem 0;
  min-height: 48px;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  position: relative;
  margin-bottom: -1px;
}
.studio-tabs__btn::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  border-radius: 2px 2px 0 0;
  background: transparent;
}
.studio-tabs__btn.is-active,
.studio-tabs__btn[aria-selected="true"] {
  color: var(--accent-deep);
}
.studio-tabs__btn.is-active::after,
.studio-tabs__btn[aria-selected="true"]::after {
  background: var(--accent);
}
a.studio-tabs__btn:hover { color: var(--ink); }

.studio-panel {
  padding: 1rem 0 2rem;
}
.studio-panel[hidden] { display: none !important; }
.studio-panel__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.85rem;
}
.studio-panel__head h2 {
  margin: 0;
  font-size: 1.05rem;
}
.linkish {
  appearance: none;
  border: 0;
  background: none;
  color: var(--accent);
  font: inherit;
  font-weight: 650;
  font-size: 0.9rem;
  cursor: pointer;
  padding: 0.5rem 0;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}

.upcoming-list { display: grid; gap: 0.55rem; }
.upcoming-row {
  display: grid;
  grid-template-columns: 4.2rem 1fr;
  gap: 0.75rem;
  align-items: center;
  padding: 0.85rem 0.95rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  text-decoration: none;
  color: inherit;
}
.upcoming-row:hover { border-color: var(--accent); color: inherit; }
.upcoming-row__date {
  display: grid;
  gap: 0.1rem;
  text-align: center;
}
.upcoming-row__date strong {
  font-size: 0.95rem;
  color: var(--secondary-deep);
}
.upcoming-row__date span,
.upcoming-row__body span {
  font-size: 0.8rem;
  color: var(--muted);
}
.upcoming-row__body {
  display: grid;
  gap: 0.15rem;
  min-width: 0;
}
.upcoming-row__body strong {
  font-size: 0.98rem;
  overflow-wrap: anywhere;
}

.schedule-app { position: relative; }
.cal-month {
  font-size: 0.95rem;
  font-weight: 650;
  color: var(--ink);
  margin: 0 0 0.65rem;
}
.cal-strip {
  display: flex;
  gap: 0.35rem;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding: 0.15rem 0 0.55rem;
  margin: 0 0 0.35rem;
  scroll-snap-type: x proximity;
}
.cal-strip::-webkit-scrollbar { display: none; }
.cal-day {
  flex: 0 0 auto;
  width: 3.15rem;
  min-height: 3.6rem;
  display: grid;
  place-items: center;
  gap: 0.15rem;
  border: 0;
  background: transparent;
  border-radius: 999px;
  font: inherit;
  color: var(--muted);
  cursor: pointer;
  scroll-snap-align: center;
  position: relative;
  padding: 0.45rem 0.2rem;
}
.cal-day__dow {
  font-size: 0.68rem;
  font-weight: 650;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}
.cal-day__num {
  width: 2rem;
  height: 2rem;
  display: grid;
  place-items: center;
  border-radius: 999px;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--ink);
}
.cal-day.is-selected .cal-day__num {
  background: var(--accent);
  color: #fff;
}
.cal-day.is-today:not(.is-selected) .cal-day__num {
  box-shadow: inset 0 0 0 1.5px var(--secondary);
}
.cal-day.has-classes::after {
  content: "";
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--accent);
  position: absolute;
  bottom: 0.35rem;
}
.cal-day.is-selected.has-classes::after { background: #fff; bottom: 0.4rem; }

.schedule-toolbar { margin: 0.25rem 0 0.85rem; }

.session-list { display: grid; gap: 0.9rem; }
.session-card {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.65rem;
  align-items: center;
  padding: 1.05rem 1.1rem;
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--surface) 92%, var(--secondary-soft)) 0%, var(--surface) 100%);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.session-card__main {
  min-width: 0;
  text-decoration: none;
  color: inherit;
}
.session-card__main:hover { color: inherit; }
.session-card__time {
  font-size: 0.8rem;
  font-weight: 750;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--secondary-deep);
  margin-bottom: 0.25rem;
}
.session-card__title {
  margin: 0 0 0.2rem;
  font-family: var(--font-display);
  font-size: 1.12rem;
  letter-spacing: -0.02em;
  overflow-wrap: anywhere;
}
.session-card__meta {
  margin: 0 0 0.35rem;
  font-size: 0.88rem;
  color: var(--muted);
}
.session-card__facts {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.75rem;
  margin: 0;
  font-size: 0.82rem;
  color: var(--muted);
}
.session-card__capacity {
  font-weight: 700;
  color: var(--ink);
}
.session-card__capacity.is-low { color: var(--warn); }
.session-card__capacity.is-full { color: #7a3030; }
.session-card__loc {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.session-card__action {
  display: flex;
  align-items: center;
}
.session-btn {
  min-width: 5.5rem;
  justify-content: center;
  border-radius: 999px;
  padding-inline: 0.95rem;
}
.session-btn.is-waitlist {
  color: var(--warn);
  border-color: #e8c4b8;
  background: #fff8f5;
}

.cal-today-fab {
  position: sticky;
  bottom: calc(4.75rem + env(safe-area-inset-bottom, 0px));
  z-index: 15;
  margin: 0.75rem 0 0;
  appearance: none;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.95);
  color: var(--ink);
  font: inherit;
  font-size: 0.85rem;
  font-weight: 700;
  padding: 0.55rem 0.9rem;
  border-radius: 999px;
  box-shadow: 0 8px 22px rgba(42, 31, 36, 0.12);
  cursor: pointer;
  width: max-content;
}
.cal-today-fab[hidden] { display: none !important; }

/* Bottom sheets */
.sheet {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  align-items: end;
}
.sheet[hidden] { display: none !important; }
.sheet__scrim {
  position: absolute;
  inset: 0;
  background: rgba(28, 16, 22, 0.45);
}
.sheet__panel {
  position: relative;
  z-index: 1;
  background: #fff;
  border-radius: 18px 18px 0 0;
  padding: 1.25rem 1.15rem calc(1.35rem + env(safe-area-inset-bottom, 0px));
  max-height: min(88dvh, 640px);
  overflow: auto;
  box-shadow: 0 -12px 40px rgba(28, 16, 22, 0.18);
  animation: sheetUp 0.28s ease-out;
}
.sheet__panel--center { text-align: center; }
@keyframes sheetUp {
  from { transform: translateY(24px); opacity: 0.6; }
  to { transform: translateY(0); opacity: 1; }
}
.sheet__close {
  position: absolute;
  top: 0.55rem;
  right: 0.55rem;
  left: auto;
  width: 2.75rem;
  height: 2.75rem;
  min-width: 44px;
  min-height: 44px;
  border: 0;
  border-radius: 999px;
  background: var(--bg);
  color: var(--ink);
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
  display: grid;
  place-items: center;
  z-index: 2;
}
.sheet__eyebrow {
  margin: 0.35rem 0 0.25rem;
  font-size: 0.85rem;
  color: var(--muted);
}
.sheet__panel h2 {
  margin: 0 0 0.35rem;
  font-size: 1.25rem;
  padding-right: 2.75rem;
}
.sheet__meta {
  margin: 0 0 0.85rem;
  font-size: 0.9rem;
  color: var(--muted);
}
.sheet__note {
  margin: 0 0 1rem;
  padding: 0.75rem 0.85rem;
  background: #f4f1f2;
  border-radius: 10px;
  font-size: 0.86rem;
  color: var(--muted);
}
.sheet__cta-label {
  margin: 0 0 0.55rem;
  font-weight: 700;
  color: var(--ink);
  font-size: 0.95rem;
}
.sheet__link {
  display: block;
  text-align: center;
  margin-top: 0.75rem;
  font-weight: 650;
  font-size: 0.92rem;
}
.sheet__link.muted { color: var(--muted); font-weight: 500; }
.sheet__foot {
  margin: 1rem 0 0;
  font-size: 0.85rem;
  color: var(--muted);
}
.waitlist-success {
  width: 3.5rem;
  height: 3.5rem;
  margin: 0.5rem auto 0.85rem;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: var(--secondary-soft);
  color: var(--secondary-deep);
  font-size: 1.5rem;
  font-weight: 700;
  box-shadow: 0 0 0 8px rgba(61, 122, 120, 0.08);
}

/* Pricing plans (mobile cards) */
.pricing-page { padding-bottom: 1.5rem; }
@media (max-width: 860px) {
  .pricing-page { padding-bottom: 0.75rem; }
}
.pricing-hero {
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--accent-soft) 85%, #fff) 0%, var(--bg) 100%);
  border-bottom: 1px solid var(--line);
  /* Static: sticky + top:nav-h left a gap where scrolled content (Balance/billing) leaked above the bar. */
  position: static;
  top: auto;
  z-index: auto;
}
.pricing-hero__inner {
  display: grid;
  grid-template-columns: 2.75rem 1fr 2.75rem;
  align-items: center;
  min-height: 3.35rem;
  gap: 0.35rem;
}
.pricing-hero h1 {
  margin: 0;
  text-align: center;
  font-size: clamp(1.12rem, 4vw, 1.3rem);
  font-weight: 700;
  color: var(--accent-deep);
}
.pricing-back {
  width: 2.5rem;
  height: 2.5rem;
  display: grid;
  place-items: center;
  border-radius: 999px;
  text-decoration: none;
  color: var(--accent-deep);
  font-size: 1.55rem;
  line-height: 1;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid color-mix(in srgb, var(--line) 70%, var(--accent));
}
.pricing-section { padding-top: 1rem; border-bottom: 0; }
.pricing-status {
  margin-bottom: 1rem;
  position: static;
  z-index: auto;
}
.plan-stack { display: grid; gap: 0.85rem; }
.plan-tile {
  background: #fff7f9;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 1rem 1rem 0.75rem;
}
.plan-tile.is-best {
  background: linear-gradient(180deg, color-mix(in srgb, var(--accent-soft) 55%, #fff) 0%, #fff7f9 55%);
  border-color: color-mix(in srgb, var(--accent) 35%, var(--line));
}
.plan-tile__badge {
  margin: 0 0 0.45rem;
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--secondary-deep);
  background: var(--secondary-soft);
  padding: 0.2rem 0.5rem;
  border-radius: 999px;
}
.plan-tile__top {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.75rem;
  align-items: start;
}
.plan-tile__copy h2 {
  margin: 0 0 0.35rem;
  font-size: 1.02rem;
}
.plan-tile__copy p {
  margin: 0;
  font-size: 0.88rem;
}
.plan-tile__buy {
  text-align: right;
  display: grid;
  gap: 0.35rem;
  justify-items: end;
  min-width: 6.5rem;
}
.plan-tile__price {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 750;
  color: var(--ink);
  line-height: 1.15;
}
.plan-tile__price span {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--muted);
}
.plan-tile__valid {
  margin: 0;
  font-size: 0.75rem;
  color: var(--muted);
}
.plan-tile__active {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--secondary-deep);
}
.plan-tile__paylink {
  display: block;
  margin-top: 0.45rem;
  font-size: 0.78rem;
  font-weight: 650;
  color: var(--muted);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.plan-tile__toggle {
  margin-top: 0.75rem;
  width: 100%;
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 0.86rem;
  font-weight: 650;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.55rem 0 0.25rem;
  border-top: 1px solid rgba(42, 31, 36, 0.06);
  cursor: pointer;
}
.plan-tile__toggle[aria-expanded="true"] span { transform: rotate(180deg); display: inline-block; }
.plan-tile__perks {
  margin: 0.35rem 0 0.25rem;
  padding: 0 0 0 1.1rem;
  color: var(--muted);
  font-size: 0.88rem;
}
.plan-tile__perks[hidden] { display: none !important; }
.plan-tile__perks li { margin: 0.25rem 0; }

/* Mobile reserve CTA (class detail) — sits above dock, does not cover page body */
.reserve-bar {
  display: none;
}

/* Mobile dock */
.mobile-dock {
  display: none;
}
@media (max-width: 860px) {
  body {
    padding-bottom: calc(4.1rem + env(safe-area-inset-bottom, 0px));
    background-attachment: scroll; /* fixed janks on iOS Safari */
  }
  /* Only when the reserve bar is actually shown — not merely in the DOM */
  body:has(.reserve-bar.is-visible) {
    padding-bottom: calc(7.6rem + env(safe-area-inset-bottom, 0px));
  }
  .site-footer {
    display: none;
  }
  .reserve-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    position: fixed;
    left: 0;
    right: 0;
    bottom: calc(3.55rem + env(safe-area-inset-bottom, 0px));
    z-index: 44;
    padding: 0.65rem 0.9rem;
    background: rgba(255, 255, 255, 0.97);
    border-top: 1px solid var(--line);
    box-shadow: 0 -8px 24px rgba(42, 31, 36, 0.06);
    transform: translateY(110%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.22s ease, opacity 0.22s ease;
  }
  .reserve-bar.is-visible {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }
  @media (prefers-reduced-motion: reduce) {
    .reserve-bar { transition: none; }
  }
  .reserve-bar__meta {
    display: grid;
    gap: 0.1rem;
    min-width: 0;
  }
  .reserve-bar__meta strong {
    font-size: 1rem;
    letter-spacing: -0.02em;
  }
  .reserve-bar__meta span {
    font-size: 0.75rem;
    color: var(--muted);
    font-weight: 600;
  }
  .reserve-bar .btn {
    flex: 0 0 auto;
    min-width: 6.5rem;
  }
  .mobile-dock {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 45;
    background: rgba(255, 255, 255, 0.98);
    border-top: 1px solid var(--line);
    backdrop-filter: blur(10px);
    padding: 0.3rem 0.2rem calc(0.3rem + env(safe-area-inset-bottom, 0px));
  }
  .mobile-dock__item {
    display: grid;
    justify-items: center;
    gap: 0.18rem;
    padding: 0.35rem 0.2rem;
    text-decoration: none;
    color: color-mix(in srgb, var(--muted) 88%, var(--ink));
    font-size: 0.75rem;
    font-weight: 650;
    letter-spacing: 0.01em;
    min-height: 48px;
    align-content: center;
    transition: color 0.15s ease;
  }
  .mobile-dock__item.is-active {
    color: var(--accent-deep);
  }
  .mobile-dock__item.is-active .mobile-dock__svg {
    stroke-width: 2.1;
  }
  .mobile-dock__ico {
    display: grid;
    place-items: center;
    width: 1.65rem;
    height: 1.65rem;
    line-height: 0;
  }
  .mobile-dock__svg,
  .mobile-dock__ico svg {
    display: block;
    width: 1.45rem;
    height: 1.45rem;
  }
  .mobile-dock__label {
    line-height: 1.1;
    text-align: center;
  }
  .site-nav {
    background: #fafbfa;
  }
  .studio-tabs {
    top: var(--nav-h);
    background: #fff;
  }
  .plan-tile__top {
    grid-template-columns: 1fr;
  }
  .plan-tile__buy {
    width: 100%;
    grid-template-columns: 1fr auto;
    align-items: center;
    text-align: left;
    justify-items: start;
    min-width: 0;
  }
  .plan-tile__buy .btn {
    justify-self: end;
    min-height: 48px;
    min-width: 5.5rem;
  }
  .session-card {
    align-items: stretch;
    grid-template-columns: 1fr;
    gap: 0.75rem;
    padding: 0.95rem 1rem;
  }
  .session-card__action {
    padding-top: 0;
    width: 100%;
  }
  .session-btn {
    width: 100%;
    min-height: 48px;
  }
  .session-card__loc {
    white-space: normal;
  }
}

@media (min-width: 861px) {
  .studio-hub { padding-bottom: 2rem; }
  .pricing-page { padding-bottom: 2rem; }
  .cal-strip { gap: 0.5rem; }
  .cal-day { width: 3.5rem; }
  .session-card {
    padding: 1.05rem 1.15rem;
  }
  .sheet {
    align-items: center;
    justify-items: center;
  }
  .sheet__panel {
    width: min(440px, calc(100% - (var(--gutter) * 2)));
    border-radius: 16px;
    margin-bottom: 0;
    padding: 1.35rem 1.25rem 1.25rem;
  }
}

/* ========== Spaces / profile / fees / filters (v1.7.1) ========== */
.spaces-page { padding-bottom: 1.5rem; }
@media (max-width: 860px) {
  .spaces-page { padding-bottom: 0.75rem; }
}
.spaces-hero h1 {
  font-size: 1.35rem;
  color: #c45c7a;
}
.spaces-body { padding-bottom: 2rem; }
.space-card {
  display: block;
  text-decoration: none;
  color: inherit;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  margin-bottom: 1.5rem;
}
.space-card:hover { color: inherit; border-color: var(--accent); }
.space-card__banner {
  min-height: 8.25rem;
  background: linear-gradient(135deg, #9fb89a 0%, #c5d6c2 45%, #e8d5dd 100%);
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: flex-end;
  padding: 1.15rem 1.1rem 1.25rem;
  position: relative;
}
.space-card__banner::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(40, 50, 40, 0.05), rgba(40, 40, 40, 0.35));
}
.space-card__brand {
  position: relative;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.4rem, 6vw, 1.85rem);
  font-weight: 500;
  color: #fff;
  letter-spacing: 0.04em;
  text-shadow: 0 1px 8px rgba(0,0,0,0.25);
}
.space-card__meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.05rem 1.1rem;
  border-top: 1px solid color-mix(in srgb, var(--line) 75%, transparent);
}
.space-card__avatar {
  flex: 0 0 auto;
  width: 2.55rem;
  height: 2.55rem;
  border-radius: 9px;
  background: linear-gradient(145deg, #f7e4ec, #e8f0e6);
  border: 1px solid color-mix(in srgb, var(--line) 70%, transparent);
  margin: 0;
  display: grid;
  place-items: center;
  color: var(--accent-deep);
}
.space-card__avatar svg {
  width: 1.25rem;
  height: 1.25rem;
  stroke-width: 1.85;
}
.space-card__meta strong {
  font-size: 1rem;
  letter-spacing: -0.02em;
  line-height: 1.25;
}
.space-join__q {
  font-weight: 650;
  color: var(--ink);
  margin: 0 0 0.75rem;
}
.space-join__form {
  display: grid;
  gap: 0.65rem;
}
.space-join__form input {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.7rem 0.9rem;
  font: inherit;
  background: #fff;
}
.space-join__btn { width: 100%; min-height: 48px; }

.filters-trigger {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-weight: 700;
  font-size: 0.92rem;
  padding: 0.35rem 0;
  cursor: pointer;
  margin-bottom: 0.45rem;
}
.filters-trigger__ico { font-size: 0.95rem; opacity: 0.7; }
.schedule-toolbar .filters--chips {
  margin-bottom: 0.35rem;
}
.chip-block {
  width: 100%;
  justify-content: flex-start;
  min-height: 48px;
  border-radius: 12px;
  margin-bottom: 0.45rem;
}
.filter-sheet-options { display: grid; gap: 0.35rem; }

.fee-callout {
  background: #fff8f2;
  border: 1px solid #efd5c4;
  border-radius: 12px;
  padding: 0.9rem 1rem;
  color: var(--ink);
}
.fee-callout strong {
  display: block;
  margin-bottom: 0.25rem;
  color: var(--warn);
  font-size: 0.92rem;
}
.fee-callout p {
  margin: 0;
  font-size: 0.88rem;
  color: var(--muted);
}
.fee-callout--pricing { margin-bottom: 1rem; }

.profile-page { padding-bottom: 1.5rem; }
@media (max-width: 860px) {
  .profile-page { padding-bottom: 0.75rem; }
}

/* Account area: menu left, content right */
.account-page { padding-bottom: 1.5rem; }
.account-shell {
  display: grid;
  grid-template-columns: minmax(210px, 250px) minmax(0, 1fr);
  gap: 1.15rem 1.35rem;
  align-items: start;
  padding-top: 0.35rem;
  padding-bottom: 1.5rem;
}
.account-shell__main {
  min-width: 0;
  order: 2;
}
.account-shell__note { margin: 0 0 0.85rem; }
.account-shell .wallet-grid { padding-bottom: 0; }
.account-shell .notif-list { padding-bottom: 0; }
.account-shell .fee-callout { margin-bottom: 1rem; }
.account-nav {
  order: 1;
  position: sticky;
  top: calc(var(--nav-h) + 0.75rem);
  padding: 0.85rem 0.9rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
}
body.admin-bar .account-nav {
  top: calc(var(--nav-h) + 32px + 0.75rem);
}
@media (min-width: 783px) {
  body.admin-bar .account-nav {
    top: calc(var(--nav-h) + 46px + 0.75rem);
  }
}
.account-nav__label {
  margin: 0 0 0.55rem;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.account-nav__list {
  display: grid;
  gap: 0.35rem;
}
.account-nav__link {
  display: block;
  padding: 0.7rem 0.75rem;
  border-radius: 10px;
  text-decoration: none;
  color: var(--ink);
  font-weight: 650;
  font-size: 0.9rem;
  line-height: 1.25;
  border: 1px solid transparent;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}
.account-nav__link:hover {
  background: color-mix(in srgb, var(--secondary-deep) 8%, transparent);
  color: var(--secondary-deep);
}
.account-nav__link.is-active {
  background: color-mix(in srgb, var(--accent) 12%, transparent);
  border-color: color-mix(in srgb, var(--accent) 35%, var(--line));
  color: var(--accent-deep);
}
.account-nav__link--muted {
  margin-top: 0.25rem;
  color: var(--muted);
  font-weight: 600;
}
.account-nav__chip { display: none; }
.profile-card__meta {
  margin: 0.55rem 0 0;
  font-size: 0.9rem;
}
.profile-card__meta a {
  color: var(--secondary-deep);
  font-weight: 650;
  text-decoration: none;
}
.profile-card__meta a:hover { text-decoration: underline; }

@media (max-width: 900px) {
  .account-page { padding-bottom: 0.75rem; }
  .account-shell {
    grid-template-columns: minmax(0, 1fr);
    gap: 0.85rem;
    padding-bottom: 1rem;
    min-width: 0;
  }
  .account-shell__main { min-width: 0; }
  /* Mobile: chip nav on top — must scroll inside, not widen the page */
  .account-nav {
    order: -1;
    position: static;
    top: auto;
    min-width: 0;
    max-width: 100%;
    width: 100%;
    padding: 0.55rem 0 0.25rem;
    background: transparent;
    border: 0;
    border-radius: 0;
    overflow: hidden;
  }
  .account-nav__label { display: none; }
  .account-nav__list {
    display: flex;
    flex-wrap: nowrap;
    gap: 0.4rem;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    overflow-x: auto;
    overflow-y: hidden;
    overscroll-behavior-x: contain;
    -webkit-overflow-scrolling: touch;
    touch-action: pan-x;
    scroll-snap-type: x proximity;
    scrollbar-width: none;
    padding: 0.15rem 0.1rem 0.4rem;
    margin: 0;
  }
  .account-nav__list::-webkit-scrollbar { display: none; height: 0; }
  .account-nav__link {
    position: relative;
    flex: 0 0 auto;
    scroll-snap-align: start;
    padding: 0.55rem 0.85rem;
    min-height: 40px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--surface);
    font-size: 0.82rem;
    white-space: nowrap;
  }
  .account-nav__link.is-active {
    background: color-mix(in srgb, var(--accent) 14%, white);
    border-color: color-mix(in srgb, var(--accent) 45%, var(--line));
  }
  .account-nav__link--muted {
    margin-top: 0;
  }
  .account-nav__full {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
  }
  .account-nav__chip { display: inline; }
}

/* Shared study history (student profile + teacher student) */
.profile-history {
  padding: 0.25rem 0 2.75rem;
}
.study-history {
  margin: 0 auto;
  max-width: min(980px, 100%);
}
.study-history__intro {
  margin-bottom: 1.15rem;
}
.study-history__eyebrow {
  margin: 0 0 0.4rem;
  font-size: 0.72rem;
  font-weight: 750;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}
.study-history__heading {
  margin: 0 0 0.35rem;
  font-family: var(--font-display);
  font-size: clamp(1.45rem, 3vw, 1.95rem);
  letter-spacing: -0.03em;
  line-height: 1.15;
}
.study-history__lead {
  margin: 0;
  color: var(--muted);
  max-width: 36rem;
  line-height: 1.6;
  font-size: 0.95rem;
}
.study-history__metrics {
  list-style: none;
  margin: 0 0 1.25rem;
  padding: 0.85rem 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.5rem 1rem;
  border-block: 1px solid var(--line);
}
.study-history__metrics li {
  display: grid;
  gap: 0.2rem;
  min-width: 0;
}
.study-history__metrics strong {
  font-family: var(--font-display);
  font-size: clamp(1.35rem, 2.5vw, 1.7rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  color: var(--ink);
}
.study-history__metrics span {
  font-size: 0.72rem;
  font-weight: 650;
  color: var(--muted);
  letter-spacing: 0.02em;
}
.study-history__layout {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(240px, 0.9fr);
  gap: 1.35rem 1.5rem;
  align-items: start;
}
.study-history__main {
  display: grid;
  gap: 1.5rem;
  min-width: 0;
}
.study-history__cal {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.15rem 1.2rem 1.2rem;
}
.study-history__cal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.95rem;
}
.study-history__cal-head h3,
.study-history__log h3,
.study-history__progress-head h3 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 650;
  letter-spacing: -0.02em;
}
.study-history__hint {
  margin: 0.28rem 0 0;
  font-size: 0.78rem;
  color: var(--muted);
}
.study-history__month-nav {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}
.study-history__nav {
  width: 2rem;
  height: 2rem;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--ink);
  text-decoration: none;
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1;
  transition: background 0.18s var(--ease-out), border-color 0.18s var(--ease-out);
}
.study-history__nav:hover {
  background: var(--accent-soft);
  border-color: color-mix(in srgb, var(--accent) 30%, var(--line));
}
.study-history__month-label {
  min-width: 7rem;
  text-align: center;
  font-size: 0.82rem;
  font-weight: 750;
  text-transform: capitalize;
}
.study-history__weekdays,
.study-history__grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 0.35rem;
}
.study-history__weekdays {
  margin: 0 0 0.4rem;
  text-align: center;
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 750;
}
.study-history__day {
  aspect-ratio: 1;
  width: 100%;
  max-width: 2.75rem;
  margin: 0 auto;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: color-mix(in srgb, var(--ink) 55%, var(--muted));
  display: grid;
  place-items: center;
  padding: 0;
  font: inherit;
  cursor: default;
  position: relative;
  transition: background 0.16s var(--ease-out), color 0.16s var(--ease-out), box-shadow 0.16s var(--ease-out);
}
button.study-history__day {
  cursor: pointer;
}
button.study-history__day:hover {
  background: var(--accent-soft);
  color: var(--accent-deep);
}
.study-history__day.is-empty {
  visibility: hidden;
}
.study-history__day-num {
  font-size: 0.8rem;
  font-weight: 700;
  line-height: 1;
}
.study-history__day.is-none {
  color: color-mix(in srgb, var(--muted) 70%, #fff);
  font-weight: 500;
}
.study-history__day.is-present {
  background: color-mix(in srgb, var(--secondary) 22%, #fff);
  color: var(--secondary-deep);
}
.study-history__day.is-noshow {
  background: color-mix(in srgb, var(--warn) 18%, #fff);
  color: #8a3d28;
}
.study-history__day.is-upcoming {
  background: color-mix(in srgb, var(--accent) 12%, #fff);
  color: var(--accent-deep);
  box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--accent) 45%, #fff);
}
.study-history__day.is-pending {
  background: var(--accent-soft);
  color: var(--accent-deep);
}
.study-history__day.is-today:not(.is-present):not(.is-noshow):not(.is-pending):not(.is-upcoming) {
  box-shadow: inset 0 0 0 2px var(--accent);
  color: var(--accent-deep);
  font-weight: 750;
}
.study-history__day.is-selected {
  transform: scale(1.06);
}
.study-history__day.is-selected.is-present {
  box-shadow: 0 0 0 2px var(--secondary);
}
.study-history__day.is-selected.is-noshow {
  box-shadow: 0 0 0 2px var(--warn);
}
.study-history__day.is-selected.is-upcoming,
.study-history__day.is-selected.is-pending {
  box-shadow: 0 0 0 2px var(--accent);
}
.study-history__legend {
  list-style: none;
  margin: 0.95rem 0 0;
  padding: 0.85rem 0 0;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem 1rem;
  font-size: 0.72rem;
  font-weight: 650;
  color: var(--muted);
}
.study-history__legend li {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}
.study-history__legend i {
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 999px;
  display: inline-block;
}
.study-history__legend i.is-present { background: var(--secondary); }
.study-history__legend i.is-noshow { background: var(--warn); }
.study-history__legend i.is-upcoming,
.study-history__legend i.is-pending { background: var(--accent); }
.study-history__detail {
  margin-top: 0.95rem;
  padding-top: 0.9rem;
  border-top: 1px solid var(--line);
  min-height: 4.5rem;
}
.study-history__detail-date {
  margin: 0 0 0.55rem;
  font-size: 0.82rem;
  font-weight: 750;
}
.study-history__detail-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.55rem;
}
.study-history__detail-list:empty,
.study-history__detail.is-empty .study-history__detail-list {
  display: none;
}
.study-history__detail-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.5rem 0.75rem;
  align-items: start;
}
.study-history__detail-row strong {
  display: block;
  font-size: 0.88rem;
  margin-bottom: 0.15rem;
}
.study-history__detail-row small {
  color: var(--muted);
  font-size: 0.75rem;
}
.study-history__detail-row .study-history__item-status {
  align-self: center;
}
.study-history__detail-empty {
  margin: 0;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.55;
}
.study-history__detail:not(.is-empty) .study-history__detail-empty {
  display: none;
}
.study-history__log h3 {
  margin-bottom: 0.75rem;
}
.study-history__empty {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}
.study-history__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0;
  border-top: 1px solid var(--line);
}
.study-history__item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.55rem 0.85rem;
  align-items: center;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--line);
}
.study-history__item:has(.study-history__item-link) {
  grid-template-columns: 1fr auto auto;
}
.study-history__item-body {
  min-width: 0;
}
.study-history__item-body strong {
  display: block;
  font-size: 0.9rem;
  margin-bottom: 0.15rem;
}
.study-history__item-body small {
  color: var(--muted);
  font-size: 0.76rem;
}
.study-history__item-status {
  font-size: 0.68rem;
  font-weight: 750;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
  color: var(--secondary-deep);
}
.study-history__item.is-noshow .study-history__item-status,
.study-history__detail-row.is-noshow .study-history__item-status {
  color: var(--warn);
}
.study-history__item.is-upcoming .study-history__item-status,
.study-history__item.is-pending .study-history__item-status,
.study-history__detail-row.is-upcoming .study-history__item-status,
.study-history__detail-row.is-pending .study-history__item-status {
  color: var(--accent-deep);
}
.study-history__item-link {
  font-size: 0.78rem;
  font-weight: 700;
  text-decoration: none;
  color: var(--accent);
}
.study-history__side {
  display: grid;
  gap: 1rem;
}
.study-history__streak {
  border-radius: var(--radius);
  padding: 1.2rem 1.15rem 1.25rem;
  color: #fff;
  background:
    radial-gradient(420px 180px at 100% 0%, rgba(255, 255, 255, 0.18), transparent 60%),
    linear-gradient(155deg, var(--accent-deep), var(--accent));
}
/* Beat global `p { color: var(--muted) }` — same pattern as .balance-block */
.study-history__streak,
.study-history__streak p,
.study-history__streak span,
.study-history__streak small,
.study-history__streak strong {
  color: #fff;
}
.study-history__streak-label {
  margin: 0;
  font-size: 0.7rem;
  font-weight: 750;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.88);
}
.study-history__streak-big {
  margin: 0.7rem 0 0.55rem;
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  font-family: var(--font-display);
  font-size: 2.6rem;
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1;
  color: #fff;
}
.study-history__streak-big small {
  font-family: var(--font);
  font-size: 0.88rem;
  font-weight: 600;
  letter-spacing: 0;
  color: rgba(255, 255, 255, 0.92);
}
.study-history__streak-copy {
  margin: 0;
  font-size: 0.84rem;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.92);
}
.study-history__progress {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.1rem 1.15rem 1.15rem;
}
.study-history__progress-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.65rem;
  margin-bottom: 0.35rem;
}
.study-history__progress-head span {
  font-size: 0.8rem;
  font-weight: 750;
  color: var(--accent-deep);
}
.study-history__meter {
  margin: 0 0 0.55rem;
  font-size: 0.9rem;
  color: var(--ink);
}
.study-history__track {
  height: 0.4rem;
  border-radius: 999px;
  background: color-mix(in srgb, var(--line) 70%, #fff);
  overflow: hidden;
}
.study-history__fill {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--accent);
  transition: width 0.35s var(--ease-out);
}
.study-history__tip {
  margin: 0.75rem 0 0;
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.55;
}

@media (max-width: 860px) {
  .study-history__layout {
    grid-template-columns: 1fr;
  }
  .study-history__side {
    grid-template-columns: 1fr;
    gap: 1.15rem;
  }
}
@media (max-width: 560px) {
  .study-history__metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem 1rem;
  }
  .study-history__cal-head {
    flex-wrap: wrap;
  }
  .study-history__day {
    max-width: 2.4rem;
  }
  .study-history__item,
  .study-history__item:has(.study-history__item-link) {
    grid-template-columns: 1fr auto;
  }
  .study-history__item-link {
    grid-column: 1 / -1;
  }
}
.promo-block {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 1.1rem 1.15rem;
  margin-bottom: 1rem;
}
.promo-block h2 {
  margin: 0 0 0.75rem;
  font-size: 1.05rem;
}
.promo-redeem-form {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.55rem;
}
.promo-redeem-form input {
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.65rem 0.85rem;
  font: inherit;
}
@media (max-width: 420px) {
  .promo-redeem-form {
    grid-template-columns: 1fr;
  }
  .promo-redeem-form .btn {
    width: 100%;
    min-height: 48px;
  }
}
.profile-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 1.1rem 1.15rem;
  margin-bottom: 1rem;
}
.profile-card__label {
  margin: 0 0 0.2rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.profile-card h2 { margin: 0 0 0.2rem; }
.profile-links { display: grid; gap: 0.55rem; margin-bottom: 1rem; }
.profile-link {
  display: block;
  padding: 0.95rem 1rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  text-decoration: none;
  color: var(--ink);
  font-weight: 650;
}
.profile-link:hover { border-color: var(--accent); color: var(--accent-deep); }
.plan-tile__per {
  margin: 0 0 0.35rem !important;
  font-size: 0.82rem !important;
  font-weight: 650;
  color: var(--secondary-deep) !important;
}

.chat-page { padding-bottom: 1.5rem; }
@media (max-width: 860px) {
  .chat-page { padding-bottom: 0.75rem; }
}
.chat-admin-link {
  font-size: 0.78rem;
  font-weight: 650;
  color: var(--muted);
  text-decoration: none;
  align-self: center;
}
.chat-admin-link:hover { color: var(--accent-deep); }

.chat-inbox-hero {
  padding: 1.1rem 0 0.85rem;
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--secondary-deep) 8%, transparent), transparent 70%),
    var(--bg);
  border-bottom: 1px solid color-mix(in srgb, var(--line) 80%, transparent);
}
.chat-inbox-hero__inner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 0.65rem;
  margin-bottom: 0.85rem;
}
.chat-inbox-hero__eyebrow {
  margin: 0 0 0.15rem;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.chat-inbox-hero__copy h1 {
  margin: 0;
  font-size: clamp(1.45rem, 4vw, 1.85rem);
  letter-spacing: -0.02em;
}
.chat-inbox-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.55rem;
  margin-bottom: 0.35rem;
}
.chat-metric {
  padding: 0.7rem 0.8rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  min-height: 4.1rem;
}
.chat-metric__label {
  display: block;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.2rem;
}
.chat-metric__value {
  font-size: 1.35rem;
  font-weight: 750;
  letter-spacing: -0.03em;
  line-height: 1.1;
}
.chat-metric--live {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.2rem;
}
.chat-metric__sub {
  font-size: 0.72rem;
  color: var(--muted);
  line-height: 1.3;
}
.chat-live {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--secondary-deep);
}
.chat-live--compact {
  font-size: 0.75rem;
  justify-self: end;
}
.chat-live__dot {
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background: #2f9e6b;
  box-shadow: 0 0 0 0 rgba(47, 158, 107, 0.45);
  animation: chat-pulse 2.2s ease-out infinite;
}
.chat-live[data-state="syncing"] .chat-live__dot {
  background: var(--accent);
  animation: none;
}
.chat-live[data-state="paused"] .chat-live__dot {
  background: var(--muted);
  animation: none;
  opacity: 0.7;
}
@keyframes chat-pulse {
  0% { box-shadow: 0 0 0 0 rgba(47, 158, 107, 0.4); }
  70% { box-shadow: 0 0 0 8px rgba(47, 158, 107, 0); }
  100% { box-shadow: 0 0 0 0 rgba(47, 158, 107, 0); }
}
@media (prefers-reduced-motion: reduce) {
  .chat-live__dot { animation: none; }
}

.chat-shell {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  min-height: min(70vh, 640px);
}
.chat-shell--inbox {
  min-height: auto;
  padding-top: 1rem;
  padding-bottom: 1.25rem;
}

/* Staff desk: conversations left, messages right */
.chat-desk {
  display: grid;
  grid-template-columns: minmax(240px, 34%) minmax(0, 1fr);
  gap: 0.85rem;
  align-items: stretch;
  padding-top: 1rem;
  padding-bottom: 1.25rem;
  min-height: min(72vh, 720px);
}
.chat-desk__list {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  min-height: 0;
  max-height: min(72vh, 720px);
  overflow: hidden;
}
.chat-desk__list .chat-inbox {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding-right: 0.15rem;
}
.chat-desk__thread {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  min-width: 0;
  min-height: 0;
  max-height: min(72vh, 720px);
  padding: 0.85rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 16px;
}
.chat-desk__thread-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  flex: 0 0 auto;
}
.chat-desk__thread-title {
  margin: 0 0 0.15rem;
  font-size: 1.15rem;
  letter-spacing: -0.02em;
}
.chat-desk__thread .chat-hint {
  margin: 0;
  font-size: 0.82rem;
}
.chat-desk__thread .chat-log {
  flex: 1 1 auto;
  min-height: 0;
  max-height: none;
  border: 0;
  border-radius: 10px;
  background: color-mix(in srgb, var(--bg) 72%, var(--surface));
  padding: 0.75rem;
}
.chat-desk__thread .chat-compose {
  position: static;
  flex: 0 0 auto;
  bottom: auto;
  padding: 0.15rem 0 0;
  background: transparent;
}
.chat-desk__empty {
  margin: auto;
  text-align: center;
  padding: 2rem 1.25rem;
  color: var(--muted);
}
.chat-desk__empty-title {
  margin: 0 0 0.35rem;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--ink);
}
.chat-desk__empty-sub {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.4;
}
.chat-hint { margin: 0; }
.chat-hint--student a { font-weight: 650; }
.chat-inbox-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.15rem;
  flex: 0 0 auto;
}
.chat-inbox-toolbar__hint {
  margin: 0;
  font-size: 0.78rem;
  color: var(--muted);
  font-weight: 600;
}
.chat-inbox {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.45rem;
}
.chat-inbox-empty {
  padding: 2.2rem 1.2rem;
  text-align: center;
  color: var(--muted);
  background: var(--surface);
  border: 1px dashed var(--line);
  border-radius: 14px;
}
.chat-inbox-empty p { margin: 0; }
.chat-inbox-empty__sub {
  margin-top: 0.4rem !important;
  font-size: 0.86rem;
}
.chat-inbox__item {
  position: relative;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 0.75rem;
  align-items: center;
  padding: 0.85rem 0.95rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  text-decoration: none;
  color: var(--ink);
  transition: border-color 0.15s ease, background 0.15s ease, transform 0.15s ease;
}
.chat-inbox__item:hover {
  border-color: color-mix(in srgb, var(--secondary-deep) 28%, var(--line));
  transform: translateY(-1px);
}
.chat-inbox__item.is-active {
  border-color: color-mix(in srgb, var(--secondary-deep) 40%, var(--line));
  background:
    linear-gradient(90deg, color-mix(in srgb, var(--secondary-deep) 10%, transparent), transparent 48%),
    var(--surface);
  box-shadow: inset 3px 0 0 var(--secondary-deep);
  transform: none;
}
.chat-inbox__item.is-unread {
  border-color: color-mix(in srgb, var(--accent) 42%, var(--line));
  background:
    linear-gradient(90deg, color-mix(in srgb, var(--accent) 10%, transparent), transparent 42%),
    var(--surface);
}
.chat-inbox__item.is-active.is-unread {
  background:
    linear-gradient(90deg, color-mix(in srgb, var(--accent) 12%, transparent), transparent 48%),
    var(--surface);
}
.chat-inbox__avatar {
  width: 2.35rem;
  height: 2.35rem;
  border-radius: 11px;
  display: grid;
  place-items: center;
  font-size: 0.78rem;
  font-weight: 750;
  letter-spacing: 0.02em;
  color: var(--secondary-deep);
  background: color-mix(in srgb, var(--secondary-deep) 12%, white);
  flex: 0 0 auto;
}
.chat-inbox__body { min-width: 0; display: grid; gap: 0.18rem; }
.chat-inbox__top {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  align-items: baseline;
}
.chat-inbox__top strong {
  font-size: 0.95rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.chat-inbox__top time {
  font-size: 0.7rem;
  color: var(--muted);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.chat-inbox__preview {
  margin: 0;
  font-size: 0.86rem;
  color: var(--muted);
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.chat-inbox__item.is-unread .chat-inbox__preview { color: var(--ink); font-weight: 550; }
.chat-inbox__you { font-weight: 650; color: var(--ink); }
.chat-inbox__badge {
  min-width: 1.35rem;
  height: 1.35rem;
  padding: 0 0.35rem;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1.35rem;
  text-align: center;
  justify-self: end;
}
@media (max-width: 560px) {
  .chat-inbox-metrics { grid-template-columns: 1fr 1fr; }
  .chat-metric--live { grid-column: 1 / -1; min-height: auto; }
}
@media (max-width: 900px) {
  .chat-desk {
    grid-template-columns: 1fr;
    min-height: auto;
  }
  .chat-desk__list,
  .chat-desk__thread {
    max-height: none;
  }
  /* Mobile desk: list XOR thread (same as messenger) */
  .chat-page--desk:not(.chat-page--desk-open) .chat-desk__thread { display: none; }
  .chat-page--desk-open .chat-desk__list { display: none; }
  .chat-page--desk-open .chat-inbox-metrics { display: none; }
  .chat-page--desk-open .chat-desk__thread {
    min-height: min(70vh, 640px);
  }
}
.chat-log {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  padding: 0.85rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  max-height: 52vh;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
}

/* Mobile chat thread: app shell — Chat bar at top, only message list scrolls */
@media (max-width: 860px) {
  html:has(.chat-page:not(.chat-page--desk):not(.chat-page--inbox)),
  html:has(.chat-page--desk-open) {
    overflow: hidden;
    height: 100%;
  }
  body:has(.chat-page:not(.chat-page--desk):not(.chat-page--inbox)),
  body:has(.chat-page--desk-open) {
    overflow: hidden;
    height: 100dvh;
    max-height: 100dvh;
    padding-bottom: 0;
    overscroll-behavior: none;
  }
  body:has(.chat-page:not(.chat-page--desk):not(.chat-page--inbox)) .site-nav,
  body:has(.chat-page--desk-open) .site-nav {
    display: none;
  }
  body:has(.chat-page:not(.chat-page--desk):not(.chat-page--inbox)) .site-footer,
  body:has(.chat-page--desk-open) .site-footer {
    display: none;
  }
  .chat-page:not(.chat-page--desk):not(.chat-page--inbox),
  .chat-page--desk-open {
    display: flex;
    flex-direction: column;
    height: calc(100dvh - 3.55rem - env(safe-area-inset-bottom, 0px));
    max-height: calc(100dvh - 3.55rem - env(safe-area-inset-bottom, 0px));
    padding-bottom: 0;
    overflow: hidden;
  }
  body.admin-bar .chat-page:not(.chat-page--desk):not(.chat-page--inbox),
  body.admin-bar .chat-page--desk-open {
    height: calc(100dvh - 3.55rem - 46px - env(safe-area-inset-bottom, 0px));
    max-height: calc(100dvh - 3.55rem - 46px - env(safe-area-inset-bottom, 0px));
  }
  .chat-page:not(.chat-page--desk):not(.chat-page--inbox) .pricing-hero,
  .chat-page--desk-open .chat-desk-hero {
    flex: 0 0 auto;
    position: static;
    top: auto;
  }
  .chat-page--desk-open .chat-desk-hero .chat-inbox-hero__copy h1 {
    font-size: 1.15rem;
  }
  .chat-page:not(.chat-page--desk):not(.chat-page--inbox) .chat-shell,
  .chat-page--desk-open .chat-desk {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding-top: 0.55rem;
    padding-bottom: 0.45rem;
    overflow: hidden;
  }
  .chat-page--desk-open .chat-desk__thread {
    flex: 1 1 auto;
    min-height: 0;
    max-height: none;
    border: 0;
    border-radius: 0;
    padding: 0;
    background: transparent;
  }
  .chat-page:not(.chat-page--desk):not(.chat-page--inbox) .chat-hint {
    display: none;
  }
  .chat-page:not(.chat-page--desk):not(.chat-page--inbox) .chat-log,
  .chat-page--desk-open .chat-log {
    flex: 1 1 auto;
    min-height: 0;
    max-height: none;
    border-radius: 12px;
  }
  .chat-page:not(.chat-page--desk):not(.chat-page--inbox) .chat-compose,
  .chat-page--desk-open .chat-compose {
    position: static;
    flex: 0 0 auto;
    bottom: auto;
    z-index: 1;
    background: var(--bg);
    padding: 0.15rem 0 0;
  }
}
.chat-empty {
  margin: auto;
  color: var(--muted);
  font-size: 0.92rem;
  text-align: center;
}
.chat-bubble {
  max-width: 88%;
  padding: 0.7rem 0.85rem;
  border-radius: 14px;
  background: rgba(42, 31, 36, 0.05);
  align-self: flex-start;
}
.chat-bubble__role {
  display: block;
  margin-bottom: 0.2rem;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}
.chat-bubble p { margin: 0; font-size: 0.95rem; line-height: 1.4; white-space: pre-wrap; word-break: break-word; }
.chat-bubble time {
  display: block;
  margin-top: 0.35rem;
  font-size: 0.72rem;
  color: var(--muted);
}
.chat-bubble.is-mine {
  align-self: flex-end;
  background: color-mix(in srgb, var(--accent) 16%, white);
}
.chat-bubble.is-studio:not(.is-mine) {
  background: color-mix(in srgb, var(--secondary-deep) 10%, white);
}
.chat-compose {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.55rem;
  align-items: end;
  position: sticky;
  bottom: calc(3.6rem + env(safe-area-inset-bottom, 0px));
  background: var(--bg);
  padding: 0.35rem 0 0.15rem;
  z-index: 2;
}
.chat-compose textarea {
  width: 100%;
  resize: vertical;
  min-height: 2.8rem;
  max-height: 7rem;
  border-radius: 12px;
  border: 1px solid var(--line);
  padding: 0.7rem 0.85rem;
  font: inherit;
  background: var(--surface);
}
.mobile-dock__item { position: relative; }
.mobile-dock__badge {
  position: absolute;
  top: 0.2rem;
  right: calc(50% - 1.55rem);
  min-width: 1.05rem;
  height: 1.05rem;
  padding: 0 0.28rem;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-size: 0.62rem;
  font-weight: 700;
  line-height: 1.05rem;
  text-align: center;
}
.wallet-pack-price {
  margin: 0 0 0.75rem;
  font-size: 1.6rem;
  font-weight: 750;
}

@media (max-width: 860px) {
  /* Type chips stay visible — primary schedule action on phones */
  .filters--chips {
    display: none;
  }
  .schedule-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem 0.65rem;
    margin: 0.15rem 0 0.75rem;
  }
  .schedule-toolbar .filters--chips {
    display: flex;
    flex: 1 1 auto;
    margin: 0;
  }
  .schedule-toolbar .filters-trigger {
    display: none; /* chips cover All / Yoga / Pilates */
  }
}

/* —— Admin front-edit pencils —— */
body.yoga-front-edit .yoga-edit-region {
  position: relative;
}
body.yoga-front-edit .yoga-edit-region::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 1.5px dashed transparent;
  border-radius: 10px;
  pointer-events: none;
  transition: border-color 0.15s ease, background 0.15s ease;
  z-index: 5;
}
body.yoga-front-edit .yoga-edit-region:hover::after,
body.yoga-front-edit .yoga-edit-region:focus-within::after {
  border-color: color-mix(in srgb, var(--accent) 70%, #fff);
  background: color-mix(in srgb, var(--accent) 6%, transparent);
}
.yoga-edit-pencil {
  position: absolute;
  top: 0.55rem;
  right: 0.55rem;
  z-index: 30;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.4rem 0.65rem;
  border-radius: 999px;
  background: var(--accent);
  color: #fff !important;
  text-decoration: none !important;
  font-size: 0.72rem;
  font-weight: 750;
  letter-spacing: 0.02em;
  line-height: 1;
  opacity: 0;
  transform: translateY(-4px);
  pointer-events: none;
  transition: opacity 0.15s ease, transform 0.15s ease, background 0.15s ease;
  box-shadow: 0 8px 20px rgba(36, 24, 32, 0.18);
}
.yoga-edit-pencil svg {
  width: 0.95rem;
  height: 0.95rem;
  stroke-width: 2.25;
}
.yoga-edit-region:hover > .yoga-edit-pencil,
.yoga-edit-region:focus-within > .yoga-edit-pencil,
.yoga-edit-pencil:focus-visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.yoga-edit-pencil:hover {
  background: var(--accent-deep);
  color: #fff !important;
}
.yoga-edit-pencil__text {
  max-width: 9rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.yoga-edit-region--hero > .yoga-edit-pencil {
  top: calc(var(--nav-h) + 0.65rem);
  right: 1rem;
}
body.admin-bar .yoga-edit-region--hero > .yoga-edit-pencil {
  top: calc(var(--nav-h) + 32px + 0.65rem);
}
@media (max-width: 782px) {
  body.admin-bar .yoga-edit-region--hero > .yoga-edit-pencil {
    top: calc(var(--nav-h) + 46px + 0.65rem);
  }
}
.yoga-edit-region--row {
  display: block;
}
.yoga-edit-region--row > .yoga-edit-pencil {
  top: 0.45rem;
  right: 0.45rem;
}
.brand-wrap {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-width: 0;
  max-width: 100%;
}
.yoga-edit-region--brand > .yoga-edit-pencil {
  top: 50%;
  right: auto;
  left: calc(100% + 0.25rem);
  transform: translateY(-50%) translateX(-4px);
}
.yoga-edit-region--brand:hover > .yoga-edit-pencil,
.yoga-edit-region--brand:focus-within > .yoga-edit-pencil {
  transform: translateY(-50%) translateX(0);
}
.yoga-edit-region--footer {
  display: block;
}
@media (max-width: 640px) {
  .yoga-edit-pencil__text { display: none; }
  .yoga-edit-pencil {
    padding: 0.45rem;
    border-radius: 10px;
  }
}
