/*
Theme Name: Coastal Mist Irrigation
Theme URI: https://coastalmistirrigation.com
Author: Coastal Mist Irrigation
Description: Custom theme for Coastal Mist Irrigation — NJ Licensed Irrigation Company. Sprinkler system installation, repair, winterization & seasonal startups across South Jersey.
Version: 1.0
License: GNU General Public License v2 or later
Text Domain: coastal-mist
*/

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --ocean-deep: #0a3d62;
  --ocean-mid: #1a6b8a;
  --ocean-light: #2d8faa;
  --sky-blue: #87ceeb;
  --sky-light: #b8e4f7;
  --grass-dark: #2d6a1e;
  --grass-mid: #4a9e2f;
  --grass-light: #6bc745;
  --sun-gold: #f5b731;
  --sun-orange: #e8942a;
  --sand: #f5e6c8;
  --sand-light: #faf3e6;
  --white: #ffffff;
  --text-dark: #1a2a1a;
  --text-mid: #3a4a3a;
  --mist: rgba(135, 206, 235, 0.15);
  --shadow-coastal: 0 4px 30px rgba(10, 61, 98, 0.12);
  --shadow-deep: 0 8px 40px rgba(10, 61, 98, 0.2);
  --radius: 12px;
  --radius-lg: 20px;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Montserrat', sans-serif;
  color: var(--text-dark);
  background: var(--white);
  overflow-x: hidden;
  line-height: 1.7;
  margin: 0; padding: 0;
}

/* ========== NAV ========== */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  background: rgba(255,255,255,0.95);
  backdrop-filter: blur(12px);
  border-bottom: 2px solid var(--grass-light);
  transition: all 0.3s;
}
.nav.scrolled { box-shadow: var(--shadow-coastal); }
.nav-inner {
  max-width: 1280px; margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.6rem 2rem;
}
.nav-logo { display: flex; align-items: center; text-decoration: none; }
.nav-logo-img { height: 75px; width: auto; display: block; }
.nav-links { display: flex; gap: 0; align-items: center; }
.nav-links a {
  text-decoration: none; color: var(--text-dark); font-weight: 600;
  font-size: 0.82rem; padding: 0.5rem 0.9rem; border-radius: 8px;
  transition: all 0.25s; text-transform: uppercase; letter-spacing: 0.5px;
  position: relative;
}
.nav-links a:hover { color: var(--ocean-mid); background: var(--mist); }
.nav-links a.current-menu-item a,
.nav-links a.active { color: var(--ocean-deep); }
.nav-cta {
  background: linear-gradient(135deg, var(--grass-mid), var(--grass-dark)) !important;
  color: white !important; padding: 0.6rem 1.2rem !important;
  border-radius: 50px !important; font-weight: 700 !important;
  box-shadow: 0 2px 12px rgba(45,106,30,0.3);
  letter-spacing: 0 !important;
}
.nav-cta:hover { transform: translateY(-1px); box-shadow: 0 4px 20px rgba(45,106,30,0.4); background: linear-gradient(135deg, var(--grass-light), var(--grass-mid)) !important; }

.mobile-toggle { display: none; background: none; border: none; cursor: pointer; padding: 0.5rem; }
.mobile-toggle span { display: block; width: 24px; height: 2px; background: var(--ocean-deep); margin: 5px 0; transition: 0.3s; border-radius: 2px; }

/* ========== HERO ========== */
.hero {
  position: relative; min-height: 100vh;
  background: linear-gradient(170deg, var(--sky-light) 0%, var(--sky-blue) 25%, #a8d8ea 50%, var(--sand-light) 100%);
  display: flex; align-items: center; justify-content: center;
  padding: 8rem 2rem 4rem; overflow: hidden;
}
.hero::before {
  content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 200px;
  background: linear-gradient(to top, var(--grass-mid) 0%, var(--grass-light) 30%, transparent 100%);
  z-index: 1;
}
.hero::after {
  content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 80px;
  background: var(--grass-dark); z-index: 2;
  clip-path: polygon(0 60%, 5% 40%, 10% 55%, 15% 35%, 20% 50%, 25% 30%, 30% 48%, 35% 28%, 40% 45%, 45% 25%, 50% 42%, 55% 22%, 60% 40%, 65% 25%, 70% 45%, 75% 30%, 80% 50%, 85% 35%, 90% 52%, 95% 38%, 100% 55%, 100% 100%, 0 100%);
}
.water-drops { position: absolute; top: 0; left: 0; right: 0; bottom: 0; pointer-events: none; z-index: 0; overflow: hidden; }
.drop {
  position: absolute; width: 4px; border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%;
  background: rgba(135, 206, 235, 0.5);
  animation: dropFall linear infinite;
}
@keyframes dropFall {
  0% { transform: translateY(-20px) scale(1); opacity: 0.7; }
  100% { transform: translateY(100vh) scale(0.5); opacity: 0; }
}
.sun {
  position: absolute; top: 60px; right: 15%; width: 120px; height: 120px;
  background: radial-gradient(circle, var(--sun-gold) 30%, var(--sun-orange) 60%, transparent 70%);
  border-radius: 50%; z-index: 0;
  box-shadow: 0 0 80px var(--sun-gold), 0 0 160px rgba(245,183,49,0.3);
  animation: sunPulse 4s ease-in-out infinite;
}
@keyframes sunPulse { 0%,100% { transform: scale(1); } 50% { transform: scale(1.05); } }
.cloud {
  position: absolute; background: rgba(255,255,255,0.8); border-radius: 50px;
  z-index: 0; animation: cloudDrift linear infinite;
}
.cloud::before, .cloud::after {
  content: ''; position: absolute; background: inherit; border-radius: 50%;
}
.cloud-1 { width: 200px; height: 50px; top: 100px; left: -200px; animation-duration: 35s; }
.cloud-1::before { width: 80px; height: 80px; top: -40px; left: 30px; }
.cloud-1::after { width: 60px; height: 60px; top: -25px; left: 100px; }
.cloud-2 { width: 150px; height: 40px; top: 180px; left: -150px; animation-duration: 45s; animation-delay: 10s; }
.cloud-2::before { width: 60px; height: 60px; top: -30px; left: 20px; }
.cloud-2::after { width: 50px; height: 50px; top: -20px; left: 80px; }
@keyframes cloudDrift { 0% { transform: translateX(0); } 100% { transform: translateX(calc(100vw + 400px)); } }
.hero-content {
  position: relative; z-index: 10; text-align: center;
  max-width: 900px;
  animation: heroFadeIn 1s ease-out;
}
@keyframes heroFadeIn { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }
.hero-logo {
  width: 260px; height: auto; margin: 0 auto 1.5rem;
  border-radius: var(--radius-lg);
  filter: drop-shadow(0 8px 30px rgba(0,0,0,0.15));
}
.hero h1 {
  font-family: 'Playfair Display', serif; font-size: clamp(2.2rem, 5vw, 3.8rem);
  color: var(--ocean-deep); line-height: 1.15; margin-bottom: 0.8rem;
  text-shadow: 0 2px 20px rgba(255,255,255,0.5);
}
.hero h1 em { font-style: normal; color: var(--grass-dark); }
.hero-sub {
  font-size: clamp(1rem, 2vw, 1.25rem); color: var(--text-mid);
  margin-bottom: 0.5rem; font-weight: 500;
}
.hero-license {
  font-size: 0.85rem; color: var(--ocean-mid); font-weight: 600;
  margin-bottom: 2rem; letter-spacing: 0.5px;
}
.hero-btns { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }
.btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.9rem 2rem; border-radius: 50px; font-weight: 700;
  font-size: 0.95rem; text-decoration: none; cursor: pointer;
  transition: all 0.3s; border: none; font-family: inherit;
}
.btn-primary {
  background: linear-gradient(135deg, var(--grass-mid), var(--grass-dark));
  color: white; box-shadow: 0 4px 20px rgba(45,106,30,0.35);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 30px rgba(45,106,30,0.45); }
.btn-secondary {
  background: white; color: var(--ocean-deep);
  border: 2px solid var(--ocean-mid);
  box-shadow: 0 4px 20px rgba(10,61,98,0.1);
}
.btn-secondary:hover { background: var(--ocean-deep); color: white; }
.btn-gold {
  background: linear-gradient(135deg, var(--sun-gold), var(--sun-orange));
  color: var(--ocean-deep); box-shadow: 0 4px 20px rgba(245,183,49,0.4);
}
.btn-gold:hover { transform: translateY(-2px); box-shadow: 0 8px 30px rgba(245,183,49,0.5); }

/* ========== TRUST BAR ========== */
.trust-bar {
  background: var(--ocean-deep); padding: 1.2rem 2rem;
  display: flex; justify-content: center; gap: 3rem; flex-wrap: wrap;
}
.trust-item { display: flex; align-items: center; gap: 0.5rem; color: white; font-weight: 600; font-size: 0.9rem; }
.trust-icon {
  width: 36px; height: 36px; background: rgba(255,255,255,0.15); border-radius: 50%;
  display: flex; align-items: center; justify-content: center; font-size: 1.1rem;
}

/* ========== SECTIONS ========== */
.section { padding: 5rem 2rem; max-width: 1200px; margin: 0 auto; }
.section-header { text-align: center; margin-bottom: 3.5rem; }
.section-tag {
  font-size: 0.8rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 3px; color: var(--grass-mid); margin-bottom: 0.5rem;
}
.section-title {
  font-family: 'Playfair Display', serif; font-size: clamp(1.8rem, 4vw, 2.8rem);
  color: var(--ocean-deep); line-height: 1.2; margin-bottom: 1rem;
}
.section-desc { max-width: 650px; margin: 0 auto; color: var(--text-mid); font-size: 1.05rem; }

/* ========== SERVICES GRID ========== */
.services-bg { background: linear-gradient(180deg, var(--sand-light) 0%, var(--white) 100%); padding: 5rem 0; }
.services-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 2rem; }
.service-card {
  background: white; border-radius: var(--radius-lg); padding: 2.5rem 2rem;
  box-shadow: var(--shadow-coastal); transition: all 0.35s;
  border-top: 4px solid var(--grass-mid); cursor: pointer;
  position: relative; overflow: hidden;
}
.service-card::after {
  content: ''; position: absolute; top: 0; left: 0; right: 0; bottom: 0;
  background: linear-gradient(135deg, var(--mist), transparent);
  opacity: 0; transition: 0.35s;
}
.service-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-deep); }
.service-card:hover::after { opacity: 1; }
.service-icon {
  width: 60px; height: 60px; border-radius: 14px;
  background: linear-gradient(135deg, var(--ocean-light), var(--ocean-deep));
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem; margin-bottom: 1.2rem; position: relative; z-index: 1;
}
.service-card h3 {
  font-family: 'Playfair Display', serif; font-size: 1.3rem;
  color: var(--ocean-deep); margin-bottom: 0.8rem; position: relative; z-index: 1;
}
.service-card p { color: var(--text-mid); font-size: 0.95rem; line-height: 1.7; position: relative; z-index: 1; }
.service-card .learn-more {
  display: inline-flex; align-items: center; gap: 0.3rem; margin-top: 1rem;
  color: var(--grass-mid); font-weight: 700; font-size: 0.85rem;
  text-decoration: none; position: relative; z-index: 1;
}

/* ========== WHY CHOOSE ========== */
.why-section { background: linear-gradient(135deg, var(--ocean-deep) 0%, var(--ocean-mid) 100%); padding: 5rem 0; }
.why-section .section-tag { color: var(--sun-gold); }
.why-section .section-title { color: white; }
.why-section .section-desc { color: rgba(255,255,255,0.8); }
.why-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem; max-width: 1200px; margin: 0 auto; padding: 0 2rem;
}
.why-card {
  text-align: center; padding: 2rem;
  background: rgba(255,255,255,0.08); border-radius: var(--radius-lg);
  border: 1px solid rgba(255,255,255,0.1); transition: 0.3s;
}
.why-card:hover { background: rgba(255,255,255,0.14); transform: translateY(-4px); }
.why-num { font-family: 'Playfair Display', serif; font-size: 3rem; color: var(--sun-gold); font-weight: 900; line-height: 1; }
.why-card h3 { color: white; font-size: 1.1rem; margin: 0.8rem 0 0.5rem; }
.why-card p { color: rgba(255,255,255,0.7); font-size: 0.9rem; }

/* ========== SERVICE AREAS ========== */
.areas-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 0.8rem; }
.area-tag {
  background: var(--mist); border: 1px solid rgba(45,159,170,0.15);
  padding: 0.7rem 1rem; border-radius: var(--radius); text-align: center;
  font-weight: 600; font-size: 0.9rem; color: var(--ocean-deep);
  transition: 0.25s; cursor: default;
}
.area-tag:hover { background: var(--ocean-deep); color: white; transform: scale(1.03); }

/* ========== SEASONAL CTA ========== */
.seasonal-cta {
  background: linear-gradient(135deg, var(--grass-dark), var(--grass-mid));
  border-radius: var(--radius-lg); padding: 3.5rem; text-align: center;
  color: white; margin: 3rem auto; max-width: 900px;
  box-shadow: var(--shadow-deep); position: relative; overflow: hidden;
}
.seasonal-cta::before {
  content: ''; position: absolute; top: -50%; right: -20%; width: 300px; height: 300px;
  background: radial-gradient(circle, rgba(255,255,255,0.08), transparent 70%);
  border-radius: 50%;
}
.seasonal-cta h2 { font-family: 'Playfair Display', serif; font-size: 2rem; margin-bottom: 0.8rem; }
.seasonal-cta p { font-size: 1.1rem; opacity: 0.9; margin-bottom: 1.5rem; max-width: 550px; margin-left: auto; margin-right: auto; }

/* ========== FORMS ========== */
.form-section { background: linear-gradient(180deg, var(--sand-light), var(--white)); padding: 5rem 0; }
.form-container {
  max-width: 700px; margin: 0 auto; background: white;
  border-radius: var(--radius-lg); padding: 3rem;
  box-shadow: var(--shadow-deep);
}
.form-group { margin-bottom: 1.5rem; }
.form-group label {
  display: block; font-weight: 600; font-size: 0.9rem;
  color: var(--ocean-deep); margin-bottom: 0.4rem;
}
.form-group input, .form-group select, .form-group textarea {
  width: 100%; padding: 0.85rem 1rem; border: 2px solid #e0e8e0;
  border-radius: var(--radius); font-family: inherit; font-size: 0.95rem;
  transition: 0.25s; background: var(--sand-light);
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
  outline: none; border-color: var(--ocean-mid);
  box-shadow: 0 0 0 3px rgba(26,107,138,0.1);
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-note { font-size: 0.8rem; color: var(--text-mid); margin-top: 0.3rem; }

/* ========== FAQ ========== */
.faq-list { max-width: 800px; margin: 0 auto; }
.faq-item { border-bottom: 1px solid #e8ede8; overflow: hidden; }
.faq-question {
  width: 100%; padding: 1.5rem 0; background: none; border: none;
  display: flex; justify-content: space-between; align-items: center;
  font-family: inherit; font-size: 1.05rem; font-weight: 600;
  color: var(--ocean-deep); cursor: pointer; text-align: left;
}
.faq-question span { font-size: 1.3rem; transition: 0.3s; }
.faq-answer { max-height: 0; overflow: hidden; transition: max-height 0.4s ease; color: var(--text-mid); line-height: 1.8; }
.faq-answer.open { max-height: 300px; }
.faq-answer-inner { padding-bottom: 1.5rem; }

/* ========== BLOG ========== */
.blog-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 2rem; }
.blog-card {
  background: white; border-radius: var(--radius-lg);
  box-shadow: var(--shadow-coastal); overflow: hidden; transition: 0.3s;
}
.blog-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-deep); }
.blog-img {
  height: 200px;
  background: linear-gradient(135deg, var(--sky-blue), var(--grass-light));
  display: flex; align-items: center; justify-content: center; font-size: 3rem;
}
.blog-body { padding: 1.8rem; }
.blog-body .blog-tag {
  font-size: 0.7rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 2px; color: var(--grass-mid); margin-bottom: 0.5rem;
}
.blog-body h3 { font-family: 'Playfair Display', serif; font-size: 1.2rem; color: var(--ocean-deep); margin-bottom: 0.5rem; }
.blog-body p { font-size: 0.9rem; color: var(--text-mid); }

/* ========== FOOTER ========== */
.footer {
  background: linear-gradient(180deg, var(--ocean-deep) 0%, #072a45 100%);
  color: white; padding: 4rem 2rem 2rem;
}
.footer-grid {
  max-width: 1200px; margin: 0 auto;
  display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 3rem;
}
.footer-brand h3 { font-family: 'Caveat', cursive; font-size: 2rem; margin-bottom: 0.5rem; }
.footer-brand p { color: rgba(255,255,255,0.65); font-size: 0.9rem; margin-bottom: 1rem; line-height: 1.7; }
.footer h4 { font-size: 0.85rem; text-transform: uppercase; letter-spacing: 2px; margin-bottom: 1rem; color: var(--sun-gold); }
.footer a { color: rgba(255,255,255,0.7); text-decoration: none; font-size: 0.9rem; transition: 0.2s; display: block; padding: 0.25rem 0; }
.footer a:hover { color: white; padding-left: 4px; }
.footer-phone {
  font-size: 1.4rem; font-weight: 800; color: var(--sun-gold);
  text-decoration: none; display: inline-block; margin-top: 0.5rem;
}
.footer-thankyou { text-align: center; padding: 2rem 2rem 0; max-width: 600px; margin: 0 auto; }
.footer-thankyou p.thankyou-msg { font-family: 'Caveat', cursive; font-size: 1.6rem; color: var(--sun-gold); line-height: 1.4; }
.footer-thankyou p.thankyou-sig { font-size: 0.85rem; color: rgba(255,255,255,0.5); margin-top: 0.3rem; }
.footer-bottom {
  max-width: 1200px; margin: 3rem auto 0; padding-top: 1.5rem;
  border-top: 1px solid rgba(255,255,255,0.1);
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 1rem;
  font-size: 0.8rem; color: rgba(255,255,255,0.4);
}

/* ========== SERVICE DETAIL ========== */
.service-detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: center; }
.service-detail-img {
  border-radius: var(--radius-lg); height: 300px;
  display: flex; align-items: center; justify-content: center; font-size: 5rem;
}

/* ========== CONTACT LAYOUT ========== */
.contact-layout { display: grid; grid-template-columns: 1fr 340px; gap: 2.5rem; align-items: start; }
.contact-sidebar-card { border-radius: var(--radius-lg); padding: 2rem; margin-bottom: 1.5rem; }

/* ========== SCHEDULER ========== */
.service-option {
  display: flex; align-items: center; gap: 1rem; padding: 1.2rem;
  border: 2px solid #e0e8e0; border-radius: var(--radius);
  cursor: pointer; transition: 0.2s; background: white;
}
.service-option:hover { border-color: var(--ocean-light); }

/* ========== ANIMATIONS ========== */
.fade-in { opacity: 0; transform: translateY(20px); transition: all 0.6s ease; }
.fade-in.visible { opacity: 1; transform: translateY(0); }

/* ========== RESPONSIVE ========== */
@media (max-width: 768px) {
  .nav-links { display: none; position: absolute; top: 100%; left: 0; right: 0; background: white; flex-direction: column; padding: 1rem; box-shadow: var(--shadow-deep); }
  .nav-links.open { display: flex; }
  .mobile-toggle { display: block; }
  .hero { min-height: auto; padding: 7rem 1.5rem 6rem; }
  .hero-logo { width: 180px; }
  .trust-bar { gap: 1.5rem; padding: 1rem; }
  .trust-item { font-size: 0.75rem; }
  .form-row { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .seasonal-cta { padding: 2rem 1.5rem; margin: 2rem 1rem; }
  .sun { width: 80px; height: 80px; top: 80px; right: 10%; }
  .service-detail-grid { grid-template-columns: 1fr !important; }
  .contact-layout { grid-template-columns: 1fr !important; }
}

/* Override WP admin bar offset */
body.admin-bar .nav { top: 32px; }
@media (max-width: 782px) { body.admin-bar .nav { top: 46px; } }


/* Area tag links - same style as area-tag but with anchor tag reset */
a.area-tag-link {
  display: block;
  background: var(--mist);
  border: 1px solid rgba(45,159,170,0.15);
  padding: 0.7rem 1rem;
  border-radius: var(--radius);
  text-align: center;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--ocean-deep);
  transition: 0.25s;
  cursor: pointer;
  text-decoration: none;
}
a.area-tag-link:hover {
  background: var(--ocean-light);
  color: var(--ocean-deep);
  text-decoration: none;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(45,159,170,0.18);
}
