:root {
  color-scheme: dark;
  --ink: #fffaf4;
  --muted: #c9bfdf;
  --purple-950: #100824;
  --purple-900: #180d35;
  --purple-800: #25124f;
  --purple-700: #3d1f72;
  --purple-500: #7847e7;
  --violet: #a77bff;
  --lime: #d9ff4f;
  --lime-deep: #9fd21e;
  --pink: #ff5ba5;
  --cyan: #55e6e2;
  --red: #ff6a70;
  --card: rgba(255, 255, 255, 0.075);
  --card-strong: rgba(255, 255, 255, 0.12);
  --line: rgba(255, 255, 255, 0.14);
  --shadow: 0 24px 70px rgba(5, 1, 18, 0.42);
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  font-family: Inter, ui-rounded, "SF Pro Rounded", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

html {
  min-height: 100%;
  background: #0d061e;
}

body {
  min-width: min(320px, 100%);
  min-height: 100dvh;
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 15% 0%, rgba(122, 71, 231, 0.42), transparent 38rem),
    radial-gradient(circle at 100% 70%, rgba(85, 230, 226, 0.14), transparent 35rem),
    #0d061e;
  -webkit-font-smoothing: antialiased;
  overscroll-behavior: none;
}

button,
input,
select,
textarea { font: inherit; }

button { -webkit-tap-highlight-color: transparent; }

button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid rgba(217, 255, 79, 0.9);
  outline-offset: 2px;
}

[hidden] { display: none !important; }

.app-shell {
  position: relative;
  width: min(100%, 680px);
  min-height: 100dvh;
  margin: 0 auto;
  overflow: hidden;
  background:
    linear-gradient(155deg, rgba(255, 255, 255, 0.045), transparent 27%),
    linear-gradient(180deg, var(--purple-800), var(--purple-950));
  box-shadow: var(--shadow);
}

.screen {
  position: relative;
  display: flex;
  min-height: 100dvh;
  flex-direction: column;
  isolation: isolate;
}

.screen::before {
  position: fixed;
  z-index: -1;
  width: 300px;
  height: 300px;
  border-radius: 50%;
  background: rgba(118, 71, 231, 0.3);
  content: "";
  filter: blur(70px);
  inset: -120px auto auto calc(50% - 260px);
  pointer-events: none;
}

.screen--home {
  align-items: center;
  padding: calc(var(--safe-top) + 22px) 20px calc(var(--safe-bottom) + 22px);
  text-align: center;
}

.home-top {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: space-between;
}

.mini-logo {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--ink);
  font-size: .78rem;
  font-weight: 900;
  letter-spacing: .13em;
}

.mini-logo__mark {
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 11px;
  background: var(--lime);
  color: #26123f;
  font-size: 1.2rem;
  box-shadow: 0 7px 20px rgba(217, 255, 79, .2);
}

.help-button {
  display: grid;
  width: 40px;
  height: 40px;
  padding: 0;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--ink);
  background: var(--card);
  font-weight: 900;
  cursor: pointer;
}

.hero {
  display: flex;
  width: 100%;
  max-width: 500px;
  flex: 1;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 32px 0 24px;
}

.hero-symbol {
  position: relative;
  display: grid;
  width: clamp(124px, 38vw, 178px);
  aspect-ratio: 1;
  margin-bottom: 23px;
  place-items: center;
  transform: rotate(-5deg);
  border: 2px solid rgba(255, 255, 255, .32);
  border-radius: 38% 62% 54% 46% / 47% 41% 59% 53%;
  background:
    radial-gradient(circle at 28% 25%, rgba(255,255,255,.35), transparent 18%),
    linear-gradient(145deg, var(--lime), #9edb26);
  color: #281140;
  font-size: clamp(5.3rem, 24vw, 8.2rem);
  font-weight: 1000;
  line-height: 1;
  box-shadow: 0 20px 50px rgba(7, 2, 21, .45), inset -12px -14px 0 rgba(73, 80, 0, .11);
}

.hero-symbol::before,
.hero-symbol::after {
  position: absolute;
  z-index: -1;
  width: 35px;
  height: 35px;
  border: 5px solid var(--pink);
  border-radius: 12px;
  content: "";
}

.hero-symbol::before { top: 4px; right: -32px; transform: rotate(22deg); }
.hero-symbol::after { bottom: 7px; left: -36px; border-color: var(--cyan); border-radius: 50%; }

.eyebrow {
  margin: 0 0 7px;
  color: var(--lime);
  font-size: .69rem;
  font-weight: 950;
  letter-spacing: .18em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p { overflow-wrap: anywhere; }

h1 {
  margin: 0;
  font-size: clamp(3.2rem, 15vw, 5.2rem);
  font-weight: 1000;
  letter-spacing: -.075em;
  line-height: .88;
  text-transform: uppercase;
}

h1 span { color: var(--lime); }

h2 {
  margin: 0;
  font-size: clamp(1.65rem, 7vw, 2.35rem);
  font-weight: 950;
  letter-spacing: -.04em;
  line-height: 1.05;
}

h3 { margin: 0; font-size: 1.05rem; }

.hero__lead {
  max-width: 420px;
  margin: 16px 0 0;
  color: var(--muted);
  font-size: clamp(.96rem, 3.9vw, 1.08rem);
  line-height: 1.5;
}

.home-actions {
  display: grid;
  width: 100%;
  max-width: 460px;
  gap: 10px;
}

.feature-row {
  display: flex;
  margin-top: 18px;
  flex-wrap: wrap;
  justify-content: center;
  gap: 7px;
  color: var(--muted);
  font-size: .7rem;
  font-weight: 850;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.feature-row span {
  padding: 7px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255,255,255,.035);
}

.topbar,
.gamebar {
  display: grid;
  min-height: calc(var(--safe-top) + 78px);
  padding: calc(var(--safe-top) + 14px) 16px 12px;
  align-items: center;
  grid-template-columns: 44px minmax(0, 1fr) 44px;
  gap: 9px;
  border-bottom: 1px solid rgba(255,255,255,.08);
  background: rgba(15, 7, 34, .34);
  backdrop-filter: blur(18px);
}

.topbar > div { min-width: 0; text-align: center; }
.topbar .eyebrow { margin-bottom: 3px; font-size: .6rem; }
.topbar h2 { font-size: 1.15rem; letter-spacing: -.02em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.gamebar {
  grid-template-columns: 44px minmax(0, 1fr) auto;
}

.round-pill,
.step-pill {
  justify-self: center;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--card);
  color: var(--muted);
  font-size: .69rem;
  font-weight: 900;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.step-pill { min-width: 42px; color: var(--ink); text-align: center; }

.icon-button {
  display: grid;
  width: 42px;
  height: 42px;
  padding: 0;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 14px;
  color: var(--ink);
  background: var(--card);
  font-size: 1.3rem;
  font-weight: 850;
  cursor: pointer;
}

.icon-button--blank { opacity: 0; pointer-events: none; }

.content {
  display: flex;
  width: 100%;
  max-width: 580px;
  margin: 0 auto;
  flex: 1;
  flex-direction: column;
  padding: 22px 16px calc(var(--safe-bottom) + 110px);
}

.content--center {
  align-items: stretch;
  justify-content: center;
  padding-bottom: calc(var(--safe-bottom) + 26px);
}

.content--result { padding-bottom: calc(var(--safe-bottom) + 28px); }

.intro-card,
.settings-card,
.panel,
.privacy-card,
.role-card,
.clue-card,
.ballot-card,
.result-card,
.score-card {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: linear-gradient(145deg, rgba(255,255,255,.11), rgba(255,255,255,.05));
  box-shadow: 0 16px 35px rgba(7, 2, 23, .2);
}

.intro-card {
  display: grid;
  margin-bottom: 18px;
  padding: 14px 15px;
  grid-template-columns: auto 1fr;
  gap: 12px;
  color: var(--muted);
  font-size: .83rem;
  line-height: 1.4;
  text-align: left;
}

.intro-card__icon {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 13px;
  background: rgba(217, 255, 79, .14);
  font-size: 1.1rem;
}

.intro-card b { display: block; margin-bottom: 2px; color: var(--ink); }

.section-head {
  display: flex;
  margin: 7px 2px 10px;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.section-head h3 { font-size: .85rem; letter-spacing: .07em; text-transform: uppercase; }
.section-head span { color: var(--muted); font-size: .77rem; }

.player-list { display: grid; gap: 8px; }

.player-row {
  display: grid;
  align-items: center;
  grid-template-columns: 39px minmax(0, 1fr) 39px;
  gap: 8px;
}

.player-number {
  display: grid;
  width: 39px;
  height: 39px;
  place-items: center;
  border-radius: 13px;
  background: var(--card-strong);
  color: var(--lime);
  font-size: .79rem;
  font-weight: 950;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 14px;
  color: var(--ink);
  background: rgba(9, 4, 24, .45);
}

input,
select { min-height: 47px; padding: 0 13px; }
textarea { min-height: 140px; padding: 13px; resize: vertical; line-height: 1.45; }
input::placeholder,
textarea::placeholder { color: #8f83a8; }
select option { color: #1c1036; background: white; }

.remove-player {
  display: grid;
  width: 39px;
  height: 39px;
  padding: 0;
  place-items: center;
  border: 0;
  border-radius: 13px;
  color: var(--muted);
  background: transparent;
  font-size: 1.25rem;
  cursor: pointer;
}

.remove-player:disabled { opacity: .25; cursor: default; }

.settings-card { margin-top: 22px; padding: 5px 14px 15px; }
.settings-card legend { padding: 0 8px; color: var(--lime); font-size: .73rem; font-weight: 950; letter-spacing: .11em; text-transform: uppercase; }

.setting { padding: 13px 0; border-bottom: 1px solid rgba(255,255,255,.08); }
.setting:last-child { border-bottom: 0; }
.setting__head { display: flex; margin-bottom: 9px; align-items: center; justify-content: space-between; gap: 10px; }
.setting__head b { font-size: .9rem; }
.setting__head span { color: var(--muted); font-size: .75rem; }

.segments {
  display: grid;
  padding: 4px;
  grid-auto-columns: 1fr;
  grid-auto-flow: column;
  gap: 4px;
  border-radius: 15px;
  background: rgba(6, 2, 18, .38);
}

.segments button {
  min-height: 39px;
  padding: 6px 7px;
  border: 0;
  border-radius: 11px;
  color: var(--muted);
  background: transparent;
  font-size: .76rem;
  font-weight: 850;
  cursor: pointer;
}

.segments button.is-active {
  color: #25123c;
  background: var(--lime);
  box-shadow: 0 5px 15px rgba(217, 255, 79, .16);
}

.category-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; }

.sticky-footer {
  position: fixed;
  z-index: 4;
  bottom: 0;
  left: 50%;
  display: grid;
  width: min(100%, 680px);
  padding: 11px 16px calc(var(--safe-bottom) + 13px);
  transform: translateX(-50%);
  border-top: 1px solid rgba(255,255,255,.09);
  background: linear-gradient(180deg, rgba(19, 9, 43, .82), #160a31 30%);
  backdrop-filter: blur(18px);
}

.btn {
  min-height: 48px;
  padding: 11px 16px;
  border: 1px solid transparent;
  border-radius: 16px;
  font-weight: 950;
  letter-spacing: -.01em;
  cursor: pointer;
  transition: transform .15s ease, filter .15s ease, background .15s ease;
}

.btn:active { transform: translateY(2px) scale(.99); }
.btn:disabled { opacity: .42; cursor: default; transform: none; }
.btn--primary { color: #24113e; background: var(--lime); box-shadow: 0 10px 28px rgba(171, 223, 36, .19); }
.btn--primary:not(:disabled):hover { filter: brightness(1.05); }
.btn--soft { border-color: var(--line); color: var(--ink); background: var(--card-strong); }
.btn--outline { border-color: rgba(217,255,79,.35); color: var(--lime); background: transparent; }
.btn--wide { width: 100%; }
.btn--xl { min-height: 58px; border-radius: 18px; font-size: 1rem; }
.btn--small { min-height: 42px; padding-inline: 12px; font-size: .78rem; }

.text-button {
  padding: 10px;
  border: 0;
  color: var(--muted);
  background: transparent;
  font-size: .83rem;
  font-weight: 800;
  text-decoration: underline;
  text-decoration-color: rgba(255,255,255,.26);
  text-underline-offset: 4px;
  cursor: pointer;
}
.text-button--danger { color: #ff9298; }

.form-error { min-height: 1.2em; margin: 7px 2px; color: #ff9ba1; font-size: .78rem; }

.privacy-card,
.role-card,
.ballot-card {
  padding: clamp(22px, 7vw, 34px) 18px;
  text-align: center;
}

.avatar {
  display: grid;
  width: 76px;
  height: 76px;
  margin: 0 auto 18px;
  place-items: center;
  border: 2px solid rgba(255,255,255,.2);
  border-radius: 25px;
  background: linear-gradient(145deg, rgba(167,123,255,.42), rgba(85,230,226,.13));
  font-size: 2.5rem;
  box-shadow: 0 16px 34px rgba(5,2,18,.25);
}

.privacy-card h2,
.role-card h2,
.ballot-card h2 { margin-bottom: 12px; }
.privacy-card p:not(.eyebrow),
.role-card p:not(.eyebrow),
.ballot-card p:not(.eyebrow) { margin: 0 auto 22px; color: var(--muted); line-height: 1.48; }

.privacy-lock {
  display: inline-flex;
  margin-bottom: 16px;
  padding: 7px 11px;
  align-items: center;
  gap: 7px;
  border-radius: 999px;
  color: var(--muted);
  background: rgba(0,0,0,.2);
  font-size: .7rem;
  font-weight: 850;
  text-transform: uppercase;
}

.secret-label {
  display: inline-flex;
  margin: 3px 0 17px;
  padding: 8px 12px;
  border-radius: 999px;
  color: #221138;
  background: var(--lime);
  font-size: .7rem;
  font-weight: 1000;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.secret-label--imposter { color: white; background: var(--pink); }

.word-card {
  margin: 12px 0 20px;
  padding: 19px 12px;
  border: 1px solid rgba(217,255,79,.35);
  border-radius: 19px;
  background: rgba(217,255,79,.08);
}

.word-card small { display: block; margin-bottom: 5px; color: var(--muted); font-size: .7rem; font-weight: 850; text-transform: uppercase; }
.word-card strong { color: var(--lime); font-size: clamp(1.55rem, 7vw, 2.4rem); line-height: 1.05; }
.role-card--secret .word-card { border-color: rgba(255,91,165,.38); background: rgba(255,91,165,.08); }
.role-card--secret .word-card strong { color: #ff91c4; }

.clue-card { overflow: hidden; }
.clue-hero { padding: 24px 20px; text-align: center; background: linear-gradient(145deg, rgba(217,255,79,.13), rgba(85,230,226,.07)); }
.clue-hero h2 { margin: 6px 0 9px; }
.clue-hero p { margin: 0; color: var(--muted); line-height: 1.5; }
.starter { display: flex; margin: 19px auto 0; align-items: center; justify-content: center; gap: 9px; font-weight: 900; }
.starter span { display: grid; width: 40px; height: 40px; place-items: center; border-radius: 14px; background: var(--card-strong); font-size: 1.35rem; }

.clue-body { padding: 19px; }
.clue-tips { display: grid; margin: 0 0 17px; padding: 0; gap: 8px; list-style: none; }
.clue-tips li { display: flex; align-items: flex-start; gap: 10px; color: var(--muted); font-size: .85rem; line-height: 1.4; }
.clue-tips li::before { flex: 0 0 auto; color: var(--lime); content: "◆"; font-size: .55rem; transform: translateY(.34rem); }

.timer {
  display: grid;
  width: 132px;
  height: 132px;
  margin: 8px auto 19px;
  place-items: center;
  border-radius: 50%;
  background: conic-gradient(var(--lime) calc(var(--progress, 1) * 1turn), rgba(255,255,255,.1) 0);
  box-shadow: 0 12px 28px rgba(7,2,23,.25);
}
.timer::before { position: absolute; width: 110px; height: 110px; border-radius: 50%; background: #291554; content: ""; }
.timer__value { position: relative; z-index: 1; text-align: center; }
.timer__value strong { display: block; font-size: 2.25rem; line-height: 1; }
.timer__value span { color: var(--muted); font-size: .67rem; font-weight: 850; text-transform: uppercase; }
.timer--done { animation: timer-pulse 1s ease-in-out infinite; }

.clue-actions { display: grid; gap: 9px; }

.ballot-grid,
.word-grid {
  display: grid;
  margin: 20px 0;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.ballot-grid button,
.word-grid button {
  display: flex;
  min-width: 0;
  min-height: 66px;
  padding: 10px;
  align-items: center;
  gap: 9px;
  border: 1px solid var(--line);
  border-radius: 16px;
  color: var(--ink);
  background: var(--card);
  font-size: .82rem;
  font-weight: 850;
  text-align: left;
  cursor: pointer;
}

.ballot-grid button span:first-child { flex: 0 0 auto; font-size: 1.35rem; }
.ballot-grid button span:last-child,
.word-grid button span { min-width: 0; overflow-wrap: anywhere; }
.ballot-grid button.is-selected,
.word-grid button.is-selected { border-color: var(--lime); color: #27123e; background: var(--lime); }

.word-grid button { justify-content: center; text-align: center; }
.word-grid button.word-grid__skip { grid-column: 1 / -1; min-height: 48px; color: var(--muted); }
.word-grid button.word-grid__skip.is-selected { color: #27123e; }

.result-card { padding: 22px 17px; text-align: center; }
.result-icon { display: grid; width: 82px; height: 82px; margin: 0 auto 14px; place-items: center; border-radius: 28px; background: rgba(217,255,79,.14); font-size: 2.55rem; }
.result-icon--escape { background: rgba(255,91,165,.16); }
.result-card > p:not(.eyebrow) { color: var(--muted); line-height: 1.5; }
.reveal-word { margin: 17px 0; padding: 16px; border-radius: 18px; background: rgba(0,0,0,.2); }
.reveal-word span { display: block; margin-bottom: 4px; color: var(--muted); font-size: .66rem; font-weight: 850; letter-spacing: .1em; text-transform: uppercase; }
.reveal-word strong { color: var(--lime); font-size: 1.65rem; }

.result-list { display: grid; margin: 18px 0; gap: 8px; text-align: left; }
.result-row { display: grid; padding: 11px 12px; align-items: center; grid-template-columns: 33px minmax(0,1fr) auto; gap: 9px; border: 1px solid rgba(255,255,255,.08); border-radius: 14px; background: rgba(0,0,0,.13); }
.result-row__avatar { font-size: 1.25rem; }
.result-row b { display: block; font-size: .84rem; }
.result-row small { color: var(--muted); }
.delta { color: var(--lime); font-size: .84rem; font-weight: 950; }
.delta--zero { color: var(--muted); }
.result-actions { display: grid; gap: 8px; }

.score-list { display: grid; gap: 9px; }
.score-row { display: grid; padding: 12px 13px; align-items: center; grid-template-columns: 30px 42px minmax(0,1fr) auto; gap: 9px; border: 1px solid var(--line); border-radius: 17px; background: var(--card); }
.score-row:first-child { border-color: rgba(217,255,79,.38); background: rgba(217,255,79,.09); }
.score-row__place { color: var(--muted); font-size: .78rem; font-weight: 900; }
.score-row__avatar { font-size: 1.45rem; }
.score-row b { display: block; }
.score-row small { color: var(--muted); }
.score-row strong { color: var(--lime); font-size: 1.15rem; }
.score-card { margin-top: 17px; padding: 15px; }
.stat-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 8px; }
.stat { padding: 13px 9px; border-radius: 14px; background: rgba(0,0,0,.18); text-align: center; }
.stat strong { display: block; color: var(--lime); font-size: 1.35rem; }
.stat span { color: var(--muted); font-size: .7rem; font-weight: 800; text-transform: uppercase; }

.sheet {
  width: min(calc(100% - 24px), 560px);
  max-height: min(88dvh, 760px);
  padding: 0;
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 28px;
  color: var(--ink);
  background: #25134d;
  box-shadow: 0 30px 100px rgba(3,1,10,.65);
}
.sheet::backdrop { background: rgba(6, 2, 16, .72); backdrop-filter: blur(8px); }
.sheet__card { position: relative; max-height: inherit; padding: 26px 20px calc(var(--safe-bottom) + 22px); overflow-y: auto; }
.sheet__card--compact { display: grid; gap: 9px; text-align: center; }
.sheet__card h2 { margin-bottom: 18px; padding-right: 30px; }
.sheet__close { position: absolute; z-index: 2; top: 14px; right: 14px; }

.rule-list { display: grid; margin: 0; padding-left: 22px; gap: 13px; color: var(--muted); line-height: 1.45; }
.rule-list b { color: var(--ink); }
.points-card { display: grid; margin: 20px 0 14px; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 7px; }
.points-card span { padding: 12px 5px; border-radius: 14px; background: rgba(0,0,0,.18); color: var(--muted); font-size: .68rem; text-align: center; }
.points-card b { display: block; color: var(--lime); font-size: 1.2rem; }
.muted { color: var(--muted); font-size: .78rem; line-height: 1.45; }

.field-label { display: grid; margin-bottom: 14px; gap: 7px; font-size: .82rem; font-weight: 900; }
.field-label small { display: block; color: var(--muted); font-weight: 500; }
.custom-list { display: grid; margin-top: 16px; gap: 7px; }
.custom-item { display: grid; padding: 10px 11px; align-items: center; grid-template-columns: minmax(0,1fr) auto; gap: 8px; border-radius: 14px; background: rgba(0,0,0,.18); }
.custom-item b { display: block; font-size: .82rem; }
.custom-item span { color: var(--muted); font-size: .7rem; }
.custom-item button { border: 0; color: #ff979c; background: transparent; font-weight: 850; cursor: pointer; }

.toast {
  position: fixed;
  z-index: 20;
  right: 16px;
  bottom: calc(var(--safe-bottom) + 16px);
  left: 16px;
  width: fit-content;
  max-width: min(440px, calc(100% - 32px));
  margin: auto;
  padding: 11px 15px;
  transform: translateY(24px);
  border: 1px solid var(--line);
  border-radius: 14px;
  opacity: 0;
  color: var(--ink);
  background: #34205a;
  box-shadow: 0 16px 36px rgba(0,0,0,.35);
  font-size: .82rem;
  font-weight: 750;
  text-align: center;
  transition: opacity .2s ease, transform .2s ease;
  pointer-events: none;
}
.toast--visible { transform: translateY(0); opacity: 1; }

@keyframes timer-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(255,91,165,.25); }
  50% { box-shadow: 0 0 0 13px rgba(255,91,165,0); }
}

@media (min-width: 681px) {
  body { padding: 24px; }
  .app-shell { min-height: calc(100dvh - 48px); border: 1px solid rgba(255,255,255,.12); border-radius: 34px; }
  .screen { min-height: calc(100dvh - 48px); }
  .sticky-footer { bottom: 24px; width: 680px; border-radius: 0 0 34px 34px; }
  .screen::before { position: absolute; }
}

@media (max-width: 370px) {
  .screen--home { padding-inline: 14px; }
  .hero { padding-block: 20px 16px; }
  .hero-symbol { width: 116px; margin-bottom: 17px; font-size: 5rem; }
  .hero__lead { margin-top: 12px; font-size: .9rem; }
  .feature-row { margin-top: 12px; }
  .feature-row span { padding: 6px 7px; font-size: .62rem; }
  .content { padding-inline: 12px; }
  .privacy-card, .role-card, .ballot-card { padding-inline: 14px; }
  .ballot-grid, .word-grid { gap: 6px; }
  .ballot-grid button, .word-grid button { min-height: 59px; padding: 8px; font-size: .76rem; }
  .segments button { padding-inline: 4px; font-size: .69rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
