:root {
  --ink: #eef6fb;
  --muted: #a7b7c2;
  --line: #263946;
  --bg: #0d151c;
  --panel: #14212b;
  --dark: #111b23;
  --dark-2: #182530;
  --blue: #246bfe;
  --green: #0f7a45;
  --teal: #047481;
  --amber: #a96400;
  --red: #ff6b5f;
  --steel: #233340;
  --hero-bg: #101922;
  --header-bg: rgba(17, 27, 35, 0.9);
  --header-border: rgba(255, 255, 255, 0.1);
  --nav-color: #c4d0d8;
  --brand-color: #fff;
  --hero-color: #fff;
  --hero-muted: #c3d0d8;
  --button-bg: #fff;
  --button-color: #121b22;
  --button-border: rgba(207, 219, 227, 0.9);
  --secondary-bg: rgba(255, 255, 255, 0.05);
  --secondary-border: rgba(255, 255, 255, 0.18);
  --secondary-color: inherit;
  --chip-bg: rgba(255, 255, 255, 0.08);
  --chip-border: rgba(255, 255, 255, 0.14);
  --chip-color: #dce8ef;
  --shadow: 0 10px 26px rgba(0, 0, 0, 0.22);
  --image-shadow: 0 16px 40px rgba(0, 0, 0, 0.28);
  --field-bg: #0f1a22;
  color-scheme: dark;
}

:root[data-theme="light"],
body[data-theme="light"] {
  --ink: #13212b;
  --muted: #5a6d78;
  --line: #cdd8e0;
  --bg: #edf3f7;
  --panel: #ffffff;
  --dark: #14212b;
  --dark-2: #20313d;
  --blue: #135fe8;
  --green: #0d7542;
  --teal: #047481;
  --amber: #a96400;
  --red: #b42318;
  --steel: #314452;
  --hero-bg: #eef4f8;
  --header-bg: rgba(255, 255, 255, 0.9);
  --header-border: rgba(18, 32, 43, 0.12);
  --nav-color: #40525e;
  --brand-color: #13212b;
  --hero-color: #13212b;
  --hero-muted: #536773;
  --button-bg: #14212b;
  --button-color: #fff;
  --button-border: rgba(20, 33, 43, 0.92);
  --secondary-bg: rgba(19, 95, 232, 0.08);
  --secondary-border: rgba(19, 95, 232, 0.2);
  --secondary-color: #123247;
  --chip-bg: #ffffff;
  --chip-border: rgba(20, 33, 43, 0.12);
  --chip-color: #273b49;
  --shadow: 0 10px 26px rgba(20, 32, 41, 0.08);
  --image-shadow: 0 16px 36px rgba(20, 32, 41, 0.14);
  --field-bg: #ffffff;
  color-scheme: light;
}

:root[data-theme="dark"],
body[data-theme="dark"] {
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

main {
  background:
    linear-gradient(180deg, var(--hero-bg) 0, var(--hero-bg) 1060px, var(--bg) 1060px, var(--bg) 100%);
}

a {
  color: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 16px clamp(16px, 5vw, 56px);
  border-bottom: 1px solid var(--header-border);
  background: var(--header-bg);
  backdrop-filter: blur(14px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--brand-color);
  font-weight: 950;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: #fff;
  color: var(--dark);
  font-size: 0.8rem;
}

nav {
  display: flex;
  gap: 18px;
  color: var(--nav-color);
  font-size: 0.92rem;
  font-weight: 800;
}

nav a {
  text-decoration: none;
}

.button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--button-border);
  border-radius: 8px;
  padding: 10px 16px;
  background: var(--button-bg);
  color: var(--button-color);
  font-weight: 900;
  text-decoration: none;
}

.button.primary {
  border-color: var(--blue);
  background: var(--blue);
  color: #fff;
  box-shadow: 0 12px 26px rgba(36, 107, 254, 0.28);
}

.button.secondary {
  border-color: var(--secondary-border);
  background: var(--secondary-bg);
  color: var(--secondary-color);
}

.header-actions,
.auth-head {
  display: flex;
  align-items: center;
  gap: 10px;
}

.auth-head {
  justify-content: space-between;
}

.theme-toggle {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--secondary-border);
  border-radius: 8px;
  padding: 9px 12px;
  background: var(--secondary-bg);
  color: var(--secondary-color);
  cursor: pointer;
  font: inherit;
  font-size: 0.86rem;
  font-weight: 950;
}

.theme-toggle.compact {
  min-height: 38px;
  padding: 8px 10px;
}

.theme-toggle-icon {
  position: relative;
  width: 18px;
  height: 18px;
  border: 2px solid currentColor;
  border-radius: 999px;
}

.theme-toggle-icon::after {
  content: "";
  position: absolute;
  inset: -2px -2px -2px 8px;
  border-radius: 999px;
  background: var(--header-bg);
}

body[data-theme="light"] .theme-toggle-icon::after {
  inset: 3px;
  background: currentColor;
}

.button.full {
  width: 100%;
}

.hero {
  display: grid;
  grid-template-columns: minmax(320px, 0.82fr) minmax(0, 1.18fr);
  gap: clamp(24px, 5vw, 64px);
  align-items: center;
  width: min(1480px, calc(100% - 32px));
  min-height: calc(100vh - 72px);
  margin: 0 auto;
  padding: clamp(42px, 7vw, 88px) 0 40px;
  color: var(--hero-color);
}

.eyebrow {
  margin: 0 0 12px;
  color: #56d0dc;
  font-size: 0.78rem;
  font-weight: 950;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

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

h1 {
  max-width: 11ch;
  margin-bottom: 18px;
  font-size: clamp(3.4rem, 7.4vw, 6.7rem);
  line-height: 0.94;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 16px;
  font-size: clamp(2rem, 4vw, 3.8rem);
  line-height: 1;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 10px;
  font-size: 1.18rem;
}

.hero-text {
  max-width: 67ch;
  color: var(--hero-muted);
  font-size: 1.15rem;
  line-height: 1.6;
}

.hero-actions,
.trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-actions {
  margin: 26px 0;
}

.trust-row span {
  border: 1px solid var(--chip-border);
  border-radius: 999px;
  padding: 8px 11px;
  background: var(--chip-bg);
  color: var(--chip-color);
  font-size: 0.82rem;
  font-weight: 900;
}

.hero-visual img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 16px;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.42);
}

.hero-callouts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.hero-callouts span {
  border: 1px solid var(--chip-border);
  border-radius: 8px;
  padding: 12px;
  background: var(--chip-bg);
  color: var(--chip-color);
  line-height: 1.35;
}

.hero-callouts strong {
  display: block;
  color: var(--hero-color);
}

.metrics-band,
.section,
.workflow,
.brand-panel,
.image-story,
.pricing {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
}

.metrics-band {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  padding: 20px 0 72px;
}

.metrics-band div,
.feature-grid article,
.module-grid article,
.workflow,
.dark-band,
.readiness,
.pricing,
.login-panel,
.login-aside {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.metrics-band div {
  padding: 18px;
  border-color: var(--chip-border);
  background: var(--dark-2);
  color: #fff;
}

.metrics-band strong {
  display: block;
  margin-bottom: 6px;
  color: var(--blue);
  font-size: 1.3rem;
}

.metrics-band span,
.feature-grid p,
.module-grid p,
.workflow p,
.workflow span,
.readiness span,
.pricing p,
.login-panel p,
.login-aside li {
  color: var(--muted);
  line-height: 1.6;
}

.dark-band {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  gap: 28px;
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto 34px;
  padding: clamp(24px, 4vw, 44px);
  border-color: #1e303d;
  background: var(--dark);
  color: #fff;
}

.dark-band p {
  color: #c6d2d9;
  line-height: 1.65;
}

.proof-grid {
  display: grid;
  gap: 12px;
}

.proof-grid div {
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  padding: 16px;
  background: rgba(255, 255, 255, 0.06);
}

.proof-grid strong {
  display: block;
  margin-bottom: 6px;
  color: #fff;
}

.proof-grid span {
  color: #c6d2d9;
  line-height: 1.55;
}

.brand-panel {
  margin-bottom: 34px;
}

.brand-panel img,
.image-story img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border: 1px solid rgba(30, 48, 61, 0.9);
  border-radius: 8px;
  box-shadow: var(--image-shadow);
}

.image-story {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(300px, 0.9fr);
  gap: clamp(20px, 4vw, 38px);
  align-items: center;
  padding: 34px 0;
}

.image-story.reverse {
  grid-template-columns: minmax(300px, 0.9fr) minmax(0, 1.1fr);
}

.image-story.reverse img {
  order: 2;
}

.image-story div {
  padding: clamp(18px, 3vw, 34px);
}

.image-story p {
  color: var(--muted);
  line-height: 1.65;
}

.section {
  padding: 68px 0;
}

.section-head {
  max-width: 760px;
  margin-bottom: 26px;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.feature-grid article {
  padding: 22px;
}

.module-section {
  padding-top: 34px;
}

.module-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.module-grid article {
  padding: 22px;
}

.module-grid span {
  display: inline-flex;
  margin-bottom: 18px;
  border-radius: 999px;
  padding: 6px 9px;
  background: rgba(36, 107, 254, 0.1);
  color: var(--blue);
  font-size: 0.76rem;
  font-weight: 950;
}

.workflow {
  display: grid;
  grid-template-columns: minmax(0, 0.86fr) minmax(0, 1.14fr);
  gap: 28px;
  align-items: start;
  padding: clamp(24px, 4vw, 42px);
}

.workflow ol {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.workflow li {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  background: color-mix(in srgb, var(--panel) 84%, var(--bg));
}

.logo-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.logo-grid span {
  display: grid;
  gap: 7px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  background: var(--panel);
  color: var(--ink);
  font-weight: 900;
}

.logo-grid small {
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 750;
  line-height: 1.45;
}

.readiness {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: 24px;
  align-items: start;
  width: min(1240px, calc(100% - 32px));
  margin: 22px auto 68px;
  padding: clamp(24px, 4vw, 40px);
  background: var(--panel);
}

.readiness ul {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.readiness li {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  background: color-mix(in srgb, var(--panel) 84%, var(--bg));
}

.pricing {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: center;
  margin-bottom: 72px;
  padding: 32px;
}

.pricing div {
  max-width: 720px;
}

footer {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 24px clamp(16px, 5vw, 56px);
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-weight: 800;
}

.login-body {
  min-height: 100vh;
  display: grid;
  place-items: center;
}

.login-shell {
  display: grid;
  grid-template-columns: minmax(320px, 450px) minmax(300px, 420px);
  gap: 16px;
  width: min(920px, calc(100% - 32px));
}

.login-shell.single {
  grid-template-columns: minmax(320px, 520px);
  justify-content: center;
}

.login-panel,
.login-aside {
  padding: 28px;
}

.login-panel .brand,
.portal-header .brand {
  color: var(--ink);
}

.login-panel .brand-mark,
.portal-header .brand-mark {
  border-color: var(--line);
  background: var(--dark);
  color: #fff;
}

.login-panel h1 {
  max-width: none;
  margin-top: 34px;
  font-size: 2.4rem;
}

.login-form {
  display: grid;
  gap: 14px;
  margin-top: 24px;
}

.login-form.compact {
  margin-top: 16px;
}

label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 900;
}

input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: var(--field-bg);
  color: var(--ink);
  font: inherit;
}

.portal-body {
  min-height: 100vh;
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--panel) 78%, transparent), color-mix(in srgb, var(--bg) 94%, transparent)),
    var(--bg);
}

.portal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px clamp(16px, 5vw, 56px);
}

.portal-shell {
  display: grid;
  gap: 22px;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: clamp(20px, 4vw, 48px) 0 60px;
}

.portal-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
  gap: clamp(22px, 4vw, 44px);
  align-items: center;
}

.portal-hero h1 {
  max-width: 13ch;
  font-size: clamp(2.5rem, 6vw, 5.6rem);
}

.portal-hero p {
  max-width: 62ch;
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.65;
}

.portal-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: clamp(18px, 3vw, 28px);
  background: var(--panel);
  box-shadow: var(--shadow);
}

.portal-card-head {
  display: flex;
  gap: 14px;
  align-items: start;
  margin-bottom: 22px;
}

.portal-card-head h2,
.portal-card h2 {
  margin-bottom: 6px;
  font-size: 1.6rem;
}

.portal-card-head p,
.portal-card p {
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.55;
}

.portal-access {
  display: grid;
  gap: 14px;
}

.portal-message {
  min-height: 1.35em;
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 900;
}

.portal-message[data-tone="success"] {
  color: var(--green);
}

.portal-message[data-tone="error"] {
  color: #b42318;
}

.portal-message[data-tone="info"] {
  color: var(--blue);
}

.portal-results {
  display: grid;
  gap: 16px;
}

.portal-summary {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: start;
}

.status-pill {
  display: inline-flex;
  margin-bottom: 12px;
  border: 1px solid #badbcc;
  border-radius: 999px;
  padding: 7px 10px;
  background: #eef9f1;
  color: var(--green);
  font-size: 0.78rem;
  font-weight: 950;
}

.portal-meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(110px, 1fr));
  gap: 10px;
  min-width: min(100%, 520px);
  margin: 0;
}

.portal-meta div {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: color-mix(in srgb, var(--panel) 84%, var(--bg));
}

.portal-meta dt {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 950;
  text-transform: uppercase;
}

.portal-meta dd {
  margin: 5px 0 0;
  font-weight: 950;
}

.portal-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(280px, 0.8fr);
  gap: 16px;
}

.portal-list {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.portal-list li {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: color-mix(in srgb, var(--panel) 84%, var(--bg));
}

.portal-list strong {
  white-space: nowrap;
}

.portal-list small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-weight: 700;
  line-height: 1.35;
}

.portal-actions {
  display: grid;
  gap: 10px;
  align-content: start;
}

.portal-feature-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.portal-feature-list span {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 11px;
  background: color-mix(in srgb, var(--panel) 84%, var(--bg));
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 900;
}

.portal-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 22px 0 0;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 950;
  text-transform: uppercase;
}

.portal-divider::before,
.portal-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line);
}

.fine-print {
  margin: 16px 0 0;
  font-size: 0.82rem;
}

.form-message {
  min-height: 1.2em;
  margin: 0;
  color: var(--red);
  font-size: 0.86rem;
  font-weight: 900;
}

.login-aside {
  align-self: stretch;
  background: var(--dark);
  color: #fff;
}

.login-aside h2 {
  font-size: 2rem;
}

.login-aside li {
  color: #d7e3ea;
}

@media (max-width: 980px) {
  .hero,
  .workflow,
  .dark-band,
  .readiness,
  .image-story,
  .image-story.reverse,
  .portal-hero,
  .login-shell {
    grid-template-columns: 1fr;
  }

  .image-story.reverse img {
    order: 0;
  }

  .feature-grid,
  .module-grid,
  .logo-grid,
  .metrics-band,
  .portal-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  nav {
    display: none;
  }
}

@media (max-width: 640px) {
  .site-header,
  .portal-header,
  .portal-summary,
  .pricing,
  footer {
    align-items: stretch;
    flex-direction: column;
  }

  .feature-grid,
  .module-grid,
  .logo-grid,
  .metrics-band,
  .hero-callouts,
  .readiness li,
  .portal-grid,
  .portal-meta,
  .workflow li {
    grid-template-columns: 1fr;
  }

  h1 {
    font-size: 3rem;
  }
}
