/* =========================================
   Andromeda Plumbing & Heating
   Dark + Shamrock Green Theme
   ========================================= */

/* ---------- VARIABLES ---------- */
:root {
  /* Light mode */
  --bg-light: #ffffff;
  --panel-light: #f8fafc;
  --text-main-light: #0f172a;
  --text-muted-light: #6b7280;

  /* Dark mode */
  --bg-dark: #020617;
  --panel-dark: #020617;
  --card-dark: #050816;
  --text-main-dark: #e5e7eb;
  --text-muted-dark: #9ca3af;

  /* Accent (shamrock green) */
  --accent: #0b6623;
  --accent-soft: #16a34a;

  --border-soft: rgba(148, 163, 184, 0.4);
  --radius-lg: 18px;
  --radius-md: 12px;
  --shadow-soft: 0 18px 45px rgba(15, 23, 42, 0.6);
}

/* ---------- GLOBAL RESET ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
  background: var(--bg-light);
  color: var(--text-main-light);
  padding-top: 90px; /* space for sticky header */
}

/* DARK MODE OVERRIDE */
body.dark-mode {
  background: radial-gradient(circle at top, #020617 0, #000000 55%);
  color: var(--text-main-dark);
}

/* ---------- LAYOUT HELPERS ---------- */
.container {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section {
  padding: 3rem 0;
}

.page-hero {
  padding: 2.5rem 0 1.5rem;
}

.page-section {
  padding: 1rem 0 3rem;
}

/* ---------- HEADER ---------- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  background: rgba(0, 0, 0, 0.96);
  border-bottom: 1px solid rgba(148, 163, 184, 0.35);
  backdrop-filter: blur(16px);
}

/* Light mode header */
body:not(.dark-mode) .site-header {
  background: rgba(255, 255, 255, 0.96);
  border-bottom-color: rgba(148, 163, 184, 0.4);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.7rem 0;
  gap: 1.5rem;
}

/* NAV LEFT */
.nav-left {
  display: flex;
  align-items: center;
  gap: 1.3rem;
  font-size: 0.86rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
}

.nav-left a {
  text-decoration: none;
  color: #9ca3af;
  border-bottom: 2px solid transparent;
  padding-bottom: 0.2rem;
  transition: color 0.15s ease, border-color 0.15s ease;
}

.nav-left a:hover {
  color: var(--accent-soft);
}

.nav-left a.active {
  color: var(--accent-soft);
  border-bottom-color: var(--accent-soft);
}

/* LOGO CENTER (unused now but safe to keep) */
.logo-center {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.2rem;
}

.header-logo {
  height: 52px;
  width: auto;
  border-radius: 999px;
  box-shadow: 0 0 0 1px rgba(148, 163, 184, 0.4);
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
  text-align: center;
}

.brand-text span:first-child {
  font-weight: 800;
  letter-spacing: 0.16em;
  font-size: 0.78rem;
  text-transform: uppercase;
  color: #e5e7eb;
}

.brand-text span:last-child {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: #9ca3af;
}

/* Light mode brand text */
body:not(.dark-mode) .brand-text span:first-child {
  color: #0f172a;
}
body:not(.dark-mode) .brand-text span:last-child {
  color: #4b5563;
}

/* HEADER RIGHT */
.header-right {
  display: flex;
  align-items: center;
  gap: 1.4rem;
}

.header-phone {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  font-size: 0.8rem;
}

.header-phone a {
  text-decoration: none;
  color: var(--accent-soft);
  font-weight: 700;
}

.header-phone span {
  color: var(--text-muted-dark);
}

body:not(.dark-mode) .header-phone span {
  color: var(--text-muted-light);
}

/* TOGGLE */
.toggle-wrapper {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.72rem;
  color: #9ca3af;
}

body:not(.dark-mode) .toggle-wrapper {
  color: #6b7280;
}

.theme-toggle {
  position: relative;
  width: 46px;
  height: 24px;
  border-radius: 999px;
  border: none;
  background: #e5e7eb;
  padding: 0;
  cursor: pointer;
  transition: background 0.18s ease;
}

.theme-toggle::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 3px;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  background: var(--accent);
  box-shadow: 0 1px 4px rgba(15, 23, 42, 0.6);
  transition: transform 0.18s ease, background 0.18s ease;
}

/* When JS marks dark mode */
.theme-toggle.is-dark {
  background: var(--accent);
}
.theme-toggle.is-dark::before {
  background: #ffffff;
  transform: translateX(18px);
}

/* ---------- TYPOGRAPHY ---------- */
h1,
h2,
h3 {
  margin-top: 0;
  margin-bottom: 0.5rem;
  font-weight: 700;
}

.page-hero h1 {
  font-size: 1.9rem;
}

.page-hero p {
  max-width: 40rem;
  color: var(--text-muted-dark);
}

body:not(.dark-mode) .page-hero p {
  color: var(--text-muted-light);
}

.page-content p {
  margin-bottom: 1rem;
  color: var(--text-main-dark);
}

body:not(.dark-mode) .page-content p {
  color: var(--text-main-light);
}

/* Bullet list with checkmarks */
.list-check {
  list-style: none;
  padding-left: 0;
}

.list-check li {
  position: relative;
  padding-left: 1.5rem;
  margin-bottom: 0.4rem;
  font-size: 0.95rem;
}

.list-check li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 0;
  color: var(--accent-soft);
  font-weight: 700;
}

/* ---------- CARDS (for sections that use them) ---------- */
.card {
  background: var(--card-dark);
  border-radius: var(--radius-lg);
  padding: 1.6rem 1.5rem;
  border: 1px solid var(--border-soft);
  box-shadow: var(--shadow-soft);
}

body:not(.dark-mode) .card {
  background: var(--panel-light);
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.18);
}

/* ---------- CONTACT FORM ---------- */
.contact-form {
  max-width: 600px;
  margin: 1.5rem auto 0;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.contact-form label {
  font-size: 0.85rem;
  font-weight: 600;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 12px 14px;
  font-size: 15px;
  border-radius: 8px;
  border: 1px solid rgba(148, 163, 184, 0.6);
  font: inherit;
  background: rgba(15, 23, 42, 0.9);
  color: #e5e7eb;
}

body:not(.dark-mode) .contact-form input,
body:not(.dark-mode) .contact-form textarea {
  background: #ffffff;
  color: #0f172a;
}

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

/* Focus */
.contact-form input:focus,
.contact-form textarea:focus {
  outline: 2px solid var(--accent-soft);
  outline-offset: 1px;
}

/* Button */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 24px;
  font-size: 16px;
  font-weight: 600;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  background: var(--accent);
  color: #ffffff;
  transition: background 0.18s ease, transform 0.08s ease, box-shadow 0.18s ease;
  margin-top: 0.4rem;
}

.btn-primary:hover {
  background: var(--accent-soft);
  transform: translateY(-1px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.45);
}

/* ---------- FOOTER ---------- */
.site-footer {
  background: #000000;
  color: #9ca3af;
  font-size: 0.8rem;
  padding: 1.6rem 0 1.3rem;
  margin-top: 2rem;
}

body:not(.dark-mode) .site-footer {
  background: #0f172a;
  color: #e5e7eb;
}

.footer-inner {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

/* ---------- RESPONSIVE ---------- */
@media (max-width: 900px) {
  .header-inner {
    flex-wrap: wrap;
    gap: 0.75rem;
  }

  .logo-center {
    order: -1;
    width: 100%;
  }
}

@media (max-width: 768px) {
  .header-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .header-right {
    width: 100%;
    justify-content: space-between;
  }

  .nav-left {
    flex-wrap: wrap;
  }

  body {
    padding-top: 110px;
  }

  /* CONTACT PAGE FIXES */
  .contact-form {
    max-width: 600px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 18px;
  }

  .btn-primary {
    padding: 14px 24px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 8px;
    background: var(--accent, #0b6623);
    color: #fff;
    border: none;
    cursor: pointer;
    transition: 0.2s ease;
  }

  .btn-primary:hover {
    background: #0e7a2a;
  }
}
/* -------- MODERN GALLERY -------- */
.modern-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 2rem;
}

.gallery-card {
  background: var(--card-dark);
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 14px 30px rgba(0,0,0,0.35);
}

body:not(.dark-mode) .gallery-card {
  background: #ffffff;
  border-color: rgba(148, 163, 184, 0.35);
  box-shadow: 0 14px 30px rgba(15,23,42,0.18);
}

.gallery-card img {
  width: 100%;
  height: auto;
  display: block;
}

.gallery-info {
  padding: 1.1rem 1.2rem;
}

.gallery-info h3 {
  margin: 0 0 0.45rem;
}

.gallery-info p {
  margin: 0;
  color: var(--text-muted-dark);
}

body:not(.dark-mode) .gallery-info p {
  color: var(--text-muted-light);
}
/* ===== HOMEPAGE LAYOUT (uses existing colors) ===== */

.hero {
  padding: 3rem 0 2.5rem;
}

.hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 2.2fr) minmax(0, 1.5fr);
  gap: 2rem;
  align-items: center;
}

.hero-logo {
  width: 160px;
  height: auto;
  display: block;
  margin-bottom: 0.75rem;
}

.hero-left {
  max-width: 640px;
}

.hero-kicker {
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.8rem;
  color: var(--text-muted-dark);
  margin-bottom: 0.4rem;
}

body:not(.dark-mode) .hero-kicker {
  color: var(--text-muted-light);
}

.hero-title {
  font-size: 2rem;
  margin-bottom: 0.6rem;
}

.hero-subtitle {
  font-size: 0.98rem;
  color: var(--text-muted-dark);
  max-width: 34rem;
  margin-bottom: 1.2rem;
}

body:not(.dark-mode) .hero-subtitle {
  color: var(--text-muted-light);
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.4rem;
}

.hero-badges span {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  padding: 0.3rem 0.7rem;
  border-radius: 999px;
  border: 1px solid rgba(148,163,184,0.45);
  color: var(--text-muted-dark);
}

body:not(.dark-mode) .hero-badges span {
  color: var(--text-muted-light);
}

.hero-cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  align-items: center;
}

.hero-cta-main {
  min-width: 180px;
}

.hero-cta-secondary {
  border: 1px solid rgba(148,163,184,0.55);
  background: transparent;
  color: inherit;
}

/* Right-hand emergency card */
.hero-right-card {
  background: var(--card-dark, #050816);
  border-radius: 16px;
  padding: 1.4rem 1.3rem;
  border: 1px solid rgba(148,163,184,0.4);
}

body:not(.dark-mode) .hero-right-card {
  background: var(--panel-light);
}

.hero-right-card h3 {
  margin-top: 0;
  margin-bottom: 0.5rem;
}

.hero-right-card p {
  margin-top: 0;
  margin-bottom: 0.8rem;
  font-size: 0.95rem;
}

.hero-right-card ul {
  margin: 0 0 0.9rem;
  padding-left: 1.2rem;
  font-size: 0.92rem;
}

.hero-card-call {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 18px;
  border-radius: 999px;
  text-decoration: none;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  font-size: 0.9rem;
}

.hero-card-call:hover {
  background: var(--accent-soft);
}

/* Home services */
.home-services .services-grid {
  display: grid;
  gap: 1.4rem;
}

@media (min-width: 768px) {
  .home-services .services-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* Home gallery preview */
.home-gallery-preview .home-gallery-grid {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .home-gallery-preview .home-gallery-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.home-gallery-item {
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid rgba(148,163,184,0.35);
  background: var(--card-dark, #050816);
}

body:not(.dark-mode) .home-gallery-item {
  background: #ffffff;
}

.home-gallery-item img {
  width: 100%;
  height: auto;
  display: block;
}

.home-gallery-item h3 {
  font-size: 0.95rem;
  margin: 0.7rem 0.8rem 0.8rem;
}

.home-gallery-link {
  margin-top: 1rem;
}

.home-gallery-link a {
  font-size: 0.9rem;
  text-decoration: none;
  color: var(--accent-soft);
}

/* Why + Service Area */
.home-why-inner {
  display: grid;
  gap: 2rem;
}

@media (min-width: 768px) {
  .home-why-inner {
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  }
}

.home-service-area ul {
  margin: 0.5rem 0 0;
  padding-left: 1.2rem;
}

/* Mobile hero + layout */
@media (max-width: 900px) {
  .hero-inner {
    grid-template-columns: 1fr;
  }
}

/* Mobile "Call Now" button */
.mobile-call-btn {
  position: fixed;
  bottom: 18px;
  right: 18px;
  background: var(--accent);
  color: #fff;
  padding: 14px 22px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  box-shadow: 0 8px 25px rgba(0,0,0,0.35);
  z-index: 9999;
  display: none;
}

.mobile-call-btn:hover {
  background: var(--accent-soft);
  transform: scale(1.03);
}

@media (max-width: 768px) {
  .mobile-call-btn {
    display: inline-block;
  }
}


