/* =============================================================
   Nexa LegalTech — corporate site (functional baseline; design to refine later).
   Navy + warm light, Manrope + Newsreader italic accents. Distinct from the demos.
   ============================================================= */

/* 1. Tokens */
:root {
  --bg: #f6f5f1;
  --paper: #ffffff;
  --ink: #0f1a2b;
  --ink-soft: #2c3a50;
  --ink-mute: #5d6878;
  --accent: #2f6fed;
  --accent-warm: #c9a15a;
  --line: rgba(15, 26, 43, 0.12);
  --navy: #0f1a2b;
  --sans: "Manrope", "Segoe UI", system-ui, -apple-system, sans-serif;
  --serif: "Newsreader", Georgia, serif;
  --gutter: clamp(1rem, 4vw, 2.5rem);
  --radius: 16px;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

/* 2. Reset & base */
*, *::before, *::after { box-sizing: border-box; margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 5rem; }
body { font-family: var(--sans); font-size: 16px; line-height: 1.6; color: var(--ink); background: var(--bg); -webkit-font-smoothing: antialiased; overflow-x: clip; }
img, svg { display: block; max-width: 100%; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }
a { color: inherit; text-decoration: none; }
p { text-wrap: pretty; }
h1, h2, h3 { line-height: 1.1; letter-spacing: -0.02em; text-wrap: balance; font-weight: 800; }
em { font-family: var(--serif); font-style: italic; font-weight: 500; letter-spacing: 0; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

/* 3. Utilities */
.container { width: 100%; max-width: 1180px; margin-inline: auto; padding-inline: var(--gutter); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: fixed; top: -100px; left: 1rem; padding: .6rem 1rem; background: var(--ink); color: #fff; z-index: 9999; border-radius: 8px; }
.skip-link:focus { top: 1rem; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* 4. Typography */
.kicker { font-size: .78rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); margin-bottom: .9rem; }
h2 { font-size: clamp(1.8rem, 1.2rem + 2.6vw, 2.9rem); }
h3 { font-size: 1.2rem; }
.lead { font-size: 1.1rem; color: var(--ink-soft); margin-top: 1rem; }

/* 5. Components */
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: .8rem 1.4rem; border-radius: 12px; background: var(--accent); color: #fff; font-weight: 700; transition: transform .3s var(--ease-out), background .3s; }
.btn:hover { transform: translateY(-2px); background: #1f5bd6; }
.btn-ghost { background: transparent; color: #fff; box-shadow: inset 0 0 0 1px rgba(255,255,255,.4); }
.btn-ghost:hover { background: rgba(255,255,255,.1); }
.btn-small { min-height: 42px; padding: .5rem 1rem; font-size: .92rem; }

/* 6. Sections */
.nav { position: sticky; top: 0; z-index: 50; background: rgba(15, 26, 43, .92); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); color: #fff; }
.nav-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 66px; }
.brand { display: inline-flex; align-items: center; gap: .6rem; }
.brand-mark { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; background: var(--accent); color: #fff; font-weight: 800; }
.brand-name { font-weight: 800; font-size: 1.1rem; letter-spacing: -.01em; }
.brand-name span { font-weight: 500; opacity: .75; margin-left: .15rem; }
.nav-toggle { display: inline-grid; place-items: center; width: 46px; height: 46px; border-radius: 12px; box-shadow: inset 0 0 0 1px rgba(255,255,255,.25); }
.nav-toggle-bars, .nav-toggle-bars::before, .nav-toggle-bars::after { display: block; width: 18px; height: 2px; background: #fff; position: relative; transition: transform .3s var(--ease-out); }
.nav-toggle-bars::before, .nav-toggle-bars::after { content: ""; position: absolute; left: 0; }
.nav-toggle-bars::before { top: -6px; }
.nav-toggle-bars::after { top: 6px; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars::before { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars::after { transform: translateY(-6px) rotate(-45deg); }
.nav-menu { position: absolute; top: 100%; left: 0; right: 0; display: none; flex-direction: column; padding: .5rem var(--gutter) 1.25rem; background: var(--navy); }
.nav-menu.is-open { display: flex; }
.nav-menu a:not(.btn) { padding: .75rem 0; border-bottom: 1px solid rgba(255,255,255,.1); }
.nav-menu .btn { margin-top: .9rem; align-self: flex-start; }
.no-js .nav-menu { position: static; display: flex; }

.hero { background: radial-gradient(90% 120% at 85% 0%, rgba(47,111,237,.35), transparent 60%), var(--navy); color: #fff; padding: clamp(3rem, 9vw, 7rem) 0; }
.hero .kicker { color: var(--accent-warm); }
.hero-title { font-size: clamp(2.2rem, 1.2rem + 4.6vw, 4.4rem); max-width: 18ch; margin-bottom: 1.3rem; }
.hero-title em { color: var(--accent-warm); }
.hero-sub { font-size: clamp(1.02rem, .95rem + .4vw, 1.22rem); color: #c9d2e0; max-width: 40rem; margin-bottom: 2rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-bottom: 2.5rem; }
.hero-points { list-style: none; padding: 0; display: grid; gap: .7rem; color: #dfe5ee; font-size: .95rem; }
.hero-points li::before { content: "✓"; color: var(--accent-warm); font-weight: 800; margin-right: .6rem; }

.section { padding: clamp(3.5rem, 8vw, 6.5rem) 0; }
.section-alt { background: #eceae3; }
.section-dark { background: var(--navy); color: #e8edf5; }
.section-dark .kicker { color: var(--accent-warm); }
.section-dark em { color: var(--accent-warm); }
.section-head { margin-bottom: clamp(2rem, 4vw, 3rem); max-width: 48rem; }
.section-note { margin-top: .8rem; color: var(--ink-mute); font-size: .92rem; }

.cards { display: grid; gap: 1rem; }
.card { background: var(--paper); border-radius: var(--radius); padding: 1.5rem; box-shadow: inset 0 0 0 1px var(--line); }
.card h3 { margin-bottom: .5rem; }
.card p { color: var(--ink-soft); }

.catalog { display: grid; gap: 1rem; }
.cat-card { background: var(--paper); border-radius: var(--radius); padding: 1.6rem; box-shadow: inset 0 0 0 1px var(--line); display: grid; gap: .6rem; align-content: start; }
.cat-card img { border-radius: 10px; aspect-ratio: 16 / 10; object-fit: cover; width: 100%; height: auto; }
.cat-tipo { font-size: .75rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); }
.cat-card p { color: var(--ink-soft); }
.cat-card ul { list-style: none; padding: 0; display: grid; gap: .3rem; font-size: .93rem; }
.cat-card li::before { content: "—"; color: var(--accent); margin-right: .5rem; }
.cat-demo { justify-self: start; margin-top: .4rem; font-weight: 700; color: var(--accent); border-bottom: 2px solid currentColor; }
.cat-vacio { color: var(--ink-mute); }

.steps { list-style: none; padding: 0; display: grid; gap: 1rem; }
.steps li { background: var(--paper); border-radius: var(--radius); padding: 1.4rem; box-shadow: inset 0 0 0 1px var(--line); }
.step-num { display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; background: var(--ink); color: #fff; font-weight: 800; margin-bottom: .8rem; }
.steps h3 { margin-bottom: .35rem; }
.steps p { color: var(--ink-soft); }

.split { display: grid; gap: clamp(2rem, 5vw, 4rem); align-items: start; }
.checks { list-style: none; padding: 0; display: grid; gap: 1rem; }
.checks li { padding-left: 2rem; position: relative; color: #d3dbe7; }
.checks li::before { content: "✓"; position: absolute; left: 0; top: 0; color: var(--accent-warm); font-weight: 800; }

.form { display: grid; gap: 1rem; background: var(--paper); padding: clamp(1.25rem, 3vw, 2rem); border-radius: var(--radius); box-shadow: inset 0 0 0 1px var(--line); }
.form-row { display: grid; gap: 1rem; }
.form label { display: grid; gap: .35rem; font-size: .9rem; font-weight: 600; }
.form input, .form select, .form textarea { width: 100%; min-height: 48px; padding: .7rem .85rem; font: inherit; color: var(--ink); background: #fff; border: 1px solid rgba(15,26,43,.22); border-radius: 10px; }
.form textarea { resize: vertical; }
.form .check { display: flex; align-items: flex-start; gap: .6rem; font-weight: 400; }
.form .check input { width: 20px; min-height: 20px; margin-top: .2rem; flex: none; accent-color: var(--accent); }
.form .check a { color: var(--accent); text-decoration: underline; }
.form .btn { justify-self: start; }
.form-status { min-height: 1.4em; font-size: .95rem; }
.form-status.is-ok, .form-flash.is-ok { color: #1e7a4c; }
.form-status.is-error, .form-flash.is-error { color: #b3261e; }
.form-flash { margin-top: 1rem; font-weight: 600; }

.footer { background: var(--navy); color: #b8c2d2; padding: 2.5rem 0; font-size: .92rem; }
.footer-grid { display: grid; gap: .8rem; }
.footer .brand-name { color: #fff; }
.footer-links { display: flex; flex-wrap: wrap; gap: 1.2rem; }
.footer-links a { text-decoration: underline; text-underline-offset: 3px; }

/* Legal pages */
.legal { padding: clamp(2.5rem, 6vw, 4.5rem) 0; }
.legal h1 { font-size: clamp(1.8rem, 1.3rem + 2vw, 2.6rem); margin-bottom: 1.5rem; }
.legal h2 { font-size: 1.25rem; margin: 2rem 0 .6rem; }
.legal p { color: var(--ink-soft); max-width: 48rem; margin-bottom: .8rem; }
.pending { background: #fff4d6; border-radius: 10px; padding: .8rem 1rem; color: #7a5a00 !important; }

/* 7. Effects */
.js .reveal { opacity: 0; transform: translateY(16px); transition: opacity .8s var(--ease-out), transform .8s var(--ease-out); }
.js .reveal.is-in { opacity: 1; transform: none; }

/* 8. Responsive */
@media (min-width: 540px) {
  .form-row { grid-template-columns: 1fr 1fr; }
  .hero-points { grid-template-columns: repeat(3, auto); gap: 1.5rem; }
}
@media (min-width: 720px) {
  .cards { grid-template-columns: 1fr 1fr; }
  .catalog { grid-template-columns: 1fr 1fr; }
  .steps { grid-template-columns: 1fr 1fr; }
}
@media (min-width: 960px) {
  .nav-toggle { display: none; }
  .nav-menu { position: static; display: flex; flex-direction: row; align-items: center; gap: 1.6rem; padding: 0; background: none; }
  .nav-menu a:not(.btn) { padding: .3rem 0; border: 0; opacity: .85; }
  .nav-menu a:not(.btn):hover { opacity: 1; }
  .nav-menu .btn { margin-top: 0; }
  .cards { grid-template-columns: repeat(3, 1fr); }
  .catalog { grid-template-columns: repeat(3, 1fr); }
  .steps { grid-template-columns: repeat(5, 1fr); }
  .split { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1fr 1.5fr auto; align-items: center; }
}

/* 9. Reduced motion: no intrusive effects in this baseline */
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
