/* ==========================================================================
   CAST Corp · Static EDA Marketing Website Stylesheet
   Brand Palette: Ink Navy (#142338), Cobalt (#3156C9), Amber (#C98528),
                  Technical Mist (#EEF2F6), Slate (#64748B), White (#FFFFFF)
   Design Intent: Deep semiconductor atmosphere, rich color contrast,
                  authentic engineering precision, zero flat AI template feel.
   ========================================================================== */

/* --- Font Definitions (Self-hosted IBM Plex WOFF2) --- */
@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("assets/fonts/ibm-plex-sans-400.woff2") format("woff2");
}

@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("assets/fonts/ibm-plex-sans-500.woff2") format("woff2");
}

@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("assets/fonts/ibm-plex-sans-600.woff2") format("woff2");
}

@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("assets/fonts/ibm-plex-sans-700.woff2") format("woff2");
}

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

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

/* --- Design Tokens --- */
:root {
  /* Brand Core Palette */
  --ink: #142338;
  --ink-deep: #09121D;
  --ink-dark: #0D1826;
  --ink-surface: #122135;
  --ink-border: #223754;
  --ink-light: #1E314B;

  --cobalt: #3156C9;
  --cobalt-vibrant: #2950D4;
  --cobalt-bright: #3B82F6;
  --cobalt-light: #60A5FA;
  --cobalt-hover: #1F3FAD;
  --cobalt-subtle: #EEF3FD;
  --cobalt-border: #BACBF8;

  --amber: #C98528;
  --amber-bright: #F59E0B;
  --amber-dark: #A56814;
  --amber-subtle: #FFF9F0;
  --amber-border: #F7DFC0;

  --mint: #10B981;
  --mint-light: #34D399;
  --cyan: #0EA5E9;
  --cyan-light: #38BDF8;

  --mist: #EEF2F6;
  --mist-dark: #E2E8F0;
  --slate: #64748B;
  --slate-dark: #334155;
  --slate-light: #94A3B8;
  --white: #FFFFFF;
  --line: #DCE3EA;
  --line-strong: #CBD5E1;

  /* Typography */
  --font-sans: "IBM Plex Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-mono: "IBM Plex Mono", Consolas, "Liberation Mono", Menlo, monospace;

  /* Layout & Rhythm */
  --site-max-width: 1240px;
  --header-height: 74px;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 22px;
  --transition-fast: 150ms cubic-bezier(0.2, 0, 0, 1);
  --transition-base: 240ms cubic-bezier(0.2, 0, 0, 1);

  /* Shadows with Brand Depth */
  --shadow-sm: 0 2px 6px rgba(20, 35, 56, 0.05);
  --shadow-md: 0 10px 28px -4px rgba(20, 35, 56, 0.10);
  --shadow-lg: 0 22px 50px -10px rgba(10, 20, 35, 0.16);
  --shadow-glow-blue: 0 0 25px rgba(49, 86, 201, 0.35);
  --shadow-glow-amber: 0 0 20px rgba(201, 133, 40, 0.30);
}

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

html {
  font-size: 16px;
  line-height: 1.55;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-height) + 24px);
  background-color: var(--white);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-sans);
  background-color: var(--white);
  color: var(--ink);
  overflow-x: hidden;
}

/* Focus Rings */
:focus-visible {
  outline: 2px solid var(--cobalt-bright);
  outline-offset: 3px;
  border-radius: 4px;
}

/* Skip Navigation */
.skip-link {
  position: absolute;
  top: -100px;
  left: 20px;
  background: var(--ink-dark);
  color: var(--white);
  padding: 12px 18px;
  z-index: 9999;
  font-weight: 600;
  text-decoration: none;
  border-radius: 0 0 var(--radius-sm) var(--radius-sm);
  transition: top var(--transition-fast);
}

.skip-link:focus {
  top: 0;
}

/* Main Container */
.container {
  width: 100%;
  max-width: var(--site-max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: clamp(20px, 4vw, 42px);
  padding-right: clamp(20px, 4vw, 42px);
}

/* --- Typography Helpers --- */
h1, h2, h3, h4 {
  color: var(--ink);
  font-weight: 700;
  letter-spacing: -0.038em;
  line-height: 1.15;
}

p {
  color: var(--slate-dark);
  font-size: 1.05rem;
  line-height: 1.65;
}

.mono {
  font-family: var(--font-mono);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--cobalt);
  margin-bottom: 12px;
}

.eyebrow-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  background-color: var(--amber);
  border-radius: 2px;
}

.eyebrow-hero {
  color: #93C5FD;
}

.eyebrow-hero .eyebrow-dot {
  background-color: #F59E0B;
  box-shadow: 0 0 8px #F59E0B;
}

.eyebrow-dark {
  color: #93C5FD;
}

.eyebrow-dark .eyebrow-dot {
  background-color: #F59E0B;
}

.lead {
  font-size: clamp(1.12rem, 1.8vw, 1.28rem);
  line-height: 1.6;
  color: var(--slate-dark);
  max-width: 740px;
}

/* --- Buttons & Touch Targets --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  padding: 13px 24px;
  min-height: 48px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  cursor: pointer;
  border: 1.5px solid transparent;
  transition: all var(--transition-fast);
  white-space: nowrap;
}

.btn-primary {
  background: linear-gradient(135deg, var(--cobalt-vibrant) 0%, var(--cobalt) 100%);
  color: var(--white);
  border-color: var(--cobalt-vibrant);
  box-shadow: 0 4px 16px rgba(49, 86, 201, 0.35);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #3B66E8 0%, var(--cobalt-vibrant) 100%);
  border-color: #3B66E8;
  color: var(--white);
  transform: translateY(-1px);
  box-shadow: var(--shadow-glow-blue);
}

.btn-glow {
  position: relative;
  overflow: hidden;
}

.btn-glow::after {
  content: "";
  position: absolute;
  top: 0; left: -100%; width: 100%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
  transition: left 0.6s ease;
}

.btn-glow:hover::after {
  left: 100%;
}

.btn-secondary {
  background-color: var(--white);
  color: var(--ink);
  border-color: var(--line-strong);
}

.btn-secondary:hover {
  background-color: var(--mist);
  border-color: #94A3B8;
  color: var(--ink);
  transform: translateY(-1px);
}

.btn-secondary-dark {
  background-color: rgba(255, 255, 255, 0.08);
  color: #E2E8F0;
  border-color: rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(8px);
}

.btn-secondary-dark:hover {
  background-color: rgba(255, 255, 255, 0.16);
  border-color: #93C5FD;
  color: var(--white);
  transform: translateY(-1px);
}

/* --- Badges / Chips --- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  font-family: var(--font-mono);
  font-size: 0.74rem;
  font-weight: 600;
  border-radius: 999px;
  border: 1px solid var(--line);
  background-color: var(--white);
  color: var(--slate-dark);
}

.badge-cobalt {
  background-color: var(--cobalt-subtle);
  border-color: var(--cobalt-border);
  color: var(--cobalt);
}

.badge-amber {
  background-color: var(--amber-subtle);
  border-color: var(--amber-border);
  color: var(--amber-dark);
}

.badge-legacy {
  background: #FEE2E2;
  border-color: #FCA5A5;
  color: #B91C1C;
}

.badge-cast-pro {
  background: #EFF6FF;
  border-color: #BFDBFE;
  color: #1D4ED8;
}

/* --- Section Structure --- */
section {
  padding: clamp(68px, 8vw, 112px) 0;
  position: relative;
}

.section-alt {
  background-color: #F4F7FB;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.section-header {
  margin-bottom: clamp(38px, 5vw, 56px);
}

.section-title {
  font-size: clamp(2rem, 3.4vw, 2.9rem);
  margin-bottom: 16px;
  color: var(--ink);
}

.title-highlight {
  color: var(--cobalt);
}

.section-desc {
  max-width: 740px;
}

/* ==========================================================================
   Header & Navigation
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background-color: rgba(9, 18, 29, 0.95);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(49, 86, 201, 0.28);
  height: var(--header-height);
  display: flex;
  align-items: center;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--white);
}

.brand-symbol {
  width: 38px;
  height: 38px;
  border: 1.5px solid #38BDF8;
  border-radius: 9px;
  display: grid;
  place-items: center;
  background: #112035;
  color: #38BDF8;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 1.25rem;
  line-height: 1;
  box-shadow: 0 0 10px rgba(56, 189, 248, 0.25);
  transition: all var(--transition-fast);
}

.brand:hover .brand-symbol {
  background-color: var(--cobalt);
  border-color: #93C5FD;
  color: var(--white);
  box-shadow: 0 0 16px rgba(49, 86, 201, 0.5);
}

.brand-title-group {
  display: flex;
  flex-direction: column;
}

.brand-name {
  font-size: 1.22rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  color: var(--white);
  line-height: 1;
}

.brand-name-sub {
  font-weight: 500;
  font-size: 0.8em;
  color: #94A3B8;
}

.brand-name-white {
  color: var(--white);
}

.brand-tag {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #60A5FA;
  margin-top: 3px;
}

.nav-desktop {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-link {
  font-size: 0.94rem;
  font-weight: 500;
  color: #CBD5E1;
  text-decoration: none;
  padding: 8px 0;
  position: relative;
  transition: color var(--transition-fast);
}

.nav-link:hover {
  color: #60A5FA;
}

.nav-link::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: #38BDF8;
  box-shadow: 0 0 8px #38BDF8;
  transition: width var(--transition-fast);
}

.nav-link:hover::after {
  width: 100%;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.nav-toggle {
  display: none;
  background: rgba(255, 255, 255, 0.08);
  border: 1.5px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-sm);
  width: 46px;
  height: 46px;
  padding: 11px;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  color: var(--white);
}

.nav-toggle-icon {
  display: block;
  width: 22px;
  height: 2px;
  background-color: var(--white);
  position: relative;
  transition: background-color var(--transition-fast);
}

.nav-toggle-icon::before,
.nav-toggle-icon::after {
  content: "";
  position: absolute;
  width: 22px;
  height: 2px;
  background-color: var(--white);
  left: 0;
  transition: transform var(--transition-fast), top var(--transition-fast);
}

.nav-toggle-icon::before { top: -7px; }
.nav-toggle-icon::after { top: 7px; }

.nav-toggle[aria-expanded="true"] .nav-toggle-icon {
  background-color: transparent;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-icon::before {
  top: 0;
  transform: rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle-icon::after {
  top: 0;
  transform: rotate(-45deg);
}

.mobile-nav-drawer {
  position: fixed;
  top: var(--header-height);
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--ink-dark);
  border-bottom: 1px solid var(--ink-border);
  padding: 24px;
  display: none;
  flex-direction: column;
  gap: 18px;
  overflow-y: auto;
  z-index: 999;
}

.mobile-nav-drawer.is-open {
  display: flex;
}

.mobile-nav-link {
  font-size: 1.2rem;
  font-weight: 600;
  color: #E2E8F0;
  text-decoration: none;
  padding: 14px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

/* ==========================================================================
   Hero Section: Deep Semiconductor Atmosphere
   ========================================================================== */
.hero-deep-tech {
  background:
    radial-gradient(circle at 82% 18%, rgba(49, 86, 201, 0.32) 0%, transparent 55%),
    radial-gradient(circle at 18% 82%, rgba(201, 133, 40, 0.14) 0%, transparent 45%),
    linear-gradient(180deg, #09121D 0%, #101F34 50%, #152640 100%);
  color: var(--white);
  padding-top: clamp(48px, 6.5vw, 84px);
  padding-bottom: clamp(72px, 9vw, 116px);
  overflow: hidden;
  position: relative;
}

.hero-tech-grid-overlay {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background-image:
    linear-gradient(rgba(56, 189, 248, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(56, 189, 248, 0.08) 1px, transparent 1px);
  background-size: 36px 36px;
  pointer-events: none;
}

.hero-container {
  position: relative;
  z-index: 2;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(36px, 5vw, 64px);
  align-items: center;
}

.hero-headline {
  font-size: clamp(2.6rem, 4.6vw, 4.2rem);
  line-height: 1.04;
  letter-spacing: -0.048em;
  margin: 18px 0 22px;
  color: var(--white);
}

.hero-gradient-text {
  background: linear-gradient(135deg, #60A5FA 0%, #38BDF8 50%, #93C5FD 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
}

.hero-lead {
  font-size: clamp(1.12rem, 1.8vw, 1.28rem);
  line-height: 1.6;
  color: #C2D0E2;
  max-width: 600px;
}

.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 36px;
  align-items: center;
}

.hero-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 38px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.hero-meta-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  font-weight: 500;
  color: #CBD5E1;
  background: rgba(255, 255, 255, 0.06);
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

/* Hero Technical Console Frame */
.hero-console-frame {
  background: #0B1524;
  border: 2px solid #233D66;
  border-radius: var(--radius-xl);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5), 0 0 30px rgba(49, 86, 201, 0.25);
  overflow: hidden;
  position: relative;
}

.console-top-bar {
  background: #111E33;
  border-bottom: 1px solid #223A60;
  padding: 12px 18px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}

.console-dots {
  display: flex;
  gap: 6px;
}

.dot-red { width: 9px; height: 9px; border-radius: 50%; background: #EF4444; }
.dot-amber { width: 9px; height: 9px; border-radius: 50%; background: #F59E0B; }
.dot-green { width: 9px; height: 9px; border-radius: 50%; background: #10B981; }

.console-title {
  font-family: var(--font-mono);
  font-size: 0.76rem;
  color: #CBD5E1;
  letter-spacing: 0.04em;
}

.console-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 700;
  color: #34D399;
  background: #063222;
  border: 1px solid #10B981;
  padding: 3px 8px;
  border-radius: 999px;
}

.live-pulse {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #34D399;
  box-shadow: 0 0 8px #34D399;
}

.console-body {
  padding: 16px;
  background: #09121F;
}

.hero-diagram-svg {
  width: 100%;
  height: auto;
  display: block;
}

.console-footer-bar {
  background: #0E1A2C;
  border-top: 1px solid #1F3456;
  padding: 10px 18px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.74rem;
}

.console-tag {
  font-family: var(--font-mono);
  font-weight: 700;
  color: #60A5FA;
  letter-spacing: 0.06em;
}

.console-spec {
  color: #94A3B8;
}

/* ==========================================================================
   Executive KPI Command Strip (High-Color Saturated Tiles)
   ========================================================================== */
.kpi-strip-section {
  padding: 0;
  margin-top: -36px;
  margin-bottom: 48px;
  position: relative;
  z-index: 10;
}

.kpi-command-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  background: linear-gradient(135deg, #0F1D33 0%, #152A4A 50%, #0F1D33 100%);
  border: 2px solid #284A80;
  border-radius: var(--radius-lg);
  padding: 18px;
  box-shadow: 0 18px 45px rgba(9, 18, 29, 0.4), 0 0 20px rgba(49, 86, 201, 0.2);
}

.kpi-command-tile {
  background: #0B1524;
  border: 1px solid #1E375C;
  border-radius: var(--radius-md);
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  transition: transform var(--transition-fast), border-color var(--transition-fast);
}

.kpi-command-tile:hover {
  transform: translateY(-2px);
  border-color: #38BDF8;
}

.kpi-tile-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.kpi-tile-tag {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #94A3B8;
}

.kpi-tile-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
}

.tile-cyan .kpi-tile-dot { background: #38BDF8; box-shadow: 0 0 6px #38BDF8; }
.tile-mint .kpi-tile-dot { background: #34D399; box-shadow: 0 0 6px #34D399; }
.tile-amber .kpi-tile-dot { background: #F59E0B; box-shadow: 0 0 6px #F59E0B; }
.tile-blue .kpi-tile-dot { background: #60A5FA; box-shadow: 0 0 6px #60A5FA; }

.kpi-tile-num {
  font-family: var(--font-mono);
  font-size: 1.95rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: 6px;
}

.tile-cyan .kpi-tile-num { color: #38BDF8; }
.tile-mint .kpi-tile-num { color: #34D399; }
.tile-amber .kpi-tile-num { color: #F59E0B; }
.tile-blue .kpi-tile-num { color: #93C5FD; }

.kpi-tile-desc {
  font-size: 0.8rem;
  color: #CBD5E1;
  line-height: 1.35;
}

/* ==========================================================================
   The Challenge Section (Rich Cards with Colored Tops & Tags)
   ========================================================================== */
.section-bottleneck {
  background-color: #F1F5FA;
  background-image:
    linear-gradient(rgba(20, 35, 56, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(20, 35, 56, 0.03) 1px, transparent 1px);
  background-size: 28px 28px;
}

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

.problem-card {
  background: var(--white);
  border: 1.5px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 34px 28px;
  display: flex;
  flex-direction: column;
  position: relative;
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast), border-color var(--transition-fast);
}

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

.card-amber-top {
  border-top: 5px solid var(--amber);
}

.card-cobalt-top {
  border-top: 5px solid var(--cobalt);
}

.card-navy-top {
  border-top: 5px solid var(--ink);
}

.problem-card-badge-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.problem-code-badge {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--slate);
}

.severity-pill {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 4px;
}

.pill-amber { background: #FEF3C7; color: #92400E; }
.pill-blue { background: #DBEAFE; color: #1E40AF; }
.pill-navy { background: #E2E8F0; color: #1E293B; }
.pill-red { background: #FEE2E2; color: #991B1B; }

.problem-title {
  font-size: 1.35rem;
  margin-bottom: 12px;
  color: var(--ink);
}

.financial-impact-box {
  margin-top: auto;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  background: #F8FAFC;
  border-left: 3px solid #DC2626;
  font-size: 0.82rem;
  color: #991B1B;
  font-weight: 500;
  line-height: 1.45;
}

.problem-card-metric {
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  font-size: 0.85rem;
  color: #B91C1C;
  font-weight: 500;
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.metric-bullet {
  font-weight: 700;
  color: #EF4444;
}

/* ==========================================================================
   Perspectives Section: Balanced Dual High-Contrast Console
   ========================================================================== */
.section-perspectives {
  background-color: var(--white);
}

.perspectives-bridge-banner {
  background: linear-gradient(135deg, #0F1F35 0%, #173258 100%);
  border: 1.5px solid #284D82;
  border-radius: var(--radius-md);
  padding: 16px 24px;
  margin-bottom: 34px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  color: var(--white);
  box-shadow: 0 8px 24px rgba(15, 31, 53, 0.12);
}

.bridge-content {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

.bridge-tag {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  background: #3156C9;
  color: var(--white);
  padding: 4px 10px;
  border-radius: 4px;
  letter-spacing: 0.06em;
}

.bridge-text {
  font-size: 0.98rem;
  color: #F8FAFC;
}

.bridge-meta {
  font-size: 0.84rem;
  color: #93C5FD;
}

.perspectives-dual-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}

/* Left: Technical Perspective Card (High-Tech Cobalt Mist Surface) */
.perspective-card-tech {
  background: #F7FAFE;
  border: 2px solid var(--cobalt-border);
  border-radius: var(--radius-xl);
  padding: clamp(28px, 4vw, 42px);
  box-shadow: var(--shadow-md);
  display: flex;
  flex-direction: column;
  position: relative;
}

.perspective-card-tech::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 5px;
  background: var(--cobalt);
  border-radius: var(--radius-xl) var(--radius-xl) 0 0;
}

/* Right: Business Perspective Card (Deep Ink Navy & Amber Console) */
.perspective-card-biz {
  background: #0D192B;
  color: var(--white);
  border: 2px solid #223854;
  border-radius: var(--radius-xl);
  padding: clamp(28px, 4vw, 42px);
  box-shadow: var(--shadow-lg), 0 0 24px rgba(13, 25, 43, 0.4);
  display: flex;
  flex-direction: column;
  position: relative;
}

.perspective-card-biz::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 5px;
  background: linear-gradient(90deg, #F59E0B, #60A5FA);
  border-radius: var(--radius-xl) var(--radius-xl) 0 0;
}

.perspective-card-header {
  margin-bottom: 24px;
}

.perspective-badge-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}

.perspective-sub-id {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--cobalt);
}

.perspective-heading {
  font-size: 1.7rem;
  margin-bottom: 12px;
  color: var(--ink);
}

.perspective-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin: 28px 0;
}

.perspective-item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  font-size: 0.98rem;
  line-height: 1.55;
}

.perspective-icon-bullet {
  width: 26px;
  height: 26px;
  border-radius: 6px;
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 0.85rem;
  flex-shrink: 0;
  margin-top: 2px;
}

.bullet-tech {
  background: var(--cobalt-subtle);
  color: var(--cobalt);
  border: 1.5px solid var(--cobalt-border);
}

.bullet-biz {
  background: #182C48;
  color: #F59E0B;
  border: 1.5px solid #2D4C75;
}

.perspective-item-title {
  font-weight: 700;
  display: block;
  margin-bottom: 3px;
  color: var(--ink);
}

.perspective-footer-quote {
  margin-top: auto;
  padding: 18px 22px;
  border-radius: var(--radius-md);
}

.quote-tech {
  background: #EDF3FC;
  border-left: 4px solid var(--cobalt);
}

.quote-biz {
  background: #122137;
  border-left: 4px solid #F59E0B;
}

.quote-text {
  font-size: 0.92rem;
  font-style: italic;
  line-height: 1.5;
  color: var(--ink);
}

.quote-author {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-top: 8px;
  color: var(--cobalt);
}

/* ==========================================================================
   Technology Foundation: The Three Pillars
   ========================================================================== */
.section-pillars {
  background-color: #F0F4FA;
}

.pillars-editorial-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 28px;
}

.pillar-featured-card {
  background: var(--white);
  border: 2px solid var(--cobalt-border);
  border-radius: var(--radius-xl);
  padding: clamp(32px, 4vw, 48px);
  box-shadow: var(--shadow-md);
  display: flex;
  flex-direction: column;
}

.pillar-top-badge {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.pillar-tag {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--cobalt);
}

.pillar-title {
  font-size: 1.45rem;
  margin-bottom: 14px;
  color: var(--ink);
}

.math-terminal-box {
  background: #0B1524;
  border: 1.5px solid #1E375C;
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  margin: 22px 0;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.math-terminal-top {
  display: flex;
  justify-content: space-between;
  font-size: 0.74rem;
  padding-bottom: 10px;
  border-bottom: 1px solid #1C3354;
  margin-bottom: 12px;
}

.math-code {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  line-height: 1.65;
  color: #E2E8F0;
}

.code-comment {
  color: #64748B;
  font-style: italic;
}

.code-highlight {
  color: #38BDF8;
  font-weight: 600;
}

.pillar-stacked-col {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.pillar-compact-card {
  background: var(--white);
  border: 1.5px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  flex: 1;
}

.card-amber-edge {
  border-left: 5px solid var(--amber);
}

.card-cobalt-edge {
  border-left: 5px solid var(--cobalt);
}

.pdk-chips-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.pdk-chip {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 600;
  background: #EDF3FC;
  color: #1E3A8A;
  border: 1px solid #BFDBFE;
  padding: 4px 10px;
  border-radius: 4px;
}

.speed-bar-wrap {
  margin-top: 18px;
  background: #F8FAFC;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
}

.speed-bar-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 6px;
}

.speed-progress-bar {
  height: 8px;
  background: #E2E8F0;
  border-radius: 4px;
  overflow: hidden;
}

.speed-fill-manual {
  height: 100%;
  background: #EF4444;
}

.speed-fill-cast {
  height: 100%;
  background: #10B981;
}

/* ==========================================================================
   Workflow Comparison (High Color Contrast)
   ========================================================================== */
.section-workflow {
  background-color: var(--white);
}

.workflow-matrix-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  margin-top: 36px;
}

.workflow-card-legacy {
  background: #FFFBFB;
  border: 1.5px solid #FCA5A5;
  border-radius: var(--radius-xl);
  padding: clamp(28px, 3.5vw, 40px);
}

.workflow-card-cast {
  background: #F8FAFE;
  border: 2.5px solid var(--cobalt);
  border-radius: var(--radius-xl);
  padding: clamp(28px, 3.5vw, 40px);
  box-shadow: 0 14px 40px rgba(49, 86, 201, 0.18);
  position: relative;
}

.workflow-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}

.workflow-card-title {
  font-size: 1.45rem;
  margin-bottom: 10px;
  color: var(--ink);
}

.workflow-card-desc {
  font-size: 0.94rem;
  color: var(--slate-dark);
  margin-bottom: 24px;
}

.step-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  margin-bottom: 12px;
  font-size: 0.92rem;
  font-weight: 500;
}

.step-row.legacy {
  background: var(--white);
  border: 1px solid #FECACA;
  color: var(--slate-dark);
}

.step-row.legacy.failure-point {
  background: #FEE2E2;
  border-color: #F87171;
  color: #991B1B;
}

.step-row.cast-step {
  background: var(--white);
  border: 1px solid var(--cobalt-border);
  color: var(--ink);
}

.step-row.cast-step.highlight-point {
  background: var(--cobalt);
  border-color: var(--cobalt);
  color: var(--white);
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(49, 86, 201, 0.25);
}

.step-num {
  font-family: var(--font-mono);
  font-weight: 700;
}

.flow-time-banner {
  margin-top: 24px;
  padding-top: 18px;
  border-top: 1.5px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.banner-legacy {
  border-color: #FCA5A5;
}

.banner-cast {
  border-color: var(--cobalt-border);
}

.time-label {
  font-size: 0.88rem;
  font-weight: 600;
}

.time-val {
  font-family: var(--font-mono);
  font-size: 1.6rem;
  font-weight: 700;
}

.time-val-legacy { color: #DC2626; }
.time-val-cast { color: var(--cobalt); }

/* ==========================================================================
   Capacity & OpEx Model: Dark Engineering Terminal Card
   ========================================================================== */
.section-calculator {
  background-color: #EEF3F8;
}

.calculator-terminal-card {
  background: #0C1726;
  border: 2px solid #233D63;
  border-radius: var(--radius-xl);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
  overflow: hidden;
  margin-top: 36px;
  color: var(--white);
}

.terminal-bar {
  background: #112035;
  border-bottom: 1px solid #1F3758;
  padding: 14px 22px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.terminal-dots {
  display: flex;
  gap: 6px;
}

.terminal-title {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 700;
  color: #93C5FD;
  letter-spacing: 0.08em;
}

.terminal-badge {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 700;
  color: #F59E0B;
  background: #251B08;
  border: 1px solid #784805;
  padding: 3px 8px;
  border-radius: 4px;
}

.calc-grid {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: clamp(32px, 4vw, 56px);
  padding: clamp(26px, 4vw, 44px);
  align-items: center;
}

.calc-controls {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.calc-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.calc-label {
  display: flex;
  justify-content: space-between;
  font-size: 0.92rem;
  font-weight: 700;
  color: #E2E8F0;
}

.calc-range {
  width: 100%;
  accent-color: #38BDF8;
  height: 8px;
  background: #1C3352;
  border-radius: 4px;
  cursor: pointer;
}

.calc-range-marks {
  display: flex;
  justify-content: space-between;
  font-size: 0.74rem;
  color: #94A3B8;
  font-weight: 600;
}

.calc-radio-group {
  display: flex;
  gap: 12px;
}

.calc-radio-btn {
  flex: 1;
  padding: 12px 14px;
  border: 1.5px solid #233C5E;
  background: #101E32;
  color: #E2E8F0;
  border-radius: var(--radius-sm);
  font-size: 0.84rem;
  font-weight: 700;
  cursor: pointer;
  text-align: center;
  transition: all var(--transition-fast);
}

.calc-radio-btn.is-active {
  border-color: #38BDF8;
  background: #182C48;
  color: #38BDF8;
  box-shadow: 0 0 12px rgba(56, 189, 248, 0.3);
}

.calc-assumptions-box {
  font-size: 0.82rem;
  color: #94A3B8;
  line-height: 1.5;
  background: #101E32;
  border-left: 3px solid #38BDF8;
  padding: 12px 16px;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.calc-results-terminal {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.result-tile {
  background: #101E32;
  border: 1px solid #1E375C;
  border-radius: var(--radius-md);
  padding: 16px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.result-metric-title {
  font-size: 0.9rem;
  color: #CBD5E1;
}

.result-metric-val {
  font-family: var(--font-mono);
  font-size: 1.6rem;
  font-weight: 700;
}

.val-slate { color: #94A3B8; }
.val-cyan { color: #38BDF8; }
.val-mint { color: #34D399; font-size: 1.9rem; }
.val-amber { color: #F59E0B; font-size: 1.9rem; }

.tile-featured {
  background: #0E243A;
  border: 1.5px solid #10B981;
  box-shadow: 0 0 16px rgba(16, 185, 129, 0.15);
}

.tile-featured-amber {
  background: #1F2218;
  border: 1.5px solid #F59E0B;
  box-shadow: 0 0 16px rgba(245, 158, 11, 0.15);
}

/* ==========================================================================
   Editorial Engineering Gallery
   ========================================================================== */
.section-gallery {
  background-color: var(--white);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
}

.gallery-card {
  border: 2px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--white);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  transition: transform var(--transition-fast), border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.gallery-card:hover {
  transform: translateY(-3px);
  border-color: var(--cobalt-border);
  box-shadow: var(--shadow-md);
}

.gallery-img-wrap {
  width: 100%;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--mist);
  position: relative;
}

.gallery-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-base);
}

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

.gallery-badge-overlay {
  position: absolute;
  top: 14px;
  left: 14px;
}

.gallery-tag {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  background: rgba(9, 18, 29, 0.85);
  color: #38BDF8;
  border: 1px solid rgba(56, 189, 248, 0.4);
  backdrop-filter: blur(8px);
  padding: 4px 10px;
  border-radius: 4px;
  letter-spacing: 0.06em;
}

.gallery-body {
  padding: 26px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.gallery-caption {
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--slate-dark);
  margin-top: 8px;
}

/* ==========================================================================
   Closing CTA Section (Deep Ink Navy, Cobalt & Amber Glow)
   ========================================================================== */
.cta-section {
  background:
    radial-gradient(circle at 85% 15%, rgba(49, 86, 201, 0.3) 0%, transparent 55%),
    linear-gradient(180deg, #09121D 0%, #112034 60%, #09121D 100%);
  color: var(--white);
  position: relative;
  overflow: hidden;
  padding: clamp(80px, 9vw, 120px) 0;
}

.cta-section::after {
  content: "";
  position: absolute;
  top: -140px;
  right: -120px;
  width: 520px;
  height: 520px;
  border: 1.5px solid rgba(56, 189, 248, 0.18);
  border-radius: 50%;
  pointer-events: none;
}

.cta-card {
  max-width: 840px;
  margin: 0 auto;
  text-align: center;
  position: relative;
  z-index: 1;
}

.cta-headline {
  font-size: clamp(2.2rem, 3.8vw, 3.3rem);
  color: var(--white);
  margin-bottom: 18px;
}

.cta-desc {
  font-size: 1.15rem;
  color: #C2D0E2;
  line-height: 1.6;
  margin-bottom: 38px;
}

.cta-form-wrap {
  background: rgba(17, 32, 53, 0.7);
  border: 1.5px solid #25446E;
  border-radius: var(--radius-lg);
  padding: clamp(24px, 3.5vw, 42px);
  text-align: left;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
}

.cta-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group.full-width {
  grid-column: span 2;
}

.form-label {
  font-size: 0.84rem;
  font-weight: 600;
  color: #E2E8F0;
}

.form-input, .form-select, .form-textarea {
  font-family: var(--font-sans);
  font-size: 0.94rem;
  background: #0A1422;
  border: 1.5px solid #233C5E;
  border-radius: var(--radius-sm);
  color: var(--white);
  padding: 12px 16px;
  min-height: 48px;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.form-input:focus, .form-select:focus, .form-textarea:focus {
  border-color: #38BDF8;
  outline: none;
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.35);
}

.form-textarea {
  min-height: 100px;
  resize: vertical;
}

.form-footer {
  margin-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}

.form-disclaimer {
  font-size: 0.8rem;
  color: #94A3B8;
  max-width: 440px;
}

/* ==========================================================================
   Footer: Authoritative Deep Navy Grounding
   ========================================================================== */
.site-footer {
  background-color: #070E17;
  border-top: 1.5px solid #1A2D47;
  padding: 64px 0 36px;
  font-size: 0.88rem;
  color: #94A3B8;
}

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

.footer-desc {
  font-size: 0.9rem;
  color: #94A3B8;
  margin-top: 14px;
  max-width: 320px;
  line-height: 1.6;
}

.footer-col-title {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #38BDF8;
  margin-bottom: 18px;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-links a {
  color: #CBD5E1;
  text-decoration: none;
  transition: color var(--transition-fast);
}

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

.footer-bottom {
  border-top: 1px solid #16253B;
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  font-size: 0.82rem;
  color: #64748B;
}

/* ==========================================================================
   Responsive Breakpoints & Reflow Logic
   ========================================================================== */

/* Laptop / iPad Pro Landscape (<= 1280px) */
@media (max-width: 1280px) {
  .hero-grid {
    gap: 36px;
  }
  .kpi-command-strip {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* iPad Landscape / Standard Tablet (<= 1024px) */
@media (max-width: 1024px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  .hero-text-block {
    max-width: 780px;
  }
  .hero-visual-block {
    max-width: 640px;
    margin: 0 auto;
    width: 100%;
  }
  .kpi-command-strip {
    grid-template-columns: repeat(2, 1fr);
  }
  .problem-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .perspectives-dual-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }
  .pillars-editorial-grid {
    grid-template-columns: 1fr;
  }
  .calc-grid {
    grid-template-columns: 1fr;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 36px;
  }
}

/* iPad Portrait / Tablet (<= 820px) */
@media (max-width: 820px) {
  .nav-desktop {
    display: none;
  }
  .nav-toggle {
    display: flex;
  }
  .workflow-matrix-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }
  .gallery-grid {
    grid-template-columns: 1fr;
  }
  .cta-form-grid {
    grid-template-columns: 1fr;
  }
  .form-group.full-width {
    grid-column: span 1;
  }
}

/* Mobile Devices (<= 500px) */
@media (max-width: 500px) {
  .kpi-command-strip {
    grid-template-columns: 1fr;
  }
  .footer-grid {
    grid-template-columns: 1fr;
  }
  .hero-ctas {
    flex-direction: column;
    align-items: stretch;
  }
  .hero-ctas .btn {
    width: 100%;
  }
  .calc-radio-group {
    flex-direction: column;
  }
  .form-footer {
    flex-direction: column;
    align-items: stretch;
  }
  .form-footer button {
    width: 100%;
  }
}

/* Accessibility: Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .live-pulse {
    box-shadow: none !important;
  }
}
