/* ==========================================================================
   Hereford ClearView - Core Styling & Design System
   ========================================================================== */

/* Design Tokens & Custom Properties */
:root {
  /* Color Palette */
  --primary: #4a90e2;        /* Softer Sky Blue */
  --primary-glow: #f0f6fc;   /* Light Blue tint */
  --primary-hover: #357abd;  /* Deeper Blue */
  --secondary: #0f172a;      /* Slate Black */
  --secondary-light: #1e293b;/* Slate Navy */
  --accent: #f59e0b;         /* Gold Accent */
  --accent-glow: #fef3c7;    /* Light Gold tint */
  --bg-light: #f8fafc;       /* Clear Off-white */
  --bg-dark: #020617;        /* Midnight Slate */
  --surface: #ffffff;        /* Pure White Surface */
  --border: #e2e8f0;         /* Light Grey Border */
  --text: #0f172a;           /* Dark Slate Text */
  --text-muted: #64748b;     /* Muted Grey Text */
  --error: #ef4444;          /* Validation Red */
  --error-glow: #fee2e2;     /* Error BG tint */
  --success: #10b981;        /* Success Green */
  
  /* Typography */
  --font-heading: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  
  /* Layout Spacing & Borders */
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-full: 9999px;
  --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.1);
  --shadow-md: 0 10px 25px -5px rgba(15, 23, 42, 0.08), 0 8px 10px -6px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 20px 40px -15px rgba(15, 23, 42, 0.12);
  
  /* Dimensions */
  --header-height: 90px;
  --header-height-shrunk: 65px;
}

/* ==========================================================================
   1. CSS Reset & Typography Base
   ========================================================================== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-height-shrunk) + 20px);
}

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background-color: var(--bg-light);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  scrollbar-gutter: stable; /* Avoid layout shifts on scrollbar appearance */
}

/* Custom Scrollbar Styles */
::-webkit-scrollbar {
  width: 10px;
}
::-webkit-scrollbar-track {
  background: var(--bg-light);
}
::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: var(--radius-full);
  border: 2px solid var(--bg-light);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--text-muted);
}

/* Typographic Alignment best practices */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.25;
  color: var(--secondary);
  text-wrap: balance; /* Symmetrical wrapping on short lines */
}

p, li, blockquote {
  text-wrap: pretty; /* Prevents typographic orphans (runts) */
  color: var(--text-muted);
}

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

ul {
  list-style: none;
}

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

.container {
  width: 100%;
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: 1.5rem;
}

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

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.875rem 1.75rem;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1rem;
  border-radius: var(--radius-md);
  border: 2px solid transparent;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.btn-primary {
  background-color: var(--primary);
  color: var(--surface);
  box-shadow: 0 4px 14px rgba(74, 144, 226, 0.4);
}
.btn-primary:hover {
  background-color: var(--primary-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(74, 144, 226, 0.5);
}

.btn-secondary {
  background-color: rgba(255, 255, 255, 0.15);
  color: var(--surface);
  border-color: rgba(255, 255, 255, 0.25);
  backdrop-filter: blur(8px);
}
.btn-secondary:hover {
  background-color: rgba(255, 255, 255, 0.3);
  border-color: rgba(255, 255, 255, 0.5);
  transform: translateY(-2px);
}

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

/* ==========================================================================
   2. Header & Sticky Shrinking Navigation
   ========================================================================== */
#main-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background-color: rgba(255, 255, 255, 0.8);
  border-bottom: 1px solid rgba(226, 232, 240, 0.5);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  height: var(--header-height);
  transition: var(--transition-smooth);
  
  /* CSS Scroll-driven animations declaration */
  animation: shrink-nav auto linear both;
  animation-timeline: scroll(block root);
  animation-range: 0px 150px;
}

@keyframes shrink-nav {
  to {
    height: var(--header-height-shrunk);
    background-color: rgba(255, 255, 255, 0.95);
    border-bottom-color: var(--border);
    box-shadow: var(--shadow-sm);
  }
}

.header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  max-width: 1250px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.35rem;
  color: var(--secondary);
}
.logo-icon {
  color: var(--primary);
  filter: drop-shadow(0 2px 4px rgba(74, 144, 226, 0.2));
  transition: var(--transition-smooth);
}
.logo:hover .logo-icon {
  transform: rotate(15deg) scale(1.1);
}
.accent-text {
  color: var(--primary);
}

/* Navigation Links */
.nav-list {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav-link {
  font-family: var(--font-heading);
  font-weight: 500;
  color: var(--text-muted);
  position: relative;
  padding: 0.5rem 0;
}
.nav-link:hover {
  color: var(--primary);
}
.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--primary);
  transition: var(--transition-smooth);
}
.nav-link:hover::after {
  width: 100%;
}

.nav-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 1.25rem;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.95rem;
  background-color: var(--primary);
  color: var(--surface);
  border-radius: var(--radius-sm);
  box-shadow: 0 4px 10px rgba(74, 144, 226, 0.2);
}
.nav-btn:hover {
  background-color: var(--primary-hover);
  transform: translateY(-1px);
  box-shadow: 0 6px 15px rgba(74, 144, 226, 0.35);
}

/* Mobile Toggle Hamburger */
.mobile-nav-toggle {
  display: none;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  z-index: 1001;
}
.hamburger-lines {
  width: 24px;
  height: 18px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.hamburger-lines .line {
  display: block;
  height: 2px;
  width: 100%;
  border-radius: var(--radius-full);
  background: var(--secondary);
  transition: transform 0.3s ease-in-out, opacity 0.2s ease-in-out;
}

/* Animated toggle to X state when menu open */
.mobile-nav-toggle[aria-expanded="true"] .line1 {
  transform: translateY(8px) rotate(45deg);
}
.mobile-nav-toggle[aria-expanded="true"] .line2 {
  opacity: 0;
}
.mobile-nav-toggle[aria-expanded="true"] .line3 {
  transform: translateY(-8px) rotate(-45deg);
}

/* ==========================================================================
   3. Hero Section (Parallax and Gradient Overlays)
   ========================================================================== */
.hero-section {
  position: relative;
  min-height: 90dvb;
  display: flex;
  align-items: center;
  padding-top: var(--header-height);
  color: var(--surface);
  overflow: hidden;
}

.hero-background-wrapper {
  position: absolute;
  inset: 0;
  z-index: -1;
}

.hero-bg-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 25%;
  /* Parallax effect on scroll natively in modern browsers */
  animation: hero-scroll auto linear both;
  animation-timeline: scroll(block root);
  animation-range: start 100vh;
}

@keyframes hero-scroll {
  to {
    transform: translateY(150px);
  }
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.85) 40%, rgba(74, 144, 226, 0.4) 100%);
  backdrop-filter: blur(2px);
}

.hero-content {
  position: relative;
  z-index: 10;
  max-width: 800px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1.5rem;
  padding-block: 4rem;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background-color: rgba(74, 144, 226, 0.2);
  border: 1px solid rgba(74, 144, 226, 0.4);
  color: var(--primary-glow);
  padding: 0.5rem 1rem;
  border-radius: var(--radius-full);
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.9rem;
  backdrop-filter: blur(10px);
}

.hero-title {
  font-size: clamp(2.5rem, 5vw, 4.5rem);
  line-height: 1.1;
  color: var(--surface);
  font-weight: 800;
  letter-spacing: -0.02em;
}

.hero-subtitle {
  font-size: clamp(1.1rem, 2vw, 1.35rem);
  color: rgba(248, 250, 252, 0.85);
  max-width: 650px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-block-start: 1rem;
}

.hero-stats {
  display: flex;
  gap: 3rem;
  margin-block-start: 3rem;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  padding-block-start: 2rem;
  width: 100%;
}

.stat-item {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.stat-num {
  font-family: var(--font-heading);
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--surface);
  line-height: 1;
}

.stat-label {
  font-size: 0.85rem;
  color: rgba(248, 250, 252, 0.7);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.scroll-down-indicator {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  color: rgba(255, 255, 255, 0.6);
  animation: bounce 2s infinite;
  display: flex;
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% { transform: translateY(0) translateX(-50%); }
  40% { transform: translateY(-10px) translateX(-50%); }
  60% { transform: translateY(-5px) translateX(-50%); }
}

/* ==========================================================================
   4. Sections Shared Styling & Features
   ========================================================================== */
section {
  padding-block: 6rem;
}

.section-header {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 4rem auto;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.section-title {
  font-size: clamp(2rem, 3.5vw, 2.75rem);
  font-weight: 800;
  letter-spacing: -0.01em;
}

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

/* Why Choose Us Feature Cards Grid */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 2rem;
}

.feature-card {
  background-color: var(--surface);
  padding: 2.5rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
  transition: var(--transition-smooth);
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.feature-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(74, 144, 226, 0.2);
}

.feature-icon-container {
  width: 56px;
  height: 56px;
  background-color: var(--primary-glow);
  color: var(--primary);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-smooth);
}

.feature-card:hover .feature-icon-container {
  background-color: var(--primary);
  color: var(--surface);
  transform: rotate(5deg);
}

.feature-card h3 {
  font-size: 1.25rem;
  color: var(--secondary);
}

.feature-card p {
  font-size: 0.95rem;
}

/* ==========================================================================
   5. Services Section (Beautiful gradient visuals)
   ========================================================================== */
.services-section {
  background-color: var(--bg-light);
  border-block: 1px solid var(--border);
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
  gap: 2rem;
}

.service-card {
  background-color: var(--surface);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  transition: var(--transition-smooth);
}

.service-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
  border-color: rgba(74, 144, 226, 0.25);
}

/* Service visual placeholders using premium background images */
.service-img-placeholder {
  height: 180px;
  position: relative;
  display: flex;
  align-items: flex-end;
  padding: 1.25rem;
  background-size: cover;
  background-position: center;
}

.residential-service-img {
  background-image: linear-gradient(to top, rgba(15, 23, 42, 0.6) 0%, transparent 60%), url('residential-window-cleaning.jpg');
}

.commercial-service-img {
  background-image: linear-gradient(to top, rgba(15, 23, 42, 0.6) 0%, transparent 60%), url('commercial-window-cleaning.jpg');
}

.gutter-service-img {
  background-image: linear-gradient(to top, rgba(15, 23, 42, 0.6) 0%, transparent 60%), url('gutter-clearing.jpg');
}

.conservatory-service-img {
  background-image: linear-gradient(to top, rgba(15, 23, 42, 0.6) 0%, transparent 60%), url('conservatory-cleaning.jpg');
}

.service-overlay-content {
  position: relative;
  z-index: 10;
  display: flex;
  width: 100%;
  justify-content: flex-start;
}

.service-price-tag {
  background-color: var(--surface);
  color: var(--text);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.9rem;
  padding: 0.4rem 0.8rem;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
}

.service-content {
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  flex: 1;
}

.service-content h3 {
  font-size: 1.35rem;
}

.service-content p {
  font-size: 0.95rem;
}

.service-features {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-block-start: auto;
  padding-block-start: 1rem;
  border-top: 1px solid var(--border);
}

.service-features li {
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text);
  font-weight: 500;
}

.service-features li::before {
  content: '';
  display: inline-block;
  width: 6px;
  height: 6px;
  background-color: var(--primary);
  border-radius: var(--radius-full);
}

/* ==========================================================================
   6. Pricing & Interactive Estimator Section
   ========================================================================== */
.pricing-section {
  display: flex;
  flex-direction: column;
}

.pricing-card-wrapper {
  background-color: var(--surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
  overflow: hidden;
}

.estimator-container {
  display: flex;
  flex-direction: column;
}

.estimator-header {
  background: linear-gradient(135deg, var(--secondary) 0%, var(--secondary-light) 100%);
  color: var(--surface);
  padding: 3rem;
  text-align: center;
}

.estimator-header h2 {
  color: var(--surface);
  font-size: 2rem;
  margin-block-end: 0.5rem;
}

.estimator-header p {
  color: rgba(248, 250, 252, 0.75);
  max-width: 600px;
  margin: 0 auto;
}

.estimator-body {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  padding: 3rem;
  gap: 3rem;
}

.estimator-controls {
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
}

.control-group {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.control-label-span {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--secondary);
  border-bottom: 2px solid var(--border);
  padding-block-end: 0.5rem;
}

/* Property Size Tiles (Exclusive selection) */
.radio-tile-group {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 1rem;
}

.radio-tile {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: 1.25rem;
  background-color: var(--bg-light);
  border: 2px solid var(--border);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: var(--transition-smooth);
  height: 100%;
}

.radio-tile:hover {
  border-color: rgba(74, 144, 226, 0.3);
  background-color: var(--surface);
}

.tile-icon {
  color: var(--text-muted);
  margin-block-end: 0.4rem;
  transition: var(--transition-smooth);
}

input[type="radio"]:checked + .radio-tile .tile-icon {
  color: var(--primary);
  transform: scale(1.15);
}

.tile-title {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--secondary);
}

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

/* Checked styling for tiles */
input[type="radio"]:checked + .radio-tile {
  border-color: var(--primary);
  background-color: var(--primary-glow);
  box-shadow: 0 4px 12px rgba(74, 144, 226, 0.1);
}

input[type="radio"]:focus-visible + .radio-tile {
  outline: 3px solid var(--primary);
  outline-offset: 2px;
}

/* Story selections */
.stories-group {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.story-btn {
  flex: 1 1 140px;
  text-align: center;
  padding: 0.85rem 1.25rem;
  background-color: var(--bg-light);
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--secondary);
  cursor: pointer;
  transition: var(--transition-smooth);
}

.story-btn:hover {
  background-color: var(--surface);
  border-color: rgba(74, 144, 226, 0.3);
}

input[type="radio"]:checked + .story-btn {
  background-color: var(--primary);
  color: var(--surface);
  border-color: var(--primary);
}

input[type="radio"]:focus-visible + .story-btn {
  outline: 3px solid var(--primary);
  outline-offset: 2px;
}

/* Checkboxes Custom style */
.checkbox-group {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.checkbox-custom-label {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  cursor: pointer;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text);
  padding: 0.5rem 0;
}

.checkbox-box {
  width: 20px;
  height: 20px;
  border: 2px solid var(--border);
  border-radius: 6px;
  background-color: var(--bg-light);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-smooth);
}

/* Checkbox Checked states */
input[type="checkbox"]:checked + .checkbox-custom-label .checkbox-box {
  background-color: var(--primary);
  border-color: var(--primary);
}

input[type="checkbox"]:checked + .checkbox-custom-label .checkbox-box::after {
  content: '';
  display: block;
  width: 5px;
  height: 9px;
  border: solid var(--surface);
  border-width: 0 2.5px 2.5px 0;
  transform: rotate(45deg) translate(-1px, -1px);
}

input[type="checkbox"]:focus-visible + .checkbox-custom-label .checkbox-box {
  outline: 3px solid var(--primary);
  outline-offset: 2px;
}

/* Price Box Result Display Card */
.estimator-result {
  display: flex;
  align-items: stretch;
}

.result-card {
  background-color: var(--bg-light);
  border: 1px dashed var(--border);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  width: 100%;
}

.result-title {
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-size: 0.85rem;
}

.price-display {
  display: flex;
  align-items: flex-start;
  color: var(--secondary);
  margin-block: 1rem;
}

.price-display .currency {
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 700;
  margin-top: 0.5rem;
}

#price-number {
  font-family: var(--font-heading);
  font-size: 5rem;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.03em;
  display: inline-block;
  transition: transform 0.2s ease-out;
}

/* Pulsing visual feedback when price updates */
.price-display.price-updated #price-number {
  animation: price-pulse 0.3s ease-out;
}

@keyframes price-pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.15); color: var(--primary); }
  100% { transform: scale(1); }
}

.price-cycle {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text);
  margin-block-end: 1.5rem;
}

.price-details {
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 1rem;
  width: 100%;
  text-align: left;
  font-size: 0.85rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-block-end: 2rem;
}

.price-details p {
  display: flex;
  justify-content: space-between;
}

.result-disclaimer {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-block-start: 1.25rem;
}

/* ==========================================================================
   7. Coverage Area & Radar Animation Map Visual
   ========================================================================== */
.coverage-section {
  background-color: var(--surface);
}

.coverage-wrapper {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 4rem;
  align-items: center;
}

.badge-accent {
  display: inline-block;
  background-color: var(--primary-glow);
  color: var(--primary);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.85rem;
  padding: 0.4rem 0.8rem;
  border-radius: var(--radius-sm);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-block-end: 1rem;
}

.coverage-info {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.coverage-lists {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  margin-block: 1rem;
}

.coverage-col h3 {
  font-size: 1.1rem;
  margin-block-end: 1rem;
  border-bottom: 2px solid var(--bg-light);
  padding-block-end: 0.5rem;
}

.coverage-col ul {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.coverage-col li {
  font-size: 0.95rem;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.coverage-col li::before {
  content: "✓";
  color: var(--primary);
  font-weight: 700;
}

.coverage-note {
  font-size: 0.9rem;
}

/* Custom CSS pulsing radar map */
.coverage-visual {
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Custom CSS pulsing radar map */
.coverage-visual {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
}

.map-container {
  width: 100%;
  max-width: 400px;
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  padding: 1rem;
  overflow: hidden;
  transition: var(--transition-smooth);
}

.map-container:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(74, 144, 226, 0.25);
}

.hereford-svg-map {
  width: 100%;
  height: auto;
  display: block;
}

/* Radar Wave Animations */
.radar-wave {
  transform-origin: 200px 200px;
  animation: radar-pulse 3s cubic-bezier(0.215, 0.61, 0.355, 1) infinite;
  opacity: 0;
}

.radar-wave-2 {
  animation-delay: 1.5s;
}

@keyframes radar-pulse {
  0% {
    r: 10px;
    opacity: 0.8;
    stroke-width: 3;
  }
  50% {
    opacity: 0.4;
  }
  100% {
    r: 140px;
    opacity: 0;
    stroke-width: 1;
  }
}

/* Map node styling & hover effects */
.map-node {
  cursor: pointer;
  transition: var(--transition-smooth);
}

.map-node circle {
  transition: var(--transition-smooth);
}

.map-node text {
  transition: var(--transition-smooth);
  font-family: var(--font-heading);
}

.map-node:hover circle:first-of-type {
  fill: var(--primary);
  transform: scale(1.3);
  transform-origin: inherit;
}

.map-node:hover text {
  fill: var(--primary-hover);
  font-weight: 700;
}

/* Hereford Centre pulsing glow */
.node-active circle:first-of-type {
  animation: core-pulse 2s infinite ease-in-out;
}

@keyframes core-pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.15); }
}

.node-glow {
  transform-origin: 200px 200px;
  animation: glow-pulse 2s infinite ease-in-out;
}

@keyframes glow-pulse {
  0%, 100% { transform: scale(1); opacity: 0.2; }
  50% { transform: scale(1.3); opacity: 0.6; }
}

.node-label-bg {
  filter: drop-shadow(0 2px 4px rgba(15, 23, 42, 0.15));
}

/* ==========================================================================
   8. Contact Form & High-Conversion Inputs
   ========================================================================== */
.contact-section {
  background-color: var(--bg-light);
}

.contact-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 4rem;
}

.contact-info-panel {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.contact-info-panel h2 {
  font-size: 2.25rem;
  font-weight: 800;
}

.contact-methods {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.contact-method-item {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
}

.c-icon {
  width: 42px;
  height: 42px;
  background-color: var(--primary-glow);
  color: var(--primary);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.contact-method-item h4 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--secondary);
  margin-block-end: 0.25rem;
}

.contact-method-item p {
  font-size: 0.9rem;
  color: var(--text);
  font-weight: 500;
}

.hover-underline:hover {
  text-decoration: underline;
  color: var(--primary);
}

.review-box {
  background-color: var(--surface);
  border: 1px solid var(--border);
  padding: 2rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  margin-block-start: 2rem;
}

.review-text {
  font-style: italic;
  font-size: 0.95rem;
  color: var(--text);
  margin-block-end: 0.75rem;
}

.review-author {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--primary-hover);
}

/* Contact Form UI */
.contact-form-panel {
  background-color: var(--surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
  padding: 3rem;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

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

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem; /* Gestalt Proximity: Label close to input */
}

.form-group label {
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--secondary);
}

.required-star {
  color: var(--error);
  margin-inline-start: 0.15rem;
}

/* Visual inputs styling */
.form-group input,
.form-group textarea,
.form-group select {
  font-family: var(--font-body);
  font-size: 1rem;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-sm);
  border: 2px solid var(--border);
  background-color: var(--bg-light);
  color: var(--text);
  min-height: 48px; /* High mobile tap target */
  width: 100%;
  transition: var(--transition-smooth);
}

.form-group textarea {
  resize: vertical;
}

/* Input Focus Glow styling */
.form-group input:focus-visible,
.form-group textarea:focus-visible,
.form-group select:focus-visible {
  outline: 3px solid var(--primary);
  outline-offset: 1px;
  background-color: var(--surface);
  border-color: var(--primary);
}

/* Form constraints check styling */
.form-group input:invalid:user-invalid,
.form-group textarea:invalid:user-invalid {
  border-color: var(--error);
  background-color: var(--error-glow);
}

.error-msg {
  font-size: 0.8rem;
  color: var(--error);
  font-weight: 600;
  display: none;
}

.form-fieldset {
  border: 2px solid var(--border);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  background-color: var(--bg-light);
}

.form-fieldset legend {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--secondary);
  padding-inline: 0.5rem;
}

.checkbox-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 1rem;
}

.checkbox-inline {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text);
}

.checkbox-inline input {
  min-height: auto;
  width: auto;
  accent-color: var(--primary);
  width: 18px;
  height: 18px;
}

/* Visual hiding for spam fields */
.visually-hidden-field {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.form-submit-container {
  margin-block-start: 1rem;
}

/* ==========================================================================
   9. Native HTML5 Dialog Success Modal
   ========================================================================== */
.success-dialog-modal {
  border: none;
  border-radius: var(--radius-lg);
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  max-width: 480px;
  margin: auto;
  padding: 3rem 2.5rem;
  background: var(--surface);
  text-align: center;
}

.success-dialog-modal::backdrop {
  background-color: rgba(15, 23, 42, 0.7);
  backdrop-filter: blur(8px);
}

.modal-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

.success-icon-wrapper {
  width: 72px;
  height: 72px;
  background-color: #d1fae5;
  color: var(--success);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
}

.success-dialog-modal h2 {
  font-size: 1.75rem;
  color: var(--secondary);
}

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

/* ==========================================================================
   10. Footer Section
   ========================================================================== */
#main-footer {
  background-color: var(--bg-dark);
  color: var(--surface);
  border-top: 1px solid var(--secondary-light);
  padding-block: 4rem 2rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 4rem;
  margin-block-end: 3rem;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.footer-brand .logo {
  color: var(--surface);
}

.footer-brand p {
  color: rgba(248, 250, 252, 0.65);
  font-size: 0.95rem;
  max-width: 320px;
}

.footer-links, .footer-contact {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.footer-links h3, .footer-contact h3 {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--surface);
  border-bottom: 2px solid var(--secondary-light);
  padding-block-end: 0.5rem;
}

.footer-links ul {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer-links a {
  color: rgba(248, 250, 252, 0.65);
  font-size: 0.95rem;
}
.footer-links a:hover {
  color: var(--primary);
  padding-inline-start: 0.25rem;
}

.footer-contact p {
  color: rgba(248, 250, 252, 0.65);
  font-size: 0.95rem;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid var(--secondary-light);
  padding-block-start: 2rem;
  font-size: 0.85rem;
  color: rgba(248, 250, 252, 0.45);
  flex-wrap: wrap;
  gap: 1.5rem;
}

.back-to-top {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.85rem;
  color: rgba(248, 250, 252, 0.65);
}
.back-to-top:hover {
  color: var(--primary);
}

/* ==========================================================================
   11. Media Queries (Mobile & Responsive adaptations)
   ========================================================================== */

/* Up to Tablet Portrait (Max-width 768px) */
@media (max-width: 768px) {
  section {
    padding-block: 4rem;
  }
  
  .section-header {
    margin-bottom: 2.5rem;
  }

  /* Hamburger Navigation Menu setup */
  .mobile-nav-toggle {
    display: block;
  }

  #nav-menu {
    position: fixed;
    top: var(--header-height);
    left: 0;
    right: 0;
    background-color: rgba(255, 255, 255, 0.98);
    border-bottom: 2px solid var(--border);
    padding: 2.5rem 1.5rem;
    box-shadow: var(--shadow-md);
    transform: translateY(-150%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.4s ease-out, opacity 0.3s ease-out;
  }
  
  /* When header shrunk, mobile menu tracks height */
  #main-header:has(+.shrunk) #nav-menu {
    top: var(--header-height-shrunk);
  }

  #nav-menu.active {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .nav-list {
    flex-direction: column;
    gap: 1.75rem;
    align-items: stretch;
    text-align: center;
  }
  
  .nav-link {
    display: block;
    font-size: 1.15rem;
  }
  
  .nav-btn {
    display: flex;
    width: 100%;
    padding: 0.85rem;
  }

  /* Hero adaptation */
  .hero-section {
    min-height: auto;
  }
  
  .hero-content {
    align-items: center;
    text-align: center;
    padding-block: 6rem 4rem;
  }
  
  .hero-subtitle {
    margin: 0 auto;
  }
  
  .hero-actions {
    justify-content: center;
    width: 100%;
  }
  
  .hero-actions .btn {
    flex: 1 1 200px;
  }
  
  .hero-stats {
    flex-direction: column;
    gap: 1.5rem;
    align-items: center;
  }

  /* Grid adaptations */
  .estimator-body {
    grid-template-columns: 1fr;
    padding: 2rem;
    gap: 2.5rem;
  }
  
  .coverage-wrapper {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
  
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 3rem;
  }

  .contact-form-panel {
    padding: 2rem;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }
}

/* Up to Small Mobile (Max-width: 480px) */
@media (max-width: 480px) {
  .form-grid {
    grid-template-columns: 1fr;
  }
  
  .full-width {
    grid-column: span 1;
  }
  
  .checkbox-grid {
    grid-template-columns: 1fr;
  }
  
  .radio-tile-group {
    grid-template-columns: 1fr;
  }
  
  .story-btn {
    flex: 1 1 100%;
  }

  .pricing-card-wrapper {
    border-radius: var(--radius-md);
  }
  
  .estimator-header {
    padding: 2rem 1.5rem;
  }
  
  #price-number {
    font-size: 4rem;
  }
}
