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

:root {
  --navy: #252236;
  --gold: #A38251;
  --gold-dark: #7d6440;
  --gold-tint: rgba(163, 130, 81, 0.12);
  --whatsapp: #25d366;
  --whatsapp-dark: #1ebe5b;
  --off-white: #f8fafc;
  --white: #ffffff;
  --text-dark: #1a2433;
  --text-muted: #46536b;

  --gradient-gold: linear-gradient(135deg, #8a6f42 0%, var(--gold) 45%, #c2a271 70%, #8a6f42 100%);

  --font-heading: 'Montserrat', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;

  --container-width: 1140px;
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-sans);
  color: var(--text-dark);
  line-height: 1.6;
  background: var(--white);
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }

.container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 24px;
}

section { padding: 64px 0; }

h1, h2, h3 { font-family: var(--font-heading); font-weight: 700; line-height: 1.25; color: var(--navy); }

.eyebrow {
  display: inline-block;
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold-dark);
  margin-bottom: 14px;
}

/* Reveal-on-scroll (progressive enhancement, see script.js) */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: 1.02rem;
  text-decoration: none;
  border-radius: 999px;
  padding: 16px 30px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease, color 0.2s ease;
  cursor: pointer;
  border: none;
}

.btn-whatsapp {
  background-color: var(--whatsapp);
  color: var(--white);
  box-shadow: 0 4px 14px rgba(37, 211, 102, 0.35);
}
.btn-whatsapp:hover {
  background-color: var(--whatsapp-dark);
  transform: translateY(-3px);
  box-shadow: 0 10px 24px rgba(37, 211, 102, 0.45);
}

.btn-outline-navy {
  background-color: transparent;
  color: var(--white);
  border: 2px solid rgba(255, 255, 255, 0.6);
}
.btn-outline-navy:hover {
  background-color: rgba(255, 255, 255, 0.12);
  border-color: var(--white);
  transform: translateY(-3px);
}

.btn-outline-gold {
  background-color: transparent;
  background-image: none;
  color: var(--gold-dark);
  border: 2px solid var(--gold);
  transition: transform 0.2s ease, box-shadow 0.2s ease, color 0.2s ease, background-image 0.2s ease;
}
.btn-outline-gold:hover {
  background-image: var(--gradient-gold);
  color: var(--white);
  border-color: transparent;
  transform: translateY(-3px);
  box-shadow: 0 10px 24px rgba(163, 130, 81, 0.35);
}

.btn-large { padding: 19px 38px; font-size: 1.1rem; }
.btn-nav { padding: 11px 20px; font-size: 0.92rem; }

.btn-wrap { text-align: center; }

.icon { width: 26px; height: 26px; }
.icon-gold { color: var(--gold-dark); }
.icon-navy { color: var(--navy); }
.icon-whatsapp { width: 19px; height: 19px; flex-shrink: 0; }

/* ===== Header ===== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--white);
  transition: box-shadow 0.25s ease;
}
.site-header.is-scrolled { box-shadow: 0 4px 18px rgba(37, 34, 54, 0.12); }

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding-top: 14px;
  padding-bottom: 14px;
}

.header-logo { display: grid; height: 46px; }
.header-logo img {
  grid-area: 1 / 1;
  align-self: start;
  justify-self: start;
  height: 46px;
  width: auto;
  opacity: 1;
  transition: opacity 0.25s ease;
}
.header-logo .logo-on-dark { opacity: 0; }

.nav-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  flex-direction: column;
  gap: 4px;
  background: var(--white);
  box-shadow: 0 20px 30px rgba(37, 34, 54, 0.14);
  padding: 8px 24px 20px;
}
.nav-menu.is-open { display: flex; }

.nav-link {
  position: relative;
  display: inline-block;
  padding: 12px 0;
  font-weight: 600;
  font-size: 0.98rem;
  color: var(--navy);
  text-decoration: none;
}
.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 6px;
  width: 0;
  height: 2px;
  background: var(--gold-dark);
  transition: width 0.25s ease;
}
.nav-link:hover::after,
.nav-link[aria-current="page"]::after { width: 100%; }
.nav-link[aria-current="page"] { color: var(--gold-dark); }

.nav-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  background: none;
  border: none;
  cursor: pointer;
  flex-shrink: 0;
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--navy);
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ===== Footer ===== */
.site-footer {
  background-color: var(--navy);
  color: rgba(248, 250, 252, 0.85);
  padding: 60px 0 0;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
  padding-bottom: 40px;
}
.footer-brand img { height: 42px; width: auto; margin-bottom: 16px; }
.footer-brand p { font-size: 0.92rem; max-width: 42ch; margin-bottom: 14px; color: rgba(248, 250, 252, 0.75); }
.footer-brand a {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--gold);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.92rem;
}
.footer-col h4 {
  font-family: var(--font-sans);
  color: var(--white);
  font-size: 0.92rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 16px;
}
.footer-links { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.footer-links a, .footer-links li {
  color: rgba(248, 250, 252, 0.75);
  text-decoration: none;
  font-size: 0.92rem;
}
.footer-links a:hover { color: var(--gold); }
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding: 20px 0;
  text-align: center;
  font-size: 0.85rem;
  color: rgba(248, 250, 252, 0.6);
}

/* ===== Photo frame ===== */
.photo-frame { position: relative; }
.photo-frame::before {
  content: "";
  position: absolute;
  inset: 16px -16px -16px 16px;
  border: 2px solid var(--gold);
  border-radius: 12px;
  z-index: 0;
}
.photo-frame img {
  position: relative;
  z-index: 1;
  border-radius: 12px;
  box-shadow: 0 20px 50px rgba(37, 34, 54, 0.3);
  width: 100%;
  height: auto;
}

/* ===== Home: Hero ===== */
.home-hero {
  background-color: var(--navy);
  padding: 56px 0 76px;
  color: var(--white);
}
.hero-grid { display: grid; grid-template-columns: 1fr; gap: 48px; align-items: center; }
.hero-grid > * { min-width: 0; }
.hero-image { display: none; }
.home-hero .eyebrow { color: var(--gold); }
.home-hero h1 { color: var(--white); font-size: 2.1rem; margin-bottom: 20px; }
.home-hero h1 .highlight { color: var(--gold); }
.home-hero .subheadline { color: #d9d8e2; font-size: 1.05rem; max-width: 52ch; margin-bottom: 32px; }
.hero-ctas { display: flex; flex-wrap: wrap; gap: 16px; }

/* ===== Home: Credentials strip ===== */
.credentials-strip {
  padding: 0;
  transform: translateY(-40px);
}
.credentials-grid {
  background: var(--white);
  border-radius: 14px;
  box-shadow: 0 20px 50px rgba(37, 34, 54, 0.18);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  overflow: hidden;
}
.credential-item {
  padding: 26px 20px;
  text-align: center;
  border-right: 1px solid var(--off-white);
  border-bottom: 1px solid var(--off-white);
}
.credential-item strong {
  display: block;
  font-family: var(--font-heading);
  font-size: 1.4rem;
  color: var(--navy);
}
.credential-item span { font-size: 0.85rem; color: var(--text-muted); }

/* ===== Section headers (shared pattern) ===== */
.section-head { text-align: center; max-width: 720px; margin: 0 auto 44px; }
.section-head.align-left { text-align: left; margin: 0 0 32px; }

/* ===== Card grids ===== */
.card-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}
.info-card {
  background: var(--white);
  border-style: solid;
  border-width: 4px 0 0 0;
  border-image: var(--gradient-gold) 1;
  border-radius: 10px;
  padding: 28px 24px;
  text-align: left;
  box-shadow: 0 8px 24px rgba(37, 34, 54, 0.1);
}
.info-card .icon-wrap { margin-bottom: 16px; }
.info-card h3 { font-size: 1.1rem; margin-bottom: 10px; }
.info-card p { color: var(--text-muted); font-size: 0.95rem; }

.areas-preview { background: var(--off-white); }
a.area-card { display: block; text-decoration: none; }

/* ===== Quote band ===== */
.quote-band {
  position: relative;
  background-color: var(--navy);
  background-image: linear-gradient(rgba(37, 34, 54, 0.8), rgba(37, 34, 54, 0.8)), url('hero-legal-bg-v2.png');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  color: var(--white);
  text-align: center;
}
.quote-mark { font-family: var(--font-heading); font-size: 4rem; color: var(--gold); line-height: 1; margin-bottom: 8px; }
.quote-band blockquote {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.4rem;
  max-width: 760px;
  margin: 0 auto 18px;
  line-height: 1.5;
}
.quote-band cite { font-style: normal; color: var(--gold); font-size: 0.92rem; font-weight: 600; }

.photo-collage {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.photo-collage img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  object-position: top center;
  border-radius: 10px;
  box-shadow: 0 12px 30px rgba(37, 34, 54, 0.18);
}

/* ===== Team preview / photo+text split ===== */
.split-section { display: grid; grid-template-columns: 1fr; gap: 40px; align-items: center; }
.split-section > * { min-width: 0; }
.split-section.reverse .split-text { order: 2; }
.split-text p { color: var(--text-muted); margin-bottom: 16px; }
.split-text p strong, .page-header p strong { color: var(--navy); }

/* ===== Steps ===== */
.steps-list { list-style: none; display: grid; grid-template-columns: 1fr; gap: 24px; counter-reset: step; }
.steps-list li {
  counter-increment: step;
  position: relative;
  padding-left: 56px;
}
.steps-list li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: var(--navy);
  color: var(--gold);
  font-family: var(--font-heading);
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}
.steps-list h3 { font-size: 1.05rem; margin-bottom: 6px; }
.steps-list p { color: var(--text-muted); font-size: 0.94rem; }

/* ===== Differentials band (dark) ===== */
.differentials-band {
  background-color: var(--navy);
}
.differentials-grid { display: grid; grid-template-columns: 1fr; gap: 20px; }
.differential-tile {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 10px;
  padding: 24px 20px;
  color: var(--white);
}
.differential-tile h3 { color: var(--white); font-size: 1.02rem; margin-bottom: 8px; }
.differential-tile p { color: rgba(248, 250, 252, 0.75); font-size: 0.92rem; }

/* ===== Final CTA ===== */
.final-cta {
  background: var(--off-white);
  text-align: center;
}
.final-cta h2 { margin-bottom: 12px; }
.final-cta p { color: var(--text-muted); margin-bottom: 28px; }
.final-cta .phone-note { margin-top: 16px; font-size: 0.92rem; color: var(--text-muted); }

/* ===== Page header (interior pages) ===== */
.page-header { background: var(--off-white); padding: 56px 0; }
.page-header h1 { font-size: 2rem; margin-bottom: 18px; }
.page-header .split-text p { color: var(--text-muted); margin-bottom: 14px; }

.page-header.about-intro {
  background-color: var(--off-white);
  background-image: linear-gradient(rgba(248, 250, 252, 0.94), rgba(248, 250, 252, 0.94)), url('hero-legal-bg-v2.png');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

/* ===== O Escritório: values grid ===== */
.values-section { background: var(--white); }

/* ===== O Escritório: team grid ===== */
.team-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
.team-card { text-align: center; }
.team-card .team-photo {
  aspect-ratio: 3 / 4;
  overflow: hidden;
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(37, 34, 54, 0.14);
  margin-bottom: 14px;
}
.team-card .team-photo img { width: 100%; height: 100%; object-fit: cover; object-position: top center; }
.team-card h3 { font-size: 1rem; margin-bottom: 2px; }
.team-card span { font-size: 0.85rem; color: var(--gold-dark); font-weight: 600; }

/* ===== Áreas de Atuação grid ===== */
.areas-grid { display: grid; grid-template-columns: 1fr; gap: 22px; scroll-margin-top: 90px; }
.area-card {
  scroll-margin-top: 90px;
  background: var(--white);
  border: 1px solid rgba(37, 34, 54, 0.1);
  border-radius: 10px;
  padding: 26px 22px;
  box-shadow: 0 2px 10px rgba(37, 34, 54, 0.06);
  transition: border-color 0.2s ease, transform 0.2s ease;
}
.area-card:hover { border-color: var(--gold); transform: translateY(-3px); }
.area-card .icon-wrap {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  background-image: var(--gradient-gold);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}
.area-card .icon-wrap .icon { color: var(--white); }
.area-card h3 { font-size: 1.05rem; margin-bottom: 8px; }
.area-card p { color: var(--text-muted); font-size: 0.92rem; }

/* ===== Contato ===== */
.contato-grid { display: grid; grid-template-columns: 1fr; gap: 40px; }
.contact-methods { display: flex; flex-direction: column; gap: 16px; }
.contact-method-card {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  background: var(--white);
  border-radius: 10px;
  padding: 20px;
  box-shadow: 0 2px 10px rgba(37, 34, 54, 0.08);
}
.contact-method-card .icon-wrap {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--gold-tint);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.contact-method-card h3 { font-size: 0.98rem; margin-bottom: 4px; }
.contact-method-card p { font-size: 0.92rem; color: var(--text-muted); margin-bottom: 10px; }

.contact-form { background: var(--off-white); border-radius: 12px; padding: 30px 26px; }
.form-field { margin-bottom: 18px; }
.form-field label { display: block; font-size: 0.88rem; font-weight: 600; color: var(--navy); margin-bottom: 6px; }
.form-field input, .form-field select, .form-field textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid rgba(37, 34, 54, 0.18);
  border-radius: 8px;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  background: var(--white);
  color: var(--text-dark);
}
.form-field textarea { min-height: 110px; resize: vertical; }
.form-field input:focus, .form-field select:focus, .form-field textarea:focus {
  outline: 2px solid var(--gold-dark);
  outline-offset: 1px;
}

.map-embed { border-radius: 12px; overflow: hidden; box-shadow: 0 8px 24px rgba(37, 34, 54, 0.12); margin-top: 48px; }
.map-embed iframe { width: 100%; height: 360px; border: 0; display: block; }
.split-image.map-embed { margin-top: 0; }
.split-image.map-embed iframe { height: 100%; min-height: 320px; }

/* ===== Responsive: Desktop ===== */
@media (min-width: 768px) {
  section { padding: 90px 0; }

  .header-logo { height: 52px; }
  .header-logo img { height: 52px; }
  .nav-toggle { display: none; }
  .nav-menu {
    display: flex;
    position: static;
    flex-direction: row;
    align-items: center;
    gap: 28px;
    box-shadow: none;
    padding: 0;
    background: none;
  }
  .nav-link { padding: 8px 0; }

  .home-hero h1 { font-size: 2.7rem; }
  .home-hero .subheadline { font-size: 1.12rem; }

  .team-grid { grid-template-columns: repeat(4, 1fr); }

  .quote-band { background-attachment: fixed; }

  .credentials-grid { grid-template-columns: repeat(4, 1fr); }
  .credential-item:nth-child(2n) { border-right: 1px solid var(--off-white); }
  .credential-item:last-child, .credential-item:nth-child(4) { border-right: none; }

  .card-grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
  .card-grid.cols-4 { grid-template-columns: repeat(4, 1fr); }
  .areas-preview-grid { grid-template-columns: repeat(2, 1fr); }

  .split-section { grid-template-columns: 1fr 1fr; }
  .split-section.reverse .split-text { order: 0; }

  .steps-list { grid-template-columns: repeat(4, 1fr); }
  .differentials-grid { grid-template-columns: repeat(4, 1fr); }

  .footer-grid { grid-template-columns: 2fr 1fr 1fr 1fr; }

  .page-header .split-section { grid-template-columns: 1.1fr 0.9fr; }

  .areas-grid { grid-template-columns: repeat(4, 1fr); }

  .contato-grid { grid-template-columns: 0.9fr 1.1fr; }
}

@media (min-width: 1024px) {
  .home-hero h1 { font-size: 3rem; }
  .page-header h1 { font-size: 2.3rem; }

  .header-transparent {
    position: static;
    background: linear-gradient(180deg, rgba(37, 34, 54, 0.45) 0%, rgba(37, 34, 54, 0.22) 55%, rgba(37, 34, 54, 0) 100%);
    margin-bottom: -84px;
    box-shadow: none;
  }
  .header-transparent .nav-link { color: var(--white); }
  .header-transparent .nav-link[aria-current="page"] { color: var(--gold); }
  .header-transparent .nav-link::after { background: var(--gold); }
  .header-transparent .nav-toggle span { background: var(--white); }
  .header-transparent .logo-on-dark { opacity: 1; }
  .header-transparent .logo-on-light { opacity: 0; }

  .home-hero {
    background-color: var(--navy);
    padding: 180px 0 115px;
  }
  .hero-grid { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 56px; align-items: center; }
  .hero-text { max-width: none; }
  .hero-image { display: block; }
}

/* ===== Home Hero: mobile image band ===== */
@media (max-width: 767px) {
  .home-hero {
    position: relative;
    padding: 0 0 56px;
    overflow: hidden;
  }
  .home-hero::before {
    content: "";
    display: block;
    height: 300px;
    margin-bottom: 14px;
    background-image:
      linear-gradient(to top, var(--navy) 0%, rgba(37, 34, 54, 0.55) 55%, rgba(37, 34, 54, 0) 100%),
      url('desktop-mobile-bg.png');
    background-size: cover;
    background-position: top center;
    background-repeat: no-repeat;
  }
  .home-hero .hero-text { text-align: center; }
  .home-hero .hero-ctas { justify-content: center; margin-bottom: 28px; }
  .home-hero .btn-outline-navy { display: none; }
}
