:root {
  color-scheme: dark;
  --space: #071522;
  --surface: #102b3a;
  --surface-deep: #0b202e;
  --text: #e4e8e2;
  --muted: #acbac1;
  --sand: #e7c884;
  --sky: #84bfd0;
  --border: #365363;
  --input-border: #64828f;
  --error: #ffb6ad;
  --error-surface: #3c2228;
  --notice: #c4dfcb;
  --notice-surface: #18352e;
  font-family: "Segoe UI", "Aptos", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  background: var(--space);
  color: var(--text);
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 280px; }
button, input, select { font: inherit; }
button, a, input, select { -webkit-tap-highlight-color: transparent; }
button, a { touch-action: manipulation; }
a { color: var(--sky); text-underline-offset: 4px; }
a:hover { color: var(--text); }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, [tabindex]:focus-visible { outline: 3px solid var(--sand); outline-offset: 4px; }
main:focus { outline: none; }
p, h1, h2, h3 { margin: 0; }
p { max-width: 68ch; }
h1, h2, h3, .brand { font-family: "Bahnschrift", "Segoe UI", sans-serif; }
h1 { font-size: clamp(2.5rem, 5vw, 4.8rem); font-weight: 600; line-height: 1.06; letter-spacing: -.035em; text-wrap: balance; }
h2 { font-size: 1.45rem; line-height: 1.25; font-weight: 600; letter-spacing: -.015em; }
img, svg { display: block; max-width: 100%; }
form { margin: 0; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; }
.site-shell { max-width: 1320px; margin: 0 auto; padding: 0 48px; }
.skip-link { position: absolute; top: -100px; left: 16px; padding: 12px 20px; background: var(--sand); color: var(--space); z-index: 20; }
.skip-link:focus { top: 12px; }
.site-header { min-height: 104px; display: flex; align-items: center; justify-content: space-between; gap: 32px; border-bottom: 1px solid var(--border); }
.brand { display: inline-flex; align-items: center; gap: 12px; font-size: 1.35rem; font-weight: 600; color: var(--text); text-decoration: none; flex-shrink: 0; }
.brand img { flex-shrink: 0; }
nav { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
nav a, .nav-logout button { min-height: 44px; display: inline-flex; align-items: center; padding: 9px 14px; text-decoration: none; font-size: .95rem; color: var(--muted); }
nav a[aria-current="page"] { color: var(--text); text-decoration: underline; text-decoration-color: var(--sand); text-underline-offset: 9px; text-decoration-thickness: 2px; }
nav a:hover, .nav-logout button:hover { color: var(--text); }
nav .nav-invite { border: 1px solid var(--border); border-radius: 5px; margin-left: 12px; color: var(--text); }
.nav-logout { margin-left: 8px; border-left: 1px solid var(--border); padding-left: 8px; }
.nav-logout button { background: transparent; border: 0; }
main { min-height: calc(100dvh - 224px); }
.home-hero { position: relative; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); align-items: center; min-height: 608px; padding: 66px 0 60px; gap: 12px; }
.hero-copy { position: relative; z-index: 1; }
.intro-line { color: var(--sky); font-size: .95rem; margin-bottom: 22px; display: flex; align-items: center; gap: 10px; }
.small-orbit { display: inline-block; width: 22px; height: 12px; border: 1px solid var(--sky); border-radius: 50%; transform: rotate(-28deg); }
.hero-description { color: var(--muted); font-size: 1.1rem; margin-top: 26px; max-width: 45ch; }
.hero-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; margin-top: 34px; }
.button { min-height: 48px; padding: 12px 22px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid transparent; border-radius: 5px; font-weight: 600; font-size: .98rem; text-decoration: none; text-align: center; line-height: 1.4; transition: background-color 140ms ease, border-color 140ms ease, color 140ms ease; }
.button-primary { color: var(--space); background: var(--sand); }
.button-primary:hover { color: var(--space); background: #f3dcae; }
.button-primary:active { background: #cfad68; }
.button-secondary { color: var(--text); border-color: var(--input-border); background: transparent; }
.button-secondary:hover { color: var(--text); background: var(--surface); border-color: var(--sky); }
.button-danger { background: transparent; color: var(--error); border-color: #9b655f; }
.button-danger:hover { background: var(--error-surface); }
.button-disabled { color: #c0cbd0; background: #233b49; border-color: #526d7b; }
.quiet-note { color: var(--muted); font-size: .88rem; max-width: 45ch; margin-top: 20px; }
.welcome { margin-top: 24px; color: var(--text); }
.orbit-art { width: 100%; margin-left: 0; opacity: .92; }
.orbit-grid { stroke: #32515f; stroke-width: 1; stroke-dasharray: 2 7; }
.orbit-track { stroke: var(--sky); stroke-width: 1.4; }
.planet-seam { stroke: #487383; stroke-width: 1; }
.orbit-stars { fill: #aac1c9; }
.orbit-waypoints { fill: var(--sand); stroke: var(--sand); stroke-width: 1; }
.orbit-small { stroke: #718e9a; stroke-width: 1; }
.arrival-notes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 36px; padding: 34px 0 54px; border-top: 1px solid var(--border); }
.arrival-notes h2 { font-size: 1.12rem; margin-bottom: 10px; }
.arrival-notes p { font-size: .94rem; color: var(--muted); }
.site-footer { min-height: 120px; padding: 26px 0; border-top: 1px solid var(--border); display: flex; align-items: center; justify-content: space-between; gap: 24px; color: var(--muted); font-size: .85rem; }
.site-footer > span { color: var(--text); font-size: 1rem; }
.entry-layout { display: grid; grid-template-columns: minmax(0, .95fr) minmax(0, 1fr); align-items: start; gap: clamp(40px, 8vw, 120px); padding: 64px 0 72px; }
.entry-intro { padding-top: 30px; }
.entry-intro h1 { font-size: clamp(2.6rem, 4.4vw, 4.15rem); }
.entry-intro > p:not(.intro-line) { margin-top: 24px; color: var(--muted); font-size: 1.08rem; max-width: 35ch; }
.entry-caption { display: flex; align-items: center; gap: 22px; padding-top: 50px; color: var(--muted); font-size: .94rem; }
.entry-caption img { flex-shrink: 0; }
.form-panel { border: 1px solid var(--border); border-radius: 10px; padding: clamp(24px, 3vw, 40px); background: var(--surface-deep); }
.form-panel > h2 { font-size: 1.65rem; }
.panel-description { color: var(--muted); margin-top: 10px; }
.account-form { display: grid; gap: 21px; margin-top: 28px; }
.account-form > .button { width: 100%; margin-top: 5px; }
.field { min-width: 0; }
.field label { display: block; margin-bottom: 8px; font-weight: 500; font-size: .95rem; }
input:not([type="hidden"]), select { width: 100%; min-height: 48px; background: var(--space); border: 1px solid var(--input-border); border-radius: 5px; padding: 10px 13px; color: var(--text); line-height: 1.4; }
input:not([type="hidden"]):hover, select:hover { border-color: var(--sky); }
input[aria-invalid="true"] { border-color: var(--error); }
input:-webkit-autofill { -webkit-text-fill-color: var(--text); box-shadow: 0 0 0 1000px var(--space) inset; }
.field-hint { font-size: .82rem; color: var(--muted); margin-top: 8px; line-height: 1.5; }
.field-error { font-size: .86rem; color: var(--error); margin-top: 8px; line-height: 1.5; }
.optional { color: var(--muted); font-size: .78rem; font-weight: 400; margin-left: 8px; }
.form-bottom { border-top: 1px solid var(--border); padding-top: 24px; margin-top: 28px; font-size: .9rem; color: var(--muted); }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
fieldset { border: 0; padding: 0; margin: 0; display: grid; gap: 20px; min-width: 0; }
fieldset + fieldset { border-top: 1px solid var(--border); padding-top: 23px; }
legend { padding: 0; margin-bottom: 16px; color: var(--sky); font-weight: 500; }
.invitation-note { margin-top: 44px; border-left: 2px solid var(--sand); padding-left: 22px; max-width: 36ch; }
.invitation-note h2 { font-size: 1.05rem; margin-bottom: 14px; }
.invitation-note p { font-size: .94rem; color: var(--muted); margin-top: 12px; }
.message { border: 1px solid; border-radius: 5px; padding: 16px 18px; margin-top: 22px; font-size: .94rem; overflow-wrap: anywhere; }
.message h2 { font-size: 1rem; margin-bottom: 8px; }
.message-error { color: var(--error); border-color: #9b655f; background: var(--error-surface); }
.message-error a { color: var(--error); }
.message ul { margin: 10px 0 0; padding-left: 22px; }
.message-notice { color: var(--notice); border-color: #527a66; background: var(--notice-surface); }
.page-heading { padding: 52px 0 34px; display: flex; align-items: end; justify-content: space-between; gap: 24px; }
.page-heading .intro-line { margin-bottom: 14px; }
.page-heading h1 { font-size: clamp(2.5rem, 4vw, 3.8rem); }
.page-heading p:not(.intro-line) { margin-top: 18px; color: var(--muted); }
.pilot-strip { display: flex; align-items: center; gap: 20px; padding: 25px 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); margin-top: 12px; }
.pilot-strip img { flex-shrink: 0; }
.pilot-strip h2 { overflow-wrap: anywhere; }
.pilot-strip > div { min-width: 0; }
.pilot-label { color: var(--muted); font-size: .82rem; }
.pilot-strip dl { margin: 0 0 0 auto; display: flex; gap: 44px; }
dt { font-size: .82rem; color: var(--muted); }
dd { margin: 2px 0 0; font-weight: 600; }
.account-columns { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 72px; padding: 44px 0 64px; }
.account-section { min-width: 0; }
.account-section > h2 { margin-bottom: 10px; }
.account-section > p { color: var(--muted); font-size: .95rem; }
.account-section .account-form { max-width: 420px; }
.table-scroll { overflow-x: auto; margin-top: 26px; }
table { border-collapse: collapse; width: 100%; font-size: .85rem; }
caption { text-align: left; color: var(--muted); font-size: .8rem; margin-bottom: 10px; }
th, td { text-align: left; padding: 12px 12px 12px 0; border-bottom: 1px solid var(--border); vertical-align: top; }
thead th { color: var(--muted); font-weight: 500; }
tbody th { color: var(--text); font-weight: 500; }
.session-address { display: block; font-size: .78rem; font-weight: 400; color: var(--muted); overflow-wrap: anywhere; }
td { color: var(--muted); font-variant-numeric: tabular-nums; }
.session-action { padding-top: 28px; }
.session-action .field-hint { max-width: 36ch; }
.empty-note { margin-top: 26px; color: var(--muted); }
.launch-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 44px; margin-top: 44px; }
.launch-option { display: flex; gap: 22px; min-width: 0; padding: 0 0 36px; }
.client-symbol { width: 56px; height: 56px; border: 1px solid var(--input-border); border-radius: 50%; display: grid; place-items: center; font-family: "Bahnschrift", "Segoe UI", sans-serif; color: var(--sand); font-size: 1.5rem; flex-shrink: 0; }
.client-web { border-radius: 8px; color: var(--sky); }
.launch-copy { display: flex; flex-direction: column; align-items: start; min-width: 0; }
.client-state { color: var(--muted); font-size: .82rem; margin-bottom: 10px; }
.state-ready { color: var(--notice); }
.launch-copy h2 { margin-bottom: 14px; font-size: 1.55rem; }
.launch-copy > p:not(.client-state) { color: var(--muted); font-size: .96rem; }
.launch-copy .launch-reason { padding-top: 18px; margin-top: auto; max-width: 45ch; }
.launch-copy form { margin-top: 24px; }
.play-footnote { margin: 0 0 54px 78px; color: var(--muted); font-size: .88rem; }

@media (max-width: 1050px) {
  .site-shell { padding: 0 32px; }
  .home-hero { min-height: 540px; }
  .hero-actions { align-items: stretch; flex-direction: column; max-width: 330px; }
  .orbit-art { width: 100%; margin-left: 0; }
  .entry-layout { gap: 44px; }
  .form-grid { grid-template-columns: 1fr; gap: 20px; }
  .account-columns { gap: 44px; }
}
@media (max-width: 760px) {
  .site-shell { padding: 0 24px; }
  .site-header { min-height: 88px; gap: 18px; flex-wrap: wrap; padding: 20px 0; }
  .brand { font-size: 1.25rem; }
  nav { gap: 0; justify-content: flex-start; width: 100%; }
  nav a, .nav-logout button { padding-left: 10px; padding-right: 10px; }
  nav a:first-child { padding-left: 0; }
  nav .nav-invite { margin-left: auto; padding-left: 12px; }
  .home-hero { grid-template-columns: 1fr; min-height: auto; padding-top: 44px; gap: 0; }
  .home-hero h1 { font-size: clamp(2.65rem, 10vw, 4.1rem); }
  .hero-description { max-width: 45ch; }
  .hero-actions { flex-direction: row; max-width: none; }
  .hero-actions .button { flex: 1 1 220px; }
  .orbit-art { width: min(100%, 500px); margin: -6px auto -30px; }
  .arrival-notes { grid-template-columns: 1fr; gap: 26px; padding-top: 30px; }
  .arrival-notes p { max-width: 52ch; }
  .entry-layout { grid-template-columns: 1fr; padding: 38px 0 48px; gap: 30px; }
  .entry-intro { padding: 0; }
  .entry-intro > p:not(.intro-line) { max-width: 47ch; }
  .entry-intro h1 { font-size: 2.7rem; }
  .entry-caption { display: none; }
  .invitation-note { margin-top: 28px; max-width: 52ch; }
  .form-panel { padding: 28px 24px; }
  .form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
  .page-heading { padding-top: 38px; align-items: start; flex-direction: column; }
  .pilot-strip { flex-wrap: wrap; gap: 16px; }
  .pilot-strip dl { width: 100%; margin-left: 72px; gap: 40px; }
  .account-columns { grid-template-columns: 1fr; gap: 38px; padding-top: 34px; }
  .account-section .account-form { max-width: none; }
  .account-section + .account-section { border-top: 1px solid var(--border); padding-top: 32px; }
  .launch-list { grid-template-columns: 1fr; gap: 0; margin-top: 32px; }
  .launch-option + .launch-option { border-top: 1px solid var(--border); padding-top: 32px; }
  .launch-copy .launch-reason { margin-top: 0; }
  .play-footnote { margin-left: 0; }
  .site-footer { align-items: start; flex-direction: column; gap: 10px; min-height: 106px; }
}
@media (max-width: 420px) {
  .site-shell { padding: 0 18px; }
  .form-panel { padding: 24px 18px; }
  .form-grid { grid-template-columns: 1fr; gap: 20px; }
  .brand img { width: 36px; height: 36px; }
  nav { font-size: .9rem; }
  nav .nav-invite { font-size: .85rem; padding: 9px; }
  .launch-option { gap: 16px; }
  .client-symbol { width: 44px; height: 44px; font-size: 1.2rem; }
  .launch-copy .button { width: 100%; }
  .launch-copy form { align-self: stretch; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: 0ms !important; animation: none !important; }
}
