/* Rastgele app chrome: tokens, layout (phone / column / desktop frame), map, top bar, bottom sheet, sections, modals. */

/* ---------- Tokens ---------- */
:root {
  color-scheme: light;
  --bg: #eef3f7;
  --surface: #ffffff;
  --surface-2: #f4f7fa;
  --ink: #0e1a24;
  --ink-2: #445566;
  --muted: #6b7c8c;
  --ink-3: #566778; /* small secondary text: >= 4.9:1 on every light surface */
  --line: #dde5ec;
  --brand: #0b5e8e;
  --brand-2: #0a7fa8;
  --on-brand: #ffffff;
  --accent: #f59e0b;

  --brand-soft: #e2eff8;
  --brand-ink: #0b5e8e;
  --ok-bg: #e5f5e5;
  --caution-bg: #fff3d6;
  --caution-line: #f2c35a;
  --caution-ink: #8a5a00;
  --danger-bg: #fde9e9;
  --danger-line: #eba2a2;
  --danger-ink: #a12424;
  --info-bg: #e6f1f8;
  --pos-ink: #0b7a0b;
  --scrim: rgba(7, 16, 25, 0.42);
  --map-bg: #aad3df;
  --skel: #e3eaf0;

  --lvl-0: #dde5ec;
  --lvl-1: #86b6ef;
  --lvl-2: #3987e5;
  --lvl-3: #1c5cab;

  --wx-sun: #f59e0b;
  --wx-sun-fill: #fde68a;
  --wx-moon: #7d93ad;
  --wx-moon-fill: #e4ebf3;
  --wx-cloud: #6b7c8c;
  --wx-cloud-fill: #ffffff;
  --wx-cloud-back: #e6ecf1;
  --wx-rain: #2a78d6;
  --wx-snow: #5598e7;
  --wx-bolt: #f59e0b;
  --wx-bolt-fill: #fde047;

  --moon-dark: #c5d0da;
  --moon-lit: #fff8dc;
  --moon-rim: #9fb0bf;

  --db-day: #fde9b0;
  --db-twilight: #c9d7e6;
  --db-night: #3a4f63;

  --shadow-1: 0 1px 2px rgba(14, 26, 36, 0.06), 0 1px 6px rgba(14, 26, 36, 0.06);
  --shadow-2: 0 4px 16px rgba(14, 26, 36, 0.16);
  --shadow-3: 0 -6px 30px rgba(14, 26, 36, 0.18);
  --shadow-fab: 0 2px 10px rgba(14, 26, 36, 0.18), 0 1px 2px rgba(14, 26, 36, 0.12);

  --radius: 16px;
  --radius-sm: 12px;
  --pill: 999px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  --safe-t: env(safe-area-inset-top, 0px);
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-l: env(safe-area-inset-left, 0px);
  --safe-r: env(safe-area-inset-right, 0px);
  --sheet-vis: 0px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #071019;
    --surface: #0f1a24;
    --surface-2: #15232f;
    --ink: #e8f0f6;
    --ink-2: #a9b9c7;
    --muted: #7f92a3;
    --ink-3: #8a9db0;
    --line: #22323f;
    --brand: #3aa0d8;
    --brand-2: #5cc0e8;
    --on-brand: #04121c;
    --accent: #fbbf24;
    --brand-soft: #10314a;
    --brand-ink: #7cc6ef;
    --ok-bg: #0f2a19;
    --caution-bg: #2c2210;
    --caution-line: #6b5114;
    --caution-ink: #f5c955;
    --danger-bg: #301417;
    --danger-line: #6e2a2e;
    --danger-ink: #ff9d9d;
    --info-bg: #0f2536;
    --pos-ink: #6ad66a;
    --scrim: rgba(0, 0, 0, 0.55);
    --map-bg: #0d2230;
    --skel: #1b2a37;
    --lvl-0: #22323f;
    --lvl-1: #184f95;
    --lvl-2: #3987e5;
    --lvl-3: #86b6ef;
    --wx-sun-fill: #f8c74a;
    --wx-moon: #9fb4cc;
    --wx-moon-fill: #33475a;
    --wx-cloud: #a9b9c7;
    --wx-cloud-fill: #1d2c39;
    --wx-cloud-back: #15232f;
    --wx-rain: #5ba4f0;
    --wx-snow: #9ec5f4;
    --moon-dark: #2a3a49;
    --moon-lit: #f3ecd0;
    --moon-rim: #4a5d6e;
    --db-day: #6b5a22;
    --db-twilight: #2f4459;
    --db-night: #0a1620;
    --shadow-1: 0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow-2: 0 4px 18px rgba(0, 0, 0, 0.5);
    --shadow-3: 0 -6px 30px rgba(0, 0, 0, 0.55);
    --shadow-fab: 0 2px 12px rgba(0, 0, 0, 0.55);
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #071019;
  --surface: #0f1a24;
  --surface-2: #15232f;
  --ink: #e8f0f6;
  --ink-2: #a9b9c7;
  --muted: #7f92a3;
  --ink-3: #8a9db0;
  --line: #22323f;
  --brand: #3aa0d8;
  --brand-2: #5cc0e8;
  --on-brand: #04121c;
  --accent: #fbbf24;
  --brand-soft: #10314a;
  --brand-ink: #7cc6ef;
  --ok-bg: #0f2a19;
  --caution-bg: #2c2210;
  --caution-line: #6b5114;
  --caution-ink: #f5c955;
  --danger-bg: #301417;
  --danger-line: #6e2a2e;
  --danger-ink: #ff9d9d;
  --info-bg: #0f2536;
  --pos-ink: #6ad66a;
  --scrim: rgba(0, 0, 0, 0.55);
  --map-bg: #0d2230;
  --skel: #1b2a37;
  --lvl-0: #22323f;
  --lvl-1: #184f95;
  --lvl-2: #3987e5;
  --lvl-3: #86b6ef;
  --wx-sun-fill: #f8c74a;
  --wx-moon: #9fb4cc;
  --wx-moon-fill: #33475a;
  --wx-cloud: #a9b9c7;
  --wx-cloud-fill: #1d2c39;
  --wx-cloud-back: #15232f;
  --wx-rain: #5ba4f0;
  --wx-snow: #9ec5f4;
  --moon-dark: #2a3a49;
  --moon-lit: #f3ecd0;
  --moon-rim: #4a5d6e;
  --db-day: #6b5a22;
  --db-twilight: #2f4459;
  --db-night: #0a1620;
  --shadow-1: 0 1px 2px rgba(0, 0, 0, 0.4);
  --shadow-2: 0 4px 18px rgba(0, 0, 0, 0.5);
  --shadow-3: 0 -6px 30px rgba(0, 0, 0, 0.55);
  --shadow-fab: 0 2px 12px rgba(0, 0, 0, 0.55);
}

/* Score bands: color is always paired with an icon + number/label. */
[data-band="great"], [data-band="good"] { --band: #0ca30c; --band-tint: rgba(12, 163, 12, 0.14); }
[data-band="fair"] { --band: #fab219; --band-tint: rgba(250, 178, 25, 0.2); }
[data-band="poor"] { --band: #ec835a; --band-tint: rgba(236, 131, 90, 0.2); }
[data-band="bad"] { --band: #d03b3b; --band-tint: rgba(208, 59, 59, 0.14); }

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; overscroll-behavior: none; }
body {
  font: 400 16px/1.45 var(--font);
  color: var(--ink);
  background: var(--bg);
  overflow: hidden;
  overscroll-behavior: none;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; margin: 0; text-align: inherit; }
button:disabled { cursor: default; }
a { color: var(--brand-ink); }
h1, h2, h3, h4, p, ul, ol { margin: 0; }
ul, ol { padding: 0; }
svg { flex: none; }
img { max-width: 100%; }
:focus-visible { outline: 3px solid var(--brand-2); outline-offset: 2px; border-radius: 8px; }
.sr-only { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; margin: -1px; }
.muted { color: var(--ink-3); }
.small { font-size: 0.875rem; }
.nw { white-space: nowrap; }
.ic-slot { display: inline-grid; place-items: center; }
[hidden] { display: none !important; }

/* ---------- Stage & frame ---------- */
.stage { position: relative; width: 100%; height: 100%; }
.intro { display: none; }
.app {
  position: relative;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
  overflow: clip; /* not even programmatically scrollable (focus on an off-screen row must not shift the whole app) */
  background: var(--map-bg);
  isolation: isolate;
}
@media (min-width: 481px) and (max-width: 899px) {
  body { background: var(--bg); }
  .app { max-width: 520px; margin: 0 auto; box-shadow: 0 0 0 1px var(--line), 0 0 40px rgba(14, 26, 36, 0.12); }
}
@media (min-width: 900px) {
  body {
    overflow: auto;
    background:
      radial-gradient(1200px 600px at 15% 10%, rgba(10, 127, 168, 0.18), transparent 60%),
      radial-gradient(900px 500px at 85% 90%, rgba(11, 94, 142, 0.16), transparent 60%),
      var(--bg);
  }
  .stage { display: flex; align-items: center; justify-content: center; gap: clamp(32px, 6vw, 88px); min-height: 100%; padding: 24px; }
  .app {
    flex: none;
    width: 420px;
    height: min(880px, calc(100vh - 48px));
    border-radius: 34px;
    box-shadow: 0 0 0 1px var(--line), 0 30px 80px rgba(7, 16, 25, 0.28), 0 8px 24px rgba(7, 16, 25, 0.14);
    --safe-t: 0px; --safe-b: 0px; --safe-l: 0px; --safe-r: 0px;
  }
  .intro { display: block; flex: 0 1 380px; max-width: 380px; }
}

/* ---------- Desktop intro panel ---------- */
.intro-brand { display: flex; align-items: center; gap: 14px; margin-bottom: 22px; }
.intro-brand img, .intro-brand svg { width: 64px; height: 64px; border-radius: 18px; box-shadow: var(--shadow-2); }
.intro h1 { font-size: 2.1rem; line-height: 1.1; letter-spacing: -0.02em; }
.intro-tag { color: var(--ink-2); font-size: 1.05rem; margin-top: 4px; }
.intro-lead { font-size: 1.15rem; line-height: 1.5; color: var(--ink); margin: 0 0 18px; }
.intro-points { list-style: none; display: grid; gap: 14px; margin: 0 0 28px; }
.intro-points li { display: grid; grid-template-columns: 40px 1fr; gap: 12px; align-items: start; color: var(--ink-2); }
.intro-points li b { display: block; color: var(--ink); font-size: 1.02rem; margin-bottom: 2px; }
.intro-points .ip-ic { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand-ink); }
.intro-qr { display: flex; gap: 18px; align-items: center; padding: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow-1); }
.intro-qr .qr { flex: none; width: 132px; height: 132px; border-radius: 12px; overflow: hidden; background: #fff; padding: 4px; }
.intro-qr .qr svg { width: 100%; height: 100%; display: block; }
.intro-qr b { display: flex; align-items: center; gap: 6px; font-size: 1.05rem; }
.intro-qr p { color: var(--ink-2); font-size: 0.92rem; margin-top: 4px; }
.intro-url { font-size: 0.8rem !important; color: var(--ink-3) !important; word-break: break-all; }
.intro-foot { margin-top: 18px; font-size: 0.82rem; color: var(--ink-3); }

/* ---------- Map ---------- */
.map { position: absolute; inset: 0; z-index: 0; background: var(--map-bg); }
.leaflet-container { background: var(--map-bg); font: 12px/1.4 var(--font); -webkit-tap-highlight-color: transparent; }
.leaflet-container a { color: var(--brand-ink); }
.leaflet-bottom { transform: translateY(calc(-1 * var(--sheet-vis))); transition: transform 0.25s var(--ease); }
.app.sheet-dragging .leaflet-bottom { transition: none; }
.leaflet-control-attribution {
  font-size: 10px; line-height: 1.5; max-width: 82vw;
  background: rgba(255, 255, 255, 0.78) !important; color: #334 !important;
  border-radius: 8px 0 0 0; padding: 0 6px !important;
}
.leaflet-control-attribution a { color: #0b5e8e !important; }
:root[data-theme="dark"] .leaflet-control-attribution { background: rgba(15, 26, 36, 0.82) !important; color: #a9b9c7 !important; }
:root[data-theme="dark"] .leaflet-control-attribution a { color: #7cc6ef !important; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .leaflet-control-attribution { background: rgba(15, 26, 36, 0.82) !important; color: #a9b9c7 !important; }
  :root:not([data-theme="light"]) .leaflet-control-attribution a { color: #7cc6ef !important; }
}
.leaflet-tooltip.marine-tip {
  background: var(--surface); color: var(--ink); border: 1px solid var(--line); border-radius: 10px;
  box-shadow: var(--shadow-1); font: 600 12px/1.2 var(--font); padding: 5px 8px;
}
.leaflet-tooltip.marine-tip::before { display: none; }

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .tiles-osm { filter: invert(1) hue-rotate(180deg) brightness(0.9) contrast(0.88) saturate(0.55); }
  :root:not([data-theme="light"]) .tiles-sat { filter: brightness(0.85); }
  :root:not([data-theme="light"]) .tiles-seamark { filter: brightness(0.9); }
}
:root[data-theme="dark"] .tiles-osm { filter: invert(1) hue-rotate(180deg) brightness(0.9) contrast(0.88) saturate(0.55); }
:root[data-theme="dark"] .tiles-sat { filter: brightness(0.85); }

/* Markers */
.pin { position: relative; width: 44px; height: 54px; }
.pin-b {
  position: absolute; left: 2px; top: 2px; width: 40px; height: 40px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--brand); color: #fff; border: 3px solid #fff;
  box-shadow: 0 3px 10px rgba(7, 16, 25, 0.35);
  font: 800 15px/1 var(--font); letter-spacing: -0.02em;
}
.pin::after {
  content: ""; position: absolute; left: 50%; top: 39px; transform: translateX(-50%);
  border-left: 7px solid transparent; border-right: 7px solid transparent; border-top: 11px solid #fff;
  filter: drop-shadow(0 2px 1px rgba(7, 16, 25, 0.25));
}
.pin[data-band] .pin-b { background: var(--band); color: #0e1a24; }
.pin .pin-b svg { color: #fff; }
.pin.is-loading .pin-b::after {
  content: ""; position: absolute; inset: -9px; border-radius: 50%;
  border: 3px solid var(--brand-2); opacity: 0.8; animation: pulse 1.2s var(--ease) infinite;
}
.pin.is-drop { animation: drop 0.35s var(--ease); }
@keyframes pulse { from { transform: scale(0.75); opacity: 0.9; } to { transform: scale(1.35); opacity: 0; } }
@keyframes drop { from { transform: translateY(-14px); opacity: 0; } to { transform: none; opacity: 1; } }
.fav-pin {
  width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center;
  background: #fff; color: #d97706; border: 2px solid #f59e0b; box-shadow: 0 2px 6px rgba(7, 16, 25, 0.3);
}
.me-dot { width: 18px; height: 18px; border-radius: 50%; background: #1a73e8; border: 3px solid #fff; box-shadow: 0 0 0 6px rgba(26, 115, 232, 0.22), 0 1px 4px rgba(0, 0, 0, 0.35); }

/* ---------- Floating top bar ---------- */
.topbar {
  position: absolute; z-index: 25;
  top: calc(var(--safe-t) + 10px); left: calc(var(--safe-l) + 12px); right: calc(var(--safe-r) + 12px);
  display: flex; gap: 8px; align-items: center; pointer-events: none;
}
.topbar > * { pointer-events: auto; }
.search {
  flex: 1; min-width: 0; height: 48px; display: flex; align-items: center; gap: 8px;
  padding: 0 6px 0 14px; background: var(--surface); border-radius: var(--pill);
  box-shadow: var(--shadow-fab); color: var(--ink-3);
}
.search input {
  flex: 1; min-width: 0; height: 100%; border: 0; outline: 0; background: transparent;
  font-size: 16px; color: var(--ink); text-overflow: ellipsis;
}
.search input::placeholder { color: var(--muted); opacity: 1; }
.search input::-webkit-search-cancel-button { display: none; }
.search:focus-within { box-shadow: var(--shadow-fab), 0 0 0 3px var(--brand-2); }
.search-clear { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; color: var(--ink-3); }
.fab {
  flex: none; width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center;
  background: var(--surface); color: var(--ink); box-shadow: var(--shadow-fab);
  transition: transform 0.15s var(--ease), background 0.15s;
}
.fab:active { transform: scale(0.94); }
.fab.is-busy svg { animation: spin 1s linear infinite; color: var(--brand-ink); }
.map-tools {
  position: absolute; z-index: 24; right: calc(var(--safe-r) + 12px); top: calc(var(--safe-t) + 70px);
  display: flex; flex-direction: column; gap: 8px;
}
.map-tools .fab { width: 44px; height: 44px; }
.pop {
  position: absolute; z-index: 45; right: calc(var(--safe-r) + 12px); top: calc(var(--safe-t) + 122px);
  width: 236px; padding: 14px; background: var(--surface); border-radius: var(--radius);
  box-shadow: var(--shadow-2); border: 1px solid var(--line);
  animation: popIn 0.16s var(--ease);
}
@keyframes popIn { from { opacity: 0; transform: translateY(-6px) scale(0.98); } to { opacity: 1; transform: none; } }
.pop-title { font-weight: 700; font-size: 0.9rem; margin-bottom: 10px; }
.layer-opts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 12px; }
.layer-opt { display: grid; gap: 6px; justify-items: center; font-size: 0.85rem; font-weight: 600; padding: 6px; border-radius: 12px; border: 2px solid transparent; }
.layer-opt.is-sel { border-color: var(--brand); background: var(--brand-soft); }
.layer-thumb { width: 72px; height: 48px; border-radius: 9px; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.12); }
.layer-thumb-map { background: linear-gradient(135deg, #aad3df 0 45%, #f2efe9 45% 70%, #c8e3b4 70%); }
.layer-thumb-sat { background: linear-gradient(135deg, #0e3a52 0 45%, #5d6b4a 45% 72%, #8a7f5e 72%); }
.switch { display: flex; align-items: center; gap: 10px; font-size: 0.9rem; cursor: pointer; min-height: 44px; }
.switch small { color: var(--ink-3); }
.switch input { position: absolute; opacity: 0; pointer-events: none; }
.switch-ui { flex: none; width: 44px; height: 26px; border-radius: 13px; background: var(--line); position: relative; transition: background 0.2s; }
.switch-ui::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3); transition: transform 0.2s var(--ease); }
.switch input:checked + .switch-ui { background: var(--brand); }
.switch input:checked + .switch-ui::after { transform: translateX(18px); }
.switch input:focus-visible + .switch-ui { outline: 3px solid var(--brand-2); outline-offset: 2px; }

/* Search results dropdown */
.results {
  position: absolute; z-index: 45;
  top: calc(var(--safe-t) + 64px); left: calc(var(--safe-l) + 12px); right: calc(var(--safe-r) + 12px);
  max-height: min(60vh, 420px); overflow-y: auto; overscroll-behavior: contain;
  list-style: none; margin: 0; padding: 6px; background: var(--surface); border-radius: var(--radius);
  box-shadow: var(--shadow-2); border: 1px solid var(--line);
  animation: popIn 0.14s var(--ease);
}
.result { width: 100%; min-height: 52px; display: flex; align-items: center; gap: 12px; padding: 8px 10px; border-radius: 12px; color: var(--ink-3); }
.result span { display: grid; min-width: 0; }
.result b { color: var(--ink); font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.result small { font-size: 0.82rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.result:hover, .result.is-active { background: var(--surface-2); }
.result-head { font-size: 0.78rem; font-weight: 700; color: var(--ink-3); padding: 8px 10px 4px; text-transform: uppercase; letter-spacing: 0.04em; }
.result-note { display: flex; gap: 8px; align-items: center; padding: 12px 10px; color: var(--ink-3); font-size: 0.9rem; }

/* Network banner */
.net-banner {
  position: absolute; z-index: 26; left: 50%; transform: translateX(-50%);
  top: calc(var(--safe-t) + 64px); display: flex; align-items: center; gap: 6px;
  padding: 4px 12px; border-radius: var(--pill); background: #31414f; color: #fff;
  font-size: 0.78rem; font-weight: 650; box-shadow: var(--shadow-2); white-space: nowrap; pointer-events: none;
}

/* ---------- Generic components ---------- */
.btn {
  min-height: 48px; padding: 0 18px; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border-radius: var(--pill); font-weight: 650; font-size: 1rem; background: var(--surface-2); color: var(--ink);
  border: 1px solid var(--line); transition: transform 0.12s var(--ease), filter 0.15s;
}
.btn:active { transform: scale(0.98); }
.btn-primary { background: var(--brand); color: var(--on-brand); border-color: transparent; }
.btn-primary:hover { filter: brightness(1.06); }
.btn-block { width: 100%; }
.btn[aria-busy="true"] svg { animation: spin 1s linear infinite; }
.btn[aria-busy="true"] { pointer-events: none; opacity: 0.85; }
.icon-btn {
  width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; color: var(--ink-2);
  transition: background 0.15s, transform 0.12s var(--ease);
}
.icon-btn:hover { background: var(--surface-2); }
.icon-btn:active { transform: scale(0.92); }
.icon-btn.is-on { color: #d97706; }
.link { display: inline-flex; align-items: center; gap: 2px; color: var(--brand-ink); font-weight: 600; min-height: 44px; }
.chip {
  flex: none; display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 14px;
  border-radius: var(--pill); background: var(--surface); border: 1px solid var(--line); color: var(--ink);
  font-size: 0.92rem; font-weight: 600; white-space: nowrap; box-shadow: var(--shadow-1);
}
.chip svg { color: var(--brand-ink); }
.chip-static { min-height: 34px; padding: 0 12px; box-shadow: none; font-weight: 500; }
.chip-row { display: flex; gap: 8px; }
.chip-wrap { display: flex; flex-wrap: wrap; gap: 8px; }
.chip .fish-ic { color: var(--brand-ink); }
.tag {
  display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: var(--pill);
  font-size: 0.78rem; font-weight: 600; background: var(--surface-2); color: var(--ink-2); border: 1px solid var(--line); white-space: nowrap;
}
.tag-danger { background: var(--danger-bg); color: var(--danger-ink); border-color: var(--danger-line); }
.tag-caution { background: var(--caution-bg); color: var(--caution-ink); border-color: var(--caution-line); }
.mini-title { font-size: 0.8rem; font-weight: 700; color: var(--ink-3); text-transform: uppercase; letter-spacing: 0.05em; display: flex; align-items: center; gap: 6px; }
.hscroll {
  overflow-x: auto; overflow-y: hidden; overscroll-behavior-x: contain; scrollbar-width: none;
  -webkit-overflow-scrolling: touch; scroll-padding-inline: 16px;
}
.hscroll::-webkit-scrollbar { display: none; }
@media (hover: hover) and (pointer: fine) {
  .hscroll { scrollbar-width: thin; scrollbar-color: var(--line) transparent; padding-bottom: 6px; }
  .hscroll::-webkit-scrollbar { display: block; height: 6px; }
  .hscroll::-webkit-scrollbar-thumb { background: var(--line); border-radius: 3px; }
}
.spin { animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Segmented control */
.seg { display: inline-flex; padding: 3px; gap: 3px; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--pill); }
.seg button {
  flex: 1; min-height: 40px; padding: 0 14px; border-radius: var(--pill); display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  font-weight: 650; font-size: 0.95rem; color: var(--ink-2); white-space: nowrap; transition: background 0.15s, color 0.15s;
}
.seg button[aria-checked="true"] { background: var(--surface); color: var(--ink); box-shadow: 0 1px 3px rgba(14, 26, 36, 0.16), 0 0 0 1px var(--line); }
:root[data-theme="dark"] .seg button[aria-checked="true"] { background: var(--brand-soft); color: #fff; box-shadow: 0 0 0 1px var(--brand); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .seg button[aria-checked="true"] { background: var(--brand-soft); color: #fff; box-shadow: 0 0 0 1px var(--brand); } }
.seg-sm button { min-height: 38px; padding: 0 12px; font-size: 0.88rem; }
.seg-block { display: flex; width: 100%; }

/* Band visuals */
.band-dot {
  flex: none; width: 20px; height: 20px; border-radius: 50%; display: inline-grid; place-items: center;
  background: var(--band, var(--muted)); color: #0e1a24;
}
.band-dot svg { stroke-width: 3; }
.band-dot-lg { width: 26px; height: 26px; }
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px 4px 4px; border-radius: var(--pill); background: var(--band-tint); color: var(--ink); white-space: nowrap; }
.badge-num { font-weight: 800; font-size: 1.05rem; letter-spacing: -0.01em; }
.badge-label { font-weight: 650; font-size: 0.92rem; }
.badge-lg { padding: 5px 12px 5px 5px; }
.badge-lg .band-dot { width: 26px; height: 26px; }
.badge-lg .badge-num { font-size: 1.25rem; }
.badge-lg .badge-label { font-size: 1rem; }
.badge-sm { padding: 2px 8px 2px 2px; gap: 4px; }
.badge-sm .band-dot { width: 16px; height: 16px; }
.badge-sm .badge-num { font-size: 0.85rem; }
.meter { display: block; height: 5px; border-radius: 3px; background: var(--band-tint); overflow: hidden; }
.meter > span { display: block; height: 100%; border-radius: 3px; background: var(--band); }
.chance { display: inline-flex; align-items: center; gap: 6px; padding: 3px 9px; border-radius: var(--pill); font-size: 0.82rem; font-weight: 700; white-space: nowrap; }
.chance::before { content: ""; width: 9px; height: 9px; border-radius: 50%; }
.chance b { font-weight: 800; padding-left: 6px; border-left: 1px solid currentColor; opacity: 0.85; }
.chance-hi { background: var(--ok-bg); color: var(--ink); }
.chance-hi::before { background: #0ca30c; }
.chance-mid { background: var(--caution-bg); color: var(--ink); }
.chance-mid::before { background: #fab219; }
.chance-lo { background: var(--surface-2); color: var(--ink-2); border: 1px solid var(--line); }
.chance-lo::before { background: var(--muted); }
.chip-lvl { display: inline-flex; align-items: center; gap: 5px; font-size: 0.78rem; font-weight: 700; color: var(--ink-2); }
.chip-lvl::before { content: ""; width: 10px; height: 10px; border-radius: 3px; background: var(--lvl-0); }
.chip-lvl.lvl-1::before { background: var(--lvl-1); }
.chip-lvl.lvl-2::before { background: var(--lvl-2); }
.chip-lvl.lvl-3::before { background: var(--lvl-3); }

/* Skeleton */
.skel { display: block; background: var(--skel); border-radius: 8px; position: relative; overflow: hidden; }
.skel::after { content: ""; position: absolute; inset: 0; transform: translateX(-100%); background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.35), transparent); animation: shimmer 1.3s infinite; }
@keyframes shimmer { to { transform: translateX(100%); } }
.skel-badge { width: 112px; height: 36px; border-radius: var(--pill); }
.skel-badge-sm { width: 64px; height: 30px; border-radius: var(--pill); }
.skel-lines { flex: 1; display: grid; gap: 8px; }
.skel-line { height: 12px; width: 100%; }
.skel-line.short { width: 60%; }

/* ---------- Bottom sheet ---------- */
.sheet {
  position: absolute; z-index: 30; left: 0; right: 0; top: 0;
  height: 100%;
  display: flex; flex-direction: column;
  background: var(--bg);
  border-radius: 22px 22px 0 0;
  box-shadow: var(--shadow-3);
  transform: translate3d(0, 100vh, 0);
  will-change: transform;
  touch-action: auto;
}
.sheet.is-anim { transition: transform 0.36s var(--ease); }
.sheet-grab {
  position: absolute; z-index: 3; top: 0; left: 0; right: 0; height: 30px;
  display: grid; place-items: center; cursor: grab; border-radius: 22px 22px 0 0;
}
.sheet-grab::before { content: ""; width: 40px; height: 5px; border-radius: 3px; background: var(--line); }
.sheet.is-scrolled .sheet-grab { background: var(--bg); box-shadow: 0 1px 0 var(--line); }
:root[data-theme="dark"] .sheet-grab::before { background: #3a4d5d; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .sheet-grab::before { background: #3a4d5d; } }
.sheet-progress { position: absolute; z-index: 4; top: 0; left: 22px; right: 22px; height: 3px; overflow: hidden; border-radius: 2px; opacity: 0; transition: opacity 0.2s; }
.sheet-progress::after { content: ""; position: absolute; top: 0; bottom: 0; width: 40%; background: var(--brand-2); border-radius: 2px; animation: indet 1.1s var(--ease) infinite; }
.sheet.is-busy .sheet-progress { opacity: 1; }
@keyframes indet { from { left: -40%; } to { left: 100%; } }
.sheet-scroll {
  flex: 1; min-height: 0; overflow-x: hidden; overflow-y: hidden; overscroll-behavior: contain;
  border-radius: 22px 22px 0 0;
}
.sheet.is-full .sheet-scroll, .sheet.is-scrollable .sheet-scroll { overflow-y: auto; -webkit-overflow-scrolling: touch; }
.sheet-body { padding-bottom: calc(var(--safe-b) + 24px); min-height: 100%; }
/* Open but not full: the sheet's lower part is below the screen edge (sheet.js --sheet-hidden), pad by that much so
   the last card can still scroll into view. */
.sheet.is-scrollable:not(.is-full) .sheet-body { padding-bottom: calc(var(--safe-b) + 24px + var(--sheet-hidden, 0px)); }
.sheet.is-busy .dimmable { opacity: 0.45; pointer-events: none; transition: opacity 0.2s; }

/* Sheet header (section 1) */
.sec-top { background: var(--surface); padding: 26px 16px 14px; border-bottom: 1px solid var(--line); border-radius: 22px 22px 0 0; }
.head-top { display: flex; align-items: flex-start; gap: 8px; }
.head-titles { flex: 1; min-width: 0; padding-top: 2px; }
.place-name {
  font-size: 1.35rem; line-height: 1.2; font-weight: 750; letter-spacing: -0.01em; overflow-wrap: anywhere;
  display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; overflow: hidden;
}
.place-sub { margin-top: 2px; font-size: 0.85rem; color: var(--ink-3); overflow-wrap: anywhere; }
.head-actions { display: flex; gap: 2px; margin: -4px -8px 0 0; }
.place-note { display: flex; gap: 6px; align-items: flex-start; margin-top: 12px; font-size: 0.82rem; color: var(--ink-2); background: var(--info-bg); padding: 7px 10px; border-radius: 10px; }
.place-note svg { margin-top: 2px; color: var(--brand-ink); }
.summary { display: flex; align-items: center; gap: 10px; margin-top: 12px; width: 100%; min-height: 44px; border-radius: 12px; }
.summary-text { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; font-size: 0.95rem; color: var(--ink-2); min-width: 0; }
.summary-text b { color: var(--ink); white-space: nowrap; }
.summary.is-loading { pointer-events: none; }
.summary-chev { margin-left: auto; color: var(--ink-3); display: grid; place-items: center; transition: opacity 0.2s; }
.sheet:not([data-state="peek"]):not([data-state="closed"]) .summary-chev { opacity: 0; }
.summary-error { align-items: center; flex-wrap: wrap; }
.summary-error .summary-text { flex: 1 1 160px; color: var(--ink); }
.error-dot { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--danger-bg); color: var(--danger-ink); flex: none; }
.btn-sm { min-height: 40px; padding: 0 14px; font-size: 0.92rem; }
.loading-note { display: flex; align-items: center; gap: 8px; margin-top: 12px; color: var(--ink-3); font-size: 0.9rem; }
.fish-row { display: flex; gap: 6px; margin-top: 10px; overflow: hidden; flex-wrap: wrap; max-height: 44px; }
/* Hit areas: keep visuals compact but every control reaches 44 px. */
.seg button, .others .chip, .hazard .link, .toast-btn { position: relative; }
.seg button::after, .others .chip::after, .hazard .link::after, .toast-btn::after { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 44px; transform: translateY(-50%); }
.mini-fish { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 12px 0 8px; border-radius: var(--pill); background: var(--surface-2); border: 1px solid var(--line); font-weight: 600; font-size: 0.9rem; color: var(--ink); }
.mini-fish .fish-ic { color: var(--brand-ink); }
.controls { display: flex; gap: 8px; margin-top: 14px; }
.controls .seg-mode { flex: 1 1 auto; min-width: 0; }
.controls .seg-mode button { padding: 0 8px; }
.controls .seg-water { flex: 0 0 auto; }
.controls .seg-water button { padding: 0 11px; }
.controls .seg button svg { color: var(--brand-ink); }
.controls .seg button[disabled] { opacity: 0.6; }
@media (max-width: 430px) {
  .controls .seg-mode svg { display: none; }
  .controls .seg-water button { padding: 0 9px; font-size: 0.86rem; }
}
@media (max-width: 339px) {
  .controls { flex-wrap: wrap; }
  .controls .seg-mode { flex-basis: 100%; }
}

/* Sections */
.sec { padding: 0 12px; margin-top: 18px; }
.sec-head { padding: 0 4px 10px; }
.sec-title { display: flex; align-items: center; gap: 8px; font-size: 1.12rem; font-weight: 750; letter-spacing: -0.01em; }
.sec-title svg { color: var(--brand-ink); }
.sec-sub { margin-top: 2px; font-size: 0.85rem; color: var(--ink-3); }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; box-shadow: var(--shadow-1); }
.banner { display: flex; align-items: center; gap: 8px; margin: 12px 12px 0; padding: 10px 14px; border-radius: 12px; font-size: 0.9rem; font-weight: 600; }
.banner-stale { background: var(--caution-bg); color: var(--ink); border: 1px solid var(--caution-line); }
.banner-stale svg { color: var(--caution-ink); }

/* Day strip (section 2) */
.sec-days { margin-top: 14px; padding: 0; }
.day-strip { display: flex; gap: 8px; padding: 2px 12px 4px; }
.day-chip {
  flex: none; width: 76px; display: flex; flex-direction: column; align-items: center; gap: 3px;
  padding: 10px 6px 9px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line);
  box-shadow: var(--shadow-1); transition: border-color 0.15s, background 0.15s, transform 0.12s var(--ease);
}
.day-chip:active { transform: scale(0.97); }
.day-chip.is-sel { border: 2px solid var(--brand); padding: 9px 5px 8px; background: var(--brand-soft); }
.day-name { font-size: 0.9rem; font-weight: 750; }
.day-date { font-size: 0.72rem; color: var(--ink-3); margin-top: -3px; }
.day-score b { font-size: 1.2rem; font-weight: 800; letter-spacing: -0.02em; }
.day-chip .meter { width: 44px; }
.day-wind { display: inline-flex; align-items: baseline; gap: 2px; font-size: 0.8rem; color: var(--ink-2); font-weight: 700; white-space: nowrap; }
.day-wind svg { align-self: center; margin-right: 1px; }
.day-wind small { font-size: 0.68rem; font-weight: 600; color: var(--ink-3); }
.day-wind svg { color: var(--ink-3); }

/* Verdict (section 3) */
.verdict { padding: 18px; background: linear-gradient(180deg, var(--band-tint), rgba(0, 0, 0, 0) 62%), var(--surface); }
.verdict-top { display: flex; align-items: center; gap: 16px; }
.ring { position: relative; flex: none; width: 104px; height: 104px; }
.ring svg { display: block; }
.ring-track { fill: none; stroke: var(--band-tint); stroke-width: 9; }
.ring-fill { fill: none; stroke: var(--band); stroke-width: 9; stroke-linecap: round; transition: stroke-dasharray 0.6s var(--ease); }
.ring-num { position: absolute; inset: 0; display: grid; place-items: center; font-size: 2.6rem; font-weight: 800; letter-spacing: -0.04em; }
.verdict-titles { min-width: 0; }
.verdict-q { font-size: 0.8rem; font-weight: 700; color: var(--ink-3); text-transform: uppercase; letter-spacing: 0.05em; }
.verdict-label { display: flex; align-items: center; gap: 8px; margin-top: 4px; font-size: 1.25rem; font-weight: 800; line-height: 1.2; letter-spacing: -0.01em; }
.verdict-when { margin-top: 4px; font-size: 0.85rem; color: var(--ink-2); }
.verdict-headline { margin-top: 14px; font-size: 1.02rem; line-height: 1.5; color: var(--ink); }
.windows { margin-top: 16px; }
.window-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.window {
  flex: 0 1 auto; min-width: 138px; display: grid; gap: 2px; padding: 10px 12px; border-radius: 14px; min-height: 44px;
  background: var(--surface-2); border: 1px solid var(--line); text-align: left; transition: border-color 0.15s, background 0.15s;
}
.window:hover { border-color: var(--brand); }
.window-label { font-size: 0.78rem; font-weight: 700; color: var(--ink-3); text-transform: uppercase; letter-spacing: 0.04em; }
.window-time { font-size: 1.08rem; font-weight: 750; }
.window .badge { justify-self: start; margin-top: 4px; }
.safety { display: flex; gap: 12px; align-items: flex-start; margin-top: 14px; padding: 12px 14px; border-radius: 14px; border: 1px solid; }
.safety-caution { background: var(--caution-bg); border-color: var(--caution-line); }
.safety-caution .safety-ic { color: var(--caution-ink); }
.safety-danger { background: var(--danger-bg); border-color: var(--danger-line); }
.safety-danger .safety-ic { color: var(--danger-ink); }
.safety-title { font-weight: 750; }
.safety-list { margin-top: 4px; padding-left: 18px; font-size: 0.92rem; color: var(--ink-2); }
.safety p + p { margin-top: 2px; font-size: 0.92rem; color: var(--ink-2); }

/* Hour strip (section 4) */
.hours-card { padding: 12px 0 10px; }
.hours-wrap { display: flex; }
.hour-legend {
  flex: none; width: 34px; display: flex; flex-direction: column; align-items: center; padding: 6px 0;
  color: var(--ink-3); border-right: 1px solid var(--line);
}
.hours { flex: 1; min-width: 0; display: flex; gap: 6px; padding: 0 10px 0 8px; scroll-snap-type: x proximity; }
.hour {
  position: relative; flex: none; width: 58px; display: flex; flex-direction: column; align-items: center; padding: 6px 0;
  border-radius: 14px; border: 1px solid transparent; scroll-snap-align: center; transition: background 0.15s, border-color 0.15s;
}
.hour:hover { background: var(--surface-2); }
.hour.is-sel { background: var(--brand-soft); border: 2px solid var(--brand); padding: 5px 0; }
.hour.is-past > :not(.h-flag) { opacity: 0.45; }
.hour.is-now .h-time { color: var(--brand-ink); }
.h-time, .l-time { height: 22px; display: flex; align-items: center; font-size: 0.85rem; font-weight: 750; }
.h-score, .l-score { height: 34px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; }
.h-score b { font-size: 1rem; font-weight: 800; line-height: 1; }
.h-score .meter { width: 34px; height: 4px; }
.h-wx, .l-wx { height: 32px; display: flex; align-items: center; justify-content: center; }
.h-temp, .l-temp, .h-wind, .l-wind, .h-wave, .l-wave, .h-water, .l-water { height: 24px; display: flex; align-items: center; justify-content: center; gap: 2px; font-size: 0.85rem; font-variant-numeric: tabular-nums; }
.h-temp { font-weight: 700; }
.h-wind svg { color: var(--ink-2); }
.h-wave, .h-water { color: var(--ink-2); }
.h-flag { position: absolute; top: 4px; right: 4px; display: grid; place-items: center; }
.h-flag-danger { color: var(--danger-ink); }
.h-flag-caution { color: var(--caution-ink); }
.hours-note { padding: 8px 14px 0; font-size: 0.78rem; color: var(--ink-3); }
.hours-data { display: flex; gap: 6px; align-items: flex-start; padding-top: 6px; }
.hours-data svg { flex: none; margin-top: 1px; color: var(--brand-ink); }

/* Selected hour (section 5) */
.hour-card-top { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.hour-when { font-size: 0.92rem; font-weight: 600; color: var(--ink-2); }
.hour-card .safety { margin-top: 12px; }
.tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 14px; }
.tile { background: var(--surface-2); border: 1px solid var(--line); border-radius: 14px; padding: 12px; min-width: 0; }
.tile-label { display: flex; align-items: center; gap: 6px; font-size: 0.8rem; font-weight: 700; color: var(--ink-3); }
.tile-label svg { color: var(--brand-ink); }
.tile-value { margin-top: 4px; font-size: 1.4rem; font-weight: 800; letter-spacing: -0.02em; line-height: 1.15; }
.tile-extra { margin-top: 2px; font-size: 0.85rem; font-weight: 600; color: var(--ink); line-height: 1.35; }
.tile-extra svg { display: inline-block; vertical-align: -3px; margin-right: 4px; color: var(--ink-2); }
.tile-meta { margin-top: 2px; font-size: 0.8rem; color: var(--ink-3); }
.tile-text { margin-top: 8px; font-size: 0.85rem; line-height: 1.4; color: var(--ink-2); }
.why { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); }
.why-title { font-size: 1rem; font-weight: 750; margin-bottom: 8px; }
.factors { list-style: none; display: grid; gap: 8px; }
.factor { display: flex; gap: 10px; align-items: flex-start; font-size: 0.93rem; color: var(--ink-2); }
.factor.is-strong { color: var(--ink); font-weight: 600; }
.factor-ic { flex: none; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; margin-top: 0; }
.factor-ic svg { stroke-width: 3; }
.factor-pos .factor-ic { background: #0ca30c; color: #fff; }
.factor-neg .factor-ic { background: #d03b3b; color: #fff; }
.factor-neu .factor-ic { background: var(--line); color: var(--ink-2); }
.why-note { display: flex; align-items: center; gap: 6px; margin-top: 12px; font-size: 0.78rem; color: var(--ink-3); }
.why-note .band-dot { width: 16px; height: 16px; }

/* Fish (section 6) */
.fish-list { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; }
.fish-tags .tag { white-space: normal; text-align: left; }
.fish-card {
  width: 100%; display: flex; gap: 12px; align-items: flex-start; padding: 12px; background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-1); transition: border-color 0.15s, transform 0.12s var(--ease);
}
.fish-card:hover { border-color: var(--brand); }
.fish-card:active { transform: scale(0.99); }
.fish-pic { flex: none; width: 76px; height: 56px; display: grid; place-items: center; border-radius: 14px; background: var(--brand-soft); color: var(--brand-ink); }
.fish-pic-sm { width: 64px; height: 46px; border-radius: 12px; }
.fish-body { flex: 1; min-width: 0; display: grid; gap: 6px; }
.fish-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.fish-name { font-size: 1.08rem; font-weight: 750; }
.fish-reason { font-size: 0.88rem; color: var(--ink-2); line-height: 1.4; }
.fish-methods { display: flex; flex-wrap: wrap; gap: 6px; }
.mchip { display: inline-flex; align-items: center; padding: 2px 9px; border-radius: var(--pill); font-size: 0.8rem; font-weight: 650; background: var(--brand-soft); color: var(--brand-ink); }
.fish-foot { display: flex; align-items: center; justify-content: space-between; gap: 6px 8px; flex-wrap: wrap; }
.fish-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.fish-tags:empty { display: none; }
.fish-more { display: inline-flex; align-items: center; gap: 2px; margin-left: auto; font-size: 0.88rem; font-weight: 700; color: var(--brand-ink); white-space: nowrap; }
.more-fish > summary { list-style: none; display: flex; align-items: center; justify-content: center; gap: 6px; min-height: 48px; border-radius: var(--radius); border: 1px dashed var(--line); color: var(--brand-ink); font-weight: 700; cursor: pointer; background: var(--surface); }
.more-fish > summary::-webkit-details-marker { display: none; }
.more-fish[open] > summary { margin-bottom: 10px; }
.more-fish[open] > summary svg { transform: rotate(180deg); }
.more-fish[open] .if-closed, .more-fish:not([open]) .if-open { display: none; }
.fish-ic .fin { opacity: 0.68; }
.empty-card { display: flex; gap: 12px; align-items: center; color: var(--ink-2); }
.empty-card svg { color: var(--ink-3); }
.hazard { display: flex; gap: 12px; margin-top: 12px; padding: 12px 14px; border-radius: var(--radius); background: var(--danger-bg); border: 1px solid var(--danger-line); }
.hazard-ic { color: var(--danger-ink); }
.hazard-title { font-weight: 750; margin-bottom: 4px; }
.hazard ul { list-style: none; display: grid; gap: 4px; font-size: 0.92rem; color: var(--ink-2); }
.hazard .link { min-height: 32px; }
.others { margin-top: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.others summary { list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 52px; padding: 0 16px; font-weight: 700; cursor: pointer; }
.others summary::-webkit-details-marker { display: none; }
.others[open] summary svg { transform: rotate(180deg); }
.others > p, .others > .chip-wrap { padding: 0 16px 14px; }
.others .chip { min-height: 40px; padding: 0 10px 0 6px; box-shadow: none; }
.others .chip-lvl { padding-left: 4px; }

/* Charts (section 7): charts.css styles the inside */
.charts-card { padding: 12px 8px 8px; overflow: hidden; }
.charts-host { min-height: 120px; }

/* Sun & moon (section 8) */
.sm-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 10px; }
.sm-item { display: flex; gap: 10px; align-items: center; }
.sm-item svg { color: var(--accent); }
.sm-item span { display: grid; }
.sm-item small { font-size: 0.78rem; color: var(--ink-3); }
.sm-item b { font-size: 1.1rem; font-weight: 750; font-variant-numeric: tabular-nums; }
.moon-row { display: flex; gap: 14px; align-items: center; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
.moon-name { font-weight: 750; font-size: 1.05rem; }
.moon-text .small { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; margin-top: 4px; }
.moon-text .small svg { color: var(--ink-3); }
.moon-dark { fill: var(--moon-dark); }
.moon-lit { fill: var(--moon-lit); }
.moon-rim { stroke: var(--moon-rim); stroke-width: 0.6; }
.solunar { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
.sol-head { display: flex; justify-content: space-between; align-items: center; }
.sol-rating { display: inline-flex; gap: 2px; color: var(--line); }
.sol-rating .on { color: var(--accent); }
.daybar { position: relative; margin-top: 12px; }
.db-sky { position: relative; height: 22px; border-radius: 8px; overflow: hidden; background: var(--db-night); }
.db-seg { position: absolute; top: 0; bottom: 0; }
.db-night { background: var(--db-night); }
.db-twilight { background: var(--db-twilight); }
.db-day { background: var(--db-day); }
.db-lane { position: relative; height: 12px; margin-top: 4px; border-radius: 6px; background: var(--surface-2); border: 1px solid var(--line); }
.db-sol { position: absolute; top: 1px; bottom: 1px; border-radius: 4px; }
.db-major { background: var(--brand); }
.db-minor { background: var(--brand-2); opacity: 0.55; }
.db-now { position: absolute; top: 0; bottom: 0; width: 2px; margin-left: -1px; background: #d03b3b; }
.db-now span { position: absolute; top: 2px; left: 4px; font-size: 0.66rem; font-weight: 800; color: #fff; text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6); }
.db-sel { position: absolute; top: 0; bottom: 0; width: 3px; margin-left: -1.5px; background: var(--ink); opacity: 0.6; border-radius: 2px; }
.db-ticks { position: relative; height: 16px; margin-top: 2px; font-size: 0.7rem; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.db-ticks span { position: absolute; transform: translateX(-50%); }
.db-ticks span:first-child { transform: none; }
.db-ticks span:last-child { transform: translateX(-100%); }
.db-legend { display: flex; flex-wrap: wrap; gap: 4px 12px; margin-top: 6px; font-size: 0.75rem; color: var(--ink-3); }
.db-legend span { display: inline-flex; align-items: center; gap: 5px; }
.lg { display: inline-block; width: 12px; height: 8px; border-radius: 2px; }
.lg-day { background: var(--db-day); }
.lg-night { background: var(--db-night); }
.lg-major { background: var(--brand); }
.lg-minor { background: var(--brand-2); opacity: 0.55; }
.sol-list { list-style: none; display: grid; gap: 6px; margin: 12px 0 10px; font-size: 0.92rem; }
.sol-list li { display: flex; gap: 8px; align-items: baseline; flex-wrap: wrap; }
.sol-list b { font-variant-numeric: tabular-nums; }
.sol-kind { font-size: 0.72rem; font-weight: 800; padding: 1px 7px; border-radius: var(--pill); text-transform: uppercase; letter-spacing: 0.03em; }
.sol-major { background: var(--brand); color: var(--on-brand); }
.sol-minor { background: var(--brand-soft); color: var(--brand-ink); }

/* Weather icon tones */
.wx .wx-sun { fill: var(--wx-sun-fill); stroke: var(--wx-sun); }
.wx .wx-ray { stroke: var(--wx-sun); }
.wx .wx-moon { fill: var(--wx-moon-fill); stroke: var(--wx-moon); }
.wx .wx-cloud { fill: var(--wx-cloud-fill); stroke: var(--wx-cloud); }
.wx .wx-cloud-back { fill: var(--wx-cloud-back); }
.wx .wx-rain { stroke: var(--wx-rain); }
.wx .wx-dots { stroke-width: 2.6; }
.wx .wx-snow { stroke: var(--wx-snow); }
.wx .wx-bolt { fill: var(--wx-bolt-fill); stroke: var(--wx-bolt); stroke-width: 1.2; }
.wx .wx-fog { stroke: var(--wx-cloud); }

/* Footer (section 9) */
.foot { margin: 22px 12px 0; display: grid; gap: 14px; font-size: 0.9rem; color: var(--ink-2); }
.foot-warn { display: flex; gap: 10px; padding: 12px 14px; border-radius: 14px; background: var(--caution-bg); border: 1px solid var(--caution-line); color: var(--ink); }
.foot-warn svg { color: var(--caution-ink); margin-top: 2px; }
.foot-legal { padding: 14px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); display: grid; gap: 8px; }
.foot-legal ul { padding-left: 18px; display: grid; gap: 6px; }
.foot-legal-title { display: flex; align-items: center; gap: 8px; font-weight: 750; color: var(--ink); font-size: 1rem; }
.foot-legal-title svg { color: var(--brand-ink); }
.foot-legal-src { font-size: 0.8rem; color: var(--ink-3); }
.foot-src { font-size: 0.8rem; color: var(--ink-3); }

/* Welcome */
.welcome { background: var(--surface); padding: 30px 16px 16px; border-radius: 22px 22px 0 0; display: grid; gap: 14px; }
.welcome-title { font-size: 1.6rem; font-weight: 800; letter-spacing: -0.02em; }
.welcome-text { margin-top: 4px; color: var(--ink-2); line-height: 1.45; }
.welcome-last { font-size: 0.9rem; color: var(--ink-2); }
.welcome .chip-row { margin: 0 -16px; padding: 2px 16px 6px; }
.welcome .mini-title { margin-bottom: -4px; }
.spot-chip svg { color: var(--brand-ink); }

/* Error */
.error-card { margin: 12px; display: grid; gap: 10px; justify-items: center; text-align: center; padding: 22px 18px; }
.error-ic { width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; background: var(--danger-bg); color: var(--danger-ink); }
.error-card p { color: var(--ink-2); }

/* ---------- v2: hour-driven hero, hour slider, "Şu an" row, plan, focus, meralar ---------- */
.live-dot { flex: none; width: 8px; height: 8px; border-radius: 50%; background: #e0393e; animation: live 1.8s ease-out infinite; }
@keyframes live { 0% { box-shadow: 0 0 0 0 rgba(224, 57, 62, 0.5); } 70% { box-shadow: 0 0 0 7px rgba(224, 57, 62, 0); } 100% { box-shadow: 0 0 0 0 rgba(224, 57, 62, 0); } }

.hero {
  margin-top: 10px; padding: 10px 12px; border-radius: var(--radius); border: 1px solid var(--line);
  background: linear-gradient(180deg, var(--band-tint), rgba(0, 0, 0, 0) 75%), var(--surface-2);
}
.hero.is-danger { border-color: var(--danger-line); background: linear-gradient(180deg, var(--danger-bg), rgba(0, 0, 0, 0) 80%), var(--surface-2); }
.hero.is-caution { border-color: var(--caution-line); }
.hero.is-loading { background: var(--surface-2); }
.hero-main { display: flex; align-items: center; gap: 12px; }
.ring-hero { width: 60px; height: 60px; }
.ring-hero .ring-track, .ring-hero .ring-fill { stroke-width: 7; }
.ring-hero .ring-num { font-size: 1.55rem; letter-spacing: -0.03em; }
.hero-text { flex: 1; min-width: 0; display: grid; gap: 2px; }
.hero-when { display: flex; align-items: center; gap: 6px; font-size: 0.78rem; font-weight: 800; color: var(--ink-2); text-transform: uppercase; letter-spacing: 0.04em; }
.hero-when svg { color: var(--ink-3); }
.hero-past { font-size: 0.68rem; font-weight: 700; padding: 1px 7px; border-radius: var(--pill); background: var(--surface); border: 1px solid var(--line); color: var(--ink-3); text-transform: none; letter-spacing: 0; }
.hero-label { display: flex; align-items: baseline; gap: 7px; line-height: 1.2; min-width: 0; }
.hl-band { flex: none; font-size: 1.28rem; font-weight: 850; letter-spacing: -0.01em; }
.hl-word { font-size: 0.9rem; font-weight: 600; color: var(--ink-2); }
.hero-reason { display: flex; gap: 6px; align-items: flex-start; font-size: 0.88rem; line-height: 1.35; color: var(--ink-2); }
.hero-reason svg { flex: none; margin-top: 2px; stroke-width: 2.6; }
.hero-reason span { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; overflow: hidden; }
/* Two lines reserved: the hero keeps its height while the hour changes, so the sheet never jumps under the finger. */
.hero-reason { min-height: calc(2 * 1.35em); }
.hl-word { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.hr-pos svg { color: var(--pos-ink); }
.hr-neg svg { color: var(--danger-ink); }
.hr-neu svg { color: var(--ink-3); }
.hero-best, .hero-focus {
  margin-top: 8px; width: 100%; display: flex; align-items: center; gap: 8px; min-height: 44px; padding: 4px 8px 4px 10px;
  border-radius: 12px; background: var(--surface); border: 1px solid var(--line); text-align: left; font-size: 0.92rem; color: var(--ink-2);
  transition: border-color 0.15s;
}
.hero-best:hover, .hero-focus:hover { border-color: var(--brand); }
.hero-best b, .hero-focus b { color: var(--ink); font-weight: 800; }
.hero-best .badge, .hero-focus .band-dot { margin-left: auto; }
.hero-best.is-in { border-color: var(--band, #0ca30c); box-shadow: inset 0 0 0 1px var(--band, #0ca30c); }
.hero-best.hero-none { color: var(--ink-2); }
p.hero-best.hero-none { cursor: default; }
.hb-ic { display: grid; place-items: center; color: var(--accent); }
.hero-best.is-in .hb-ic { color: var(--ink); }
.hero-best.is-in[data-band="good"] .hb-ic, .hero-best.is-in[data-band="great"] .hb-ic { color: var(--pos-ink); }
.hb-text, .hf-text { min-width: 0; line-height: 1.3; }
.hero-focus { background: var(--brand-soft); border-color: var(--brand); }
/* With a fish focus, the fish line gives the best window for the chosen fish (the day's general windows stay in the plan). */
.hero-focus ~ .hero-best { display: none; }
.hf-pic { display: grid; place-items: center; color: var(--brand-ink); }
.skel-ring { flex: none; width: 60px; height: 60px; border-radius: 50%; }
.skel-slider { height: 58px; margin-top: 10px; border-radius: 12px; }

/* Hour slider: 24 score bars + scrubber */
.hs { display: grid; grid-template-columns: 44px minmax(0, 1fr) 44px; align-items: center; gap: 6px; margin-top: 8px; }
.hs-step {
  width: 44px; height: 48px; border-radius: 14px; display: grid; place-items: center;
  background: var(--surface-2); border: 1px solid var(--line); color: var(--ink); transition: transform 0.12s var(--ease), background 0.15s;
}
.hs-step:active { transform: scale(0.94); }
.hs-step:disabled { opacity: 0.35; }
.hs-track { position: relative; height: 58px; touch-action: pan-y; cursor: pointer; user-select: none; -webkit-user-select: none; border-radius: 10px; }
.hs-track:focus-visible { outline: 3px solid var(--brand-2); outline-offset: 3px; }
.hs-bars { position: absolute; left: 0; right: 0; top: 2px; height: 30px; display: flex; align-items: flex-end; gap: 2px; }
.hs-bar { flex: 1 1 0; min-width: 0; border-radius: 3px 3px 1px 1px; background: var(--band); opacity: 0.8; transition: opacity 0.15s; }
.hs-bar.is-past { opacity: 0.3; }
.hs-bar.is-sel { opacity: 1; }
.hs-bar.is-danger { background: repeating-linear-gradient(135deg, var(--band) 0 3px, rgba(255, 255, 255, 0.55) 3px 5px); }
.hs-now { position: absolute; top: -2px; bottom: -4px; width: 0; border-left: 2px dashed var(--ink-3); margin-left: -1px; pointer-events: none; }
.hs-base { position: absolute; left: 0; right: 0; top: 34px; height: 24px; border-top: 2px solid var(--line); }
.hs-tick, .hs-now-l { position: absolute; top: 5px; transform: translateX(-50%); font-size: 0.7rem; line-height: 1; color: var(--ink-3); font-variant-numeric: tabular-nums; white-space: nowrap; }
.hs-now-l { font-weight: 800; color: var(--ink-2); transition: opacity 0.12s; }
/* The knob already sits on the current hour (and the hero says "Şu an"): do not let it half-cover the label. */
.hs-now-l.is-under { opacity: 0; }
.hs-thumb { position: absolute; top: -36px; bottom: -2px; width: 34px; margin-left: -17px; pointer-events: none; transition: left 0.14s var(--ease); z-index: 1; }
.hs-track.is-drag .hs-thumb { transition: none; }
.hs-thumb::before { content: ""; position: absolute; left: 50%; top: 0; bottom: 22px; width: 2px; margin-left: -1px; border-radius: 1px; background: var(--ink); }
.hs-knob {
  position: absolute; left: 50%; bottom: 0; transform: translateX(-50%); min-width: 34px; height: 24px; padding: 0 5px; border-radius: 8px;
  display: grid; place-items: center; background: var(--ink); color: var(--surface); font: 800 0.8rem/1 var(--font); font-variant-numeric: tabular-nums;
  box-shadow: 0 2px 6px rgba(7, 16, 25, 0.3);
}

/* "Şu an" quick row */
.now-row { position: relative; margin-top: 14px; }
/* Label as a small tab on the row's top edge ("Şu an" / "Seçili saat · 06:00"): explicit without costing a line. */
.now-tab {
  position: absolute; z-index: 1; top: -9px; left: 10px; max-width: calc(100% - 20px); padding: 1px 8px; border-radius: var(--pill);
  background: var(--surface); border: 1px solid var(--line); color: var(--ink-2); font-size: 0.75rem; font-weight: 800;
  line-height: 1.4; text-transform: uppercase; letter-spacing: 0.05em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.now-row.is-now .now-tab { color: var(--danger-ink); border-color: var(--danger-line); }
.now-row .nc { padding-top: 11px; }
.now-title { display: flex; align-items: center; gap: 6px; margin: 0 2px 6px; font-size: 0.74rem; font-weight: 800; color: var(--ink-3); text-transform: uppercase; letter-spacing: 0.05em; }
.now-cells { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.nc { min-width: 0; display: grid; justify-items: center; gap: 1px; padding: 6px 2px 5px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line); text-align: center; }
.nc-top { display: inline-flex; align-items: center; gap: 4px; max-width: 100%; }
@media (max-width: 359px) {
  .nc-top { flex-direction: column; gap: 0; }
  .now-cells { gap: 4px; }
  .nc { padding-left: 0; padding-right: 0; }
  .nc-l { font-size: 0.66rem; letter-spacing: -0.01em; }
  .hl-word { display: none; }
  .ring.ring-hero, .ring.ring-hero svg { width: 56px; height: 56px; }
  .ring.ring-hero .ring-num { font-size: 1.4rem; }
  .hb-long { display: none; }
}
.hb-short { display: none; }
@media (max-width: 359px) { .hb-short { display: inline; } }
.nc-ic { flex: none; height: 22px; display: grid; place-items: center; color: var(--brand-ink); }
.nc-wind .nc-ic { color: var(--ink); }
.nc-v { font-size: 1rem; font-weight: 800; line-height: 1.15; white-space: nowrap; font-variant-numeric: tabular-nums; }
.nc-v small { margin-left: 2px; font-size: 0.66rem; font-weight: 650; color: var(--ink-3); }
.nc-l { max-width: 100%; font-size: 0.72rem; font-weight: 650; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.now-row.is-loading { min-height: 60px; }

/* Ocean model strip under the "Şu an" cells: current (big arrow) and the water at the fishing depth. */
.ocean-strip { margin-top: 6px; padding: 8px 10px 6px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line); }
.ocean-strip.is-warn { background: var(--caution-bg); border-color: var(--caution-line); }
.os-parts { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 6px 12px; }
.os-part { display: flex; align-items: center; gap: 8px; min-width: 0; }
.os-part > .ic { flex: none; color: var(--brand-ink); }
.os-arrow { flex: none; color: var(--brand-ink); }
.os-txt { display: grid; min-width: 0; line-height: 1.2; }
.os-l { font-size: 0.72rem; font-weight: 750; color: var(--ink-3); text-transform: uppercase; letter-spacing: 0.04em; }
.os-v { font-size: 1.15rem; font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; }
.os-v small { margin-left: 3px; font-size: 0.7rem; font-weight: 650; color: var(--ink-3); }
.os-w { font-size: 0.8rem; font-weight: 650; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.os-warn { display: flex; gap: 6px; align-items: flex-start; margin: 8px 0 0; font-size: 0.84rem; line-height: 1.35; color: var(--caution-ink); }
.os-warn .ic { flex: none; margin-top: 1px; }
.os-src { margin: 4px 0 0; font-size: 0.68rem; color: var(--ink-3); text-align: right; }

/* Fish of the hour (header), focus chip, mera notes */
.hfish { margin-top: 12px; }
.hfish .fish-row { margin-top: 6px; }
.hfish .fish-row { min-height: 44px; }
.hfish-empty { align-items: center; }
.mini-fish.is-focus { border: 2px solid var(--brand); background: var(--brand-soft); padding: 0 11px 0 7px; }
.sub-row { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; margin-top: 2px; }
.sub-row .place-sub { margin-top: 0; }
.focus-chip {
  position: relative; display: inline-flex; align-items: center; gap: 5px; min-height: 32px; padding: 0 4px 0 9px; border-radius: var(--pill);
  background: var(--brand); color: var(--on-brand); font-weight: 750; font-size: 0.86rem; white-space: nowrap;
}
.focus-chip .fish-ic { color: var(--on-brand); }
.focus-chip::after { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 44px; transform: translateY(-50%); }
.focus-x { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: rgba(255, 255, 255, 0.2); }
.mera-note { margin-top: 12px; display: grid; gap: 6px; padding: 10px 12px; border-radius: 12px; background: var(--info-bg); font-size: 0.88rem; line-height: 1.4; color: var(--ink-2); }
.mera-tip, .mera-known { display: flex; gap: 8px; align-items: flex-start; }
.mera-note svg { flex: none; margin-top: 2px; color: var(--brand-ink); }
.mera-known b { color: var(--ink); font-weight: 650; }
.tag-focus { background: var(--brand); color: var(--on-brand); border-color: transparent; }
.fish-card.is-focus { border: 2px solid var(--brand); padding: 11px; background: linear-gradient(180deg, var(--brand-soft), var(--surface) 75%); }

/* Day plan card */
.plan { padding: 16px; background: linear-gradient(180deg, var(--band-tint), rgba(0, 0, 0, 0) 45%), var(--surface); }
.plan-title { display: flex; align-items: center; gap: 8px; font-size: 1.12rem; font-weight: 800; letter-spacing: -0.01em; }
.plan-title svg { color: var(--brand-ink); }
.pl-list { list-style: none; display: grid; gap: 10px; margin-top: 12px; }
.pl-line { display: flex; gap: 10px; align-items: flex-start; font-size: 0.97rem; line-height: 1.45; }
.pl-line > span:last-child { padding-top: 4px; }
.pl-ic { flex: none; width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand-ink); }
.pl-warn .pl-ic { background: var(--caution-bg); color: var(--caution-ink); }
.plan .windows { margin-top: 14px; }
.plan-none { margin-top: 12px; }
.sec-days .sec-head { padding: 0 16px 10px; }

/* Species host view inside the sheet */
.host-head { display: flex; align-items: center; gap: 8px; padding: 26px 10px 10px 16px; background: var(--surface); border-bottom: 1px solid var(--line); border-radius: 22px 22px 0 0; }
.host-title { flex: 1; min-width: 0; display: flex; align-items: center; gap: 8px; font-size: 1.2rem; font-weight: 800; }
.host-title svg { color: var(--brand-ink); }
.host-body { min-height: 120px; }

/* Glossary terms and popover */
.gl {
  position: relative; display: inline-flex; align-items: baseline; gap: 3px; padding: 0; color: inherit; font: inherit; cursor: help;
  text-decoration: underline dotted; text-decoration-color: var(--ink-3); text-underline-offset: 3px; text-decoration-thickness: 1.5px;
}
.gl::after { content: ""; position: absolute; left: -4px; right: -4px; top: -4px; bottom: -4px; }
.tile-meta, .tile-extra { line-height: 1.5; }
.gl-q { display: inline-grid; place-items: center; width: 15px; height: 15px; border-radius: 50%; font-size: 10px; font-weight: 800; line-height: 1; background: var(--brand-soft); color: var(--brand-ink); text-decoration: none; transform: translateY(-1px); }
.gl[aria-expanded="true"] { color: var(--brand-ink); }
.gloss {
  position: absolute; z-index: 60; width: min(320px, calc(100% - 24px)); padding: 12px 14px 12px; background: var(--surface); color: var(--ink);
  border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow-2); font-size: 0.9rem; line-height: 1.45; animation: popIn 0.14s var(--ease);
}
.gp-title { display: flex; align-items: center; gap: 6px; font-weight: 800; margin-bottom: 4px; }
.gp-title svg { color: var(--brand-ink); }
.gp-text { color: var(--ink-2); }
.gloss-close { position: absolute; top: 4px; right: 4px; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; color: var(--ink-3); }

/* Map: "Balık seç" pill (second row under the search bar, left of the layers button) and meralar pins */
.map-cta {
  position: absolute; z-index: 24; left: calc(var(--safe-l) + 12px); top: calc(var(--safe-t) + 70px); max-width: calc(100% - 92px);
  display: flex; gap: 6px; align-items: center; pointer-events: none;
}
.map-cta > * { pointer-events: auto; }
.map-cta { transition: opacity 0.2s, visibility 0.2s; }
.app[data-sheet="half"] .map-cta, .app[data-sheet="full"] .map-cta { opacity: 0; visibility: hidden; }
.fish-pill {
  display: inline-flex; align-items: center; gap: 8px; min-height: 44px; max-width: 230px; padding: 0 18px 0 14px; border-radius: var(--pill);
  background: var(--brand); color: var(--on-brand); font-weight: 800; font-size: 1rem; box-shadow: var(--shadow-fab); white-space: nowrap;
  transition: transform 0.12s var(--ease);
}
.fish-pill:active { transform: scale(0.97); }
.fish-pill .emo { font-size: 1.15rem; line-height: 1; }
.fish-pill span { overflow: hidden; text-overflow: ellipsis; }
.fish-pill-x { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: var(--surface); color: var(--ink); box-shadow: var(--shadow-fab); }
.btn-fish { background: var(--brand-soft); color: var(--brand-ink); border: 1.5px solid var(--brand); font-weight: 750; }
.welcome-actions { display: grid; gap: 10px; }
.fish-cta { margin-top: 12px; white-space: normal; text-align: center; line-height: 1.25; padding-top: 6px; padding-bottom: 6px; }
.spot-wrap { display: grid; place-items: center; }
.spot-dot {
  width: 20px; height: 20px; border-radius: 50%; box-sizing: border-box; display: grid; place-items: center;
  background: #f59e0b; border: 3px solid #fff; box-shadow: 0 1px 4px rgba(0, 0, 0, .55), 0 0 0 1px rgba(120, 70, 0, .55);
}
.spot-dot::after { content: ''; width: 6px; height: 6px; border-radius: 50%; background: #fff; }
.spot-dot.is-fishing { background: #0b9a6e; box-shadow: 0 1px 4px rgba(0, 0, 0, .55), 0 0 0 1px rgba(0, 80, 55, .6); }
.leaflet-tooltip.spot-label { background: rgba(255, 255, 255, .95); color: #2f3b46; border: 1px solid rgba(0, 0, 0, .15); box-shadow: 0 1px 3px rgba(0, 0, 0, .25); padding: 1px 6px; font-size: 11.5px; font-weight: 600; }
.leaflet-tooltip.spot-label::before { display: none; }
.mera-pin { width: 44px; height: 44px; display: grid; place-items: center; }
.mera-dot {
  width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: #fff; color: #0b5e8e;
  border: 2px solid #0b5e8e; box-shadow: 0 1px 5px rgba(7, 16, 25, 0.35);
}
.mera-dot.is-fresh { color: #0b7a5a; border-color: #0b7a5a; }
.mera-pin.is-sel .mera-dot { background: #0b5e8e; color: #fff; }
.leaflet-tooltip.mera-label {
  background: rgba(255, 255, 255, 0.92); color: #0e1a24; border: 0; border-radius: 6px; padding: 1px 6px;
  box-shadow: 0 1px 3px rgba(7, 16, 25, 0.25); font: 700 11px/1.35 var(--font);
}
.leaflet-tooltip.mera-label::before { display: none; }
.zones .zone-mine { color: var(--ink); font-weight: 650; }
.banned .safety-title { font-size: 1.05rem; }

/* ---------- Overlays (modal sheets & drawer) ---------- */
.ovl { position: absolute; inset: 0; z-index: 50; }
.ovl-scrim { position: absolute; inset: 0; background: var(--scrim); opacity: 0; transition: opacity 0.28s var(--ease); }
.ovl.is-open .ovl-scrim { opacity: 1; }
.ovl-panel {
  position: absolute; inset: 0; display: flex; flex-direction: column; background: var(--bg); outline: none;
  transform: translate3d(0, 100%, 0); transition: transform 0.34s var(--ease); will-change: transform;
}
.ovl.is-open .ovl-panel { transform: none; }
.ovl-drawer .ovl-panel {
  left: auto; width: min(340px, 88%); border-radius: 22px 0 0 22px; background: var(--surface);
  transform: translate3d(105%, 0, 0); box-shadow: var(--shadow-2);
}
.ovl-drawer.is-open .ovl-panel { transform: none; }
.ovl-bar {
  flex: none; display: flex; align-items: center; gap: 4px;
  padding: calc(var(--safe-t) + 6px) calc(var(--safe-r) + 8px) 6px calc(var(--safe-l) + 6px);
  background: var(--surface); border-bottom: 1px solid var(--line); min-height: 56px;
}
.ovl-title { flex: 1; min-width: 0; font-size: 1.1rem; font-weight: 750; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ovl-body { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; padding: 16px 16px calc(var(--safe-b) + 32px); }
.ovl-drawer .ovl-bar { border-bottom: 0; background: transparent; }
.ovl-drawer .ovl-body { padding: 0 0 calc(var(--safe-b) + 16px); }
.ovl-grab { position: absolute; top: 0; left: 0; right: 0; height: 10px; }

/* Menu */
.menu { display: flex; flex-direction: column; min-height: 100%; }
.menu-brand { display: flex; gap: 12px; align-items: center; padding: 4px 20px 18px; }
.menu-brand b { display: block; font-size: 1.25rem; }
.menu-brand small { color: var(--ink-3); }
.menu-list { display: grid; padding: 0 10px; }
.menu-item { display: flex; align-items: center; gap: 14px; min-height: 64px; padding: 8px 10px; border-radius: 14px; text-align: left; }
.menu-item:hover { background: var(--surface-2); }
.menu-ic { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand-ink); flex: none; }
.menu-text { flex: 1; display: grid; min-width: 0; }
.menu-text small { color: var(--ink-3); font-size: 0.83rem; }
.menu-chev { color: var(--ink-3); }
.count { min-width: 24px; height: 24px; padding: 0 7px; border-radius: 12px; background: var(--brand); color: var(--on-brand); font-size: 0.8rem; font-weight: 800; display: grid; place-items: center; }
.menu-foot { margin-top: auto; padding: 20px; font-size: 0.9rem; }

/* Screens */
.screen-intro { margin-bottom: 10px; }
.empty { display: grid; justify-items: center; text-align: center; gap: 10px; padding: 40px 12px; color: var(--ink-2); }
.empty svg { color: var(--ink-3); }
.empty h3 { color: var(--ink); }
.fav-list { list-style: none; display: grid; gap: 10px; }
.fav-row { display: flex; align-items: center; gap: 4px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 4px 4px 4px 0; box-shadow: var(--shadow-1); }
.fav-main { flex: 1; min-width: 0; display: flex; align-items: center; gap: 12px; padding: 10px 6px 10px 14px; min-height: 64px; text-align: left; }
.fav-ic { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand-ink); flex: none; }
.fav-text { flex: 1; min-width: 0; display: grid; }
.fav-text b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fav-text small { color: var(--ink-3); font-size: 0.83rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fav-text .fav-best { display: flex; align-items: center; gap: 4px; color: var(--ink-2); font-weight: 600; }
.fav-score .badge-label { display: none; }
@media (min-width: 400px) { .fav-score .badge-label { display: inline; } }
.fav-del { color: var(--ink-3); }

.guide-controls { position: sticky; top: -16px; z-index: 2; margin: -16px -16px 0; padding: 12px 16px; background: var(--bg); display: grid; gap: 10px; }
.search-inline { height: 48px; border: 1px solid var(--line); box-shadow: none; }
.guide-filters { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.select-wrap { position: relative; display: inline-flex; align-items: center; }
.select-wrap select {
  appearance: none; -webkit-appearance: none; min-height: 44px; padding: 0 34px 0 14px; border-radius: var(--pill);
  border: 1px solid var(--line); background: var(--surface); font-weight: 600; font-size: 0.9rem; color: var(--ink);
}
.select-wrap svg { position: absolute; right: 10px; pointer-events: none; color: var(--ink-3); }
.list-title { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; font-size: 1rem; font-weight: 750; margin: 18px 4px 8px; }
.list-title small { font-weight: 500; color: var(--ink-3); font-size: 0.82rem; }
.list-title-danger { color: var(--danger-ink); align-items: center; }
.guide-ul { list-style: none; display: grid; gap: 8px; }
.guide-row { width: 100%; display: flex; align-items: center; gap: 12px; padding: 8px 12px 8px 8px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; text-align: left; min-height: 64px; }
.guide-row:hover { border-color: var(--brand); }
.guide-text { flex: 1; min-width: 0; display: grid; }
.guide-text small { color: var(--ink-3); font-size: 0.82rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.guide-meta { display: grid; justify-items: end; gap: 2px; text-align: right; }
.guide-meta small { color: var(--ink-3); font-size: 0.75rem; white-space: nowrap; }

.settings { display: grid; gap: 22px; }
.set-group { display: grid; gap: 8px; }
.set-title { font-size: 1rem; font-weight: 750; margin-top: 6px; }
.about { display: grid; gap: 12px; line-height: 1.55; color: var(--ink-2); }
.about h2 { color: var(--ink); font-size: 1.4rem; }
.about-brand { display: flex; gap: 14px; align-items: center; }
.about .set-title { color: var(--ink); }
.bullets { padding-left: 20px; display: grid; gap: 5px; }
.steps { padding-left: 22px; display: grid; gap: 6px; }
.steps-big { gap: 12px; font-size: 1.02rem; }
.steps-big svg { vertical-align: -3px; color: var(--brand-ink); }
.install-ios { display: grid; gap: 14px; }

/* Fish detail */
.fd { display: grid; gap: 18px; }
.fd-hero { display: grid; gap: 4px; padding: 0 0 4px; }
.fd-pic { width: 100%; height: 140px; display: grid; place-items: center; border-radius: 24px; background: var(--brand-soft); color: var(--brand-ink); margin-bottom: 10px; }
.fd-name { font-size: 1.7rem; font-weight: 800; letter-spacing: -0.02em; }
.fd-aka { color: var(--ink-2); }
.fd-latin { color: var(--ink-3); font-style: italic; font-size: 0.92rem; }
.fd-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.fd-about { margin-top: 10px; color: var(--ink-2); line-height: 1.55; }
.fd-hazard-note { color: var(--danger-ink); font-weight: 600; }
.fd-chance { display: grid; gap: 8px; }
.fd-chance-row { display: flex; }
.fd-sec .sec-head { padding: 0 0 10px; }
.fd-card { padding: 14px; }
.methods { display: grid; gap: 10px; }
.method { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.method summary { list-style: none; display: flex; align-items: center; gap: 8px; min-height: 54px; padding: 0 14px; cursor: pointer; }
.method summary::-webkit-details-marker { display: none; }
.method[open] summary > svg { transform: rotate(180deg); }
.method-name { font-weight: 750; flex: 1; }
.method-modes { font-size: 0.78rem; color: var(--ink-3); font-weight: 600; }
.method-body { padding: 0 14px 14px; display: grid; gap: 10px; }
.method-note { display: flex; gap: 8px; padding: 10px 12px; border-radius: 12px; background: var(--brand-soft); color: var(--ink); font-size: 0.93rem; }
.method-note svg { color: var(--brand-ink); margin-top: 2px; }
.kv { width: 100%; border-collapse: collapse; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; font-size: 0.93rem; }
.kv th, .kv td { padding: 10px 12px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.kv tr:last-child th, .kv tr:last-child td { border-bottom: 0; }
.kv th { width: 38%; color: var(--ink-3); font-weight: 600; }
.season-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
.season { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 3px; height: 92px; }
.sb-col { display: flex; flex-direction: column; justify-content: flex-end; align-items: stretch; gap: 4px; min-width: 0; }
.sb-col .sb-bar { display: block; border-radius: 4px 4px 1px 1px; min-height: 4px; }
.sb-m { font-size: 0.62rem; text-align: center; color: var(--ink-3); white-space: nowrap; overflow: hidden; }
.sb-col.is-now .sb-m { color: var(--ink); font-weight: 800; }
.sb-col.is-now .sb-bar { box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--ink); }
.sb-bar.lvl-0 { background: var(--lvl-0); }
.sb-bar.lvl-1 { background: var(--lvl-1); }
.sb-bar.lvl-2 { background: var(--lvl-2); }
.sb-bar.lvl-3 { background: var(--lvl-3); }
.season-now { margin-top: 10px; font-size: 0.92rem; }
.season-legend { display: flex; gap: 12px; margin-top: 8px; font-size: 0.75rem; color: var(--ink-3); }
.season-legend span { display: inline-flex; align-items: center; gap: 5px; }
.season-legend .lg { height: 10px; width: 10px; }
.fd-act-title { margin-top: 16px; }
.act { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 8px; }
.act-col { display: grid; gap: 4px; justify-items: center; }
.act-track { width: 100%; height: 48px; display: flex; align-items: flex-end; }
.act-track .sb-bar { width: 100%; border-radius: 6px 6px 2px 2px; }
.act-label { font-size: 0.78rem; color: var(--ink-2); font-weight: 600; }
.legal p { font-size: 0.95rem; }
.legal { display: grid; gap: 6px; }
.tips li { line-height: 1.45; }
.fd-sources ul { list-style: none; display: grid; gap: 4px; font-size: 0.82rem; margin-top: 6px; }
.fd-sources a { overflow-wrap: anywhere; }

/* ---------- Toasts ---------- */
.toasts {
  position: absolute; z-index: 90; left: 12px; right: 12px; top: calc(var(--safe-t) + 66px);
  display: grid; justify-items: center; gap: 8px; pointer-events: none;
}
.toast {
  pointer-events: auto; display: flex; align-items: center; gap: 12px; max-width: 100%;
  padding: 10px 10px 10px 16px; border-radius: 14px; background: #1d2b37; color: #fff;
  box-shadow: var(--shadow-2); font-size: 0.93rem; font-weight: 600;
  animation: toastIn 0.22s var(--ease);
}
.toast.is-out { animation: toastOut 0.2s var(--ease) forwards; }
.toast-btn { min-height: 36px; padding: 0 12px; border-radius: 10px; background: rgba(255, 255, 255, 0.14); color: #fff; font-weight: 750; white-space: nowrap; }
.toast-btn-primary { background: #5cc0e8; color: #04121c; }
@keyframes toastIn { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }
@keyframes toastOut { to { opacity: 0; transform: translateY(-8px); } }

/* ---------- No-JS ---------- */
.noscript { position: fixed; inset: 0; display: grid; place-items: center; padding: 24px; text-align: center; background: var(--bg); font-size: 1.1rem; z-index: 999; }

/* ---------- Motion preferences ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; scroll-behavior: auto !important; }
  .skel::after { display: none; }
}

/* ---------- Small phones ---------- */
@media (max-width: 359px) {
  .place-name { font-size: 1.22rem; }
  .seg button { padding: 0 10px; font-size: 0.9rem; }
  .ring { width: 92px; height: 92px; }
  .ring svg { width: 92px; height: 92px; }
  .ring-num { font-size: 2.25rem; }
  .verdict-label { font-size: 1.1rem; }
  .tiles { gap: 8px; }
  .tile { padding: 10px; }
  .tile-value { font-size: 1.22rem; }
}

/* v2 final: closed-season chip in "Sezonda olan diğer balıklar", error tips under the error header */
.chip-lvl.chip-ban { color: var(--danger-ink); }
.chip-lvl.chip-ban::before { background: var(--danger-ink); }
.error-tips { padding: 14px 16px; }
.error-tips .mini-title { display: flex; align-items: center; gap: 6px; }
.error-tips ul { margin: 8px 0 0; padding-left: 20px; display: grid; gap: 6px; color: var(--ink-2); font-size: 0.92rem; line-height: 1.4; }

/* Species list owns the map: its ranked markers need the strip above the sheet, so the wind legend steps aside. */
.app[data-species-list] .rg-wind-legend { display: none; }
/* The wind legend's help panel opens upward; the "Balık seç" pill must not cover its first row. */
.app.wind-help-open .map-cta { opacity: 0; visibility: hidden; }

/* ---------- v2 final: header order for beginners (verdict → hour → now → day → plan → fish → mera → controls) ---------- */
/* Kıyıdan ⇄ Tekneden next to the place line: always visible, even at peek. */
.mode-pill {
  position: relative; display: inline-flex; align-items: center; gap: 5px; min-height: 30px; padding: 0 10px 0 8px; border-radius: var(--pill);
  background: var(--surface-2); border: 1px solid var(--line); color: var(--ink); font-size: 0.84rem; font-weight: 750; white-space: nowrap;
}
.mode-pill svg { color: var(--brand-ink); }
.mode-pill .mp-swap { color: var(--ink-3); font-weight: 700; }
.mode-pill::after { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 44px; transform: translateY(-50%); }
.mode-pill:hover { border-color: var(--brand); }
/* Compact day row in the header */
.head-days { margin-top: 12px; }
.head-days-title { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 8px; }
.head-days-title span { font-weight: 600; text-transform: none; letter-spacing: 0; color: var(--ink-3); font-size: 0.74rem; }
.day-strip-sm { gap: 6px; margin: 6px -16px 0; padding: 2px 16px 4px; }
.day-chip.day-chip-sm { min-width: 58px; padding: 5px 6px 6px; gap: 2px; }
.day-chip.day-chip-sm.is-sel { padding: 4px 5px 5px; }
.day-sm-row { display: inline-flex; align-items: center; gap: 3px; }
.day-sm-row b { font-size: 1.05rem; font-weight: 800; letter-spacing: -0.02em; }
.day-chip-sm .meter { width: 38px; }
/* Plan in the header: first two lines, the rest behind "Planın tamamı" */
.head-plan { margin-top: 12px; }
.head-plan .plan { padding: 14px; box-shadow: none; border: 1px solid var(--line); }
.plan-compact .pl-list { margin-top: 10px; }
.plan-more > summary {
  list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 44px; margin-top: 8px;
  padding: 0 12px; border-radius: 12px; background: var(--surface-2); color: var(--brand-ink); font-weight: 750; font-size: 0.92rem; cursor: pointer;
}
.plan-more > summary::-webkit-details-marker { display: none; }
.plan-more > summary svg { flex: none; transition: transform 0.15s; }
.plan-more[open] > summary svg { transform: rotate(180deg); }
.plan-more[open] .if-closed, .plan-more:not([open]) .if-open { display: none; }
.plan-more .pl-list { margin-top: 10px; }
/* Mera tip: two lines until tapped */
details.mera-note > summary { list-style: none; cursor: pointer; }
details.mera-note > summary::-webkit-details-marker { display: none; }
details.mera-note > summary > svg:last-child { margin-left: auto; color: var(--ink-3); transition: transform 0.15s; }
details.mera-note[open] > summary > svg:last-child { transform: rotate(180deg); }
details.mera-note:not([open]) .mera-tip-text { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; overflow: hidden; }
details.mera-note .mera-known { margin-top: 6px; }
/* Species host title on one line (long fish names end in "…"). */
.host-title span { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 359px) { .host-title { font-size: 1.06rem; } .host-head { padding-top: 22px; } }

/* Dry land: no water at the tapped point — nearest sea, lakes and meralar instead of a forecast. */
.pin[data-band="none"] .pin-b { background: var(--ink-3); }
.summary-dry .summary-text { color: var(--ink); }
.summary-dry .summary-text b { white-space: normal; }
.summary-dry .error-dot { background: var(--surface-2); color: var(--ink-2); }
.dry-card { margin-top: 14px; display: grid; gap: 8px; }
.dry-list { display: grid; gap: 2px; margin: 0 -6px; }
.dry-item { width: 100%; min-height: 60px; }
.dry-km { flex: none; font-size: 0.85rem; font-weight: 700; color: var(--ink-2); white-space: nowrap; }
.dry-none { color: var(--ink-2); font-size: 0.92rem; line-height: 1.45; }
.dry-water { margin-top: 6px; border: 1.5px dashed var(--line); min-height: 48px; }
.dry-hint { font-size: 0.82rem; color: var(--ink-3); line-height: 1.4; }

/* ---------- Realism round: water notes, focus note, habitat question, blocked card, dry / outside cards ---------- */
/* One-card views (dry land, outside the map, blocked, error): the sheet keeps the card's surface, no grey below it. */
.sheet-body.is-solo { background: var(--surface); }
.sheet-body.is-solo .sec-top { border-bottom: 0; }
.half-end { height: 0; }

/* Notes about the water itself, above the hero (salt lake, drinking water, declared pond, open sea for a small boat) */
.wnote {
  display: flex; align-items: flex-start; gap: 8px; margin-top: 10px; padding: 9px 10px 9px 12px; border-radius: 12px;
  font-size: 0.88rem; line-height: 1.4; color: var(--ink); background: var(--info-bg); border: 1px solid transparent;
}
.wnote > svg { flex: none; margin-top: 1px; color: var(--brand-ink); }
.wnote p { flex: 1; min-width: 0; }
.wnote b { font-weight: 750; }
.wnote-caution { background: var(--caution-bg); border-color: var(--caution-line); }
.wnote-caution > svg { color: var(--caution-ink); }
.wnote-btn { flex: none; align-self: center; min-height: 44px; padding: 0 14px; background: var(--surface); }
.wnote-chip { align-items: center; padding: 6px 10px; background: var(--surface-2); border-color: var(--line); color: var(--ink-2); font-size: 0.84rem; font-weight: 650; }
.wnote-chip svg { color: var(--ink-3); }

/* A fish focus that does not live here (lüfer in a lake): why, and its meralar instead */
.fnote {
  display: flex; align-items: flex-start; gap: 10px; margin-top: 10px; padding: 10px 4px 10px 10px; border-radius: 14px;
  background: var(--caution-bg); border: 1px solid var(--caution-line);
}
.fnote-pic { flex: none; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; background: var(--surface); color: var(--caution-ink); }
.fnote-body { flex: 1; min-width: 0; display: grid; gap: 6px; }
.fnote-text { font-weight: 750; line-height: 1.35; }
.fnote-known { font-size: 0.86rem; color: var(--ink-2); }
.fnote-cta { justify-self: start; min-height: 44px; }
.fnote-x { flex: none; margin-top: -4px; }

/* "Burası nasıl bir yer?" for a sea shore without a known mera */
.hab { margin-top: 12px; }
.hab-hint { margin-top: 4px; font-size: 0.85rem; line-height: 1.4; color: var(--ink-2); }
.hab-row { margin: 6px -16px 0; padding: 2px 16px 4px; }
.hab-chip { box-shadow: none; }
.hab-chip.is-on { background: var(--brand); color: var(--on-brand); border-color: transparent; }

/* Blocked: no score where the angler cannot fish in this mode, or where there is nothing to fish */
.blocked {
  display: flex; gap: 12px; align-items: flex-start; margin-top: 14px; padding: 14px; border-radius: var(--radius);
  background: var(--surface-2); border: 1px solid var(--line);
}
.blocked-ic { flex: none; width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand-ink); }
.blocked-no-fish .blocked-ic, .blocked-banned .blocked-ic { background: var(--danger-bg); color: var(--danger-ink); }
.blocked-body { flex: 1; min-width: 0; }
.blocked-title { font-size: 1.12rem; font-weight: 800; line-height: 1.25; letter-spacing: -0.01em; }
.blocked-text { margin-top: 4px; font-size: 0.95rem; line-height: 1.45; color: var(--ink-2); }
.blocked-acts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.blocked-acts .btn { min-height: 44px; }

/* Dry land and outside cards: the way to say "there is water here" sits in the summary, visible at peek */
.summary-dry { align-items: flex-start; }
.dry-body { flex: 1; min-width: 0; display: grid; gap: 8px; }
.dry-say { font-size: 0.95rem; line-height: 1.4; color: var(--ink); }
.dry-say b { font-weight: 750; }
.summary-dry .dry-water {
  justify-self: start; min-height: 44px; margin-top: 0; border: 1.5px dashed var(--brand); background: var(--brand-soft); color: var(--brand-ink); font-weight: 700;
}
.dry-q { font-size: 1.02rem; font-weight: 800; line-height: 1.3; }
.dry-kinds { display: flex; flex-wrap: wrap; gap: 8px; }
.dry-kind { flex: 1 1 100%; min-height: 52px; justify-content: flex-start; padding: 0 18px; white-space: nowrap; }
.dry-kinds .btn-sm { min-height: 44px; }
.dry-cancel { justify-self: start; font-size: 0.92rem; }
.dry-card .btn-fish { margin-top: 4px; }

/* Search tags, favourites without a score, the hero's "tomorrow" and "why" lines */
.result .rtag { justify-self: start; margin-top: 2px; padding: 1px 8px; border-radius: var(--pill); font-size: 0.75rem; font-weight: 700; }
.rtag-ban { background: var(--danger-bg); color: var(--danger-ink); }
.rtag-caution { background: var(--caution-bg); color: var(--caution-ink); }
.fav-flag {
  display: inline-block; max-width: 7.5rem; padding: 3px 9px; border-radius: var(--pill); background: var(--surface-2); border: 1px solid var(--line);
  font-size: 0.8rem; font-weight: 700; color: var(--ink-2); text-align: center; line-height: 1.25;
}
.hero-best.hero-next .hb-ic { color: var(--brand-ink); }
.hb-go { margin-left: auto; display: inline-flex; align-items: center; gap: 2px; font-weight: 750; color: var(--brand-ink); white-space: nowrap; }
details.wnote-chip { display: block; padding: 0; }
details.wnote-chip > summary {
  list-style: none; display: flex; align-items: center; gap: 8px; min-height: 44px; padding: 4px 10px; cursor: pointer;
}
details.wnote-chip > summary::-webkit-details-marker { display: none; }
details.wnote-chip > summary > span { flex: 1; min-width: 0; }
details.wnote-chip > summary > svg:last-child { flex: none; transition: transform 0.15s; }
details.wnote-chip[open] > summary > svg:last-child { transform: rotate(180deg); }
details.wnote-chip > p { padding: 0 12px 10px 34px; font-weight: 500; color: var(--ink-2); }
.fish-other { display: flex; gap: 8px; align-items: flex-start; margin-top: 12px; padding: 0 4px; font-size: 0.88rem; line-height: 1.4; color: var(--ink-2); }
.fish-other svg { flex: none; margin-top: 2px; color: var(--brand-ink); }
.fish-other b { color: var(--ink); font-weight: 650; }
.blocked-acts .btn { flex-direction: column; gap: 0; line-height: 1.15; padding-top: 4px; padding-bottom: 4px; }
.blocked-acts .ba-km { font-size: 0.74rem; font-weight: 650; opacity: 0.85; }
.blocked-src { margin-top: 6px; font-size: 0.85rem; }
.blocked-src a { display: inline-flex; align-items: center; gap: 4px; min-height: 44px; color: var(--brand-ink); font-weight: 650; }

/* ---------- Extensions (2026-10-21): shared floating-button column + menu rows ---------- */
/* Column under the layers button: round 44 px icon buttons (Son avlar, Fırsatlar, Sohbet). Hover (desktop) or keyboard
   focus — and, once a day, a 3 s "peek" after the app opens — slides the text label out to the LEFT of the icon
   (.is-peek; never when ext/index.js finds no room: .no-expand). A button that would touch the wind legend, "Balık
   seç", the attribution or the sheet moves to a side slot (.is-side) or is tucked away (.is-tucked; it also has a
   menu row). */
.ext-fabs {
  position: absolute; z-index: 24; right: calc(var(--safe-r) + 12px); top: calc(var(--safe-t) + 122px);
  display: flex; flex-direction: column; align-items: flex-end; gap: 8px; pointer-events: none;
}
.ext-fabs > * { pointer-events: auto; transition: transform 0.15s var(--ease), opacity 0.2s, visibility 0.2s, padding 0.25s var(--ease); }
.ext-fabs > button {
  position: relative; display: inline-flex; flex-direction: row-reverse; align-items: center; justify-content: flex-start;
  height: 44px; min-width: 44px; padding: 0 11px; gap: 0; border-radius: var(--pill); white-space: nowrap;
}
.ext-fabs > button > svg, .ext-fabs > button > .ph-fab-ic { flex: none; display: grid; place-items: center; }
.ext-fabs .fab-label {
  display: inline-block; max-width: 0; opacity: 0; overflow: hidden; margin-right: 0;
  transition: max-width 0.26s var(--ease), opacity 0.2s, margin 0.26s var(--ease);
}
.ext-fabs > button.is-peek, .ext-fabs > button:not(.no-expand):focus-visible { padding-left: 14px; }
.ext-fabs > button.is-peek .fab-label, .ext-fabs > button:not(.no-expand):focus-visible .fab-label { max-width: 9em; opacity: 1; margin-right: 6px; }
@media (hover: hover) and (pointer: fine) {
  .ext-fabs > button:not(.no-expand):not(.is-side):hover { padding-left: 14px; }
  .ext-fabs > button:not(.no-expand):not(.is-side):hover .fab-label { max-width: 9em; opacity: 1; margin-right: 6px; }
}
.ext-fabs > .is-tucked { opacity: 0; visibility: hidden; transform: translateX(12px); pointer-events: none; }
.ext-fabs.fab-measure > * { transition: none !important; }
@media (prefers-reduced-motion: reduce) { .ext-fabs > *, .ext-fabs .fab-label { transition: none; } }
/* Rows that extensions add to the menu drawer share the menu's layout. */
.menu-ext { display: grid; }
.menu-ext > .menu-item { width: 100%; }
.ext-fabs > .is-side { position: absolute; top: var(--fab-side-top, 0); right: var(--fab-side-right, 52px); }

/* Professional mode (Açık deniz), sea depth and the weather-only view (SPEC §7.11) */
.seg-mode.seg-3 button { padding: 0 6px; gap: 5px; }
.seg-2l { display: inline-flex; flex-direction: column; align-items: flex-start; line-height: 1.05; }
.seg-2l small { font-size: 0.7rem; font-weight: 600; color: var(--ink-3); letter-spacing: 0.01em; }
.seg button[aria-checked="true"] .seg-2l small { color: var(--ink-2); }
.controls-both { flex-wrap: wrap; }
.controls-both .seg-mode { flex-basis: 100%; }
@media (max-width: 360px) {
  .seg-mode.seg-3 button { font-size: 0.86rem; padding: 0 4px; }
  .seg-2l small { font-size: 0.66rem; }
}
.settings .seg button { white-space: normal; line-height: 1.15; text-align: center; padding-top: 4px; padding-bottom: 4px; }
.mode-pill.is-pro { border-color: var(--brand); }
.place-depth { display: flex; align-items: center; gap: 6px; margin-top: 3px; font-size: 0.84rem; color: var(--ink-2); font-weight: 600; }
.place-depth svg { flex: none; color: var(--brand-ink); }
.pro-note p b { color: var(--ink); }
.pro-gear ul { margin: 0; padding: 0 12px 10px 34px; font-weight: 500; color: var(--ink-2); }
.wx-only-title { display: flex; align-items: center; gap: 8px; margin: 14px 4px 2px; font-weight: 750; font-size: 1rem; color: var(--ink); }
.wx-only-title svg { color: var(--brand-ink); }
.wx-only-sub { margin: 0 4px; font-size: 0.85rem; color: var(--ink-3); }
.wx-only { padding-bottom: 24px; }
.wx-only .sec:first-child { margin-top: 8px; }
.day-chip.is-wx-only .day-wind { display: inline-flex; align-items: center; gap: 2px; font-size: 0.78rem; color: var(--ink-2); font-weight: 650; }
.hours-card.is-wx-only .hour { padding-top: 8px; }
.btn.btn-ghost { background: transparent; border: 1px solid var(--line); color: var(--ink); }
.foot-pro { border-color: var(--brand); }
.foot-pro ul { margin: 0; padding-left: 18px; display: grid; gap: 6px; font-size: 0.88rem; color: var(--ink-2); }
.pro-more > summary { display: flex; align-items: center; gap: 4px; cursor: pointer; font-weight: 650; color: var(--brand-ink); min-height: 44px; list-style: none; }
.pro-more > summary::-webkit-details-marker { display: none; }
.pro-more[open] > summary svg { transform: rotate(180deg); }
.legal-pro { margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line); display: grid; gap: 6px; }
.legal-pro .mini-title { display: flex; align-items: center; gap: 6px; }
.legal-pro .mini-title svg { color: var(--brand-ink); }

/* Fish photos (fishpic.js): transparent WebP cut-outs on a soft tile; the silhouette shows when the photo is off. */
:root { --fpic-tile: radial-gradient(120% 95% at 50% 38%, #ffffff 0%, #e9f0f6 62%, #dbe6ef 100%); --fpic-shadow: drop-shadow(0 1.5px 2px rgba(14, 26, 36, 0.22)); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) { --fpic-tile: radial-gradient(120% 95% at 50% 38%, #3a5063 0%, #26394a 60%, #1b2c3a 100%); --fpic-shadow: drop-shadow(0 1.5px 2px rgba(0, 0, 0, 0.45)); }
}
:root[data-theme="dark"] { --fpic-tile: radial-gradient(120% 95% at 50% 38%, #3a5063 0%, #26394a 60%, #1b2c3a 100%); --fpic-shadow: drop-shadow(0 1.5px 2px rgba(0, 0, 0, 0.45)); }
.fpic { position: relative; align-self: stretch; justify-self: stretch; width: 100%; height: 100%; min-height: 100%; display: block; border-radius: inherit; background: var(--fpic-tile); overflow: hidden; }
.fpic-img { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; padding: 5% 6%; object-fit: contain; filter: var(--fpic-shadow); }
.fpic-lg .fpic-img { padding: 3% 4%; }
.fpic > .fpic-fb { display: none; position: absolute; inset: 0; margin: auto; }
.fpic.is-off { background: none; }
.fpic.is-off > .fpic-img { display: none; }
.fpic.is-off > .fpic-fb { display: block; }
.fd-pic-photo { height: auto; aspect-ratio: 2 / 1; max-height: 240px; margin-bottom: 4px; }
.fd-pic-photo:has(.fpic.is-off) { aspect-ratio: auto; height: 140px; }
.fd-credit { margin: 0 2px 8px; font-size: 0.74rem; line-height: 1.35; color: var(--ink-3); overflow-wrap: anywhere; }
.fd-credit a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }

/* Touch tooltips (tips.js): a tap on an info element / a long press on a button shows its title. */
.touch-tip {
  position: fixed; z-index: 2000; max-width: min(300px, calc(100vw - 24px)); padding: 8px 12px; border-radius: 10px;
  background: var(--ink); color: var(--surface); font-size: 0.86rem; font-weight: 600; line-height: 1.35;
  box-shadow: 0 6px 18px rgba(7, 16, 25, 0.3); pointer-events: none;
}
.touch-tip[hidden] { display: none; }
@media (hover: none) {
  button, .fab, [title] { -webkit-touch-callout: none; }
  button, .fab { -webkit-user-select: none; user-select: none; }
}

/* ---------- "Telefona yükle" card (welcome sheet + floating above the sheet, SPEC §5) ---------- */
.install-card {
  display: grid; grid-template-columns: auto 1fr; gap: 6px 12px; align-items: center; padding: 12px 12px 10px;
  background: var(--brand-soft); color: var(--ink); border: 1px solid var(--line); border-radius: var(--radius);
}
.install-card-ic svg, .install-card-ic img { display: block; width: 40px; height: 40px; border-radius: 11px; }
.install-card-text { display: grid; gap: 2px; min-width: 0; }
.install-card-text b { font-size: 0.98rem; }
.install-card-text small { color: var(--ink-2); font-size: 0.84rem; line-height: 1.35; }
.install-card-btns { grid-column: 1 / -1; display: flex; justify-content: flex-end; gap: 8px; flex-wrap: wrap; }
.install-card .btn { min-height: 44px; padding: 0 14px; font-size: 0.93rem; }
.install-card .btn-ghost { background: transparent; border-color: transparent; color: var(--ink-2); }
.install-card-float {
  position: absolute; z-index: 32; left: calc(var(--safe-l, 0px) + 10px); right: calc(var(--safe-r, 0px) + 10px);
  bottom: calc(var(--sheet-vis, 0px) + 10px); background: var(--surface); box-shadow: var(--shadow-2);
  animation: installIn 0.28s var(--ease);
}
.install-card-float[hidden] { display: none; }
@keyframes installIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .install-card-float { animation: none; } }
.install-note { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--brand-soft); }
.install-note svg { flex: none; color: var(--brand-ink); margin-top: 2px; }
.install-note p { margin: 0; font-size: 0.93rem; }
.set-link { width: 100%; border: 1px solid var(--line); background: var(--surface); }
