/* Rafa la Jirafa: el sitio se ve como el app. Los valores salen de design/tokens.json.
   Papel menta liso, listas planas con una línea fina, títulos grandes, un solo botón relleno por pantalla.
   La personalidad vive en Rafa: su burbuja (el único guijarro), su letra y el cuello que sube. */

@font-face { font-family: "DynaPuff"; font-weight: 400 700; font-display: swap; src: url(/fuentes/dynapuff-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "DynaPuff"; font-weight: 400 700; font-display: swap; src: url(/fuentes/dynapuff-latin-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Zen Maru Gothic"; font-weight: 500; font-display: swap; src: url(/fuentes/zenmaru-500-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Zen Maru Gothic"; font-weight: 500; font-display: swap; src: url(/fuentes/zenmaru-500-latin-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Zen Maru Gothic"; font-weight: 700; font-display: swap; src: url(/fuentes/zenmaru-700-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Zen Maru Gothic"; font-weight: 700; font-display: swap; src: url(/fuentes/zenmaru-700-latin-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }

:root {
  --papel: #F1F8F4;
  --tinta: #17302A;
  --tinta-suave: #5A736C;
  --linea: rgba(23,48,42,.12);
  --linea-fuerte: rgba(23,48,42,.22);
  --superficie: rgba(255,255,255,.55);
  --superficie-alta: rgba(255,255,255,.82);
  --hoja: #2F9E6B;
  --hoja-tinta: #1B6F48;
  --hoja-suave: rgba(47,158,107,.16);
  --foco: #7F8FE6;
  --foco-tinta: #4453B0;
  --foco-suave: rgba(127,143,230,.18);
  --miel: #F2C46D;
  --miel-tinta: #8A5A33;
  --miel-suave: rgba(242,196,109,.22);
  --cielo-tinta: #1D6796;
  --arena-tinta: #735A33;
  --sobre-acento: #0F2A22;
  --hoja-clara: #9BD6B5;
  --hoja-oscura: #5FB88A;
  --marca: "DynaPuff", ui-rounded, system-ui, sans-serif;
  --rafa: "Zen Maru Gothic", ui-rounded, system-ui, sans-serif;
  --texto: ui-rounded, "SF Pro Rounded", -apple-system, BlinkMacSystemFont, system-ui, "Segoe UI", Roboto, sans-serif;
  --burbuja: 8px 30px 30px 30px;
  --sombra: 0 6px 16px rgba(23,48,42,.14);
  --e1: 4px; --e2: 8px; --e3: 12px; --e4: 16px; --e5: 24px; --e6: 32px; --e7: 48px;
  --muelle: cubic-bezier(.2,.8,.2,1);
}

html { color-scheme: light; scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
* { box-sizing: border-box; }
body { margin: 0; background: var(--papel); color: var(--tinta); font: 17px/1.5 var(--texto); -webkit-font-smoothing: antialiased; overflow-x: hidden; }
img, svg { max-width: 100%; height: auto; display: block; }
a { color: var(--hoja-tinta); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: .15em; }
:focus-visible { outline: 2px solid var(--hoja); outline-offset: 3px; border-radius: 4px; }
p { margin: 0; max-width: 60ch; }
ul, ol { margin: 0; padding: 0; list-style: none; }
h1, h2, h3 { margin: 0; text-wrap: balance; }
h1 { font-family: var(--marca); font-weight: 500; font-size: clamp(42px, 7vw, 72px); line-height: 1.02; letter-spacing: -.005em; }
h2 { font-weight: 700; font-size: clamp(28px, 4.2vw, 38px); line-height: 1.12; letter-spacing: -.01em; }
h3 { font-weight: 700; font-size: 20px; line-height: 1.3; }
.suave { color: var(--tinta-suave); }
.etiqueta { font-size: 12px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--tinta-suave); }
.grande { font-size: clamp(19px, 2.2vw, 22px); line-height: 1.45; }
.contenedor { width: 100%; max-width: 1040px; margin: 0 auto; padding-left: max(16px, env(safe-area-inset-left)); padding-right: max(16px, env(safe-area-inset-right)); }
section { padding: clamp(48px, 8vw, 96px) 0 0; }
section > .contenedor > h2 { margin-bottom: var(--e4); }
section > .contenedor > .intro { margin-bottom: var(--e6); }

/* Cabecera: la marca con nombre a la izquierda (DynaPuff solo aquí y en el título), enlaces en verde */
.cabecera { position: sticky; top: 0; z-index: 10; background: color-mix(in srgb, var(--papel) 86%, transparent); backdrop-filter: blur(22px) saturate(140%); -webkit-backdrop-filter: blur(22px) saturate(140%); border-bottom: 1px solid var(--linea); }
.cabecera .contenedor { display: flex; align-items: center; justify-content: space-between; gap: var(--e4); min-height: 60px; }
.marca { display: inline-flex; align-items: center; gap: 10px; color: var(--tinta); font-family: var(--marca); font-weight: 600; font-size: 22px; line-height: 1; }
.marca:hover { text-decoration: none; }
.marca img { width: 38px; height: 28px; }
.menu { display: flex; gap: clamp(12px, 2.5vw, 28px); font-weight: 600; font-size: 15px; }
.menu a { color: var(--hoja-tinta); white-space: nowrap; }
@media (max-width: 640px) { .menu a:not(.siempre) { display: none; } }

/* Botones: solo dos estilos, como en el app. Un relleno por pantalla */
.pildora { display: inline-flex; align-items: center; justify-content: center; min-height: 46px; padding: 0 22px; border-radius: 999px; font: 600 17px/1 var(--texto); color: var(--sobre-acento); background: var(--hoja); border: 0; cursor: pointer; text-decoration: none; transition: transform .18s var(--muelle), filter .18s; }
.pildora:hover { text-decoration: none; filter: brightness(1.04); }
.pildora:active { transform: scale(.98); }
.pildora.texto { background: transparent; color: var(--hoja-tinta); padding: 0 12px; }
.pildora.texto:hover { text-decoration: underline; text-underline-offset: .15em; }
.pildora.foco { background: var(--foco); }
.acciones { display: flex; flex-wrap: wrap; align-items: center; gap: var(--e2) var(--e4); }
@media (max-width: 520px) { .acciones .pildora:not(.texto) { width: 100%; } }

/* Rafa y su burbuja: Rafa siempre a la izquierda, la cola de la burbuja hacia su boca */
.habla { display: flex; align-items: flex-start; gap: var(--e3); }
.habla > img, .habla > svg { flex: none; width: 76px; }
.habla.grande > img, .habla.grande > svg { width: 112px; }
.burbuja { font-family: var(--rafa); font-weight: 500; font-size: 19px; line-height: 1.35; background: var(--superficie-alta); padding: 12px 16px; border-radius: var(--burbuja); margin-top: 14px; max-width: 34ch; }
.habla.grande .burbuja { font-size: clamp(20px, 2.4vw, 24px); margin-top: 22px; }
.burbuja q { quotes: '"' '"'; }

/* Listas planas: sin tarjeta ni borde, una línea fina bajo cada fila */
.lista > li { display: flex; gap: var(--e3); align-items: flex-start; padding: 14px 0; border-bottom: 1px solid var(--linea); }
.lista > li:first-child { border-top: 1px solid var(--linea); }
.lista.sin-tope > li:first-child { border-top: 0; }
.numero { flex: none; width: 26px; height: 26px; border-radius: 50%; background: var(--hoja-suave); color: var(--hoja-tinta); display: grid; place-items: center; font-weight: 800; font-size: 13px; margin-top: 1px; }
.numero.uno { background: var(--hoja); color: var(--sobre-acento); }
.casilla { flex: none; width: 26px; height: 26px; border-radius: 50%; border: 2px solid var(--hoja); background: transparent; margin-top: 0; cursor: pointer; appearance: none; -webkit-appearance: none; position: relative; transition: background .18s, transform .32s var(--muelle); }
.casilla:checked { background: var(--hoja); }
.casilla:active { transform: scale(1.12); }
.lista .texto-fila { flex: 1; }
.lista .hecha .texto-fila { color: var(--tinta-suave); text-decoration: line-through; text-decoration-color: var(--linea-fuerte); }
.lista small { display: block; font-size: 14px; color: var(--tinta-suave); }
.lista small b { font-weight: 600; color: var(--miel-tinta); }

/* Teléfonos: la captura tal cual, con la esquina del iPhone y una línea fina. Sin sombra: es papel */
.tel { width: 100%; max-width: 320px; border-radius: 11.5%/5.3%; border: 1px solid var(--linea-fuerte); background: var(--papel); }
.tel.chico { max-width: 260px; }

/* Portada */
.portada { padding-top: clamp(40px, 7vw, 88px); }
.portada .contenedor { display: grid; gap: var(--e6); align-items: center; grid-template-columns: 1fr; }
.portada .texto { display: grid; gap: var(--e5); }
.portada .texto .etiqueta { margin-bottom: calc(-1 * var(--e3)); }
.portada .tel { justify-self: center; }
@media (min-width: 860px) { .portada .contenedor { grid-template-columns: 1.15fr .85fr; gap: var(--e7); } .portada .tel { max-width: 340px; } }

/* Cómo funciona: los tres pasos y la demo */
.demo { display: grid; gap: var(--e5); align-items: start; margin-top: var(--e6); padding: var(--e5) 0 0; border-top: 1px solid var(--linea); }
/* Como en Inicio: Rafa a la izquierda en una columna de alto fijo, y su burbuja a la derecha, a la altura de la boca, que sube con ella */
.demo .escenario { position: relative; display: flex; align-items: flex-start; gap: var(--e3); padding-bottom: var(--e6); }
.demo .escena { width: 160px; height: 352px; flex: none; }
.demo .escenario .burbuja { position: absolute; top: 0; left: calc(160px + var(--e3)); right: 0; margin: 0; max-width: none; }
@media (min-width: 720px) {
  .demo { grid-template-columns: 1fr 1fr; gap: var(--e6); align-items: end; }
  .demo .escenario { padding-bottom: 0; }
  .demo .escena { width: 200px; height: 440px; }
  .demo .escenario .burbuja { left: calc(200px + var(--e3)); }
}
.demo .escena svg { width: 100%; height: 100%; overflow: visible; }
.demo .pie { font-size: 14px; color: var(--tinta-suave); margin-top: var(--e3); }
.demo .ojo { transform-box: fill-box; transform-origin: center; }
@media (prefers-reduced-motion: no-preference) {
  .demo.viva .ojo { animation: parpadeo 4.6s infinite; }
  .demo.viva .ojo.derecho { animation-delay: .04s; }
  .demo .hojita { transition: opacity .32s, transform .6s var(--muelle); }
  .demo .hojita.comida { opacity: 0; transform: scale(.4) rotate(40deg); transform-box: fill-box; transform-origin: center; }
}
@keyframes parpadeo { 0%, 93%, 100% { transform: scaleY(1); } 96% { transform: scaleY(.08); } }

/* Lo que hace: cada pilar es texto y una captura, alternando lados */
.pilares { display: grid; gap: clamp(40px, 6vw, 72px); }
.pilar { display: grid; gap: var(--e5); align-items: center; }
.pilar .cuerpo { display: grid; gap: var(--e3); }
.pilar .cuerpo h3 { font-size: clamp(22px, 3vw, 28px); }
.pilar .tel { justify-self: center; }
@media (min-width: 760px) {
  .pilar { grid-template-columns: 1fr 300px; gap: var(--e7); }
  .pilar:nth-child(even) .tel { order: -1; }
}

/* Rafa, las caras */
.caras { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: var(--e4); margin-top: var(--e5); }
.caras figure { margin: 0; display: grid; gap: var(--e1); justify-items: center; text-align: center; }
.caras img { width: 120px; }
.caras figcaption { font-size: 14px; color: var(--tinta-suave); }
.frases { display: grid; gap: var(--e4); margin-top: var(--e6); }
@media (min-width: 720px) { .frases { grid-template-columns: 1fr 1fr; } }

/* Gratis y Pro */
.planes { display: grid; gap: var(--e6); }
@media (min-width: 720px) { .planes { grid-template-columns: 1fr 1fr; } }
.planes h3 { margin-bottom: var(--e2); }
.planes .lista > li { padding: 10px 0; }
.punto { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--hoja); margin-top: 9px; }
.punto.foco { background: var(--foco); }

/* Preguntas: filas que se abren, como un menú del sistema */
.preguntas details { border-bottom: 1px solid var(--linea); }
.preguntas details:first-child { border-top: 1px solid var(--linea); }
.preguntas summary { cursor: pointer; list-style: none; padding: 16px 0; font-weight: 600; font-size: 18px; display: flex; justify-content: space-between; gap: var(--e4); }
.preguntas summary::-webkit-details-marker { display: none; }
.preguntas summary::after { content: "+"; color: var(--hoja-tinta); font-weight: 400; font-size: 24px; line-height: 1; flex: none; }
.preguntas details[open] summary::after { content: "–"; }
.preguntas details > p { padding: 0 0 18px; }

/* Pie */
.pie-sitio { margin-top: clamp(64px, 10vw, 120px); padding: var(--e6) 0 calc(var(--e6) + env(safe-area-inset-bottom)); border-top: 1px solid var(--linea); font-size: 15px; color: var(--tinta-suave); }
.pie-sitio .contenedor { display: grid; gap: var(--e4); }
.pie-sitio nav { display: flex; flex-wrap: wrap; gap: var(--e2) var(--e5); font-weight: 600; }
.pie-sitio .glifo { width: 34px; opacity: .9; }

/* Páginas de texto (privacidad, soporte, prensa) */
.documento { padding-top: clamp(32px, 5vw, 56px); }
.documento .contenedor { max-width: 720px; display: grid; gap: var(--e5); }
.documento h1 { font-family: var(--texto); font-weight: 700; font-size: clamp(32px, 5vw, 44px); letter-spacing: -.01em; }
.documento h2 { font-size: 24px; margin-top: var(--e4); }
.documento h3 { font-size: 18px; }
.documento p, .documento li { max-width: 68ch; }
.documento ul.viñetas, .documento ol.numerada { display: grid; gap: var(--e2); padding-left: 22px; }
.documento ul.viñetas { list-style: disc; }
.documento ol.numerada { list-style: decimal; }
.documento li::marker { color: var(--hoja); font-weight: 700; }
.documento table { border-collapse: collapse; width: 100%; font-size: 15px; }
.documento th, .documento td { text-align: left; padding: 10px 12px 10px 0; border-bottom: 1px solid var(--linea); vertical-align: top; }
.documento th { font-size: 12px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--tinta-suave); }
.documento .fecha { font-size: 14px; color: var(--tinta-suave); }
.descargas { display: grid; gap: var(--e3); grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.descargas a { display: grid; gap: var(--e2); justify-items: center; padding: var(--e4); border: 1px solid var(--linea); border-radius: 18px; text-align: center; font-size: 14px; font-weight: 600; }
.descargas a img { height: 72px; width: auto; }
.descargas a:hover { text-decoration: none; background: var(--superficie); }
.muestra-color { width: 100%; height: 44px; border-radius: 999px; border: 1px solid var(--linea); }

.visualmente-oculto { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
