:root {
  --bg: #F2F2F7;
  --card: #FFFFFF;
  --card-press: #E5E5EA;
  --label: #000000;
  --label-2: rgba(60, 60, 67, 0.62);
  --label-3: rgba(60, 60, 67, 0.32);
  --sep: rgba(60, 60, 67, 0.22);
  --bar: rgba(249, 249, 249, 0.82);
  --tint: #0A6CFF;
  --phuket: #0E7C75;
  --bangkok: #B8731A;
  --phuket-soft: rgba(14, 124, 117, 0.12);
  --bangkok-soft: rgba(184, 115, 26, 0.13);
  --green: #248A3D;
  --red: #D70015;
  --red-soft: rgba(215, 0, 21, 0.09);
  --green-soft: rgba(36, 138, 61, 0.1);
  --tab-inactive: #8E8E93;
  --safe-t: env(safe-area-inset-top, 0px);
  --safe-b: env(safe-area-inset-bottom, 0px);
  --tabbar-h: calc(49px + var(--safe-b));
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #000000;
    --card: #1C1C1E;
    --card-press: #2C2C2E;
    --label: #FFFFFF;
    --label-2: rgba(235, 235, 245, 0.6);
    --label-3: rgba(235, 235, 245, 0.3);
    --sep: rgba(84, 84, 88, 0.6);
    --bar: rgba(22, 22, 24, 0.8);
    --tint: #3D8BFF;
    --phuket: #3DB8AD;
    --bangkok: #E3A048;
    --phuket-soft: rgba(61, 184, 173, 0.16);
    --bangkok-soft: rgba(227, 160, 72, 0.16);
    --green: #30D158;
    --red: #FF6961;
    --red-soft: rgba(255, 105, 97, 0.14);
    --green-soft: rgba(48, 209, 88, 0.13);
  }
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; background: var(--bg); overscroll-behavior: none; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Inter", system-ui, sans-serif;
  font-size: 17px; line-height: 1.3; color: var(--label);
  -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: 100%;
}
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
a { color: var(--tint); text-decoration: none; }
:focus-visible { outline: 2px solid var(--tint); outline-offset: 2px; border-radius: 6px; }

#app { position: fixed; inset: 0; max-width: 600px; margin: 0 auto; overflow: hidden; background: var(--bg); }
.tab { position: absolute; inset: 0; display: none; }
.tab.active { display: block; }
.stack { position: absolute; inset: 0; overflow: hidden; }

.scroller, .page {
  position: absolute; inset: 0; overflow-y: auto; overflow-x: hidden;
  -webkit-overflow-scrolling: touch; background: var(--bg);
  padding-bottom: calc(var(--tabbar-h) + 28px);
}
.page { transition: transform 300ms var(--ease); will-change: transform; }
.page-pushed { transform: translateX(100%); box-shadow: -1px 0 0 var(--sep); }
.page-pushed.shown { transform: translateX(0); }
.page.behind { transform: translateX(-30%); }
.page.dragging { transition: none; }

/* ---------- Nav bar + large title ---------- */
.navbar {
  position: sticky; top: 0; z-index: 10;
  padding-top: var(--safe-t); height: calc(44px + var(--safe-t));
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  background: transparent; transition: background 200ms, box-shadow 200ms;
}
.navbar.solid {
  background: var(--bar);
  -webkit-backdrop-filter: saturate(180%) blur(20px); backdrop-filter: saturate(180%) blur(20px);
  box-shadow: 0 0.5px 0 var(--sep);
}
.navbar .small-title { grid-column: 2; font-weight: 600; font-size: 17px; opacity: 0; transition: opacity 180ms; white-space: nowrap; }
.navbar.solid .small-title { opacity: 1; }
.navbar .back {
  grid-column: 1; justify-self: start; display: flex; align-items: center; gap: 2px;
  color: var(--tint); min-height: 44px; padding: 0 12px 0 6px; font-size: 17px;
}
.navbar .back svg { width: 13px; height: 21px; }
.large-title { margin: 0; padding: 2px 16px 8px; font-size: 34px; font-weight: 700; letter-spacing: 0.37px; line-height: 41px; }
.subhead { margin: -4px 16px 14px; color: var(--label-2); font-size: 15px; }

/* ---------- Inset grouped lists ---------- */
.group { margin: 0 16px 32px; }
.group-header { padding: 0 16px 7px; font-size: 13px; color: var(--label-2); letter-spacing: -0.08px; }
.group-footer { padding: 7px 16px 0; font-size: 13px; color: var(--label-2); line-height: 1.38; }
.list { background: var(--card); border-radius: 10px; overflow: hidden; }
.row {
  position: relative; display: flex; align-items: center; gap: 12px; width: 100%;
  min-height: 44px; padding: 11px 16px; text-align: left;
}
.row + .row::before {
  content: ""; position: absolute; top: 0; right: 0; left: var(--inset, 16px);
  height: 0.5px; background: var(--sep);
}
button.row:active, a.row:active, label.row:active { background: var(--card-press); }
.row .grow { flex: 1; min-width: 0; }
.row .title { font-size: 17px; }
.row .sub { font-size: 15px; color: var(--label-2); margin-top: 2px; }
.row .value { color: var(--label-2); font-size: 17px; text-align: right; }
.chev { width: 8px; height: 13px; flex: none; color: var(--label-3); }
.row-text { font-size: 15px; line-height: 1.4; }

/* ---------- Segmented control ---------- */
.segmented {
  display: grid; grid-template-columns: repeat(3, 1fr); margin: 4px 16px 20px;
  padding: 2px; border-radius: 9px; background: rgba(118, 118, 128, 0.12);
}
.segmented button { min-height: 32px; border-radius: 7px; font-size: 13px; font-weight: 500; }
.segmented button[aria-pressed="true"] {
  background: var(--card); font-weight: 600;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.12), 0 3px 1px rgba(0, 0, 0, 0.04);
}
@media (prefers-color-scheme: dark) { .segmented button[aria-pressed="true"] { background: #636366; } }

/* ---------- Tags ---------- */
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 7px; }
.pill { display: inline-flex; align-items: center; height: 22px; padding: 0 9px; border-radius: 11px; font-size: 12px; font-weight: 600; }
.pill.teen { background: var(--phuket-soft); color: var(--phuket); }
.pill.shopping { background: var(--bangkok-soft); color: var(--bangkok); }
.pill.veg { color: var(--green); box-shadow: inset 0 0 0 1px var(--green); }

/* ---------- Date tile (itinerary rows) ---------- */
.datetile {
  flex: none; width: 46px; height: 50px; border-radius: 10px; display: flex; flex-direction: column;
  align-items: center; justify-content: center; line-height: 1;
}
.datetile .wd { font-size: 11px; font-weight: 600; letter-spacing: 0.2px; }
.datetile .dd { font-size: 22px; font-weight: 700; margin-top: 3px; font-variant-numeric: tabular-nums; }
.c-phuket { --city: var(--phuket); --city-soft: var(--phuket-soft); }
.c-bangkok { --city: var(--bangkok); --city-soft: var(--bangkok-soft); }
.datetile { background: var(--city-soft); color: var(--city); }
.daynum { font-size: 13px; color: var(--city); font-weight: 600; }

/* ---------- Banners ---------- */
.banner { margin: 0 16px 24px; padding: 12px 14px; border-radius: 10px; font-size: 15px; line-height: 1.4; }
.banner.bad { background: var(--red-soft); color: var(--red); }
.banner.ok { background: var(--green-soft); color: var(--green); font-weight: 600; }
.banner p { margin: 0; }
.banner p + p { margin-top: 8px; }
.banner .actions { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }
.btn {
  min-height: 44px; padding: 0 18px; border-radius: 12px; font-size: 15px; font-weight: 600;
  background: var(--tint); color: #fff; display: inline-flex; align-items: center; justify-content: center; gap: 6px;
}
.btn:active { opacity: 0.7; }
.btn.plain { background: var(--card); color: var(--tint); }
.banner.bad .btn { background: var(--red); }

input[type="date"] {
  font: inherit; color: var(--tint); background: rgba(118, 118, 128, 0.12); border: 0;
  border-radius: 7px; padding: 6px 10px; min-height: 34px; max-width: 170px;
}

/* ---------- Day detail ---------- */
.dayhero { margin: 0 16px 20px; }
.dayhero .eyebrow { font-size: 15px; font-weight: 600; color: var(--city); }
.dayhero h2 { margin: 6px 0 0; font-size: 28px; line-height: 1.12; font-weight: 700; letter-spacing: 0.2px; }
.dayhero .when { margin-top: 6px; color: var(--label-2); font-size: 15px; }

.rail { margin: 0 16px 28px; background: var(--card); border-radius: 10px; padding: 6px 0; }
.stop { display: grid; grid-template-columns: 74px 1fr; position: relative; }
.stop .t {
  padding: 14px 8px 14px 14px; font-size: 13px; font-weight: 600; color: var(--city);
  font-variant-numeric: tabular-nums; line-height: 1.25;
}
.stop .b { position: relative; padding: 13px 16px 14px 22px; }
.stop .b::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 2px; background: var(--city-soft);
}
.stop:first-child .b::before { top: 19px; }
.stop:last-child .b::before { bottom: calc(100% - 19px); }
.stop .b::after {
  content: ""; position: absolute; left: -4px; top: 15px; width: 10px; height: 10px; border-radius: 50%;
  background: var(--card); box-shadow: inset 0 0 0 2.5px var(--city);
}
.stop + .stop .b { border-top: 0.5px solid var(--sep); }
.stop .st { font-size: 17px; font-weight: 600; line-height: 1.25; }
.stop .sn { margin-top: 4px; font-size: 15px; color: var(--label-2); line-height: 1.38; }
.maplink {
  display: inline-flex; align-items: center; gap: 5px; margin-top: 8px; min-height: 32px;
  padding: 0 12px; border-radius: 16px; background: rgba(118, 118, 128, 0.12); color: var(--tint);
  font-size: 14px; font-weight: 600;
}
.maplink svg { width: 13px; height: 13px; }
.maplink:active { opacity: 0.6; }

.foodcard { margin: 0 16px 28px; padding: 16px; border-radius: 10px; background: var(--card); }
.foodcard .meal { font-size: 13px; font-weight: 600; color: var(--city); }
.foodcard .place { margin-top: 4px; font-size: 20px; font-weight: 700; line-height: 1.2; }
.foodcard .note { margin-top: 6px; font-size: 15px; color: var(--label-2); line-height: 1.4; }

.warn { display: flex; gap: 10px; align-items: flex-start; }
.warn svg { flex: none; width: 20px; height: 20px; color: #FF9500; margin-top: 1px; }

/* ---------- Today ---------- */
.hero {
  margin: 0 16px 28px; border-radius: 22px; padding: 22px 20px 20px; color: #fff;
  background: var(--city); position: relative; overflow: hidden;
}
.c-phuket.hero { background: linear-gradient(160deg, #13968D, #0B5F5A); }
.c-bangkok.hero { background: linear-gradient(160deg, #C9832A, #8E5612); }
.hero .k { font-size: 15px; font-weight: 600; opacity: 0.86; }
.hero .big { font-size: 64px; font-weight: 800; line-height: 1; letter-spacing: -1.5px; margin-top: 10px; font-variant-numeric: tabular-nums; }
.hero h2 { margin: 8px 0 0; font-size: 24px; line-height: 1.15; font-weight: 700; }
.hero .meta { margin-top: 8px; font-size: 15px; opacity: 0.86; }
.hero .btn { margin-top: 18px; background: rgba(255, 255, 255, 0.22); color: #fff; -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
.hero .stripe { position: absolute; right: -30px; top: -30px; width: 140px; height: 140px; border-radius: 50%; background: rgba(255, 255, 255, 0.08); }

/* ---------- Food ---------- */
.phrases .row { align-items: baseline; }
.phrases .th { font-size: 17px; font-weight: 600; color: var(--label); }
.dish .name { font-size: 17px; font-weight: 600; }
.dish .thai { font-size: 15px; color: var(--city); font-weight: 500; margin-top: 1px; }
.dish .desc { font-size: 15px; color: var(--label-2); margin-top: 6px; line-height: 1.38; }
.dish .where { font-size: 13px; color: var(--label-2); margin-top: 8px; display: flex; gap: 5px; align-items: center; }
.dish .where svg { width: 12px; height: 12px; flex: none; color: var(--city); }
.dish { align-items: flex-start; }

/* ---------- Checklist ---------- */
.check { align-items: flex-start; cursor: pointer; }
.check input { position: absolute; opacity: 0; pointer-events: none; }
.check .box {
  flex: none; width: 24px; height: 24px; border-radius: 50%; margin-top: -1px;
  box-shadow: inset 0 0 0 1.5px var(--label-3); display: grid; place-items: center;
  transition: background 150ms;
}
.check .box svg { width: 13px; height: 13px; color: #fff; opacity: 0; }
.check input:checked + .box { background: var(--green); box-shadow: none; }
.check input:checked + .box svg { opacity: 1; }
.check input:checked ~ .grow { color: var(--label-2); text-decoration: line-through; text-decoration-color: var(--label-3); }
.check input:focus-visible + .box { outline: 2px solid var(--tint); outline-offset: 2px; }
.check .grow { font-size: 16px; line-height: 1.35; }

.cost .title { font-size: 16px; }
.footer { margin: 0 32px 24px; font-size: 13px; color: var(--label-2); text-align: center; line-height: 1.4; }

/* ---------- Tab bar ---------- */
.tabbar {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 50;
  height: var(--tabbar-h); padding-bottom: var(--safe-b);
  display: grid; grid-template-columns: repeat(6, 1fr);
  background: var(--bar);
  -webkit-backdrop-filter: saturate(180%) blur(20px); backdrop-filter: saturate(180%) blur(20px);
  box-shadow: 0 -0.5px 0 var(--sep);
}
.tabbar button {
  display: flex; flex-direction: column; align-items: center; justify-content: flex-start;
  padding-top: 5px; gap: 2px; color: var(--tab-inactive); min-height: 44px;
}
.tabbar svg { width: 26px; height: 26px; }
.tabbar span { font-size: 10px; font-weight: 500; letter-spacing: 0.1px; }
.tabbar button[aria-selected="true"] { color: var(--tint); }

/* ---------- Shared controls ---------- */
.nav-right { grid-column: 3; justify-self: end; padding-right: 16px; }
.link { color: var(--tint); font-size: 17px; min-height: 44px; display: inline-flex; align-items: center; }
.link.strong { font-weight: 600; }
.link:active { opacity: 0.5; }
.link:disabled { opacity: 0.4; }
.btn.wide { width: 100%; min-height: 50px; font-size: 17px; }
.btn.danger { background: var(--card); color: var(--red); }
.field {
  font: inherit; font-size: 17px; color: var(--label); background: transparent; border: 0; outline: 0;
  width: 100%; min-width: 0; padding: 0; min-height: 24px;
}
.field::placeholder { color: var(--label-3); }
textarea.field { resize: vertical; line-height: 1.35; }
.form-row .flabel { flex: none; width: 104px; color: var(--label); }
.form-row .field { text-align: left; }
.form-row input[type="date"], .form-row input[type="time"] { color: var(--tint); }
.row-head { display: flex; justify-content: space-between; align-items: center; padding-right: 4px; }
.row-head .link { font-size: 15px; min-height: 32px; }

/* ---------- Checklist ---------- */
.check-row { padding: 0; align-items: stretch; }
.check-row .grow-wrap { display: flex; flex: 1; gap: 12px; padding: 11px 0 11px 16px; align-items: flex-start; cursor: pointer; min-height: 44px; }
.check-row .grow-wrap:active { background: var(--card-press); }
.check-row .grow { display: flex; flex-direction: column; gap: 3px; padding-right: 16px; }
.cmeta { font-size: 13px; color: var(--label-2); }
.check-row .grow-wrap input:checked ~ .grow { text-decoration: none; }
.check-row .grow-wrap input:checked ~ .grow .ctext { color: var(--label-2); text-decoration: line-through; text-decoration-color: var(--label-3); }
.check-row .del, .filerow .del { flex: none; color: #fff; background: var(--red); font-size: 15px; font-weight: 600; padding: 0 16px; min-width: 76px; }
.filerow .del { background: none; color: var(--red); min-height: 44px; padding: 0; min-width: 0; }
.addrow { gap: 8px; }
.addrow .link { font-weight: 600; }
.radio .box { border-radius: 50%; }

/* ---------- Sync line ---------- */
.syncline { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: -8px 32px 12px; font-size: 13px; color: var(--label-2); }
.syncline .link { font-size: 13px; min-height: 36px; }
.syncline.off { color: #C93400; }
@media (prefers-color-scheme: dark) { .syncline.off { color: #FF9F0A; } }
.footer .link { font-size: 13px; min-height: 0; }

/* ---------- Boarding-pass cards ---------- */
.c-home { --city: var(--tint); --city-soft: rgba(10, 108, 255, 0.1); }
.pass {
  display: block; width: calc(100% - 32px); margin: 0 16px 16px; padding: 14px 16px 6px; text-align: left;
  background: var(--card); border-radius: 16px; position: relative; overflow: hidden;
  border-top: 5px solid var(--city);
}
.pass.empty { background: transparent; border: 1.5px dashed var(--label-3); border-top: 5px solid var(--city-soft); padding-bottom: 14px; }
.pass.empty:active { background: var(--card-press); }
.pass.empty .iata, .pass.empty .hotel-name { color: var(--label-3); }
.pass-top { display: flex; justify-content: space-between; gap: 12px; font-size: 13px; font-weight: 600; color: var(--city); }
.pass-route { display: grid; grid-template-columns: 1fr auto 1fr; align-items: start; gap: 8px; margin-top: 10px; }
.pass-route .r { text-align: right; }
.iata { font-size: 38px; font-weight: 800; letter-spacing: 0.5px; line-height: 1; font-variant-numeric: tabular-nums; }
.place { font-size: 13px; color: var(--label-2); margin-top: 4px; }
.time { font-size: 17px; font-weight: 600; margin-top: 6px; font-variant-numeric: tabular-nums; }
.pass-line { display: flex; align-items: center; color: var(--city); padding-top: 9px; position: relative; width: 64px; justify-content: center; }
.pass-line::before { content: ""; position: absolute; left: 0; right: 0; top: 20px; border-top: 1.5px dashed var(--city-soft); }
.pass-line svg { width: 22px; height: 22px; position: relative; background: var(--card); padding: 0 3px; box-sizing: content-box; }
.pass.empty .pass-line svg { background: var(--bg); }
.pass-add { margin-top: 14px; font-size: 15px; font-weight: 600; color: var(--tint); }
.perf { margin: 14px -16px 12px; border-top: 1.5px dashed var(--sep); position: relative; }
.perf::before, .perf::after { content: ""; position: absolute; top: -9px; width: 16px; height: 16px; border-radius: 50%; background: var(--bg); }
.perf::before { left: -8px; } .perf::after { right: -8px; }
.pass-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 12px; }
.pass-meta .k { font-size: 12px; color: var(--label-2); }
.pass-meta .v { font-size: 16px; font-weight: 600; margin-top: 2px; overflow-wrap: anywhere; }
.mono { font-variant-numeric: tabular-nums; letter-spacing: 1px; }
.copy { font-weight: 700; color: var(--label); min-height: 28px; text-align: left; }
.copy:active { opacity: 0.5; }
.pax { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.paxchip { font-size: 12px; font-weight: 600; padding: 4px 9px; border-radius: 11px; color: var(--label-3); box-shadow: inset 0 0 0 1px var(--sep); text-decoration: line-through; }
.paxchip.on { color: var(--city); background: var(--city-soft); box-shadow: none; text-decoration: none; }
.pass-notes { margin: 10px 0 0; font-size: 15px; color: var(--label-2); line-height: 1.38; white-space: pre-wrap; }
.files { display: flex; flex-direction: column; gap: 6px; margin-top: 12px; }
.filechip {
  display: flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 12px; border-radius: 10px;
  background: rgba(118, 118, 128, 0.12); color: var(--tint); font-size: 15px; font-weight: 600; text-align: left;
}
.filechip svg { width: 18px; height: 18px; flex: none; }
.filechip span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.filechip:active { opacity: 0.6; }
.pass-foot { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-top: 6px; font-size: 12px; color: var(--label-2); }
.pass-foot .link { font-weight: 600; padding-left: 12px; }
.hotel-name { display: flex; align-items: center; gap: 10px; margin-top: 10px; font-size: 22px; font-weight: 700; line-height: 1.2; }
.hotel-name svg { width: 26px; height: 26px; flex: none; color: var(--city); }
.hotel-addr { margin: 6px 0 0; font-size: 15px; color: var(--label-2); line-height: 1.38; }
.hotel-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 4px; }

/* ---------- Sheet + viewer ---------- */
.sheet-wrap { position: fixed; inset: 0; z-index: 100; pointer-events: none; }
.sheet-backdrop { position: absolute; inset: 0; background: rgba(0, 0, 0, 0.4); opacity: 0; transition: opacity 300ms; }
.sheet {
  position: absolute; left: 0; right: 0; bottom: 0; max-width: 600px; margin: 0 auto;
  height: calc(100% - var(--safe-t) - 12px); background: var(--bg); border-radius: 12px 12px 0 0;
  transform: translateY(100%); transition: transform 320ms var(--ease);
  display: flex; flex-direction: column; overflow: hidden;
}
.sheet-wrap.open { pointer-events: auto; }
.sheet-wrap.open .sheet-backdrop { opacity: 1; }
.sheet-wrap.open .sheet { transform: translateY(0); }
.sheet-bar {
  flex: none; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; padding: 6px 16px;
  min-height: 56px; background: var(--bar); box-shadow: 0 0.5px 0 var(--sep);
  -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px);
}
.sheet-bar > :last-child { justify-self: end; }
.sheet-title { font-weight: 600; font-size: 17px; text-align: center; max-width: 52vw; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sheet-body { flex: 1; overflow-y: auto; padding: 20px 0 calc(var(--safe-b) + 24px); -webkit-overflow-scrolling: touch; }
.upload { position: relative; margin-top: 10px; overflow: hidden; }
.upload input { position: absolute; inset: 0; opacity: 0; cursor: pointer; font-size: 0; }
.filerow svg { width: 20px; height: 20px; color: var(--tint); flex: none; }
.filerow .fname { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; text-align: left; min-width: 0; }
.filerow .fname .title { font-size: 16px; color: var(--tint); max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.filerow .fname .sub { font-size: 13px; }
.row .sub { color: var(--label-2); }

.viewer {
  position: fixed; inset: 0; z-index: 120; background: var(--bg); display: none; flex-direction: column;
  padding-top: var(--safe-t);
}
.viewer.open { display: flex; }
.viewer-body { flex: 1; overflow: auto; -webkit-overflow-scrolling: touch; padding: 12px 0 calc(var(--safe-b) + 12px); }
.viewer-body img { display: block; max-width: 100%; margin: 0 auto; }
.viewer-body iframe { display: block; width: 100%; height: calc(100% - 60px); min-height: 70vh; border: 0; background: #fff; }

.toast {
  position: fixed; left: 50%; bottom: calc(var(--tabbar-h) + 14px); z-index: 200; transform: translate(-50%, 20px);
  max-width: min(560px, calc(100% - 32px)); padding: 12px 18px; border-radius: 14px;
  background: rgba(30, 30, 32, 0.92); color: #fff; font-size: 15px; line-height: 1.35; text-align: center;
  opacity: 0; pointer-events: none; transition: opacity 200ms, transform 200ms var(--ease);
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- Phrases ---------- */
.polite { margin: 0 16px 28px; padding: 14px 16px; border-radius: 12px; background: var(--card); font-size: 15px; line-height: 1.42; }
.polite p { margin: 0; }
.polite p + p { margin-top: 6px; color: var(--label-2); }
.say { align-items: center; padding-top: 12px; padding-bottom: 12px; }
.say .grow { display: flex; flex-direction: column; gap: 3px; }
.say-en { font-size: 17px; font-weight: 600; }
.say-sound { font-size: 17px; color: var(--tint); }
.say-end { color: var(--label-2); font-size: 14px; }
.say-thai { font-size: 18px; color: var(--label-2); text-align: right; flex: none; max-width: 40%; }
.spk { flex: none; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: rgba(118, 118, 128, 0.12); color: var(--tint); }
.spk svg { width: 18px; height: 18px; }

@media (max-width: 360px) { .tabbar span { font-size: 9px; } .iata { font-size: 32px; } }

@media (prefers-reduced-motion: reduce) {
  .page, .navbar, .navbar .small-title, .check .box, .sheet, .sheet-backdrop, .toast { transition: none !important; }
}
