/* ============================================================
   MERCES ADVOCACIA — styles.css
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Playfair+Display:ital,wght@0,400;0,500;0,600;0,700;1,400;1,500&display=swap');

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

:root {
  --bg:        #090e0b;
  --bg-card:   #111810;
  --fg:        #f0ece3;
  --fg-muted:  #7a9185;
  --border:    #1d2a22;
  --primary:   #14261b;
  --accent:    #c9a227;
  --accent-fg: #090e0b;
  --green-btn: #25D366;
  --font-sans: 'Inter', sans-serif;
  --font-serif:'Playfair Display', serif;
  --radius:    2px;
  --container: 1200px;
  --header-h:  80px;
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--fg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; }
a  { text-decoration: none; color: inherit; }

/* ── Utilities ───────────────────────────────────────────── */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: 24px;
}

.divider {
  height: 1px;
  background: linear-gradient(to right, transparent, var(--border), transparent);
}

.divider--gold {
  background: linear-gradient(to right, transparent, rgba(201,162,39,.3), transparent);
}

/* ── Animations ──────────────────────────────────────────── */
.fade-up {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .7s ease, transform .7s ease;
}
.fade-up.visible {
  opacity: 1;
  transform: translateY(0);
}
.stagger .fade-up:nth-child(1) { transition-delay: 0s; }
.stagger .fade-up:nth-child(2) { transition-delay: .15s; }
.stagger .fade-up:nth-child(3) { transition-delay: .30s; }
.stagger .fade-up:nth-child(4) { transition-delay: .45s; }
.stagger .fade-up:nth-child(5) { transition-delay: .60s; }
.stagger .fade-up:nth-child(6) { transition-delay: .75s; }

/* ── Header ──────────────────────────────────────────────── */
#header {
  position: fixed;
  top: 0; left: 0;
  width: 100%;
  height: var(--header-h);
  background: rgba(9,14,11,.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  z-index: 100;
  display: flex;
  align-items: center;
}
#header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
#header .logo {
  height: 48px;
  width: auto;
  object-fit: contain;
}
.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}
.instagram-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,.2);
  color: rgba(255,255,255,.7);
  transition: color .2s, border-color .2s;
  flex-shrink: 0;
}
.instagram-link:hover {
  color: #fff;
  border-color: rgba(255,255,255,.5);
}
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  border: none;
  font-family: var(--font-sans);
  font-weight: 600;
  border-radius: var(--radius);
  transition: background .2s, transform .2s;
  text-decoration: none;
}
.btn--gold {
  background: var(--accent);
  color: var(--accent-fg);
  padding: 12px 24px;
  font-size: .95rem;
  letter-spacing: .04em;
}
.btn--gold:hover { background: #b8921f; }
.btn--gold-lg {
  background: var(--accent);
  color: var(--accent-fg);
  padding: 18px 40px;
  font-size: 1.1rem;
  letter-spacing: .03em;
  box-shadow: 0 12px 32px rgba(201,162,39,.25);
}
.btn--gold-lg:hover { background: #b8921f; transform: scale(1.03); }
.btn--full {
  width: 100%;
  justify-content: center;
  padding: 18px;
  font-size: 1rem;
}

/* ── Hero — photo fills top as background, text below ─────── */
#hero {
  position: relative;
  background: var(--bg);
  overflow: hidden;
}

/* Photo sits directly below h1 — pulled up to hide dark top area of source image */
.hero-photo-bg {
  position: relative;
  width: 100%;
  height: 56vh;
  max-height: 520px;
  z-index: 1;
  margin-top: -120px;
}

.hero-photo-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 35%;
  display: block;
}

/* ── Desktop: centered column hero ────────────────────────── */
@media (min-width: 769px) {
  #hero {
    min-height: 100vh;
    padding-top: var(--header-h);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
  }

  .hero-h1-block {
    padding-top: 0;
    padding-bottom: 0;
    width: 100%;
    max-width: 860px;
    margin: 0 auto;
    text-align: center;
  }

  #hero h1 {
    font-size: clamp(2.2rem, 3.4vw, 3.2rem);
    margin: 0 auto 0;
    text-align: center;
  }

  /* Photo: centered, max-width capped so it's not edge-to-edge */
  .hero-photo-bg {
    position: relative !important;
    width: 100% !important;
    max-width: 960px !important;
    height: 82vh !important;
    max-height: 780px !important;
    margin: -80px auto 0 !important;
    z-index: 1;
  }

  .hero-photo-bg img {
    object-position: center 52%;
  }

  /* Fade left and right edges into the dark background */
  .hero-photo-bg::before {
    content: '';
    position: absolute;
    left: 0; top: 0; bottom: 0;
    width: 12%;
    background: linear-gradient(to right, #090e0b, transparent);
    z-index: 3;
    pointer-events: none;
  }

  .hero-photo-bg::after {
    content: '';
    position: absolute;
    right: 0; top: 0; bottom: 0;
    width: 12%;
    background: linear-gradient(to left, #090e0b, transparent);
    z-index: 3;
    pointer-events: none;
  }

  .hero-inner {
    position: relative;
    z-index: 2;
    width: 100%;
    margin-top: -120px;
    padding-top: 0;
    padding-bottom: 64px;
    text-align: center;
  }

  .hero-text {
    align-items: center;
    text-align: center;
    max-width: 720px;
    margin: 0 auto;
  }
}

/* Seamless dissolve at the bottom — no cut line */
.hero-photo-bg-fade {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 68%;
  background: linear-gradient(to top, var(--bg) 0%, var(--bg) 10%, rgba(9,14,11,.9) 40%, transparent 100%);
  pointer-events: none;
}

/* h1 block above the photo */
.hero-h1-block {
  padding-top: calc(var(--header-h) + 16px);
  padding-bottom: 0;
  max-width: 700px;
}

/* Badge / description / CTA — below the photo */
.hero-inner {
  position: relative;
  z-index: 2;
  padding-top: 0;
  padding-bottom: 72px;
  text-align: center;
}

.hero-text {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-width: 700px;
  margin: 0 auto;
}

/* Top fade removed — headline and photo share same dark background */
.hero-photo-bg-top-fade {
  display: none;
}

@media (max-width: 768px) {
  .hero-photo-bg {
    height: 60vh;
    max-height: 440px;
  }
  .hero-inner {
    padding-bottom: 20px;
  }
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  border: 1px solid rgba(201,162,39,.4);
  background: rgba(201,162,39,.1);
  color: var(--accent);
  border-radius: 99px;
  font-size: .8rem;
  font-weight: 500;
  letter-spacing: .1em;
  text-transform: uppercase;
  margin-top: 20px;
  margin-bottom: 24px;
}
.hero-badge span {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--accent);
}
#hero h1 {
  font-family: var(--font-serif);
  font-size: clamp(2.2rem, 5vw, 3.8rem);
  font-weight: 700;
  line-height: 1.15;
  color: #fff;
  margin-bottom: 24px;
}
#hero h1 em {
  color: var(--accent);
  font-style: italic;
}
#hero p {
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: rgba(255,255,255,.7);
  margin-bottom: 40px;
  max-width: 560px;
  line-height: 1.7;
}

/* ── Social Proof ────────────────────────────────────────── */
#social {
  padding-block: 80px;
  background: var(--bg-card);
}
.stars-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin-bottom: 12px;
}
.stars-row svg { color: var(--accent); }
#social .rating-text {
  text-align: center;
  font-size: 1.1rem;
  font-weight: 500;
  margin-bottom: 48px;
}
#social .rating-text span { color: var(--fg-muted); font-weight: 400; font-size: .95rem; }
.testimonials {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}
.testimonial-card {
  background: var(--bg);
  border: 1px solid var(--border);
  padding: 24px;
  border-radius: var(--radius);
  transition: border-color .3s;
}
.testimonial-card:hover { border-color: rgba(201,162,39,.35); }
/* Header: avatar + name */
.testimonial-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}
.testimonial-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(201,162,39,.35);
  flex-shrink: 0;
}
.testimonial-name {
  font-weight: 600;
  font-size: .88rem;
  color: var(--fg);
  margin: 0 0 4px 0;
  line-height: 1.2;
}
.testimonial-card .card-stars {
  display: flex; gap: 3px;
}
.testimonial-card .card-stars svg { color: var(--accent); }
.testimonial-card .review-text {
  font-size: .875rem;
  color: rgba(240,236,227,.72);
  font-style: italic;
  line-height: 1.7;
  margin-top: 12px;
}

/* ── Services ────────────────────────────────────────────── */
#services {
  padding-block: 96px;
  background: var(--bg);
}
.section-label {
  text-align: center;
  font-size: .75rem;
  font-weight: 500;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
}
.section-title {
  font-family: var(--font-serif);
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 700;
  text-align: center;
  color: var(--fg);
  margin-bottom: 16px;
}
.section-rule {
  width: 48px; height: 2px;
  background: var(--accent);
  margin: 0 auto 24px;
}
.section-desc {
  text-align: center;
  max-width: 600px;
  margin-inline: auto;
  color: var(--fg-muted);
  font-size: 1.05rem;
  margin-bottom: 56px;
}
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}
.service-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 32px;
  border-radius: var(--radius);
  transition: border-color .3s, box-shadow .3s;
  cursor: default;
}
.service-card:hover {
  border-color: rgba(201,162,39,.4);
  box-shadow: 0 8px 24px rgba(0,0,0,.4);
}
.service-icon {
  width: 48px; height: 48px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
  transition: border-color .3s, background .3s;
}
.service-card:hover .service-icon {
  border-color: rgba(201,162,39,.4);
  background: rgba(201,162,39,.1);
}
.service-icon svg { color: var(--accent); }
.service-card h3 {
  font-family: var(--font-serif);
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--fg);
}
.service-card p {
  font-size: .88rem;
  color: var(--fg-muted);
  line-height: 1.7;
}
.services-note {
  display: flex;
  align-items: center;
  gap: 12px;
  justify-content: center;
  margin-top: 48px;
  padding: 16px 28px;
  background: var(--bg-card);
  border: 1px solid rgba(201,162,39,.2);
  border-radius: var(--radius);
  width: fit-content;
  margin-inline: auto;
  font-size: .9rem;
  font-weight: 500;
}
.services-note svg { color: var(--accent); flex-shrink: 0; }

/* ── Differentials ───────────────────────────────────────── */
#differentials {
  padding-block: 96px;
  background: var(--bg-card);
  position: relative;
  overflow: hidden;
}
#differentials::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle at 2px 2px, rgba(201,162,39,.04) 1px, transparent 0);
  background-size: 32px 32px;
}
.diff-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
  position: relative;
  z-index: 1;
}
.diff-list { display: flex; flex-direction: column; gap: 28px; }
.diff-item  { display: flex; align-items: center; gap: 20px; }
.diff-icon {
  flex-shrink: 0;
  width: 44px; height: 44px;
  border: 1px solid rgba(201,162,39,.3);
  background: rgba(201,162,39,.1);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
}
.diff-icon svg { color: var(--accent); }
.diff-item p { font-size: 1rem; color: rgba(240,236,227,.85); }

/* CTA Card */
.cta-card {
  background: var(--bg);
  border: 1px solid var(--border);
  padding: 48px;
  border-radius: var(--radius);
  position: relative;
}
.cta-card::before {
  content: '';
  position: absolute;
  top: -12px; left: -12px;
  width: 64px; height: 64px;
  border-top: 2px solid rgba(201,162,39,.6);
  border-left: 2px solid rgba(201,162,39,.6);
}
.cta-card::after {
  content: '';
  position: absolute;
  bottom: -12px; right: -12px;
  width: 64px; height: 64px;
  border-bottom: 2px solid rgba(201,162,39,.6);
  border-right: 2px solid rgba(201,162,39,.6);
}
.cta-card h3 {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--fg);
  margin-bottom: 16px;
}
.cta-card p {
  color: var(--fg-muted);
  margin-bottom: 32px;
  line-height: 1.7;
}

/* ── Closing CTA ─────────────────────────────────────────── */
#cta-final {
  padding-block: 120px;
  background: var(--bg);
  text-align: center;
  position: relative;
  overflow: hidden;
}
#cta-final::before {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 600px; height: 600px;
  border-radius: 50%;
  background: rgba(201,162,39,.05);
  filter: blur(80px);
  pointer-events: none;
}
.cta-icon-wrap {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 72px; height: 72px;
  border: 1px solid rgba(201,162,39,.35);
  background: rgba(201,162,39,.1);
  border-radius: var(--radius);
  margin-bottom: 32px;
}
.cta-icon-wrap svg { color: var(--accent); }
#cta-final h2 {
  font-family: var(--font-serif);
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 700;
  color: var(--fg);
  max-width: 700px;
  margin-inline: auto;
  margin-bottom: 24px;
  line-height: 1.25;
}
#cta-final p {
  font-size: 1.1rem;
  color: var(--fg-muted);
  max-width: 540px;
  margin-inline: auto;
  margin-bottom: 48px;
  line-height: 1.7;
}

/* ── Footer ──────────────────────────────────────────────── */
#footer {
  background: var(--bg-card);
  border-top: 1px solid var(--border);
  padding-block: 40px;
}
#footer .container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
#footer .logo { height: 40px; width: auto; object-fit: contain; }
#footer p { font-size: .85rem; color: var(--fg-muted); }

/* ── Floating WhatsApp ───────────────────────────────────── */
.whatsapp-float {
  position: fixed;
  bottom: 24px; right: 24px;
  z-index: 200;
  background: var(--green-btn);
  color: #fff;
  width: 60px; height: 60px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 24px rgba(37,211,102,.35);
  transition: transform .25s, background .25s;
}
.whatsapp-float:hover { transform: scale(1.12); background: #20bd5a; }
.whatsapp-float .wa-tooltip {
  position: absolute;
  right: calc(100% + 16px);
  top: 50%; transform: translateY(-50%);
  background: var(--bg-card);
  color: var(--fg);
  border: 1px solid var(--border);
  padding: 8px 16px;
  border-radius: var(--radius);
  font-size: .85rem;
  font-weight: 500;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s;
  box-shadow: 0 4px 16px rgba(0,0,0,.5);
}
.whatsapp-float:hover .wa-tooltip { opacity: 1; }

/* ── Responsive ──────────────────────────────────────────── */
@media (max-width: 900px) {
  .diff-grid { grid-template-columns: 1fr; gap: 48px; }
  .cta-card  { padding: 32px; }
}

/* Tablet */
@media (max-width: 860px) {
  .hero-text   { max-width: 520px; }
}

/* Mobile */
@media (max-width: 640px) {
  #hero h1    { font-size: 1.85rem; }
  .btn--gold-lg {
    padding: 16px 20px;
    font-size: .9rem;
    max-width: 100%;
    width: 100%;
    justify-content: center;
    box-sizing: border-box;
  }
  .hero-inner { padding-block: 72px 56px; }
  .hero-text  { max-width: 100%; }
  #social, #services, #differentials, #cta-final { padding-block: 64px; }
  #cta-final .fade-up { width: 100%; display: flex; justify-content: center; }
}
