/* SurgeCast (surgecast.app), "Modern Oceanographic" (Greg's brief, 2026-10-13).
   Dark by default; light only when the system asks. 8px spacing scale, one
   card radius, Manrope headings and numbers, Inter body. No entrance or scroll
   animation: hover and selection transitions only. */
@font-face { font-family: "Inter"; font-style: normal; font-weight: 400 700; font-display: swap; src: url("/assets/fonts/inter-v20-latin.woff2") format("woff2"); }
@font-face { font-family: "Manrope"; font-style: normal; font-weight: 600 800; font-display: swap; src: url("/assets/fonts/manrope-v20-latin.woff2") format("woff2"); }

:root {
  /* Greg's palette */
  /* SurgeCast palette (Greg 10-14): Deep Navy #0B1E2B, Ocean Blue #0F3B5B, Teal #0EA5A5, Cyan #22D3EE, Seafoam #A7F3D0.
     The button teal stays a step darker than brand Teal so white text keeps AA contrast. */
  --abyss: #0b1e2b; --deep: #0c2738; --card: #103448; --teal: #147d87; --seafoam: #22d3ee; --mist: #a9c7d2;
  --brand-blue: #0f3b5b; --brand-teal: #0ea5a5; --brand-cyan: #22d3ee; --brand-foam: #a7f3d0;
  --bg: var(--abyss); --surface: var(--deep); --panel: var(--card); --panel-2: #0d2d40;
  --ink: #eef7fa; --muted: var(--mist); --line: #1d4a62; --accent: var(--seafoam); --accent-ink: #032628;
  --flag: #d7263d; --danger-bg: #3a0f15; --danger-line: #a3263a; --danger-ink: #ffdfe3;
  /* condition colors: distinct hues, dark text on every chip for contrast */
  --great: #34d399; --good: #a8d36c; --mediocre: #f6c945; --rough: #fb8c3c; --stayhome: #ff5a5f;
  --lv-ink: #071a14; --none: #33536a; --none-ink: #dbe8ee;
  /* text-safe level tints for words (trajectory line), dark theme */
  --tx-great: #4ee0a0; --tx-good: #b9e46a; --tx-mediocre: #f6c945; --tx-rough: #ff9d5c; --tx-stayhome: #ff6b6b;
  --night-band: rgba(0, 0, 0, .32); --night-ink: #c9d6f2;
  --s1: 8px; --s2: 16px; --s3: 24px; --s4: 32px; --s5: 48px;
  --radius: 16px; --shadow: 0 8px 24px rgba(0, 0, 0, .28);
  --font-h: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --font-b: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  color-scheme: dark;
}
@media (prefers-color-scheme: light) {
  :root {
    --bg: #eaf3f6; --surface: #ffffff; --panel: #ffffff; --panel-2: #f1f7f9;
    --ink: #071c2a; --muted: #46616f; --line: #c9dce4; --accent: #0b6f78; --accent-ink: #ffffff;
    --danger-bg: #fff0f1; --danger-line: #e7a1a9; --danger-ink: #6d0a16;
    --great: #1fb57a; --good: #9cc65e; --mediocre: #f0bd2c; --rough: #f47b25; --stayhome: #e5484d;
    --none: #c9d7de; --none-ink: #233a49;
    --tx-great: #0d7f52; --tx-good: #4d7a12; --tx-mediocre: #8a6100; --tx-rough: #b5480a; --tx-stayhome: #c0262f;
    --shadow: 0 4px 16px rgba(6, 21, 34, .08);
    --night-band: rgba(16, 32, 72, .12); --night-ink: #33416b;
    color-scheme: light;
  }
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 17px/1.55 var(--font-b); }
a { color: var(--accent); text-underline-offset: 2px; }
h1, h2, h3, h4 { font-family: var(--font-h); line-height: 1.2; text-wrap: balance; margin: 0; }
h2 { font-size: 1.35rem; font-weight: 800; }
h3 { font-size: 1.1rem; font-weight: 700; }
.wrap { max-width: 1120px; margin: 0 auto; padding-inline: max(16px, env(safe-area-inset-left)) max(16px, env(safe-area-inset-right)); }
.small { font-size: .88rem; }
.muted { color: var(--muted); }
.sub { font: 500 .85rem var(--font-b); color: var(--muted); margin-left: var(--s1); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.ic { width: 1em; height: 1em; flex: none; vertical-align: -0.14em; }
.na { color: var(--muted); }

/* Nav */
.nav { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 10; background: rgba(11, 30, 43, .92); border-bottom: 1px solid var(--line); backdrop-filter: blur(6px); }
.nav-in { display: flex; align-items: center; justify-content: space-between; gap: var(--s2); min-height: var(--nav-h); }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; font: 800 1.05rem var(--font-h); }
.flag { flex: none; border-radius: 2px; }
.nav-links { display: flex; gap: var(--s2); }
.nav-links a { color: var(--mist); text-decoration: none; font-weight: 600; font-size: .92rem; }
.nav-links a:hover { color: #fff; }
@media (max-width: 420px) { .nav-links a:nth-child(3) { display: none; } }
@media (prefers-color-scheme: light) { .nav { background: rgba(11, 30, 43, .96); } }

/* Homepage hero: the kelp photo with a scrim on the text side */
.hero { position: relative; color: #fff; overflow: hidden; background: var(--abyss); border-bottom: 1px solid var(--line); }
.hero-media { position: absolute; inset: 0; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; object-position: 60% 40%; display: block; }
.hero-media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(6, 21, 34, .72) 0%, rgba(6, 21, 34, .86) 70%, rgba(6, 21, 34, .96) 100%); }
@media (min-width: 760px) { .hero-media::after { background: linear-gradient(90deg, rgba(6, 21, 34, .95) 0%, rgba(6, 21, 34, .82) 42%, rgba(6, 21, 34, .25) 75%, rgba(6, 21, 34, .1) 100%); } }
.hero-in { position: relative; z-index: 1; }
.hero-in { padding-block: var(--s4) var(--s4); }
.kicker { margin: 0 0 var(--s1); font: 700 .78rem var(--font-b); letter-spacing: .14em; color: var(--seafoam); }
.hero h1 { font-size: clamp(1.9rem, 6vw, 3rem); font-weight: 800; letter-spacing: -.02em; max-width: 16ch; }
.lede { margin: var(--s1) 0 var(--s2); color: #d6e9ef; max-width: 46ch; font-size: 1.05rem; }
.stats { list-style: none; display: flex; flex-wrap: wrap; gap: var(--s1); padding: 0; margin: 0 0 var(--s2); }
.stats li { background: rgba(16, 52, 72, .85); border: 1px solid var(--line); border-radius: 999px; padding: 6px 14px; font-size: .92rem; color: #d6e9ef; }
.stats b { font: 800 1.1rem var(--font-h); color: #fff; margin-right: 4px; }
.asof, .ages { display: flex; flex-wrap: wrap; gap: 6px var(--s2); align-items: center; margin: 0; font-size: .86rem; color: var(--mist); }
.asof .ic, .ages .ic { margin-right: 6px; }
.is-stale, .age.is-stale { color: #ffcf7a !important; font-weight: 700; }
.age { display: inline-flex; align-items: center; gap: 6px; font-size: .84rem; color: var(--muted); }
.hero .asof { color: #c6dce4; }

main > .wrap { padding-block: var(--s3) var(--s5); }
.sites-section { margin-bottom: var(--s4); }
.band { margin-bottom: var(--s4) !important; }

/* Panels and sections */
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: var(--s3); margin: 0 0 var(--s3); box-shadow: var(--shadow); }
.panel > h2 { display: flex; align-items: center; flex-wrap: wrap; gap: var(--s1); margin-bottom: var(--s2); }
.panel h3 { margin: var(--s3) 0 var(--s1); }
@media (max-width: 520px) { .panel { padding: var(--s2); } }

/* Ratings */
.badge, .chip { display: inline-flex; align-items: center; border-radius: 999px; font-family: var(--font-h); font-weight: 800; white-space: nowrap; color: var(--lv-ink); }
.badge { padding: 4px 12px; font-size: .95rem; }
.badge--lg { padding: 6px 16px; font-size: 1.12rem; }
.badge--xl { padding: 8px 22px; font-size: 1.45rem; }
.chip { padding: 2px 9px; font-size: .74rem; }
.lv-great { background: var(--great); } .lv-good { background: var(--good); } .lv-mediocre { background: var(--mediocre); }
.lv-rough { background: var(--rough); } .lv-stayhome { background: var(--stayhome); }
.lv-none { background: var(--none); color: var(--none-ink); }
.trend { font: 700 .98rem var(--font-h); color: var(--ink); }
.status { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s1) var(--s2); margin: var(--s2) 0 var(--s1); }

/* Confidence, explained on tap */
.conf { display: inline-block; margin: var(--s1) 0; }
.conf summary { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; list-style: none; font-size: .86rem; font-weight: 600; color: var(--muted); border: 1px solid var(--line); border-radius: 999px; padding: 3px 12px; }
.conf summary::-webkit-details-marker { display: none; }
.conf summary::after { content: "?"; font-weight: 800; color: var(--accent); margin-left: 2px; }
.conf[open] summary { border-color: var(--accent); color: var(--ink); }
.conf .pop-body p { margin: 0; }
.conf-mini { display: inline-flex; align-items: center; gap: 6px; font-size: .84rem; color: var(--muted); }

/* Danger: its own dimension, never just a color */
.danger { display: flex; gap: var(--s2); align-items: flex-start; background: var(--danger-bg); border: 1px solid var(--danger-line); border-left: 6px solid var(--flag); color: var(--danger-ink); border-radius: var(--radius); padding: var(--s2); margin: 0 0 var(--s2); }
.danger > .ic { width: 28px; height: 28px; color: #ff6b74; margin-top: 2px; }
.danger strong { font: 800 1.05rem var(--font-h); }
.danger p { margin: 4px 0 0; }
.danger-mini { display: flex; align-items: center; gap: 8px; margin: 0 0 var(--s1); padding: 6px 10px; border-radius: 10px; background: var(--danger-bg); color: var(--danger-ink); border-left: 4px solid var(--flag); font-weight: 700; font-size: .88rem; }
.limited { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: .9rem; font-style: italic; margin: 0 0 var(--s2); }

/* Metrics: big numbers, small units */
.metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s1); margin: var(--s2) 0; }
.metrics--4 { grid-template-columns: repeat(2, 1fr); }
@media (min-width: 560px) { .metrics--4 { grid-template-columns: repeat(4, 1fr); } }
.metrics--grid { grid-template-columns: repeat(2, 1fr); }
@media (min-width: 640px) { .metrics--grid { grid-template-columns: repeat(4, 1fr); } }
.metrics > div { background: var(--panel-2); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; min-width: 0; }
.metrics dt { display: flex; align-items: center; gap: 6px; font-size: .74rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.metrics dt .ic { color: var(--accent); width: 15px; height: 15px; }
.metrics dd { display: flex; align-items: center; gap: 4px; margin: 4px 0 0; font: 800 1.6rem/1.1 var(--font-h); color: var(--ink); }
.metrics .u { font: 600 .8rem var(--font-b); color: var(--muted); margin-left: 2px; }
.metrics .sub { margin-left: 6px; font-size: .78rem; }
.metrics .hint { display: block; font-size: .76rem; color: var(--muted); margin-top: 2px; }
.dir { width: 20px; height: 20px; color: var(--accent); }

/* Regional overview */
.overview .sub { margin-left: 0; display: block; width: 100%; }
.ov-grid { display: grid; gap: var(--s2); grid-template-columns: 1fr; }
@media (min-width: 860px) { .ov-grid { grid-template-columns: 1fr 1fr; } }
.ov { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: var(--s2); }
.ov-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: var(--s1); }
.ov .metrics { margin: var(--s2) 0 var(--s1); }
.ov-sentence { margin: 0; color: var(--ink); }

/* Toolbar */
.sites-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s2); margin: var(--s4) 0 var(--s1); }
.toolbar { display: flex; flex-wrap: wrap; gap: var(--s1); align-items: center; }
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: var(--surface); }
.seg button { display: inline-flex; align-items: center; gap: 6px; border: 0; background: transparent; color: var(--muted); font: 600 .9rem var(--font-b); padding: 8px 12px; cursor: pointer; transition: background .15s, color .15s; }
.seg button[aria-pressed="true"] { background: var(--teal); color: #fff; }
.seg--sm button { padding: 6px 10px; font-size: .84rem; }
.sel { display: inline-flex; align-items: center; gap: 6px; font-size: .86rem; color: var(--muted); }
.sel select { background: var(--surface); color: var(--ink); border: 1px solid var(--line); border-radius: 10px; padding: 7px 10px; font: 600 .9rem var(--font-b); }
.howto { margin: 0 0 var(--s2); }
.empty-filter { color: var(--muted); }

/* Site cards: dive slates, the whole card is the link */
.sites { display: grid; gap: var(--s2); grid-template-columns: 1fr; }
@media (min-width: 760px) { .sites { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1100px) { .sites { grid-template-columns: 1fr 1fr 1fr; } }
.card { position: relative; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: var(--s2) var(--s2) 12px; box-shadow: var(--shadow); transition: border-color .15s; display: flex; flex-direction: column; }
.card:hover { border-color: var(--accent); }
.card-link { position: absolute; inset: 0; z-index: 1; border-radius: var(--radius); }
.card-link:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.card-top { padding-right: 44px; }
.card-top h3 { font-size: 1.28rem; font-weight: 800; }
.area { display: inline-flex; align-items: center; gap: 6px; font-size: .86rem; color: var(--muted); margin-top: 2px; }
.card .status { margin: 12px 0 6px; }
.sentence { margin: 0 0 4px; }
.card .metrics { margin: 12px 0; }
.card .metrics dd { font-size: 1.45rem; }
.card-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 6px var(--s2); margin-top: auto; padding-top: 10px; border-top: 1px solid var(--line); }
.cta { margin-left: auto; display: inline-flex; align-items: center; gap: 2px; font-weight: 700; color: var(--accent); font-size: .92rem; }
.fav { position: absolute; top: 12px; right: 12px; z-index: 2; width: 40px; height: 40px; display: grid; place-items: center; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); color: var(--muted); cursor: pointer; transition: color .15s, border-color .15s; }
.fav .ic { width: 20px; height: 20px; }
.fav:hover { border-color: var(--accent); color: var(--accent); }
.fav.is-on { color: #ffd23f; border-color: #ffd23f; }
.fav.is-on .ic { fill: #ffd23f; }
.fav--lg { position: static; flex: none; }

/* Five-day strip */
.strip { list-style: none; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 2px; padding: 10px 4px; margin: 4px 0 var(--s1); background: var(--panel-2); border-radius: 12px; }
.strip li { display: flex; flex-direction: column; align-items: center; gap: 4px; min-width: 0; }
.strip-day { font-size: .76rem; color: var(--muted); font-weight: 600; }
.strip .chip { max-width: 100%; overflow: hidden; text-overflow: ellipsis; font-size: .66rem; padding: 2px 5px; letter-spacing: -.01em; }

/* List view */
.sites.is-list { grid-template-columns: 1fr; gap: var(--s1); }
.sites.is-list .card { display: grid; grid-template-columns: minmax(0, 1.4fr) auto; grid-template-areas: "top status" "metrics metrics"; align-items: center; gap: 0 var(--s2); padding: 12px 64px 12px var(--s2); }
.sites.is-list .card-top { grid-area: top; padding-right: 0; }
.sites.is-list .status { grid-area: status; margin: 0; justify-self: end; }
.sites.is-list .metrics { grid-area: metrics; margin: 8px 0 0; }
.sites.is-list .metrics dd { font-size: 1.15rem; }
.sites.is-list .sentence, .sites.is-list .strip, .sites.is-list .outlook, .sites.is-list .card-foot, .sites.is-list .danger-mini, .sites.is-list .trend, .sites.is-list .trend-note, .sites.is-list .now-label, .sites.is-list .hazard-line, .sites.is-list .tide-line { display: none; }
@media (min-width: 760px) {
  .sites.is-list .card { grid-template-columns: minmax(0, 1.2fr) minmax(0, 2fr) auto; grid-template-areas: "top metrics status"; }
  .sites.is-list .metrics { margin: 0; }
}

/* Site hero */
.site-hero { background: linear-gradient(180deg, var(--deep) 0%, var(--abyss) 100%); border-bottom: 1px solid var(--line); color: #fff; }
.site-hero-in { padding-block: var(--s3); display: grid; gap: var(--s3); }
@media (min-width: 860px) { .site-hero-in.has-photo { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); align-items: center; } }
.crumbs { display: flex; align-items: center; gap: 4px; margin: 0 0 var(--s1); font-size: .86rem; color: var(--mist); }
.crumbs a { color: var(--seafoam); text-decoration: none; }
.title-row { display: flex; align-items: center; justify-content: space-between; gap: var(--s2); }
.site-hero h1 { font-size: clamp(1.8rem, 6vw, 2.6rem); font-weight: 800; letter-spacing: -.02em; }
.alt { font-weight: 600; font-size: .55em; color: var(--mist); letter-spacing: 0; }
.site-hero .area { color: var(--mist); }
.assess { font-size: 1.1rem; margin: var(--s1) 0; color: #e3f1f5; }
.site-hero .conf summary { color: var(--mist); }
.site-hero .trend { color: #fff; }
.site-photo { margin: 0; }
.site-photo img { display: block; width: 100%; height: auto; aspect-ratio: 8 / 5; object-fit: cover; border-radius: var(--radius); border: 1px solid var(--line); }
.site-photo figcaption { font-size: .76rem; color: var(--mist); margin-top: 6px; }
.rationale { margin: 0 0 var(--s1); }

/* Day selector and panels */
.daytabs { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; margin: 0 0 var(--s2); }
.daytabs button { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 10px 4px; border-radius: 12px; border: 1px solid var(--line); background: var(--panel-2); color: var(--ink); cursor: pointer; font: 700 .86rem var(--font-h); min-width: 0; transition: border-color .15s, background .15s; }
.daytabs button[aria-selected="true"] { border-color: var(--accent); background: var(--panel); box-shadow: inset 0 -3px 0 var(--accent); }
.daytabs .chip { font-size: .62rem; padding: 2px 4px; max-width: 100%; white-space: normal; text-align: center; line-height: 1.15; letter-spacing: -.01em; }
.day { padding: var(--s2) 0; border-top: 1px solid var(--line); }
.js .day { border-top: 0; padding-top: 0; }
.day-head { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s1) var(--s2); margin-bottom: 6px; }
.day-head h3 { margin: 0; font-size: 1.2rem; }
.dp-name { font-size: .76rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.tides { display: flex; flex-wrap: wrap; align-items: center; gap: 4px var(--s2); color: var(--muted); font-size: .88rem; margin: 0; }
.tides .ic { color: var(--accent); }

/* Native charts */
.chart-box { margin-top: var(--s3); padding-top: var(--s2); border-top: 1px solid var(--line); }
.chart-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: var(--s1); margin-bottom: var(--s1); }
.chart-head h3 { margin: 0; }
.chart { margin: 0 0 var(--s2); }
.chart figcaption { font-size: .84rem; color: var(--muted); font-weight: 600; margin-bottom: 4px; }
.js .chart figcaption { display: none; }
.chart-svg { display: block; width: 100%; height: auto; background: var(--panel-2); border: 1px solid var(--line); border-radius: 12px; }
.chart-svg .night { fill: rgba(0, 0, 0, .22); }
.chart-svg .grid { stroke: var(--line); stroke-width: 1; }
.chart-svg .daysep { stroke: var(--line); stroke-dasharray: 3 3; }
.chart-svg .tick { fill: var(--muted); font: 600 13px var(--font-b); }
.chart-svg .line { fill: none; stroke: var(--seafoam); stroke-width: 2.2; stroke-linejoin: round; }
.chart-svg .area { fill: rgba(34, 211, 238, .14); }
.chart-svg .cell.lv-great { fill: var(--great); } .chart-svg .cell.lv-good { fill: var(--good); } .chart-svg .cell.lv-mediocre { fill: var(--mediocre); }
.chart-svg .cell.lv-rough { fill: var(--rough); } .chart-svg .cell.lv-stayhome { fill: var(--stayhome); }
@media (prefers-color-scheme: light) { .chart-svg .night { fill: rgba(6, 21, 34, .06); } .chart-svg .line { stroke: var(--teal); } .chart-svg .area { fill: rgba(20, 125, 135, .12); } }

/* Live cams: equal link cards in an even grid */
.cams { display: grid; gap: 12px; grid-template-columns: 1fr; grid-auto-rows: 1fr; }
@media (min-width: 640px) { .cams { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1000px) { .cams { grid-template-columns: 1fr 1fr 1fr; } }
.cam { display: flex; align-items: center; gap: 12px; padding: 14px; border-radius: var(--radius); background: var(--panel-2); border: 1px solid var(--line); color: inherit; text-decoration: none; transition: border-color .15s; min-height: 76px; }
.cam:hover { border-color: var(--accent); }
.cam > .ic { color: var(--accent); width: 20px; height: 20px; flex: none; }
.cam-text { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0; }
.cam-text span { color: var(--muted); font-size: .86rem; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* Tables */
.table-wrap { overflow-x: auto; }
table { border-collapse: collapse; width: 100%; font-size: .92rem; }
th, td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; }
thead th { font-size: .74rem; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }

/* Site information and advanced tabs */
.info dt { display: flex; align-items: center; gap: 8px; font: 700 .95rem var(--font-h); margin-top: var(--s2); }
.info dt .ic { color: var(--accent); }
.info dd { margin: 4px 0 0; }
.tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: var(--s2); border-bottom: 1px solid var(--line); }
.tabs button { border: 0; background: transparent; color: var(--muted); font: 700 .92rem var(--font-h); padding: 10px 12px; cursor: pointer; border-bottom: 3px solid transparent; transition: color .15s, border-color .15s; }
.tabs button[aria-selected="true"] { color: var(--ink); border-bottom-color: var(--accent); }
.js .tabpanel > h3 { display: none; }
.noaa { margin: var(--s2) 0; padding: 12px; background: var(--panel-2); border: 1px solid var(--line); border-radius: var(--radius); }
.noaa figcaption { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px; margin-bottom: 8px; }
.noaa-img { display: block; border-radius: 10px; background: #fff; overflow: hidden; cursor: zoom-in; } /* whole chart, natural aspect (Greg 10-14: the Hanson plot's Hs and wind panels were cut off) */
.noaa-img img { display: block; width: 100%; height: auto; }
.noaa-fail { display: flex; align-items: center; gap: 8px; color: var(--muted); }
.link-btn { background: none; border: 0; color: var(--accent); font: inherit; font-weight: 700; cursor: pointer; padding: 0; text-decoration: underline; }
.links { margin: 0; padding-left: 20px; }
.links li { margin: 8px 0; }

/* Favorites */
.favs h2 .ic { color: #ffd23f; fill: #ffd23f; }

/* Footer */
.foot { border-top: 1px solid var(--line); padding-block: var(--s3) calc(var(--s4) + env(safe-area-inset-bottom)); font-size: .88rem; color: var(--muted); background: var(--surface); }
.foot-warn { display: flex; align-items: center; gap: 8px; color: var(--ink); }
.foot-warn .ic { color: var(--flag); }
.prose { padding-block: var(--s4); max-width: 760px; }
.prose h2 { margin-top: var(--s3); }
.empty-state { color: var(--muted); }

/* Focus */
button:focus-visible, a:focus-visible, select:focus-visible, summary:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

/* Maps links (Google Maps app on Android) */
.dir-link { position: relative; z-index: 2; display: inline-flex; align-items: center; gap: 6px; font-weight: 700; font-size: .88rem; color: var(--accent); text-decoration: none; }
.maps-row { display: flex; flex-wrap: wrap; gap: var(--s1); margin: var(--s2) 0 0; }
.btn-link { display: inline-flex; align-items: center; gap: 8px; padding: 9px 14px; border-radius: 12px; background: var(--teal); color: #fff; font-weight: 700; font-size: .92rem; text-decoration: none; transition: background .15s; }
.btn-link:hover { background: #18929e; }
.btn-link--ghost { background: transparent; border: 1px solid var(--line); color: var(--seafoam); }
.btn-link--ghost:hover { background: rgba(78, 209, 206, .08); }
.places { margin: 0 0 4px; padding-left: 18px; }
.places li { margin: 4px 0; }

/* Rating ribbon */
.ribbon { background: transparent; border: 0; border-radius: 0; }
.chart-svg .seg { stroke: none; cursor: pointer; }
.chart-svg .seg.lv-great { fill: var(--great); } .chart-svg .seg.lv-good { fill: var(--good); } .chart-svg .seg.lv-mediocre { fill: var(--mediocre); }
.chart-svg .seg.lv-rough { fill: var(--rough); } .chart-svg .seg.lv-stayhome { fill: var(--stayhome); } .chart-svg .seg.lv-none { fill: var(--none); }
.chart-svg .seg:focus { outline: none; stroke: #fff; stroke-width: 2; }
.chart-svg .night-in { fill: rgba(6, 21, 34, .38); pointer-events: none; }
.chart-svg .now { stroke: #fff; stroke-width: 2; }
.chart-svg .now-t { fill: var(--ink); font-weight: 800; }
.chart-info { margin: 6px 0 0; color: var(--muted); min-height: 1.4em; }
@media (prefers-color-scheme: light) { .chart-svg .now { stroke: #071c2a; } .chart-svg .night-in { fill: rgba(6, 21, 34, .18); } }

.chart-svg.cw-900 { display: none; }
@media (min-width: 700px) { .chart-svg.cw-360 { display: none; } .chart-svg.cw-900 { display: block; } }

/* Favorites */
.fav-count { display: inline-grid; place-items: center; min-width: 20px; height: 20px; margin-left: 6px; padding: 0 6px; border-radius: 999px; background: #ffd23f; color: #1a1400; font: 800 .74rem var(--font-h); }
.fav--labeled { width: auto; padding: 0 14px; gap: 8px; display: inline-flex; align-items: center; font: 700 .9rem var(--font-b); }
.your-sites { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 0 0 var(--s2); padding: 10px 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.ys-label { display: inline-flex; align-items: center; gap: 6px; font: 800 .9rem var(--font-h); color: #ffd23f; margin-right: 4px; }
.ys-label .ic { fill: #ffd23f; }
.ys-chip { display: inline-flex; align-items: center; gap: 8px; padding: 6px 10px; border-radius: 12px; border: 1px solid var(--line); background: var(--panel); color: var(--ink); text-decoration: none; font-weight: 700; font-size: .9rem; }
.ys-chip:hover { border-color: var(--accent); }
.ys-all { margin-left: auto; display: inline-flex; align-items: center; gap: 2px; font-weight: 700; font-size: .9rem; color: var(--accent); text-decoration: none; }
.favpage { padding-block: var(--s3) var(--s5); }
.favpage h1 { display: flex; align-items: center; gap: 10px; font-size: 2rem; margin: 0 0 var(--s2); }
.favpage h1 .ic { color: #ffd23f; fill: #ffd23f; }
.fav-head { display: flex; justify-content: space-between; align-items: center; gap: var(--s2); margin-bottom: var(--s1); }
.fav-table th a { display: block; font-weight: 800; }
.fav-table th .small { display: block; font-weight: 400; }
.fav-blocked { display: flex; align-items: center; gap: 8px; color: #ffcf7a; font-weight: 700; }
.picks { list-style: none; padding: 0; margin: var(--s2) 0 0; display: grid; gap: 8px; }
.pick { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px; padding: 10px 12px; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; }
.pick a { color: var(--ink); text-decoration: none; display: flex; flex-direction: column; min-width: 0; }
.pick a:hover strong { color: var(--accent); }
.fav--pick { position: static; width: 48px; height: 48px; }
.fav--pick .ic { width: 24px; height: 24px; }
.toast { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(16px + env(safe-area-inset-bottom, 0px)); z-index: 50; max-width: calc(100% - 32px); background: #e9f7f8; color: #071c2a; border-radius: 12px; padding: 12px 16px; font-weight: 700; box-shadow: 0 8px 24px rgba(0,0,0,.4); }
.toast a { color: #0b6f78; margin-left: 6px; }
@media (max-width: 600px) {
  .fav-table thead { display: none; }
  .fav-table tr { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
  .fav-table th, .fav-table td { border: 0; padding: 0; white-space: normal; }
  .fav-table th { grid-column: 1 / -1; }
  .fav-table td::before { content: attr(data-label); display: block; font-size: .7rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
}

/* Monterey underwater band: a plain grid, no carousel */
.band { margin: 0 0 var(--s3); }
.band-h { font-size: 1.1rem; margin-bottom: var(--s1); }
.band-grid { display: grid; gap: 8px; grid-template-columns: repeat(2, 1fr); }
@media (min-width: 900px) { .band-grid { grid-template-columns: repeat(4, 1fr); } }
.band-grid figure { margin: 0; }
.band-grid img { display: block; width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 12px; border: 1px solid var(--line); }
.band-grid figcaption { font-size: .78rem; color: var(--muted); margin-top: 4px; }

/* Getting in */
.getting-in .maps-row { margin: var(--s1) 0 var(--s2); }
.aerials { display: grid; gap: 12px; grid-template-columns: 1fr; }
@media (min-width: 760px) { .aerials { grid-template-columns: 1fr 1fr; } }
.aerial { margin: 0; }
.aerial img { display: block; width: 100%; height: auto; aspect-ratio: 8 / 5; object-fit: cover; border-radius: 12px; border: 1px solid var(--line); }
.aerial figcaption { font-size: .78rem; color: var(--muted); margin-top: 4px; }
.pin { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 8px; border: 2px solid #fff; vertical-align: 0; }
.pin--entry { background: #ff3b4f; } .pin--parking { background: #ffd23f; }
.getting-in .places { list-style: none; padding-left: 0; }

/* Tides */
.tchips { display: flex; flex-wrap: wrap; gap: 6px; margin: var(--s1) 0; }
.tchip { display: inline-flex; align-items: center; gap: 4px; padding: 3px 9px; border-radius: 999px; font-size: .82rem; border: 1px solid var(--line); background: var(--panel-2); color: var(--ink); white-space: nowrap; }
.tchip .ic { width: 12px; height: 12px; }
.tchip--h .ic { color: var(--seafoam); }
.tchip--l .ic { color: #ffb36b; transform: rotate(180deg); }
.tchip b { font-weight: 700; color: var(--muted); }
.tide-line { display: flex; align-items: flex-start; gap: 6px; margin: -4px 0 8px; font-size: .86rem; color: var(--muted); }
.tide-line .ic { color: var(--accent); }
.tide-hint { display: flex; align-items: flex-start; gap: 8px; margin: var(--s1) 0 0; padding: 8px 12px; border-radius: 12px; background: rgba(34, 211, 238, .1); border: 1px solid var(--line); font-size: .9rem; }
.tide-hint .ic { color: var(--accent); margin-top: 3px; }
.ov-tides { display: flex; flex-direction: column; gap: 4px; margin-top: var(--s2); padding-top: var(--s2); border-top: 1px solid var(--line); }
.ov-tides-h { display: inline-flex; align-items: center; gap: 8px; font: 700 .95rem var(--font-h); }
.ov-tides-h .ic { color: var(--accent); }
.chart-svg .tide-dot { stroke: #061522; stroke-width: 1.5; }
.chart-svg .tide-h { fill: #e9f7f8; } .chart-svg .tide-l { fill: #ffb36b; }
.chart-svg .tide-t { fill: var(--ink); font-size: 11px; }

/* Stale data (QA M5): banner, and the badges go grey. */
.stale-banner { display: flex; gap: 10px; align-items: flex-start; box-sizing: border-box; width: min(1088px, calc(100% - 32px)); margin: 12px auto; padding: 12px 16px; border-radius: 12px; background: #fff4d6; color: #5a3d00; border: 1px solid #f0c75e; font-size: .95rem; }
.stale-banner .ic { flex: none; width: 18px; height: 18px; margin-top: 2px; }
.wrap > .stale-banner { width: 100%; }
body:has(.stale-banner) .badge, body:has(.stale-banner) .chip { filter: grayscale(1); opacity: .75; }

/* A site that shares another site's entry (Bluefish from the Whalers Cove ramp). */
.shared-entry { display: flex; gap: 8px; align-items: flex-start; font-size: .92rem; margin: 6px 0 10px; color: inherit; opacity: .9; }
.shared-entry .ic { flex: none; width: 16px; height: 16px; margin-top: 3px; }

/* "When should I dive?": daypart radio chips + one detail panel. */
.dp-pick { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin: var(--s2) 0 var(--s1); }
.dp-pick button { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 10px 4px; border-radius: 12px; border: 1px solid var(--line); background: var(--panel-2); color: var(--ink); cursor: pointer; font: 700 .86rem var(--font-h); min-width: 0; }
.dp-pick button[aria-checked="true"] { border-color: var(--accent); background: var(--panel); box-shadow: inset 0 -3px 0 var(--accent); }
.dp-pick button:focus-visible, .daytabs button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.dp-pick button[disabled] { cursor: default; opacity: .55; }
.dp-pick .chip { font-size: .66rem; padding: 2px 6px; max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
.dp-passed { font: 600 .72rem var(--font-b); color: var(--muted); }
.dp-detail { padding: var(--s1) 0; }
.dp-detail + .dp-detail { border-top: 1px solid var(--line); }
html.js .dp-detail + .dp-detail { border-top: 0; }
.dp-when { font: 700 .9rem var(--font-h); margin: 0 0 6px; }
.dp-tides { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: .88rem; color: var(--muted); margin: var(--s1) 0; }
.dp-tides .ic { width: 15px; height: 15px; }
.details { font-size: .86rem; color: var(--muted); margin: 0 0 var(--s1); }

/* ===== Homepage round 2 (Greg 10-13): fewer boxes, clear hierarchy ===== */
[id] { scroll-margin-top: calc(var(--nav-h) + 16px); }
.num, .metrics dd, .ov-read dd, .tides-next dd { font-variant-numeric: tabular-nums; }
/* Cards: the badge is the one loud element */
.card-top h3 { font-size: 1.36rem; font-weight: 800; letter-spacing: -.01em; }
.card .area { font-size: .84rem; }
.card .status { margin: 12px 0 8px; gap: 8px 12px; }
.now-label { font-size: .84rem; color: var(--muted); font-weight: 600; }
.trend-note { display: inline-flex; align-items: center; gap: 5px; font-size: .82rem; font-weight: 600; color: var(--muted); }
.trend-note .ic { width: 15px; height: 15px; }
.trend-note.is-better .ic { color: var(--great); }
.trend-note.is-worse .ic { color: var(--rough); }
.warn-badge { display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px 6px 10px; border-radius: 999px; background: var(--stayhome); color: var(--lv-ink); font-family: var(--font-h); }
.warn-badge b { font-size: 1.12rem; font-weight: 800; }
.warn-badge span { font-size: .95rem; font-weight: 600; margin-left: -3px; }
.warn-badge .ic { width: 18px; height: 18px; }
.hazard-line { display: flex; align-items: center; gap: 6px; margin: -2px 0 6px; font-size: .82rem; font-weight: 600; color: var(--stayhome); }
.hazard-line .ic { width: 15px; height: 15px; }
.card .sentence { font-size: .94rem; line-height: 1.5; min-height: 3em; margin: 0; }
.metrics--card { gap: 8px; margin: 14px 0 12px !important; }
.metrics--card > div { border: 0; background: var(--panel-2); padding: 10px 12px; }
.metrics--card dt { font-size: .68rem; letter-spacing: .05em; }
.metrics--card dt .ic { width: 13px; height: 13px; }
.card .metrics--card dd { font-size: 1.85rem; font-weight: 800; }
.metrics--card .u { font-size: .78rem; }
.card-foot { border-top-color: color-mix(in srgb, var(--line) 70%, transparent); }
/* Morning dive outlook */
.outlook { margin: 2px 0 12px; }
.outlook-h { display: flex; justify-content: space-between; align-items: baseline; margin: 0 0 6px; font: 700 .8rem var(--font-h); }
.outlook-h .muted { font: 500 .76rem var(--font-b); }
.ol-bars { list-style: none; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; padding: 0; margin: 0; }
.ol-bars li { min-width: 0; }
.ol-day { position: relative; z-index: 2; width: 100%; display: flex; flex-direction: column; align-items: stretch; gap: 3px; padding: 2px 0; background: none; border: 0; color: inherit; cursor: pointer; font: inherit; text-align: center; border-radius: 6px; }
.ol-day:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.ol-day { -webkit-tap-highlight-color: transparent; }
.ol-name { font-size: .72rem; font-weight: 600; color: var(--muted); }
.ol-bar { display: block; height: 8px; border-radius: 4px; }
.ol-lv { font-size: .64rem; font-weight: 700; color: var(--ink); opacity: .8; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* Solid bars only (Greg 10-13); the level is written under each bar. Stay home
   bars use a deeper red so they never read as Rough's orange, in either theme. */
.ol-bar.lv-stayhome { background: #c4202c; }
.ol-bar.lv-none { background: transparent; border: 1px dashed var(--line); }
.ol-pop { position: absolute; bottom: calc(100% + 6px); left: 50%; transform: translate(-50%, 4px); opacity: 0; visibility: hidden; pointer-events: none; transition: opacity .15s ease-out, transform .15s ease-out, visibility 0s linear .15s; width: 220px; max-width: 72vw; padding: 8px 10px; border-radius: 10px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); font-size: .8rem; line-height: 1.4; text-align: left; color: var(--ink); z-index: 6; }
.ol-pop span { display: block; margin-top: 2px; }
.ol-pop b { font-family: var(--font-h); }
.ol-day.is-first .ol-pop { left: 0; transform: translateY(4px); }
.ol-day.is-last .ol-pop { left: auto; right: 0; transform: translateY(4px); }
.ol-day:hover .ol-pop, .ol-day:focus .ol-pop { opacity: 1; visibility: visible; transform: translate(-50%, 0); transition-delay: 0s; }
.ol-day.is-first:hover .ol-pop, .ol-day.is-first:focus .ol-pop, .ol-day.is-last:hover .ol-pop, .ol-day.is-last:focus .ol-pop { transform: none; }
.dx { overflow: hidden; }
@media (prefers-reduced-motion: reduce) { .ol-pop { transition: none; } }
/* Ocean right now: readings dominate, one surface step, no nested borders */
.overview .ov-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 4px var(--s2); margin-bottom: 4px; }
.overview .ov-head h2 { margin: 0; }
.overview .asof { font-size: .8rem; }
.ov-help { margin: 0 0 var(--s2); font-size: .86rem; color: var(--muted); }
.ov-help summary { cursor: pointer; color: var(--accent); font-weight: 600; width: max-content; max-width: 100%; }
.ov-help p { margin: 6px 0 0; }
.ov { background: var(--panel-2); border: 0; border-radius: 14px; padding: 14px 16px; }
.ov h3 { margin: 0 0 8px !important; font-size: 1rem; }
.ov-read { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin: 0 0 8px; }
.ov-read div { min-width: 0; }
.ov-read dt { font-size: .7rem; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.ov-read dd { margin: 2px 0 0; display: flex; align-items: center; gap: 2px; font: 800 1.75rem/1.1 var(--font-h); }
.ov-read .u { font: 600 .78rem var(--font-b); color: var(--muted); margin-left: 2px; }
.ov-sentence { font-size: .9rem; color: var(--ink); margin: 0 0 4px; }
.ov-meta { margin: 0; font-size: .78rem; color: var(--muted); }
.ov-meta.is-stale { color: var(--mediocre); }
.tides-box { margin-top: var(--s2); background: var(--panel-2); border-radius: 14px; padding: 14px 16px; display: grid; gap: 6px 16px; grid-template-columns: 1fr; }
.tides-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.tides-top h3 { display: inline-flex; align-items: center; gap: 8px; margin: 0 !important; font-size: 1rem; }
.tides-top h3 .ic { color: var(--accent); }
.pill { font-size: .76rem; font-weight: 700; padding: 3px 10px; border-radius: 999px; background: var(--panel); border: 1px solid var(--line); color: var(--ink); }
.tides-next { display: flex; gap: var(--s4); margin: 0; }
.tides-next dt { font-size: .76rem; color: var(--muted); }
.tides-next dd { margin: 2px 0 0; font: 800 1.15rem var(--font-h); }
.tides-all summary { cursor: pointer; color: var(--accent); font-weight: 600; font-size: .88rem; width: max-content; }
.tides-all .tchips { margin-top: 8px; }
.tides-all p { margin: 6px 0 0; }
/* Supporting sections: unboxed, compact */
.quiet { margin: var(--s4) 0; }
.quiet h2 { display: flex; align-items: center; gap: 8px; font-size: 1.1rem; margin-bottom: var(--s1); }
.quiet h2 .ic { color: var(--accent); width: 18px; height: 18px; }
.quiet-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 4px var(--s3); grid-template-columns: 1fr; }
@media (min-width: 760px) { .quiet-list { grid-template-columns: 1fr 1fr; } }
.quiet-list li { padding: 8px 0; border-bottom: 1px solid color-mix(in srgb, var(--line) 60%, transparent); min-width: 0; }
.quiet-list a { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; text-decoration: none; }
.quiet-list a:hover { text-decoration: underline; }
.quiet-list a .ic { width: 14px; height: 14px; opacity: .7; }
.quiet-list span { display: block; font-size: .84rem; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 520px) { .quiet-list span { white-space: normal; } .ov-read { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.band { margin: var(--s4) 0 !important; }
.band-h { font-size: 1.1rem; }

/* Uniform cards: each card's sections share rows with its neighbors (subgrid),
   so short cards have no gap at the bottom and sections line up across a row. */
@supports (grid-template-rows: subgrid) {
  .sites:not(.is-list) .card { display: grid; grid-row: span 5; grid-template-rows: subgrid; row-gap: 0; align-content: start; }
  .sites:not(.is-list) .card > .card-foot { align-self: end; }
  .sites:not(.is-list) .card > .outlook { align-self: end; }
}
.card-slot:empty { margin: 0; }
.card-status .status { margin: 12px 0 8px; }
.overview .asof { color: var(--muted); }

.tide-line .ic { flex: none; margin-top: 3px; }
.ov-help ul { list-style: none; margin: 10px 0; padding: 0; }
/* Two independent columns (Greg 10-14): each item sits right under the one above it, no row gaps */
@media (min-width: 760px) { .ov-help ul { columns: 2; column-gap: 32px; max-width: calc(120ch + 32px); } }
.ov-help li { margin: 0 0 10px; break-inside: avoid; }
.ov-help b { display: block; }
.ov-help p { max-width: none; }
.ov-help b { color: var(--ink); }

/* ===== Motion (Greg 10-13: polished load and scroll motion fits diving).
   Load: CSS only, ends visible, so no JS is needed to see anything.
   Scroll: site.js adds .rv only to elements below the first viewport.
   Reduced motion: none of this runs. ===== */
@keyframes dv-fade-up { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes dv-settle { from { transform: scale(1.03); } to { transform: none; } }
@keyframes dv-fade { from { opacity: 0; } to { opacity: 1; } }
@media (prefers-reduced-motion: no-preference) {
  .hero-in > *, .site-hero-text > * { animation: dv-fade-up .55s cubic-bezier(.2, .7, .2, 1) both; }
  .hero-in > :nth-child(2), .site-hero-text > :nth-child(2) { animation-delay: .07s; }
  .hero-in > :nth-child(3), .site-hero-text > :nth-child(3) { animation-delay: .14s; }
  .hero-in > :nth-child(4), .site-hero-text > :nth-child(4) { animation-delay: .21s; }
  .hero-in > :nth-child(n+5), .site-hero-text > :nth-child(n+5) { animation-delay: .26s; }
  .hero-media img { animation: dv-settle 1.2s cubic-bezier(.2, .7, .2, 1) both; }
  .site-photo { animation: dv-fade .7s ease-out .1s both; }
  .rv { opacity: 0; transform: translateY(12px); }
  .rv.is-in { opacity: 1; transform: none; transition: opacity .4s ease-out, transform .4s cubic-bezier(.2, .7, .2, 1); }
  .hero-media { will-change: transform; }
}

/* "What this can't see": unboxed, subdued */
.cant-see { margin: 0 0 var(--s3); padding: 0 4px; font-size: .86rem; color: var(--muted); max-width: 80ch; }
.cant-see b { color: var(--ink); font-weight: 700; }

/* ===== Site page round 3 (Greg 10-13): a planning tool, not a report ===== */
.site-hero h1 { font-size: clamp(2.1rem, 6.4vw, 3.1rem); letter-spacing: -.025em; }
.site-hero .crumbs { font-size: .82rem; opacity: .8; }
.site-hero .area { font-size: .88rem; }
main [id] { scroll-margin-top: calc(var(--nav-h) + 60px); }
.cur { margin-top: 14px; }
.cur-eyebrow { margin: 0 0 8px; font: 700 .74rem var(--font-h); letter-spacing: .1em; text-transform: uppercase; color: var(--seafoam); }
.cur-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; }
.as-of { color: var(--mist); font-size: .92rem; }
.site-hero .assess { margin: 10px 0 0; }
.cur-ctx { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 14px; padding-top: 12px; border-top: 1px solid rgba(169, 199, 210, .18); }
.ctx-l { display: block; font-size: .78rem; color: var(--mist); margin-bottom: 4px; }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; margin-top: 16px; }
.hero-actions .conf { margin: 0; }
.src-pop { position: relative; font-size: .86rem; color: var(--mist); }
.src-pop summary { cursor: pointer; display: inline-flex; align-items: center; gap: 6px; list-style: none; }
.src-pop summary::-webkit-details-marker { display: none; }
.src-body { position: absolute; z-index: 20; top: calc(100% + 8px); left: 0; width: min(340px, 84vw); padding: 12px 14px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); color: var(--ink); font-size: .86rem; }
.src-body p { margin: 0 0 8px; } .src-body p:last-child { margin: 0; }
.ph { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 12px; margin-bottom: var(--s2); }
.ph h2 { margin: 0; }
.ph > .ic { color: var(--accent); width: 22px; height: 22px; }
.ph-meta { font-size: .84rem; color: var(--muted); }
.tiles4 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin: 0; }
@media (min-width: 900px) { .tiles4 { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.tiles4 > div { background: var(--panel-2); border-radius: 14px; padding: 14px 16px; min-width: 0; }
.tiles4 dt { display: flex; align-items: center; gap: 6px; font-size: .84rem; color: var(--muted); font-weight: 600; }
.tiles4 dt .ic { width: 15px; height: 15px; color: var(--accent); }
.tiles4 dd { margin: 6px 0 2px; font: 800 2rem/1.1 var(--font-h); font-variant-numeric: tabular-nums; }
.tiles4 .u { font: 600 .85rem var(--font-b); color: var(--muted); margin-left: 3px; }
.tiles4 .hint { display: inline-flex; align-items: center; gap: 4px; font-size: .84rem; color: var(--muted); }
.tip { position: relative; display: inline-block; }
.tip summary { list-style: none; cursor: pointer; display: inline-flex; color: var(--accent); }
.tip summary::-webkit-details-marker { display: none; }
.tip summary .ic { width: 15px; height: 15px; }
.tip-body { position: absolute; z-index: 20; bottom: calc(100% + 6px); left: -40px; width: min(260px, 70vw); padding: 10px 12px; border-radius: 10px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); color: var(--ink); font-size: .84rem; line-height: 1.4; }
.sec-row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 22px; margin-top: 14px; font-size: .94rem; }
.sec-row > span { display: inline-flex; align-items: center; gap: 6px; }
.sec-row .ic { width: 16px; height: 16px; color: var(--accent); }
.sec-row details { margin-left: auto; }
.sec-row details[open] { flex-basis: 100%; margin-left: 0; }
.allr summary, .limits summary, .why summary, .hist summary, .adv summary, .noaa-wrap summary { cursor: pointer; color: var(--accent); font-weight: 600; font-size: .92rem; display: inline-flex; align-items: center; gap: 4px; list-style: none; }
.allr summary::-webkit-details-marker, .limits summary::-webkit-details-marker, .why summary::-webkit-details-marker, .hist summary::-webkit-details-marker, .adv summary::-webkit-details-marker, .noaa-wrap summary::-webkit-details-marker { display: none; }
.allr summary .ic, .hist summary .ic { width: 15px; height: 15px; transition: transform .2s ease-out; }
.allr[open] summary .ic, .hist[open] summary .ic { transform: rotate(90deg); }
.allr-list { margin: 8px 0 0; padding-left: 18px; color: var(--muted); font-size: .9rem; }
.limits { margin-top: 14px; padding-top: 12px; border-top: 1px solid color-mix(in srgb, var(--line) 60%, transparent); }
.limits summary .ic { width: 15px; height: 15px; }
.limits p { margin: 8px 0 0; color: var(--muted); font-size: .92rem; max-width: 80ch; }
/* Plan your dive */
.plan { border-color: color-mix(in srgb, var(--accent) 45%, var(--line)); }
.pd-days { grid-template-columns: repeat(7, minmax(0, 1fr)); }
.pd-days button { gap: 6px; padding: 12px 6px; }
.dt-bar { display: block; width: 72%; height: 6px; border-radius: 3px; }
.dt-bar.lv-stayhome { background: #c4202c; }
.dt-lv { font-size: .8rem; font-weight: 700; }
.pd-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 12px; }
.pd-head h3 { margin: 0; font-size: 1.12rem; }
.pd-basis { margin: 8px 0 4px; font-size: .96rem; }
.why { margin: 0 0 10px; }
.why .dx p { margin: 6px 0 0; }
.seg-ctl { display: inline-flex !important; gap: 4px; padding: 4px; margin: 6px 0 12px; border-radius: 999px; background: var(--panel-2); max-width: 100%; }
.seg-ctl button { flex-direction: row !important; gap: 8px !important; padding: 8px 14px !important; border: 0 !important; border-radius: 999px !important; background: transparent !important; box-shadow: none !important; }
.seg-ctl button[aria-checked="true"] { background: var(--panel) !important; box-shadow: 0 0 0 1px var(--accent) inset !important; }
.seg-ctl .dp-name { text-transform: none; letter-spacing: 0; font-size: .9rem; color: var(--ink); }
@media (max-width: 520px) { .seg-ctl { display: grid !important; grid-template-columns: repeat(3, minmax(0, 1fr)); width: 100%; border-radius: 14px; } .seg-ctl button { flex-direction: column !important; gap: 4px !important; padding: 8px 4px !important; border-radius: 10px !important; } }
.dp-detail { background: var(--panel-2); border-radius: 14px; padding: 14px 16px !important; }
.dp-detail .tiles4 > div { background: var(--panel); }
.pd-when { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 12px; margin: 0 0 6px; font: 700 1rem var(--font-h); }
.pd-line { margin: 0 0 12px; }
/* Hourly outlook */
.ho { margin-top: var(--s3); padding-top: var(--s2); border-top: 1px solid color-mix(in srgb, var(--line) 60%, transparent); }
.ho-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.ho-head h3 { margin: 0; }
.tl { position: relative; }
.tl .chart { margin: 0; }
.tl-hit { position: absolute; inset: 0; cursor: crosshair; border-radius: 8px; touch-action: pan-y; }
.tl-hit:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.tl-cur, .tl-sel { position: absolute; top: 14px; bottom: 22px; width: 2px; margin-left: -1px; pointer-events: none; }
.tl-cur { background: color-mix(in srgb, var(--ink) 55%, transparent); }
.tl-sel { background: var(--accent); box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent) 30%, transparent); }
.tl-sel::before { content: ""; position: absolute; top: -5px; left: -4px; width: 10px; height: 10px; border-radius: 50%; background: var(--accent); }
.tl-read { margin: 8px 0 0; min-height: 2.8em; font-size: .9rem; color: var(--muted); }
/* Entry & parking + Live cams & observations */
.pair { display: grid; gap: 0 var(--s3); grid-template-columns: 1fr; align-items: start; }
@media (min-width: 1000px) { .pair { grid-template-columns: 1fr 1fr; } }
.ep { display: grid; gap: var(--s2); grid-template-columns: 1fr; }
@media (min-width: 760px) and (max-width: 999px) { .ep { grid-template-columns: 1fr 1fr; align-items: start; } }
.ep .aerial { margin: 0; }
.ep-line { display: flex; gap: 8px; align-items: flex-start; margin: 0 0 10px; }
.ep-line > .ic { flex: none; width: 17px; height: 17px; margin-top: 4px; color: var(--accent); }
.ep-links { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 4px 0 14px; }
.ep-links a { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; text-decoration: none; }
.ep-links .ic { width: 15px; height: 15px; }
.ep-haz { border-left: 3px solid var(--rough); padding: 2px 0 2px 12px; }
.ep-haz h3 { display: flex; align-items: center; gap: 6px; margin: 0 0 4px !important; font-size: .98rem; }
.ep-haz h3 .ic { width: 16px; height: 16px; color: var(--rough); }
.ep-haz p { margin: 0; font-size: .94rem; }
.aerial--more { margin-top: var(--s2); }
.obs-sum { background: var(--panel-2); border-radius: 14px; padding: 14px 16px; margin-bottom: var(--s2); }
.obs-h { margin: 0 0 10px; font: 700 .95rem var(--font-h); }
.obs-big { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 0; }
.obs-big dt { font-size: .8rem; color: var(--muted); }
.obs-big dd { margin: 2px 0 0; font: 800 1.8rem/1.1 var(--font-h); font-variant-numeric: tabular-nums; }
.obs-big .u { font: 600 .8rem var(--font-b); color: var(--muted); margin-left: 2px; }
.obs-trend { margin-top: 12px; padding-top: 10px; border-top: 1px solid color-mix(in srgb, var(--line) 60%, transparent); }
.spark { display: block; width: 100%; height: 56px; margin-top: 4px; }
.spark-l { fill: none; stroke: var(--accent); stroke-width: 2; }
.spark-a { fill: color-mix(in srgb, var(--accent) 14%, transparent); stroke: none; }
.obs-foot { margin: 10px 0 4px; font-size: .84rem; color: var(--muted); }
.cams-h { margin: var(--s2) 0 var(--s1) !important; font-size: 1rem; }
/* About this dive site */
.about3 { display: grid; gap: var(--s2) var(--s3); grid-template-columns: 1fr; }
@media (min-width: 900px) { .about3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.about3 h3 { margin: 0 0 6px !important; font-size: 1rem; }
.about3 p { margin: 0; }
.advisory { display: flex; gap: 8px; align-items: flex-start; background: var(--panel-2); border-radius: 10px; padding: 10px 12px; font-size: .92rem; }
.advisory .ic { flex: none; width: 16px; height: 16px; margin-top: 3px; color: var(--accent); }
/* Advanced: instrument-style small multiples, always dark */
.adv > .dx { padding-top: 12px; }
.minis { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); margin: 8px 0 16px; }
.mini { margin: 0; padding: 10px 12px 8px; border-radius: 12px; background: #071a26; border: 1px solid rgba(78, 209, 206, .16); }
.mini figcaption { display: flex; justify-content: space-between; gap: 8px; font-size: .8rem; color: #a9c7d2; margin-bottom: 4px; }
.mini figcaption b { color: #e8f6fa; font-weight: 700; }
.mini svg { display: block; width: 100%; height: auto; }
.mini .mg { stroke: rgba(169, 199, 210, .14); stroke-width: 1; }
.mini .mt { fill: #7f9fac; font-size: 9px; font-family: var(--font-b); }
.mini .ml { fill: none; stroke: #22d3ee; stroke-width: 1.6; }
.mini .md { fill: #22d3ee; }
.mini .muted { color: #7f9fac; }
.noaa-wrap { margin: 8px 0 12px; }
.noaa-wrap .noaa { margin-top: 10px; }
/* Sticky section bar */
.subnav { position: fixed; left: 0; right: 0; top: calc(var(--nav-h) + env(safe-area-inset-top, 0px)); z-index: 9; background: rgba(11, 30, 43, .95); border-bottom: 1px solid var(--line); backdrop-filter: blur(6px); color: #fff; }
.subnav-in { display: flex; align-items: center; gap: 8px 10px; min-height: 46px; }
.sn-name { font: 800 1rem var(--font-h); color: #fff; text-decoration: none; white-space: nowrap; }
.sn-cur { font-size: .78rem; color: var(--mist); }
.sn-links { margin-left: auto; display: flex; gap: 16px; overflow-x: auto; scrollbar-width: none; }
.sn-links a { color: var(--mist); font-weight: 600; font-size: .9rem; text-decoration: none; white-space: nowrap; }
.sn-links a:hover { color: #fff; }
@media (max-width: 600px) { .sn-cur { display: none; } .sn-links { gap: 12px; } .sn-name { max-width: 34vw; overflow: hidden; text-overflow: ellipsis; } }
.pair .cams { grid-template-columns: 1fr; grid-auto-rows: auto; }
@media (min-width: 640px) and (max-width: 999px) { .pair .cams { grid-template-columns: 1fr 1fr; } }
.dt-lv { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 520px) { .pd-days { gap: 4px; } .pd-days button { padding: 10px 2px; } .dt-lv { font-size: .66rem; letter-spacing: -.01em; } }

/* Homepage: fixed trend slot */
.trend-slot { min-height: 1.45em; margin: -2px 0 6px; }
.site-hero-in:not(.has-photo) .site-hero-text { max-width: 780px; }
.outlook-link { position: relative; z-index: 2; display: inline-flex; align-items: center; gap: 2px; font: 600 .74rem var(--font-b); color: var(--muted); text-decoration: none; }
.outlook-link:hover { color: var(--accent); }
.outlook-link .ic { width: 12px; height: 12px; }

/* Floating popovers (confidence, Updated, the site-estimate info): anchored, no reflow */
details.pop { position: relative; }
.pop > .pop-body { position: absolute; z-index: 30; top: calc(100% + 8px); left: 0; bottom: auto; width: min(320px, calc(100vw - 32px)); padding: 12px 14px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); color: var(--ink); font-size: .88rem; line-height: 1.45; text-align: left; font-weight: 400; }
.pop.flip-x > .pop-body { left: auto; right: 0; }
.pop.flip-y > .pop-body { top: auto; bottom: calc(100% + 8px); }
.tip.pop > .pop-body { left: -40px; }
.tip.pop.flip-x > .pop-body { left: auto; right: -8px; }
@keyframes dv-pop { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: no-preference) { .pop[open] > .pop-body { animation: dv-pop .15s ease-out; } }
/* Forecast limitations: full width, 2 columns on desktop */
.lim-lead { margin: 8px 0 6px; font-weight: 600; color: var(--ink) !important; }
.lim-grid { list-style: none; margin: 8px 0 0; padding: 0; }
.lim-grid > li { margin: 0 0 8px; break-inside: avoid; }
@media (min-width: 760px) { .lim-grid { columns: 2; column-gap: 32px; } }
.lim-grid li { color: var(--muted); font-size: .92rem; }
.lim-grid b { display: block; color: var(--ink); }
.limits p { max-width: none; }
.why .dx p { max-width: none; }
/* Paired cards are always equal height; extra space sits at the bottom (Greg 10-13) */
.pair { align-items: stretch; gap: var(--s3); margin-bottom: var(--s3); }
.pair > .panel { margin: 0; display: flex; flex-direction: column; }
.pair > #live > p.small:last-child { margin-top: auto; padding-top: var(--s1); }
.ov-grid { align-items: stretch; }
.ov { display: flex; flex-direction: column; }
.ov .ov-meta { margin-top: auto; padding-top: 4px; }

/* Entry card content sits at the top; any extra height is at the bottom */
.pair > .panel { justify-content: flex-start; }
.ep { align-content: start; }
/* View history: a side sheet on desktop, a bottom sheet on phones (Greg 10-13) */
.link-btn.hist-open { display: inline-flex; align-items: center; gap: 4px; padding: 0; border: 0; background: none; color: var(--accent); font: 600 .92rem var(--font-b); cursor: pointer; }
.link-btn.hist-open .ic { width: 15px; height: 15px; }
dialog.sheet { position: fixed; inset: 0 0 0 auto; width: min(560px, 100vw); height: 100%; max-height: 100%; max-width: 100vw; margin: 0; padding: 0; border: 0; border-left: 1px solid rgba(34, 211, 238, .2); background: #071a26; color: #e8f6fa; box-shadow: -12px 0 40px rgba(0, 0, 0, .45); }
dialog.sheet::backdrop { background: rgba(3, 10, 16, .55); }
.sheet-in { display: flex; flex-direction: column; height: 100%; padding: 18px 20px calc(18px + env(safe-area-inset-bottom, 0px)); gap: 12px; }
.sheet-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.sheet-head h2 { margin: 0; font-size: 1.15rem; color: #fff; }
.sheet-sub { display: block; font: 400 .82rem var(--font-b); color: #a9c7d2; margin-top: 2px; }
.sheet-x { flex: none; width: 36px; height: 36px; border-radius: 50%; border: 1px solid rgba(169, 199, 210, .3); background: transparent; color: #e8f6fa; font-size: 1.4rem; line-height: 1; cursor: pointer; }
.sheet-x:hover, .sheet-x:focus-visible { border-color: #22d3ee; outline: none; }
.sheet-charts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.sheet-charts .mini { padding: 8px 10px 6px; }
.sheet-scroll { flex: 1; min-height: 0; overflow: auto; border-radius: 10px; border: 1px solid rgba(34, 211, 238, .14); }
.obs--sheet { width: 100%; border-collapse: collapse; font-size: .9rem; font-variant-numeric: tabular-nums; color: #e8f6fa; }
.obs--sheet th { position: sticky; top: 0; z-index: 1; background: #0b2738; color: #a9c7d2; text-align: left; font-weight: 600; font-size: .78rem; padding: 8px 10px; }
.obs--sheet td { padding: 7px 10px; border-top: 1px solid rgba(169, 199, 210, .1); white-space: nowrap; }
.obs--sheet .muted { color: #7f9fac; font-size: .8rem; }
@media (max-width: 640px) {
  dialog.sheet { inset: auto 0 0 0; width: 100%; height: 86vh; max-height: 86vh; border-left: 0; border-top: 1px solid rgba(34, 211, 238, .2); border-radius: 16px 16px 0 0; }
  .sheet-charts { grid-template-columns: 1fr; }
  .sheet-charts .mini:nth-child(2) { display: none; }
}
@keyframes dv-sheet-r { from { transform: translateX(28px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes dv-sheet-up { from { transform: translateY(32px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes dv-fade-in { from { opacity: 0; } to { opacity: 1; } }
@media (prefers-reduced-motion: no-preference) {
  dialog.sheet[open] { animation: dv-sheet-r .2s ease-out; }
  dialog.sheet[open]::backdrop { animation: dv-fade-in .2s ease-out; }
  dialog.sheet.is-closing { animation: dv-sheet-r .19s ease-in reverse forwards; }
  @media (max-width: 640px) { dialog.sheet[open] { animation-name: dv-sheet-up; } dialog.sheet.is-closing { animation-name: dv-sheet-up; } }
}
/* Hourly outlook: day tiles with daylight hour beads (Greg 10-13, option B) */
.ho-sub { font: 500 .8rem var(--font-b); color: var(--muted); margin-left: 6px; }
.dtiles { display: grid; gap: 10px; grid-template-columns: 1fr; }
@media (min-width: 900px) { .dtiles { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
.dtile { background: var(--panel-2); border-radius: 14px; padding: 12px 12px 10px; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.dtile-h { display: flex; align-items: center; justify-content: space-between; gap: 6px; }
.dtile-name { font: 800 .95rem var(--font-h); }
.beads { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 3px; }
.bead { height: 26px; min-width: 0; padding: 0; border: 0; border-radius: 6px; cursor: pointer; background: var(--none); transition: transform .15s ease-out, box-shadow .15s ease-out, opacity .15s ease-out, background-color .2s ease-out; }
.bead.lv-great { background: var(--great); } .bead.lv-good { background: var(--good); } .bead.lv-mediocre { background: var(--mediocre); } .bead.lv-rough { background: var(--rough); } .bead.lv-stayhome { background: #c4202c; }
.bead.is-past { opacity: .3; cursor: default; }
.bead:disabled { cursor: default; }
.bead.is-now { box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--ink); }
.bead:not(:disabled):hover { transform: translateY(-2px); }
.bead.is-sel { box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--accent); transform: translateY(-2px); }
.bead:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.tl[data-mode="tide"] .beads { display: none; }
.tcurve { display: block; width: 100%; height: 40px; }
.tc-l { fill: none; stroke: var(--accent); stroke-width: 2; }
.tc-a { fill: color-mix(in srgb, var(--accent) 16%, transparent); }
.tcurve-none { margin: 0; font-size: .8rem; color: var(--muted); height: 40px; }
.bead-ticks { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); font-size: .7rem; color: var(--muted); margin-top: -4px; }
.bead-ticks span:nth-child(1) { grid-column: 1 / span 5; }
.bead-ticks span:nth-child(2) { grid-column: 6 / span 4; }
.bead-ticks span:nth-child(3) { grid-column: 10 / span 3; }
.dtile-tides { list-style: none; margin: 2px 0 0; padding: 0; font-size: .78rem; color: var(--muted); line-height: 1.45; font-variant-numeric: tabular-nums; }
.dtile-tides--none { opacity: .7; }
@media (prefers-reduced-motion: reduce) { .bead { transition: none; } .bead:not(:disabled):hover, .bead.is-sel { transform: none; } }
/* history sheet: quieter row lines, compact on phones */
.obs--sheet tr, .obs--sheet td, .obs--sheet th { border-color: rgba(169, 199, 210, .1) !important; border-left: 0; border-right: 0; }
@media (max-width: 640px) { .obs--sheet { font-size: .8rem; } .obs--sheet th, .obs--sheet td { padding: 6px 6px; } .obs--sheet th { font-size: .7rem; } }

.now-badge { margin-left: 8px; vertical-align: middle; }
.now-badge .badge { font-size: .82rem; padding: 3px 10px; }
.ol-pop { width: auto; min-width: 140px; max-width: min(260px, 72vw); white-space: nowrap; }
.ol-pop span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .78rem; color: var(--muted); }

.dp-times { display: block; font: 500 .7rem var(--font-b); color: var(--muted); }
.seg-ctl .dp-name { text-align: left; line-height: 1.15; }
.trend-note.is-steady .ic, .trend-note.is-tomorrow .ic { color: var(--muted); }
.trend-note.is-better { color: color-mix(in srgb, var(--great) 55%, var(--muted)); }
.trend-note.is-worse { color: color-mix(in srgb, var(--rough) 55%, var(--muted)); }
.site-hero .trend-note.is-better { color: #8fe0b8; } .site-hero .trend-note.is-worse { color: #ffb37a; } .site-hero .trend-note.is-steady, .site-hero .trend-note.is-tomorrow { color: var(--mist); }
/* Badge with the site's scale (floating popover) */
.scale-pop { position: relative; z-index: 3; display: inline-block; }
.scale-pop > summary { list-style: none; cursor: pointer; display: inline-flex; border-radius: 999px; }
.scale-pop > summary::-webkit-details-marker { display: none; }
.scale-pop > summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.scale-pop .pop-body { width: min(300px, calc(100vw - 32px)); }
.sc-h { margin: 0 0 6px !important; font-weight: 700; font-size: .84rem; }
.sc-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 3px; font-size: .86rem; font-variant-numeric: tabular-nums; }
.sc-list li { display: flex; align-items: center; gap: 8px; padding: 2px 6px; border-radius: 6px; }
.sc-list li.is-cur { background: var(--panel-2); font-weight: 700; }
.sc-dot { width: 10px; height: 10px; border-radius: 50%; flex: none; }
.sc-dot.lv-stayhome { background: #c4202c; }
/* Card tiles = today's peak */
.peak-l { margin: 12px 0 4px; font-size: .74rem; font-weight: 600; color: var(--muted); letter-spacing: .02em; }
.peak .metrics--card { margin-top: 0 !important; }

/* Trajectory colored by the level it heads to (Greg 10-13); icon matches; steady stays muted */
.trend-note.to-great, .trend-note.to-great .ic { color: var(--tx-great) !important; }
.trend-note.to-good, .trend-note.to-good .ic { color: var(--tx-good) !important; }
.trend-note.to-mediocre, .trend-note.to-mediocre .ic { color: var(--tx-mediocre) !important; }
.trend-note.to-rough, .trend-note.to-rough .ic { color: var(--tx-rough) !important; }
.trend-note.to-stayhome, .trend-note.to-stayhome .ic { color: var(--tx-stayhome) !important; }
/* the site hero is always dark: use the dark-theme tints there */
.site-hero .trend-note.to-great, .site-hero .trend-note.to-great .ic { color: #4ee0a0 !important; }
.site-hero .trend-note.to-good, .site-hero .trend-note.to-good .ic { color: #b9e46a !important; }
.site-hero .trend-note.to-mediocre, .site-hero .trend-note.to-mediocre .ic { color: #f6c945 !important; }
.site-hero .trend-note.to-rough, .site-hero .trend-note.to-rough .ic { color: #ff9d5c !important; }
.site-hero .trend-note.to-stayhome, .site-hero .trend-note.to-stayhome .ic { color: #ff6b6b !important; }

/* Card: "Why this rating?" beside the badge; confidence only when not High */
.why-pop { position: relative; z-index: 3; }
.why-pop > summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 4px; font-size: .8rem; font-weight: 600; color: var(--muted); padding: 4px 6px; border-radius: 8px; }
.why-pop > summary::-webkit-details-marker { display: none; }
.why-pop > summary .ic { width: 15px; height: 15px; color: var(--accent); }
.why-pop > summary:hover, .why-pop[open] > summary { color: var(--ink); }
.why-pop > summary:focus-visible { outline: 2px solid var(--accent); }
.why-s { margin: 0 0 10px !important; font-size: .9rem; color: var(--ink); }
@media (max-width: 420px) { .why-l { display: none; } }
.conf-note { position: relative; z-index: 3; }
.conf-note > summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; font-size: .82rem; color: var(--muted); }
.conf-note > summary::-webkit-details-marker { display: none; }
.conf-note > .pop-body { top: auto; bottom: calc(100% + 8px); }
.card .card-status { padding-bottom: 2px; }
.card .peak .metrics--card { margin-top: 6px !important; }
/* the card's Why popover anchors to the badge row and spans the card width (never off screen) */
.card .card-status { position: relative; z-index: 4; }
.card .why-pop { position: static; }
.card .why-pop > .pop-body, .card .why-pop.flip-x > .pop-body, .card .why-pop.flip-y > .pop-body { left: 0; right: 0; width: auto; top: calc(100% + 4px); bottom: auto; z-index: 30; }
.card .status { position: static; }
.card:has(details.pop[open]) { z-index: 6; }

/* Card footer: "Why this rating?" (and Medium/Low confidence) left, View forecast right; popovers open upward across the card */
.card .card-foot { position: relative; z-index: 4; flex-wrap: nowrap; }
.foot-l { display: inline-flex; align-items: center; gap: 4px; min-width: 0; flex-wrap: wrap; }
.foot-sep { color: var(--muted); }
.card .card-foot .why-pop, .card .card-foot .conf-note { position: static; }
.card .card-foot .why-pop > .pop-body, .card .card-foot .why-pop.flip-x > .pop-body, .card .card-foot .why-pop.flip-y > .pop-body,
.card .card-foot .conf-note > .pop-body, .card .card-foot .conf-note.flip-x > .pop-body { left: 0; right: 0; width: auto; top: auto; bottom: calc(100% + 6px); z-index: 30; }
.card .card-foot .why-pop > summary { padding: 0; }
.card .card-status { z-index: auto; }
@media (max-width: 420px) { .why-l { display: inline; } }
.card .card-foot .cta { white-space: nowrap; flex: none; }
.foot-l { flex: 1; flex-direction: column; align-items: flex-start; gap: 2px; }
.foot-sep { display: none; }

/* Vis likely poor: quiet, one-way */
.vis-pop > summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; font-size: .84rem; color: var(--muted); }
.vis-pop > summary::-webkit-details-marker { display: none; }
.vis-pop > summary .ic { width: 15px; height: 15px; }
.vis-why { margin: 6px 0; padding-left: 18px; font-size: .86rem; }
.card .card-foot .vis-pop { position: static; }
.card .card-foot .vis-pop > .pop-body, .card .card-foot .vis-pop.flip-x > .pop-body { left: 0; right: 0; width: auto; top: auto; bottom: calc(100% + 6px); z-index: 30; }
.card .card-foot .vis-pop > summary { font-size: .78rem; }

/* View forecast is a real link above the footer layer (Greg 10-13 bug) */
.card .card-foot a.cta { position: relative; z-index: 5; cursor: pointer; text-decoration: none; }
.card .card-foot a.cta:hover { text-decoration: underline; }
.card .card-foot a.cta:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }

/* Waves / Wind tabs: beads become a mini bar chart on one shared scale (Greg 10-13) */
.dtile-peak { display: none; font-size: .78rem; font-weight: 700; color: var(--accent); font-variant-numeric: tabular-nums; }
.tl[data-mode="waves"] .dtile-h .chip, .tl[data-mode="wind"] .dtile-h .chip { display: none; }
.tl[data-mode="waves"] .pk-waves, .tl[data-mode="wind"] .pk-wind { display: inline; }
.tl[data-mode="waves"] .bead, .tl[data-mode="wind"] .bead { background: var(--none); height: 4px; border-radius: 3px 3px 1px 1px; box-shadow: none; transform: none; }
.tl[data-mode="waves"] .bead[data-wv] { background: var(--accent); height: max(4px, calc(var(--wv, 0) * 34px)); }
.tl[data-mode="wind"] .bead[data-kv] { background: var(--accent); height: max(4px, calc(var(--kv, 0) * 34px)); }
.tl[data-mode="waves"] .bead.is-past, .tl[data-mode="wind"] .bead.is-past { opacity: .45; }
.tl[data-mode="waves"] .bead.is-sel, .tl[data-mode="wind"] .bead.is-sel { box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--accent); }
.tl[data-mode="waves"] .bead.is-now, .tl[data-mode="wind"] .bead.is-now { box-shadow: 0 0 0 2px var(--surface), 0 0 0 3px var(--muted); }

/* Today's tide chart (homepage), same look as the site's line charts */
.tide-day { display: block; width: 100%; height: auto; margin: 8px 0 4px; overflow: visible; }
.tide-day.cw-900 { display: none; }
@media (min-width: 700px) { .tide-day.cw-360 { display: none; } .tide-day.cw-900 { display: block; } }
.tide-day .tn { fill: rgba(6, 21, 34, .08); }
.tide-day .tg { stroke: color-mix(in srgb, var(--line) 70%, transparent); stroke-width: 1; }
.tide-day .tg0 { stroke: var(--muted); stroke-width: 1; stroke-dasharray: 3 3; }
.tide-day .tt { fill: var(--muted); font: 500 10px var(--font-b); }
.tide-day .ta { fill: color-mix(in srgb, var(--seafoam) 22%, transparent); }
.tide-day .tl2 { fill: none; stroke: var(--teal); stroke-width: 2; }
.tide-day .td { stroke: var(--surface); stroke-width: 2; }
.tide-day .td-h { fill: var(--teal); } .tide-day .td-l { fill: var(--rough); }
.tide-day .tl3 { fill: var(--ink); font: 600 11px var(--font-b); }
.tide-day .tnow { stroke: var(--ink); stroke-width: 1.5; stroke-dasharray: 2 3; }
.tide-day .tnd { fill: var(--ink); stroke: var(--surface); stroke-width: 2; }
.tide-day .tnt { font-weight: 700; }
@media not all and (prefers-color-scheme: light) { .tide-day .tn { fill: rgba(0, 0, 0, .22); } .tide-day .tl2 { stroke: var(--seafoam); } .tide-day .td-h { fill: var(--seafoam); } }

.card .area { display: flex; max-width: 100%; min-width: 0; white-space: nowrap; overflow: hidden; }
.card .area > .ic { flex: none; }
.card .area { text-overflow: ellipsis; }

/* Card photo header that fades into the card (Greg 10-13, option B) */
.card--photo { overflow: hidden; --card-rgb: 16, 52, 72; }
@media (prefers-color-scheme: light) { .card--photo { --card-rgb: 255, 255, 255; } }
.card-photo { position: absolute; left: 0; right: 0; top: 0; height: 200px; z-index: 0; pointer-events: none; border-radius: var(--radius) var(--radius) 0 0; overflow: hidden; }
.card-photo img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 45%; }
.card-photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(var(--card-rgb), .15) 0%, rgba(var(--card-rgb), .55) 60%, rgb(var(--card-rgb)) 100%); }
@media (prefers-color-scheme: light) {
  /* light theme: a soft dark veil behind the name, then the fade to the white card */
  .card-photo::after { background: linear-gradient(180deg, rgba(6, 21, 34, .42) 0%, rgba(6, 21, 34, .16) 38%, rgba(255, 255, 255, .55) 66%, #fff 100%); }
}
.card--photo > *:not(.card-photo):not(.card-link):not(.fav) { position: relative; z-index: 1; }
.card--photo .card-link { z-index: 1; }
.card--photo > .card-status, .card--photo > .card-foot { z-index: 4; }
.card--photo > .fav { z-index: 3; }
.card--photo .card-top h3 { color: #fff; text-shadow: 0 1px 2px rgba(0, 0, 0, .65), 0 0 12px rgba(0, 0, 0, .45); }
.card--photo .card-top .area { color: #f1f7f9; text-shadow: 0 1px 2px rgba(0, 0, 0, .7); }
.card--photo .card-top .area .ic { color: #f1f7f9; }
.card--photo .now-label { text-shadow: 0 0 6px rgb(var(--card-rgb)); }
.card--photo .metrics--card > div { background: color-mix(in srgb, var(--panel-2) 85%, transparent); }
.sites.is-list .card-photo { display: none; }
.sites.is-list .card--photo .card-top h3, .sites.is-list .card--photo .card-top .area { color: inherit; text-shadow: none; }
.card--photo .now-label { color: #fff; font-weight: 700; text-shadow: 0 1px 3px rgba(0, 0, 0, .7); }
@media (prefers-color-scheme: light) { .card--photo .now-label { color: var(--ink); text-shadow: 0 0 4px #fff, 0 0 10px #fff; } }

/* footer: at most two lines; the vis and confidence notes share the second */
.foot-notes { display: flex; align-items: center; gap: 4px; flex-wrap: nowrap; min-width: 0; }
.foot-notes .foot-sep { display: inline; color: var(--muted); }
.foot-notes:empty { display: none; }
.card .card-foot .vis-pop > summary span { white-space: nowrap; }
.sites > .card { min-width: 0; }
.card .card-foot .foot-l, .card .foot-notes { min-width: 0; }
.card .foot-notes { overflow: hidden; }
.card .foot-notes > details { min-width: 0; }
.card .foot-notes summary { white-space: nowrap; }
/* footer grid: Why + View forecast on line 1, the notes span line 2; cards never widen their column */
.sites { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 760px) { .sites { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .sites { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.sites.is-list { grid-template-columns: minmax(0, 1fr); }
.sites:not(.is-list) .card { grid-template-columns: minmax(0, 1fr); }
.card .card-foot { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; column-gap: 8px; row-gap: 2px; }
.card .foot-l { display: contents; }
.card .card-foot .why-pop { grid-column: 1; grid-row: 1; }
.card .card-foot a.cta { grid-column: 2; grid-row: 1; }
.card .foot-notes { grid-column: 1 / -1; grid-row: 2; }
/* Hourly outlook tabs (Greg 10-13, after night dives): every tab uses one
   40 px plot band per row, so switching tabs never moves the page. Rating =
   28 px beads centered in it; Waves / Wind = bars scaled to the band; Tide =
   the curve in the band, with turn labels kept inside it (they never touch the
   hour ticks). Tide-turn lines are not listed under the rows (only the Tide tab
   shows turns; the list stays for screen readers). */
.bd-day { height: 40px; align-items: center; }
.bd-night { height: 46px; align-items: center; }
.tl[data-mode="waves"] .bd-day, .tl[data-mode="wind"] .bd-day, .tl[data-mode="waves"] .bd-night, .tl[data-mode="wind"] .bd-night { align-items: end; background-image: linear-gradient(to top, transparent calc(50% - .5px), color-mix(in srgb, var(--line) 80%, transparent) calc(50% - .5px), color-mix(in srgb, var(--line) 80%, transparent) calc(50% + .5px), transparent calc(50% + .5px)); }
.tl[data-mode="waves"] .bead, .tl[data-mode="wind"] .bead { height: 4px; }
.tl[data-mode="waves"] .bead[data-wv] { height: max(4px, calc(var(--wv, 0) * 40px)); }
.tl[data-mode="wind"] .bead[data-kv] { height: max(4px, calc(var(--kv, 0) * 40px)); }
.tcurve-box { position: relative; height: 40px; }
.tl[data-mode="tide"] .tcurve, .tl[data-mode="tide"] .tcurve-none { height: 100%; }
.tc-mark { position: absolute; transform: translate(-50%, -50%); width: 8px; height: 8px; border-radius: 50%; border: 2px solid var(--panel-2); z-index: 1; }
.tc-mark.h { background: var(--accent); } .tc-mark.l { background: var(--rough); }
.tc-lab { position: absolute; transform: translateX(-50%); font-size: .68rem; font-weight: 600; color: var(--ink); white-space: nowrap; font-variant-numeric: tabular-nums; line-height: 1.2; padding: 0 3px; border-radius: 4px; background: color-mix(in srgb, var(--panel-2) 80%, transparent); z-index: 2; }
.tc-lab.h { margin-top: 5px; } .tc-lab.l { margin-top: calc(-1.2em - 6px); }
.tc-lab.edge-l { transform: none; } .tc-lab.edge-r { transform: translateX(-100%); }
.tc-now { position: absolute; top: 0 !important; bottom: 0; width: 0; border-left: 2px solid var(--ink); opacity: .75; z-index: 1; }
.tc-now-dot { position: absolute; transform: translate(-50%, -50%); width: 9px; height: 9px; border-radius: 50%; background: var(--ink); border: 2px solid var(--panel-2); z-index: 2; }
.tc-past { position: absolute; top: 0; bottom: 0; left: 0; background: color-mix(in srgb, var(--panel-2) 55%, transparent); z-index: 1; pointer-events: none; }
.dtile-tides { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.bead { position: relative; }
.bead.is-past { opacity: .45; cursor: pointer; }
.bead.is-now::after { content: "Now"; position: absolute; left: 50%; bottom: calc(100% + 3px); transform: translateX(-50%); font: 700 .62rem var(--font-b); color: var(--ink); white-space: nowrap; pointer-events: none; }
.tl[data-mode="waves"] .bead.is-now::after, .tl[data-mode="wind"] .bead.is-now::after { bottom: auto; top: -15px; }
@media (max-width: 600px) {
  .tl[data-mode="tide"] .tcurve-box { height: 96px; }
  .tc-lab .tc-ft { display: none; }
}
.dtile-h { min-height: 1.4rem; } .dtile-tides { margin-top: 0; }
/* Plan your dive: the Morning / Afternoon / Evening control is centered, with three equal segments,
   each stacking word, time and level badge on its center line (Greg 10-13). */
.seg-ctl { display: grid !important; grid-template-columns: repeat(3, minmax(0, 1fr)); width: min(100%, 540px); margin: 6px auto 12px !important; border-radius: 16px; }
.seg-ctl button { flex-direction: column !important; align-items: center; justify-content: center; gap: 5px !important; padding: 8px 6px !important; border-radius: 12px !important; text-align: center; }
.seg-ctl .dp-name { text-align: center; }

/* ---------- Night dives (Greg 10-13): Evening 4-8 PM, Night 8 PM-midnight ---------- */
/* Daily outlook: day bar plus a narrower night segment, level words under both */
.outlook-h .ol-key { display: inline-flex; align-items: center; gap: 4px; font: 500 .7rem var(--font-b); color: var(--muted); }
.ol-key i { display: inline-block; width: 14px; height: 6px; border-radius: 3px; background: var(--muted); opacity: .7; }
.ol-key i.k-night { width: 6px; margin-left: 6px; background: var(--night-ink); box-shadow: 0 0 0 1.5px var(--night-band); }
.ol-split { display: flex; gap: 2px; }
.ol-split .ol-bar { flex: 13 1 0; min-width: 0; }
.ol-split .ol-bar--night { flex: 4 1 0; box-shadow: 0 0 0 1.5px var(--night-band); }
.ol-bar.lv-passed, .dt-bar.lv-passed { background: repeating-linear-gradient(135deg, var(--none) 0 3px, transparent 3px 6px); }
.ol-lvn { display: inline-flex; align-items: center; justify-content: center; gap: 2px; font-size: .62rem; font-weight: 700; color: var(--night-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.ol-lvn .ic { width: 9px; height: 9px; flex: none; }
.ol-pop .ol-note { margin-top: 4px; }
/* List view: tonight's chip beside the badge */
.list-night { display: none; align-items: center; gap: 6px; margin: 0; font-size: .8rem; font-weight: 600; color: var(--night-ink); }
.list-night .ic { width: 14px; height: 14px; }
.sites.is-list .list-night { display: inline-flex; grid-area: night; justify-self: end; }
.sites.is-list .card { grid-template-areas: "top status" "metrics metrics" "night night"; }
@media (max-width: 759px) { .sites.is-list .list-night { justify-self: start; margin-top: 8px; } }
@media (min-width: 760px) {
  .sites.is-list .card { grid-template-columns: minmax(0, 1.2fr) minmax(0, 2fr) auto auto; grid-template-areas: "top metrics night status"; }
}
.now-label small { display: block; font-size: .74rem; font-weight: 600; color: var(--muted); }
.peak-at { margin: -6px 0 8px; font-size: .74rem; color: var(--muted); }
.sites.is-list .peak-at { display: none; }
.why-when { margin: 0 0 4px !important; font-size: .76rem; font-weight: 700; color: var(--muted); }
/* Plan your dive: day and night chips, four windows */
.pd-chips { display: inline-flex; flex-wrap: wrap; gap: 6px; }
.chip--night { gap: 4px; box-shadow: 0 0 0 2px var(--night-band); }
.chip--night .ic { width: 12px; height: 12px; }
.dp-name .ic { width: 14px; height: 14px; vertical-align: -2px; margin-right: 4px; color: var(--night-ink); }
.seg-ctl button.dp-night:not([aria-checked="true"]) { background: var(--night-band) !important; }
.seg-ctl { grid-template-columns: repeat(4, minmax(0, 1fr)); width: min(100%, 720px); }
@media (max-width: 600px) { .seg-ctl { grid-template-columns: repeat(2, minmax(0, 1fr)); width: 100%; } }
.dp-detail--night { background: linear-gradient(var(--night-band), var(--night-band)), var(--panel-2); }
.night-note { display: flex; gap: 8px; align-items: flex-start; margin: 12px 0 0; font-size: .88rem; color: var(--muted); }
.night-note .ic { width: 16px; height: 16px; flex: none; margin-top: 2px; color: var(--night-ink); }
.sky { display: flex; flex-wrap: wrap; gap: 4px 16px; margin: 10px 0 0; font-size: .86rem; font-variant-numeric: tabular-nums; }
.sky span { display: inline-flex; align-items: center; gap: 6px; }
.sky .ic { width: 15px; height: 15px; color: var(--night-ink); }
/* Day tabs: day bar plus night segment */
.dt-split { display: flex; gap: 2px; width: 72%; }
.dt-split .dt-bar { width: auto; flex: 13 1 0; }
.dt-split .dt-bar--night { flex: 4 1 0; box-shadow: 0 0 0 1.5px var(--night-band); }
/* Hourly outlook: one full-width row per day, 7 AM to midnight; beads never shrink */
.dtiles { grid-template-columns: 1fr !important; gap: 8px; }
.dtile { padding: 10px 12px; }
.dtile-h { flex-wrap: wrap; justify-content: flex-start; gap: 6px 8px; }
.dtile-name { min-width: 4.2em; }
.dtile-chips { display: inline-flex; gap: 6px; flex-wrap: wrap; }
.dtile-h .dtile-peak { margin-left: auto; }
.beads { display: grid; grid-template-columns: 13fr 4fr; gap: 6px; align-items: stretch; }
.bd-day, .bd-night { display: grid; gap: 3px; min-width: 0; }
.bd-day { grid-template-columns: repeat(13, minmax(0, 1fr)); }
.bd-night { grid-template-columns: repeat(4, minmax(0, 1fr)); padding: 3px; margin: -3px; border-radius: 9px; background: var(--night-band); }
.bead { height: 28px; }
.bd-night-lab { display: none; }
.bead-ticks { display: grid; grid-template-columns: 13fr 4fr; gap: 6px; margin-top: 2px; }
.bead-ticks span:nth-child(1), .bead-ticks span:nth-child(2), .bead-ticks span:nth-child(3) { grid-column: 1; grid-row: 1; }
.bead-ticks span:nth-child(2) { margin-left: calc(5 / 13 * 100%); }
.bead-ticks span:nth-child(3) { margin-left: calc(9 / 13 * 100%); }
.bead-ticks .tk-night { grid-column: 2 !important; display: inline-flex; align-items: center; gap: 3px; color: var(--night-ink); }
.bead-ticks .tk-night .ic { width: 11px; height: 11px; }
.tc-night { position: absolute; bottom: 0; right: 0; background: var(--night-band); border-radius: 6px; pointer-events: none; }
.tl[data-mode="tide"] .tcurve-box .tc-night { top: 0; }
@media (min-width: 900px) {
  .dtile { display: grid; grid-template-columns: 190px minmax(0, 1fr); gap: 4px 16px; align-items: start; }
  .dtile-h { flex-direction: column; align-items: flex-start; }
  .dtile-h .dtile-peak { margin-left: 0; }
}
/* Phones: night beads on their own line at the same size as the day beads,
   under the day row's time ticks */
.bd-nightrow { min-width: 0; display: grid; }
.dt-lv .ic { width: 11px; height: 11px; vertical-align: -1px; margin-right: 2px; }
@media (max-width: 600px) {
  .dtile-b { display: flex; flex-direction: column; gap: 6px; }
  .beads { display: contents; }
  .bd-day { order: 1; }
  .tcurve-box { order: 1; }
  .bead-ticks { order: 2; grid-template-columns: 1fr; margin-top: -2px; }
  .bead-ticks .tk-night { display: none; }
  .bd-nightrow { order: 3; display: flex; align-items: center; gap: 10px; margin-top: 4px; }
  .bd-night { width: calc((100% + 3px) * 4 / 13 + 3px); margin: 0; flex: none; }
  .bd-night-lab { display: inline-flex; align-items: center; gap: 4px; font-size: .72rem; font-weight: 600; color: var(--night-ink); }
  .bd-night-lab .ic { width: 12px; height: 12px; }
  .dtile-tides { order: 4; }
}
.tl[data-mode="waves"] .bd-day, .tl[data-mode="wind"] .bd-day, .tl[data-mode="waves"] .bd-night, .tl[data-mode="wind"] .bd-night { align-items: end; }
.tl[data-mode="waves"] .dtile-h .chip, .tl[data-mode="wind"] .dtile-h .chip { display: none; }
.sites.is-list .peak { grid-area: metrics; min-width: 0; }
/* Phones, Tide tab: the curve spans 7 AM to midnight, so the ticks use the same 13 + 4 split */
@media (max-width: 600px) {
  .tl[data-mode="tide"] .bead-ticks { grid-template-columns: 13fr 4fr; gap: 6px; }
  .tl[data-mode="tide"] .bead-ticks .tk-night { display: inline-flex; }
}
/* ---------- New sites (10-13): card groups, card notes, site rules and checks ---------- */
.site-group + .site-group { margin-top: var(--s3); }
.sg-h { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; margin: 0 0 12px; font-size: 1.15rem; font-weight: 800; }
.sg-sub { font: 500 .84rem var(--font-b); color: var(--muted); }
.card-note { display: flex; align-items: center; gap: 6px; margin-top: 4px; font-size: .78rem; font-weight: 600; color: var(--muted); }
.card-note .ic { width: 13px; height: 13px; flex: none; }
.card-note--closed { color: var(--tx-stayhome); }
.sites.is-list .card-note { display: none; }
.ep-box { margin: 12px 0 0; padding: 10px 12px; border-radius: 12px; background: var(--panel-2); }
.ep-box h3 { display: flex; align-items: center; gap: 6px; margin: 0 0 6px; font-size: .92rem; }
.ep-box h3 .ic { width: 15px; height: 15px; }
.ep-box ul { margin: 0; padding-left: 18px; font-size: .9rem; }
.ep-box p { margin: 0; font-size: .9rem; }
.ep-check { border-left: 3px solid var(--mediocre); }
.ep-rules { border-left: 3px solid var(--accent); }
.ep-call a { font-weight: 700; color: var(--accent); }
.night-note--rule { color: var(--ink); font-weight: 600; }
.card-note { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
/* Hourly outlook rows (Greg 10-13): no rating chips beside the beads (the windows
   above show them); a compact day label above full-width beads; earlier hours
   in full color, only the current hour outlined with "Now". */
.dtile { display: flex !important; flex-direction: column; align-items: stretch !important; gap: 4px; padding: 8px 12px 10px; }
.dtile-h { flex-direction: row !important; align-items: baseline !important; gap: 8px; min-height: 0; }
.dtile-name { font-size: .82rem; min-width: 0; }
.bead.is-past, .tl[data-mode="waves"] .bead.is-past, .tl[data-mode="wind"] .bead.is-past { opacity: 1; }
/* ---------- Hourly outlook: ribbons + one five-day chart (Greg picked mockup A, 10-13) ---------- */
.mk[data-mode="waves"] .mk-m:not(.m-waves), .mk[data-mode="wind"] .mk-m:not(.m-wind), .mk[data-mode="tide"] .mk-m:not(.m-tide) { display: none !important; }
.mk-rib { display: grid; grid-template-columns: 13fr 4fr; gap: 4px; }
.mk-rd, .mk-rn { display: grid; gap: 2px; }
.mk-rd { grid-template-columns: repeat(13, minmax(0, 1fr)); }
.mk-rn { grid-template-columns: repeat(4, minmax(0, 1fr)); padding: 2px; margin: -2px; border-radius: 5px; background: var(--night-band); }
.mk-c { height: 12px; border-radius: 3px; background: var(--none); cursor: pointer; }
.mk-c.lv-great { background: var(--great); } .mk-c.lv-good { background: var(--good); } .mk-c.lv-mediocre { background: var(--mediocre); } .mk-c.lv-rough { background: var(--rough); } .mk-c.lv-stayhome { background: #c4202c; }
.mk-c.is-now { box-shadow: 0 0 0 2px var(--surface), 0 0 0 3px var(--ink); }
.mk-c.is-sel { box-shadow: 0 0 0 2px var(--surface), 0 0 0 3px var(--accent); }
.mk-ticks { display: grid; grid-template-columns: 13fr 4fr; gap: 4px; font-size: .68rem; color: var(--muted); position: relative; height: 1.1em; }
.mk-ticks span { position: absolute; } .mk-ticks span:nth-child(1) { left: 0; } .mk-ticks span:nth-child(2) { left: calc(5 / 17 * 100%); } .mk-ticks span:nth-child(3) { left: calc(9 / 17 * 100%); } .mk-ticks span:nth-child(4) { left: calc(13 / 17 * 100% + 4px); }
.mk-dn { font: 800 .8rem var(--font-h); }
/* A */
.mk-ribs { display: grid; gap: 4px; margin: 4px 0 12px; }
.mk-ribrow { display: grid; grid-template-columns: 3.4rem minmax(0, 1fr); align-items: center; gap: 8px; }
.mk-charts { margin-top: 4px; }
.mk-chart { display: block; width: 100%; height: auto; overflow: visible; }
.mk-chart.cw-900 { display: none; }
@media (min-width: 700px) { .mk-chart.cw-600 { display: none; } .mk-chart.cw-900 { display: block; } }
.mk-grid { stroke: color-mix(in srgb, var(--line) 80%, transparent); stroke-width: 1; }
.mk-tick { fill: var(--muted); font: 500 10px var(--font-b); }
.mk-area { fill: color-mix(in srgb, var(--accent) 22%, transparent); }
.mk-line { fill: none; stroke: var(--accent); stroke-width: 2; }
.mk-pk { fill: var(--accent); stroke: var(--surface); stroke-width: 1.5; }
.mk-pkt { fill: var(--ink); font: 700 10px var(--font-b); paint-order: stroke; stroke: var(--panel); stroke-width: 3px; }
.mk-now { stroke: var(--ink); stroke-width: 1.5; }
.mk-nowt { fill: var(--ink); font: 700 10px var(--font-b); }
.mk-hit { fill: transparent; cursor: crosshair; }
.mk-hit:hover, .mk-hit.is-sel { fill: color-mix(in srgb, var(--accent) 18%, transparent); }

.mk-day { fill: var(--ink); font: 700 11px var(--font-h); }
.mk-key { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 16px; margin: 6px 0 0; }
.mk-k { display: inline-flex; align-items: center; gap: 6px; }
.mk-key i { display: inline-block; width: 14px; height: 10px; border-radius: 2px; }

/* ---------- Site page polish (Greg 10-14): daytime first, after dark as context ---------- */
/* Plan your dive: Daytime windows, then After dark set apart */
.dp-pick.dp-split { display: grid !important; grid-template-columns: minmax(0, 3fr) minmax(0, 1.15fr); gap: 14px; width: min(100%, 760px); padding: 0; background: none; align-items: end; }
.dp-grp { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.dp-grp-l { display: inline-flex; align-items: center; gap: 4px; font: 700 .7rem var(--font-b); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); padding-left: 6px; }
.dp-grp-l .ic { width: 12px; height: 12px; }
.dp-grp-b { display: grid; gap: 4px; padding: 4px; border-radius: 16px; background: var(--panel-2); }
.dp-grp--day .dp-grp-b { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.dp-grp--night .dp-grp-b { grid-template-columns: 1fr; background: transparent; border: 1px dashed color-mix(in srgb, var(--muted) 45%, transparent); }
.dp-grp--night button { opacity: .92; }
.dp-grp--night .dp-name .ic { display: none; }
.seg-ctl button.dp-night:not([aria-checked="true"]) { background: transparent !important; }
@media (max-width: 600px) { .dp-pick.dp-split { grid-template-columns: 1fr; gap: 8px; } .dp-grp--night .dp-grp-b { width: calc((100% - 8px) / 3 + 8px); } }
.dp-detail--night { background: var(--panel-2); border: 1px dashed color-mix(in srgb, var(--muted) 40%, transparent); }

/* Hourly strip: lighter rows, after-dark hours muted with a dashed outline, Today emphasized */
.mk-ribs { gap: 3px; }
.mk-c { height: 10px; border-radius: 2px; }
.mk-rn { background: none; outline: 1px dashed color-mix(in srgb, var(--muted) 45%, transparent); outline-offset: 0; border-radius: 3px; }
.mk-rn .mk-c { filter: saturate(.55) brightness(.9); }
.mk-ribrow .mk-dn { font-weight: 600; color: var(--muted); }
.mk-ribrow:first-child .mk-dn { font-weight: 800; color: var(--ink); }
.mk-ribrow.is-sel .mk-dn { color: var(--accent); }
.mk-c.is-sel { box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--accent); position: relative; z-index: 1; }
.mk-ticks .tk-dark { display: inline-flex; align-items: center; gap: 3px; }
.mk-ticks .tk-dark .ic { width: 11px; height: 11px; }

/* Chart: clean background; thin after-dark markers; the line dims after dark and dashes overnight */
.mk-phase { stroke: color-mix(in srgb, var(--muted) 55%, transparent); stroke-width: 1; stroke-dasharray: 2 3; }
.mk-moon { fill: none; stroke: var(--muted); stroke-width: 2.4; }
.mk-line-a { opacity: .6; }
.mk-line-o { stroke: var(--muted); opacity: .75; stroke-dasharray: 4 3; }
.mk-ovl { fill: var(--muted); font: 500 9px var(--font-b); opacity: .8; }
.mk-pt { fill: var(--surface); stroke: var(--accent); stroke-width: 3; opacity: 0; pointer-events: none; }
.mk-pt.is-sel { opacity: 1; }
.mk-hit.is-sel { fill: color-mix(in srgb, var(--accent) 22%, transparent); }
.mk-key i { width: 18px; height: 0; border-radius: 0; border-top: 2px solid var(--accent); }
.mk-key-a { opacity: .6; }
.mk-key-o { border-top: 2px dashed var(--muted) !important; }

/* Readout: compact chips for the inspected moment */
.mk-read.has-chips { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; min-height: 2.8em; }
.rd-c { display: inline-flex; align-items: center; padding: 3px 9px; border-radius: 999px; background: var(--panel-2); color: var(--ink); font: 600 .8rem var(--font-b); font-variant-numeric: tabular-nums; white-space: nowrap; }
.rd-sel { background: transparent; color: var(--accent); padding-left: 0; font-weight: 700; }
.rd-time { font-family: var(--font-h); font-weight: 800; }
.rd-lv { color: var(--lv-ink); font-weight: 800; }
.rd-lv.lv-none { color: var(--none-ink); }
.rd-ovn, .rd-note { background: transparent; border: 1px dashed color-mix(in srgb, var(--muted) 50%, transparent); color: var(--muted); }

/* Right now: bigger numbers, quieter labels, All readings secondary */
.tiles4 dd { font-size: 2.3rem; }
.tiles4 dt { font-size: .78rem; font-weight: 500; letter-spacing: .01em; }
.tiles4 .hint { font-size: .8rem; opacity: .9; }
.sec-row .allr summary { color: var(--muted); font-size: .84rem; font-weight: 500; }

/* Hero: the trajectory line as a compact alert chip */
.site-hero .trend-note { padding: 3px 10px 3px 8px; border-radius: 999px; font-size: .8rem; background: color-mix(in srgb, currentColor 14%, transparent); border: 1px solid color-mix(in srgb, currentColor 35%, transparent); }

/* Entry & parking: concise operational lines */
.ep-line { margin: 0 0 6px; font-size: .93rem; line-height: 1.45; }
.ep-line > .ic { margin-top: 2px; width: 16px; height: 16px; }
.ep-box { margin-top: 10px; padding: 8px 12px; }
.ep-box ul { padding-left: 16px; } .ep-box li + li { margin-top: 2px; }
.ep-haz p { font-size: .9rem; line-height: 1.45; }

/* About: editorial columns with room to breathe */
.about3 { gap: 20px 40px; }
@media (min-width: 900px) { .about3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.about3 > div { max-width: 46ch; }
.about3 p { line-height: 1.6; }
.about3 h3 { font-size: .8rem !important; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }

/* Advanced: layered, not a data dump */
.advanced .tabs { margin-top: 4px; }
.advanced .tabpanel { padding: 4px 2px 0; }
.advanced .tabpanel > h3 { margin: 4px 0 10px; }
.advanced .tabpanel > p { max-width: 75ch; }
.advanced .tabpanel > p + p { margin-top: 8px; }
.advanced .minis { margin-bottom: 18px; }
.advanced .noaa-wrap { margin: 14px 0; padding: 10px 12px; border-radius: 12px; background: var(--panel-2); }
.advanced .info dt { padding-top: 10px; border-top: 1px solid color-mix(in srgb, var(--line) 60%, transparent); }
.advanced .info dt:first-child { border-top: 0; padding-top: 0; }
.rd-c.rd-lv.lv-great { background: var(--great); } .rd-c.rd-lv.lv-good { background: var(--good); } .rd-c.rd-lv.lv-mediocre { background: var(--mediocre); } .rd-c.rd-lv.lv-rough { background: var(--rough); } .rd-c.rd-lv.lv-stayhome { background: var(--stayhome); } .rd-c.rd-lv.lv-none { background: var(--none); }
.mk-ticks span { white-space: nowrap; }
.mk-ticks .tk-s { display: none; }
@media (max-width: 600px) { .mk-ticks .tk-l { display: none; } .mk-ticks .tk-s { display: inline; } }
.advanced .tabpanel > p:has(> strong:first-child) { padding: 10px 14px; border-radius: 12px; background: var(--panel-2); max-width: none; }
.advanced .tabpanel > p:has(> strong:first-child) + p:has(> strong:first-child) { margin-top: 8px; }
/* ---------- Homepage polish (Greg 10-14): one outlook row, a Day/Night toggle for the grid ---------- */
.ol-v { display: contents; }
.ol-v--night, .oh-night { display: none; }
.sites-section[data-outlook="night"] .ol-v--day, .sites-section[data-outlook="night"] .oh-day { display: none; }
.sites-section[data-outlook="night"] .ol-v--night { display: contents; }
.sites-section[data-outlook="night"] .oh-night { display: inline-flex; align-items: center; gap: 4px; }
.oh-night .ic { width: 12px; height: 12px; }
.ol-bar { height: 7px; }
.ol-lv { display: inline-flex; align-items: center; justify-content: center; gap: 2px; font-size: .66rem; }
.ol-dark { display: inline-flex; color: var(--tx-stayhome); }
.ol-dark .ic { width: 10px; height: 10px; }
.outlook-h { font: 600 .74rem var(--font-b); color: var(--muted); }
.ol-mode { display: inline-flex; align-items: center; gap: 2px; padding: 3px; border-radius: 999px; background: var(--panel-2); border: 1px solid var(--line); }
.ol-mode-l { font-size: .74rem; font-weight: 600; color: var(--muted); padding: 0 6px 0 8px; }
.ol-mode button { display: inline-flex; align-items: center; gap: 5px; border: 0; border-radius: 999px; padding: 5px 12px; background: transparent; color: var(--muted); font: 700 .84rem var(--font-h); cursor: pointer; }
.ol-mode button .ic { width: 14px; height: 14px; }
.ol-mode button[aria-pressed="true"] { background: var(--accent); color: var(--accent-ink); }
.ol-mode button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.sites-head { flex-wrap: wrap; gap: 10px 16px; }
/* Region headers breathe, with a quiet divider between groups */
.sg-h { font-size: 1.35rem; margin: 6px 0 14px; }
.sg-sub { font-size: .86rem; }
.site-group + .site-group { margin-top: var(--s4); padding-top: var(--s3); border-top: 1px solid color-mix(in srgb, var(--line) 55%, transparent); }
/* Dangerous: urgent, not broken */
/* Seven days (Greg 10-14): the phone chart keeps its text size and scrolls sideways */
.mk-charts { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.mk-chart.cw-600 { min-width: 600px; }

/* Seven days (Greg 10-14): no special styling for the far days; the windGap note uses .far-note */
.far-note { display: flex; gap: 8px; align-items: flex-start; margin: 4px 0 8px; font-size: .86rem; color: var(--muted); }
.far-note .ic { width: 15px; height: 15px; flex: none; margin-top: 2px; }
.ol-name { font-size: .68rem; }
.ol-lv { font-size: .6rem; letter-spacing: -.02em; }
@media (max-width: 600px) {
  .pd-days { grid-template-columns: repeat(7, minmax(54px, 1fr)); overflow-x: auto; }
  .pd-days .dt-lv { font-size: .6rem; }
}
/* ---------- Level badges (Greg 10-14): one width per size, Severe with its warning triangle ---------- */
.badge, .chip { justify-content: center; gap: .3em; box-sizing: border-box; }
.badge .ic, .chip .ic { width: 1em; height: 1em; flex: none; stroke-width: 2.6; }
.ol-lv.is-bad .ic, .dt-lv .ic-triangle-alert, .rd-lv .ic { width: 1em; height: 1em; flex: none; }
.ol-lv.is-bad { color: var(--tx-stayhome); opacity: 1; }
.rd-lv { gap: 4px; }
/* widths measured 10-14 at each size (widest = Severe with its icon); text centered */
.badge { min-width: 6.35em; } .badge--lg { min-width: 6.55em; } .badge--xl { min-width: 6.65em; } .chip { min-width: 6.3em; }
.pd-chips .chip, .dtile-chips .chip { min-width: 0; }
/* Narrow cards: "Severe" keeps its full word, with the triangle stacked above it */
.ol-bars { container-type: inline-size; }
@container (max-width: 340px) { .ol-lv.is-bad { flex-direction: column; gap: 0; line-height: 1.05; } }
/* ---------- Phone toolbar + Filters sheet (Greg 10-14); desktop keeps the full toolbar ---------- */
.mtb { display: flex; align-items: center; gap: 6px; width: 100%; }
.mtb-b { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--panel-2); color: var(--ink); font: 700 .86rem var(--font-h); cursor: pointer; }
.mtb-b .ic { width: 16px; height: 16px; color: var(--accent); }
.mtb-b span { display: inline-flex; align-items: center; gap: 6px; }
.mtb-b:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.mtb .mtb-night, .mtb[data-outlook="night"] .mtb-day, .mtb .mtb-list, .mtb[data-view="list"] .mtb-cards { display: none; }
.mtb[data-outlook="night"] .mtb-night, .mtb[data-view="list"] .mtb-list { display: inline-flex; }
.mtb-f { margin-left: auto; }
.mtb-n { min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: var(--accent); color: var(--accent-ink); font: 800 .74rem var(--font-b); justify-content: center; }
@media (min-width: 601px) { .mtb { display: none !important; } }
@media (max-width: 600px) {
  .sites-head .ol-mode, .sites-head .toolbar { display: none !important; }
  .sites-head { margin-top: var(--s3); gap: 8px; }
  .sites-head h2 { font-size: 1.25rem; }
  .sites-section .site-group:first-of-type .sg-h { margin-top: 2px; }
}
dialog.sheet--auto { height: auto !important; max-height: 86vh !important; }
@media (min-width: 641px) { dialog.sheet--auto { inset: auto 0 0 auto; height: auto; border-radius: 16px 0 0 0; } }
.flt-g { border: 0; margin: 0; padding: 0; display: grid; gap: 6px; }
.flt-g legend { font: 700 .76rem var(--font-b); letter-spacing: .06em; text-transform: uppercase; color: #a9c7d2; margin-bottom: 6px; }
.flt-o { display: flex; align-items: center; gap: 12px; min-height: 48px; padding: 0 14px; border-radius: 12px; border: 1px solid rgba(169, 199, 210, .22); cursor: pointer; font-size: 1rem; color: #e8f6fa; }
.flt-o input { width: 20px; height: 20px; accent-color: #22d3ee; flex: none; }
.flt-o:has(input:checked) { border-color: #22d3ee; background: rgba(34, 211, 238, .1); }
.flt-actions { display: flex; gap: 10px; margin-top: 4px; }
.flt-actions button { flex: 1; min-height: 48px; border-radius: 12px; font: 800 1rem var(--font-h); cursor: pointer; }
.flt-reset { background: transparent; color: #e8f6fa; border: 1px solid rgba(169, 199, 210, .35); }
.flt-apply { background: #22d3ee; color: #032628; border: 0; }
.sheet--auto .sheet-in { overflow: auto; }
/* ---------- Mobile polish (Greg 10-14) ---------- */
.nav-links a { display: inline-flex; align-items: center; gap: 5px; }
.nav-links a .ic { display: none; width: 18px; height: 18px; }
.brand span { white-space: nowrap; }
.hero-meta, .site-photo--m { display: none; }
@media (max-width: 600px) {
  .nav-links { gap: 14px; }
  .nav-links a .ic { display: inline-block; }
  .nav-links .nl-t { display: none; }
  .brand { font-size: .98rem; gap: 8px; }
  /* site hero: title full width, star icon top right, a step smaller, one wrapped action row */
  .site-hero-in { padding-block: 14px 18px; gap: 0; }
  .site-hero .crumbs { margin-bottom: 6px; }
  .title-row { align-items: flex-start; }
  .site-hero h1 { font-size: 1.75rem; line-height: 1.15; }
  .site-hero .alt { display: block; font-size: .6em; margin-top: 2px; }
  .fav--labeled { width: 40px; height: 40px; padding: 0; justify-content: center; flex: none; }
  .fav--labeled [data-fav-label] { display: none; }
  .site-hero .area { font-size: .84rem; }
  .cur { margin-top: 10px; }
  .cur-eyebrow { margin-bottom: 6px; font-size: .68rem; }
  .cur-row { gap: 8px 10px; }
  .cur-row .as-of { display: none; }
  .site-hero .badge--xl { font-size: 1.12rem; padding: 6px 14px; }
  .assess { font-size: 1rem; margin: 8px 0 0; }
  .hero-actions { margin-top: 12px; gap: 8px 10px; }
  .hero-actions .btn-link { padding: 8px 14px; font-size: .9rem; }
  .hero-actions .conf summary { font-size: .82rem; padding: 6px 10px; }
  .hero-actions .src-pop summary { font-size: .8rem; }
  .hero-meta { display: block; flex-basis: 100%; font-size: .78rem; color: var(--mist); margin-top: -2px; }
  .site-hero .site-photo:not(.site-photo--m) { display: none; }
  .site-photo--m { display: block; margin: 0 0 16px; }
}
/* Light mode cards: the photo's top stays dark enough for the white title, area and note (mobile pass 10-14) */
@media (prefers-color-scheme: light) {
  .card-photo::after { background: linear-gradient(180deg, rgba(6, 21, 34, .62) 0%, rgba(6, 21, 34, .38) 34%, rgba(255, 255, 255, .5) 66%, #fff 100%) !important; }
}
.card--photo .card-note { color: #f1f7f9; text-shadow: 0 1px 2px rgba(0, 0, 0, .7); }
.card--photo .card-note .ic { color: #f1f7f9; }
.card--photo .card-note--closed { color: #ffd0d0; }
.sites.is-list .card--photo .card-note { color: inherit; text-shadow: none; }
@media (max-width: 600px) {
  .advanced .tabs { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .advanced .tabs button { flex: none; }
}
@media (max-width: 600px) {
  .sites.is-list .card { padding: 10px 60px 10px 14px; }
  .sites.is-list .card-top h3 { font-size: 1.05rem; }
  .sites.is-list .badge--lg { font-size: .86rem; padding: 4px 10px; }
  .sites.is-list .area { font-size: .8rem; }
}
.dp-name--times { font-size: .9rem; }
.why .dx p.small + p.small { margin-top: 4px; }
.rd-c small { font-size: .7rem; font-weight: 600; color: var(--muted); margin-right: 2px; }
.mk-key .mk-k .ic { width: 13px; height: 13px; color: var(--muted); }
/* Desktop: the 7-day ribbons and chart always fit their panel (Greg's 10-14 screenshot showed a clip) */
.mk-ribs, .mk-ribrow, .mk-rib, .mk-charts { min-width: 0; max-width: 100%; }
.mk-ticks .tk-dark { left: auto !important; right: 0; }
@media (min-width: 700px) { .mk-charts { overflow-x: visible; } .mk-chart.cw-900 { width: 100%; max-width: 100%; min-width: 0; } }
/* Phones: every popover opens in ONE bottom sheet attached to <body> (site.js), over a backdrop, so no
   transformed ancestor can trap or clip it; the in-place body stays hidden (Greg 10-14) */
.pop-sheet { position: fixed; inset: 0; z-index: 80; display: flex; align-items: flex-end; background: rgba(3, 10, 16, .5); }
.pop-sheet[hidden] { display: none !important; }
.pop-sheet-in { position: relative; box-sizing: border-box; width: calc(100% - 16px); max-height: 70vh; overflow: auto; margin: 0 8px calc(8px + env(safe-area-inset-bottom, 0px)); padding: 16px 44px 16px 16px; border-radius: 16px; background: var(--surface); color: var(--ink); border: 1px solid var(--line); box-shadow: 0 -8px 32px rgba(0, 0, 0, .45); font-size: .95rem; line-height: 1.5; }
.pop-sheet-in p { margin: 0 0 8px; } .pop-sheet-in p:last-child { margin-bottom: 0; }
.pop-sheet-x { position: absolute; top: 8px; right: 8px; width: 32px; height: 32px; border-radius: 50%; border: 1px solid var(--line); background: transparent; color: var(--ink); font-size: 1.2rem; line-height: 1; cursor: pointer; }
@media (max-width: 600px) { html.js details.pop > .pop-body { display: none !important; } }
/* Day tabs and other sideways scrollers on phones: no visible scrollbar, an edge fade instead */
@media (max-width: 600px) {
  .pd-days, .advanced .tabs { scrollbar-width: none; -ms-overflow-style: none; }
  .pd-days::-webkit-scrollbar, .advanced .tabs::-webkit-scrollbar { display: none; }
  .pd-days { -webkit-mask-image: linear-gradient(90deg, #000 88%, transparent); mask-image: linear-gradient(90deg, #000 88%, transparent); }
}
.mk-ticks .tk-dark .ic { margin-right: 2px; }
/* The window panel reads as the selected tile's details (no heading or badge; Greg 10-14) */
.dp-details .dp-detail { border-top: 3px solid var(--accent); }
.dp-details .dp-detail--night { border-top-style: solid; }
.dp-details .pd-line { margin-top: 0; }
.night-note { font-size: .84rem; }
/* Sticky sub-header: the site name wins on phones; anchored sections clear the sticky bars */
@media (max-width: 600px) { .sn-links { display: none; } .sn-name { max-width: none !important; } }
main section[id], main .day, main details { scroll-margin-top: calc(var(--nav-h) + 56px); }
.pd-days button, .daytabs button { position: relative; } /* keeps the .sr text inside the sideways scroller (it widened phone pages to 409 px) */

/* SurgeCast brand in the header (Greg 10-14) */
:root { --nav-h: 66px; }
@media (max-width: 600px) { :root { --nav-h: 58px; } }
/* Header lockup (Greg 10-14): the concept's own mark (raster crop), name 25px desktop / 21px phone */
.brand picture { display: block; flex: none; line-height: 0; }
.brand .brand-mark { display: block; width: auto; height: 40px; }
.brand { gap: 10px; }
.brand-w { font: 800 1.5625rem/1 var(--font-h); letter-spacing: -.02em; color: #fff; white-space: nowrap; }
.brand-w b { font-weight: 800; color: var(--brand-cyan); }
@media (max-width: 600px) { .brand .brand-mark { height: 32px; } .brand { gap: 8px; } .brand-w { font-size: 1.3125rem; } }

/* Hourly outlook on phones (Greg 10-14): bubbles are display-only; touch and hold the chart, then drag, to scrub the hours */
.ho-sub { display: inline-block; }
.ho-tch { display: none; }
.mk.is-touch .ho-ptr { display: none; } .mk.is-touch .ho-tch { display: inline; }
.mk.is-touch .mk-c { cursor: default; }
.mk.is-touch .mk-c.is-sel { box-shadow: none; }
.mk.is-touch .mk-ribrow.is-sel .mk-dn { color: var(--muted); }
.mk.is-touch .mk-ribrow:first-child .mk-dn { color: var(--ink); }
.mk.is-touch .mk-chart { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
.mk.is-touch .mk-hit { cursor: default; }
.mk.is-touch .mk-hit:hover:not(.is-sel) { fill: transparent; }
/* the axis's after-dark label: its inner spans flow inline (the absolute tick rule hit them too, so the moon sat on "8 PM") */
.mk-ticks .tk-dark span { position: static; }

/* Forecast vs. buoy (Advanced > Buoy, Greg 10-14) */
.track { margin: 16px 0; padding: 14px; background: var(--panel-2); border: 1px solid var(--line); border-radius: var(--radius); }
.track h4 { margin: 0 0 6px; }
.track-read { margin: 0 0 10px; }
.track-h { margin: 10px 0 2px; font: 700 .74rem var(--font-b); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.tk-chart { display: block; width: 100%; height: auto; overflow: visible; }
.tk-chart.cw-900 { display: none; }
@media (min-width: 700px) { .tk-chart.cw-360 { display: none; } .tk-chart.cw-900 { display: block; } }
.tk-obs { fill: none; stroke: var(--accent); stroke-width: 2.2; stroke-linejoin: round; }
.tk-fc { fill: none; stroke: var(--ink); stroke-width: 1.6; stroke-dasharray: 5 3; opacity: .75; }
.tk-fut { fill: color-mix(in srgb, var(--muted) 10%, transparent); }
.tk-day { stroke: color-mix(in srgb, var(--muted) 35%, transparent); stroke-width: 1; }
.tk-lab { fill: var(--muted); font: 600 10px var(--font-b); }
.mk-key i.tk-key-o { border-top: 2.2px solid var(--accent); }
.mk-key i.tk-key-f { border-top: 2px dashed var(--ink) !important; opacity: .75; }
/* the corrected forecast the ratings use: violet, distinct from the buoy (accent) and the raw model (dashed ink) */
.track { --tk-cor: #c4b5fd; }
@media (prefers-color-scheme: light) { .track { --tk-cor: #6d28d9; } }
.tk-cor { fill: none; stroke: var(--tk-cor); stroke-width: 2.4; stroke-linejoin: round; }
.mk-key i.tk-key-c { border-top: 2.4px solid var(--tk-cor); }

/* Thunder and NWS alerts (Greg 10-14): hazard banners with their own icons; rain is a plain value only */
.danger--nws { border-left-color: #d97706; }
.danger--th { border-left-color: #eab308; }
.danger a { color: inherit; text-decoration: underline; }
.hazard-line--nws .ic, .hazard-line--th .ic { color: var(--danger-ink); }
.dp-th { display: inline-flex; color: #ca8a04; margin-left: 4px; vertical-align: middle; }
.dp-th .ic { width: 15px; height: 15px; }
@media not all and (prefers-color-scheme: light) { .dp-th { color: #facc15; } }
.th-note { display: flex; gap: 8px; align-items: flex-start; margin: 0 0 10px; padding: 8px 10px; border-radius: 10px; background: var(--danger-bg); color: var(--danger-ink); border-left: 4px solid #eab308; font-size: .92rem; }
.th-note .ic { flex: none; width: 18px; height: 18px; margin-top: 1px; }
.info-note { display: flex; gap: 8px; align-items: flex-start; margin: 0 0 var(--s2); color: var(--muted); font-size: .9rem; }
.info-note .ic { flex: none; width: 16px; height: 16px; margin-top: 2px; }
.mk-c.has-th { box-shadow: inset 0 4px 0 #7c3aed; }
.mk-c.has-th.is-now { box-shadow: inset 0 4px 0 #7c3aed, 0 0 0 2px var(--surface), 0 0 0 3px var(--ink); }
.mk-key i.mk-key-th { width: 12px; height: 10px; border: 0 !important; border-radius: 2px; background: var(--none); box-shadow: inset 0 4px 0 #7c3aed; }
.mk-k-th .ic { width: 13px; height: 13px; }
.rd-th { background: var(--danger-bg) !important; color: var(--danger-ink) !important; font-weight: 700; }
