/* ==========================================================================
   NY PLUMBING — HOWARD BEACH, QUEENS, NY
   Design System & Master Stylesheet
   Identity: Coastal Marine Slate, Deep Navy & Warm Amber/Ember Accents
   Class Prefix: hwb-
   ========================================================================== */

:root {
  --hwb-navy-900: #0a192f;
  --hwb-navy-800: #102a43;
  --hwb-navy-700: #1a365d;
  --hwb-navy-600: #234e70;
  --hwb-slate-500: #486581;
  --hwb-slate-400: #627d98;
  --hwb-slate-300: #829ab1;
  --hwb-slate-100: #f0f4f8;
  --hwb-slate-50: #f8fafc;
  --hwb-white: #ffffff;
  --hwb-charcoal: #1f2937;
  --hwb-gray-700: #374151;
  --hwb-gray-600: #4b5563;
  --hwb-gray-200: #e2e8f0;
  --hwb-gray-100: #f1f5f9;

  /* Accent - High Visibility Ember Heat */
  --hwb-amber-500: #d97706;
  --hwb-amber-600: #b45309;
  --hwb-amber-400: #f59e0b;
  --hwb-amber-glow: rgba(217, 119, 6, 0.25);

  /* Alert / Emergency */
  --hwb-red-700: #b91c1c;
  --hwb-red-50: #fef2f2;
  --hwb-red-border: #fecaca;

  /* Typography */
  --hwb-font-main: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Helvetica Neue", Arial, sans-serif;
  --hwb-font-mono: SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;

  /* Spacing */
  --hwb-container: 1200px;
  --hwb-radius-sm: 4px;
  --hwb-radius-md: 8px;
  --hwb-radius-lg: 12px;
  --hwb-shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
  --hwb-shadow-md: 0 4px 12px rgba(10, 25, 47, 0.08);
  --hwb-shadow-lg: 0 10px 25px rgba(10, 25, 47, 0.12);
  --hwb-transition: all 0.2s ease-in-out;
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--hwb-font-main);
  color: var(--hwb-charcoal);
  background-color: var(--hwb-white);
  line-height: 1.65;
  padding-bottom: 70px; /* Space for mobile sticky call bar */
}

@media (min-width: 992px) {
  body {
    padding-bottom: 0;
  }
}

/* Accessibility: Skip Link */
.hwb-skip-link {
  position: absolute;
  top: -40px;
  left: 10px;
  background: var(--hwb-amber-500);
  color: var(--hwb-white);
  padding: 8px 16px;
  z-index: 9999;
  text-decoration: none;
  font-weight: 700;
  border-radius: var(--hwb-radius-sm);
  transition: top 0.2s ease;
}

.hwb-skip-link:focus {
  top: 10px;
}

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

.hwb-section {
  padding: 56px 0;
}

@media (min-width: 768px) {
  .hwb-section {
    padding: 72px 0;
  }
}

.hwb-section-alt {
  background-color: var(--hwb-slate-50);
}

.hwb-section-dark {
  background-color: var(--hwb-navy-900);
  color: var(--hwb-white);
}

/* Typography Hierarchy */
h1, h2, h3, h4 {
  color: var(--hwb-navy-900);
  line-height: 1.25;
  font-weight: 700;
  margin-bottom: 1rem;
}

h1 {
  font-size: 2rem;
  letter-spacing: -0.02em;
}

h2 {
  font-size: 1.65rem;
  margin-top: 1.5rem;
  letter-spacing: -0.01em;
}

h3 {
  font-size: 1.25rem;
  margin-top: 1.25rem;
}

h4 {
  font-size: 1.1rem;
}

p {
  margin-bottom: 1.25rem;
  color: var(--hwb-gray-700);
}

.hwb-lead {
  font-size: 1.15rem;
  line-height: 1.6;
  color: var(--hwb-slate-500);
  font-weight: 500;
}

ul, ol {
  margin-bottom: 1.25rem;
  padding-left: 1.5rem;
  color: var(--hwb-gray-700);
}

li {
  margin-bottom: 0.5rem;
}

a {
  color: var(--hwb-navy-700);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: var(--hwb-transition);
}

a:hover, a:focus {
  color: var(--hwb-amber-600);
}

/* Header & Navigation */
.hwb-header {
  background-color: var(--hwb-navy-900);
  color: var(--hwb-white);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.hwb-nav-wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  padding: 10px 0;
}

.hwb-brand {
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: var(--hwb-white);
}

.hwb-brand-title {
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  color: var(--hwb-white);
  line-height: 1.1;
}

.hwb-brand-sub {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--hwb-slate-300);
  font-weight: 600;
}

/* Nav Menu */
.hwb-nav-menu {
  display: none;
  list-style: none;
  padding: 0;
  margin: 0;
}

.hwb-nav-item {
  position: relative;
}

.hwb-nav-link {
  color: var(--hwb-white);
  text-decoration: none;
  padding: 10px 14px;
  font-weight: 600;
  font-size: 0.95rem;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: var(--hwb-radius-sm);
  transition: var(--hwb-transition);
}

.hwb-nav-link:hover, .hwb-nav-link:focus, .hwb-nav-link.active {
  background-color: rgba(255, 255, 255, 0.1);
  color: var(--hwb-amber-400);
}

/* Dropdown */
.hwb-dropdown-toggle {
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
}

.hwb-dropdown-arrow {
  display: inline-block;
  width: 0;
  height: 0;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 5px solid currentColor;
  transition: transform 0.2s ease;
}

.hwb-dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background-color: var(--hwb-navy-800);
  min-width: 250px;
  border-radius: var(--hwb-radius-sm);
  box-shadow: var(--hwb-shadow-lg);
  list-style: none;
  padding: 8px 0;
  border: 1px solid rgba(255, 255, 255, 0.1);
  z-index: 1050;
}

.hwb-dropdown-item a {
  display: block;
  padding: 8px 18px;
  color: var(--hwb-slate-100);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: var(--hwb-transition);
}

.hwb-dropdown-item a:hover, .hwb-dropdown-item a:focus {
  background-color: var(--hwb-navy-700);
  color: var(--hwb-amber-400);
  padding-left: 22px;
}

/* Header Action / Phone Button (Single Button Requirement) */
.hwb-header-cta {
  display: none;
}

.hwb-btn-call {
  background-color: var(--hwb-amber-500);
  color: var(--hwb-white);
  padding: 10px 18px;
  border-radius: var(--hwb-radius-sm);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.95rem;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 2px 6px var(--hwb-amber-glow);
  transition: var(--hwb-transition);
}

.hwb-btn-call:hover, .hwb-btn-call:focus {
  background-color: var(--hwb-amber-600);
  color: var(--hwb-white);
  transform: translateY(-1px);
}

.hwb-phone-icon {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

/* Mobile Toggle */
.hwb-nav-toggle {
  display: flex;
  flex-direction: column;
  justify-content: space-around;
  width: 44px;
  height: 44px;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--hwb-radius-sm);
  padding: 10px;
  cursor: pointer;
  z-index: 1100;
}

.hwb-nav-toggle span {
  width: 100%;
  height: 2px;
  background-color: var(--hwb-white);
  transition: var(--hwb-transition);
}

.hwb-nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}
.hwb-nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}
.hwb-nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* Desktop Navigation rules */
@media (min-width: 992px) {
  h1 { font-size: 2.5rem; }
  h2 { font-size: 1.85rem; }
  
  .hwb-nav-toggle {
    display: none;
  }
  
  .hwb-nav-menu {
    display: flex;
    align-items: center;
    gap: 4px;
  }
  
  .hwb-header-cta {
    display: block;
  }

  .hwb-nav-item:hover .hwb-dropdown-menu,
  .hwb-nav-item:focus-within .hwb-dropdown-menu {
    display: block;
  }
}

/* Mobile Menu Opened State */
@media (max-width: 991px) {
  .hwb-nav-menu.is-open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background-color: var(--hwb-navy-900);
    padding: 16px 20px 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
  }

  .hwb-nav-menu.is-open .hwb-nav-link {
    padding: 12px 8px;
    font-size: 1.05rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    width: 100%;
    justify-content: space-between;
  }

  .hwb-dropdown-menu {
    position: static;
    background-color: rgba(0, 0, 0, 0.25);
    border: none;
    box-shadow: none;
    padding-left: 12px;
  }

  .hwb-dropdown-menu.is-open {
    display: block;
  }
}

/* Breadcrumbs */
.hwb-breadcrumb-wrapper {
  background-color: var(--hwb-gray-100);
  padding: 10px 0;
  border-bottom: 1px solid var(--hwb-gray-200);
  font-size: 0.85rem;
}

.hwb-breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  list-style: none;
  margin: 0;
  padding: 0;
}

.hwb-breadcrumb-item {
  display: flex;
  align-items: center;
}

.hwb-breadcrumb-item + .hwb-breadcrumb-item::before {
  content: "/";
  padding: 0 8px;
  color: var(--hwb-slate-400);
}

.hwb-breadcrumb-item a {
  color: var(--hwb-navy-700);
  text-decoration: none;
}

.hwb-breadcrumb-item a:hover {
  text-decoration: underline;
}

.hwb-breadcrumb-item[aria-current="page"] {
  color: var(--hwb-slate-500);
  font-weight: 600;
}

/* Hero Section */
.hwb-hero {
  background: linear-gradient(135deg, var(--hwb-navy-900) 0%, var(--hwb-navy-800) 100%);
  color: var(--hwb-white);
  padding: 48px 0 60px;
  position: relative;
  overflow: hidden;
}

.hwb-hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 36px;
  align-items: center;
}

@media (min-width: 992px) {
  .hwb-hero-grid {
    grid-template-columns: 1.15fr 0.85fr;
  }
}

.hwb-hero-content h1 {
  color: var(--hwb-white);
  margin-bottom: 1.25rem;
}

.hwb-hero-content p {
  color: var(--hwb-slate-100);
  font-size: 1.1rem;
  margin-bottom: 1.5rem;
}

.hwb-hero-badge {
  display: inline-block;
  background-color: rgba(217, 119, 6, 0.2);
  color: var(--hwb-amber-400);
  border: 1px solid var(--hwb-amber-500);
  padding: 4px 12px;
  border-radius: 50px;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 1rem;
}

.hwb-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
  margin-top: 1.5rem;
}

.hwb-btn-primary {
  background-color: var(--hwb-amber-500);
  color: var(--hwb-white);
  padding: 14px 24px;
  font-size: 1.05rem;
  font-weight: 700;
  text-decoration: none;
  border-radius: var(--hwb-radius-sm);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  box-shadow: 0 4px 14px var(--hwb-amber-glow);
  transition: var(--hwb-transition);
}

.hwb-btn-primary:hover, .hwb-btn-primary:focus {
  background-color: var(--hwb-amber-600);
  color: var(--hwb-white);
  transform: translateY(-2px);
}

.hwb-hero-image-wrap {
  position: relative;
  border-radius: var(--hwb-radius-md);
  overflow: hidden;
  box-shadow: var(--hwb-shadow-lg);
  border: 2px solid rgba(255, 255, 255, 0.1);
}

.hwb-hero-image-wrap img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  aspect-ratio: 16 / 10;
}

/* Image Framing for Inner Pages */
.hwb-page-image-card {
  margin: 28px 0 36px;
  border-radius: var(--hwb-radius-md);
  overflow: hidden;
  box-shadow: var(--hwb-shadow-md);
  border: 1px solid var(--hwb-gray-200);
  background: var(--hwb-slate-50);
}

.hwb-page-image-card img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  max-height: 480px;
}

.hwb-page-image-caption {
  padding: 10px 16px;
  font-size: 0.85rem;
  color: var(--hwb-slate-500);
  border-top: 1px solid var(--hwb-gray-200);
}

/* Feature Grid & Cards */
.hwb-cards-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  margin-top: 28px;
}

@media (min-width: 640px) {
  .hwb-cards-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 992px) {
  .hwb-cards-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.hwb-card {
  background: var(--hwb-white);
  border: 1px solid var(--hwb-gray-200);
  border-radius: var(--hwb-radius-md);
  padding: 24px;
  box-shadow: var(--hwb-shadow-sm);
  transition: var(--hwb-transition);
}

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

.hwb-card-title {
  font-size: 1.15rem;
  margin-bottom: 0.75rem;
  color: var(--hwb-navy-900);
}

.hwb-card p {
  font-size: 0.95rem;
  color: var(--hwb-gray-600);
  margin-bottom: 1rem;
}

/* Two Column Layouts */
.hwb-two-col {
  display: grid;
  grid-template-columns: 1fr;
  gap: 36px;
  align-items: start;
}

@media (min-width: 768px) {
  .hwb-two-col {
    grid-template-columns: 1fr 1fr;
  }
}

/* Diagnostic Timeline / Steps */
.hwb-process-list {
  list-style: none;
  padding: 0;
  margin: 28px 0;
}

.hwb-process-item {
  position: relative;
  padding-left: 56px;
  margin-bottom: 24px;
}

.hwb-process-step {
  position: absolute;
  left: 0;
  top: 0;
  width: 40px;
  height: 40px;
  background-color: var(--hwb-navy-800);
  color: var(--hwb-white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.1rem;
  border: 2px solid var(--hwb-amber-500);
}

.hwb-process-title {
  font-size: 1.15rem;
  margin-bottom: 0.4rem;
  color: var(--hwb-navy-900);
}

/* Callout Box / Alert Box */
.hwb-callout {
  background-color: var(--hwb-slate-100);
  border-left: 4px solid var(--hwb-navy-700);
  padding: 20px 24px;
  margin: 32px 0;
  border-radius: 0 var(--hwb-radius-sm) var(--hwb-radius-sm) 0;
}

.hwb-callout h3, .hwb-callout h4 {
  margin-top: 0;
  color: var(--hwb-navy-900);
}

.hwb-callout-emergency {
  background-color: var(--hwb-red-50);
  border-left: 4px solid var(--hwb-red-700);
  border: 1px solid var(--hwb-red-border);
  border-left-width: 5px;
}

.hwb-callout-emergency h3, .hwb-callout-emergency h4 {
  color: var(--hwb-red-700);
}

/* In-Content Phone CTA Strip */
.hwb-cta-banner {
  background: linear-gradient(135deg, var(--hwb-navy-900) 0%, var(--hwb-navy-800) 100%);
  color: var(--hwb-white);
  padding: 36px 30px;
  border-radius: var(--hwb-radius-md);
  margin: 40px 0;
  text-align: center;
  box-shadow: var(--hwb-shadow-md);
}

.hwb-cta-banner h3 {
  color: var(--hwb-white);
  font-size: 1.5rem;
  margin-bottom: 0.75rem;
}

.hwb-cta-banner p {
  color: var(--hwb-slate-100);
  max-width: 650px;
  margin: 0 auto 1.5rem;
}

/* Technical Comparison Table */
.hwb-table-wrap {
  overflow-x: auto;
  margin: 28px 0;
  border: 1px solid var(--hwb-gray-200);
  border-radius: var(--hwb-radius-md);
}

.hwb-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.95rem;
}

.hwb-table th, .hwb-table td {
  padding: 14px 18px;
  border-bottom: 1px solid var(--hwb-gray-200);
}

.hwb-table th {
  background-color: var(--hwb-navy-900);
  color: var(--hwb-white);
  font-weight: 700;
}

.hwb-table tr:nth-child(even) {
  background-color: var(--hwb-slate-50);
}

/* FAQs Accordion */
.hwb-faq-section {
  margin: 48px 0;
}

.hwb-faq-item {
  border: 1px solid var(--hwb-gray-200);
  border-radius: var(--hwb-radius-sm);
  margin-bottom: 12px;
  background: var(--hwb-white);
  overflow: hidden;
}

.hwb-faq-question {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  padding: 16px 20px;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--hwb-navy-900);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: inherit;
}

.hwb-faq-question:hover {
  background-color: var(--hwb-slate-50);
}

.hwb-faq-icon {
  font-size: 1.25rem;
  color: var(--hwb-amber-500);
  transition: transform 0.2s ease;
}

.hwb-faq-answer {
  display: none;
  padding: 0 20px 20px;
  color: var(--hwb-gray-700);
}

.hwb-faq-item.is-active .hwb-faq-answer {
  display: block;
}

.hwb-faq-item.is-active .hwb-faq-icon {
  transform: rotate(45deg);
}

/* Service Area Neighborhood Grid */
.hwb-neighborhood-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  margin: 32px 0;
}

@media (min-width: 768px) {
  .hwb-neighborhood-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.hwb-neighborhood-card {
  border-left: 4px solid var(--hwb-amber-500);
  background: var(--hwb-white);
  border-radius: 0 var(--hwb-radius-sm) var(--hwb-radius-sm) 0;
  padding: 20px;
  box-shadow: var(--hwb-shadow-sm);
  border-top: 1px solid var(--hwb-gray-200);
  border-right: 1px solid var(--hwb-gray-200);
  border-bottom: 1px solid var(--hwb-gray-200);
}

.hwb-neighborhood-card h3 {
  margin-top: 0;
  color: var(--hwb-navy-900);
}

/* Footer (Distinct Dark Navy with accessible text) */
.hwb-footer {
  background-color: var(--hwb-navy-900);
  color: var(--hwb-slate-300);
  padding: 56px 0 28px;
  font-size: 0.9rem;
  border-top: 3px solid var(--hwb-amber-500);
}

.hwb-footer a {
  color: var(--hwb-slate-100);
  text-decoration: none;
}

.hwb-footer a:hover, .hwb-footer a:focus {
  color: var(--hwb-amber-400);
  text-decoration: underline;
}

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

@media (min-width: 640px) {
  .hwb-footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 992px) {
  .hwb-footer-grid {
    grid-template-columns: 1.4fr 1fr 1fr 1fr;
  }
}

.hwb-footer-col h4 {
  color: var(--hwb-white);
  font-size: 1.05rem;
  margin-bottom: 1.1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding-bottom: 8px;
}

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

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

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

.hwb-network-attribution {
  margin-top: 8px;
  color: var(--hwb-slate-400);
}

.hwb-network-attribution a {
  color: var(--hwb-amber-400);
  font-weight: 600;
}

/* Fixed Mobile Call Bar */
.hwb-mobile-bar {
  display: block;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background-color: var(--hwb-navy-900);
  padding: 10px 16px;
  box-shadow: 0 -3px 12px rgba(0, 0, 0, 0.25);
  z-index: 999;
  border-top: 2px solid var(--hwb-amber-500);
}

@media (min-width: 992px) {
  .hwb-mobile-bar {
    display: none;
  }
}

.hwb-mobile-bar-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background-color: var(--hwb-amber-500);
  color: var(--hwb-white);
  padding: 12px;
  border-radius: var(--hwb-radius-sm);
  text-decoration: none;
  font-weight: 700;
  font-size: 1.05rem;
}

.hwb-mobile-bar-btn:active {
  background-color: var(--hwb-amber-600);
}
