/* ============================================================
   MADMA BIKES — design system público
   Estilo "Showroom limpio": blanco, aire, tipografía contrastada,
   rojo solo en acentos y CTAs. Mobile-first.
   ============================================================ */

/* ---------- Fuente ---------- */
@font-face {
  font-family: 'Manrope';
  src: url('/assets/fonts/manrope-var.woff2') format('woff2-variations');
  font-weight: 200 800;
  font-display: swap;
}

/* ---------- Variables ---------- */
:root {
  --rojo: #e30613;
  --rojo-texto: #c00510;       /* para texto pequeño sobre blanco (contraste AA) */
  --rojo-oscuro: #a50410;
  --negro: #0d0d0d;
  --tinta: #111111;
  --texto: #333333;
  --texto-2: #666666;
  --texto-3: #888888;
  --gris-f: #f7f7f7;
  --gris-fafa: #fafafa;
  --borde: #ececec;
  --blanco: #ffffff;
  --verde-wa: #25d366;
  --fuente: 'Manrope', -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  --sombra: 0 2px 24px rgba(0, 0, 0, .07);
  --radio: 10px;
  --cabecera-alto: 64px;
}

/* ---------- Reset mínimo ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--fuente);
  font-size: 16px;
  line-height: 1.6;
  color: var(--texto);
  background: var(--blanco);
}
img, video { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4, p { margin: 0; }
button { font: inherit; cursor: pointer; border: 0; background: none; }
input, textarea, select { font: inherit; }

:focus-visible { outline: 3px solid var(--rojo); outline-offset: 2px; border-radius: 4px; }

.salto-contenido {
  position: absolute; left: -9999px; top: 0; z-index: 300;
  background: var(--negro); color: #fff; padding: 10px 18px; border-radius: 0 0 8px 0;
}
.salto-contenido:focus { left: 0; }

.oculto-visual {
  position: absolute !important; width: 1px; height: 1px;
  margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------- Tipografía ---------- */
h1, .h1 { font-size: clamp(2.1rem, 5.5vw, 3.4rem); font-weight: 300; line-height: 1.12; color: var(--tinta); letter-spacing: -.01em; }
h2, .h2 { font-size: clamp(1.5rem, 3.4vw, 2.1rem); font-weight: 300; line-height: 1.2; color: var(--tinta); }
h3, .h3 { font-size: 1.12rem; font-weight: 700; color: var(--tinta); }
h1 b, h2 b, .h1 b, .h2 b { font-weight: 800; }

.etiqueta {
  display: inline-block;
  font-size: .72rem; font-weight: 800; letter-spacing: .28em;
  color: var(--rojo-texto); text-transform: uppercase;
}
.seccion-negra .etiqueta, .pie .etiqueta { color: var(--rojo); }
.linea-roja { width: 38px; height: 3px; background: var(--rojo); border: 0; margin: 0 0 18px; }

/* ---------- Layout ---------- */
.contenedor { max-width: 1180px; margin-inline: auto; padding-inline: 20px; }
.seccion { padding-block: 64px; }
.seccion-gris { background: var(--gris-f); }
.seccion-negra { background: var(--negro); color: #d6d6d6; }
.seccion-negra h2, .seccion-negra h3 { color: #fff; }

.cabecera-seccion { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 14px; margin-bottom: 30px; }
.cabecera-seccion p { color: var(--texto-2); max-width: 56ch; }

.grid-2 { display: grid; gap: 22px; grid-template-columns: 1fr; }
.grid-3 { display: grid; gap: 22px; grid-template-columns: 1fr; }
.grid-4 { display: grid; gap: 18px; grid-template-columns: repeat(2, 1fr); }

@media (min-width: 640px) {
  .grid-2 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 900px) {
  .seccion { padding-block: 88px; }
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
  .grid-4 { grid-template-columns: repeat(4, 1fr); }
}

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 26px; border-radius: 999px;
  font-weight: 700; font-size: .95rem; line-height: 1;
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
  white-space: nowrap;
}
.btn:active { transform: scale(.97); }
.btn-rojo { background: var(--rojo); color: #fff; }
.btn-rojo:hover { background: var(--rojo-oscuro); box-shadow: 0 6px 18px rgba(227, 6, 19, .3); }
.btn-negro { background: var(--negro); color: #fff; }
.btn-negro:hover { box-shadow: 0 6px 18px rgba(0, 0, 0, .25); }
.btn-borde { border: 1.5px solid var(--tinta); color: var(--tinta); background: transparent; }
.btn-borde:hover { background: var(--tinta); color: #fff; }
.btn-blanco { background: #fff; color: var(--tinta); }
.btn-grande { padding: 16px 34px; font-size: 1.02rem; }

.enlace-rojo {
  display: inline-block; font-weight: 700; color: var(--tinta);
  border-bottom: 2px solid var(--rojo); padding-bottom: 2px;
  transition: color .15s ease;
}
.enlace-rojo:hover { color: var(--rojo-texto); }

/* ---------- Cabecera ---------- */
.cabecera {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  height: var(--cabecera-alto);
  display: flex; align-items: center;
  background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--borde);
  transition: background .25s ease, box-shadow .25s ease;
}
.cabecera-interior { display: flex; align-items: center; justify-content: space-between; gap: 18px; width: 100%; }
.cabecera.es-transparente { background: transparent; border-bottom-color: transparent; backdrop-filter: none; }
.cabecera.es-transparente.con-fondo {
  background: rgba(255, 255, 255, .94); border-bottom-color: var(--borde);
  backdrop-filter: blur(8px); box-shadow: 0 2px 18px rgba(0, 0, 0, .05);
}

.logo { display: inline-flex; align-items: center; gap: 10px; }
.logo-texto {
  font-weight: 800; font-size: 1.05rem; letter-spacing: .14em; color: var(--tinta);
  font-style: normal; white-space: nowrap;
}
.logo-texto i { font-style: normal; color: var(--rojo); }
.logo-blanco { color: #fff; }

.nav-principal { display: none; }
.nav-principal a {
  font-size: .82rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  color: var(--tinta); padding: 8px 11px; border-radius: 6px; position: relative;
}
.nav-principal a::after {
  content: ""; position: absolute; left: 11px; right: 11px; bottom: 2px; height: 2px;
  background: var(--rojo); transform: scaleX(0); transform-origin: left; transition: transform .18s ease;
}
.nav-principal a:hover::after, .nav-principal a.activo::after { transform: scaleX(1); }

.acciones-cabecera { display: flex; align-items: center; gap: 10px; }
.acciones-cabecera .btn { padding: 10px 20px; font-size: .85rem; }
.acceso-link { font-size: .82rem; font-weight: 700; color: var(--texto-2); display: none; }
.acceso-link:hover { color: var(--tinta); }

.burger { display: inline-flex; flex-direction: column; gap: 5px; padding: 10px; }
.burger span { width: 22px; height: 2px; background: var(--tinta); transition: transform .2s ease, opacity .2s ease; }
.burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.nav-movil {
  position: fixed; inset: 0; z-index: 99; display: flex; flex-direction: column;
  padding: calc(var(--cabecera-alto) + 24px) 28px 28px;
  background: #fff; transform: translateX(100%); transition: transform .25s ease;
}
.nav-movil.abierto { transform: translateX(0); }
.nav-movil a {
  padding: 15px 4px; font-size: 1.15rem; font-weight: 700; color: var(--tinta);
  border-bottom: 1px solid var(--borde);
}
.nav-movil a.activo { color: var(--rojo-texto); }
.nav-movil .btn { margin-top: 22px; }
.nav-movil .acceso-movil { margin-top: 10px; text-align: center; color: var(--texto-2); font-size: .95rem; border-bottom: 0; }

@media (min-width: 900px) {
  .nav-principal { display: flex; gap: 2px; }
  .burger, .nav-movil { display: none; }
  .acceso-link { display: inline; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden; background: var(--negro);
  min-height: min(92vh, 760px); display: flex; align-items: center;
  padding-top: var(--cabecera-alto);
}
.hero-fondo, .hero-fondo video, .hero-fondo img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
}
.hero-fondo video, .hero-fondo img { filter: blur(2px) brightness(.8); transform: scale(1.06); }
.hero-velo {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(255,255,255,.95) 0%, rgba(255,255,255,.86) 55%, rgba(255,255,255,.55) 100%);
}
.hero-contenido { position: relative; max-width: 640px; padding-block: 60px; }
.hero-contenido .h1 { color: var(--tinta); }
.hero-sub { margin-top: 16px; font-size: 1.06rem; color: var(--texto); max-width: 44ch; }
.hero-ctas { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; margin-top: 28px; }

.hero-stats { display: flex; gap: 34px; margin-top: 44px; }
.hero-stats b { display: block; font-size: 1.45rem; font-weight: 800; color: var(--tinta); line-height: 1.1; }
.hero-stats span { font-size: .8rem; color: var(--texto-2); }

.hero-flecha {
  position: absolute; left: 50%; bottom: 16px; transform: translateX(-50%);
  color: var(--texto-2); font-size: 1.3rem; animation: flota 2.2s ease-in-out infinite;
}
@keyframes flota { 0%, 100% { transform: translate(-50%, 0); } 50% { transform: translate(-50%, 8px); } }

@media (min-width: 900px) {
  .hero-velo {
    background: linear-gradient(90deg, rgba(255,255,255,.97) 0%, rgba(255,255,255,.88) 36%, rgba(255,255,255,.05) 68%, rgba(255,255,255,0) 100%);
  }
}

/* ---------- Tarjetas pilar (Tienda/Taller/Club) ---------- */
.tarjeta-pilar {
  display: block; border: 1px solid var(--borde); border-radius: var(--radio); overflow: hidden;
  background: #fff; transition: transform .18s ease, box-shadow .18s ease;
}
.tarjeta-pilar:hover { transform: translateY(-4px); box-shadow: var(--sombra); }
.tarjeta-pilar img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.tarjeta-pilar-cuerpo { padding: 18px 20px 22px; }
.tarjeta-pilar-cuerpo h3 { margin: 6px 0 6px; font-size: 1.18rem; }
.tarjeta-pilar-cuerpo p { font-size: .92rem; color: var(--texto-2); }
.tarjeta-pilar-cuerpo .enlace-rojo { margin-top: 12px; font-size: .9rem; }

/* ---------- Bloque DJI × Megamo ---------- */
.bloque-dji { display: grid; grid-template-columns: 1fr; overflow: hidden; }
.bloque-dji-texto { padding: 48px 24px; }
.bloque-dji-texto h2 { margin-top: 10px; }
.bloque-dji-texto > p { margin-top: 14px; color: #b9b9b9; max-width: 50ch; }
.dji-datos { display: flex; gap: 30px; margin-top: 26px; flex-wrap: wrap; }
.dji-datos b { display: block; font-size: 1.5rem; font-weight: 800; color: #fff; line-height: 1.1; }
.dji-datos small { font-size: .76rem; color: var(--texto-3); }
.bloque-dji-foto { min-height: 280px; }
.bloque-dji-foto img { width: 100%; height: 100%; object-fit: cover; }
@media (min-width: 900px) {
  .bloque-dji { grid-template-columns: 1.15fr 1fr; }
  .bloque-dji-texto { padding: 72px 56px 72px 0; }
}

/* ---------- Tiles modalidad ---------- */
.tile-modalidad {
  position: relative; display: block; border-radius: var(--radio); overflow: hidden;
  aspect-ratio: 4 / 3; background: var(--negro);
}
.tile-modalidad img { width: 100%; height: 100%; object-fit: cover; filter: brightness(.66); transition: transform .3s ease, filter .3s ease; }
.tile-modalidad:hover img { transform: scale(1.04); filter: brightness(.78); }
.tile-modalidad-texto { position: absolute; left: 18px; bottom: 16px; right: 18px; color: #fff; }
.tile-modalidad-texto b { font-size: 1.3rem; font-weight: 800; letter-spacing: .04em; }
.tile-modalidad-texto span { display: block; font-size: .85rem; color: #e3e3e3; }

/* ---------- Tarjeta de producto (v2 aprobada) ---------- */
.tarjeta-prod {
  display: flex; flex-direction: column;
  border: 1px solid var(--borde); border-radius: var(--radio); overflow: hidden; background: #fff;
  transition: transform .18s ease, box-shadow .18s ease;
}
.tarjeta-prod:hover { transform: translateY(-4px); box-shadow: var(--sombra); }
.tarjeta-prod-foto { position: relative; background: var(--gris-fafa); }
.tarjeta-prod-foto img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.tarjeta-prod-cuerpo { padding: 14px 16px 18px; text-align: center; }
.tarjeta-prod-cuerpo h3 { font-size: 1rem; font-weight: 700; }
.tarjeta-prod-cuerpo .desc { font-size: .82rem; color: var(--texto-3); margin-top: 3px; min-height: 1.2em; }
.precio { margin-top: 8px; font-size: 1.12rem; font-weight: 800; color: var(--rojo-texto); }
.precio s { color: #aaa; font-weight: 400; font-size: .85rem; margin-left: 6px; }

.badge {
  position: absolute; top: 10px; left: 10px; z-index: 1;
  font-size: .64rem; font-weight: 800; letter-spacing: .08em;
  padding: 4px 9px; border-radius: 4px; color: #fff; background: var(--rojo);
}
.badge-negro { background: var(--negro); }

/* ---------- Chips de filtro ---------- */
.chips { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.chip {
  display: inline-block; padding: 8px 16px; border-radius: 999px;
  font-size: .82rem; font-weight: 600; color: var(--texto);
  border: 1px solid #ddd; background: #fff; transition: all .15s ease;
}
.chip:hover { border-color: var(--tinta); color: var(--tinta); }
.chip.activo { background: var(--negro); color: #fff; border-color: var(--negro); }
.buscador { margin-left: auto; display: flex; }
.buscador input {
  border: 1px solid #ddd; border-radius: 999px; padding: 8px 18px; font-size: .85rem; width: 190px;
}
.buscador input:focus { outline: 2px solid var(--rojo); border-color: transparent; }

/* ---------- Franja de marcas ---------- */
.franja-marcas { display: flex; align-items: center; gap: 30px; flex-wrap: wrap; justify-content: center; }
.franja-marcas img, .franja-marcas .marca-nombre {
  filter: grayscale(1); opacity: .55; transition: filter .2s ease, opacity .2s ease;
  max-height: 34px; width: auto;
}
.franja-marcas a:hover img, .franja-marcas a:hover .marca-nombre { filter: grayscale(0); opacity: 1; }
.marca-nombre { font-weight: 800; font-size: 1.1rem; color: var(--tinta); letter-spacing: .03em; }

/* ---------- Tarjeta de marca ---------- */
.tarjeta-marca { border: 1px solid var(--borde); border-radius: var(--radio); overflow: hidden; background: #fff; display: flex; flex-direction: column; }
.tarjeta-marca-logo {
  height: 110px; display: flex; align-items: center; justify-content: center;
  background: var(--gris-fafa); border-bottom: 1px solid var(--borde); padding: 18px;
}
.tarjeta-marca-logo img { max-height: 56px; max-width: 70%; width: auto; object-fit: contain; filter: grayscale(1); transition: filter .2s ease; }
.tarjeta-marca:hover .tarjeta-marca-logo img { filter: grayscale(0); }
.tarjeta-marca-cuerpo { padding: 16px 18px 20px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.tarjeta-marca-cuerpo .badge-marca { font-size: .66rem; font-weight: 800; letter-spacing: .14em; color: var(--rojo-texto); }
.tarjeta-marca-cuerpo p { font-size: .88rem; color: var(--texto-2); flex: 1; }
.mini-galeria { display: grid; grid-template-columns: repeat(3, 1fr); gap: 5px; }
.mini-galeria img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 5px; }

.tarjeta-marca-destacada { display: grid; grid-template-columns: 1fr; border: 1px solid var(--borde); border-radius: var(--radio); overflow: hidden; background: #fff; }
.tarjeta-marca-destacada .cuerpo { padding: 26px; }
.tarjeta-marca-destacada .fotos { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; }
.tarjeta-marca-destacada .fotos img { width: 100%; height: 100%; min-height: 170px; object-fit: cover; }
@media (min-width: 900px) {
  .tarjeta-marca-destacada { grid-template-columns: 1.2fr 1fr; }
}

/* ---------- Timeline historia ---------- */
.timeline { display: grid; gap: 22px; grid-template-columns: 1fr 1fr; }
.timeline article { border-top: 3px solid var(--rojo); padding-top: 12px; }
.timeline b { font-size: 1.1rem; color: var(--tinta); }
.timeline p { font-size: .88rem; color: var(--texto-2); margin-top: 4px; }
@media (min-width: 900px) { .timeline { grid-template-columns: repeat(4, 1fr); } }

/* ---------- Galería de fotos ---------- */
.galeria-tira { display: grid; grid-template-columns: repeat(2, 1fr); gap: 6px; }
.galeria-tira img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 6px; }
@media (min-width: 900px) { .galeria-tira { grid-template-columns: repeat(4, 1fr); } }

/* ---------- Banner club / cierres con foto ---------- */
.banner-foto { position: relative; overflow: hidden; background: var(--negro); }
.banner-foto > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: brightness(.5); }
.banner-foto-contenido { position: relative; text-align: center; color: #fff; padding: 84px 20px; max-width: 760px; margin-inline: auto; }
.banner-foto-contenido h2 { color: #fff; margin-top: 14px; }
.banner-chips { display: flex; flex-wrap: wrap; gap: 8px 20px; justify-content: center; margin-top: 16px; font-size: .9rem; color: #ececec; }
.banner-foto-contenido .hero-ctas { justify-content: center; }
.etiqueta-bloque { display: inline-block; background: var(--rojo); color: #fff; font-size: .7rem; font-weight: 800; letter-spacing: .25em; padding: 5px 12px; border-radius: 4px; }

/* ---------- Ventajas del club ---------- */
.tarjeta-ventaja { border: 1px solid var(--borde); border-radius: var(--radio); padding: 18px; background: #fff; }
.tarjeta-ventaja .icono { font-size: 1.5rem; }
.tarjeta-ventaja h3 { font-size: .98rem; margin-top: 8px; }
.tarjeta-ventaja p { font-size: .84rem; color: var(--texto-2); margin-top: 3px; }
.tarjeta-cuota { background: var(--negro); border-color: var(--negro); color: #fff; display: flex; flex-direction: column; }
.tarjeta-cuota .importe { font-size: 2rem; font-weight: 800; line-height: 1; }
.tarjeta-cuota .importe small { font-size: .85rem; font-weight: 400; color: #aaa; }
.tarjeta-cuota p { color: #aaa; flex: 1; }
.tarjeta-cuota .btn { margin-top: 14px; }

/* ---------- Eventos ---------- */
.tarjeta-evento { border: 1px solid var(--borde); border-radius: var(--radio); padding: 16px 18px; background: #fff; }
.tarjeta-evento-cab { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.fecha-evento { font-size: .82rem; font-weight: 800; color: var(--rojo-texto); letter-spacing: .05em; }
.chip-modalidad { font-size: .68rem; font-weight: 700; background: var(--gris-f); color: var(--texto-2); padding: 3px 9px; border-radius: 4px; letter-spacing: .08em; text-transform: uppercase; }
.tarjeta-evento h3 { margin-top: 6px; font-size: 1.02rem; }
.tarjeta-evento .meta { font-size: .82rem; color: var(--texto-3); margin-top: 3px; }
.tarjeta-evento .pie-evento { display: flex; justify-content: space-between; align-items: center; margin-top: 12px; gap: 10px; }
.plazas { font-size: .78rem; font-weight: 700; color: #b45309; background: #fef3c7; padding: 3px 9px; border-radius: 99px; }
.plazas.completo { color: #dc2626; background: #fee2e2; }

/* ---------- FAQ ---------- */
.faq details { border: 1px solid var(--borde); border-radius: var(--radio); background: #fff; padding: 0 20px; margin-bottom: 10px; }
.faq summary { cursor: pointer; padding: 16px 0; font-weight: 700; color: var(--tinta); list-style: none; position: relative; padding-right: 30px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 2px; top: 50%; transform: translateY(-50%); font-size: 1.3rem; color: var(--rojo); font-weight: 400; }
.faq details[open] summary::after { content: "–"; }
.faq details p { padding-bottom: 16px; color: var(--texto-2); font-size: .92rem; }

/* ---------- Formularios ---------- */
.campo { display: block; margin-bottom: 16px; }
.campo > span { display: block; font-size: .8rem; font-weight: 700; color: var(--texto); margin-bottom: 6px; }
.campo input, .campo textarea, .campo select {
  width: 100%; padding: 13px 16px; border: 1px solid #ddd; border-radius: 8px;
  font-size: .95rem; background: #fff; color: var(--tinta);
}
.campo input:focus, .campo textarea:focus, .campo select:focus { outline: 2px solid var(--rojo); border-color: transparent; }
.campo textarea { min-height: 130px; resize: vertical; }
.campo .ayuda { display: block; font-size: .76rem; color: var(--texto-3); margin-top: 4px; }
.campo.con-error input, .campo.con-error textarea { border-color: var(--rojo); }
.error-campo { color: var(--rojo-texto); font-size: .78rem; margin-top: 4px; display: block; }

.check { display: flex; gap: 10px; align-items: flex-start; margin-bottom: 14px; font-size: .85rem; color: var(--texto-2); }
.check input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--rojo); flex-shrink: 0; }

.aviso { padding: 14px 18px; border-radius: 8px; font-size: .92rem; margin-bottom: 18px; }
.aviso-ok { background: #dcfce7; color: #166534; }
.aviso-error { background: #fee2e2; color: #991b1b; }

.trampa { position: absolute; left: -9999px; opacity: 0; height: 0; overflow: hidden; }

/* ---------- Tarjetas contacto directo ---------- */
.tarjeta-contacto {
  display: flex; gap: 14px; align-items: center;
  border: 1px solid var(--borde); border-radius: var(--radio); padding: 16px 18px; background: #fff;
  transition: transform .15s ease, box-shadow .15s ease;
}
.tarjeta-contacto:hover { transform: translateY(-2px); box-shadow: var(--sombra); }
.tarjeta-contacto .icono-red { width: 44px; height: 44px; border-radius: 50%; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.icono-wa { background: var(--verde-wa); }
.icono-ig { background: radial-gradient(circle at 30% 110%, #fdf497 0%, #fd5949 45%, #d6249f 60%, #285AEB 90%); border-radius: 12px !important; }
.icono-mail { background: var(--negro); }
.tarjeta-contacto b { display: block; color: var(--tinta); font-size: .98rem; }
.tarjeta-contacto small { color: var(--texto-3); font-size: .8rem; }

/* ---------- Mapa con fachada ---------- */
.mapa-fachada {
  position: relative; border-radius: var(--radio); overflow: hidden; background: #e9e9e9;
  min-height: 280px; display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 12px;
  text-align: center; padding: 20px;
}
.mapa-fachada p { color: var(--texto-2); font-size: .9rem; }
.mapa-fachada iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* ---------- Banner de cookies (RGPD) ---------- */
.cookie-banner {
  position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 300; margin: 0 auto;
  max-width: 720px; display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center;
  justify-content: center; background: var(--tinta, #111); color: #fff;
  padding: 14px 18px; border-radius: 14px; box-shadow: 0 10px 34px rgba(0,0,0,.32);
  font-size: .85rem; line-height: 1.4;
}
.cookie-banner p { margin: 0; color: #e9e9e9; flex: 1 1 320px; }
.cookie-banner a { color: #fff; text-decoration: underline; }
.cookie-banner .btn { white-space: nowrap; }
.cookie-banner[hidden] { display: none; }

/* ---------- Paginación ---------- */
.paginacion { display: flex; gap: 6px; justify-content: center; margin-top: 36px; }
.paginacion a, .paginacion span {
  min-width: 40px; height: 40px; display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--borde); border-radius: 8px; font-weight: 700; font-size: .9rem; color: var(--texto);
}
.paginacion a:hover { border-color: var(--tinta); }
.paginacion .actual { background: var(--negro); color: #fff; border-color: var(--negro); }

/* ---------- Migas ---------- */
.migas { font-size: .8rem; color: var(--texto-3); margin-bottom: 18px; }
.migas a { color: var(--texto-2); }
.migas a:hover { color: var(--rojo-texto); }

/* ---------- Ficha de producto ---------- */
.ficha-producto { display: grid; gap: 34px; grid-template-columns: 1fr; }
.galeria-producto .principal { border: 1px solid var(--borde); border-radius: var(--radio); overflow: hidden; background: var(--gris-fafa); }
.galeria-producto .principal img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.galeria-producto .miniaturas { display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; }
.galeria-producto .miniaturas button { border: 2px solid transparent; border-radius: 8px; overflow: hidden; padding: 0; background: var(--gris-fafa); }
.galeria-producto .miniaturas button.activa { border-color: var(--rojo); }
.galeria-producto .miniaturas img { width: 74px; height: 56px; object-fit: cover; }
.ficha-info .precio { font-size: 1.8rem; margin-top: 14px; }
.ficha-info .descripcion { margin-top: 18px; color: var(--texto-2); white-space: pre-line; }
.ficha-info .btn { margin-top: 26px; }
@media (min-width: 900px) { .ficha-producto { grid-template-columns: 1.1fr 1fr; } }

/* ---------- Footer ---------- */
.pie { background: var(--negro); color: #9a9a9a; font-size: .88rem; }
.pie-superior { display: grid; gap: 34px; grid-template-columns: 1fr; padding-block: 56px 40px; }
.pie h4 { color: #fff; font-size: .95rem; margin-bottom: 14px; letter-spacing: .04em; }
.pie a:hover { color: #fff; }
.pie li { margin-bottom: 9px; }
.pie-marca p { margin-top: 12px; max-width: 30ch; line-height: 1.7; }
.pie-redes { display: flex; gap: 12px; margin-top: 18px; }
.pie-redes a { width: 38px; height: 38px; border: 1px solid #333; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; transition: border-color .15s ease, background .15s ease; }
.pie-redes a:hover { border-color: #fff; }
.pie-inferior {
  border-top: 1px solid #262626; padding-block: 20px;
  display: flex; flex-wrap: wrap; gap: 10px 24px; justify-content: space-between; align-items: center;
  font-size: .78rem; color: #7c7c7c;
}
.pie-inferior a:hover { color: #fff; }
.pie-legal { display: flex; flex-wrap: wrap; gap: 6px 18px; }
.credito b { color: #d6d6d6; font-weight: 700; }
@media (min-width: 900px) { .pie-superior { grid-template-columns: 1.4fr 1fr 1fr 1.2fr; } }

/* ---------- WhatsApp flotante con sonar ---------- */
.wa-flotante {
  position: fixed; right: 18px; bottom: 18px; z-index: 90;
  width: 58px; height: 58px; border-radius: 50%;
  background: var(--verde-wa); display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 16px rgba(0, 0, 0, .22);
  animation: sonar 2.4s ease-out infinite;
}
.wa-flotante svg { width: 32px; height: 32px; }
.wa-flotante:hover { background: #1fb858; }
@keyframes sonar {
  0%   { box-shadow: 0 4px 16px rgba(0,0,0,.22), 0 0 0 0 rgba(37, 211, 102, .45), 0 0 0 0 rgba(37, 211, 102, .25); }
  70%  { box-shadow: 0 4px 16px rgba(0,0,0,.22), 0 0 0 16px rgba(37, 211, 102, 0), 0 0 0 30px rgba(37, 211, 102, 0); }
  100% { box-shadow: 0 4px 16px rgba(0,0,0,.22), 0 0 0 0 rgba(37, 211, 102, 0), 0 0 0 0 rgba(37, 211, 102, 0); }
}

/* ---------- Página de acceso (login / recuperar) ---------- */
.pagina-acceso { min-height: 100vh; display: flex; align-items: center; justify-content: center; background: var(--gris-f); padding: 24px; }
.caja-acceso { width: 100%; max-width: 410px; background: #fff; border: 1px solid var(--borde); border-radius: 14px; padding: 34px 30px; }
.caja-acceso .logo { justify-content: center; display: flex; margin-bottom: 8px; }
.caja-acceso h1 { font-size: 1.3rem; font-weight: 700; text-align: center; margin-bottom: 22px; }
.caja-acceso .btn { width: 100%; margin-top: 6px; }
.caja-acceso .extra { text-align: center; margin-top: 18px; font-size: .85rem; color: var(--texto-2); }
.caja-acceso .extra a { color: var(--rojo-texto); font-weight: 600; }

/* ---------- Wizard alta socio ---------- */
.wizard-progreso { display: flex; gap: 6px; margin: 18px 0 6px; }
.wizard-progreso i { flex: 1; height: 4px; border-radius: 2px; background: var(--borde); }
.wizard-progreso i.hecho { background: var(--rojo); }
.wizard-paso-titulo { text-align: center; font-size: .8rem; color: var(--texto-3); margin-bottom: 20px; }
.resumen-alta { background: var(--gris-f); border-radius: 10px; padding: 18px; font-size: .9rem; }
.resumen-alta dt { font-weight: 700; color: var(--tinta); margin-top: 10px; font-size: .78rem; letter-spacing: .04em; text-transform: uppercase; }
.resumen-alta dd { margin: 2px 0 0; color: var(--texto-2); }
.texto-legal { font-size: .76rem; color: var(--texto-3); line-height: 1.5; }

/* ---------- Utilidades ---------- */
.texto-centro { text-align: center; }
.mt-10 { margin-top: 10px; } .mt-20 { margin-top: 20px; } .mt-30 { margin-top: 30px; } .mt-40 { margin-top: 40px; }
.sin-resultados { text-align: center; color: var(--texto-2); padding: 60px 20px; }
.sin-resultados b { display: block; font-size: 1.2rem; color: var(--tinta); margin-bottom: 6px; }

/* ---------- Animaciones de entrada ---------- */
.aparece { opacity: 0; transform: translateY(18px); transition: opacity .5s ease, transform .5s ease; }
.aparece.visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .wa-flotante { animation: none; }
  .hero-flecha { animation: none; }
  .aparece { opacity: 1; transform: none; transition: none; }
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}

/* ============================================================
   Calendario de salidas y detalle de ruta (mapa + altimetría)
   ============================================================ */

/* ---------- Indicador de dureza (gauge SVG) ---------- */
.gauge { display: block; height: auto; max-width: 100%; }
.gauge-bloque { display: flex; flex-direction: column; align-items: center; gap: 2px; }
.gauge-bloque .etiqueta { font-size: .66rem; }

/* ---------- Detalle de salida ---------- */
.salida-cabecera { display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: baseline; }
.salida-fecha { font-size: .82rem; font-weight: 800; color: var(--rojo-texto); letter-spacing: .04em; }
.salida-meta-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }

.salida-stats {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; align-items: center;
  background: #fff; border: 1px solid var(--borde); border-radius: var(--radio); padding: 18px;
}
.salida-stats .gauge-wrap { grid-column: 1 / -1; display: flex; justify-content: center; }
.salida-stat { display: flex; flex-direction: column; gap: 2px; }
.salida-stat .et { font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; color: var(--texto-3); }
.salida-stat .val { font-size: 1.18rem; font-weight: 800; color: var(--tinta); line-height: 1.15; }
.salida-stat .val small { font-size: .8rem; font-weight: 600; color: var(--texto-2); }
@media (min-width: 720px) {
  .salida-stats { grid-template-columns: repeat(4, 1fr) auto; }
  .salida-stats .gauge-wrap { grid-column: auto; }
}

/* ---------- Mapa Leaflet ---------- */
.salida-mapa {
  height: 300px; border-radius: var(--radio); overflow: hidden; border: 1px solid var(--borde);
  position: relative; z-index: 0;            /* contiene los controles Leaflet bajo la cabecera fija */
  background: #e8eef0;
}
@media (min-width: 720px) { .salida-mapa { height: 420px; } }
.leaflet-container { font: inherit; background: #e8eef0; }
.leaflet-control-attribution { font-size: 10px; }

/* ---------- Llévate la ruta (descarga / Garmin / Strava) ---------- */
.salida-llevar-botones { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 10px; }
.salida-llevar-botones .btn { font-size: .85rem; padding: 10px 18px; }

/* ---------- Bloque de inscripción ---------- */
.salida-cta {
  background: var(--gris-f); border: 1px solid var(--borde); border-radius: 14px; padding: 20px 22px;
  display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap;
}
.salida-cta-texto { min-width: 0; }
.salida-cta-acciones { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
@media (max-width: 560px) {
  .salida-cta-acciones { width: 100%; flex-direction: column; align-items: stretch; gap: 12px; }
  .salida-cta-acciones .btn { width: 100%; }
  .salida-cta-acciones .enlace-rojo { text-align: center; }
}

/* ---------- Altimetría ---------- */
.salida-altimetria { margin-top: 10px; width: 100%; }
.alt-svg { width: 100%; height: auto; display: block; touch-action: pan-y; }
.alt-eje { font-family: var(--fuente); font-size: 11px; fill: var(--texto-3); }
.alt-tip { font-family: var(--fuente); font-size: 11px; font-weight: 700; }
.salida-altimetria-cab { display: flex; justify-content: space-between; align-items: baseline; margin: 18px 0 2px; }
.salida-altimetria-cab .pista { font-size: .76rem; color: var(--texto-3); }

/* ---------- Calendario público ---------- */
.cal-mes { font-size: 1.05rem; font-weight: 800; color: var(--tinta); margin: 30px 0 14px; text-transform: capitalize; border-bottom: 2px solid var(--rojo); display: inline-block; padding-bottom: 4px; }
.cal-lista { display: grid; gap: 14px; }
.cal-item {
  display: grid; grid-template-columns: 60px 1fr; gap: 12px 16px; align-items: center;
  background: #fff; border: 1px solid var(--borde); border-radius: 14px; padding: 16px;
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.cal-item:hover { transform: translateY(-2px); box-shadow: var(--sombra); border-color: #dcdcdc; }
.cal-fecha {
  width: 60px; height: 64px; border-radius: 12px; background: var(--negro); color: #fff;
  display: flex; flex-direction: column; align-items: center; justify-content: center; flex-shrink: 0;
}
.cal-fecha .dia { font-size: 1.55rem; font-weight: 800; line-height: 1; }
.cal-fecha .mes { font-size: .62rem; letter-spacing: .12em; text-transform: uppercase; color: var(--rojo); font-weight: 800; margin-top: 2px; }
.cal-cuerpo { min-width: 0; }
.cal-cuerpo h3 { font-size: 1.08rem; line-height: 1.2; }
.cal-cuerpo .cal-sub { font-size: .82rem; color: var(--texto-2); margin-top: 3px; }
.cal-stats { display: flex; flex-wrap: wrap; gap: 6px 12px; align-items: center; margin-top: 10px; font-size: .82rem; color: var(--texto-2); }
.cal-stats b { color: var(--tinta); }
.cal-dato { display: inline-flex; align-items: center; gap: 4px; }
.cal-nivel { color: var(--texto-3); }
.cal-pill { font-size: .66rem; font-weight: 800; letter-spacing: .03em; padding: 4px 11px; border-radius: 99px; color: #fff; white-space: nowrap; }
.cal-ver { font-size: .8rem; font-weight: 700; color: var(--rojo-texto); }

/* Altimetría a la derecha de cada salida */
.cal-alti { grid-column: 1 / -1; display: flex; align-items: center; gap: 12px; }
.cal-alti-graf {
  flex: 1; min-width: 0; height: 50px; border-radius: 8px; overflow: hidden;
  background: linear-gradient(180deg, #fafafa, #f3f3f3); border: 1px solid var(--borde);
}
.alt-mini { width: 100%; height: 100%; display: block; }
@media (min-width: 760px) {
  .cal-item { grid-template-columns: 60px 1fr 230px; }
  .cal-alti { grid-column: auto; flex-direction: column; align-items: stretch; gap: 6px; width: 230px; }
  .cal-alti-graf { width: 100%; height: 56px; }
  .cal-alti .cal-pill, .cal-alti .cal-ver { align-self: flex-end; }
}

/* ---------- Impresión ---------- */
@media print {
  .cabecera, .wa-flotante, .pie, .hero-flecha { display: none !important; }
}
