/* Saudade København Design System — tokens imported from the design project */
@import url('https://fonts.googleapis.com/css2?family=Sora:wght@300;400;500;600;700;800&family=IBM+Plex+Mono:wght@400;500;600&display=swap');

:root {
  /* base palette */
  --navy-900:#00104b; --navy-700:#132766; --navy-500:#3d4a78; --navy-300:#7680a3; --navy-100:#c9cee0;
  --sky-500:#5ea8bc; --sky-300:#8fcbda; --sky-100:#b7e1eb; --sky-050:#e4f4f7;
  --terracotta-500:#c26a4a; --terracotta-300:#dba48f; --terracotta-100:#f2e0d8;
  --paper:#faf7f0; --white:#ffffff;
  --fog-300:#c7cdd8; --fog-200:#dde1e8; --fog-100:#eef0f4;
  --ink:#0b1226; --black:#14161c;
  /* semantic — white ground, cards defined by hairline rules rather than tint */
  --bg-page:var(--white); --bg-surface:var(--white); --bg-surface-sunken:#f5f7f9;
  --bg-inverse:var(--navy-900);
  --text-primary:var(--navy-900); --text-secondary:var(--navy-500); --text-muted:var(--navy-300);
  --text-on-inverse:var(--white); --text-on-accent:var(--white);
  --border-default:var(--fog-300); --border-subtle:#e6eaf1;
  /* layout containers (from the design system) */
  --container:1180px; --container-reading:680px; --container-pad:24px;
  --accent:var(--navy-900); --accent-hover:var(--navy-700);
  --accent-soft:var(--sky-100); --accent-soft-hover:var(--sky-300);
  --focus-ring:var(--sky-500); --data:var(--sky-500);
  --accent-warm:var(--terracotta-500); --accent-warm-hover:#a9583b;
  --accent-warm-soft:var(--terracotta-100);
  --success:#4a7a5e; --warning:#c98a3a; --danger:#a8433a;
  /* darkened text-only variants: the design-system --warning / --terracotta-500
     are tuned for fills and fall below 4.5:1 as small text on light surfaces */
  --warning-text:#9c6b2d; --warm-text:#975239;
  /* type */
  --font-sans:'Sora',-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif;
  --font-mono:'IBM Plex Mono',ui-monospace,SFMono-Regular,Menlo,monospace;
  --text-display-m:clamp(1.75rem,3vw,2.25rem);
  --text-h2:1.375rem; --text-h3:1.125rem;
  --text-body-l:1.0625rem; --text-body:0.9375rem; --text-small:0.8125rem; --text-micro:0.6875rem;
  --tracking-tight:-0.02em; --tracking-wide:0.06em;
  /* effects */
  --radius-s:4px; --radius-m:8px; --radius-l:14px; --radius-pill:999px;
  --shadow-card:0 1px 2px rgba(0,16,75,0.06);
  --shadow-raised:0 6px 20px rgba(0,16,75,0.10);
  --ease-standard:cubic-bezier(.4,0,.2,1);
  --duration-base:200ms;
}

* { box-sizing: border-box; margin: 0; }
body {
  font-family: var(--font-sans); background: var(--bg-page); color: var(--text-primary);
  line-height: 1.5; -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); text-decoration: underline; }

/* header spans the full container on every page, independent of content width */
header.site {
  display: flex; align-items: center; justify-content: space-between;
  gap: 14px 24px; flex-wrap: wrap;
  max-width: var(--container); margin: 0 auto;
  padding: 22px var(--container-pad) 18px;
  border-bottom: 1px solid var(--border-subtle);
}
header.site .brand { display: flex; align-items: center; flex-shrink: 0; }
header.site img.logo { height: clamp(24px, 4vw, 32px); display: block; width: auto; }
header.site .nav {
  display: flex; align-items: center; gap: 4px; flex-wrap: wrap;
}
header.site .nav a {
  font-size: var(--text-small); font-weight: 500; white-space: nowrap;
  color: var(--text-secondary); padding: 7px 10px; border-radius: var(--radius-s);
  transition: background var(--duration-base) var(--ease-standard), color var(--duration-base) var(--ease-standard);
}
header.site .nav a:hover { background: var(--sky-050); color: var(--accent); text-decoration: none; }
header.site .nav a[aria-current="page"] { color: var(--accent); background: var(--sky-050); }
header.site .nav a.nav-cta {
  background: var(--accent); color: var(--text-on-accent); font-weight: 600;
  padding: 8px 14px;
}
header.site .nav a.nav-cta:hover { background: var(--accent-hover); color: #fff; }
header.site .nav a:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 2px; }
@media (max-width: 560px) {
  header.site { gap: 12px; padding-bottom: 14px; }
  header.site .nav { width: 100%; justify-content: space-between; gap: 2px; }
  header.site .nav a { padding: 7px 9px; }
}

/* Two content widths: a reading column for forms and prose, a wide one for feeds. */
main {
  max-width: var(--container-reading); margin: 0 auto; width: 100%;
  padding: 40px var(--container-pad) 88px;
}
main.feed { max-width: var(--container); }
@media (max-width: 640px) { main { padding: 28px 18px 64px; } }

.hero-title {
  font-size: var(--text-display-m); font-weight: 700; letter-spacing: var(--tracking-tight);
  line-height: 1.15; color: var(--text-primary); margin-bottom: 4px;
}
.hero-sub { font-size: var(--text-body); color: var(--text-secondary); margin-bottom: 20px; }

/* full-bleed hero — a sibling of <main>, so it spans the page without 100vw
   (which would overflow by the scrollbar width on desktop) */
.hero { position: relative; width: 100%; overflow: hidden; background: var(--navy-900); }
.hero img {
  width: 100%; height: clamp(300px, 52vh, 560px); object-fit: cover; display: block;
}
.hero-overlay {
  position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: flex-end;
  background: linear-gradient(to top, rgba(0,16,75,.72), rgba(0,16,75,.22) 55%, rgba(0,16,75,.02) 90%);
}
.hero-inner {
  max-width: var(--container); width: 100%; margin: 0 auto;
  padding: 0 var(--container-pad) clamp(28px, 5vw, 60px);
}
.hero-overlay .hero-title {
  color: #fff; margin-bottom: 8px;
  font-size: clamp(2.25rem, 5.5vw, 4rem); line-height: 1.02;
}
.hero-overlay .hero-sub {
  color: rgba(255,255,255,.9); margin-bottom: 0; max-width: 44ch;
  font-size: var(--text-body-l);
}

/* Trips render as full-width rows on desktop — no ragged half-empty grid tracks —
   and collapse to stacked cards on narrow screens. */
.trip-list { display: flex; flex-direction: column; }
.trip-row {
  display: grid; align-items: center; gap: 4px 28px;
  grid-template-columns: 104px minmax(0, 1fr) 200px 24px;
  padding: 24px 8px; border-top: 1px solid var(--border-subtle);
  color: var(--text-primary); text-decoration: none;
  transition: background var(--duration-base) var(--ease-standard);
}
.trip-list .trip-row:last-child { border-bottom: 1px solid var(--border-subtle); }
.trip-row:hover { background: var(--bg-surface-sunken); text-decoration: none; }
.trip-row:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: -2px; }
.tr-date {
  font-family: var(--font-mono); line-height: 1.15;
}
.tr-date .d { display: block; font-size: 1.75rem; font-weight: 500; color: var(--text-primary); }
.tr-date .m {
  display: block; font-size: var(--text-micro); text-transform: uppercase;
  letter-spacing: var(--tracking-wide); color: var(--text-muted); margin-top: 2px;
}
.tr-main { min-width: 0; }
.tr-title {
  font-size: var(--text-h3); font-weight: 600; letter-spacing: var(--tracking-tight);
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
}
.tr-meta {
  font-size: var(--text-small); color: var(--text-secondary); margin-top: 4px;
  display: flex; gap: 6px 14px; flex-wrap: wrap;
}
.tr-meta .mono { color: var(--text-muted); }
.tr-spots { min-width: 0; }
.tr-spots .label {
  font-size: var(--text-small); color: var(--text-muted); margin-bottom: 6px; display: block;
}
.tr-go { color: var(--text-muted); font-size: 20px; justify-self: end; transition: transform var(--duration-base) var(--ease-standard); }
.trip-row:hover .tr-go { transform: translateX(3px); color: var(--accent); }
.trip-row.cancelled { opacity: .55; }
.trip-row.cancelled .tr-title { text-decoration: line-through; }

@media (max-width: 760px) {
  .trip-row {
    grid-template-columns: 64px minmax(0, 1fr); gap: 2px 16px; padding: 18px 4px;
    align-items: start;
  }
  .tr-date .d { font-size: 1.25rem; }
  .tr-spots { grid-column: 2; margin-top: 10px; }
  .tr-go { display: none; }
}

/* grid used by the dashboard for trip cards */
.trip-grid { display: grid; grid-template-columns: 1fr; gap: 16px; }
@media (min-width: 820px) { .trip-grid { grid-template-columns: 1fr 1fr; } }
.trip-grid > .card { margin-bottom: 0; align-self: start; }

/* cancelled states */
.cancel-banner {
  background: #f7ece9; border: 1px solid var(--danger); color: var(--danger);
  border-radius: var(--radius-m); padding: 14px 18px; margin-bottom: 16px;
  font-weight: 500; font-size: var(--text-body);
}

/* outing page: details column + sticky signup rail on desktop.
   On mobile the rail comes first, so "who's coming" stays above the fold. */
.outing-layout { display: grid; gap: 24px; grid-template-columns: 1fr; }
@media (min-width: 900px) {
  .outing-layout { grid-template-columns: minmax(0, 1.55fr) minmax(320px, .95fr); gap: 32px; align-items: start; }
  .outing-rail { position: sticky; top: 24px; }
}
.outing-main, .outing-rail { min-width: 0; display: flex; flex-direction: column; }
/* opt-in: only the outing page lifts its rail above the details on narrow screens,
   so "who's coming" stays the first thing you see */
@media (max-width: 899px) {
  .outing-rail.rail-first { order: -1; }
}
.outing-head { margin-bottom: 24px; }
.outing-head .eyebrow {
  font-size: var(--text-small); font-weight: 500; letter-spacing: var(--tracking-wide);
  text-transform: uppercase; color: var(--text-muted); margin-bottom: 6px;
}
.outing-head h1 {
  font-size: clamp(1.9rem, 3.4vw, 2.75rem); font-weight: 700;
  letter-spacing: var(--tracking-tight); line-height: 1.08; margin: 0;
}
.outing-head .facts {
  display: flex; gap: 8px 26px; flex-wrap: wrap; margin-top: 14px;
  font-size: var(--text-body); color: var(--text-secondary);
}

h2.section {
  font-size: var(--text-small); font-weight: 500; letter-spacing: var(--tracking-wide);
  text-transform: uppercase; color: var(--text-muted); margin: 28px 0 10px;
}

.card {
  background: var(--bg-surface); border: 1px solid var(--border-subtle);
  border-radius: var(--radius-m); box-shadow: var(--shadow-card);
  padding: 20px; margin-bottom: 16px;
}
.card.inverse { background: var(--bg-inverse); color: var(--text-on-inverse); border-color: var(--bg-inverse); }

label {
  display: block; font-size: var(--text-small); font-weight: 500;
  letter-spacing: var(--tracking-wide); text-transform: uppercase;
  color: var(--text-muted); margin: 14px 0 6px;
}
label:first-child { margin-top: 0; }
input, textarea, select {
  width: 100%; font-family: var(--font-sans); font-size: var(--text-body);
  color: var(--text-primary); border: 1px solid var(--border-default);
  border-radius: var(--radius-s); padding: 10px 12px; background: var(--white);
}
select {
  appearance: none; cursor: pointer; padding-right: 38px;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%237680a3' stroke-width='1.8' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 13px center;
}
input:focus, textarea:focus, select:focus { outline: 2px solid var(--focus-ring); outline-offset: 1px; }
textarea { resize: vertical; min-height: 64px; }
.row { display: flex; gap: 12px; flex-wrap: wrap; }
.row > div { flex: 1; min-width: 120px; }

button.btn {
  font-family: var(--font-sans); font-weight: 600; font-size: var(--text-body);
  border-radius: var(--radius-s); padding: 12px 18px; border: none; cursor: pointer;
  transition: background var(--duration-base) var(--ease-standard);
}
.btn-primary { background: var(--accent); color: var(--text-on-accent); }
.btn-primary:hover { background: var(--accent-hover); }
.btn-primary:disabled { background: var(--fog-300); color: var(--text-muted); cursor: not-allowed; }
.btn-ghost, button.btn.btn-ghost { background: transparent; color: var(--accent); border: 1px solid var(--border-default); }
.btn-ghost:hover { background: var(--bg-surface-sunken); }
.btn-quiet {
  background: none; border: none; cursor: pointer; color: var(--text-muted);
  font-family: var(--font-sans); font-size: var(--text-small); padding: 4px 8px;
}
.btn-quiet:hover { color: var(--danger); }
.btn-danger-soft {
  background: none; border: 1px solid var(--border-default); border-radius: var(--radius-s);
  color: var(--danger); font-family: var(--font-sans); font-weight: 500;
  font-size: var(--text-small); padding: 8px 14px; cursor: pointer;
}
.btn-danger-soft:hover { background: #f7ece9; }

.mono { font-family: var(--font-mono); }
.muted { color: var(--text-muted); }
.small { font-size: var(--text-small); }
.err { color: var(--danger); font-size: var(--text-small); margin-top: 10px; }

/* stat blocks (weather) */
.stats { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.stat { display: flex; flex-direction: column; gap: 2px; }
.stat b { font-family: var(--font-mono); font-size: 20px; color: var(--navy-900); font-weight: 500; }
.stat span {
  font-size: var(--text-micro); text-transform: uppercase;
  letter-spacing: var(--tracking-wide); color: var(--text-muted);
}

/* meta line on outing header */
.meta { display: flex; flex-direction: column; gap: 4px; font-size: var(--text-body); color: var(--text-secondary); }

/* spots */
.spots-bar { height: 6px; background: var(--fog-100); border-radius: var(--radius-pill); overflow: hidden; margin: 12px 0 6px; }
.spots-bar > div { height: 100%; background: var(--sky-500); border-radius: var(--radius-pill); transition: width var(--duration-base) var(--ease-standard); }
.spots-bar > div.full { background: var(--accent-warm); }

/* roster */
ul.roster { list-style: none; padding: 0; }
ul.roster li { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--border-subtle); }
ul.roster li:last-child { border-bottom: 0; padding-bottom: 0; }
ul.roster li:first-child { padding-top: 0; }
.avatar {
  width: 34px; height: 34px; border-radius: var(--radius-pill); flex-shrink: 0;
  background: var(--sky-100); color: var(--navy-900); display: flex; align-items: center;
  justify-content: center; font-weight: 600; font-size: var(--text-small);
}
.roster .who { flex: 1; min-width: 0; }
.roster .who .name { font-weight: 500; }
.roster .items { color: var(--text-muted); font-size: var(--text-small); }
.pill {
  display: inline-block; padding: 1px 9px; border-radius: var(--radius-pill);
  font-size: var(--text-micro); font-weight: 600; letter-spacing: var(--tracking-wide);
  text-transform: uppercase; background: var(--sky-050); color: var(--navy-500);
  vertical-align: 2px;
}
.pill.warn { background: var(--accent-warm-soft); color: var(--warm-text); }
.pill.bad { background: #f7ece9; color: var(--danger); }

/* about — boat details */
.spec-grid { display: grid; grid-template-columns: 1fr; gap: 0; }
@media (min-width: 520px) { .spec-grid { grid-template-columns: 1fr 1fr; gap: 0 28px; } }
/* in the narrow sidebar a single column reads better */
.outing-rail .spec-grid { grid-template-columns: 1fr; gap: 0; }
.spec:last-child { border-bottom: 0; }
.spec {
  display: flex; justify-content: space-between; gap: 16px; align-items: baseline;
  padding: 10px 0; border-bottom: 1px solid var(--border-subtle);
}
.spec .k {
  font-size: var(--text-micro); text-transform: uppercase;
  letter-spacing: var(--tracking-wide); color: var(--text-muted); font-weight: 600;
}
.spec .v {
  font-family: var(--font-mono); font-size: var(--text-small);
  color: var(--text-primary); text-align: right;
}
/* line drawings: show whole, never crop, on a white ground */
.drawing { margin: 0; }
.drawing img {
  display: block; width: 100%; max-width: 460px; height: auto; margin: 0 auto;
  background: #fff; border-radius: var(--radius-s);
}
.drawing figcaption {
  margin-top: 12px; text-align: center; font-size: var(--text-small);
  color: var(--text-muted);
}

.prose { font-size: var(--text-body-l); color: var(--text-secondary); line-height: 1.65; }
.prose p { margin: 0 0 14px; max-width: 62ch; }
.prose p:last-child { margin-bottom: 0; }

/* gallery */
.photo-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px;
}
@media (min-width: 700px) {
  .photo-grid { grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 14px; }
}
.photo {
  position: relative; padding: 0; border: 1px solid var(--border-subtle); cursor: pointer;
  border-radius: var(--radius-m); overflow: hidden; background: var(--bg-surface);
  aspect-ratio: 4 / 3; display: block; width: 100%; box-shadow: var(--shadow-card);
}
.photo img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform var(--duration-slow, 320ms) var(--ease-standard); }
.photo:hover img { transform: scale(1.04); }
.photo:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 2px; }
.photo .cap {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 18px 10px 8px;
  font-family: var(--font-sans); font-size: var(--text-small); color: #fff; text-align: left;
  background: linear-gradient(to top, rgba(0,16,75,.72), rgba(0,16,75,0));
}

/* lightbox */
.lightbox {
  position: fixed; inset: 0; z-index: 60; background: rgba(0,16,75,.92);
  display: flex; align-items: center; justify-content: center; padding: 40px 16px;
}
.lightbox[hidden] { display: none; }
.lightbox img { max-width: 100%; max-height: 82vh; border-radius: var(--radius-m); display: block; }
.lb-cap {
  position: absolute; bottom: 20px; left: 0; right: 0; text-align: center;
  color: rgba(255,255,255,.9); font-size: var(--text-small); padding: 0 20px;
}
.lb-close, .lb-nav {
  position: absolute; background: rgba(255,255,255,.12); color: #fff; border: 0;
  cursor: pointer; border-radius: var(--radius-pill); font-family: var(--font-sans);
  display: grid; place-items: center; transition: background var(--duration-base) var(--ease-standard);
}
.lb-close:hover, .lb-nav:hover { background: rgba(255,255,255,.25); }
.lb-close { top: 16px; right: 16px; width: 40px; height: 40px; font-size: 24px; line-height: 1; }
.lb-nav { top: 50%; transform: translateY(-50%); width: 44px; height: 44px; font-size: 28px; line-height: 1; }
.lb-prev { left: 12px; } .lb-next { right: 12px; }
.lb-close:focus-visible, .lb-nav:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }

/* captain photo manager */
.photo-manage { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 10px; margin-top: 14px; }
.pm-item { position: relative; border-radius: var(--radius-s); overflow: hidden; border: 1px solid var(--border-subtle); aspect-ratio: 1; }
.pm-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pm-item button {
  position: absolute; top: 5px; right: 5px; width: 24px; height: 24px; border-radius: var(--radius-pill);
  background: rgba(0,16,75,.78); color: #fff; border: 0; cursor: pointer; font-size: 14px; line-height: 1;
}
.pm-item button:hover { background: var(--danger); }

/* standing note on every sail — sets expectations at the point of signing up */
.notice {
  margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--border-subtle);
}
.notice-title {
  font-size: var(--text-micro); font-weight: 600; text-transform: uppercase;
  letter-spacing: var(--tracking-wide); color: var(--text-muted); margin-bottom: 8px;
}
.notice ul {
  margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 7px;
  font-size: var(--text-small); color: var(--text-secondary); line-height: 1.5;
}
.notice li::marker { color: var(--accent-warm); }
.notice strong { color: var(--text-primary); font-weight: 600; }

/* email consent */
.consent { margin-top: 12px; display: flex; flex-direction: column; gap: 10px; }
.consent .check {
  display: flex; gap: 10px; align-items: flex-start; margin: 0; cursor: pointer;
  font-size: var(--text-small); font-weight: 400; text-transform: none;
  letter-spacing: 0; color: var(--text-secondary); line-height: 1.45;
}
.consent .check input {
  width: 16px; height: 16px; margin: 2px 0 0; flex-shrink: 0;
  accent-color: var(--accent); cursor: pointer;
}
.consent .check b { color: var(--text-primary); font-weight: 600; }
.consent-note {
  margin: 0; font-size: var(--text-micro); color: var(--text-muted); line-height: 1.5;
}

/* weather chart (stacked small multiples) */
.wx-chart-wrap { position: relative; }
.wxc { width: 100%; height: auto; display: block; overflow: visible; }
.wxc-title {
  font-family: var(--font-sans); font-size: 11px; font-weight: 600;
  fill: var(--text-primary); text-transform: uppercase; letter-spacing: 0.06em;
}
.wxc-unit { fill: var(--text-muted); font-weight: 400; letter-spacing: 0; }
.wxc-grid { stroke: var(--border-subtle); stroke-width: 1; }
.wxc-ylab { font-family: var(--font-mono); font-size: 10px; fill: var(--text-muted); text-anchor: end; }
.wxc-xlab { font-family: var(--font-mono); font-size: 10px; fill: var(--text-muted); text-anchor: middle; }
.wxc-leg { font-family: var(--font-sans); font-size: 10px; fill: var(--text-secondary); }
.wxc-gust { fill: var(--sky-100); }
.wxc-wind { fill: none; stroke: var(--navy-900); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.wxc-line { fill: none; stroke: var(--navy-500); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.wxc-area { fill: rgba(61, 74, 120, .14); }
.wxc-bar { fill: var(--navy-500); }
.wxc-arrow { stroke: var(--navy-500); stroke-width: 1.5; fill: none; stroke-linecap: round; }
.wxc-cross { stroke: var(--navy-300); stroke-width: 1; stroke-dasharray: 3 3; pointer-events: none; }
.wxc-dot { fill: var(--navy-900); stroke: #fff; stroke-width: 2; pointer-events: none; }
.wx-tip {
  position: absolute; pointer-events: none; transform: translate(-50%, -100%);
  background: var(--navy-900); color: #fff; padding: 8px 10px;
  border-radius: var(--radius-s); font-size: var(--text-small); line-height: 1.35;
  box-shadow: var(--shadow-raised); white-space: nowrap; opacity: 0;
  transition: opacity .12s var(--ease-standard); z-index: 5;
}
.wx-table-toggle { margin-top: 14px; }
.wx-table-toggle summary {
  cursor: pointer; font-size: var(--text-small); color: var(--text-secondary);
  list-style: none; display: inline-flex; align-items: center; gap: 6px;
}
.wx-table-toggle summary::before { content: '▸'; color: var(--text-muted); }
.wx-table-toggle[open] summary::before { content: '▾'; }
.wx-table-toggle summary::-webkit-details-marker { display: none; }
.wx-table-toggle summary:hover { color: var(--accent); }
.wx-table-toggle .wx-wrap { margin-top: 10px; }

/* nautical chart */
.map { height: 300px; width: 100%; border-radius: var(--radius-m); overflow: hidden; z-index: 0; background: var(--sky-050); }
.leaflet-container { font-family: var(--font-sans); }

/* weather table */
table.wx { width: 100%; border-collapse: collapse; font-size: var(--text-small); }
table.wx th {
  text-align: left; color: var(--text-muted); font-size: var(--text-micro); font-weight: 500;
  text-transform: uppercase; letter-spacing: var(--tracking-wide);
  padding: 6px 8px 6px 0; border-bottom: 1px solid var(--border-subtle);
}
table.wx td { font-family: var(--font-mono); padding: 7px 8px 7px 0; border-bottom: 1px solid var(--border-subtle); color: var(--text-secondary); }
table.wx td:first-child { color: var(--text-primary); }
table.wx tr:last-child td { border-bottom: 0; }
.wx-wrap { overflow-x: auto; }
.sunline {
  font-family: var(--font-mono); font-size: var(--text-small); color: var(--text-secondary);
  margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--border-subtle);
}
.callout { font-size: var(--text-small); color: var(--warning-text); margin: 8px 0 0; }
.callout.ok { color: var(--success); }

/* stepper */
.stepper { display: flex; align-items: center; gap: 14px; }
.stepper button {
  width: 36px; height: 36px; border-radius: var(--radius-pill);
  border: 1px solid var(--border-default); background: var(--white);
  font-size: 18px; cursor: pointer; color: var(--text-primary);
}
.stepper button:hover { background: var(--bg-surface-sunken); }
.stepper .val { font-family: var(--font-mono); min-width: 16px; text-align: center; }

/* share card (host) */
.share-label {
  font-size: var(--text-small); text-transform: uppercase;
  letter-spacing: var(--tracking-wide); color: var(--sky-100); margin-bottom: 10px;
}
.linkbox { display: flex; gap: 8px; }
.linkbox input {
  flex: 1; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.25);
  color: #fff; font-family: var(--font-mono); font-size: var(--text-small);
}
.linkbox .btn-ghost { border-color: rgba(255,255,255,.35); color: #fff; }
.linkbox .btn-ghost:hover { background: rgba(255,255,255,.12); }

/* departure-point search */
.geo-box { position: relative; }
.geo-results {
  position: absolute; top: calc(100% + 4px); left: 0; right: 0; z-index: 20;
  background: var(--white); border: 1px solid var(--border-default);
  border-radius: var(--radius-s); overflow: hidden auto; max-height: 320px;
  box-shadow: var(--shadow-raised);
}
.geo-results[hidden] { display: none; }
.geo-results button {
  display: block; width: 100%; text-align: left; background: var(--white);
  color: var(--text-primary); font-family: var(--font-sans); font-size: var(--text-body);
  border: none; border-bottom: 1px solid var(--border-subtle); padding: 9px 12px; cursor: pointer;
}
.geo-results button:last-child { border-bottom: 0; }
.geo-results button:hover, .geo-results button.active { background: var(--sky-050); }
.geo-results .g-main { display: block; font-weight: 500; }
.geo-results .g-anchor { color: var(--accent-warm); }
.geo-results .g-ctx { display: block; font-size: var(--text-small); color: var(--text-muted); margin-top: 1px; }
.geo-empty { padding: 10px 12px; font-size: var(--text-small); color: var(--text-muted); }


footer { text-align: center; padding: 24px; color: var(--text-muted); font-size: var(--text-micro); text-transform: uppercase; letter-spacing: var(--tracking-wide); }
