/* 日式極簡 — washi paper, sumi ink, one vermilion seal.
   Hairlines instead of shadows, space instead of boxes.
   Type stays large: the readers are in their seventies. */

:root {
  --bg: #F6F2EA;          /* 和紙 */
  --paper: #FBF9F4;       /* lighter sheet for panels */
  --ink: #26231F;         /* 墨 */
  --ink-2: #5E5850;       /* 薄墨 */
  --ink-3: #716A60;
  --line: #DDD5C7;        /* hairline */
  --line-2: #C9BFAE;
  --shu: #B5432C;         /* 朱 — the only colour */
  --shu-ink: #FFFFFF;
  --shu-soft: #F1E2D8;
  --moss: #5D6B4E;        /* only for "uploaded ✓" */
  --serif: "Noto Serif TC", "Songti TC", "PMingLiU", serif;
  --sans: -apple-system, "PingFang TC", "Noto Sans TC", "Heiti TC", sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #171614; --paper: #1F1D1A; --ink: #EDE7DC; --ink-2: #B8AFA2; --ink-3: #9D958A;
    --line: #34302B; --line-2: #4A453E; --shu: #D9694F; --shu-ink: #171614; --shu-soft: #3A2620;
    --moss: #9DB08A; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #171614; --paper: #1F1D1A; --ink: #EDE7DC; --ink-2: #B8AFA2; --ink-3: #9D958A;
  --line: #34302B; --line-2: #4A453E; --shu: #D9694F; --shu-ink: #171614; --shu-soft: #3A2620;
  --moss: #9DB08A; color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 20px;
  line-height: 1.85;
  letter-spacing: .02em;
  padding-bottom: calc(100px + env(safe-area-inset-bottom));
}
main { max-width: 640px; margin: 0 auto; padding: 0 20px; }
h1, h2, h3 { font-family: var(--serif); font-weight: 700; line-height: 1.4; margin: 0; letter-spacing: .04em; }
h1 { font-size: 30px; }
h2 { font-size: 24px; }
h3 { font-size: 22px; }
p { margin: .5em 0; }
a { color: var(--ink); text-decoration-color: var(--line-2); text-underline-offset: 4px; }
button, input, textarea, select { font: inherit; color: inherit; letter-spacing: inherit; }
.muted { color: var(--ink-2); }
.small { font-size: 17px; }
[hidden] { display: none !important; }

/* seal (落款印) — the one red thing on a page */
.seal, .seal-sm {
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--shu); color: var(--shu-ink);
  font-family: var(--serif); font-weight: 700; border-radius: 3px;
}
.seal-sm { width: 26px; height: 26px; font-size: 15px; margin-right: 10px; flex: none; }

/* ---------- header ---------- */
.top {
  position: sticky; top: 0; z-index: 10;
  background: var(--bg);
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
  padding: calc(10px + env(safe-area-inset-top)) 20px 10px;
}
.top-inner { max-width: 640px; margin: 0 auto; display: flex; align-items: center; gap: 12px; }
.top-title {
  flex: 1; display: flex; align-items: center; color: var(--ink); text-decoration: none;
  font-family: var(--serif); font-weight: 700; font-size: 18px; letter-spacing: .06em;
}
.who-chip {
  border: 1px solid var(--line-2); background: transparent; border-radius: 999px;
  padding: 4px 16px; font-size: 17px; cursor: pointer; min-height: 42px;
}

/* ---------- bottom tabs ---------- */
.tabs {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 20;
  background: var(--bg);
  background: color-mix(in srgb, var(--bg) 90%, transparent);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border-top: 1px solid var(--line);
  display: flex; justify-content: center;
  padding-bottom: env(safe-area-inset-bottom);
}
.tabs a {
  flex: 1; max-width: 200px; text-align: center; text-decoration: none; color: var(--ink-3);
  padding: 10px 0 8px; font-size: 16px; line-height: 1.3; letter-spacing: .1em;
}
.tabs .ico { display: block; width: 28px; height: 28px; margin: 0 auto 2px; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
.tabs a.on { color: var(--ink); font-weight: 600; }
.tabs a.on .ico { stroke: var(--shu); stroke-width: 1.7; }

/* ---------- home ---------- */
.hero { padding: 26px 0 6px; text-align: center; }
.hero-art { display: block; width: 100%; max-width: 420px; height: auto; margin: 0 auto; }
.hero-art .sun { fill: var(--shu); }
.hero-art .ridge { fill: none; stroke: var(--ink); stroke-width: 1.3; stroke-linecap: round; }
.hero-art .ridge.far { stroke: var(--ink-3); stroke-width: 1; }
.hero-text { margin-top: 8px; }
.kicker-en { font-size: 13px; letter-spacing: .32em; color: var(--ink-3); }
.hero h1 { font-size: 32px; margin-top: 6px; letter-spacing: .08em; }
.hero .dates { color: var(--ink-2); margin: 4px 0 0; font-size: 18px; }

.route {
  list-style: none; padding: 0; margin: 22px 0 0;
  display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 4px 0;
  font-family: var(--serif); font-size: 17px; color: var(--ink-2); white-space: nowrap;
}
.route li { display: flex; align-items: center; }
.route li + li::before { content: ""; width: 14px; height: 1px; background: var(--line-2); margin: 0 7px; }

.countdown {
  text-align: center; margin: 26px 0 0; color: var(--ink-2); font-size: 18px; letter-spacing: .1em;
}
.countdown b { font-family: var(--serif); font-size: 34px; color: var(--shu); margin: 0 6px; font-weight: 700; vertical-align: -2px; }
.today-btn {
  display: flex; justify-content: center; align-items: baseline; gap: 12px;
  margin: 24px 0 0; padding: 18px 20px; border-radius: 4px;
  background: var(--ink); color: var(--bg); text-decoration: none;
  font-size: 22px; font-weight: 700; letter-spacing: .1em;
}
.today-btn span { font-family: var(--serif); font-size: 18px; opacity: .75; }
.who-line { text-align: center; color: var(--ink-3); font-size: 16px; margin: 18px 0 0; letter-spacing: .12em; }

.day-list { list-style: none; padding: 0; margin: 30px 0 10px; border-top: 1px solid var(--ink); }
.day-list li { border-bottom: 1px solid var(--line); }
.day-card {
  display: flex; gap: 18px; align-items: center; text-decoration: none; color: inherit;
  padding: 18px 2px;
}
.day-num {
  flex: none; width: 48px; text-align: center;
  font-family: var(--serif); font-size: 36px; font-weight: 700; line-height: 1; color: var(--ink);
}
.day-card.is-today .day-num { color: var(--shu); }
.day-body { flex: 1; min-width: 0; }
.day-card .t { font-family: var(--serif); font-weight: 700; font-size: 21px; line-height: 1.45; letter-spacing: .04em; }
.day-card .s { color: var(--ink-2); font-size: 16px; line-height: 1.6; }
.day-card .chev { color: var(--ink-3); font-size: 28px; font-weight: 300; }

/* ---------- day page ---------- */
.day-head { position: relative; padding: 32px 64px 10px 0; }
.day-head .seal { position: absolute; right: 0; top: 34px; width: 48px; height: 48px; font-size: 28px; }
.day-meta { color: var(--ink-2); font-size: 17px; letter-spacing: .1em; }
.day-head h1 { margin-top: 6px; font-size: 29px; }
.day-city { color: var(--ink-3); font-size: 17px; margin-top: 4px; letter-spacing: .1em; }
.summary { color: var(--ink-2); margin: 14px 0 0; padding-top: 14px; border-top: 1px solid var(--line); }

.weather-note {
  border-left: 2px solid var(--shu); padding: 4px 0 4px 16px; margin: 22px 0;
  font-size: 18px; color: var(--ink);
}

h2.sec {
  display: flex; align-items: center; gap: 14px; margin: 44px 0 18px; font-size: 22px; letter-spacing: .12em;
}
h2.sec::after { content: ""; flex: 1; height: 1px; background: var(--line); }

.timeline { list-style: none; padding: 0; margin: 0; }
.stop { position: relative; padding: 0 0 34px 30px; }
.stop::before { content: ""; position: absolute; left: 6px; top: 22px; bottom: 4px; width: 1px; background: var(--line-2); }
.stop:last-child::before { display: none; }
.stop .node {
  position: absolute; left: 0; top: 11px; width: 13px; height: 13px; border-radius: 50%;
  border: 1.5px solid var(--ink); background: var(--bg);
}
.stop .time { color: var(--shu); font-weight: 700; font-size: 18px; }
.stop .name { font-size: 23px; }
.jp { color: var(--ink-2); font-size: 17px; line-height: 1.6; margin-top: 2px; }
.say {
  display: inline-flex; align-items: center; gap: 4px; margin: 4px 0 0 4px; vertical-align: middle;
  border: 1px solid var(--line-2); color: var(--ink); background: transparent;
  border-radius: 999px; padding: 2px 14px 2px 10px; font-size: 16px; cursor: pointer; min-height: 40px;
}
.say svg { width: 20px; height: 20px; fill: var(--shu); stroke: var(--shu); stroke-width: 1.5; stroke-linecap: round; }
.say:active { background: var(--shu-soft); }

.card {
  background: var(--paper); border: 1px solid var(--line); border-radius: 4px;
  padding: 18px 20px; margin-top: 14px;
}
.move { color: var(--ink-2); font-size: 18px; margin-top: 6px; }

.label { font-size: 15px; letter-spacing: .24em; color: var(--ink-3); font-weight: 600; }
.look { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line); }
.tips-label { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line); }
.tips { margin: 6px 0 0; padding: 0; list-style: none; }
.tips li { position: relative; padding-left: 20px; font-size: 18px; margin: 8px 0; line-height: 1.7; }
.tips li::before { content: ""; position: absolute; left: 2px; top: .85em; width: 7px; height: 1px; background: var(--ink-2); }
.tips li.warn::before { display: none; }
.tips li.warn { padding-left: 0; }
.warn-tag {
  display: inline-block; font-size: 14px; letter-spacing: .1em; color: var(--shu);
  border: 1px solid var(--shu); border-radius: 2px; padding: 0 6px; margin-right: 8px; line-height: 1.6; vertical-align: 2px;
}

.story { margin-top: 18px; padding: 4px 0 2px 18px; border-left: 2px solid var(--shu); }
.story .label { color: var(--shu); }
.story p { font-family: var(--serif); font-size: 19px; line-height: 1.95; }
.story p + p { margin-top: .7em; }

/* ---------- meals ---------- */
.meals { margin-top: 30px; }
.meals h3, .times h3 { font-size: 20px; letter-spacing: .12em; }
.meal-list { list-style: none; padding: 0; margin: 10px 0 0; }
.meal-list li { display: flex; gap: 14px; align-items: baseline; padding: 8px 0; border-bottom: 1px solid var(--line); }
.meal-list li:last-child { border-bottom: 0; }
.meal-badge {
  flex: none; width: 32px; height: 32px; border: 1px solid var(--ink); border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--serif); font-size: 16px; font-weight: 700; transform: translateY(-2px);
}

/* ---------- hotel ---------- */
.hotel { margin-top: 30px; padding: 0; border-color: var(--ink); }
.hotel-band {
  display: flex; justify-content: space-between; padding: 8px 20px;
  border-bottom: 1px solid var(--ink); font-size: 15px; letter-spacing: .3em; color: var(--ink-2);
}
.hotel-band span { letter-spacing: .1em; color: var(--shu); }
.hotel-body { padding: 18px 20px 20px; }
.hotel h2 { font-size: 25px; }
.hotel dl { margin: 14px 0 0; display: grid; grid-template-columns: auto 1fr; gap: 4px 16px; font-size: 18px; }
.hotel dt { color: var(--ink-3); letter-spacing: .1em; }
.hotel dd { margin: 0; }

/* ---------- buttons ---------- */
.btn {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; min-height: 60px; margin-top: 16px; padding: 12px 16px;
  border-radius: 4px; border: 1px solid var(--ink); cursor: pointer; text-decoration: none;
  font-size: 20px; font-weight: 700; letter-spacing: .12em;
  background: var(--ink); color: var(--bg);
}
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--line-2); }
.btn.quiet { background: transparent; color: var(--ink-3); font-weight: 400; min-height: 48px; font-size: 17px; border: 0; }
.btn:disabled { opacity: .55; }
.btn-row { display: flex; gap: 10px; }
.btn-row .btn { flex: 1; }

.day-nav { display: flex; gap: 10px; margin: 30px 0 6px; }
.day-nav a {
  flex: 1; text-align: center; text-decoration: none; color: var(--ink);
  border: 1px solid var(--line-2); border-radius: 4px; padding: 12px 8px; font-size: 18px; letter-spacing: .08em;
}
.day-nav a.off { visibility: hidden; }

/* ---------- times ---------- */
.times { margin-top: 24px; }
.times .muted { font-size: 16px; }
.times-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0; margin-top: 10px; border-top: 1px solid var(--line); }
.time-cell {
  text-align: left; background: transparent; border: 0; border-bottom: 1px solid var(--line);
  padding: 10px 4px; cursor: pointer; display: flex; flex-direction: column; min-height: 78px;
}
.time-cell:nth-child(odd) { border-right: 1px solid var(--line); padding-right: 12px; }
.time-cell:nth-child(even) { padding-left: 14px; }
.time-cell .lbl { font-size: 15px; color: var(--ink-3); letter-spacing: .08em; }
.time-cell .val { font-family: var(--serif); font-size: 25px; font-weight: 700; line-height: 1.35; }
.time-cell .val.none { font-family: var(--sans); font-size: 17px; font-weight: 400; color: var(--ink-3); }
.time-cell .by { font-size: 13px; color: var(--ink-3); }

/* ---------- photos ---------- */
.section-title { display: flex; align-items: baseline; justify-content: space-between; margin: 34px 0 10px; padding-bottom: 6px; border-bottom: 1px solid var(--line); }
.section-title a { text-decoration: none; }
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; }
.grid a { display: block; aspect-ratio: 1; overflow: hidden; border-radius: 2px; background: var(--line); position: relative; }
.grid img { width: 100%; height: 100%; object-fit: cover; display: block; }
.grid .has-note::after {
  content: ""; position: absolute; right: 6px; bottom: 6px; width: 8px; height: 8px; border-radius: 50%;
  background: var(--shu); box-shadow: 0 0 0 2px #fff;
}
.empty { border: 1px dashed var(--line-2); border-radius: 4px; padding: 22px 18px; text-align: center; color: var(--ink-3); font-size: 17px; }

.photo-page { padding-top: 20px; }
.photo-page img.big { width: 100%; border-radius: 2px; display: block; background: var(--line); }
.meta { color: var(--ink-3); font-size: 16px; margin: 12px 0; letter-spacing: .04em; }
.note-box { font-family: var(--serif); font-size: 22px; line-height: 1.8; margin: 8px 0; white-space: pre-wrap; }
.claude-box { margin: 22px 0; padding: 4px 0 4px 18px; border-left: 2px solid var(--ink-3); white-space: pre-wrap; }
.claude-box .label { white-space: normal; display: block; margin-bottom: 4px; }
h3.sub { font-size: 19px; letter-spacing: .14em; margin-top: 30px; }
.comments { list-style: none; padding: 0; margin: 8px 0 12px; border-top: 1px solid var(--line); }
.comments li { border-bottom: 1px solid var(--line); padding: 10px 2px; }
.comments li { display: flex; gap: 12px; }
.comments b { font-weight: 700; flex: none; }

textarea, input[type=text], input[type=tel] {
  width: 100%; border: 1px solid var(--line-2); border-radius: 4px; padding: 12px 14px;
  background: var(--paper); font-size: 20px;
}
textarea { min-height: 90px; resize: vertical; }
textarea:focus, input:focus { outline: none; border-color: var(--ink); }

/* ---------- sheets ---------- */
.sheet {
  position: fixed; inset: 0; z-index: 40; background: var(--bg); overflow-y: auto;
  padding: calc(16px + env(safe-area-inset-top)) 20px calc(24px + env(safe-area-inset-bottom));
}
.sheet-inner { max-width: 640px; margin: 0 auto; }
.up-item { display: flex; gap: 14px; margin: 16px 0; align-items: flex-start; padding-bottom: 16px; border-bottom: 1px solid var(--line); }
.up-item img { width: 96px; height: 96px; object-fit: cover; border-radius: 2px; flex: none; background: var(--line); }
.up-item .right { flex: 1; min-width: 0; }
.up-status { font-size: 16px; color: var(--ink-3); }
.up-status.ok { color: var(--moss); }
.up-status.bad { color: var(--shu); }

.center-page { min-height: 100vh; display: flex; flex-direction: column; justify-content: center; padding: 24px 0; }
.center-page h2 { text-align: center; }
.people { display: grid; grid-template-columns: 1fr 1fr; gap: 0; margin-top: 22px; border-top: 1px solid var(--line); }
.people button {
  min-height: 74px; border: 0; border-bottom: 1px solid var(--line); background: transparent;
  font-family: var(--serif); font-size: 23px; font-weight: 700; cursor: pointer; letter-spacing: .08em;
}
.people button:nth-child(odd) { border-right: 1px solid var(--line); }
.people button.on { color: var(--shu); }
.people button:active { background: var(--shu-soft); }

.seal.big { width: 56px; height: 56px; font-size: 30px; margin: 0 auto 18px; }
.login-title { text-align: center; font-size: 28px; letter-spacing: .1em; }
.code-input { text-align: center; letter-spacing: .5em; font-size: 34px !important; font-family: var(--serif); }
.err { color: var(--shu); min-height: 1.8em; text-align: center; }

.toast {
  position: fixed; left: 50%; bottom: calc(110px + env(safe-area-inset-bottom)); transform: translateX(-50%);
  background: var(--ink); color: var(--bg); padding: 10px 24px; border-radius: 4px; z-index: 60; font-size: 18px; letter-spacing: .08em;
}
.sample-flag { border-left: 2px solid var(--shu); padding-left: 14px; font-size: 17px; margin: 14px 0; }

.keep { word-break: keep-all; overflow-wrap: anywhere; }

/* ---------- weather ---------- */
.wx { margin-top: 24px; }
.wx h3 { font-size: 20px; letter-spacing: .12em; }
.wx-list { list-style: none; padding: 0; margin: 10px 0 0; border-top: 1px solid var(--line); }
.wx-list li {
  display: grid; grid-template-columns: 40px 1fr auto auto; gap: 12px; align-items: center;
  padding: 10px 0; border-bottom: 1px solid var(--line);
}
.wx-ch {
  width: 38px; height: 38px; border: 1px solid var(--ink); border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--serif); font-weight: 700; font-size: 19px;
}
.wx-place { font-size: 18px; line-height: 1.4; min-width: 0; }
.wx-place small { display: block; font-size: 14px; color: var(--ink-3); letter-spacing: .04em; }
.wx-temp { text-align: right; font-family: var(--serif); line-height: 1.2; }
.wx-temp b { display: block; font-size: 23px; }
.wx-temp i { font-style: normal; font-size: 17px; color: var(--ink-3); }
.wx-rain { text-align: right; font-size: 17px; line-height: 1.2; min-width: 44px; }
.wx-rain small { display: block; font-size: 13px; color: var(--ink-3); }
.wx-advice { margin-top: 12px; border-left: 2px solid var(--shu); padding-left: 14px; }
.wx-advice p { margin: 4px 0; font-size: 18px; }
.wx-src { font-size: 13px; color: var(--ink-3); margin: 10px 0 0; }
.day-card .wx-s:empty { display: none; }

/* ---------- spot photos ---------- */
.spot { margin: 14px 0 0; }
.spot img { display: block; width: 100%; height: auto; border-radius: 2px; background: var(--line); }
.spot img.tall { max-height: 460px; width: auto; max-width: 100%; margin: 0 auto; }
.spot figcaption { display: flex; flex-direction: column; gap: 0; margin-top: 8px; }
.spot figcaption span { font-size: 16px; color: var(--ink-2); letter-spacing: .06em; }
.spot figcaption a { font-size: 13px; color: var(--ink-3); text-decoration: none; letter-spacing: .02em; line-height: 1.5; word-break: break-word; }

/* ---------- navigation ---------- */
.page-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-top: 12px; }
.back {
  background: transparent; border: 0; padding: 8px 4px; min-height: 48px; cursor: pointer;
  font-size: 18px; color: var(--ink); letter-spacing: .06em; white-space: nowrap; flex: none;
}
.day-strip { display: flex; gap: 4px; }
.day-strip a {
  width: 36px; height: 42px; display: inline-flex; align-items: center; justify-content: center; position: relative;
  font-family: var(--serif); font-weight: 700; font-size: 18px; text-decoration: none; color: var(--ink-2);
  border: 1px solid var(--line); border-radius: 3px;
}
.day-strip a.on { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.day-strip a.today::after {
  content: ""; position: absolute; bottom: 3px; width: 5px; height: 5px; border-radius: 50%; background: var(--shu);
}
.day-head { padding: 18px 0 10px; }
.tabs a.tab-up { color: var(--shu); }
.tabs a.tab-up .ico { stroke: var(--shu); }

.center-msg { padding: 60px 0 0; text-align: center; }
.center-msg .countdown { margin-bottom: 8px; font-size: 22px; }

/* ---------- small things ---------- */
.link-btn {
  background: transparent; border: 0; padding: 6px 0; min-height: 44px; cursor: pointer;
  color: var(--ink-3); font-size: 17px; text-decoration: underline; text-underline-offset: 4px; text-decoration-color: var(--line-2);
}
.photo-page img.big, .spot img { cursor: zoom-in; }

.edit-sheet { padding-top: 40px; }
.edit-sheet h2 { font-size: 28px; margin: 4px 0 6px; }
.big-input { font-family: var(--serif); font-size: 34px !important; text-align: center; padding: 16px !important; margin-top: 14px; }

.lightbox {
  position: fixed; inset: 0; z-index: 70; background: #0E0D0C;
  display: flex; align-items: center; justify-content: center; flex-direction: column;
  padding: env(safe-area-inset-top) 0 env(safe-area-inset-bottom);
}
.lightbox img { max-width: 100%; max-height: calc(100% - 90px); object-fit: contain; }
.lb-close {
  margin-top: 18px; min-height: 52px; padding: 0 36px; border-radius: 4px; cursor: pointer;
  background: transparent; color: #EDE7DC; border: 1px solid #5A544C; font-size: 19px; letter-spacing: .2em;
}
.no-photo { margin: 12px 0 0; padding: 14px; border: 1px dashed var(--line-2); border-radius: 2px; text-align: center; font-size: 16px; color: var(--ink-3); }
