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

.export-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.select-all {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
  color: var(--muted);
}

.select-all input {
  width: 16px;
  height: 16px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}
.bulk-edit-panel {
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 16px;
  padding: 16px;
  background: rgba(8, 10, 18, 0.75);
  margin-bottom: 16px;
}

.bulk-edit-panel header {
  margin-bottom: 10px;
}

.bulk-edit-panel h3 {
  margin: 0;
  font-size: 1rem;
}

.bulk-edit-panel p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 0.85rem;
}

.bulk-edit-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px;
  margin-bottom: 12px;
}

.bulk-edit-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
:root {
  color-scheme: dark;
  font-family: "Space Grotesk", system-ui, -apple-system, sans-serif;
  --bg: #05060a;
  --bg-alt: #0f111a;
  --card: rgba(16, 19, 32, 0.85);
  --card-strong: #141828;
  --text: #f5f7ff;
  --muted: #8b92b2;
  --accent: #4bb5ff;
  --accent-strong: #2fffa2;
  --warning: #f8d477;
  --danger: #ff7f7f;
  --border: rgba(255, 255, 255, 0.08);
  --grid: rgba(255, 255, 255, 0.04);
  --shadow: 0 25px 55px rgba(2, 6, 23, 0.75);
  --mono: "IBM Plex Mono", "Space Grotesk", monospace;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 20% 20%, rgba(79, 255, 226, 0.08), transparent 45%),
    radial-gradient(circle at 80% 0%, rgba(75, 181, 255, 0.18), transparent 55%),
    var(--bg);
  color: var(--text);
  font-size: 16px;
  line-height: 1.5;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  border-radius: 18px;
  display: block;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: var(--shadow);
}

.page-shell {
  width: min(1200px, 92vw);
  margin: 0 auto;
  padding: 48px 0 72px;
}

.page-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 32px;
  margin-bottom: 32px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--grid);
}

.header-copy {
  position: relative;
  padding-left: 22px;
}

.header-copy::before {
  content: "";
  position: absolute;
  left: 0;
  top: 4px;
  bottom: 12px;
  width: 4px;
  border-radius: 999px;
  background: linear-gradient(180deg, var(--accent), var(--accent-strong));
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.4em;
  font-size: 0.78rem;
  color: var(--muted);
  margin: 0;
}

.page-header h1 {
  font-size: clamp(2.2rem, 4vw, 3.6rem);
  margin: 8px 0;
}

.subtitle {
  color: var(--muted);
  font-size: 1rem;
  max-width: 540px;
}

.subtitle strong {
  color: var(--accent-strong);
  font-family: var(--mono);
}

.logout-form button {
  background: rgba(255, 255, 255, 0.04);
  border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--text);
  padding: 10px 22px;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
  transition: border 0.2s ease, color 0.2s ease;
}

.logout-form button:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.panel {
  background: var(--card);
  border-radius: 28px;
  padding: 24px 28px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
  margin-bottom: 28px;
}

.panel::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  border: 1px solid transparent;
  background: linear-gradient(145deg, rgba(79, 255, 226, 0.08), rgba(75, 181, 255, 0));
  mask: linear-gradient(#000, #000) content-box, linear-gradient(#000, #000);
  mask-composite: exclude;
  padding: 1px;
  pointer-events: none;
}

.compact-form {
  width: 100%;
}

.form-grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 24px;
}

.form-column.upload {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.form-column.details {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.file-button {
  border: 1px dashed rgba(255, 255, 255, 0.25);
  border-radius: 16px;
  padding: 16px;
  text-align: center;
  font-size: 0.95rem;
  cursor: pointer;
  transition: border 0.2s ease, background 0.2s ease;
}

.file-button input[type="file"] {
  display: none;
}

.file-button:hover {
  border-color: var(--accent);
  background: rgba(75, 181, 255, 0.08);
}

#preview {
  width: 100%;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.35);
}

.manual-fields {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
}

.manual-fields textarea {
  min-height: 60px;
  resize: vertical;
}

.station-picker {
  display: flex;
  flex-direction: column;
  gap: 8px;
  background: rgba(255, 255, 255, 0.01);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 14px;
}

.station-filter {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.station-filter input {
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font-family: var(--mono);
  font-size: 0.95rem;
}

#station-select {
  width: 100%;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(3, 4, 10, 0.6);
  color: var(--text);
  padding: 6px;
  font-family: var(--mono);
  font-size: 0.9rem;
}

#station-select option {
  padding: 6px 8px;
}

.station-hint {
  margin: 0;
  font-size: 0.8rem;
  color: var(--muted);
}

.geo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
  align-items: end;
}

label input[type="text"],
.manual-fields textarea {
  width: 100%;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font-size: 0.95rem;
  font-family: var(--mono);
}

label {
  color: var(--muted);
  font-size: 0.9rem;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.primary {
  width: 100%;
  padding: 12px 16px;
  border-radius: 12px;
  border: none;
  background: linear-gradient(120deg, var(--accent), var(--accent-strong));
  color: #020408;
  font-size: 0.95rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 15px 25px rgba(79, 255, 226, 0.35);
}

.secondary {
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.02);
  color: var(--text);
  cursor: pointer;
  font-weight: 500;
  transition: border 0.2s ease, color 0.2s ease;
}

.secondary:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.geo-status {
  min-height: 16px;
  font-size: 0.85rem;
  color: var(--muted);
  margin: -6px 0 4px;
}

.geo-status.success {
  color: var(--accent-strong);
}

.geo-status.warning {
  color: var(--warning);
}

.geo-status.error {
  color: var(--danger);
}

.reference header p {
  color: var(--muted);
}

.reference figcaption {
  margin-top: 12px;
  font-size: 1rem;
  color: var(--accent-strong);
  font-family: var(--mono);
}

.history header {
  margin-bottom: 16px;
}

.history header p {
  color: var(--muted);
  margin-top: 6px;
}

.history .table-wrapper {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
}

th,
td {
  text-align: left;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

th {
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.7rem;
  color: var(--muted);
}

td {
  font-family: var(--mono);
}

.actions-cell {
  min-width: 220px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.edit-panel {
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  padding: 6px 10px;
  background: rgba(10, 12, 20, 0.6);
}

.edit-panel summary {
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent);
  list-style: none;
}

.edit-panel summary::-webkit-details-marker {
  display: none;
}

.edit-panel[open] summary {
  margin-bottom: 6px;
}

.edit-panel form {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.mini-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 8px;
}

.secondary.small,
.ghost.small {
  padding: 8px 10px;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.ghost {
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: transparent;
  color: var(--danger);
  cursor: pointer;
}

.ghost:hover {
  border-color: var(--danger);
}

.flash-list {
  list-style: none;
  padding: 0;
  margin: 0 0 24px;
  display: grid;
  gap: 10px;
}

.flash {
  padding: 12px 18px;
  border-radius: 14px;
  border: 1px solid transparent;
  font-weight: 500;
}

.flash-success {
  background: rgba(47, 255, 162, 0.15);
  border-color: rgba(47, 255, 162, 0.4);
}

.flash-error {
  background: rgba(255, 127, 127, 0.15);
  border-color: rgba(255, 127, 127, 0.4);
}

.flash-warning {
  background: rgba(248, 212, 119, 0.15);
  border-color: rgba(248, 212, 119, 0.4);
}

.flash-info {
  background: rgba(75, 181, 255, 0.18);
  border-color: rgba(75, 181, 255, 0.4);
}

.auth-page {
  background: radial-gradient(circle at 20% 20%, rgba(75, 181, 255, 0.25), transparent 45%), #03040a;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  color: white;
  padding: 40px 16px;
}

.auth-card {
  background: rgba(8, 9, 15, 0.85);
  padding: 48px;
  border-radius: 30px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  width: min(440px, 95vw);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.auth-card .eyebrow {
  color: var(--accent);
  letter-spacing: 0.5em;
}

.auth-card h1 {
  margin: 16px 0 8px;
}

.auth-card p {
  color: var(--muted);
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 28px;
}

.auth-form input {
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
}

.auth-form button {
  margin-top: 10px;
  padding: 14px 16px;
  border-radius: 16px;
  border: none;
  background: linear-gradient(120deg, var(--accent), var(--accent-strong));
  color: #020408;
  font-weight: 600;
  cursor: pointer;
}

@media (max-width: 900px) {
  .page-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .logout-form button {
    width: 100%;
  }

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

  .form-column.upload {
    flex-direction: row;
    align-items: center;
    gap: 16px;
  }

  #preview {
    max-width: 160px;
  }
}

@media (max-width: 600px) {
  .panel {
    padding: 20px;
  }

  table {
    font-size: 0.8rem;
  }
}
