/* now.rsq.kr — location utilities. Mobile first, dark by default. */
:root {
  --bg: #060a12;
  --bg-2: #0a101c;
  --panel: #0d1523;
  --panel-2: #121c2e;
  --panel-3: #18243a;
  --line: rgba(140, 175, 230, 0.14);
  --line-2: rgba(140, 175, 230, 0.26);
  --txt: #e9f1ff;
  --txt-2: #b9c8df;
  --muted: #8497b4;
  --accent: #35e0b8;
  --accent-ink: #04241d;
  --accent-2: #6f9dff;
  --sun: #ffcf5c;
  --moon: #cfd9ff;
  --good: #4fdc8b;
  --warn: #ffb257;
  --bad: #ff7070;
  --info: #6fb6ff;
  --plum: #c79bff;
  --radius: 18px;
  --radius-s: 12px;
  --shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue",
    "Apple SD Gothic Neo", "Noto Sans KR", "Hiragino Sans", "Yu Gothic", sans-serif;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  color-scheme: dark;
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #f4f7fc;
    --bg-2: #eaf0f9;
    --panel: #ffffff;
    --panel-2: #f3f7fd;
    --panel-3: #e8effa;
    --line: rgba(16, 40, 80, 0.12);
    --line-2: rgba(16, 40, 80, 0.22);
    --txt: #0d1726;
    --txt-2: #2b3a50;
    --muted: #5d6f8a;
    --accent: #0b9f85;
    --accent-ink: #ffffff;
    --accent-2: #2f62d8;
    --sun: #c98a00;
    --moon: #5566aa;
    --good: #14915a;
    --warn: #b46a00;
    --bad: #c93a3a;
    --info: #1f6fd0;
    --plum: #7b3fd0;
    --shadow: 0 16px 40px rgba(20, 40, 80, 0.12);
    color-scheme: light;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 76px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--txt);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  /* Korean/CJK copy breaks at word boundaries and never mid-sentence */
  word-break: keep-all;
  overflow-wrap: break-word;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    radial-gradient(900px 480px at 82% -8%, rgba(111, 157, 255, 0.14), transparent 65%),
    radial-gradient(760px 420px at 6% 0%, rgba(53, 224, 184, 0.1), transparent 60%);
  pointer-events: none;
  z-index: -1;
}
@media (prefers-color-scheme: light) {
  body::before { opacity: 0.55; }
}
a { color: var(--accent-2); text-decoration: none; }
a:hover { text-decoration: underline; }
img, canvas, svg { max-width: 100%; }
h1, h2, h3, h4 { line-height: 1.22; margin: 0; letter-spacing: -0.015em; }
p { margin: 0; }
button, input, select { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
.skip { position: absolute; left: -9999px; top: 0; background: var(--accent); color: var(--accent-ink); padding: 10px 16px; z-index: 100; }
.skip:focus { left: 8px; top: 8px; }

/* ---------- in-app browser notice ---------- */
.inapp {
  background: color-mix(in srgb, var(--warn) 14%, var(--panel));
  border-bottom: 1px solid color-mix(in srgb, var(--warn) 34%, transparent);
  color: var(--txt);
  font-size: 12.5px;
  line-height: 1.45;
}
.inapp[hidden] { display: none; }
.inapp-in {
  max-width: 1220px;
  margin: 0 auto;
  padding: 8px 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.inapp-msg { margin: 0; flex: 1 1 210px; min-width: 0; }
.inapp-msg > span { display: block; }
.inapp-hint { color: var(--txt-2); font-size: 11.5px; margin-top: 1px; }
.inapp-compact .inapp-msg > [data-i18n="inapp.msg"] { display: none; }
.inapp-compact .inapp-hint { font-size: 12px; color: var(--txt); margin-top: 0; }
.inapp-act { display: inline-flex; align-items: center; gap: 6px; flex: 0 0 auto; margin-left: auto; }
.inapp-btn {
  appearance: none;
  border: 1px solid color-mix(in srgb, var(--warn) 48%, var(--line-2));
  background: color-mix(in srgb, var(--warn) 18%, var(--panel-2));
  color: var(--txt);
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  padding: 6px 11px;
  border-radius: 9px;
  cursor: pointer;
  white-space: nowrap;
  -webkit-tap-highlight-color: transparent;
}
.inapp-btn:hover { background: color-mix(in srgb, var(--warn) 28%, var(--panel-2)); }
.inapp-x {
  flex: 0 0 auto;
  width: 26px;
  height: 26px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: color-mix(in srgb, var(--txt) 8%, transparent);
  color: var(--txt-2);
  font-size: 12px;
  line-height: 1;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.inapp-x:hover { background: color-mix(in srgb, var(--txt) 16%, transparent); }

/* ---------- header ---------- */
.hdr {
  position: sticky;
  top: 0;
  z-index: 40;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid var(--line);
}
.hdr-in {
  max-width: 1220px;
  margin: 0 auto;
  padding: 10px 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.brand { display: inline-flex; align-items: center; gap: 8px; color: var(--txt); text-decoration: none; flex: 0 0 auto; }
.menu-btn {
  display: none;
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  padding: 0;
  margin: 0 2px 0 -4px;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--txt);
  line-height: 1;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.menu-btn svg { display: block; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.menu-btn:hover { background: color-mix(in srgb, var(--txt) 8%, transparent); }
.menu-btn:active { background: color-mix(in srgb, var(--txt) 14%, transparent); }
body.drawer-open { overflow: hidden; }
.brand:hover { text-decoration: none; }
.brand-mark { color: var(--accent); font-size: 20px; line-height: 1; }
.brand-txt { font-weight: 800; letter-spacing: 0.02em; font-size: 17px; white-space: nowrap; }
.brand-txt i { font-style: normal; color: var(--muted); font-weight: 600; display: inline; }
.tools-nav {
  display: flex;
  gap: 4px;
  overflow-x: auto;
  scrollbar-width: none;
  padding: 2px;
  flex: 1 1 auto;
  min-width: 0;
  mask-image: linear-gradient(to right, transparent, #000 10px, #000 calc(100% - 10px), transparent);
}
.tools-nav::-webkit-scrollbar { display: none; }
.tools-nav a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 11px;
  border-radius: 999px;
  color: var(--txt-2);
  font-size: 13.5px;
  white-space: nowrap;
  border: 1px solid transparent;
}
.tools-nav a:hover { background: var(--panel-2); text-decoration: none; color: var(--txt); }
.tools-nav a.on { background: var(--panel-3); border-color: var(--line-2); color: var(--txt); }
.tools-nav a span[aria-hidden] { font-size: 14px; opacity: 0.9; }
.hdr-ctl { display: flex; align-items: center; gap: 8px; }
.loc-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  max-width: 160px;
  padding: 7px 12px;
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-radius: 999px;
  cursor: pointer;
  font-size: 13.5px;
  color: var(--txt);
}
button.loc-chip { font-weight: 500; }
.loc-chip:hover { border-color: var(--line-2); }
.loc-chip .pin { color: var(--accent); font-size: 13px; }
#locLabel { overflow: visible; text-overflow: clip; white-space: normal; word-break: keep-all; }
.langs { display: inline-flex; background: var(--panel-2); border: 1px solid var(--line); border-radius: 999px; padding: 2px; }
.langs button {
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 5px 8px;
  border-radius: 999px;
  cursor: pointer;
}
.langs button[aria-pressed="true"] { background: var(--accent); color: var(--accent-ink); }

@media (max-width: 900px) {
  .hdr-in { gap: 8px; padding: 8px 10px; }
  .menu-btn { display: inline-flex; }
  .tools-nav { display: none; }
  .brand-txt { font-size: 14px; }
  .brand { gap: 6px; }
  .brand-mark { font-size: 17px; }
  .hdr-ctl { margin-left: auto; gap: 6px; }
  .loc-chip { max-width: 116px; padding: 6px 10px; font-size: 12.5px; }
  .langs button { padding: 5px 7px; }
}
@media (max-width: 420px) {
  .hdr-in { gap: 6px; padding: 8px; }
  .brand { gap: 5px; }
  .brand-mark { font-size: 15px; }
  .brand-txt { font-size: 12.5px; letter-spacing: 0; }
  .menu-btn { width: 36px; margin: 0 0 0 -6px; }
  .loc-chip { max-width: 104px; padding: 6px 8px; font-size: 11.5px; gap: 4px; }
  .langs button { padding: 5px 6px; font-size: 11px; }
}

/* ---------- menu drawer ---------- */
.drawer { position: fixed; inset: 0; z-index: 60; }
.drawer-scrim {
  position: absolute;
  inset: 0;
  background: rgba(4, 7, 15, 0.62);
  backdrop-filter: blur(2px);
  animation: scrimIn 0.16s ease-out;
}
.drawer-panel {
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  width: min(84vw, 320px);
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 14px 14px calc(18px + env(safe-area-inset-bottom));
  background: var(--panel);
  border-right: 1px solid var(--line-2);
  box-shadow: 18px 0 40px rgba(0, 0, 0, 0.4);
  overflow-y: auto;
  animation: drawerIn 0.18s ease-out;
}
.drawer-head { display: flex; align-items: center; justify-content: space-between; padding: 4px 4px 10px; border-bottom: 1px solid var(--line); }
.drawer-head .brand-txt { font-size: 16px; }
.drawer-nav { display: flex; flex-direction: column; gap: 2px; padding: 6px 0; }
.drawer-nav a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 10px;
  border-radius: 12px;
  color: var(--txt-2);
  font-size: 14.5px;
}
.drawer-nav a:hover { background: var(--panel-2); color: var(--txt); text-decoration: none; }
.drawer-nav a.on { background: var(--panel-3); color: var(--txt); }
.drawer-nav a span[aria-hidden] { font-size: 16px; }
.drawer-foot { margin-top: auto; display: flex; gap: 14px; padding: 12px 10px 4px; border-top: 1px solid var(--line); font-size: 13px; }
@keyframes drawerIn { from { transform: translateX(-100%); } to { transform: translateX(0); } }
@keyframes scrimIn { from { opacity: 0; } to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .drawer-panel, .drawer-scrim { animation: none; } }

/* ---------- layout ---------- */
.wrap { max-width: 1180px; margin: 0 auto; padding: 22px 16px 40px; }
.narrow { max-width: 780px; }
.stack { display: flex; flex-direction: column; gap: 18px; }
.grid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }
.grid-2 { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.grid-4 { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); }
.row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.spread { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.mt { margin-top: 18px; }

/* ---------- hero ---------- */
.hero {
  border: 1px solid var(--line);
  border-radius: 26px;
  padding: clamp(20px, 4vw, 34px);
  background:
    radial-gradient(700px 300px at 88% 0%, rgba(111, 157, 255, 0.18), transparent 70%),
    radial-gradient(600px 320px at 0% 100%, rgba(53, 224, 184, 0.12), transparent 70%),
    linear-gradient(160deg, var(--panel-2), var(--panel));
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(160, 200, 255, 0.18) 1px, transparent 1px);
  background-size: 46px 46px;
  opacity: 0.25;
  pointer-events: none;
  mask-image: linear-gradient(to bottom, #000, transparent 70%);
}
.hero > * { position: relative; z-index: 1; }
.hero h1 { font-size: clamp(1.6rem, 4.6vw, 2.5rem); margin: 10px 0 6px; }
.hero > h1:first-child { margin-top: 0; }
.hero h1 em { font-style: normal; color: var(--accent); }
.hero-lede { color: var(--txt-2); max-width: 62ch; font-size: 15.5px; }
.hero-clock {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin: 20px 0 4px;
  flex-wrap: wrap;
}
.hero-time { font-size: clamp(2.6rem, 9vw, 4.2rem); font-weight: 800; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; line-height: 1; }
.hero-date { color: var(--muted); font-size: 14px; }
.hero-place { display: inline-flex; align-items: center; gap: 6px; color: var(--txt-2); font-size: 14.5px; }
.hero-place b { color: var(--txt); font-weight: 600; }
.hero-src { margin: 2px 0 0; font-size: 11.5px; color: var(--muted); letter-spacing: 0.01em; font-variant-numeric: tabular-nums; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.chip {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 7px;
  white-space: normal;
  padding: 8px 12px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--panel-3) 70%, transparent);
  border: 1px solid var(--line);
  font-size: 13px;
  color: var(--txt-2);
  font-variant-numeric: tabular-nums;
}
.chip b { color: var(--txt); font-weight: 650; }
.chip .ico { font-size: 14px; }
.chip.good b { color: var(--good); }
.chip.warn b { color: var(--warn); }
.chip.bad b { color: var(--bad); }

/* ---------- section ---------- */
.sec-h { display: flex; align-items: end; justify-content: space-between; gap: 12px; margin: 34px 0 14px; flex-wrap: wrap; }
.sec-h h2 { font-size: clamp(1.2rem, 3vw, 1.5rem); }
.sec-h p { color: var(--muted); font-size: 13.5px; }

/* ---------- cards ---------- */
.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px;
  min-width: 0;
}
.card.flat { background: var(--panel-2); }
.card h3 { font-size: 15px; color: var(--txt-2); font-weight: 650; }
.card-h { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.card-h .hint { font-size: 12px; color: var(--muted); }
.value { font-size: clamp(1.7rem, 5vw, 2.2rem); font-weight: 750; font-variant-numeric: tabular-nums; letter-spacing: -0.02em; }
.value small { font-size: 0.45em; font-weight: 600; color: var(--muted); margin-left: 4px; letter-spacing: 0; }
/* 다음 만조가 내일이면 앞에 붙는 작은 '내일' */
.value .tmrw { font-size: 0.42em; font-weight: 650; color: var(--muted); letter-spacing: 0; margin-right: 2px; vertical-align: 0.12em; }
.label { font-size: 12px; color: var(--muted); }
.sub { font-size: 13px; color: var(--txt-2); }

.tool-card {
  display: flex;
  flex-direction: column;
  align-content: start;
  gap: 8px;
  padding: 18px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--txt);
  transition: transform 0.15s ease, border-color 0.15s ease, background 0.15s ease;
  min-height: 152px;
}
.tool-card:hover { text-decoration: none; transform: translateY(-2px); border-color: var(--line-2); background: var(--panel-2); }
.tool-card .tc-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.tool-card .tc-ico { font-size: 24px; line-height: 1; }
.tool-card .tc-live { font-size: 12px; color: var(--accent); font-variant-numeric: tabular-nums; text-align: right; }
.tool-card h3 { font-size: 16.5px; font-weight: 700; color: var(--txt); }
/* card copy always wraps in full: no ellipsis, no line clamp, no cut sentences */
.tool-card p {
  font-size: 13.5px;
  color: var(--muted);
  line-height: 1.5;
  display: block;
  overflow: visible;
  white-space: normal;
  word-break: keep-all;
  overflow-wrap: anywhere;
  -webkit-line-clamp: unset;
  text-overflow: clip;
}
.hero-lede, .page-h .lede, .note, .sub, .hint { word-break: keep-all; overflow-wrap: anywhere; }
.tool-card .tc-go { margin-top: auto; font-size: 12.5px; color: var(--accent-2); font-weight: 600; }

/* ---------- controls ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 9px 15px;
  border-radius: 11px;
  border: 1px solid var(--line-2);
  background: var(--panel-2);
  color: var(--txt);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}
.btn:hover { background: var(--panel-3); }
.btn.primary { background: var(--accent); border-color: transparent; color: var(--accent-ink); }
.btn.primary:hover { filter: brightness(1.06); background: var(--accent); }
.btn.ghost { background: transparent; }
.btn.wide { width: 100%; }
.btn[disabled] { opacity: 0.5; cursor: not-allowed; }
.btn.danger { border-color: color-mix(in srgb, var(--bad) 50%, transparent); color: var(--bad); }

.seg { display: inline-flex; background: var(--panel-2); border: 1px solid var(--line); border-radius: 11px; padding: 3px; gap: 2px; flex-wrap: wrap; }
.seg button {
  border: 0;
  background: transparent;
  padding: 6px 11px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
}
.seg button[aria-pressed="true"] { background: var(--panel-3); color: var(--txt); box-shadow: inset 0 0 0 1px var(--line-2); }

input[type="number"], input[type="text"], input[type="search"], input[type="datetime-local"], select {
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 9px 11px;
  width: 100%;
  min-width: 0;
  color: var(--txt);
}
input::placeholder { color: var(--muted); }
select { appearance: none; background-image: none; }

/* ---------- page head ---------- */
.page-h { padding: 10px 0 0; }
.crumb { font-size: 12.5px; color: var(--muted); letter-spacing: 0.04em; text-transform: uppercase; font-weight: 600; }
.page-h h1 { font-size: clamp(1.7rem, 5vw, 2.4rem); margin: 8px 0 8px; }
.page-h .lede { color: var(--txt-2); max-width: 68ch; font-size: 15.5px; }
.page-h .ico { font-size: 0.85em; margin-right: 8px; }

/* ---------- tables ---------- */
.tbl { width: 100%; border-collapse: collapse; font-size: 14px; }
.tbl th {
  text-align: left;
  font-size: 11.5px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 650;
  padding: 6px 8px;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
.tbl td { padding: 9px 8px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.tbl .dim { color: var(--muted); }
.tbl-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }

/* ---------- bars / meters ---------- */
.bar { height: 8px; border-radius: 999px; background: var(--panel-3); overflow: hidden; }
.bar > i { display: block; height: 100%; border-radius: 999px; background: var(--accent); transition: width 0.4s ease; }
.bar.thin { height: 6px; }
.meter-row { display: grid; grid-template-columns: 84px 1fr 72px; align-items: center; gap: 10px; font-size: 13.5px; }
.meter-row .v { text-align: right; font-variant-numeric: tabular-nums; color: var(--txt-2); }
.pollen-point { color: var(--muted); font-size: 12.5px; }
.pollen-row { display: grid; grid-template-columns: 62px auto 1fr; align-items: center; gap: 10px; font-size: 13.5px; }
.pollen-row .v { text-align: right; color: var(--txt-2); font-size: 12.5px; }
.nb-notice { font-size: 12.5px; line-height: 1.65; color: var(--txt-2); background: var(--panel-2); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; }
@media (max-width: 420px) { .pollen-row { grid-template-columns: 52px auto 1fr; gap: 8px; font-size: 13px; } .pollen-row .v { font-size: 12px; } }

.pill { display: inline-block; padding: 3px 9px; border-radius: 999px; font-size: 12px; font-weight: 650; white-space: nowrap; }
.pill.good { background: color-mix(in srgb, var(--good) 16%, transparent); color: var(--good); }
.pill.warn { background: color-mix(in srgb, var(--warn) 16%, transparent); color: var(--warn); }
.pill.bad { background: color-mix(in srgb, var(--bad) 16%, transparent); color: var(--bad); }
.pill.info { background: color-mix(in srgb, var(--info) 16%, transparent); color: var(--info); }
.pill.mute { background: var(--panel-3); color: var(--muted); }

.help-list { margin: 8px 0 0 18px; padding: 0; display: grid; gap: 6px; font-size: 13px; color: var(--txt-2); line-height: 1.5; }
.help-list li { padding-left: 2px; }
.tide-chart { width: 100%; height: 220px; display: block; border-radius: 12px; background: var(--panel-2); }

/* ---------- misc blocks ---------- */
.note {
  border: 1px solid var(--line);
  border-left: 3px solid var(--accent-2);
  border-radius: 12px;
  background: var(--panel-2);
  padding: 13px 15px;
  font-size: 13.5px;
  color: var(--txt-2);
}
.note.warn { border-left-color: var(--warn); }
.note b { color: var(--txt); }
.notes { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); margin-top: 34px; }
.notes .card h3 { font-size: 14px; color: var(--txt); margin-bottom: 8px; }
.notes .card p, .notes .card li { font-size: 13.5px; color: var(--muted); }
.notes .card ul { margin: 0; padding-left: 18px; }
.sources { font-size: 12.5px; color: var(--muted); margin-top: 18px; }
.sources a { color: var(--muted); text-decoration: underline; text-underline-offset: 2px; }

.empty { color: var(--muted); font-size: 14px; padding: 10px 0; }
.spin { display: inline-block; width: 13px; height: 13px; border: 2px solid var(--line-2); border-top-color: var(--accent); border-radius: 50%; animation: spin 0.8s linear infinite; vertical-align: -2px; }
@keyframes spin { to { transform: rotate(360deg); } }
.err { color: var(--bad); font-size: 13.5px; }

/* ---------- modal ---------- */
.modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 16px;
  background: rgba(4, 8, 16, 0.68);
  backdrop-filter: blur(6px);
}
.modal[hidden] { display: none; }
.modal-card {
  width: min(520px, 100%);
  max-height: min(86vh, 720px);
  overflow-y: auto;
  background: var(--panel);
  border: 1px solid var(--line-2);
  border-radius: 22px;
  padding: 20px;
  box-shadow: var(--shadow);
}
.modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.modal-head h2 { font-size: 18px; }
.modal-note { font-size: 13px; color: var(--muted); margin-bottom: 14px; }
.modal-fine { font-size: 12px; color: var(--muted); margin-top: 12px; }
.x { border: 0; background: var(--panel-2); color: var(--txt-2); width: 32px; height: 32px; border-radius: 50%; cursor: pointer; font-size: 14px; }
.geo-status { font-size: 13px; color: var(--warn); margin-top: 8px; }
.city-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(96px, 1fr)); gap: 8px; margin: 16px 0; }
.city-grid button {
  padding: 10px 8px;
  border-radius: 11px;
  border: 1px solid var(--line);
  background: var(--panel-2);
  cursor: pointer;
  font-size: 13.5px;
  color: var(--txt);
}
.city-grid button:hover { border-color: var(--line-2); }
.city-grid button[aria-pressed="true"] { border-color: var(--accent); color: var(--accent); }
.coord-form { display: grid; grid-template-columns: 1fr 1fr auto; gap: 8px; align-items: end; }
.coord-form label { display: grid; gap: 4px; font-size: 12px; color: var(--muted); }
@media (max-width: 520px) { .coord-form { grid-template-columns: 1fr 1fr; } .coord-form .btn { grid-column: 1 / -1; } }

/* ---------- toast ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 22px;
  transform: translateX(-50%);
  background: var(--panel-3);
  border: 1px solid var(--line-2);
  color: var(--txt);
  padding: 11px 16px;
  border-radius: 12px;
  font-size: 13.5px;
  z-index: 120;
  box-shadow: var(--shadow);
  max-width: min(92vw, 460px);
}
.toast[hidden] { display: none; }

/* ---------- footer ---------- */
.ftr { border-top: 1px solid var(--line); margin-top: 40px; background: color-mix(in srgb, var(--bg-2) 70%, transparent); }
.ftr-in { max-width: 1180px; margin: 0 auto; padding: 28px 16px 34px; display: grid; gap: 14px; }
.ftr-brand p { color: var(--muted); font-size: 13.5px; margin-top: 6px; }
.ftr-links { display: flex; gap: 16px; flex-wrap: wrap; font-size: 13.5px; }
.ftr-legal { color: var(--muted); font-size: 12px; max-width: 78ch; line-height: 1.6; }
.ftr-src { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 11px; color: var(--muted); opacity: 0.85; }
.ftr-src a { color: inherit; text-decoration: none; border-bottom: 1px dotted currentColor; }
.ftr-src a:hover { color: var(--txt-2); text-decoration: none; }
.ftr-copy { color: var(--muted); font-size: 12px; }
.ftr-visits {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.ftr-visits b { color: var(--txt-2); font-weight: 700; }
.ftr-visits .sep { opacity: 0.5; }

/* ---------- compact tool grid (mobile) ---------- */
.tool-card .tc-short { display: none; }
@media (max-width: 640px) {
  .wrap { padding: 16px 12px 32px; }
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .tool-card {
    min-height: 0;
    padding: 12px 11px;
    gap: 5px;
    border-radius: 16px;
  }
  .tool-card .tc-top { gap: 4px; }
  .tool-card .tc-ico { font-size: 19px; }
  .tool-card .tc-live { font-size: 10.5px; }
  .tool-card h3 { font-size: 14px; line-height: 1.25; }
  .tool-card p { font-size: 11.5px; line-height: 1.4; }
  .tool-card .tc-long { display: none; }
  .tool-card .tc-short { display: block; }
  .tool-card .tc-go { font-size: 11.5px; margin-top: 2px; }
  .hero { border-radius: 20px; }
}

/* ---------- tool specific ---------- */
/* ---------- speed dial ---------- */
.seg.seg-sm button { padding: 5px 10px; font-size: 12px; }
.speed-dial { display: flex; justify-content: center; padding: 2px 0 0; }
.speed-dial svg { width: min(100%, 300px); height: auto; display: block; overflow: visible; }
.speed-dial .dial-track { fill: none; stroke: var(--line-2); stroke-width: 9; stroke-linecap: round; }
.speed-dial .dial-fill { fill: none; stroke: var(--accent); stroke-width: 9; stroke-linecap: round; transition: stroke-dasharray 0.45s cubic-bezier(0.2, 0.7, 0.3, 1); }
.speed-dial .tick { stroke: var(--muted); stroke-width: 1.2; opacity: 0.55; }
.speed-dial .tick.major { stroke: var(--txt-2); stroke-width: 2.4; opacity: 0.9; }
.speed-dial .dial-txt { fill: var(--muted); font-size: 11px; font-variant-numeric: tabular-nums; }
.speed-dial #dialNeedle { stroke: var(--accent); stroke-width: 3.6; stroke-linecap: round; transform-box: view-box; transform-origin: 120px 120px; transition: transform 0.45s cubic-bezier(0.2, 0.7, 0.3, 1); }
.speed-dial .cap { fill: var(--accent); }
.speed-dial .dial-val { fill: var(--txt); font-size: 30px; font-weight: 750; font-variant-numeric: tabular-nums; letter-spacing: -0.02em; }
.speed-dial .dial-unit { fill: var(--muted); font-size: 11.5px; }

/* ---------- internet speed test ---------- */
.net-main { display: grid; gap: 14px; }
.net-readout { display: flex; justify-content: space-between; align-items: flex-end; gap: 10px; flex-wrap: wrap; }
.net-num { display: flex; align-items: baseline; gap: 8px; min-width: 0; }
.net-num b { font-size: clamp(2.8rem, 13vw, 5rem); font-weight: 800; letter-spacing: -0.04em; line-height: 1; font-variant-numeric: tabular-nums; }
.net-unit { font-size: 15px; color: var(--muted); font-weight: 650; }
.net-state { display: grid; gap: 2px; justify-items: end; text-align: right; }
.net-status { font-size: 13.5px; color: var(--txt-2); font-weight: 650; }
.net-sub { font-size: 12.5px; color: var(--muted); font-variant-numeric: tabular-nums; }
.net-bar { height: 10px; }
.net-btn { padding: 13px 16px; font-size: 15px; }
.net-grades { display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); }
.net-grade { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 12px; background: var(--panel-2); border: 1px solid var(--line); border-radius: 11px; font-size: 13.5px; }
.net-grade .ng-name { color: var(--txt-2); }
@media (max-width: 520px) { .net-state { justify-items: start; text-align: left; } }

/* ---------- sky viewer ---------- */
.sky-stage {
  position: relative;
  width: 100%;
  height: clamp(300px, 54vh, 540px);
  border-radius: 14px;
  overflow: hidden;
  background: radial-gradient(circle at 50% 78%, #0b1730, #04070f 72%);
  border: 1px solid var(--line);
  touch-action: none;
  cursor: grab;
}
.sky-stage:active { cursor: grabbing; }
.sky-cam { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; background: #000; }
.sky-cam[hidden] { display: none; }
.sky-canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.iss-map {
  display: block;
  width: 100%;
  aspect-ratio: 2 / 1;
  margin-top: 12px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #060a12;
}
.sky-hud {
  position: absolute;
  left: 10px;
  bottom: 10px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  color: var(--txt-2);
  background: color-mix(in srgb, var(--panel) 74%, transparent);
  border: 1px solid var(--line);
  pointer-events: none;
}
.sky-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 12px; }
.sky-tools .btn { font-size: 13px; padding: 8px 12px; }
.sky-tools .btn[aria-pressed="true"] {
  border-color: var(--accent);
  color: var(--accent);
  background: color-mix(in srgb, var(--accent) 14%, transparent);
}
.sky-tools .btn[disabled] { opacity: 0.45; cursor: not-allowed; }
.chk { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--muted); cursor: pointer; }
.legend { display: flex; flex-wrap: wrap; gap: 12px; font-size: 12px; color: var(--muted); margin-top: 8px; }
.legend i { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 5px; vertical-align: 1px; }
.hint { font-size: 12.5px; color: var(--muted); }

/* ---------- fishing index ---------- */
.fish-search { max-width: 240px; flex: 1 1 160px; }
.fish-list { display: grid; gap: 10px; }
.fish-row { padding: 11px 12px; border-radius: 12px; background: var(--panel-2); border: 1px solid var(--line); display: grid; gap: 7px; }
.fish-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.fish-top b { font-size: 14.5px; font-weight: 700; }
.fish-top .label { color: var(--muted); font-size: 12px; }
.fish-top .pill { margin-left: auto; }
.fish-chips { gap: 6px; }
.fish-chip { padding: 4px 9px; font-size: 12px; border-radius: 999px; background: var(--panel-3); border: 1px solid var(--line); color: var(--txt-2); }
.fish-chip b { color: var(--txt); font-weight: 650; }
.fish-meta { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
/* 지명 검색 결과 머리줄 — "화원 근처 공식 포인트 · 가까운 순" + 기준 지점 */
.fish-place-head { margin-top: 12px; padding: 9px 12px; border-radius: 10px; border: 1px solid rgba(53,224,184,0.30); background: rgba(53,224,184,0.08); display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; font-size: 13px; word-break: keep-all; }
.fish-place-head b { font-weight: 700; color: var(--txt); }
.fish-place-head small { font-size: 12px; color: var(--muted); }
.fish-maps { display: grid; grid-template-columns: repeat(auto-fit, minmax(118px, 1fr)); gap: 8px; }
.fish-maps a { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 40px; padding: 8px 11px; border-radius: 10px; border: 1px solid var(--line); background: var(--panel-3); color: var(--txt); font-size: 12.5px; font-weight: 650; word-break: keep-all; }
.fish-maps a:hover { background: var(--panel-2); border-color: var(--accent); text-decoration: none; }
.fish-maps a::after { content: "↗"; color: var(--muted); }
@media (max-width: 400px) { .fish-maps { grid-template-columns: 1fr 1fr; } .fish-maps a { font-size: 12px; padding: 8px 10px; } }

/* ---------- pomodoro ---------- */
.pomo-card { display: grid; gap: 16px; justify-items: center; }
.pomo-card .seg { justify-self: center; }
.pomo-ring { position: relative; width: min(280px, 74vw); aspect-ratio: 1; display: grid; place-items: center; }
.pomo-ring svg { width: 100%; height: 100%; transform: rotate(-90deg); overflow: visible; }
.ring-track { fill: none; stroke: var(--line-2); stroke-width: 10; }
.ring-fill { fill: none; stroke: var(--accent); stroke-width: 10; stroke-linecap: round; transition: stroke-dashoffset 0.25s linear; }
.pomo-face { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; gap: 4px; }
.pomo-time { font-size: clamp(2.6rem, 13vw, 3.6rem); font-weight: 800; letter-spacing: -0.03em; line-height: 1; font-variant-numeric: tabular-nums; }
.pomo-state { font-size: 13px; color: var(--muted); font-weight: 650; }
.pomo-acts { justify-content: center; gap: 8px; }
.pomo-acts .btn { font-size: 14px; padding: 10px 15px; }
.pomo-meta { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; justify-content: center; }


.sun-arc { width: 100%; height: auto; display: block; border-radius: 14px; background: linear-gradient(180deg, var(--panel-2), var(--panel)); }
.timeline { display: flex; height: 26px; border-radius: 8px; overflow: hidden; border: 1px solid var(--line); }
.timeline span { display: block; height: 100%; }
.tl-labels { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--muted); margin-top: 4px; font-variant-numeric: tabular-nums; }

.moonface { width: 96px; height: 96px; }
.hour-strip { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(58px, 1fr); gap: 8px; overflow-x: auto; padding-bottom: 6px; scrollbar-width: thin; }
.hour-cell { display: grid; gap: 4px; justify-items: center; padding: 10px 4px; border-radius: 12px; background: var(--panel-2); border: 1px solid var(--line); font-size: 12px; min-width: 58px; }
.hour-cell .h { color: var(--muted); font-variant-numeric: tabular-nums; }
.hour-cell .e { font-size: 19px; line-height: 1.2; }
.hour-cell .t { font-weight: 700; font-variant-numeric: tabular-nums; }
.hour-cell .p { color: var(--info); font-size: 11px; }
.day-row { display: grid; grid-template-columns: 58px 30px 1fr auto; gap: 10px; align-items: center; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 13.5px; }
.day-row:last-child { border-bottom: 0; }
.day-row .dw { color: var(--txt-2); }
.day-row .tmax { font-weight: 700; font-variant-numeric: tabular-nums; text-align: right; }
.day-row .tmin { color: var(--muted); font-variant-numeric: tabular-nums; width: 38px; text-align: right; }
.tempbar { height: 5px; border-radius: 99px; background: var(--panel-3); position: relative; }
.tempbar i { position: absolute; height: 100%; border-radius: 99px; background: linear-gradient(90deg, var(--info), var(--sun)); }

#map { height: 380px; border-radius: var(--radius); border: 1px solid var(--line); z-index: 1; background: var(--panel-2); }
#map.small { height: 300px; }
.leaflet-container { background: #0a1220; font-family: var(--font); }
@media (prefers-color-scheme: light) { .leaflet-container { background: #dfe7f2; } }
.leaflet-control-attribution { font-size: 10px; }

.speed-big { font-size: clamp(3.2rem, 16vw, 6rem); font-weight: 800; letter-spacing: -0.04em; line-height: 1; font-variant-numeric: tabular-nums; }
.unit-toggle { display: inline-flex; gap: 4px; }
.trip-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.trip-list li { display: flex; justify-content: space-between; gap: 10px; padding: 10px 12px; background: var(--panel-2); border: 1px solid var(--line); border-radius: 10px; font-size: 13px; align-items: center; }
.trip-list .acts { display: flex; gap: 6px; }
.icon-btn { border: 1px solid var(--line); background: transparent; color: var(--muted); border-radius: 8px; padding: 4px 8px; cursor: pointer; font-size: 12px; }
.icon-btn:hover { color: var(--txt); border-color: var(--line-2); }

.compass-wrap { display: grid; place-items: center; padding: 8px; }
.compass { width: min(280px, 78vw); height: auto; }
.compass .cdial { transition: transform 0.09s linear; transform-origin: 150px 150px; }
.heading-big { font-size: clamp(2rem, 8vw, 3rem); font-weight: 800; font-variant-numeric: tabular-nums; letter-spacing: -0.02em; }

.noise-bar { position: relative; height: 22px; border-radius: 99px; background: linear-gradient(90deg, #2f8f6a 0%, #6fbf4a 30%, #e2c044 60%, #e08a3c 78%, #d9534f 100%); opacity: 0.92; }
.noise-bar .needle { position: absolute; top: -5px; width: 4px; height: 32px; border-radius: 2px; background: var(--txt); box-shadow: 0 0 0 2px var(--bg); transition: left 0.08s linear; }
.noise-scale { display: flex; justify-content: space-between; font-size: 11px; color: var(--muted); margin-top: 6px; }

.quake-item { display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: center; padding: 11px 0; border-bottom: 1px solid var(--line); }
.quake-item:last-child { border-bottom: 0; }
.mag-badge { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; font-weight: 800; font-size: 16px; color: #08111f; font-variant-numeric: tabular-nums; }
.quake-item .q-place { font-size: 14px; font-weight: 600; }
.quake-item .q-meta { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }

.tool-panel { display: grid; gap: 14px; }

/* ---------- nearby peaks (compass page) ---------- */
.peak-hero { display: grid; gap: 16px 20px; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }
.peak-lead { min-width: 0; }
.peak-name-row { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 10px; }
.peak-name { font-size: clamp(1.25rem, 5vw, 1.6rem); font-weight: 750; letter-spacing: -0.01em; margin: 2px 0 4px; word-break: keep-all; overflow-wrap: anywhere; }
button.peak-name { background: none; border: 0; padding: 0; font-family: inherit; color: var(--txt); text-align: left; cursor: pointer; }
button.peak-name:hover { color: var(--accent); }
.peak-map-btn { display: inline-flex; align-items: center; padding: 7px 13px; min-height: 36px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--panel-2); color: var(--txt-2); font-size: 12.5px; font-weight: 650; cursor: pointer; }
.peak-map-btn:hover { background: var(--panel-3); color: var(--txt); }
.peak-list { list-style: none; margin: 10px 0 0; padding: 0; }
.peak-item { border-top: 1px solid var(--line); }
.peak-item:first-child { border-top: 0; }
.peak-item b, .peak-item .pn { font-weight: 650; word-break: keep-all; overflow-wrap: anywhere; }
.peak-head { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; column-gap: 10px; width: 100%; padding: 10px 0; background: none; border: 0; font-family: inherit; font-size: 14px; color: var(--txt); text-align: left; cursor: pointer; }
.peak-head .pn { grid-column: 1; font-weight: 650; }
.peak-head .label { grid-column: 1; font-size: 12.5px; color: var(--muted); font-variant-numeric: tabular-nums; word-break: keep-all; overflow-wrap: anywhere; }
.peak-head .chev { grid-column: 2; grid-row: 1 / span 2; width: 8px; height: 8px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg); transition: transform .18s ease; }
.peak-head:hover .pn { color: var(--accent); }
.peak-head:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 8px; }
.peak-item.open .peak-head .chev { transform: rotate(225deg); }
.peak-panel { display: grid; gap: 12px; padding: 0 0 14px; }
.peak-panel[hidden] { display: none; }
.peak-facts { display: grid; gap: 6px; margin: 0; }
.peak-facts > div { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; font-size: 13px; }
.peak-facts dt { color: var(--muted); word-break: keep-all; }
.peak-facts dd { margin: 0; font-weight: 650; font-variant-numeric: tabular-nums; word-break: keep-all; overflow-wrap: anywhere; text-align: right; }
.peak-maps { display: grid; grid-template-columns: repeat(auto-fit, minmax(132px, 1fr)); gap: 8px; }
.peak-maps a { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 44px; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--line-2); background: var(--panel-2); color: var(--txt); font-size: 13px; font-weight: 650; word-break: keep-all; }
.peak-maps a:hover { background: var(--panel-3); border-color: var(--accent); text-decoration: none; }
.peak-maps a::after { content: "↗"; color: var(--muted); }
#peakCard h3 { word-break: keep-all; }
.map-list { display: grid; gap: 8px; }
.map-list a { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 48px; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--line-2); background: var(--panel-2); color: var(--txt); font-size: 14.5px; font-weight: 650; }
.map-list a:hover { background: var(--panel-3); border-color: var(--accent); text-decoration: none; }
.map-list a::after { content: "↗"; color: var(--muted); font-weight: 600; }
.tool-top { display: grid; gap: 14px; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); }
@media (max-width: 780px) { .tool-top { grid-template-columns: 1fr; } }
.hide { display: none !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }
/* 해시 고정용 주석: 내용이 같아도 배포 때 새 에셋 항목이 되도록 (Content-Type 다시 싣기) */
