:root {
  color-scheme: light;
  --ink: #18212e;
  --muted: #5b6778;
  --line: #e5e9ef;
  --surface: #ffffff;
  --surface-soft: #f6f8fb;
  --blue: #0065d0;
  --blue-strong: #0564cf;
  --green: #177245;
  --amber: #9b5b00;
  --red: #b42318;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 16px;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid #006de0; outline-offset: 3px; }
.hero-note { margin-top: 15px; font-size: 13px; }
.blue-text { color: var(--blue); }
.download-actions { margin-top: 14px; }
.button[aria-disabled="true"] { pointer-events: none; opacity: .55; }
.login-card > button, .aside-bottom > button { width: 100%; }
label.full { display: flex; align-items: center; gap: 8px; margin-bottom: 16px; }
body { margin: 0; color: var(--ink); background: var(--surface-soft); line-height: 1.55; }
a { color: inherit; }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }
.shell { min-height: 100vh; }
.container { width: min(1160px, calc(100% - 40px)); margin: 0 auto; }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 18px 0; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 760; text-decoration: none; letter-spacing: -.02em; }
.brand, .button { white-space: nowrap; }
.brand-mark { display: grid; place-items: center; width: 30px; height: 30px; color: #fff; border-radius: 10px; background: var(--blue); font-size: 15px; box-shadow: 0 5px 14px #087cfa2e; }
.topnav { display: flex; align-items: center; gap: 22px; color: var(--muted); font-size: 14px; }
.topnav a { text-decoration: none; }
.topnav a:hover, .topnav a:focus-visible { color: var(--blue); }
.hero { display: grid; grid-template-columns: 1.05fr .95fr; align-items: center; gap: 70px; min-height: 610px; padding: 64px 0 80px; }
.eyebrow { margin: 0 0 16px; color: var(--blue); font-size: 13px; font-weight: 730; letter-spacing: .12em; }
h1, h2, h3, p { margin-top: 0; }
h1 { max-width: 640px; margin-bottom: 22px; font-size: clamp(42px, 6vw, 76px); letter-spacing: -.03em; line-height: 1.12; }
h2 { margin-bottom: 10px; font-size: clamp(26px, 4vw, 38px); letter-spacing: -.04em; line-height: 1.15; }
h3 { margin-bottom: 5px; font-size: 18px; }
.lede { max-width: 550px; color: var(--muted); font-size: 19px; }
.actions { display: flex; flex-wrap: wrap; gap: 11px; margin-top: 30px; }
.button { display: inline-flex; min-height: 44px; align-items: center; justify-content: center; padding: 0 17px; border: 0; border-radius: 13px; background: var(--blue); color: #fff; font-weight: 680; text-decoration: none; transition: transform .18s ease, background .18s ease; }
.button:hover, .button:focus-visible { background: var(--blue-strong); transform: translateY(-1px); }
.button.secondary { border: 1px solid var(--line); background: var(--surface); color: var(--ink); }
.button.secondary:hover { background: var(--surface-soft); }
.button.small { min-height: 36px; padding: 0 12px; border-radius: 10px; font-size: 14px; }
.button.danger { background: #fff3f2; color: var(--red); }
.button:disabled { cursor: wait; opacity: .55; transform: none; }
.hero-card { position: relative; min-height: 430px; padding: 26px; overflow: hidden; border: 1px solid #dce5f0; border-radius: 30px; background: #edf5ff; box-shadow: 0 28px 75px #204b7920; }
.hero-card:before { position: absolute; inset: 0; content: ""; background: radial-gradient(circle at 74% 10%, #bfe0ff 0 18%, transparent 19%), radial-gradient(circle at 25% 58%, #d9efff 0 25%, transparent 26%); opacity: .8; }
.route-board { position: relative; display: flex; min-height: 378px; flex-direction: column; justify-content: space-between; padding: 20px; border: 1px solid #ffffffb8; border-radius: 24px; background: #ffffffe6; box-shadow: 0 15px 40px #3275b51c; }
.route-top { display: flex; align-items: start; justify-content: space-between; }
.route-label { color: var(--muted); font-size: 12px; }
.route-city { margin-top: 3px; font-size: 24px; font-weight: 750; }
.route-icon { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; background: #e8f3ff; color: var(--blue); font-size: 20px; }
.route-line { position: relative; display: grid; gap: 22px; margin: 14px 4px; }
.route-line:before { position: absolute; top: 12px; bottom: 12px; left: 9px; width: 2px; content: ""; background: #c8dff9; }
.route-stop { position: relative; display: flex; align-items: center; gap: 14px; }
.route-dot { z-index: 1; display: grid; place-items: center; width: 20px; height: 20px; border: 4px solid #fff; border-radius: 50%; background: var(--blue); color: #fff; box-shadow: 0 2px 7px #087cfa66; font-size: 9px; font-weight: 700; }
.route-stop span:last-child { font-weight: 650; }
.route-footer { display: flex; align-items: center; justify-content: space-between; padding-top: 14px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; }
.section { padding: 82px 0; }
.section.alt { background: var(--surface); }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 28px; }
.section-head p { max-width: 490px; margin: 0; color: var(--muted); }
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.feature { padding: 24px; border: 1px solid var(--line); border-radius: 20px; background: var(--surface); }
.feature-icon { display: grid; place-items: center; width: 38px; height: 38px; margin-bottom: 20px; border-radius: 12px; background: #eaf3ff; color: var(--blue); font-size: 19px; }
.feature p { margin-bottom: 0; color: var(--muted); font-size: 14px; }
.notice { padding: 18px 20px; border: 1px solid #d8e6f7; border-radius: 16px; background: #f2f8ff; color: #315675; }
.footer { padding: 30px 0 40px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; }
.footer-row { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.legal { max-width: 760px; padding: 76px 0 100px; }
.legal p, .legal li { color: #526071; }
.legal li { margin: 8px 0; }

/* Admin */
.admin-shell { min-height: 100vh; }
.admin-login { display: grid; min-height: 100vh; place-items: center; padding: 24px; background: #edf4fc; }
.login-card { width: min(420px, 100%); padding: 34px; border: 1px solid #dbe5f1; border-radius: 24px; background: var(--surface); box-shadow: 0 20px 60px #2a507521; }
.login-card h1 { margin: 22px 0 8px; font-size: 30px; letter-spacing: -.04em; }
.login-card p { color: var(--muted); }
.admin-shell .admin-login { background: var(--surface-soft); }
.admin-shell .login-card { width: min(440px, 100%); border-color: var(--line); border-radius: 16px; padding: 32px; }
.admin-shell .login-card h1 { font-size: 28px; letter-spacing: -.03em; }
.admin-shell .login-card > p { margin: 0 0 24px; }
.admin-shell .visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.admin-shell .admin-auth-form fieldset { min-width: 0; margin: 0; padding: 0; border: 0; }
.admin-shell .admin-auth-form > .button { min-height: 48px; }
.admin-shell .login-card .admin-auth-form > .button { width: 100%; }
.admin-shell .admin-auth-form .error { margin: 0 0 12px; }
.admin-shell .admin-auth-form .error:empty { min-height: 0; margin: 0; }
.admin-shell .login-card .error { color: var(--red); }
.admin-shell .password-field { display: flex; align-items: center; border: 1px solid #d8dee8; border-radius: 11px; background: var(--surface); }
.admin-shell .password-field input { min-width: 0; border: 0; background: transparent; }
.admin-shell .password-field:focus-within { border-color: var(--blue); }
.admin-shell .password-toggle { align-self: stretch; flex-shrink: 0; min-width: 52px; min-height: 44px; padding: 8px 12px; border: 0; border-radius: 10px; background: transparent; color: var(--blue); font-size: 14px; }
.admin-shell .password-toggle:hover { background: var(--surface-soft); }
.admin-shell .password-toggle:active { background: var(--line); }
.admin-shell .admin-auth-form input:disabled, .admin-shell .password-toggle:disabled { opacity: .65; cursor: wait; }
.admin-shell .field-hint { color: var(--muted); font-size: 13px; line-height: 1.6; }
.admin-shell .field-optional { color: var(--muted); font-weight: 400; }
.admin-shell input[aria-invalid="true"] { border-color: var(--red); }
.admin-shell .password-field:has(input[aria-invalid="true"]) { border-color: var(--red); }
.admin-shell .auth-message { padding: 12px 0; border-block: 1px solid var(--line); color: var(--ink); font-size: 14px; }
.admin-shell .auth-status p { margin: 0 0 16px; }
.admin-shell .auth-notice { padding-top: 20px; border-top: 1px solid var(--line); }
.admin-shell .auth-notice h2 { margin: 0 0 8px; font-size: 18px; }
.admin-shell .auth-notice p { margin: 0; font-size: 14px; }
.admin-shell .account-panel { max-width: 640px; }
.admin-shell .account-intro { margin: 0 0 24px; color: var(--muted); }
.admin-shell .account-password-section { padding-top: 24px; margin-top: 24px; border-top: 1px solid var(--line); }
.admin-shell #account-status:empty { display: none; }
.admin-shell #account-retry { margin-left: 8px; }
.field { display: grid; gap: 7px; margin-bottom: 16px; }
.field label { color: #526071; font-size: 13px; font-weight: 650; }
.field input, .field textarea, .field select { width: 100%; padding: 11px 12px; border: 1px solid #d8dee8; border-radius: 11px; background: #fff; color: var(--ink); outline: 0; }
.field textarea { min-height: 90px; resize: vertical; }
.field input:focus, .field textarea:focus, .field select:focus { border-color: var(--blue); box-shadow: 0 0 0 3px #087cfa20; }
.form-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0 16px; }
.full { grid-column: 1 / -1; }
.error { min-height: 22px; color: var(--red); font-size: 13px; }
.admin-layout { display: grid; grid-template-columns: 228px 1fr; min-height: 100vh; }
.admin-aside { position: sticky; top: 0; display: flex; height: 100vh; flex-direction: column; padding: 24px 14px; border-right: 1px solid var(--line); background: var(--surface); }
.aside-brand { padding: 0 10px 28px; }
.aside-nav { display: grid; gap: 4px; }
.aside-nav button { padding: 11px 12px; border: 0; border-radius: 10px; background: transparent; color: #637083; text-align: left; }
.aside-nav button:hover, .aside-nav button.active { background: #eaf3ff; color: var(--blue); font-weight: 670; }
.aside-bottom { margin-top: auto; padding: 12px 10px 0; border-top: 1px solid var(--line); }
.admin-main { min-width: 0; padding: 28px clamp(20px, 4vw, 52px) 60px; }
.admin-header { display: flex; align-items: start; justify-content: space-between; gap: 20px; margin-bottom: 26px; }
.admin-header h1 { margin: 0; font-size: 32px; letter-spacing: -.05em; }
.admin-header p { margin: 5px 0 0; color: var(--muted); }
.view { display: none; animation: rise .22s ease both; }
.view.active { display: block; }
@keyframes rise { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 24px; }
.stat { padding: 20px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); }
.stat-label { color: var(--muted); font-size: 13px; }
.stat-value { margin-top: 5px; font-size: 28px; font-weight: 750; letter-spacing: -.04em; }
.stat-note { margin-top: 3px; color: var(--muted); font-size: 12px; }
.panel { margin-bottom: 20px; padding: 22px; border: 1px solid var(--line); border-radius: 18px; background: var(--surface); }
.panel-title { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 17px; }
.panel-title h2 { margin: 0; font-size: 19px; letter-spacing: -.02em; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { padding: 11px 10px; border-bottom: 1px solid #edf0f4; text-align: left; vertical-align: top; white-space: nowrap; }
th { color: var(--muted); font-size: 12px; font-weight: 670; }
tr:last-child td { border-bottom: 0; }
.muted { color: var(--muted); }
.pill { display: inline-flex; align-items: center; min-height: 24px; padding: 0 8px; border-radius: 99px; background: #edf1f5; color: #586676; font-size: 12px; font-weight: 650; }
.pill.ok { background: #e7f7ee; color: var(--green); }
.pill.warn { background: #fff4df; color: var(--amber); }
.pill.bad { background: #ffebe9; color: var(--red); }
.config-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.config { padding: 13px; border: 1px solid var(--line); border-radius: 13px; }
.config strong { display: block; margin-bottom: 4px; font-size: 13px; }
.config span { color: var(--muted); font-size: 12px; }
.toast { position: fixed; right: 22px; bottom: 22px; z-index: 10; max-width: min(380px, calc(100% - 44px)); padding: 12px 16px; border: 1px solid #ced8e5; border-radius: 13px; background: #fff; box-shadow: 0 12px 32px #25476a26; animation: toast-in .2s ease both; }
.toast.error { border-color: #f1b8b2; color: var(--red); }
.hero-card, .route-board, .login-card, .toast { box-shadow: none; }
.hero-card { border: 0; background: transparent; padding: 0; }
.hero-card:before { display: none; }
.route-board { border: 0; background: #edf4fc; padding: 28px; }
.route-dot { width: 28px; height: 28px; border: 0; font-size: 12px; box-shadow: none; flex-shrink: 0; }
.route-line:before { left: 13px; }
.feature { border: 0; border-radius: 0; border-top: 1px solid var(--line); padding: 24px 0; }
.feature-icon { display: none; }
.feature-grid { gap: 28px; }
.admin-header h1 { letter-spacing: -.03em; }
::selection { background: #c8dff9; color: #18212e; }
input, textarea { caret-color: var(--blue); }
table { font-variant-numeric: tabular-nums; }
a { text-underline-offset: 3px; }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@media (max-width: 820px) {
  .container { width: min(100% - 28px, 640px); }
  .hero { grid-template-columns: 1fr; gap: 36px; min-height: auto; padding-top: 42px; }
  .hero-card { min-height: 360px; }
  .feature-grid { grid-template-columns: 1fr; }
  .section { padding: 62px 0; }
  .topnav { gap: 12px; }
  .admin-layout { display: block; }
  .admin-aside { position: static; height: auto; flex-direction: row; align-items: center; gap: 16px; overflow-x: auto; padding: 12px 14px; }
  .aside-brand { padding: 0; }
  .aside-brand, .aside-nav, .admin-header > button { flex-shrink: 0; }
  .aside-nav { display: flex; }
  .aside-nav button { white-space: nowrap; }
  .aside-bottom { flex-shrink: 0; border-top: 0; padding: 0; margin: 0; }
  .admin-main { padding: 24px 16px 40px; }
  .stats, .config-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
  .admin-shell .admin-login { padding: 16px; }
  .admin-shell .login-card { padding: 24px; }
  .admin-shell .account-panel { padding: 20px; }
  .admin-shell #account-form > .button { width: 100%; }
  .admin-shell #account-retry { margin: 12px 0 0; }
  .topbar { align-items: flex-start; }
  .topnav a:not(:last-child) { display: none; }
  .form-grid { grid-template-columns: 1fr; }
  .full { grid-column: auto; }
  .stats { gap: 8px; }
  .stat { padding: 14px; }
  .stat-value { font-size: 23px; }
  .config-grid { grid-template-columns: 1fr 1fr; }
  .panel-title, .section-head { flex-direction: column; align-items: flex-start; }
}
@media (prefers-reduced-motion: reduce) {
  *, *:before, *:after { scroll-behavior: auto !important; animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
