/* Design System & Core Styles */
:root {
  /* Boutique dark palette inspired by the Polistyle reference */
  --color-bg: #0c0b09;
  --color-bg-alt: #141210;
  --color-card: rgba(30, 27, 23, 0.72);
  --color-border: rgba(201, 169, 110, 0.18);
  
  --color-primary: #c9a96e;
  --color-primary-light: #e0c88f;
  --color-primary-dark: #a78a56;
  
  --color-secondary: #8fa99a;
  --color-secondary-light: #b9d0c1;
  --color-secondary-dark: #617c6d;
  
  --color-text: #d8d0c4;
  --color-text-muted: #a99f91;
  --color-text-light: #fff8ec;
  --font-serif: 'Cormorant Garamond', Georgia, serif;
  --font-sans: 'Jost', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  
  /* Layout */
  --container-max-width: 1200px;
  --header-height: 80px;
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  
  /* Shadows */
  --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.3), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-glow-primary: 0 0 22px rgba(201, 169, 110, 0.28);
  --shadow-glow-secondary: 0 0 20px rgba(143, 169, 154, 0.22);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-height) + 16px);
  font-size: 16px;
}

body {
  background-color: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-sans);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

/* Typography */
h1, h2, h3, h4 {
  color: var(--color-text-light);
  font-family: var(--font-serif);
  font-weight: 600;
  letter-spacing: 0;
  line-height: 1.12;
}

h1 { font-size: clamp(2.5rem, 5vw, 4rem); }
h2 { font-size: clamp(1.8rem, 4vw, 2.6rem); }
h3 { font-size: clamp(1.4rem, 3vw, 1.8rem); }
h4 { font-size: 1.2rem; }

a {
  color: var(--color-primary-light);
  text-decoration: none;
  transition: var(--transition);
}

a:hover {
  color: var(--color-primary-light);
}

:focus-visible {
  outline: 2px solid var(--color-secondary-light);
  outline-offset: 4px;
}

body.menu-open {
  overflow: hidden;
}

/* Utilities */
.container {
  width: 100%;
  max-width: var(--container-max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 20px;
  padding-right: 20px;
}

.text-center { text-align: center; }

.gradient-text {
  background: linear-gradient(135deg, var(--color-primary-light) 0%, var(--color-secondary-light) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.glass-card {
  background: var(--color-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  transition: var(--transition);
  font-family: var(--font-sans);
  letter-spacing: 0;
}

.btn-sm {
  padding: 8px 16px;
  font-size: 0.85rem;
}

.btn-primary {
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
  color: var(--color-bg);
  box-shadow: var(--shadow-glow-primary);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 25px rgba(201, 169, 110, 0.5);
  background: linear-gradient(135deg, var(--color-primary-light) 0%, var(--color-primary) 100%);
}

.btn-secondary {
  background: linear-gradient(135deg, var(--color-secondary) 0%, var(--color-secondary-dark) 100%);
  color: var(--color-bg);
  box-shadow: var(--shadow-glow-secondary);
}

.btn-secondary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 25px rgba(143, 169, 154, 0.5);
  background: linear-gradient(135deg, var(--color-secondary-light) 0%, var(--color-secondary) 100%);
}

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

.btn-outline:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--color-text-muted);
}

.btn-block {
  display: flex;
  width: 100%;
}

/* Header */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--header-height);
  background: rgba(12, 11, 9, 0.8);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-border);
  z-index: 1000;
  display: flex;
  align-items: center;
  transition: var(--transition);
}

.header.scrolled {
  height: 70px;
  background: rgba(12, 11, 9, 0.95);
  box-shadow: var(--shadow-sm);
}

.header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--color-text-light);
  font-weight: 800;
  font-family: var(--font-sans);
  font-size: 1.4rem;
}

.logo-accent {
  background: linear-gradient(135deg, var(--color-primary-light) 0%, var(--color-primary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.logo-svg {
  color: var(--color-text-light);
}

.logo-img {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
}

.nav-list {
  display: flex;
  list-style: none;
  gap: 24px;
}

.nav-link {
  color: var(--color-text-muted);
  font-size: 0.95rem;
  font-weight: 500;
}

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

.header-actions {
  display: flex;
  align-items: center;
  gap: 24px;
}

.phone-link {
  color: var(--color-text-light);
  font-weight: 600;
  font-size: 0.95rem;
  font-family: var(--font-sans);
}

.email-link {
  color: var(--color-text-muted);
  font-weight: 600;
  font-size: 0.9rem;
  font-family: var(--font-sans);
}

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

.nav-contacts {
  display: none;
}

.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 24px;
  height: 18px;
  background: transparent;
  border: none;
  cursor: pointer;
}

.menu-toggle:focus-visible {
  outline: 2px solid var(--color-secondary-light);
  outline-offset: 6px;
}

.menu-toggle span {
  display: block;
  height: 2px;
  width: 100%;
  background-color: var(--color-text-light);
  border-radius: 2px;
  transition: var(--transition);
}

/* Hero Section */
.hero {
  padding-top: calc(var(--header-height) + 20px);
  padding-bottom: 46px;
  min-height: min(760px, 92svh);
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -10%;
  right: -10%;
  width: 50vw;
  height: 50vw;
  background: radial-gradient(circle, rgba(201, 169, 110, 0.08) 0%, rgba(201, 169, 110, 0) 70%);
  z-index: -1;
}

.hero-container {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 60px;
  align-items: center;
}

.hero-content {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.hero-kicker {
  color: var(--color-primary-light);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero-title {
  max-width: 780px;
  font-weight: 500;
}

.badge-container {
  display: flex;
}

.hero-badge {
  background: rgba(201, 169, 110, 0.1);
  border: 1px solid rgba(201, 169, 110, 0.2);
  color: var(--color-primary-light);
  padding: 6px 14px;
  border-radius: 100px;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero-subtitle {
  font-size: 1.12rem;
  color: var(--color-text-muted);
  max-width: 560px;
}

.hero-region {
  color: var(--color-primary-light);
  font-size: 0.95rem;
  font-weight: 600;
}

.hero-buttons {
  display: flex;
  gap: 16px;
  margin-top: 10px;
}

.hero-stats {
  display: flex;
  gap: 40px;
  margin-top: 20px;
  border-top: 1px solid var(--color-border);
  padding-top: 20px;
}

.stat-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.stat-num {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--color-text-light);
  font-family: var(--font-sans);
}

.stat-label {
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

/* ==========================================
   Matrix Canvas Visual (Hero)
   ========================================== */
.hero-visual {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

.matrix-container {
  position: relative;
  width: 100%;
  aspect-ratio: 4/3;
  max-width: 480px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border);
  background: #070706;
  overflow: hidden;
  box-shadow: 
    var(--shadow-lg), 
    0 30px 60px rgba(0, 0, 0, 0.4), 
    inset 0 0 30px rgba(201, 169, 110, 0.05);
}

#matrix-canvas {
  width: 100%;
  height: 100%;
  display: block;
}

.matrix-glow-overlay {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, transparent 30%, rgba(12, 11, 9, 0.8) 100%);
  pointer-events: none;
  z-index: 2;
}

/* Sections Structure */
section {
  padding: 40px 0;
  position: relative;
  scroll-margin-top: calc(var(--header-height) + 16px);
}

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

.section-header.text-center {
  margin-left: auto;
  margin-right: auto;
}

.section-subtitle {
  color: var(--color-primary-light);
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0;
  display: block;
  margin-bottom: 12px;
}

.section-title {
  margin-bottom: 20px;
}

.section-desc {
  color: var(--color-text-muted);
  font-size: 1.1rem;
}

/* Segment Choice */
.segment-choice {
  padding: 76px 0 70px;
  min-height: calc(100svh - var(--header-height));
  display: flex;
  align-items: center;
  background:
    radial-gradient(circle at 20% 10%, rgba(143, 169, 154, 0.08), transparent 30%),
    radial-gradient(circle at 80% 20%, rgba(201, 169, 110, 0.1), transparent 32%),
    var(--color-bg);
}

.segment-choice .container {
  transform: scale(var(--segment-scale, 0.96));
  transform-origin: center top;
  opacity: var(--segment-opacity, 0.82);
  transition: transform 0.12s linear, opacity 0.12s linear;
}

.segment-choice .section-header {
  max-width: 780px;
  margin-bottom: 36px;
}

.segment-choice-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-auto-rows: 1fr;
  align-items: stretch;
  gap: 24px;
}

.segment-card {
  position: relative;
  height: 100%;
  min-height: 390px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 18px;
  padding: 34px;
  text-align: left;
  color: var(--color-text);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.015)),
    rgba(30, 27, 23, 0.76);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  cursor: pointer;
  transition: var(--transition-slow);
  font: inherit;
}

.segment-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(120deg, rgba(201, 169, 110, 0.14), transparent 42%),
    radial-gradient(circle at top right, rgba(143, 169, 154, 0.18), transparent 38%);
  opacity: 0;
  transition: var(--transition-slow);
}

.segment-card > * {
  position: relative;
  z-index: 1;
}

.segment-card:hover,
.segment-card:focus-visible,
.segment-card.active {
  transform: translateY(-6px);
  border-color: rgba(143, 169, 154, 0.32);
  box-shadow: var(--shadow-lg), 0 18px 50px rgba(143, 169, 154, 0.08);
}

.segment-card:hover::before,
.segment-card:focus-visible::before,
.segment-card.active::before {
  opacity: 1;
}

.segment-card:focus-visible,
.segment-switch:focus-visible {
  outline: 2px solid var(--color-secondary-light);
  outline-offset: 4px;
}

.segment-card-kicker {
  color: var(--color-secondary-light);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
  font-family: var(--font-sans);
}

.segment-card-title {
  color: var(--color-text-light);
  font-size: clamp(1.9rem, 3vw, 2.6rem);
  line-height: 1.1;
  font-weight: 600;
  font-family: var(--font-serif);
}

.segment-card-text {
  max-width: 520px;
  color: var(--color-text);
  font-size: 1rem;
  line-height: 1.65;
}

.segment-points {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
}

.segment-points span {
  color: var(--color-text-light);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  padding: 8px 10px;
  font-size: 0.78rem;
  font-weight: 700;
}

.segment-card-cta {
  color: var(--color-text-light);
  font-size: 0.95rem;
  font-weight: 800;
  font-family: var(--font-sans);
}

.segment-card-cta::after {
  content: ' →';
  color: var(--color-secondary-light);
}

.region-note {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  align-items: center;
  justify-content: center;
  margin-top: 26px;
  color: var(--color-text-muted);
  font-size: 0.92rem;
}

.region-note strong {
  color: var(--color-primary-light);
  font-weight: 600;
}

/* Shared page layouts */
.page-hero {
  padding-top: calc(var(--header-height) + 40px);
  padding-bottom: 64px;
  min-height: min(720px, 88svh);
  display: flex;
  align-items: center;
  overflow: hidden;
}

.page-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.78fr);
  gap: 56px;
  align-items: center;
}

.page-kicker,
.eyebrow {
  color: var(--color-primary-light);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.page-lead {
  color: var(--color-text-muted);
  font-size: 1.12rem;
  max-width: 680px;
  margin-top: 20px;
}

.page-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 28px;
}

.hero-note,
.service-note {
  margin-top: 22px;
  padding: 18px 20px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.025);
  color: var(--color-text-muted);
}

.hero-note strong,
.service-note strong {
  color: var(--color-text-light);
}

.route-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.route-card {
  min-height: 320px;
  text-decoration: none;
}

.compact-section {
  padding: 64px 0;
}

.approach-band {
  background: radial-gradient(circle at top right, rgba(143, 169, 154, 0.05) 0%, rgba(201, 169, 110, 0.03) 70%), var(--color-bg-alt);
}

.contact-section {
  background: var(--color-bg-alt);
}

.contact-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: center;
  padding: 28px;
}

.contact-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: flex-end;
}

.crosslink-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  margin-top: 30px;
  padding: 24px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.025);
}

.crosslink-card p {
  color: var(--color-text-muted);
}

.visual-card {
  position: relative;
  min-height: 420px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: #070706;
  box-shadow: var(--shadow-lg);
}

.visual-card .services-image-diagram {
  inset: 0;
  width: 100%;
  height: 100%;
  left: 0;
  right: auto;
  top: 0;
  transform: none;
  border-radius: 0;
}

.visual-card .service-animation {
  opacity: 1;
  transform: none;
}

.visual-card .layer-completed {
  clip-path: inset(0 0 0 42%);
}

.visual-card .service-animation.active-state .layer-completed {
  clip-path: inset(0 0 0 0%);
}

.visual-caption {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 18px;
  z-index: 8;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.mode-badge {
  display: inline-flex;
  align-items: center;
  padding: 7px 10px;
  border-radius: var(--radius-sm);
  color: var(--color-text-light);
  background: rgba(8, 7, 6, 0.72);
  border: 1px solid var(--color-border);
  font-size: 0.76rem;
  font-weight: 800;
}

.geo-section {
  background:
    radial-gradient(circle at 15% 15%, rgba(143, 169, 154, 0.07), transparent 30%),
    radial-gradient(circle at 82% 18%, rgba(201, 169, 110, 0.08), transparent 34%),
    var(--color-bg);
}

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

.geo-chip {
  padding: 12px 14px;
  color: var(--color-text-light);
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  font-weight: 700;
}

.geo-details {
  margin-top: 28px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: rgba(30, 27, 23, 0.72);
  overflow: hidden;
}

.geo-details summary {
  cursor: pointer;
  padding: 20px 24px;
  color: var(--color-text-light);
  font-weight: 800;
  list-style-position: inside;
}

.geo-details summary:focus-visible {
  outline-offset: -4px;
}

.geo-details-body {
  padding: 0 24px 24px;
}

.geo-disclaimer {
  color: var(--color-text-muted);
  margin-bottom: 20px;
}

.direction-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.direction-card {
  padding: 18px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.025);
}

.direction-card h3 {
  font-size: 1.25rem;
  margin-bottom: 8px;
}

.direction-card p {
  color: var(--color-text-muted);
  font-size: 0.9rem;
  margin-bottom: 10px;
}

.direction-card ul {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
}

.direction-card li {
  padding: 6px 9px;
  border: 1px solid rgba(201, 169, 110, 0.14);
  border-radius: 6px;
  color: var(--color-text);
  background: rgba(255, 255, 255, 0.025);
  font-size: 0.82rem;
}

.business-geo {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 24px;
  align-items: start;
}

.legal-page {
  padding-top: calc(var(--header-height) + 40px);
  padding-bottom: 60px;
}

.legal-shell {
  max-width: 860px;
  padding: 40px;
}

.legal-shell h1 {
  font-size: 2rem;
  margin-bottom: 22px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--color-border);
}

.legal-shell h2 {
  font-size: 1.35rem;
  margin-top: 30px;
  margin-bottom: 12px;
}

.legal-shell p,
.legal-shell li {
  color: var(--color-text-muted);
  margin-bottom: 14px;
}

.legal-shell ul {
  padding-left: 20px;
  margin-bottom: 20px;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--color-primary);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 700;
  margin-bottom: 30px;
}

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

.legal-box {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  padding: 20px;
  margin: 30px 0 0;
}

/* Services Sections */
.services {
  background-color: var(--color-bg-alt);
  position: relative;
  overflow: hidden;
}

.services .container {
  position: relative;
  z-index: 10; /* Render safe above the background underlay */
}

.services .section-header {
  max-width: 100%;
  margin-bottom: 30px;
}

.segment-branches {
  padding: 70px 0;
}

.segment-branch {
  scroll-margin-top: calc(var(--header-height) + 24px);
  animation: fadeIn 0.4s ease-out;
}

.segment-branch-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: start;
  margin-bottom: 30px;
}

.segment-inline-switch {
  display: inline-flex;
  gap: 8px;
  padding: 6px;
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
}

.segment-switch {
  color: var(--color-text-muted);
  background: transparent;
  border: 1px solid transparent;
  border-radius: 6px;
  padding: 9px 13px;
  font-size: 0.82rem;
  font-weight: 800;
  cursor: pointer;
  transition: var(--transition);
  font-family: var(--font-sans);
  white-space: nowrap;
}

.segment-switch:hover {
  color: var(--color-text-light);
  background: rgba(255, 255, 255, 0.05);
}

.segment-switch.active {
  color: var(--color-bg);
  background: var(--color-primary);
  border-color: var(--color-primary);
}

.segment-branch .services-compact-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: stretch;
}

.segment-branch .services-compact-grid-wide {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.segment-branch .service-card {
  min-height: 218px;
  flex-direction: column;
  background: rgba(30, 27, 23, 0.82);
}

.segment-branch .card-desc {
  font-size: 0.88rem;
}

.branch-cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 30px;
}

.services-tabs {
  display: flex;
  gap: 12px;
  margin-bottom: 24px;
  border-bottom: 1px solid var(--color-border);
  padding-bottom: 16px;
  width: 100%;
  position: relative;
  z-index: 2;
}

.tab-btn {
  background: transparent;
  border: 1px solid transparent;
  color: var(--color-text-muted);
  padding: 8px 16px;
  font-size: 0.9rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
  font-family: var(--font-sans);
}

.tab-btn:hover {
  color: var(--color-text-light);
  background: rgba(255,255,255,0.02);
}

.tab-btn.active {
  color: var(--color-primary-light);
  border-color: rgba(201, 169, 110, 0.2);
  background: rgba(201, 169, 110, 0.08);
}

.services-wrapper {
  position: relative;
  z-index: 2;
  width: 58%;
  max-width: 700px;
}

.services-panel {
  display: none;
}

.services-panel.active {
  display: block;
  animation: fadeIn 0.4s ease-out;
}

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

/* Compact Grid & Service Cards */
.services-compact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.service-card {
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 20px;
  display: flex;
  gap: 16px;
  box-shadow: var(--shadow-sm);
  transition: var(--transition-slow);
}

.service-card:hover {
  transform: translateY(-4px);
  border-color: rgba(143, 169, 154, 0.2);
  background: rgba(30, 27, 23, 0.9);
  box-shadow: var(--shadow-lg), 0 8px 24px rgba(143, 169, 154, 0.04);
}

.card-icon {
  width: 44px;
  height: 44px;
  background: rgba(201, 169, 110, 0.08);
  border: 1px solid rgba(201, 169, 110, 0.15);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-primary-light);
  flex-shrink: 0;
}

.card-icon svg {
  width: 20px;
  height: 20px;
}

.card-text {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.card-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--color-text-light);
}

.card-desc {
  font-size: 0.82rem;
  color: var(--color-text-muted);
  line-height: 1.4;
}

/* Background Underlay Animation Container */
.services-animation-container {
  position: absolute;
  left: 0; /* Starts full width to allow wider diagrams */
  right: 0;
  top: 0;
  bottom: 0;
  z-index: 1;
  pointer-events: none;
  user-select: none;
  overflow: hidden;
}

.services-animation-fade {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, 
    #0c0b09 0%, 
    #0c0b09 32%,
    rgba(12, 11, 9, 0.92) 48%,
    rgba(12, 11, 9, 0.45) 75%, 
    transparent 100%
  );
  z-index: 6;
  pointer-events: none;
}

.service-animation {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  pointer-events: none;
  transform: scale(0.97);
  transition: opacity 0.5s cubic-bezier(0.4, 0, 0.2, 1), transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  align-items: center;
  justify-content: center;
}

.service-animation.active {
  opacity: 1;
  pointer-events: auto;
  transform: scale(1);
  z-index: 5;
}

/* 1. Business SVG Animation Styles */
.services-svg-diagram {
  position: absolute;
  left: calc(50% - 150px); /* Starts around the middle of the right cards */
  right: 0; /* Stretches to the right screen edge */
  top: 50%;
  transform: translateY(-50%);
  height: 85%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  transition: var(--transition);
}

.business-svg {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* Cable Mess Chaos Layer */
.cable-mess {
  opacity: 1;
  transition: opacity 1.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.service-animation.active-state .cable-mess {
  opacity: 0;
  pointer-events: none;
}

.warning-beacon {
  animation: flash-red 1s infinite alternate;
}

@keyframes flash-red {
  0% { fill: #ef4444; filter: drop-shadow(0 0 1px #ef4444); opacity: 0.6; }
  100% { fill: #f87171; filter: drop-shadow(0 0 8px #ef4444); opacity: 1; }
}

/* Cable Clean Organized Layer */
.cable-clean {
  opacity: 0;
  transform: scale(0.95);
  transform-origin: center;
  transition: opacity 2s cubic-bezier(0.4, 0, 0.2, 1) 0.8s, transform 2s cubic-bezier(0.2, 0.8, 0.2, 1) 0.8s;
}

.service-animation.active-state .cable-clean {
  opacity: 1;
  transform: scale(1);
}

/* 2. Residential Image Comparison Sweep Styles */
.services-image-diagram {
  position: absolute;
  left: calc(50% - 150px); /* Starts around the middle of the right cards */
  right: 0; /* Stretches to the right screen edge */
  top: 50%;
  transform: translateY(-50%);
  height: 85%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  transition: var(--transition);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0,0,0,0.5);
}

/* Blend mask overlay to soften photo boundaries on the dark background */
.services-image-diagram::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, transparent 35%, #0c0b09 100%);
  z-index: 4;
  pointer-events: none;
}

.anim-grid-decor {
  position: absolute;
  inset: 0;
  background-image: 
    linear-gradient(rgba(255,255,255,0.015) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.015) 1px, transparent 1px);
  background-size: 20px 20px;
  z-index: 1;
  pointer-events: none;
}

.anim-layer {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  user-select: none;
}

.anim-layer img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.layer-blueprint {
  z-index: 2;
  filter: contrast(1.05) brightness(0.9);
}

.layer-completed {
  z-index: 3;
  /* Automatically sweep in when active-state is added */
  clip-path: inset(0 0 0 100%);
  transition: clip-path 8s cubic-bezier(0.25, 1, 0.5, 1);
}

.service-animation.active-state .layer-completed {
  clip-path: inset(0 0 0 0%);
}

/* About / Process Section */
.about-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  align-items: center;
}

.steps-container {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-top: 24px;
}

.step-card {
  display: flex;
  gap: 20px;
}

.step-num {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--color-primary-light);
  background: rgba(201, 169, 110, 0.07);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border: 1px solid rgba(201, 169, 110, 0.15);
  font-family: var(--font-sans);
}

.step-text h4 {
  margin-bottom: 6px;
  font-size: 1.1rem;
}

.step-text p {
  font-size: 0.95rem;
  color: var(--color-text-muted);
}

.about-visual {
  display: flex;
  justify-content: center;
}

.quote-card {
  padding: 48px;
  position: relative;
  max-width: 420px;
  border-left: 4px solid var(--color-primary);
}

.quote-icon {
  position: absolute;
  top: 10px;
  left: 20px;
  font-size: 5rem;
  font-family: Georgia, serif;
  color: rgba(201, 169, 110, 0.05);
  line-height: 1;
}

.quote-body {
  font-size: 1.05rem;
  font-style: italic;
  color: var(--color-text-light);
  position: relative;
  z-index: 2;
  margin-bottom: 24px;
}

.quote-author {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.author-name {
  font-weight: 700;
  color: var(--color-text-light);
  font-size: 0.95rem;
}

.author-title {
  font-size: 0.8rem;
  color: var(--color-text-muted);
}

/* Penultimate "Для самых внимательных" Section */
.attentive {
  background: radial-gradient(circle at top right, rgba(143, 169, 154, 0.05) 0%, rgba(201, 169, 110, 0.03) 70%), var(--color-bg-alt);
  padding: 45px 0;
  overflow: hidden;
}

.attentive-box {
  background: var(--color-card);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 30px;
  max-width: 860px;
  margin-left: auto;
  margin-right: auto;
  position: relative;
  box-shadow: var(--shadow-lg), 0 20px 40px rgba(0,0,0,0.3);
}

.attentive-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(143, 169, 154, 0.1);
  border: 1px solid rgba(143, 169, 154, 0.2);
  color: var(--color-secondary-light);
  padding: 6px 14px;
  border-radius: 100px;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0;
  margin-bottom: 24px;
  font-family: var(--font-sans);
}

.attentive-title {
  margin-bottom: 30px;
  line-height: 1.3;
}

.attentive-content {
  display: flex;
  flex-direction: column;
  gap: 20px;
  position: relative;
  z-index: 2;
}

.attentive-content p {
  font-size: 1.05rem;
  color: var(--color-text);
  line-height: 1.7;
}

.attentive-content strong {
  color: var(--color-text-light);
}

.attentive-footer-text {
  border-top: 1px solid var(--color-border);
  padding-top: 20px;
  color: var(--color-text-muted);
}

.attentive-mascot {
  position: absolute;
  bottom: 20px;
  right: 20px;
  opacity: 0.15;
  pointer-events: none;
  z-index: 1;
}

/* Callback / Calendar Form Section */
.callback-section {
  padding-bottom: 45px;
}

.callback-grid {
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: 48px;
  align-items: stretch;
}

.callback-info {
  display: flex;
  flex-direction: column;
  height: auto;
}

.contact-details {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-top: 30px;
}

.contact-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 20px;
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
}

.contact-icon {
  font-size: 1.5rem;
}

.contact-label {
  display: block;
  font-size: 0.75rem;
  color: var(--color-text-muted);
  text-transform: uppercase;
}

.contact-value {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--color-text-light);
}

.callback-form-container {
  padding: 30px;
}

.lead-form {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

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

.form-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-text-light);
  font-family: var(--font-sans);
}

.form-input {
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--color-border);
  padding: 12px 16px;
  color: var(--color-text-light);
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  transition: var(--transition);
  outline: none;
  font-family: inherit;
}

.form-input:focus {
  border-color: var(--color-primary-light);
  background: rgba(255,255,255,0.06);
  box-shadow: 0 0 10px rgba(201, 169, 110, 0.15);
}

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

.form-hint {
  color: var(--color-text-muted);
  font-size: 0.76rem;
  line-height: 1.4;
}

.lead-honeypot {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.captcha-group {
  min-height: 106px;
}

.smart-captcha {
  max-width: 100%;
  overflow: hidden;
}

.smart-captcha-placeholder {
  display: flex;
  align-items: center;
  min-height: 76px;
  padding: 14px 16px;
  color: var(--color-text-muted);
  background: rgba(255, 255, 255, 0.025);
  border: 1px dashed var(--color-border);
  border-radius: var(--radius-sm);
  font-size: 0.82rem;
  line-height: 1.4;
}

.segment-form-note {
  color: var(--color-secondary-light);
  font-size: 0.82rem;
  font-weight: 800;
  font-family: var(--font-sans);
}

.form-error {
  font-size: 0.75rem;
  color: #ef4444;
  height: 16px;
}

/* Custom Calendar Widget Styles (Compact 25% smaller for premium UX) */
.calendar-widget {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  padding: 14px;
  width: 100%;
  max-width: 380px; /* Compact maximum width (25% smaller) */
  box-sizing: border-box;
  margin: 0 auto; /* Centered horizontally */
}

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

.calendar-nav-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--color-border);
  width: 30px;
  height: 30px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text-light);
  cursor: pointer;
  transition: var(--transition);
  font-size: 0.85rem;
}

.calendar-nav-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--color-text-light);
}

.calendar-month-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--color-text-light);
  font-family: var(--font-sans);
  letter-spacing: 0;
}

.calendar-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  text-align: center;
  font-size: 0.75rem;
  color: var(--color-text-muted);
  font-weight: 700;
  margin-bottom: 8px;
}

.calendar-weekdays .weekend {
  color: rgba(239, 68, 68, 0.9);
}

.calendar-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
}

.calendar-day-cell {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: 600;
  border-radius: 6px;
  cursor: pointer;
  transition: var(--transition);
  color: var(--color-text);
  border: none;
  background: transparent;
}

.calendar-day-cell:hover:not(.disabled) {
  background: rgba(255, 255, 255, 0.08);
  color: var(--color-text-light);
}

.calendar-day-cell.selected {
  background: var(--color-primary);
  color: var(--color-text-light);
  font-weight: 700;
  box-shadow: var(--shadow-glow-primary);
}

.calendar-day-cell.disabled {
  color: rgba(255,255,255,0.12);
  cursor: not-allowed;
  pointer-events: none;
}

.calendar-day-cell.today {
  border: 1px solid rgba(201, 169, 110, 0.4);
}

/* Weekend Highlight */
.calendar-day-cell.weekend:not(.disabled) {
  color: rgba(239, 68, 68, 0.95);
  font-weight: 600;
}
.calendar-day-cell.weekend.disabled {
  color: rgba(239, 68, 68, 0.35);
}

/* Call booking slots Russified hint styling */
.time-slots-hint {
  font-size: 0.72rem;
  color: var(--color-text-muted);
  line-height: 1.45;
  margin-top: 10px;
  border-left: 2px solid var(--color-primary-light);
  padding-left: 8px;
}

/* Time slots grid */
.time-slots-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(70px, 1fr));
  gap: 8px;
  margin-top: 6px;
}

.time-slot {
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--color-border);
  padding: 8px 0;
  font-size: 0.8rem;
  font-weight: 600;
  text-align: center;
  border-radius: 4px;
  cursor: pointer;
  color: var(--color-text);
  transition: var(--transition);
}

.time-slot:hover {
  background: rgba(255,255,255,0.08);
  color: var(--color-text-light);
  border-color: var(--color-text-muted);
}

.time-slot.selected {
  background: var(--color-secondary);
  color: var(--color-bg);
  border-color: var(--color-secondary-light);
  box-shadow: var(--shadow-glow-secondary);
}

/* Consent FZ-152 styling */
.form-consent-group {
  margin-top: 10px;
}

.consent-row {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
}

.consent-checkbox-label {
  display: flex;
  align-items: flex-start;
  cursor: pointer;
  user-select: none;
}

.consent-checkbox {
  position: absolute;
  opacity: 0;
  cursor: pointer;
  height: 0;
  width: 0;
}

.consent-checkbox-custom {
  width: 18px;
  height: 18px;
  border: 1px solid var(--color-border);
  border-radius: 4px;
  background: rgba(255,255,255,0.03);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: var(--transition);
  margin-top: 3px;
}

.consent-checkbox:checked ~ .consent-checkbox-custom {
  background: var(--color-secondary);
  border-color: var(--color-secondary);
}

.consent-checkbox-custom::after {
  content: '';
  display: none;
  width: 5px;
  height: 10px;
  border: solid var(--color-bg);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
  margin-bottom: 2px;
}

.consent-checkbox:checked ~ .consent-checkbox-custom::after {
  display: block;
}

.consent-text {
  margin: 0;
  font-size: 0.78rem;
  color: var(--color-text-muted);
  line-height: 1.4;
}

.consent-links {
  grid-column: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  margin-top: 2px;
}

.consent-link {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  text-decoration: underline;
  color: var(--color-text-muted);
  font-size: 0.78rem;
}

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

/* Success Form State */
.form-success-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px 0;
  animation: fadeIn 0.4s ease-out;
}

.success-icon {
  width: 64px;
  height: 64px;
  background: rgba(143, 169, 154, 0.1);
  color: var(--color-secondary-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
  border: 1px solid rgba(143, 169, 154, 0.2);
  box-shadow: var(--shadow-glow-secondary);
}

.success-icon svg {
  width: 32px;
  height: 32px;
}

.success-title {
  margin-bottom: 12px;
}

.success-msg {
  font-size: 0.95rem;
  color: var(--color-text-muted);
  max-width: 460px;
  margin-bottom: 30px;
  line-height: 1.5;
}

.success-msg strong {
  color: var(--color-text-light);
}

/* Cookie Banner */
.cookie-banner {
  position: fixed;
  bottom: 24px;
  left: 24px;
  right: 24px;
  max-width: 600px;
  background: rgba(30, 27, 23, 0.9);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  padding: 16px 24px;
  z-index: 1000;
  display: flex;
  align-items: center;
  box-shadow: var(--shadow-lg);
  animation: slideUp 0.5s ease-out;
}

.cookie-banner.hidden {
  display: none;
}

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

.cookie-banner-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  gap: 20px;
}

.cookie-banner-content p {
  font-size: 0.8rem;
  color: var(--color-text-muted);
  line-height: 1.4;
}

.cookie-banner-content a {
  text-decoration: underline;
  color: var(--color-text-muted);
}

.cookie-banner-content a:hover {
  color: var(--color-text-light);
}

/* Footer */
.footer {
  background: #080706;
  border-top: 1px solid var(--color-border);
  padding: 35px 0 0 0;
}

.footer-container {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr 1fr;
  gap: 40px;
  padding-bottom: 40px;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.footer-about-text {
  font-size: 0.9rem;
  color: var(--color-text-muted);
  max-width: 320px;
}

.footer-links-group {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.footer-title {
  font-size: 1rem;
}

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

.footer-links a {
  color: var(--color-text-muted);
  font-size: 0.9rem;
}

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

.footer-legal-detail {
  font-size: 0.8rem;
  color: var(--color-text-muted);
}

.footer-bottom {
  border-top: 1px solid var(--color-border);
  padding: 30px 0;
}

.copyright {
  font-size: 0.8rem;
  color: var(--color-text-muted);
}

/* Responsive Styles */
@media (max-width: 1100px) {
  .header-email {
    display: none;
  }
}

@media (max-width: 992px) {
  .hero-container {
    grid-template-columns: 1fr;
    gap: 50px;
    text-align: center;
  }
  
  .hero-content {
    align-items: center;
  }
  
  .hero-subtitle {
    margin-left: auto;
    margin-right: auto;
  }
  
  .hero-buttons {
    justify-content: center;
  }
  
  .hero-stats {
    justify-content: center;
  }
  
  .about-grid {
    grid-template-columns: 1fr;
    gap: 50px;
  }
  
  .services-animation-container {
    left: 0;
    width: 100%;
    opacity: 0.12; /* subtle behind cards on mobile stack */
  }
  
  .services-wrapper {
    width: 100%;
  }

  .segment-branch-head {
    grid-template-columns: 1fr;
  }

  .segment-inline-switch {
    width: fit-content;
  }

  .segment-branch .services-compact-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  
  .services-svg-diagram,
  .services-image-diagram {
    left: auto;
    right: 50%;
    transform: translate(50%, -50%);
    width: 85%;
    max-width: 360px;
  }
  
  .about-visual {
    order: -1;
  }
  
  .callback-grid {
    grid-template-columns: 1fr;
    gap: 60px;
  }

  .page-hero-grid,
  .business-geo {
    grid-template-columns: 1fr;
  }

  .page-hero {
    min-height: auto;
  }

  .visual-card {
    min-height: 360px;
  }
  
  .callback-info {
    height: auto;
  }
  
  .contact-details {
    margin-top: 30px;
  }
  
  .footer-container {
    grid-template-columns: 1fr 1fr;
    gap: 50px;
  }
}

@media (max-width: 768px) {
  .nav {
    position: fixed;
    top: var(--header-height);
    left: 0;
    right: 0;
    width: auto;
    height: calc(100vh - var(--header-height));
    background: var(--color-bg);
    z-index: 999;
    padding: 40px;
    transition: var(--transition-slow);
    border-right: none;
    transform: translateX(-100%);
    overflow-y: auto;
  }
  
  .nav.active {
    transform: translateX(0);
  }
  
  .nav-list {
    flex-direction: column;
    gap: 22px;
  }
  
  .nav-link {
    font-size: 1.2rem;
  }

  .nav-contacts {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-top: 18px;
    padding-top: 22px;
    border-top: 1px solid var(--color-border);
  }
  
  .menu-toggle {
    display: flex;
  }
  
  .menu-toggle.active span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
  }
  
  .menu-toggle.active span:nth-child(2) {
    opacity: 0;
  }
  
  .menu-toggle.active span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
  }
  
  .header-actions {
    display: flex;
    gap: 10px;
  }

  .header-actions .btn,
  .header-email {
    display: none;
  }

  .phone-link {
    font-size: 0.82rem;
    white-space: nowrap;
  }

  .segment-choice-grid {
    grid-template-columns: 1fr;
  }

  .route-grid,
  .direction-grid,
  .geo-main-grid,
  .contact-panel,
  .crosslink-card {
    grid-template-columns: 1fr;
  }

  .contact-actions,
  .crosslink-card .btn {
    justify-content: flex-start;
  }

  .segment-card {
    min-height: 310px;
    padding: 28px;
  }
  
  .footer-container {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  
  .attentive-box {
    padding: 30px;
  }
  
  .callback-form-container {
    padding: 24px;
  }
  
  .cookie-banner {
    flex-direction: column;
    gap: 12px;
    text-align: center;
  }
  
  .cookie-banner-content {
    flex-direction: column;
    gap: 12px;
  }
}

@media (max-width: 480px) {
  .container {
    padding-left: 16px;
    padding-right: 16px;
  }

  .logo-text {
    font-size: 1.12rem;
  }

  .logo-img {
    width: 34px;
    height: 34px;
  }

  .phone-link {
    font-size: 0.76rem;
  }

  .page-actions,
  .contact-actions {
    flex-direction: column;
  }

  .page-actions .btn,
  .contact-actions .btn {
    width: 100%;
  }

  .visual-card {
    min-height: 300px;
  }

  .hero-buttons {
    flex-direction: column;
    width: 100%;
  }
  
  .hero-buttons .btn {
    width: 100%;
  }
  
  .hero-stats {
    flex-wrap: wrap;
    gap: 20px 40px;
  }

  .segment-inline-switch,
  .branch-cta-row {
    width: 100%;
  }

  .segment-switch,
  .branch-cta-row .btn {
    flex: 1 1 100%;
  }

  .segment-branch .services-compact-grid,
  .services-compact-grid {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.001ms !important;
  }
}

/* ==========================================
   Residential Image comparison slider Showcase
   ========================================== */
.residential-showcase {
  margin-top: 80px;
  border-top: 1px solid var(--color-border);
  padding-top: 80px;
}

.showcase-header {
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 40px;
}

.showcase-title {
  font-size: clamp(1.4rem, 3vw, 1.8rem);
  margin-bottom: 12px;
}

.showcase-subtitle {
  font-size: 0.95rem;
  color: var(--color-text-muted);
}

.interactive-diagram.image-diagram {
  aspect-ratio: 16/9;
  max-width: 860px;
  margin-left: auto;
  margin-right: auto;
  background: #080706;
}

.showcase-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
}

#res-layer-completed {
  z-index: 3;
  clip-path: inset(0 0 0 50%);
  transition: clip-path 0.05s ease-out;
}

#res-slider-bar {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 2px;
  background: linear-gradient(to bottom, var(--color-primary-light) 0%, var(--color-secondary-light) 100%);
  z-index: 4;
  box-shadow: 0 0 10px var(--color-primary-light);
  pointer-events: none;
  transition: left 0.05s ease-out;
}

#res-slider-handle {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 44px;
  height: 44px;
  background: #241f19;
  border: 2px solid var(--color-primary-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text-light);
  cursor: ew-resize;
  z-index: 5;
  box-shadow: 0 0 15px rgba(201, 169, 110, 0.4), var(--shadow-sm);
  transition: left 0.05s ease-out, transform 0.2s, border-color 0.2s;
}

#res-slider-handle:hover {
  transform: translate(-50%, -50%) scale(1.1);
  border-color: var(--color-secondary-light);
  box-shadow: 0 0 20px rgba(143, 169, 154, 0.5);
}
