:root {
  --ink: #162026;
  --muted: #687783;
  --line: #dde5ea;
  --paper: #f7f9fb;
  --panel: #ffffff;
  --navy: #17324d;
  --sky: #2f80a7;
  --green: #27745f;
  --gold: #b07a30;
  --red: #b54a48;
  --shadow: 0 18px 45px rgba(22, 32, 38, 0.1);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
}

a {
  color: inherit;
  text-decoration: none;
}

.shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 252px 1fr;
}

.sidebar {
  background: #101c28;
  color: #eff6fb;
  padding: 26px 18px;
  position: sticky;
  top: 0;
  height: 100vh;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 28px;
}

.mark {
  width: 38px;
  height: 38px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: #d7ecf6;
  color: #102334;
  font-weight: 800;
}

.brand strong {
  display: block;
  font-size: 18px;
}

.brand span,
.nav small {
  color: #9fb1bf;
  font-size: 12px;
}

.nav {
  display: grid;
  gap: 6px;
}

.nav a {
  border-radius: 8px;
  padding: 11px 12px;
  color: #d8e5ee;
  font-weight: 650;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav a:hover,
.nav a.active {
  background: #203346;
  color: #fff;
}

.main {
  min-width: 0;
}

.topbar {
  min-height: 76px;
  padding: 18px 34px;
  background: rgba(247, 249, 251, 0.92);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
}

.topbar h1 {
  margin: 0;
  font-size: clamp(24px, 3vw, 34px);
  letter-spacing: 0;
}

.topbar p {
  margin: 2px 0 0;
  color: var(--muted);
}

.content {
  padding: 30px 34px 46px;
  max-width: 1320px;
}

.hero {
  min-height: 360px;
  background:
    linear-gradient(90deg, rgba(12, 27, 40, 0.92), rgba(18, 46, 64, 0.7), rgba(20, 91, 110, 0.32)),
    url("https://images.unsplash.com/photo-1436491865332-7a61a109cc05?auto=format&fit=crop&w=1800&q=80") center/cover;
  color: #fff;
  padding: 44px;
  border-radius: 8px;
  display: grid;
  align-content: end;
  box-shadow: var(--shadow);
  margin-bottom: 24px;
}

.hero h2 {
  max-width: 760px;
  margin: 0 0 12px;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.03;
  letter-spacing: 0;
}

.hero p {
  margin: 0;
  max-width: 650px;
  font-size: 18px;
  color: #dbe8ef;
}

.radar-panel {
  background: #101c28;
  color: #eef7fb;
  border-radius: 8px;
  padding: 18px;
  box-shadow: var(--shadow);
}

.radar-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin-bottom: 14px;
}

.radar-top h2 {
  margin: 0;
  font-size: 22px;
}

.radar-map {
  position: relative;
  min-height: 430px;
  overflow: hidden;
  border-radius: 8px;
  background:
    linear-gradient(rgba(108, 151, 170, 0.18) 1px, transparent 1px),
    linear-gradient(90deg, rgba(108, 151, 170, 0.18) 1px, transparent 1px),
    radial-gradient(circle at 30% 38%, rgba(47, 128, 167, 0.38), transparent 22%),
    radial-gradient(circle at 68% 42%, rgba(39, 116, 95, 0.28), transparent 20%),
    #0b1722;
  background-size: 42px 42px, 42px 42px, auto, auto, auto;
  border: 1px solid rgba(221, 229, 234, 0.18);
}

.radar-map::before,
.radar-map::after {
  content: "";
  position: absolute;
  inset: 14%;
  border: 1px solid rgba(215, 236, 246, 0.16);
  border-radius: 50%;
}

.radar-map::after {
  inset: 29%;
}

.radar-label {
  position: absolute;
  color: rgba(238, 247, 251, 0.62);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.radar-label.london {
  left: 44%;
  top: 70%;
}

.radar-label.paris {
  left: 52%;
  top: 82%;
}

.radar-label.ams {
  left: 58%;
  top: 60%;
}

.plane-dot {
  position: absolute;
  width: 23px;
  height: 23px;
  border: 0;
  padding: 0;
  min-height: 0;
  background: transparent;
  cursor: pointer;
  z-index: 2;
}

.plane-dot::before {
  content: "";
  position: absolute;
  inset: 4px 10px 2px;
  background: #f1c66d;
  border-radius: 10px 10px 3px 3px;
  box-shadow: 0 0 12px rgba(241, 198, 109, 0.55);
}

.plane-dot::after {
  content: "";
  position: absolute;
  left: 3px;
  top: 10px;
  width: 17px;
  height: 4px;
  background: #f1c66d;
  border-radius: 999px;
}

.radar-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.radar-strip div {
  background: rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: 12px;
}

.radar-strip strong {
  display: block;
  font-size: 24px;
}

.radar-table {
  margin-top: 18px;
  max-height: 430px;
  overflow: auto;
}

.radar-table table {
  min-width: 560px;
}

.radar-table th,
.radar-table td {
  border-color: rgba(221, 229, 234, 0.12);
  color: #eef7fb;
}

.radar-table .muted {
  color: #9fb1bf;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.button,
button {
  border: 0;
  border-radius: 8px;
  padding: 11px 15px;
  background: var(--navy);
  color: #fff;
  font-weight: 750;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
}

.button.secondary,
button.secondary {
  background: #e8eef2;
  color: var(--ink);
}

.button.ghost {
  background: transparent;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.36);
}

.button.danger,
button.danger {
  background: var(--red);
}

.grid {
  display: grid;
  gap: 18px;
}

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

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

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

.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 20px;
  box-shadow: 0 8px 22px rgba(22, 32, 38, 0.04);
}

.stat strong {
  display: block;
  font-size: 30px;
  line-height: 1;
}

.stat span,
.muted {
  color: var(--muted);
}

.section-title {
  margin: 30px 0 14px;
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: end;
}

.section-title h2 {
  margin: 0;
  font-size: 22px;
}

.section-title p {
  margin: 4px 0 0;
  color: var(--muted);
}

.flight-card {
  display: grid;
  gap: 16px;
}

.flight-head,
.route-line,
.row {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
}

.flight-number {
  font-weight: 850;
  font-size: 18px;
}

.pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 5px 9px;
  font-size: 12px;
  font-weight: 750;
  color: var(--navy);
  background: #e8f2f7;
}

.pill.good {
  color: var(--green);
  background: #e8f5f1;
}

.pill.warn {
  color: var(--gold);
  background: #fbf2e4;
}

.radar-panel .pill.warn {
  background: rgba(176, 122, 48, 0.22);
  color: #f1c66d;
}

.airport-code {
  font-size: 30px;
  font-weight: 850;
  letter-spacing: 0;
}

.route-rule {
  height: 2px;
  flex: 1;
  background: linear-gradient(90deg, var(--sky), var(--gold));
  min-width: 50px;
}

.meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  color: var(--muted);
  font-size: 14px;
}

.price {
  color: var(--green);
  font-weight: 850;
  font-size: 20px;
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 760px;
}

th,
td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

th {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

tr:last-child td {
  border-bottom: 0;
}

form {
  margin: 0;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  align-items: end;
}

label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-weight: 700;
  font-size: 13px;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  border-radius: 8px;
  padding: 12px 13px;
  font: inherit;
}

textarea {
  min-height: 110px;
  resize: vertical;
}

.auth {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 460px;
  background: #101c28;
}

.auth-art {
  background:
    linear-gradient(90deg, rgba(16, 28, 40, 0.88), rgba(16, 28, 40, 0.28)),
    url("https://images.unsplash.com/photo-1464037866556-6812c9d1c72e?auto=format&fit=crop&w=1600&q=80") center/cover;
  color: #fff;
  padding: 46px;
  display: grid;
  align-content: end;
}

.auth-art h1 {
  margin: 0 0 10px;
  max-width: 720px;
  font-size: clamp(38px, 6vw, 72px);
  line-height: 1.02;
}

.auth-panel {
  background: var(--paper);
  padding: 38px;
  display: grid;
  align-content: center;
}

.auth-panel .card {
  box-shadow: var(--shadow);
}

.stack {
  display: grid;
  gap: 14px;
}

.flash {
  padding: 12px 14px;
  border-radius: 8px;
  background: #e8f5f1;
  color: var(--green);
  margin-bottom: 18px;
  font-weight: 700;
}

.flash.error {
  background: #fae9e8;
  color: var(--red);
}

.empty {
  padding: 28px;
  text-align: center;
  color: var(--muted);
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: #fff;
}

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

  .sidebar {
    position: static;
    height: auto;
  }

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

  .grid.cols-2,
  .grid.cols-3,
  .grid.cols-4,
  .radar-strip,
  .form-grid {
    grid-template-columns: 1fr;
  }

  .auth-art {
    min-height: 380px;
  }
}

@media (max-width: 640px) {
  .topbar,
  .content,
  .hero,
  .auth-panel,
  .auth-art {
    padding: 22px;
  }

  .topbar,
  .flight-head,
  .row,
  .section-title {
    align-items: flex-start;
    flex-direction: column;
  }

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

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