/* ================================================================
   ReServe Home Pros — Design System
   Shared across all pages. Single source of truth.
   ================================================================ */

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,500;0,600;0,700;1,400;1,500&family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;0,9..40,600;0,9..40,700;1,9..40,400&display=swap');

/* ── Tokens ── */
:root {
  --obsidian: #131518;
  --charcoal: #1B1E23;
  --graphite: #262A31;
  --surface: #2E323A;

  --copper: #B8642E;
  --copper-bright: #CC7A3E;
  --copper-deep: #9A5425;
  --copper-glow: rgba(184, 100, 46, 0.12);

  --cream: #F8F4EE;
  --linen: #EDE8E0;
  --warm-white: #FDFBF7;
  --white: #FFFFFF;

  --sage: #6B8C7A;
  --sage-soft: rgba(107, 140, 122, 0.12);

  --text-hero: #F0EDE6;
  --text-on-dark: #C8C3BA;
  --text-dark: #1A1A1A;
  --text-mid: #5C5C5C;
  --text-light: #8A8A8A;

  --border-dark: rgba(255,255,255,0.06);
  --border-light: rgba(0,0,0,0.08);

  --r-sm: 4px;
  --r-md: 6px;

  --shadow-subtle: 0 2px 12px rgba(0,0,0,0.04);
  --shadow-card: 0 8px 32px rgba(0,0,0,0.06);
  --shadow-elevated: 0 16px 48px rgba(0,0,0,0.10);
}

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

html { scroll-behavior: smooth; font-size: 17px; }

body {
  font-family: 'DM Sans', -apple-system, sans-serif;
  color: var(--text-dark);
  background: var(--warm-white);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

h1, h2, h3 {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-weight: 500;
  line-height: 1.15;
}

img { max-width: 100%; height: auto; display: block; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--copper); outline-offset: 3px; }

/* ── Layout ── */
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 32px; }
.wrap-narrow { max-width: 900px; margin: 0 auto; padding: 0 32px; }
.wrap-wide { max-width: 1400px; margin: 0 auto; padding: 0 32px; }

/* ── Animations ── */
.js .reveal { opacity: 0; transform: translateY(28px); transition: opacity .9s cubic-bezier(.22,1,.36,1), transform .9s cubic-bezier(.22,1,.36,1); }
.js .reveal.visible { opacity: 1; transform: translateY(0); }
.js .reveal-delay-1 { transition-delay: .12s; }
.js .reveal-delay-2 { transition-delay: .24s; }
.js .reveal-delay-3 { transition-delay: .36s; }
.js .reveal-delay-4 { transition-delay: .48s; }

/* ── Grain texture (reusable) ── */
.grain::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.04'/%3E%3C/svg%3E");
  pointer-events: none;
}

/* ================================================================
   HEADER
   ================================================================ */
.hdr {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 200;
  padding: 20px 0;
  transition: background .4s ease, padding .4s ease, box-shadow .4s ease;
}
.hdr--dark {
  /* Default: transparent on dark hero */
}
.hdr--light {
  background: var(--white);
  box-shadow: 0 1px 0 var(--border-light);
  padding: 14px 0;
}
.hdr.scrolled {
  background: rgba(19, 21, 24, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding: 14px 0;
  box-shadow: 0 1px 0 var(--border-dark);
}
.hdr--light.scrolled {
  background: rgba(255,255,255,0.97);
  box-shadow: 0 1px 0 var(--border-light);
}
.hdr .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.hdr-logo img {
  height: 38px;
  width: auto;
  border-radius: var(--r-sm);
}
.hdr-nav {
  display: flex;
  align-items: center;
  gap: 32px;
}
.hdr-link {
  color: var(--text-on-dark);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  transition: color .3s ease;
}
.hdr-link:hover { color: var(--copper); }
.hdr-link.active { color: var(--copper); }

/* Light header variant */
.hdr--light .hdr-link { color: var(--text-mid); }
.hdr--light .hdr-link:hover { color: var(--copper); }
.hdr--light .hdr-link.active { color: var(--copper-deep); }
.hdr--light .hdr-phone { color: var(--copper-deep); }

.hdr-phone {
  color: var(--copper);
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
  letter-spacing: 0.3px;
  transition: color .3s ease;
}
.hdr-phone:hover { color: var(--copper-bright); }
.hdr-phone svg { width: 16px; height: 16px; fill: currentColor; flex-shrink: 0; }

/* Mobile nav toggle */
.hdr-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}
.hdr-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-on-dark);
  margin: 5px 0;
  transition: all .3s ease;
}
.hdr--light .hdr-toggle span { background: var(--text-dark); }

/* ================================================================
   BUTTONS
   ================================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 16px 36px;
  font-family: 'DM Sans', sans-serif;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-decoration: none;
  border: none;
  cursor: pointer;
  border-radius: var(--r-sm);
  transition: all .3s cubic-bezier(.22,1,.36,1);
}
.btn-copper { background: var(--copper); color: var(--obsidian); }
.btn-copper:hover { background: var(--copper-bright); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(196,154,108,0.3); }
.btn-ghost { background: transparent; color: var(--text-on-dark); border: 1px solid rgba(255,255,255,0.15); }
.btn-ghost:hover { border-color: var(--copper); color: var(--copper); }
.btn-ghost-dark { background: transparent; color: var(--text-dark); border: 1px solid var(--border-light); }
.btn-ghost-dark:hover { border-color: var(--copper); color: var(--copper-deep); }
.btn-sm { padding: 12px 24px; font-size: 13px; }

/* ================================================================
   SECTION HELPERS
   ================================================================ */
.section-label {
  font-family: 'DM Sans', sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 3.5px;
  text-transform: uppercase;
  color: var(--copper);
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.section-label::before { content: ''; width: 32px; height: 1px; background: var(--copper); }
.section-label-center { justify-content: center; }
.section-label-center::before { display: none; }
.section-label-light { color: var(--copper); }
.section-label-dark { color: var(--copper-deep); }

.section-header { text-align: center; margin-bottom: 64px; }
.section-sub { color: var(--text-mid); margin-top: 12px; font-size: 1rem; }

/* ================================================================
   PAGE HERO (reusable across inner pages)
   ================================================================ */
.page-hero {
  position: relative;
  padding: 160px 0 80px;
  background: var(--obsidian);
  overflow: hidden;
}
.page-hero.grain { position: relative; }
.page-hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.page-hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.page-hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(19,21,24,0.7) 0%, rgba(19,21,24,0.85) 100%);
}
.page-hero .wrap { position: relative; z-index: 10; }
.page-hero h1 {
  font-size: clamp(2.4rem, 4.5vw, 3.4rem);
  font-weight: 400;
  color: var(--text-hero);
  letter-spacing: -0.3px;
  margin-bottom: 16px;
}
.page-hero h1 em { font-style: italic; color: var(--copper); }
.page-hero .page-hero-sub {
  font-size: 1.1rem;
  color: var(--text-on-dark);
  max-width: 560px;
  line-height: 1.8;
}

/* ================================================================
   TRUST BAR
   ================================================================ */
.trust-bar {
  background: var(--charcoal);
  border-top: 1px solid var(--border-dark);
  padding: 28px 0;
}
.trust-bar .wrap { display: flex; justify-content: center; gap: 56px; flex-wrap: wrap; }
.trust-item { display: flex; align-items: center; gap: 12px; }
.trust-item .num { font-family: 'Cormorant Garamond', serif; font-size: 28px; font-weight: 600; color: var(--copper); line-height: 1; }
.trust-item .label { font-size: 12px; text-transform: uppercase; letter-spacing: 1.5px; color: var(--text-on-dark); opacity: 0.6; }
.trust-divider { width: 1px; background: var(--border-dark); align-self: stretch; }

/* ================================================================
   FOOTER
   ================================================================ */
.footer {
  background: var(--obsidian);
  border-top: 1px solid var(--border-dark);
  padding: 56px 0 32px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}
.footer-brand p {
  font-size: 0.85rem;
  color: var(--text-on-dark);
  opacity: 0.5;
  line-height: 1.7;
  margin-top: 16px;
  max-width: 280px;
}
.footer-brand img { height: 40px; width: auto; border-radius: var(--r-sm); }
.footer-badges { display: flex; gap: 20px; align-items: center; margin-top: 20px; }
.footer-badges img { height: 36px; width: auto; opacity: 0.5; filter: grayscale(20%); transition: opacity .3s ease; }
.footer-badges img:hover { opacity: 0.8; }
.footer-col h4 {
  font-family: 'DM Sans', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-on-dark);
  opacity: 0.4;
  margin-bottom: 16px;
}
.footer-col a {
  display: block;
  font-size: 14px;
  color: var(--text-on-dark);
  opacity: 0.6;
  text-decoration: none;
  padding: 4px 0;
  transition: opacity .3s ease;
}
.footer-col a:hover { opacity: 1; color: var(--copper); }
.footer-bottom {
  border-top: 1px solid var(--border-dark);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.footer-bottom-left { font-size: 12px; color: var(--text-on-dark); opacity: 0.3; }
.footer-bottom-right { display: flex; gap: 24px; }
.footer-bottom-right a { font-size: 12px; color: var(--text-on-dark); opacity: 0.3; text-decoration: none; transition: opacity .3s ease; }
.footer-bottom-right a:hover { opacity: 0.7; }

/* ================================================================
   BEFORE / AFTER SLIDER
   ================================================================ */
.ba-slider { position: relative; aspect-ratio: 4/3; cursor: ew-resize; overflow: hidden; }
.ba-slider img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; user-select: none; -webkit-user-drag: none; }
.ba-slider .ba-after { clip-path: inset(0 50% 0 0); }
.ba-slider .ba-handle { position: absolute; top: 0; bottom: 0; left: 50%; width: 2px; background: var(--white); transform: translateX(-50%); z-index: 3; pointer-events: none; }
.ba-slider .ba-handle::after { content: ''; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 40px; height: 40px; background: var(--white); border-radius: 50%; box-shadow: 0 2px 12px rgba(0,0,0,0.2); }
.ba-slider .ba-handle::before { content: '\2194'; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); font-size: 18px; color: var(--charcoal); z-index: 4; pointer-events: none; }
.ba-slider .ba-label { position: absolute; bottom: 12px; padding: 4px 12px; font-size: 10px; font-weight: 600; letter-spacing: 2px; text-transform: uppercase; background: rgba(0,0,0,0.6); color: var(--white); border-radius: 2px; z-index: 2; pointer-events: none; }
.ba-slider .ba-label-before { left: 12px; }
.ba-slider .ba-label-after { right: 12px; }
.ba-slider input[type="range"] { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: ew-resize; z-index: 5; margin: 0; }

/* ================================================================
   CTA BAND (reusable dark CTA section)
   ================================================================ */
.cta-band {
  padding: 100px 0;
  background: var(--obsidian);
  text-align: center;
  position: relative;
  overflow: hidden;
}
.cta-band::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 30% 50%, rgba(196,154,108,0.06) 0%, transparent 60%),
    radial-gradient(ellipse at 70% 50%, rgba(196,154,108,0.04) 0%, transparent 60%);
  pointer-events: none;
}
.cta-band .wrap { position: relative; z-index: 1; }
.cta-band h2 { font-size: clamp(2rem, 3.5vw, 2.8rem); font-weight: 400; color: var(--text-hero); margin-bottom: 16px; }
.cta-band h2 em { font-style: italic; color: var(--copper); }
.cta-band .cta-sub { font-size: 1.05rem; color: var(--text-on-dark); opacity: 0.7; max-width: 480px; margin: 0 auto 40px; line-height: 1.8; }
.cta-band .cta-actions { display: flex; justify-content: center; gap: 16px; flex-wrap: wrap; }
.cta-band .phone-note { display: block; margin-top: 20px; font-size: 14px; color: var(--text-on-dark); opacity: 0.4; }
.cta-band .phone-note a { color: var(--copper); text-decoration: none; }

/* ================================================================
   RESPONSIVE
   ================================================================ */
@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
}

@media (max-width: 900px) {
  .hdr-nav .hdr-link { display: none; }
  .hdr-toggle { display: block; }
  .page-hero { padding: 140px 0 60px; }
}

@media (max-width: 680px) {
  html { font-size: 16px; }
  .trust-bar .wrap { gap: 24px; }
  .trust-divider { display: none; }
  .trust-item { flex-direction: column; text-align: center; gap: 4px; }
  .footer-grid { grid-template-columns: 1fr; gap: 24px; }
  .footer-bottom { flex-direction: column; gap: 12px; text-align: center; }
}
