.pilot-highlights {
  margin: 2.5rem 0 1.5rem;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 1.25rem;
  background: #f8fafc;
}

.pilot-highlights__header h2 {
  margin: 0.2rem 0 0.4rem;
}

.pilot-highlights__eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.2em;
  font-size: 0.75rem;
  color: #475569;
}

.pilot-highlights__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem;
  margin-top: 1.25rem;
}

.pilot-highlights__card {
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  background: #fff;
}

.pilot-highlights__card header h3 {
  margin: 0 0 0.25rem;
}

.pilot-highlights__empty,
.pilot-highlights__error {
  padding: 0.8rem 1rem;
  border-radius: 10px;
  font-size: 0.9rem;
  background: #f8fafc;
  color: #475569;
}

.pilot-highlights__error {
  background: #fff1f2;
  color: #b91c1c;
}

.pilot-highlights__table-wrapper {
  overflow-x: auto;
}

.pilot-highlights__table {
  width: 100%;
  border-collapse: collapse;
  min-width: 320px;
}

.pilot-highlights__table th,
.pilot-highlights__table td {
  font-size: 0.8rem;
  text-align: left;
  padding: 0.35rem 0.5rem;
  border-bottom: 1px solid #e2e8f0;
}

.pilot-highlights__table th {
  background: #fff;
  color: #475569;
  font-weight: 600;
}

.pilot-highlights__date-cell strong {
  font-size: 0.9rem;
  font-weight: 600;
  color: #0f172a;
}

.pilot-highlights__icon-cell {
  text-align: center;
}

.pilot-highlights__icon-cell img {
  width: 26px;
  height: 26px;
}

.pilot-highlights__distance-cell {
  font-weight: 600;
  color: #0f172a;
}

.pilot-highlights__actions {
  text-align: center;
}

.pilot-highlights__action-list {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.22rem;
}

.pilot-highlights__action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 34px;
  width: 34px;
  min-width: 34px;
  height: 34px;
  min-height: 34px;
  padding: 0;
  border: 1px solid rgba(15, 76, 129, 0.25);
  border-radius: 999px;
  background: rgba(15, 76, 129, 0.07);
  color: #0f4c81;
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, transform 0.15s ease;
}

.pilot-highlights__action:hover,
.pilot-highlights__action:focus-visible {
  background: rgba(15, 76, 129, 0.15);
  color: #0a3760;
  transform: translateY(-1px);
}

.pilot-highlights__action--copied {
  border-color: #22c55e;
  background: #22c55e;
  color: #ffffff;
}

.pilot-highlights__action-text {
  display: none;
}

.pilot-highlights__muted {
  color: #cbd5f5;
}

@media (max-width: 720px) {
  .pilot-highlights {
    padding: 1rem;
    border-radius: 14px;
  }

  .pilot-highlights__grid {
    grid-template-columns: 1fr;
    gap: 0.85rem;
  }

  .pilot-highlights__card {
    padding: 0.9rem;
  }

  .pilot-highlights__table {
    min-width: 0;
  }

  .pilot-highlights__table thead {
    display: none;
  }

  .pilot-highlights__table,
  .pilot-highlights__table tbody,
  .pilot-highlights__table tr,
  .pilot-highlights__table td {
    display: block;
    width: 100%;
  }

  .pilot-highlights__table tr {
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 0.7rem 0.8rem;
    margin-bottom: 0.75rem;
    background: #fff;
  }

  .pilot-highlights__table td {
    padding: 0.2rem 0;
    border-bottom: none;
  }

    .pilot-highlights__actions {
        text-align: left;
        padding-top: 0.45rem;
    }

  .pilot-highlights__action-list {
    justify-content: flex-start;
  }
}

body.dark-mode .pilot-highlights {
  border-color: rgba(71, 85, 105, 0.72);
  background: rgba(15, 23, 42, 0.88);
}

body.dark-mode .pilot-highlights__eyebrow,
body.dark-mode .pilot-highlights__empty,
body.dark-mode .pilot-highlights__table th,
body.dark-mode .pilot-highlights__muted {
  color: #cbd5e1;
}

body.dark-mode .pilot-highlights__card,
body.dark-mode .pilot-highlights__table th,
body.dark-mode .pilot-highlights__table tr,
body.dark-mode .pilot-highlights__table td,
body.dark-mode .pilot-highlights__empty {
  background: rgba(15, 23, 42, 0.92);
  border-color: rgba(71, 85, 105, 0.72);
}

body.dark-mode .pilot-highlights__date-cell strong,
body.dark-mode .pilot-highlights__distance-cell {
  color: #f8fafc;
}

body.dark-mode .pilot-highlights__action {
  border-color: rgba(147, 197, 253, 0.32);
  background: rgba(37, 99, 235, 0.18);
  color: #dbeafe;
}

body.dark-mode .pilot-highlights__action:hover,
body.dark-mode .pilot-highlights__action:focus-visible {
  background: rgba(37, 99, 235, 0.28);
  color: #ffffff;
}

body.dark-mode .pilot-highlights__action--copied {
  border-color: #22c55e;
  background: #22c55e;
  color: #ffffff;
}

body.dark-mode .pilot-highlights__error {
  background: rgba(127, 29, 29, 0.38);
  color: #fecaca;
}
