/* ============================================
   Trial Suite — Design System
   Fonts loaded via <link> in HTML <head>
   ============================================ */

/* ---- Design Tokens ---- */
:root {
  /* Color: white base + warm surface tiles */
  --bg:           #FFFFFF;
  --bg-surface:   #F5F4F0;
  --bg-nav:       rgba(255, 255, 255, 0.88);
  --bg-nav-solid: rgba(255, 255, 255, 0.98);
  --text:         #1A1A18;
  --text-2:       #6B6B66;
  --text-3:       #767670;  /* AA-compliant ~4.5:1 on --bg */
  --border:       #E5E4E0;
  --accent:       #B34A24;  /* AA-compliant ~4.7:1 on --bg */
  --accent-hover: #963D1E;
  --accent-light: rgba(179, 74, 36, 0.07);

  /* Typography */
  --font-display: 'Source Serif 4', Georgia, serif;
  --font-body:    'Pretendard', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;

  /* Spacing (4pt grid) */
  --s-4:  4px;
  --s-8:  8px;
  --s-12: 12px;
  --s-16: 16px;
  --s-24: 24px;
  --s-32: 32px;
  --s-48: 48px;
  --s-64: 64px;
  --s-96: 96px;

  /* Layout */
  --container: 1080px;
  --nav-h:     64px;

  /* Legacy aliases (backward-compat for ctms/epro/specimen/contact pages) */
  --bg-primary:     var(--bg);
  --bg-secondary:   var(--bg-surface);
  --bg-sepia:       #E8E1D9;
  --bg-dark:        #2B2B2B;
  --text-primary:   var(--text);
  --text-secondary: var(--text-2);
  --text-light:     var(--text-3);
  --text-inverse:   #FAFAF8;
  --border-color:   var(--border);
  --border-sepia:   #D8D1C9;
  --accent-primary:      var(--accent);
  --accent-hover-legacy: var(--accent-hover);
  --container-width: var(--container);
  --spacing-xs: var(--s-8);
  --spacing-sm: var(--s-16);
  --spacing-md: var(--s-32);
  --spacing-lg: var(--s-64);
  --spacing-xl: 120px;
  --border-radius-sm: 8px;
  --border-radius-md: 12px;
  --box-shadow-subtle: 0 4px 20px rgba(0, 0, 0, 0.04);
  --box-shadow-hover:  0 12px 30px rgba(0, 0, 0, 0.08);
  --transition-smooth: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}


/* ---- Reset ---- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  color: var(--text);
  background: var(--bg);
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
img { display: block; max-width: 100%; height: auto; }
button { font: inherit; cursor: pointer; }

/* ---- Accessibility ---- */
.skip-link {
  position: absolute;
  top: -100%;
  left: var(--s-16);
  z-index: 200;
  padding: var(--s-8) var(--s-16);
  background: var(--text);
  color: var(--bg);
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: var(--border-radius-sm);
}

.skip-link:focus {
  top: var(--s-8);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Focus indicators */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 2px;
}

.btn-primary:focus-visible {
  outline-offset: 4px;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-body);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--text);
}


/* ---- Layout ---- */
.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 clamp(20px, 5vw, 40px);
}

.section {
  padding: clamp(80px, 12vw, 160px) 0;
}

/* Tile-based sections: tight outer padding, tile provides inner space */
.section:has(> .tile) {
  padding: clamp(10px, 1.5vw, 16px) clamp(12px, 2vw, 20px);
}

/* Content tile — rounded box on white background */
.tile {
  max-width: 1200px;
  margin: 0 auto;
  padding: clamp(48px, 7vw, 80px) clamp(40px, 6vw, 72px);
  background: var(--bg-surface);
  border-radius: clamp(16px, 2vw, 24px);
}

/* Legacy: keep for subpages */
.section-surface {
  background: var(--bg-surface);
}


/* ============================================
   Navigation
   ============================================ */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: var(--bg-nav);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  transition: box-shadow 0.3s ease, background 0.3s ease;
}

.navbar.scrolled {
  box-shadow: 0 1px 0 0 var(--border);
}

.nav-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: var(--nav-h);
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 clamp(20px, 5vw, 40px);
  transition: height 0.3s ease;
}

.navbar.scrolled .nav-inner {
  height: 56px;
}

/* Logo */
.nav-logo {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--text);
}

.logo-dot {
  color: var(--accent);
  font-weight: 700;
}

/* Links */
.nav-links {
  display: flex;
  align-items: center;
  gap: var(--s-24);
}

.nav-link {
  position: relative;
  font-size: 0.875rem;
  font-weight: 450;
  color: var(--text-2);
  transition: color 0.2s ease;
  padding: var(--s-4) 0;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  right: 0;
  height: 1.5px;
  background: var(--text);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav-link:hover {
  color: var(--text);
}

.nav-link:hover::after,
.nav-link.active::after {
  transform: scaleX(1);
}

/* Divider */
.nav-divider {
  width: 1px;
  height: 16px;
  background: var(--border);
  flex-shrink: 0;
}

/* CTA button */
.nav-cta {
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text);
  letter-spacing: 0.01em;
  padding: 7px 18px;
  border: 1px solid var(--border);
  border-radius: 100px;
  transition: border-color 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.nav-cta:hover {
  border-color: var(--text-3);
  background: var(--bg-surface);
}

/* Hamburger toggle */
.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: var(--s-4);
  background: none;
  border: none;
  padding: var(--s-8);
  width: 44px;
  height: 44px;
}

.menu-toggle span {
  display: block;
  width: 18px;
  height: 1.5px;
  background: var(--text);
  transition: transform 0.25s ease, opacity 0.25s ease;
  transform-origin: center;
}

.menu-toggle.active span:first-child {
  transform: translateY(2.75px) rotate(45deg);
}

.menu-toggle.active span:last-child {
  transform: translateY(-2.75px) rotate(-45deg);
}


/* ============================================
   Hero
   ============================================ */
.hero {
  padding: calc(var(--nav-h) + clamp(80px, 14vw, 160px)) 0 clamp(48px, 8vw, 96px);
  text-align: center;
}

.hero-label {
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text-3);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-bottom: var(--s-24);
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(3rem, 8vw, 5.5rem);
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -0.035em;
  margin-bottom: var(--s-24);
  color: var(--text);
}

.hero-desc {
  font-size: 1.0625rem;
  color: var(--text-2);
  max-width: 400px;
  margin: 0 auto var(--s-48);
  line-height: 1.8;
}

/* Hero Slideshow */
.hero-slideshow {
  max-width: 1200px;
  margin: clamp(40px, 6vw, 72px) auto 0;
  padding: 0 clamp(16px, 3vw, 32px);
}

.slideshow-track {
  position: relative;
  border-radius: var(--border-radius-md);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow:
    0 4px 8px -2px rgba(26, 26, 24, 0.05),
    0 24px 64px -16px rgba(26, 26, 24, 0.14);
  /* reserve height to prevent CLS */
  aspect-ratio: 16 / 9;
  background: var(--bg-surface);
}

.slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.slide--active {
  opacity: 1;
  z-index: 1;
}

.slide img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: top left;
}

/* Indicators — product name tabs */
.slideshow-indicators {
  display: flex;
  justify-content: center;
  gap: var(--s-4);
  margin-top: var(--s-16);
}

.indicator {
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-3);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: var(--s-8) var(--s-16);
  background: none;
  border: none;
  border-radius: 100px;
  cursor: pointer;
  transition: color 0.2s ease, background 0.2s ease;
  min-height: 36px;
}

.indicator:hover {
  color: var(--text-2);
  background: var(--bg-surface);
}

.indicator--active {
  color: var(--text);
  background: var(--bg-surface);
}

/* Progress bar under active indicator */
.indicator--active::after {
  content: '';
  display: block;
  height: 2px;
  margin-top: var(--s-4);
  background: var(--accent);
  border-radius: 1px;
  animation: indicatorProgress 4s linear forwards;
}

@keyframes indicatorProgress {
  from { width: 0; }
  to { width: 100%; }
}

/* Hero dual CTA */
.hero-actions {
  display: flex;
  gap: var(--s-16);
  justify-content: center;
  align-items: center;
}


/* ============================================
   Buttons
   ============================================ */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 15px 32px;
  min-height: 48px;
  background: var(--accent);
  color: var(--bg);
  font-family: var(--font-body);
  font-size: 0.9375rem;
  font-weight: 500;
  border: none;
  border-radius: var(--border-radius-sm);
  transition: background 0.15s ease;
  cursor: pointer;
}

.btn-primary:hover {
  background: var(--accent-hover);
}

.btn-ghost {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-body);
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--text-2);
  padding: 15px var(--s-24);
  min-height: 48px;
  background: none;
  border: none;
  cursor: pointer;
  transition: color 0.15s ease;
}

.btn-ghost:hover {
  color: var(--text);
}

.btn-text {
  display: inline-flex;
  align-items: center;
  color: var(--accent);
  font-weight: 500;
  font-size: 0.9375rem;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  transition: color 0.15s ease;
}

.btn-text::after {
  content: '\2192';
  margin-left: 6px;
  display: inline-block;
  transition: transform 0.2s ease;
}

.btn-text:hover {
  color: var(--accent-hover);
}

.btn-text:hover::after {
  transform: translateX(4px);
}


/* ============================================
   Feature Rows — alternating image+text
   ============================================ */
.feature-row {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: clamp(32px, 6vw, 80px);
  align-items: center;
}

.feature-row--reverse {
  grid-template-columns: 1fr 1.15fr;
}

.feature-row--reverse .feature-media {
  order: 1;
}

.feature-media {
  border-radius: var(--border-radius-md);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: 0 8px 32px -8px rgba(26, 26, 24, 0.08);
}

.feature-media img {
  width: 100%;
  display: block;
}

.feature-label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: var(--s-12);
}

.feature-content h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.3;
  margin-bottom: var(--s-16);
}

.feature-content p {
  color: var(--text-2);
  font-size: 1rem;
  line-height: 1.8;
  margin-bottom: var(--s-24);
  max-width: 480px;
}

/* Feature Tags — pill-shaped highlights */
.feature-tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-8);
  list-style: none;
  margin-bottom: var(--s-24);
}

.feature-tags li {
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text-2);
  padding: 6px 14px;
  border: 1px solid var(--border);
  border-radius: 100px;
  white-space: nowrap;
  line-height: 1.4;
}


/* ============================================
   Hero Screenshot (product subpages)
   ============================================ */
.hero-screenshot {
  max-width: 1200px;
  margin: clamp(40px, 6vw, 72px) auto 0;
  padding: 0 clamp(16px, 3vw, 32px);
}

.hero-screenshot img {
  width: 100%;
  display: block;
  border-radius: var(--border-radius-md);
  border: 1px solid var(--border);
  box-shadow:
    0 4px 8px -2px rgba(26, 26, 24, 0.05),
    0 24px 64px -16px rgba(26, 26, 24, 0.14);
}


/* ============================================
   Value Section (Why / 3-column reasoning)
   ============================================ */
.value-section {
  margin-bottom: clamp(40px, 6vw, 64px);
}

.value-title {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.3;
  margin-bottom: var(--s-16);
}

.value-subtitle {
  color: var(--text-2);
  font-size: 1rem;
  line-height: 1.8;
  max-width: 640px;
}

.value-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(24px, 4vw, 48px);
}

/* Value item card */
.value-item {
  padding: var(--s-32);
  background: var(--bg-surface);
  border-radius: var(--border-radius-md);
}

.sub-section--surface .value-item {
  background: var(--bg);
}

/* Row 1: icon + number inline, fixed height */
.value-item-header {
  display: flex;
  align-items: center;
  gap: var(--s-12);
  margin-bottom: var(--s-16);
}

.value-icon {
  width: 44px;
  height: 44px;
  padding: 9px;
  flex-shrink: 0;
  background: var(--page-accent-light, var(--accent-light));
  color: var(--page-accent, var(--accent));
  border-radius: 10px;
  display: block;
}

.value-number {
  font-family: var(--font-display);
  font-size: 0.75rem;
  color: var(--page-accent, var(--text-3));
  font-weight: 600;
  letter-spacing: 0.02em;
  line-height: 1;
}

.value-item h3 {
  font-size: 1.0625rem;
  font-weight: 600;
  line-height: 1.4;
  margin-bottom: var(--s-8);
}

.value-item p {
  color: var(--text-2);
  font-size: 0.9375rem;
  line-height: 1.7;
}


/* ============================================
   Compact Feature Grid (text-only, no cards)
   ============================================ */
.tile-title {
  font-size: clamp(1.25rem, 2.5vw, 1.5rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: clamp(32px, 5vw, 48px);
}

.compact-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(24px, 4vw, 48px) clamp(32px, 5vw, 64px);
}

.compact-item h3 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: var(--s-8);
  line-height: 1.4;
}

.compact-item p {
  color: var(--text-2);
  font-size: 0.875rem;
  line-height: 1.7;
}


/* ============================================
   Function Grid — thumb + description cards
   ============================================ */
.func-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(16px, 3vw, 24px);
}

.func-card {
  display: flex;
  flex-direction: column;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--border-radius-md);
  overflow: hidden;
  cursor: pointer;
  text-align: left;
  font: inherit;
  color: inherit;
  padding: 0;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

.func-card:hover {
  border-color: var(--page-accent, var(--border));
  box-shadow: 0 8px 24px -8px rgba(26, 26, 24, 0.08);
}

.func-thumb {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border);
}

.func-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top left;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.func-card:hover .func-thumb img {
  transform: scale(1.03);
}

.func-body {
  padding: var(--s-24);
}

.func-body h3 {
  font-size: 0.9375rem;
  font-weight: 600;
  margin-bottom: var(--s-4);
  line-height: 1.4;
}

.func-body p {
  color: var(--text-2);
  font-size: 0.8125rem;
  line-height: 1.6;
}


/* ============================================
   Lightbox
   ============================================ */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(26, 26, 24, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: clamp(16px, 4vw, 48px);
  cursor: zoom-out;
}

.lightbox[hidden] {
  display: none;
}

.lightbox-img {
  max-width: 100%;
  max-height: 90vh;
  border-radius: var(--border-radius-sm);
  box-shadow: 0 24px 80px -20px rgba(0, 0, 0, 0.4);
  cursor: default;
}

.lightbox-close {
  position: absolute;
  top: clamp(12px, 2vw, 24px);
  right: clamp(12px, 2vw, 24px);
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.7);
  font-size: 1.75rem;
  cursor: pointer;
  border-radius: 50%;
  transition: color 0.15s ease, background 0.15s ease;
}

.lightbox-close:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
}


/* ============================================
   Clients
   ============================================ */
.clients-label {
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text-3);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-align: center;
  margin-bottom: var(--s-24);
}

.clients-list {
  display: flex;
  justify-content: center;
  gap: clamp(16px, 3vw, 40px);
  flex-wrap: wrap;
  font-size: 0.9375rem;
  color: var(--text-3);
  font-weight: 500;
}

/* Logo-based client list */
.clients-logos {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: clamp(32px, 5vw, 64px);
  flex-wrap: nowrap;
}

.clients-logos img {
  height: 28px;
  width: auto;
  object-fit: contain;
  filter: grayscale(1);
  opacity: 0.45;
  transition: filter 0.3s ease, opacity 0.3s ease;
}

.clients-logos img:hover {
  filter: grayscale(0);
  opacity: 1;
}


/* ============================================
   Dark tile centered variant & AI body
   ============================================ */
.tile--centered {
  text-align: center;
}

.ai-body {
  font-size: 1.0625rem;
  color: rgba(255, 255, 255, 0.5);
  line-height: 1.8;
  max-width: 520px;
  margin: 0 auto var(--s-32);
}

.btn-outline-light {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 28px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 100px;
  color: rgba(255, 255, 255, 0.75);
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 500;
  background: none;
  cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease;
  min-height: 44px;
}

.btn-outline-light:hover {
  border-color: rgba(255, 255, 255, 0.4);
  color: #fff;
}


/* ============================================
   Section Label
   ============================================ */
.section-label {
  font-family: var(--font-body);
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text-3);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: var(--s-48);
  line-height: 1.5;
}


/* ============================================
   Page Accent Colors — per-product identity
   ============================================ */
.page-ctms {
  --page-accent:         #6B52AE;
  --page-accent-hover:   #5A449A;
  --page-accent-light:   rgba(107, 82, 174, 0.07);
  --page-accent-on-dark: #A694D8;
}

.page-epro {
  --page-accent:         #946B1E;
  --page-accent-hover:   #7D5A18;
  --page-accent-light:   rgba(148, 107, 30, 0.07);
  --page-accent-on-dark: #C4A050;
}

.page-specimen {
  --page-accent:         #9E3558;
  --page-accent-hover:   #872D4C;
  --page-accent-light:   rgba(158, 53, 88, 0.07);
  --page-accent-on-dark: #D06888;
}

/* Apply page accent to all point-color elements */
[class*="page-"] .sub-hero-label  { color: var(--page-accent); }
[class*="page-"] .feature-label   { color: var(--page-accent); }
[class*="page-"] .value-number    { color: var(--page-accent); }
[class*="page-"] .info-num        { color: var(--page-accent); }
[class*="page-"] .key-message     { border-bottom-color: var(--page-accent-light); }

[class*="page-"] .btn-primary     { background: var(--page-accent); }
[class*="page-"] .btn-primary:hover { background: var(--page-accent-hover); }

[class*="page-"] .btn-text        { color: var(--page-accent); }
[class*="page-"] .btn-text:hover  { color: var(--page-accent-hover); }

[class*="page-"] :focus-visible   { outline-color: var(--page-accent); }

/* Nav active & hover on subpages */
[class*="page-"] .nav-link.active {
  color: var(--page-accent);
}

[class*="page-"] .nav-link.active::after {
  background: var(--page-accent);
}

[class*="page-"] .nav-link:hover::after {
  background: var(--page-accent);
}

/* AI section on subpages */
[class*="page-"] .ai-overline       { color: var(--page-accent-on-dark); }
[class*="page-"] .ai-feature-label  { color: var(--page-accent-on-dark); }
[class*="page-"] .btn-outline-light:hover {
  border-color: var(--page-accent-on-dark);
  color: var(--page-accent-on-dark);
}


/* ============================================
   Subpage Layout
   Distinct from main: left-aligned hero,
   full-width sections (not floating tiles),
   denser content spacing.
   ============================================ */

/* Sub Hero — compact, left-aligned, surface bg */
.sub-hero {
  padding: calc(var(--nav-h) + clamp(48px, 8vw, 80px)) 0 clamp(48px, 8vw, 80px);
  background: var(--bg-surface);
  position: relative;
  overflow: hidden;
  z-index: 0;
}

/* Background image variant */
.sub-hero--bg::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--sub-hero-bg) center / cover no-repeat;
  opacity: 0.09;
  z-index: -1;
  pointer-events: none;
}

.sub-hero-label {
  display: inline-block;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: var(--s-16);
}

.sub-hero-title {
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.2;
  margin-bottom: var(--s-16);
  max-width: 680px;
}

.sub-hero-desc {
  font-size: 1.0625rem;
  color: var(--text-2);
  line-height: 1.8;
  max-width: 560px;
  margin-bottom: var(--s-32);
}

.sub-hero-actions {
  display: flex;
  gap: var(--s-16);
  align-items: center;
}

/* Sub Sections — full-width backgrounds */
.sub-section {
  padding: clamp(64px, 10vw, 120px) 0;
}

.sub-section--surface {
  background: var(--bg-surface);
}

.sub-section--dark {
  background:
    radial-gradient(ellipse at 50% 0%, rgba(179, 74, 36, 0.06) 0%, transparent 50%),
    var(--text);
  color: var(--bg);
}

.sub-section--dark-inner {
  text-align: center;
  max-width: 640px;
  margin: 0 auto;
}

.sub-dark-title {
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  font-weight: 700;
  color: var(--bg);
  letter-spacing: -0.025em;
  margin-bottom: var(--s-16);
  line-height: 1.25;
}

.sub-dark-desc {
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.5);
  line-height: 1.8;
  margin-bottom: var(--s-32);
}

.sub-section-title {
  font-size: clamp(1.375rem, 3vw, 1.75rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.3;
  margin-bottom: var(--s-16);
}

.sub-section-desc {
  color: var(--text-2);
  font-size: 1rem;
  line-height: 1.8;
  max-width: 720px;
  margin-bottom: clamp(40px, 6vw, 64px);
}

/* Key Message — bold statement with underline */
.key-message {
  font-size: clamp(1.0625rem, 2vw, 1.1875rem);
  font-weight: 600;
  color: var(--text);
  line-height: 1.6;
  padding-bottom: var(--s-24);
  border-bottom: 1px solid var(--border);
  margin-bottom: clamp(40px, 6vw, 56px);
}

/* Info Table — clean row-based data */
.info-table {
  border-top: 1px solid var(--border);
  margin-top: clamp(40px, 6vw, 64px);
}

.info-row {
  display: grid;
  grid-template-columns: 40px 180px 1fr;
  gap: var(--s-16);
  padding: var(--s-16) 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.9375rem;
  align-items: baseline;
}

.info-num {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--accent);
  font-size: 0.875rem;
}

.info-title {
  font-weight: 600;
  color: var(--text);
}

.info-desc {
  color: var(--text-2);
}

/* Sub CTA */
.sub-cta {
  text-align: center;
}


/* ============================================
   AI Section — dark tile with impact
   ============================================ */
.tile--dark {
  background:
    radial-gradient(ellipse at 50% 0%, rgba(179, 74, 36, 0.06) 0%, transparent 50%),
    var(--text);
  color: var(--bg);
}

/* Hero area */
.ai-hero {
  text-align: center;
  padding-bottom: clamp(40px, 6vw, 64px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  margin-bottom: clamp(40px, 6vw, 64px);
  position: relative;
}

.ai-overline {
  font-size: 0.75rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.35);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: var(--s-16);
}

.ai-title {
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  font-weight: 700;
  color: var(--bg);
  letter-spacing: -0.03em;
  line-height: 1.2;
}

.ai-year {
  position: absolute;
  right: 0;
  bottom: clamp(20px, 3vw, 40px);
  font-family: var(--font-display);
  font-size: clamp(5rem, 15vw, 11rem);
  font-weight: 600;
  color: rgba(255, 255, 255, 0.03);
  line-height: 0.8;
  letter-spacing: -0.04em;
  user-select: none;
  pointer-events: none;
}

/* Feature columns */
.ai-features {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(24px, 4vw, 48px);
}

.ai-feature-label {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  color: #D4734E;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: var(--s-12);
}

.ai-feature h3 {
  font-size: 1.125rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.92);
  letter-spacing: -0.01em;
  margin-bottom: var(--s-8);
  line-height: 1.35;
}

.ai-feature p {
  color: rgba(255, 255, 255, 0.45);
  font-size: 0.875rem;
  line-height: 1.7;
}


/* ============================================
   Legacy: Roadmap (for subpages if needed)
   ============================================ */
.roadmap-list {
  display: flex;
  flex-direction: column;
}

.roadmap-row {
  display: grid;
  grid-template-columns: 84px 1fr auto;
  gap: var(--s-24);
  padding: var(--s-16) 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.9375rem;
  align-items: baseline;
}

.roadmap-product { font-weight: 600; color: var(--text); }
.roadmap-feature { color: var(--text-2); }
.roadmap-date { color: var(--text-3); font-size: 0.8125rem; text-align: right; white-space: nowrap; }


/* ============================================
   CTA Section
   ============================================ */
.cta-section {
  text-align: center;
}

.cta-title {
  font-size: clamp(1.375rem, 3vw, 1.75rem);
  font-weight: 700;
  letter-spacing: -0.025em;
  margin-bottom: var(--s-12);
  line-height: 1.35;
}

.cta-desc {
  color: var(--text-2);
  font-size: 0.9375rem;
  margin-bottom: var(--s-32);
  line-height: 1.75;
}


/* ============================================
   Footer
   ============================================ */
footer {
  background: #252525;
  padding: var(--s-32) 0;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8125rem;
  color: #888;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: var(--s-12);
}

.footer-links {
  display: flex;
  gap: var(--s-24);
}

.footer-links a {
  color: #888;
  transition: color 0.15s ease;
}

.footer-links a:hover {
  color: #ccc;
}


/* ============================================
   Entrance Animations
   ============================================ */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-in {
  opacity: 0;
  animation: fadeUp 0.7s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.delay-1 { animation-delay: 0.1s; }
.delay-2 { animation-delay: 0.2s; }
.delay-3 { animation-delay: 0.3s; }
.delay-4 { animation-delay: 0.4s; }

/* Scroll reveal */
[data-reveal] {
  opacity: 0;
  transform: translateY(16px);
  transition:
    opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

[data-reveal].revealed {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger children */
[data-reveal-stagger] > * {
  opacity: 0;
  transform: translateY(12px);
  transition:
    opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

[data-reveal-stagger].revealed > * {
  opacity: 1;
  transform: translateY(0);
}

[data-reveal-stagger].revealed > *:nth-child(1) { transition-delay: 0s; }
[data-reveal-stagger].revealed > *:nth-child(2) { transition-delay: 0.08s; }
[data-reveal-stagger].revealed > *:nth-child(3) { transition-delay: 0.16s; }
[data-reveal-stagger].revealed > *:nth-child(4) { transition-delay: 0.24s; }


/* ============================================
   Reduced Motion
   ============================================ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-delay: 0ms !important;
    transition-duration: 0.01ms !important;
  }
}


/* ============================================
   LEGACY COMPONENTS
   (backward-compat for ctms, epro, specimen, contact)
   Remove sections as each page is redesigned.
   ============================================ */

/* Legacy: Nav (old class name compat) */
.navbar .nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: var(--nav-h);
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 clamp(20px, 5vw, 40px);
}

/* Legacy: Section backgrounds */
.section-bg-secondary { background-color: var(--bg-surface); }
.section-bg-sepia     { background-color: var(--bg-sepia); }

.section-bg-dark {
  background-color: var(--bg-dark);
  color: var(--text-inverse);
}

.section-bg-dark h1,
.section-bg-dark h2,
.section-bg-dark h3,
.section-bg-dark p {
  color: var(--text-inverse);
}

/* Legacy: Grids */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s-32);
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--s-32);
}

/* Legacy: Cards */
.card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--border-radius-md);
  padding: var(--s-32);
  transition: var(--transition-smooth);
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}

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

.card h3 {
  font-size: 1.5rem;
  margin-bottom: var(--s-8);
}

.card p {
  color: var(--text-2);
  flex-grow: 1;
  margin-bottom: var(--s-32);
}

/* Legacy: Badges & Tags */
.tags-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: var(--s-32);
}

.tag {
  background: var(--bg-surface);
  color: var(--text-2);
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 0.85rem;
  font-weight: 500;
  border: 1px solid var(--border);
}

.badge {
  display: inline-block;
  background: var(--accent-light);
  color: var(--accent);
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: var(--s-16);
}

.card-cta {
  display: inline-flex;
  align-items: center;
  font-weight: 600;
  color: var(--text);
  transition: color 0.2s ease;
}

.card-cta::after {
  content: '\2192';
  margin-left: 6px;
  transition: transform 0.2s ease;
}

.card:hover .card-cta { color: var(--accent); }
.card:hover .card-cta::after { transform: translateX(4px); }

/* Legacy: Buttons (old markup compat) */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  border-radius: var(--border-radius-sm);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: var(--transition-smooth);
  border: none;
}

.btn.btn-primary {
  background-color: var(--accent);
  color: var(--text-inverse);
}

.btn.btn-primary:hover {
  background-color: var(--accent-hover);
}

.btn-secondary {
  background-color: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  border-color: var(--text);
  background-color: var(--bg-surface);
}

/* Legacy: AI Table */
.ai-banner-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: var(--s-32);
}

.ai-banner-table th,
.ai-banner-table td {
  padding: 16px;
  text-align: left;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.ai-banner-table th {
  color: #A0A0A0;
  font-weight: 500;
}

.ai-banner-table td {
  color: var(--text-inverse);
}

.link-accent {
  color: var(--accent);
  font-weight: 500;
}

.link-accent:hover {
  text-decoration: underline;
}

/* Legacy: Highlight / Answer Table / Value / Timeline (used on subpages) */
.highlight-box {
  background: var(--accent-light);
  border: 1px solid var(--accent);
  border-radius: var(--border-radius-md);
  padding: var(--s-24);
  margin-bottom: var(--s-32);
}

.answer-table {
  width: 100%;
  border-collapse: collapse;
}

.answer-table td {
  padding: var(--s-16) var(--s-24);
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}

/* Legacy: Form */
.form-group {
  margin-bottom: var(--s-16);
  text-align: left;
}

.form-label {
  display: block;
  font-weight: 500;
  margin-bottom: var(--s-8);
}

.form-control {
  width: 100%;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--border-radius-sm);
  font: inherit;
  font-size: 1rem;
  background: var(--bg);
  color: var(--text);
  transition: border-color 0.15s ease;
}

.form-control:focus {
  outline: none;
  border-color: var(--accent);
}

.checkbox-group {
  display: flex;
  gap: var(--s-16);
  flex-wrap: wrap;
}

/* Legacy: Hero actions */
.hero-actions {
  display: flex;
  gap: var(--s-16);
  justify-content: center;
}

/* Legacy: Footer (multi-row layout on subpages) */
.footer-inner:has(.footer-top) {
  flex-direction: column;
  align-items: stretch;
  gap: var(--s-32);
}

.footer-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: #ccc;
}

.footer-nav {
  display: flex;
  gap: var(--s-16);
}

.footer-nav a {
  color: #aaa;
  font-size: 0.9rem;
  transition: color 0.15s ease;
}

.footer-nav a:hover {
  color: #fff;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: #888;
  font-size: 0.85rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: var(--s-32);
}

.footer-legal a {
  color: #888;
  margin-left: var(--s-16);
  transition: color 0.15s ease;
}

.footer-legal a:hover {
  color: #ccc;
}

/* Legacy: Utilities */
.text-center { text-align: center; }
.mb-xs { margin-bottom: var(--s-8); }
.mb-sm { margin-bottom: var(--s-16); }
.mb-md { margin-bottom: var(--s-32); }
.mb-lg { margin-bottom: var(--s-64); }
.mb-xl { margin-bottom: 120px; }


/* ============================================
   Responsive
   ============================================ */
@media (max-width: 768px) {
  /* Navigation */
  .menu-toggle {
    display: flex;
  }

  .nav-links {
    display: none;
    flex-direction: column;
    position: absolute;
    top: var(--nav-h);
    left: 0;
    right: 0;
    background: var(--bg-nav-solid);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: var(--s-24) clamp(20px, 5vw, 40px);
    gap: var(--s-16);
    border-bottom: 1px solid var(--border);
  }

  .nav-links.open {
    display: flex;
  }

  .nav-link::after {
    display: none;
  }

  .nav-link {
    font-size: 1rem;
    padding: var(--s-8) 0;
  }

  .nav-divider {
    width: 100%;
    height: 1px;
  }

  .nav-cta {
    text-align: center;
    padding: var(--s-12) var(--s-24);
    font-size: 0.875rem;
  }

  .navbar.scrolled .nav-inner {
    height: var(--nav-h);
  }

  /* Hero */
  .hero-actions {
    flex-direction: column;
    gap: var(--s-8);
  }

  .hero-slideshow {
    padding: 0 clamp(12px, 4vw, 20px);
  }

  .slideshow-indicators {
    gap: var(--s-4);
  }

  .indicator {
    font-size: 0.6875rem;
    padding: var(--s-8) var(--s-12);
  }

  /* Tiles */
  .tile {
    padding: clamp(32px, 6vw, 48px) clamp(20px, 5vw, 32px);
    border-radius: var(--border-radius-md);
  }

  /* Feature Rows */
  .feature-row,
  .feature-row--reverse {
    grid-template-columns: 1fr;
    gap: var(--s-32);
  }

  .feature-row--reverse .feature-media {
    order: 0;
  }

  .feature-content h2 {
    font-size: 1.5rem;
  }

  .feature-content h2 br {
    display: none;
  }

  /* AI Section */
  .ai-year {
    position: static;
    display: block;
    font-size: 4rem;
    color: rgba(255, 255, 255, 0.05);
    text-align: center;
    margin-top: var(--s-16);
  }

  .ai-title br {
    display: none;
  }

  .ai-features {
    grid-template-columns: 1fr;
    gap: var(--s-32);
  }

  .ai-body br {
    display: none;
  }

  /* Value grid */
  .value-grid {
    grid-template-columns: 1fr;
    gap: var(--s-32);
  }

  .value-title br {
    display: none;
  }

  /* Compact feature grid */
  .compact-grid {
    grid-template-columns: 1fr;
    gap: var(--s-32);
  }

  /* Function grid */
  .func-grid {
    grid-template-columns: 1fr;
    gap: var(--s-16);
  }

  /* Clients */
  .clients-list {
    flex-direction: column;
    align-items: center;
    gap: var(--s-12);
  }

  .clients-logos {
    flex-wrap: wrap;
    gap: clamp(20px, 4vw, 32px);
  }

  .clients-logos img {
    height: 22px;
  }

  /* Subpage */
  .sub-hero-title br {
    display: none;
  }

  .sub-hero-actions {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--s-8);
  }

  .info-row {
    grid-template-columns: 1fr;
    gap: var(--s-4);
  }

  .info-num {
    display: none;
  }

  .sub-dark-title br {
    display: none;
  }

  /* Legacy: Roadmap */
  .roadmap-row {
    grid-template-columns: 1fr;
    gap: var(--s-4);
    padding: var(--s-16) 0;
  }

  .roadmap-date {
    text-align: left;
  }

  /* Footer — ensure touch targets */
  .footer-inner {
    flex-direction: column;
    gap: var(--s-16);
    text-align: center;
  }

  .footer-links a {
    display: inline-block;
    padding: var(--s-8) var(--s-4);
    min-height: 44px;
    line-height: 28px;
  }

  /* Legacy */
  .grid-3,
  .grid-2 {
    grid-template-columns: 1fr;
  }

  .footer-top {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--s-32);
  }

  .hero-actions {
    flex-direction: column;
  }

  .footer-bottom {
    flex-direction: column;
    gap: var(--s-8);
    text-align: center;
  }

  .footer-legal a:first-child {
    margin-left: 0;
  }
}
