/* ===========================
   CVMA – Cora van der Merwe Attorneys
   Style Sheet
   Aesthetic: Warm Legal Elegance — Slate blue, antique gold, warm white
=========================== */

:root {
  --navy: #2c3e5a;
  --navy-mid: #3a5272;
  --navy-light: #4e6a8a;
  --gold: #b8952a;
  --gold-light: #d4af5a;
  --gold-pale: #f0e4c2;
  --cream: #faf7f2;
  --cream-dark: #f0ead9;
  --warm-white: #fffdf9;
  --white: #ffffff;
  --text: #2a2a3a;
  --text-light: #5a5a7a;
  --font-display: 'Cormorant Garamond', Georgia, serif;
  --font-body: 'Montserrat', sans-serif;
  --transition: 0.3s ease;
  --shadow: 0 8px 40px rgba(44,62,90,0.10);
  --shadow-heavy: 0 20px 60px rgba(44,62,90,0.18);
  --radius: 2px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.8;
  color: var(--text);
  background: var(--warm-white);
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }

/* ===========================
   UTILITY
=========================== */
.container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 2rem;
}
.section { padding: 100px 0; }

.section-label {
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1rem;
}
.section-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 300;
  line-height: 1.2;
  color: var(--navy);
  margin-bottom: 1.5rem;
}
.section-intro {
  max-width: 640px;
  color: var(--text-light);
  margin-bottom: 3rem;
  font-weight: 300;
}
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: center;
}
.btn {
  display: inline-block;
  padding: 0.85rem 2.2rem;
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  cursor: pointer;
  border: none;
  transition: var(--transition);
  border-radius: var(--radius);
}
.btn-primary { background: var(--gold); color: var(--white); }
.btn-primary:hover {
  background: var(--gold-light);
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(184,149,42,0.30);
}
.btn-ghost {
  background: transparent;
  color: var(--white);
  border: 1px solid rgba(255,255,255,0.55);
}
.btn-ghost:hover { border-color: var(--gold-light); color: var(--gold-light); }

/* ===========================
   NAV
=========================== */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 1.2rem 0;
  transition: background 0.4s ease, box-shadow 0.4s ease;
}
.nav.scrolled {
  background: var(--navy);
  box-shadow: 0 2px 30px rgba(44,62,90,0.25);
  padding: 0.8rem 0;
}
.nav-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.logo { display: flex; flex-direction: column; line-height: 1; }
.logo-main {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 600;
  color: var(--white);
  letter-spacing: 0.1em;
}
.logo-sub {
  font-size: 8px;
  font-weight: 400;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-light);
  margin-top: 2px;
}
.nav-links {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 2.5rem;
}
.nav-links a {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.85);
  transition: var(--transition);
}
.nav-links a:hover { color: var(--gold-light); }
.nav-cta {
  background: var(--gold) !important;
  color: var(--white) !important;
  padding: 0.6rem 1.4rem;
  border-radius: var(--radius);
}
.nav-cta:hover { background: var(--gold-light) !important; }
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.hamburger span { display: block; width: 24px; height: 2px; background: var(--white); transition: var(--transition); }

/* ===========================
   HERO
=========================== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  inset: 0;
  background-image: url('https://images.unsplash.com/photo-1505664194779-8beaceb93744?w=1800&q=80');
  background-size: cover;
  background-position: center 30%;
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    105deg,
    rgba(44,62,90,0.82) 0%,
    rgba(44,62,90,0.60) 60%,
    rgba(44,62,90,0.30) 100%
  );
}
.hero-bg::after {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 5px;
  height: 100%;
  background: linear-gradient(180deg, var(--gold), transparent 80%);
}
.hero-content {
  position: relative;
  z-index: 2;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 2rem;
  padding-top: 80px;
  animation: fadeUp 1s ease both;
}
.hero-eyebrow {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--gold-light);
  margin-bottom: 1.5rem;
}
.hero-title {
  font-family: var(--font-display);
  font-size: clamp(3.5rem, 8vw, 7rem);
  font-weight: 300;
  line-height: 1;
  color: var(--white);
  margin-bottom: 1.8rem;
}
.hero-title em { font-style: italic; color: var(--gold-light); }
.hero-sub {
  max-width: 520px;
  color: rgba(255,255,255,0.80);
  font-weight: 300;
  font-size: 0.95rem;
  margin-bottom: 2.5rem;
  line-height: 1.9;
}
.hero-actions { display: flex; gap: 1.2rem; flex-wrap: wrap; }
.hero-scroll {
  position: absolute;
  bottom: 2.5rem; right: 3rem;
  display: flex; flex-direction: column;
  align-items: center; gap: 0.6rem; z-index: 2;
}
.hero-scroll span {
  font-size: 9px; letter-spacing: 0.2em; text-transform: uppercase;
  color: rgba(255,255,255,0.45); writing-mode: vertical-rl;
}
.scroll-line {
  width: 1px; height: 60px;
  background: linear-gradient(180deg, var(--gold), transparent);
  animation: scrollPulse 2s ease infinite;
}

/* ===========================
   STATS BAND
=========================== */
.stats-band {
  background: var(--cream);
  padding: 3rem 2rem;
  display: flex; align-items: center;
  justify-content: center; gap: 0; flex-wrap: wrap;
  border-bottom: 1px solid var(--cream-dark);
}
.stat { display: flex; flex-direction: column; align-items: center; padding: 1rem 3rem; text-align: center; }
.stat-num {
  font-family: var(--font-display);
  font-size: 1.8rem; font-weight: 600;
  color: var(--navy); line-height: 1; margin-bottom: 0.3rem;
}
.stat-label {
  font-size: 10px; font-weight: 500; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--gold);
}
.stat-divider { width: 1px; height: 48px; background: var(--cream-dark); flex-shrink: 0; }

/* ===========================
   ABOUT — subtle photo wash
=========================== */
.about {
  position: relative;
  overflow: hidden;
  background: var(--warm-white);
}
.about-bg-photo {
  position: absolute;
  inset: 0;
  background-image: url('https://images.unsplash.com/photo-1453945619913-79ec89a82c51?w=1600&q=80');
  background-size: cover;
  background-position: center;
  opacity: 0.05;
}
.about .container { position: relative; z-index: 1; }
.about-text p { color: var(--text-light); font-weight: 300; margin-bottom: 1.2rem; line-height: 1.9; }
.about-text .btn { margin-top: 1rem; }

.about-quote-block {
  background: var(--navy);
  padding: 3.5rem;
  position: relative;
  border-left: 4px solid var(--gold);
  box-shadow: var(--shadow-heavy);
}
.about-quote-block::before {
  content: '"';
  font-family: var(--font-display);
  font-size: 8rem; color: var(--gold); opacity: 0.18;
  position: absolute; top: -1rem; left: 2rem; line-height: 1;
}
blockquote {
  font-family: var(--font-display);
  font-size: 1.3rem; font-style: italic; font-weight: 300;
  line-height: 1.7; color: var(--white); margin-bottom: 1.5rem;
}
cite { font-size: 11px; letter-spacing: 0.15em; text-transform: uppercase; color: var(--gold-light); font-style: normal; }

/* ===========================
   PRACTICE AREAS
=========================== */
.practice { background: var(--cream); }
.practice-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.practice-card {
  background: var(--warm-white);
  padding: 2.5rem 2rem;
  border-top: 3px solid transparent;
  transition: var(--transition);
  box-shadow: 0 2px 14px rgba(44,62,90,0.06);
}
.practice-card:hover {
  border-top-color: var(--gold);
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}
.card-num {
  font-family: var(--font-display);
  font-size: 2.5rem; font-weight: 600;
  color: var(--cream-dark); line-height: 1; margin-bottom: 0.8rem;
}
.practice-card h3 {
  font-family: var(--font-display);
  font-size: 1.25rem; font-weight: 600;
  color: var(--navy); margin-bottom: 0.8rem; line-height: 1.3;
}
.practice-card p { font-size: 13px; color: var(--text-light); line-height: 1.8; font-weight: 300; }

.learn-more {
  display: inline-block;
  margin-top: 1rem;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--red);
  border-bottom: 1px solid transparent;
  transition: var(--transition);
}
.learn-more:hover {
  border-bottom-color: var(--gold);
  color: var(--gold-light);
}

/* ===========================
   MODAL
=========================== */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(44,62,90,0.65);
  z-index: 500;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  backdrop-filter: blur(3px);
}
.modal-overlay.active {
  display: flex;
  animation: fadeIn 0.25s ease;
}
.modal-box {
  background: var(--warm-white);
  max-width: 620px;
  width: 100%;
  padding: 3rem;
  position: relative;
  border-top: 4px solid var(--gold);
  box-shadow: var(--shadow-heavy);
  max-height: 90vh;
  overflow-y: auto;
  animation: slideUp 0.3s ease;
}
.modal-close {
  position: absolute;
  top: 1.2rem; right: 1.2rem;
  background: none;
  border: none;
  font-size: 1rem;
  color: var(--text-light);
  cursor: pointer;
  width: 32px; height: 32px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  transition: var(--transition);
}
.modal-close:hover { background: var(--cream-dark); color: var(--navy); }

.modal-photo {
  width: calc(100% + 6rem);
  margin: -3rem -3rem 2rem -3rem;
  height: 220px;
  background-size: cover;
  background-position: center;
  border-bottom: 3px solid var(--gold);
}
.modal-label {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.6rem;
}
.modal-title {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 300;
  color: var(--navy);
  margin-bottom: 1rem;
  line-height: 1.2;
}
.modal-intro {
  color: var(--text-light);
  font-weight: 300;
  margin-bottom: 1.4rem;
  line-height: 1.9;
  font-size: 14px;
}
.modal-body {
  margin-bottom: 1.8rem;
}
.modal-body p {
  font-size: 13px;
  color: var(--text-light);
  font-weight: 300;
  line-height: 1.9;
  margin-bottom: 1rem;
}
.modal-services {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 2rem;
}
.modal-services li {
  padding: 1.2rem 1.4rem;
  background: var(--cream);
  border-left: 3px solid var(--gold);
}
.modal-services li strong {
  display: block;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--navy);
  margin-bottom: 0.3rem;
  text-transform: uppercase;
}
.modal-services li span {
  font-size: 13px;
  color: var(--text-light);
  font-weight: 300;
  line-height: 1.7;
}
.modal-cta { display: inline-block; }

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes slideUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ===========================
   WHY CVMA — full photo background
=========================== */
.why { position: relative; overflow: hidden; }
.why-bg-photo {
  position: absolute; inset: 0;
  background-image: url('https://images.unsplash.com/photo-1531540782668-79a9cfa2e1ee?w=1600&q=80');
  background-size: cover;
  background-position: center 40%;
}
.why-bg-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(44,62,90,0.90) 0%, rgba(58,82,114,0.86) 100%);
}
.why .container { position: relative; z-index: 1; }
.why .section-title { color: var(--white); }
.why .section-intro { color: rgba(255,255,255,0.65); }
.why-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2rem; margin-top: 3rem; }
.why-card {
  padding: 2.5rem;
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(255,255,255,0.05);
  backdrop-filter: blur(4px);
  transition: var(--transition);
}
.why-card:hover { border-color: var(--gold); background: rgba(184,149,42,0.08); }
.why-icon { font-size: 1.8rem; margin-bottom: 1rem; }
.why-card h3 { font-family: var(--font-display); font-size: 1.3rem; font-weight: 400; color: var(--white); margin-bottom: 0.8rem; }
.why-card p { font-size: 13px; color: rgba(255,255,255,0.62); line-height: 1.9; font-weight: 300; }

/* ===========================
   CONTACT
=========================== */
.contact { background: var(--warm-white); }
.contact-cols { align-items: start; gap: 5rem; }
.contact-info p { color: var(--text-light); font-weight: 300; margin-bottom: 2rem; }
.contact-details { display: flex; flex-direction: column; gap: 1.5rem; }
.contact-item { display: flex; flex-direction: column; gap: 0.3rem; }
.ci-label { font-size: 10px; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase; color: var(--gold); }
.contact-item a, .contact-item span { color: var(--text-light); font-size: 14px; font-weight: 300; line-height: 1.6; }
.contact-item a:hover { color: var(--gold); }
.contact-form {
  background: var(--cream);
  padding: 3rem; box-shadow: var(--shadow);
  border-top: 3px solid var(--gold);
}
.form-group { display: flex; flex-direction: column; margin-bottom: 1.4rem; }
label { font-size: 10px; font-weight: 600; letter-spacing: 0.18em; text-transform: uppercase; color: var(--navy); margin-bottom: 0.5rem; }
input, select, textarea {
  border: 1px solid #e0d8cc; background: var(--white);
  padding: 0.75rem 1rem; font-family: var(--font-body);
  font-size: 13px; color: var(--text); border-radius: var(--radius);
  outline: none; transition: border-color var(--transition); width: 100%;
}
input:focus, select:focus, textarea:focus { border-color: var(--gold); }
textarea { resize: vertical; }
.full-width { width: 100%; text-align: center; margin-top: 0.5rem; }
.form-note { font-size: 11px; color: var(--text-light); text-align: center; margin-top: 1rem; font-style: italic; opacity: 0.7; }
.form-success { display: none; text-align: center; padding: 1rem; background: #d4edda; color: #155724; border-radius: var(--radius); margin-top: 1rem; font-size: 13px; }

/* ===========================
   FOOTER — photo background
=========================== */
.footer { position: relative; overflow: hidden; padding: 4rem 0 0; }
.footer-bg-photo {
  position: absolute; inset: 0;
  background-image: url('https://images.unsplash.com/photo-1479142506502-19b3a3b7ff33?w=1200&q=80');
  background-size: cover; background-position: center;
}
.footer-bg-overlay { position: absolute; inset: 0; background: rgba(44,62,90,0.93); }
.footer .container, .footer-bottom { position: relative; z-index: 1; }
.footer-inner {
  display: flex; justify-content: space-between; align-items: flex-start;
  flex-wrap: wrap; gap: 2rem; padding-bottom: 3rem;
  border-bottom: 1px solid rgba(255,255,255,0.10);
}
.footer-brand .logo-main { font-size: 1.8rem; }
.footer-brand .logo-sub { display: block; margin-top: 4px; }
.footer-tagline { margin-top: 0.8rem; font-size: 12px; color: rgba(255,255,255,0.38); font-style: italic; font-family: var(--font-display); }
.footer-links { display: flex; flex-direction: column; gap: 0.6rem; }
.footer-links a { font-size: 11px; font-weight: 500; letter-spacing: 0.15em; text-transform: uppercase; color: rgba(255,255,255,0.52); transition: var(--transition); }
.footer-links a:hover { color: var(--gold-light); }
.footer-bottom { padding: 1.5rem 2rem; text-align: center; }
.footer-bottom p { font-size: 11px; color: rgba(255,255,255,0.28); letter-spacing: 0.05em; }

/* ===========================
   ANIMATIONS
=========================== */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(30px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes scrollPulse {
  0%, 100% { opacity: 0.4; }
  50%       { opacity: 1; }
}

/* ===========================
   RESPONSIVE
=========================== */
@media (max-width: 900px) {
  .two-col { grid-template-columns: 1fr; gap: 3rem; }
  .practice-grid { grid-template-columns: repeat(2, 1fr); }
  .why-grid { grid-template-columns: 1fr; }
  .nav-links {
    display: none; position: absolute;
    top: 100%; left: 0; right: 0;
    background: var(--navy); flex-direction: column;
    padding: 1.5rem 2rem; gap: 1.2rem; box-shadow: var(--shadow);
  }
  .nav-links.open { display: flex; }
  .hamburger { display: flex; }
  .hero-scroll { display: none; }
  .contact-cols { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .practice-grid { grid-template-columns: 1fr; }
  .stats-band { gap: 0; }
  .stat { padding: 1rem 1.5rem; }
  .stat-divider { display: none; }
  .contact-form { padding: 2rem; }
  .about-quote-block { padding: 2.5rem 1.8rem; }
  .hero-actions { flex-direction: column; }
}

/* ===========================
   ARTICLES SECTION
=========================== */
.articles {
  background: var(--warm-white);
}

.articles-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-bottom: 2.5rem;
}

.filter-btn {
  font-family: var(--font-body);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  padding: 0.5rem 1.2rem;
  border: 1px solid var(--cream-dark);
  background: var(--cream);
  color: var(--text-light);
  cursor: pointer;
  border-radius: var(--radius);
  transition: var(--transition);
}
.filter-btn:hover {
  border-color: var(--gold);
  color: var(--navy);
}
.filter-btn.active {
  background: var(--navy);
  color: var(--white);
  border-color: var(--navy);
}

.articles-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.article-card {
  background: var(--white);
  border: 1px solid var(--cream-dark);
  border-top: 3px solid var(--gold);
  padding: 1.8rem;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}
.article-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-top-color: var(--navy);
}

.article-category {
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.7rem;
}

.article-card h3 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--navy);
  line-height: 1.3;
  margin-bottom: 0.7rem;
}

.article-excerpt {
  font-size: 12px;
  color: var(--text-light);
  line-height: 1.8;
  font-weight: 300;
  flex: 1;
  margin-bottom: 1.2rem;
}

.article-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid var(--cream-dark);
  padding-top: 0.8rem;
  margin-top: auto;
}

.article-date {
  font-size: 10px;
  color: var(--text-light);
  font-weight: 300;
}

.article-read {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold);
}

.articles-note {
  font-size: 12px;
  color: var(--text-light);
  font-style: italic;
  text-align: center;
  padding: 1rem;
  border-top: 1px solid var(--cream-dark);
  font-weight: 300;
}

/* Article Reader Overlay */
.article-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(44,62,90,0.65);
  z-index: 500;
  align-items: flex-start;
  justify-content: center;
  padding: 2rem;
  backdrop-filter: blur(3px);
  overflow-y: auto;
}
.article-overlay.active {
  display: flex;
  animation: fadeIn 0.25s ease;
}
.article-reader {
  background: var(--warm-white);
  max-width: 720px;
  width: 100%;
  padding: 3.5rem;
  position: relative;
  border-top: 4px solid var(--gold);
  box-shadow: var(--shadow-heavy);
  margin: auto;
  animation: slideUp 0.3s ease;
}
.article-reader-label {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.6rem;
}
.article-reader-title {
  font-family: var(--font-display);
  font-size: 2.2rem;
  font-weight: 300;
  color: var(--navy);
  margin-bottom: 0.8rem;
  line-height: 1.2;
}
.article-reader-meta {
  font-size: 11px;
  color: var(--text-light);
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--cream-dark);
  font-weight: 300;
}
.article-reader-body {
  font-size: 14px;
  color: var(--text-light);
  line-height: 1.95;
  font-weight: 300;
  margin-bottom: 2.5rem;
}
.article-reader-body p {
  margin-bottom: 1.2rem;
}
.article-reader-body h4 {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--navy);
  margin: 1.8rem 0 0.8rem;
}
.article-reader-footer {
  border-top: 1px solid var(--cream-dark);
  padding-top: 1.5rem;
}
.article-card.hidden { display: none; }

@media (max-width: 900px) {
  .articles-grid { grid-template-columns: repeat(2, 1fr); }
  .article-reader { padding: 2rem; }
}
@media (max-width: 600px) {
  .articles-grid { grid-template-columns: 1fr; }
  .articles-filter { gap: 0.4rem; }
}
