/* =============================================================
   soyanita.com — portada. Misma paleta que las herramientas.
   1 Tokens · 2 Reset · 3 Utilidades · 4 Componentes · 5 Secciones
   6 Responsive · 7 Reduced-motion
   ============================================================= */

/* ---------- 1. Tokens ---------- */
:root {
  --bg:        #f6f6f3;
  --surface:   #ffffff;
  --surface-2: #f1f1ed;
  --ink:       #17171c;
  --ink-soft:  #52525e;
  --ink-mute:  #7c7c8a;
  --line:      #e2e2dc;
  --line-strong:#cfcfc7;
  --accent:      #1f6feb;
  --accent-deep: #1550b3;
  --accent-soft: #e8f0fe;

  --sans: "Manrope", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --r-sm: 8px; --r-md: 12px; --r-lg: 18px; --r-xl: 24px;
  --shadow-sm: 0 1px 2px rgba(20,20,30,.05), 0 1px 3px rgba(20,20,30,.04);
  --shadow-md: 0 4px 12px rgba(20,20,30,.06), 0 12px 32px rgba(20,20,30,.06);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --gutter: clamp(1rem, 4vw, 2.5rem);
  --maxw: 1060px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg:        #121216;
    --surface:   #1a1a20;
    --surface-2: #22222a;
    --ink:       #f2f2f0;
    --ink-soft:  #b6b6c2;
    --ink-mute:  #8b8b98;
    --line:      #2e2e38;
    --line-strong:#3d3d49;
    --accent:      #6ea8ff;
    --accent-deep: #94c0ff;
    --accent-soft: #1b2740;
    --shadow-sm: 0 1px 2px rgba(0,0,0,.4);
    --shadow-md: 0 4px 14px rgba(0,0,0,.45);
  }
}

/* ---------- 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.65;
  color: var(--ink); background: var(--bg);
  -webkit-font-smoothing: antialiased; overflow-x: clip;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
p { text-wrap: pretty; }
h1, h2, h3 { text-wrap: balance; line-height: 1.14; letter-spacing: -.022em; font-weight: 800; }
h1 { font-size: clamp(1.8rem, 5vw, 2.85rem); }
h2 { font-size: clamp(1.35rem, 3.2vw, 1.95rem); }
h3 { font-size: clamp(1.05rem, 2vw, 1.22rem); }
::selection { background: var(--accent); color: #fff; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }

/* ---------- 3. Utilidades ---------- */
.wrap { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--gutter); }
.wrap-narrow { max-width: 760px; }
.skip-link {
  position: fixed; top: -100px; left: 1rem; z-index: 999;
  padding: .6rem 1rem; background: var(--ink); color: var(--bg);
  border-radius: var(--r-sm); font-weight: 600;
}
.skip-link:focus { top: 1rem; }

/* ---------- 4. Componentes ---------- */
.site-header {
  position: sticky; top: 0; z-index: 40;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 3.75rem; }
.brand { display: inline-flex; align-items: center; gap: .55rem; font-weight: 800; letter-spacing: -.03em; }
.brand-mark { width: 24px; height: 24px; color: var(--accent); }
.brand-name { font-size: 1.12rem; }
.brand-dim { color: var(--ink-mute); font-weight: 600; }
.header-nav { display: none; gap: 1.4rem; font-size: .92rem; font-weight: 500; color: var(--ink-soft); }
.header-nav a:hover { color: var(--accent); }

.btn {
  display: inline-block; padding: .85rem 1.4rem; border-radius: var(--r-md);
  font-weight: 700; font-size: .97rem; border: 1px solid transparent;
  transition: transform .18s var(--ease-out), background-color .18s var(--ease-out);
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--accent); color: #fff; box-shadow: var(--shadow-md); }
.btn-primary:hover { background: var(--accent-deep); }
@media (prefers-color-scheme: dark) { .btn-primary { color: #0c1526; } }

/* ---------- 5. Secciones ---------- */
.hero { padding: clamp(2.2rem, 7vw, 4.5rem) 0 clamp(1.6rem, 4vw, 2.6rem); }
.eyebrow {
  font-size: .76rem; font-weight: 800; letter-spacing: .13em; text-transform: uppercase;
  color: var(--accent); margin-bottom: .7rem;
}
.hero-sub { margin-top: 1rem; font-size: clamp(1rem, 2vw, 1.14rem); color: var(--ink-soft); max-width: 60ch; }
.hero-cta { margin-top: 1.6rem; }

.section { padding: clamp(2rem, 5.5vw, 3.4rem) 0; }
.section-prose { background: var(--surface); border-block: 1px solid var(--line); }
.section-legal, .section-contacto { border-top: 1px solid var(--line); }

.tool {
  display: grid; gap: 1rem; margin-top: 1.5rem;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-xl); padding: clamp(1.2rem, 3vw, 1.8rem);
  box-shadow: var(--shadow-sm);
}
.tool-icon { width: 52px; height: 52px; color: var(--accent); }
.tool-body h3 { margin-bottom: .55rem; }
.tool-body h3 a { transition: color .18s var(--ease-out); }
.tool-body h3 a:hover { color: var(--accent); }
.tool-body p { color: var(--ink-soft); margin-bottom: .7rem; font-size: .95rem; }
.tool-go a { color: var(--accent); font-weight: 700; font-size: .95rem; }
.tool-go a:hover { text-decoration: underline; text-underline-offset: 3px; }
.mas { margin-top: 1.2rem; font-size: .9rem; color: var(--ink-mute); }
.mas a { color: var(--accent); font-weight: 600; }

.prose h2 { margin-bottom: .9rem; }
.prose h3 { margin-top: 1.9rem; margin-bottom: .5rem; }
.prose p { margin-bottom: .9rem; color: var(--ink-soft); max-width: 70ch; }
.prose strong { color: var(--ink); }

.faq {
  border: 1px solid var(--line); border-radius: var(--r-md);
  background: var(--surface); margin-bottom: .55rem; overflow: hidden;
}
.faq summary {
  cursor: pointer; list-style: none; padding: .9rem 2.4rem .9rem 1rem;
  font-weight: 700; font-size: .95rem; position: relative;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: 1rem; top: 50%; transform: translateY(-50%);
  font-size: 1.25rem; font-weight: 400; color: var(--ink-mute);
  transition: transform .25s var(--ease-out);
}
.faq[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq p { padding: 0 1rem 1rem; font-size: .9rem; color: var(--ink-soft); }
.faq p + p { padding-top: .5rem; }
.faq a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }

.section-contacto p { color: var(--ink-soft); }
.correo { margin: .8rem 0; }
.correo a {
  display: inline-block; font-size: clamp(1.05rem, 3vw, 1.35rem); font-weight: 800;
  color: var(--accent); padding: .5rem .9rem; border-radius: var(--r-md);
  background: var(--accent-soft);
}
.firma { margin-top: 1rem; font-size: .88rem; color: var(--ink-mute); }

.site-footer { border-top: 1px solid var(--line); padding: 2rem 0 2.6rem; background: var(--surface); }
.footer-inner { display: grid; gap: .7rem; text-align: center; }
.footer-brand { font-weight: 700; font-size: .9rem; }
.footer-nav { display: flex; flex-wrap: wrap; justify-content: center; gap: 1rem; font-size: .85rem; color: var(--ink-soft); }
.footer-nav a:hover { color: var(--accent); }

/* ---------- 6. Responsive ---------- */
@media (min-width: 720px) {
  .header-nav { display: flex; }
  .tool { grid-template-columns: 52px 1fr; gap: 1.4rem; align-items: start; }
  .footer-inner { grid-template-columns: 1fr auto; text-align: left; align-items: center; }
}

/* ---------- 7. Reduced-motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn:hover { transform: none; }
}

/* --- páginas legales independientes --- */
.legal-doc h1 { margin-bottom: .4rem; }
.legal-doc .actualizado { font-size: .82rem; color: var(--ink-mute); margin-bottom: 1.6rem; }
.legal-doc p { margin-bottom: .95rem; color: var(--ink-soft); }
.legal-doc strong { color: var(--ink); }
.legal-doc a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }
.legal-doc code { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: .92em; }
.volver { font-size: .87rem; font-weight: 600; margin-bottom: 1.2rem; }
.volver a { color: var(--ink-mute); text-decoration: none; }
.volver a:hover { color: var(--accent); }
.otra-pagina {
  margin-top: 2rem; padding-top: 1.2rem; border-top: 1px solid var(--line);
  font-size: .9rem;
}
.legal-lista { margin-top: .9rem; padding-left: 1.1rem; display: grid; gap: .5rem; }
.legal-lista li { color: var(--ink-soft); font-size: .93rem; }
.legal-lista a { color: var(--accent); font-weight: 700; }
