/* ============================================
   JC Apex Home Services — Global Stylesheet
   ============================================ */

/* --- Custom Properties --- */
:root {
  --green-900: #0d2b1a;
  --green-800: #14432a;
  --green-700: #1a5c3a;
  --green-600: #22764a;
  --green-500: #2d9d64;
  --green-400: #4cba7d;
  --green-300: #7dd3a6;
  --green-200: #b6e8cc;
  --green-100: #e6f5ed;
  --green-50:  #f3faf6;
  --gold-500:  #c8a94e;
  --gold-400:  #d4b95e;
  --gold-300:  #e0ca7e;
  --gold-200:  #f0e4b6;
  --slate-900: #111827;
  --slate-800: #1e293b;
  --slate-700: #334155;
  --slate-600: #475569;
  --slate-500: #64748b;
  --slate-400: #94a3b8;
  --slate-300: #cbd5e1;
  --slate-200: #e2e8f0;
  --slate-100: #f1f5f9;
  --white:     #ffffff;
  --shadow-sm:  0 1px 2px rgba(0,0,0,.06);
  --shadow-md:  0 4px 12px rgba(0,0,0,.08);
  --shadow-lg:  0 10px 30px rgba(0,0,0,.12);
  --shadow-xl:  0 20px 50px rgba(0,0,0,.16);
  --radius-sm:  6px;
  --radius-md:  10px;
  --radius-lg:  16px;
  --radius-xl:  24px;
  --transition: .25s ease;
  --font-body:  'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-head:  'Poppins', var(--font-body);
  --max-width:  1200px;
}

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  color: var(--slate-800);
  background: var(--white);
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--green-600); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--green-700); }
ul, ol { list-style: none; }
button, input, textarea, select { font: inherit; }

/* --- Typography --- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-head);
  font-weight: 700;
  line-height: 1.25;
  color: var(--slate-900);
}
h1 { font-size: clamp(2rem, 5vw, 3.25rem); }
h2 { font-size: clamp(1.6rem, 4vw, 2.5rem); }
h3 { font-size: clamp(1.25rem, 3vw, 1.75rem); }
h4 { font-size: 1.25rem; }
p { margin-bottom: 1rem; }
.section-label {
  display: inline-block;
  font-size: .8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--green-600);
  margin-bottom: .5rem;
}
.section-title { margin-bottom: 1rem; }
.section-subtitle {
  font-size: 1.1rem;
  color: var(--slate-600);
  max-width: 640px;
}

/* --- Layout --- */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.25rem;
}
section { padding: 5rem 0; }
.text-center { text-align: center; }
.text-center .section-subtitle { margin-left: auto; margin-right: auto; }

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .85rem 2rem;
  font-weight: 600;
  font-size: .95rem;
  border-radius: var(--radius-sm);
  border: 2px solid transparent;
  cursor: pointer;
  transition: all var(--transition);
  text-align: center;
  line-height: 1.3;
}
.btn-primary {
  background: var(--green-600);
  color: var(--white);
  border-color: var(--green-600);
}
.btn-primary:hover {
  background: var(--green-700);
  border-color: var(--green-700);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}
.btn-secondary {
  background: transparent;
  color: var(--white);
  border-color: var(--white);
}
.btn-secondary:hover {
  background: var(--white);
  color: var(--green-700);
  transform: translateY(-2px);
}
.btn-outline {
  background: transparent;
  color: var(--green-600);
  border-color: var(--green-600);
}
.btn-outline:hover {
  background: var(--green-600);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}
.btn-gold {
  background: var(--gold-500);
  color: var(--green-900);
  border-color: var(--gold-500);
  font-weight: 700;
}
.btn-gold:hover {
  background: var(--gold-400);
  border-color: var(--gold-400);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* ========== NAVIGATION ========== */
.site-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  background: rgba(255,255,255,.97);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--slate-200);
  transition: box-shadow var(--transition);
}
.site-nav.scrolled { box-shadow: var(--shadow-md); }
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.25rem;
}
.nav-logo {
  display: flex;
  align-items: center;
  gap: .6rem;
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 1.35rem;
  color: var(--green-700);
}
.nav-logo .logo-icon {
  width: 38px; height: 38px;
  background: var(--green-600);
  border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  color: var(--white);
  font-size: 1.1rem;
  font-weight: 900;
}
.nav-links { display: flex; align-items: center; gap: .25rem; }
.nav-links a {
  padding: .5rem .85rem;
  font-size: .9rem;
  font-weight: 500;
  color: var(--slate-700);
  border-radius: var(--radius-sm);
  transition: all var(--transition);
}
.nav-links a:hover,
.nav-links a.active {
  color: var(--green-600);
  background: var(--green-50);
}

/* Dropdown */
.nav-dropdown { position: relative; }
.nav-dropdown > a::after {
  content: '';
  display: inline-block;
  width: 0; height: 0;
  margin-left: 5px;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 5px solid currentColor;
  vertical-align: middle;
  transition: transform var(--transition);
}
.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 230px;
  background: var(--white);
  border: 1px solid var(--slate-200);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  padding: .5rem;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: all var(--transition);
  z-index: 100;
}
.nav-dropdown:hover .dropdown-menu,
.nav-dropdown.open .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.dropdown-menu a {
  display: block;
  padding: .55rem .85rem;
  font-size: .88rem;
  border-radius: var(--radius-sm);
  color: var(--slate-700);
}
.dropdown-menu a:hover {
  background: var(--green-50);
  color: var(--green-600);
}
.nav-cta {
  display: flex;
  align-items: center;
  gap: .75rem;
}
.nav-phone {
  font-weight: 700;
  font-size: .95rem;
  color: var(--green-700);
}
.nav-phone:hover { color: var(--green-600); }

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: .5rem;
}
.hamburger span {
  display: block;
  width: 24px;
  height: 2.5px;
  background: var(--slate-700);
  border-radius: 2px;
  transition: all var(--transition);
}
.hamburger.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.hamburger.active span:nth-child(2) { opacity: 0; }
.hamburger.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* ========== HERO ========== */
.hero {
  position: relative;
  min-height: 600px;
  display: flex;
  align-items: center;
  padding: 8rem 0 5rem;
  background: linear-gradient(135deg, var(--green-900) 0%, var(--green-700) 50%, var(--green-600) 100%);
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 80%, rgba(255,255,255,.05) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(200,169,78,.1) 0%, transparent 50%);
}
.hero-content {
  position: relative;
  z-index: 2;
  max-width: 700px;
}
.hero h1 {
  color: var(--white);
  margin-bottom: .75rem;
  font-size: clamp(2.25rem, 5.5vw, 3.5rem);
}
.hero h1 .tagline {
  display: block;
  color: var(--gold-400);
  font-size: .55em;
  font-weight: 600;
  margin-top: .35rem;
}
.hero p {
  color: var(--green-200);
  font-size: 1.15rem;
  margin-bottom: 2rem;
  max-width: 540px;
}
.hero-buttons { display: flex; flex-wrap: wrap; gap: 1rem; }

/* Page-level hero (shorter) */
.page-hero {
  padding: 7rem 0 3.5rem;
  min-height: auto;
}
.page-hero .breadcrumb {
  color: var(--green-300);
  font-size: .85rem;
  margin-bottom: .75rem;
}
.page-hero .breadcrumb a { color: var(--green-200); }
.page-hero .breadcrumb a:hover { color: var(--white); }

/* ========== CARDS ========== */
.card-grid {
  display: grid;
  gap: 1.75rem;
}
.card-grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
.card-grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.card-grid.cols-4 { grid-template-columns: repeat(4, 1fr); }
.card {
  background: var(--white);
  border: 1px solid var(--slate-200);
  border-radius: var(--radius-md);
  padding: 2rem;
  transition: all var(--transition);
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--green-300);
}
.card-icon {
  width: 52px; height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-md);
  background: var(--green-100);
  color: var(--green-600);
  font-size: 1.5rem;
  margin-bottom: 1.25rem;
}
.card h3 { margin-bottom: .5rem; }
.card p { color: var(--slate-600); font-size: .95rem; margin-bottom: 1rem; }
.card-link {
  font-weight: 600;
  font-size: .9rem;
  color: var(--green-600);
  display: inline-flex;
  align-items: center;
  gap: .35rem;
}
.card-link:hover { gap: .6rem; }

/* ========== FEATURES / WHY US ========== */
.features-section { background: var(--green-50); }
.feature-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.5rem;
  margin-top: 3rem;
}
.feature-item { text-align: center; }
.feature-item .icon-circle {
  width: 64px; height: 64px;
  margin: 0 auto 1.25rem;
  background: var(--green-600);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-size: 1.6rem;
}
.feature-item h4 { margin-bottom: .5rem; }
.feature-item p { color: var(--slate-600); font-size: .93rem; }

/* ========== SERVICE AREAS BAR ========== */
.areas-bar {
  background: var(--green-800);
  padding: 3rem 0;
  text-align: center;
}
.areas-bar h2 { color: var(--white); margin-bottom: .5rem; }
.areas-bar p { color: var(--green-200); margin-bottom: 1.5rem; }
.areas-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: .75rem;
}
.areas-list a {
  display: inline-block;
  padding: .5rem 1.25rem;
  background: rgba(255,255,255,.1);
  border: 1px solid rgba(255,255,255,.15);
  border-radius: var(--radius-xl);
  color: var(--white);
  font-size: .9rem;
  font-weight: 500;
  transition: all var(--transition);
}
.areas-list a:hover {
  background: var(--gold-500);
  color: var(--green-900);
  border-color: var(--gold-500);
}

/* ========== CTA BANNER ========== */
.cta-banner {
  background: linear-gradient(135deg, var(--green-700) 0%, var(--green-600) 100%);
  padding: 4rem 0;
  text-align: center;
}
.cta-banner h2 { color: var(--white); margin-bottom: .75rem; }
.cta-banner p { color: var(--green-200); margin-bottom: 2rem; font-size: 1.1rem; }
.cta-buttons { display: flex; justify-content: center; gap: 1rem; flex-wrap: wrap; }

/* ========== TESTIMONIALS ========== */
.testimonials-section { background: var(--slate-100); }
.testimonial-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.75rem;
  margin-top: 2.5rem;
}
.testimonial-card {
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 2rem;
  box-shadow: var(--shadow-sm);
}
.testimonial-stars { color: var(--gold-500); font-size: 1.1rem; margin-bottom: .75rem; }
.testimonial-card blockquote {
  font-size: .95rem;
  color: var(--slate-600);
  line-height: 1.65;
  margin-bottom: 1rem;
}
.testimonial-author {
  font-weight: 600;
  font-size: .85rem;
  color: var(--slate-800);
}
.testimonial-location {
  font-size: .8rem;
  color: var(--slate-500);
}

/* ========== ABOUT PAGE ========== */
.about-story {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}
.about-story-img {
  aspect-ratio: 4/3;
  background: linear-gradient(135deg, var(--green-200) 0%, var(--green-100) 100%);
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 4rem;
}
.about-values {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin-top: 3rem;
}
.value-card {
  text-align: center;
  padding: 2rem 1.5rem;
  background: var(--white);
  border-radius: var(--radius-md);
  border: 1px solid var(--slate-200);
}
.value-card .value-icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}
.value-card h4 { margin-bottom: .5rem; }
.value-card p { font-size: .9rem; color: var(--slate-600); }

/* ========== CONTACT PAGE ========== */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
}
.contact-info-card {
  display: flex;
  gap: 1rem;
  padding: 1.25rem;
  background: var(--green-50);
  border-radius: var(--radius-md);
  margin-bottom: 1rem;
}
.contact-info-card .ci-icon {
  width: 44px; height: 44px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--green-600);
  color: var(--white);
  border-radius: var(--radius-sm);
  font-size: 1.1rem;
}
.contact-info-card h4 { font-size: .95rem; margin-bottom: .15rem; }
.contact-info-card p { font-size: .9rem; color: var(--slate-600); margin: 0; }
.contact-info-card a { color: var(--green-600); font-weight: 600; }

/* Form */
.form-group { margin-bottom: 1.25rem; }
.form-group label {
  display: block;
  font-weight: 600;
  font-size: .9rem;
  margin-bottom: .35rem;
  color: var(--slate-700);
}
.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: .75rem 1rem;
  border: 1.5px solid var(--slate-300);
  border-radius: var(--radius-sm);
  font-size: .95rem;
  background: var(--white);
  transition: border-color var(--transition), box-shadow var(--transition);
}
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--green-500);
  box-shadow: 0 0 0 3px rgba(45,157,100,.15);
}
.form-group textarea { min-height: 130px; resize: vertical; }
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
.form-status {
  padding: 1rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: .9rem;
  margin-top: 1rem;
  display: none;
}
.form-status.success {
  display: block;
  background: var(--green-100);
  color: var(--green-700);
  border: 1px solid var(--green-300);
}
.form-status.error {
  display: block;
  background: #fef2f2;
  color: #b91c1c;
  border: 1px solid #fecaca;
}

/* ========== SERVICE PAGE ========== */
.service-content {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 3.5rem;
}
.service-main h2 { margin-top: 2.5rem; margin-bottom: 1rem; }
.service-main ul {
  list-style: none;
  padding: 0;
  margin-bottom: 1.5rem;
}
.service-main ul li {
  position: relative;
  padding: .4rem 0 .4rem 1.75rem;
  color: var(--slate-600);
}
.service-main ul li::before {
  content: "\2713";
  position: absolute;
  left: 0;
  color: var(--green-600);
  font-weight: 700;
}
.service-sidebar .sidebar-card {
  background: var(--green-50);
  border: 1px solid var(--green-200);
  border-radius: var(--radius-md);
  padding: 1.75rem;
  margin-bottom: 1.5rem;
}
.sidebar-card h4 { margin-bottom: 1rem; }
.sidebar-card ul { list-style: none; }
.sidebar-card ul li { padding: .4rem 0; }
.sidebar-card ul li a {
  color: var(--slate-700);
  font-size: .9rem;
  font-weight: 500;
}
.sidebar-card ul li a:hover { color: var(--green-600); }
.sidebar-card ul li.active a {
  color: var(--green-600);
  font-weight: 700;
}

/* ========== AREA PAGE ========== */
.area-services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 2rem;
}
.area-service-card {
  background: var(--white);
  border: 1px solid var(--slate-200);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  text-align: center;
  transition: all var(--transition);
}
.area-service-card:hover {
  border-color: var(--green-300);
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}
.area-service-card .asc-icon {
  font-size: 2rem;
  margin-bottom: .75rem;
}
.area-service-card h4 { font-size: 1rem; margin-bottom: .35rem; }
.area-service-card p { font-size: .85rem; color: var(--slate-500); margin: 0; }

/* ========== FOOTER ========== */
.site-footer {
  background: var(--green-900);
  color: var(--green-200);
  padding: 4rem 0 0;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 2.5rem;
}
.footer-brand p { font-size: .9rem; line-height: 1.7; margin-top: .75rem; }
.footer-col h4 {
  color: var(--white);
  font-size: .95rem;
  font-weight: 700;
  margin-bottom: 1rem;
  text-transform: uppercase;
  letter-spacing: .06em;
}
.footer-col ul li { padding: .3rem 0; }
.footer-col ul li a {
  color: var(--green-200);
  font-size: .9rem;
  transition: color var(--transition);
}
.footer-col ul li a:hover { color: var(--gold-400); }
.footer-bottom {
  margin-top: 3rem;
  padding: 1.5rem 0;
  border-top: 1px solid rgba(255,255,255,.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: .85rem;
  flex-wrap: wrap;
  gap: 1rem;
}
.footer-bottom a { color: var(--green-300); }
.footer-bottom a:hover { color: var(--gold-400); }

/* ========== RESPONSIVE ========== */
@media (max-width: 1024px) {
  .card-grid.cols-4 { grid-template-columns: repeat(2, 1fr); }
  .feature-list { grid-template-columns: repeat(2, 1fr); }
  .testimonial-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  /* Nav */
  .nav-links {
    position: fixed;
    top: 72px; left: 0; right: 0;
    bottom: 0;
    background: var(--white);
    flex-direction: column;
    align-items: stretch;
    padding: 1.5rem;
    gap: 0;
    transform: translateX(100%);
    transition: transform var(--transition);
    overflow-y: auto;
  }
  .nav-links.open { transform: translateX(0); }
  .nav-links a { padding: .75rem 1rem; font-size: 1rem; }
  .dropdown-menu {
    position: static;
    box-shadow: none;
    border: none;
    opacity: 1;
    visibility: visible;
    transform: none;
    padding: 0 0 0 1rem;
    display: none;
  }
  .nav-dropdown.open .dropdown-menu { display: block; }
  .hamburger { display: flex; }
  .nav-cta .btn { display: none; }

  /* Layout */
  .hero { min-height: auto; padding: 6.5rem 0 3.5rem; }
  section { padding: 3.5rem 0; }
  .card-grid.cols-2,
  .card-grid.cols-3,
  .card-grid.cols-4 { grid-template-columns: 1fr; }
  .feature-list,
  .testimonial-grid,
  .about-values,
  .area-services-grid { grid-template-columns: 1fr; }
  .about-story { grid-template-columns: 1fr; gap: 2rem; }
  .contact-grid { grid-template-columns: 1fr; }
  .service-content { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; text-align: center; }
}

@media (max-width: 480px) {
  .hero-buttons { flex-direction: column; }
  .hero-buttons .btn { width: 100%; justify-content: center; }
}
