/* ============================================================
   Willow Grove Design System — shared across every page
   Light "Garden" theme: white surfaces with a green brand ramp.
   body.light is kept as an alias so existing markup keeps working.
============================================================ */

:root {
  --bg:        #f5faf7;
  --bg-2:      #ffffff;
  --surface:   #ffffff;
  --surface-2: #f2f8f4;
  --surface-3: #e7f2eb;
  --border:    #dfeae3;
  --border-2:  #c7ddd0;
  --text:      #10241a;
  --text-dim:  #4b6357;
  --text-dim2: #7b9488;
  /* Brand ramp (names kept for backwards compatibility) */
  --indigo:    #16a34a;  /* brand green */
  --indigo-2:  #15803d;  /* deeper green — text on white */
  --purple:    #0d9488;  /* teal accent */
  --violet:    #047857;  /* emerald — gradient end */
  --green:     #16a34a;  /* success */
  --amber:     #d97706;
  --red:       #dc2626;
  --glow:      0 14px 44px rgba(22, 163, 74, 0.16);
  --radius:    16px;
  --radius-sm: 10px;
  --max:       1140px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Inter, sans-serif;
}

/* Alias — the whole app is light now; kept so body.light markup still works */
body.light {
  --bg:        #f5faf7;
  --bg-2:      #ffffff;
  --surface:   #ffffff;
  --surface-2: #f2f8f4;
  --surface-3: #e7f2eb;
  --border:    #dfeae3;
  --border-2:  #c7ddd0;
  --text:      #10241a;
  --text-dim:  #4b6357;
  --text-dim2: #7b9488;
  --glow:      0 10px 40px rgba(22, 163, 74, 0.14);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
a { text-decoration: none; color: inherit; }
.container { max-width: var(--max); margin: 0 auto; padding: 0 24px; }

/* Ambient background wash */
body::before {
  content: "";
  position: fixed;
  top: -20%; left: 50%;
  width: 900px; height: 900px;
  transform: translateX(-50%);
  background: radial-gradient(circle, rgba(22,163,74,0.10) 0%, transparent 60%);
  pointer-events: none;
  z-index: 0;
}

/* Cursor glow — soft spotlight that follows the mouse (desktop only) */
#cursor-glow {
  position: fixed;
  width: 480px; height: 480px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(22,163,74,0.10) 0%, rgba(13,148,136,0.05) 40%, transparent 70%);
  pointer-events: none;
  z-index: 0;
  transform: translate(-50%, -50%);
  transition: opacity .4s;
  opacity: 0;
}
body.light #cursor-glow {
  background: radial-gradient(circle, rgba(22,163,74,0.09) 0%, transparent 70%);
}
@media (hover: none), (max-width: 760px) { #cursor-glow { display: none; } }

/* Custom scrollbar */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(22,163,74,0.35); border-radius: 100px; }
::-webkit-scrollbar-thumb:hover { background: rgba(22,163,74,0.6); }

/* Selection */
::selection { background: rgba(22,163,74,0.22); color: inherit; }
body.light ::selection { background: rgba(22,163,74,0.22); color: inherit; }

/* ============================================================
   NAV (public pages)
============================================================ */
.site-nav {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 16px 24px;
  background: rgba(255,255,255,0.72);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s, background .3s;
}
.site-nav.scrolled { border-bottom-color: var(--border); background: rgba(255,255,255,0.94); box-shadow: 0 2px 18px rgba(16,36,26,0.05); }
.nav-inner {
  max-width: var(--max); margin: 0 auto; width: 100%;
  display: flex; align-items: center; justify-content: space-between;
}
.brand {
  font-size: 1.25rem; font-weight: 800; letter-spacing: -0.02em;
  display: flex; align-items: center; gap: 8px;
}
.brand .dot { color: var(--indigo-2); }
.nav-links { display: flex; align-items: center; gap: 28px; }
.nav-links a.link { color: var(--text-dim); font-size: 0.9rem; font-weight: 500; transition: color .2s; }
.nav-links a.link:hover { color: var(--text); }
@media (max-width: 760px) { .nav-links .link { display: none; } }

/* ============================================================
   BUTTONS
============================================================ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--font);
  font-weight: 600; font-size: 0.9rem;
  padding: 10px 18px; border-radius: var(--radius-sm);
  cursor: pointer; border: none;
  transition: transform .15s, box-shadow .2s, background .2s, border-color .2s, opacity .2s;
  position: relative; overflow: hidden;
}
.btn-primary {
  background: linear-gradient(135deg, var(--indigo) 0%, var(--violet) 100%);
  color: #fff;
  box-shadow: 0 4px 20px rgba(22,163,74,0.30);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 30px rgba(4,120,87,0.40); }
.btn-primary:active { transform: translateY(0); }
.btn-ghost { background: var(--surface); color: var(--text); border: 1px solid var(--border-2); }
.btn-ghost:hover { background: var(--surface-2); border-color: var(--indigo); }
.btn-danger { background: rgba(220,38,38,0.10); color: #b91c1c; border: 1px solid rgba(220,38,38,0.28); }
.btn-danger:hover { background: rgba(220,38,38,0.18); }
body.light .btn-danger { color: #b91c1c; }
.btn-lg { padding: 14px 26px; font-size: 1rem; border-radius: 12px; }
.btn-sm { padding: 5px 12px; font-size: 0.8rem; border-radius: 8px; }
.btn-block { width: 100%; }

/* Ripple shine sweep on primary buttons */
.btn-primary::after {
  content: "";
  position: absolute; top: 0; left: -80%;
  width: 50%; height: 100%;
  background: linear-gradient(100deg, transparent, rgba(255,255,255,0.25), transparent);
  transform: skewX(-20deg);
  transition: left .5s ease;
}
.btn-primary:hover::after { left: 130%; }

/* ============================================================
   CARDS & SURFACES
============================================================ */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: border-color .25s, transform .25s, box-shadow .25s;
}
.card { box-shadow: 0 2px 16px rgba(16,36,26,0.05); backdrop-filter: none; }
body.light .card { background: var(--surface); box-shadow: 0 2px 16px rgba(16,36,26,0.05); backdrop-filter: none; }
.card-hover:hover { border-color: var(--border-2); transform: translateY(-3px); box-shadow: var(--glow); }
.card-pad { padding: 28px; }

.auth-card {
  width: 100%; max-width: 420px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 40px 36px;
  backdrop-filter: none;
  box-shadow: 0 20px 60px rgba(16,36,26,0.10);
  position: relative; z-index: 1;
}
.auth-card h1 { font-size: 1.5rem; font-weight: 800; letter-spacing: -0.02em; margin-bottom: 6px; }
.auth-card .sub { color: var(--text-dim); font-size: 0.9rem; margin-bottom: 28px; }
.auth-wrap {
  min-height: 100vh;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  padding: 90px 20px 40px;
  position: relative; z-index: 1;
}
.auth-brand { margin-bottom: 26px; font-size: 1.5rem; }

/* ============================================================
   FORMS
============================================================ */
.form-group { margin-bottom: 18px; }
.form-group label {
  display: block; font-size: 0.8rem; font-weight: 600;
  color: var(--text-dim); margin-bottom: 7px;
  text-transform: uppercase; letter-spacing: 0.05em;
}
.input,
input[type=text].input, input[type=password].input, input[type=email].input,
input[type=tel].input, input[type=date].input, input[type=time].input,
select.input, textarea.input {
  width: 100%;
  padding: 11px 14px;
  background: var(--surface-2);
  border: 1px solid var(--border-2);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font);
  font-size: 0.95rem;
  transition: border-color .2s, box-shadow .2s, background .2s;
}
.input::placeholder { color: var(--text-dim2); }
.input:focus {
  outline: none;
  border-color: var(--indigo);
  box-shadow: 0 0 0 3px rgba(22,163,74,0.18);
  background: #ffffff;
}
select.input option { background: var(--bg-2); color: var(--text); }
textarea.input { resize: vertical; min-height: 90px; }
.field-hint { font-size: 0.78rem; color: var(--text-dim2); margin-top: 5px; }

/* ============================================================
   BADGES / BANNERS / FLASH
============================================================ */
.badge {
  display: inline-block; padding: 3px 10px; border-radius: 999px;
  font-size: 0.75rem; font-weight: 700; letter-spacing: 0.02em;
}
.badge-green  { background: rgba(22,163,74,0.12);  color: #15803d; border: 1px solid rgba(22,163,74,0.28); }
.badge-red    { background: rgba(220,38,38,0.10);  color: #b91c1c; border: 1px solid rgba(220,38,38,0.26); }
.badge-yellow { background: rgba(217,119,6,0.12);  color: #a16207; border: 1px solid rgba(217,119,6,0.28); }
.badge-gray   { background: var(--surface-2);      color: var(--text-dim); border: 1px solid var(--border-2); }
.badge-indigo { background: rgba(13,148,136,0.12); color: #0f766e; border: 1px solid rgba(13,148,136,0.28); }
body.light .badge-green  { color: #15803d; }
body.light .badge-red    { color: #b91c1c; }
body.light .badge-yellow { color: #a16207; }

.flash {
  padding: 12px 16px; border-radius: var(--radius-sm); margin-bottom: 20px;
  font-size: 0.875rem; font-weight: 500;
  animation: fadeSlideDown .35s ease both;
}
.flash.success { background: rgba(22,163,74,0.10); color: #15803d; border: 1px solid rgba(22,163,74,0.28); }
.flash.error   { background: rgba(220,38,38,0.09); color: #b91c1c; border: 1px solid rgba(220,38,38,0.26); }
body.light .flash.success { color: #15803d; }
body.light .flash.error   { color: #b91c1c; }

/* ============================================================
   TABLES
============================================================ */
.table-wrap { overflow-x: auto; }
table.data {
  width: 100%; border-collapse: collapse; font-size: 0.875rem;
}
table.data th {
  padding: 13px 16px; text-align: left;
  font-weight: 600; font-size: 0.75rem;
  color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.06em;
  border-bottom: 1px solid var(--border-2);
  background: var(--surface-2);
}
table.data td { padding: 13px 16px; border-bottom: 1px solid var(--border); color: var(--text); }
table.data tr:last-child td { border-bottom: none; }
table.data tbody tr { transition: background .15s; }
table.data tbody tr:hover td { background: var(--surface-2); }

/* ============================================================
   TYPOGRAPHY HELPERS
============================================================ */
.grad-text {
  background: linear-gradient(120deg, var(--indigo) 0%, var(--purple) 60%, #0f766e 100%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.page-title { font-size: clamp(1.8rem, 4vw, 2.6rem); font-weight: 850; letter-spacing: -0.03em; line-height: 1.1; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 0.8rem; font-weight: 600; color: var(--indigo-2);
  background: rgba(22,163,74,0.10); border: 1px solid rgba(22,163,74,0.25);
  padding: 6px 14px; border-radius: 100px;
}
.eyebrow .pulse {
  width: 7px; height: 7px; border-radius: 50%; background: var(--green);
  box-shadow: 0 0 0 0 rgba(22,163,74,0.6); animation: pulse 2s infinite;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(22,163,74,.6); }
  70% { box-shadow: 0 0 0 8px rgba(22,163,74,0); }
  100% { box-shadow: 0 0 0 0 rgba(22,163,74,0); }
}

/* ============================================================
   MOTION — reveal on scroll + entrances
============================================================ */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }
.reveal-d1 { transition-delay: .08s; }
.reveal-d2 { transition-delay: .16s; }
.reveal-d3 { transition-delay: .24s; }

@keyframes fadeSlideDown { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: none; } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
.anim-in { animation: fadeUp .5s ease both; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
  .reveal { opacity: 1; transform: none; }
}

/* ============================================================
   PROSE (legal / long-form pages)
============================================================ */
.prose { max-width: 780px; margin: 0 auto; }
.prose h1 { font-size: 2rem; font-weight: 800; letter-spacing: -0.02em; margin-bottom: 10px; }
.prose h2 { font-size: 1.25rem; font-weight: 700; margin: 34px 0 12px; color: var(--text); }
.prose p, .prose li { color: var(--text-dim); font-size: 0.95rem; }
.prose ul { padding-left: 22px; margin: 10px 0; }
.prose li { margin-bottom: 6px; }
.prose .meta { color: var(--text-dim2); font-size: 0.85rem; margin-bottom: 30px; }
.prose a { color: var(--indigo-2); }
.prose a:hover { text-decoration: underline; }
.prose strong { color: var(--text); }

/* ============================================================
   FOOTER (public pages)
============================================================ */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 34px 24px;
  margin-top: 80px;
  position: relative; z-index: 1;
}
.site-footer .inner {
  max-width: var(--max); margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 14px;
  color: var(--text-dim2); font-size: 0.85rem;
}
.site-footer a { color: var(--text-dim); transition: color .2s; }
.site-footer a:hover { color: var(--text); }
.site-footer .links { display: flex; gap: 20px; }

/* Honeypot field for the contact form. Hidden from sight, from screen readers
   (aria-hidden in the markup) and from keyboard nav (tabindex="-1"). Uses
   absolute positioning rather than display:none because some bots skip
   display:none inputs — the point is that a bot CAN see and fill it. */
.hp-field {
  position: absolute !important;
  left: -9999px !important;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
