html,
body {
  height: 100%;
}

body {
  min-height: 100vh;
  color: #f8fafc;
  font-family: var(--aerotico-font-ui);
  background:
    radial-gradient(circle at top, rgba(30, 94, 255, 0.22), transparent 36%),
    radial-gradient(circle at right, rgba(20, 184, 166, 0.12), transparent 28%),
    var(--aerotico-navy);
}

.card {
  border-radius: 1rem;
}

.app-shell {
  display: grid;
  grid-template-columns: minmax(320px, 400px) minmax(0, 1fr);
  gap: 1rem;
  min-height: 100vh;
  padding: 1rem;
}

.app-sidebar {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 1rem;
  min-height: 0;
}

.app-main {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  gap: 1rem;
  min-height: 0;
}

.app-dock {
  display: grid;
  grid-template-columns: minmax(320px, 420px) minmax(0, 1fr);
  gap: 1rem;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--aerotico-font-display);
}

.hero-card {
  background:
    linear-gradient(160deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.01)),
    rgba(11, 31, 58, 0.95);
}

.panel-card {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.015)),
    rgba(7, 17, 33, 0.94);
}

.brand-logo {
  display: block;
  width: min(100%, 320px);
  height: auto;
}

.hero-copy {
  color: rgba(226, 232, 240, 0.82);
}

.hero-badge {
  background: var(--aerotico-blue) !important;
}

.sidebar-cta-stack {
  display: grid;
  gap: 0.75rem;
}

.hero-hint {
  color: rgba(226, 232, 240, 0.7);
  font-size: 0.92rem;
  line-height: 1.45;
}

.form-feedback {
  color: rgba(226, 232, 240, 0.74);
}

.list-group-item {
  background: transparent;
  border-color: rgba(121, 227, 125, 0.12);
  color: #f8f9fa;
}

.form-control,
.form-check-input {
  border-color: rgba(30, 94, 255, 0.28);
}

.form-control {
  background: rgba(255, 255, 255, 0.03);
  color: #f8fafc;
}

.form-control:focus {
  background: rgba(255, 255, 255, 0.05);
  color: #f8fafc;
  border-color: rgba(20, 184, 166, 0.7);
  box-shadow: 0 0 0 0.25rem rgba(30, 94, 255, 0.18);
}

.form-label,
.form-check-label {
  color: rgba(248, 250, 252, 0.88);
}

.btn-primary {
  background: linear-gradient(135deg, var(--aerotico-blue), var(--aerotico-teal));
  border: 0;
}

.btn-outline-info {
  color: #7dd3fc;
  border-color: rgba(125, 211, 252, 0.45);
}

.btn-outline-info:hover {
  background: rgba(20, 184, 166, 0.14);
  border-color: rgba(20, 184, 166, 0.65);
}

.live-output {
  min-height: 300px;
  max-height: 360px;
  overflow: auto;
  white-space: pre-wrap;
  word-break: break-word;
  background: rgba(15, 23, 42, 0.88);
  border: 1px solid rgba(30, 94, 255, 0.18);
  border-radius: 0.75rem;
  color: #93c5fd;
  padding: 1rem;
}

.map-panel {
  height: min(72vh, 860px);
  min-height: 560px;
  border-bottom-left-radius: 1rem;
  border-bottom-right-radius: 1rem;
  overflow: hidden;
}

.map-card,
.sidebar-list-card,
.live-card,
.weather-stack-card {
  min-height: 0;
}

.sidebar-list-card .card-body {
  display: flex;
  flex-direction: column;
  min-height: 0;
}

#aircraft-list {
  overflow: auto;
}

.aircraft-modal {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: grid;
  place-items: center;
  padding: 1rem;
}

.aircraft-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 6, 23, 0.72);
  backdrop-filter: blur(10px);
}

.aircraft-modal__dialog {
  position: relative;
  width: min(760px, 100%);
  max-height: calc(100vh - 2rem);
  overflow: auto;
}

.aircraft-marker-wrapper {
  background: transparent;
  border: 0;
}

.aircraft-marker-wrapper--tracked {
  position: relative;
}

.aircraft-marker-wrapper--tracked::before {
  content: '';
  position: absolute;
  inset: -4px;
  border: 2px solid #FFD700;
  border-radius: 50%;
  box-shadow: 0 0 12px rgba(255, 215, 0, 0.7), 0 0 24px rgba(255, 215, 0, 0.4);
  pointer-events: none;
  z-index: -1;
}

.aircraft-icon,
.poi-icon {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  transform-origin: center;
  filter: drop-shadow(0 0 2px rgba(3, 7, 18, 0.95)) drop-shadow(0 0 8px rgba(3, 7, 18, 0.75));
}

.poi-marker-wrapper {
  background: transparent;
  border: 0;
}

.poi-icon--airport {
  filter: drop-shadow(0 10px 18px rgba(15, 23, 42, 0.5));
}

.poi-icon--aerodrome,
.poi-icon--heliport {
  opacity: 0.9;
  filter: drop-shadow(0 8px 14px rgba(15, 23, 42, 0.45));
}

.aircraft-marker {
  font-size: 1.25rem;
  line-height: 1;
  text-shadow: 0 0 10px rgba(15, 23, 42, 0.8);
}

.status-dot {
  display: inline-block;
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 999px;
  margin-right: 0.5rem;
}

.leaflet-popup-content-wrapper,
.leaflet-popup-tip {
  background: rgba(15, 23, 42, 0.98);
  color: #e2e8f0;
}

.atc-link {
  color: #7dd3fc;
  text-decoration: none;
}

.atc-link:hover {
  color: #bae6fd;
  text-decoration: underline;
}

.weather-metric {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.5rem 1rem;
}

.weather-metric strong {
  color: #f8fafc;
}

.airport-report {
  border-top: 1px solid rgba(121, 227, 125, 0.12);
  padding-top: 0.75rem;
}

.airport-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem 1rem;
}

.airport-detail-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(30, 94, 255, 0.14);
  border-radius: 0.75rem;
  padding: 0.75rem;
}

.movement-group {
  display: grid;
  gap: 0.75rem;
}

.movement-row {
  border-top: 1px dashed rgba(125, 211, 252, 0.18);
  padding-top: 0.65rem;
}

.movement-row:first-child {
  border-top: 0;
  padding-top: 0;
}

.context-panel {
  border-top: 1px solid rgba(30, 94, 255, 0.16);
  padding-top: 0.75rem;
}

.route-sample-point {
  border-top: 1px dashed rgba(20, 184, 166, 0.18);
  padding-top: 0.5rem;
  margin-top: 0.5rem;
}

.aircraft-actions {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-top: 0.75rem;
}

.aircraft-meta {
  line-height: 1.45;
}

.card {
  backdrop-filter: blur(10px);
}

@media (max-width: 991.98px) {
  .app-shell {
    grid-template-columns: 1fr;
    padding: 0.75rem;
  }

  .brand-logo {
    width: min(100%, 260px);
  }

  .app-dock {
    grid-template-columns: 1fr;
  }

  .aircraft-modal {
    padding: 0.75rem;
  }

  .airport-detail-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 991.98px) {
  .map-panel {
    height: 52vh;
    min-height: 360px;
  }
}
