:root {
  --orange: #FF6B1A; --orange-soft: #FFE3D1; --ink: #1E1A24; --cream: #FFF3E3; --amber: #FFB547; --ok: #1F9D57;
  --bg: #FFF8EF; --card: #FFFFFF; --text: #1E1A24; --muted: #6B6475; --line: rgba(30,26,36,.10); --tab-bg: rgba(255,255,255,.92);
  --radius: 18px; --safe-b: env(safe-area-inset-bottom, 0px);
}
:root[data-theme="dark"] {
  --bg: #14111A; --card: #1F1B27; --text: #FFF3E3; --muted: #A59DB0; --line: rgba(255,243,227,.10);
  --orange-soft: #3A2417; --tab-bg: rgba(20,17,26,.92); --ok: #3DD27F;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--bg); color: var(--text); font: 16px/1.45 Inter, -apple-system, "SF Pro Text", "Helvetica Neue", Arial, sans-serif; }
body { padding-bottom: calc(76px + var(--safe-b)); }
main { max-width: 560px; margin: 0 auto; padding: 16px 16px 24px; }
h1 { font-size: 30px; line-height: 1.1; letter-spacing: -.02em; font-weight: 800; margin: 14px 0 10px; }
h2 { font-size: 20px; letter-spacing: -.01em; font-weight: 800; margin: 26px 0 10px; }
h3 { font-size: 16px; margin: 0; font-weight: 700; }
p { margin: 0 0 10px; }
.muted { color: var(--muted); }
.accent { color: var(--orange); }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 18px; }
.brand img { width: 36px; height: 36px; border-radius: 10px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; margin-bottom: 12px; }
.hero { padding: 6px 0 4px; }
.btn { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; min-height: 52px; padding: 0 18px; border: 0; border-radius: 16px;
  font: inherit; font-weight: 700; color: var(--ink); background: var(--orange); cursor: pointer; text-decoration: none; margin-top: 10px; }
.btn:active { transform: scale(.985); }
.btn.ghost { background: var(--card); border: 1px solid var(--line); color: var(--text); }
.btn.small { min-height: 42px; width: auto; padding: 0 16px; margin: 0; font-size: 15px; }
.btn[disabled] { opacity: .55; cursor: default; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0 4px; }
.chip { padding: 7px 12px; border-radius: 999px; background: var(--card); border: 1px solid var(--line); font-size: 14px; font-weight: 600; }
.chip.off { color: var(--muted); font-weight: 500; }
.perks { list-style: none; margin: 0; padding: 0; }
.perks li { padding: 10px 0 10px 30px; position: relative; border-top: 1px solid var(--line); }
.perks li:first-child { border-top: 0; }
.perks li::before { content: ""; position: absolute; left: 0; top: 13px; width: 18px; height: 18px; border-radius: 50%; background: var(--orange); }
.perks li::after { content: ""; position: absolute; left: 6px; top: 17px; width: 5px; height: 9px; border: solid var(--ink); border-width: 0 2px 2px 0; transform: rotate(45deg); }
.svc-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; width: 100%; background: none; border: 0; padding: 0; font: inherit; color: inherit; text-align: left; cursor: pointer; }
.svc-head .from { color: var(--muted); font-size: 14px; white-space: nowrap; }
.svc-head .from.out { color: var(--muted); opacity: .8; }
.plans { margin-top: 12px; border-top: 1px solid var(--line); }
.plan { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.plan:last-child { border-bottom: 0; padding-bottom: 0; }
.plan .t { font-weight: 700; }
.plan .d { font-size: 13px; color: var(--muted); }
.plan.out { opacity: .55; }
.price { font-weight: 800; white-space: nowrap; }
label { display: block; font-size: 14px; font-weight: 600; margin: 14px 0 6px; }
input[type=text], input[type=email] { width: 100%; min-height: 52px; padding: 0 14px; border-radius: 14px; border: 1.5px solid var(--line); background: var(--card); color: var(--text); font: inherit; }
input:focus { outline: 2px solid var(--orange); outline-offset: 1px; border-color: transparent; }
.keybox { font: 700 20px/1.2 ui-monospace, "SF Mono", Menlo, monospace; letter-spacing: .04em; padding: 14px; border-radius: 14px; background: var(--orange-soft); text-align: center; word-break: break-all; }
.status { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 700; padding: 4px 10px; border-radius: 999px; background: var(--orange-soft); }
.status.active { color: var(--ok); background: color-mix(in srgb, var(--ok) 14%, transparent); }
.row { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.steps { counter-reset: s; list-style: none; padding: 0; margin: 0; }
.steps li { counter-increment: s; position: relative; padding: 0 0 14px 40px; }
.steps li::before { content: counter(s); position: absolute; left: 0; top: 0; width: 28px; height: 28px; border-radius: 50%; background: var(--ink); color: var(--cream); display: grid; place-items: center; font-weight: 800; font-size: 14px; }
:root[data-theme="dark"] .steps li::before { background: var(--orange); color: var(--ink); }
details { border-top: 1px solid var(--line); padding: 12px 0; }
details:first-of-type { border-top: 0; }
summary { font-weight: 700; cursor: pointer; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
summary::after { content: "+"; color: var(--orange); font-weight: 800; }
details[open] summary::after { content: "–"; }
details p { margin: 8px 0 0; color: var(--muted); }
.empty { text-align: center; padding: 34px 10px; color: var(--muted); }
.empty img { width: 64px; height: 64px; opacity: .9; margin-bottom: 8px; border-radius: 16px; }
.banner { padding: 10px 14px; border-radius: 14px; background: var(--orange-soft); font-size: 14px; margin-bottom: 12px; }
.err { color: #D63B2F; font-size: 14px; margin-top: 8px; min-height: 20px; }
:root[data-theme="dark"] .err { color: #FF7A6E; }
nav#tabs { position: fixed; left: 0; right: 0; bottom: 0; display: flex; justify-content: space-around; padding: 8px 6px calc(8px + var(--safe-b));
  background: var(--tab-bg); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-top: 1px solid var(--line); }
nav#tabs a { flex: 1; max-width: 100px; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 6px 0; border-radius: 12px; color: var(--muted); text-decoration: none; font-size: 11px; font-weight: 600; }
nav#tabs svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
nav#tabs a.on { color: var(--text); }
nav#tabs a.on svg { stroke: var(--orange); fill: color-mix(in srgb, var(--orange) 18%, transparent); }
#toast { position: fixed; left: 50%; bottom: calc(92px + var(--safe-b)); transform: translate(-50%, 20px); opacity: 0; pointer-events: none; transition: .25s;
  background: var(--ink); color: var(--cream); padding: 10px 16px; border-radius: 12px; font-size: 14px; max-width: 86vw; }
#toast.show { opacity: 1; transform: translate(-50%, 0); }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
:root[data-theme="dark"] #toast { background: var(--cream); color: var(--ink); }
.seg { display: flex; gap: 4px; padding: 4px; margin: 6px 0 14px; background: var(--card); border: 1px solid var(--line); border-radius: 14px; overflow-x: auto; }
.seg button { flex: 1; min-height: 38px; padding: 0 10px; border: 0; border-radius: 10px; background: none; color: var(--muted); font: inherit; font-size: 14px; font-weight: 700; white-space: nowrap; cursor: pointer; }
.seg button.on { background: var(--orange); color: var(--ink); }
.tiles { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.tile { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; }
.tile b { display: block; font-size: 28px; line-height: 1.1; letter-spacing: -.02em; }
.tile span { color: var(--muted); font-size: 13px; }
select { width: 100%; min-height: 52px; padding: 0 12px; border-radius: 14px; border: 1.5px solid var(--line); background: var(--card); color: var(--text); font: inherit; }
