:root {
  color-scheme: light;
  --ink: #111827;
  --muted: #667085;
  --line: #d8dee8;
  --panel: #ffffff;
  --canvas: #f4f7fb;
  --blue: #265ee8;
  --blue-dark: #1741a6;
  --teal: #0d9488;
  --amber: #b7791f;
  --red: #c2413b;
  --green: #2f855a;
  --shadow: 0 12px 30px rgba(18, 38, 63, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--canvas);
  color: var(--ink);
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

.shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
}

.sidebar {
  background: #101828;
  color: #fff;
  padding: 22px 18px;
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
  letter-spacing: 0;
}

.brand img {
  width: 118px;
  height: 40px;
  object-fit: contain;
  background: #fff;
  border-radius: 4px;
  padding: 4px 8px;
}

.nav {
  display: grid;
  gap: 6px;
}

.nav-button,
.secondary,
.icon-button,
form button {
  border: 1px solid transparent;
  border-radius: 6px;
  min-height: 38px;
}

.nav-button {
  width: 100%;
  text-align: left;
  background: transparent;
  color: #d8e1f2;
  padding: 10px 12px;
}

.nav-button:hover,
.nav-button.active {
  background: #1d2939;
  color: #fff;
  border-color: #344054;
}

.token-box {
  margin-top: auto;
  display: grid;
  gap: 8px;
  color: #d8e1f2;
}

.token-box label {
  font-size: 12px;
  color: #b8c1d1;
}

.token-box input {
  width: 100%;
  border: 1px solid #344054;
  background: #0b1220;
  color: #fff;
  border-radius: 6px;
  padding: 10px;
}

.secondary {
  background: #eef4ff;
  color: var(--blue-dark);
  border-color: #c7d7fe;
}

.release-order {
  padding: 8px 10px;
  white-space: nowrap;
}

.main {
  min-width: 0;
  padding: 24px;
}

.topbar {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
  margin-bottom: 20px;
}

h1,
h2,
p {
  margin: 0;
}

h1 {
  font-size: 28px;
  line-height: 1.15;
}

h2 {
  font-size: 16px;
}

.topbar p {
  color: var(--muted);
  margin-top: 4px;
}

.icon-button {
  width: 42px;
  height: 42px;
  background: var(--panel);
  border-color: var(--line);
  box-shadow: var(--shadow);
}

.status {
  border: 1px solid #f5c2c7;
  background: #fff1f2;
  color: #9f1239;
  border-radius: 6px;
  padding: 10px 12px;
  margin-bottom: 16px;
}

.view {
  display: none;
}

.view.active {
  display: block;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(150px, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}

.metric {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  box-shadow: var(--shadow);
}

.metric span {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.metric strong {
  display: block;
  font-size: 30px;
  margin-top: 6px;
}

.band {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.band.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
}

.band-header {
  min-height: 56px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.filter {
  width: min(260px, 48vw);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 9px 10px;
}

.table-wrap {
  overflow: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 720px;
}

th,
td {
  text-align: left;
  padding: 11px 14px;
  border-bottom: 1px solid #e8edf5;
  vertical-align: top;
  font-size: 14px;
}

th {
  color: #475467;
  background: #f8fafc;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

tr:hover td {
  background: #f8fbff;
}

.mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px;
}

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  background: #eef2ff;
  color: var(--blue-dark);
}

.badge.green {
  background: #ecfdf3;
  color: var(--green);
}

.badge.amber {
  background: #fffbeb;
  color: var(--amber);
}

.badge.red {
  background: #fef2f2;
  color: var(--red);
}

.timeline {
  padding: 8px 14px 14px;
}

.event {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 14px;
  padding: 10px 0;
  border-bottom: 1px solid #edf2f7;
}

.event time {
  color: var(--muted);
  font-size: 12px;
}

.detail-panel {
  border-left: 1px solid var(--line);
  padding: 16px;
  display: grid;
  gap: 12px;
  align-content: start;
  background: #fbfcff;
}

.detail-panel label {
  display: grid;
  gap: 6px;
  color: #344054;
  font-size: 13px;
}

.detail-panel input,
.detail-panel select {
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 9px 10px;
  background: #fff;
  min-width: 0;
}

form button {
  background: var(--blue);
  color: #fff;
  border-color: var(--blue);
  padding: 10px 12px;
}

@media (max-width: 900px) {
  .shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: sticky;
    top: 0;
    z-index: 3;
  }

  .nav {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .nav-button {
    text-align: center;
  }

  .metrics,
  .band.split {
    grid-template-columns: 1fr;
  }

  .detail-panel {
    border-left: 0;
    border-top: 1px solid var(--line);
  }
}
