/* Pilates Planner site - glass look mirrored from the app (theme/Glass.kt, Palettes.kt) */
:root {
  --bg: #15111E;
  --fill: #7A5FB8;
  --accent: #D3C2FF;
  --surface: #201A2C;
  --card: rgba(240, 234, 250, .14);
  --text: #F1EEF7;
  --muted: #B9AECB;
  --peach: #FFC4A3;
  --glow-main: #9B7FD4;
  --glow-side: #C978AA;
  --glow-warm: #F0AA82;
  --edge: rgba(255, 214, 190, .7);
  --line: rgba(255, 255, 255, .25);
  --radius: 22px;
  --radius-sm: 14px;
  --maxw: 1120px;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }

body {
  margin: 0;
  font-family: "Heebo", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  overflow-x: hidden;
  transition: background-color .4s;
}

/* Radial glows behind everything, same placement as glassBackground() */
.glows {
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(circle at 85% 8%, color-mix(in srgb, var(--glow-main) 45%, transparent), transparent 45vmax),
    radial-gradient(circle at 5% 65%, color-mix(in srgb, var(--glow-side) 22%, transparent), transparent 40vmax),
    radial-gradient(circle at 70% 95%, color-mix(in srgb, var(--glow-main) 30%, transparent), transparent 45vmax),
    var(--bg);
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); }
a:focus-visible, button:focus-visible, summary:focus-visible {
  outline: 2px solid var(--peach); outline-offset: 3px; border-radius: 10px;
}

.skip {
  position: absolute; inset-inline-start: 16px; top: -60px; z-index: 50;
  background: var(--fill); color: #fff; padding: 10px 16px; border-radius: 12px;
}
.skip:focus { top: 12px; }

.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 16px; }

h1, h2, h3 { line-height: 1.2; margin: 0 0 .5em; font-weight: 700; }
h1 { font-size: clamp(2.2rem, 7vw, 3.6rem); letter-spacing: -.01em; }
h2 { font-size: clamp(1.6rem, 4.5vw, 2.3rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1em; }
.muted { color: var(--muted); }
.eyebrow { color: var(--peach); font-weight: 500; font-size: .95rem; margin-bottom: .4em; display: block; }

/* Glass card */
.glass {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  -webkit-backdrop-filter: blur(18px) saturate(1.2);
  backdrop-filter: blur(18px) saturate(1.2);
  box-shadow: 0 10px 40px rgba(0, 0, 0, .25);
}
.glass.hl {
  border-color: var(--edge);
  box-shadow: 0 0 12px color-mix(in srgb, var(--edge) 45%, transparent), 0 10px 40px rgba(0, 0, 0, .25);
}

/* Header */
.top {
  position: sticky; top: 0; z-index: 20;
  background: color-mix(in srgb, var(--bg) 70%, transparent);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(255, 255, 255, .08);
}
.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 60px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; font-weight: 700; font-size: 1.1rem; }
.brand svg { width: 32px; height: 32px; flex: none; }
.nav { display: none; gap: 20px; }
.nav a { color: var(--muted); text-decoration: none; font-size: .95rem; }
.nav a:hover { color: var(--text); }
@media (min-width: 860px) { .nav { display: flex; } }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 0 24px; border-radius: 999px;
  font: inherit; font-weight: 500; text-decoration: none; cursor: pointer;
  border: 1px solid transparent; transition: transform .15s, box-shadow .2s;
}
.btn-fill { background: var(--fill); color: #fff; box-shadow: 0 0 14px color-mix(in srgb, var(--fill) 55%, transparent); }
.btn-fill:hover { transform: translateY(-1px); }
.btn-ghost { background: transparent; color: var(--accent); border-color: color-mix(in srgb, var(--accent) 55%, transparent); }
.btn-sm { min-height: 40px; padding: 0 16px; font-size: .95rem; }

/* Sections */
section { padding: 64px 0; scroll-margin-top: 64px; }
.section-head { max-width: 680px; margin-bottom: 32px; }

/* Hero */
.hero { padding-top: 40px; }
.hero .wrap { display: grid; gap: 40px; align-items: center; }
@media (min-width: 900px) { .hero .wrap { grid-template-columns: 1.1fr .9fr; } }
.hero .lead { font-size: 1.2rem; color: var(--muted); max-width: 34em; }
.hero .lead strong { color: var(--text); font-weight: 500; }
.cta { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin: 24px 0 10px; }
.note { font-size: .9rem; color: var(--peach); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 22px 0 0; padding: 0; list-style: none; }
.chips li {
  font-size: .9rem; padding: 4px 12px; border-radius: 999px;
  background: color-mix(in srgb, var(--fill) 30%, transparent); color: var(--accent);
  border: 1px solid rgba(255, 255, 255, .12);
}

/* Phone frames */
.phones { display: flex; justify-content: center; gap: 18px; align-items: flex-end; }
.phone {
  width: min(250px, 62vw); aspect-ratio: 1080 / 2520; flex: none;
  border-radius: 34px; padding: 9px; position: relative;
  background: linear-gradient(160deg, #3a3346, #17131f);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .18), 0 30px 60px rgba(0, 0, 0, .45),
              0 0 50px color-mix(in srgb, var(--glow-main) 35%, transparent);
}
.phone img, .phone .screen { width: 100%; height: 100%; object-fit: cover; object-position: top; border-radius: 26px; }
.phone.small { width: min(200px, 44vw); }
.phones .phone.small { display: none; }
@media (min-width: 560px) { .phones .phone.small { display: block; } }
figure { margin: 0; }
figcaption { text-align: center; color: var(--muted); font-size: .9rem; margin-top: 12px; }

/* Feature grid */
.grid { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 620px) { .grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 960px) { .grid.three { grid-template-columns: repeat(3, 1fr); } }
.card { padding: 22px; }
.card p { color: var(--muted); margin: 0; }
.icon {
  width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; margin-bottom: 14px;
  background: color-mix(in srgb, var(--fill) 35%, transparent); color: var(--accent);
}
.icon svg { width: 24px; height: 24px; }

/* Exercise gallery: white illustrations on light plates, as in the app */
.gallery { display: grid; gap: 14px; grid-template-columns: repeat(2, 1fr); margin-top: 28px; }
@media (min-width: 720px) { .gallery { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1000px) { .gallery { grid-template-columns: repeat(4, 1fr); } }
.ex { padding: 10px; }
.ex .plate { background: #fff; border-radius: var(--radius-sm); aspect-ratio: 4 / 3; display: grid; place-items: center; overflow: hidden; }
.ex .plate img { max-height: 100%; object-fit: contain; }
.ex figcaption { margin-top: 8px; text-align: start; color: var(--text); font-size: .95rem; }
.ex figcaption span { display: block; color: var(--muted); font-size: .82rem; }

/* Split layout: text + phone */
.split { display: grid; gap: 36px; align-items: center; }
@media (min-width: 900px) { .split { grid-template-columns: 1fr 1fr; } .split.rev > :first-child { order: 2; } }

/* Steps list */
.steps { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; counter-reset: s; }
.steps li { padding: 16px 18px 16px 18px; padding-inline-start: 62px; position: relative; }
.steps li::before {
  counter-increment: s; content: counter(s);
  position: absolute; inset-inline-start: 16px; top: 16px;
  width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center;
  background: var(--fill); color: #fff; font-weight: 700; font-size: .95rem;
}
.steps strong { display: block; }
.steps span { color: var(--muted); }

/* Apparatus row */
.apparatus { display: flex; flex-wrap: wrap; gap: 10px; padding: 0; margin: 0 0 24px; list-style: none; }
.apparatus li { padding: 8px 16px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); }

/* Teaching mode */
.teach-bg { position: relative; }
.teach-bg::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(circle at 50% 22%, color-mix(in srgb, var(--glow-warm) 22%, transparent), transparent 55%);
}
.ticks { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.ticks li { position: relative; padding-inline-start: 26px; color: var(--muted); }
.ticks li::before { content: "•"; position: absolute; inset-inline-start: 6px; color: var(--peach); font-weight: 700; }
.ticks li strong { color: var(--text); font-weight: 500; }

/* Privacy */
.privacy { padding: 28px; display: grid; gap: 24px; }
@media (min-width: 800px) { .privacy { grid-template-columns: repeat(3, 1fr); } }
.privacy h3 { color: var(--accent); }
.privacy p { color: var(--muted); margin: 0; }

/* FAQ */
.faq { display: grid; gap: 12px; max-width: 820px; }
.faq details { padding: 0; }
.faq summary {
  cursor: pointer; list-style: none; padding: 18px 22px; font-weight: 500; font-size: 1.05rem;
  display: flex; justify-content: space-between; gap: 12px; align-items: center;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--peach); font-size: 1.4rem; line-height: 1; flex: none; }
.faq details[open] summary::after { content: "−"; }
.faq details p { padding: 0 22px 18px; margin: 0; color: var(--muted); }

/* Download */
.download { text-align: center; padding: 36px 22px; }
.download .cta { justify-content: center; }

/* Palette switcher */
.palette { display: flex; align-items: center; gap: 8px; }
.palette .lbl { font-size: .85rem; color: var(--muted); display: none; }
@media (min-width: 480px) { .palette .lbl { display: inline; } }
.swatch {
  width: 28px; height: 28px; border-radius: 50%; padding: 0; cursor: pointer;
  border: 2px solid rgba(255, 255, 255, .25); background: var(--sw);
  box-shadow: inset 0 0 0 3px var(--sw-bg);
}
.swatch[aria-pressed="true"] { border-color: var(--peach); box-shadow: inset 0 0 0 3px var(--sw-bg), 0 0 10px var(--sw); }
.palette-big { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.palette-big .swatch { width: auto; height: 40px; border-radius: 999px; padding: 0 16px 0 10px; color: var(--text); font: inherit; font-size: .92rem;
  display: inline-flex; align-items: center; gap: 8px; background: var(--surface); box-shadow: none; }
.palette-big .swatch i { width: 18px; height: 18px; border-radius: 50%; background: var(--sw); display: inline-block; }

/* Footer */
footer { padding: 36px 0 48px; border-top: 1px solid rgba(255, 255, 255, .08); color: var(--muted); font-size: .92rem; }
.notice { margin: 18px 0 0; padding: 14px 18px; font-size: .95rem; line-height: 1.6; color: var(--muted); border-inline-start: 3px solid var(--peach); }
.notice strong { color: var(--peach); }
footer .foot-note { flex: 1 1 320px; text-align: center; }
footer .wrap { display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between; align-items: center; }

.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Scripts Heebo lacks: Cyrillic and Arabic */
html[lang="ru"] body { font-family: "Rubik", system-ui, -apple-system, "Segoe UI", Arial, sans-serif; }
html[lang="ar"] body { font-family: "Noto Sans Arabic", "Heebo", system-ui, -apple-system, "Segoe UI", Arial, sans-serif; }

/* Header tools: colours + language */
.tools { display: flex; align-items: center; gap: 14px; }
@media (max-width: 559px) { .top .palette { display: none; } }
.langs { position: relative; }
.langs summary {
  list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 6px;
  min-height: 34px; padding: 0 12px; border-radius: 999px; font-size: .88rem;
  color: var(--text); border: 1px solid var(--line); background: color-mix(in srgb, var(--surface) 70%, transparent);
}
.langs summary::-webkit-details-marker { display: none; }
.langs summary svg { width: 16px; height: 16px; color: var(--accent); }
.langs ul {
  position: absolute; inset-inline-end: 0; top: calc(100% + 8px); z-index: 30; margin: 0; padding: 6px;
  list-style: none; min-width: 150px; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius-sm); box-shadow: 0 14px 40px rgba(0, 0, 0, .4);
}
.langs a { display: block; padding: 7px 12px; border-radius: 10px; color: var(--text); text-decoration: none; font-size: .95rem; }
.langs a:hover { background: color-mix(in srgb, var(--fill) 30%, transparent); }
.langs a[aria-current="page"] { color: var(--peach); }

/* Plans */
.plans .card { display: flex; flex-direction: column; gap: 10px; }
.plans .price { color: var(--peach); font-weight: 500; margin: 0; }
.plans .ticks { margin: 4px 0 6px; }
.plans .cta { margin: auto 0 0; }
