/*
 * Camino a Seúl: Hub
 * Basado en LittleLink (https://littlelink.io), © Seth Cottle, licencia MIT (ver LICENSE-littlelink).
 */

@font-face {
  font-family: "Fredoka";
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url("/fonts/fredoka-latin-variable.woff2") format("woff2");
}

/* Colores: bandera de Corea (azul, rojo) y negro
   –––––––––––––––––––––––––––––––––––––––––––––––––– */
:root {
  color-scheme: light dark;

  --fondo: #FBFAF7;
  --superficie: #FFFFFF;
  --texto: #141414;
  --texto-suave: #4A4A4A;
  --borde: #141414;
  --azul: #0047A0;
  --azul-texto: #FFFFFF;
  --rojo: #CD2E3A;
  --enlace: #0047A0;
  --foco: #0047A0;
  --marca: #000000;

  --espacio-xs: 0.5rem;
  --espacio-s: 1rem;
  --espacio-m: 1.5rem;
  --espacio-l: 2rem;
  --espacio-xl: 3rem;
  --radio: 0.875rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --fondo: #0F1012;
    --superficie: #1A1B1F;
    --texto: #F3F3F1;
    --texto-suave: #B8B8B8;
    --borde: #8A8A8A;
    --azul: #2E6BD1;
    --rojo: #FF6B76;
    --enlace: #8AB4FF;
    --foco: #8AB4FF;
    --marca: #FFFFFF;
  }
}

/* Reset mínimo (de LittleLink)
   –––––––––––––––––––––––––––––––––––––––––––––––––– */
*,
*::before,
*::after {
  box-sizing: border-box;
}

body,
h1,
h2,
p,
ul {
  margin: 0;
}

ul {
  padding: 0;
  list-style: none;
}

/* Que hidden gane siempre, aunque la clase defina display (p. ej. .boton). */
[hidden] {
  display: none !important;
}

img,
svg {
  display: block;
  max-width: 100%;
}

/* Base
   –––––––––––––––––––––––––––––––––––––––––––––––––– */
body {
  min-height: 100vh;
  background: var(--fondo);
  color: var(--texto);
  font-family: "Fredoka", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.5;
  -webkit-text-size-adjust: 100%;
}

/* Franja con los colores de la bandera */
body::before {
  content: "";
  display: block;
  height: 0.375rem;
  background: linear-gradient(90deg, var(--rojo) 0 50%, var(--azul) 50% 100%);
}

a {
  color: var(--enlace);
  text-underline-offset: 0.2em;
}

:focus-visible {
  outline: 3px solid var(--foco);
  outline-offset: 3px;
}

.contenedor {
  width: 100%;
  max-width: 30rem;
  margin: 0 auto;
  padding: var(--espacio-l) var(--espacio-s) 0;
}

/* Cabecera
   –––––––––––––––––––––––––––––––––––––––––––––––––– */
.cabecera {
  text-align: center;
  margin-bottom: var(--espacio-l);
}

/* Logo: el isotipo con el nombre debajo, en texto para que cambie con el modo */
.marca {
  margin-bottom: var(--espacio-m);
}

.logo {
  width: 9rem;
  height: auto;
  margin: 0 auto;
}

.marca__nombre {
  margin-top: var(--espacio-xs);
  font-size: 1.25rem;
  font-weight: 500;
  line-height: 1.2;
  color: var(--marca);
}

h1 {
  font-size: 2.25rem;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.01em;
}

.historia {
  margin-top: var(--espacio-xs);
  font-size: 1.125rem;
  color: var(--texto-suave);
}

.lema {
  margin-top: var(--espacio-xs);
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--rojo);
}

/* Botones
   –––––––––––––––––––––––––––––––––––––––––––––––––– */
.boton {
  display: flex;
  align-items: center;
  gap: 0.875rem;
  width: 100%;
  min-height: 3.5rem;
  padding: 0.75rem 1.125rem;
  border: 2px solid var(--borde);
  border-radius: var(--radio);
  background: var(--superficie);
  color: var(--texto);
  font: inherit;
  font-size: 1.0625rem;
  font-weight: 600;
  line-height: 1.25;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
  transition: transform 120ms ease, border-color 120ms ease;
}

.boton:hover {
  border-color: var(--azul);
}

.boton:active {
  transform: scale(0.98);
}

.boton small {
  display: block;
  margin-top: 0.125rem;
  font-size: 0.875rem;
  font-weight: 400;
  color: var(--texto-suave);
}

.icono {
  width: 1.5rem;
  height: 1.5rem;
  flex-shrink: 0;
}

.boton--principal {
  min-height: 4.5rem;
  margin-bottom: var(--espacio-m);
  border-color: var(--azul);
  background: var(--azul);
  color: var(--azul-texto);
  font-size: 1.1875rem;
  box-shadow: 0 0.375rem 0 0 color-mix(in srgb, var(--azul) 55%, #000);
}

.boton--principal:hover {
  border-color: var(--azul);
}

.boton--principal small {
  color: inherit;
}

.boton--principal .icono {
  width: 2rem;
  height: 2rem;
}

.boton--compacto {
  justify-content: center;
  width: auto;
  min-height: 3rem;
  margin: 0 auto;
  text-align: center;
}

.enlaces {
  display: grid;
  gap: 0.75rem;
}

/* Secciones
   –––––––––––––––––––––––––––––––––––––––––––––––––– */
.seccion {
  display: grid;
  gap: 0.75rem;
  margin-top: var(--espacio-xl);
  scroll-margin-top: var(--espacio-s);
}

h2 {
  font-size: 1.5rem;
  font-weight: 600;
  line-height: 1.2;
}

.titulo-icono {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.seccion > p {
  color: var(--texto-suave);
}

/* Yape */
.yape summary {
  list-style: none;
}

.yape summary::-webkit-details-marker {
  display: none;
}

.yape[open] summary {
  border-color: var(--azul);
}

.yape__panel {
  display: grid;
  gap: 0.75rem;
  margin-top: 0.75rem;
  padding: var(--espacio-m) var(--espacio-s);
  border-radius: var(--radio);
  background: var(--superficie);
  text-align: center;
}

.yape__numero {
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  font-variant-numeric: tabular-nums;
}

.yape__qr {
  width: 100%;
  max-width: 15rem;
  height: auto;
  margin: 0 auto;
  border-radius: 0.5rem;
}

.nota {
  font-size: 0.875rem;
  color: var(--texto-suave);
}

/* Pie
   –––––––––––––––––––––––––––––––––––––––––––––––––– */
.pie {
  display: grid;
  gap: var(--espacio-xs);
  margin: var(--espacio-xl) 0;
  font-size: 0.9375rem;
  text-align: center;
  color: var(--texto-suave);
}

.pie a {
  display: inline-block;
  padding: 0.75rem;
  font-size: 1.0625rem;
  font-weight: 600;
}

@media (prefers-reduced-motion: reduce) {
  .boton {
    transition: none;
  }
}

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}
