/* BusanSeoulTrains.com
   Palette, sourced from the departure city, Korea's beach capital:
   - Sea: the deep blue water off Haeundae and Gwangalli beaches
   - Coral: the dongbaek camellia, Busan's official city flower
   - Sand: the beaches themselves; Sun: the warm lights of Gwangan Bridge
   Signature mechanic (shared with zermattzurich.com's altimeter idea):
   the header chip counts the kilometres left to Seoul as you scroll, and
   the route line can be "ridden" stop by stop — see script.js. */
:root {
  --sea: #1C7CA8;
  --sea-deep: #0F4C6E;
  --sea-ink: #0B3550;
  --sky: #E5F3F9;
  --coral: #E8505B;
  --coral-deep: #C73A46;
  --coral-soft: #FDE7E8;
  --sun: #F6B44B;
  --sun-soft: #FFF3DD;
  --sand: #FBF8F2;
  --sand-2: #F4EBDD;
  --card: #FFFFFF;
  --ink: #1D2B36;
  --ink-soft: #56656F;
  --line: #E6DFD3;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 10px 30px -14px rgba(15, 76, 110, .28);
  --wrap: 1160px;
  --header-h: 68px;
  --display: "Outfit", "Segoe UI", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 12px); }
body {
  margin: 0;
  font-family: "Nunito Sans", "Segoe UI", Arial, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--sand);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3 { font-family: var(--display); font-weight: 700; line-height: 1.18; margin: 0 0 .5em; color: var(--sea-ink); letter-spacing: -.01em; }
h1 { font-size: clamp(2.1rem, 5vw, 3.6rem); font-weight: 800; }
h2 { font-size: clamp(1.6rem, 3.1vw, 2.3rem); }
h3 { font-size: 1.25rem; font-weight: 600; }
p { margin: 0 0 1em; }
a { color: var(--sea); }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 16px; }
section { padding: 80px 0; }
.section-lede { font-size: 1.08rem; color: var(--ink-soft); max-width: 760px; }

/* ---------- buttons (scoped classes; the tracking class is never styled) ---------- */
.btn {
  display: inline-block; padding: 14px 26px; border-radius: 999px;
  font-family: var(--display); font-weight: 600; text-decoration: none;
  transition: transform .15s ease, background-color .15s ease, box-shadow .15s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--coral); color: #fff; box-shadow: 0 8px 20px -8px rgba(232,80,91,.7); }
.btn-primary:hover { background: var(--coral-deep); }
.btn-light { background: #fff; color: var(--coral-deep); }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(251, 248, 242, .92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  max-width: var(--wrap); margin: 0 auto; padding: 0 16px; height: var(--header-h);
  display: grid; grid-template-columns: auto auto 1fr auto; align-items: center; gap: 16px;
}
.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--sea-ink); font-family: var(--display); font-weight: 700; font-size: 1.05rem; }
.logo-mark {
  width: 36px; height: 36px; border-radius: 50%; background: var(--coral); color: #fff;
  display: grid; place-items: center; font-size: .82rem; letter-spacing: .02em;
}
.logo-text em { font-style: normal; color: var(--coral); }
.logo-arrow { margin: 0 3px; color: var(--sea); }

.km-chip {
  display: inline-flex; align-items: baseline; gap: 6px;
  background: var(--sky); color: var(--sea-deep); border-radius: 999px;
  padding: 6px 14px; font-size: .82rem; white-space: nowrap;
  opacity: 0; transform: translateY(-4px); transition: opacity .3s ease, transform .3s ease;
}
.km-chip.show { opacity: 1; transform: none; }
.km-val { font-family: var(--display); font-weight: 800; font-size: 1.1rem; color: var(--sea-ink); font-variant-numeric: tabular-nums; }
.km-place { color: var(--coral-deep); font-weight: 700; }
.km-place::before { content: "· "; color: var(--ink-soft); font-weight: 400; }

.nav-panel { grid-column: 3; grid-row: 1; justify-self: end; }
.nav-panel ul { list-style: none; display: flex; gap: 20px; margin: 0; padding: 0; }
@media (max-width: 1100px) { .nav-panel ul { gap: 14px; } .nav-panel a { font-size: .9rem; } }
.nav-panel a { color: var(--ink); text-decoration: none; font-weight: 600; font-size: .95rem; white-space: nowrap; }
.nav-panel a:hover { color: var(--coral); }
.header-cta {
  grid-column: 4; grid-row: 1;
  background: var(--coral); color: #fff; padding: 9px 18px; border-radius: 999px;
  font-family: var(--display); font-weight: 600; font-size: .92rem; text-decoration: none;
}
.header-cta:hover { background: var(--coral-deep); }
.nav-panel .nav-cta { display: none; }
.nav-toggle { display: none; }

@media (max-width: 1040px) { .km-unit { display: none; } }
@media (max-width: 859px) {
  .header-inner { grid-template-columns: 1fr auto; gap: 10px; }
  .km-chip { display: none; }
  .header-inner > .header-cta { display: none; }
  .nav-toggle {
    grid-column: 2; display: inline-flex; flex-direction: column; justify-content: center; gap: 5px;
    width: 42px; height: 42px; padding: 0 10px; background: #fff;
    border: 1px solid var(--line); border-radius: 12px; cursor: pointer;
  }
  .nav-toggle span { display: block; height: 2px; background: var(--sea-ink); border-radius: 2px; transition: transform .2s, opacity .2s; }
  .nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
  .nav-panel {
    position: absolute; top: var(--header-h); left: 0; right: 0;
    grid-column: 1 / -1; justify-self: stretch;
    background: var(--sand); border-bottom: 1px solid var(--line); display: none;
  }
  .nav-panel.open { display: block; }
  .nav-panel ul { flex-direction: column; gap: 0; padding: 8px 16px 16px; }
  .nav-panel a { display: block; padding: 12px 0; border-bottom: 1px solid var(--line); }
  .nav-panel .nav-cta { display: block; padding-top: 14px; }
  .nav-panel .nav-cta a.header-cta {
    display: block; width: 100%; text-align: center; padding: 14px 18px; border: 0;
    background: var(--coral-deep); color: #fff; font-size: 1rem;
  }
  .nav-panel .nav-cta a.header-cta:hover { background: var(--coral); color: #fff; }
  .logo-text { font-size: .92rem; line-height: 1.15; }
}

/* ---------- hero ---------- */
.hero {
  position: relative; padding: 0; color: #fff; overflow: hidden;
  background:
    radial-gradient(circle at 82% 18%, rgba(246,180,75,.55) 0 70px, rgba(246,180,75,0) 210px),
    linear-gradient(180deg, #5DB7DE 0%, #2A8FBF 38%, #13618A 100%);
}
.hero-bg { position: absolute; inset: auto 0 0 0; height: 220px; pointer-events: none; }
.hero-waves { width: 100%; height: 100%; display: block; }
.hero-inner { position: relative; z-index: 1; max-width: var(--wrap); margin: 0 auto; padding: 64px 16px 150px; }
.hero-badge {
  display: inline-flex; gap: 10px; align-items: center;
  background: rgba(255,255,255,.18); border: 1px solid rgba(255,255,255,.35);
  border-radius: 999px; padding: 6px 16px; font-weight: 700; font-size: .9rem; margin-bottom: 18px;
}
.hb-arrow { color: var(--sun); }
.hero h1 { color: #fff; max-width: 900px; text-shadow: 0 2px 18px rgba(11,53,80,.25); }
.h1-sub { display: block; font-weight: 500; font-size: .5em; margin-top: .35em; color: #EAF6FB; }
.hero-lede { max-width: 720px; font-size: 1.1rem; color: #F1F9FC; }
.search-card {
  background: #fff; color: var(--ink); border-radius: 22px; padding: 22px 22px 14px;
  box-shadow: 0 24px 50px -22px rgba(11,53,80,.55); margin: 30px 0 28px;
}
.search-card h2 { font-size: 1.15rem; margin-bottom: 10px; color: var(--sea-ink); }
#firebird-search-widget { min-height: 120px; }
.search-note { font-size: .88rem; color: var(--ink-soft); margin: 10px 0 0; }
.hero-facts { display: grid; grid-template-columns: repeat(4, auto); justify-content: start; gap: 12px 40px; margin: 0; }
.hero-facts dt { font-size: .8rem; text-transform: uppercase; letter-spacing: .07em; color: #D7EEF7; }
.hero-facts dd { margin: 0; font-family: var(--display); font-weight: 700; font-size: 1.35rem; color: #fff; }
@media (max-width: 700px) {
  .hero-inner { padding: 40px 16px 120px; }
  .hero-facts { grid-template-columns: 1fr 1fr; gap: 14px 24px; }
  .search-card { padding: 16px 14px 10px; }
}

/* ---------- glance ---------- */
.glance { padding-top: 40px; }
.glance-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 28px; }
.glance-card {
  background: var(--card); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow);
  display: flex; flex-direction: column; gap: 6px;
}
.g-num { font-family: var(--display); font-size: 1.75rem; font-weight: 800; color: var(--sea); }
.glance-card:nth-child(2) .g-num { color: var(--coral); }
.g-label { color: var(--ink-soft); font-size: .95rem; }
@media (max-width: 760px) { .glance-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 460px) { .glance-grid { gap: 10px; } .glance-card { padding: 14px; } .g-num { font-size: 1.3rem; } .g-label { font-size: .85rem; } }

/* ---------- route line + stage cards ---------- */
.route { background: var(--sky); }
.route-intro { columns: 2; column-gap: 40px; column-fill: balance; max-width: 1100px; }
/* paragraphs may flow across the column break so both columns end at about the same height (same reading order) */
.route-intro p { break-inside: auto; orphans: 2; widows: 2; }
.route-intro p:last-child { margin-bottom: 0; }
@media (max-width: 860px) { .route-intro { columns: 1; } }
.line-card { margin: 28px 0 20px; background: #fff; border-radius: 22px; padding: 18px 20px 14px; box-shadow: var(--shadow); }
.ride-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 22px; margin-bottom: 4px; }
.ride-btn {
  font: inherit; font-family: var(--display); font-weight: 600; cursor: pointer;
  background: var(--coral); color: #fff; border: 0; border-radius: 999px; padding: 10px 20px;
}
.ride-btn:hover { background: var(--coral-deep); }
.ride-btn[aria-pressed="true"] { background: var(--sea-deep); }
.ride-icon { display: inline-block; width: 1em; }
.ride-readout { display: flex; align-items: baseline; gap: 10px; }
.ride-clock { font-family: var(--display); font-weight: 800; font-size: 1.5rem; color: var(--sea-ink); font-variant-numeric: tabular-nums; }
.ride-place { color: var(--coral-deep); font-weight: 700; }
.line-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.line-svg { display: block; width: 100%; min-width: 720px; height: auto; }
.ln-base { stroke: #CFE5EF; stroke-width: 10; stroke-linecap: round; fill: none; }
.ln-trail { stroke: var(--sea); stroke-width: 10; stroke-linecap: round; fill: none; stroke-dasharray: 920; stroke-dashoffset: 920; }
.ln-tunnel { stroke: var(--sea-ink); stroke-width: 10; stroke-dasharray: 6 5; fill: none; }
.ln-srt { stroke: var(--sun); stroke-width: 4; stroke-dasharray: 2 6; stroke-linecap: round; fill: none; }
.ln-note { font-size: 12px; fill: var(--ink-soft); font-family: "Nunito Sans", Arial, sans-serif; }
.ln-note.srt { fill: #B07A1E; font-weight: 700; }
.stop { cursor: pointer; }
.stop circle { fill: #fff; stroke: var(--sea); stroke-width: 4; transition: fill .2s, r .2s; }
.stop.major circle { stroke: var(--coral); stroke-width: 5; }
.stop text { font-family: var(--display); font-weight: 600; font-size: 14px; fill: var(--sea-ink); text-anchor: middle; }
.stop:hover circle, .stop:focus circle { fill: var(--sun-soft); }
.stop.on circle { fill: var(--coral); stroke: var(--coral-deep); }
.stop:focus { outline: none; }
.stop:focus-visible circle { stroke: var(--sun); stroke-width: 6; }
.ride-train rect { fill: var(--coral); }
.ride-train rect.win { fill: #fff; }
.ride-halo { fill: rgba(232,80,91,.18); }
.line-card figcaption { font-size: .85rem; color: var(--ink-soft); margin-top: 6px; }

.stage-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 14px; }
.stage-tabs button {
  font: inherit; font-weight: 700; font-size: .9rem; cursor: pointer;
  background: #fff; color: var(--sea-deep); border: 1.5px solid #CFE5EF; border-radius: 999px; padding: 7px 14px;
}
.stage-tabs button[aria-selected="true"] { background: var(--sea); color: #fff; border-color: var(--sea); }
.stage { display: none; grid-template-columns: 300px 1fr; background: #fff; border-radius: 22px; overflow: hidden; box-shadow: var(--shadow); }
.stage.active { display: grid; animation: stageIn .35s ease; }
@keyframes stageIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.stage-head {
  min-height: 200px; padding: 22px; color: #fff;
  display: flex; flex-direction: column; justify-content: space-between;
  background: linear-gradient(150deg, var(--sea) 0%, var(--sea-deep) 100%);
}
.stage-head.s1 { background: linear-gradient(150deg, #2E9C9A, #1B6E7A); }
.stage-head.s2 { background: linear-gradient(150deg, #E8505B, #B83545); }
.stage-head.s3 { background: linear-gradient(150deg, #E89A3C, #C26E1E); }
.stage-head.s4 { background: linear-gradient(150deg, #5B7FCB, #3A58A0); }
.stage-head.s5 { background: linear-gradient(150deg, #24486E, #13263F); }
.stage-ko { font-family: var(--display); font-weight: 800; font-size: 2rem; line-height: 1.15; }
.stage-min { align-self: flex-start; background: rgba(255,255,255,.2); border-radius: 999px; padding: 4px 12px; font-weight: 700; font-size: .85rem; }
.stage-body { padding: 26px 28px; align-self: center; }
@media (max-width: 700px) {
  .stage { grid-template-columns: 1fr; }
  .stage-head { min-height: 120px; }
}

/* ---------- trains ---------- */
.train-cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; margin: 28px 0 20px; }
.train-card { background: var(--card); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); border-top: 5px solid var(--sea); }
.tc-cheong { border-top-color: var(--coral); }
.tc-slow { border-top-color: var(--sun); }
.tc-tag { display: inline-block; font-size: .75rem; font-weight: 800; text-transform: uppercase; letter-spacing: .07em; color: var(--sea-deep); background: var(--sky); border-radius: 999px; padding: 3px 10px; }
.tc-cheong .tc-tag { color: var(--coral-deep); background: var(--coral-soft); }
.tc-slow .tc-tag { color: #8A5B12; background: var(--sun-soft); }
.train-card h3 { margin-top: 10px; }
.train-card ul { margin: 0; padding-left: 1.1em; color: var(--ink-soft); font-size: .95rem; }
.note { background: var(--sun-soft); border-radius: var(--radius); padding: 16px 20px; color: #6B5427; }
@media (max-width: 760px) { .train-cards { grid-template-columns: 1fr; } }

/* ---------- history ---------- */
.history { background: var(--sand-2); }
.timeline { list-style: none; margin: 28px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.timeline li { background: #fff; border-radius: var(--radius); padding: 18px 20px; box-shadow: var(--shadow); }
.tl-year { display: inline-block; font-family: var(--display); font-weight: 800; font-size: 1.05rem; color: #fff; background: var(--sea); border-radius: 999px; padding: 2px 12px; margin-bottom: 8px; }
.timeline li:last-child .tl-year { background: var(--coral); }
.timeline p { color: var(--ink-soft); font-size: .96rem; margin: 0; }
@media (max-width: 860px) { .timeline { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .timeline { grid-template-columns: 1fr; } }

/* ---------- arrive ---------- */
.arrive-split { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 26px; }
.arrive-split article { background: var(--card); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); }
.arrive-split article:nth-child(2) { background: var(--coral-soft); box-shadow: none; }
@media (max-width: 860px) { .arrive-split { grid-template-columns: 1fr; } }

/* ---------- schedule / planner ---------- */
.schedule { background: var(--card); }
.planner { background: linear-gradient(150deg, var(--sea) 0%, var(--sea-deep) 100%); color: #EAF6FB; border-radius: 22px; padding: 26px; margin: 28px 0 40px; }
.planner h3 { color: #fff; }
.planner p { color: #D3EAF3; font-size: .95rem; }
.planner-form { display: flex; flex-wrap: wrap; gap: 16px; margin: 10px 0 20px; }
.planner-form label { display: flex; flex-direction: column; gap: 6px; font-size: .85rem; font-weight: 700; color: #fff; flex: 1 1 220px; }
.planner-form select, .planner-form input {
  font: inherit; font-size: 1rem; padding: 11px 14px; border-radius: 12px; border: 0; background: #fff; color: var(--ink);
}
.planner-form label { min-width: 0; }
.planner-form select, .planner-form input { width: 100%; min-width: 0; max-width: 100%; box-sizing: border-box; }
.board { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px; background: #fff; color: var(--ink-soft); border-radius: 16px; padding: 18px 22px; font-weight: 700; }
.board b { display: block; font-family: var(--display); font-size: 2.1rem; color: var(--sea-ink); font-variant-numeric: tabular-nums; }
.b-to { text-align: right; }
.b-dur { background: var(--coral-soft); color: var(--coral-deep); border-radius: 999px; padding: 6px 14px; text-align: center; }
@media (max-width: 520px) { .board { grid-template-columns: 1fr; } .b-to { text-align: left; } .b-dur { justify-self: start; } }
.table-wrap { overflow-x: auto; margin: 16px 0 22px; border-radius: var(--radius); background: var(--card); box-shadow: var(--shadow); }
table { border-collapse: collapse; width: 100%; min-width: 560px; font-size: .96rem; }
th, td { text-align: left; padding: 13px 16px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { background: var(--sky); font-family: var(--display); font-weight: 600; color: var(--sea-ink); }
tr:last-child td { border-bottom: 0; }

/* ---------- fares / classes / onboard ---------- */
.fares { background: var(--sand); }
.cta-inline { margin-top: 18px; }
.classes { background: var(--card); }
.class-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 22px; }
.class-grid article { background: var(--card); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow); }
.classes .class-grid article { background: var(--sand); box-shadow: none; }
@media (max-width: 860px) { .class-grid { grid-template-columns: 1fr; } }

/* ---------- departure ---------- */
.depart { background: var(--sea-deep); color: #E3F1F7; }
.depart h2 { color: #fff; }
.depart-cols { display: grid; grid-template-columns: 1.1fr 1fr; gap: 40px; align-items: stretch; }
.depart-text p { word-break: keep-all; overflow-wrap: break-word; }
.depart-text p:last-child { margin-bottom: 0; }
.depart-side { position: relative; min-height: 280px; }
.tick-list { list-style: none; margin: 36px 0 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; column-gap: 40px; }
.tick-list li:last-child:nth-child(odd) { grid-column: 1 / -1; }
.tick-list li { padding: 11px 0 11px 34px; border-bottom: 1px solid rgba(255,255,255,.14); position: relative; }
.tick-list li::before { content: "✓"; position: absolute; left: 0; top: 10px; width: 22px; height: 22px; border-radius: 50%; background: var(--sun); color: var(--sea-ink); font-size: .8rem; font-weight: 800; display: grid; place-items: center; }
@media (max-width: 860px) {
  .depart-cols { grid-template-columns: 1fr; gap: 24px; }
  .depart-side { min-height: 0; aspect-ratio: 3 / 2; align-self: start; width: 100%; }
  .tick-list { grid-template-columns: 1fr; margin-top: 24px; }
}

/* ---------- access / stopovers / compare ---------- */
.access { background: var(--card); }
.access p { max-width: 820px; }
.stopovers { background: var(--sky); }
.stopovers .class-grid article:nth-child(1) { border-top: 5px solid #2E9C9A; }
.stopovers .class-grid article:nth-child(2) { border-top: 5px solid var(--coral); }
.stopovers .class-grid article:nth-child(3) { border-top: 5px solid var(--sun); }

/* ---------- tips ---------- */
.tips { background: var(--sand); }
.tips-list { list-style: none; counter-reset: tip; padding: 0; margin: 24px 0 0; display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.tips-list li { counter-increment: tip; position: relative; background: #fff; border-radius: var(--radius); padding: 22px 22px 18px 74px; box-shadow: var(--shadow); }
.tips-list li::before {
  content: counter(tip); position: absolute; left: 22px; top: 20px;
  width: 36px; height: 36px; border-radius: 50%; background: var(--coral); color: #fff;
  font-family: var(--display); font-weight: 800; display: grid; place-items: center;
}
.tips-list h3 { font-size: 1.1rem; margin-bottom: .3em; }
.tips-list p { margin: 0; color: var(--ink-soft); }
@media (max-width: 760px) { .tips-list { grid-template-columns: 1fr; } }

/* ---------- ticket ---------- */
.ticket { background: var(--card); }
.ticket-inner { display: grid; grid-template-columns: 1.4fr 1fr; gap: 40px; align-items: center; }
.ticket-mock {
  margin: 0; background: var(--sky); border-radius: 20px; padding: 22px 24px; position: relative;
  box-shadow: var(--shadow); border-left: 10px solid var(--coral);
}
.ticket-mock::after { content: ""; position: absolute; right: 64px; top: 12px; bottom: 12px; border-left: 2px dashed #B9D8E6; }
.ticket-mock div { display: grid; grid-template-columns: 90px 1fr; gap: 8px; padding: 6px 0; }
.ticket-mock dt { color: var(--ink-soft); font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; padding-top: 3px; }
.ticket-mock dd { margin: 0; font-family: var(--display); font-weight: 700; color: var(--sea-ink); }
@media (max-width: 860px) { .ticket-inner { grid-template-columns: 1fr; } }

/* ---------- faq ---------- */
.faq { background: var(--sand); }
.faq-list { margin-top: 20px; display: grid; gap: 10px; }
.faq-list details { background: #fff; border-radius: 14px; padding: 2px 20px; box-shadow: 0 4px 14px -10px rgba(15,76,110,.35); }
.faq-list summary { cursor: pointer; list-style: none; padding: 16px 34px 16px 0; position: relative; font-family: var(--display); font-weight: 600; color: var(--sea-ink); }
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after {
  content: "+"; position: absolute; right: 0; top: 13px; width: 26px; height: 26px; border-radius: 50%;
  background: var(--sky); color: var(--sea); display: grid; place-items: center; font-weight: 700;
}
.faq-list details[open] summary::after { content: "–"; background: var(--coral); color: #fff; }
.faq-list p { color: var(--ink-soft); }

/* ---------- final CTA + footer ---------- */
.cta-band { background: linear-gradient(135deg, var(--coral) 0%, #F07A52 100%); color: #fff; text-align: center; }
.cta-band h2 { color: #fff; }
.cta-band p { opacity: .95; }
.site-footer { background: var(--sea-ink); color: #B8CEDA; padding: 40px 0; font-size: .9rem; }
.site-footer a { color: #fff; text-decoration: underline; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn, .stage.active { transition: none; animation: none; }
}

/* ---------- photography ---------- */
.hero-photo { position: absolute; inset: 0; }
.hero-img { width: 100%; height: 100%; object-fit: cover; object-position: 65% 50%; display: block; }
.hero-photo::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(90deg, rgba(11,53,80,.82) 0%, rgba(11,53,80,.55) 45%, rgba(11,53,80,.08) 75%),
    linear-gradient(180deg, rgba(11,53,80,.25) 0%, rgba(11,53,80,0) 30%);
}
.hero-bg { z-index: 1; }
@media (max-width: 860px) {
  .hero-photo::after { background: linear-gradient(180deg, rgba(11,53,80,.7) 0%, rgba(11,53,80,.55) 55%, rgba(11,53,80,.35) 100%); }
}

.stage { grid-template-columns: 380px 1fr; }
.stage-head { position: relative; min-height: 280px; overflow: hidden; isolation: isolate; }
.stage-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.stage-head::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(180deg, rgba(11,53,80,.55) 0%, rgba(11,53,80,.05) 45%, rgba(11,53,80,.6) 100%);
}
.stage-ko { text-shadow: 0 2px 12px rgba(0,0,0,.35); }
@media (max-width: 700px) { .stage { grid-template-columns: 1fr; } .stage-head { min-height: 220px; } }

.card-img {
  display: block; width: calc(100% + 48px); max-width: none; height: auto; aspect-ratio: 16 / 9; object-fit: cover;
  margin: -24px -24px 18px; border-radius: var(--radius) var(--radius) 0 0;
}
.train-card { overflow: hidden; border-top: 0; }
.train-card .card-img { border-bottom: 5px solid var(--sea); }
.train-card.tc-cheong .card-img { border-bottom-color: var(--coral); }
.train-card.tc-slow .card-img { border-bottom-color: var(--sun); }
.class-grid article { overflow: hidden; }
.class-grid .card-img { width: calc(100% + 44px); margin: -22px -22px 16px; aspect-ratio: 3 / 2; }
.stopovers .class-grid article { border-top: 0 !important; }
.arrive-split article:first-child .card-img { aspect-ratio: 3 / 2; }

.depart-img { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 45%; border-radius: 22px; box-shadow: 0 16px 34px -18px rgba(0,0,0,.5); }

.cta-band { position: relative; overflow: hidden; isolation: isolate; padding: 110px 0; }
.cta-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.cta-band::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(11,53,80,.1) 0%, rgba(11,53,80,.45) 60%, rgba(11,53,80,.7) 100%); }
.cta-band h2, .cta-band p { text-shadow: 0 2px 14px rgba(0,0,0,.3); }

/* hero: photo band on top, search card overlapping its lower edge */
.hero { --photo-h: clamp(560px, 72vh, 680px); background: var(--sand); }
.hero-photo { inset: 0 0 auto 0; height: var(--photo-h); }
.hero-bg { inset: auto 0 auto 0; top: calc(var(--photo-h) - 140px); height: 140px; }
.hero-inner { padding-bottom: 40px; }
.hero-facts dt { color: var(--ink-soft); }
.hero-facts dd { color: var(--sea-ink); }
.hero-facts { padding: 4px 4px 0; }
@media (max-width: 700px) {
  .hero { --photo-h: 640px; }
  .hero-inner { padding-bottom: 28px; }
}

/* ---------- arriving in Seoul: featured card + icon info cards ---------- */
.arrive-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-top: 26px; }
.arrive-main {
  grid-column: 1 / -1; display: grid; grid-template-columns: 1.1fr 1fr; overflow: hidden;
  background: var(--card); border-radius: 22px; box-shadow: var(--shadow);
}
.arrive-main { isolation: isolate; }
/* photo lives in its own box; the img is absolutely positioned inside it, so no percentage height has to resolve against the grid (WebKit stretched it over the text) */
.arrive-photo { position: relative; margin: 0; min-height: 300px; overflow: hidden; background: var(--sky); }
.arrive-photo::before { content: ""; display: block; padding-top: 67.08%; } /* sizes the box from its width (1200x805 photo); stretches taller if the text is taller */
.arrive-photo .card-img { position: absolute; top: 0; left: 0; width: 100%; height: 100%; max-width: none; margin: 0; border-radius: 0; aspect-ratio: auto; object-fit: cover; }
.arrive-main-body { position: relative; z-index: 1; background: var(--card); padding: 30px 32px; align-self: center; }
.info-card {
  position: relative; background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 24px 24px 20px 92px;
}
.info-card:nth-of-type(2) { background: var(--coral-soft); box-shadow: none; }
.info-card:nth-of-type(3) { background: var(--sky); box-shadow: none; }
.info-icon {
  position: absolute; left: 24px; top: 24px; width: 50px; height: 50px; border-radius: 16px;
  display: grid; place-items: center; background: #fff; box-shadow: 0 6px 16px -10px rgba(15,76,110,.6);
}
.info-icon svg { width: 28px; height: 28px; fill: none; stroke: var(--coral-deep); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.info-card:nth-of-type(3) .info-icon svg { stroke: var(--sea); }
.info-card p { margin: 0; }
@media (max-width: 860px) {
  .arrive-grid { grid-template-columns: 1fr; }
  .arrive-main { grid-template-columns: 1fr; }
  .arrive-photo { min-height: 0; }
  .arrive-photo::before { padding-top: 66.667%; }
  .arrive-main-body { padding: 22px; align-self: stretch; }
}
@media (max-width: 460px) { .info-card { padding: 84px 20px 20px; } .info-icon { left: 20px; top: 20px; } }

/* ---------- classes: photo pair + amenity strip ---------- */
.class-grid.class-pair { grid-template-columns: 1fr 1fr; }
.onboard-strip {
  margin-top: 18px; display: grid; grid-template-columns: 1.4fr 1fr; gap: 24px 36px; align-items: center;
  background: var(--sky); border-radius: 22px; padding: 26px 30px;
}
.onboard-strip p { margin: 0; color: var(--ink); }
.amenity-chips { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.amenity-chips li {
  background: #fff; color: var(--sea-deep); border-radius: 999px; padding: 7px 14px;
  font-weight: 700; font-size: .88rem; box-shadow: 0 4px 12px -8px rgba(15,76,110,.5);
}
.amenity-chips li::before { content: "✓ "; color: var(--coral); }
.amenity-chips li:last-child::before { content: "✕ "; color: var(--ink-soft); }
@media (max-width: 860px) {
  .class-grid.class-pair { grid-template-columns: 1fr; }
  .onboard-strip { grid-template-columns: 1fr; padding: 22px; }
}

/* hero v3: photo behind everything, widget straight on the photo (no card),
   intro copy and key facts below the search — search stays on screen one */
.hero { background: var(--sea-ink); }
.hero-photo { inset: 0; height: auto; }
.hero-photo::after {
  background:
    linear-gradient(90deg, rgba(11,53,80,.78) 0%, rgba(11,53,80,.45) 50%, rgba(11,53,80,.15) 80%),
    linear-gradient(180deg, rgba(11,53,80,.2) 0%, rgba(11,53,80,0) 25%, rgba(11,53,80,.55) 70%, rgba(11,53,80,.8) 100%);
}
.hero-bg { top: auto; bottom: 0; height: 110px; }
.hero-inner { padding: 36px 16px 120px; }
.hero h1 { margin-bottom: .45em; }
.hero-search { margin: 6px 0 26px; }
.hero-search h2 { color: #fff; font-size: 1.05rem; font-weight: 600; margin: 0 0 10px; text-shadow: 0 1px 10px rgba(0,0,0,.35); }
.hero-search #firebird-search-widget { min-height: 0; }
.hero-after { max-width: 760px; }
.hero-after .hero-lede { color: #F1F9FC; }
.hero-after .search-note { color: #D3EAF3; font-size: .9rem; margin: -4px 0 22px; }
.hero-facts dt { color: #CFE7F2; }
.hero-facts dd { color: #fff; }
@media (max-width: 860px) {
  .hero-photo::after { background: linear-gradient(180deg, rgba(11,53,80,.65) 0%, rgba(11,53,80,.45) 40%, rgba(11,53,80,.8) 100%); }
}
@media (max-width: 700px) {
  .hero-inner { padding: 18px 16px 100px; }
  .hero-badge, .h1-sub { display: none; }
  .hero h1 { font-size: 2rem; margin-bottom: .35em; }
  .hero-search { margin-bottom: 22px; }
}

/* search widget on the photo (same fixes as zermattzurich.com):
   drop the widget's own outer padding so the date field isn't squeezed,
   make its out-of-field text readable on the photo, and give the stacked
   mobile date row a white background */
.hero-search #firebird-search-widget > div { padding: 0; }
.hero-search #firebird-search-widget .ant-checkbox-wrapper,
.hero-search #firebird-search-widget .ant-checkbox-wrapper span,
.hero-search #firebird-search-widget > div > :not(form) { color: #fff; text-shadow: 0 1px 6px rgba(10,16,20,.7); }
@media (max-width: 767px) {
  .hero-search #firebird-search-widget form > div:has(.search-date-label) { background: #fff; border-radius: 8px; }
}
