@font-face{font-family:"Atkinson Hyperlegible";src:url(fonts/atkinson-400.woff2) format("woff2");font-weight:400;font-display:swap}
@font-face{font-family:"Atkinson Hyperlegible";src:url(fonts/atkinson-700.woff2) format("woff2");font-weight:700;font-display:swap}
@font-face{font-family:"JetBrains Mono";src:url(fonts/jetbrains-mono-700.woff2) format("woff2");font-weight:700;font-display:swap}
:root{
  --bg:#F7F8FB; --card:#FFFFFF; --line:#E1E5EE; --line2:#C9D0DC;
  --ink:#0B1B33; --muted:#46536B; --faint:#5B6779; --accent:#F5A30B; --link:#2457C5;
  --red:#C2341F; --ok-bg:#DCEFE2; --ok-fg:#14532D; --warn-bg:#FDEBC8; --warn-fg:#6B4300; --bad-bg:#FBE1DC; --bad-fg:#8F1D12;
  --font:"Atkinson Hyperlegible", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --mono:"JetBrains Mono", ui-monospace, Menlo, Consolas, monospace;
}
*{box-sizing:border-box}
html,body{margin:0;background:var(--bg);color:var(--ink);font-family:var(--font);-webkit-text-size-adjust:100%}
body{min-height:100vh;font-size:17px}
a{color:var(--link)} a:hover{color:#173E94}
button,input,select,textarea{font:inherit;color:inherit}
:focus-visible{outline:3px solid var(--link);outline-offset:2px;border-radius:6px}
.app{max-width:520px;margin:0 auto;padding:20px 18px calc(96px + env(safe-area-inset-bottom));display:flex;flex-direction:column;gap:18px}
.pad{padding:20px}
.row{display:flex;align-items:center;gap:12px}
.between{justify-content:space-between}
.col{display:flex;flex-direction:column;gap:4px}
.stack{display:flex;flex-direction:column;gap:10px}
.grow{flex:1;min-width:0}
h1,h2,h3{margin:0;line-height:1.15;font-weight:700}
h1{font-size:26px;letter-spacing:-.01em}
h1.hero-title{font-size:34px;line-height:1.05;letter-spacing:-.02em;text-align:center}
h2{font-size:20px}
p{margin:0;line-height:1.5}
.muted{color:var(--muted);font-size:16px;line-height:1.45}
.small{font-size:15px}
.faint{color:var(--faint);font-size:14px;line-height:1.45}
.center{text-align:center}
.logo{width:40px;height:40px;flex-shrink:0}
.brand{font-weight:700;font-size:23px;letter-spacing:-.01em}
.brand sup{font-size:12px;color:var(--muted);font-weight:400}
.pill{font-size:14px;color:var(--muted);font-weight:700}
.iconbtn{width:44px;height:44px;border-radius:12px;border:1px solid var(--line2);background:var(--card);display:inline-flex;align-items:center;justify-content:center;cursor:pointer;text-decoration:none;flex-shrink:0}
.iconbtn svg{width:20px;height:20px;stroke:var(--ink);fill:none;stroke-width:2.2;stroke-linecap:round;stroke-linejoin:round}
.card{background:var(--card);border:1px solid var(--line);border-radius:20px;padding:18px;display:flex;flex-direction:column;gap:10px}
.outline{border:1px solid var(--line2);border-radius:14px;padding:12px 14px;background:var(--card)}
.dashed{border-style:dashed}
.btn{display:flex;align-items:center;justify-content:center;gap:8px;min-height:52px;padding:0 18px;border-radius:14px;border:0;background:var(--accent);color:var(--ink);font-weight:700;font-size:17px;text-decoration:none;cursor:pointer;width:100%}
.btn:hover{color:var(--ink);filter:brightness(1.04)}
.btn svg{width:18px;height:18px;stroke:currentColor;fill:none;stroke-width:2.5;stroke-linecap:round;stroke-linejoin:round}
.btn.dark{background:var(--ink);color:#fff}
.btn.dark:hover{color:#fff}
.btn.ghost{background:var(--card);border:1.5px solid var(--ink);color:var(--ink)}
.btn.danger{background:transparent;border:1.5px solid #E8B4AC;color:var(--bad-fg)}
.btn.small{min-height:44px;width:auto;font-size:15px}
.btn[disabled]{opacity:.5;cursor:not-allowed}
.grid2{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.tile{flex-direction:column;min-height:100px;border-radius:16px}
.tile svg{width:28px;height:28px}
.progress{height:8px;border-radius:4px;background:var(--line);overflow:hidden}
.progress > i{display:block;height:8px;background:var(--accent);width:0}

/* home route */
.route{position:relative;height:152px}
.route .solid{position:absolute;left:4px;top:74px;height:8px;border-radius:4px;background:var(--accent)}
.route .dash{position:absolute;top:77px;height:0;border-top:3px dashed #8A96AD}
.stop{position:absolute;top:0;width:84px;height:152px;transform:translateX(-50%);display:block;color:var(--ink);text-decoration:none}
.stop .pot{position:absolute;left:24px;top:53px;width:36px;height:43px}
.stop .flag{position:absolute;left:28px;top:46px;width:28px;height:36px}
.stop .lab{position:absolute;left:0;right:0;display:flex;flex-direction:column;align-items:center;gap:1px;text-align:center;line-height:1.2;font-size:14px}
.stop .lab.up{bottom:102px}
.stop .lab.down{top:100px}
.stop .lab b{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;word-break:break-word}
.stop .lab span{color:var(--muted)}
.legend{display:flex;gap:14px;flex-wrap:wrap;font-size:14px;color:var(--muted);font-weight:700}
.legend span{display:flex;align-items:center;gap:5px}
.legend svg{width:14px;height:17px}

/* next stop board */
.board{background:var(--ink);color:#fff;border-radius:22px;padding:20px;display:flex;flex-direction:column;gap:12px}
.board .k{font-family:var(--mono);font-size:13px;font-weight:700;letter-spacing:.12em;color:var(--accent)}
.board .v{font-family:var(--mono);font-size:20px;font-weight:700;color:#FFE7A8;line-height:1.25;text-transform:uppercase;word-break:break-word}
.board p{color:#D5DCEA;font-size:16px}

/* checklist */
.item{display:flex;align-items:center;gap:12px;background:var(--card);border:1px solid var(--line);border-radius:14px;padding:8px 14px;min-height:60px}
.item a.grow{color:var(--ink);text-decoration:none;display:flex;flex-direction:column;gap:2px}
.item .t{font-size:16px;font-weight:700}
.item .s{font-size:14px;color:var(--muted)}
.check{width:30px;height:30px;border-radius:15px;border:2px solid #8A96AD;background:transparent;display:inline-flex;align-items:center;justify-content:center;cursor:pointer;flex-shrink:0;padding:0}
.check svg{width:16px;height:16px;stroke:var(--ink);fill:none;stroke-width:3;stroke-linecap:round;stroke-linejoin:round;opacity:0}
.check[aria-pressed="true"]{background:var(--accent);border-color:var(--accent)}
.check[aria-pressed="true"] svg{opacity:1}
.hit{min-width:44px;min-height:44px;display:inline-flex;align-items:center;justify-content:center}
.chev{width:18px;height:18px;stroke:var(--faint);fill:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;flex-shrink:0}
.lockline svg{width:20px;height:20px;stroke:var(--ink);fill:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;flex-shrink:0}
.lockline p{font-size:15px;color:var(--ink);line-height:1.4}

/* full line (working life) */
.fl{display:flex;flex-direction:column}
.fl-row{display:flex;gap:14px;min-height:78px;color:var(--ink);text-decoration:none}
.fl-rail{width:40px;flex-shrink:0;display:flex;flex-direction:column;align-items:center}
.fl-rail .seg{width:8px;background:var(--accent)}
.fl-rail .seg.top{height:8px}
.fl-rail .seg.bot{flex:1}
.fl-rail .seg.none{background:transparent}
.fl-rail .seg.dashed{background:transparent;border-left:3px dashed #8A96AD;width:3px}
.fl-rail .pot{width:34px;height:40px;flex-shrink:0}
.fl-rail .flag{width:30px;height:38px;flex-shrink:0}
.fl-rail .ring{width:24px;height:24px;border-radius:50%;border:5px solid #8A96AD;background:#fff;flex-shrink:0}
.fl-rail .ring.now{border-color:var(--link);width:28px;height:28px}
.fl-body{flex:1;min-width:0;display:flex;flex-direction:column;gap:3px;padding:4px 0 14px}
.fl-body .n{font-weight:700;font-size:19px;line-height:1.2;word-break:break-word}
.fl-body .y{font-family:var(--mono);font-size:13px;font-weight:700;color:var(--muted);white-space:nowrap}
.fl-body .d{font-size:15px;color:var(--muted)}
.fl-body .st{font-size:14px;font-weight:700}
.st-found{color:var(--ok-fg)} .st-checking{color:var(--warn-fg)} .st-tofind{color:var(--red)} .st-none{color:var(--muted)} .st-gap,.st-now{color:var(--link)}

.tag{display:inline-block;padding:3px 10px;border-radius:999px;font-size:13px;font-weight:700;flex-shrink:0;white-space:nowrap}
.t-found{background:var(--ok-bg);color:var(--ok-fg)}
.t-checking{background:var(--warn-bg);color:var(--warn-fg)}
.t-tofind{background:var(--bad-bg);color:var(--bad-fg)}
.t-none{background:var(--line);color:var(--ink)}
.doc{display:flex;align-items:center;gap:12px;background:var(--card);border:1px solid var(--line);border-radius:14px;padding:10px 12px;color:var(--ink);text-decoration:none;min-height:66px}
.thumb{width:44px;height:54px;border-radius:6px;background:#E8ECF3;flex-shrink:0;object-fit:cover;display:flex;align-items:center;justify-content:center;color:var(--ink);font-size:12px;font-weight:700}
form.stack label{display:flex;flex-direction:column;gap:6px;font-size:16px;font-weight:700}
input[type=text],input[type=email],input[type=password],input[type=number],select,textarea{width:100%;min-height:50px;padding:10px 12px;border-radius:12px;border:1.5px solid var(--line2);background:#fff;color:var(--ink);font-size:17px;font-weight:400}
textarea{min-height:96px;resize:vertical}
.hint{font-weight:400;color:var(--muted);font-size:14px}
.switch{display:flex;align-items:center;justify-content:space-between;gap:12px;background:var(--card);border:1px solid var(--line);border-radius:14px;padding:12px 14px;min-height:60px}
.switch input{width:26px;height:26px;accent-color:var(--ink);flex-shrink:0}
.banner{background:var(--warn-bg);color:var(--warn-fg);border-radius:14px;padding:12px 14px;display:flex;gap:10px;align-items:center}
.banner a{color:var(--warn-fg);font-weight:700}
.preview-img{width:100%;border-radius:12px;background:#E8ECF3}
.help h2{margin-top:4px}
.help ul{margin:0;padding-left:20px;line-height:1.55;color:var(--muted);font-size:16px}
.tabs{position:fixed;left:0;right:0;bottom:0;background:rgba(255,255,255,.97);border-top:1px solid var(--line);display:flex;justify-content:center;padding:6px 6px calc(6px + env(safe-area-inset-bottom));z-index:10}
.tabs a{flex:1;max-width:104px;display:flex;flex-direction:column;align-items:center;gap:3px;min-height:54px;justify-content:center;color:var(--faint);text-decoration:none;font-size:12px;font-weight:700;border-radius:10px}
.tabs a svg{width:23px;height:23px;stroke:currentColor;fill:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.tabs a[aria-current="page"]{color:var(--ink)}
.tabs a[aria-current="page"]::after{content:"";width:20px;height:3px;border-radius:2px;background:var(--accent);margin-top:1px}
.tabs.hidden{display:none}
.toast{position:fixed;left:50%;transform:translateX(-50%);bottom:calc(86px + env(safe-area-inset-bottom));background:var(--ink);color:#fff;padding:10px 16px;border-radius:12px;font-weight:700;font-size:15px;z-index:20;max-width:90vw;text-align:center}
.lock{min-height:80vh;display:flex;flex-direction:column;justify-content:center;gap:16px}
.err{color:var(--bad-fg);font-size:15px}
.sr{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
footer.foot{margin-top:8px}
@media (min-width:700px){.app{padding-top:32px}}


/* ---------- Dark mode (v1.2.0) ----------
   Follows the phone unless the user picks Light or Dark in Your data (sets data-theme on <html>). */
@media (prefers-color-scheme: dark){
:root:not([data-theme=light]){color-scheme:dark;
  --bg:#0A1628; --card:#11223B; --line:#1F3354; --line2:#2E4669;
  --ink:#EEF2F8; --muted:#B4C0D4; --faint:#9AA8BE; --accent:#F5A30B; --link:#8EB4FF;
  --red:#FF8A75; --ok-bg:#163A26; --ok-fg:#9FE0B5; --warn-bg:#3D2D0A; --warn-fg:#FFD78A; --bad-bg:#3F1A15; --bad-fg:#FFB4A6;}
:root:not([data-theme=light]) a:hover{color:#B7CFFF}
:root:not([data-theme=light]) .btn,:root:not([data-theme=light]) .btn:hover{color:#0B1B33}
:root:not([data-theme=light]) .btn.dark,:root:not([data-theme=light]) .btn.dark:hover{background:#F5A30B;color:#0B1B33}
:root:not([data-theme=light]) .btn.ghost{background:var(--card);border-color:var(--ink);color:var(--ink)}
:root:not([data-theme=light]) .btn.danger{border-color:#8F4A40;color:var(--bad-fg)}
:root:not([data-theme=light]) .board{background:#050D1A;border:1px solid #2E4669}
:root:not([data-theme=light]) .toast{color:#0B1B33;background:#EEF2F8}
:root:not([data-theme=light]) .route .dash,:root:not([data-theme=light]) .fl-rail .seg.dashed,:root:not([data-theme=light]) .check{border-color:#5E7090}
:root:not([data-theme=light]) .fl-rail .ring{border-color:#5E7090;background:var(--card)}
:root:not([data-theme=light]) .thumb,:root:not([data-theme=light]) .preview-img{background:#1F3354}
:root:not([data-theme=light]) .tabs{background:rgba(10,22,40,.97)}
:root:not([data-theme=light]) .switch input{accent-color:#F5A30B}
:root:not([data-theme=light]) [fill="#FFFFFF"]{fill:#11223B}
:root:not([data-theme=light]) [stroke="#0B1B33"]{stroke:#EEF2F8}
:root:not([data-theme=light]) [fill="#0B1B33"]{fill:#EEF2F8}
:root:not([data-theme=light]) [stroke="#C2341F"]{stroke:#FF8A75}
:root:not([data-theme=light]) [stroke="#8A96AD"]{stroke:#5E7090}
:root:not([data-theme=light]) [fill="#EEF1F7"]{fill:#1A2D4C}
:root:not([data-theme=light]) input[type=text],:root:not([data-theme=light]) input[type=email],:root:not([data-theme=light]) input[type=password],:root:not([data-theme=light]) input[type=number],:root:not([data-theme=light]) select,:root:not([data-theme=light]) textarea{background:#0A1628;color:var(--ink);border-color:#3A5279}
:root:not([data-theme=light]) ::placeholder{color:#7F8DA6}
}
:root[data-theme=dark]{color-scheme:dark;
  --bg:#0A1628; --card:#11223B; --line:#1F3354; --line2:#2E4669;
  --ink:#EEF2F8; --muted:#B4C0D4; --faint:#9AA8BE; --accent:#F5A30B; --link:#8EB4FF;
  --red:#FF8A75; --ok-bg:#163A26; --ok-fg:#9FE0B5; --warn-bg:#3D2D0A; --warn-fg:#FFD78A; --bad-bg:#3F1A15; --bad-fg:#FFB4A6;}
:root[data-theme=dark] a:hover{color:#B7CFFF}
:root[data-theme=dark] .btn,:root[data-theme=dark] .btn:hover{color:#0B1B33}
:root[data-theme=dark] .btn.dark,:root[data-theme=dark] .btn.dark:hover{background:#F5A30B;color:#0B1B33}
:root[data-theme=dark] .btn.ghost{background:var(--card);border-color:var(--ink);color:var(--ink)}
:root[data-theme=dark] .btn.danger{border-color:#8F4A40;color:var(--bad-fg)}
:root[data-theme=dark] .board{background:#050D1A;border:1px solid #2E4669}
:root[data-theme=dark] .toast{color:#0B1B33;background:#EEF2F8}
:root[data-theme=dark] .route .dash,:root[data-theme=dark] .fl-rail .seg.dashed,:root[data-theme=dark] .check{border-color:#5E7090}
:root[data-theme=dark] .fl-rail .ring{border-color:#5E7090;background:var(--card)}
:root[data-theme=dark] .thumb,:root[data-theme=dark] .preview-img{background:#1F3354}
:root[data-theme=dark] .tabs{background:rgba(10,22,40,.97)}
:root[data-theme=dark] .switch input{accent-color:#F5A30B}
:root[data-theme=dark] [fill="#FFFFFF"]{fill:#11223B}
:root[data-theme=dark] [stroke="#0B1B33"]{stroke:#EEF2F8}
:root[data-theme=dark] [fill="#0B1B33"]{fill:#EEF2F8}
:root[data-theme=dark] [stroke="#C2341F"]{stroke:#FF8A75}
:root[data-theme=dark] [stroke="#8A96AD"]{stroke:#5E7090}
:root[data-theme=dark] [fill="#EEF1F7"]{fill:#1A2D4C}
:root[data-theme=dark] input[type=text],:root[data-theme=dark] input[type=email],:root[data-theme=dark] input[type=password],:root[data-theme=dark] input[type=number],:root[data-theme=dark] select,:root[data-theme=dark] textarea{background:#0A1628;color:var(--ink);border-color:#3A5279}
:root[data-theme=dark] ::placeholder{color:#7F8DA6}

/* ---------- Appearance switch, intro card, How it works (v1.2.0) ---------- */
.seg{display:flex;background:var(--card);border:1px solid var(--line);border-radius:14px;padding:4px;gap:4px}
.seg button{flex:1;min-height:44px;border:0;border-radius:10px;background:transparent;color:var(--muted);font-weight:700;font-size:15px;cursor:pointer}
.seg button[aria-pressed="true"]{background:var(--accent);color:#0B1B33}
.why{position:relative;background:var(--card);border:1.5px solid var(--accent);border-radius:20px;padding:18px;display:flex;flex-direction:column;gap:10px}
.why h2{padding-right:40px}
.why .x{position:absolute;right:6px;top:6px;width:44px;height:44px;border:0;background:transparent;color:var(--faint);font-size:26px;line-height:1;cursor:pointer;border-radius:12px}
.numrow{display:flex;gap:10px;align-items:flex-start}
.numrow .n{width:26px;height:26px;border-radius:13px;background:var(--accent);color:#0B1B33;font-weight:700;display:flex;align-items:center;justify-content:center;font-size:15px;flex-shrink:0;margin-top:1px}
.more{font-weight:700;font-size:16px}
.steps{position:relative;display:flex;flex-direction:column;gap:22px;padding-left:46px;margin:4px 0}
.steps::before{content:"";position:absolute;left:15px;top:14px;bottom:14px;width:6px;border-radius:3px;background:var(--accent)}
.steps .st{position:relative}
.steps .dot{position:absolute;left:-46px;top:-2px;width:36px;height:36px;border-radius:18px;background:var(--card);border:4px solid var(--ink);display:flex;align-items:center;justify-content:center;font-weight:700}
.steps h3{font-size:19px;margin-bottom:4px}
.card.amber{border:1.5px solid var(--accent)}
.card ul{margin:0;padding-left:20px;line-height:1.5}
.card ul li+li{margin-top:4px}
