/* Operational polish: dual-clock readability and denser, non-duplicative detail views. */

#flight-time-line,
.flight-card dd,
.flight-card__times dd,
.flight-phase small,
.live-flight-status dd,
.flight-delay-item dd,
.flight-delay-overlap span,
.flight-reference td,
.flight-reference-card dd,
.flight-countdown em {
  font-variant-numeric: tabular-nums;
}

/* Dual display times are longer than the previous single-clock values. */
.flight-card--optimized .flight-card__times dd,
.live-flight-status dd,
.flight-delay-item dd,
.flight-reference-card dd {
  white-space: normal;
  overflow-wrap: normal;
  line-height: 1.25;
}

/* Two timing columns scan faster and prevent dual-clock values from being crushed. */
.flight-card--optimized .flight-card__times,
.flight-card--optimized .flight-card__times--operational,
.flight-card--optimized.flight-card--access .flight-card__times,
.live-flight-status dl,
.flight-delay-item dl {
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
}

/* The phase strip also carries dual clocks, so use a readable 2x2 milestone grid. */
.flight-phase ol {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.flight-phase__step small {
  overflow: visible;
  text-overflow: clip;
  white-space: normal;
  line-height: 1.15;
}

/* Keep exact operational times visible in Active and Upcoming. The phase strip
   communicates state; these rows preserve the precise next milestones. */

.flight-card--access .flight-countdown em {
  white-space: normal;
}

.flight-reference {
  min-width: 1040px;
}

.flight-reference th,
.flight-reference td {
  white-space: normal;
  line-height: 1.25;
}

/* Priority Pass is an operating window, not a departure. */
.flight-card--access .flight-card__top em {
  background: linear-gradient(135deg, #334155, #0f172a);
}

.flight-card--access .flight-card__times dt {
  white-space: normal;
}

/* Native time inputs cannot show both clock systems, so pair them with a dual-clock preview. */
.dual-time-input-preview {
  display: block;
  margin-top: 6px;
  color: #64748b;
  font-size: 0.78rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.dual-time-input-preview[hidden] {
  display: none;
}

/* Keep the healthy connection state secondary to operational actions. */
.flight-data-status--live {
  box-shadow: none;
}

@media (max-width: 900px) {
  .flight-reference-card dl {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 420px) {
  .flight-reference-card dl {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  .flight-card__times dd,
  .live-flight-status dd,
  .flight-delay-item dd,
  .flight-reference-card dd {
    font-size: 0.78rem;
  }

  .flight-card__times dt,
  .live-flight-status dt,
  .flight-delay-item dt,
  .flight-reference-card dt {
    font-size: 0.6rem;
  }
}
