:root {
  --paper: #fbf5e8;
  --paper-deep: #efe6d2;
  --page: #f1e8d3;
  --teal: #234a70;
  --teal-soft: #35648f;
  --amber: #d9a441;
  --amber-deep: #7d5410;
  --rose: #a2492f;
  --ink: #24282c;
  --muted: #55606a;
  --line: #d8ccb0;
  --card: #fffcf4;
  --danger: #8f2d1f;
  --radius: 8px;
  --col: 1040px;
  --nav-h: 64px;
  --serif: "Noto Serif TC", "Songti TC", "PMingLiU", "Source Han Serif TC", Georgia, "Times New Roman", serif;
  --sans: "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", "Heiti TC", system-ui, sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--page);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
:focus-visible { outline: 3px solid var(--teal-soft); outline-offset: 2px; }
[hidden] { display: none !important; }
button { font: inherit; }
.loading { padding: 24px 20px; color: var(--muted); }

.app {
  max-width: var(--col);
  margin: 0 auto;
  min-height: 100vh;
  background: var(--paper);
  padding-bottom: calc(var(--nav-h) + env(safe-area-inset-bottom, 0px) + 16px);
}

/* ---------- top bar ---------- */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 20px;
  background: var(--paper);
  color: var(--teal);
  border-bottom: 3px double #c9bb98;
}
.brand { display: flex; align-items: center; gap: 10px; min-height: 44px; min-width: 0; }
.brand-mark { flex: none; width: 32px; height: 32px; }
.brand-text { display: flex; flex-direction: column; line-height: 1.2; min-width: 0; }
.brand-text strong { font-family: var(--serif); font-size: 17px; font-weight: 700; letter-spacing: .02em; }
.brand-text span { font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--amber-deep); }
.lang {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  padding: 0 14px;
  border: 1.5px solid var(--teal);
  border-radius: var(--radius);
  background: transparent;
  color: var(--teal);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: .04em;
  cursor: pointer;
}

/* ---------- draft + storage strips ---------- */
.draft-strip {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 12px;
  padding: 8px 20px;
  background: var(--amber);
  color: #2e2006;
  border-bottom: 2px solid var(--amber-deep);
}
.draft-badge { font-weight: 800; font-size: 14px; overflow-wrap: anywhere; }
.draft-return {
  min-height: 44px;
  padding: 0 14px;
  border: 1.5px solid #2e2006;
  border-radius: var(--radius);
  background: transparent;
  color: #2e2006;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
}
.storage-notice {
  padding: 10px 20px;
  background: #fbf1da;
  border-bottom: 1px solid #ecd49c;
  color: #4a3a14;
  font-size: 14px;
}

/* ---------- hero: postcard first, bilingual intro after ---------- */
.hero { background: var(--paper); color: var(--ink); padding: 0; border-bottom: 1px solid var(--line); }
.skyline { display: block; width: 100%; height: auto; }
.hero-intro { padding: 22px 20px 26px; text-align: center; }
.eyebrow { display: inline-block; margin: 0 0 10px; font-size: 13px; font-weight: 700; color: var(--amber-deep); letter-spacing: .12em; }
.hero h1 { margin: 0; font-family: var(--serif); font-size: 30px; line-height: 1.28; font-weight: 700; letter-spacing: .01em; color: var(--teal); }
.hero h1 span { display: block; }
.hero h1 span + span { color: var(--rose); font-size: 22px; margin-top: 6px; font-weight: 600; }
.hero-lead { margin: 14px auto 0; max-width: 34em; font-size: 16px; color: var(--muted); }

/* ---------- main column ---------- */
.content { padding: 20px 20px 28px; display: flex; flex-direction: column; gap: 24px; min-width: 0; overflow-wrap: anywhere; }
.content:focus { outline: none; }
.content h1 { margin: 0; font-family: var(--serif); font-size: 26px; line-height: 1.3; color: var(--teal); }
.content .lead { margin: 6px 0 0; color: var(--muted); }
.content p { margin: 0; }
.meta { font-size: 14px; color: var(--muted); }

.notice {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 14px 16px;
  background: #fbf1da;
  border: 1px solid #e3cb92;
  border-left: 5px solid var(--amber);
  border-radius: var(--radius);
  font-size: 14px;
  color: #4a3a14;
}
.notice svg { flex: none; width: 22px; height: 22px; margin-top: 2px; }
.notice b { display: block; font-size: 15px; color: #3a2c0c; }
.notice p { margin: 2px 0 0; }
.notice.stop { background: #f9e4df; border-color: #e3b0a6; border-left-color: var(--danger); color: #4a1a12; }
.notice.stop b { color: var(--danger); }

.section-title { margin: 0 0 10px; font-family: var(--serif); font-size: 20px; color: var(--teal); line-height: 1.3; padding-bottom: 6px; border-bottom: 1px solid var(--line); }
.section-title small { display: block; margin-top: 2px; font-family: var(--sans); font-size: 13px; font-weight: 400; color: var(--muted); }

.actions { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.action {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-height: 44px;
  padding: 14px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--card);
}
.action .ico { width: 40px; height: 40px; display: grid; place-items: center; border-radius: var(--radius); background: var(--paper-deep); }
.action .ico svg { width: 24px; height: 24px; }
.action strong { font-family: var(--serif); font-size: 17px; line-height: 1.3; color: var(--teal); }
.action .sub { font-size: 13px; color: var(--muted); line-height: 1.45; }
.action.primary { background: var(--teal); border-color: var(--teal); box-shadow: inset 0 -3px 0 var(--amber); }
.action.primary .ico { background: rgba(217, 164, 65, .22); }
.action.primary strong { color: #fff; }
.action.primary .sub { color: #dbe6f0; }

/* ---------- checklist ---------- */
.progress { font-size: 14px; font-weight: 700; color: var(--teal); margin: 0 0 10px; }
.checklist, .plain-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.task {
  padding: 14px 16px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: grid;
  gap: 6px;
  align-content: start;
}
.task.done { background: var(--paper-deep); }
.check {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  cursor: pointer;
  font-weight: 700;
  color: var(--teal);
}
.check input { flex: none; width: 24px; height: 24px; margin: 0; accent-color: var(--teal); cursor: pointer; }
.task .desc { font-size: 15px; color: var(--ink); }
.task .owner { font-size: 13px; color: var(--muted); }

.btn, .link-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 16px;
  border-radius: var(--radius);
  border: 1.5px solid var(--teal);
  background: transparent;
  color: var(--teal);
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  text-align: center;
}
.btn.solid { background: var(--teal); color: #fff; }
.btn.amber { background: var(--amber); border-color: var(--amber-deep); color: #2e2006; }
.link-btn { align-self: flex-start; }
.btn-row { display: flex; flex-wrap: wrap; gap: 10px; }

.text-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-weight: 700;
  color: var(--teal);
  border-bottom: 2px solid var(--amber);
  align-self: flex-start;
}
.footer-links { padding-top: 4px; border-top: 1px solid var(--line); }
.owner-link { display: inline-flex; align-items: center; min-height: 44px; font-size: 13px; color: var(--muted); text-decoration: underline; }

/* ---------- scams list ---------- */
.search { display: flex; flex-direction: column; gap: 8px; }
.search label { font-weight: 700; font-size: 15px; color: var(--teal); }
.search input {
  width: 100%;
  min-height: 52px;
  padding: 0 14px;
  border: 1.5px solid var(--teal);
  border-radius: var(--radius);
  background: var(--card);
  font: inherit;
  color: var(--ink);
}
.search input:focus-visible { outline: 3px solid var(--teal-soft); outline-offset: 0; }
.chips { display: flex; flex-wrap: wrap; gap: 10px; margin: 0; padding: 0; list-style: none; }
.chip {
  min-height: 44px;
  padding: 0 16px;
  border-radius: var(--radius);
  border: 1.5px solid var(--teal);
  background: transparent;
  color: var(--teal);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}
.chip[aria-pressed="true"] { background: var(--teal); color: #fff; }
.count { font-size: 14px; color: var(--muted); }
.empty, .error-box {
  padding: 16px;
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  background: var(--card);
  color: var(--muted);
}
.error-box { border-style: solid; border-color: #e3b0a6; background: #f9e4df; color: #4a1a12; }

.cards { display: grid; gap: 14px; list-style: none; margin: 0; padding: 0; }
.card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 18px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 1px 0 rgba(35, 74, 112, .06);
}
.tag {
  align-self: flex-start;
  padding: 2px 10px;
  border-radius: 4px;
  background: #f6e6c3;
  color: var(--amber-deep);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .04em;
}
.tag.safety { background: #dde8f2; color: var(--teal); }
.tag.consumer { background: #f3dfd7; color: #7a3420; }
.card h2, .card h3 { margin: 0; font-family: var(--serif); font-size: 19px; line-height: 1.35; color: var(--teal); }
.card p { font-size: 15px; color: var(--muted); }
.card-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; margin-top: auto; }

/* ---------- detail ---------- */
.detail { max-width: 760px; }
.detail section { padding: 16px 0; border-top: 1px solid var(--line); }
.detail section:first-of-type { border-top: 0; }
.detail h2 { margin: 0 0 6px; font-family: var(--serif); font-size: 18px; color: var(--teal); }
.example {
  margin: 0;
  padding: 12px 14px;
  background: var(--paper-deep);
  border-left: 4px solid var(--amber);
  border-radius: var(--radius);
}
.example-label { display: block; margin-bottom: 4px; font-size: 13px; font-weight: 700; color: var(--amber-deep); }
.sources { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.sources a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-weight: 600;
  color: var(--teal);
  text-decoration: underline;
  text-decoration-color: var(--amber);
  text-underline-offset: 3px;
}
.dates { margin: 0; display: grid; gap: 8px; }
.dates div { padding: 10px 12px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); }
.dates dt { font-size: 13px; color: var(--muted); }
.dates dd { margin: 0; font-weight: 700; }
.dates .checked { border-left: 5px solid var(--teal); }
.dates .incident { border-left: 5px solid var(--amber); border-style: dashed; border-left-style: solid; }

/* ---------- help ---------- */
.call-grid { display: grid; gap: 12px; }
.call {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-height: 72px;
  justify-content: center;
  padding: 14px 18px;
  border-radius: var(--radius);
  background: var(--teal);
  color: #fff;
}
.call strong { font-size: 22px; line-height: 1.25; }
.call span { font-size: 14px; color: #dbe6f0; }
.call.danger { background: var(--danger); }
.call.danger span { color: #f6d9d3; }
.steps { margin: 0; padding-left: 1.4em; display: grid; gap: 8px; }

/* ---------- editor ---------- */
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-weight: 700; color: var(--teal); }
.field textarea {
  width: 100%;
  min-height: 240px;
  padding: 12px;
  border: 1.5px solid var(--teal);
  border-radius: var(--radius);
  background: var(--card);
  font: 13px/1.5 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  color: var(--ink);
  resize: vertical;
}
.field input[type="file"] { min-height: 44px; max-width: 100%; font: inherit; }
.status { padding: 12px 14px; border-radius: var(--radius); background: #dde8f2; color: var(--teal); font-weight: 600; }
.errors { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.errors li { padding: 10px 12px; background: #f9e4df; border: 1px solid #e3b0a6; border-radius: var(--radius); color: #4a1a12; font-size: 14px; }
.errors code { display: block; font: 600 13px ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; overflow-wrap: anywhere; }

/* ---------- bottom nav ---------- */
.bottom-nav {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 10;
  max-width: var(--col);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  background: var(--paper);
  border-top: 3px double #c9bb98;
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
.bottom-nav a {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  min-height: var(--nav-h);
  padding: 6px 2px;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.2;
  text-align: center;
  color: #4a5560;
}
.bottom-nav svg { width: 24px; height: 24px; }
.bottom-nav a[aria-current="page"] { color: var(--teal); background: var(--paper-deep); box-shadow: inset 0 3px 0 var(--rose); }

/* ---------- travel pack: pillars, planner, prepare, safety guidance ---------- */
.stack { display: grid; gap: 12px; min-width: 0; }
.filter-label { margin: 4px 0 -4px; font-size: 13px; font-weight: 700; color: var(--muted); }
.pillars { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.pillar {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-height: 44px;
  min-width: 0;
  padding: 12px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--card);
}
.pillar strong { font-family: var(--serif); font-size: 16px; line-height: 1.3; color: var(--teal); }
.pillar .sub { font-size: 12px; line-height: 1.45; color: var(--muted); }
.pillar.primary { background: var(--teal); border-color: var(--teal); box-shadow: inset 0 -3px 0 var(--amber); }
.pillar.primary strong { color: #fff; }
.pillar.primary .sub { color: #dbe6f0; }

.purpose-intro { color: var(--muted); }
.plan { display: grid; gap: 16px; padding: 18px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); min-width: 0; }
.plan h3 { margin: 0; font-family: var(--serif); font-size: 20px; line-height: 1.35; color: var(--teal); }
.plan h3.sub-title { font-size: 17px; padding-bottom: 4px; border-bottom: 1px solid var(--line); }
.plan h4, .guide-entry h4 { margin: 0; font-family: var(--serif); font-size: 17px; line-height: 1.35; color: var(--teal); }

.budget { display: grid; gap: 8px; padding: 14px; background: #fbf1da; border: 1px solid #e3cb92; border-left: 5px solid var(--amber); border-radius: var(--radius); color: #3a2c0c; }
.budget-label { font-size: 13px; font-weight: 700; color: var(--amber-deep); }
.budget-total { font-family: var(--serif); font-size: 26px; font-weight: 700; line-height: 1.2; color: var(--teal); }
.budget-parts { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; font-size: 14px; }
.budget-parts li { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 2px 12px; }
.budget-note { font-size: 14px; line-height: 1.55; }

.timeline { list-style: none; margin: 0; padding: 0 0 0 14px; display: grid; gap: 14px; border-left: 3px solid var(--amber); }
.stop { display: grid; gap: 6px; min-width: 0; }
.stop > p { font-size: 15px; }
.period { align-self: start; justify-self: start; padding: 2px 10px; border-radius: 4px; background: var(--teal); color: #fff; font-size: 12px; font-weight: 700; }
.lbl { display: block; font-size: 13px; font-weight: 700; color: var(--amber-deep); }
.field-block { display: grid; gap: 2px; }
.field-block p { font-size: 15px; }

.disc { border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); min-width: 0; }
.disc > summary, .guide-entry > summary {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 10px;
  min-height: 44px;
  padding: 8px 14px;
  font-weight: 700;
  color: var(--teal);
  cursor: pointer;
}
.disc.small { border-style: dashed; }
.disc.small > summary { font-size: 14px; }
.disc-body { display: grid; gap: 10px; padding: 4px 14px 14px; min-width: 0; }

.tag-row { display: flex; flex-wrap: wrap; gap: 6px; }
.tag.fact.official_fact { background: #dde8f2; color: var(--teal); }
.tag.fact.editorial_advice { background: #f6e6c3; color: var(--amber-deep); }
.tag.scam { background: #f3dfd7; color: #7a3420; }
.tag.dont-do { background: #ece4d0; color: var(--ink); }
.task .tag-row { margin-top: 2px; }
.src-list li { display: flex; flex-direction: column; }
.src-meta { font-size: 13px; color: var(--muted); }

.guide-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.guide-entry { border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); min-width: 0; }
.guide-entry > summary { color: var(--ink); display: grid; grid-template-columns: 3.3em minmax(0, 1fr) auto; align-items: start; }
.situation-stars { font-family: sans-serif; white-space: nowrap; letter-spacing: 0; color: var(--amber-deep); }
.star-legend { border:1px solid var(--line); border-radius:var(--radius); padding:12px 14px; background:var(--card); }
.star-legend h2 { font:700 16px/1.4 var(--sans); margin:0 0 8px; color:var(--teal); }
.star-legend ul { display:grid; gap:6px; list-style:none; padding:0; margin:0; }
.star-legend li { display:grid; grid-template-columns:3.3em minmax(0,1fr); gap:10px; align-items:baseline; font-size:15px; }
.star-legend .meta { margin:8px 0 0; font-size:12px; }
.safety-order { display:flex; flex-wrap:wrap; align-items:center; gap:8px 12px; font-weight:700; color:var(--teal); }
.safety-order select { flex:1; min-width:220px; }
.guide-entry > summary strong { min-width: 0; overflow-wrap: anywhere; font-family: var(--serif); color: var(--teal); }

/* ---------- desktop ---------- */
@media (min-width: 720px) {
  .app { border-left: 1px solid var(--line); border-right: 1px solid var(--line); }
  .topbar { padding: 12px 40px; }
  .draft-strip, .storage-notice { padding-left: 40px; padding-right: 40px; }
  .hero { padding: 28px 40px 0; border-bottom: 0; }
  .skyline { border: 1px solid var(--line); box-shadow: 0 2px 10px rgba(35, 74, 112, .12); }
  .hero-intro { padding: 30px 0 8px; }
  .hero h1 { font-size: 38px; }
  .hero h1 span + span { font-size: 26px; }
  .content { padding: 28px 40px 40px; gap: 32px; }
  .content h1 { font-size: 30px; }
  .actions, .checklist, .cards, .call-grid { grid-template-columns: 1fr 1fr; }
  .checklist, .cards { gap: 16px; }
  .checklist { align-items: start; }
  .pillar { padding: 16px; }
  .pillar strong { font-size: 18px; }
  .pillar .sub { font-size: 14px; }
  .detail .dates { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 359px) {
  .hero h1 { font-size: 26px; }
  .actions { grid-template-columns: 1fr; }
}
@media (max-width: 479px) {
  .pillars { gap: 6px; }
  .pillar { padding: 10px 8px; }
  .pillar strong { font-size: 15px; }
  .pillar .sub { font-size: 12px; }
}
@media (max-width: 359px) {
  .pillars { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; animation: none !important; }
}

/* Travel order stays visible; secondary explanations never precede the main action. */
.header-actions { display:flex; align-items:center; justify-content:flex-end; gap:10px; flex-wrap:wrap; }
.quick-link { display:inline-flex; align-items:center; min-height:44px; color:var(--teal); font-size:13px; font-weight:700; text-decoration:underline; text-underline-offset:4px; }
.topbar { flex-wrap:wrap; }
.stage-choices { display:grid; gap:10px; }
.stage-card { display:flex; align-items:center; gap:14px; min-height:88px; padding:16px; background:var(--card); border:1px solid var(--line); border-radius:var(--radius); color:var(--teal); }
.stage-card > .stack { flex:1; gap:3px; }
.stage-card strong { font-family:var(--serif); font-size:20px; }
.stage-card .sub { font-size:14px; line-height:1.5; color:var(--muted); }
.step-number { flex:none; font-size:13px; font-weight:800; letter-spacing:.07em; color:var(--amber-deep); }
.journey-status { padding:16px; border:1px solid var(--line); border-radius:var(--radius); }
.journey-steps { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:4px; }
.journey-step { display:flex; flex-direction:column; gap:3px; padding:8px 4px; min-height:64px; border-bottom:2px solid var(--line); color:var(--muted); text-align:center; font-size:13px; line-height:1.35; }
.journey-step[aria-current="step"] { color:var(--teal); background:var(--paper-deep); border-color:var(--rose); font-weight:700; }
.stage-tabs { display:flex; gap:6px; flex-wrap:wrap; }
.stage-tabs .btn { flex:1 1 90px; padding:8px; font-size:14px; line-height:1.4; }
.stage-tabs [aria-current="step"] { color:#fff; background:var(--teal); }
.next-step { padding:16px; border:1px solid #e3cb92; border-left:4px solid var(--amber); border-radius:var(--radius); background:#fbf1da; }
.next-step .eyebrow { margin:0; font-size:12px; }
.next-step .btn { padding:10px 14px; }
.task h3 { margin:0; font-family:var(--serif); color:var(--teal); font-size:20px; }
.flow-checklist { grid-template-columns:1fr; }
.task, .arrival-card, .stop { scroll-margin-top:16px; }
.tdac-steps { display:grid; gap:20px; margin:0; padding-left:24px; }
.tdac-steps li::marker { color:var(--amber-deep); font-weight:700; }
.route-summary { color:var(--teal); font-weight:600; }
.arrival-list { list-style:none; padding:0; margin:0; display:grid; gap:16px; }
.arrival-card { background:var(--card); padding:18px; border:1px solid var(--line); border-radius:var(--radius); }
.arrival-card h2 { font-family:var(--serif); color:var(--teal); font-size:21px; margin:0; line-height:1.4; }
.arrival-card h3 { font-size:17px; margin:0; color:var(--teal); }
.day-overview { margin:0; padding-left:24px; }
.day-overview .text-link { border:0; }
.active-stop { background:var(--card); padding:18px; border:1px solid var(--line); border-left:4px solid var(--amber); border-radius:var(--radius); }
.active-stop h4 { font-family:var(--serif); color:var(--teal); font-size:22px; margin:0; }
.hero-intro { padding:16px 20px; }
.hero h2 { margin:0; color:var(--teal); font-family:var(--serif); font-size:22px; }
.hero h2 span { display:block; }
.hero h2 span + span { color:var(--rose); font-size:18px; }
.hero-lead { font-size:14px; margin-top:8px; }
.module-builder { display:grid; gap:24px; align-items:start; }
.schedule-board { border:2px solid var(--teal); border-radius:var(--radius); padding:16px; background:var(--paper); }
.schedule-heading { display:flex; align-items:center; justify-content:space-between; gap:12px; position:sticky; top:0; z-index:1; background:var(--paper); padding:4px 0; }
.schedule-heading h2,.module-library h2 { margin:0; color:var(--teal); font-family:var(--serif); }
.schedule-list { list-style:none; padding:0; margin:0; }
.schedule-drop { border:1px dashed var(--line); border-radius:6px; padding:6px 10px; font-size:12px; color:var(--muted); text-align:center; min-height:28px; }
.schedule-slot + .schedule-slot { margin-top:6px; }
.scheduled-card { padding:12px; border:1px solid var(--line); border-radius:8px; background:var(--card); }
.scheduled-card p { margin:0 0 6px; }
.scheduled-card > strong { display:block; }
.module-grid { display:grid; gap:16px; }
.module-card { display:flex; flex-direction:column; gap:10px; border:1px solid var(--line); border-top:3px solid var(--amber); padding:16px; border-radius:var(--radius); background:var(--card); min-width:0; }
.module-card h3 { font-family:var(--serif); color:var(--teal); font-size:22px; line-height:1.4; margin:0; }
.module-card p { margin:0; }
.module-card > .btn-row { margin-top:auto; }
.drag-handle { touch-action:none; cursor:grab; }
.drop-over { background:#d7e9e6!important; outline:3px solid var(--teal); }
.drag-ghost { position:fixed; pointer-events:none; z-index:1000; max-width:240px; background:var(--teal); color:#fff; padding:12px; border-radius:8px; box-shadow:0 5px 20px #0004; }
.module-dragging { user-select:none; cursor:grabbing; }
.schedule-summary { border-top:1px solid var(--line); padding-top:10px; }
.warning { padding:10px; color:#664816; background:#fff1cf; border-left:3px solid var(--amber); font-size:14px; }
.btn:disabled { opacity:.55; cursor:default; }
select { min-height:44px; max-width:100%; border:1px solid var(--line); border-radius:6px; background:var(--card); padding:8px; color:var(--ink); font:inherit; }
.admin-shell { max-width:1200px; margin:auto; padding-bottom:48px; }
#admin-status { position:sticky; top:0; z-index:20; max-height:24dvh; overflow:auto; }
.admin-layout { display:grid; gap:24px; align-items:start; }
.admin-items { list-style:none; margin:0; padding:0; display:grid; gap:8px; }
.admin-item { width:100%; text-align:left; }
.admin-situation { display:grid; grid-template-columns:84px minmax(0,1fr) auto; align-items:center; gap:12px; padding:8px 14px; min-height:64px; border:1px solid var(--line); border-radius:var(--radius); background:var(--card); }
.admin-stars { display:flex; }
.admin-star { width:28px; min-height:44px; padding:0; border:0; background:transparent; color:var(--amber-deep); font-size:24px; cursor:pointer; }
.admin-star:hover { background:var(--teal-soft); border-radius:4px; }
.admin-situation-title { min-width:0; padding:8px 0; border:0; background:transparent; text-align:left; font:700 20px/1.4 var(--serif); color:var(--teal); cursor:pointer; overflow-wrap:anywhere; }
.admin-situation-title:hover { text-decoration:underline; }
.admin-situation-labels { display:grid; gap:4px; justify-items:end; }
.admin-layout.admin-situations-layout { grid-template-columns:minmax(0,1fr); }
.admin-situations-layout .admin-list { max-height:none; overflow:visible; position:static; }
@media(max-width:480px) { .admin-situation { gap:8px; padding:6px 8px; } .admin-situation-title { font-size:17px; } .admin-situation-labels .tag { font-size:11px; padding:4px 6px; } }
.admin-form { min-width:0; padding:20px; border:1px solid var(--line); border-radius:var(--radius); background:var(--card); }
.admin-form input:not([type=checkbox]),.admin-form textarea,.admin-list input { width:100%; min-height:44px; font:inherit; padding:10px; border:1px solid var(--line); border-radius:6px; }
.admin-form textarea { min-height:90px; resize:vertical; }
.admin-pair { margin:0; padding:12px; border:1px solid var(--line); display:grid; gap:12px; min-width:0; }
.activity-fields { display:flex; flex-wrap:wrap; gap:10px; border:1px solid var(--line); }
@media(min-width:800px) { .admin-layout { grid-template-columns:280px minmax(0,1fr); } .admin-list { max-height:75dvh; overflow:auto; position:sticky; top:12px; } }
@media (min-width:960px) {
  .module-builder { grid-template-columns:minmax(280px,360px) minmax(0,1fr); }
  .schedule-board { position:sticky; top:12px; max-height:calc(100dvh - 100px); overflow:auto; }
  .module-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
}
@media (max-width:959px) {
  .schedule-board { position:sticky; top:0; z-index:12; max-height:42dvh; overflow:auto; box-shadow:0 4px 12px #173e3720; }
  .schedule-board p,.schedule-board label { font-size:13px; }
}
@media (min-width:720px) {
  .stage-choices { grid-template-columns:repeat(3,minmax(0,1fr)); }
  .stage-card { flex-direction:column; align-items:flex-start; }
  .stage-card strong { font-size:23px; }
  .stage-card > .stack { align-content:start; }
  .journey-steps { max-width:720px; }
  .flow-checklist { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .flow-checklist #task-tdac { grid-column:1/-1; }
}
@media (max-width:420px) {
  .topbar { padding:8px 16px; gap:4px; }
  .brand-text strong { font-size:16px; }
  .header-actions { width:100%; justify-content:flex-end; gap:16px; }
  .header-actions .lang { min-height:44px; }
  .content { padding:20px 16px 28px; gap:20px; }
}
