/**
 * Terra Volts - Enterprise Renewable Energy Infrastructure Design System
 * Light/Dark Mode Native Theme Engine, Tesla + Enterprise B2B Styling
 */

/* ==========================================================================
   THEME TOKENS (Crescendo Corporate Blue & Deep Slate Navy System)
   ========================================================================== */
:root {
  --font-heading: 'Montserrat', sans-serif;
  --font-body: 'Plus Jakarta Sans', sans-serif;
  --transition-smooth: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);

  /* Corporate Blue Brand Accents */
  --brand-blue: #1b75bb;
  --brand-blue-hover: #155d96;
  --brand-cyan: #00a6fb;
  --brand-cyan-hover: #0090da;
  --brand-accent: #0077c8;
  --brand-gradient: linear-gradient(135deg, #1b75bb 0%, #00a6fb 100%);
  --brand-gradient-subtle: linear-gradient(135deg, rgba(27, 117, 187, 0.1) 0%, rgba(0, 166, 251, 0.1) 100%);
}

/* Dark Mode (Default) */
[data-theme="dark"],
:root:not([data-theme="light"]) {
  --bg-base: #070e17;
  --bg-surface: #0c1827;
  --bg-surface-elevated: #112237;
  --bg-card: #101f33;
  --bg-card-hover: #162a45;
  --bg-input: #13243a;
  --header-bg: rgba(7, 14, 23, 0.92);

  --text-primary: #ffffff;
  --text-secondary: #cbd5e1;
  --text-muted: #94a3b8;
  --text-invert: #070e17;
  --text-brand: #38bdf8;

  --border-color: rgba(255, 255, 255, 0.12);
  --border-color-hover: rgba(56, 189, 248, 0.5);
  --border-subtle: rgba(255, 255, 255, 0.06);

  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 16px 40px rgba(0, 0, 0, 0.7);
  --shadow-glow: 0 0 30px rgba(0, 166, 251, 0.2);

  --btn-primary-bg: #1b75bb;
  --btn-primary-text: #ffffff;
  --btn-primary-hover: #00a6fb;

  --table-stripe: rgba(255, 255, 255, 0.03);
  --table-border: rgba(255, 255, 255, 0.12);

  --callout-bg: linear-gradient(135deg, #134e7a 0%, #1b75bb 100%);
}

/* Light Mode */
[data-theme="light"] {
  --bg-base: #ffffff;
  --bg-surface: #f4f8fb;
  --bg-surface-elevated: #ffffff;
  --bg-card: #ffffff;
  --bg-card-hover: #f0f6fa;
  --bg-input: #ffffff;
  --header-bg: rgba(255, 255, 255, 0.96);

  --text-primary: #0a1f33;
  --text-secondary: #334155;
  --text-muted: #64748b;
  --text-invert: #ffffff;
  --text-brand: #1b75bb;

  --border-color: #e2e8f0;
  --border-color-hover: rgba(27, 117, 187, 0.5);
  --border-subtle: #edf2f7;

  --shadow-sm: 0 2px 8px rgba(10, 31, 51, 0.05);
  --shadow-md: 0 8px 24px rgba(10, 31, 51, 0.08);
  --shadow-lg: 0 16px 40px rgba(10, 31, 51, 0.12);
  --shadow-glow: 0 0 30px rgba(27, 117, 187, 0.15);

  --btn-primary-bg: #1b75bb;
  --btn-primary-text: #ffffff;
  --btn-primary-hover: #155d96;

  --table-stripe: #f8fafc;
  --table-border: #cbd5e1;

  --callout-bg: linear-gradient(135deg, #1b75bb 0%, #0088dd 100%);
}

/* ==========================================================================
   GLOBAL BASE STYLES
   ========================================================================== */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 90px;
}

[id] {
  scroll-margin-top: 90px;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-base);
  color: var(--text-primary);
  line-height: 1.65;
  transition: background-color 0.3s ease, color 0.3s ease;
  overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6,
.font-heading {
  font-family: var(--font-heading);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-primary);
}

a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition-smooth);
}

img {
  max-width: 100%;
  height: auto;
}

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

.text-white-90 {
  color: rgba(255, 255, 255, 0.92) !important;
}

.text-white-80 {
  color: rgba(255, 255, 255, 0.82) !important;
}

/* SVG Icon System — global sizing */
.tv-icon {
  display: inline-block;
  width: 1em;
  height: 1em;
  vertical-align: -0.125em;
  /* optical alignment with text baseline */
  flex-shrink: 0;
  stroke: currentColor;
  fill: none;
}

/* Larger icon variant for feature cards */
.tv-icon-lg {
  width: 1.5em;
  height: 1.5em;
}

/* XL for hero/standalone icon containers */
.tv-icon-xl {
  width: 2em;
  height: 2em;
}


/* Enforce High-Contrast for text-muted across themes */
[data-theme="dark"] .text-muted,
:root:not([data-theme="light"]) .text-muted {
  color: #94a3b8 !important;
}

[data-theme="light"] .text-muted {
  color: #64748b !important;
}

[data-theme="dark"] .text-secondary,
:root:not([data-theme="light"]) .text-secondary {
  color: #cbd5e1 !important;
}

[data-theme="light"] .text-secondary {
  color: #334155 !important;
}

.bg-gradient-subtle {
  background: var(--brand-gradient-subtle);
}

.badge-glow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 50px;
  background: rgba(0, 230, 118, 0.1);
  border: 1px solid rgba(0, 230, 118, 0.3);
  color: var(--brand-green);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.badge-glow::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: var(--brand-green);
  box-shadow: 0 0 8px var(--brand-green);
}

/* ==========================================================================
   HEADER & NAVIGATION
   ========================================================================== */
.tv-header {
  position: sticky;
  top: 0;
  z-index: 1050;
  background: var(--header-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-color);
  transition: var(--transition-smooth);
  padding: 12px 0;
}

.nav-mobile-toggle-btn {
  width: 40px;
  height: 40px;
  min-width: 40px;
  min-height: 40px;
  display: inline-flex;
  /* No !important — lets Bootstrap d-xl-none hide it on desktop */
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  background: var(--bg-card);
  border: 1px solid var(--border-color) !important;
  color: var(--text-primary) !important;
  transition: var(--transition-smooth);
  flex-shrink: 0;
  padding: 0 !important;
  margin: 0;
}

.nav-mobile-toggle-btn:hover {
  border-color: var(--brand-cyan) !important;
  color: var(--brand-cyan) !important;
  background: var(--bg-card-hover);
}

.nav-mobile-toggle-btn i {
  font-size: 1.55rem;
  line-height: 1;
}

.tv-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  color: var(--text-primary);
  flex-shrink: 0;
  white-space: nowrap;
}

.tv-brand>div {
  flex-shrink: 0;
  min-width: 0;
}

.tv-brand-icon,
.tv-brand-logo-img {
  width: 40px;
  height: 40px;
  min-width: 40px;
  min-height: 40px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center;
  /* background: #ffffff; */
  padding: 2px;
  display: flex;
  align-items: center;
  justify-content: center;
  /* box-shadow: 0 0 14px rgba(27, 117, 187, 0.35); */
  /* border: 1px solid rgba(27, 117, 187, 0.3); */
  flex-shrink: 0;
}

.tv-brand span.subtext {
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--text-muted);
  display: block;
  margin-top: -3px;
  white-space: nowrap;
}

.tv-nav {
  flex-shrink: 1;
}

.tv-nav .nav-link {
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: 6px;
  transition: var(--transition-smooth);
  white-space: nowrap;
}

.tv-nav .nav-link:hover,
.tv-nav .nav-link.active {
  color: var(--text-brand);
  background: var(--brand-gradient-subtle);
}

/* WordPress nav_menu <li> items — match .nav-link appearance */
.tv-nav-menu {
  padding: 0;
  margin: 0;
}

.tv-nav-menu>li {
  list-style: none;
}

.tv-nav-menu>li>a {
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: 6px;
  transition: var(--transition-smooth);
  white-space: nowrap;
  display: inline-block;
  font-family: var(--font-heading);
}

.tv-nav-menu>li>a:hover,
.tv-nav-menu>li.current-menu-item>a,
.tv-nav-menu>li.current_page_item>a {
  color: var(--text-brand);
  background: var(--brand-gradient-subtle);
}

.header-actions {
  flex-shrink: 0;
}

/* Theme Switcher Toggle */
.theme-switch-btn {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  width: 38px;
  height: 38px;
  min-width: 38px;
  min-height: 38px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition-smooth);
  flex-shrink: 0;
}

.theme-switch-btn:hover {
  border-color: var(--brand-cyan);
  color: var(--brand-cyan);
  box-shadow: var(--shadow-glow);
}

/* Primary and Outline Buttons */
.btn-tv-primary {
  background: var(--btn-primary-bg);
  color: var(--btn-primary-text) !important;
  font-family: var(--font-heading);
  font-size: 0.88rem;
  font-weight: 700;
  padding: 11px 24px;
  border-radius: 6px;
  border: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  transition: var(--transition-smooth);
  box-shadow: var(--shadow-md);
  flex-shrink: 0;
  white-space: nowrap;
}

.btn-tv-primary:hover {
  background: var(--btn-primary-hover);
  color: var(--btn-primary-text) !important;
  transform: translateY(-2px);
  box-shadow: var(--shadow-glow);
}

.btn-tv-outline {
  background: transparent;
  color: var(--text-primary);
  font-family: var(--font-heading);
  font-size: 0.88rem;
  font-weight: 600;
  padding: 11px 26px;
  border-radius: 6px;
  border: 1.5px solid var(--border-color);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  transition: var(--transition-smooth);
}

[data-theme="light"] .btn-tv-outline {
  border-color: #cbd5e1;
  color: var(--text-primary);
}

.btn-tv-outline:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--text-brand);
  color: var(--text-brand);
  transform: translateY(-2px);
}

[data-theme="light"] .btn-tv-outline:hover {
  background: rgba(27, 117, 187, 0.08);
  border-color: var(--brand-blue);
  color: var(--brand-blue);
}

/* Hero Outline Button - Hero background is always dark in both light & dark modes */
.tv-hero .btn-tv-outline,
.tv-hero-actions .btn-tv-outline {
  color: #ffffff !important;
  border: 1.5px solid rgba(255, 255, 255, 0.65) !important;
  background: rgba(255, 255, 255, 0.1) !important;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.tv-hero .btn-tv-outline:hover,
.tv-hero-actions .btn-tv-outline:hover {
  background: #ffffff !important;
  color: #070e17 !important;
  border-color: #ffffff !important;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.35), 0 0 15px rgba(255, 255, 255, 0.3);
  transform: translateY(-2px);
}

.btn-white-pill {
  background: #ffffff;
  color: #1b75bb !important;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.85rem;
  padding: 10px 24px;
  border-radius: 50px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: none;
  text-decoration: none;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  transition: var(--transition-smooth);
}

.btn-white-pill:hover {
  background: #f0f6fa;
  color: #155d96 !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

/* Callout Box (Crescendo Solid Blue) */
.callout-card-blue {
  background: var(--callout-bg);
  color: #ffffff;
  border-radius: 6px;
  padding: 36px 32px;
  box-shadow: var(--shadow-md);
  height: 100%;
}

.callout-card-blue h3 {
  color: #ffffff !important;
  font-size: 1.35rem;
  font-weight: 700;
  margin-bottom: 14px;
}

.callout-card-blue p {
  color: rgba(255, 255, 255, 0.92);
  font-size: 0.95rem;
  line-height: 1.7;
  margin-bottom: 0;
}

/* Split Feature 50/50 Box */
.split-feature-box {
  background: var(--callout-bg);
  color: #ffffff;
  padding: 48px;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.split-feature-box h2,
.split-feature-box h3 {
  color: #ffffff !important;
  font-size: clamp(1.6rem, 2.5vw, 2.2rem);
  font-weight: 800;
  margin-bottom: 18px;
}

.split-feature-box p {
  color: rgba(255, 255, 255, 0.92);
  font-size: 0.98rem;
  line-height: 1.75;
  margin-bottom: 24px;
}

/* Mature Solution Card (Crescendo 8-Card Grid) */
.solution-grid-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  padding: 30px 22px;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  transition: var(--transition-smooth);
}

.solution-grid-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--brand-blue);
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.solution-grid-card h4 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-brand);
  margin-bottom: 12px;
}

.solution-grid-card p {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 0;
}

/* ==========================================================================
   HERO SECTION
   ========================================================================== */
.tv-hero {
  position: relative;
  min-height: 80vh;
  display: flex;
  align-items: center;
  background: linear-gradient(180deg, var(--bg-base) 0%, rgba(7, 14, 23, 0.75) 100%),
    radial-gradient(circle at 80% 20%, rgba(27, 117, 187, 0.1) 0%, transparent 60%);
  padding: 100px 0 80px 0;
  overflow: hidden;
}

/* ── Video Background ──────────────────────────────────────── */
.tv-hero-video-wrap {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}

.tv-hero-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  /* Toned-down so the gradient overlay + text pop cleanly */
  filter: brightness(0.65) saturate(1.1);
}

.tv-hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(160deg,
      rgba(7, 14, 23, 0.72) 0%,
      rgba(11, 28, 48, 0.55) 60%,
      rgba(7, 14, 23, 0.35) 100%);
}

[data-theme="light"] .tv-hero-video {
  filter: brightness(0.5) contrast(1.15);
}

[data-theme="light"] .tv-hero-overlay {
  background: linear-gradient(160deg,
      rgba(7, 14, 23, 0.78) 0%,
      rgba(11, 28, 48, 0.62) 60%,
      rgba(7, 14, 23, 0.45) 100%);
}

/* Subpage Hero Background Image Overlay */
.tv-hero-bg-overlay {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  z-index: 0;
  filter: brightness(0.65) saturate(1.1);
}

.tv-hero-bg-overlay::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(160deg,
      rgba(7, 14, 23, 0.78) 0%,
      rgba(11, 28, 48, 0.65) 60%,
      rgba(7, 14, 23, 0.5) 100%);
  z-index: 1;
}

[data-theme="light"] .tv-hero-bg-overlay {
  filter: brightness(0.55) contrast(1.1);
}

[data-theme="light"] .tv-hero-bg-overlay::after {
  background: linear-gradient(160deg,
      rgba(7, 14, 23, 0.82) 0%,
      rgba(11, 28, 48, 0.72) 60%,
      rgba(7, 14, 23, 0.55) 100%);
}

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

.tv-hero h1 {
  font-size: clamp(2.5rem, 5.5vw, 4.2rem);
  font-weight: 800;
  line-height: 1.12;
  margin-bottom: 24px;
  color: #ffffff !important;
}

.tv-hero p.lead {
  font-size: clamp(1.05rem, 1.8vw, 1.25rem);
  color: rgba(255, 255, 255, 0.9) !important;
  line-height: 1.65;
  margin-bottom: 36px;
  max-width: 680px;
}

/* Live Stats Bar in Hero */
.hero-stats-bar {
  margin-top: 60px;
  padding: 24px 32px;
  border-radius: 8px;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-md);
}

.stat-item h3 {
  font-size: 2rem;
  font-weight: 800;
  margin-bottom: 4px;
  color: var(--text-brand);
}

.stat-item p {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  margin-bottom: 0;
}

/* ==========================================================================
   CARDS & SECTIONS
   ========================================================================== */
.section-padding {
  padding: 100px 0;
}

.section-header {
  margin-bottom: 60px;
}

.section-header h2 {
  font-size: clamp(2rem, 3.5vw, 2.75rem);
  font-weight: 800;
  margin-bottom: 16px;
}

.section-header p {
  font-size: 1.1rem;
  color: var(--text-secondary);
  max-width: 620px;
}

/* Card Styling */
.tv-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 14px;
  padding: clamp(20px, 2vw, 26px) clamp(18px, 1.8vw, 24px);
  height: 100%;
  display: flex;
  flex-direction: column;
  transition: var(--transition-smooth);
  position: relative;
  overflow: hidden;
}

.tv-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-color-hover);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg), var(--shadow-glow);
}

.tv-card-media {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-radius: 12px;
  margin-bottom: 20px;
  border: 1px solid var(--border-color);
  transition: var(--transition-smooth);
}

.tv-card:hover .tv-card-media {
  transform: scale(1.02);
}

/* ==========================================================================
   CORE SOLUTIONS ARCHITECTURAL SHOWCASE CARDS (2x2 Wide Split Grid)
   ========================================================================== */
.tv-solution-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  overflow: hidden;
  height: 100%;
  display: flex;
  flex-direction: column;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.35s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.35s ease,
    background 0.35s ease;
  position: relative;
  box-shadow: var(--shadow-sm);
}

[data-theme="light"] .tv-solution-card {
  background: #ffffff;
  border-color: #e2e8f0;
  box-shadow: 0 4px 18px rgba(10, 31, 51, 0.05);
}

.tv-solution-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-color-hover);
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg), 0 0 24px rgba(0, 163, 224, 0.12);
}

[data-theme="light"] .tv-solution-card:hover {
  background: #ffffff;
  border-color: rgba(27, 117, 187, 0.4);
  box-shadow: 0 16px 36px rgba(10, 31, 51, 0.08), 0 0 20px rgba(27, 117, 187, 0.1);
}

/* Horizontal split on >= 768px (md and up) */
@media (min-width: 768px) {
  .tv-solution-card {
    flex-direction: row;
    align-items: stretch;
  }
}

/* Solution Media (Left Column) */
.tv-solution-media-col {
  position: relative;
  width: 100%;
  min-height: 220px;
  overflow: hidden;
  background: var(--bg-surface);
  flex-shrink: 0;
}

@media (min-width: 768px) {
  .tv-solution-media-col {
    width: 44%;
    min-height: 270px;
  }
}

.tv-solution-img {
  width: 100%;
  height: 100%;
  min-height: 220px;
  object-fit: cover;
  display: block;
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.tv-solution-card:hover .tv-solution-img {
  transform: scale(1.05);
}

/* Solution Editorial Content (Right Column) */
.tv-solution-content-col {
  padding: clamp(22px, 2.4vw, 30px);
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.tv-solution-title {
  font-family: var(--font-heading);
  font-size: clamp(1.22rem, 1.45vw, 1.42rem);
  font-weight: 700;
  letter-spacing: -0.015em;
  line-height: 1.3;
  margin-bottom: 12px;
  color: var(--text-primary);
  transition: color 0.25s ease;
}

.tv-solution-card:hover .tv-solution-title {
  color: var(--text-brand);
}

.tv-solution-desc {
  font-size: clamp(0.88rem, 0.95vw, 0.94rem);
  line-height: 1.65;
  color: var(--text-secondary);
  margin-bottom: 20px;
}

/* Subtle Deployment Focus Metadata */
.tv-solution-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px;
  margin-top: auto;
  margin-bottom: 22px;
  padding-top: 14px;
  border-top: 1px solid var(--border-subtle);
}

.tv-solution-meta-label {
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  flex-shrink: 0;
}

.tv-solution-meta-val {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.4;
}

/* Solution Action Link */
.tv-solution-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-heading);
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text-brand);
  text-decoration: none;
  transition: color 0.25s ease, gap 0.25s ease;
  width: fit-content;
}

.tv-solution-link svg {
  width: 15px;
  height: 15px;
  transition: transform 0.25s ease;
  color: var(--text-brand);
}

.tv-solution-card:hover .tv-solution-link {
  color: var(--brand-cyan);
  gap: 12px;
}

[data-theme="light"] .tv-solution-card:hover .tv-solution-link {
  color: var(--brand-blue-hover);
}

.tv-solution-card:hover .tv-solution-link svg {
  transform: translateX(3px);
}

/* ==========================================================================
   ENGINEERED HARDWARE PRODUCT CARDS (Image-First Approach)
   ========================================================================== */
.tv-product-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 0;
  height: 100%;
  display: flex;
  flex-direction: column;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.35s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.35s ease,
    background 0.35s ease;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

[data-theme="light"] .tv-product-card {
  background: #ffffff;
  border-color: #e2e8f0;
  box-shadow: 0 4px 18px rgba(10, 31, 51, 0.05);
}

.tv-product-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-color-hover);
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg), 0 0 25px rgba(27, 117, 187, 0.12);
}

[data-theme="light"] .tv-product-card:hover {
  background: #ffffff;
  border-color: rgba(27, 117, 187, 0.45);
  box-shadow: 0 16px 34px rgba(10, 31, 51, 0.1), 0 0 20px rgba(27, 117, 187, 0.1);
}

/* Full-Bleed Top Image Header (Image-First) */
.tv-product-thumb {
  position: relative;
  width: 100%;
  height: 220px;
  overflow: hidden;
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border-subtle);
}

.tv-product-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.tv-product-card:hover .tv-product-thumb img {
  transform: scale(1.06);
}

/* Card Body & Fluid Typography */
.tv-product-body {
  padding: 24px 22px 24px 22px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.tv-product-title {
  font-size: clamp(1.12rem, 1.25vw, 1.28rem);
  font-weight: 700;
  letter-spacing: -0.015em;
  line-height: 1.35;
  margin-bottom: 10px;
  color: var(--text-primary);
  transition: color 0.25s ease;
}

.tv-product-card:hover .tv-product-title {
  color: var(--text-brand);
}

.tv-product-desc {
  font-size: clamp(0.86rem, 0.95vw, 0.93rem);
  line-height: 1.65;
  color: var(--text-secondary);
  margin-bottom: 22px;
  flex-grow: 1;
}

/* Tactile Action CTA Button */
.tv-product-action {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 11px 18px;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
  background: transparent;
  border: 1.5px solid var(--border-color);
  text-decoration: none;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

[data-theme="light"] .tv-product-action {
  border-color: #cbd5e1;
  color: #0a1f33;
  background: #f8fafc;
}

.tv-product-action-icon {
  width: 14px;
  height: 14px;
  transition: transform 0.25s ease;
  flex-shrink: 0;
}

.tv-product-card:hover .tv-product-action,
.tv-product-action:hover {
  background: var(--brand-blue);
  border-color: var(--brand-blue);
  color: #ffffff !important;
  box-shadow: 0 4px 14px rgba(27, 117, 187, 0.3);
}

.tv-product-card:hover .tv-product-action-icon,
.tv-product-action:hover .tv-product-action-icon {
  transform: translateX(4px);
}

/* ==========================================================================
   INSIGHTS CARDS (Homepage & Archive)
   ========================================================================== */
.tv-insight-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 0;
  height: 100%;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.35s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.35s ease;
  box-shadow: var(--shadow-sm);
}

[data-theme="light"] .tv-insight-card {
  background: #ffffff;
  border-color: #e2e8f0;
  box-shadow: 0 4px 18px rgba(10, 31, 51, 0.05);
}

.tv-insight-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-color-hover);
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg), 0 0 25px rgba(27, 117, 187, 0.12);
}

[data-theme="light"] .tv-insight-card:hover {
  background: #ffffff;
  border-color: rgba(27, 117, 187, 0.45);
  box-shadow: 0 16px 34px rgba(10, 31, 51, 0.09);
}

.tv-insight-thumb {
  position: relative;
  width: 100%;
  height: 210px;
  overflow: hidden;
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border-subtle);
}

.tv-insight-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.tv-insight-card:hover .tv-insight-thumb img {
  transform: scale(1.06);
}

.tv-insight-body {
  padding: 24px 22px 22px 22px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.tv-insight-title {
  font-size: clamp(1.1rem, 1.25vw, 1.25rem);
  font-weight: 700;
  line-height: 1.38;
  margin-bottom: 10px;
  color: var(--text-primary);
  transition: color 0.25s ease;
}

.tv-insight-title a {
  color: inherit;
  text-decoration: none;
}

.tv-insight-card:hover .tv-insight-title a {
  color: var(--text-brand);
}

.tv-insight-desc {
  font-size: clamp(0.86rem, 0.92vw, 0.92rem);
  line-height: 1.62;
  color: var(--text-secondary);
  margin-bottom: 20px;
  flex-grow: 1;
}

.tv-insight-footer {
  padding-top: 16px;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
  font-size: 0.82rem;
}

.tv-insight-action {
  font-weight: 700;
  color: var(--brand-blue);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
  transition: all 0.2s ease;
}

[data-theme="dark"] .tv-insight-action {
  color: var(--brand-cyan);
}

.tv-insight-action-icon {
  width: 13px;
  height: 13px;
  transition: transform 0.25s ease;
}

.tv-insight-card:hover .tv-insight-action-icon,
.tv-insight-action:hover .tv-insight-action-icon {
  transform: translateX(4px);
}

.tv-card-icon {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  background: var(--brand-gradient-subtle);
  border: 1px solid rgba(0, 230, 118, 0.2);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--brand-green);
  font-size: 1.5rem;
  margin-bottom: 20px;
}

.tv-card h3 {
  font-size: 1.35rem;
  margin-bottom: 12px;
}

.tv-card p {
  color: var(--text-secondary);
  font-size: 0.92rem;
  line-height: 1.6;
}

.tv-card-badge {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 4px;
  background: rgba(0, 210, 255, 0.1);
  color: var(--brand-cyan);
  display: inline-block;
  margin-bottom: 14px;
}

/* ==========================================================================
   SOLUTIONS COMPARISON MATRIX TABLE
   ========================================================================== */
.solutions-table-wrap {
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--table-border);
  box-shadow: var(--shadow-md);
  background: var(--bg-surface);
}

.solutions-table {
  width: 100%;
  border-collapse: collapse;
  margin: 0;
  text-align: left;
}

.solutions-table th {
  background: var(--bg-surface-elevated);
  padding: 18px 24px;
  font-family: var(--font-heading);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  border-bottom: 2px solid var(--table-border);
}

.solutions-table td {
  padding: 20px 24px;
  border-bottom: 1px solid var(--table-border);
  color: var(--text-secondary);
  font-size: 0.92rem;
}

.solutions-table tr:nth-child(even) {
  background: var(--table-stripe);
}

.solutions-table tr:hover {
  background: var(--bg-card-hover);
}

.solutions-table td.solution-title {
  color: var(--text-primary);
  font-weight: 700;
  font-family: var(--font-heading);
}

/* ==========================================================================
   PRODUCT CATALOG TABS & SPEC PANELS
   ========================================================================== */
.product-nav-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 20px;
  margin-bottom: 40px;
}

.product-nav-pills .pill-btn {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-family: var(--font-heading);
  font-size: 0.9rem;
  font-weight: 700;
  padding: 12px 24px;
  border-radius: 8px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  user-select: none;
  touch-action: manipulation;
  transition: var(--transition-smooth);
}

.product-nav-pills .pill-btn:hover {
  color: var(--text-primary);
  border-color: var(--text-primary);
}

.product-nav-pills .pill-btn.active {
  background: var(--brand-blue);
  color: #ffffff;
  border-color: transparent;
  box-shadow: 0 4px 16px rgba(27, 117, 187, 0.35);
}

.product-tabs-content {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.product-tab-pane {
  position: relative;
  display: block;
  animation: tvProductFadeIn 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.product-tab-pane.d-none {
  display: none !important;
}

.tv-tab-anchor {
  position: absolute;
  top: -110px;
  left: 0;
  display: block;
  visibility: hidden;
  pointer-events: none;
}

@keyframes tvProductFadeIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.product-spec-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  overflow: hidden;
  padding: 40px;
}

.spec-list {
  list-style: none;
  padding: 0;
  margin: 24px 0 0 0;
}

.spec-list li {
  padding: 14px 0;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  gap: 14px;
  font-size: 0.92rem;
  color: var(--text-secondary);
}

.spec-list li:last-child {
  border-bottom: none;
}

.spec-list li i {
  color: var(--text-brand);
  font-size: 1.1rem;
  flex-shrink: 0;
  margin-top: 2px;
}

.spec-list strong {
  color: var(--text-primary);
}

/* ==========================================================================
   INTERACTIVE ENERGY CALCULATOR WIDGET
   ========================================================================== */
.calculator-widget {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 40px;
  box-shadow: var(--shadow-lg);
}

.calc-range-input {
  width: 100%;
  accent-color: var(--brand-blue);
  height: 6px;
  background: var(--bg-card);
  border-radius: 4px;
  outline: none;
}

.calc-result-box {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 24px;
  text-align: center;
}

.calc-result-number {
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--text-brand);
  font-family: var(--font-heading);
}

/* ==========================================================================
   CONTACT INTAKE & CONVERSION
   ========================================================================== */
.contact-section {
  background: var(--bg-surface);
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
}

.tv-form-control {
  width: 100%;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  padding: 14px 18px;
  color: var(--text-primary);
  font-size: 0.95rem;
  font-family: var(--font-body);
  transition: var(--transition-smooth);
}

.tv-form-control::placeholder {
  color: var(--text-muted);
  opacity: 0.85;
}

.tv-form-control option {
  background: var(--bg-surface);
  color: var(--text-primary);
}

.tv-form-control:focus {
  outline: none;
  border-color: var(--brand-blue);
  box-shadow: 0 0 0 3px rgba(27, 117, 187, 0.2);
}

.form-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
  display: block;
}

/* Accordion Contrast Rules */
.accordion-item {
  background-color: var(--bg-card) !important;
  border-color: var(--border-color) !important;
}

.accordion-button {
  background-color: var(--bg-card) !important;
  color: var(--text-primary) !important;
  font-size: 1.05rem;
  padding: 20px 24px;
}

.accordion-button:not(.collapsed) {
  background-color: var(--bg-card-hover) !important;
  color: var(--text-brand) !important;
  box-shadow: none;
}

.accordion-button::after {
  filter: var(--theme-icon-filter, invert(1) grayscale(100%) brightness(200%));
}

[data-theme="light"] .accordion-button::after {
  filter: none;
}

.accordion-body {
  background-color: var(--bg-card) !important;
  color: var(--text-secondary) !important;
  font-size: 0.95rem;
  line-height: 1.7;
  padding: 20px 24px;
}

/* ==========================================================================
   FOOTER BANNER CTA (Background Image & Deep Gradient Overlay)
   ========================================================================== */
.footer-cta-banner {
  position: relative;
  background: linear-gradient(135deg, rgba(7, 14, 23, 0.94) 0%, rgba(13, 28, 48, 0.9) 100%), url('../img/hero-solar.jpg') center/cover no-repeat;
  color: #ffffff;
  padding: 90px 0;
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
  overflow: hidden;
  text-align: center;
}

.footer-cta-banner::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(27, 117, 187, 0.2) 0%, transparent 70%);
  pointer-events: none;
}

.footer-cta-banner .container {
  position: relative;
  z-index: 2;
}

.footer-cta-banner h2 {
  color: #ffffff !important;
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.tv-footer {
  background: var(--bg-base);
  color: var(--text-secondary);
  padding: 80px 0 44px 0;
  border-top: 1px solid var(--border-color);
  font-size: 0.9rem;
}

.footer-brand-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 16px;
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 10px;
}

.footer-links a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.92rem;
  display: inline-block;
  transition: var(--transition-fast);
}

.footer-links a:hover {
  color: var(--brand-green);
  transform: translateX(3px);
}

.footer-links .current-menu-item > a,
.footer-links li.active > a {
  color: var(--text-brand);
  font-weight: 700;
}

.footer-bottom {
  margin-top: 68px;
  padding-top: 32px;
  border-top: 1px solid var(--border-subtle);
  font-size: 0.85rem;
  color: var(--text-muted);
}

.footer-bottom-main {
  padding-bottom: 20px;
}

.footer-copyright {
  font-weight: 500;
  color: var(--text-secondary);
}

.footer-division-badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 12px;
  border-radius: 999px;
  background: rgba(27, 117, 187, 0.08);
  border: 1px solid rgba(27, 118, 187, 0.016);
  color: var(--brand-cyan, #1b75bb);
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

[data-theme="light"] .footer-division-badge {
  background: rgba(27, 117, 187, 0.07);
  border-color: rgba(27, 117, 187, 0.25);
  color: var(--text-brand);
}

.footer-legal-links {
  gap: 16px;
}

.footer-legal-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.82rem;
  transition: var(--transition-smooth);
}

.footer-legal-links a:hover {
  color: var(--text-primary);
}

.footer-sep {
  color: var(--border-color);
  font-size: 0.8rem;
  user-select: none;
}

/* Sub-tier: Engineering Credit & System Status */
.footer-bottom-sub {
  padding-top: 18px;
  border-top: 1px dashed var(--border-subtle);
  font-size: 0.8rem;
  line-height: 1.6;
}

.footer-credit {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--text-muted);
}

.footer-credit-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--text-primary);
  text-decoration: none;
  font-weight: 600;
  transition: var(--transition-smooth);
}

.footer-credit-link:hover {
  color: var(--text-brand);
  transform: translateX(2px);
}

.footer-credit-icon {
  width: 12px;
  height: 12px;
  transition: transform 0.2s ease;
}

.footer-credit-link:hover .footer-credit-icon {
  transform: translateX(2px);
}

.footer-sys-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  font-size: 0.78rem;
}

.footer-sys-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 8px rgba(16, 185, 129, 0.6);
  display: inline-block;
  animation: pulse-dot 2.5s infinite;
}

@keyframes pulse-dot {

  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.5;
    transform: scale(0.85);
  }
}

/* ==========================================================================
   RESPONSIVE DESIGN (Desktop, Laptop, Tablet, Phone)
   ========================================================================== */
@media (max-width: 1199.98px) {
  .tv-header {
    padding: 8px 0 !important;
  }

  .tv-brand {
    font-size: 1.2rem;
    gap: 10px;
  }

  .tv-brand-logo-img,
  .tv-brand-icon {
    width: 34px;
    height: 34px;
    min-width: 34px;
    min-height: 34px;
  }

  .btn-tv-primary.header-cta-btn {
    padding: 8px 16px;
    font-size: 0.82rem;
  }

  .nav-mobile-toggle-btn {
    width: 36px;
    height: 36px;
    min-width: 36px;
    min-height: 36px;
  }

  .nav-mobile-toggle-btn i {
    font-size: 1.45rem;
  }

  .tv-hero h1 {
    font-size: clamp(2.2rem, 4.5vw, 3.5rem);
  }
}

@media (max-width: 991.98px) {
  .tv-hero {
    min-height: auto;
    padding: 80px 0 60px 0;
  }

  .section-padding {
    padding: 60px 0;
  }

  .product-spec-card {
    padding: 28px;
  }

  .hero-stats-bar {
    margin-top: 40px;
    padding: 20px 24px;
  }
}

@media (max-width: 767.98px) {
  .tv-header {
    padding: 6px 0 !important;
  }

  .tv-brand {
    font-size: 1.12rem;
    gap: 8px;
  }

  .tv-brand-logo-img,
  .tv-brand-icon {
    width: 32px;
    height: 32px;
    min-width: 32px;
    min-height: 32px;
  }

  .btn-tv-primary.header-cta-btn {
    padding: 7px 12px;
    font-size: 0.78rem;
  }

  .nav-mobile-toggle-btn {
    width: 34px;
    height: 34px;
    min-width: 34px;
    min-height: 34px;
  }

  .nav-mobile-toggle-btn i {
    font-size: 1.35rem;
  }

  /* Mobile hero: show only headline + lead paragraph */
  .tv-hero-actions {
    display: none !important;
  }

  /* Section & Spacing Mobile Rhythm */
  .section-padding {
    padding: 55px 0;
  }

  .section-header {
    margin-bottom: 30px;
  }

  .section-header h2,
  .section-header .display-6 {
    font-size: 1.65rem !important;
    line-height: 1.25 !important;
    letter-spacing: -0.01em;
    margin-bottom: 10px !important;
  }

  .section-header p,
  .section-header p.fs-5 {
    font-size: 0.95rem !important;
    line-height: 1.6 !important;
    max-width: 100%;
  }

  /* Mobile Hero Typography */
  .tv-hero {
    padding: 60px 0 50px 0;
    min-height: auto;
  }

  .tv-hero h1,
  .tv-hero .display-3,
  .tv-hero .display-4 {
    font-size: 1.85rem !important;
    line-height: 1.22 !important;
    letter-spacing: -0.01em;
    margin-bottom: 14px;
  }

  .tv-hero p.lead,
  .tv-hero p {
    font-size: 0.96rem !important;
    line-height: 1.6 !important;
    margin-bottom: 20px;
  }

  /* Bootstrap Display Classes Mobile Scaling */
  .display-3 {
    font-size: 1.9rem !important;
    line-height: 1.2 !important;
  }

  .display-4 {
    font-size: 1.75rem !important;
    line-height: 1.22 !important;
  }

  .display-6 {
    font-size: 1.55rem !important;
    line-height: 1.25 !important;
  }

  /* Universal Mobile Text Hygiene */
  h1, .h1 { font-size: 1.8rem; line-height: 1.25; }
  h2, .h2 { font-size: 1.45rem; line-height: 1.3; }
  h3, .h3 { font-size: 1.2rem; line-height: 1.35; }
  h4, .h4 { font-size: 1.05rem; line-height: 1.4; }

  p, li, .text-secondary {
    letter-spacing: 0;
  }

  .tv-hero .d-flex.flex-wrap.gap-3 a {
    width: 100%;
    justify-content: center;
  }

  .hero-stats-bar {
    padding: 16px;
    margin-top: 30px;
  }

  .hero-stats-bar .stat-item h3 {
    font-size: 1.6rem;
  }

  .hero-stats-bar .stat-item p {
    font-size: 0.75rem;
  }

  .product-nav-pills {
    overflow-x: auto;
    flex-wrap: nowrap;
    white-space: nowrap;
    padding-bottom: 12px;
    margin-bottom: 24px;
    -webkit-overflow-scrolling: touch;
  }

  .product-nav-pills .pill-btn {
    padding: 10px 18px;
    font-size: 0.85rem;
    flex-shrink: 0;
  }

  .solutions-table-wrap {
    overflow-x: auto;
    border-radius: 12px;
  }

  .calculator-widget {
    padding: 20px;
  }

  .calc-result-number {
    font-size: 2rem;
  }

  .tv-form-control {
    font-size: 16px;
    /* Prevents auto-zoom on iOS */
    padding: 12px 14px;
  }

  .product-spec-card {
    padding: 20px;
  }

  .tv-card {
    padding: 20px 18px;
  }

  .tv-solution-card {
    border-radius: 16px;
  }

  .tv-solution-content-col {
    padding: 22px 20px;
  }

  .tv-product-card {
    padding: 0;
  }

  .tv-product-thumb {
    height: 190px;
  }

  .tv-product-body {
    padding: 20px 18px 22px 18px;
  }

  .tv-insight-card {
    border-radius: 14px;
  }

  .tv-insight-thumb {
    height: 190px;
  }

  .tv-insight-body {
    padding: 20px 18px 20px 18px;
  }

  .footer-bottom {
    margin-top: 48px;
    padding-top: 24px;
  }

  .footer-bottom-main {
    padding-bottom: 16px;
  }

  .footer-bottom-sub {
    padding-top: 14px;
    gap: 10px;
  }
}

@media (max-width: 575.98px) {
  .tv-brand {
    font-size: 1.05rem;
    gap: 8px;
  }

  .tv-brand-logo-img {
    width: 30px;
    height: 30px;
    min-width: 30px;
    min-height: 30px;
  }

  .tv-brand span.subtext {
    display: none;
  }

  .theme-switch-btn {
    width: 34px;
    height: 34px;
    min-width: 34px;
    min-height: 34px;
    font-size: 0.85rem;
  }

  .section-padding {
    padding: 44px 0;
  }

  .section-header {
    margin-bottom: 24px;
  }

  .section-header h2,
  .section-header .display-6 {
    font-size: 1.45rem !important;
    line-height: 1.28 !important;
  }

  .section-header p,
  .section-header p.fs-5 {
    font-size: 0.88rem !important;
    line-height: 1.55 !important;
  }

  .tv-hero h1,
  .tv-hero .display-3,
  .tv-hero .display-4 {
    font-size: 1.62rem !important;
    line-height: 1.24 !important;
  }

  .tv-hero p.lead {
    font-size: 0.9rem !important;
    line-height: 1.55 !important;
    margin-bottom: 18px;
  }

  .tv-solution-card {
    border-radius: 14px;
  }

  .tv-solution-media-col {
    min-height: 200px;
    height: 200px;
  }

  .tv-solution-content-col {
    padding: 20px 16px 20px 16px;
  }

  .tv-solution-title {
    font-size: 1.2rem;
  }

  .tv-solution-desc {
    font-size: 0.88rem;
  }

  .tv-product-card {
    padding: 0;
    border-radius: 14px;
  }

  .tv-product-thumb {
    height: 210px;
  }

  .tv-product-body {
    padding: 20px 16px 20px 16px;
  }

  .tv-product-title {
    font-size: 1.18rem;
  }

  .tv-product-desc {
    font-size: 0.88rem;
  }

  .tv-product-action {
    padding: 10px 16px;
    font-size: 0.85rem;
  }

  .tv-insight-thumb {
    height: 205px;
  }

  .tv-insight-body {
    padding: 20px 16px 20px 16px;
  }

  .tv-insight-title {
    font-size: 1.15rem;
  }
}

/* ==========================================================================
   DARK MODE — TEXT VISIBILITY FIXES
   Ensures headings and body copy are readable on dark card/surface bgs
   ========================================================================== */

/* All headings default to --text-primary in dark mode */
[data-theme="dark"] h1,
[data-theme="dark"] h2,
[data-theme="dark"] h3,
[data-theme="dark"] h4,
[data-theme="dark"] h5,
[data-theme="dark"] h6,
:root:not([data-theme="light"]) h1,
:root:not([data-theme="light"]) h2,
:root:not([data-theme="light"]) h3,
:root:not([data-theme="light"]) h4,
:root:not([data-theme="light"]) h5,
:root:not([data-theme="light"]) h6 {
  color: var(--text-primary);
}

/* Preserve intentional brand-coloured headings */
[data-theme="dark"] h2[style*="color: var(--text-brand)"],
[data-theme="dark"] h3[style*="color: var(--text-brand)"],
[data-theme="dark"] h4[style*="color: var(--text-brand)"],
:root:not([data-theme="light"]) h2[style*="color: var(--text-brand)"],
:root:not([data-theme="light"]) h3[style*="color: var(--text-brand)"],
:root:not([data-theme="light"]) h4[style*="color: var(--text-brand)"] {
  color: var(--text-brand) !important;
}

/* Small feature badge labels inside dark-surface mini-cards */
[data-theme="dark"] .fw-bold,
:root:not([data-theme="light"]) .fw-bold {
  color: var(--text-primary);
}

/* Bootstrap text-primary-emphasis is near-invisible in dark mode */
[data-theme="dark"] .text-primary-emphasis,
:root:not([data-theme="light"]) .text-primary-emphasis {
  color: var(--text-brand) !important;
}

/* Bootstrap outline button fix — invisible on dark bg */
[data-theme="dark"] .btn-outline-primary,
:root:not([data-theme="light"]) .btn-outline-primary {
  color: var(--brand-cyan) !important;
  border-color: var(--brand-cyan) !important;
}

[data-theme="dark"] .btn-outline-primary:hover,
:root:not([data-theme="light"]) .btn-outline-primary:hover {
  background-color: rgba(0, 166, 251, 0.12) !important;
  color: #ffffff !important;
}

/* Section headings that inline color: var(--text-brand) via style attr */
section h2,
section h3,
section h4 {
  color: var(--text-primary);
}

/* Ensure About mini-card text labels are always visible */
[data-theme="dark"] .d-flex.align-items-center h6,
:root:not([data-theme="light"]) .d-flex.align-items-center h6 {
  color: var(--text-primary) !important;
}

[data-theme="dark"] .d-flex.align-items-center small,
:root:not([data-theme="light"]) .d-flex.align-items-center small {
  color: var(--text-muted) !important;
}

/* ==========================================================================
   404 NOT FOUND PAGE
   ========================================================================== */
.tv-404-wrap {
  background: var(--bg-base);
  min-height: calc(100vh - 80px);
  display: flex;
  align-items: center;
}

.tv-404-section {
  position: relative;
  width: 100%;
  padding: 100px 0;
  overflow: hidden;
  text-align: center;
}

/* Giant faded 404 behind the content */
.tv-404-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(27, 117, 187, 0.18) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

.tv-404-inner {
  position: relative;
  z-index: 2;
  max-width: 680px;
  margin: 0 auto;
}

.tv-404-code {
  font-family: var(--font-heading);
  font-size: clamp(6rem, 18vw, 14rem);
  font-weight: 900;
  line-height: 1;
  letter-spacing: -0.05em;
  background: var(--brand-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  opacity: 0.18;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -60%);
  pointer-events: none;
  user-select: none;
  white-space: nowrap;
}

.tv-404-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: var(--brand-gradient-subtle);
  border: 1px solid rgba(27, 117, 187, 0.3);
  box-shadow: 0 0 40px rgba(27, 117, 187, 0.25);
  margin: 0 auto 8px;
  animation: tv-compass-rock 3s ease-in-out infinite;
}

.tv-404-icon i {
  font-size: 2.2rem;
  background: var(--brand-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Gentle compass-needle sway — "let us point you the right way" */
@keyframes tv-compass-rock {
  0% {
    transform: rotate(-15deg);
  }

  50% {
    transform: rotate(15deg);
  }

  100% {
    transform: rotate(-15deg);
  }
}

.tv-404-title {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 16px;
  line-height: 1.15;
}

.tv-404-lead {
  font-size: 1.05rem;
  color: var(--text-secondary);
  line-height: 1.75;
  max-width: 520px;
  margin: 0 auto 40px;
}

.tv-404-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
  margin-bottom: 48px;
}

/* Quick nav links */
.tv-404-links {
  border-top: 1px solid var(--border-subtle);
  padding-top: 32px;
}

.tv-404-links-label {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.tv-404-links-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
}

.tv-404-links-row a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 18px;
  border-radius: 50px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-size: 0.88rem;
  font-weight: 600;
  font-family: var(--font-heading);
  transition: var(--transition-smooth);
}

.tv-404-links-row a:hover {
  background: var(--bg-card-hover);
  border-color: var(--brand-cyan);
  color: var(--text-brand);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.tv-404-links-row a i {
  font-size: 0.85rem;
  color: var(--text-brand);
}

/* Mobile */
@media (max-width: 767.98px) {
  .tv-404-section {
    padding: 60px 0;
  }

  .tv-404-icon {
    width: 64px;
    height: 64px;
  }

  .tv-404-icon i {
    font-size: 1.8rem;
  }

  .tv-404-actions {
    flex-direction: column;
    align-items: center;
  }

  .tv-404-actions a {
    width: 100%;
    justify-content: center;
  }
}