/* 小車入庫 官網（garagein.app）— 顏色、字型照 App 的 theme.dart */
:root {
  --bg: #202225;
  --bg-deep: #18191b;
  --paper: #2a2d31;
  --paper2: #33363a;
  --ink: #f5f6f7;
  --muted: #b9bec5;
  --faint: #8a9098;
  --hair: #3a3d42;
  --edge: #575d65;
  --orange: #f36b32;
  --on-orange: #202225;
  --green: #3dbe7a;
  --red: #e0705f;
  --plate: #f2f3f5;
  --plate-ink: #1e2023;
  --radius: 18px;
  --cjk: "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", sans-serif;
  --disp: "Oswald", "Noto Sans TC", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--cjk);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
.wrap { width: min(1120px, 100% - 32px); margin-inline: auto; }

/* 速度線背景（App 的 speedLines） */
.speed {
  background-image: repeating-linear-gradient(-12deg, transparent 0 22px, rgba(255,255,255,.035) 22px 24px);
}

/* ── 頁首 ── */
.top {
  position: sticky; top: 0; z-index: 10;
  background: rgba(24,25,27,.86);
  backdrop-filter: saturate(140%) blur(12px);
  -webkit-backdrop-filter: saturate(140%) blur(12px);
  border-bottom: 1px solid var(--hair);
}
.top .wrap { display: flex; align-items: center; justify-content: space-between; height: 60px; gap: 16px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 900; font-size: 18px; letter-spacing: .04em; }
.brand img { width: 32px; height: 32px; border-radius: 8px; }
.top nav { display: flex; gap: 20px; font-size: 14px; color: var(--muted); }
.top nav a { text-decoration: none; }
.top nav a:hover { color: var(--ink); }
.top .cta {
  text-decoration: none; background: var(--orange); color: var(--on-orange);
  font-weight: 900; font-size: 14px; padding: 7px 14px; border-radius: 999px; white-space: nowrap;
}
@media (max-width: 640px) { .top nav { display: none; } }

/* ── Hero ── */
.hero { padding: 72px 0 88px; overflow: hidden; }
.hero .wrap { display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; }
.eyebrow { font-family: var(--disp); color: var(--orange); letter-spacing: .18em; font-size: 14px; text-transform: uppercase; }
.hero h1 { font-size: clamp(38px, 6vw, 64px); line-height: 1.15; margin: 12px 0 20px; font-weight: 900; letter-spacing: .02em; }
.hero h1 em { font-style: normal; color: var(--orange); }
.hero p.lead { color: var(--muted); font-size: 18px; margin: 0 0 32px; max-width: 32em; }
@media (max-width: 860px) {
  .hero { padding: 48px 0 64px; }
  .hero .wrap { grid-template-columns: 1fr; gap: 40px; }
}

/* 下載按鈕 */
.stores { display: flex; flex-wrap: wrap; gap: 12px; }
.store {
  display: inline-flex; align-items: center; gap: 12px;
  min-width: 190px; padding: 10px 18px 10px 14px; border-radius: 14px;
  background: var(--ink); color: var(--bg); text-decoration: none;
  border: 1px solid var(--ink);
}
.store svg { width: 28px; height: 28px; flex: none; }
.store small { display: block; font-size: 11px; line-height: 1.2; opacity: .75; }
.store b { display: block; font-size: 18px; line-height: 1.2; font-family: var(--disp); letter-spacing: .02em; font-weight: 600; }
.store.soon { background: transparent; color: var(--ink); border-color: var(--edge); cursor: default; }
.store.soon small { color: var(--orange); opacity: 1; font-weight: 700; }
.note { color: var(--faint); font-size: 13px; margin-top: 14px; }

/* 手機示意 */
.phone {
  justify-self: center; width: min(320px, 82vw); aspect-ratio: 9 / 19;
  border-radius: 44px; padding: 12px; background: #0e0f10;
  box-shadow: 0 0 0 2px #3a3d42, 0 40px 80px rgba(0,0,0,.55), 0 0 120px rgba(243,107,50,.12);
  position: relative;
}
.phone::before { content: ""; position: absolute; top: 22px; left: 50%; transform: translateX(-50%); width: 92px; height: 26px; border-radius: 20px; background: #000; z-index: 2; }
.screen { height: 100%; border-radius: 34px; overflow: hidden; background: var(--bg); position: relative; display: flex; flex-direction: column; }
.screen .bar { padding: 60px 20px 10px; font-weight: 900; font-size: 20px; }
.scanbox {
  margin: 6px 20px 0; height: 34%; border-radius: 20px; position: relative;
  background: radial-gradient(120% 90% at 50% 40%, #3b3f45, #1b1c1e);
  display: grid; place-items: center; overflow: hidden;
}
.scanbox .barcode { width: 62%; height: 38%; background: repeating-linear-gradient(90deg, #f5f6f7 0 3px, transparent 3px 5px, #f5f6f7 5px 6px, transparent 6px 10px, #f5f6f7 10px 14px, transparent 14px 16px); opacity: .9; border-radius: 2px; }
.scanbox .laser { position: absolute; left: 12%; right: 12%; height: 2px; background: var(--orange); box-shadow: 0 0 12px var(--orange); animation: laser 2.4s ease-in-out infinite; }
.scanbox .corner { position: absolute; width: 26px; height: 26px; border: 3px solid var(--orange); }
.scanbox .c1 { top: 14px; left: 14px; border-right: 0; border-bottom: 0; border-radius: 8px 0 0 0; }
.scanbox .c2 { top: 14px; right: 14px; border-left: 0; border-bottom: 0; border-radius: 0 8px 0 0; }
.scanbox .c3 { bottom: 14px; left: 14px; border-right: 0; border-top: 0; border-radius: 0 0 0 8px; }
.scanbox .c4 { bottom: 14px; right: 14px; border-left: 0; border-top: 0; border-radius: 0 0 8px 0; }
@keyframes laser { 0%, 100% { top: 28%; } 50% { top: 70%; } }
.result {
  margin: 16px 20px 0; border-radius: 20px; background: var(--paper); border: 1px solid var(--hair);
  padding: 14px; animation: pop 4.8s ease-in-out infinite;
}
.result .pic { background: var(--plate); border-radius: 14px; padding: 8px 10px; }
.result .meta { display: flex; align-items: baseline; gap: 8px; margin-top: 10px; }
.result .no { font-family: var(--disp); color: var(--orange); font-size: 15px; letter-spacing: .04em; }
.result .name { font-family: var(--disp); font-size: 17px; letter-spacing: .02em; }
.badge { display: inline-flex; align-items: center; gap: 6px; margin-top: 8px; font-weight: 900; font-size: 14px; color: var(--green); }
.badge i { width: 18px; height: 18px; border-radius: 50%; background: var(--green); display: grid; place-items: center; }
.badge i::after { content: ""; width: 8px; height: 4px; border: solid var(--bg); border-width: 0 0 2px 2px; transform: translateY(-1px) rotate(-45deg); }
@keyframes pop { 0%, 30% { opacity: 0; transform: translateY(14px); } 40%, 92% { opacity: 1; transform: none; } 100% { opacity: 0; } }
.tabbar { margin-top: auto; display: flex; justify-content: space-around; padding: 12px 10px 22px; background: var(--bg-deep); border-top: 1px solid var(--hair); font-size: 11px; color: var(--faint); }
.tabbar span.on { color: var(--orange); font-weight: 700; }
@media (prefers-reduced-motion: reduce) { .scanbox .laser, .result { animation: none; } .result { opacity: 1; } }

/* ── 區塊 ── */
section { padding: 88px 0; }
section.alt { background: var(--bg-deep); }
.sec-head { max-width: 40em; margin-bottom: 44px; }
.sec-head h2 { font-size: clamp(28px, 4vw, 40px); line-height: 1.25; margin: 10px 0 12px; font-weight: 900; }
.sec-head p { color: var(--muted); margin: 0; }
@media (max-width: 640px) { section { padding: 64px 0; } }

/* 四大功能 */
.features { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.feature {
  background: var(--paper); border: 1px solid var(--hair); border-radius: var(--radius);
  padding: 28px; display: flex; flex-direction: column; gap: 20px; overflow: hidden;
}
.feature .step { font-family: var(--disp); color: var(--orange); font-size: 14px; letter-spacing: .14em; }
.feature h3 { margin: 4px 0 6px; font-size: 22px; line-height: 1.4; font-weight: 900; }
.feature p { margin: 0; color: var(--muted); font-size: 15px; }
.feature .art { margin-top: auto; }
@media (max-width: 760px) { .features { grid-template-columns: 1fr; } .feature { padding: 22px; } }

/* 圖鑑格子 */
.dex { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.slot { aspect-ratio: 1; border-radius: 10px; background: var(--plate); display: grid; place-items: center; position: relative; padding: 6px; }
.slot img { width: 100%; height: 100%; object-fit: contain; }
.slot b { position: absolute; left: 6px; top: 4px; font-family: var(--disp); font-size: 11px; color: var(--plate-ink); font-weight: 500; }
.slot.empty { background: transparent; border: 1.5px dashed var(--edge); }
.slot.empty b { color: var(--faint); position: static; font-size: 15px; }

/* 店裡掃 */
.dup { display: flex; gap: 14px; align-items: center; background: var(--paper2); border-radius: 14px; padding: 12px; }
.dup .pic { width: 44%; background: var(--plate); border-radius: 10px; padding: 6px; flex: none; }
.dup .no { font-family: var(--disp); color: var(--orange); font-size: 14px; }
.dup .name { font-family: var(--disp); font-size: 15px; line-height: 1.3; }
.dup .warn { color: var(--orange); font-weight: 900; font-size: 14px; margin-top: 6px; display: flex; align-items: center; gap: 6px; }
.dup .warn i { width: 18px; height: 18px; border-radius: 50%; background: var(--orange); color: var(--on-orange); font-style: normal; font-size: 12px; display: grid; place-items: center; font-weight: 900; }

/* 新車消息 */
.news { display: grid; gap: 10px; }
.news-row { display: flex; align-items: center; gap: 12px; background: var(--paper2); border-radius: 12px; padding: 8px 12px 8px 8px; }
.news-row .pic { width: 92px; background: var(--plate); border-radius: 8px; padding: 4px; flex: none; }
.news-row .tag { background: var(--orange); color: var(--on-orange); font-size: 11px; font-weight: 700; border-radius: 6px; padding: 1px 7px; }
.news-row .date { font-family: var(--mono); color: var(--faint); font-size: 12px; }
.news-row .name { font-family: var(--disp); font-size: 15px; line-height: 1.3; margin-top: 2px; }

/* 細節清單 */
.details { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.detail { border: 1px solid var(--hair); border-radius: 16px; padding: 22px; background: var(--paper); }
.detail .ico { width: 40px; height: 40px; border-radius: 12px; background: rgba(243,107,50,.14); color: var(--orange); display: grid; place-items: center; margin-bottom: 14px; }
.detail .ico svg { width: 22px; height: 22px; }
.detail h4 { margin: 0 0 6px; font-size: 17px; font-weight: 900; }
.detail p { margin: 0; color: var(--muted); font-size: 14.5px; }
@media (max-width: 900px) { .details { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .details { grid-template-columns: 1fr; } }

/* 隱私承諾 */
.promise { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.promise div { border-left: 3px solid var(--orange); padding: 4px 0 4px 18px; }
.promise h4 { margin: 0 0 4px; font-size: 18px; font-weight: 900; }
.promise p { margin: 0; color: var(--muted); font-size: 15px; }
@media (max-width: 760px) { .promise { grid-template-columns: 1fr; } }

/* 下載 */
.download { text-align: center; }
.download .wrap { display: flex; flex-direction: column; align-items: center; }
.download img.icon { width: 104px; height: 104px; border-radius: 24px; box-shadow: 0 16px 40px rgba(0,0,0,.4); margin-bottom: 24px; }
.download h2 { font-size: clamp(28px, 4vw, 40px); margin: 0 0 10px; font-weight: 900; }
.download p { color: var(--muted); margin: 0 0 28px; }
.download .stores { justify-content: center; }

/* ── 頁尾 ── */
footer { border-top: 1px solid var(--hair); padding: 40px 0 48px; color: var(--faint); font-size: 13px; }
footer .wrap { display: grid; gap: 14px; }
footer .links { display: flex; flex-wrap: wrap; gap: 8px 22px; font-size: 14px; color: var(--muted); }
footer .links a { text-decoration: none; }
footer .links a:hover { color: var(--ink); }
footer p { margin: 0; }

/* ── 文件頁（隱私權、支援） ── */
.doc { padding: 56px 0 88px; }
.doc .wrap { max-width: 760px; }
.doc h1 { font-size: clamp(30px, 5vw, 42px); margin: 8px 0 6px; font-weight: 900; }
.doc .updated { color: var(--faint); font-size: 14px; margin: 0 0 36px; font-family: var(--mono); }
.doc h2 { font-size: 21px; margin: 40px 0 10px; font-weight: 900; padding-top: 8px; border-top: 1px solid var(--hair); }
.doc h2:first-of-type { border-top: 0; }
.doc p, .doc li { color: var(--muted); }
.doc strong { color: var(--ink); }
.doc ul { padding-left: 1.3em; }
.doc li { margin: 4px 0; }
.doc table { width: 100%; border-collapse: collapse; margin: 12px 0; font-size: 15px; }
.doc th, .doc td { text-align: left; vertical-align: top; padding: 10px 12px; border-bottom: 1px solid var(--hair); }
.doc th { color: var(--ink); font-weight: 700; white-space: nowrap; }
.doc td { color: var(--muted); }
.doc .callout { background: var(--paper); border: 1px solid var(--hair); border-radius: 14px; padding: 16px 18px; color: var(--muted); }
.doc a { color: var(--orange); }
.faq details { border: 1px solid var(--hair); border-radius: 14px; background: var(--paper); margin: 10px 0; }
.faq summary { cursor: pointer; padding: 16px 18px; font-weight: 700; list-style: none; position: relative; padding-right: 44px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 18px; top: 50%; transform: translateY(-50%); color: var(--orange); font-family: var(--disp); font-size: 22px; }
.faq details[open] summary::after { content: "–"; }
.faq details > div { padding: 0 18px 16px; color: var(--muted); }
.mail { display: inline-flex; align-items: center; gap: 10px; background: var(--orange); color: var(--on-orange) !important; font-weight: 900; text-decoration: none; padding: 12px 20px; border-radius: 999px; }
@media (max-width: 560px) { .doc table, .doc thead, .doc tbody, .doc tr, .doc th, .doc td { display: block; } .doc th { padding-bottom: 0; border: 0; } }
.sec-head a.inline { color: var(--orange); }
section[id] { scroll-margin-top: 60px; }
