:root {
  color-scheme: dark;
  --bg: #07100f;
  --bg-elevated: #0b1715;
  --panel: rgba(14, 29, 26, 0.86);
  --panel-solid: #0e1d1a;
  --panel-hover: #132521;
  --border: rgba(177, 224, 208, 0.12);
  --border-strong: rgba(177, 224, 208, 0.2);
  --text: #effaf6;
  --muted: #88a49a;
  --muted-light: #abc1b9;
  --accent: #6be7bd;
  --accent-strong: #90f1cf;
  --accent-ink: #06251c;
  --danger: #ff9d93;
  --danger-bg: rgba(103, 31, 28, 0.3);
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.28);
  --radius: 18px;
  --radius-small: 12px;
  font-family:
    Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  font-synthesis: none;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--bg);
}

body {
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  color: var(--text);
  background:
    radial-gradient(circle at 15% 0%, rgba(53, 155, 121, 0.13), transparent 34rem),
    linear-gradient(180deg, #07100f 0%, #081210 45%, #07100f 100%);
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  font: inherit;
}

[hidden] {
  display: none !important;
}

.ambient {
  position: fixed;
  z-index: -1;
  width: 32rem;
  height: 32rem;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.11;
  pointer-events: none;
}

.ambient-one {
  top: -18rem;
  right: -9rem;
  background: #58d3aa;
}

.ambient-two {
  bottom: -24rem;
  left: -8rem;
  background: #2b8c75;
}

.topbar {
  position: relative;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 78px;
  padding: 0 4vw;
  border-bottom: 1px solid var(--border);
  background: rgba(7, 16, 15, 0.78);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  gap: 12px;
  align-items: center;
  color: inherit;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 1px solid rgba(107, 231, 189, 0.38);
  border-radius: 11px;
  color: var(--accent);
  background:
    linear-gradient(145deg, rgba(107, 231, 189, 0.15), rgba(107, 231, 189, 0.03));
  font-family: Georgia, serif;
  font-size: 21px;
}

.brand strong,
.brand small {
  display: block;
}

.brand strong {
  font-size: 14px;
  letter-spacing: 0.015em;
}

.brand small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.04em;
}

.session-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}

.secure-label {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-right: 5px;
  color: var(--muted-light);
  font-size: 12px;
}

.secure-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px rgba(107, 231, 189, 0.1);
}

main {
  width: min(1380px, 92vw);
  min-height: calc(100vh - 150px);
  margin: 0 auto;
}

.login-shell {
  display: grid;
  min-height: calc(100vh - 150px);
  place-items: center;
  padding: 48px 0;
}

.login-card {
  width: min(480px, 100%);
  padding: 52px;
  border: 1px solid var(--border-strong);
  border-radius: 24px;
  background:
    linear-gradient(145deg, rgba(16, 34, 30, 0.98), rgba(10, 23, 21, 0.96));
  box-shadow: var(--shadow);
  text-align: center;
}

.lock-emblem {
  position: relative;
  width: 64px;
  height: 64px;
  margin: 0 auto 28px;
  border: 1px solid rgba(107, 231, 189, 0.28);
  border-radius: 19px;
  background: rgba(107, 231, 189, 0.07);
}

.lock-emblem::before {
  position: absolute;
  top: 15px;
  left: 21px;
  width: 20px;
  height: 18px;
  border: 2px solid var(--accent);
  border-bottom: 0;
  border-radius: 11px 11px 0 0;
  content: "";
}

.lock-emblem span {
  position: absolute;
  top: 31px;
  left: 17px;
  width: 28px;
  height: 22px;
  border-radius: 6px;
  background: var(--accent);
}

.lock-emblem span::after {
  position: absolute;
  top: 7px;
  left: 12px;
  width: 4px;
  height: 8px;
  border-radius: 3px;
  background: var(--accent-ink);
  content: "";
}

.eyebrow {
  margin: 0 0 9px;
  color: var(--accent);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 12px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(32px, 5vw, 46px);
  font-weight: 500;
  letter-spacing: -0.035em;
  line-height: 1.04;
}

h2 {
  margin-bottom: 0;
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -0.015em;
}

.login-copy {
  margin: 0 auto 30px;
  color: var(--muted-light);
  font-size: 14px;
  line-height: 1.7;
}

.fine-print {
  margin: 20px 0 0;
  color: var(--muted);
  font-size: 11px;
}

.button {
  display: inline-flex;
  gap: 14px;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 16px;
  border: 1px solid transparent;
  border-radius: 10px;
  color: var(--text);
  cursor: pointer;
  transition:
    background 150ms ease,
    border-color 150ms ease,
    transform 150ms ease;
}

.button:hover {
  transform: translateY(-1px);
}

.button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.button:disabled {
  opacity: 0.55;
  cursor: wait;
  transform: none;
}

.button-primary {
  width: 100%;
  min-height: 48px;
  color: var(--accent-ink);
  background: var(--accent);
  font-size: 13px;
  font-weight: 700;
}

.button-primary:hover {
  background: var(--accent-strong);
}

.button-quiet {
  border-color: var(--border);
  background: rgba(255, 255, 255, 0.025);
  color: var(--muted-light);
  font-size: 12px;
}

.button-quiet:hover {
  border-color: var(--border-strong);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
}

.dashboard {
  padding: 54px 0 80px;
}

.dashboard-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 34px;
}

.dashboard-heading h1 {
  margin-bottom: 10px;
}

.subheading {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.as-of {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  padding-bottom: 3px;
}

.as-of span,
.as-of small {
  color: var(--muted);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.as-of strong {
  margin: 6px 0 5px;
  color: var(--muted-light);
  font-size: 13px;
}

.as-of small {
  color: var(--accent);
  letter-spacing: 0.04em;
  text-transform: none;
}

.notice {
  display: flex;
  gap: 7px;
  flex-direction: column;
  margin-bottom: 22px;
  padding: 17px 19px;
  border: 1px solid var(--border);
  border-radius: var(--radius-small);
  background: var(--panel);
  font-size: 13px;
}

.notice span {
  color: var(--muted-light);
}

.notice-error {
  border-color: rgba(255, 157, 147, 0.22);
  background: var(--danger-bg);
}

.notice-error strong {
  color: var(--danger);
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 14px;
}

.metric-card,
.panel {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.08);
}

.metric-card {
  min-height: 168px;
  padding: 22px;
}

.metric-feature {
  border-color: rgba(107, 231, 189, 0.2);
  background:
    linear-gradient(145deg, rgba(22, 52, 44, 0.92), rgba(12, 27, 24, 0.9));
}

.metric-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 29px;
  color: var(--muted-light);
  font-size: 11px;
  font-weight: 600;
}

.metric-icon {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--accent);
  background: rgba(107, 231, 189, 0.06);
  font-family: Georgia, serif;
  font-size: 13px;
}

.metric-value {
  display: block;
  overflow: hidden;
  margin-bottom: 12px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(29px, 3.1vw, 40px);
  font-weight: 500;
  letter-spacing: -0.025em;
  line-height: 1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.metric-card p {
  margin: 0;
  color: var(--muted);
  font-size: 11px;
}

.content-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(300px, 0.82fr);
  gap: 14px;
  margin-bottom: 14px;
}

.panel {
  padding: 24px;
}

.panel-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 22px;
}

.chart-summary {
  text-align: right;
}

.chart-summary span,
.chart-summary strong {
  display: block;
}

.chart-summary span {
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 10px;
}

.chart-summary strong {
  font-size: 15px;
}

.chart-wrap {
  width: 100%;
  height: 250px;
}

.chart-wrap svg {
  width: 100%;
  height: 100%;
  overflow: visible;
}

.chart-gridline {
  stroke: rgba(177, 224, 208, 0.08);
  stroke-width: 1;
  vector-effect: non-scaling-stroke;
}

.chart-area {
  fill: url("#chart-fill");
}

.chart-line {
  fill: none;
  stroke: var(--accent);
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2.5;
  vector-effect: non-scaling-stroke;
}

.chart-point {
  fill: var(--panel-solid);
  stroke: var(--accent);
  stroke-width: 3;
  vector-effect: non-scaling-stroke;
}

.chart-axis {
  display: flex;
  justify-content: space-between;
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
}

.detail-list {
  margin: 0;
}

.detail-list > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 46px;
  border-bottom: 1px solid var(--border);
}

.detail-list dt {
  color: var(--muted);
  font-size: 11px;
}

.detail-list dd {
  margin: 0;
  font-size: 12px;
  font-weight: 650;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 9px;
  border: 1px solid rgba(107, 231, 189, 0.19);
  border-radius: 999px;
  color: var(--accent);
  background: rgba(107, 231, 189, 0.07);
  font-size: 10px;
}

.status-pill.status-delayed {
  border-color: rgba(255, 192, 118, 0.22);
  color: #ffc076;
  background: rgba(255, 192, 118, 0.07);
}

.launch-date {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 22px;
  padding: 15px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.018);
}

.launch-date span {
  color: var(--muted);
  font-size: 10px;
  text-transform: uppercase;
}

.launch-date strong {
  font-size: 11px;
}

.history-panel {
  margin-bottom: 14px;
}

.record-count {
  color: var(--muted);
  font-size: 10px;
}

.table-wrap {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  padding: 14px 12px;
  border-bottom: 1px solid var(--border);
  text-align: right;
  white-space: nowrap;
}

th:first-child,
td:first-child {
  padding-left: 0;
  text-align: left;
}

th:last-child,
td:last-child {
  padding-right: 0;
}

th {
  color: var(--muted);
  font-size: 9px;
  font-weight: 650;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

td {
  color: var(--muted-light);
  font-size: 11px;
}

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

.isolation-note {
  display: flex;
  gap: 15px;
  align-items: center;
  padding: 18px 20px;
  border: 1px dashed rgba(107, 231, 189, 0.19);
  border-radius: var(--radius-small);
  background: rgba(107, 231, 189, 0.025);
}

.isolation-icon {
  display: grid;
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  place-items: center;
  border: 1px solid var(--border);
  border-radius: 50%;
  color: var(--accent);
}

.isolation-note strong {
  display: block;
  margin-bottom: 4px;
  font-size: 11px;
}

.isolation-note p {
  margin: 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.5;
}

footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: min(1380px, 92vw);
  min-height: 72px;
  margin: 0 auto;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 10px;
}

@media (max-width: 980px) {
  .metric-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

@media (max-width: 640px) {
  .topbar {
    padding: 0 20px;
  }

  .brand small,
  .secure-label {
    display: none;
  }

  .button-quiet {
    min-height: 36px;
    padding: 0 11px;
  }

  main {
    width: min(100% - 30px, 1380px);
  }

  .login-card {
    padding: 38px 25px;
  }

  .dashboard {
    padding-top: 38px;
  }

  .dashboard-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 22px;
  }

  .as-of {
    align-items: flex-start;
  }

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

  .metric-card {
    min-height: 150px;
  }

  .panel {
    padding: 20px;
  }

  .chart-wrap {
    height: 200px;
  }

  footer {
    align-items: flex-start;
    flex-direction: column;
    justify-content: center;
    gap: 7px;
    width: min(100% - 30px, 1380px);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
