/* Folio & Co. styles (v2) */
/* v2: a working desk. Green opens and closes the page, cream in between. Every trip becomes a numbered file. */
:root {
  --ground: #F4F1EA;
  --paper: #FBFAF6;
  --ink: #1C1C1A;
  --muted: #5E5A51;
  --faint: #A9A397;
  --line: #D8D2C4;
  --brand: #1E4D36;
  --brand-fill: #1E4D36;
  --on-brand: #F4F1EA;
  --on-brand-muted: #BFD0C4;
  --brand-soft: #E2E9E2;
  --section: #1E4D36;
  --nav: #1E4D36;
  --sand: #E6DAC4;
  --manila: #E6DAC4;
  --manila-edge: #D3C3A4;
  --red: #B8322A;
  --red-soft: #F6E3DF;
  --blue: #2F4A8A;
  --blue-soft: #E2E7F3;
  --laterite: #A9532F;
  --focus: #2F4A8A;
  --display: 'Gloock', 'Iowan Old Style', Georgia, serif;
  --accent-serif: 'Fraunces', Georgia, serif;
  --body: 'Hanken Grotesk', 'Helvetica Neue', Arial, sans-serif;
  --mono: 'IBM Plex Mono', ui-monospace, 'SFMono-Regular', Menlo, monospace;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ground: #121613; --paper: #1A201C; --ink: #ECE8DF; --muted: #ABA699; --faint: #6E6A61; --line: #313A33;
    --brand: #93C6A8; --brand-fill: #2C6B4C; --on-brand: #F4F1EA; --on-brand-muted: #A9C2B2; --brand-soft: #1F2D25;
    --section: #17372A; --nav: #17372A; --sand: #2A2620; --manila: #2A2620; --manila-edge: #3A342B;
    --red: #E58276; --red-soft: #3A2220; --blue: #9DB2E3; --blue-soft: #1F2638; --laterite: #DB9067; --focus: #9DB2E3; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --ground: #121613; --paper: #1A201C; --ink: #ECE8DF; --muted: #ABA699; --faint: #6E6A61; --line: #313A33;
  --brand: #93C6A8; --brand-fill: #2C6B4C; --on-brand: #F4F1EA; --on-brand-muted: #A9C2B2; --brand-soft: #1F2D25;
  --section: #17372A; --nav: #17372A; --sand: #2A2620; --manila: #2A2620; --manila-edge: #3A342B;
  --red: #E58276; --red-soft: #3A2220; --blue: #9DB2E3; --blue-soft: #1F2638; --laterite: #DB9067; --focus: #9DB2E3; color-scheme: dark;
}
* { box-sizing: border-box; }
html { scroll-padding-top: 96px; }
body { margin: 0; background: var(--ground); color: var(--ink); font-family: var(--body); font-size: 16px; line-height: 1.55; -webkit-font-smoothing: antialiased; }
.wrap { max-width: 1160px; margin: 0 auto; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
h1, h2, h3 { font-family: var(--display); font-weight: 400; margin: 0; text-wrap: balance; line-height: 1.06; }
p { margin: 0; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.mono { font-family: var(--mono); font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase; }
.label { font-family: var(--mono); font-size: 12px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); }
.label::before { content: "( "; } .label::after { content: " )"; }
.on-green .label { color: var(--on-brand-muted); }
i.ser { font-family: var(--accent-serif); }
.hint { font-size: 13px; color: var(--muted); }
[hidden] { display: none !important; }


/* Nav: one floating bar */
.navbar { position: sticky; top: 12px; z-index: 20; padding-inline: 16px; margin-top: 12px; }
/* Slides out of the way while scrolling down or typing, back on scroll up */
.navbar.away { transform: translateY(calc(-100% - 24px)); }
.navbar .bar { max-width: 760px; margin: 0 auto; background: var(--nav); color: #F4F1EA; border-radius: 6px; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 10px 10px 20px; box-shadow: 0 10px 30px rgba(0,0,0,.12); }
.wordmark { font-family: var(--display); font-size: 22px; line-height: 1; background: none; border: 0; color: inherit; padding: 6px 0; cursor: pointer; white-space: nowrap; }
.wordmark i { font-family: var(--accent-serif); font-size: 17px; }
.navbar nav { display: flex; align-items: center; gap: 6px; }
.navbar nav a, .navbar nav button.link { color: #DCD8CF; text-decoration: none; font: 500 14px/1 var(--body); padding: 12px 10px; background: none; border: 0; cursor: pointer; }
.navbar nav a:hover, .navbar nav button.link:hover { color: #fff; }

.btn { font: 600 15px/1 var(--body); min-height: 46px; padding: 0 20px; border-radius: 6px; border: 1.5px solid var(--brand-fill); background: var(--brand-fill); color: var(--on-brand); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 10px; text-decoration: none; }
.btn:hover { filter: brightness(1.08); }
.btn.ghost { background: transparent; color: var(--brand); border-color: var(--brand); }
.btn.small { min-height: 40px; padding: 0 14px; font-size: 14px; }
.btn.light { background: #F4F1EA; color: #1E4D36; border-color: #F4F1EA; }
.btn.light-ghost { background: transparent; color: #F4F1EA; border-color: rgba(244,241,234,.5); }
.btn.nav-cta { background: #F4F1EA; color: #1E4D36; border-color: #F4F1EA; min-height: 40px; font-size: 14px; }
.btn .arr { font-family: var(--mono); font-size: 13px; border: 1px solid currentColor; border-radius: 3px; padding: 2px 5px; line-height: 1; }
.btn:disabled { opacity: .6; cursor: progress; }

/* Hero */
.hero { background: var(--ground); color: var(--ink); }
.hero .label { color: var(--laterite); }
.hero .wrap { padding-block: 56px 80px; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 56px; align-items: center; }
.hero h1 { font-size: clamp(44px, 6.4vw, 84px); letter-spacing: -0.01em; margin-top: 18px; color: var(--brand); }
.hero .lede { font-size: 19px; color: var(--muted); max-width: 30em; margin-top: 22px; }
.hero .meta { display: flex; flex-wrap: wrap; gap: 8px 28px; margin-top: 40px; font-family: var(--mono); font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.hero .meta b { color: var(--ink); font-weight: 500; }
.hero .folder .body { box-shadow: 0 18px 40px rgba(30,77,54,.14); }

/* The file: a manila folder that holds the form */
.folder { position: relative; padding-top: 34px; color: var(--ink); }
.folder .tab { position: absolute; top: 0; left: 0; height: 40px; width: min(62%, 320px); background: var(--manila); border-radius: 8px 8px 0 0; padding: 10px 18px; font-family: var(--mono); font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.folder .body { position: relative; background: var(--manila); border-radius: 0 10px 10px 10px; padding: 18px; box-shadow: 0 24px 50px rgba(0,0,0,.22); }
.sheet { background: var(--paper); border-radius: 6px; padding: 26px; border: 1px solid var(--manila-edge); }
.sheet-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; border-bottom: 1.5px solid var(--ink); padding-bottom: 14px; }
.sheet-head h2 { font-size: 30px; color: var(--brand); }
.fileno { text-align: right; flex: none; }
.fileno .n { font-family: var(--mono); font-size: 18px; letter-spacing: .08em; color: var(--ink); display: block; margin-top: 2px; }
.route-line { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 14px; min-height: 30px; }
.stamp { display: inline-block; color: var(--rc, var(--brand)); border: 2px solid currentColor; border-radius: 4px; padding: 4px 9px; font-family: var(--mono); font-weight: 500; font-size: 11px; letter-spacing: .14em; text-transform: uppercase; transform: rotate(-2deg); }

form.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 16px; margin-top: 16px; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field.full { grid-column: 1 / -1; }
label, .legend { font-size: 13px; font-weight: 600; color: var(--ink); }
input, select, textarea { font: 400 16px/1.4 var(--body); color: var(--ink); background: var(--ground); border: 1.5px solid var(--line); border-radius: 6px; min-height: 46px; padding: 10px 12px; width: 100%; }
textarea { min-height: 96px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--brand); outline: none; box-shadow: 0 0 0 3px var(--brand-soft); }
.pills { display: flex; flex-wrap: wrap; gap: 8px; }
.pills label { font-weight: 500; font-size: 14px; display: inline-flex; align-items: center; border: 1.5px solid var(--line); border-radius: 6px; padding: 0 14px; min-height: 40px; cursor: pointer; background: var(--ground); }
.pills input { position: absolute; opacity: 0; width: 1px; height: 1px; min-height: 0; }
.pills label:has(input:checked) { border-color: var(--brand-fill); background: var(--brand-fill); color: var(--on-brand); }
.pills label:has(input:focus-visible) { outline: 3px solid var(--focus); outline-offset: 2px; }

/* Sections */
section.sec .wrap { padding-block: 96px; display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 32px; }
section.sec + section.sec .wrap { padding-top: 24px; }
.sec h2 { font-size: clamp(32px, 4.2vw, 50px); color: var(--ink); }
.sec .intro { color: var(--muted); max-width: 36em; margin-top: 14px; font-size: 18px; }

/* Steps: rows that settle in as you reach them */
.rows { list-style: none; margin: 40px 0 0; padding: 0; border-top: 1px solid var(--line); }
.rows li { display: grid; grid-template-columns: 56px minmax(0, 220px) minmax(0, 1fr); gap: 24px; padding: 30px 0; border-bottom: 1px solid var(--line); align-items: baseline; }
.rows .no { font-family: var(--mono); font-size: 13px; color: var(--laterite); }
.rows h3 { font-size: 34px; }
.rows p { color: var(--muted); font-size: 17px; max-width: 34em; }
.js-reveal .rows li { opacity: .3; transition: opacity .6s ease; }
.js-reveal .rows li.lit { opacity: 1; }

/* Destinations: file tabs */
.dests { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; margin-top: 36px; }
.dest { text-align: left; background: var(--paper); border: 1px solid var(--line); border-radius: 0 6px 6px 6px; padding: 16px; cursor: pointer; display: flex; flex-direction: column; gap: 10px; font: inherit; color: inherit; position: relative; min-height: 104px; }
.dest::before { content: ""; position: absolute; top: -9px; left: -1px; width: 44%; height: 9px; background: var(--paper); border: 1px solid var(--line); border-bottom: 0; border-radius: 5px 5px 0 0; }
.dest:hover { border-color: var(--brand); }
.dest:hover::before { border-color: var(--brand); }
.dest .nm { font-family: var(--display); font-size: 22px; line-height: 1.1; }
.dest .stamp { align-self: flex-start; margin-top: auto; font-size: 10px; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 28px; }

.r-appointment { --rc: var(--brand); }
.r-evisa { --rc: var(--blue); }
.r-eta { --rc: var(--blue); }
.r-calling { --rc: var(--laterite); }
.r-visafree { --rc: var(--red); }
.r-check { --rc: var(--muted); }

.routes { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-top: 36px; }
.route { padding: 20px; display: flex; flex-direction: column; gap: 10px; background: var(--paper); border: 1.5px solid var(--rc); border-radius: 6px; }
.route .stamp { align-self: flex-start; }
.route h3 { font-size: 26px; }
.route p { font-size: 15px; color: var(--muted); }
.route .eg { font-size: 13px; color: var(--ink); margin-top: auto; }

/* Track */
.track { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 28px; max-width: 520px; }
.track input { flex: 1 1 220px; font-family: var(--mono); letter-spacing: .08em; text-transform: uppercase; }
.trackmsg { margin-top: 12px; font-size: 15px; }

/* Closing */
.close { background: var(--sand); color: var(--ink); }
.close .label { color: var(--laterite); }
.close .wrap { padding-block: 96px 40px; display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 32px; }
.close h2 { font-size: clamp(44px, 7vw, 96px); color: var(--brand); }
.close .acts { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 36px; }
.close .straight { color: var(--muted); max-width: 40em; margin-top: 40px; font-size: 15px; }
.foot { grid-column: 1 / -1; border-top: 1px solid var(--manila-edge); margin-top: 64px; padding-top: 22px; display: flex; flex-wrap: wrap; gap: 12px 28px; justify-content: space-between; font-size: 14px; color: var(--muted); }
.foot .clock { font-family: var(--mono); letter-spacing: .08em; }
.foot .clock b { color: var(--ink); font-weight: 500; }

/* Progress */
.progress-wrap { padding-top: 28px; }
.progress { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; }
.progress li { border-top: 3px solid var(--line); padding-top: 8px; font-size: 13px; color: var(--muted); line-height: 1.3; }
.progress li .n { display: block; font-family: var(--mono); font-size: 11px; letter-spacing: .1em; margin-bottom: 2px; }
.progress li.done { border-color: var(--brand); color: var(--ink); }
.progress li.now { border-color: var(--red); color: var(--ink); font-weight: 600; }

/* Travellers */
.trav { margin-top: 18px; }
.trav-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.trav-head h2 { font-family: var(--mono); font-size: 13px; letter-spacing: .16em; text-transform: uppercase; color: var(--laterite); font-weight: 500; }
.primary-pick { display: inline-flex; align-items: center; gap: 8px; font-weight: 500; font-size: 14px; cursor: pointer; }
.primary-pick input { width: 18px; height: 18px; min-height: 0; accent-color: var(--brand-fill); margin: 0; }
.scan { border: 1.5px dashed var(--manila-edge); background: var(--ground); border-radius: 6px; padding: 24px; margin: 16px 0 18px; display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; }
.scan h3 { font-family: var(--body); font-weight: 600; font-size: 17px; }
.scan p { font-size: 14px; color: var(--muted); max-width: 30em; }
.scan .ok { color: var(--brand); font-size: 13px; font-weight: 600; }
.addtrav { width: 100%; margin-top: 16px; border: 1.5px dashed var(--line); background: transparent; border-radius: 6px; padding: 18px 20px; font: 600 15px/1 var(--body); color: var(--brand); cursor: pointer; text-align: left; min-height: 56px; }
.addtrav:hover { border-color: var(--brand); }
.linkbtn { background: none; border: 0; padding: 8px 0; font: 500 14px var(--body); color: var(--red); cursor: pointer; text-decoration: underline; }
.ferr { color: var(--red); font-size: 12px; }
.tgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 16px; }
input[aria-invalid="true"], select[aria-invalid="true"] { border-color: var(--red); }
.opt { font-weight: 400; color: var(--muted); }

/* Costs */
.costs { background: var(--paper); border: 1px solid var(--line); border-radius: 6px; margin-top: 20px; overflow: hidden; }
.costs .crow { display: flex; justify-content: space-between; gap: 16px; padding: 13px 18px; border-bottom: 1px solid var(--line); font-size: 15px; flex-wrap: wrap; }
.costs .crow small { display: block; color: var(--muted); font-size: 12px; }
.costs .crow .amt { font-family: var(--mono); font-size: 14px; white-space: nowrap; }
.costs .crow.tot { background: var(--brand-soft); border-bottom: 0; font-weight: 600; }
.costs .crow.tot .amt { font-family: var(--display); font-size: 24px; color: var(--brand); font-weight: 400; }
.costs .note { padding: 12px 18px; font-size: 13px; color: var(--muted); border-top: 1px solid var(--line); }
.svc .plus { font-size: 13px; color: var(--muted); }

/* Inner views */
.view { min-height: 70vh; }
.inner { padding-block: 40px 80px; }
.narrow { max-width: 780px; }
.crumbs { display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; justify-content: space-between; }
.trip { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { font-size: 13px; border: 1px solid var(--line); border-radius: 4px; padding: 4px 10px; background: var(--paper); }
.filehead { margin-top: 28px; display: flex; flex-direction: column; gap: 14px; }
.filehead .stamp { align-self: flex-start; }
.filehead h1 { font-size: clamp(36px, 5.4vw, 62px); color: var(--brand); }
.alert { background: var(--red-soft); border-radius: 6px; padding: 14px 16px; display: flex; gap: 12px; align-items: flex-start; }
.alert strong { color: var(--red); }
.alert svg { flex: none; margin-top: 2px; stroke: var(--red); }
.facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border: 1px solid var(--line); border-radius: 6px; background: var(--paper); margin-top: 28px; overflow: hidden; }
.fact { padding: 16px 18px; border-right: 1px solid var(--line); display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.fact:last-child { border-right: 0; }
.fact .mono { color: var(--muted); font-size: 11px; }
.fact .v { font-size: 15px; }

.two { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: 40px; margin-top: 48px; align-items: start; }
.two h2, .inner h2.s { font-size: 30px; color: var(--ink); }
ol.process { list-style: none; padding: 0; margin: 20px 0 0; counter-reset: p; }
ol.process li { counter-increment: p; display: grid; grid-template-columns: 34px minmax(0, 1fr); gap: 12px; padding-bottom: 18px; position: relative; }
ol.process li::before { content: counter(p); width: 30px; height: 30px; border-radius: 50%; border: 1.5px solid var(--rc); color: var(--rc); display: grid; place-items: center; font-family: var(--mono); font-size: 13px; background: var(--ground); position: relative; z-index: 1; }
ol.process li:not(:last-child)::after { content: ""; position: absolute; left: 15px; top: 30px; bottom: 0; width: 1.5px; background: var(--line); }
ol.process .who { font-family: var(--mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); display: block; }

.checklist { display: flex; flex-direction: column; gap: 22px; margin-top: 20px; }
.group h3 { font-family: var(--mono); font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--laterite); margin-bottom: 8px; }
.group ul { list-style: none; margin: 0; padding: 0; border: 1px solid var(--line); border-radius: 6px; background: var(--paper); }
.group li { border-bottom: 1px solid var(--line); }
.group li:last-child { border-bottom: 0; }
.group label.item { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: 12px; padding: 12px 14px; font-weight: 400; font-size: 15px; cursor: pointer; align-items: start; }
.group label.item input { width: 20px; height: 20px; min-height: 0; margin: 2px 0 0; accent-color: var(--brand-fill); }
.group label.item small { display: block; color: var(--muted); font-size: 13px; }
.group label.item:has(input:checked) b { text-decoration: line-through; color: var(--muted); }

.services { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 16px; margin-top: 20px; }
.svc { background: var(--paper); border: 1.5px solid var(--line); border-radius: 6px; padding: 22px; display: flex; flex-direction: column; gap: 10px; }
.svc.featured { border-color: var(--brand-fill); }
.svc .price { font-family: var(--display); font-size: 30px; color: var(--brand); }
.svc h3 { font-family: var(--body); font-weight: 600; font-size: 18px; }
.svc .per { font-size: 13px; color: var(--muted); margin-top: -8px; }
.svc ul { margin: 0; padding-left: 18px; color: var(--muted); font-size: 14px; display: flex; flex-direction: column; gap: 4px; }
.svc .btn { margin-top: auto; }

.summary { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; align-items: center; background: var(--manila); border-radius: 6px; padding: 14px 16px; margin-top: 20px; }
.card { background: var(--paper); border: 1px solid var(--line); border-radius: 6px; padding: 26px; }
.consent { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: 10px; font-weight: 400; font-size: 14px; color: var(--muted); align-items: start; }
.consent input { width: 20px; height: 20px; min-height: 0; margin: 2px 0 0; accent-color: var(--brand-fill); }
.err { color: var(--red); font-size: 13px; }
.prow { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: 15px; border-bottom: 1px solid var(--line); padding-bottom: 10px; }
.prow.total { border-bottom: 0; font-family: var(--display); font-size: 30px; color: var(--brand); padding-bottom: 0; }
.methods { display: flex; gap: 8px; flex-wrap: wrap; }

/* Opened file */
.opened { margin-top: 8px; }
.opened .folder .body { box-shadow: none; }
.opened .sheet-head h1 { font-size: clamp(30px, 4.6vw, 46px); color: var(--brand); }
.bigno { font-family: var(--mono); font-size: clamp(22px, 3.4vw, 30px); letter-spacing: .06em; color: var(--ink); display: block; }
.openstamp { color: var(--red); border: 3px double currentColor; border-radius: 6px; padding: 6px 12px; font-family: var(--display); font-size: 22px; letter-spacing: .08em; transform: rotate(-6deg); display: inline-block; margin-top: 8px; }
.timeline { display: grid; grid-template-columns: repeat(auto-fit, minmax(88px, 1fr)); gap: 8px; margin-top: 22px; }
.tl { border-top: 3px solid var(--line); padding-top: 8px; font-size: 13px; color: var(--muted); }
.tl.done { border-color: var(--brand); color: var(--ink); }
.tl.now { border-color: var(--red); color: var(--ink); font-weight: 600; }
.files { list-style: none; padding: 0; margin: 18px 0 0; border: 1px solid var(--line); border-radius: 6px; background: var(--paper); }
.files li { display: flex; gap: 12px; align-items: center; justify-content: space-between; padding: 12px 14px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.files li:last-child { border-bottom: 0; }
.files .nm { min-width: 0; flex: 1 1 260px; font-size: 15px; }
.files .nm small { display: block; color: var(--muted); font-size: 12px; overflow-wrap: anywhere; }
.status { font-family: var(--mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; border-radius: 4px; padding: 3px 8px; border: 1.5px solid currentColor; }
.status.missing { color: var(--red); }
.status.received { color: var(--blue); }
.up { position: relative; }
.up input { position: absolute; inset: 0; opacity: 0; cursor: pointer; min-height: 0; }
.wa pre { white-space: pre-wrap; font-family: var(--body); font-size: 15px; background: var(--ground); border: 1px dashed var(--line); border-radius: 6px; padding: 12px 14px; margin: 10px 0; user-select: all; }

@media (max-width: 900px) {
  .hero .wrap { grid-template-columns: minmax(0, 1fr); gap: 40px; padding-block: 48px 56px; }
  section.sec .wrap, .close .wrap { grid-template-columns: minmax(0, 1fr); gap: 14px; padding-block: 64px; }
  section.sec + section.sec .wrap { padding-top: 8px; }
  .routes { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .fact:nth-child(2n) { border-right: 0; }
  .fact:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .two { grid-template-columns: minmax(0, 1fr); }
  .navbar .hide-sm { display: none; }
}
@media (max-width: 560px) {
  .progress { gap: 4px; }
  .tgrid { grid-template-columns: minmax(0, 1fr); }
  .progress li { font-size: 11px; }
  form.grid { grid-template-columns: minmax(0, 1fr); }
  .rows li { grid-template-columns: 40px minmax(0, 1fr); gap: 6px 14px; }
  .rows li p { grid-column: 2; }
  .rows h3 { font-size: 28px; }
  .routes, .facts { grid-template-columns: minmax(0, 1fr); }
  .fact { border-right: 0; border-bottom: 1px solid var(--line); }
  .fact:last-child { border-bottom: 0; }
  .sheet { padding: 18px; }
  .folder .body { padding: 10px; }
  .sheet-head { flex-direction: column; }
  .fileno { text-align: left; }
  .navbar .bar { padding-left: 14px; }
  .wordmark { font-size: 19px; }
  .timeline { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (prefers-reduced-motion: no-preference) {
  .navbar { transition: transform .25s ease; }
  .view:not([hidden]) { animation: rise .35s ease-out; }
  @keyframes rise { from { transform: translateY(6px); } to { transform: none; } }
  .stamp-in { animation: thump .45s cubic-bezier(.2,1.6,.4,1) both; }
  @keyframes thump { from { transform: rotate(-6deg) scale(1.6); opacity: 0; } to { transform: rotate(-6deg) scale(1); opacity: 1; } }
}

/* Live-site additions */
body { padding-bottom: env(safe-area-inset-bottom, 0px); }
img { max-width: 100%; }
.status.uploading { color: var(--muted); }
.files .nm small.failed, .scan .ok.failed { color: var(--red); }
.up:has(input:disabled) { opacity: .6; }
.up:has(input:disabled) input { cursor: progress; }
.up:has(input:focus-visible) { outline: 3px solid var(--focus); outline-offset: 2px; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
