﻿@layer base, layout, components, responsive;

@layer base {
  :root {
    color-scheme:dark;
    --background:#0A0F18; --surface:#0C1420; --panel:#101A28;
    --border:#1A2636; --border-strong:#263B58; --heading:#F8FBFF;
    --text:#E5EDF7; --muted:#8FA4BD; --action:#15506D;
    --action-border:#2D6A8A; --accent:#62C0E2; --error:#FFACB4;
    font-family:Inter,system-ui,-apple-system,"Segoe UI",sans-serif;
    font-synthesis:none; color:var(--text); background:var(--background);
  }
  * { box-sizing:border-box; }
  html { scroll-padding-top:24px; }
  body { margin:0; font-size:16px; line-height:1.7; }
  h1,h2,h3,p,figure { margin:0; }
  h1,h2,h3 { color:var(--heading); font-weight:600; line-height:1.15; }
  h1 { font-size:clamp(2.25rem,4.6vw,3.5rem); letter-spacing:-.045em; }
  h2 { font-size:clamp(1.75rem,3vw,2.25rem); letter-spacing:-.03em; }
  h3 { font-size:1.25rem; line-height:1.4; letter-spacing:-.015em; }
  p + p { margin-top:16px; }
  a { color:inherit; text-underline-offset:5px; text-decoration-thickness:1px; }
  a:hover { color:var(--accent); }
  button,input,select { font:inherit; }
  button { cursor:pointer; }
  :focus-visible { outline:3px solid var(--accent); outline-offset:4px; }
  [hidden] { display:none !important; }
  ::selection { background:var(--action); color:var(--heading); }
  code { font-family:Consolas,monospace; font-size:.95em; }
}

@layer layout {
  .wrap { width:min(1160px,calc(100% - 80px)); margin-inline:auto; }
  .section { padding-block:80px; }
  .surface { background:var(--surface); border-block:1px solid var(--border); }
  .site-header { display:flex; align-items:center; justify-content:space-between; gap:32px; min-height:96px; border-bottom:1px solid var(--border); }
  .hero { display:grid; grid-template-columns:1.15fr 1fr; gap:72px; align-items:center; padding-block:88px 80px; }
  .processing-note { display:grid; grid-template-columns:minmax(0,1fr) 280px; gap:80px; align-items:center; padding-block:32px; border-block:1px solid var(--border); }
  .editorial-grid { display:grid; grid-template-columns:1fr 1.15fr; gap:96px; }
  .page-intro { padding-block:72px 64px; border-bottom:1px solid var(--border); }
  .page-intro > p:not(.eyebrow) { max-width:700px; margin-top:24px; font-size:18px; }
  .section-heading { margin-bottom:40px; max-width:760px; }
  .section-heading > p:last-child { margin-top:24px; max-width:680px; }
  .split-heading { display:grid; grid-template-columns:1.1fr 1fr; gap:64px; max-width:none; align-items:end; }
  .feature-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:24px; }
  .pricing-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:24px; }
  .registration-grid { display:grid; grid-template-columns:1fr 1.2fr; gap:72px; align-items:start; }
  .privacy-section { display:grid; grid-template-columns:1fr 1.2fr; gap:72px; }
  .site-footer { display:flex; align-items:start; justify-content:space-between; flex-wrap:wrap; gap:32px; padding-block:40px; border-top:1px solid var(--border); }
}

@layer components {
  .skip-link { position:fixed; z-index:10; left:16px; top:-100px; padding:12px 20px; background:var(--panel); border:1px solid var(--accent); border-radius:8px; }
  .skip-link:focus { top:12px; }
  .brand { display:inline-flex; align-items:center; gap:10px; min-height:48px; text-decoration:none; font-size:26px; font-weight:650; letter-spacing:-1px; color:var(--heading); }
  .brand img { display:block; width:36px; height:36px; flex-shrink:0; object-fit:contain; }
  nav { display:flex; align-items:center; gap:32px; }
  nav a { display:inline-flex; align-items:center; min-height:44px; text-decoration:none; font-size:14px; }
  nav a[aria-current=page]:not(.button) { color:var(--heading); text-decoration:underline; text-decoration-color:var(--accent); text-underline-offset:8px; }
  .button { display:inline-flex; min-height:48px; align-items:center; justify-content:center; gap:20px; border:1px solid var(--action-border); border-radius:8px; background:var(--action); color:var(--heading); padding:10px 20px; text-decoration:none; font-size:14px; font-weight:600; line-height:1.6; transition:background .15s,border-color .15s; }
  .button:hover { background:#1A607F; border-color:var(--accent); color:var(--heading); }
  .button:disabled { opacity:.65; cursor:default; }
  .eyebrow { font-size:13px; font-weight:600; letter-spacing:.12em; color:var(--muted); margin-bottom:16px; }
  .hero-description { font-size:22px; line-height:1.5; margin-top:24px; max-width:440px; color:var(--heading); }
  .hero-copy h1 { font-size:clamp(2rem,3.6vw,3.25rem); text-wrap:balance; }
  .hero-copy > p:not(.eyebrow):not(.hero-description) { max-width:510px; margin-top:20px; }
  .hero-actions { display:flex; flex-wrap:wrap; align-items:center; gap:16px 24px; margin-top:28px; }
  .text-link { display:inline-flex; align-items:center; min-height:44px; font-size:14px; font-weight:600; color:var(--accent); }
  .mini-pill { display:inline-block; border:1px solid var(--border-strong); border-radius:4px; font-size:12px; color:var(--muted); padding:3px 8px; letter-spacing:.05em; }
  .media-figure { min-width:0; width:100%; background:var(--surface); border:1px solid var(--border-strong); border-radius:12px; overflow:hidden; }
  .media-frame { aspect-ratio:16 / 9; display:grid; place-items:center; padding:16px; color:var(--muted); font-size:14px; }
  #process-diagram { min-width:0; }
  .process-illustration { display:block; width:100%; height:auto; }
  .product-screenshot { display:block; width:100%; height:auto; object-fit:contain; }
  #product-screenshot { overflow:visible; border-radius:0; }
  .media-figure figcaption { padding:12px 16px; border-top:1px solid var(--border); color:var(--muted); font-size:13px; }
  .demo-figure { max-width:280px; align-self:center; justify-self:center; }
  .showcase-heading { margin-bottom:32px; }
  .showcase-heading p { margin-top:20px; }
  .processing-note .prose { max-width:680px; }
  .value-section > h2 { max-width:760px; text-wrap:balance; }
  .value-section + .value-section,.value-section + .closing-cta { border-top:1px solid var(--border); }
  .value-list { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:32px 56px; margin:32px 0 0; padding-left:24px; }
  .value-list li { padding-left:8px; }
  .value-list li::marker { color:var(--accent); font-size:14px; }
  .value-list p { margin-top:12px; }
  .planned-note { margin-top:24px; padding-left:20px; border-left:2px solid var(--accent); max-width:760px; font-size:14px; color:var(--muted); }
  .planned-note h3 { font-size:16px; margin-bottom:8px; }
  .planned-ref { color:var(--accent); padding-inline:3px; text-decoration:none; }
  .commercial-terms { max-width:760px; margin-top:32px; }
  .migration-notice { display:grid; grid-template-columns:1fr auto; align-items:center; gap:40px; padding:28px 32px; background:var(--panel); border:1px solid var(--border-strong); border-radius:10px; }
  .migration-notice .eyebrow { margin-bottom:8px; }
  .migration-notice h2 { font-size:22px; margin-bottom:12px; }
  .migration-notice p:last-child { max-width:750px; }
  .notice-actions { display:flex; flex-direction:column; align-items:start; gap:4px; }
  .source-link { font-size:13px; color:var(--muted); min-height:44px; display:inline-flex; align-items:center; }
  .prose h3:not(:first-child) { margin-top:32px; }
  .prose h3 + p { margin-top:12px; }
  .prose > .text-link,.prose > .button { margin-top:24px; }
  .closing-cta { display:flex; gap:64px; justify-content:space-between; align-items:center; }
  .alpha-offer { max-width:800px; }
  .alpha-offer h2 + p { margin-top:24px; }
  .alpha-offer > .text-link { margin-top:8px; }
  .closing-cta .button { flex-shrink:0; }
  .section-description { margin-top:24px; }
  .feature-grid article { padding:28px; background:var(--panel); border:1px solid var(--border); border-radius:10px; }
  .feature-number { font-size:13px; color:var(--muted); letter-spacing:.05em; }
  .feature-grid h3 { margin:12px 0; }
  .section-footnote { font-size:14px; margin-top:24px; color:var(--muted); }
  .roadmap-list { list-style:none; counter-reset:roadmap; margin:0; padding:0; display:grid; grid-template-columns:1fr 1fr; column-gap:48px; }
  .roadmap-list li { counter-increment:roadmap; display:grid; grid-template-columns:28px 1fr; column-gap:16px; padding:24px 0; border-top:1px solid var(--border); }
  .roadmap-list li::before { content:counter(roadmap,decimal-leading-zero); font-size:13px; color:var(--muted); padding-top:4px; }
  .roadmap-list h3 { font-size:20px; }
  .roadmap-list p { grid-column:2; margin-top:8px; }
  .price-card { padding:28px; border:1px solid var(--border-strong); border-radius:10px; background:var(--panel); display:flex; flex-direction:column; gap:24px; align-items:start; }
  .price-card p + p { margin-top:0; }
  .price { color:var(--heading); font-size:48px; font-weight:600; line-height:1.1; letter-spacing:-.03em; }
  .price > span { display:block; font-size:14px; font-weight:400; line-height:1.6; letter-spacing:0; margin-top:16px; color:var(--muted); }
  .price > small { font-size:16px; letter-spacing:0; }
  .current-price { border-color:var(--action-border); background:var(--surface); }
  .price-note { border-top:1px solid var(--border); padding-top:20px; font-size:14px; color:var(--muted); }
  .price-card > small { color:var(--muted); font-size:13px; }
  .current-price .button { width:100%; margin-top:auto; }
  .registration-section { background:var(--surface); border-bottom:1px solid var(--border); }
  .registration-intro > p:not(.eyebrow) { margin-top:24px; }
  .signup-steps { padding-left:22px; margin-block:24px; }
  .signup-steps li { padding:8px 0 8px 8px; }
  .prototype-note { padding:24px; border:1px solid var(--border-strong); border-radius:8px; margin-bottom:16px; }
  .prototype-note p { margin-top:8px; }
  .form-card { background:var(--panel); border:1px solid var(--border-strong); border-radius:12px; padding:32px; min-width:0; }
  .form-card h3 { margin:12px 0; font-size:22px; }
  .form-help { color:var(--muted); font-size:14px; line-height:1.6; }
  .field { margin-top:24px; }
  .field > label { display:block; font-size:14px; font-weight:600; margin-bottom:8px; }
  input:not([type=checkbox]):not([type=radio]),select { width:100%; min-height:48px; padding:10px 12px; border:1px solid var(--action-border); border-radius:8px; color:var(--text); background:var(--background); }
  input::placeholder { color:var(--muted); }
  input[aria-invalid=true],select[aria-invalid=true] { border:2px solid var(--error); }
  .field-error { color:var(--error); font-size:14px; margin-top:6px; }
  .field-error:empty { display:none; }
  .acknowledgement label { display:flex; align-items:start; gap:12px; font-weight:400; min-height:44px; }
  .acknowledgement input { width:20px; height:20px; flex-shrink:0; margin:3px 0 0; accent-color:var(--accent); }
  .full-width { width:100%; }
  form > .button { margin-top:24px; }
  .form-bottom { text-align:center; margin-top:16px; }
  .error-summary,.notice { padding:16px; border:1px solid var(--error); border-radius:8px; color:var(--error); margin-top:16px; }
  .form-card section > .button { margin-block:24px 16px; }
  .text-button { background:transparent; border:0; color:var(--accent); text-decoration:underline; text-underline-offset:4px; padding:10px 0; min-height:44px; font-size:14px; }
  #flow-status:not(:empty) { margin-top:24px; padding-top:16px; border-top:1px solid var(--border); overflow-wrap:anywhere; }
  #flow-status[data-error=true] { color:var(--error); }
  #restart-button { margin-top:16px; }
  .page-intro .source-note { font-size:14px !important; color:var(--muted); }
  .migration-steps { padding:0; margin:0; list-style:none; counter-reset:steps; }
  .migration-steps li { counter-increment:steps; position:relative; padding:0 0 32px 52px; }
  .migration-steps li::before { content:counter(steps,decimal-leading-zero); position:absolute; top:0; left:0; color:var(--accent); font-size:14px; line-height:28px; }
  .migration-steps h3 { margin-bottom:12px; }
  .migration-steps li:last-child { padding-bottom:0; }
  .footer-brand .brand { font-size:20px; }
  .footer-brand p { font-size:14px; color:var(--muted); margin-top:6px; }
  .site-footer nav { flex-wrap:wrap; gap:8px 24px; }
  .footer-status { flex-basis:100%; color:var(--muted); font-size:13px; }
}

@layer responsive {
  @media (max-width:1000px) {
    .wrap { width:calc(100% - 48px); }
    .hero { gap:32px; }
    .editorial-grid,.registration-grid,.privacy-section { gap:40px; }
    .pricing-grid { grid-template-columns:1fr; }
    .price-card { gap:20px; }
    .migration-notice { grid-template-columns:1fr; gap:16px; }
    .notice-actions { flex-direction:row; flex-wrap:wrap; align-items:center; gap:8px 24px; }
  }
  @media (max-width:700px) {
    .wrap { width:calc(100% - 40px); }
    .site-header { padding-block:20px; min-height:auto; flex-wrap:wrap; gap:12px; }
    .site-header nav { width:100%; justify-content:space-between; flex-wrap:wrap; gap:12px; }
    .site-header .button { padding-inline:12px; gap:8px; font-size:13px; }
    .brand { font-size:24px; }
    .section { padding-block:48px; }
    .hero { grid-template-columns:1fr; padding-block:48px; gap:40px; }
    .hero-description { font-size:20px; }
    .processing-note { grid-template-columns:1fr; gap:28px; }
    .page-intro { padding-block:48px; }
    .page-intro > p:not(.eyebrow) { font-size:16px; }
    .editorial-grid,.registration-grid,.privacy-section,.split-heading { grid-template-columns:1fr; gap:28px; }
    .feature-grid,.roadmap-list { grid-template-columns:1fr; }
    .value-list { grid-template-columns:1fr; gap:28px; }
    .feature-grid article,.price-card { padding:24px; }
    .migration-notice { padding:24px; }
    .migration-notice h2 { font-size:22px; }
    .closing-cta { flex-direction:column; align-items:start; gap:28px; }
    .form-card { padding:24px; }
    .section-heading { margin-bottom:32px; }
    .split-heading > p:last-child { margin-top:0; }
    .site-footer { gap:24px; }
    .site-footer nav { width:100%; align-items:start; flex-direction:column; gap:4px; }
    .migration-steps li { padding-left:40px; }
  }
  @media (prefers-reduced-motion:reduce) {
    html { scroll-behavior:auto; }
    *,*::before,*::after { animation:none !important; transition:none !important; }
  }
}

/* Registration controls retain the site's existing palette and spacing. */
input:disabled, select:disabled { opacity:.5; cursor:not-allowed; }
.registration-details { min-width:0; margin:0; padding:0; border:0; }
.sr-only { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip-path:inset(50%); white-space:nowrap; border:0; }
.purpose-group { border:0; padding:0; min-width:0; }
.purpose-group legend { margin-bottom:12px; font-weight:600; }
.purpose-group label { display:flex; align-items:flex-start; gap:10px; margin-bottom:12px; }
.purpose-group input[type="radio"] { width:auto; flex:none; margin-top:5px; accent-color:var(--accent); }
#country-options { max-height:240px; overflow-y:auto; list-style:none; padding:6px; margin:8px 0; border:1px solid currentColor; border-radius:8px; }
#country-options [role="option"] { padding:10px 12px; border-radius:4px; cursor:pointer; }
#country-options [aria-selected="true"], #country-options [role="option"]:hover { background:#283d4b; color:#fff; }
.purpose-group:focus { outline:2px solid currentColor; outline-offset:4px; }

.legal-text { white-space: pre-wrap; overflow-wrap: anywhere; font: inherit; }

/* Approved homepage v2 editorial spacing; other pages retain their styles. */
@layer components {
  .homepage-v2 .homepage-section { border-top:1px solid var(--border); }
  .homepage-v2 .homepage-section > p { max-width:760px; margin-top:20px; }
  .homepage-v2 .homepage-section > h3 { max-width:760px; margin-top:36px; }
  .homepage-v2 .homepage-section > figure { margin-block:32px; }
  .homepage-v2 .hero-actions { display:flex; flex-wrap:wrap; gap:12px; }
}

/* Approved download CTA update; bounded to the homepage. */
@layer responsive {
  .homepage-v2 .hero { padding-block:40px; }
  .homepage-v2 .hero-actions .button { min-height:60px; padding:14px 24px; font-size:18px; background:#4ade80; border-color:#4ade80; color:#0a0f18; }
  .homepage-v2 .hero-actions .button:hover { background:#86efac; border-color:#86efac; color:#0a0f18; }
  @media (max-width:700px) {
    .homepage-v2 .hero { padding-block:24px; }
    .homepage-v2 .hero-copy h1 { font-size:30px; }
    .homepage-v2 .hero-copy > p:not(.eyebrow):not(.hero-description) { margin-top:16px; }
    .homepage-v2 .hero-actions > strong { width:100%; }
    .homepage-v2 .hero-actions .button { width:100%; }
  }
}
