@font-face { font-family: 'Atkinson Hyperlegible'; font-style: normal; font-weight: 400; font-display: swap; src: url('/assets/fonts/atkinson-hyperlegible-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Atkinson Hyperlegible'; font-style: normal; font-weight: 700; font-display: swap; src: url('/assets/fonts/atkinson-hyperlegible-latin-700-normal.woff2') format('woff2'); }
@font-face { font-family: 'Barlow Condensed'; font-style: normal; font-weight: 600; font-display: swap; src: url('/assets/fonts/barlow-condensed-latin-600-normal.woff2') format('woff2'); }
@font-face { font-family: 'Barlow Condensed'; font-style: normal; font-weight: 700; font-display: swap; src: url('/assets/fonts/barlow-condensed-latin-700-normal.woff2') format('woff2'); }
/* Layout: one column. The refund figure comes first, then receipts to edit, then the airport steps. */
:root {
  --bg: #EEF2F5;
  --surface: #FFFFFF;
  --ink: #13202B;
  --muted: #566673;
  --line: #D3DBE2;
  --accent: #0B4A8C;
  --accent-ink: #FFFFFF;
  --tint: #E4EDF6;
  --signal: #F2C200;
  --signal-ink: #1A1500;
  --hero-bg: #0B3A6B;
  --hero-ink: #FFFFFF;
  --hero-muted: #B7CBE0;
  --ok: #0F7A55;
  --ok-bg: #DDF2E8;
  --no: #8A5200;
  --no-bg: #FFF0D1;
  --idle-bg: #E8EDF1;
  --font-body: 'Atkinson Hyperlegible', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-num: 'Barlow Condensed', 'Atkinson Hyperlegible', system-ui, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0D151C;
    --surface: #15202A;
    --ink: #E6ECF1;
    --muted: #92A3B1;
    --line: #28384A;
    --accent: #7DB8F5;
    --accent-ink: #0D151C;
    --tint: #1B2B3B;
    --hero-bg: #12395F;
    --hero-ink: #FFFFFF;
    --hero-muted: #A9C3DD;
    --ok: #5ED0A0;
    --ok-bg: #123A2C;
    --no: #F2B866;
    --no-bg: #3A2C10;
    --idle-bg: #1E2B37;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0D151C;
  --surface: #15202A;
  --ink: #E6ECF1;
  --muted: #92A3B1;
  --line: #28384A;
  --accent: #7DB8F5;
  --accent-ink: #0D151C;
  --tint: #1B2B3B;
  --hero-bg: #12395F;
  --hero-ink: #FFFFFF;
  --hero-muted: #A9C3DD;
  --ok: #5ED0A0;
  --ok-bg: #123A2C;
  --no: #F2B866;
  --no-bg: #3A2C10;
  --idle-bg: #1E2B37;
  color-scheme: dark;
}
html[lang="ja"] { --font-body: 'Atkinson Hyperlegible', 'Hiragino Sans', 'Hiragino Kaku Gothic ProN', 'Yu Gothic', 'Meiryo', 'Noto Sans JP', sans-serif; }
html[lang="zh-CN"] { --font-body: 'Atkinson Hyperlegible', 'PingFang SC', 'Microsoft YaHei', 'Noto Sans SC', sans-serif; }
html[lang="zh-TW"] { --font-body: 'Atkinson Hyperlegible', 'PingFang TC', 'Microsoft JhengHei', 'Noto Sans TC', sans-serif; }
html[lang="th"] { --font-body: 'Atkinson Hyperlegible', 'Noto Sans Thai', 'Leelawadee UI', 'Thonburi', 'Sarabun', sans-serif; }
html[lang="vi"] { --font-body: system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif; }
html[lang="ko"] { --font-body: 'Atkinson Hyperlegible', 'Apple SD Gothic Neo', 'Malgun Gothic', 'Noto Sans KR', sans-serif; }

* { box-sizing: border-box; }
body {
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.55 var(--font-body);
  padding-block: 20px 56px;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}
.wrap { max-width: 720px; margin: 0 auto; display: grid; gap: 28px; }
h1, h2, h3, p, ol, ul, dl, dd { margin: 0; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.top { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.tag { background: var(--signal); color: var(--signal-ink); font-weight: 700; font-size: 13px; letter-spacing: .04em; padding: 5px 10px; border-radius: 4px; }
select, input[type="text"], input[type="number"], input[type="date"] {
  font: inherit; color: var(--ink); background: var(--surface);
  border: 1px solid var(--line); border-radius: 8px; height: 44px; padding: 0 12px; min-width: 0;
}
.langpick select { padding-right: 8px; }

.intro { display: grid; gap: 10px; }
h1 { font-size: clamp(26px, 6.2vw, 38px); line-height: 1.2; font-weight: 700; text-wrap: balance; }
.lead { color: var(--muted); max-width: 60ch; }

.hero { background: var(--hero-bg); color: var(--hero-ink); border-radius: 14px; padding: 22px 20px 20px; }
.hero-label { color: var(--hero-muted); font-size: 14px; letter-spacing: .06em; font-weight: 700; }
.hero-fig { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-top: 4px; font-family: var(--font-num); font-weight: 700; font-size: clamp(64px, 18vw, 104px); line-height: 1; font-variant-numeric: tabular-nums; }
.cur { font-size: 20px; letter-spacing: .1em; color: var(--hero-muted); }
.hero-meta { display: grid; grid-template-columns: repeat(auto-fit, minmax(128px, 1fr)); gap: 12px 20px; margin-top: 18px; padding-top: 16px; border-top: 1px solid rgba(255, 255, 255, .22); }
.hero-meta dt { color: var(--hero-muted); font-size: 13px; }
.hero-meta dd { font-size: 19px; font-weight: 700; font-variant-numeric: tabular-nums; }
.hero-note { margin-top: 14px; font-size: 14px; color: var(--hero-muted); }

h2 { font-size: 20px; line-height: 1.3; }
.sec-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.help { color: var(--muted); font-size: 14px; max-width: 64ch; }
.stack { display: grid; gap: 12px; }
.try { display: flex; }
.try .ghost[hidden] { display: none; }
.sample { font-size: 14px; background: var(--tint); color: var(--ink); padding: 8px 12px; border-radius: 8px; }

.receipt { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 14px; display: grid; gap: 12px; }
.r-head { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 10px; }
.r-no { font-size: 16px; white-space: nowrap; }
.rows { display: grid; gap: 10px; }
.row { display: grid; grid-template-columns: minmax(0, 1fr) 9.5rem 2.75rem; gap: 8px; align-items: center; }
.amt { position: relative; display: block; }
.amt .yen { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.amt input { width: 100%; padding-left: 28px; text-align: right; font-variant-numeric: tabular-nums; }
.row select { width: 100%; }
@media (max-width: 520px) {
  .row { grid-template-columns: minmax(0, 1fr) 2.75rem; }
  .row select { grid-column: 1 / -1; }
}
.r-foot { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 8px 14px; padding-top: 12px; border-top: 1px dashed var(--line); }
.chip { font-size: 13px; font-weight: 700; padding: 4px 10px; border-radius: 999px; white-space: nowrap; }
.chip.ok { background: var(--ok-bg); color: var(--ok); }
.chip.no { background: var(--no-bg); color: var(--no); }
.chip.idle { background: var(--idle-bg); color: var(--muted); }
.r-nums { display: flex; gap: 6px 16px; flex-wrap: wrap; font-size: 13px; color: var(--muted); font-variant-numeric: tabular-nums; }
.r-refund { font-family: var(--font-num); font-size: 30px; font-weight: 700; line-height: 1; font-variant-numeric: tabular-nums; }
.short { grid-column: 1 / -1; font-size: 14px; color: var(--no); }

.dt { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: 14px; color: var(--muted); }
.fee.dep input { width: auto; text-align: left; justify-self: start; }
.air { list-style: none; padding: 0; margin-top: 12px; display: grid; gap: 12px; }
.air li { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 14px; display: grid; gap: 6px; }
.air h3 { font-size: 16px; line-height: 1.35; }
.air p { color: var(--muted); font-size: 15px; }
.links { display: flex; flex-wrap: wrap; gap: 0 18px; }
.links a { color: var(--accent); font-weight: 700; padding: 8px 0; }
button { font: inherit; cursor: pointer; }
.btn { background: var(--accent); color: var(--accent-ink); border: 0; border-radius: 8px; height: 44px; padding: 0 18px; font-weight: 700; justify-self: start; }
.link { background: none; border: 0; color: var(--accent); font-weight: 700; padding: 8px 0; justify-self: start; min-height: 44px; }
.ghost { background: none; border: 1px solid var(--line); color: var(--ink); border-radius: 8px; height: 40px; padding: 0 12px; white-space: nowrap; }
.icon { background: none; border: 1px solid var(--line); color: var(--muted); border-radius: 8px; width: 44px; height: 44px; font-size: 20px; line-height: 1; }

.fee { display: grid; gap: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 14px; }
.fee label { font-weight: 700; }
.fee input { width: 7rem; text-align: right; }

.steps { list-style: none; padding: 0; counter-reset: step; display: grid; margin-top: 12px; }
.steps li { counter-increment: step; position: relative; padding: 16px 0 16px 46px; border-top: 1px solid var(--line); display: grid; gap: 4px; }
.steps li::before { content: counter(step); position: absolute; left: 0; top: 16px; width: 30px; height: 30px; border-radius: 50%; background: var(--accent); color: var(--accent-ink); display: grid; place-items: center; font-weight: 700; font-size: 15px; }
.where { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); }
.steps h3 { font-size: 17px; line-height: 1.35; }
.steps p { color: var(--muted); white-space: pre-line; }

.no-list { margin-top: 10px; padding-left: 20px; display: grid; gap: 6px; }
.foot { display: grid; gap: 10px; color: var(--muted); font-size: 13px; border-top: 1px solid var(--line); padding-top: 16px; }
.foot a { color: var(--accent); font-weight: 700; }
@media (prefers-reduced-motion: no-preference) {
  .btn, .ghost, .icon { transition: background-color .15s; }
}

/* --- additions --- */
.banner { padding: 10px 14px; border-radius: 10px; font-size: 14px; background: var(--no-bg); color: var(--no); font-weight: 700; }
.hero-fx { margin-top: 10px; font-size: 18px; font-weight: 700; font-variant-numeric: tabular-nums; }
.merged { grid-column: 1 / -1; font-size: 13px; color: var(--muted); }
.r-fx { grid-column: 1 / -1; }
.row .cat { width: 100%; }
.chk { list-style: none; padding: 0; margin-top: 12px; display: grid; gap: 4px; }
.chk label { display: flex; gap: 12px; align-items: flex-start; padding: 10px 0; min-height: 44px; cursor: pointer; }
.chk input { width: 24px; height: 24px; flex: none; margin: 0; accent-color: var(--accent); }
.fx { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; }
.fx label { display: grid; gap: 4px; font-weight: 700; font-size: 14px; }
.fx input, .fx select { width: 100%; text-align: left; }
.fx .help { grid-column: 1 / -1; font-weight: 400; }
.actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.copy-fallback { width: 100%; min-height: 120px; font: inherit; font-size: 14px; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 10px; }
.foot nav { display: flex; gap: 18px; flex-wrap: wrap; }
.doc { display: grid; gap: 14px; }
.doc h1 { font-size: 28px; }
.doc h2 { margin-top: 12px; }
.doc ul, .doc ol { padding-left: 20px; display: grid; gap: 8px; }
.doc h3 { font-size: 17px; margin-top: 6px; }
.doc .lede { font-size: 18px; }
.doc table.cmp { width: 100%; border-collapse: collapse; font-size: 14px; table-layout: fixed; }
.doc table.cmp th, .doc table.cmp td { border: 1px solid var(--line); padding: 7px 8px; text-align: left; vertical-align: top; overflow-wrap: anywhere; }
.doc table.cmp th:first-child { width: 26%; }
.doc table.cmp thead th { background: var(--tint); }
.doc a, .back { color: var(--accent); font-weight: 700; }
.notfound { text-align: center; display: grid; gap: 14px; padding-top: 60px; }

/* --- layout v2: mobile first, two columns on wide screens --- */
.top { gap: 12px; flex-wrap: nowrap; }
.brand { font-weight: 700; font-size: 16px; color: var(--ink); text-decoration: none; letter-spacing: .01em; min-height: 44px; display: inline-flex; align-items: center; }
.langmenu { position: relative; }
.langmenu summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 14px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); font-weight: 700; }
.langmenu summary::-webkit-details-marker { display: none; }
.langmenu[open] summary { border-color: var(--accent); }
.langmenu .globe { flex: none; color: var(--accent); }
.langs { position: absolute; right: 0; top: calc(100% + 6px); z-index: 20; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; min-width: min(320px, calc(100vw - 32px)); padding: 8px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 8px 24px rgba(0, 0, 0, .18); }
.langs a { display: flex; align-items: center; min-height: 44px; padding: 0 12px; border-radius: 8px; color: var(--ink); text-decoration: none; font-weight: 700; }
.langs a:hover { background: var(--tint); }
.langs a[aria-current="page"] { background: var(--accent); color: var(--accent-ink); }

.layout { display: grid; gap: 28px; }
.hero { scroll-margin-top: 12px; }
.btn-light { background: rgba(255, 255, 255, .16); color: var(--hero-ink); border: 1px solid rgba(255, 255, 255, .45); border-radius: 8px; height: 44px; padding: 0 16px; font-weight: 700; }
.hero .actions { margin-top: 14px; }
.hero .hero-note { margin-top: 10px; }

.fold { border-top: 1px solid var(--line); padding-top: 4px; }
.fold > summary { list-style: none; cursor: pointer; min-height: 48px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.fold > summary::-webkit-details-marker { display: none; }
.fold > summary::after { content: '+'; font-size: 24px; color: var(--accent); line-height: 1; }
.fold[open] > summary::after { content: '\2212'; }
.fold .help { margin-top: 4px; }
.side { display: grid; gap: 24px; align-content: start; }

.bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 15; display: flex; align-items: baseline; gap: 10px; padding: 10px max(16px, env(safe-area-inset-right, 0px)) calc(10px + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); background: var(--hero-bg); color: var(--hero-ink); text-decoration: none; box-shadow: 0 -4px 16px rgba(0, 0, 0, .2); }
.bar[hidden] { display: none; }
.bar-l { color: var(--hero-muted); font-size: 13px; font-weight: 700; flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bar b { font-family: var(--font-num); font-size: 28px; line-height: 1; font-variant-numeric: tabular-nums; }
.bar-dl { color: var(--hero-muted); font-size: 12px; white-space: nowrap; }
body.has-bar { padding-bottom: 88px; }

@media (max-width: 520px) {
  select, input[type="text"], input[type="number"], input[type="date"] { height: 48px; }
  .icon { width: 48px; height: 48px; }
  .row { grid-template-columns: minmax(0, 1fr) 3rem; }
  .r-head { grid-template-columns: minmax(0, 1fr) auto; }
  .r-head input { grid-column: 1 / -1; order: 3; }
  .r-foot { grid-template-columns: auto minmax(0, 1fr); }
  .r-refund { grid-column: 1 / -1; font-size: 34px; }
  .langs { grid-template-columns: 1fr 1fr; }
}
@media (min-width: 900px) {
  body { padding-top: 32px; }
  .wrap { max-width: 1040px; gap: 36px; }
  .layout { grid-template-columns: minmax(0, 1fr) 380px; gap: 36px; align-items: start; }
  .layout > .inputs { grid-column: 1; grid-row: 1; }
  .layout > .hero { grid-column: 2; grid-row: 1; position: sticky; top: 16px; }
  .layout.below > .guide { grid-column: 1; grid-row: 1; }
  .layout.below > .side { grid-column: 2; grid-row: 1; }
  .intro { max-width: 720px; }
  .bar { display: none !important; }
  body.has-bar { padding-bottom: 56px; }
  .foot { max-width: 720px; }
}
.doc { max-width: 720px; }
