:root {
  --bg: #080b10;
  --panel: #12161d;
  --panel-soft: #0f131a;
  --panel-strong: #171d27;
  --ink: #eef3ff;
  --muted: #93a1b8;
  --line: #263144;
  --cobalt: #0047ab;
  --cobalt-bright: #2f7dff;
  --cobalt-soft: rgba(0, 71, 171, 0.2);
  --white-soft: rgba(255, 255, 255, 0.06);
  --shadow: 0 18px 52px rgba(0, 0, 0, 0.34);
  color-scheme: dark;
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  background:
    radial-gradient(circle at 72% 8%, rgba(0, 71, 171, 0.24), transparent 34%),
    linear-gradient(180deg, #0d1118 0%, var(--bg) 48%, #070a0f 100%);
  color: var(--ink);
}

button,
input,
select,
textarea {
  font: inherit;
}

.page-shell {
  display: grid;
  gap: 18px;
  width: min(1500px, 100%);
  margin: 0 auto;
  padding: 20px 18px 42px;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px 24px;
  min-height: 330px;
  align-content: end;
  padding: 18px 0;
}

.nav {
  display: flex;
  grid-column: 1 / -1;
  align-self: start;
  gap: 10px;
}

.nav a {
  display: inline-grid;
  min-height: 42px;
  align-items: center;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(18, 22, 29, 0.9);
  color: var(--ink);
  font-size: 0.86rem;
  font-weight: 900;
  text-decoration: none;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.nav a:hover {
  border-color: rgba(47, 125, 255, 0.55);
  background: var(--cobalt-soft);
}

.brand-row {
  display: flex;
  grid-column: 1 / -1;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.logo {
  display: grid;
  width: 206px;
  height: 138px;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(47, 125, 255, 0.28);
  border-radius: 8px;
  background: #ffffff;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.04),
    0 14px 30px rgba(0, 71, 171, 0.18);
}

.logo img {
  width: 184px;
  height: auto;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.update-button {
  align-self: center;
  min-height: 42px;
  padding: 0 18px;
  border: 1px solid var(--cobalt-bright);
  border-radius: 999px;
  background: linear-gradient(180deg, var(--cobalt-bright), var(--cobalt));
  color: #ffffff;
  cursor: pointer;
  font-size: 0.86rem;
  font-weight: 900;
  box-shadow:
    0 12px 26px rgba(0, 71, 171, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.secondary-button {
  min-height: 42px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel);
  color: var(--ink);
  cursor: pointer;
  font-size: 0.86rem;
  font-weight: 900;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.update-button:disabled {
  opacity: 0.65;
  cursor: wait;
}

.secondary-button:disabled {
  color: var(--muted);
  cursor: wait;
}

.small-pill {
  display: inline-grid;
  min-height: 30px;
  align-items: center;
  padding: 0 10px;
  border-radius: 999px;
  background: var(--cobalt-soft);
  color: #9ec5ff;
  font-size: 0.76rem;
  font-weight: 900;
  white-space: nowrap;
}

.eyebrow {
  margin: 0 0 4px;
  color: #9ec5ff;
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

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

.hero h1 {
  grid-column: 1 / -1;
  max-width: 980px;
  margin-bottom: 0;
  color: var(--ink);
  font-size: clamp(2.6rem, 7vw, 6rem);
  line-height: 0.95;
}

.hero > p:last-child {
  grid-column: 1 / -1;
  max-width: 780px;
  margin: 0;
  color: var(--muted);
  font-size: 1.08rem;
  line-height: 1.55;
}

.main-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(360px, 0.65fr);
  gap: 18px;
}

.panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(18, 22, 29, 0.96);
  box-shadow: var(--shadow);
}

.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 68px;
  padding: 16px;
  border-bottom: 1px solid var(--line);
}

.panel-head.compact {
  min-height: 58px;
}

.panel-head h2,
.focus-copy h3 {
  margin-bottom: 0;
}

.status-body {
  display: grid;
  grid-template-columns: 174px minmax(0, 1fr);
  gap: 22px;
  align-items: center;
  padding: 18px;
}

.meter {
  position: relative;
  display: grid;
  width: 160px;
  height: 160px;
  place-items: center;
}

.meter svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.meter-track,
.meter-value {
  fill: none;
  stroke-width: 10;
}

.meter-track {
  stroke: #242d3c;
}

.meter-value {
  stroke: var(--cobalt-bright);
  stroke-linecap: round;
  transition: stroke-dashoffset 0.35s ease;
}

.meter strong {
  font-size: 2rem;
}

.focus-copy {
  display: grid;
  gap: 10px;
}

.focus-copy h3 {
  font-size: 1.35rem;
}

.focus-copy p,
.shape-list span,
.phase p,
.update p {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}

.eta-box {
  display: grid;
  gap: 4px;
  padding: 12px;
  border: 1px solid rgba(47, 125, 255, 0.28);
  border-radius: 8px;
  background: var(--cobalt-soft);
}

.eta-box span {
  color: #9ec5ff;
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
}

.eta-box strong {
  color: var(--ink);
}

.eta-box p {
  font-size: 0.9rem;
}

.shape-list {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.shape-list article {
  display: grid;
  gap: 5px;
  min-height: 82px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-soft);
}

.phases,
.feed {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.phase {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  min-height: 88px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-soft);
}

.phase.done {
  border-left: 4px solid var(--cobalt-bright);
}

.phase.active {
  border-left: 4px solid #ffffff;
  background: var(--cobalt-soft);
}

.phase.blocked {
  border-left: 4px solid #8ab8ff;
}

.phase-index {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 999px;
  background: var(--panel-strong);
  color: var(--ink);
  font-weight: 900;
}

.phase strong,
.update strong {
  display: block;
  margin-bottom: 4px;
}

.phase-status {
  display: inline-grid;
  min-height: 28px;
  align-items: center;
  padding: 0 9px;
  border-radius: 999px;
  background: var(--panel-strong);
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 900;
}

.phase.done .phase-status,
.phase.active .phase-status {
  color: #9ec5ff;
}

.update {
  display: grid;
  gap: 4px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-soft);
}

.update time {
  color: #9ec5ff;
  font-size: 0.76rem;
  font-weight: 900;
  text-transform: uppercase;
}

.empty-state {
  display: grid;
  min-height: 160px;
  place-items: center;
  color: var(--muted);
  text-align: center;
}

@media (max-width: 920px) {
  .hero,
  .main-grid,
  .status-body {
    grid-template-columns: 1fr;
  }

  .update-button {
    justify-self: start;
  }

  .meter {
    justify-self: center;
  }
}

@media (max-width: 640px) {
  .page-shell {
    padding: 14px;
  }

  .hero {
    min-height: 290px;
  }

  .panel-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .phase {
    grid-template-columns: 34px minmax(0, 1fr);
  }

  .phase-status {
    grid-column: 2;
    justify-self: start;
  }
}
