/* =============================================================
   Bautista Gabarro — web design
   Archetype 05 (Mouse-Reactive Gradient), toned for local businesses:
   near-black ground, warm white ink, ONE signal-orange accent.
   ============================================================= */

/* =============================================================
   1. Tokens
   ============================================================= */
:root {
  --bg:      #0b0b0c;
  --bg-2:    #141415;
  --ink:     #f4f2ee;
  --mute:    #a39f98;
  --line:    rgba(244, 242, 238, 0.12);
  --line-2:  rgba(244, 242, 238, 0.22);
  --accent:  #ff6a2b;

  /* hero gradient blobs — one warm family + one cool counterweight */
  --blob-1:  #ff6a2b;
  --blob-2:  #b8321f;
  --blob-3:  #34297d;

  --serif: "Instrument Serif", Georgia, "Times New Roman", serif;
  --sans:  "Geist", "Segoe UI", system-ui, -apple-system, sans-serif;
  --mono:  "Geist Mono", ui-monospace, "SF Mono", Consolas, monospace;

  --gutter: clamp(1.25rem, 4vw, 3rem);
  --max:    1240px;

  --ease-out:  cubic-bezier(0.16, 1, 0.3, 1);
  --ease-soft: cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* =============================================================
   2. Reset & base
   ============================================================= */
*, *::before, *::after { box-sizing: border-box; margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}
img, svg, video { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
p { text-wrap: pretty; }
h1, h2, h3 { font-weight: 400; line-height: 1.02; text-wrap: balance; }
::selection { background: var(--accent); color: var(--bg); }

/* [hidden] must always win (gotcha A.15) */
[hidden] { display: none !important; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
  border-radius: 4px;
}

/* =============================================================
   3. Utilities
   ============================================================= */
.skip-link {
  position: fixed; top: -100px; left: 1rem; z-index: 9999;
  padding: .6rem 1rem; border-radius: 8px;
  background: var(--ink); color: var(--bg); font-weight: 500;
}
.skip-link:focus { top: 1rem; }

.wrap {
  width: 100%;
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.eyebrow {
  font-family: var(--mono);
  font-size: .75rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--mute);
}
.eyebrow .dot { color: var(--accent); }

/* =============================================================
   4. Header
   ============================================================= */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  transition: background .4s var(--ease-soft), border-color .4s var(--ease-soft);
  border-bottom: 1px solid transparent;
}
.site-header.is-solid {
  background: rgba(11, 11, 12, .82);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom-color: var(--line);
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .site-header.is-solid { background: var(--bg); }
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem;
  height: 64px;
}
.brand {
  font-family: var(--serif);
  font-size: 1.35rem;
  letter-spacing: -.01em;
  white-space: nowrap;
}
.brand em { font-style: italic; color: var(--accent); }
.nav { display: flex; align-items: center; gap: 1.5rem; }
.nav-links { display: none; gap: 1.5rem; list-style: none; padding: 0; }
.nav-links a, .lang {
  font-size: .9rem;
  color: var(--mute);
  transition: color .25s var(--ease-out);
}
.nav-links a:hover, .lang:hover { color: var(--ink); }
.lang {
  font-family: var(--mono);
  font-size: .8rem;
  letter-spacing: .08em;
  padding: .35rem .7rem;
  border: 1px solid var(--line-2);
  border-radius: 999px;
}

/* =============================================================
   5. Hero
   ============================================================= */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex; align-items: flex-end;
  padding-block: 7rem 4rem;
  overflow: hidden;
  isolation: isolate;
}
.hero-gradient {
  position: absolute; inset: 0; z-index: -1;
  pointer-events: none;
  background: var(--bg);
}
.blob {
  position: absolute;
  width: 62vmax; height: 62vmax;
  left: 50%; top: 50%;
  margin: -31vmax 0 0 -31vmax;
  border-radius: 50%;
  filter: blur(90px);
  opacity: .5;
  will-change: transform;
}
.blob-1 { background: radial-gradient(circle, var(--blob-1) 0%, transparent 62%); }
.blob-2 { background: radial-gradient(circle, var(--blob-2) 0%, transparent 62%); opacity: .45; }
.blob-3 { background: radial-gradient(circle, var(--blob-3) 0%, transparent 62%); opacity: .55; }
/* static resting positions (used as-is with reduced motion / no JS) */
.blob-1 { transform: translate3d(18vw, -8vh, 0); }
.blob-2 { transform: translate3d(-22vw, 14vh, 0); }
.blob-3 { transform: translate3d(4vw, 30vh, 0); }

/* grain keeps the blur from banding on cheap screens */
.hero-gradient::after {
  content: ""; position: absolute; inset: 0;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)' opacity='.5'/></svg>");
  opacity: .08;
  mix-blend-mode: overlay;
}

.hero-inner { display: flex; flex-direction: column; gap: 1.75rem; }
.hero-title {
  font-family: var(--serif);
  font-size: clamp(3.1rem, 10.5vw, 10.5rem);
  letter-spacing: -.03em;
  line-height: .94;
}
.hero-title em { font-style: italic; color: var(--accent); }
.hero-sub {
  max-width: 34rem;
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
  color: rgba(244, 242, 238, .82);
}
.hero-cta { display: flex; flex-wrap: wrap; gap: .75rem; }

/* =============================================================
   6. Buttons
   ============================================================= */
.btn {
  display: inline-flex; align-items: center; gap: .6rem;
  padding: .9rem 1.4rem;
  border-radius: 999px;
  font-weight: 500;
  font-size: .98rem;
  transition: transform .35s var(--ease-out), background .3s var(--ease-out),
              color .3s var(--ease-out), box-shadow .35s var(--ease-out);
}
.btn-primary { background: var(--ink); color: var(--bg); }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 28px -12px rgba(255, 106, 43, .55); }
.btn-ghost { border: 1px solid var(--line-2); }
.btn-ghost:hover { background: rgba(244, 242, 238, .06); transform: translateY(-2px); }
.btn .arrow { transition: transform .35s var(--ease-out); }
.btn:hover .arrow { transform: translateX(3px); }

/* =============================================================
   7. Sections
   ============================================================= */
.section { padding-block: clamp(5rem, 11vw, 9rem); }
.section + .section { border-top: 1px solid var(--line); }
.section-head {
  display: flex; flex-direction: column; gap: 1rem;
  margin-bottom: clamp(2.5rem, 6vw, 4rem);
}
.section-title {
  font-family: var(--serif);
  font-size: clamp(2.4rem, 6vw, 4.8rem);
  letter-spacing: -.025em;
}
.section-title em { font-style: italic; color: var(--accent); }
.section-lede { max-width: 36rem; color: var(--mute); font-size: 1.05rem; }

/* --- Manifesto --- */
.manifesto p {
  max-width: 60ch;
  font-family: var(--serif);
  font-size: clamp(1.6rem, 3.4vw, 2.7rem);
  line-height: 1.22;
  letter-spacing: -.012em;
}
.manifesto p + p { margin-top: 1.5rem; }
.manifesto .hl { color: var(--accent); font-style: italic; }

/* --- Numbers --- */
.numbers {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0;
  border-top: 1px solid var(--line);
}
.number {
  padding: 2rem 1.25rem 2rem 0;
  border-bottom: 1px solid var(--line);
}
.number:nth-child(odd) { padding-right: 1.25rem; border-right: 1px solid var(--line); }
.number:nth-child(even) { padding-left: 1.25rem; }
.number-value {
  font-family: var(--serif);
  font-size: clamp(3.4rem, 8vw, 6rem);
  line-height: 1;
  letter-spacing: -.03em;
  font-variant-numeric: tabular-nums;
}
.number-value .unit { color: var(--accent); }
.number-label { margin-top: .75rem; color: var(--mute); max-width: 18rem; }

/* --- Process --- */
.steps {
  list-style: none; padding: 0;
  display: grid; gap: 0;
  counter-reset: step;
}
.step {
  counter-increment: step;
  display: grid;
  grid-template-columns: 1fr;
  gap: .6rem;
  padding-block: 2rem;
  border-top: 1px solid var(--line);
}
.step:last-child { border-bottom: 1px solid var(--line); }
.step::before {
  content: counter(step, decimal-leading-zero);
  font-family: var(--mono);
  font-size: .8rem;
  letter-spacing: .12em;
  color: var(--accent);
}
.step h3 { font-family: var(--serif); font-size: clamp(1.8rem, 3.6vw, 2.6rem); letter-spacing: -.02em; }
.step p { color: var(--mute); max-width: 34rem; }

/* --- Included --- */
.included {
  list-style: none; padding: 0;
  display: grid; gap: 0;
}
.included li {
  display: grid;
  grid-template-columns: 1fr;
  gap: .35rem;
  padding-block: 1.5rem;
  border-top: 1px solid var(--line);
}
.included li:last-child { border-bottom: 1px solid var(--line); }
.included strong { font-weight: 500; font-size: 1.1rem; }
.included-group { margin: 3rem 0 1rem; }
.included-group:first-of-type { margin-top: 0; }
.included span { color: var(--mute); }

/* --- Work (accordion rows, hover invert) --- */
.work-list { border-top: 1px solid var(--line); }
.work-item { border-bottom: 1px solid var(--line); }
.work-item > summary {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 1rem;
  padding: 1.6rem .25rem;
  cursor: pointer;
  transition: background .35s var(--ease-out), color .35s var(--ease-out),
              padding .35s var(--ease-out);
}
.work-item > summary::-webkit-details-marker { display: none; }
.work-name {
  font-family: var(--serif);
  font-size: clamp(2rem, 5.2vw, 4rem);
  letter-spacing: -.025em;
  line-height: 1.05;
}
.work-meta { display: block; margin-top: .35rem; color: var(--mute); font-size: .98rem; transition: color .35s var(--ease-out); }
.work-status {
  font-family: var(--mono);
  font-size: .72rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  padding: .35rem .7rem;
  border: 1px solid var(--line-2);
  border-radius: 999px;
  white-space: nowrap;
}
.work-item > summary:hover,
.work-item[open] > summary {
  background: var(--ink);
  color: var(--bg);
  padding-inline: 1rem;
}
.work-item > summary:hover .work-meta,
.work-item[open] > summary .work-meta { color: #4d4a45; }
.work-item > summary:hover .work-status,
.work-item[open] > summary .work-status { border-color: rgba(11, 11, 12, .3); }

.work-panel {
  display: grid; gap: 1.5rem;
  padding: 1.75rem .25rem 2.25rem;
}
/* PLACEHOLDER frame: replaced by the real screenshot later */
.shot {
  aspect-ratio: 16 / 10;
  border-radius: 14px;
  border: 1px dashed var(--line-2);
  background:
    linear-gradient(135deg, rgba(255, 106, 43, .07), transparent 55%),
    var(--bg-2);
  display: grid; place-items: center;
  overflow: hidden;
}
.shot img { width: 100%; height: 100%; object-fit: cover; }
.shot-label { font-family: var(--mono); font-size: .75rem; letter-spacing: .12em; text-transform: uppercase; color: var(--mute); }
.work-text { color: var(--mute); max-width: 34rem; }
.work-note {
  margin: .75rem 0 1.25rem;
  font-family: var(--mono);
  font-size: .72rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--mute);
}

/* --- FAQ --- */
.faq { border-top: 1px solid var(--line); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-item > summary {
  list-style: none;
  display: flex; justify-content: space-between; align-items: center; gap: 1.5rem;
  padding: 1.4rem 0;
  font-size: clamp(1.05rem, 1.8vw, 1.25rem);
  cursor: pointer;
}
.faq-item > summary::-webkit-details-marker { display: none; }
.faq-item > summary::after {
  content: "+";
  font-family: var(--mono);
  color: var(--accent);
  font-size: 1.3rem;
  transition: transform .35s var(--ease-out);
}
.faq-item[open] > summary::after { transform: rotate(45deg); }
.faq-item p { padding-bottom: 1.5rem; color: var(--mute); max-width: 44rem; }

/* --- Contact --- */
.contact { padding-bottom: clamp(4rem, 8vw, 6rem); }
.contact-title {
  font-family: var(--serif);
  font-size: clamp(3rem, 9vw, 8rem);
  letter-spacing: -.03em;
  margin-bottom: 2rem;
}
.contact-mail {
  display: inline-block;
  font-family: var(--serif);
  font-size: clamp(1.5rem, 4.6vw, 3.6rem);
  letter-spacing: -.02em;
  line-height: 1.15;
  word-break: break-word;
  background-image: linear-gradient(var(--accent), var(--accent));
  background-size: 0% 2px;
  background-position: 0 100%;
  background-repeat: no-repeat;
  transition: background-size .6s var(--ease-out), color .3s var(--ease-out);
}
.contact-mail:hover { background-size: 100% 2px; color: var(--accent); }
.contact-lines {
  display: grid; gap: 1.25rem;
  margin-top: 2.75rem;
  padding-top: 2rem;
  border-top: 1px solid var(--line);
}
.contact-line { display: flex; flex-direction: column; gap: .3rem; }
.contact-line a { font-size: 1.15rem; transition: color .25s var(--ease-out); }
.contact-line a:hover { color: var(--accent); }
.contact-line .actions { display: flex; flex-wrap: wrap; gap: .5rem 1.25rem; }

/* --- Footer --- */
.site-footer { border-top: 1px solid var(--line); padding-block: 2rem 2.5rem; }
.footer-inner {
  display: flex; flex-wrap: wrap; gap: .75rem 1.5rem;
  justify-content: space-between;
  font-size: .88rem; color: var(--mute);
}
.footer-links { display: flex; flex-wrap: wrap; gap: 1.25rem; }
.footer-links a { text-decoration: underline; text-underline-offset: 3px; }
.footer-links a:hover { color: var(--ink); }

/* =============================================================
   8. Reveal (only when JS is running — content never depends on it)
   ============================================================= */
.js-reveal .reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .9s var(--ease-out), transform .9s var(--ease-out);
}
.js-reveal .reveal.is-in { opacity: 1; transform: none; }

/* =============================================================
   9. Responsive (mobile-first)
   ============================================================= */
@media (min-width: 720px) {
  .nav-links { display: flex; }
  .numbers { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .number { border-right: 1px solid var(--line); padding: 2.25rem 1.5rem; }
  .number:nth-child(odd), .number:nth-child(even) { padding: 2.25rem 1.5rem; }
  .number:first-child { padding-left: 0; }
  .number:last-child { border-right: 0; }
  .step { grid-template-columns: 5rem minmax(0, 1fr) minmax(0, 1.2fr); align-items: baseline; gap: 2rem; }
  .included li { grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: 2rem; align-items: baseline; }
  .contact-lines { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (min-width: 960px) {
  .work-panel { grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); align-items: end; }
}

/* =============================================================
   10. Reduced motion — only the intrusive bits
   ============================================================= */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .blob { will-change: auto; }
  .js-reveal .reveal { transition-duration: .01ms; }
}

/* =============================================================
   PÁGINAS LEGALES — añadir al final de styles.css
   Son documentos: se leen. Sin animaciones, sin efectos, sin splash.
   Usan los mismos tokens del arquetipo para que no parezcan otra web.
   ============================================================= */

.legal-page {
  background: var(--bg);
  color: var(--ink, var(--cream));
}

.legal-header {
  max-width: 780px;
  margin: 0 auto;
  padding: 2rem 1.5rem 0;
}

.legal-back {
  font-size: .9rem;
  opacity: .75;
  transition: opacity .25s var(--ease-out);
}
.legal-back:hover { opacity: 1; }

.legal-wrap {
  max-width: 780px;          /* medida de lectura: ~70 caracteres */
  margin: 0 auto;
  padding: 2.5rem 1.5rem 4rem;
}

.legal-wrap h1 {
  font-size: clamp(1.9rem, 4vw, 2.6rem);
  margin-bottom: .5rem;
}

.legal-updated {
  font-size: .85rem;
  opacity: .65;
  margin-bottom: 2.5rem;
}

.legal-wrap h2 {
  font-size: clamp(1.15rem, 2.2vw, 1.4rem);
  margin: 2.5rem 0 .75rem;
  line-height: 1.25;
}

.legal-wrap h3 {
  font-size: 1.02rem;
  margin: 1.75rem 0 .5rem;
  opacity: .9;
}

.legal-wrap p,
.legal-wrap li {
  font-size: 1rem;           /* nunca por debajo de 16px: tiene que leerse */
  line-height: 1.7;
  margin-bottom: .9rem;
}

.legal-wrap ul {
  padding-left: 1.2rem;
  margin-bottom: 1.2rem;
}
.legal-wrap li { margin-bottom: .5rem; }

.legal-wrap a {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.legal-footer {
  max-width: 780px;
  margin: 0 auto;
  padding: 2rem 1.5rem 3rem;
  border-top: 1px solid rgba(128,128,128,.22);
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: space-between;
  font-size: .88rem;
  opacity: .8;
}
.legal-footer nav { display: flex; gap: 1.25rem; }

/* -------------------------------------------------------------
   Enlaces legales en el FOOTER DEL SITIO (no en las páginas legales).
   Mínimo 14px y contraste real: un enlace legal en gris diminuto sobre
   gris es un incumplimiento con estilo. Ver 16-legal-por-pais.md §5.
   ------------------------------------------------------------- */
.site-footer .legal-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  font-size: .875rem;        /* = 14px, el mínimo */
  opacity: .85;              /* nunca por debajo de .7 */
}
.site-footer .legal-links a { text-decoration: underline; text-underline-offset: 3px; }
.site-footer .legal-links a:hover { opacity: 1; }

/* Segundo idioma de la página legal: se ve como título principal, pero es h2
   (una página, un solo h1). */
.legal-wrap .legal-h1 {
  font-size: clamp(1.9rem, 4vw, 2.6rem);
  margin: 0 0 .5rem;
}
.legal-wrap h1, .legal-wrap .legal-h1 { font-family: var(--serif); letter-spacing: -.02em; }
.legal-wrap a { color: var(--accent); }
