@font-face {
  font-family: Figtree;
  src: url("./figtree-latin.woff2") format("woff2");
  font-weight: 300 900;
  font-display: swap;
}

@font-face {
  font-family: "IBM Plex Mono";
  src: url("./ibm-plex-mono-400.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}

:root {
  color-scheme: light;
  --ink: #0a0a0a;
  --paper: #fff;
  --muted: #60606a;
  --line: #e4e4e8;
  --control: #85858d;
  --soft: #f7f7f9;
  --dark-muted: #b7b7c0;
  --dark-line: #343438;
  --cyan: #51dbf7;
  --violet: #a855f7;
  --focus: #6b21a8;
  --error: #a12622;
  --sans: Figtree, system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; color: var(--ink); background: var(--paper); font-family: var(--sans); -webkit-font-smoothing: antialiased; }
button, input { font: inherit; }
a { color: inherit; text-underline-offset: 4px; }
button, a, input { -webkit-tap-highlight-color: transparent; }
a:focus-visible, button:focus-visible, input:focus-visible { outline: 3px solid var(--focus); outline-offset: 4px; }
button:disabled { cursor: not-allowed; opacity: .55; }
[hidden] { display: none !important; }
.skip-link { position: fixed; z-index: 10; top: 12px; left: 12px; padding: 12px 18px; background: var(--paper); transform: translateY(-180%); }
.skip-link:focus { transform: none; }
.login-shell { min-height: 100svh; display: grid; grid-template-columns: minmax(400px, 46%) 1fr; }

.brand-panel { position: relative; display: flex; flex-direction: column; padding: 44px clamp(36px, 4.7vw, 80px) 32px; color: var(--paper); background: var(--ink); isolation: isolate; }
.brand-panel::before { content: ""; position: absolute; z-index: -1; inset: 0; background: radial-gradient(ellipse at 10% 80%, #51dbf709, transparent 65%); pointer-events: none; }
.brand-link { display: inline-flex; width: fit-content; padding: 4px 0; }
.brand-logo { display: block; width: 184px; height: auto; }
.brand-panel a:focus-visible { outline-color: var(--cyan); }
.brand-story { width: 100%; max-width: 500px; margin: auto 0; padding: 76px 0 64px; }
.eyebrow { margin: 0 0 22px; font: 11px/1.6 var(--mono); letter-spacing: .12em; text-transform: uppercase; }
.brand-story .eyebrow { color: var(--dark-muted); }
.brand-story h2 { margin: 0; font-size: clamp(38px, 4.1vw, 60px); font-weight: 500; line-height: 1.07; letter-spacing: -.045em; }
.brand-story h2 span { display: block; }
.brand-description { max-width: 32ch; margin: 24px 0 0; color: var(--dark-muted); font-size: 17px; line-height: 1.6; }

.document-scene { position: relative; display: grid; grid-template-columns: 86px 1fr 64px 1fr 112px; align-items: center; margin: 52px 0 24px; min-height: 128px; }
.paper-stack { position: relative; height: 113px; }
.paper { position: absolute; width: 70px; height: 91px; border: 1px solid #66666f; border-radius: 5px; background: #1b1b1f; }
.paper-back { left: 0; top: 0; transform: rotate(-8deg); }
.paper-front { left: 12px; top: 14px; padding: 14px 10px; transform: rotate(3deg); }
.paper-front b { display: block; width: 21px; padding: 3px 0; border-bottom: 1px solid var(--cyan); color: var(--paper); font: 9px var(--mono); }
.paper-front i { display: block; height: 2px; margin-top: 9px; background: #73737c; }
.paper-front i:last-child { width: 70%; background: var(--cyan); }
.flow-line { height: 1px; margin: 0 8px; background: var(--dark-line); position: relative; overflow: hidden; }
.flow-line::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, transparent, var(--cyan)); transform-origin: left; animation: connect 850ms 300ms both; }
.flow-line.flow-out::after { background: linear-gradient(90deg, transparent, var(--violet)); animation-delay: 850ms; }
.flow-core { width: 64px; height: 64px; display: grid; place-items: center; border: 1px solid #5c4a75; border-radius: 16px; background: #1d1925; }
.flow-core img { width: 38px; height: 34px; }
.output-stack { display: grid; gap: 8px; }
.output-row { display: flex; align-items: center; gap: 9px; padding: 11px 10px; border: 1px solid var(--dark-line); border-radius: 5px; background: #18181c; animation: settle 550ms 900ms both; }
.output-row:nth-child(2) { animation-delay: 1050ms; }
.output-row:nth-child(3) { animation-delay: 1200ms; }
.output-row i { width: 7px; height: 7px; border: 1px solid var(--cyan); border-radius: 2px; flex: none; }
.output-row:nth-child(2) i { border-color: var(--violet); }
.output-row span { height: 2px; width: 100%; background: #73737c; }
.process-label { margin: 0; color: var(--dark-muted); font: 11px/1.7 var(--mono); letter-spacing: .015em; }
.brand-footer { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; padding-top: 24px; border-top: 1px solid var(--dark-line); color: var(--dark-muted); font-size: 11px; line-height: 1.5; }
.residency { display: inline-flex; align-items: center; gap: 9px; }
.residency img { width: 25px; height: 17px; }
.copyright { margin: 0; }

.access-panel { display: flex; flex-direction: column; padding: 38px clamp(28px, 5vw, 84px) 26px; min-width: 0; }
.access-header { display: flex; align-items: center; justify-content: space-between; gap: 20px; min-height: 44px; }
.home-link { display: inline-flex; align-items: center; gap: 9px; min-height: 44px; text-decoration: none; font-size: 13px; color: var(--muted); }
.home-link:hover { color: var(--ink); text-decoration: underline; }
.home-link svg { width: 15px; height: 15px; }
.language-nav { display: flex; align-items: center; gap: 2px; }
.language-nav a { display: grid; place-items: center; min-width: 42px; min-height: 44px; border-radius: 5px; color: var(--muted); font: 11px var(--mono); text-decoration: none; }
.language-nav a[aria-current="page"] { color: var(--ink); background: var(--soft); }
.language-nav a:hover { color: var(--ink); background: var(--soft); }
.login-card { width: 100%; max-width: 400px; margin: auto; padding: 64px 0; animation: settle 650ms 80ms both; }
.mobile-brand { display: none; }
.access-kicker { display: flex; align-items: center; gap: 8px; width: fit-content; margin: 0 0 22px; color: var(--muted); font-size: 12px; }
.access-kicker::before { content: ""; width: 6px; height: 6px; border: 1px solid currentColor; border-radius: 50%; }
h1 { margin: 0; font-size: clamp(28px, 2.8vw, 38px); line-height: 1.13; letter-spacing: -.035em; font-weight: 500; }
.login-description { margin: 14px 0 32px; color: var(--muted); line-height: 1.6; font-size: 15px; max-width: 37ch; }
.field-label { display: block; margin: 0 0 10px; font-size: 13px; font-weight: 600; }
.email-wrap { position: relative; }
.email-wrap svg { position: absolute; top: 18px; left: 16px; width: 18px; height: 18px; color: var(--muted); pointer-events: none; }
.email-input { width: 100%; min-height: 54px; border: 1px solid var(--control); border-radius: 6px; background: var(--paper); color: var(--ink); padding: 14px 16px 14px 46px; font-size: 16px; transition: border-color 150ms; }
.email-input::placeholder { color: var(--muted); opacity: 1; }
.email-input:hover { border-color: var(--ink); }
.email-input[aria-invalid="true"] { border-color: var(--error); }
.field-error { margin: 9px 0 0; color: var(--error); font-size: 13px; line-height: 1.5; }
.field-error:empty { display: none; }
.continue-button { display: flex; align-items: center; justify-content: center; gap: 12px; width: 100%; min-height: 54px; margin-top: 16px; padding: 14px 20px; border: 1px solid var(--ink); border-radius: 6px; color: var(--paper); background: var(--ink); cursor: pointer; font-size: 14px; font-weight: 500; transition: background 150ms; }
.continue-button svg { width: 17px; height: 17px; transition: transform 180ms; }
.continue-button:hover:not(:disabled) { background: #28282b; }
.continue-button:hover:not(:disabled) svg { transform: translateX(3px); }
.access-status { margin: 0; font-size: 13px; line-height: 1.6; color: var(--muted); }
.access-status:not(:empty) { margin-top: 18px; padding: 14px 16px; border: 1px solid var(--line); border-radius: 6px; background: var(--soft); }
.contact-note { margin: 26px 0 0; padding-top: 24px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; line-height: 1.65; }
.contact-note a { display: inline-block; min-height: 24px; color: var(--ink); }
.launch-note { margin: 20px 0 0; max-width: 46ch; font-size: 12px; line-height: 1.6; color: var(--muted); }
.access-footer { display: flex; justify-content: center; flex-wrap: wrap; gap: 8px 24px; }
.access-footer a { display: inline-flex; align-items: center; min-height: 44px; color: var(--muted); font-size: 12px; }
.access-footer a:hover { color: var(--ink); }

@keyframes settle { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
@keyframes connect { from { transform: scaleX(0); } to { transform: scaleX(1); } }

@media (min-width: 1600px) {
  .brand-story { margin-left: auto; margin-right: auto; }
  .login-card { max-width: 420px; }
}
@media (max-width: 1050px) and (min-width: 801px) {
  .brand-panel { padding-left: 32px; padding-right: 32px; }
  .access-panel { padding-left: 32px; padding-right: 32px; }
  .brand-story h2 { font-size: 42px; }
  .document-scene { grid-template-columns: 76px 1fr 56px 1fr 94px; }
  .flow-core { width: 56px; height: 56px; }
}
@media (max-width: 800px) {
  .login-shell { display: block; }
  .brand-panel { display: none; }
  .access-panel { min-height: 100svh; padding: 20px 28px 16px; }
  .login-card { padding: 52px 0; }
  .mobile-brand { display: inline-flex; margin-bottom: 44px; }
  .mobile-brand img { width: 180px; height: auto; }
  h1 { font-size: 32px; }
}
@media (max-width: 360px) {
  .access-panel { padding-left: 20px; padding-right: 20px; }
  .login-card { padding-top: 36px; padding-bottom: 36px; }
  h1 { font-size: 29px; }
}
@media (prefers-reduced-motion: reduce) {
  .login-card, .output-row, .flow-line::after { animation: none; }
  .continue-button, .continue-button svg, .email-input { transition: none; }
  .continue-button:hover:not(:disabled) svg { transform: none; }
}

@media (forced-colors: active) {
  .brand-panel { border-right: 1px solid CanvasText; }
  .language-nav a[aria-current="page"] { outline: 1px solid CanvasText; }
}
