@media (max-width: 1180px) {
  .app-shell {
    grid-template-columns: 78px minmax(0, 1fr);
  }

  .side-nav {
    padding: 18px 10px;
    align-items: stretch;
  }

  .brand strong {
    font-size: 0.98rem;
  }

  .brand span,
  .side-meta {
    display: none;
  }

  .nav-links a {
    justify-content: center;
    padding: 0 8px;
  }

  .nav-label {
    display: none;
  }

  .nav-short {
    display: inline;
  }

  .dashboard-grid,
  .live-grid,
  .about-grid {
    grid-template-columns: 1fr;
  }

  .next-grid,
  .field-grid {
    grid-template-columns: 1fr;
  }

  .detail-grid {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: repeat(4, minmax(250px, auto));
    grid-template-areas:
      "radar map"
      "doppler frequency"
      "info info"
      "solar solar";
  }

  .detail-pane-info {
    grid-row: auto;
  }
}

@media (max-width: 760px) {
  html,
  body {
    max-width: 100%;
    overflow-x: hidden;
  }

  .app-shell {
    display: block;
    height: auto;
    min-height: 100vh;
    width: 100%;
    max-width: 100%;
    overflow: visible;
    padding-bottom: 76px;
  }

  .side-nav {
    position: fixed;
    inset: auto 0 0;
    z-index: 30;
    height: 64px;
    display: block;
    padding: 8px;
    border-top: 1px solid var(--line);
    border-right: 0;
    max-width: 100vw;
  }

  .brand,
  .side-meta {
    display: none;
  }

  .nav-links {
    height: 100%;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 4px;
  }

  .nav-links a {
    min-height: 48px;
    padding: 0 4px;
    font-size: 0.78rem;
  }

  .nav-links a.active {
    box-shadow: inset 0 -3px 0 var(--accent);
  }

  .app-main {
    height: auto;
    overflow: visible;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    padding: 18px 14px 24px;
  }

  .mobile-site-meta {
    display: grid;
    gap: 5px;
    margin-top: 22px;
    padding: 16px 4px 6px;
    border-top: 1px solid var(--line);
    color: var(--muted);
    font-size: 0.86rem;
    line-height: 1.25;
    text-align: center;
  }

  .mobile-site-meta a {
    color: var(--link);
    text-decoration: none;
    font-weight: 700;
  }

  .topbar {
    display: grid;
  }

  h1 {
    max-width: 100%;
    font-size: 2.25rem;
    line-height: 1;
  }

  .panel,
  .settings-section,
  .planning-day,
  .live-card,
  .about-panel {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    padding: 14px;
  }

  .station-row,
  .header-tools {
    display: grid;
    justify-content: stretch;
  }

  .table-wrap {
    max-width: 100%;
    overflow-x: auto;
    overscroll-behavior-x: contain;
  }

  table {
    width: max-content;
    min-width: 760px;
    font-size: 0.86rem;
  }

  th,
  td {
    padding: 10px 12px;
  }

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

  .button,
  .icon-button,
  .ghost-button {
    width: 100%;
  }

  .segmented {
    width: 100%;
    grid-auto-flow: initial;
    grid-template-columns: repeat(3, 1fr);
  }

  .segmented[data-range-count="2"],
  .band-toggle {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .band-toggle span {
    width: 100%;
    justify-content: center;
  }

  .planning-pass {
    display: grid;
    grid-template-columns: 1fr;
  }

  .planning-pass-actions {
    justify-content: stretch;
  }

  .tiny-action {
    width: 100%;
  }

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

  .detail-overlay {
    padding: 0;
  }

  .detail-panel {
    height: 100dvh;
    border-radius: 0;
    border: 0;
  }

  .detail-header {
    align-items: start;
    padding: 14px;
  }

  .detail-header h2 {
    font-size: 1.2rem;
  }

  .close-button {
    width: auto;
  }

  .detail-grid {
    grid-template-columns: 1fr;
    grid-template-rows: none;
    grid-template-areas:
      "radar"
      "map"
      "doppler"
      "frequency"
      "info"
      "solar";
    padding: 10px;
  }

  .detail-pane {
    min-height: 310px;
  }

  .detail-pane-info,
  .detail-pane-frequency {
    min-height: auto;
  }

  .info-grid div,
  .frequency-list div,
  .solar-list div {
    align-items: start;
  }
}
