/* Santi Gastro · hoja de estilo única del sitio
   Identidad del canal: papel crema, tinta azul oscura, coral para temas de colon.
   Fuentes locales (sin servicios externos): Fraunces, Nunito y Caveat. */

@font-face { font-family: 'Fraunces'; font-weight: 400 800; font-display: swap; src: url('/assets/fonts/fraunces-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: 'Fraunces'; font-weight: 400 800; font-display: swap; src: url('/assets/fonts/fraunces-latin-ext.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Nunito'; font-weight: 300 900; font-display: swap; src: url('/assets/fonts/nunito-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: 'Nunito'; font-weight: 300 900; font-display: swap; src: url('/assets/fonts/nunito-latin-ext.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Caveat'; font-weight: 400 700; font-display: swap; src: url('/assets/fonts/caveat-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: 'Caveat'; font-weight: 400 700; font-display: swap; src: url('/assets/fonts/caveat-latin-ext.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }

:root {
  color-scheme: light;
  --papel: #F6EFE6;
  --papel-hondo: #EFE4D6;
  --tinta: #1F2A44;
  --tinta-suave: #4A5470;
  --neutro: #A99F93;          /* gris cálido: aro de la foto y detalles generales */
  /* Color de acento: neutro en todo el sitio; cada tema lo cambia con una clase en <body> */
  --acento: #8C8378;
  --acento-fuerte: #4A5470;
  --ambar: #EF9F27;
  --verde: #1D9E75;
  --renglon: rgba(31, 42, 68, 0.07);
  --ancho-texto: 40rem;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background-color: var(--papel);
  color: var(--tinta);
  font-family: 'Nunito', system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-size: 1.125rem;
  line-height: 1.65;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--acento-fuerte); text-underline-offset: 0.18em; }
a:hover { color: var(--tinta); }
a:focus-visible { outline: 3px solid var(--ambar); outline-offset: 2px; border-radius: 4px; }

.salto { position: absolute; left: -999px; }
.salto:focus { left: 1rem; top: 1rem; background: var(--tinta); color: var(--papel); padding: 0.5rem 1rem; z-index: 10; }

.contenedor { width: 100%; max-width: 46rem; margin: 0 auto; padding: 0 1rem; }

/* ---------- Encabezado ---------- */
.cabecera { border-bottom: 2px solid var(--tinta); background: var(--papel); }
.cabecera .contenedor { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.6rem 1rem; padding-top: 0.8rem; padding-bottom: 0.8rem; }
.marca { display: flex; align-items: center; gap: 0.6rem; text-decoration: none; color: var(--tinta); }
.marca img, .marca svg { width: 44px; height: 44px; border-radius: 50%; border: 3px solid var(--neutro); flex-shrink: 0; }
.marca-texto { display: flex; flex-direction: column; }
.marca-lema { font-size: 0.85rem; font-weight: 700; color: var(--tinta-suave); line-height: 1.2; }
.marca-nombre { font-family: 'Fraunces', Georgia, serif; font-weight: 700; font-size: 1.15rem; line-height: 1.15; }
.menu { display: flex; align-items: center; gap: 0.5rem; }
.menu a { display: inline-flex; align-items: center; gap: 0.35rem; font-size: 0.9rem; font-weight: 800; color: var(--tinta); text-decoration: none; padding: 0.4rem 0.75rem; border: 2px solid var(--tinta); border-radius: 999px; white-space: nowrap; }
.menu a:hover { background: var(--tinta); color: var(--papel); }
.menu .menu-ig { background: var(--tinta); color: var(--papel); }
.menu .menu-ig:hover { background: var(--acento-fuerte); border-color: var(--acento-fuerte); }
@media (max-width: 30rem) {
  .menu { width: 100%; }
  .menu a { flex: 1; justify-content: center; }
}

/* ---------- Portada ---------- */
.presentacion { padding: 2rem 0 1.25rem; }
.presentacion h1 { font-family: 'Fraunces', Georgia, serif; font-weight: 700; font-size: clamp(1.9rem, 7vw, 2.6rem); line-height: 1.12; margin: 0 0 0.6rem; }
.presentacion p { margin: 0; color: var(--tinta-suave); }
.flecha-lado { display: none; }
.nota-mano { font-family: 'Caveat', cursive; font-size: 1.6rem; line-height: 1.2; color: var(--acento-fuerte); margin-top: 0.75rem !important; }

.lista { list-style: none; margin: 1rem 0 2.5rem; padding: 0; display: grid; gap: 1rem; }
.tarjeta { position: relative; display: grid; grid-template-columns: 7.5rem 1fr; gap: 1rem; align-items: start; background: #FFFAF3; border: 2px solid var(--tinta); border-radius: 14px; padding: 0.75rem; box-shadow: 4px 4px 0 var(--tinta); transition: transform 0.12s ease, box-shadow 0.12s ease; }
.tarjeta:hover { transform: translate(-2px, -2px); box-shadow: 6px 6px 0 var(--tinta); }
.tarjeta img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: 8px; }
.tarjeta h2 { font-family: 'Fraunces', Georgia, serif; font-size: 1.25rem; line-height: 1.2; margin: 0.35rem 0 0.3rem; }
.tarjeta h2 a { color: var(--tinta); text-decoration: none; }
.tarjeta h2 a::after { content: ""; position: absolute; inset: 0; border-radius: 14px; }
.tarjeta p { margin: 0; font-size: 0.95rem; line-height: 1.45; color: var(--tinta-suave); }
.tarjeta .fecha { font-size: 0.8rem; font-weight: 700; margin-top: 0.4rem; }

@media (min-width: 36rem) {
  .tarjeta { grid-template-columns: 10rem 1fr; padding: 1rem; }
  .tarjeta h2 { font-size: 1.45rem; }
}

/* ---------- Etiquetas ---------- */
.etiquetas { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.etiqueta { display: inline-block; font-size: 0.75rem; font-weight: 800; letter-spacing: 0.02em; line-height: 1; padding: 0.38rem 0.65rem; border-radius: 999px; color: #fff; }
.etiqueta-tema { background: var(--tinta); color: var(--papel); text-transform: uppercase; letter-spacing: 0.08em; border-radius: 6px; }
.etiqueta-todos { background: var(--verde); }
.etiqueta-salud { background: #2F6FB5; }

/* ---------- Artículo ---------- */
.articulo { padding: 1.75rem 0 1rem; }
.articulo-cabeza { border-bottom: 2px dashed var(--acento); padding-bottom: 1.25rem; margin-bottom: 1.5rem; }
.articulo h1 { font-family: 'Fraunces', Georgia, serif; font-weight: 700; font-size: clamp(2rem, 8vw, 2.9rem); line-height: 1.08; margin: 0.8rem 0 0.75rem; }
.bajada { font-size: 1.2rem; line-height: 1.5; color: var(--tinta-suave); margin: 0 0 1rem; }
.datos { font-size: 0.9rem; font-weight: 700; color: var(--tinta-suave); margin: 0; }

.cuerpo { max-width: var(--ancho-texto); }
.cuerpo h2 { font-family: 'Fraunces', Georgia, serif; font-size: 1.55rem; line-height: 1.2; margin: 2.25rem 0 0.6rem; }
.cuerpo h2::before { content: ""; display: block; width: 2.5rem; height: 5px; border-radius: 3px; background: var(--acento); margin-bottom: 0.6rem; }
.cuerpo p, .cuerpo ul { margin: 0 0 1rem; }
.cuerpo ul { padding-left: 1.25rem; }
.cuerpo li { margin-bottom: 0.45rem; }
.cuerpo li::marker { color: var(--acento-fuerte); }
.cuerpo sup { font-size: 0.7em; line-height: 0; font-weight: 700; }
.cuerpo sup a { text-decoration: none; padding: 0 0.1em; }

.aviso { background: #FFFAF3; border: 2px solid var(--tinta); border-left: 8px solid var(--ambar); border-radius: 10px; padding: 1rem 1.1rem; margin: 0 0 1.5rem; }
.aviso strong { display: block; font-family: 'Fraunces', Georgia, serif; font-size: 1.1rem; margin-bottom: 0.2rem; }
.aviso p { margin: 0; }

.resaltado { background: linear-gradient(transparent 55%, rgba(239, 159, 39, 0.45) 55%); padding: 0 0.1em; }

.cuadro { background: var(--papel-hondo); border-radius: 12px; padding: 1rem 1.1rem 0.3rem; margin: 0 0 1.25rem; }
.cuadro-titulo { font-family: 'Caveat', cursive; font-size: 1.55rem; line-height: 1.1; color: var(--acento-fuerte); margin: 0 0 0.4rem !important; }

.portada-reel { max-width: 15rem; margin: 0 auto 1.5rem; }
.portada-reel img { border-radius: 12px; border: 2px solid var(--tinta); box-shadow: 4px 4px 0 var(--tinta); }
.portada-reel figcaption { font-size: 0.85rem; text-align: center; margin-top: 0.6rem; color: var(--tinta-suave); }

.firma { display: flex; align-items: center; gap: 0.7rem; margin: 2.5rem 0 1.25rem; padding-top: 1rem; border-top: 1px solid rgba(31, 42, 68, 0.2); }
.firma img { width: 48px; height: 48px; border-radius: 50%; border: 2px solid var(--neutro); flex-shrink: 0; }
.firma p { margin: 0; font-size: 0.9rem; line-height: 1.35; color: var(--tinta-suave); }
.firma .nombre { font-family: 'Fraunces', Georgia, serif; font-weight: 700; font-size: 1rem; color: var(--tinta); text-decoration: none; }
.firma .nombre:hover { text-decoration: underline; }
.aviso-educativo { border-left-color: var(--verde); }

/* ---------- Sobre mí ---------- */
.perfil { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 2rem 0 0.5rem; }
.perfil img { width: 150px; height: 150px; border-radius: 50%; border: 5px solid var(--neutro); }
.perfil h1 { font-family: 'Fraunces', Georgia, serif; font-size: clamp(1.9rem, 7vw, 2.5rem); line-height: 1.1; margin: 1rem 0 0.3rem; }
.perfil p { margin: 0; color: var(--tinta-suave); font-weight: 700; }
.pendiente { background: rgba(239, 159, 39, 0.25); border: 2px dashed var(--ambar); border-radius: 8px; padding: 0.6rem 0.8rem; }

.referencias { max-width: var(--ancho-texto); margin-top: 2.5rem; padding-top: 1rem; border-top: 2px solid var(--tinta); }
.referencias h2 { font-family: 'Fraunces', Georgia, serif; font-size: 1.3rem; margin: 0 0 0.75rem; }
.referencias ol { padding-left: 1.5rem; margin: 0; font-size: 0.9rem; line-height: 1.5; }
.referencias li { margin-bottom: 0.6rem; overflow-wrap: anywhere; }
.referencias li:target { background: rgba(239, 159, 39, 0.3); border-radius: 4px; }

.volver { display: inline-block; margin: 2rem 0 0; font-weight: 700; }

/* ---------- Pie ---------- */
.pie { margin-top: 3rem; background: var(--tinta); color: var(--papel); padding: 1.75rem 0 2.25rem; font-size: 0.95rem; }
.pie p { margin: 0 0 0.6rem; }
.pie a { color: var(--papel); }
.pie .aviso-legal { font-weight: 700; }
.pie .pequeno { font-size: 0.8rem; opacity: 0.8; }

/* ---------- Colores por tema ---------- */
/* Temas de colon: coral, como en los videos. Un tema nuevo = una clase nueva aquí. */
.tema-colon { --acento: #E98572; --acento-fuerte: #C4545A; }
.publicaciones li { font-size: 0.98rem; line-height: 1.5; }

/* ---------- Columna lateral del artículo (solo computador) ---------- */
.lateral { display: none; }
.lateral-reel { margin: 0 0 1.5rem; }
.lateral-reel img { border-radius: 12px; border: 2px solid var(--tinta); box-shadow: 4px 4px 0 var(--tinta); }
.lateral-reel figcaption { font-size: 0.9rem; line-height: 1.45; margin-top: 0.75rem; color: var(--tinta-suave); }
.indice { background: #FFFAF3; border: 2px solid var(--tinta); border-radius: 12px; padding: 1rem 1.1rem; }
.indice-titulo { font-family: 'Caveat', cursive; font-size: 1.5rem; line-height: 1; color: var(--acento-fuerte); margin: 0 0 0.5rem; }
.indice ol { margin: 0; padding-left: 1.2rem; font-size: 0.92rem; line-height: 1.4; }
.indice li { margin-bottom: 0.4rem; }
.indice li::marker { color: var(--acento-fuerte); font-weight: 700; }
.indice a { color: var(--tinta); text-decoration: none; }
.indice a:hover { text-decoration: underline; }
.cuerpo h2, .referencias h2 { scroll-margin-top: 1.5rem; }

/* ---------- Versión de computador ---------- */
@media (min-width: 64rem) {
  body { font-size: 1.15rem; }
  .contenedor { max-width: 76rem; padding: 0 2.5rem; }

  /* Portada: presentación fija a la izquierda, artículos a la derecha */
  .portada-grid { display: grid; grid-template-columns: 21rem minmax(0, 1fr); gap: 4rem; align-items: start; }
  .portada-grid .presentacion { position: sticky; top: 2rem; padding-top: 3.5rem; }
  .portada-grid .presentacion h1 { font-size: 2.9rem; }
  .portada-grid .flecha-abajo { display: none; }
  .portada-grid .flecha-lado { display: inline; }
  .portada-grid .lista { margin-top: 3.5rem; grid-template-columns: repeat(auto-fill, minmax(19rem, 1fr)); gap: 1.75rem; }
  .portada-grid .tarjeta { grid-template-columns: 1fr; padding: 1rem; }
  .portada-grid .tarjeta img { aspect-ratio: 4 / 5; }
  .portada-grid .tarjeta h2 { font-size: 1.5rem; }

  /* Artículo: texto de lectura cómoda y columna lateral fija */
  .articulo { padding-top: 2.75rem; }
  .articulo-cabeza { max-width: 52rem; }
  .articulo-grid { display: grid; grid-template-columns: minmax(0, 42rem) 18rem; gap: 4rem; justify-content: space-between; }
  .lateral { display: block; position: sticky; top: 1.5rem; align-self: start; }
  .lateral-reel img { width: auto; max-height: min(34vh, 18rem); margin: 0 auto; }
  .lateral-reel figcaption { text-align: center; }

  /* Sobre mí: foto y nombre fijos a la izquierda */
  .sobre-grid { display: grid; grid-template-columns: 19rem minmax(0, 42rem); gap: 4rem; justify-content: center; align-items: start; }
  .sobre-grid .perfil { position: sticky; top: 2rem; padding-top: 3rem; }
  .sobre-grid .perfil img { width: 190px; height: 190px; }
  .sobre-grid .cuerpo { padding-top: 1.25rem; }
}
