/* BattaFit — low-stim, mobile-first, WCAG 2.2 AA */
:root {
  --bg: #0f1720;
  --panel: #16212c;
  --panel-2: #1c2a37;
  --ink: #e8eef2;
  --mute: #9fb1bd;
  --teal: #4fd1b5;
  --teal-deep: #2e7d6b;
  --line: #26384a;
  --radius: 16px;
  --maxw: 860px;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
body {
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.6;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--teal); }

/* header */
.top {
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 20px; max-width: var(--maxw); margin: 0 auto;
}
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 1.25rem; letter-spacing: .3px; }
.logo { width: 30px; height: 30px; color: var(--teal); }
.top-cta {
  text-decoration: none; color: var(--ink); background: var(--panel-2);
  border: 1px solid var(--line); padding: 10px 16px; border-radius: 999px;
  font-size: .92rem; min-height: 44px; display: inline-flex; align-items: center;
}
.top-cta:hover { border-color: var(--teal-deep); }

main { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }

/* hero / tool */
.hero { text-align: center; padding: 44px 0 30px; }
.hero h1 { font-size: clamp(1.8rem, 5.5vw, 2.7rem); line-height: 1.2; letter-spacing: -.5px; }
.hero .sub { color: var(--mute); max-width: 34em; margin: 14px auto 30px; }
.hero .sub strong { color: var(--ink); }

.battery-row { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.batt {
  background: var(--panel); color: var(--ink); border: 2px solid var(--line);
  border-radius: var(--radius); cursor: pointer;
  width: clamp(86px, 17vw, 128px); min-height: 92px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px;
  font-size: 1rem; font-weight: 600; font-family: inherit;
  transition: border-color .15s, transform .15s;
}
.batt svg { width: 46px; height: 26px; color: var(--teal); }
.batt:hover { border-color: var(--teal-deep); transform: translateY(-2px); }
.batt:focus-visible, .chip:focus-visible, .go:focus-visible, button:focus-visible, input:focus-visible {
  outline: 3px solid var(--teal); outline-offset: 2px;
}
.batt.sel { border-color: var(--teal); background: var(--panel-2); }

.prefs { margin-top: 26px; }
.prefs-label { color: var(--mute); margin-bottom: 12px; }
.prefs-label .opt { font-size: .85rem; opacity: .8; }
.chip-row { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-bottom: 22px; }
.chip {
  background: var(--panel); color: var(--ink); border: 1.5px solid var(--line);
  padding: 10px 16px; border-radius: 999px; cursor: pointer; font-size: .95rem;
  min-height: 44px; font-family: inherit;
}
.chip.sel { border-color: var(--teal); background: var(--panel-2); }
.go {
  background: var(--teal); color: #08251d; border: none; cursor: pointer;
  font-size: 1.15rem; font-weight: 700; font-family: inherit;
  padding: 16px 34px; border-radius: 999px; min-height: 56px;
}
.go:hover { filter: brightness(1.08); }

/* result card */
.result { margin: 30px auto 0; max-width: 560px; text-align: left; }
.routine {
  background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 26px;
}
.routine h2 { font-size: 1.35rem; margin-bottom: 4px; }
.routine .meta { color: var(--mute); font-size: .95rem; margin-bottom: 18px; }
.move {
  display: flex; align-items: flex-start; gap: 14px;
  padding: 14px 0; border-top: 1px solid var(--line);
}
.move .n {
  background: var(--panel-2); color: var(--teal); font-weight: 700;
  min-width: 40px; height: 40px; border-radius: 12px;
  display: flex; align-items: center; justify-content: center; font-size: .95rem;
}
.move .txt strong { display: block; }
.move .txt span { color: var(--mute); font-size: .93rem; }
.move .swap {
  margin-left: auto; background: none; border: 1px solid var(--line); color: var(--mute);
  border-radius: 10px; min-width: 44px; min-height: 44px; cursor: pointer; font-size: 1.05rem;
}
.move .swap:hover { border-color: var(--teal-deep); color: var(--ink); }
.routine .actions { display: flex; gap: 10px; margin-top: 20px; flex-wrap: wrap; }
.routine .actions button {
  flex: 1; min-width: 140px; min-height: 52px; border-radius: 12px; cursor: pointer;
  font-size: 1rem; font-weight: 600; font-family: inherit;
}
.btn-primary { background: var(--teal); color: #08251d; border: none; }
.btn-ghost { background: none; color: var(--ink); border: 1.5px solid var(--line); }
.btn-ghost:hover { border-color: var(--teal-deep); }
.rest-card { text-align: center; }
.rest-card .big { font-size: 1.5rem; font-weight: 700; margin-bottom: 8px; }
.done-note {
  text-align: center; background: var(--panel-2); border-radius: 12px;
  padding: 14px; margin-top: 16px; color: var(--teal); font-weight: 600;
}

/* why */
.why { padding: 50px 0 10px; }
.why h2, .waitlist h2 { text-align: center; font-size: 1.6rem; margin-bottom: 26px; }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 16px; }
.card {
  background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 22px;
}
.card h3 { font-size: 1.05rem; margin-bottom: 8px; color: var(--teal); }
.card p { color: var(--mute); font-size: .95rem; }

/* waitlist */
.waitlist { padding: 56px 0 30px; text-align: center; }
.waitlist > p { color: var(--mute); max-width: 38em; margin: 0 auto 24px; }
#wl-form { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
#wl-form input {
  background: var(--panel); border: 1.5px solid var(--line); color: var(--ink);
  border-radius: 12px; padding: 14px 16px; font-size: 1rem; font-family: inherit;
  min-width: min(320px, 80vw); min-height: 52px;
}
#wl-form button {
  background: var(--teal); color: #08251d; border: none; border-radius: 12px;
  padding: 14px 24px; font-size: 1rem; font-weight: 700; cursor: pointer;
  min-height: 52px; font-family: inherit;
}
.wl-note { color: var(--mute); font-size: .85rem; margin-top: 12px; }
.wl-note.ok { color: var(--teal); font-weight: 600; }
.wl-note.err { color: #e8a06a; }

footer { text-align: center; color: var(--mute); font-size: .85rem; padding: 40px 20px 30px; }
footer .disclaimer { font-size: .75rem; opacity: .75; margin-top: 8px; max-width: 46em; margin-left: auto; margin-right: auto; }

.visually-hidden {
  position: absolute; width: 1px; height: 1px; margin: -1px;
  clip-path: inset(50%); overflow: hidden; white-space: nowrap;
}
