:root {
  --ink: #0a1424;
  --ink-2: #0e1d32;
  --ink-3: #172a45;
  --paper: #f4f1eb;
  --paper-2: #faf8f4;
  --white: #fff;
  --gold: #c5a15a;
  --gold-light: #e6d3a0;
  --steel: #aab4c2;
  --text: #182334;
  --muted: #667085;
  --line: rgba(20, 34, 54, .12);
  --radius: 22px;
  --shadow: 0 24px 70px rgba(10, 20, 36, .12);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background: var(--paper-2);
  line-height: 1.6;
  overflow-x: hidden;
}
body.menu-open { overflow: hidden; }
a { color: inherit; text-decoration: none; }
button, a { -webkit-tap-highlight-color: transparent; }
svg { display: block; }
.container { width: min(1160px, calc(100% - 40px)); margin: 0 auto; }
.section { padding: 100px 0; }
.section-soft { background: var(--paper); }
.section-dark { background: var(--ink); color: var(--white); }
.skip-link { position: fixed; left: 16px; top: -80px; z-index: 1000; padding: 12px 16px; background: var(--white); color: var(--ink); border-radius: 10px; transition: top .2s ease; }
.skip-link:focus { top: 16px; }

.site-header {
  position: fixed; inset: 0 0 auto; z-index: 100;
  background: rgba(8, 17, 31, .75);
  border-bottom: 1px solid rgba(255,255,255,.08);
  backdrop-filter: blur(18px);
  transition: background .25s ease, box-shadow .25s ease;
}
.site-header.scrolled { background: rgba(8, 17, 31, .94); box-shadow: 0 10px 30px rgba(0,0,0,.18); }
.nav-wrap { height: 82px; display: flex; align-items: center; justify-content: space-between; gap: 28px; }
.brand { display: inline-flex; align-items: center; gap: 12px; color: var(--white); min-width: 0; }
.brand-mark { width: 43px; height: 43px; display: grid; place-items: center; border: 1px solid rgba(230, 211, 160, .45); border-radius: 13px; background: rgba(255,255,255,.04); }
.brand-mark svg { width: 28px; height: 28px; }
.brand-mark svg path:first-child { fill: none; stroke: var(--gold-light); stroke-width: 2.8; }
.brand-mark svg path:last-child { fill: none; stroke: var(--gold-light); stroke-width: 2.3; stroke-linecap: round; }
.brand-text { display: grid; line-height: 1.16; }
.brand-text strong { font-family: Georgia, "Times New Roman", serif; font-size: 1.1rem; letter-spacing: .02em; }
.brand-text small { margin-top: 4px; font-size: .68rem; color: #cbd2dc; white-space: nowrap; }
.site-nav { display: flex; align-items: center; gap: 24px; color: #dce2ea; font-size: .92rem; }
.site-nav a { position: relative; padding: 8px 0; transition: color .2s ease; }
.site-nav a:not(.nav-cta)::after { content: ""; position: absolute; left: 0; bottom: 1px; width: 0; height: 1px; background: var(--gold-light); transition: width .2s ease; }
.site-nav a:hover { color: var(--white); }
.site-nav a:hover::after { width: 100%; }
.nav-cta { padding: 10px 16px !important; border: 1px solid rgba(230,211,160,.5); border-radius: 999px; color: var(--gold-light); }
.menu-toggle { display: none; width: 44px; height: 44px; border: 0; background: transparent; padding: 10px; }
.menu-toggle span { display: block; height: 2px; background: var(--white); margin: 5px 0; transition: transform .2s ease, opacity .2s ease; }

.hero { position: relative; min-height: 100vh; min-height: 100svh; display: grid; align-items: center; overflow: hidden; padding: 142px 0 90px; }
.hero::before { content: ""; position: absolute; inset: 0; background-image: linear-gradient(rgba(255,255,255,.026) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.026) 1px, transparent 1px); background-size: 58px 58px; mask-image: linear-gradient(to bottom, black, transparent 86%); pointer-events: none; }
.hero-glow { position: absolute; border-radius: 50%; filter: blur(40px); opacity: .18; }
.hero-glow-a { width: 480px; height: 480px; right: -140px; top: 5%; background: #7f612a; }
.hero-glow-b { width: 360px; height: 360px; left: -140px; bottom: -100px; background: #375c83; }
.hero-grid { position: relative; z-index: 2; display: grid; grid-template-columns: 1.1fr .9fr; align-items: center; gap: 70px; }
.eyebrow { margin: 0 0 16px; text-transform: uppercase; letter-spacing: .18em; color: var(--gold-light); font-size: .75rem; font-weight: 800; }
.eyebrow.dark { color: #8a692e; }
.hero h1, .section-heading h2, .summary-panel h2, .contact-copy h2, .institutional-band h2 { font-family: Georgia, "Times New Roman", serif; font-weight: 500; line-height: 1.04; letter-spacing: -.025em; }
.hero h1 { margin: 0; max-width: 740px; font-size: clamp(3.1rem, 6.2vw, 6.6rem); }
.hero h1 span { color: var(--gold-light); font-style: italic; font-weight: 400; }
.hero-lead { max-width: 620px; margin: 28px 0 0; font-size: clamp(1.08rem, 1.8vw, 1.35rem); color: #cfd6df; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 36px; }
.btn { min-height: 50px; display: inline-flex; align-items: center; justify-content: center; padding: 0 20px; border-radius: 999px; font-weight: 800; font-size: .92rem; transition: transform .2s ease, box-shadow .2s ease, background .2s ease; }
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: linear-gradient(135deg, var(--gold-light), var(--gold)); color: #17130c; box-shadow: 0 12px 34px rgba(197,161,90,.22); }
.btn-ghost { border: 1px solid rgba(255,255,255,.22); color: var(--white); background: rgba(255,255,255,.035); }
.hero-contact { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-top: 30px; color: #e5e9ee; font-weight: 700; }
.hero-contact a { border-bottom: 1px solid rgba(230,211,160,.3); }
.hero-contact a:hover { color: var(--gold-light); }
.hero-visual { position: relative; aspect-ratio: 1; display: grid; place-items: center; }
.hero-emblem { width: min(70%, 330px); aspect-ratio: 1; border-radius: 50%; display: grid; place-items: center; background: radial-gradient(circle at 50% 42%, rgba(255,255,255,.08), rgba(255,255,255,.02) 58%, transparent 60%); box-shadow: inset 0 0 80px rgba(230,211,160,.08), 0 0 80px rgba(197,161,90,.07); animation: float 6s ease-in-out infinite; }
.hero-emblem svg { width: 92%; height: 92%; }
.forensic-orbit { position: absolute; border: 1px solid rgba(230,211,160,.18); border-radius: 50%; }
.orbit-1 { width: 92%; height: 92%; animation: spin 30s linear infinite; }
.orbit-2 { width: 74%; height: 74%; border-style: dashed; animation: spin 20s linear infinite reverse; }
.data-chip { position: absolute; display: flex; align-items: center; gap: 9px; padding: 10px 14px; border: 1px solid rgba(255,255,255,.12); border-radius: 999px; background: rgba(9,20,35,.72); backdrop-filter: blur(12px); color: #e4e8ee; font-size: .82rem; box-shadow: 0 15px 35px rgba(0,0,0,.22); }
.data-chip span { width: 7px; height: 7px; border-radius: 50%; background: var(--gold-light); box-shadow: 0 0 12px var(--gold); }
.chip-a { left: 5%; top: 20%; }
.chip-b { right: 0; top: 44%; }
.chip-c { left: 18%; bottom: 12%; }
.scroll-cue { position: absolute; left: 50%; bottom: 28px; width: 28px; height: 42px; border: 1px solid rgba(255,255,255,.22); border-radius: 999px; transform: translateX(-50%); }
.scroll-cue span { position: absolute; left: 50%; top: 9px; width: 4px; height: 4px; margin-left: -2px; border-radius: 50%; background: var(--gold-light); animation: scrollDot 1.8s ease-in-out infinite; }

.split-intro { display: grid; grid-template-columns: .85fr 1.15fr; gap: 70px; align-items: center; }
.section-heading h2 { margin: 0; font-size: clamp(2.4rem, 5vw, 4.8rem); color: var(--ink); }
.section-heading > p:last-child { margin: 18px 0 0; color: var(--muted); max-width: 700px; }
.section-dark .section-heading h2, .section-forensic .section-heading h2, .contact-section .section-heading h2 { color: var(--white); }
.section-heading.centered { text-align: center; max-width: 760px; margin: 0 auto 48px; }
.section-heading.centered > p:last-child { margin-inline: auto; }
.muted-title { font-family: Georgia, "Times New Roman", serif; font-size: 1.2rem; color: var(--muted); }
.statement-card { position: relative; padding: 36px 40px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); box-shadow: var(--shadow); overflow: hidden; }
.statement-card::after { content: "LF"; position: absolute; right: 20px; bottom: -18px; color: rgba(10,20,36,.035); font-family: Georgia, serif; font-size: 9rem; line-height: 1; }
.statement-line { display: block; width: 64px; height: 3px; margin-bottom: 24px; background: linear-gradient(90deg, var(--gold), transparent); }
.statement-card p { position: relative; z-index: 1; margin: 0; font-family: Georgia, serif; font-size: clamp(1.5rem, 2.3vw, 2.15rem); line-height: 1.35; color: var(--ink); }

.card-grid { display: grid; gap: 18px; }
.law-grid { grid-template-columns: repeat(3, 1fr); }
.service-card { position: relative; min-height: 190px; padding: 30px; border-radius: var(--radius); background: var(--white); border: 1px solid var(--line); overflow: hidden; transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease; }
.service-card::after { content: ""; position: absolute; right: -45px; bottom: -60px; width: 150px; height: 150px; border-radius: 50%; border: 1px solid rgba(197,161,90,.18); }
.service-card:hover { transform: translateY(-6px); border-color: rgba(197,161,90,.5); box-shadow: var(--shadow); }
.card-index { display: block; color: #9a7a3f; font-size: .76rem; font-weight: 900; letter-spacing: .15em; }
.service-card h3 { margin: 60px 0 0; font-family: Georgia, serif; font-size: 1.55rem; font-weight: 500; color: var(--ink); }
.service-card-more { background: var(--ink); border-color: var(--ink); }
.service-card-more h3 { color: var(--white); }
.service-card-more .card-index { color: var(--gold-light); }

.section-forensic { position: relative; background: linear-gradient(145deg, #0a1424, #11233b); color: var(--white); overflow: hidden; }
.section-forensic::before { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at 85% 20%, rgba(197,161,90,.11), transparent 25%), radial-gradient(circle at 10% 90%, rgba(95,132,173,.13), transparent 25%); }
.section-forensic .container { position: relative; z-index: 1; }
.section-forensic .section-heading > p:last-child { color: #b7c0cc; }
.forensic-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-top: 46px; }
.forensic-card { min-height: 180px; padding: 26px; border: 1px solid rgba(255,255,255,.1); border-radius: 18px; background: rgba(255,255,255,.035); backdrop-filter: blur(8px); transition: transform .25s ease, background .25s ease, border-color .25s ease; }
.forensic-card:hover { transform: translateY(-5px); background: rgba(255,255,255,.06); border-color: rgba(230,211,160,.35); }
.forensic-dot { width: 10px; height: 10px; display: block; border: 2px solid var(--gold-light); border-radius: 50%; box-shadow: 0 0 16px rgba(230,211,160,.28); }
.forensic-card h3 { margin: 40px 0 6px; font-family: Georgia, serif; font-size: 1.45rem; font-weight: 500; }
.forensic-card p { margin: 0; color: #aeb8c6; font-size: .9rem; }
.forensic-more { background: linear-gradient(145deg, rgba(197,161,90,.12), rgba(255,255,255,.035)); }

.services-summary { background: var(--paper-2); }
.summary-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.summary-panel { position: relative; min-height: 360px; padding: 46px; border: 1px solid var(--line); border-radius: 26px; background: var(--white); overflow: hidden; }
.summary-panel h2 { max-width: 470px; margin: 70px 0 18px; font-size: clamp(2.2rem, 4vw, 4rem); color: var(--ink); }
.summary-panel p:last-child { max-width: 520px; margin: 0; color: var(--muted); }
.summary-number { position: absolute; right: 28px; top: 15px; color: rgba(10,20,36,.06); font-family: Georgia, serif; font-size: 7rem; line-height: 1; }
.dark-panel { background: var(--ink); border-color: var(--ink); color: var(--white); }
.dark-panel h2 { color: var(--white); }
.dark-panel p:last-child { color: #b9c1cb; }
.dark-panel .summary-number { color: rgba(255,255,255,.05); }

.experience-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; max-width: 920px; margin: 0 auto; }
.experience-card { position: relative; min-height: 280px; padding: 38px; border-radius: 24px; background: var(--white); border: 1px solid var(--line); box-shadow: 0 16px 50px rgba(10,20,36,.07); overflow: hidden; }
.experience-card::after { content: ""; position: absolute; width: 190px; height: 190px; right: -60px; bottom: -70px; border: 1px solid rgba(197,161,90,.22); border-radius: 50%; }
.experience-icon { width: 56px; height: 56px; display: grid; place-items: center; border-radius: 16px; background: var(--ink); color: var(--gold-light); font-family: Georgia, serif; font-size: 1.4rem; }
.experience-card p { margin: 56px 0 8px; color: #8a692e; font-size: .78rem; text-transform: uppercase; letter-spacing: .15em; font-weight: 900; }
.experience-card h3 { margin: 0; font-family: Georgia, serif; font-size: clamp(1.7rem, 3vw, 2.5rem); font-weight: 500; color: var(--ink); }

.institutional-band { padding: 78px 0; color: var(--white); text-align: center; background: linear-gradient(105deg, #0a1424 0%, #132640 52%, #0a1424 100%); border-top: 1px solid rgba(255,255,255,.05); border-bottom: 1px solid rgba(255,255,255,.05); }
.institutional-band p { margin: 0 0 12px; color: var(--gold-light); font-size: .78rem; font-weight: 900; text-transform: uppercase; letter-spacing: .14em; }
.institutional-band h2 { margin: 0; font-size: clamp(2.2rem, 5vw, 4.6rem); }
.institutional-band span { display: block; margin-top: 18px; color: #bcc6d2; }

.schedule-wrap { display: grid; grid-template-columns: .8fr 1.2fr; gap: 60px; align-items: center; }
.schedule-card { display: flex; align-items: center; gap: 28px; padding: 34px; border-radius: 22px; background: var(--ink); color: var(--white); box-shadow: var(--shadow); }
.schedule-card p { margin: 0 0 4px; color: #b7c0cc; }
.schedule-card strong { font-family: Georgia, serif; font-size: clamp(2rem, 4vw, 3.5rem); font-weight: 500; color: var(--gold-light); }
.clock { position: relative; flex: 0 0 82px; width: 82px; height: 82px; border: 2px solid rgba(230,211,160,.55); border-radius: 50%; }
.clock::after { content: ""; position: absolute; left: 50%; top: 50%; width: 7px; height: 7px; border-radius: 50%; background: var(--gold-light); transform: translate(-50%, -50%); }
.clock-hour, .clock-minute { position: absolute; left: 50%; top: 50%; width: 2px; background: var(--gold-light); transform-origin: bottom center; border-radius: 4px; }
.clock-hour { height: 22px; transform: translate(-50%, -100%) rotate(35deg); }
.clock-minute { height: 29px; transform: translate(-50%, -100%) rotate(118deg); }

.contact-section { position: relative; color: var(--white); background: #08111f; overflow: hidden; }
.contact-section::before { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at 75% 50%, rgba(197,161,90,.13), transparent 28%); }
.contact-grid { position: relative; z-index: 1; display: grid; grid-template-columns: 1fr 1fr; gap: 70px; align-items: center; }
.contact-copy h2 { margin: 0; font-size: clamp(2.5rem, 5vw, 4.9rem); }
.contact-copy > p:last-child { color: #b8c2ce; }
.contact-actions { display: grid; gap: 14px; }
.phone-card { display: grid; grid-template-columns: 1fr auto; gap: 4px 18px; align-items: center; padding: 24px 26px; border-radius: 18px; border: 1px solid rgba(255,255,255,.12); background: rgba(255,255,255,.045); transition: transform .2s ease, border-color .2s ease, background .2s ease; }
.phone-card:hover { transform: translateX(5px); background: rgba(255,255,255,.07); border-color: rgba(230,211,160,.42); }
.phone-card small { color: #9eabb9; }
.phone-card strong { font-size: clamp(1.4rem, 3vw, 2rem); letter-spacing: .02em; }
.phone-card span { grid-column: 2; grid-row: 1 / 3; color: var(--gold-light); font-weight: 900; }

.site-footer { padding: 70px 0 22px; color: #cbd3dd; background: #050c16; }
.footer-grid { display: grid; grid-template-columns: 1.4fr .8fr .8fr 1fr; gap: 34px; }
.footer-grid h3 { margin: 0 0 14px; color: var(--white); font-size: .9rem; text-transform: uppercase; letter-spacing: .1em; }
.footer-grid p { color: #8f9baa; }
.footer-grid > div > a:not(.brand) { display: block; width: fit-content; margin: 8px 0; color: #aeb8c5; }
.footer-grid > div > a:hover { color: var(--gold-light); }
.footer-brand .brand-text small { white-space: normal; }
.footer-bottom { margin-top: 50px; padding-top: 22px; border-top: 1px solid rgba(255,255,255,.08); font-size: .8rem; color: #758292; }
.back-to-top { position: fixed; right: 18px; bottom: 18px; z-index: 70; width: 46px; height: 46px; border: 1px solid rgba(255,255,255,.14); border-radius: 50%; background: rgba(8,17,31,.9); color: var(--gold-light); font-size: 1.25rem; box-shadow: 0 12px 30px rgba(0,0,0,.2); cursor: pointer; opacity: 0; visibility: hidden; transform: translateY(10px); transition: .2s ease; }
.back-to-top.visible { opacity: 1; visibility: visible; transform: translateY(0); }

/* El contenido siempre es visible. Las animaciones solo se activan cuando main.js carga correctamente. */
.reveal { opacity: 1; transform: none; }
.js .reveal { opacity: 0; transform: translateY(24px); transition: opacity .75s ease, transform .75s ease; }
.js .reveal.is-visible { opacity: 1; transform: translateY(0); }

@keyframes float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes scrollDot { 0% { transform: translateY(0); opacity: 0; } 30% { opacity: 1; } 100% { transform: translateY(16px); opacity: 0; } }

@media (max-width: 980px) {
  .site-nav { position: fixed; top: 82px; left: 0; right: 0; min-height: calc(100svh - 82px); padding: 34px 24px; background: rgba(7,15,27,.98); display: grid; align-content: start; gap: 8px; transform: translateX(100%); transition: transform .25s ease; }
  .site-nav.open { transform: translateX(0); }
  .site-nav a { padding: 16px 4px; border-bottom: 1px solid rgba(255,255,255,.08); font-size: 1.08rem; }
  .nav-cta { margin-top: 10px; text-align: center; border: 1px solid rgba(230,211,160,.38) !important; }
  .menu-toggle { display: block; }
  .menu-toggle.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .menu-toggle.active span:nth-child(2) { opacity: 0; }
  .menu-toggle.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
  .hero-grid { grid-template-columns: 1fr; gap: 44px; }
  .hero-copy { text-align: center; }
  .hero-copy .hero-lead { margin-inline: auto; }
  .hero-actions, .hero-contact { justify-content: center; }
  .hero-visual { max-width: 520px; width: 100%; margin: 0 auto; }
  .split-intro, .schedule-wrap, .contact-grid { grid-template-columns: 1fr; gap: 34px; }
  .law-grid { grid-template-columns: repeat(2, 1fr); }
  .forensic-grid { grid-template-columns: repeat(2, 1fr); }
  .summary-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
  .container { width: min(100% - 28px, 1160px); }
  .section { padding: 74px 0; }
  .nav-wrap { height: 72px; }
  .site-nav { top: 72px; min-height: calc(100svh - 72px); }
  .brand-mark { width: 38px; height: 38px; }
  .brand-text strong { font-size: 1rem; }
  .brand-text small { max-width: 205px; white-space: normal; font-size: .61rem; }
  .hero { min-height: auto; padding: 124px 0 82px; }
  .hero h1 { font-size: clamp(2.75rem, 14vw, 4.3rem); }
  .hero-actions { display: grid; }
  .btn { width: 100%; }
  .hero-contact { font-size: .94rem; }
  .hero-contact span { display: none; }
  .hero-contact a { width: 100%; }
  .hero-visual { aspect-ratio: 1 / .9; }
  .chip-a { left: 0; top: 12%; }
  .chip-b { right: 0; top: 48%; }
  .chip-c { left: 8%; bottom: 4%; }
  .data-chip { padding: 8px 11px; font-size: .72rem; }
  .law-grid, .forensic-grid, .experience-grid { grid-template-columns: 1fr; }
  .service-card { min-height: 150px; }
  .service-card h3 { margin-top: 36px; }
  .forensic-card { min-height: 155px; }
  .summary-panel { min-height: 320px; padding: 32px 26px; }
  .summary-panel h2 { margin-top: 80px; }
  .experience-card { min-height: 240px; padding: 30px; }
  .schedule-card { align-items: flex-start; padding: 26px; gap: 20px; }
  .clock { flex-basis: 66px; width: 66px; height: 66px; }
  .phone-card { grid-template-columns: 1fr; }
  .phone-card span { grid-column: 1; grid-row: auto; margin-top: 8px; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { margin-top: 34px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .reveal { opacity: 1; transform: none; }
}
