:root {
  color-scheme: dark;
  --bg: #101e30;
  --panel: #192e44;
  --blue: #75c9ff;
  --orange: #ffbd52;
  --green: #83dbab;
  --red: #ff6666;
  font-family: "DejaVu Sans", system-ui, sans-serif;
  color: #fff;
  background: var(--bg);
}
* { box-sizing: border-box; }
body { margin: 0 auto; padding: 0 .4rem; max-width: 1600px; font-weight: 700; }
header { position: relative; min-height: 100px; height: 15vh; display: grid; align-content: center; text-align: center; padding-inline: clamp(52px, 12vw, 145px); }
header img { position: absolute; left: 2%; top: 50%; transform: translateY(-50%); width: clamp(40px, 9vw, 128px); max-height: 96%; object-fit: contain; }
h1, h2, h3, p { margin: .2em 0; }
h1 { color: var(--blue); font-size: clamp(1.05rem, 3vw, 2rem); }
header p { font-size: clamp(.7rem, 1.6vw, 1rem); }
.instruments, .runways { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .3rem; }
.instruments { min-height: 360px; height: 57vh; grid-template-rows: minmax(0, 1fr); }
.wind { display: grid; grid-template-rows: minmax(0, 1fr) auto auto; text-align: center; padding-bottom: .3rem; }
canvas { display: block; width: 100%; height: 100%; }
#compass { contain: size; min-height: 0; min-width: 0; }
#wind { color: var(--orange); font-size: clamp(1.25rem, 3vw, 2.2rem); }
.tiles { display: grid; grid-template: repeat(3, 1fr) / repeat(2, minmax(0, 1fr)); gap: .3rem; }
.tile { background: var(--panel); text-align: center; display: grid; place-content: center; padding: .5rem; }
.tile h2 { font-size: clamp(.7rem, 1.7vw, 1.05rem); }
.tiles p { color: var(--blue); font-size: clamp(1rem, 2.8vw, 2rem); }
.tiles .tile:last-child { grid-column: span 2; }
.runways { min-height: 110px; height: 17vh; margin-top: .3rem; }
.runways p { white-space: pre-line; font-size: clamp(.75rem, 1.6vw, 1.05rem); }
footer { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: .65rem 1rem; text-align: center; min-height: 9vh; padding: .45rem; font-size: .82rem; }
#status, #countdown { color: var(--orange); }
nav { display: flex; justify-content: center; gap: .35rem; flex-wrap: wrap; }
button, nav a { border: 0; padding: .65em .8em; background: #245476; color: white; font: inherit; text-decoration: none; cursor: pointer; }
button[aria-pressed="true"] { outline: 2px solid var(--blue); outline-offset: -2px; }
#history { text-align: center; }
#history h2, #history h3 { color: var(--blue); }
#history .plot:last-child h3 { color: var(--orange); }
.plot canvas { height: max(180px, 25vh); }
.plot { padding: .6rem .2rem; }
@media (max-width: 590px) {
  .instruments { height: auto; grid-template: auto auto / minmax(0, 1fr); }
  .wind { height: 330px; }
  .tiles { grid-template-rows: repeat(3, minmax(65px, auto)); }
  .runways { height: auto; }
}

.external-media { margin: 1.25rem 0; padding: 1rem; background: var(--panel); }
.external-media h2 { color: var(--blue); margin-bottom: .75rem; }
.external-media a { color: var(--blue); }
.forecast-frame { display: block; width: 100%; height: 360px; border: 0; background: #fff; }
.camera-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 360px), 1fr)); gap: 1rem; }
.camera iframe { display: block; width: 100%; aspect-ratio: 16 / 9; border: 0; background: var(--bg); }
.camera h3, .camera p, .external-media p { margin-block: .5rem; }
