/* AnimalDex · web
   Colores del juego (paleta Sweetie 16 y la carcasa roja), con letra redonda y
   legible en todos los idiomas. Lo pixelado se reserva a detalles en latín. */

:root {
  --shell: #d63a4a;
  --shell-dark: #9b1f31;
  --ink: #1a1c2c;
  --ink-soft: #333c57;
  --cream: #fff5e6;
  --paper: #ffffff;
  --sand: #ffe7c7;
  --yellow: #ffcd75;
  --gold: #f5a623;
  --green: #38b764;
  --lime: #a7f070;
  --blue: #41a6f6;
  --deep-blue: #3b5dc9;
  --pink: #f7a8b8;
  --orange: #ef7d57;
  --muted: #5d6680;
  --radius: 18px;
  --border: 3px solid var(--ink);
  --shadow: 0 6px 0 var(--ink);
  --font: "Nunito", "M PLUS Rounded 1c", "Hiragino Maru Gothic ProN", "PingFang SC", "Noto Sans SC", "Microsoft YaHei", system-ui, sans-serif;
  --pixel: "Pixelify Sans", var(--font);
  color-scheme: light;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font: 500 18px/1.6 var(--font);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
:lang(ja) body, body:lang(ja) { font-family: "M PLUS Rounded 1c", "Hiragino Maru Gothic ProN", var(--font); }
:lang(zh) body, body:lang(zh) { font-family: "Nunito", "PingFang SC", "Noto Sans SC", "Microsoft YaHei", var(--font); }
img { max-width: 100%; display: block; }
a { color: var(--deep-blue); font-weight: 700; }
a:hover { color: var(--shell); }
.wrap { width: min(1120px, 100%); margin: 0 auto; padding: 0 16px; }

/* Cabecera */
.top {
  position: sticky; top: 0; z-index: 20;
  background: var(--shell);
  border-bottom: var(--border);
}
.top .wrap { display: flex; align-items: center; gap: 16px; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; }
.brand img { width: 38px; height: 38px; border-radius: 10px; border: 2px solid var(--ink); }
.brand span { font: 700 24px/1 var(--pixel); letter-spacing: .5px; text-shadow: 2px 2px 0 var(--shell-dark); }
.brand:hover { color: #fff; }
.nav { display: flex; gap: 4px; margin-left: auto; }
.nav a { color: #fff; text-decoration: none; padding: 8px 12px; border-radius: 12px; font-weight: 800; }
.nav a:hover { background: var(--shell-dark); color: #fff; }
.lang { position: relative; }
.lang select {
  appearance: none; -webkit-appearance: none;
  font: 800 15px var(--font); color: var(--ink);
  background: var(--yellow); border: 2px solid var(--ink); border-radius: 12px;
  padding: 7px 30px 7px 12px; cursor: pointer;
  box-shadow: 0 3px 0 var(--ink);
}
.lang::after { content: "▾"; position: absolute; right: 11px; top: 50%; transform: translateY(-55%); pointer-events: none; font-weight: 900; }

/* Botones */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  font: 900 18px/1 var(--font); text-decoration: none;
  color: #fff; background: var(--ink);
  padding: 16px 22px; border-radius: 16px;
  border: var(--border); box-shadow: 0 5px 0 var(--shell-dark);
  transition: transform .1s ease, box-shadow .1s ease;
}
.btn:hover { color: #fff; transform: translateY(2px); box-shadow: 0 3px 0 var(--shell-dark); }
.btn small { display: block; font-size: 12px; font-weight: 700; opacity: .8; margin-bottom: 4px; }
.btn .apple { width: 26px; height: 30px; flex: none; }
.btn.light { color: var(--ink); background: var(--yellow); box-shadow: var(--shadow); }
.btn.light:hover { color: var(--ink); box-shadow: 0 3px 0 var(--ink); }

/* Portada */
.hero {
  background:
    radial-gradient(circle at 80% 30%, rgba(255,255,255,.18) 0 160px, transparent 161px),
    linear-gradient(180deg, var(--shell) 0%, #e2515b 100%);
  color: #fff;
  border-bottom: var(--border);
  position: relative;
  overflow: hidden;
}
.hero::before {
  /* huellas de fondo */
  content: ""; position: absolute; inset: 0; opacity: .12;
  background-image: url("img/huellas.svg");
  background-size: 120px;
}
.hero .wrap { position: relative; display: grid; grid-template-columns: 1.1fr .9fr; gap: 24px; align-items: center; padding-top: 56px; padding-bottom: 72px; }
.kicker {
  display: inline-block; font: 700 14px/1 var(--pixel); letter-spacing: 1px;
  background: var(--ink); color: var(--yellow); padding: 8px 12px; border-radius: 10px;
}
.hero h1 { font-size: clamp(36px, 6vw, 62px); line-height: 1.08; margin: 18px 0 16px; font-weight: 900; text-shadow: 0 4px 0 var(--shell-dark); }
.hero p { font-size: 20px; max-width: 560px; margin: 0 0 28px; }
.hero .meta { margin-top: 16px; font-size: 15px; font-weight: 700; opacity: .9; }
.hero-art { position: relative; min-height: 380px; }
.hero-art .kiko { width: min(380px, 80%); margin: 0 auto; filter: drop-shadow(0 18px 0 rgba(26,28,44,.25)); animation: bob 3.2s ease-in-out infinite; }
.hero-art .friend { position: absolute; width: 120px; animation: bob 3.6s ease-in-out infinite; }
.hero-art .f1 { left: 0; bottom: 10px; animation-delay: -.8s; }
.hero-art .f2 { right: 0; top: 10px; animation-delay: -1.6s; }
.hero-art .f3 { right: 6%; bottom: 0; width: 100px; animation-delay: -2.2s; }
@keyframes bob { 50% { transform: translateY(-10px); } }
@media (prefers-reduced-motion: reduce) { .hero-art .kiko, .hero-art .friend { animation: none; } }

/* Cifras */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-top: -36px; position: relative; z-index: 2; }
.stat { background: var(--paper); border: var(--border); border-radius: var(--radius); box-shadow: var(--shadow); text-align: center; padding: 16px 10px; }
.stat b { display: block; font: 900 34px/1.1 var(--font); color: var(--shell); }
.stat span { font-size: 15px; font-weight: 800; color: var(--muted); }

/* Secciones */
section { padding: 72px 0; }
.section-title { text-align: center; max-width: 720px; margin: 0 auto 40px; }
.section-title h2 { font-size: clamp(28px, 4vw, 42px); line-height: 1.15; margin: 12px 0; font-weight: 900; }
.section-title p { color: var(--muted); font-size: 19px; margin: 0; }
.tag { display: inline-block; font: 700 13px/1 var(--pixel); letter-spacing: 1px; color: var(--ink); background: var(--yellow); border: 2px solid var(--ink); padding: 7px 10px; border-radius: 10px; }

.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.card { background: var(--paper); border: var(--border); border-radius: var(--radius); box-shadow: var(--shadow); padding: 24px; }
.card h3 { font-size: 22px; margin: 12px 0 8px; font-weight: 900; }
.card p { margin: 0; color: var(--ink-soft); }
.step { width: 48px; height: 48px; border-radius: 14px; border: var(--border); display: grid; place-items: center; font: 900 22px var(--font); }
.step.s1 { background: var(--blue); color: #fff; }
.step.s2 { background: var(--yellow); }
.step.s3 { background: var(--green); color: #fff; }

/* Escaparate de la Dex */
.dex { background: var(--ink); color: #fff; border-top: var(--border); border-bottom: var(--border); }
.dex .section-title p { color: #c6d4e0; }
.grid {
  display: grid; grid-template-columns: repeat(6, 1fr); gap: 14px;
}
.slot {
  background: #262b44; border: 3px solid #0b0c14; border-radius: 16px; padding: 10px 8px 12px; text-align: center;
  background-image: linear-gradient(#2c3150 1px, transparent 1px), linear-gradient(90deg, #2c3150 1px, transparent 1px);
  background-size: 16px 16px;
}
.slot img { width: 100%; aspect-ratio: 1; object-fit: contain; }
.slot .num { font: 700 12px var(--pixel); color: #94b0c2; }
.slot .name { display: block; font-weight: 800; font-size: 15px; margin-top: 2px; }
.stars { font-size: 12px; letter-spacing: 1px; }
.r1 { color: #a7f070; } .r2 { color: #41a6f6; } .r3 { color: #c99bea; } .r4 { color: #ffcd75; } .r5 { color: #ef7d57; }
.dex .note { text-align: center; margin-top: 28px; color: #c6d4e0; }

/* Características */
.features { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.feature { display: grid; grid-template-columns: 110px 1fr; gap: 18px; align-items: center; }
.feature img { width: 110px; }
.feature h3 { margin-top: 0; }

/* Plus */
.plus { background: linear-gradient(135deg, #fff1c9, #ffe0b0); border-top: var(--border); border-bottom: var(--border); }
.plus-box { display: grid; grid-template-columns: .8fr 1.2fr; gap: 28px; align-items: center; }
.plus-mascots { display: flex; justify-content: center; gap: 8px; }
.plus-mascots img { width: 46%; }
.badge-plus { display: inline-block; font: 900 15px var(--font); background: linear-gradient(135deg, #ffe9a8, #f5a623, #ffcd75, #c47a12); border: 2px solid var(--ink); border-radius: 10px; padding: 6px 12px; }
.checks { list-style: none; padding: 0; margin: 18px 0; }
.checks li { padding-left: 34px; position: relative; margin: 10px 0; font-weight: 700; }
.checks li::before { content: "✓"; position: absolute; left: 0; top: 1px; width: 24px; height: 24px; border-radius: 8px; background: var(--green); color: #fff; display: grid; place-items: center; font-weight: 900; font-size: 14px; border: 2px solid var(--ink); }
.small { font-size: 15px; color: var(--muted); }

/* Preguntas */
.faq { max-width: 820px; margin: 0 auto; }
details { background: var(--paper); border: var(--border); border-radius: var(--radius); box-shadow: 0 4px 0 var(--ink); padding: 16px 20px; margin-bottom: 14px; }
summary { cursor: pointer; font-weight: 900; font-size: 19px; list-style: none; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; float: right; font-weight: 900; }
details[open] summary::after { content: "–"; }
details p { margin: 10px 0 0; color: var(--ink-soft); }

/* Llamada final */
.cta { text-align: center; }
.cta .card { max-width: 760px; margin: 0 auto; padding: 36px 24px; background: var(--sand); }
.cta h2 { margin: 0 0 10px; font-size: clamp(26px, 4vw, 38px); font-weight: 900; }

/* Pie */
.foot { background: var(--ink); color: #c6d4e0; padding: 40px 0; border-top: var(--border); }
.foot .wrap { display: flex; flex-wrap: wrap; gap: 20px 32px; align-items: center; justify-content: space-between; }
.foot nav { display: flex; flex-wrap: wrap; gap: 8px 20px; }
.foot a { color: #fff; text-decoration: none; }
.foot a:hover { color: var(--yellow); }
.foot .brand span { text-shadow: none; }

/* Páginas de texto (ayuda, privacidad, normas) */
.doc { padding: 48px 0 72px; }
.doc .paper { max-width: 820px; margin: 0 auto; background: var(--paper); border: var(--border); border-radius: var(--radius); box-shadow: var(--shadow); padding: 32px clamp(18px, 4vw, 44px); }
.doc h1 { font-size: clamp(28px, 4vw, 38px); line-height: 1.15; margin-top: 0; }
.doc h2 { font-size: 22px; margin-top: 1.8em; color: var(--shell-dark); }
.doc em { color: var(--muted); }
.doc ul { padding-left: 1.2em; }
.doc li { margin: 6px 0; }
.doc .lang-note { background: var(--sand); border: 2px solid var(--ink); border-radius: 12px; padding: 10px 14px; font-size: 15px; }
.contact-box { margin-top: 28px; background: var(--sand); border: var(--border); border-radius: var(--radius); padding: 20px; text-align: center; }
.contact-box .btn { margin-top: 8px; }

[hidden] { display: none !important; }

/* Móvil */
@media (max-width: 900px) {
  .hero .wrap, .plus-box { grid-template-columns: 1fr; }
  .hero-art { min-height: 300px; }
  .cards, .features { grid-template-columns: 1fr; }
  .grid { grid-template-columns: repeat(3, 1fr); }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .nav { display: none; }
  .lang { margin-left: auto; }
}
@media (max-width: 480px) {
  body { font-size: 17px; }
  .feature { grid-template-columns: 80px 1fr; }
  .feature img { width: 80px; }
  .hero-art .friend { width: 84px; }
}
