:root {
  color-scheme: dark;
  font-family: "Segoe UI Variable", "Segoe UI", Inter, system-ui, sans-serif;
  background: #090c0f;
  color: #f2f5f7;
  font-synthesis: none;
  --ink: #090c0f;
  --panel: #11171c;
  --panel-raised: #151d23;
  --line: #293640;
  --steel: #79b8dc;
  --steel-dim: #426b84;
  --orange: #ff7a1a;
  --orange-soft: #d85f0f;
  --muted: #8b9aa5;
  --success: #74d6a2;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  background:
    linear-gradient(rgba(121, 184, 220, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(121, 184, 220, 0.035) 1px, transparent 1px),
    radial-gradient(circle at 82% 12%, rgba(255, 122, 26, 0.11), transparent 30%),
    #090c0f;
  background-size: 48px 48px, 48px 48px, auto, auto;
}

button,
input,
select {
  font: inherit;
}

button,
select {
  cursor: pointer;
}

.app-shell {
  width: min(1500px, 100%);
  min-height: 100vh;
  margin: 0 auto;
  padding: 26px clamp(22px, 5vw, 72px) 20px;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--line);
}

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

.brand-mark {
  display: grid;
  grid-template-columns: repeat(2, 11px);
  grid-template-rows: repeat(2, 11px);
  gap: 3px;
  padding: 10px;
  border: 2px solid var(--steel);
  border-radius: 50%;
  box-shadow: inset 0 0 0 4px #10171c;
}

.brand-mark span {
  background: #304858;
}

.brand-mark span:nth-child(3) {
  background: var(--orange);
}

.brand-copy {
  display: flex;
  flex-direction: column;
  line-height: 1;
}

.brand-name {
  font-size: clamp(1.05rem, 2vw, 1.45rem);
  font-weight: 800;
  letter-spacing: 0.04em;
}

.brand-name strong {
  color: var(--orange);
}

.brand-tagline,
.eyebrow,
.panel-index,
.environment,
footer,
.build-id {
  font-family: Consolas, "Cascadia Mono", monospace;
  letter-spacing: 0.11em;
}

.brand-tagline {
  margin-top: 7px;
  color: var(--steel);
  font-size: 0.62rem;
}

.environment {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 9px 12px;
  border: 1px solid #664225;
  color: #f1b17e;
  font-size: 0.67rem;
}

.pulse {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--orange);
  box-shadow: 0 0 0 5px rgba(255, 122, 26, 0.1);
}

main {
  padding: 68px 0 36px;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 48px;
  margin-bottom: 54px;
}

.eyebrow,
.panel-index {
  margin: 0 0 14px;
  color: var(--steel);
  font-size: 0.72rem;
}

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

h1 {
  max-width: 900px;
  margin-bottom: 20px;
  font-size: clamp(2.3rem, 5.2vw, 5.3rem);
  font-weight: 700;
  line-height: 0.98;
  letter-spacing: -0.045em;
}

.lede {
  max-width: 800px;
  margin-bottom: 0;
  color: #9cabb4;
  font-size: clamp(1rem, 1.5vw, 1.2rem);
  line-height: 1.65;
}

.proof-badge {
  display: flex;
  min-width: 260px;
  flex-direction: column;
  gap: 9px;
  padding: 20px;
  border-top: 3px solid var(--orange);
  background: rgba(17, 23, 28, 0.78);
}

.proof-badge span {
  color: var(--orange);
  font-family: Consolas, monospace;
  font-size: 0.7rem;
}

.proof-badge strong {
  letter-spacing: 0.04em;
}

.proof-badge small {
  color: var(--muted);
}

.workspace {
  display: grid;
  grid-template-columns: minmax(340px, 0.78fr) minmax(430px, 1.22fr);
  gap: 22px;
}

.panel {
  position: relative;
  min-height: 570px;
  padding: clamp(24px, 3vw, 38px);
  border: 1px solid var(--line);
  background: rgba(17, 23, 28, 0.93);
  box-shadow: 0 24px 90px rgba(0, 0, 0, 0.25);
}

.panel::before {
  position: absolute;
  top: -1px;
  left: -1px;
  width: 64px;
  height: 3px;
  background: var(--steel);
  content: "";
}

.build-form-panel::before {
  background: var(--orange);
}

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

.panel-heading h2 {
  margin-bottom: 0;
  font-size: 1.55rem;
}

.status-dot,
.text-button {
  border: 0;
  background: transparent;
  color: var(--success);
  font-family: Consolas, monospace;
  font-size: 0.68rem;
  letter-spacing: 0.08em;
}

.text-button {
  color: var(--steel);
  padding: 6px;
}

.text-button:hover,
.text-button:focus-visible {
  color: white;
}

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

form label,
fieldset {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

form label > span,
legend {
  color: #9cabb4;
  font-size: 0.76rem;
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

input,
select {
  width: 100%;
  min-height: 48px;
  padding: 0 13px;
  border: 1px solid #35444f;
  border-radius: 0;
  outline: none;
  background: #0c1115;
  color: #f2f5f7;
}

input:focus,
select:focus {
  border-color: var(--steel);
  box-shadow: 0 0 0 3px rgba(121, 184, 220, 0.12);
}

.field-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 14px;
}

.configuration-summary {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  border: 1px solid #2c3942;
  background: #2c3942;
}

.configuration-summary > div {
  min-width: 0;
  padding: 13px;
  background: #0c1115;
}

.configuration-summary span {
  display: block;
  margin-bottom: 5px;
  color: #6f818d;
  font-family: Consolas, monospace;
  font-size: 0.6rem;
  letter-spacing: 0.08em;
}

.configuration-summary strong {
  display: block;
  overflow: hidden;
  color: #d8e1e6;
  font-size: 0.76rem;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.content-stack {
  display: flex;
  max-height: 152px;
  flex-direction: column;
  gap: 6px;
  overflow-y: auto;
}

.content-item {
  display: grid;
  grid-template-columns: 62px minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 9px;
  padding: 10px;
  border: 1px solid #26333c;
  background: #0c1115;
}

.content-kind,
.content-version,
.approval {
  font-family: Consolas, monospace;
  font-size: 0.58rem;
  letter-spacing: 0.05em;
}

.content-kind {
  color: var(--steel);
}

.content-name {
  overflow: hidden;
  color: #aebbc3;
  font-size: 0.7rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.content-version {
  color: #778892;
}

.approval {
  color: var(--success);
}

fieldset {
  margin: 0;
  padding: 0;
  border: 0;
}

.segment {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
}

.segment label {
  position: relative;
}

.segment input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.segment span {
  display: grid;
  min-height: 42px;
  place-items: center;
  border: 1px solid #35444f;
  background: #0c1115;
  color: #8b9aa5;
}

.segment input:checked + span {
  border-color: var(--orange);
  background: rgba(255, 122, 26, 0.09);
  color: #ffc294;
}

.primary-button {
  display: flex;
  min-height: 54px;
  align-items: center;
  justify-content: space-between;
  margin-top: 5px;
  padding: 0 18px;
  border: 1px solid var(--orange);
  background: var(--orange);
  color: #16100b;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.primary-button:hover:not(:disabled),
.primary-button:focus-visible:not(:disabled) {
  background: #ff9144;
}

.primary-button:disabled {
  cursor: wait;
  opacity: 0.6;
}

.form-note {
  margin: -5px 0 0;
  color: #73828c;
  font-size: 0.75rem;
}

.empty-state {
  display: grid;
  min-height: 390px;
  place-items: center;
  align-content: center;
  text-align: center;
}

.empty-glyph {
  display: grid;
  width: 82px;
  height: 82px;
  margin-bottom: 24px;
  place-items: center;
  border: 1px solid #35444f;
  color: var(--steel);
  font-family: Consolas, monospace;
}

.empty-state h3 {
  margin-bottom: 8px;
}

.empty-state p {
  max-width: 350px;
  color: var(--muted);
  line-height: 1.55;
}

.build-list {
  display: flex;
  max-height: 430px;
  flex-direction: column;
  gap: 12px;
  overflow: auto;
  padding-right: 5px;
}

.build-card {
  padding: 19px;
  border: 1px solid #2c3942;
  background: var(--ink);
}

.build-card-top,
.build-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.build-id {
  color: var(--steel);
  font-size: 0.65rem;
}

.build-card h3 {
  margin: 4px 0 0;
  font-size: 1rem;
}

.build-status {
  padding: 6px 8px;
  border: 1px solid var(--steel-dim);
  color: var(--steel);
  font-family: Consolas, monospace;
  font-size: 0.62rem;
}

.build-status.completed {
  border-color: #386d52;
  color: var(--success);
}

.build-status.failed {
  border-color: #85453f;
  color: #ff8e82;
}

.build-message {
  margin: 18px 0 11px;
  color: #bdc8ce;
  font-size: 0.85rem;
}

.progress-track {
  height: 5px;
  overflow: hidden;
  background: #202a31;
}

.progress-fill {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--steel-dim), var(--steel));
  transition: width 300ms ease;
}

.completed .progress-fill {
  background: var(--success);
}

.build-meta {
  flex-wrap: wrap;
  margin-top: 13px;
  color: #71808a;
  font-family: Consolas, monospace;
  font-size: 0.62rem;
}

.notice {
  margin: 16px 0 0;
  padding: 11px;
  border-left: 2px solid var(--steel);
  background: rgba(121, 184, 220, 0.07);
  color: #b8d7e8;
  font-size: 0.76rem;
}

footer {
  display: flex;
  justify-content: space-between;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  color: #5d6c75;
  font-size: 0.62rem;
}

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

  .proof-badge {
    min-width: 0;
  }
}

@media (max-width: 560px) {
  .app-shell {
    padding-inline: 16px;
  }

  .environment,
  .brand-tagline {
    display: none;
  }

  main {
    padding-top: 44px;
  }

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

  .configuration-summary {
    grid-template-columns: 1fr;
  }

  .content-item {
    grid-template-columns: 62px minmax(0, 1fr) auto;
  }

  .content-version {
    display: none;
  }

  footer {
    flex-direction: column;
    gap: 8px;
  }
}

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

.pilot-shell {
  width: min(1320px, 100%);
  min-height: 100vh;
  margin: 0 auto;
  padding: 26px clamp(22px, 5vw, 72px) 40px;
}

.pilot-main {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(340px, 0.75fr);
  align-items: center;
  gap: clamp(36px, 7vw, 90px);
  min-height: calc(100vh - 130px);
  padding: 60px 0;
}

.pilot-story h1 {
  max-width: 800px;
}

.pilot-card {
  padding: clamp(28px, 4vw, 44px);
  border: 1px solid var(--line);
  border-top: 3px solid var(--orange);
  background: rgba(17, 23, 28, 0.96);
  box-shadow: 0 24px 90px rgba(0, 0, 0, 0.32);
}

.pilot-card h2 {
  margin-bottom: 8px;
  font-size: clamp(1.7rem, 3vw, 2.35rem);
}

.pilot-email {
  margin-bottom: 24px;
  color: var(--steel);
  font-family: Consolas, "Cascadia Mono", monospace;
  font-size: 0.82rem;
}

.pilot-roles {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
}

.pilot-roles span {
  padding: 7px 9px;
  border: 1px solid var(--steel-dim);
  color: #b7d9ec;
  font-family: Consolas, "Cascadia Mono", monospace;
  font-size: 0.64rem;
  letter-spacing: 0.08em;
}

.pilot-note {
  margin-bottom: 24px;
  color: var(--muted);
  font-size: 0.84rem;
  line-height: 1.6;
}

.pilot-button {
  width: 100%;
}

@media (max-width: 860px) {
  .pilot-main {
    grid-template-columns: 1fr;
    align-items: start;
  }
}
