/* ==========================================================================
   Fredy's Construction & Roofing — Main Stylesheet
   Colors: Primary #1B5E96 (Blue), Accent #CC4A00 (Orange), Dark #1A2332
   Mobile-first responsive design
   ========================================================================== */

/* --- CSS Custom Properties --- */
:root {
  --primary: #1B5E96;
  --primary-dark: #154A78;
  --primary-light: #2A7AB8;
  --accent: #CC4A00;
  --accent-dark: #A63D00;
  --accent-light: #E65500;
  --dark: #1A2332;
  --dark-light: #2C3E50;
  --text: #333333;
  --text-light: #666666;
  --text-muted: #717171;
  --bg: #FFFFFF;
  --bg-light: #F7F9FC;
  --bg-warm: #FFF8F0;
  --border: #E0E6ED;
  --border-light: #F0F3F7;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.08);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.1);
  --shadow-lg: 0 8px 30px rgba(0,0,0,0.12);
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --max-width: 1200px;
  --header-height: 90px;
  --transition: 0.3s ease;
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  overflow-x: hidden;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

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

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

h1, h2, h3, h4, h5, h6 {
  color: var(--dark);
  line-height: 1.25;
  font-weight: 700;
}

h1 { font-size: 2.25rem; }
h2 { font-size: 1.875rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

p { margin-bottom: 1rem; }

ul, ol { padding-left: 1.25rem; }

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

.section {
  padding: 60px 0;
}

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

.text-center { text-align: center; }
.text-primary { color: var(--primary); }
.text-accent { color: var(--accent); }

.section-header {
  text-align: center;
  margin-bottom: 48px;
}

.section-header h2 {
  margin-bottom: 12px;
}

.section-header p {
  color: var(--text-light);
  font-size: 1.1rem;
  max-width: 700px;
  margin: 0 auto;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  font-size: 1rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
  line-height: 1.2;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
}
.btn-primary:hover {
  background: var(--accent-dark);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn-secondary {
  background: transparent;
  color: #fff;
  border: 2px solid rgba(255,255,255,0.8);
}
.btn-secondary:hover {
  background: rgba(255,255,255,0.15);
  color: #fff;
  border-color: #fff;
}

.btn-outline {
  background: transparent;
  color: var(--primary);
  border: 2px solid var(--primary);
}
.btn-outline:hover {
  background: var(--primary);
  color: #fff;
}

.btn-white {
  background: #fff;
  color: var(--primary);
}
.btn-white:hover {
  background: var(--bg-light);
  color: var(--primary-dark);
}

.btn-sm {
  padding: 10px 20px;
  font-size: 0.9rem;
}

.btn-lg {
  padding: 16px 36px;
  font-size: 1.1rem;
}

.btn-group {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* --- Header / Navigation --- */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: #fff;
  box-shadow: var(--shadow-sm);
  height: var(--header-height);
  transition: box-shadow var(--transition);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.15rem;
  color: var(--primary);
  text-decoration: none;
  white-space: nowrap;
}

.logo-icon {
  width: 126px;
  height: 126px;
  object-fit: contain;
  flex-shrink: 0;
  margin-top: 25px;
  border-radius: var(--radius-sm);
}

.nav-desktop {
  display: none;
  align-items: center;
  gap: 4px;
}

.nav-desktop a {
  padding: 8px 14px;
  color: var(--text);
  font-weight: 500;
  font-size: 0.92rem;
  border-radius: var(--radius-sm);
  transition: all var(--transition);
}

.nav-desktop a:hover,
.nav-desktop a.active {
  color: var(--primary);
  background: var(--bg-light);
}

.nav-desktop .btn {
  margin-left: 8px;
}

/* Dropdown */
.nav-dropdown {
  position: relative;
}

.nav-dropdown > a::after {
  content: '';
  display: inline-block;
  width: 6px;
  height: 6px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  margin-left: 6px;
  vertical-align: middle;
  margin-bottom: 2px;
}

.dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 220px;
  background: #fff;
  box-shadow: var(--shadow-lg);
  border-radius: var(--radius-md);
  padding: 8px 0;
  z-index: 100;
}

.nav-dropdown:hover .dropdown-menu {
  display: block;
}

.dropdown-menu a {
  display: block;
  padding: 10px 20px;
  font-size: 0.9rem;
  border-radius: 0;
}

.dropdown-menu a:hover {
  background: var(--bg-light);
}

/* Mobile hamburger */
.nav-toggle {
  display: flex;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2.5px;
  background: var(--dark);
  border-radius: 2px;
  transition: all var(--transition);
}

.nav-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}
.nav-toggle.active span:nth-child(2) {
  opacity: 0;
}
.nav-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* Mobile Navigation */
.nav-mobile {
  display: none;
  position: fixed;
  top: var(--header-height);
  left: 0;
  right: 0;
  bottom: 0;
  background: #fff;
  z-index: 999;
  overflow-y: auto;
  padding: 20px;
}

.nav-mobile.active {
  display: block;
}

.nav-mobile a {
  display: block;
  padding: 14px 16px;
  color: var(--text);
  font-weight: 500;
  font-size: 1.05rem;
  border-bottom: 1px solid var(--border-light);
}

.nav-mobile a:hover,
.nav-mobile a.active {
  color: var(--primary);
  background: var(--bg-light);
}

.nav-mobile .mobile-dropdown-items {
  display: none;
  padding-left: 16px;
}

.nav-mobile .mobile-dropdown-items.active {
  display: block;
}

.nav-mobile .mobile-dropdown-items a {
  font-size: 0.95rem;
  padding: 10px 16px;
  color: var(--text-light);
}

.nav-mobile .btn {
  width: 100%;
  margin-top: 16px;
}

.header-phone {
  display: none;
  align-items: center;
  gap: 6px;
  color: var(--primary);
  font-weight: 700;
  font-size: 0.95rem;
}

.header-phone svg {
  width: 16px;
  height: 16px;
}

/* --- Hero Section --- */
.hero {
  position: relative;
  min-height: 60vh;
  display: flex;
  align-items: center;
  background: linear-gradient(135deg, var(--dark) 0%, var(--primary-dark) 100%);
  color: #fff;
  margin-top: var(--header-height);
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url('../images/hero-roofer-working.jpg') center/cover no-repeat;
  opacity: 0.2;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: var(--max-width);
  padding-top: 60px;
  padding-bottom: 60px;
  padding-left: 24px;
  padding-right: 24px;
}

.hero h1 {
  color: #fff;
  font-size: 1.5rem;
  margin-bottom: 20px;
  line-height: 1.2;
}

.hero p {
  font-size: 1.15rem;
  opacity: 0.9;
  margin-bottom: 32px;
  line-height: 1.7;
}

/* --- Trust Bar --- */
.trust-bar {
  background: var(--bg-light);
  border-bottom: 1px solid var(--border);
  padding: 30px 0;
}

.trust-items {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  text-align: center;
}

.trust-item {
  padding: 12px;
}

.trust-item .number {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--primary);
  display: block;
}

.trust-item .label {
  font-size: 0.85rem;
  color: var(--text-light);
  margin-top: 4px;
}

/* --- Storm Banner --- */
.storm-banner {
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);
  color: #fff;
  padding: 40px 0;
  text-align: center;
}

.storm-banner h2 {
  color: #fff;
  margin-bottom: 16px;
  font-size: 1.75rem;
}

.storm-banner p {
  max-width: 700px;
  margin: 0 auto 24px;
  opacity: 0.95;
  font-size: 1.05rem;
}

/* --- Service Cards --- */
.services-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

.service-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 32px 24px;
  transition: all var(--transition);
}

.service-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
  border-color: var(--primary);
}

.service-card-icon {
  width: 48px;
  height: 48px;
  background: var(--bg-light);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  color: var(--primary);
  font-size: 1.5rem;
}

.service-card h3 {
  font-size: 1.2rem;
  margin-bottom: 10px;
}

.service-card p {
  color: var(--text-light);
  font-size: 0.95rem;
  margin-bottom: 0;
}

.service-card a {
  display: inline-block;
  margin-top: 12px;
  color: var(--primary);
  font-weight: 600;
  font-size: 0.9rem;
}

.service-card a::after {
  content: ' →';
}

/* --- Why FCR / Differentiators --- */
.diff-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

.diff-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 12px;
}

.diff-icon {
  width: 48px;
  height: 48px;
  min-width: 48px;
  background: var(--primary);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
}

.diff-item h4 {
  font-size: 1.05rem;
  margin-bottom: 6px;
}

.diff-item p {
  color: var(--text-light);
  font-size: 0.95rem;
  margin: 0;
}

/* --- About Snippet (text + image) --- */
.split-section {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
  align-items: center;
}

.split-image {
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 4/3;
  background: var(--bg-light);
}

.split-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* --- City Tags --- */
.city-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
}

.city-tag {
  display: inline-block;
  padding: 10px 14px;
  background: var(--bg-light);
  border: 1px solid var(--border);
  border-radius: 20px;
  font-size: 0.875rem;
  color: var(--text);
  transition: all var(--transition);
  min-height: 44px;
  line-height: 1.4;
}

.city-tag:hover {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

/* --- Reviews --- */
.reviews-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

.review-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 28px 24px;
}

.review-stars {
  color: #F5A623;
  font-size: 1.1rem;
  margin-bottom: 12px;
}

.review-card blockquote {
  font-style: italic;
  color: var(--text);
  font-size: 0.95rem;
  margin-bottom: 16px;
  line-height: 1.6;
}

.review-author {
  font-weight: 600;
  color: var(--text-light);
  font-size: 0.9rem;
}

/* --- Final CTA Banner --- */
.cta-banner {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: #fff;
  padding: 60px 0;
  text-align: center;
}

.cta-banner h2 {
  color: #fff;
  margin-bottom: 16px;
}

.cta-banner p {
  max-width: 600px;
  margin: 0 auto 32px;
  opacity: 0.9;
  font-size: 1.1rem;
}

/* --- Page Hero (inner pages) --- */
.page-hero {
  background: linear-gradient(135deg, var(--dark) 0%, var(--primary-dark) 100%);
  color: #fff;
  padding: 80px 0 50px;
  margin-top: var(--header-height);
  text-align: center;
}

.page-hero h1 {
  color: #fff;
  margin-bottom: 12px;
}

.page-hero p {
  opacity: 0.85;
  max-width: 650px;
  margin: 0 auto;
  font-size: 1.1rem;
}

/* --- Service Detail Page --- */
.service-detail {
  padding: 48px 0;
}

.service-detail h2 {
  margin-bottom: 16px;
}

.service-detail p {
  color: var(--text-light);
  font-size: 1.05rem;
  line-height: 1.7;
}

.service-detail ul {
  margin: 16px 0 24px;
}

.service-detail ul li {
  color: var(--text-light);
  padding: 6px 0;
  line-height: 1.5;
}

.service-detail ul li::marker {
  color: var(--primary);
}

/* --- FAQ --- */
.faq-list {
  max-width: 800px;
  margin: 0 auto;
}

.faq-item {
  border-bottom: 1px solid var(--border);
}

.faq-question {
  width: 100%;
  background: none;
  border: none;
  padding: 20px 40px 20px 0;
  text-align: left;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--dark);
  cursor: pointer;
  position: relative;
  line-height: 1.4;
  font-family: inherit;
}

.faq-question::after {
  content: '+';
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.5rem;
  font-weight: 300;
  color: var(--primary);
  transition: transform var(--transition);
}

.faq-item.active .faq-question::after {
  content: '−';
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease;
}

.faq-answer-inner {
  padding: 0 0 20px;
  color: var(--text-light);
  font-size: 0.98rem;
  line-height: 1.7;
}

.faq-item.active .faq-answer {
  max-height: 2000px;
}

/* --- Contact Form --- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
}

.contact-info-card {
  background: var(--bg-light);
  border-radius: var(--radius-md);
  padding: 32px 24px;
}

.contact-info-item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 14px 0;
  border-bottom: 1px solid var(--border-light);
}

.contact-info-item:last-child {
  border-bottom: none;
}

.contact-info-icon {
  width: 40px;
  height: 40px;
  min-width: 40px;
  background: var(--primary);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
}

.contact-info-item h4 {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 500;
  margin-bottom: 2px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.contact-info-item p,
.contact-info-item a {
  font-size: 1rem;
  color: var(--text);
  font-weight: 600;
  margin: 0;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 6px;
  color: var(--dark);
}

.form-group label .required {
  color: var(--accent);
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 12px 16px;
  font-size: 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: #fff;
  color: var(--text);
  transition: border-color var(--transition);
  font-family: inherit;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(27,94,150,0.1);
}

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

.form-note {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 12px;
}

/* --- Gallery Category Cards --- */
.gallery-categories {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

.gallery-category-card {
  position: relative;
  display: block;
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 16/10;
  text-decoration: none;
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.gallery-category-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 32px rgba(0,0,0,0.18);
}

.gallery-category-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

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

.gallery-category-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.75) 0%, rgba(0,0,0,0.15) 50%, rgba(0,0,0,0.05) 100%);
  display: flex;
  align-items: flex-end;
  padding: 24px;
  transition: background 0.3s ease;
}

.gallery-category-card:hover .gallery-category-overlay {
  background: linear-gradient(to top, rgba(27,94,150,0.85) 0%, rgba(27,94,150,0.25) 50%, rgba(0,0,0,0.05) 100%);
}

.gallery-category-overlay h3 {
  color: #fff;
  font-size: 1.3rem;
  font-weight: 800;
  margin: 0;
  text-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

/* --- Gallery Breadcrumb --- */
.gallery-breadcrumb {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--primary);
  font-weight: 600;
  text-decoration: none;
  margin-bottom: 24px;
  font-size: 0.95rem;
  transition: color var(--transition);
}

.gallery-breadcrumb:hover {
  color: var(--accent);
}

.gallery-breadcrumb svg {
  width: 18px;
  height: 18px;
}

/* --- Gallery Empty State --- */
.gallery-empty {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-muted);
}

.gallery-empty svg {
  width: 64px;
  height: 64px;
  margin-bottom: 16px;
  opacity: 0.4;
}

.gallery-empty h3 {
  font-size: 1.3rem;
  color: var(--text);
  margin-bottom: 8px;
}

/* --- Gallery Subcategory Titles --- */
.gallery-subcategory-title {
  font-size: 1.5rem;
  color: var(--text);
  margin-top: 40px;
  margin-bottom: 20px;
  padding-bottom: 10px;
  border-bottom: 3px solid var(--primary);
}

.gallery-subcategory-title:first-of-type {
  margin-top: 20px;
}

/* --- Gallery --- */
.gallery-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin-bottom: 32px;
}

.gallery-filter {
  padding: 12px 20px;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: #fff;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition);
  font-family: inherit;
  color: var(--text);
  min-height: 44px;
}

.gallery-filter:hover,
.gallery-filter.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

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

.gallery-item {
  border-radius: var(--radius-md);
  overflow: hidden;
  aspect-ratio: 4/3;
  background: var(--bg-light);
  cursor: pointer;
  transition: transform var(--transition);
}

.gallery-item:hover {
  transform: scale(1.02);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* --- Stats Row --- */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.stat-item {
  text-align: center;
  padding: 24px 16px;
  background: #fff;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
}

.stat-number {
  font-size: 2rem;
  font-weight: 800;
  color: var(--primary);
  display: block;
}

.stat-label {
  font-size: 0.875rem;
  color: var(--text-light);
  margin-top: 4px;
}

/* --- Footer --- */
.footer {
  background: var(--dark);
  color: rgba(255,255,255,0.8);
  padding: 60px 0 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  margin-bottom: 40px;
}

.footer-col h4 {
  color: #fff;
  font-size: 1rem;
  margin-bottom: 16px;
}

.footer-col p,
.footer-col a {
  color: rgba(255,255,255,0.7);
  font-size: 0.9rem;
  line-height: 1.8;
}

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

.footer-col ul {
  list-style: none;
  padding: 0;
}

.footer-col ul li a {
  display: block;
  padding: 10px 0;
  min-height: 44px;
}

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding: 24px 0;
  text-align: center;
}

.footer-bottom p {
  font-size: 0.875rem;
  color: rgba(255,255,255,0.5);
  margin: 0;
}

.footer-tagline {
  color: var(--accent) !important;
  font-weight: 600;
  font-style: italic;
}

/* --- Emergency Banner --- */
.emergency-banner {
  background: var(--dark);
  color: #fff;
  padding: 40px 0;
  text-align: center;
}

.emergency-banner h3 {
  color: #fff;
  margin-bottom: 12px;
}

.emergency-banner p {
  opacity: 0.85;
  margin-bottom: 20px;
}

.emergency-phone {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--accent);
}

.emergency-phone a {
  color: var(--accent);
}

/* --- Service Detail List --- */
.service-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 48px;
}

.service-list-item {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  align-items: start;
  padding-bottom: 48px;
  border-bottom: 1px solid var(--border);
}

.service-list-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

/* --- Lightbox --- */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.9);
  z-index: 2000;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.lightbox.active {
  display: flex;
}

.lightbox img {
  max-width: 90vw;
  max-height: 90vh;
  border-radius: var(--radius-md);
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: none;
  border: none;
  color: #fff;
  font-size: 2rem;
  cursor: pointer;
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */

/* Tablet (640px+) */
@media (min-width: 640px) {
  h1 { font-size: 2.75rem; }
  h2 { font-size: 2.25rem; }

  .hero h1 { font-size: 2.5rem; }

  .trust-items { grid-template-columns: repeat(3, 1fr); }
  .services-grid { grid-template-columns: repeat(2, 1fr); }
  .diff-grid { grid-template-columns: repeat(2, 1fr); }
  .reviews-grid { grid-template-columns: repeat(2, 1fr); }
  .gallery-grid { grid-template-columns: repeat(3, 1fr); }
  .gallery-categories { grid-template-columns: repeat(2, 1fr); }
  .stats-grid { grid-template-columns: repeat(3, 1fr); }
  .footer-grid { grid-template-columns: repeat(2, 1fr); }
  .contact-grid { grid-template-columns: 1fr 1fr; }
  .split-section { grid-template-columns: 1fr 1fr; }
}

/* Desktop (1024px+) */
@media (min-width: 1024px) {
  .nav-desktop { display: flex; }
  .nav-toggle { display: none; }
  .header-phone { display: flex; }

  h1 { font-size: 3rem; }
  .hero h1 { font-size: 2rem; }

  .section { padding: 80px 0; }

  .trust-items { grid-template-columns: repeat(5, 1fr); }
  .services-grid { grid-template-columns: repeat(3, 1fr); }
  .diff-grid { grid-template-columns: repeat(3, 1fr); }
  .reviews-grid { grid-template-columns: repeat(3, 1fr); }
  .gallery-grid { grid-template-columns: repeat(4, 1fr); }
  .gallery-categories { grid-template-columns: repeat(3, 1fr); }
  .stats-grid { grid-template-columns: repeat(3, 1fr); }
  .footer-grid { grid-template-columns: 2fr 1fr 1fr 1.5fr; }
}

/* Large Desktop (1280px+) */
@media (min-width: 1280px) {
  .stats-grid { grid-template-columns: repeat(6, 1fr); }
}

/* --- Scroll offset for anchor links --- */
[id] {
  scroll-margin-top: calc(var(--header-height) + 20px);
}

/* --- Selection --- */
::selection {
  background: var(--primary);
  color: #fff;
}

/* ==========================================================================
   ADDITIONAL STYLES — Matching agent-generated HTML structure
   ========================================================================== */

/* --- Header Actions (desktop CTA + phone) --- */
.header-actions {
  display: none;
  align-items: center;
  gap: 16px;
}

.header-cta {
  white-space: nowrap;
}

.lang-toggle {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text);
  text-decoration: none;
  padding: 6px 10px;
  border: 2px solid var(--primary);
  border-radius: var(--radius-sm);
  transition: background 0.2s, color 0.2s;
  min-width: 44px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.lang-toggle:hover,
.lang-toggle:focus-visible {
  background: var(--primary);
  color: #fff;
}

/* --- Hamburger (mobile menu toggle) --- */
.hamburger {
  display: flex;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 14px;
  min-width: 44px;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  z-index: 1001;
}

.hamburger-line {
  display: block;
  width: 24px;
  height: 2.5px;
  background: var(--dark);
  border-radius: 2px;
  transition: all var(--transition);
}

.hamburger.active .hamburger-line:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}
.hamburger.active .hamburger-line:nth-child(2) {
  opacity: 0;
}
.hamburger.active .hamburger-line:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* --- Nav list (ul-based desktop nav) --- */
.nav-list {
  display: flex;
  align-items: center;
  list-style: none;
  gap: 4px;
  margin: 0;
  padding: 0;
}

.nav-item {
  position: relative;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 8px 14px;
  color: var(--text);
  font-weight: 500;
  font-size: 0.92rem;
  border-radius: var(--radius-sm);
  transition: all var(--transition);
  white-space: nowrap;
}

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

.dropdown-arrow {
  transition: transform var(--transition);
}

/* Desktop dropdown menu (ul-based) */
.nav-dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 220px;
  background: #fff;
  box-shadow: var(--shadow-lg);
  border-radius: var(--radius-md);
  padding: 8px 0;
  z-index: 100;
  list-style: none;
}

.nav-dropdown:hover .nav-dropdown-menu {
  display: block;
}

.nav-dropdown-menu li a {
  display: block;
  padding: 10px 20px;
  font-size: 0.9rem;
  color: var(--text);
  transition: all var(--transition);
}

.nav-dropdown-menu li a:hover {
  background: var(--bg-light);
  color: var(--primary);
}

/* --- Mobile Navigation (agent structure) --- */
.nav-mobile-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.nav-mobile-list > li > a,
.nav-mobile-link {
  display: block;
  padding: 14px 16px;
  color: var(--text);
  font-weight: 500;
  font-size: 1.05rem;
  border-bottom: 1px solid var(--border-light);
}

.nav-mobile-link:hover,
.nav-mobile-link.active {
  color: var(--primary);
  background: var(--bg-light);
}

.nav-mobile-dropdown-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 14px 16px;
  background: none;
  border: none;
  border-bottom: 1px solid var(--border-light);
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--text);
  cursor: pointer;
  font-family: inherit;
}

.nav-mobile-dropdown-menu {
  display: none;
  list-style: none;
  padding: 0;
  margin: 0;
  background: var(--bg-light);
}

.nav-mobile-dropdown-toggle.active + .nav-mobile-dropdown-menu,
.nav-mobile-dropdown-menu.active {
  display: block;
}

.nav-mobile-dropdown-menu li a {
  display: block;
  padding: 10px 16px 10px 32px;
  font-size: 0.95rem;
  color: var(--text-light);
  border-bottom: 1px solid var(--border-light);
}

.nav-mobile-dropdown-menu li a:hover {
  color: var(--primary);
}

.nav-mobile-actions {
  padding: 20px 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.nav-mobile-phone {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px;
  color: var(--primary);
  font-weight: 700;
  font-size: 1.1rem;
  border: 2px solid var(--primary);
  border-radius: var(--radius-sm);
}

.btn-block {
  display: block;
  width: 100%;
  text-align: center;
}

/* --- Hero overlay for agent structure --- */
.hero-overlay {
  position: absolute;
  inset: 0;
  background: url('../images/hero-roofer-working.jpg') center/cover no-repeat;
  opacity: 0.2;
}

.hero-title {
  color: #fff;
}

.hero-subtitle {
  opacity: 0.9;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* --- Logo text structure --- */
.logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.logo-name {
  font-weight: 800;
  font-size: 0.95rem;
}

.logo-tagline {
  font-weight: 800;
  font-size: 0.95rem;
  color: var(--accent);
}

/* --- Service card wrapping link --- */
a.service-card {
  text-decoration: none;
  color: inherit;
  display: block;
}

a.service-card:hover {
  color: inherit;
}

/* --- About section image placeholder --- */
.image-placeholder {
  width: 100%;
  aspect-ratio: 4/3;
  background: var(--bg-light);
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-size: 0.9rem;
  border: 2px dashed var(--border);
}

/* --- Values grid --- */
.values-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
}

.value-item {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.value-icon {
  width: 48px;
  height: 48px;
  min-width: 48px;
  background: var(--primary);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  flex-shrink: 0;
}

.value-item h3 {
  font-size: 1.1rem;
  margin-bottom: 6px;
}

.value-item p {
  color: var(--text-light);
  font-size: 0.95rem;
  margin: 0;
}

/* --- Primary areas cards --- */
.primary-areas-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-bottom: 48px;
}

.area-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 24px;
  text-align: center;
  transition: all var(--transition);
}

.area-card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--primary);
}

.area-card h3 {
  font-size: 1.1rem;
  margin-bottom: 4px;
}

.area-card .badge {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  padding: 2px 10px;
  border-radius: 10px;
  font-size: 0.75rem;
  font-weight: 600;
  margin-bottom: 8px;
}

.area-card p {
  color: var(--text-light);
  font-size: 0.9rem;
  margin-bottom: 12px;
}

/* --- Gallery item overlay --- */
.gallery-item {
  position: relative;
}

.gallery-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 12px;
  background: linear-gradient(transparent, rgba(0,0,0,0.7));
  color: #fff;
  font-size: 0.85rem;
  font-weight: 600;
}

/* --- Disclaimer / note box --- */
.disclaimer,
.note-box {
  background: var(--bg-warm);
  border-left: 4px solid var(--accent);
  padding: 16px 20px;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: 0.95rem;
  color: var(--text-light);
  margin: 20px 0;
}

/* --- Storm damage type cards --- */
.damage-types-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

.damage-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 28px 24px;
}

.damage-card h3 {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.1rem;
  margin-bottom: 10px;
}

.damage-card p {
  color: var(--text-light);
  font-size: 0.95rem;
  margin: 0;
}

/* --- Process steps --- */
.process-steps {
  counter-reset: step;
  list-style: none;
  padding: 0;
}

.process-steps li {
  counter-increment: step;
  display: flex;
  gap: 16px;
  align-items: flex-start;
  padding: 16px 0;
  border-bottom: 1px solid var(--border-light);
}

.process-steps li::before {
  content: counter(step);
  min-width: 36px;
  height: 36px;
  background: var(--primary);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
  flex-shrink: 0;
}

/* --- Thank you page --- */
.thank-you-content {
  text-align: center;
  padding: 40px 0;
  max-width: 600px;
  margin: 0 auto;
}

.thank-you-content h2 {
  font-size: 2rem;
  margin-bottom: 16px;
  color: var(--primary);
}

/* --- Tablet responsive additions --- */
@media (min-width: 640px) {
  .values-grid { grid-template-columns: repeat(2, 1fr); }
  .damage-types-grid { grid-template-columns: repeat(2, 1fr); }
  .primary-areas-grid { grid-template-columns: repeat(3, 1fr); }
}

/* --- Desktop responsive additions --- */
@media (min-width: 1024px) {
  .hamburger { display: none; }
  .header-actions { display: flex; }
  .nav-desktop { display: flex; }

  .values-grid { grid-template-columns: repeat(2, 1fr); }
  .damage-types-grid { grid-template-columns: repeat(2, 1fr); }
}

/* --- Persistent Call Now Button (mobile only) --- */
.call-now-btn {
  position: fixed;
  bottom: 24px;
  bottom: calc(24px + env(safe-area-inset-bottom));
  right: 24px;
  right: calc(24px + env(safe-area-inset-right));
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  font-size: 1rem;
  padding: 14px 24px;
  border-radius: 50px;
  text-decoration: none;
  box-shadow: 0 4px 16px rgba(204, 74, 0, 0.4);
  z-index: 900;
  transition: background 0.2s, box-shadow 0.2s, transform 0.2s;
  min-height: 44px;
}
.call-now-btn:hover,
.call-now-btn:active {
  background: var(--accent-dark);
  box-shadow: 0 6px 20px rgba(204, 74, 0, 0.5);
  transform: translateY(-2px);
  color: #fff;
}
.call-now-btn svg {
  flex-shrink: 0;
}

/* Hide Call Now on desktop */
@media (min-width: 1024px) {
  .call-now-btn {
    display: none;
  }
}

/* --- Skip Link (Accessibility) --- */
.skip-link {
  position: absolute;
  top: -100%;
  left: 16px;
  background: var(--primary);
  color: #fff;
  padding: 12px 24px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.95rem;
  z-index: 10000;
  transition: top 0.2s;
  text-decoration: none;
}
.skip-link:focus {
  top: 12px;
  color: #fff;
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}

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

/* --- Cookie Consent Banner --- */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--dark);
  color: rgba(255,255,255,0.9);
  padding: 16px 20px;
  z-index: 9999;
  display: none;
  box-shadow: 0 -4px 20px rgba(0,0,0,0.2);
}
.cookie-banner.visible {
  display: block;
}
.cookie-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.cookie-text {
  font-size: 0.9rem;
  line-height: 1.5;
  flex: 1;
  min-width: 200px;
}
.cookie-text a {
  color: var(--accent);
  text-decoration: underline;
}
.cookie-text a:hover {
  color: var(--accent-light);
}
.cookie-actions {
  display: flex;
  gap: 10px;
  flex-shrink: 0;
}
.cookie-accept {
  background: var(--accent);
  color: #fff;
  border: none;
  padding: 10px 20px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.875rem;
  cursor: pointer;
  transition: background var(--transition);
  min-height: 44px;
}
.cookie-accept:hover {
  background: var(--accent-dark);
}
.cookie-decline {
  background: transparent;
  color: rgba(255,255,255,0.7);
  border: 1px solid rgba(255,255,255,0.3);
  padding: 10px 20px;
  border-radius: var(--radius-sm);
  font-weight: 500;
  font-size: 0.875rem;
  min-height: 44px;
  cursor: pointer;
  transition: all var(--transition);
}
.cookie-decline:hover {
  border-color: rgba(255,255,255,0.6);
  color: #fff;
}

/* --- Form Error Messages (Accessibility) --- */
.form-error {
  color: var(--accent);
  font-size: 0.875rem;
  margin-top: 4px;
  display: none;
}
.form-group.has-error .form-error {
  display: block;
}
.form-group.has-error input,
.form-group.has-error select,
.form-group.has-error textarea {
  border-color: var(--accent);
}

/* --- Privacy Notice (Contact Form) --- */
.form-privacy {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-top: 12px;
  line-height: 1.5;
}
.form-privacy a {
  color: var(--primary);
  text-decoration: underline;
}

/* --- Focus visible for all interactive elements --- */
a:focus-visible,
button:focus-visible,
select:focus-visible,
input:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid var(--primary);
  outline-offset: 2px;
}

/* --- Touch :active feedback (mobile) --- */
.btn:active,
.btn-primary:active,
.btn-outline:active {
  transform: scale(0.97);
  opacity: 0.9;
}

.gallery-filter:active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

.city-tag:active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

.cookie-accept:active {
  background: var(--accent-dark);
}

.cookie-decline:active {
  border-color: rgba(255,255,255,0.6);
  color: #fff;
}

/* --- Safe area insets for iPhone notch/home indicator --- */
@supports (padding: env(safe-area-inset-bottom)) {
  .cookie-banner {
    padding-bottom: calc(16px + env(safe-area-inset-bottom));
  }
}
