/* =============================================================
   Amicus — Design System
   Reference: DESIGN.md
   ============================================================= */

:root {
  /* Brand */
  --color-electric-blue: #1e90ff;
  --color-vivid-indigo: #5b3df5;
  --color-deep-navy: #060b2d;
  --color-soft-violet: #8b5cff;
  --color-ice-blue: #b9e3ff;
  --color-white: #ffffff;

  /* Text */
  --text-primary: var(--color-deep-navy);
  --text-on-dark: var(--color-white);
  --text-muted: rgba(6, 11, 45, 0.6);
  --text-muted-on-dark: rgba(255, 255, 255, 0.65);

  /* Borders */
  --border-light: rgba(6, 11, 45, 0.12);
  --border-soft: rgba(6, 11, 45, 0.06);
  --border-dark: rgba(255, 255, 255, 0.12);

  /* Surfaces */
  --surface-glass-dark: rgba(255, 255, 255, 0.08);
  --surface-glass-light: rgba(6, 11, 45, 0.04);

  /* Shadows */
  --shadow-elevated: 0 4px 10px rgba(6, 11, 45, 0.1);
  --shadow-glow: 0 8px 24px rgba(91, 61, 245, 0.2);

  /* Gradients */
  --gradient-brand: linear-gradient(
    135deg,
    #1e90ff 0%,
    #5b3df5 35%,
    #8b5cff 100%
  );
  --gradient-brand-text: linear-gradient(
    135deg,
    #1e90ff 0%,
    #5b3df5 40%,
    #8b5cff 100%
  );

  /* Radius */
  --radius-sharp: 4px;
  --radius-comfortable: 8px;

  /* Type */
  --font-display: "Space Grotesk", "The Future", Arial, sans-serif;
  --font-mono: "JetBrains Mono", "PP Neue Montreal Mono", Georgia, monospace;

  /* Layout */
  --container-max: 1200px;
  --section-padding-y: 100px;
}

/* ============== Reset / Base ============== */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-display);
  font-size: 16px;
  line-height: 1.3;
  letter-spacing: -0.16px;
  color: var(--text-primary);
  background: var(--color-white);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: var(--color-vivid-indigo);
  text-decoration: none;
  transition: color 160ms ease;
}

a:hover {
  color: var(--color-soft-violet);
}

.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 24px;
}

/* ============== Typography ============== */
.display {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(40px, 7vw, 72px);
  line-height: 1.05;
  letter-spacing: -0.03em;
  margin: 0 0 20px;
  color: var(--text-primary);
}

.display__accent {
  background: var(--gradient-brand-text);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

.section-title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(28px, 3.6vw, 40px);
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0;
  color: var(--text-primary);
  max-width: 22ch;
}

.section-title--dark {
  color: var(--text-on-dark);
}

.lead {
  font-size: 18px;
  line-height: 1.4;
  letter-spacing: -0.18px;
  color: var(--text-muted);
  max-width: 56ch;
  margin: 0 0 32px;
}

.mono-label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-vivid-indigo);
  display: inline-block;
  margin-bottom: 16px;
}

.mono-label--dark {
  color: var(--color-soft-violet);
}

.mono-small {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.mono-small--dark {
  color: var(--text-muted-on-dark);
}

/* ============== Buttons ============== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 500;
  letter-spacing: -0.16px;
  padding: 12px 20px;
  border-radius: var(--radius-sharp);
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 160ms ease, color 160ms ease,
    border-color 160ms ease, box-shadow 200ms ease, transform 160ms ease;
  white-space: nowrap;
}

.btn--large {
  padding: 14px 24px;
  font-size: 16px;
}

.btn--primary {
  background: var(--color-vivid-indigo);
  color: var(--color-white);
}

.btn--primary:hover {
  background: var(--color-soft-violet);
  color: var(--color-white);
  box-shadow: var(--shadow-glow);
}

.btn--outlined {
  background: transparent;
  color: var(--text-primary);
  border-color: var(--border-light);
}

.btn--outlined:hover {
  color: var(--color-vivid-indigo);
  border-color: var(--color-vivid-indigo);
}

.btn[disabled] {
  opacity: 0.7;
  cursor: not-allowed;
}

.btn__spinner {
  display: none;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid currentColor;
  border-right-color: transparent;
  animation: btn-spin 0.7s linear infinite;
}

.btn.is-loading .btn__label {
  display: none;
}

.btn.is-loading .btn__spinner {
  display: inline-block;
}

@keyframes btn-spin {
  to { transform: rotate(360deg); }
}

.link-muted {
  font-size: 16px;
  color: var(--text-primary);
  letter-spacing: -0.16px;
}

.link-muted:hover {
  color: var(--color-vivid-indigo);
}

.link-arrow {
  display: inline-block;
  margin-top: 16px;
  font-weight: 500;
  color: var(--color-vivid-indigo);
}

/* ============== Nav ============== */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: saturate(140%) blur(12px);
  -webkit-backdrop-filter: saturate(140%) blur(12px);
  border-bottom: 1px solid var(--border-soft);
}

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 80px;
  gap: 24px;
}

.nav__logo img {
  height: 44px;
  width: auto;
  display: block;
}

.nav__links {
  display: flex;
  gap: 28px;
}

.nav__links a {
  color: var(--text-primary);
  font-size: 16px;
  letter-spacing: -0.16px;
}

.nav__links a:hover {
  color: var(--color-vivid-indigo);
}

.nav__actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.nav__hamburger {
  display: none;
  width: 40px;
  height: 40px;
  background: transparent;
  border: 0;
  padding: 0;
  cursor: pointer;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  border-radius: 6px;
}

.nav__hamburger-bar {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--color-deep-navy);
  border-radius: 2px;
  transition: transform 0.22s ease, opacity 0.22s ease;
}

.nav__hamburger.is-open .nav__hamburger-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav__hamburger.is-open .nav__hamburger-bar:nth-child(2) {
  opacity: 0;
}
.nav__hamburger.is-open .nav__hamburger-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

@media (max-width: 880px) {
  .nav__links {
    display: none;
  }
  .nav__actions {
    display: none;
  }
  .nav__hamburger {
    display: flex;
  }
}

/* Nav drawer (mobile) */
.nav-drawer {
  position: fixed;
  inset: 0;
  z-index: 100;
}

.nav-drawer[hidden] {
  display: none;
}

.nav-drawer__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(6, 11, 45, 0.18);
  opacity: 0;
  transition: opacity 0.24s ease;
  cursor: pointer;
}

.nav-drawer.is-open .nav-drawer__backdrop {
  opacity: 1;
}

.nav-drawer__panel {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(360px, 84vw);
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.65) 0%,
    rgba(255, 255, 255, 0.45) 60%,
    rgba(185, 227, 255, 0.35) 100%
  );
  backdrop-filter: blur(24px) saturate(160%);
  -webkit-backdrop-filter: blur(24px) saturate(160%);
  border-left: 1px solid rgba(255, 255, 255, 0.4);
  padding: 28px 28px 32px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  transform: translateX(100%);
  transition: transform 0.26s cubic-bezier(0.2, 0.8, 0.2, 1);
  box-shadow: -10px 0 40px rgba(6, 11, 45, 0.12);
  overflow-y: auto;
}

.nav-drawer.is-open .nav-drawer__panel {
  transform: translateX(0);
}

.nav-drawer__close {
  align-self: flex-end;
  width: 36px;
  height: 36px;
  background: transparent;
  border: 0;
  font-size: 28px;
  line-height: 1;
  color: var(--text-muted);
  cursor: pointer;
  border-radius: 6px;
  transition: background 0.15s ease, color 0.15s ease;
}

.nav-drawer__close:hover {
  background: rgba(6, 11, 45, 0.06);
  color: var(--color-deep-navy);
}

.nav-drawer__links {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.nav-drawer__links a {
  display: block;
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: var(--color-deep-navy);
  padding: 12px 0;
  border-bottom: 1px solid rgba(6, 11, 45, 0.08);
}

.nav-drawer__links a.active,
.nav-drawer__links a:hover {
  color: var(--color-vivid-indigo);
}

.nav-drawer__actions {
  margin-top: 8px;
  display: flex;
  flex-direction: column;
}

.nav-drawer__actions .btn {
  width: 100%;
  justify-content: center;
}

/* ============== Hero ============== */
.hero {
  position: relative;
  padding: 120px 0 100px;
  overflow: hidden;
  isolation: isolate;
}

.hero__bloom {
  position: absolute;
  inset: -10% -10% auto -10%;
  height: 700px;
  background:
    radial-gradient(
      55% 45% at 70% 35%,
      rgba(139, 92, 255, 0.45) 0%,
      rgba(139, 92, 255, 0) 70%
    ),
    radial-gradient(
      50% 45% at 30% 40%,
      rgba(91, 61, 245, 0.32) 0%,
      rgba(91, 61, 245, 0) 70%
    ),
    radial-gradient(
      45% 40% at 50% 80%,
      rgba(185, 227, 255, 0.45) 0%,
      rgba(185, 227, 255, 0) 70%
    );
  filter: blur(10px);
  z-index: -1;
}

.hero__bloom-video {
  position: absolute;
  inset: 0 -10% 0 -10%;
  width: calc(100% + 20%);
  height: 100%;
  object-fit: cover;
  object-position: center;
  z-index: -2;
  pointer-events: none;
  opacity: 0.7;
  filter: blur(2px) saturate(0.85);
}

.hero:has(.hero__bloom-video)::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0) 80%,
    rgba(255, 255, 255, 0.6) 95%,
    rgba(255, 255, 255, 1) 100%
  );
  pointer-events: none;
  z-index: -1;
}

/* ============== Hero with full-color video media ============== */
.hero--media-full {
  color: var(--text-on-dark);
}

.hero--media-full .hero__bloom-video {
  opacity: 1;
  filter: none;
}

.hero--media-full::after {
  background: linear-gradient(
    180deg,
    rgba(6, 11, 45, 0.35) 0%,
    rgba(6, 11, 45, 0.25) 40%,
    rgba(6, 11, 45, 0.55) 100%
  ) !important;
}

.display__accent--on-dark {
  background: linear-gradient(
    135deg,
    var(--color-ice-blue) 0%,
    var(--color-soft-violet) 100%
  );
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

.hero__inner {
  text-align: center;
}

.hero__cta {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 80px;
}

.hero .lead {
  margin-left: auto;
  margin-right: auto;
}

.hero__trust {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.hero__logos {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 40px;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 18px;
  color: var(--text-muted);
  letter-spacing: -0.18px;
}

/* ============== Stats ============== */
.stats {
  padding: 64px 0;
  background: var(--color-ice-blue);
  background:
    linear-gradient(
      180deg,
      rgba(185, 227, 255, 0.35) 0%,
      rgba(185, 227, 255, 0.15) 100%
    );
  border-top: 1px solid var(--border-soft);
  border-bottom: 1px solid var(--border-soft);
}

.stats__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.stat {
  padding: 8px 0;
}

.stat__num {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(40px, 5vw, 56px);
  line-height: 1.0;
  letter-spacing: -0.03em;
  color: var(--color-vivid-indigo);
  margin-bottom: 8px;
}

.stat__caption {
  font-size: 14px;
  line-height: 1.4;
  color: var(--text-muted);
  margin: 0;
  max-width: 28ch;
}

@media (max-width: 880px) {
  .stats__grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .stats__grid {
    grid-template-columns: 1fr;
  }
}

/* ============== Features ============== */
.features {
  padding: var(--section-padding-y) 0;
}

.section-head {
  margin-bottom: 56px;
  max-width: 720px;
}

.section-head--dark .mono-label {
  color: var(--color-soft-violet);
}

.features__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.features__grid .feature-card--brand {
  grid-column: span 3;
}

.feature-card {
  background: var(--color-white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-comfortable);
  padding: 28px;
  transition: box-shadow 200ms ease, transform 200ms ease,
    border-color 200ms ease;
}

.feature-card:hover {
  box-shadow: var(--shadow-elevated);
  border-color: rgba(91, 61, 245, 0.25);
  transform: translateY(-2px);
}

.feature-card__icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sharp);
  background: rgba(185, 227, 255, 0.4);
  margin-bottom: 20px;
}

.dot {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  display: block;
}

.dot--blue {
  background: var(--color-electric-blue);
}

.dot--indigo {
  background: var(--color-vivid-indigo);
}

.dot--violet {
  background: var(--color-soft-violet);
}

.feature-card__title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 22px;
  line-height: 1.2;
  letter-spacing: -0.022em;
  margin: 0 0 8px;
  color: var(--text-primary);
}

.feature-card__body {
  font-size: 16px;
  line-height: 1.45;
  letter-spacing: -0.16px;
  color: var(--text-muted);
  margin: 0;
}

.feature-card--brand {
  background: var(--gradient-brand);
  border: none;
  color: var(--color-white);
  padding: 40px;
  position: relative;
  overflow: hidden;
}

.feature-card--brand .feature-card__title {
  color: var(--color-white);
  font-size: 32px;
  line-height: 1.1;
  letter-spacing: -0.025em;
  margin-top: 12px;
  max-width: 18ch;
}

.feature-card--brand .feature-card__body {
  color: rgba(255, 255, 255, 0.85);
  max-width: 56ch;
}

.feature-card--brand .link-arrow {
  color: var(--color-white);
  text-decoration: underline;
  text-underline-offset: 4px;
}

.feature-card--brand .link-arrow:hover {
  color: var(--color-ice-blue);
}

.feature-card--brand:hover {
  transform: none;
  box-shadow: var(--shadow-glow);
}

@media (max-width: 880px) {
  .features__grid {
    grid-template-columns: 1fr;
  }
  .features__grid .feature-card--brand {
    grid-column: span 1;
  }
}

/* ============== Products ============== */
.products {
  padding: var(--section-padding-y) 0;
}

.products__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.product-card {
  background: var(--color-white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-comfortable);
  padding: 28px;
  display: flex;
  flex-direction: column;
  transition: box-shadow 200ms ease, transform 200ms ease,
    border-color 200ms ease;
}

.product-card:hover {
  box-shadow: var(--shadow-elevated);
  border-color: rgba(91, 61, 245, 0.25);
  transform: translateY(-2px);
}

.product-card--link {
  text-decoration: none;
  color: inherit;
}

.product-card--link:hover,
.product-card--link:visited {
  color: inherit;
}

.product-card__tag {
  margin-bottom: 16px;
  color: var(--color-vivid-indigo);
}

.product-card__title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 22px;
  line-height: 1.2;
  letter-spacing: -0.022em;
  margin: 0 0 8px;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.product-card__brand {
  height: 32px;
  width: auto;
  display: inline-block;
  margin-bottom: 6px;
}

.product-card__tagline {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 16px;
  line-height: 1.35;
  letter-spacing: -0.16px;
  color: var(--color-vivid-indigo);
  margin: 0 0 12px;
}

.product-card__body {
  font-size: 15px;
  line-height: 1.5;
  letter-spacing: -0.15px;
  color: var(--text-muted);
  margin: 0;
}

@media (max-width: 880px) {
  .products__grid {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 881px) and (max-width: 1100px) {
  .products__grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ============== Focus / Dark Section ============== */
.focus {
  position: relative;
  background: var(--color-deep-navy);
  color: var(--text-on-dark);
  padding: var(--section-padding-y) 0;
  overflow: hidden;
  isolation: isolate;
}

.focus__aurora {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(
      40% 50% at 20% 30%,
      rgba(91, 61, 245, 0.35) 0%,
      rgba(91, 61, 245, 0) 70%
    ),
    radial-gradient(
      40% 40% at 85% 70%,
      rgba(139, 92, 255, 0.25) 0%,
      rgba(139, 92, 255, 0) 70%
    );
  z-index: -1;
}

.focus__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.focus__grid--four {
  grid-template-columns: repeat(4, 1fr);
}

.focus__note {
  margin-top: 32px;
  text-align: center;
  display: block;
}

/* ============== Tech Teaser (homepage) ============== */
.tech-teaser {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
  margin-top: 48px;
  margin-bottom: 24px;
}

.tech-teaser__copy {
  display: flex;
  flex-direction: column;
  gap: 20px;
  align-items: flex-start;
  text-align: left;
}

.tech-teaser__copy .lead {
  margin: 0;
  text-align: left;
  margin-left: 0;
  margin-right: 0;
}

.tech-teaser__visual {
  display: flex;
  justify-content: center;
  align-items: center;
  aspect-ratio: 16 / 10;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.tech-teaser__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.tech-teaser__placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  height: 100%;
  min-height: 320px;
  padding: 32px;
  background:
    radial-gradient(
      circle at 30% 30%,
      rgba(91, 61, 245, 0.18) 0%,
      transparent 60%
    ),
    radial-gradient(
      circle at 70% 70%,
      rgba(30, 144, 255, 0.18) 0%,
      transparent 60%
    );
  border: 1px dashed rgba(255, 255, 255, 0.2);
  border-radius: 14px;
  text-align: center;
}

.tech-teaser__placeholder-hint {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.35);
}

.btn--on-dark {
  color: var(--color-white);
  border-color: rgba(255, 255, 255, 0.4);
}

.btn--on-dark:hover {
  color: var(--color-white);
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.7);
}

@media (max-width: 880px) {
  .tech-teaser {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .tech-teaser__visual {
    min-height: 240px;
  }
}

.lead--dark {
  color: var(--text-muted-on-dark);
  margin-top: 20px;
}

.paper-card {
  display: block;
  padding: 28px;
  border: 1px solid var(--border-dark);
  border-radius: var(--radius-comfortable);
  background: var(--surface-glass-dark);
  color: var(--text-on-dark);
  transition: border-color 200ms ease, transform 200ms ease,
    background 200ms ease;
}

.paper-card:hover {
  border-color: rgba(139, 92, 255, 0.5);
  background: rgba(255, 255, 255, 0.05);
  transform: translateY(-2px);
  color: var(--text-on-dark);
}

.paper-card .mono-small {
  display: block;
  margin-bottom: 16px;
}

.paper-card h3 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 22px;
  line-height: 1.2;
  letter-spacing: -0.022em;
  margin: 0 0 12px;
  color: var(--text-on-dark);
}

.paper-card p {
  font-size: 15px;
  line-height: 1.45;
  color: var(--text-muted-on-dark);
  margin: 0;
}

@media (max-width: 880px) {
  .focus__grid {
    grid-template-columns: 1fr;
  }
  .focus__grid--four {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 881px) and (max-width: 1100px) {
  .focus__grid--four {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ============== CTA Band ============== */
.cta-band {
  padding: 100px 0;
  background:
    radial-gradient(
      60% 80% at 50% 50%,
      rgba(185, 227, 255, 0.4) 0%,
      rgba(185, 227, 255, 0) 70%
    ),
    var(--color-white);
}

.cta-band__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  flex-wrap: wrap;
}

.cta-band__actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.cta-band .section-title {
  margin-top: 12px;
}

/* ============== Footer ============== */
.footer {
  background: var(--color-deep-navy);
  color: var(--text-on-dark);
  padding: 80px 0 32px;
}

.footer__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
  padding-bottom: 56px;
  border-bottom: 1px solid var(--border-dark);
}

.footer__col {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer__col .mono-small {
  margin-bottom: 8px;
  color: var(--color-soft-violet);
}

.footer__col a {
  color: rgba(255, 255, 255, 0.75);
  font-size: 15px;
  letter-spacing: -0.15px;
}

.footer__col a:hover {
  color: var(--color-white);
}

.footer__brand {
  padding: 56px 0 32px;
  display: flex;
  justify-content: center;
}

.footer__logo {
  width: 100%;
  max-width: 720px;
  height: auto;
  opacity: 0.95;
}

.footer__base {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  padding-top: 24px;
  border-top: 1px solid var(--border-dark);
}

@media (max-width: 880px) {
  .footer__grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .footer__grid {
    grid-template-columns: 1fr;
  }
}

/* ============== Product Page — Cinematic Hero (full-bleed video) ============== */
.hero--cinematic {
  position: relative;
  min-height: min(820px, 92vh);
  padding: 0;
  overflow: hidden;
  isolation: isolate;
  display: flex;
  align-items: center;
  color: var(--text-on-dark);
}

.hero__bg-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(
      60% 60% at 50% 50%,
      rgba(6, 11, 45, 0.55) 0%,
      rgba(6, 11, 45, 0.75) 70%,
      rgba(6, 11, 45, 0.85) 100%
    );
  z-index: -1;
}

.hero__cinematic-inner {
  position: relative;
  width: 100%;
  padding: 140px 24px;
  max-width: var(--container-max);
  margin: 0 auto;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero__cinematic-inner > * {
  max-width: 720px;
}

.hero__cinematic-inner .lead {
  margin-left: auto;
  margin-right: auto;
}

.hero--cinematic .product-header {
  justify-content: center;
}

.display--on-dark {
  color: var(--text-on-dark);
}

.hero__cta--left {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 0;
}

.product-header--dark .product-header__name {
  color: var(--text-on-dark);
}

.btn--ghost {
  background: rgba(255, 255, 255, 0.08);
  color: var(--color-white);
  border-color: rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.btn--ghost:hover {
  background: rgba(255, 255, 255, 0.16);
  border-color: rgba(255, 255, 255, 0.6);
  color: var(--color-white);
}

@media (max-width: 880px) {
  .hero--cinematic {
    min-height: 720px;
  }
  .hero__cinematic-inner {
    padding: 100px 24px;
  }
  .hero__overlay {
    background:
      radial-gradient(
        70% 70% at 50% 50%,
        rgba(6, 11, 45, 0.65) 0%,
        rgba(6, 11, 45, 0.85) 100%
      );
  }
}

/* ============== Product Header (logo + name kicker) ============== */
.product-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.product-header__brand {
  height: 36px;
  width: auto;
  display: block;
}

.product-header__name {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 20px;
  letter-spacing: -0.02em;
  color: var(--text-primary);
}

/* ============== Image Placeholders ============== */
.image-placeholder {
  margin: 0;
  border: 1.5px dashed rgba(91, 61, 245, 0.35);
  background:
    repeating-linear-gradient(
      135deg,
      rgba(91, 61, 245, 0.03) 0 12px,
      rgba(91, 61, 245, 0.06) 12px 24px
    ),
    rgba(255, 255, 255, 0.5);
  border-radius: var(--radius-comfortable);
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: flex-start;
}

.image-placeholder .mono-small {
  color: var(--color-vivid-indigo);
}

.image-placeholder p {
  font-size: 14px;
  line-height: 1.45;
  color: var(--text-muted);
  margin: 0;
  max-width: 52ch;
}

.image-placeholder--hero {
  width: 100%;
  aspect-ratio: 16 / 9;
  justify-content: flex-end;
}

.image-placeholder--workflow {
  margin-left: auto;
  margin-right: auto;
  width: 100%;
  max-width: 960px;
  aspect-ratio: 16 / 9;
  justify-content: flex-end;
}

.image-placeholder--diagram-43 {
  margin-left: auto;
  margin-right: auto;
  width: 100%;
  max-width: 760px;
  aspect-ratio: 4 / 3;
  justify-content: flex-end;
}

/* ============== Hero Video ============== */
.hero__video {
  width: 100%;
  border-radius: var(--radius-comfortable);
  overflow: hidden;
  background: var(--color-deep-navy);
  box-shadow: var(--shadow-glow);
  position: relative;
  aspect-ratio: 4 / 3;
}

.hero__video-el {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.image-placeholder--workflow.image-placeholder--with-margin,
.section .image-placeholder--workflow {
  margin-top: 48px;
}

/* ============== Trust Figures (real images) ============== */
.trust-figure {
  margin: 0;
  width: 100%;
  border-radius: var(--radius-comfortable);
  overflow: hidden;
  background: var(--color-deep-navy);
  box-shadow: var(--shadow-glow);
  display: block;
}

.trust-figure img {
  width: 100%;
  height: auto;
  display: block;
}

.trust-figure--hero {
  aspect-ratio: 16 / 9;
}

.trust-figure--hero img {
  height: 100%;
  object-fit: cover;
}

.trust-figure--workflow {
  margin-left: auto;
  margin-right: auto;
  max-width: 960px;
}

.trust-figure--diagram-43 {
  margin-left: auto;
  margin-right: auto;
  max-width: 720px;
}

.section .trust-figure--workflow,
.section .trust-figure--diagram-43,
.section .trust-figure--region {
  margin-top: 48px;
  margin-bottom: 48px;
}

.trust-figure--region {
  margin-left: auto;
  margin-right: auto;
  max-width: 1100px;
}

/* ============== Generic Section ============== */
.section {
  padding: var(--section-padding-y) 0;
}

.section--tinted {
  background:
    linear-gradient(
      180deg,
      rgba(185, 227, 255, 0.18) 0%,
      rgba(185, 227, 255, 0.05) 100%
    );
  border-top: 1px solid var(--border-soft);
  border-bottom: 1px solid var(--border-soft);
}

/* ============== Problem Grid ============== */
.problem-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.problem-card {
  background: var(--color-white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-comfortable);
  padding: 28px;
  transition: border-color 200ms ease, box-shadow 200ms ease,
    transform 200ms ease;
}

.problem-card:hover {
  border-color: rgba(91, 61, 245, 0.25);
  box-shadow: var(--shadow-elevated);
  transform: translateY(-2px);
}

.problem-card__num {
  display: block;
  margin-bottom: 16px;
  color: var(--color-vivid-indigo);
}

.problem-card h3 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 18px;
  line-height: 1.25;
  letter-spacing: -0.018em;
  margin: 0 0 10px;
  color: var(--text-primary);
}

.problem-card p {
  font-size: 14px;
  line-height: 1.5;
  color: var(--text-muted);
  margin: 0;
}

@media (max-width: 1100px) {
  .problem-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .problem-grid {
    grid-template-columns: 1fr;
  }
}

/* ============== Steps Grid ============== */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.step-card {
  background: var(--color-white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-comfortable);
  padding: 32px;
  position: relative;
}

.step-card__num {
  display: block;
  margin-bottom: 20px;
  color: var(--color-vivid-indigo);
}

.step-card h3 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 22px;
  line-height: 1.2;
  letter-spacing: -0.022em;
  margin: 0 0 12px;
  color: var(--text-primary);
}

.step-card p {
  font-size: 15px;
  line-height: 1.5;
  color: var(--text-muted);
  margin: 0;
}

@media (max-width: 880px) {
  .steps-grid {
    grid-template-columns: 1fr;
  }
}

/* ============== Audience Grid ============== */
.audience-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.audience-card {
  padding: 28px;
  border-left: 2px solid var(--color-vivid-indigo);
  background: var(--color-white);
  border-radius: 0 var(--radius-comfortable) var(--radius-comfortable) 0;
}

.audience-card .mono-small {
  display: block;
  margin-bottom: 12px;
  color: var(--color-vivid-indigo);
}

.audience-card h3 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 20px;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin: 0 0 12px;
  color: var(--text-primary);
}

.audience-card p {
  font-size: 15px;
  line-height: 1.5;
  color: var(--text-muted);
  margin: 0;
}

@media (max-width: 880px) {
  .audience-grid {
    grid-template-columns: 1fr;
  }
}

/* ============== Comparison Table ============== */
.compare {
  border: 1px solid var(--border-light);
  border-radius: var(--radius-comfortable);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  background: var(--color-white);
}

.compare__table {
  width: 100%;
  min-width: 720px;
  border-collapse: collapse;
  font-size: 15px;
}

.compare__table thead th {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 16px;
  text-align: left;
  padding: 20px 24px;
  background: rgba(185, 227, 255, 0.18);
  color: var(--text-primary);
  letter-spacing: -0.016em;
  border-bottom: 1px solid var(--border-light);
}

.compare__table thead th.compare__highlight {
  background: var(--gradient-brand);
  color: var(--color-white);
}

.compare__table tbody th {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
  text-align: left;
  padding: 20px 24px;
  width: 22%;
  vertical-align: top;
  border-bottom: 1px solid var(--border-soft);
  background: rgba(6, 11, 45, 0.02);
}

.compare__table tbody td {
  padding: 20px 24px;
  vertical-align: top;
  color: var(--text-muted);
  line-height: 1.5;
  border-bottom: 1px solid var(--border-soft);
}

.compare__table tbody td.compare__highlight {
  color: var(--text-primary);
  background: rgba(91, 61, 245, 0.04);
  font-weight: 500;
}

.compare__table tbody tr:last-child th,
.compare__table tbody tr:last-child td {
  border-bottom: none;
}

@media (max-width: 720px) {
  .compare__table thead th,
  .compare__table tbody th,
  .compare__table tbody td {
    padding: 14px 16px;
    font-size: 14px;
  }
}

/* ============== Trust Strip ============== */
.trust-strip {
  padding: 56px 0;
  background: var(--color-deep-navy);
  color: var(--text-on-dark);
}

.trust-strip__inner {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.trust-strip__item .mono-small {
  display: block;
  margin-bottom: 12px;
  color: var(--color-soft-violet);
}

.trust-strip__item p {
  font-size: 16px;
  line-height: 1.45;
  color: var(--text-muted-on-dark);
  margin: 0;
  max-width: 32ch;
}

@media (max-width: 880px) {
  .trust-strip__inner {
    grid-template-columns: 1fr;
    gap: 24px;
  }
}

/* ============== Product Card — plain title (no logo) ============== */
.product-card__title.plain {
  display: block;
}

/* ============== Page Hero (smaller, no full-bleed video) ============== */
.hero--page {
  padding: 100px 0 80px;
  text-align: center;
}

.hero__page-inner {
  max-width: 880px;
  margin-left: auto;
  margin-right: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero--page .lead {
  margin-left: auto;
  margin-right: auto;
}

.hero--page .hero__cta--left {
  justify-content: center;
}

.hero--page .subp-meta {
  margin-left: auto;
  margin-right: auto;
}

/* ============== Solutions TOC ============== */
.solution-toc {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.solution-toc a {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 8px 14px;
  border: 1px solid var(--border-light);
  border-radius: 999px;
  color: var(--text-primary);
  transition: border-color 160ms ease, background 160ms ease,
    color 160ms ease;
}

.solution-toc a:hover {
  border-color: var(--color-vivid-indigo);
  background: rgba(91, 61, 245, 0.06);
  color: var(--color-vivid-indigo);
}

.solution-toc--on-dark {
  justify-content: center;
  margin-top: 16px;
}

.solution-toc--on-dark a {
  border-color: rgba(255, 255, 255, 0.3);
  color: var(--color-white);
  background: rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.solution-toc--on-dark a:hover {
  border-color: rgba(255, 255, 255, 0.7);
  background: rgba(255, 255, 255, 0.16);
  color: var(--color-white);
}

/* ============== Split Page Hero (text + media side-by-side) ============== */
.hero--split-page {
  padding: 100px 0 80px;
  text-align: left;
}

.hero--split-page .hero__bloom {
  inset: -10% -20% auto 30%;
  height: 600px;
}

.hero__split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}

.hero--split-page .hero__content {
  text-align: left;
}

.hero--split-page .hero__cta {
  justify-content: flex-start;
  margin-bottom: 0;
}

.hero--split-page .lead {
  margin-left: 0;
  margin-right: 0;
}

.hero--split-page .hero__media {
  display: flex;
  justify-content: center;
}

@media (max-width: 880px) {
  .hero--split-page .hero__split {
    grid-template-columns: 1fr;
    gap: 32px;
  }
}

/* ============== Five-card problem grid ============== */
.problem-grid--five {
  grid-template-columns: repeat(5, 1fr);
}

@media (max-width: 1100px) {
  .problem-grid--five {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .problem-grid--five {
    grid-template-columns: 1fr;
  }
}

/* ============== Four-card audience grid ============== */
.audience-grid--four {
  grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 1100px) {
  .audience-grid--four {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .audience-grid--four {
    grid-template-columns: 1fr;
  }
}

/* ============== Layer Cards (7-layer architecture) ============== */
.layer-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
  margin-top: 48px;
}

.layer-card {
  background: var(--color-white);
  border: 1px solid var(--border-light);
  border-left: 3px solid var(--color-vivid-indigo);
  border-radius: 0 var(--radius-comfortable) var(--radius-comfortable) 0;
  padding: 24px;
  transition: border-color 200ms ease, box-shadow 200ms ease,
    transform 200ms ease;
}

.layer-card:hover {
  box-shadow: var(--shadow-elevated);
  transform: translateY(-2px);
}

.layer-card__num {
  display: block;
  margin-bottom: 12px;
  color: var(--color-vivid-indigo);
}

.layer-card h3 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 18px;
  line-height: 1.2;
  letter-spacing: -0.018em;
  margin: 0 0 10px;
  color: var(--text-primary);
}

.layer-card p {
  font-size: 14px;
  line-height: 1.5;
  color: var(--text-muted);
  margin: 0;
}

/* ============== Certifications List ============== */
.cert-list {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-top: 32px;
}

.cert-item {
  background: var(--color-white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-comfortable);
  padding: 24px;
}

.cert-item .mono-small {
  display: block;
  margin-bottom: 12px;
  color: var(--color-vivid-indigo);
}

.cert-item h3 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 18px;
  line-height: 1.2;
  letter-spacing: -0.018em;
  margin: 0 0 10px;
  color: var(--text-primary);
}

.cert-item p {
  font-size: 14px;
  line-height: 1.5;
  color: var(--text-muted);
  margin: 0;
}

.cert-note {
  display: block;
  text-align: center;
  margin-top: 28px;
  color: var(--text-muted);
  max-width: 64ch;
  margin-left: auto;
  margin-right: auto;
}

@media (max-width: 880px) {
  .cert-list {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .cert-list {
    grid-template-columns: 1fr;
  }
}

/* ============== Image placeholder — certs strip ============== */
.image-placeholder--certs {
  margin-left: auto;
  margin-right: auto;
  width: 100%;
  max-width: 1100px;
  aspect-ratio: 16 / 5;
  justify-content: flex-end;
}

/* ============== Resource Cards (Trust Center) ============== */
.resource-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.resource-card {
  background: var(--color-white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-comfortable);
  padding: 28px;
  display: flex;
  flex-direction: column;
  transition: border-color 200ms ease, box-shadow 200ms ease,
    transform 200ms ease;
}

.resource-card:hover {
  border-color: rgba(91, 61, 245, 0.25);
  box-shadow: var(--shadow-elevated);
  transform: translateY(-2px);
}

.resource-card .mono-small {
  display: block;
  margin-bottom: 14px;
  color: var(--color-vivid-indigo);
}

.resource-card__status {
  display: inline-block !important;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid currentColor;
  font-size: 10px;
  width: fit-content;
}

.resource-card__status--public {
  color: var(--color-vivid-indigo);
  background: rgba(91, 61, 245, 0.06);
}

.resource-card__status--gated {
  color: var(--text-muted);
  background: rgba(6, 11, 45, 0.04);
}

.resource-card h3 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 20px;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin: 0 0 10px;
  color: var(--text-primary);
}

.resource-card p {
  font-size: 15px;
  line-height: 1.5;
  color: var(--text-muted);
  margin: 0 0 16px;
  flex-grow: 1;
}

.resource-card .link-arrow {
  margin-top: 0;
}

@media (max-width: 880px) {
  .resource-grid {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 881px) and (max-width: 1100px) {
  .resource-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ============== Solution Catalog ============== */
.section--catalog {
  padding-top: 40px;
}

.solution-group {
  padding: 56px 0;
  border-top: 1px solid var(--border-soft);
}

.solution-group:first-child {
  border-top: none;
  padding-top: 24px;
}

.solution-group__head {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 16px 32px;
  margin-bottom: 32px;
}

.solution-group__brand-row {
  display: flex;
  align-items: center;
  gap: 12px;
  grid-column: 1 / 2;
}

.solution-group__brand {
  height: 40px;
  width: auto;
  display: block;
}

.solution-group__name {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(24px, 3vw, 32px);
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0;
  color: var(--text-primary);
}

.solution-group__tagline {
  grid-column: 1 / 2;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 18px;
  line-height: 1.35;
  letter-spacing: -0.18px;
  color: var(--color-vivid-indigo);
  margin: 0;
  max-width: 56ch;
}

.solution-group__link {
  grid-column: 2 / 3;
  grid-row: 1 / 3;
  align-self: center;
  margin-top: 0;
  white-space: nowrap;
}

.solution-group__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}

.solution-card {
  background: var(--color-white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-comfortable);
  padding: 24px;
  transition: border-color 200ms ease, box-shadow 200ms ease,
    transform 200ms ease;
}

.solution-card:hover {
  border-color: rgba(91, 61, 245, 0.25);
  box-shadow: var(--shadow-elevated);
  transform: translateY(-2px);
}

.solution-card__title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 18px;
  line-height: 1.2;
  letter-spacing: -0.018em;
  margin: 0 0 8px;
  color: var(--text-primary);
}

.solution-card__tagline {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 500;
  line-height: 1.35;
  letter-spacing: -0.14px;
  color: var(--color-vivid-indigo);
  margin: 0 0 12px;
}

.solution-card__body {
  font-size: 14px;
  line-height: 1.5;
  letter-spacing: -0.14px;
  color: var(--text-muted);
  margin: 0;
}

@media (max-width: 720px) {
  .solution-group__head {
    grid-template-columns: 1fr;
  }
  .solution-group__brand-row,
  .solution-group__tagline,
  .solution-group__link {
    grid-column: 1 / 2;
  }
  .solution-group__link {
    grid-row: auto;
    align-self: flex-start;
    margin-top: 0;
  }
}

/* =============================================================
   Sub-processors page
   ============================================================= */
.subp-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  margin: 24px 0 32px;
  padding: 16px 20px;
  background: rgba(91, 61, 245, 0.06);
  border: 1px solid rgba(91, 61, 245, 0.18);
  border-radius: var(--radius-comfortable);
  width: fit-content;
}

.subp-meta__item {
  color: var(--text-primary);
}

.subp-meta__item strong {
  color: var(--color-vivid-indigo);
  margin-right: 6px;
  font-weight: 500;
  letter-spacing: 0.04em;
}

/* Activation pills */
.subp-pill {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border: 1px solid currentColor;
  white-space: nowrap;
}

.subp-pill--always {
  color: var(--color-vivid-indigo);
  background: rgba(91, 61, 245, 0.08);
}

.subp-pill--cond {
  color: var(--color-electric-blue);
  background: rgba(30, 144, 255, 0.08);
}

.subp-pill--internal {
  color: var(--text-muted);
  background: rgba(6, 11, 45, 0.04);
}

/* Table wrapper */
.subp-table-wrap {
  margin-top: 32px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-comfortable);
  background: var(--color-white);
  overflow-x: auto;
}

.subp-table {
  width: 100%;
  min-width: 880px;
  border-collapse: collapse;
  font-family: var(--font-display);
  font-size: 14px;
  line-height: 1.5;
  min-width: 880px;
}

.subp-table thead th {
  text-align: left;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 16px 18px;
  background: rgba(6, 11, 45, 0.03);
  border-bottom: 1px solid var(--border-light);
  white-space: nowrap;
}

.subp-table tbody th[scope="row"] {
  text-align: left;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 15px;
  color: var(--text-primary);
  padding: 18px;
  vertical-align: top;
  width: 18%;
  min-width: 160px;
  border-bottom: 1px solid var(--border-soft);
}

.subp-table tbody th[scope="row"] a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid rgba(91, 61, 245, 0.3);
  transition: border-color 150ms ease, color 150ms ease;
}

.subp-table tbody th[scope="row"] a:hover {
  color: var(--color-vivid-indigo);
  border-bottom-color: var(--color-vivid-indigo);
}

.subp-table tbody td {
  padding: 18px;
  vertical-align: top;
  color: var(--text-primary);
  border-bottom: 1px solid var(--border-soft);
}

.subp-table tbody td small {
  display: block;
  margin-top: 4px;
  font-size: 12px;
  color: var(--text-muted);
}

.subp-table tbody tr:last-child th,
.subp-table tbody tr:last-child td {
  border-bottom: none;
}

.subp-table tbody tr:hover {
  background: rgba(91, 61, 245, 0.025);
}

/* Column widths */
.subp-table thead th:nth-child(1),
.subp-table tbody th[scope="row"] {
  width: 16%;
}

.subp-table thead th:nth-child(2),
.subp-table tbody td:nth-child(2) {
  width: 24%;
}

.subp-table thead th:nth-child(3),
.subp-table tbody td:nth-child(3) {
  width: 12%;
}

.subp-table thead th:nth-child(4),
.subp-table tbody td:nth-child(4) {
  width: 22%;
}

.subp-table thead th:nth-child(5),
.subp-table tbody td:nth-child(5) {
  width: 26%;
}

/* Changelog */
.changelog-list {
  margin-top: 32px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.changelog-item {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 32px;
  padding: 24px;
  background: var(--color-white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-comfortable);
}

.changelog-item__date {
  color: var(--color-vivid-indigo);
  padding-top: 4px;
}

.changelog-item__body h3 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 18px;
  line-height: 1.3;
  margin: 0 0 8px;
  color: var(--text-primary);
}

.changelog-item__body p {
  margin: 0;
  font-size: 15px;
  line-height: 1.55;
  color: var(--text-muted);
}

@media (max-width: 720px) {
  .subp-meta {
    width: 100%;
    flex-direction: column;
    gap: 8px;
  }
  .changelog-item {
    grid-template-columns: 1fr;
    gap: 12px;
  }
}

/* =============================================================
   Markdown Viewer (.prose) — for rendered .md docs
   ============================================================= */
.viewer {
  background: var(--color-white);
}

.viewer__layout {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 64px;
  padding: 60px 0 100px;
  align-items: start;
}

.viewer__toc {
  position: sticky;
  top: 100px;
  max-height: calc(100vh - 120px);
  overflow-y: auto;
  padding-right: 16px;
}

.viewer__toc-label {
  display: block;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.viewer__toc-list {
  list-style: none;
  padding: 0;
  margin: 0;
  border-left: 1px solid var(--border-light);
}

.viewer__toc-list li {
  margin: 0;
}

.viewer__toc-list a {
  display: block;
  padding: 6px 0 6px 14px;
  margin-left: -1px;
  font-size: 13px;
  line-height: 1.4;
  color: var(--text-muted);
  text-decoration: none;
  border-left: 1px solid transparent;
  transition: color 150ms ease, border-color 150ms ease;
}

.viewer__toc-list a:hover,
.viewer__toc-list a.is-active {
  color: var(--color-vivid-indigo);
  border-left-color: var(--color-vivid-indigo);
}

.viewer__toc-list .is-h3 a {
  padding-left: 28px;
  font-size: 12px;
  color: var(--text-muted);
}

.viewer__main {
  min-width: 0; /* allow tables to overflow gracefully */
}

.viewer__loading,
.viewer__error {
  padding: 80px 0;
  text-align: center;
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.viewer__error {
  color: #c0392b;
}

/* === Prose content === */
.prose {
  font-family: var(--font-display);
  color: var(--text-primary);
  font-size: 16px;
  line-height: 1.7;
  max-width: 760px;
}

.prose > *:first-child {
  margin-top: 0;
}

.prose h1 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 40px;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 56px 0 24px;
  color: var(--text-primary);
}

.prose h2 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 28px;
  line-height: 1.2;
  letter-spacing: -0.015em;
  margin: 56px 0 20px;
  padding-top: 24px;
  border-top: 1px solid var(--border-soft);
  color: var(--text-primary);
  scroll-margin-top: 100px;
}

.prose h3 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 21px;
  line-height: 1.3;
  letter-spacing: -0.01em;
  margin: 36px 0 14px;
  color: var(--text-primary);
  scroll-margin-top: 100px;
}

.prose h4 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 17px;
  line-height: 1.35;
  margin: 28px 0 10px;
  color: var(--text-primary);
}

.prose p {
  margin: 0 0 16px;
}

.prose strong {
  font-weight: 500;
  color: var(--text-primary);
}

.prose em {
  font-style: italic;
  color: var(--text-primary);
}

.prose a {
  color: var(--color-vivid-indigo);
  text-decoration: none;
  border-bottom: 1px solid rgba(91, 61, 245, 0.3);
  transition: border-color 150ms ease;
}

.prose a:hover {
  border-bottom-color: var(--color-vivid-indigo);
}

.prose ul,
.prose ol {
  margin: 0 0 18px;
  padding-left: 28px;
}

.prose li {
  margin-bottom: 6px;
}

.prose li > ul,
.prose li > ol {
  margin-top: 6px;
  margin-bottom: 6px;
}

.prose blockquote {
  margin: 24px 0;
  padding: 12px 20px;
  border-left: 3px solid var(--color-vivid-indigo);
  background: rgba(91, 61, 245, 0.04);
  color: var(--text-muted);
  font-size: 15px;
  border-radius: 0 var(--radius-comfortable) var(--radius-comfortable) 0;
}

.prose blockquote p:last-child {
  margin-bottom: 0;
}

.prose code {
  font-family: var(--font-mono);
  font-size: 0.88em;
  padding: 2px 6px;
  background: rgba(6, 11, 45, 0.06);
  border-radius: 4px;
  color: var(--color-vivid-indigo);
}

.prose pre {
  background: var(--color-deep-navy);
  color: var(--color-ice-blue);
  padding: 20px 24px;
  border-radius: var(--radius-comfortable);
  overflow-x: auto;
  font-family: var(--font-mono);
  font-size: 13px;
  line-height: 1.55;
  margin: 24px 0;
}

.prose pre code {
  background: transparent;
  padding: 0;
  color: inherit;
  font-size: inherit;
}

.prose hr {
  border: none;
  border-top: 1px solid var(--border-light);
  margin: 48px 0;
}

.prose table {
  width: 100%;
  border-collapse: collapse;
  margin: 24px 0;
  font-size: 14px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-comfortable);
  overflow: hidden;
  display: block;
  overflow-x: auto;
}

.prose thead th {
  text-align: left;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 12px 14px;
  background: rgba(6, 11, 45, 0.03);
  border-bottom: 1px solid var(--border-light);
  white-space: nowrap;
}

.prose tbody td,
.prose tbody th {
  padding: 12px 14px;
  vertical-align: top;
  border-bottom: 1px solid var(--border-soft);
  text-align: left;
}

.prose tbody tr:last-child td,
.prose tbody tr:last-child th {
  border-bottom: none;
}

.prose tbody th {
  font-weight: 500;
  color: var(--text-primary);
}

.prose img {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius-comfortable);
  margin: 24px 0;
}

/* Document header (in-viewer) */
.doc-header {
  padding: 48px 0 24px;
  border-bottom: 1px solid var(--border-soft);
  margin-bottom: 32px;
}

.doc-header__meta {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.doc-header__back {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 150ms ease;
}

.doc-header__back:hover {
  color: var(--color-vivid-indigo);
}

.doc-header__divider {
  color: var(--text-muted);
  opacity: 0.4;
}

.doc-header__type {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-vivid-indigo);
}

.doc-header__title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 36px;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 8px 0 12px;
  color: var(--text-primary);
}

.doc-header__subtitle {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 19px;
  line-height: 1.4;
  letter-spacing: -0.01em;
  color: var(--color-vivid-indigo);
  margin: 0 0 24px;
  max-width: 60ch;
}

.doc-header__actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* Essay reading layout (no TOC sidebar) */
.viewer--essay {
  background: var(--color-white);
}

.viewer--essay .doc-header,
.viewer--essay .viewer__main {
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
}

.viewer--essay .doc-header {
  padding-top: 56px;
}

.viewer--essay .viewer__main {
  padding-bottom: 100px;
}

@media (max-width: 920px) {
  .viewer__layout {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .viewer__toc {
    position: static;
    max-height: none;
    padding: 16px 20px;
    background: rgba(91, 61, 245, 0.04);
    border-radius: var(--radius-comfortable);
  }
}

@media (max-width: 720px) {
  .doc-header__title {
    font-size: 28px;
  }
  .prose h1 {
    font-size: 30px;
  }
  .prose h2 {
    font-size: 24px;
  }
}

/* =============================================================
   Research Papers
   ============================================================= */
.research-group {
  padding: 56px 0;
  border-top: 1px solid var(--border-soft);
}

.research-group:first-of-type {
  border-top: none;
  padding-top: 24px;
}

.research-group__head {
  margin-bottom: 28px;
}

.research-group__name {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(24px, 3vw, 32px);
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 8px;
  color: var(--text-primary);
}

.research-group__tagline {
  font-family: var(--font-display);
  font-size: 17px;
  line-height: 1.4;
  letter-spacing: -0.18px;
  color: var(--color-vivid-indigo);
  margin: 0;
  max-width: 60ch;
}

.paper-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.paper {
  background: var(--color-white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-comfortable);
  padding: 28px 32px;
  transition: border-color 200ms ease, box-shadow 200ms ease,
    transform 200ms ease;
}

.paper:hover {
  border-color: rgba(91, 61, 245, 0.25);
  box-shadow: var(--shadow-elevated);
  transform: translateY(-2px);
}

.paper__meta {
  margin-bottom: 14px;
}

.paper__title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 22px;
  line-height: 1.25;
  letter-spacing: -0.02em;
  margin: 0 0 6px;
  color: var(--text-primary);
}

.paper__subtitle {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 16px;
  line-height: 1.4;
  color: var(--color-vivid-indigo);
  margin: 0 0 14px;
}

.paper__abstract {
  font-size: 15px;
  line-height: 1.65;
  color: var(--text-muted);
  margin: 0 0 20px;
  max-width: 72ch;
}

.paper__abstract em {
  font-style: italic;
  color: var(--text-primary);
}

.paper__formats {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}

.paper__lang {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 150ms ease;
}

.paper__lang:hover {
  color: var(--color-vivid-indigo);
}

@media (max-width: 720px) {
  .paper {
    padding: 24px;
  }
  .paper__title {
    font-size: 19px;
  }
}

/* ============== Technologies page ============== */
.tech-section {
  padding: 100px 0;
  background: var(--color-white);
}

.tech-section--alt {
  background: rgba(185, 227, 255, 0.12);
}

.tech-section__inner {
  max-width: 880px;
  margin-left: auto;
  margin-right: auto;
}

.tech-section .section-head {
  margin-bottom: 32px;
}

.section-title--brand {
  background: linear-gradient(
    135deg,
    var(--color-electric-blue) 0%,
    var(--color-vivid-indigo) 50%,
    var(--color-soft-violet) 100%
  );
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

.section-subtitle {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 400;
  font-size: 22px;
  line-height: 1.4;
  color: var(--color-vivid-indigo);
  margin: 8px 0 0;
}

.prose-block {
  font-size: 17px;
  line-height: 1.7;
  color: var(--text-primary);
}

.prose-block p {
  margin: 0 0 18px;
}

.prose-block p:last-child {
  margin-bottom: 0;
}

.prose-block strong {
  color: var(--color-deep-navy);
}

.prose-block em {
  color: var(--color-vivid-indigo);
  font-style: italic;
}

.prose-block code {
  font-family: var(--font-mono);
  font-size: 0.88em;
  padding: 2px 6px;
  background: rgba(91, 61, 245, 0.08);
  color: var(--color-vivid-indigo);
  border-radius: 4px;
}

.checklist {
  list-style: none;
  padding: 0;
  margin: 24px 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.checklist li {
  position: relative;
  padding-left: 28px;
  line-height: 1.65;
}

.checklist li::before {
  content: "→";
  position: absolute;
  left: 0;
  top: 0;
  color: var(--color-vivid-indigo);
  font-weight: 600;
}

.checklist--issues li::before {
  content: "×";
  color: #d04343;
  font-size: 18px;
  line-height: 1.4;
}

.problem-grid--two {
  grid-template-columns: repeat(2, 1fr);
  margin-top: 24px;
  margin-bottom: 24px;
}

.problem-grid--issues .problem-card__num {
  color: #d04343;
}

.problem-grid--capabilities .problem-card__num {
  color: var(--color-vivid-indigo);
}

/* ============== KG Decoration (force-directed graph) ============== */
.kg-decoration {
  position: relative;
  background: var(--color-deep-navy);
  padding: 80px 0 60px;
  overflow: hidden;
  isolation: isolate;
}

.kg-decoration__aurora {
  position: absolute;
  inset: -20% -10% auto -10%;
  height: 80%;
  background:
    radial-gradient(
      40% 50% at 30% 50%,
      rgba(91, 61, 245, 0.35) 0%,
      transparent 70%
    ),
    radial-gradient(
      40% 50% at 70% 50%,
      rgba(30, 144, 255, 0.25) 0%,
      transparent 70%
    );
  filter: blur(40px);
  z-index: 0;
  pointer-events: none;
}

.kg-decoration__inner {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.kg-decoration__svg {
  width: 100%;
  max-width: 960px;
  height: 540px;
  display: block;
  cursor: grab;
}

.kg-decoration__svg:active {
  cursor: grabbing;
}

.kg-decoration__caption {
  text-align: center;
  letter-spacing: 0.08em;
  opacity: 0.7;
}

@media (max-width: 720px) {
  .kg-decoration__svg {
    height: 360px;
  }
  .kg-decoration {
    padding: 56px 0 40px;
  }
}

.prose-block--after-grid {
  margin-top: 24px;
}

@media (max-width: 880px) {
  .problem-grid--two {
    grid-template-columns: 1fr;
  }
}

.principle-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-top: 8px;
}

.principle {
  background: var(--color-white);
  border: 1px solid var(--border-light);
  border-radius: 14px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.principle:hover {
  border-color: var(--color-vivid-indigo);
  transform: translateY(-2px);
}

.principle__num {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--color-vivid-indigo);
}

.principle__title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 20px;
  letter-spacing: -0.01em;
  color: var(--color-deep-navy);
  margin: 0;
}

.principle p {
  font-size: 15px;
  line-height: 1.6;
  color: var(--text-muted);
  margin: 0;
}

.principle code {
  font-family: var(--font-mono);
  font-size: 0.85em;
  padding: 1px 5px;
  background: rgba(91, 61, 245, 0.08);
  color: var(--color-vivid-indigo);
  border-radius: 4px;
}

@media (max-width: 880px) {
  .tech-section {
    padding: 64px 0;
  }
  .principle-grid {
    grid-template-columns: 1fr;
  }
}

/* ============================================================
   Contact page
   ============================================================ */
.contact-section {
  padding: 60px 0 100px;
  background: var(--color-white);
}

.contact-grid {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) minmax(0, 1.4fr);
  gap: 64px;
  align-items: start;
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 36px;
  position: sticky;
  top: 100px;
}

.contact-info__block {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.contact-info__title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 22px;
  letter-spacing: -0.01em;
  color: var(--color-deep-navy);
  margin: 0;
}

.contact-info__address {
  font-style: normal;
  font-size: 15px;
  line-height: 1.7;
  color: var(--text-muted);
}

.contact-info__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.contact-info__list li {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.contact-info__list a {
  font-size: 15px;
  color: var(--color-vivid-indigo);
  letter-spacing: -0.01em;
  word-break: break-word;
}

.contact-info__list a:hover {
  color: var(--color-soft-violet);
  text-decoration: underline;
}

.contact-info__hours {
  margin: 0;
  font-size: 15px;
  line-height: 1.7;
  color: var(--text-muted);
}

/* Form */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
  background: var(--color-white);
  border: 1px solid var(--border-light);
  border-radius: 14px;
  padding: 36px;
}

.contact-form__row {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.contact-form__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.contact-form__label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 500;
  color: var(--color-deep-navy);
  letter-spacing: -0.01em;
}

.contact-form__label > span em {
  font-style: normal;
  color: var(--color-vivid-indigo);
  margin-left: 2px;
}

.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form input[type="tel"],
.contact-form select,
.contact-form textarea {
  font-family: var(--font-display);
  font-size: 15px;
  color: var(--color-deep-navy);
  background: var(--color-white);
  border: 1px solid var(--border-light);
  border-radius: 8px;
  padding: 12px 14px;
  outline: none;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
  width: 100%;
}

.contact-form select {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='none' stroke='%235b3df5' stroke-width='1.5' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 40px;
  cursor: pointer;
}

.contact-form textarea {
  resize: vertical;
  min-height: 120px;
  line-height: 1.5;
}

.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
  border-color: var(--color-vivid-indigo);
  box-shadow: 0 0 0 3px rgba(91, 61, 245, 0.12);
}

/* intl-tel-input alignment */
.contact-form .iti {
  width: 100%;
  display: block;
}

.contact-form .iti__tel-input {
  width: 100%;
}

.contact-form .iti--separate-dial-code .iti__selected-dial-code {
  font-family: var(--font-display);
  color: var(--color-deep-navy);
}

/* intl-tel-input country search box (in dropdown) */
.iti__search-input {
  font-family: var(--font-display) !important;
  font-size: 15px !important;
  color: var(--color-deep-navy) !important;
  padding: 12px 14px !important;
  height: auto !important;
  min-height: 44px !important;
  border: 0 !important;
  border-bottom: 1px solid var(--border-light) !important;
  border-radius: 0 !important;
  outline: none !important;
  width: 100% !important;
  box-sizing: border-box !important;
}

.iti__search-input:focus {
  border-bottom-color: var(--color-vivid-indigo) !important;
  box-shadow: 0 1px 0 0 var(--color-vivid-indigo) !important;
}

.iti__country-list {
  font-family: var(--font-display);
  font-size: 14px;
}

.iti__country {
  padding: 10px 14px;
}

.contact-form input:invalid:not(:placeholder-shown),
.contact-form textarea:invalid:not(:placeholder-shown) {
  border-color: rgba(220, 38, 38, 0.6);
}

.contact-form__consent {
  margin-top: 4px;
}

.contact-form__checkbox {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  line-height: 1.55;
  color: var(--text-muted);
  cursor: pointer;
}

.contact-form__checkbox input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  border: 1px solid var(--border-light);
  border-radius: 4px;
  background: var(--color-white);
  cursor: pointer;
  position: relative;
  margin-top: 2px;
  transition: border-color 0.18s ease, background 0.18s ease;
}

.contact-form__checkbox input[type="checkbox"]:checked {
  background: var(--color-vivid-indigo);
  border-color: var(--color-vivid-indigo);
}

.contact-form__checkbox input[type="checkbox"]:checked::after {
  content: "";
  position: absolute;
  left: 5px;
  top: 1px;
  width: 5px;
  height: 10px;
  border: solid var(--color-white);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.contact-form__checkbox a {
  color: var(--color-vivid-indigo);
  text-decoration: underline;
}

.contact-form__actions {
  display: flex;
  gap: 12px;
  margin-top: 8px;
  flex-wrap: wrap;
}

.contact-form__status {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: -0.01em;
  color: var(--text-muted);
  min-height: 20px;
  margin-top: 4px;
}

.contact-form__status--success {
  color: var(--color-vivid-indigo);
  background: rgba(91, 61, 245, 0.06);
  border: 1px solid rgba(91, 61, 245, 0.2);
  border-radius: 8px;
  padding: 12px 14px;
  line-height: 1.5;
}

/* Map */
.contact-map {
  position: relative;
  width: 100%;
  height: 560px;
  background: var(--color-deep-navy);
  overflow: hidden;
}

.contact-map__iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  filter: saturate(0.95);
}

.contact-map__overlay {
  position: absolute;
  top: 50%;
  right: max(40px, calc((100vw - var(--container-max)) / 2 + 24px));
  transform: translateY(-50%);
  z-index: 2;
  pointer-events: none;
}

.contact-map__card {
  background: var(--color-white);
  border: 1px solid var(--border-light);
  border-radius: 14px;
  padding: 28px;
  width: 360px;
  max-width: calc(100vw - 80px);
  box-shadow: 0 20px 50px rgba(6, 11, 45, 0.18);
  display: flex;
  flex-direction: column;
  gap: 12px;
  pointer-events: auto;
}

.contact-map__title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 22px;
  letter-spacing: -0.01em;
  color: var(--color-deep-navy);
  margin: 0;
}

.contact-map__address {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-muted);
  margin: 0 0 8px;
}

/* Modal */
.modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.modal[hidden] {
  display: none;
}

.modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(6, 11, 45, 0.55);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  animation: modal-fade 0.2s ease-out;
}

.modal__panel {
  position: relative;
  background: var(--color-white);
  border-radius: 16px;
  padding: 40px;
  max-width: 460px;
  width: 100%;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  box-shadow: 0 30px 80px rgba(6, 11, 45, 0.3);
  animation: modal-rise 0.28s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.modal__icon {
  margin-bottom: 4px;
}

.modal__title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 26px;
  letter-spacing: -0.02em;
  color: var(--color-deep-navy);
  margin: 0;
}

.modal__body {
  font-size: 15px;
  line-height: 1.6;
  color: var(--text-muted);
  margin: 0;
}

.modal__body strong {
  color: var(--color-deep-navy);
  font-weight: 600;
}

.modal__body a {
  color: var(--color-vivid-indigo);
  text-decoration: underline;
}

.modal__actions {
  margin-top: 12px;
  width: 100%;
  display: flex;
  justify-content: center;
}

.modal__actions .btn {
  min-width: 140px;
}

.modal__close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 32px;
  height: 32px;
  border: 0;
  background: transparent;
  font-size: 24px;
  line-height: 1;
  color: var(--text-muted);
  cursor: pointer;
  border-radius: 6px;
  transition: background 0.15s ease, color 0.15s ease;
}

.modal__close:hover {
  background: rgba(6, 11, 45, 0.06);
  color: var(--color-deep-navy);
}

@keyframes modal-fade {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes modal-rise {
  from {
    opacity: 0;
    transform: translateY(16px) scale(0.97);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@media (max-width: 960px) {
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .contact-info {
    position: static;
  }
  .contact-form {
    padding: 28px;
  }
  .contact-form__grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .contact-map {
    height: auto;
    overflow: visible;
    background: transparent;
    display: flex;
    flex-direction: column;
  }
  .contact-map__iframe {
    position: relative;
    inset: auto;
    height: 360px;
    order: 1;
  }
  .contact-map__overlay {
    position: relative;
    top: auto;
    left: auto;
    right: auto;
    transform: none;
    order: 2;
    padding: 24px;
    background: var(--color-white);
    pointer-events: auto;
  }
  .contact-map__card {
    width: 100%;
    box-shadow: none;
    padding: 0;
    border: 0;
    border-radius: 0;
  }
}
