/* 東達汽車 第五版 A｜電影預告片開場 */
:root {
  --ink: #050505;
  --ink2: #0e0e0f;
  --paper: #f3f1ec;
  --dim: #a9a6a0;
  --red: #e3262d;
  --line: rgba(243, 241, 236, .28);
  --hd: 'Anton', 'Noto Sans TC', 'PingFang TC', sans-serif;
  --tc: 'Noto Sans TC', 'PingFang TC', 'Heiti TC', sans-serif;
  --top: 72px;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { background: var(--ink); color: var(--paper); font: 500 18px/1.6 var(--tc); -webkit-text-size-adjust: 100%; }
body { background: var(--ink); overflow-x: hidden; }
img { display: block; max-width: 100%; }
a { color: inherit; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; }

/* ── 按鈕：細框＋箭頭 ── */
.btn { display: inline-flex; align-items: center; gap: .7em; min-height: 52px; padding: 0 22px; border: 1px solid var(--line);
  color: var(--paper); text-decoration: none; font: 700 18px/1 var(--tc); letter-spacing: .02em; position: relative; overflow: hidden;
  transition: border-color .25s, background-color .25s; white-space: nowrap; }
.btn i { font-style: normal; transition: transform .3s cubic-bezier(.2,.8,.2,1); }
.btn:hover { border-color: var(--paper); background: rgba(243,241,236,.06); }
.btn:hover i { transform: translateX(5px); }
.btn-line { border-color: rgba(6, 199, 85, .75); }
.btn-line::before { content: ''; width: 9px; height: 9px; border-radius: 50%; background: #06c755; box-shadow: 0 0 12px #06c755; }
.btn-line:hover { border-color: #06c755; background: rgba(6,199,85,.08); }
.btn-xl { min-height: 64px; font-size: 22px; padding: 0 28px; }

/* ── 頂欄 ── */
.top { position: fixed; inset: 0 0 auto; height: var(--top); z-index: 50; display: flex; align-items: center; gap: 28px; padding: 0 28px;
  background: linear-gradient(rgba(5,5,5,.88), rgba(5,5,5,.35) 70%, rgba(5,5,5,0)); transition: opacity .6s, transform .6s; }
.top.solid { background: rgba(5,5,5,.94); border-bottom: 1px solid rgba(243,241,236,.08); }
.is-intro .top { opacity: 0; transform: translateY(-12px); pointer-events: none; }
.logo { font: 900 22px/1 var(--tc); letter-spacing: .12em; text-decoration: none; }
.logo span { color: var(--red); }
.nav { display: flex; gap: 26px; margin-left: auto; }
.nav a { text-decoration: none; font-size: 17px; color: rgba(243,241,236,.88); text-shadow: 0 1px 10px rgba(0,0,0,.7); transition: color .2s; }
.nav a:hover { color: var(--paper); }
.top-cta { min-height: 44px; padding: 0 16px; font-size: 16px; background: rgba(5,5,5,.55); }

/* ── ① 預告片 ── */
.film { position: relative; height: 640vh; }
.stage { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; background: #000; }
.plate { position: absolute; left: 50%; top: 50%; width: max(100vw, 177.9vh); aspect-ratio: 2752 / 1536; transform: translate(-50%, -50%);
  transform-origin: 38% 62%; will-change: transform; }
.plate > * { position: absolute; inset: 0; width: 100%; height: 100%; }
.plate .base { object-fit: cover; }
.dark { background: #000; opacity: 1; }
.lights img { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; }
.glow { opacity: 0; }

.vid { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; pointer-events: none; background: #000; }
.rm .vid { display: none; }
.shots { position: absolute; inset: 0; }
.shot { position: absolute; inset: 0; opacity: 0; overflow: hidden; }
.shot img, .shot-video { position: absolute; inset: -6%; width: 112%; height: 112%; max-width: none; object-fit: cover; will-change: transform; }
video.shot-video { opacity: 0; }

.sweep { position: absolute; inset: -20% -60%; pointer-events: none; opacity: 0; will-change: transform, opacity;
  background: linear-gradient(105deg, transparent 42%, rgba(255,255,255,.0) 44%, rgba(255,255,255,.32) 50%, rgba(255,255,255,0) 56%, transparent 58%);
  transform: translateX(-60%); }
.cut { position: absolute; inset: 0; background: #000; opacity: 0; pointer-events: none; }
.bars i { position: absolute; left: 0; right: 0; height: 11vh; background: #000; z-index: 2; transform: scaleY(0); }
.bars i:first-child { top: 0; transform-origin: top; }
.bars i:last-child { bottom: 0; transform-origin: bottom; }
.stage::before { content: ''; position: absolute; inset: 0; z-index: 4; pointer-events: none;
  background: linear-gradient(0deg, rgba(0,0,0,.72) 0%, rgba(0,0,0,.38) 36%, rgba(0,0,0,0) 62%), linear-gradient(90deg, rgba(0,0,0,.28) 0%, rgba(0,0,0,0) 50%); }
.stage::after { content: ''; position: absolute; inset: 0; pointer-events: none; z-index: 3;
  background: radial-gradient(120% 90% at 50% 50%, transparent 55%, rgba(0,0,0,.55) 100%); }

.studio { position: absolute; left: 50%; top: 50%; transform: translate(-50%,-50%); z-index: 6; font: 700 18px/1 var(--tc);
  letter-spacing: .5em; color: var(--dim); white-space: nowrap; opacity: 0; }

/* 標題卡：上下兩半一刀切進來 */
.card { position: absolute; z-index: 6; left: 6vw; bottom: 15vh; max-width: 88vw; pointer-events: none; text-shadow: 0 2px 30px rgba(0,0,0,.55), 0 0 2px rgba(0,0,0,.4); }
.card.right { left: auto; right: 6vw; text-align: right; }
.card .kick { font: 700 20px/1 var(--tc); letter-spacing: .35em; color: var(--paper); opacity: 0; margin-bottom: 14px; }
.card .kick::before { content: ''; display: inline-block; width: 34px; height: 2px; background: var(--red); vertical-align: middle; margin-right: 14px; }
.card.right .kick::before { display: none; }
.card.right .kick::after { content: ''; display: inline-block; width: 34px; height: 2px; background: var(--red); vertical-align: middle; margin-left: 14px; }
.slash { position: relative; display: block; font: 400 clamp(64px, 12.5vw, 210px)/.9 var(--hd); letter-spacing: .01em; color: var(--paper); }
.slash.big { font: 900 clamp(52px, 8.6vw, 150px)/1.02 var(--tc); letter-spacing: -.02em; }
.slash .ghost { visibility: hidden; display: block; }
.slash .half { position: absolute; inset: 0; display: block; white-space: nowrap; will-change: transform, opacity; }
.slash .half.a { clip-path: polygon(0 0, 100% 0, 100% 46%, 0 56%); }
.slash .half.b { clip-path: polygon(0 56%, 100% 46%, 100% 100%, 0 100%); }
.slash .blade { position: absolute; left: -4%; right: -4%; top: 50%; height: 3px; background: var(--red); box-shadow: 0 0 18px var(--red);
  transform: scaleX(0) rotate(-1.6deg); transform-origin: left center; }
.card .sub { font: 700 22px/1.4 var(--tc); color: var(--paper); margin-top: 16px; opacity: 0; }

/* 結尾：價格 */
.final { position: absolute; z-index: 7; left: 6vw; top: 50%; transform: translateY(-46%); max-width: 640px; opacity: 0; visibility: hidden; }
.final-name { font: 700 22px/1.3 var(--tc); color: var(--paper); }
.final-price { font: 400 clamp(110px, 16vw, 250px)/.88 var(--hd); letter-spacing: -.01em; margin: 14px 0 10px; display: flex; align-items: baseline; gap: 10px; }
.final-price span { font: 900 clamp(40px, 4.4vw, 68px)/1 var(--tc); color: var(--red); }
.final-meta { font-size: 20px; color: var(--dim); }
.final-act { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.final-act .btn { background: rgba(5,5,5,.62); }
.final-more { display: inline-block; margin-top: 22px; color: var(--paper); font-size: 18px; text-decoration: none; border-bottom: 1px solid var(--line); padding-bottom: 3px; }
.final-more i { font-style: normal; display: inline-block; animation: bob 1.6s ease-in-out infinite; }
@keyframes bob { 50% { transform: translateY(4px); } }
.stage .shade { position: absolute; inset: 0; z-index: 5; pointer-events: none; opacity: 0;
  background: linear-gradient(90deg, rgba(0,0,0,.82) 0%, rgba(0,0,0,.55) 38%, rgba(0,0,0,0) 70%); }

.tag-ai { position: absolute; right: 18px; bottom: 16px; z-index: 8; font-size: 16px; color: rgba(243,241,236,.8); background: rgba(0,0,0,.45); padding: 4px 10px; }
.cue { position: absolute; left: 50%; bottom: 28px; transform: translateX(-50%); z-index: 8; display: flex; flex-direction: column; align-items: center; gap: 10px;
  font-size: 16px; letter-spacing: .3em; opacity: 0; }
.cue i { width: 1px; height: 46px; background: linear-gradient(var(--paper), transparent); animation: cue 1.8s ease-in-out infinite; transform-origin: top; }
@keyframes cue { 0% { transform: scaleY(0); } 50% { transform: scaleY(1); } 100% { transform: scaleY(1); opacity: 0; } }
.skip { position: absolute; right: 22px; top: 22px; z-index: 60; font-size: 16px; color: var(--dim); border-bottom: 1px solid var(--line); padding: 4px 0; }
body:not(.is-intro) .skip { display: none; }

/* ── ② 現場 17 台 ── */
.garage { position: relative; padding: 120px 0 80px; background: var(--ink); }
.g-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; padding: 0 6vw 28px; flex-wrap: wrap; }
.g-title { font: 900 clamp(40px, 5vw, 76px)/1 var(--tc); letter-spacing: -.01em; }
.g-count { font: 400 1.25em/1 var(--hd); color: var(--red); display: inline-block; min-width: 1.1em; }
.g-tabs { display: flex; gap: 6px; flex-wrap: wrap; }
.g-tabs button { font: 700 18px/1 var(--tc); padding: 12px 14px; color: var(--dim); border-bottom: 2px solid transparent; transition: color .2s, border-color .2s; }
.g-tabs button[aria-selected="true"] { color: var(--paper); border-color: var(--red); }
.g-tabs button:hover { color: var(--paper); }

.g-stage { display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(320px, 1fr); gap: 40px; padding: 0 6vw; align-items: center; }
.g-frame { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: #000; touch-action: pan-y; }
.g-frame img { width: 100%; height: 100%; object-fit: cover; }
.g-flash { position: absolute; inset: 0; background: #000; opacity: 0; pointer-events: none; will-change: opacity; }
.g-frame > img { position: absolute; inset: 0; will-change: transform; }
.g-curtain { position: absolute; left: 0; right: 0; height: 50.5%; background: var(--ink); z-index: 2; pointer-events: none; }
.g-curtain.t { top: 0; } .g-curtain.b { bottom: 0; }
.rm .g-curtain { display: none; }
.g-frame .g-tag { right: 10px; bottom: auto; top: 10px; z-index: 1; }
.g-sold { position: absolute; z-index: 1; left: 16px; top: 16px; font: 900 20px/1 var(--tc); color: var(--paper); background: var(--red); padding: 8px 12px; transform: rotate(-3deg); }
.g-arrow { position: absolute; z-index: 1; top: 50%; width: 56px; height: 56px; margin-top: -28px; border: 1px solid rgba(255,255,255,.6); color: #fff;
  background: rgba(0,0,0,.5); font-size: 22px; transition: background-color .2s; }
.g-arrow:hover { background: rgba(0,0,0,.65); }
.g-arrow.prev { left: 14px; } .g-arrow.next { right: 14px; }
.g-idx { font: 400 22px/1 var(--hd); letter-spacing: .1em; color: var(--dim); }
.g-name { font: 900 clamp(30px, 2.8vw, 44px)/1.15 var(--tc); margin-top: 12px; }
.g-trim { color: var(--dim); font-size: 19px; margin-top: 6px; }
.g-price { font: 400 clamp(84px, 8.4vw, 136px)/.95 var(--hd); margin: 18px 0 8px; display: flex; align-items: baseline; gap: 8px; }
.g-price .u { font: 900 32px/1 var(--tc); color: var(--red); }
.g-price.ask { font: 900 46px/1.1 var(--tc); }
.g-price .digit { display: inline-block; overflow: hidden; height: .95em; vertical-align: top; }
.g-price .digit > span { display: block; }
.g-price .digit > span > span { display: block; height: .95em; line-height: .95em; }
.g-spec { list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 0 18px; border-top: 1px solid var(--line); margin-top: 14px; }
.g-spec li { padding: 10px 0; border-bottom: 1px solid rgba(243,241,236,.12); font-size: 18px; }
.g-spec li b { display: block; font-size: 16px; color: var(--dim); font-weight: 500; }
.g-act { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 22px; }

/* 片條 */
.reel { display: flex; gap: 14px; overflow-x: auto; padding: 34px 6vw 28px; scroll-snap-type: x proximity; scrollbar-width: thin; scrollbar-color: #444 transparent; }
.reel button { flex: 0 0 auto; display: flex; flex-direction: column; width: 210px; text-align: left; scroll-snap-align: start; position: relative; padding: 14px 0 0; }
.reel button::before { content: ''; position: absolute; left: 0; right: 0; top: 0; height: 8px;
  background: repeating-linear-gradient(90deg, #2a2a2a 0 10px, transparent 10px 18px); transition: background .3s; }
.reel .thumb { display: block; aspect-ratio: 16/9; overflow: hidden; background: #111; position: relative; }
.reel img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s; }
.reel .thumb::after { content: ''; position: absolute; inset: 0; background: #000; opacity: .45; transition: opacity .4s; }
.reel button:hover .thumb::after { opacity: .15; }
.reel button[aria-current="true"] .thumb::after { opacity: 0; }
.reel button:hover img { transform: scale(1.04); }
.reel button[aria-current="true"]::before { background: repeating-linear-gradient(90deg, var(--red) 0 10px, transparent 10px 18px); }
.reel .rn { display: block; font: 700 17px/1.3 var(--tc); margin-top: 10px; }
.reel .rp { display: block; font: 400 22px/1.2 var(--hd); color: var(--dim); }
.reel button[aria-current="true"] .rp { color: var(--paper); }
.reel .rs { z-index: 1; position: absolute; left: 8px; top: 8px; font: 900 16px/1 var(--tc); background: var(--red); padding: 5px 8px; }
.reel button[hidden] { display: none; }

/* ── ③ 片尾 ── */
.visit { position: relative; min-height: 100vh; display: grid; place-items: center; padding: 120px 6vw; overflow: hidden;
  background: radial-gradient(70% 60% at 50% 40%, #1a1414 0%, var(--ink) 70%); }
.roll { text-align: center; max-width: 900px; }
.roll-k { font: 700 20px/1 var(--tc); letter-spacing: .4em; color: var(--dim); }
.roll-big { font: 900 clamp(54px, 8vw, 128px)/1.05 var(--tc); letter-spacing: -.02em; margin: 20px 0 36px; }
.roll-act { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; }
.credits { margin: 64px auto 36px; display: grid; gap: 14px; max-width: 520px; }
.credits div { display: grid; grid-template-columns: 1fr 1.6fr; gap: 24px; align-items: baseline; }
.credits dt { text-align: right; color: var(--dim); font-size: 17px; letter-spacing: .3em; }
.credits dd { text-align: left; font: 700 20px/1.4 var(--tc); }
.credits a { text-decoration: none; }
.roll .line-in { display: block; }

.foot { padding: 34px 6vw 46px; border-top: 1px solid rgba(243,241,236,.12); color: var(--dim); font-size: 16px; }
.foot b { color: var(--paper); }

/* ── 關於這個網站 ── */
.about { padding: 90px 6vw 70px; border-top: 1px solid rgba(243,241,236,.12); background: #0b0b0c; }
.about > * { max-width: 760px; }
.about h2 { font: 900 clamp(30px, 3.4vw, 44px)/1.2 var(--tc); margin-bottom: 18px; }
.about h3 { font: 900 24px/1.3 var(--tc); margin: 40px 0 14px; }
.about p { font-size: 18px; line-height: 1.75; color: var(--paper); margin-bottom: 12px; }
.fees { border-top: 1px solid var(--line); margin-bottom: 18px; }
.fees div { display: grid; grid-template-columns: 130px 1fr; gap: 18px; padding: 16px 0; border-bottom: 1px solid rgba(243,241,236,.14); align-items: baseline; }
.fees dt { font: 700 18px/1.4 var(--tc); color: var(--dim); }
.fees dd { font-size: 17px; line-height: 1.6; color: var(--dim); }
.fees dd b { display: block; font: 400 34px/1.1 var(--hd); color: var(--paper); margin-bottom: 4px; letter-spacing: .01em; }
.about-cta { margin-top: 26px; padding: 18px 20px; border-left: 3px solid var(--red); background: rgba(243,241,236,.04); font-weight: 700; }
.real-note { color: var(--dim); font-size: 16px; margin: 18px 0 22px; }
@media (max-width: 860px) {
  .about { padding: 64px 20px 50px; }
  .fees div { grid-template-columns: 1fr; gap: 4px; }
}

/* ── 視窗 ── */
.modal { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 20px; background: rgba(0,0,0,.82); }
.modal[hidden] { display: none; }
.modal-box { background: #111; border: 1px solid var(--line); width: min(980px, 100%); max-height: 90vh; overflow: auto; padding: 22px; }
.modal-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.modal-head h3 { font: 900 24px/1.2 var(--tc); }
.x { font-size: 32px; line-height: 1; width: 48px; height: 48px; border: 1px solid var(--line); }
.qr-box { width: min(640px, 100%); }
.qr-body { display: grid; grid-template-columns: 220px 1fr; gap: 22px; margin-top: 16px; align-items: start; }
.qr-code { background: #fff; padding: 8px; }
.qr-code svg { display: block; width: 100%; height: auto; }
.qr-text { font-size: 17px; color: var(--paper); background: #1b1b1b; padding: 12px; margin-bottom: 14px; }
.qr-tel { margin-top: 14px; color: var(--dim); font-size: 17px; }

/* ── 手機 ── */
@media (max-width: 860px) {
  :root { --top: 60px; }
  .top { padding: 0 16px; gap: 12px; }
  .nav { display: none; }
  .top-cta { margin-left: auto; }
  .film { height: 560vh; }
  .plate { width: 230vw; top: 46%; transform-origin: 36% 62%; transform: translate(-48%, -50%); }
  .vid { inset: auto; left: 50%; top: 46%; width: 230vw; height: auto; aspect-ratio: 16 / 9; transform: translate(-50%, -50%); }
  .card { left: 20px; right: 20px; bottom: 13vh; max-width: none; }
  .card.right { right: 20px; }
  .card .kick { font-size: 18px; }
  .card .sub { font-size: 19px; }
  .slash { font-size: 21vw; }
  .slash.big { font-size: 15vw; }
  .final { left: 20px; right: 20px; top: auto; bottom: 7vh; transform: none; }
  .final-name { font-size: 19px; }
  .final-price { font-size: 34vw; margin: 8px 0 6px; }
  .final-price span { font-size: 11vw; }
  .final-meta { font-size: 17px; }
  .final-act { margin-top: 16px; }
  .final-act .btn { flex: 1 1 100%; justify-content: space-between; }
  .final-more { margin-top: 14px; }
  .stage .shade { background: linear-gradient(0deg, rgba(0,0,0,.92) 0%, rgba(0,0,0,.7) 45%, rgba(0,0,0,0) 72%); }
  .tag-ai { right: 10px; bottom: auto; top: 70px; }
  .cue { bottom: 20px; }
  .skip { top: 16px; right: 16px; }
  .studio { letter-spacing: .3em; }
  .garage { padding: 90px 0 50px; display: flex; flex-direction: column; }
  .g-stage { display: contents; }
  .g-head { order: 1; } .g-frame { order: 2; } .reel { order: 3; } .g-info { order: 4; padding: 6px 20px 0; }
  .g-head { padding: 0 20px 20px; }
  .g-stage { grid-template-columns: 1fr; gap: 22px; padding: 0 20px; }
  .g-frame { margin: 0; }
  .g-arrow { width: 48px; height: 48px; margin-top: -24px; }
  .g-price { font-size: 88px; }
  .g-act .btn { flex: 1 1 100%; justify-content: space-between; }
  .reel { padding: 14px 20px 18px; flex-shrink: 0; }
  .reel button { width: 160px; }
  .visit { padding: 90px 20px; }
  .roll-act .btn { flex: 1 1 100%; justify-content: space-between; }
  .credits div { grid-template-columns: 70px 1fr; gap: 14px; }
  .qr-body { grid-template-columns: 1fr; }
  .qr-code { max-width: 240px; }
}

/* ── 減少動態：不黏住、不跑開場，直接看到亮燈車與價格 ── */
@media (prefers-reduced-motion: reduce) {
  .grain, .cue i, .final-more i { animation: none; }
}
.rm .film { height: auto; }
.rm .stage { position: relative; height: 100vh; height: 100svh; }
.rm .dark, .rm .glow, .rm .cue, .rm .studio, .rm .card, .rm .skip { display: none; }
.rm .final { opacity: 1; visibility: visible; }
.rm .stage .shade { opacity: 1; }
.rm .shots { display: none; }
