/* ============================================
   Libit — Design System
   Warm caramel sanctuary · matched to the Libit app
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+Hebrew:wght@300;400;500;600;700;800;900&family=Poppins:wght@400;500;600;700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:wght,FILL@100..700,0..1&display=swap');

/* ---------- Tokens ---------- */
:root {
  /* ---- App palette (Figma variables) ----
     חום #6a3f3a · חום בהיר #aa7a54 · אפרסק כהה #e4b7a0
     אפרסק בהיר #edcebc · בז' #feeddb · בז' בהיר #fff7ee · בז' בהיר בהיר #fffbf7 */

  /* Surfaces — warm cream ramp */
  --bg: #fff7ee;          /* בז' בהיר — page background */
  --bg-elev: #fffbf7;     /* בז' בהיר בהיר — cards / elevated */
  --bg-low: #fdefdf;
  --bg-deep: #f8e2ce;     /* בז' area */
  --bg-high: #f0d5be;
  --bg-variant: #e9cbb2;

  /* Text — warm browns */
  --ink: #6a3f3a;         /* חום */
  --ink-soft: #8a6153;
  --muted: #a9836e;
  --outline-soft: #ecd2bd;

  /* Brand — caramel accent (חום בהיר) used for text, links, eyebrows, borders */
  --primary: #aa7a54;
  --primary-hover: #8a6041;
  --primary-light: #f6e7d9;
  --on-primary: #ffffff;

  /* Peach — the app's primary BUTTON fill (אפרסק כהה) */
  --peach: #e4b7a0;
  --peach-deep: #d29e83;
  --peach-soft: #edcebc;  /* אפרסק בהיר */
  --beige: #feeddb;       /* בז' */

  /* Secondary remapped to caramel (the app has no green) */
  --secondary: #aa7a54;
  --secondary-light: #f3e4d6;
  --secondary-deep: #8a6041;
  --on-secondary: #ffffff;

  --tertiary: #a9836e;

  /* Type — Noto Sans Hebrew for Hebrew, Poppins for Latin eyebrows/labels */
  --font: 'Noto Sans Hebrew', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --font-latin: 'Poppins', var(--font);

  /* Layout */
  --container: 1280px;
  --gutter: clamp(1rem, 3vw, 1.5rem);
  --section-gap: clamp(3rem, 7vw, 6rem);

  /* Radii — the app rounds everything softly; pills for buttons/inputs */
  --r-sm: 0.5rem;
  --r-md: 0.85rem;
  --r-lg: 1.25rem;
  --r-xl: 1.75rem;
  --r-2xl: 2.25rem;
  --r-pill: 100px;

  /* Motion */
  --t-fast: 200ms ease;
  --t-base: 300ms cubic-bezier(0.4, 0, 0.2, 1);
  --t-slow: 520ms cubic-bezier(0.22, 1, 0.36, 1);

  /* Shadows — soft warm caramel glow (app signature: 0 0 20px #AA7A5433) */
  --shadow-1: 0 6px 24px rgba(170, 122, 84, 0.10);
  --shadow-2: 0 14px 36px rgba(170, 122, 84, 0.20);
  --shadow-soft: 0 2px 10px rgba(170, 122, 84, 0.08);
  --shadow-glow: 0 0 20px rgba(170, 122, 84, 0.20);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

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

body {
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.5;
  color: var(--ink);
  background-color: var(--bg);
  background-image:
    radial-gradient(60rem 40rem at 100% -10%, rgba(254, 237, 219, 0.9), transparent 60%),
    radial-gradient(50rem 36rem at -10% 20%, rgba(237, 206, 188, 0.35), transparent 60%);
  background-repeat: no-repeat;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  direction: rtl;
  overflow-x: hidden;
}

img, svg, video { display: block; max-width: 100%; height: auto; }

button {
  font-family: inherit;
  background: none;
  border: 0;
  cursor: pointer;
  color: inherit;
}

a {
  color: var(--ink);
  text-decoration: none;
  transition: color var(--t-fast);
}

a:hover { color: var(--primary); }

ul, ol { margin: 0; padding: 0; list-style: none; }
p { margin: 0; }

/* Scrollbar */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--outline-soft); border-radius: var(--r-pill); }
::-webkit-scrollbar-thumb:hover { background: var(--primary); }

/* Material Symbols defaults */
.material-symbols-outlined {
  font-family: 'Material Symbols Outlined';
  font-weight: normal;
  font-style: normal;
  font-size: 24px;
  line-height: 1;
  letter-spacing: normal;
  text-transform: none;
  display: inline-block;
  white-space: nowrap;
  word-wrap: normal;
  direction: ltr;
  -webkit-font-feature-settings: 'liga';
  -webkit-font-smoothing: antialiased;
  font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
}

/* ---------- Typography ---------- */
.display {
  font-size: clamp(2rem, 5.5vw, 2.75rem);
  line-height: 1.18;
  font-weight: 800;
  letter-spacing: 0;
  color: var(--primary);
  margin: 0;
}

.display-xl {
  font-size: clamp(2.25rem, 5.2vw, 3.4rem);
  line-height: 1.18;
  font-weight: 800;
  letter-spacing: 0;
  color: var(--ink);
  margin: 0;
}

.headline {
  font-size: clamp(1.25rem, 2vw, 1.5rem);
  line-height: 1.33;
  font-weight: 700;
  color: var(--ink);
  margin: 0;
  letter-spacing: 0;
}

.body-lg {
  font-size: 1.125rem;
  line-height: 1.55;
  color: var(--ink-soft);
}

.body {
  font-size: 1rem;
  line-height: 1.55;
  color: var(--ink-soft);
}

.label {
  font-size: 0.8125rem;
  line-height: 1.23;
  letter-spacing: 0.08em;
  font-weight: 600;
  text-transform: uppercase;
  color: var(--tertiary);
}

.eyebrow {
  font-size: 0.9rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--peach-deep);
  margin: 0;
}

.quote-accent {
  font-size: 1.25rem;
  line-height: 1.5;
  color: var(--ink);
  font-weight: 400;
}

.muted { color: var(--muted); }

/* ---------- Layout ---------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding-inline: var(--gutter);
  position: relative;
}

.section {
  padding-block: var(--section-gap);
  position: relative;
}

.section-tight {
  padding-block: clamp(2rem, 4vw, 3rem);
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 247, 238, 0.82);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid transparent;
  transition: border-color var(--t-base), background var(--t-base);
}

.site-header.is-scrolled {
  border-bottom-color: rgba(236, 210, 189, 0.7);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  height: 80px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--primary);
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: 0;
}

.brand-mark {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 38%, #edc3ad 0%, var(--peach) 70%);
  display: inline-grid;
  place-items: center;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(170, 122, 84, 0.28);
}

.brand-mark img { width: 74%; height: auto; margin-top: 2px; }

.brand-name {
  display: inline-flex;
  align-items: baseline;
  gap: 0.4rem;
}

.brand-tag {
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--muted);
  letter-spacing: 0;
  padding-inline-start: 0.55rem;
  border-inline-start: 1px solid var(--outline-soft);
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex: 1;
  justify-content: center;
}

.nav-menu a {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--ink-soft);
  padding: 0.5rem 0.75rem;
  border-radius: var(--r-lg);
  transition: background var(--t-fast), color var(--t-fast);
  letter-spacing: 0.02em;
}

.nav-menu a:hover {
  background: var(--bg-low);
  color: var(--primary);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.nav-burger {
  display: none;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  border-radius: var(--r-md);
  color: var(--primary);
}

.nav-burger:hover { background: var(--bg-low); }
.nav-burger .material-symbols-outlined { font-size: 28px; }

@media (max-width: 880px) {
  .nav-menu, .nav-actions .btn-ghost { display: none; }
  .nav-burger { display: inline-flex; }
}

/* On small phones the header CTA is offered inside the drawer instead */
@media (max-width: 560px) {
  .nav-actions .btn-primary { display: none; }
  .nav { gap: 0.75rem; height: 68px; }

  .display-xl { font-size: clamp(1.9rem, 8.6vw, 2.4rem); line-height: 1.22; }
  .display { font-size: clamp(1.7rem, 7.6vw, 2.1rem); }
  .plan { padding: 1.75rem 1.35rem 1.35rem; }
}

@media (max-width: 380px) {
  .display-xl { font-size: 1.8rem; }
  .container { --gutter: 1rem; }
}

/* Mobile drawer */
.mobile-drawer {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: var(--bg);
  padding: 1.5rem var(--gutter);
  transform: translateX(100%);
  transition: transform var(--t-slow);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}

[dir="rtl"] .mobile-drawer { transform: translateX(-100%); }
.mobile-drawer.is-open { transform: translateX(0); }

.mobile-drawer .drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2.5rem;
}

.mobile-drawer .drawer-close {
  width: 44px; height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--r-md);
  color: var(--ink);
}

.mobile-drawer .drawer-close:hover { background: var(--bg-low); }

.mobile-drawer .drawer-menu {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.mobile-drawer .drawer-menu a {
  display: block;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--ink);
  padding-block: 0.75rem;
  border-bottom: 1px solid var(--bg-high);
  letter-spacing: -0.01em;
}

.mobile-drawer .drawer-actions {
  margin-top: auto;
  padding-top: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.9rem;
  border-radius: var(--r-pill);
  font-family: var(--font);
  font-size: 0.95rem;
  font-weight: 800;
  letter-spacing: 0.01em;
  cursor: pointer;
  white-space: nowrap;
  transition: background var(--t-base), color var(--t-base), border-color var(--t-base), transform var(--t-fast), box-shadow var(--t-base);
  border: 2px solid transparent;
  outline: none;
}

.btn:focus-visible {
  box-shadow: 0 0 0 3px rgba(170, 122, 84, 0.30);
}

.btn:active { transform: scale(0.97); }

/* Primary — solid peach, white text (app Component 2) */
.btn-primary {
  background: var(--peach);
  color: var(--on-primary);
}

.btn-primary:hover {
  background: var(--peach-deep);
  color: var(--on-primary);
}

.btn-primary.with-shadow {
  box-shadow: var(--shadow-glow);
}

/* Secondary — cream fill, peach outline, peach text (app Component 3) */
.btn-secondary {
  background: var(--bg-elev);
  color: var(--peach-deep);
  border-color: var(--peach);
}

.btn-secondary:hover {
  background: var(--primary-light);
  color: var(--peach-deep);
}

.btn-ghost {
  background: transparent;
  color: var(--primary);
  padding: 0.55rem 1.1rem;
  font-weight: 700;
}

.btn-ghost:hover {
  color: var(--primary-hover);
  background: var(--primary-light);
}

/* Tonal — soft peach fill */
.btn-tonal {
  background: var(--peach-soft);
  color: var(--secondary-deep);
}

.btn-tonal:hover {
  background: var(--peach);
  color: var(--on-primary);
}

.btn-block { width: 100%; }

.btn-lg { padding: 1rem 2.1rem; font-size: 1.02rem; }
.btn .material-symbols-outlined { font-size: 20px; }

.btn-cream {
  background: var(--bg);
  color: var(--primary);
  box-shadow: var(--shadow-glow);
}

.btn-cream:hover { background: #fff; color: var(--primary-hover); }

.btn-store {
  background: var(--primary);
  color: var(--on-primary);
  padding: 0.875rem 1.5rem;
  gap: 0.75rem;
  border-radius: var(--r-pill);
}

.btn-store:hover { background: var(--primary-hover); color: var(--on-primary); }
.btn-store .material-symbols-outlined { font-size: 28px; }

.btn-store-text { display: flex; flex-direction: column; align-items: flex-end; line-height: 1.1; }
.btn-store-text small { font-size: 0.68rem; font-weight: 400; opacity: 0.78; }
.btn-store-text strong { font-size: 1rem; font-weight: 700; letter-spacing: 0; }

/* ---------- Shared bits: watercolor wash, phone frame, chips ---------- */
.wash {
  position: absolute;
  inset: 8% 4%;
  background: url('../img/watercolor.webp') center / contain no-repeat;
  opacity: 0.9;
  z-index: 0;
  pointer-events: none;
}

.phone {
  position: relative;
  z-index: 1;
  margin: 0;
  width: clamp(230px, 24vw, 290px);
  aspect-ratio: 420 / 912;
  padding: 9px;
  background: var(--bg-elev);
  border-radius: 46px;
  box-shadow:
    0 0 0 1px rgba(236, 210, 189, 0.9),
    0 30px 60px -20px rgba(106, 63, 58, 0.28),
    var(--shadow-glow);
}

.phone img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 38px;
}

.ticks {
  display: grid;
  gap: 0.65rem;
  margin-top: 1.5rem;
}

.ticks li {
  position: relative;
  padding-inline-start: 1.9rem;
  color: var(--ink);
  font-size: 1.02rem;
  letter-spacing: 0.02em;
}

.ticks li::before {
  content: '';
  position: absolute;
  inset-inline-start: 0;
  top: 0.15em;
  width: 1.25rem;
  height: 1.25rem;
  border-radius: 50%;
  background: var(--peach-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M9.5 16.2 5.3 12l-1.4 1.4 5.6 5.6 11-11-1.4-1.4z' fill='%23aa7a54'/%3E%3C/svg%3E") center / 70% no-repeat;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 1.75rem;
}

.chips li {
  background: var(--beige);
  color: var(--primary);
  padding: 0.7rem 1.35rem;
  border-radius: var(--r-pill);
  font-size: 1rem;
  letter-spacing: 0.02em;
}

/* ---------- Hero ---------- */
.hero {
  padding-block: clamp(2.5rem, 6vw, 5rem) clamp(3rem, 7vw, 6rem);
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}

.hero-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1.35rem;
}

.hero-proof,
.closing-proof {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.05em;
}

.hero-proof {
  color: var(--primary);
  background: var(--bg-elev);
  padding: 0.5rem 1rem 0.5rem 1.1rem;
  border-radius: var(--r-pill);
  box-shadow: var(--shadow-soft);
}

.hero-proof img {
  width: 92px;
  height: auto;
  /* the app's stars are cream; tint them caramel on light backgrounds */
  filter: brightness(0) saturate(100%) invert(56%) sepia(31%) saturate(560%) hue-rotate(345deg) brightness(92%);
}

.display-xl .accent { color: var(--primary); display: block; }

.hero-lead {
  font-size: 1.15rem;
  line-height: 1.7;
  color: var(--ink-soft);
  max-width: 34rem;
  letter-spacing: 0.01em;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 0.4rem;
}

.hero-note {
  font-size: 0.88rem;
  color: var(--muted);
}

.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: clamp(460px, 48vw, 640px);
}

.wash-hero { inset: 0 -6%; }

.phone-hero { width: clamp(250px, 25vw, 300px); transform: rotate(-3deg); }

.hero-mascot {
  position: absolute;
  z-index: 2;
  width: clamp(120px, 13vw, 170px);
  inset-inline-end: max(0px, calc(50% - 15rem));
  bottom: 6%;
  filter: drop-shadow(0 12px 18px rgba(170, 122, 84, 0.25));
  animation: float 6s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

/* ---------- Method: Michal's letter ---------- */
.method {
  background:
    radial-gradient(60% 70% at 85% 30%, rgba(237, 206, 188, 0.45), transparent 70%),
    var(--beige);
}

.method-grid {
  display: grid;
  grid-template-columns: minmax(300px, 0.85fr) 1.15fr;
  gap: clamp(2.5rem, 6vw, 5rem);
  align-items: center;
}

.letter {
  background: var(--bg-elev);
  border-radius: var(--r-2xl);
  padding: 0 clamp(1.5rem, 3vw, 2.5rem) 2rem;
  text-align: center;
  box-shadow: var(--shadow-1);
  color: var(--ink);
  font-size: 1.05rem;
  line-height: 1.7;
  letter-spacing: 0.02em;
}

.letter p + p { margin-top: 0.5rem; }

.letter-portrait {
  position: relative;
  width: 230px;
  height: 230px;
  margin: -3.5rem auto 0.25rem;
}

.letter-wash {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.letter-photo {
  position: absolute;
  width: 112px;
  height: 112px;
  top: 64px;
  inset-inline-start: 59px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--peach-soft);
}

.letter-mascot {
  position: absolute;
  width: 92px;
  height: 92px;
  bottom: 22px;
  inset-inline-start: 18px;
  transform: scaleX(-1);
}

.letter-title {
  font-size: 1.15rem;
  font-weight: 800;
  margin: 0 0 0.35rem;
}

.letter-signature {
  width: 132px;
  margin: 1.25rem auto 0;
}

.method-content { display: flex; flex-direction: column; gap: 1.25rem; }

.method-quote {
  margin: 0.5rem 0;
  padding: 0.25rem 1.5rem;
  border-inline-start: 3px solid var(--peach);
}

.method-quote p {
  font-size: clamp(1.15rem, 1.8vw, 1.35rem);
  line-height: 1.6;
  color: var(--ink);
}

.method-quote cite {
  display: block;
  margin-top: 0.85rem;
  font-style: normal;
  font-size: 0.9rem;
  color: var(--primary);
  font-weight: 700;
}

/* ---------- Feature rows (Libit chat, battery) ---------- */
.feature { overflow: hidden; }

.feature-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: clamp(2rem, 6vw, 5rem);
  align-items: center;
}

.feature-grid-flip .feature-text { order: 2; }
.feature-grid-flip .feature-visual { order: 1; }

.feature-text { max-width: 36rem; }
.feature-text .display { margin: 0.85rem 0 1.15rem; }

.feature-visual {
  position: relative;
  display: flex;
  justify-content: center;
  padding-block: 2rem;
}

.ask-pill {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  max-width: 24rem;
  margin-top: 2rem;
  padding: 0.95rem 1.4rem;
  background: #fff;
  border-radius: var(--r-pill);
  box-shadow: var(--shadow-glow);
  color: var(--primary);
  font-size: 1rem;
  transition: transform var(--t-fast), box-shadow var(--t-base);
}

.ask-pill:hover { color: var(--primary-hover); transform: translateY(-2px); box-shadow: var(--shadow-2); }

.feature-battery {
  background: linear-gradient(180deg, transparent 0%, rgba(254, 237, 219, 0.7) 100%);
  position: relative;
}

.feature-scene {
  position: absolute;
  inset: 0 0 auto;
  width: 100%;
  height: 70%;
  object-fit: cover;
  opacity: 0.22;
  -webkit-mask-image: linear-gradient(180deg, #000 30%, transparent);
  mask-image: linear-gradient(180deg, #000 30%, transparent);
  pointer-events: none;
}

/* ---------- Power jar ---------- */
.jar-grid {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: clamp(2rem, 6vw, 5rem);
  align-items: center;
}

.jar-head .display { margin: 0.85rem 0 1.15rem; }

.jar-illus {
  width: 140px;
  margin-bottom: 1rem;
  filter: drop-shadow(var(--shadow-soft));
}

.moments {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

/* The app staggers the pill widths; keep that rhythm */
.moment {
  display: flex;
  align-items: center;
  gap: 1rem;
  min-height: 76px;
  padding-inline: 0.75rem 1.75rem;
  background: var(--peach-soft);
  border-radius: 200px;
  box-shadow: var(--shadow-glow);
  color: var(--ink);
  font-size: 1.08rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  margin-inline-end: 6%;
}

.moment:nth-child(3) { margin-inline-end: 8%; }
.moment:nth-child(5) { margin-inline-end: 8%; }

.moment-deep {
  background: var(--peach);
  color: #fff;
  margin-inline-end: 0;
}

.moment img {
  width: 82px;
  height: 82px;
  margin-block: -10px;
  flex-shrink: 0;
}

/* ---------- Program trail ---------- */
.program {
  background:
    radial-gradient(50% 60% at 15% 60%, rgba(237, 206, 188, 0.35), transparent 70%);
}

.program-grid {
  display: grid;
  grid-template-columns: 1fr minmax(300px, 440px);
  gap: clamp(2rem, 6vw, 5rem);
  align-items: center;
}

.program-text .display { margin: 0.85rem 0 1.15rem; }

.stages {
  list-style: none;
  display: grid;
  gap: 0.75rem;
  margin-top: 2rem;
}

.stages li {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  font-size: 1.1rem;
  color: var(--ink);
}

.stage-num {
  display: inline-grid;
  place-items: center;
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 50%;
  background: radial-gradient(circle at 40% 35%, #f6cdb6, var(--peach-deep));
  color: #fff;
  font-weight: 800;
  font-family: var(--font-latin);
  box-shadow: inset 0 -2px 0 rgba(106, 63, 58, 0.15), var(--shadow-soft);
}

/* Coordinates mirror the app's "The program" screen (420 × 912),
   cropped to the band y 230 → 710 */
.trail {
  position: relative;
  aspect-ratio: 420 / 480;
  border-radius: var(--r-2xl);
  overflow: hidden;
  background: var(--bg);
  box-shadow: var(--shadow-2);
}

.trail > * { position: absolute; }

.trail-bg {
  width: 195.48%;
  max-width: none;
  left: -48.57%;
  top: -95%;
  opacity: 0.85;
}

.trail-flag { width: 8.8%; left: 50.5%; top: 5%; }
.trail-sign { width: 11.5%; }
.trail-sign-3 { width: 9.8%; left: 36.9%; top: 16.9%; }
.trail-sign-2 { left: 61.4%; top: 34.8%; }
.trail-sign-1 { width: 13.1%; left: 23.6%; top: 56.25%; }

.trail-tag {
  background: var(--bg);
  color: var(--primary);
  font-weight: 800;
  font-size: clamp(0.8rem, 1.3vw, 1rem);
  letter-spacing: 0.02em;
  padding: 0.45rem 1rem;
  border-radius: 200px;
  box-shadow: var(--shadow-glow);
  white-space: nowrap;
}

.trail-tag-3 { left: 48.8%; top: 20.2%; }
.trail-tag-2 { left: 30.7%; top: 39.6%; }
.trail-tag-1 { left: 36.2%; top: 61.9%; }

.trail-hiker {
  width: 27.6%;
  left: 7.9%;
  top: 73.75%;
  transform: scaleX(-1);
}

.trail-bubble {
  left: 33.1%;
  top: 76.25%;
  width: 56.4%;
  aspect-ratio: 237 / 103;
  display: grid;
  place-items: center;
  padding: 0 7% 0 5%;
  background: url('../img/program/bubble.webp') center / 100% 100% no-repeat;
  color: var(--primary);
  font-size: clamp(0.72rem, 1.15vw, 0.9rem);
  line-height: 1.35;
  text-align: center;
}

/* ---------- Pricing ---------- */
.pricing-section {
  background: linear-gradient(180deg, transparent, rgba(254, 237, 219, 0.6) 30%, transparent);
}

.section-head {
  max-width: 40rem;
  margin: 0 auto 2rem;
  text-align: center;
}

.section-head .display { margin: 0.85rem 0 0.9rem; }
.section-head p:last-child { color: var(--ink-soft); font-size: 1.08rem; }

.partner-toggle {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.8rem;
  margin-bottom: 2.5rem;
  color: var(--ink);
  font-weight: 600;
}

.partner-toggle small { color: var(--primary); font-weight: 700; font-size: 0.95em; }

.switch {
  position: relative;
  width: 52px;
  height: 30px;
  border-radius: var(--r-pill);
  background: var(--bg-high);
  transition: background var(--t-base);
  flex-shrink: 0;
}

.switch-knob {
  position: absolute;
  top: 3px;
  inset-inline-start: 3px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 6px rgba(106, 63, 58, 0.2);
  transition: transform var(--t-base);
}

.switch[aria-checked="true"] { background: var(--peach); }
.switch[aria-checked="true"] .switch-knob { transform: translateX(-22px); }

.pricing {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  align-items: stretch;
}

.plan {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--bg-elev);
  border-radius: var(--r-xl);
  padding: 2rem 1.5rem 1.5rem;
  box-shadow: var(--shadow-1);
}

.plan.featured {
  background: #fff;
  box-shadow: 0 0 0 2px var(--peach), var(--shadow-2);
}

.plan-badge {
  position: absolute;
  top: -0.85rem;
  inset-inline-start: 50%;
  transform: translateX(50%);
  background: var(--peach);
  color: #fff;
  padding: 0.3rem 1rem;
  border-radius: var(--r-pill);
  font-size: 0.82rem;
  font-weight: 800;
  white-space: nowrap;
}

.plan-name {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--primary);
  margin: 0;
}

.plan-tagline {
  color: var(--ink-soft);
  font-size: 0.95rem;
  margin-top: 0.3rem;
}

.plan-price {
  font-family: var(--font-latin);
  font-size: 2.6rem;
  font-weight: 600;
  color: var(--ink);
  margin: 1.1rem 0 1.25rem;
  line-height: 1;
  direction: ltr;
  text-align: end;
}

.plan-price small {
  font-family: var(--font);
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--muted);
  margin-inline-start: 0.2rem;
}

.plan-includes {
  font-weight: 700;
  color: var(--ink);
  font-size: 0.95rem;
  margin-bottom: 0.65rem;
}

.plan-features {
  display: grid;
  gap: 0.6rem;
  margin-bottom: 1.25rem;
}

.plan-features li {
  position: relative;
  padding-inline-start: 1.5rem;
  font-size: 0.93rem;
  line-height: 1.5;
  color: var(--ink-soft);
}

.plan-features li::before {
  content: '';
  position: absolute;
  inset-inline-start: 0;
  top: 0.5em;
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  background: var(--peach);
}

.plan-footnote {
  font-size: 0.85rem;
  color: var(--muted);
  margin-bottom: 1.25rem;
}

.plan .btn { margin-top: auto; }

.pricing-extra {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 1rem;
  margin-top: 1.5rem;
}

.extra-card {
  background: var(--bg-elev);
  border-radius: var(--r-xl);
  padding: 1.75rem;
  border: 1px solid rgba(236, 210, 189, 0.7);
}

.extra-card h3 {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--primary);
  margin: 0 0 1rem;
}

.extra-list { margin: 0; display: grid; gap: 0.85rem; }

.extra-list div {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 0.85rem;
  border-bottom: 1px dashed var(--outline-soft);
}

.extra-list div:last-child { border-bottom: 0; padding-bottom: 0; }
.extra-list dt { color: var(--ink-soft); font-size: 0.93rem; }
.extra-list dd { margin: 0; color: var(--ink); font-weight: 700; white-space: nowrap; font-size: 0.95rem; }

.terms-list { display: grid; gap: 0.6rem; }
.terms-list li { font-size: 0.93rem; line-height: 1.6; color: var(--ink-soft); }
.terms-list strong { color: var(--ink); }

/* ---------- Closing CTA (splash screen) ---------- */
.closing {
  background:
    radial-gradient(70% 90% at 50% 0%, rgba(255, 247, 238, 0.25), transparent 70%),
    var(--peach);
  padding-block: clamp(3.5rem, 8vw, 6rem);
  color: var(--ink);
  text-align: center;
}

.closing-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.closing-logo { width: clamp(110px, 14vw, 150px); margin-bottom: 0.5rem; }

.closing h2 {
  font-size: clamp(1.8rem, 4.5vw, 2.6rem);
  font-weight: 800;
  color: var(--ink);
  margin: 0;
}

.closing p { font-size: 1.1rem; max-width: 32rem; }

.closing .btn { margin-top: 0.75rem; }

.closing-proof { margin-top: 1rem; color: var(--ink); }
.closing-proof img { width: 100px; }

/* ---------- Home responsive ---------- */
@media (max-width: 1100px) {
  .pricing { grid-template-columns: repeat(2, 1fr); row-gap: 1.75rem; }
}

@media (max-width: 880px) {
  .hero-grid,
  .method-grid,
  .feature-grid,
  .jar-grid,
  .program-grid,
  .pricing-extra { grid-template-columns: 1fr; }

  .hero-text { align-items: center; text-align: center; }
  .hero-actions { justify-content: center; }
  .feature-grid-flip .feature-text,
  .feature-grid-flip .feature-visual { order: initial; }
  .feature-text, .jar-head, .program-text { max-width: none; }
  .method-grid { padding-top: 2rem; }
  .letter { max-width: 26rem; margin-inline: auto; }
  .trail { max-width: 440px; width: 100%; margin-inline: auto; }
  .hero-visual { min-height: 0; padding-block: 1rem; }
}

@media (max-width: 560px) {
  .pricing { grid-template-columns: 1fr; }
  .hero-actions .btn { width: 100%; }
  .hero-mascot { width: 104px; inset-inline-end: 0; bottom: 0; }
  .phone, .phone-hero { width: min(68vw, 260px); }
  .moment { font-size: 0.98rem; margin-inline-end: 0 !important; min-height: 68px; }
  .moment img { width: 68px; height: 68px; }
  .partner-toggle { font-size: 0.95rem; text-align: start; }
  .extra-list div { flex-direction: column; gap: 0.2rem; }
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--bg-elev);
  border-top: 1px solid rgba(236, 210, 189, 0.7);
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.25rem 2rem;
  padding-block: 2rem;
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--primary);
}

/* Logo tinted peach via mask, so the cream SVG works on a light footer */
.footer-mark {
  width: 34px;
  height: 26px;
  background: var(--peach);
  -webkit-mask: url('../img/logo-heart.svg') center / contain no-repeat;
  mask: url('../img/logo-heart.svg') center / contain no-repeat;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  justify-content: center;
}

.footer-links a {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--ink-soft);
}

.footer-links a:hover {
  color: var(--primary);
  text-decoration: underline;
  text-underline-offset: 4px;
}

.footer-copy {
  flex-basis: 100%;
  font-size: 0.84rem;
  line-height: 1.7;
  color: var(--muted);
  padding-top: 1.25rem;
  border-top: 1px solid rgba(236, 210, 189, 0.6);
}

.footer-copy a { color: var(--primary); }

@media (max-width: 640px) {
  .footer-inner { flex-direction: column; text-align: center; }
}

/* ---------- Legal / Static page ---------- */
.legal {
  padding-block: clamp(3rem, 6vw, 5rem);
}

.legal-head {
  max-width: 780px;
  margin: 0 auto 3rem;
  text-align: center;
}

.legal-head .eyebrow { margin-bottom: 0.85rem; }

.legal-head h1 {
  font-size: clamp(2rem, 5vw, 3rem);
  color: var(--ink);
  font-weight: 800;
  margin: 0 0 0.85rem;
  letter-spacing: -0.025em;
  line-height: 1.1;
}

.legal-head p { color: var(--muted); }

.legal-body {
  max-width: 760px;
  margin: 0 auto;
  font-size: 1.0625rem;
  line-height: 1.75;
  color: var(--ink-soft);
}

.legal-body h2 {
  font-size: 1.5rem;
  color: var(--ink);
  margin: 2.5rem 0 1rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.legal-body h3 {
  font-size: 1.125rem;
  color: var(--ink);
  margin: 1.75rem 0 0.75rem;
  font-weight: 600;
}

.legal-body p { margin-bottom: 1rem; }

.legal-body ul {
  list-style: none;
  padding-inline-start: 0;
  margin: 1rem 0 1.5rem;
}

.legal-body ul li {
  position: relative;
  padding-inline-start: 1.6rem;
  margin-bottom: 0.6rem;
}

.legal-body ul li::before {
  content: '';
  position: absolute;
  inset-inline-start: 0;
  top: 0.85rem;
  width: 8px;
  height: 1px;
  background: var(--primary);
}

.legal-body strong { color: var(--ink); font-weight: 700; }

.legal-body a {
  color: var(--primary);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.legal-body a:hover { color: var(--primary-hover); }

.legal-body > ol { counter-reset: step; margin-bottom: 1.2rem; }
.legal-body > ol li {
  counter-increment: step;
  position: relative;
  padding-inline-start: 1.8rem;
  margin-bottom: 0.6rem;
}
.legal-body > ol li::before {
  content: counter(step) '.';
  position: absolute;
  inset-inline-start: 0;
  color: var(--primary);
  font-weight: 700;
}

.legal-toc {
  background: var(--bg-low);
  border: 1px solid rgba(236, 210, 189, 0.7);
  border-radius: var(--r-lg);
  padding: 1.5rem 1.75rem;
  margin-bottom: 2.5rem;
}

.legal-toc-title {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.85rem;
}

.legal-toc ol {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.5rem 1.5rem;
  counter-reset: toc;
}

.legal-toc ol li { counter-increment: toc; }

.legal-toc ol li a {
  display: flex;
  gap: 0.55rem;
  font-size: 0.96rem;
  color: var(--ink-soft);
  padding-block: 0.2rem;
}

.legal-toc ol li a::before {
  content: counter(toc, decimal-leading-zero);
  color: var(--primary);
  font-size: 0.85rem;
  font-weight: 700;
}

.legal-toc ol li a:hover { color: var(--ink); }

@media (max-width: 640px) {
  .legal-toc ol { grid-template-columns: 1fr; }
}

/* ---------- Contact ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
}

@media (max-width: 880px) { .contact-grid { grid-template-columns: 1fr; } }

.contact-info h1 {
  font-size: clamp(2rem, 4.5vw, 2.75rem);
  color: var(--ink);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.025em;
  margin: 0.85rem 0 1.25rem;
}

.contact-info > p {
  color: var(--ink-soft);
  font-size: 1.125rem;
  line-height: 1.55;
  margin-bottom: 2.5rem;
}

.contact-channels {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.contact-channel {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  background: var(--bg-elev);
  border: 1px solid rgba(236, 210, 189, 0.7);
  border-radius: var(--r-lg);
  transition: border-color var(--t-base), transform var(--t-fast);
}

.contact-channel:hover {
  border-color: var(--outline-soft);
  transform: translateY(-1px);
}

.contact-channel-icon {
  width: 44px; height: 44px;
  border-radius: var(--r-md);
  background: var(--bg-low);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  flex-shrink: 0;
}

.contact-channel-icon .material-symbols-outlined { font-size: 22px; }

.contact-channel .info {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.contact-channel .info span {
  font-size: 0.72rem;
  color: var(--muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 600;
}

.contact-channel .info a,
.contact-channel .info strong {
  font-size: 1.0625rem;
  color: var(--ink);
  font-weight: 600;
}

.contact-form {
  background: var(--bg-elev);
  border: 1px solid rgba(236, 210, 189, 0.7);
  border-radius: var(--r-xl);
  padding: clamp(1.75rem, 3vw, 2.5rem);
  box-shadow: var(--shadow-1);
}

.contact-form .field { margin-bottom: 1.25rem; }

.contact-form label {
  display: block;
  font-size: 0.8125rem;
  color: var(--ink);
  font-weight: 600;
  margin-bottom: 0.5rem;
  letter-spacing: 0.02em;
}

.contact-form input,
.contact-form textarea,
.contact-form select {
  width: 100%;
  background: var(--bg-low);
  border: 1px solid transparent;
  border-radius: var(--r-md);
  padding: 0.85rem 1rem;
  font-family: var(--font);
  font-size: 1rem;
  color: var(--ink);
  transition: border-color var(--t-fast), background var(--t-fast), box-shadow var(--t-fast);
}

.contact-form textarea {
  resize: vertical;
  min-height: 140px;
  line-height: 1.55;
}

.contact-form input:focus,
.contact-form textarea:focus,
.contact-form select:focus {
  outline: none;
  border-color: var(--primary);
  background: var(--bg-elev);
  box-shadow: 0 0 0 3px rgba(170, 122, 84, 0.16);
}

.contact-form .field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

@media (max-width: 540px) { .contact-form .field-row { grid-template-columns: 1fr; } }

.contact-form .submit {
  display: flex;
  justify-content: flex-start;
  margin-top: 0.5rem;
}

.contact-form-note {
  margin-top: 1.25rem;
  font-size: 0.875rem;
  color: var(--muted);
  line-height: 1.55;
}

/* ---------- Reveal animation ---------- */
.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity var(--t-slow), transform var(--t-slow);
}

.reveal.in {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; }
}

/* ============================================
   Accessibility (תקן ישראלי 5568 · WCAG 2.0 AA)
   ============================================ */

/* Skip to main content */
.a11y-skip {
  position: absolute;
  top: 0;
  inset-inline-start: 0;
  background: var(--ink);
  color: var(--bg);
  padding: 0.75rem 1.25rem;
  font-size: 1rem;
  font-weight: 700;
  border-radius: 0 0 var(--r-md) 0;
  z-index: 200;
  transform: translateY(-100%);
  transition: transform var(--t-base);
}

[dir="rtl"] .a11y-skip { border-radius: 0 0 0 var(--r-md); }

.a11y-skip:focus {
  transform: translateY(0);
  outline: 3px solid var(--primary-light);
  outline-offset: -3px;
  color: var(--bg);
}

/* Stronger focus outlines globally for keyboard users */
.a11y-focus-visible *:focus-visible,
body:not(.a11y-no-focus) *:focus-visible {
  outline: 3px solid var(--primary);
  outline-offset: 3px;
  border-radius: var(--r-sm);
}

/* ---- Accessibility widget ---- */
.a11y-widget {
  position: fixed;
  bottom: 1rem;
  inset-inline-end: 1rem;
  z-index: 90;
  font-family: var(--font);
}

.a11y-toggle {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--primary);
  color: var(--on-primary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 24px rgba(170, 122, 84, 0.35);
  border: 0;
  cursor: pointer;
  transition: background var(--t-base), transform var(--t-fast);
}

.a11y-toggle:hover { background: var(--primary-hover); }
.a11y-toggle:active { transform: scale(0.96); }
.a11y-toggle:focus-visible {
  outline: 3px solid var(--primary);
  outline-offset: 3px;
}

.a11y-toggle .material-symbols-outlined {
  font-size: 30px;
  font-variation-settings: 'FILL' 1, 'wght' 500;
}

.a11y-panel {
  position: absolute;
  bottom: calc(100% + 0.75rem);
  inset-inline-end: 0;
  width: min(340px, calc(100vw - 2rem));
  background: var(--bg-elev);
  border: 1px solid rgba(236, 210, 189, 0.7);
  border-radius: var(--r-xl);
  padding: 1.25rem;
  box-shadow: 0 16px 40px rgba(27, 28, 28, 0.18);
  opacity: 0;
  transform: translateY(8px) scale(0.97);
  transform-origin: bottom right;
  pointer-events: none;
  transition: opacity var(--t-base), transform var(--t-base);
  max-height: calc(100vh - 6rem);
  overflow-y: auto;
}

[dir="rtl"] .a11y-panel { transform-origin: bottom left; }

.a11y-widget.is-open .a11y-panel {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

.a11y-panel-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  padding-bottom: 0.85rem;
  border-bottom: 1px solid var(--bg-high);
}

.a11y-panel-head h3 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--ink);
  margin: 0;
  letter-spacing: -0.005em;
}

.a11y-panel-close {
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--r-sm);
  color: var(--ink-soft);
  cursor: pointer;
}

.a11y-panel-close:hover { background: var(--bg-low); color: var(--ink); }
.a11y-panel-close .material-symbols-outlined { font-size: 22px; }

.a11y-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-bottom: 1rem;
}

.a11y-group-label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

.a11y-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.4rem;
}

.a11y-opt {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.55rem;
  background: var(--bg-low);
  border: 1px solid transparent;
  border-radius: var(--r-md);
  font-family: var(--font);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--ink-soft);
  cursor: pointer;
  transition: background var(--t-fast), border-color var(--t-fast), color var(--t-fast);
}

.a11y-opt:hover {
  background: var(--bg-deep);
  color: var(--ink);
}

.a11y-opt.is-active {
  background: var(--primary-light);
  border-color: var(--primary);
  color: var(--primary-hover);
}

.a11y-opt .material-symbols-outlined { font-size: 18px; }

.a11y-toggle-row {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.a11y-switch {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.65rem 0.85rem;
  background: var(--bg-low);
  border: 1px solid transparent;
  border-radius: var(--r-md);
  font-family: var(--font);
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--ink);
  cursor: pointer;
  text-align: start;
  transition: background var(--t-fast), border-color var(--t-fast);
  width: 100%;
}

.a11y-switch:hover { background: var(--bg-deep); }

.a11y-switch[aria-pressed="true"] {
  background: var(--primary-light);
  border-color: var(--primary);
  color: var(--primary-hover);
}

.a11y-switch-label {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
}

.a11y-switch-label .material-symbols-outlined { font-size: 20px; color: var(--primary); }
.a11y-switch[aria-pressed="true"] .a11y-switch-label .material-symbols-outlined { color: var(--primary-hover); }

.a11y-switch-state {
  width: 32px;
  height: 18px;
  border-radius: 9999px;
  background: var(--outline-soft);
  position: relative;
  transition: background var(--t-fast);
  flex-shrink: 0;
}

.a11y-switch-state::after {
  content: '';
  position: absolute;
  top: 2px;
  inset-inline-end: 2px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--bg-elev);
  transition: transform var(--t-fast);
}

.a11y-switch[aria-pressed="true"] .a11y-switch-state { background: var(--primary); }
.a11y-switch[aria-pressed="true"] .a11y-switch-state::after { transform: translateX(14px); }
[dir="rtl"] .a11y-switch[aria-pressed="true"] .a11y-switch-state::after { transform: translateX(-14px); }

.a11y-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--bg-high);
}

.a11y-action {
  padding: 0.6rem 0.75rem;
  background: var(--bg-low);
  border-radius: var(--r-md);
  font-family: var(--font);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--ink);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  border: 1px solid transparent;
  transition: background var(--t-fast), color var(--t-fast);
}

.a11y-action:hover { background: var(--bg-deep); }
.a11y-action .material-symbols-outlined { font-size: 18px; }

.a11y-action.statement {
  background: var(--secondary-light);
  color: var(--secondary-deep);
}

.a11y-action.statement:hover { background: var(--peach-soft); color: var(--secondary-deep); }

/* ---- Body state classes ---- */

/* Font size scaling — multiplies root font-size */
body.a11y-font-1 { font-size: 18px; }
body.a11y-font-2 { font-size: 20px; }
body.a11y-font-3 { font-size: 22px; }

body.a11y-font-1 .display,
body.a11y-font-1 .display-xl { line-height: 1.2; }
body.a11y-font-2 .display,
body.a11y-font-2 .display-xl { line-height: 1.2; }
body.a11y-font-3 .display,
body.a11y-font-3 .display-xl { line-height: 1.2; }

/* High contrast mode */
body.a11y-contrast {
  --bg: #000000;
  --bg-elev: #000000;
  --bg-low: #0a0a0a;
  --bg-deep: #161616;
  --bg-high: #1f1f1f;
  --bg-variant: #2a2a2a;
  --ink: #ffffff;
  --ink-soft: #f1f1f1;
  --muted: #d0d0d0;
  --outline-soft: #ffffff;
  --primary: #ffd900;
  --primary-hover: #ffe44d;
  --primary-light: #1a1500;
  --on-primary: #000000;
  --secondary: #00ffff;
  --secondary-light: #002a2a;
  --secondary-deep: #00ffff;
  --tertiary: #ffffff;
}

body.a11y-contrast,
body.a11y-contrast * {
  background-image: none !important;
  text-shadow: none !important;
  box-shadow: none !important;
}

body.a11y-contrast .site-header,
body.a11y-contrast .site-footer,
body.a11y-contrast .method,
body.a11y-contrast .plan,
body.a11y-contrast .letter,
body.a11y-contrast .extra-card,
body.a11y-contrast .moment,
body.a11y-contrast .trail-tag,
body.a11y-contrast .contact-channel,
body.a11y-contrast .contact-form,
body.a11y-contrast .legal-toc {
  border: 2px solid var(--ink);
  background: var(--bg) !important;
}

body.a11y-contrast .moment { color: var(--ink); }

body.a11y-contrast .wash,
body.a11y-contrast .feature-scene { display: none; }

body.a11y-contrast .trail-bubble {
  background: var(--bg) !important;
  border: 2px solid var(--ink);
  border-radius: var(--r-md);
}

body.a11y-contrast a,
body.a11y-contrast a:hover { color: var(--primary); text-decoration: underline; }

body.a11y-contrast .btn-primary {
  background: var(--primary);
  color: var(--on-primary);
  border: 2px solid var(--ink);
}

body.a11y-contrast .btn-secondary,
body.a11y-contrast .btn-tonal {
  background: var(--bg);
  color: var(--ink);
  border: 2px solid var(--ink);
}


/* Grayscale */
body.a11y-grayscale {
  filter: grayscale(100%);
}

/* Underline all links */
body.a11y-underline-links a {
  text-decoration: underline !important;
  text-underline-offset: 3px;
}

/* Highlight links on hover/focus with strong background */
body.a11y-highlight-links a:hover,
body.a11y-highlight-links a:focus {
  background: var(--primary-light) !important;
  color: var(--primary-hover) !important;
  outline: 2px solid var(--primary);
}

/* Stop all animations */
body.a11y-no-motion *,
body.a11y-no-motion *::before,
body.a11y-no-motion *::after {
  animation-duration: 0.001ms !important;
  animation-iteration-count: 1 !important;
  transition-duration: 0.001ms !important;
  scroll-behavior: auto !important;
}

/* Readable font — fallback to system font with strong default sans-serif */
body.a11y-readable-font,
body.a11y-readable-font * {
  font-family: Arial, Helvetica, sans-serif !important;
  letter-spacing: 0.02em !important;
}

/* Larger cursor */
body.a11y-big-cursor,
body.a11y-big-cursor * {
  cursor: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='40' height='40' viewBox='0 0 40 40'><path d='M2 2 L2 30 L9 23 L13 35 L18 33 L14 21 L24 21 Z' fill='black' stroke='white' stroke-width='2'/></svg>"), auto !important;
}

body.a11y-big-cursor a,
body.a11y-big-cursor button,
body.a11y-big-cursor input,
body.a11y-big-cursor textarea,
body.a11y-big-cursor select,
body.a11y-big-cursor [role="button"],
body.a11y-big-cursor .nav-burger,
body.a11y-big-cursor .a11y-toggle {
  cursor: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='40' height='40' viewBox='0 0 40 40'><circle cx='20' cy='20' r='14' fill='black' stroke='white' stroke-width='2'/></svg>"), pointer !important;
}

/* Mobile widget adjustments */
@media (max-width: 540px) {
  .a11y-widget {
    bottom: 0.75rem;
    inset-inline-end: 0.75rem;
  }
  .a11y-toggle {
    width: 48px;
    height: 48px;
  }
  .a11y-toggle .material-symbols-outlined { font-size: 26px; }
}
