:root {
  --bg: #000000;
  --bg-deep: #000000;
  --panel: #050505;
  --panel-strong: #080808;
  --line: rgba(255, 255, 255, 0.12);
  --line-strong: rgba(255, 255, 255, 0.22);
  --text: #f4f4f4;
  --muted: #b3b3b3;
  --critical: #ffffff;
  --high: #d6d6d6;
  --elevated: #b3b3b3;
  --steady: #868686;
  --shadow: 0 30px 70px rgba(0, 0, 0, 0.68);
  --radius: 28px;
  --grid-major: rgba(255, 255, 255, 0.035);
  --grid-minor: rgba(255, 255, 255, 0.03);
  --noise-opacity: 0.08;
  --surface: #090909;
  --surface-hover: #121212;
  --surface-soft: rgba(255, 255, 255, 0.02);
  --surface-strong: rgba(5, 5, 5, 0.94);
  --timeline-panel-bg:
    linear-gradient(180deg, rgba(255, 255, 255, 0.06), transparent 28%),
    rgba(2, 2, 2, 0.82);
  --settings-panel-bg: rgba(4, 4, 4, 0.98);
  --globe-shell-bg:
    radial-gradient(circle at 20% 18%, rgba(255, 255, 255, 0.07), transparent 18rem),
    radial-gradient(circle at 78% 26%, rgba(255, 255, 255, 0.05), transparent 20rem),
    #010101;
  --overlay-chip-bg: #050505;
  --overlay-chip-border: rgba(255, 255, 255, 0.1);
  --kicker: #d0d0d0;
  --timeline-primary-text: #f3e6a4;
  --timeline-secondary-text: #ffffff;
  --timeline-kicker-text: #ffffff;
  --danger-bg: rgba(46, 5, 5, 0.96);
  --danger-bg-hover: rgba(72, 10, 10, 0.98);
  --danger-border: rgba(174, 48, 48, 0.5);
  --skeleton-base: #1a2332;
  --skeleton-mid: #243040;
}

html[data-theme="light"] {
  --bg: #f3ede3;
  --bg-deep: #ece3d7;
  --panel: #fffcf8;
  --panel-strong: #f7f0e6;
  --line: rgba(39, 28, 18, 0.14);
  --line-strong: rgba(39, 28, 18, 0.24);
  --text: #18120d;
  --muted: #6d6054;
  --critical: #111111;
  --high: #2b241e;
  --elevated: #554a40;
  --steady: #7d736a;
  --shadow: 0 24px 56px rgba(84, 66, 49, 0.14);
  --grid-major: rgba(46, 34, 24, 0.06);
  --grid-minor: rgba(46, 34, 24, 0.045);
  --noise-opacity: 0.03;
  --surface: rgba(255, 255, 255, 0.92);
  --surface-hover: rgba(245, 238, 229, 0.98);
  --surface-soft: rgba(255, 255, 255, 0.72);
  --surface-strong: rgba(255, 252, 248, 0.95);
  --timeline-panel-bg:
    linear-gradient(180deg, rgba(255, 255, 255, 0.84), transparent 28%),
    rgba(255, 252, 248, 0.92);
  --settings-panel-bg: rgba(255, 252, 248, 0.97);
  --globe-shell-bg:
    radial-gradient(circle at 18% 18%, rgba(0, 0, 0, 0.035), transparent 18rem),
    radial-gradient(circle at 78% 24%, rgba(0, 0, 0, 0.028), transparent 20rem),
    #ffffff;
  --overlay-chip-bg: rgba(255, 255, 255, 0.9);
  --overlay-chip-border: rgba(39, 28, 18, 0.12);
  --kicker: #5f5348;
  --timeline-primary-text: #6b5421;
  --timeline-secondary-text: #3f3428;
  --timeline-kicker-text: #5f5348;
  --danger-bg: rgba(114, 28, 28, 0.92);
  --danger-bg-hover: rgba(137, 38, 38, 0.96);
  --danger-border: rgba(148, 52, 52, 0.42);
  --skeleton-base: #ece7de;
  --skeleton-mid: #ddd4c8;
}

* {
  box-sizing: border-box;
}

html {
  color-scheme: dark;
}

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--text);
  font-family:
    "Space Grotesk",
    "IBM Plex Sans KR",
    "Noto Sans KR",
    sans-serif;
}

body::before {
  content: "";
  position: fixed;
  inset: 1px;
  background-image:
    linear-gradient(var(--grid-major) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-minor) 1px, transparent 1px);
  background-size: 36px 36px;
  background-position: 18px 18px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.55), transparent 95%);
  pointer-events: none;
}

.screen-noise {
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: var(--noise-opacity);
  background:
    radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.08), transparent 0.6rem),
    radial-gradient(circle at 80% 50%, rgba(255, 255, 255, 0.08), transparent 0.5rem),
    radial-gradient(circle at 50% 80%, rgba(255, 255, 255, 0.05), transparent 0.45rem);
  background-size: 12rem 12rem;
}

.dashboard {
  position: relative;
  z-index: 1;
  width: min(1240px, calc(100vw - 28px));
  margin: 0 auto;
  padding: 28px 0 52px;
}

.hero,
.layout-grid {
  display: grid;
  gap: 18px;
}

.hero {
  grid-template-columns: minmax(0, 1.25fr) minmax(320px, 0.85fr);
  margin-bottom: 18px;
}

.panel {
  position: relative;
  overflow: hidden;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: var(--shadow);
}

.panel::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.18), transparent);
}

.eyebrow,
.panel-kicker {
  margin: 0 0 0.6rem;
  color: var(--kicker);
  text-transform: uppercase;
  letter-spacing: 0.22em;
  font-size: 0.78rem;
  font-weight: 700;
}

h1,
h2,
p {
  margin: 0;
}

h1 {
  max-width: 12ch;
  font-size: clamp(2.35rem, 5vw, 4.45rem);
  line-height: 0.95;
  letter-spacing: -0.06em;
}

h2 {
  font-size: 1.45rem;
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.hero-text {
  max-width: 50rem;
  margin-top: 1rem;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.75;
}

.control-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 1.5rem;
}

.sound-controls {
  display: grid;
  grid-template-columns: minmax(180px, 220px) minmax(220px, 1fr) auto;
  gap: 12px;
  align-items: end;
  margin-top: 1rem;
}

.sound-control {
  display: grid;
  gap: 0.55rem;
}

.sound-control-wide {
  min-width: 0;
}

.sound-label {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.sound-select,
.sound-range {
  width: 100%;
}

.sound-select {
  appearance: none;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 0.8rem 0.9rem;
  background: var(--surface);
  color: var(--text);
  font: inherit;
}

.sound-range-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  min-width: 0;
}

.sound-range {
  accent-color: var(--text);
}

.sound-value {
  min-width: 3rem;
  color: var(--text);
  font-size: 0.9rem;
  text-align: right;
}

.control-button,
.track-button {
  appearance: none;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.8rem 1rem;
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    background 180ms ease;
}

.control-button:hover,
.control-button:focus-visible,
.track-button:hover,
.track-button:focus-visible {
  transform: translateY(-1px);
  border-color: var(--line-strong);
  background: var(--surface-hover);
  outline: none;
}

.control-button:disabled,
.track-button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}

.control-button.quiet {
  color: var(--muted);
}

.control-button.is-off {
  border-color: var(--line);
  color: var(--muted);
}

.control-button.danger {
  border-color: var(--danger-border);
  background: var(--danger-bg);
  color: #fff0f0;
}

.control-button.danger:hover,
.control-button.danger:focus-visible {
  border-color: rgba(214, 92, 92, 0.72);
  background: var(--danger-bg-hover);
}

.icon-action-button {
  width: 100%;
  min-height: 74px;
  padding: 0.9rem 0.72rem 0.78rem;
  border-radius: 22px;
  display: grid;
  justify-items: center;
  gap: 0.45rem;
  text-align: center;
}

.icon-action-button svg {
  width: 22px;
  height: 22px;
}

.icon-action-label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.track-button {
  padding: 0.52rem 0.8rem;
  font-size: 0.82rem;
  color: #f0f0f0;
}

.hero-status {
  background: var(--panel-strong);
}

.hero-status-top {
  display: grid;
  gap: 0.85rem;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  border-radius: 999px;
  padding: 0.45rem 0.8rem;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  background: var(--surface);
  color: var(--text);
}

.status-pill::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 999px;
  flex: 0 0 auto;
  background: currentColor;
  opacity: 0.88;
}

.status-pill.status-pill-connecting {
  background: rgba(36, 36, 36, 0.94);
  color: #f3c46b;
}

.status-pill.status-pill-connecting::before {
  animation: connection-dot-pulse 1.1s ease-in-out infinite;
}

.status-pill.status-pill-live {
  background: rgba(14, 41, 24, 0.95);
  color: #8fe0a2;
}

.status-pill.status-pill-error {
  background: rgba(63, 13, 13, 0.96);
  color: #ffb0b0;
}

.status-line {
  font-size: 1.1rem;
  line-height: 1.45;
}

.scoreboard {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 1.4rem;
}

.score-card {
  padding: 14px;
  border-radius: 22px;
  background: #090909;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.score-label {
  display: block;
  color: var(--muted);
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.score-value {
  display: block;
  margin-top: 0.45rem;
  font-size: clamp(1.45rem, 3vw, 2.1rem);
  letter-spacing: -0.05em;
}

.hero-meta {
  display: grid;
  gap: 0.8rem;
  margin-top: 1.4rem;
  padding-top: 1.1rem;
  border-top: 1px solid var(--line);
}

.meta-line,
.panel-head,
.focus-top,
.focus-links,
.stage-divider {
  display: flex;
  justify-content: space-between;
  gap: 14px;
}

.meta-line span,
.panel-note {
  color: var(--muted);
}

.panel-head {
  align-items: flex-start;
  margin-bottom: 1rem;
}

.globe-stage {
  margin-bottom: 18px;
}

.globe-stage-wide {
  width: min(1520px, calc(100vw - 24px));
  margin-left: 50%;
  transform: translateX(-50%);
  padding: 20px 20px 24px;
}

.globe-stage-wide .panel-head {
  margin-bottom: 18px;
}

.globe-stage-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(320px, 0.85fr);
  gap: 18px;
  align-items: stretch;
}

.globe-frame {
  position: relative;
  min-height: 480px;
  border-radius: 30px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: #000000;
}

.globe-frame-wide {
  min-height: clamp(480px, 72vh, 860px);
}

.globe-frame::before,
.globe-frame::after {
  content: "";
  position: absolute;
  inset: 18px;
  border-radius: 28px;
  pointer-events: none;
}

.globe-frame::before {
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.globe-frame::after {
  inset: auto 0 0;
  height: 42%;
  background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.88));
}

.globe-canvas {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  cursor: grab;
  touch-action: none;
}

.globe-canvas.is-dragging {
  cursor: grabbing;
}

.globe-marker-bubble {
  position: absolute;
  z-index: 2;
  min-width: min(220px, calc(100% - 36px));
  max-width: min(320px, calc(100% - 36px));
  padding: 0.8rem 0.95rem 0.9rem;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 20px;
  background: rgba(0, 0, 0, 0.96);
  box-shadow: 0 18px 34px rgba(0, 0, 0, 0.5);
  color: #f7f7f7;
  pointer-events: none;
  transform: translate(-50%, calc(-100% - 18px));
  transition:
    opacity 140ms ease,
    transform 140ms ease;
}

.globe-marker-bubble::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -8px;
  width: 14px;
  height: 14px;
  border-right: 1px solid rgba(255, 255, 255, 0.18);
  border-bottom: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(0, 0, 0, 0.96);
  transform: translateX(-50%) rotate(45deg);
}

.globe-marker-bubble.is-hidden {
  opacity: 0;
  transform: translate(-50%, calc(-100% - 8px));
}

.globe-marker-bubble.is-below {
  transform: translate(-50%, 18px);
}

.globe-marker-bubble.is-below::after {
  top: -8px;
  bottom: auto;
  border-right: 0;
  border-bottom: 0;
  border-left: 1px solid rgba(255, 255, 255, 0.18);
  border-top: 1px solid rgba(255, 255, 255, 0.18);
}

.globe-bubble-line {
  display: block;
  line-height: 1.15;
}

.globe-bubble-kicker {
  display: block;
  margin-bottom: 0.35rem;
  color: #9d9d9d;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.globe-bubble-title {
  display: block;
  font-size: 1.08rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.12;
}

.globe-bubble-meta {
  margin-top: 0.45rem;
  color: #e0e0e0;
  font-size: 0.8rem;
}

.globe-bubble-place {
  margin-top: 0.32rem;
  color: #d0d0d0;
  font-size: 0.88rem;
  line-height: 1.25;
}

.globe-overlay-label {
  --globe-overlay-transform: translateX(-50%);
  position: absolute;
  top: 18px;
  left: 50%;
  z-index: 4;
  padding: 0.5rem 0.8rem;
  border-radius: 999px;
  background: #050505;
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--muted);
  font-size: 0.8rem;
  text-align: center;
  max-width: min(560px, calc(100% - 40px));
  pointer-events: none;
  transform: var(--globe-overlay-transform);
  transition: opacity 220ms ease;
}

.globe-overlay-label.is-hidden {
  opacity: 0;
  transform: var(--globe-overlay-transform);
  pointer-events: none;
}

.legend-section {
  display: grid;
  gap: 8px;
  align-content: start;
}

.legend-section-title {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.legend-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0.45rem 0.65rem;
  border-radius: 999px;
  background: #050505;
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--kicker);
  font-size: 0.8rem;
}

.legend-dot {
  width: 10px;
  height: 10px;
  display: inline-block;
}

.marker-glyph {
  position: relative;
  flex: 0 0 auto;
}

.marker-glyph-circle {
  border-radius: 50%;
}

.marker-glyph-triangle {
  width: 0;
  height: 0;
  border-left: 6px solid transparent;
  border-right: 6px solid transparent;
  border-bottom: 11px solid #ff9e42;
}

.marker-glyph-diamond {
  width: 10px;
  height: 10px;
  transform: rotate(45deg);
}

.legend-dot.critical {
  background: #ff4c4c;
  box-shadow: 0 0 10px rgba(255, 112, 112, 0.72);
}

.legend-dot.high {
  background: #ff9e42;
  box-shadow: 0 0 10px rgba(255, 181, 102, 0.62);
}

.legend-dot.aftershock {
  background: #ff4c4c;
  box-shadow:
    0 0 0 3px rgba(255, 76, 76, 0.18),
    0 0 12px rgba(255, 92, 92, 0.62);
}

.legend-dot.elevated {
  background: #8f8f8f;
  box-shadow: 0 0 10px rgba(212, 212, 212, 0.58);
}

.legend-dot.low {
  background: #dddddd;
  box-shadow: 0 0 10px rgba(240, 240, 240, 0.52);
}

.legend-dot.icon-glyph.marker-glyph-circle,
.legend-dot.icon-glyph.marker-glyph-diamond {
  background: #d9dde2;
  box-shadow: none;
}

.legend-dot.icon-glyph.marker-glyph-triangle {
  border-bottom-color: #d9dde2;
  box-shadow: none;
}

.legend-dot.home {
  background: #ffffff;
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.8);
}

.legend-chip-note {
  justify-content: flex-start;
}

.globe-focus-card {
  min-height: 0;
  display: grid;
}

.globe-focus-shell {
  display: grid;
  gap: 16px;
  min-height: 100%;
  padding: 18px;
  border-radius: 28px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: #060606;
}

.focus-top {
  align-items: flex-start;
}

.focus-title {
  font-size: 1.24rem;
}

.focus-lead,
.globe-hint {
  color: var(--muted);
  line-height: 1.7;
}

.focus-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.focus-stat {
  padding: 14px;
  border-radius: 22px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: #0a0a0a;
}

.focus-stat span {
  display: block;
  color: var(--muted);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.focus-stat strong {
  display: block;
  margin-top: 0.35rem;
  font-size: 1.05rem;
  line-height: 1.35;
}

.focus-links {
  flex-wrap: wrap;
}

.focus-links a {
  color: #f2f2f2;
}

.stage-divider {
  align-items: end;
  margin: 20px 0 12px;
}

.stage-mini-title {
  font-size: 1.1rem;
}

.pulse-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(72px, 1fr));
  gap: 10px;
  min-height: 158px;
}

.pulse-bar {
  display: grid;
  align-items: end;
  min-height: 126px;
  padding: 0.75rem 0.6rem;
  border-radius: 22px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: #080808;
}

.pulse-bar-fill {
  width: 100%;
  border-radius: 18px 18px 8px 8px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(125, 125, 125, 0.82));
}

.pulse-bar.critical .pulse-bar-fill {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(150, 150, 150, 0.92));
}

.pulse-bar-footer {
  margin-top: 0.65rem;
  display: grid;
  gap: 0.18rem;
}

.pulse-mag {
  font-size: 1rem;
  font-weight: 700;
}

.pulse-place {
  color: var(--muted);
  font-size: 0.72rem;
  line-height: 1.3;
}

.layout-grid {
  grid-template-columns: repeat(12, minmax(0, 1fr));
}

.span-7 {
  grid-column: span 7;
}

.span-6 {
  grid-column: span 6;
}

.span-5 {
  grid-column: span 5;
}

.alert-list,
.event-list,
.region-list,
.significant-list,
.collector-list {
  display: grid;
  gap: 12px;
}

.alert-card,
.event-card,
.region-card,
.collector-card,
.significant-card,
.home-watch-inner {
  padding: 16px;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: #060606;
}

.alert-card.critical {
  border-color: rgba(255, 255, 255, 0.22);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.alert-card.high {
  border-color: rgba(255, 255, 255, 0.16);
}

.alert-top,
.event-top,
.collector-top,
.significant-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.magnitude-pill,
.severity-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 0.35rem 0.6rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
}

.magnitude-pill {
  background: #131313;
  color: #f1f1f1;
}

.magnitude-pill.critical,
.severity-pill.critical {
  background: #f1f1f1;
  color: #000000;
}

.magnitude-pill.high,
.severity-pill.high {
  background: #d7d7d7;
  color: #040404;
}

.magnitude-pill.elevated,
.severity-pill.elevated {
  background: #b9b9b9;
  color: #060606;
}

.magnitude-pill.steady,
.severity-pill.steady {
  background: #151515;
  color: #d2d2d2;
}

.item-title {
  font-size: 1.06rem;
  line-height: 1.4;
}

.item-copy,
.region-meta,
.collector-copy,
.feed-note {
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.65;
}

.item-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 0.8rem;
  color: var(--muted);
  font-size: 0.84rem;
}

.reason-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.reason-pill {
  display: inline-flex;
  border-radius: 999px;
  padding: 0.34rem 0.58rem;
  background: #111111;
  color: var(--text);
  font-size: 0.78rem;
}

.home-watch-card {
  min-height: 172px;
}

.home-watch-inner {
  display: grid;
  gap: 0.8rem;
}

.home-watch-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.home-watch-stat {
  padding: 12px;
  border-radius: 18px;
  background: #0a0a0a;
}

.home-watch-stat span {
  display: block;
  color: var(--muted);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.home-watch-stat strong {
  display: block;
  margin-top: 0.35rem;
  font-size: 1.25rem;
}

.region-card {
  display: grid;
  gap: 0.7rem;
}

.region-meter {
  height: 8px;
  border-radius: 999px;
  background: #121212;
  overflow: hidden;
}

.region-meter-fill {
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, rgba(245, 245, 245, 0.82), rgba(108, 108, 108, 0.88));
}

.collector-card a,
.event-card a,
.alert-card a,
.significant-card a,
.feed-note a {
  color: #f2f2f2;
}

.collector-card ul,
.significant-card ul {
  margin: 0.7rem 0 0;
  padding-left: 1rem;
  color: var(--muted);
}

.empty-state {
  padding: 1.1rem;
  border-radius: 22px;
  background: #050505;
  color: var(--muted);
  border: 1px dashed rgba(255, 255, 255, 0.14);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 1080px) {
  .globe-stage-layout {
    grid-template-columns: 1fr;
  }

  .globe-frame,
  .globe-focus-card {
    min-height: 420px;
  }
}

@media (max-width: 980px) {
  .hero {
    grid-template-columns: 1fr;
  }

  .sound-controls {
    grid-template-columns: 1fr 1fr;
  }

  .layout-grid {
    grid-template-columns: 1fr;
  }

  .span-7,
  .span-6,
  .span-5 {
    grid-column: auto;
  }
}

@media (max-width: 720px) {
  .dashboard {
    width: min(100vw - 16px, 100%);
    padding-top: 16px;
  }

  .globe-stage-wide {
    width: calc(100vw - 12px);
    padding: 14px 14px 18px;
  }

  .panel {
    padding: 18px;
    border-radius: 22px;
  }

  h1 {
    max-width: none;
    font-size: clamp(2.1rem, 12vw, 3.5rem);
  }

  .scoreboard,
  .home-watch-stats,
  .focus-grid {
    grid-template-columns: 1fr 1fr;
  }

  .sound-controls {
    grid-template-columns: 1fr;
  }

  .meta-line,
  .panel-head,
  .alert-top,
  .event-top,
  .collector-top,
  .significant-top,
  .focus-top,
  .focus-links,
  .stage-divider {
    flex-direction: column;
  }

  .globe-frame {
    min-height: 360px;
  }

  .globe-legend {
    right: 16px;
  }
}

.dashboard-solo {
  --measured-header-height: 118px;
  --desktop-header-clearance: max(136px, calc(var(--measured-header-height) + 18px));
  --desktop-sidebar-width: min(356px, calc(100vw - 36px));
  --desktop-bottom-clearance: 18px;
  --globe-legend-clearance: 112px;
  position: relative;
  width: 100%;
  height: 100dvh;
  min-height: 100dvh;
  margin: 0;
  border: 0;
  outline: 0;
  padding: 0;
  box-shadow: none;
  overflow: hidden;
}

.dashboard-solo::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 5;
  pointer-events: none;
  opacity: 0;
  background:
    radial-gradient(circle at 50% 42%, rgba(112, 10, 10, 0.34), transparent 56%),
    linear-gradient(180deg, rgba(54, 4, 4, 0.12), rgba(20, 0, 0, 0.34));
  transition: opacity 180ms ease;
}

.dashboard-solo.is-incident-alert::after {
  opacity: 1;
  animation: incident-alert-pulse 1.16s ease-in-out infinite;
}

@keyframes incident-alert-pulse {
  0%,
  100% {
    opacity: 0.16;
  }

  46% {
    opacity: 0.48;
  }

  68% {
    opacity: 0.24;
  }
}

.app-header {
  position: absolute;
  top: 16px;
  left: 20px;
  right: 20px;
  z-index: 9;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
  pointer-events: none;
}

.app-brand {
  display: flex;
  flex: 1 1 auto;
  align-items: center;
  gap: 16px;
  min-width: 0;
  max-width: min(48vw, 560px);
}

.app-brand-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.app-header-title-brand {
  font-size: clamp(1.26rem, 2vw, 1.68rem);
  line-height: 1;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.header-map-toolbar {
  display: flex;
  flex: 1 1 auto;
  align-items: center;
  justify-content: flex-end;
  gap: 14px;
  min-width: 0;
  margin-inline: 24px;
  pointer-events: auto;
}

.header-date-tools {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.header-date-picker {
  display: inline-flex;
  align-items: center;
}

.header-date-input {
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface-strong);
  color: var(--text);
  font: inherit;
  font-size: 0.85rem;
}

.live-mode-button {
  appearance: none;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface-strong);
  color: var(--text);
  font: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.live-mode-button.is-live {
  border-color: rgba(74, 222, 128, 0.42);
  color: #dcfce7;
}

.live-mode-button.is-history {
  color: var(--muted);
}

.live-mode-button:disabled {
  cursor: default;
}

.live-mode-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.44);
  animation: livePulse 1.4s ease-out infinite;
}

.history-banner {
  position: fixed;
  top: 90px;
  left: 50%;
  z-index: 22;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  max-width: min(720px, calc(100vw - 28px));
  padding: 0.75rem 0.95rem;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface-strong);
  color: var(--text);
  box-shadow: 0 22px 42px rgba(0, 0, 0, 0.34);
  transform: translateX(-50%);
  transition:
    opacity 180ms ease,
    transform 180ms ease;
}

.history-banner p {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.history-banner-button {
  appearance: none;
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 0.82rem;
  font-weight: 700;
}

.history-banner.is-hidden {
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -8px);
}

.app-site-title {
  margin: 0;
  color: var(--muted);
  font-size: 0.98rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-shadow: 0 10px 24px rgba(0, 0, 0, 0.45);
}

.app-header-actions {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 12px;
  margin-left: auto;
  pointer-events: auto;
}

.header-search-shell {
  position: relative;
  width: 54px;
  height: 54px;
  display: inline-flex;
  flex: 0 0 auto;
}

.header-search-panel {
  position: absolute;
  right: calc(100% + 10px);
  bottom: 0;
  width: 0;
  min-height: 54px;
  opacity: 0;
  overflow: hidden;
  pointer-events: none;
  transition:
    width 180ms ease,
    opacity 160ms ease;
}

.header-search-shell.is-open .header-search-panel {
  width: min(320px, max(220px, calc(100vw - 760px)));
  opacity: 1;
  pointer-events: auto;
}

.header-search-field {
  display: block;
  width: 100%;
}

.header-search-input {
  width: 100%;
  min-width: 0;
  min-height: 54px;
}

.header-search-toggle,
.globe-date-toggle {
  appearance: none;
  width: 54px;
  height: 54px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface-strong);
  color: var(--text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    background 160ms ease,
    color 160ms ease;
}

.header-search-toggle:hover,
.header-search-toggle:focus-visible,
.globe-date-toggle:hover,
.globe-date-toggle:focus-visible {
  transform: translateY(-1px);
  border-color: var(--line-strong);
  background: var(--surface-hover);
  outline: none;
}

.header-search-toggle.is-active,
.header-search-shell.is-open .header-search-toggle,
.globe-date-toggle.is-active,
.globe-date-shell.is-open .globe-date-toggle {
  color: var(--text);
  border-color: rgba(96, 165, 250, 0.55);
  background: rgba(30, 58, 95, 0.28);
}

.header-search-toggle svg,
.globe-date-toggle svg {
  width: 18px;
  height: 18px;
}

.globe-date-shell {
  position: relative;
  width: 54px;
  height: 54px;
  display: inline-flex;
  flex: 0 0 auto;
}

.globe-date-panel {
  position: absolute;
  right: calc(100% + 10px);
  bottom: 0;
  width: 0;
  min-height: 56px;
  opacity: 0;
  overflow: hidden;
  pointer-events: none;
  transition:
    width 180ms ease,
    opacity 160ms ease;
}

.globe-date-shell.is-open .globe-date-panel {
  width: min(280px, max(240px, calc(100vw - 860px)));
  opacity: 1;
  pointer-events: auto;
}

.globe-date-field {
  display: block;
  width: 100%;
}

.globe-date-hidden-input {
  position: absolute;
  width: 0;
  height: 0;
  opacity: 0;
  pointer-events: none;
}

.globe-date-navigator {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) 44px;
  align-items: center;
  gap: 10px;
  min-height: 56px;
}

.globe-date-readout {
  min-width: 0;
  display: grid;
  gap: 2px;
  text-align: center;
}

.globe-date-caption {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.globe-date-value {
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  white-space: nowrap;
}

.globe-date-nav-button {
  appearance: none;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface-strong);
  color: var(--text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font: inherit;
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    background 160ms ease,
    opacity 160ms ease;
}

.globe-date-nav-button:hover,
.globe-date-nav-button:focus-visible {
  transform: translateY(-1px);
  border-color: var(--line-strong);
  background: var(--surface-hover);
  outline: none;
}

.globe-date-nav-button:disabled {
  opacity: 0.4;
  cursor: default;
  transform: none;
}

.header-clock {
  display: grid;
  justify-items: end;
  gap: 0.2rem;
  min-width: 0;
}

.header-clock strong {
  font-size: 1.08rem;
  font-weight: 700;
  letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
  text-shadow: 0 10px 24px rgba(0, 0, 0, 0.45);
}

.app-brand-logo {
  width: 58px;
  height: 58px;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.app-header-title {
  max-width: none;
  font-size: clamp(1.8rem, 3.4vw, 3rem);
  line-height: 0.94;
  white-space: normal;
  word-break: keep-all;
  line-break: strict;
  text-shadow: 0 10px 24px rgba(0, 0, 0, 0.45);
}

.monitor-layout {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 100%;
}

.timeline-panel,
.globe-stage-solo,
.globe-shell,
.globe-frame-solo {
  height: 100%;
  min-height: 0;
}

.timeline-panel.panel,
.globe-shell.panel {
  padding: 0;
}

.globe-shell.panel {
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.timeline-panel::after,
.globe-shell::after {
  display: none;
}

.timeline-panel {
  --timeline-drag-offset: 0px;
  position: absolute;
  top: var(--desktop-header-clearance);
  bottom: auto;
  left: 18px;
  z-index: 7;
  width: var(--desktop-sidebar-width);
  height: calc(100% - var(--desktop-header-clearance) - var(--desktop-bottom-clearance));
  min-height: 300px;
  max-height: calc(100% - var(--desktop-header-clearance) - var(--desktop-bottom-clearance));
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: var(--timeline-panel-bg);
  backdrop-filter: blur(18px);
  box-shadow: var(--shadow);
  transform: translateY(var(--timeline-drag-offset));
}

.timeline-head {
  display: block;
  min-width: 0;
  padding: 20px 18px 16px;
  border-bottom: 1px solid var(--line);
}

.timeline-head-top {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
  min-width: 0;
}

.timeline-head .panel-kicker {
  color: var(--timeline-kicker-text);
}

.timeline-desktop-filter-row {
  display: grid;
  gap: 12px;
  margin-top: 14px;
}

.event-type-filter-shell {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.event-type-filter-buttons {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.event-type-filter-button {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 0;
  min-height: 44px;
  padding: 0.7rem 0.85rem;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface-soft);
  color: var(--timeline-primary-text);
  cursor: pointer;
  transition:
    border-color 160ms ease,
    background-color 160ms ease,
    transform 160ms ease,
    box-shadow 160ms ease;
}

.event-type-filter-button[aria-pressed="true"] {
  border-color: rgba(245, 224, 135, 0.36);
  background: rgba(245, 224, 135, 0.08);
  box-shadow: inset 0 0 0 1px rgba(245, 224, 135, 0.14);
}

.event-type-filter-button[aria-pressed="false"] {
  color: var(--muted);
  opacity: 0.72;
}

.event-type-filter-button:hover {
  border-color: var(--line-strong);
}

.event-type-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
}

.event-type-icon-earthquake {
  width: 14px;
  height: 14px;
  border-radius: 999px;
  background: currentColor;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.event-type-icon-volcano {
  width: 0;
  height: 0;
  border-left: 8px solid transparent;
  border-right: 8px solid transparent;
  border-bottom: 15px solid currentColor;
}

.event-type-label {
  min-width: 0;
  font-size: 0.84rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.timeline-content {
  min-height: 0;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
}

.timeline-body {
  display: grid;
  gap: 14px;
  min-width: 0;
  padding: 0 18px 16px;
}

.timeline-stats-grid {
  margin-top: 2px;
}

.timeline-stats-grid .settings-stat {
  min-height: 88px;
}

.brand-logo {
  width: 56px;
  height: 56px;
  flex: 0 0 auto;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: var(--surface-soft);
  box-shadow: 0 14px 26px rgba(0, 0, 0, 0.28);
}

.timeline-status-stack {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.status-line-compact {
  color: var(--timeline-primary-text);
  font-size: 0.98rem;
  line-height: 1.38;
  overflow-wrap: anywhere;
  text-wrap: pretty;
}

.timeline-copy {
  color: var(--timeline-secondary-text);
  font-size: 0.95rem;
  line-height: 1.55;
  overflow-wrap: anywhere;
  text-wrap: pretty;
}

.timeline-tools {
  display: grid;
  gap: 8px;
}

.timeline-search,
.timeline-filter {
  display: grid;
  gap: 8px;
}

.timeline-filter-label {
  color: var(--kicker);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.timeline-filter-select {
  width: 100%;
  min-width: 0;
}

.filter-slider-shell {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.filter-slider-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.filter-slider-title {
  color: var(--timeline-kicker-text);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.filter-slider-value {
  color: var(--timeline-primary-text);
  font-size: 0.84rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.filter-slider-input {
  width: 100%;
  min-width: 0;
  margin: 0;
  accent-color: #93c5fd;
}

.filter-slider-input::-webkit-slider-runnable-track {
  height: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
}

.filter-slider-input::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  margin-top: -6px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: #f8fafc;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.28);
}

.filter-slider-input::-moz-range-track {
  height: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
}

.filter-slider-input::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: #f8fafc;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.28);
}

.filter-slider-scale {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 4px;
  color: var(--timeline-secondary-text);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-align: center;
}

.volcano-filter-scale {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

.volcano-filter-input {
  accent-color: #fb923c;
}

.timeline-meta-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.timeline-meta-item {
  display: grid;
  gap: 0.45rem;
  padding: 0.85rem 0.95rem;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface-soft);
}

.timeline-meta-item span {
  color: var(--timeline-secondary-text);
  font-size: 0.74rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.timeline-meta-item strong {
  color: var(--timeline-primary-text);
  font-size: 0.95rem;
  letter-spacing: -0.02em;
}

.timeline-meta-item-single {
  grid-column: 1 / -1;
}

.timeline-note {
  color: var(--timeline-kicker-text);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.timeline-list {
  min-height: 0;
  overflow: auto;
  padding: 14px 14px 16px 18px;
  display: grid;
  gap: 10px;
}

.timeline-list::-webkit-scrollbar {
  width: 10px;
}

.timeline-list::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
}

.timeline-entry {
  display: grid;
  gap: 10px;
  padding: 14px 14px 15px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--surface-soft);
  cursor: pointer;
  transition:
    border-color 160ms ease,
    background-color 160ms ease,
    transform 160ms ease,
    box-shadow 160ms ease;
}

.timeline-entry:hover {
  border-color: var(--line-strong);
  background: var(--surface-hover);
}

.timeline-entry:focus-visible {
  outline: none;
  border-color: var(--line-strong);
  box-shadow: 0 0 0 1px var(--line-strong);
}

.timeline-entry.is-active {
  border-color: var(--line-strong);
  background: var(--surface-hover);
  transform: translateX(4px);
  box-shadow: inset 0 0 0 1px var(--line);
}

.timeline-ad-card {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--surface-soft);
}

.timeline-ad-top {
  align-items: center;
}

.timeline-ad-disclosure {
  color: var(--timeline-secondary-text);
  font-size: 0.77rem;
  line-height: 1.55;
  word-break: keep-all;
}

.timeline-mag-ad {
  background: rgba(255, 255, 255, 0.14);
  color: #f5f5f5;
}

.timeline-ad-slot-wrap {
  display: flex;
  justify-content: center;
  width: 100%;
}

.timeline-ad-slot {
  width: min(286px, 100%);
  min-height: 100px;
}

.timeline-ad-slot iframe {
  display: block;
  width: 100%;
  border-radius: 16px;
  overflow: hidden;
}

.timeline-entry-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.timeline-entry-copy {
  min-width: 0;
}

.timeline-entry-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.timeline-entry-type {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--timeline-primary-text);
  flex: 0 0 auto;
}

.timeline-entry-type svg {
  width: 16px;
  height: 16px;
}

.timeline-entry-type-earthquake {
  color: #f7f2d6;
  background: rgba(255, 244, 168, 0.08);
  border-color: rgba(255, 244, 168, 0.18);
}

.timeline-entry-type-volcano {
  color: #ffcf9d;
  background: rgba(251, 146, 60, 0.12);
  border-color: rgba(251, 146, 60, 0.26);
}

.timeline-entry-time {
  color: var(--timeline-primary-text);
  font-size: 0.83rem;
  font-weight: 600;
}

.timeline-entry-place {
  color: var(--timeline-primary-text);
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.28;
}

.timeline-entry-region {
  color: var(--timeline-secondary-text);
  font-size: 0.84rem;
}

.timeline-entry-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 10px;
  color: var(--timeline-secondary-text);
  font-size: 0.8rem;
}

.timeline-mag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 0.35rem 0.65rem;
  background: #f4f4f4;
  color: #050505;
  font-size: 0.82rem;
  font-weight: 700;
}

.timeline-mag.is-volcano {
  background: rgba(251, 146, 60, 0.18);
  color: #ffddb9;
}

.globe-stage-solo {
  position: relative;
  min-width: 0;
  min-height: 100%;
}

.globe-shell {
  --action-rail-button-size: 54px;
  --action-rail-gap: 10px;
  --action-rail-offset: 18px;
  --action-rail-clearance: calc(var(--action-rail-button-size) + var(--action-rail-gap) + 12px);
  position: relative;
  overflow: hidden;
  width: 100%;
  height: 100%;
  background: var(--globe-shell-bg);
}

.globe-action-rail {
  position: absolute;
  right: var(--action-rail-offset);
  bottom: max(var(--action-rail-offset), env(safe-area-inset-bottom));
  z-index: 7;
  display: flex;
  flex-direction: column-reverse;
  align-items: flex-end;
  gap: var(--action-rail-gap);
}

.globe-action-rail > button,
.globe-action-rail > .header-search-shell,
.globe-action-rail > .globe-date-shell {
  flex: 0 0 auto;
  width: var(--action-rail-button-size);
  height: var(--action-rail-button-size);
}

#settingsToggle {
  order: 0;
}

#locationButton {
  order: 1;
}

#mobileLegendToggle {
  order: 2;
}

#desktopSearchShell,
#mobileSearchOpen {
  order: 3;
}

#desktopDateShell,
#mobileDateOpen {
  order: 4;
}

#alarmCenterToggle {
  order: 5;
}

.globe-action-rail > button,
.globe-action-rail > .header-search-shell > button,
.globe-action-rail > .globe-date-shell > button {
  width: var(--action-rail-button-size);
  height: var(--action-rail-button-size);
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface-strong);
  color: var(--text);
  box-shadow: 0 18px 30px rgba(0, 0, 0, 0.38);
  backdrop-filter: blur(14px);
}

.globe-action-rail > button svg,
.globe-action-rail > .header-search-shell > button svg,
.globe-action-rail > .globe-date-shell > button svg {
  width: 20px;
  height: 20px;
}

.action-rail-badge {
  position: absolute;
  top: -5px;
  right: -5px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: #ef4444;
  color: #fff;
  font-size: 0.65rem;
  font-weight: 700;
  line-height: 18px;
  text-align: center;
  box-shadow: 0 10px 18px rgba(0, 0, 0, 0.34);
}

.action-rail-badge.is-hidden {
  display: none;
}

.alarm-center-panel {
  position: absolute;
  right: calc(var(--action-rail-offset) + var(--action-rail-clearance));
  bottom: 0;
  z-index: 8;
  width: min(360px, calc(100% - 44px));
  max-height: min(420px, calc(100% - 48px));
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: var(--surface-strong);
  box-shadow: 0 22px 36px rgba(0, 0, 0, 0.42);
  display: grid;
  gap: 10px;
  overflow: hidden;
  transition:
    opacity 180ms ease,
    transform 180ms ease;
}

.alarm-center-panel.is-hidden {
  opacity: 0;
  pointer-events: none;
  transform: translateX(10px);
}

.alarm-center-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.alarm-center-title {
  margin: 0;
  color: var(--text);
  font-size: 0.92rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.alarm-center-note {
  margin: 0;
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.45;
}

.alarm-center-list {
  display: grid;
  gap: 8px;
  max-height: 290px;
  overflow: auto;
  padding-right: 2px;
}

.alarm-center-item {
  appearance: none;
  width: 100%;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 0.8rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface-soft);
  color: var(--text);
  text-align: left;
}

.alarm-center-item-scale {
  min-width: 54px;
  color: #fef3a6;
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.alarm-center-item.tone-critical .alarm-center-item-scale {
  color: #ff6b6b;
}

.alarm-center-item.tone-high .alarm-center-item-scale {
  color: #ffbe6b;
}

.alarm-center-item-copy {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.alarm-center-item-title {
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 0.9rem;
  font-weight: 700;
}

.alarm-center-item-meta {
  color: var(--muted);
  font-size: 0.76rem;
}

.alarm-center-empty {
  padding: 1rem 0.25rem 0.5rem;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.5;
}

.globe-hud {
  position: absolute;
  top: 28px;
  left: 50%;
  right: auto;
  z-index: 4;
  display: flex;
  justify-content: center;
  gap: 14px;
  align-items: center;
  width: min(560px, calc(100vw - 560px));
  min-width: min(280px, calc(100vw - 220px));
  transform: translateX(-50%);
  text-align: center;
  pointer-events: none;
}

.desktop-map-controls {
  position: absolute;
  top: auto;
  bottom: var(--globe-legend-clearance);
  left: 50%;
  z-index: 5;
  display: grid;
  gap: 10px;
  width: min(360px, calc(100vw - 620px));
  min-width: 280px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--surface-strong);
  backdrop-filter: blur(18px);
  box-shadow: 0 22px 40px rgba(0, 0, 0, 0.32);
  transform: translateX(-50%);
}

.desktop-map-search,
.desktop-map-filter {
  display: grid;
  gap: 8px;
}

.desktop-map-search-input {
  min-height: 48px;
}

.timeline-filter-slider {
  width: 100%;
}

.volcano-data-note {
  margin: 8px 2px 0;
  color: var(--muted);
  font-size: 0.76rem;
  line-height: 1.45;
}

.globe-frame-solo {
  border: 0;
  border-radius: 0;
  background: transparent;
  min-height: 100%;
}

.globe-frame-solo::before {
  display: none;
}

.globe-location-fab {
  position: relative;
  z-index: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    background 160ms ease,
    opacity 160ms ease;
}

.settings-section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.settings-help-toggle {
  appearance: none;
  width: 32px;
  height: 32px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface-soft);
  color: var(--muted);
  font: inherit;
  font-size: 0.9rem;
  font-weight: 700;
}

.settings-help-text {
  margin: 0;
  padding: 0.7rem 0.85rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface-soft);
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.45;
  transition:
    opacity 180ms ease,
    transform 180ms ease,
    max-height 180ms ease,
    padding 180ms ease,
    border-width 180ms ease;
}

.settings-help-text.is-hidden {
  opacity: 0;
  max-height: 0;
  overflow: hidden;
  padding-top: 0;
  padding-bottom: 0;
  border-width: 0;
  transform: translateY(-4px);
  pointer-events: none;
}

.settings-fieldset {
  margin: 0;
  padding: 0;
  border: 0;
  min-width: 0;
}

.settings-fieldset > legend {
  margin-bottom: 10px;
}

.loading-fade-target {
  opacity: 0;
  transition: opacity 200ms ease;
}

.loading-fade-target.is-ready,
.loading-fade-target.is-skeleton,
.loading-fade-target.skeleton-text {
  opacity: 1;
}

@keyframes livePulse {
  0% {
    box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.44);
  }

  70% {
    box-shadow: 0 0 0 10px rgba(34, 197, 94, 0);
  }

  100% {
    box-shadow: 0 0 0 0 rgba(34, 197, 94, 0);
  }
}

@keyframes valueFadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

.globe-location-fab:hover,
.globe-location-fab:focus-visible {
  transform: translateY(-1px);
  border-color: var(--line-strong);
  background: var(--surface-hover);
  outline: none;
}

.globe-location-fab.is-active {
  border-color: var(--line-strong);
}

.globe-location-fab.is-locating {
  opacity: 0.84;
}

.globe-location-fab:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.globe-location-fab svg {
  width: 24px;
  height: 24px;
}

.incident-alert {
  position: fixed;
  left: 50%;
  bottom: max(18px, env(safe-area-inset-bottom));
  z-index: 12;
  display: flex;
  align-items: center;
  gap: 16px;
  width: min(720px, calc(100vw - 40px));
  padding: 14px 16px;
  border: 1px solid rgba(174, 48, 48, 0.44);
  border-radius: 24px;
  background: rgba(14, 3, 3, 0.96);
  box-shadow: 0 28px 56px rgba(0, 0, 0, 0.54);
  transform: translateX(-50%);
  transition:
    opacity 180ms ease,
    transform 180ms ease;
}

.incident-alert.tone-critical {
  border-color: rgba(208, 58, 58, 0.54);
  background: rgba(54, 10, 10, 0.96);
}

.incident-alert.tone-high {
  border-color: rgba(212, 141, 52, 0.42);
  background: rgba(53, 28, 8, 0.95);
}

.incident-alert.tone-steady {
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(14, 14, 14, 0.96);
}

.incident-alert.is-hidden {
  opacity: 0;
  pointer-events: none;
  transform: translateX(-50%) translateY(10px);
}

.timeline-footer {
  padding: 8px 4px 2px;
  color: var(--muted);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-align: center;
}

.timeline-footer p {
  margin: 0;
  line-height: 1.5;
}

.timeline-list.is-loaded .timeline-entry,
.timeline-list.is-loaded .timeline-footer {
  animation: valueFadeIn 200ms ease;
}

.incident-alert-copy {
  display: grid;
  gap: 0.32rem;
  min-width: 0;
  flex: 1 1 auto;
}

.incident-alert-kicker {
  color: #ffb2b2;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.incident-alert-title,
#incidentAlertTitle {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.18;
  overflow-wrap: anywhere;
}

#incidentAlertMeta {
  color: #d6b5b5;
  font-size: 0.86rem;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.settings-fab,
.settings-close {
  appearance: none;
  border: 1px solid var(--line);
  background: var(--surface-strong);
  color: var(--text);
  cursor: pointer;
}

.settings-fab {
  position: relative;
  top: auto;
  right: auto;
  z-index: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    background 160ms ease;
}

.settings-fab:hover,
.settings-fab:focus-visible,
.settings-close:hover,
.settings-close:focus-visible {
  transform: translateY(-1px);
  border-color: var(--line-strong);
  background: var(--surface-hover);
  outline: none;
}

.settings-fab svg {
  width: 22px;
  height: 22px;
}

.settings-panel {
  position: absolute;
  top: 86px;
  right: calc(var(--action-rail-offset) + var(--action-rail-clearance));
  z-index: 6;
  width: min(360px, calc(100% - var(--action-rail-clearance) - 36px));
  max-height: min(calc(100% - 108px), calc(100dvh - 120px));
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--settings-panel-bg);
  box-shadow: var(--shadow);
  overflow-y: auto;
  overflow-x: hidden;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  touch-action: pan-y;
  transition:
    opacity 160ms ease,
    transform 160ms ease;
}

.settings-panel::-webkit-scrollbar {
  width: 10px;
}

.settings-panel::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
}

.settings-panel.is-hidden {
  opacity: 0;
  pointer-events: none;
  transform: translateY(-10px) scale(0.98);
}

.settings-panel-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
  margin-bottom: 14px;
}

.settings-section {
  display: grid;
  gap: 12px;
}

.settings-section + .settings-section {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.settings-language {
  margin-bottom: 14px;
}

.settings-preferences {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 14px;
}

.settings-filter-stack {
  display: grid;
  gap: 12px;
}

.settings-filter-group {
  display: grid;
  gap: 8px;
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--surface-soft);
}

.settings-filter-group .event-type-filter-buttons {
  margin-top: 2px;
}

.settings-filter-group .volcano-data-note {
  margin-top: 6px;
  margin-bottom: 0;
}

.settings-preferences .settings-language {
  margin-bottom: 0;
}

.settings-title {
  font-size: 1.15rem;
}

.settings-close {
  width: 44px;
  height: 44px;
  border-radius: 999px;
  font: inherit;
  font-weight: 700;
}

.settings-stat-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.settings-stat {
  display: grid;
  gap: 0.45rem;
  padding: 0.9rem;
  border-radius: 18px;
  background: var(--surface-soft);
  border: 1px solid var(--line);
}

.settings-stat-wide {
  grid-column: 1 / -1;
}

.settings-stat span {
  color: var(--muted);
  font-size: 0.73rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.settings-stat strong {
  font-size: 1.32rem;
  letter-spacing: -0.05em;
}

.settings-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.settings-chip {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  border-radius: 999px;
  padding: 0.5rem 0.8rem;
  border: 1px solid var(--line);
  background: var(--surface-soft);
  color: var(--text);
  font-size: 0.8rem;
}

.settings-actions {
  margin-top: 0;
}

.settings-action-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.settings-sound {
  margin-top: 0;
  grid-template-columns: 1fr;
}

#previewAlarmButton {
  display: none;
}

.globe-overlay-label {
  --globe-overlay-transform: translateX(-50%);
  top: auto;
  bottom: 18px;
  left: 50%;
  right: auto;
  transform: var(--globe-overlay-transform);
  padding: 0.65rem 0.95rem;
  background: var(--overlay-chip-bg);
  border: 1px solid var(--overlay-chip-border);
  color: var(--muted);
  font-size: 0.7rem;
  line-height: 1.1;
}

@media (max-width: 1180px) {
  .dashboard-solo {
    --desktop-header-clearance: 128px;
    --desktop-sidebar-width: min(320px, calc(100vw - 32px));
    --globe-legend-clearance: 128px;
  }

  .header-map-toolbar {
    margin-inline: 14px;
    gap: 10px;
  }

  .timeline-panel {
    width: var(--desktop-sidebar-width);
  }

  .globe-hud {
    width: min(460px, calc(100vw - 440px));
  }

  .desktop-map-controls {
    width: min(400px, calc(100vw - 420px));
    min-width: 300px;
  }

  .header-search-shell.is-open .header-search-panel {
    width: min(280px, max(200px, calc(100vw - 680px)));
  }

  .globe-date-shell.is-open .globe-date-panel {
    width: min(250px, max(216px, calc(100vw - 760px)));
  }
}

@media (max-width: 767px), ((max-width: 1023px) and (orientation: portrait)) {
  .dashboard-solo {
    display: grid;
    grid-template-rows: auto auto;
    width: 100%;
    height: auto;
    min-height: auto;
    gap: 10px;
    padding-top: 0;
    padding-bottom: 10px;
    overflow: visible;
  }

  .app-header {
    position: relative;
    top: auto;
    left: auto;
    right: auto;
    z-index: auto;
    align-items: center;
    padding: 10px 10px 2px;
    pointer-events: auto;
  }

  .app-brand {
    max-width: min(72vw, 440px);
  }

  .header-clock {
    display: none;
  }

  .monitor-layout {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
    height: auto;
    min-height: auto;
    position: relative;
  }

  .globe-stage-solo {
    order: 1;
    width: 100%;
    height: auto;
    min-height: 0;
    aspect-ratio: 1 / 1;
  }

  .timeline-panel {
    position: relative;
    top: auto;
    left: auto;
    z-index: auto;
    width: auto;
    min-height: auto;
    max-height: none;
    order: 2;
    border-radius: var(--radius);
    backdrop-filter: none;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.04), transparent 28%),
      #020202;
    box-shadow: var(--shadow);
  }

  .globe-shell.panel {
    border: 0;
    border-radius: 0;
    box-shadow: none;
  }

  .globe-shell {
    height: 100%;
    min-height: 0;
    overflow: visible;
  }

  .globe-frame-solo {
    height: 100%;
    min-height: 0;
  }

  .timeline-list {
    max-height: 42vh;
  }
  .settings-panel {
    max-height: min(560px, calc(100svh - 104px));
    padding-bottom: calc(22px + env(safe-area-inset-bottom));
  }

  .incident-alert {
    width: calc(100vw - 24px);
    bottom: max(12px, env(safe-area-inset-bottom));
    padding: 12px 13px;
    gap: 12px;
  }

  .globe-hud {
    top: 22px;
    bottom: auto;
    left: 22px;
    right: 86px;
    width: auto;
    min-width: 0;
    transform: none;
    text-align: left;
    justify-content: space-between;
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (max-width: 720px) {
  .app-header {
    position: relative;
    top: auto;
    left: auto;
    right: auto;
    align-items: flex-start;
    padding: 0;
  }

  .app-brand {
    gap: 12px;
    max-width: min(78vw, 360px);
  }

  .app-site-title {
    font-size: 0.82rem;
    letter-spacing: 0.1em;
  }

  .app-header-actions {
    gap: 10px;
  }

  .header-clock strong {
    font-size: 0.95rem;
  }

  .app-brand-logo {
    width: 50px;
    height: 50px;
  }

  .app-header-title {
    font-size: clamp(1.35rem, 7vw, 2rem);
  }

  .timeline-panel {
    position: relative;
    top: auto;
    left: auto;
    width: auto;
    max-height: none;
    border-radius: 24px;
  }

  .timeline-head {
    padding: 16px 14px 14px;
  }

  .timeline-body {
    padding-left: 14px;
    padding-right: 14px;
  }

  .timeline-list {
    padding-left: 14px;
    padding-right: 14px;
  }

  .timeline-meta-grid,
  .settings-stat-grid {
    grid-template-columns: 1fr 1fr;
  }

  .settings-preferences,
  .settings-action-grid {
    grid-template-columns: 1fr 1fr;
  }

  .timeline-entry-top {
    flex-direction: column;
  }

  .globe-hud {
    top: 16px;
    bottom: auto;
    left: 16px;
    right: 76px;
    width: auto;
  }

  .globe-overlay-label {
    bottom: 14px;
    max-width: calc(100vw - 24px);
    padding: 0.52rem 0.8rem;
    font-size: 0.62rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .settings-fab {
    width: 50px;
    height: 50px;
  }

  .settings-panel {
    top: 72px;
    right: calc(14px + var(--action-rail-clearance));
    width: calc(100% - var(--action-rail-clearance) - 24px);
    max-height: min(560px, calc(100svh - 86px));
  }

  .incident-alert {
    align-items: stretch;
    flex-direction: column;
  }

  .icon-action-button {
    min-height: 68px;
  }

  .incident-alert .control-button {
    width: 100%;
    justify-content: center;
  }

  .globe-stage-solo {
    aspect-ratio: 1 / 1;
  }
}

.app-site-row {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.header-connection-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  flex: 0 0 auto;
  background: #f59e0b;
  box-shadow: 0 0 0 1px rgba(245, 158, 11, 0.28), 0 0 14px rgba(245, 158, 11, 0.48);
}

.header-connection-dot.tone-steady {
  background: #22c55e;
  box-shadow: 0 0 0 1px rgba(34, 197, 94, 0.22), 0 0 14px rgba(34, 197, 94, 0.42);
}

.header-connection-dot.tone-high {
  animation: connection-dot-pulse 1.4s ease-in-out infinite;
}

.header-connection-dot.tone-critical,
.header-connection-dot.tone-stale {
  background: #ef4444;
  box-shadow: 0 0 0 1px rgba(239, 68, 68, 0.28), 0 0 14px rgba(239, 68, 68, 0.46);
  animation: connection-dot-pulse 0.92s ease-in-out infinite;
}

@keyframes connection-dot-pulse {
  0%,
  100% {
    opacity: 0.78;
    transform: scale(1);
  }

  50% {
    opacity: 1;
    transform: scale(1.18);
  }
}

.mobile-latest-bar,
.mobile-filter-bar,
.mobile-search-modal,
.mobile-stats-row,
.timeline-drawer-toggle,
.globe-legend-toggle,
.mobile-legend-popover,
.mobile-sound-options {
  display: none;
}

.settings-section-title {
  margin: 0;
  color: var(--kicker);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.settings-actions-notify {
  grid-template-columns: 1fr;
}

@keyframes shimmer {
  0% {
    background-position: -200% 0;
  }

  100% {
    background-position: 200% 0;
  }
}

.skeleton-block,
.skeleton-text {
  color: transparent !important;
  background: linear-gradient(90deg, var(--skeleton-base) 25%, var(--skeleton-mid) 50%, var(--skeleton-base) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s linear infinite;
  border-radius: 999px;
}

.skeleton-block {
  display: block;
}

.skeleton-text {
  display: inline-block;
  min-width: 3.2ch;
  min-height: 1.05em;
}

.timeline-entry-skeleton {
  pointer-events: none;
}

.timeline-entry-skeleton-copy {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.timeline-skeleton-line {
  width: 100%;
  height: 11px;
  border-radius: 999px;
}

.timeline-skeleton-line-short {
  width: 38%;
}

.timeline-skeleton-line-mid {
  width: 56%;
}

.timeline-skeleton-pill {
  width: 54px;
  height: 30px;
  border-radius: 999px;
}

button:focus-visible,
input:focus-visible,
select:focus-visible,
[role="button"]:focus-visible {
  outline: 2px solid #93c5fd;
  outline-offset: 2px;
}

:focus:not(:focus-visible) {
  outline: none;
}

.status-pill-loading,
.status-line.is-skeleton,
.timeline-copy.is-skeleton,
.timeline-meta-item strong.is-skeleton,
.settings-stat strong.is-skeleton {
  color: transparent !important;
  background: linear-gradient(90deg, var(--skeleton-base) 25%, var(--skeleton-mid) 50%, var(--skeleton-base) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s linear infinite;
}

.status-pill-loading {
  min-width: 98px;
  min-height: 32px;
  border-color: transparent;
  border-radius: 999px;
}

.status-line.is-skeleton {
  display: block;
  width: min(260px, 72%);
  min-height: 18px;
  border-radius: 999px;
}

.timeline-copy.is-skeleton {
  display: block;
  width: 100%;
  min-height: 44px;
  border-radius: 14px;
}

.timeline-meta-item strong.is-skeleton,
.settings-stat strong.is-skeleton {
  display: block;
  width: 68px;
  min-height: 1.2em;
  border-radius: 999px;
}

.mobile-latest-button {
  width: 100%;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  grid-template-areas:
    "mag region age"
    "mag meta age";
  align-items: center;
  gap: 2px 10px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(15, 21, 32, 0.94);
  color: var(--text);
  padding: 0.7rem 0.85rem;
  box-shadow: 0 18px 32px rgba(0, 0, 0, 0.28);
}

html[data-theme="light"] .mobile-latest-button {
  background: rgba(255, 255, 255, 0.94);
}

.mobile-latest-button:disabled {
  cursor: default;
}

.mobile-latest-mag,
.mobile-latest-mag-value {
  grid-area: mag;
}

.mobile-latest-region,
.mobile-latest-region-value {
  grid-area: region;
}

.mobile-latest-meta,
.mobile-latest-meta-value {
  grid-area: meta;
}

.mobile-latest-age,
.mobile-latest-age-value {
  grid-area: age;
  justify-self: end;
  text-align: right;
}

.mobile-latest-mag {
  width: 46px;
  height: 20px;
}

.mobile-latest-region {
  width: min(48vw, 160px);
  height: 14px;
}

.mobile-latest-meta {
  width: min(36vw, 120px);
  height: 12px;
}

.mobile-latest-age {
  width: 42px;
  height: 12px;
}

.mobile-latest-mag-value {
  font-size: 1.02rem;
  font-weight: 700;
  letter-spacing: -0.04em;
}

.mobile-latest-button.tone-critical .mobile-latest-mag-value {
  color: #ef4444;
}

.mobile-latest-button.tone-high .mobile-latest-mag-value {
  color: #f59e0b;
}

.mobile-latest-button.tone-low .mobile-latest-mag-value {
  color: #b1b5bb;
}

.mobile-latest-region-value {
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 0.82rem;
  font-weight: 600;
}

.mobile-latest-meta-value,
.mobile-latest-age-value {
  color: var(--muted);
  font-size: 0.72rem;
}

.mobile-search-open,
.filter-slider-shell.mobile-filter-slider {
  min-width: 0;
}

.mobile-search-open {
  appearance: none;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  font: inherit;
}

.mobile-search-open {
  display: none;
  align-items: center;
  justify-content: center;
}

.mobile-search-open svg {
  width: 18px;
  height: 18px;
}

.mobile-filter-bar .event-type-filter-shell {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}

html[data-theme="light"] .mobile-filter-bar .event-type-filter-shell {
  background: transparent;
}

.mobile-filter-folder {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(13, 17, 23, 0.92);
  overflow: hidden;
}

html[data-theme="light"] .mobile-filter-folder {
  background: rgba(255, 255, 255, 0.92);
}

.mobile-filter-folder[open] {
  box-shadow: 0 16px 28px rgba(0, 0, 0, 0.16);
}

.mobile-filter-folder-summary {
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 48px;
  padding: 0.82rem 0.95rem;
  cursor: pointer;
}

.mobile-filter-folder-summary::-webkit-details-marker {
  display: none;
}

.mobile-filter-folder-summary::after {
  content: "▾";
  color: var(--muted);
  font-size: 0.9rem;
  flex: 0 0 auto;
  transition: transform 160ms ease;
}

.mobile-filter-folder[open] .mobile-filter-folder-summary::after {
  transform: rotate(180deg);
}

.mobile-filter-folder-title {
  color: var(--text);
  font-size: 0.86rem;
  font-weight: 700;
}

.mobile-filter-folder-value {
  color: #f5e087;
  font-size: 0.82rem;
  font-weight: 700;
  text-align: right;
}

.mobile-filter-folder-body {
  display: grid;
  gap: 10px;
  padding: 0 12px 12px;
  border-top: 1px solid var(--line);
}

.mobile-search-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.mobile-search-title {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.mobile-search-close {
  appearance: none;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-size: 1.35rem;
  line-height: 1;
}

.mobile-search-field {
  display: grid;
  gap: 10px;
}

.mobile-search-field .sound-select {
  min-height: 52px;
  font-size: 1rem;
}

.mobile-date-navigator {
  grid-template-columns: 52px minmax(0, 1fr) 52px;
  min-height: 72px;
}

.mobile-date-navigator .globe-date-nav-button {
  width: 52px;
  height: 52px;
  border-radius: 16px;
}

.mobile-date-navigator .globe-date-value {
  font-size: 1rem;
}

.timeline-drawer-toggle {
  appearance: none;
  width: 100%;
  min-height: 44px;
  padding: 4px 0;
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

.timeline-drawer-grip {
  display: block;
  width: 40px;
  height: 5px;
  margin: 0;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.7);
}

.timeline-drawer-label {
  display: block;
  font-size: 0.92rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--timeline-primary-text);
  text-align: left;
}

.mobile-stat-chip {
  min-width: 0;
  padding: 0.52rem 0.6rem;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(13, 17, 23, 0.92);
}

html[data-theme="light"] .mobile-stat-chip {
  background: rgba(255, 255, 255, 0.92);
}

.mobile-stat-chip span {
  display: block;
  color: var(--muted);
  font-size: 0.62rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.mobile-stat-chip strong {
  display: block;
  margin-top: 0.2rem;
  font-size: 0.88rem;
  letter-spacing: -0.03em;
}

.globe-legend-toggle {
  appearance: none;
  position: relative;
  left: auto;
  right: auto;
  bottom: auto;
  z-index: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1;
}

.mobile-legend-popover {
  position: absolute;
  left: auto;
  right: calc(var(--action-rail-offset) + var(--action-rail-clearance));
  bottom: 0;
  z-index: 8;
  width: min(320px, calc(100% - 36px));
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface-strong);
  box-shadow: 0 22px 36px rgba(0, 0, 0, 0.42);
  display: grid;
  gap: 8px;
  transition:
    opacity 180ms ease,
    transform 180ms ease;
}

.mobile-legend-popover.is-hidden {
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
}

.mobile-sound-options {
  display: grid;
  gap: 8px;
}

.mobile-sound-option {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 0.7rem 0.8rem;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface-soft);
}

.mobile-sound-option.is-selected {
  border-color: #3b82f6;
  box-shadow: inset 0 0 0 1px rgba(59, 130, 246, 0.24);
}

.mobile-sound-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.mobile-sound-icon {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--muted);
}

.mobile-sound-icon svg {
  width: 18px;
  height: 18px;
}

.mobile-sound-option.is-selected .mobile-sound-icon {
  color: #dbeafe;
  border-color: rgba(147, 197, 253, 0.44);
  background: rgba(59, 130, 246, 0.16);
}

.mobile-sound-name {
  min-width: 0;
  font-size: 0.9rem;
  font-weight: 600;
}

.mobile-sound-check {
  width: 20px;
  height: 20px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: transparent;
  position: relative;
}

.mobile-sound-check::after {
  content: "";
  position: absolute;
  inset: 4px;
  border-radius: 999px;
  background: transparent;
  transition: background 180ms ease;
}

.mobile-sound-option.is-selected .mobile-sound-check {
  border-color: #93c5fd;
  background: rgba(59, 130, 246, 0.12);
}

.mobile-sound-option.is-selected .mobile-sound-check::after {
  background: #93c5fd;
}

.settings-notification-slider .filter-slider-scale {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.settings-toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-width: 0;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface-soft);
}

.settings-inline-toggle {
  appearance: none;
  min-width: 72px;
  min-height: 38px;
  padding: 0.55rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font: inherit;
  font-size: 0.82rem;
  font-weight: 700;
}

.settings-inline-toggle.is-active {
  border-color: rgba(96, 165, 250, 0.36);
  background: rgba(59, 130, 246, 0.14);
  color: #dbeafe;
}

@media (max-width: 767px), ((max-width: 1023px) and (orientation: portrait)) {
  body {
    overflow: hidden;
  }

  .dashboard-solo {
    --mobile-bottom-sheet-peek: clamp(156px, 24dvh, 196px);
    --mobile-bottom-sheet-expanded: min(72dvh, 560px);
    --mobile-overlay-offset: calc(var(--mobile-bottom-sheet-peek) + 12px);
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100dvh;
    min-height: 100dvh;
    padding: 0;
    overflow: hidden;
  }

  .app-header {
    position: relative;
    top: auto;
    left: auto;
    right: auto;
    z-index: 20;
    flex: 0 0 auto;
    min-height: 32px;
    padding:
      max(env(safe-area-inset-top), 12px)
      max(env(safe-area-inset-right), 12px)
      4px
      max(env(safe-area-inset-left), 12px);
    align-items: center;
    gap: 12px;
    pointer-events: auto;
  }

  .app-brand {
    max-width: none;
    gap: 10px;
    align-items: center;
  }

  .app-brand-logo {
    width: 28px;
    height: 28px;
  }

  .app-brand-copy {
    display: block;
    min-width: 0;
  }

  .app-header-title {
    min-width: 0;
    font-size: 1rem;
    line-height: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .app-header-actions {
    gap: 8px;
  }

  .header-search-shell {
    display: none;
  }

  .globe-date-shell {
    display: none;
  }

  .header-map-toolbar {
    display: none;
  }

  .timeline-desktop-filter-row {
    display: none;
  }

  .header-clock {
    display: none;
  }

  .settings-fab {
    width: 44px;
    height: 44px;
  }

  .mobile-latest-bar {
    display: block;
    flex: 0 0 auto;
    padding: 4px 12px 8px;
    z-index: 18;
  }

  .mobile-filter-bar {
    display: grid;
    gap: 8px;
    flex: 0 0 auto;
    padding: 0 12px 8px;
    z-index: 18;
  }

  .mobile-filter-slider {
    min-width: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
  }

  .mobile-date-open {
    flex: 0 0 auto;
  }

  .mobile-filter-bar .event-type-filter-buttons {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .mobile-filter-bar .event-type-filter-button {
    min-height: 46px;
  }

  html[data-theme="light"] .mobile-filter-slider {
    background: transparent;
  }

  .mobile-search-modal {
    position: fixed;
    inset: 0;
    z-index: 32;
    display: grid;
    transition: opacity 180ms ease;
  }

  .mobile-search-modal.is-hidden {
    opacity: 0;
    pointer-events: none;
  }

  .mobile-search-backdrop {
    appearance: none;
    position: absolute;
    inset: 0;
    border: 0;
    background: rgba(0, 0, 0, 0.58);
  }

  .mobile-search-sheet {
    position: relative;
    align-self: end;
    display: grid;
    gap: 16px;
    padding: 16px 16px calc(22px + env(safe-area-inset-bottom));
    border-radius: 26px 26px 0 0;
    border: 1px solid var(--line);
    border-bottom: 0;
    background: var(--settings-panel-bg);
    box-shadow: 0 -24px 60px rgba(0, 0, 0, 0.42);
    transform: translateY(0);
    transition: transform 180ms ease;
  }

  .mobile-search-modal.is-hidden .mobile-search-sheet {
    transform: translateY(18px);
  }

  .history-banner {
    top: calc(env(safe-area-inset-top) + 108px);
    left: 12px;
    right: 12px;
    max-width: none;
    padding: 0.7rem 0.85rem;
    transform: none;
    display: grid;
    gap: 10px;
  }

  .history-banner.is-hidden {
    transform: translateY(-8px);
  }

  .monitor-layout {
    flex: 1 1 auto;
    min-height: 0;
    position: relative;
    display: block;
    overflow: hidden;
  }

  .globe-stage-solo {
    order: 0;
    height: 100%;
    min-height: 0;
    aspect-ratio: auto;
    width: 100%;
  }

  .globe-shell {
    --action-rail-button-size: 54px;
    --action-rail-gap: 8px;
    --action-rail-offset: 12px;
    --action-rail-clearance: calc(var(--action-rail-button-size) + var(--action-rail-gap) + 8px);
    height: 100%;
    overflow: hidden;
    border-radius: 0;
  }

  .globe-hud,
  .desktop-map-controls {
    display: none;
  }

  .globe-overlay-label {
    left: 50%;
    right: auto;
    bottom: var(--mobile-overlay-offset);
    top: auto;
    max-width: calc(100% - 28px);
    transform: translateX(-50%);
    padding: 0.52rem 0.78rem;
    text-align: center;
    font-size: 0.72rem;
    line-height: 1.2;
  }

  .globe-action-rail {
    right: var(--action-rail-offset);
    bottom: calc(var(--mobile-overlay-offset) + 4px);
  }

  .alarm-center-panel {
    right: calc(var(--action-rail-offset) + var(--action-rail-clearance));
    width: min(320px, calc(100vw - 84px));
    max-height: min(320px, calc(100% - 64px));
    bottom: calc(var(--mobile-overlay-offset) + 4px);
  }

  .globe-legend-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
  }

  .mobile-legend-popover {
    display: grid;
    right: calc(var(--action-rail-offset) + var(--action-rail-clearance));
    bottom: calc(var(--mobile-overlay-offset) + 4px);
    width: min(280px, calc(100vw - 88px));
  }

  .globe-location-fab {
    width: 44px;
    height: 44px;
  }

  .header-search-shell,
  .globe-date-shell {
    display: none;
  }

  .mobile-search-open {
    display: inline-flex;
    width: 44px;
    height: 44px;
  }

  .mobile-stats-row {
    position: absolute;
    top: 12px;
    left: 12px;
    right: 12px;
    z-index: 5;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    padding: 0;
    background: transparent;
    pointer-events: none;
  }

  .mobile-stat-chip {
    backdrop-filter: blur(16px);
    box-shadow: 0 16px 30px rgba(0, 0, 0, 0.24);
  }

  html[data-theme="light"] .mobile-stats-row {
    background: transparent;
  }

  .timeline-panel {
    position: absolute;
    inset: auto 0 0;
    top: auto;
    left: 0;
    right: 0;
    z-index: 12;
    width: auto;
    min-height: var(--mobile-bottom-sheet-peek);
    height: var(--mobile-bottom-sheet-peek);
    max-height: var(--mobile-bottom-sheet-peek);
    margin: 0;
    border-width: 1px 0 0;
    border-radius: 28px 28px 0 0;
    background: var(--timeline-panel-bg);
    backdrop-filter: blur(22px);
    box-shadow: 0 -24px 56px rgba(0, 0, 0, 0.42);
    transition:
      height 220ms ease,
      max-height 220ms ease,
      transform 220ms ease;
  }

  .timeline-panel.is-drawer-expanded {
    height: var(--mobile-bottom-sheet-expanded);
    max-height: var(--mobile-bottom-sheet-expanded);
  }

  .timeline-head {
    padding: 8px 16px 6px;
    background: linear-gradient(180deg, rgba(5, 5, 5, 0.96), rgba(5, 5, 5, 0.84));
  }

  html[data-theme="light"] .timeline-head {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(255, 255, 255, 0.84));
  }

  .timeline-head-top {
    display: block;
  }

  .timeline-drawer-toggle {
    position: relative;
    display: block;
    width: 100%;
    min-height: 56px;
    padding: 16px 0 0;
    touch-action: none;
    user-select: none;
    -webkit-user-select: none;
    text-align: left;
  }

  .timeline-drawer-toggle .timeline-drawer-grip {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
  }

  .timeline-drawer-toggle .timeline-drawer-label {
    display: block;
    width: 100%;
    padding-left: 4px;
    text-align: left;
  }

  .timeline-head .panel-kicker {
    display: none;
  }

  .timeline-panel.is-dragging {
    transition: none;
  }

  .timeline-content {
    min-height: 0;
    grid-template-rows: minmax(0, 1fr);
  }

  .timeline-body {
    display: none;
  }

  .timeline-list {
    min-height: 0;
    padding: 0 12px calc(14px + env(safe-area-inset-bottom));
    gap: 8px;
  }

  .timeline-entry {
    gap: 6px;
    padding: 10px 12px;
    border-radius: 18px;
  }

  .timeline-entry-top {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    align-items: start;
  }

  .timeline-entry-time {
    font-size: 0.72rem;
  }

  .timeline-entry-place {
    font-size: 0.9rem;
  }

  .timeline-entry-region {
    font-size: 0.76rem;
  }

  .timeline-entry-meta {
    gap: 4px 8px;
    font-size: 0.72rem;
  }

  .timeline-mag {
    min-width: 52px;
    justify-content: center;
    padding: 0.34rem 0.55rem;
    font-size: 0.78rem;
  }

  .timeline-panel:not(.is-drawer-expanded) .timeline-ad-card {
    display: none;
  }

  .timeline-panel:not(.is-drawer-expanded) .timeline-footer {
    display: none;
  }

  .timeline-panel:not(.is-drawer-expanded) .timeline-list {
    mask-image: linear-gradient(180deg, #000 0 70%, transparent 100%);
  }

  .settings-panel {
    position: fixed;
    inset: auto 0 0;
    z-index: 26;
    width: 100%;
    height: min(90dvh, 760px);
    max-height: min(90dvh, 760px);
    padding: 16px 16px calc(24px + env(safe-area-inset-bottom));
    border-radius: 28px 28px 0 0;
    border-bottom: 0;
    transform: translateY(0);
  }

  .settings-panel.is-hidden {
    transform: translateY(104%);
  }

  .settings-panel-head {
    position: sticky;
    top: 0;
    z-index: 1;
    padding-bottom: 10px;
    background: var(--settings-panel-bg);
  }

  .settings-close {
    width: 44px;
    height: 44px;
  }

  .settings-preferences,
  .settings-stat-grid {
    grid-template-columns: 1fr;
  }

  .settings-action-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .settings-actions {
    margin-top: 10px;
  }

  .icon-action-button {
    min-height: 56px;
  }

  #previewAlarmButton,
  .settings-sound > label:nth-of-type(2) {
    display: none;
  }

  .mobile-sound-options {
    display: grid;
  }

  .incident-alert {
    top: auto;
    bottom: calc(var(--mobile-overlay-offset) + 18px);
    left: 12px;
    right: 12px;
    width: auto;
    padding: 12px 12px 12px 14px;
    border-radius: 18px;
    transform: none;
  }

  .incident-alert.is-hidden {
    transform: translateY(12px);
  }

  .incident-alert .control-button {
    width: 100%;
    min-height: 52px;
    padding-inline: 1rem;
  }

  .dashboard-solo.is-mobile-timeline-expanded {
    --mobile-overlay-offset: calc(var(--mobile-bottom-sheet-expanded) + 12px);
  }
}
