/* ─────────────────────────────────────────────────────────────
   Onubia Pop para las páginas estáticas (demo, carteles, calculadora, vigilancia, landings de software).
   Mismos tokens y piezas que la web en React (src/index.css): papel crema, tinta, naranja de marca y confeti.
   ───────────────────────────────────────────────────────────── */
@font-face {
  font-family: 'Bricolage Grotesque';
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url('/fonts/bricolage-display-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('/fonts/jakarta-normal-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'Instrument Serif';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/instrument-serif-italic-latin.woff2') format('woff2');
}

:root {
  --paper: #FFF8EE;
  --white: #FFFFFF;
  --raised: #FFF0DC;
  --ink: #16130F;
  --steel: #48423A;
  --steel-dim: #6B6358;
  --signal: #C2410C;
  --pop: #FF5B14;
  --pop-hover: #FF7433;
  --lime: #C6F04D;
  --sun: #FFD23F;
  --sky: #AEB7FF;
  --focus: #5B6CFF;
  --rose: #FF94C9;
  --mint: #8DE4C0;
  --wa: #25D366;
  --display: 'Bricolage Grotesque', ui-sans-serif, system-ui, sans-serif;
  --body: 'Plus Jakarta Sans', ui-sans-serif, system-ui, sans-serif;
  --serif: 'Instrument Serif', Georgia, serif;
  --shadow: 4px 4px 0 0 var(--ink);
  --shadow-lg: 7px 7px 0 0 var(--ink);
}

*, *::before, *::after { box-sizing: border-box; }
/* Sin márgenes por defecto (especificidad cero: cualquier clase los puede poner) */
:where(h1, h2, h3, h4, p, figure, blockquote, dl, dd) { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img, svg { max-width: 100%; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }
::selection { background: var(--lime); color: var(--ink); }

/* Contenedor y secciones */
.wrap { max-width: 80rem; margin: 0 auto; padding: 0 20px; }
@media (min-width: 640px) { .wrap { padding: 0 32px; } }
.sec { position: relative; border-top: 2px solid var(--ink); padding: 72px 0; overflow: hidden; }
@media (min-width: 640px) { .sec { padding: 104px 0; } }
.sec-white { background: var(--white); }
.sec-lime { background: var(--lime); }
.sec-sun { background: var(--sun); }
.sec-sky { background: var(--sky); }
.sec-rose { background: var(--rose); }
.sec-mint { background: var(--mint); }
.sec-pop { background: var(--pop); }
.sec-ink { background: var(--ink); color: var(--paper); }
.dots {
  background-image: radial-gradient(rgba(22, 19, 15, 0.16) 1.3px, transparent 1.4px);
  background-size: 24px 24px;
}

/* Tipografía */
.display, h1.display, h2.display {
  font-family: var(--display);
  font-weight: 800;
  letter-spacing: -0.045em;
  line-height: 0.92;
  margin: 0;
}
.h1 { font-size: clamp(2.6rem, 6.4vw, 5.2rem); }
.h2 { font-size: clamp(2.2rem, 5.2vw, 4.2rem); }
.h3 { font-family: var(--display); font-weight: 800; font-size: 1.55rem; line-height: 1.02; letter-spacing: -0.03em; margin: 0; }
.lead { font-size: clamp(1.08rem, 1.6vw, 1.25rem); font-weight: 500; color: var(--steel); line-height: 1.6; max-width: 56ch; }
.muted { color: var(--steel); }
.small { font-size: 0.875rem; }
.center { text-align: center; }

/* Acento: una palabra en serif cursiva con trazo de rotulador detrás */
.acc {
  --hl: var(--lime);
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.01em;
  padding: 0 0.12em 0 0.06em;
  background-image: linear-gradient(transparent 52%, var(--hl) 52%, var(--hl) 90%, transparent 90%);
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}
.acc-sun { --hl: var(--sun); }
.acc-rose { --hl: var(--rose); }
.acc-sky { --hl: #B9C1FF; }
.acc-mint { --hl: var(--mint); }
.acc-pop { --hl: #FFB088; }
.sec-ink .acc { background-image: none; color: var(--hl); }
.sec-ink .acc-pop { --hl: #FF7A45; }

/* Etiqueta de sección */
.etq {
  display: inline-flex; align-items: center; gap: 0.5rem;
  color: var(--ink);
  border: 2px solid var(--ink); border-radius: 999px;
  background: var(--white);
  padding: 0.38rem 0.9rem;
  font-size: 0.78rem; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase;
  box-shadow: 2px 2px 0 0 var(--ink);
}

/* Botones «caramelo» */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.6rem;
  border: 2px solid var(--ink); border-radius: 999px;
  padding: 0.95rem 1.6rem;
  font-family: var(--body); font-weight: 800; font-size: 1rem; line-height: 1.1;
  color: var(--ink); background: var(--white);
  box-shadow: var(--shadow);
  transition: transform 0.18s ease, box-shadow 0.18s ease, background-color 0.2s;
  text-decoration: none; cursor: pointer;
  /* long labels wrap instead of spilling out of their card on phones */
  max-width: 100%; text-align: center; overflow-wrap: anywhere;
}
.btn:hover { transform: translate(-2px, -2px); box-shadow: 6px 6px 0 0 var(--ink); }
.btn:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 0 var(--ink); }
.btn:disabled { opacity: 0.55; cursor: not-allowed; transform: none; }
.btn-pop { background: var(--pop); }
.btn-pop:hover { background: var(--pop-hover); }
.btn-ink { background: var(--ink); color: var(--paper); }
.btn-wa { background: var(--wa); }
.btn-lime { background: var(--lime); }
.btn-sm { padding: 0.6rem 1.1rem; font-size: 0.9rem; }
.btn-lg { padding: 1.15rem 2rem; font-size: 1.1rem; }
.btn-block { width: 100%; }
.btns { display: flex; flex-wrap: wrap; gap: 14px; }

/* Tarjetas y pegatinas */
.card {
  background: var(--white);
  border: 2px solid var(--ink);
  border-radius: 24px;
  box-shadow: 6px 6px 0 0 var(--ink);
}
.card-pad { padding: 24px; }
@media (min-width: 640px) { .card-pad { padding: 32px; } }
.sticker {
  display: inline-flex; align-items: center; gap: 0.4rem;
  color: var(--ink);
  border: 2px solid var(--ink); border-radius: 999px;
  padding: 0.45rem 0.95rem;
  font-weight: 800; font-size: 0.92rem; line-height: 1.1;
  background: var(--white);
  box-shadow: 3px 3px 0 0 var(--ink);
  transform: rotate(var(--r, -3deg));
  white-space: nowrap;
}
.bg-lime { background: var(--lime); }
.bg-sun { background: var(--sun); }
.bg-sky { background: var(--sky); }
.bg-rose { background: var(--rose); }
.bg-mint { background: var(--mint); }
.bg-pop { background: var(--pop); }
.bg-white { background: var(--white); }
.chips { display: flex; flex-wrap: wrap; gap: 12px; padding: 0; margin: 0; list-style: none; }

/* Rejillas */
.grid { display: grid; gap: 22px; }
@media (min-width: 720px) { .grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1024px) { .grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } .grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 720px) and (max-width: 1023px) { .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Formularios */
.lbl { display: block; font-weight: 800; margin-bottom: 6px; }
.lbl small { font-weight: 600; color: var(--steel); }
.inp {
  width: 100%;
  background: var(--white);
  border: 2px solid var(--ink);
  border-radius: 14px;
  padding: 0.8rem 1rem;
  font: inherit; font-size: 1rem; color: var(--ink);
}
.inp::placeholder { color: var(--steel-dim); }
.inp:focus { outline: none; box-shadow: 0 0 0 4px rgba(91, 108, 255, 0.35); }
select.inp { appearance: none; -webkit-appearance: none; }
.hint { font-size: 0.85rem; font-weight: 500; color: var(--steel); margin-top: 6px; }

/* Preguntas frecuentes (details/summary) */
.faq { display: grid; gap: 14px; }
.faq details { background: var(--white); border: 2px solid var(--ink); border-radius: 20px; transition: box-shadow 0.2s; }
.faq details[open] { background: var(--lime); box-shadow: 5px 5px 0 0 var(--ink); }
.faq details:nth-child(2n)[open] { background: var(--sun); }
.faq details:nth-child(3n)[open] { background: var(--sky); }
.faq summary {
  list-style: none; cursor: pointer;
  display: flex; align-items: center; justify-content: space-between; gap: 18px;
  padding: 18px 22px;
  font-family: var(--display); font-weight: 800; font-size: 1.22rem; line-height: 1.15; letter-spacing: -0.02em;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; flex-shrink: 0;
  display: grid; place-items: center; width: 38px; height: 38px;
  border: 2px solid var(--ink); border-radius: 999px; background: var(--white);
  font-family: var(--body); font-size: 1.4rem; font-weight: 700; line-height: 1;
  transition: transform 0.25s;
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { margin: 0; padding: 0 22px 20px; font-weight: 500; line-height: 1.6; max-width: 66ch; }

/* Cabecera flotante (como la de la web) */
.pop-nav { position: sticky; top: 0; z-index: 40; padding: 12px 12px 0; }
.pop-nav-in {
  max-width: 80rem; margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  background: var(--white);
  border: 2px solid var(--ink); border-radius: 999px;
  padding: 8px 8px 8px 18px;
  box-shadow: 4px 4px 0 0 var(--ink);
}
.pop-logo { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; font-family: var(--display); font-weight: 800; font-size: 1.3rem; letter-spacing: -0.04em; }
.pop-logo img { width: 28px; height: 28px; }
.pop-links { display: none; gap: 26px; font-weight: 600; font-size: 0.95rem; }
.pop-links a { text-decoration: none; }
.pop-links a:hover { text-decoration: underline; text-underline-offset: 4px; }
@media (min-width: 900px) { .pop-links { display: flex; } }

/* Pie */
.pop-foot { background: var(--ink); color: var(--paper); border-top: 2px solid var(--ink); padding: 48px 0 40px; }
.pop-foot-in { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px; }
.pop-foot a { color: var(--paper); text-decoration: none; opacity: 0.85; }
.pop-foot a:hover { opacity: 1; text-decoration: underline; }
.pop-foot nav { display: flex; flex-wrap: wrap; gap: 18px; font-size: 0.95rem; }
.pop-foot .pop-logo { color: var(--paper); }

/* Movimiento: solo si el usuario no lo ha desactivado */
@keyframes pop-drift { 0%, 100% { transform: translateY(0) rotate(0); } 50% { transform: translateY(-8px) rotate(4deg); } }
.drift { animation: pop-drift 6s ease-in-out infinite; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .drift { animation: none; }
  .btn, .btn:hover { transition: none; transform: none; }
}

@media print {
  .pop-nav, .pop-foot, .no-print { display: none !important; }
}

/* Iconos en línea (trazos de lucide) */
.ico { width: 24px; height: 24px; flex-shrink: 0; }
.ibox { display: grid; place-items: center; width: 52px; height: 52px; flex-shrink: 0; border: 2px solid var(--ink); border-radius: 16px; background: var(--white); }
.wa-ico { width: 20px; height: 20px; flex-shrink: 0; }

/* Dos columnas: título a la izquierda, contenido a la derecha */
.split { display: grid; gap: 40px; }
@media (min-width: 1024px) { .split { grid-template-columns: 4fr 8fr; gap: 64px; } }
