/* ============================================================
   Bufet Jurídico C.A.R. y Asociados
   Estilo "Archio" (limpio, claro, contadores) + colores C.A.R.
   Azul marino #0d141a + blanco + dorado #b08d3e. Poppins.
   ============================================================ */

:root {
  --navy: #0d141a;
  --navy-2: #16222d;
  --gold: #b08d3e;
  --gold-2: #8f6f2e;
  --white: #ffffff;
  --paper: #f6f7f8;
  --ink: #1a232c;
  --text: #56585e;
  --muted: #8a939c;
  --line: #e7e9ec;
  --sans: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --radius: 6px;
  --maxw: 1140px;
  --shadow-sm: 0 1px 3px rgba(13,20,26,.07);
  --shadow-md: 0 14px 40px rgba(13,20,26,.12);
  --shadow-lg: 0 28px 70px rgba(13,20,26,.18);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.7;
  color: var(--text);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button { font-family: inherit; cursor: pointer; }

h1, h2, h3, h4 {
  font-family: var(--sans);
  color: var(--navy);
  line-height: 1.15;
  font-weight: 700;
  letter-spacing: -0.01em;
}
h1 { font-size: clamp(2.3rem, 5vw, 3.8rem); font-weight: 700; }
h2 { font-size: clamp(1.8rem, 3.4vw, 2.6rem); }
h3 { font-size: 1.25rem; font-weight: 600; }
h4 { font-size: 1.05rem; font-weight: 600; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 12px;
  font-size: .74rem; font-weight: 600; letter-spacing: .2em;
  text-transform: uppercase; color: var(--gold-2);
  margin-bottom: 14px;
}
.eyebrow::before { content: ""; width: 30px; height: 2px; background: var(--gold); }
.eyebrow.on-dark { color: var(--gold); }
.lead { font-size: 1.08rem; color: var(--text); max-width: 60ch; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 28px; }
.section { padding: 90px 0; }
.section--soft { background: var(--paper); }
.section--navy { background: var(--navy); color: #c3ccd3; }
.section--navy h2, .section--navy h3 { color: #fff; }
.section-head { max-width: 720px; margin-bottom: 46px; }
.section-head--center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head--center .eyebrow { justify-content: center; }
.section-head h2 { margin-bottom: 14px; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  padding: 14px 28px; border-radius: var(--radius); min-height: 48px;
  font-weight: 600; font-size: .94rem; letter-spacing: .01em;
  border: 1px solid transparent; transition: all .22s ease;
}
.btn--gold { background: var(--gold); color: #fff; }
.btn--gold:hover { background: var(--gold-2); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn--navy { background: var(--navy); color: #fff; }
.btn--navy:hover { background: var(--navy-2); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn--outline { background: transparent; color: var(--navy); border-color: var(--line); }
.btn--outline:hover { border-color: var(--gold); color: var(--gold-2); }
.btn--white { background: #fff; color: var(--navy); }
.btn--white:hover { background: #eef1f3; }
.btn .arrow { transition: transform .22s ease; }
.btn:hover .arrow { transform: translateX(3px); }

/* Header */
.site-header { position: sticky; top: 0; z-index: 100; background: rgba(255,255,255,.94); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 120px; }
.brand { display: flex; align-items: center; gap: 13px; }
.brand-logo { height: 94px; width: auto; max-width: 340px; display: block; }
.hero-logo { width: 433px; height: 433px; display: block; margin: 0 auto 30px; }
.brand-mark {
  width: 44px; height: 44px; flex: 0 0 auto; border: 1.5px solid var(--gold);
  display: grid; place-items: center; font-weight: 700; font-size: .78rem;
  color: var(--gold-2); letter-spacing: .02em; border-radius: 3px;
}
.brand-name { line-height: 1.15; }
.brand-name b { display: block; font-size: 1rem; color: var(--navy); font-weight: 700; }
.brand-name span { font-size: .68rem; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }

.nav { display: flex; align-items: center; gap: 28px; }
.nav a { font-size: .93rem; font-weight: 500; color: var(--text); position: relative; padding: 6px 0; }
.nav a::after { content: ""; position: absolute; left: 0; bottom: 0; width: 0; height: 2px; background: var(--gold); transition: width .22s ease; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--navy); }
.nav a:hover::after, .nav a[aria-current="page"]::after { width: 100%; }
.nav-cta { margin-left: 4px; }

.nav-toggle { display: none; background: none; border: 0; width: 44px; height: 44px; flex-direction: column; justify-content: center; gap: 5px; align-items: center; }
.nav-toggle span { display: block; width: 24px; height: 2px; background: var(--navy); transition: .25s; }
.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); }

/* Hero */
.hero { position: relative; overflow: hidden; background: var(--paper); }
.hero-inner { display: grid; grid-template-columns: 1.05fr .95fr; gap: 48px; align-items: center; padding: 84px 0 90px; }
.hero h1 { margin: 0 0 20px; }
.hero h1 em { font-style: normal; color: var(--gold-2); }
.hero p.lead { font-size: 1.12rem; margin-bottom: 32px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }
.hero-visual { position: relative; }
.hero-visual img { border-radius: var(--radius); box-shadow: var(--shadow-lg); aspect-ratio: 4/5; object-fit: cover; width: 100%; }
.hero-visual::after { content: ""; position: absolute; inset: 18px -18px -18px 18px; z-index: -1; border: 2px solid var(--gold); border-radius: var(--radius); }

/* Counter stats band */
.stats-band { background: var(--navy); padding: 52px 0; }
.stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); }
.stat { padding: 16px 24px; text-align: center; border-left: 1px solid rgba(255,255,255,.14); }
.stat:first-child { border-left: 0; }
.stat b { display: block; font-size: clamp(2.4rem, 4.5vw, 3.4rem); font-weight: 700; color: var(--gold); line-height: 1; }
.stat span { display: block; margin-top: 10px; font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; color: #84929c; }

/* Practice areas grid */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; transition: transform .25s ease, box-shadow .25s ease; }
.card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); }
.card .card-img { aspect-ratio: 16/11; overflow: hidden; }
.card .card-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .45s ease; }
.card:hover .card-img img { transform: scale(1.06); }
.card .card-body { padding: 24px 26px 28px; }
.card .tag { font-size: .72rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--gold-2); }
.card h3 { margin: 10px 0 10px; }
.card p { color: var(--text); font-size: .94rem; }
.card .more { display: inline-flex; align-items: center; gap: 7px; margin-top: 16px; font-weight: 600; font-size: .9rem; color: var(--gold-2); }
.card .more .arrow { transition: transform .22s; }
.card:hover .more .arrow { transform: translateX(3px); }

/* Split */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.split img { border-radius: var(--radius); box-shadow: var(--shadow-md); }
.split ul.check { margin-top: 22px; display: grid; gap: 12px; }
.split ul.check li { display: flex; gap: 12px; align-items: flex-start; color: var(--text); }
.check-ico { flex: 0 0 auto; width: 24px; height: 24px; border-radius: 50%; background: var(--gold); color: #fff; display: grid; place-items: center; margin-top: 2px; }
.check-ico svg { width: 13px; height: 13px; }

/* Values */
.values { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.value { padding: 30px 22px; text-align: center; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.value .v-num { font-weight: 700; font-size: .9rem; color: var(--gold-2); letter-spacing: .1em; }
.value h3 { margin: 12px 0 8px; }
.value p { font-size: .9rem; color: var(--text); }

/* Testimonials */
.testi-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 26px; }
.testi { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 36px 34px; position: relative; }
.testi::before { content: "\201C"; font-size: 3.6rem; color: var(--gold); line-height: 1; position: absolute; top: 18px; left: 24px; opacity: .4; font-weight: 700; }
.testi p { font-size: 1.05rem; color: var(--navy); position: relative; z-index: 1; }
.testi .stars { color: var(--gold); letter-spacing: 3px; margin: 16px 0 8px; }
.testi cite { font-style: normal; font-size: .9rem; color: var(--muted); }
.testi cite b { display: block; color: var(--navy); font-size: .95rem; font-weight: 600; }

/* CTA band */
.cta-band { background: var(--navy); color: #c3ccd3; text-align: center; padding: 88px 32px; }
.cta-band h2 { color: #fff; max-width: 26ch; margin: 0 auto 18px; }
.cta-band p { max-width: 58ch; margin: 0 auto 32px; color: #b9c2ca; }

/* Footer */
.site-footer { background: var(--navy); color: #84929c; padding: 64px 0 32px; font-size: .9rem; }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr; gap: 40px; }
.footer-grid h4 { color: #fff; font-size: .8rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; margin-bottom: 18px; }
.footer-grid a { display: block; padding: 4px 0; color: #aeb7bf; transition: color .2s; }
.footer-grid a:hover { color: var(--gold); }
.footer-contact li { display: flex; gap: 10px; margin-bottom: 12px; align-items: flex-start; }
.footer-contact svg { width: 18px; height: 18px; flex: 0 0 auto; color: var(--gold); margin-top: 3px; }
.footer-contact a { display: inline; color: #c3ccd3; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.12); margin-top: 48px; padding-top: 24px; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: .8rem; color: #5f6c76; }

/* Page hero (interior) */
.page-hero { padding: 80px 0 60px; background: var(--paper); }
.page-hero h1 { margin: 0 0 14px; }
.page-hero p { color: var(--text); max-width: 62ch; font-size: 1.05rem; }

/* Lists (services) */
.svc-list { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.svc-item { display: flex; gap: 14px; align-items: flex-start; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 24px; }
.svc-item .check-ico { margin-top: 2px; }
.svc-item b { display: block; color: var(--navy); font-size: .98rem; font-weight: 600; }
.svc-item p { color: var(--muted); font-size: .9rem; margin-top: 3px; }

/* Contact */
.contact-grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: 48px; align-items: start; }
.contact-card { display: flex; gap: 16px; padding: 22px 0; border-bottom: 1px solid var(--line); }
.contact-card:last-child { border-bottom: 0; }
.contact-card .ico { width: 48px; height: 48px; flex: 0 0 auto; border-radius: 50%; background: var(--paper); color: var(--gold-2); display: grid; place-items: center; }
.contact-card .ico svg { width: 22px; height: 22px; }
.contact-card b { display: block; color: var(--navy); margin-bottom: 2px; }
.contact-card p { color: var(--muted); font-size: .94rem; }
.contact-card a { color: var(--gold-2); font-weight: 600; }

.form { display: grid; gap: 16px; }
.form .row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form label { font-size: .84rem; font-weight: 600; color: var(--navy); display: block; margin-bottom: 6px; }
.form input, .form textarea, .form select {
  width: 100%; padding: 13px 15px; border: 1px solid var(--line); border-radius: var(--radius);
  font-family: var(--sans); font-size: .95rem; color: var(--ink); background: #fff;
  transition: border-color .2s, box-shadow .2s;
}
.form input:focus, .form textarea:focus, .form select:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px rgba(176,141,62,.16); }
.form textarea { min-height: 140px; resize: vertical; }
.form .note { font-size: .82rem; color: var(--muted); }

/* Reveal (safe) */
.js-anim .reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.js-anim .reveal-left { opacity: 0; transform: translateX(-32px); transition: opacity .7s ease, transform .7s ease; }
.js-anim .reveal-right { opacity: 0; transform: translateX(32px); transition: opacity .7s ease, transform .7s ease; }
.js-anim .reveal-zoom { opacity: 0; transform: scale(.94); transition: opacity .7s ease, transform .7s ease; }
.js-anim .reveal.in, .js-anim .reveal-left.in, .js-anim .reveal-right.in, .js-anim .reveal-zoom.in { opacity: 1; transform: none; }
/* stagger for card grids */
.js-anim .grid-3 .card:nth-child(2) { transition-delay: .08s; }
.js-anim .grid-3 .card:nth-child(3) { transition-delay: .16s; }
.js-anim .grid-3 .card:nth-child(4) { transition-delay: .24s; }
.js-anim .grid-3 .card:nth-child(5) { transition-delay: .32s; }
.js-anim .grid-3 .card:nth-child(6) { transition-delay: .40s; }
.js-anim .values .value:nth-child(2) { transition-delay: .08s; }
.js-anim .values .value:nth-child(3) { transition-delay: .16s; }
.js-anim .values .value:nth-child(4) { transition-delay: .24s; }
@media (prefers-reduced-motion: reduce) {
  .js-anim .reveal, .js-anim .reveal-left, .js-anim .reveal-right, .js-anim .reveal-zoom { opacity: 1; transform: none; transition: none; }
}

/* Shine sweep (like Archio) */
.btn--gold, .btn--navy { position: relative; overflow: hidden; }
.btn--gold::after, .btn--navy::after {
  content: ""; position: absolute; top: 0; left: -80%; width: 45%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.45), transparent);
  transform: skewX(-20deg);
}
.btn--gold:hover::after, .btn--navy:hover::after { left: 130%; transition: left .55s ease; }

/* Focus visibility */
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible {
  outline: 2px solid var(--gold); outline-offset: 2px;
}
.skip-link { position: absolute; left: -9999px; top: 0; z-index: 200; background: var(--navy); color: #fff; padding: 12px 20px; font-weight: 600; }
.skip-link:focus { left: 0; }

/* Responsive */
@media (max-width: 960px) {
  .hero-inner, .split, .contact-grid, .footer-grid { grid-template-columns: 1fr; }
  .hero-visual { order: -1; max-width: 460px; }
  .grid-3, .values { grid-template-columns: repeat(2, 1fr); }
  .testi-grid, .svc-list { grid-template-columns: 1fr; }
  .nav { display: none; }
  .nav-toggle { display: flex; }
  .nav.open { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; position: absolute; top: 120px; left: 0; right: 0; background: #fff; border-bottom: 1px solid var(--line); padding: 18px 28px 26px; }
  .nav.open a { width: 100%; padding: 12px 0; border-bottom: 1px solid var(--line); }
  .nav.open a:last-of-type { border-bottom: 0; }
  .nav-cta { margin: 12px 0 0; width: 100%; }
  .nav-cta .btn { width: 100%; }
  .stats-grid { grid-template-columns: 1fr; }
  .stat { border-left: 0; border-top: 1px solid rgba(255,255,255,.14); }
  .stat:first-child { border-top: 0; }
}
@media (max-width: 560px) {
  .grid-3, .values, .form .row { grid-template-columns: 1fr; }
  .section { padding: 66px 0; }
  .hero-inner { padding: 54px 0 60px; }
  .brand-name span { display: none; }
}
