/* ===== MANITA — Design System ===== */
:root {
  --primary: #2563EB;        /* azul confianza — identidad Manita (fondos/decorativo) */
  --primary-dark: #1E40AF;
  --primary-light: #93C5FD;
  --primary-text: #1D4ED8;   /* azul accesible AA (~6:1 s/ blanco) — para TEXTO y botones */
  --accent: #1E3A8A;         /* azul índigo profundo */
  --navy: #10214A;           /* azul marino para títulos */
  --navy2: #1E3A8A;
  --dark: #1A2233;
  --gray: #556070;           /* gris azulado accesible AA */
  --light-gray: #9AA6B8;
  --bg: #ffffff;
  --bg-alt: #F5F8FC;         /* gris azulado muy claro */
  --mint: #EFF4FF;           /* azul muy claro (chips/fondos suaves) */
  --border: #E4E9F2;
  --success: #16A97F;
  --success-text: #0C6B4F;   /* verde accesible AA para texto sobre fondos verdes claros */
  --warning: #F2A93B;        /* ámbar decorativo (estrellas de fondo) */
  --warning-text: #9A6200;   /* ámbar accesible AA (5.1:1 s/ blanco) — para texto de rating */
  --danger: #E5484D;
  /* Sombras en capas (elevación tipo Material) */
  --shadow-xs: 0 1px 2px rgba(16,33,74,0.06);
  --shadow: 0 4px 20px rgba(16,33,74,0.07);
  --shadow-md: 0 6px 24px rgba(16,33,74,0.10);
  --shadow-lg: 0 12px 40px rgba(16,33,74,0.13);
  --shadow-primary: 0 8px 24px rgba(37,99,235,0.32); /* sombra azul para CTAs */

  /* Radios */
  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 22px;
  --radius-pill: 999px;

  /* Escala de espaciado (base 4px) */
  --sp-1: 4px;  --sp-2: 8px;  --sp-3: 12px; --sp-4: 16px;
  --sp-5: 20px; --sp-6: 24px; --sp-8: 32px; --sp-10: 40px; --sp-12: 48px;

  /* Escala tipográfica */
  --fs-xs: 12px; --fs-sm: 13px; --fs-base: 15px; --fs-md: 17px;
  --fs-lg: 20px; --fs-xl: 24px; --fs-2xl: 30px; --fs-3xl: 36px;

  /* Curvas de animación */
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --dur: 0.2s;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
body {
  font-family: -apple-system, "SF Pro Display", "Segoe UI", 'Inter', system-ui, sans-serif;
  color: var(--dark);
  background: var(--bg);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
a { text-decoration: none; color: inherit; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
/* Scroll suave (2026: movimiento que acompaña), desactivable por accesibilidad */
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 12px 24px; border-radius: 12px; font-weight: 600; font-size: 14px;
  cursor: pointer; border: none; transition: all 0.2s; white-space: nowrap;
}
.btn-primary { position: relative; overflow: hidden; background: var(--primary-text); color: #fff; box-shadow: var(--shadow-primary); }  /* fondo accesible AA con texto blanco */
.btn-primary:hover { background: var(--primary-dark); transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.btn-primary:active { transform: translateY(0) scale(0.98); }
/* Brillo sutil que cruza el botón al pasar el cursor (micro-interacción 2026) */
.btn-primary::before { content: ""; position: absolute; top: 0; left: -130%; width: 55%; height: 100%; background: linear-gradient(120deg, transparent, rgba(255,255,255,0.35), transparent); transform: skewX(-20deg); pointer-events: none; }
.btn-primary:hover::before { animation: btnShine 0.8s ease; }
@keyframes btnShine { to { left: 150%; } }
@media (prefers-reduced-motion: reduce) { .btn-primary:hover::before { animation: none; } }
.btn-ghost { background: transparent; color: var(--dark); }
.btn-ghost:hover { background: var(--bg-alt); }
.btn-lg { padding: 16px 32px; font-size: 16px; }
.btn-search { padding: 14px 32px; }

/* ===== HEADER ===== */
.header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255,255,255,0.85); backdrop-filter: saturate(1.4) blur(12px); -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid var(--border); transition: box-shadow var(--dur) var(--ease);
}
.header.scrolled { box-shadow: var(--shadow); }
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 68px; gap: 20px; }
.logo { display: flex; align-items: center; gap: 8px; font-weight: 800; font-size: 22px; flex-shrink: 0; }
.logo-icon { font-size: 24px; }
.logo-text { color: var(--primary-text); }

/* Header search (Webel style, centered pill) */
.header-search {
  display: flex; align-items: center; background: #fff; border: 1px solid var(--border);
  border-radius: 30px; padding: 4px; box-shadow: var(--shadow); flex: 1; max-width: 520px;
}
.hs-field { flex: 1; padding: 0 16px; }
.hs-field input { border: none; outline: none; font-family: inherit; font-size: 14px; width: 100%; padding: 8px 0; }
.hs-loc { border-left: 1px solid var(--border); }
.hs-btn { border-radius: 24px; padding: 10px 24px; }

.header-actions { display: flex; gap: 16px; align-items: center; flex-shrink: 0; }
.nav-link { font-weight: 600; color: var(--navy); font-size: 14px; }
.nav-link:hover { color: var(--primary); }
.btn-account { background: #fff; border: 1px solid var(--border); color: var(--navy); border-radius: 24px; box-shadow: var(--shadow); }

/* Category pills bar */
.cat-bar { border-top: 1px solid var(--border); background: #fff; position: relative; z-index: 90; }
.cat-bar-inner { display: flex; gap: 10px; padding: 12px 20px; justify-content: center; flex-wrap: wrap; }
.cat-pill {
  display: flex; align-items: center; gap: 6px; padding: 8px 16px; border-radius: 24px;
  background: #fff; border: 1px solid var(--border); font-size: 13px; font-weight: 600;
  color: var(--navy); white-space: nowrap; cursor: pointer; transition: all 0.2s; box-shadow: var(--shadow);
}
.cat-pill:hover { border-color: var(--primary); color: var(--primary-text); }
.cat-pill .p-icon { font-size: 16px; }
.pill-caret { font-size: 10px; opacity: 0.6; }

/* Category dropdown */
.cat-pill-wrap { position: relative; }
.cat-dropdown {
  display: none; position: absolute; top: calc(100% + 8px); left: 50%; transform: translateX(-50%);
  background: #fff; border-radius: 14px; box-shadow: var(--shadow-lg); padding: 8px;
  min-width: 200px; z-index: 200; border: 1px solid var(--border);
}
.cat-pill-wrap:hover .cat-dropdown { display: block; }
.cat-dropdown::before { content: ''; position: absolute; top: -8px; left: 0; right: 0; height: 8px; }
.cat-dropdown-item {
  display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-radius: 10px;
  font-size: 14px; font-weight: 500; color: var(--navy); transition: background 0.15s;
}
.cat-dropdown-item:hover { background: var(--mint); color: var(--primary-dark); }
.cat-dropdown-item span { font-size: 18px; }

/* Wide dropdown with columns (Clases) */
.cat-dropdown-wide { gap: 4px; min-width: 640px; padding: 14px; }
.cat-pill-wrap:hover .cat-dropdown-wide { display: flex; }
.cat-dropdown-col { flex: 1; min-width: 120px; }
.cat-dropdown-head { font-size: 12px; font-weight: 700; color: var(--gray); text-transform: uppercase; letter-spacing: 0.5px; padding: 6px 10px; margin-bottom: 4px; }
.cat-dropdown-item.small { padding: 7px 10px; font-size: 13px; }
@media (max-width: 900px) { .cat-dropdown-wide { min-width: auto; flex-wrap: wrap; } }

/* ===== HERO (limpio, buscador protagonista) ===== */
.hero {
  position: relative; min-height: 420px;
  background: radial-gradient(1200px 500px at 50% -10%, #3B82F6 0%, #2563EB 40%, #1E3A8A 100%);
  overflow: hidden; text-align: center; padding: 64px 0 72px;
}
/* Patrón decorativo sutil (puntos), no distrae */
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: 0; opacity: 0.10;
  background-image: radial-gradient(#fff 1.4px, transparent 1.4px);
  background-size: 26px 26px;
}
/* Formas animadas de fondo (blobs) — look moderno con movimiento sutil */
.hero-blobs { position: absolute; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }
.hero-blob { position: absolute; border-radius: 50%; filter: blur(40px); opacity: 0.35; }
.hero-blob.b1 { width: 320px; height: 320px; background: #60A5FA; top: -80px; left: -60px; animation: blobMove 14s ease-in-out infinite; }
.hero-blob.b2 { width: 260px; height: 260px; background: #93C5FD; bottom: -70px; right: -40px; animation: blobMove 18s ease-in-out infinite reverse; }
.hero-blob.b3 { width: 200px; height: 200px; background: #3B82F6; top: 40%; right: 20%; animation: blobMove 22s ease-in-out infinite; }
@keyframes blobMove {
  0%,100% { transform: translate(0,0) scale(1); }
  33% { transform: translate(40px,30px) scale(1.1); }
  66% { transform: translate(-30px,20px) scale(0.95); }
}
@media (prefers-reduced-motion: reduce) {
  .hero-blob { animation: none !important; }
}
.hero-overlay { position: relative; z-index: 2; color: #fff; padding: 0 20px; max-width: 820px; margin: 0 auto; }
/* Buscador central del hero (mezcla GetNinjas/Webel) */
.hero-search-box { display: flex; gap: 8px; background: #fff; border-radius: var(--radius-pill); padding: 8px; box-shadow: var(--shadow-lg); max-width: 640px; margin: 28px auto 0; transition: box-shadow var(--dur) var(--ease), transform var(--dur) var(--ease); }
.hero-search-box:focus-within { box-shadow: 0 0 0 4px rgba(147,197,253,0.5), var(--shadow-lg); transform: translateY(-2px); }
.hsb-btn { position: relative; overflow: hidden; }
.hsb-btn::after { content: ""; position: absolute; top: 0; left: -120%; width: 60%; height: 100%; background: linear-gradient(120deg, transparent, rgba(255,255,255,0.35), transparent); transform: skewX(-20deg); }
.hero-search-box:hover .hsb-btn::after { animation: shine 0.9s ease; }
@keyframes shine { to { left: 140%; } }
.hsb-field { display: flex; align-items: center; gap: 8px; flex: 1; padding: 0 10px; }
.hsb-field.hsb-zone { flex: 0 0 34%; border-left: 1px solid var(--border); }
.hsb-icon { font-size: 16px; flex-shrink: 0; }
.hsb-field input { border: none; outline: none; width: 100%; font-family: inherit; font-size: var(--fs-base); color: var(--dark); background: transparent; min-height: 44px; }
.hsb-btn { border-radius: var(--radius-pill); padding: 0 24px; min-height: 48px; flex-shrink: 0; }
.hero-overlay h1 { font-size: 44px; font-weight: 800; margin-bottom: 14px; line-height: 1.12; letter-spacing: -0.5px; text-shadow: 0 2px 12px rgba(0,0,0,0.12); }
.hero-overlay p { font-size: 18px; opacity: 0.95; margin-bottom: 4px; }
.highlight { color: var(--primary-text); }

/* Accesos directos por categoría bajo el buscador (iconos circulares limpios) */
.hero-cats { display: flex; gap: 18px; flex-wrap: wrap; justify-content: center; margin-top: 26px; }
.hero-cat { display: flex; flex-direction: column; align-items: center; gap: 8px; color: #fff; text-decoration: none; width: 76px; transition: transform var(--dur) var(--ease); animation: heroCatIn 0.5s var(--ease-out) both; }
.hero-cat:nth-child(1){animation-delay:.35s}.hero-cat:nth-child(2){animation-delay:.41s}
.hero-cat:nth-child(3){animation-delay:.47s}.hero-cat:nth-child(4){animation-delay:.53s}
.hero-cat:nth-child(5){animation-delay:.59s}.hero-cat:nth-child(6){animation-delay:.65s}
.hero-cat:nth-child(7){animation-delay:.71s}
@keyframes heroCatIn { from { opacity:0; transform: translateY(12px) scale(0.9); } to { opacity:1; transform: translateY(0) scale(1); } }
.hero-cat:hover { transform: translateY(-4px); }
.hero-cat:hover .hc-ic { transform: scale(1.1) rotate(-4deg); }
.hero-cat .hc-ic { width: 60px; height: 60px; border-radius: 20px; background: rgba(255,255,255,0.16); backdrop-filter: blur(6px); display: flex; align-items: center; justify-content: center; font-size: 28px; box-shadow: var(--shadow); transition: background var(--dur) var(--ease), transform var(--dur) var(--ease); }
.hero-cat:hover .hc-ic { background: rgba(255,255,255,0.28); }
.hero-cat .hc-lb { font-size: 12px; font-weight: 600; opacity: 0.95; }

@media (max-width: 600px){
  .hero-search-box { flex-direction: column; border-radius: var(--radius); }
  .hsb-field.hsb-zone { border-left: none; border-top: 1px solid var(--border); }
  .hsb-btn { width: 100%; }
  .hero-overlay h1 { font-size: 32px; }
  .hero-cat { width: 68px; }
  .hero-cat .hc-ic { width: 52px; height: 52px; font-size: 24px; }
}

/* Entrada del hero (aparece suave al cargar) */
.hero-overlay h1 { animation: heroIn 0.7s var(--ease-out) both; }
.hero-overlay p { animation: heroIn 0.7s var(--ease-out) 0.1s both; }
.hero-search-box { animation: heroIn 0.7s var(--ease-out) 0.2s both; }
.hero-cats { animation: heroIn 0.7s var(--ease-out) 0.3s both; }
@keyframes heroIn { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }

/* Aparición de secciones al hacer scroll (estilo Webel) */
.reveal { opacity: 0; transform: translateY(30px); transition: opacity 0.6s var(--ease-out), transform 0.6s var(--ease-out); }
.reveal.in { opacity: 1; transform: translateY(0); }

/* ===== SECTIONS ===== */
.section { padding: 70px 0; }
.section-alt { background: var(--bg-alt); }
.section-title { font-size: 36px; font-weight: 800; text-align: center; margin-bottom: 8px; letter-spacing: -0.5px; color: var(--navy); }
.section-sub { text-align: center; color: var(--gray); font-size: 16px; margin-bottom: 48px; }
/* Eyebrow: etiqueta pequeña sobre el título (patrón editorial profesional) */
.section-eyebrow { display: block; text-align: center; color: var(--primary-text); font-size: 12px; font-weight: 800; letter-spacing: 1.5px; text-transform: uppercase; margin-bottom: 10px; }

/* ===== STEPS ===== */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.step { text-align: center; padding: 20px; position: relative; }
.step-visual { position: relative; width: 96px; height: 96px; border-radius: 28px; display: flex; align-items: center; justify-content: center; font-size: 42px; margin: 0 auto 22px; box-shadow: var(--shadow-lg); background: linear-gradient(135deg, var(--primary), var(--primary-dark)); transition: transform var(--dur) var(--ease); }
.step:hover .step-visual { transform: translateY(-6px) scale(1.04); }
.step-num { position: absolute; top: -8px; right: -8px; width: 30px; height: 30px; border-radius: 50%; background: #fff; color: var(--primary-text); font-size: 15px; font-weight: 800; display: flex; align-items: center; justify-content: center; box-shadow: var(--shadow); border: 2px solid var(--mint); }
.step h3 { font-size: 19px; margin-bottom: 10px; color: var(--navy); }
.step p { color: var(--gray); font-size: 14px; max-width: 280px; margin: 0 auto; }
/* Línea conectora entre pasos (desktop) */
.steps-connected .step:not(:last-child)::after {
  content: ""; position: absolute; top: 68px; right: -16px; width: 32px; height: 2px;
  background: repeating-linear-gradient(90deg, var(--primary-light) 0 6px, transparent 6px 12px);
}
@media (max-width: 900px) { .steps-connected .step::after { display: none; } }

/* ===== BANNER ===== */
.banner { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.banner-img { border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-md); position: relative; }
.banner-img img { width: 100%; height: 360px; object-fit: cover; display: block; transition: transform 0.6s var(--ease-out); }
.banner-img:hover img { transform: scale(1.04); }
.banner-text h2 { font-size: 32px; font-weight: 800; color: var(--navy); margin-bottom: 16px; line-height: 1.2; letter-spacing: -0.5px; }
.banner-text p { color: var(--gray); margin-bottom: 24px; font-size: 16px; }

/* ===== APP SECTION ===== */
.app-section { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; }
.app-text h2 { font-size: 32px; font-weight: 800; color: var(--navy); margin-bottom: 12px; }
.app-text p { color: var(--gray); margin-bottom: 20px; }
.app-badges { display: flex; gap: 12px; }
.app-badge { background: var(--navy); color: #fff; padding: 12px 20px; border-radius: 12px; font-size: 13px; font-weight: 600; }
.app-phone { font-size: 160px; text-align: center; }

/* ===== TRUST BAR (bajo el hero) ===== */
.trust-bar { background: #fff; border-bottom: 1px solid var(--border); position: relative; margin-top: -32px; z-index: 5; }
.trust-bar-inner { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; padding: 20px; background: #fff; border: 1px solid var(--border); border-radius: var(--radius-lg); box-shadow: var(--shadow-md); }
.trust-item { display: flex; align-items: center; gap: 12px; }
.trust-icon { font-size: 24px; width: 48px; height: 48px; border-radius: 14px; background: var(--mint); display: flex; align-items: center; justify-content: center; flex-shrink: 0; transition: transform var(--dur) var(--ease); }
.trust-item:hover .trust-icon { transform: scale(1.08); }
.trust-item strong { display: block; font-size: 14px; color: var(--navy); }
.trust-item div span { font-size: 12px; color: var(--gray); }
@media (max-width: 900px){ .trust-bar-inner { grid-template-columns: repeat(2, 1fr); gap: 14px; } }
@media (max-width: 480px){ .trust-bar-inner { grid-template-columns: 1fr; } }

/* ===== CATEGORIES ===== */
.categories-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.category-card {
  background: #fff; border-radius: var(--radius); padding: 28px 20px; text-align: center;
  box-shadow: var(--shadow); transition: all 0.2s; cursor: pointer; border: 1px solid var(--border);
}
.category-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: var(--primary); }
.category-icon { font-size: 42px; margin-bottom: 12px; display: inline-flex; align-items: center; justify-content: center; width: 72px; height: 72px; border-radius: 20px; background: var(--mint); transition: transform var(--dur) var(--ease); }
.category-card:hover .category-icon { transform: scale(1.08) rotate(-3deg); }
.category-card h3 { font-size: 16px; margin-bottom: 4px; color: var(--navy); }
.category-card p { font-size: 13px; color: var(--gray); margin-bottom: 10px; }
.cat-count { display: inline-block; font-size: 12px; font-weight: 700; color: var(--primary-text); background: var(--mint); padding: 4px 10px; border-radius: var(--radius-pill); }
.cat-count-soon { color: var(--gray); background: var(--bg-alt); }

/* ===== POPULAR ===== */
.popular-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.popular-card {
  background: #fff; border-radius: var(--radius); overflow: hidden;
  box-shadow: var(--shadow); transition: all 0.2s; cursor: pointer;
}
.popular-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.popular-card-img { height: 180px; position: relative; overflow: hidden; }
.popular-card-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s var(--ease-out); }
.popular-card:hover .popular-card-img img { transform: scale(1.08); }
/* Degradado inferior para legibilidad si el título va sobre la imagen */
.popular-card-img::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(16,33,74,0.35), transparent 55%); opacity: 0; transition: opacity var(--dur) var(--ease); }
.popular-card:hover .popular-card-img::after { opacity: 1; }
.popular-card-badge { position: absolute; top: 10px; left: 10px; background: var(--primary-text); color: #fff; font-size: 11px; padding: 4px 10px; border-radius: 8px; font-weight: 700; z-index: 2; }
.popular-card-body { padding: 14px; text-align: center; }
.popular-card-body h3 { font-size: 15px; color: var(--navy); font-weight: 600; }

/* ===== POSTS (imagen + texto alternado) — "Lo más solicitado" ===== */
.posts-list { max-width: 1000px; margin: 0 auto; display: flex; flex-direction: column; gap: 28px; }
.post-card { display: grid; grid-template-columns: 42% 1fr; gap: 28px; align-items: center; background: #fff; border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow); text-decoration: none; color: inherit; transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease); }
.post-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.post-card:nth-child(even) { grid-template-columns: 1fr 42%; }
.post-card:nth-child(even) .post-card-img { order: 2; }
.post-card-img { height: 240px; overflow: hidden; }
.post-card-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s var(--ease-out); }
.post-card:hover .post-card-img img { transform: scale(1.06); }
.post-card-body { padding: 28px; }
.post-card-body h3 { font-size: 22px; color: var(--navy); margin-bottom: 10px; }
.post-card-body p { color: var(--gray); margin-bottom: 16px; }
.post-card-cta { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; color: var(--primary-text); }
.post-card:hover .post-card-cta { gap: 10px; }
@media (max-width: 700px) {
  .post-card, .post-card:nth-child(even) { grid-template-columns: 1fr; }
  .post-card:nth-child(even) .post-card-img { order: 0; }
  .post-card-img { height: 200px; }
}

/* ===== WHY ===== */
.why-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.why-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 36px 28px; text-align: center; box-shadow: var(--shadow); transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease); }
.why-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.why-icon { font-size: 34px; margin: 0 auto 18px; width: 72px; height: 72px; border-radius: 20px; background: var(--mint); display: flex; align-items: center; justify-content: center; transition: transform var(--dur) var(--ease); }
.why-card:hover .why-icon { transform: scale(1.08) rotate(-4deg); }
.why-card h3 { font-size: 20px; margin-bottom: 10px; color: var(--navy); }
.why-card p { color: var(--gray); font-size: 15px; }

/* ===== STATS ===== */
.stats-section { background: var(--navy); color: #fff; }
.stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; text-align: center; }
.stat strong { display: block; font-size: 42px; font-weight: 800; }
.stat span { font-size: 15px; opacity: 0.85; }

/* ===== TESTIMONIALS ===== */
.testimonials, .testimonials-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.testimonial-author .t-badge { width: 44px; height: 44px; border-radius: 50%; background: var(--mint); color: var(--success-text); display: flex; align-items: center; justify-content: center; font-size: 20px; flex-shrink: 0; }
/* Redes sociales del footer */
.footer-social { display: flex; gap: 10px; margin-top: 14px; }
.footer-social a { width: 44px; height: 44px; border-radius: 50%; background: rgba(255,255,255,0.1); display: flex; align-items: center; justify-content: center; font-size: 20px; transition: background var(--dur) var(--ease); }
.footer-social a:hover { background: rgba(255,255,255,0.2); }
.testimonial { background: #fff; border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); border: 1px solid var(--border); }
.testimonial-stars { color: var(--warning); margin-bottom: 12px; }
.testimonial-text { color: var(--dark); font-size: 15px; margin-bottom: 16px; }
.testimonial-author { display: flex; align-items: center; gap: 10px; }
.testimonial-author .avatar { font-size: 32px; }
.testimonial-author .t-avatar { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; }
.testimonial-author strong { font-size: 14px; display: block; }
.testimonial-author span { font-size: 13px; color: var(--gray); }

/* ===== CTA PRO ===== */
.cta-pro { background: linear-gradient(135deg, var(--primary), var(--primary-dark)); color: #fff; }
.cta-pro h2 { color: #fff; }
.cta-pro-inner { display: flex; align-items: center; justify-content: space-between; gap: 40px; }
.cta-pro h2 { font-size: 32px; margin-bottom: 12px; }
.cta-pro p { font-size: 16px; opacity: 0.9; margin-bottom: 24px; max-width: 500px; }
.cta-pro .btn-primary { background: #fff; color: var(--primary-text); }
.cta-pro .btn-primary:hover { background: var(--bg-alt); }
.cta-pro-icon { font-size: 120px; }

/* ===== FOOTER ===== */
.footer { background: var(--dark); color: #fff; padding: 50px 0 0; }
.footer-inner { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 32px; padding-bottom: 40px; }
.footer-brand p { color: var(--light-gray); font-size: 14px; margin-top: 12px; max-width: 260px; }
.footer-brand .logo-text { color: #fff; }
.footer-col h4 { font-size: 15px; margin-bottom: 16px; }
.footer-col a { display: block; color: var(--light-gray); font-size: 14px; margin-bottom: 10px; transition: color 0.2s; }
.footer-col a:hover { color: #fff; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.1); padding: 20px 0; text-align: center; font-size: 13px; color: var(--light-gray); }

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero h1 { font-size: 36px; }
  .hero-image { display: none; }
  .steps, .why-grid, .testimonials, .testimonials-grid { grid-template-columns: 1fr; }
  .categories-grid, .popular-grid { grid-template-columns: repeat(2, 1fr); }
  .stats-grid { grid-template-columns: 1fr; gap: 32px; }
  .nav { display: none; }
  .footer-inner { grid-template-columns: 1fr 1fr; }
  .cta-pro-inner { flex-direction: column; text-align: center; }
  .cta-pro-icon { font-size: 80px; }
}

/* ===== QR MODAL ===== */
.modal-overlay {
  display: none; position: fixed; inset: 0; z-index: 1000;
  background: rgba(27,42,74,0.5); backdrop-filter: blur(4px);
  align-items: center; justify-content: center;
}
.modal-overlay.open { display: flex; }
.modal-box {
  background: #fff; border-radius: 20px; padding: 36px; max-width: 420px; width: 90%;
  text-align: center; position: relative; box-shadow: var(--shadow-lg);
}
.modal-box h3 { font-size: 22px; color: var(--navy); margin-bottom: 8px; }
.modal-sub { color: var(--gray); font-size: 14px; margin: 8px 0 16px; }
.modal-close { position: absolute; top: 16px; right: 16px; background: var(--bg-alt); border: none; width: 32px; height: 32px; border-radius: 50%; cursor: pointer; font-size: 14px; color: var(--gray); }
.qr-code { display: flex; justify-content: center; margin: 20px 0; }
.qr-code img { border-radius: 12px; }
.modal-badges { display: flex; gap: 12px; justify-content: center; margin-top: 12px; }

/* ===== GUARANTEE ===== */
.guarantee-section { background: linear-gradient(135deg, var(--navy), #0f1c33); color: #fff; }
.guarantee-label { text-align: center; color: var(--primary-light); font-size: 12px; font-weight: 700; letter-spacing: 2px; margin-bottom: 12px; }
.guarantee-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 20px; }
.guarantee-card { background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.1); border-radius: var(--radius); padding: 28px; text-align: center; }
.guarantee-card .g-icon { font-size: 40px; margin-bottom: 14px; }
.guarantee-card h3 { font-size: 17px; margin-bottom: 8px; }
.guarantee-card p { color: rgba(255,255,255,0.75); font-size: 14px; }

/* ===== PRESS ===== */
.press-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-top: 20px; }
.press-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; font-size: 14px; color: var(--navy); font-style: italic; box-shadow: var(--shadow); }
.press-card span { display: block; margin-top: 12px; font-style: normal; font-weight: 700; color: var(--primary); font-size: 13px; }

@media (max-width: 900px) {
  .guarantee-grid, .press-grid { grid-template-columns: 1fr; }
  .banner, .app-section { grid-template-columns: 1fr; }
}

/* ===== ESTADOS: loading / empty / error (MVP transaccional) ===== */
.state-loading { display: grid; grid-template-columns: 1fr 360px; gap: 32px; }
@media (max-width: 900px) { .state-loading { grid-template-columns: 1fr; } }
/* Empty state con marca (ícono en círculo + título + CTA) */
.empty-state { text-align: center; padding: var(--sp-10) var(--sp-5); }
.empty-state .es-icon {
  width: 88px; height: 88px; margin: 0 auto var(--sp-4); border-radius: 50%;
  background: var(--mint); display: flex; align-items: center; justify-content: center; font-size: 40px;
}
.empty-state h3 { font-size: var(--fs-md); color: var(--navy); font-weight: 800; margin-bottom: var(--sp-2); }
.empty-state p { font-size: var(--fs-sm); color: var(--gray); max-width: 300px; margin: 0 auto var(--sp-4); line-height: 1.5; }
.empty-state .btn { display: inline-flex; }

.state-empty, .state-error {
  text-align: center; padding: 40px; border-radius: var(--radius);
  color: var(--gray); background: var(--bg-alt); border: 1px solid var(--border);
}
.state-error { color: var(--danger); background: #FDECEC; border-color: #F5C6C6; }
.state-error .btn, .state-empty .btn { margin-top: 12px; }

/* Skeletons */
.skeleton {
  background: linear-gradient(90deg, #eee 25%, #f5f5f5 50%, #eee 75%);
  background-size: 200% 100%; animation: sk 1.2s infinite; border-radius: 12px;
}
@keyframes sk { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
.skeleton-card { height: 96px; margin-bottom: 14px; }
.skeleton-line { height: 20px; margin-bottom: 10px; }
.skeleton-side { height: 320px; }
/* Skeleton con forma de tarjeta de servicio (mejora percepción de carga) */
.sk-pro { display: flex; gap: var(--sp-4); align-items: center; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: var(--sp-4); margin-bottom: var(--sp-3); }
.sk-pro .sk-av { width: 60px; height: 60px; border-radius: 50%; flex-shrink: 0; }
.sk-pro .sk-body { flex: 1; }
.sk-pro .sk-l { height: 16px; border-radius: 8px; margin-bottom: 10px; }
.sk-pro .sk-l.w60 { width: 60%; } .sk-pro .sk-l.w40 { width: 40%; } .sk-pro .sk-l.w80 { width: 80%; }
.sk-pro .sk-av, .sk-pro .sk-l { background: linear-gradient(90deg, #eef1f6 25%, #f6f8fb 50%, #eef1f6 75%); background-size: 200% 100%; animation: sk 1.2s infinite; }

/* Toasts (reemplazan alert/confirm/prompt) */
.toast {
  position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%) translateY(20px);
  background: var(--navy); color: #fff; padding: 12px 20px; border-radius: 12px;
  font-size: 14px; font-weight: 500; box-shadow: var(--shadow-lg); z-index: 2000;
  opacity: 0; transition: all 0.3s ease; max-width: 90%;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.toast-error { background: var(--danger); }
.toast-success { background: var(--success); }
.toast-info { background: var(--navy); }

/* ===== PWA install button ===== */
.pwa-install {
  position: fixed; bottom: 20px; right: 20px; z-index: 1500;
  background: var(--primary); color: #fff; border: none; border-radius: 24px;
  padding: 12px 18px; font-size: 14px; font-weight: 600; cursor: pointer;
  box-shadow: var(--shadow-lg); font-family: inherit;
  display: flex; align-items: center; gap: 6px; transition: all 0.2s;
}
.pwa-install:hover { background: var(--primary-dark); transform: translateY(-2px); }
@media (max-width: 600px) { .pwa-install { bottom: 14px; right: 14px; padding: 10px 14px; } }

/* ===== Menú móvil (hamburguesa) — M089/M090 ===== */
.hamburger {
  display: none; background: none; border: none; cursor: pointer;
  width: 40px; height: 40px; padding: 8px; flex-direction: column;
  justify-content: space-between; flex-shrink: 0;
}
.hamburger span {
  display: block; height: 3px; width: 100%; background: var(--navy);
  border-radius: 2px; transition: all 0.25s;
}
.hamburger[aria-expanded="true"] span:nth-child(1) { transform: translateY(9px) rotate(45deg); }
.hamburger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.hamburger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-9px) rotate(-45deg); }

@media (max-width: 820px) {
  .hamburger { display: flex; }
  .header-search { display: none; }
  /* Acciones se colapsan en un panel desplegable */
  .header-actions {
    position: absolute; top: 68px; right: 0; left: 0;
    background: #fff; border-bottom: 1px solid var(--border);
    flex-direction: column; align-items: stretch; gap: 0;
    padding: 8px 20px; box-shadow: var(--shadow-lg);
    max-height: 0; overflow: hidden; padding-top: 0; padding-bottom: 0;
    transition: max-height 0.25s ease, padding 0.25s ease; z-index: 95;
  }
  .header-actions.open { max-height: 360px; padding-top: 12px; padding-bottom: 12px; }
  .header-actions .nav-link,
  .header-actions .btn-account { padding: 12px 0; width: 100%; text-align: left; border-radius: 8px; }
  .header-actions .btn-account { margin-top: 6px; text-align: center; }
}

/* Respeta preferencia de menos movimiento (accesibilidad — M191) */
@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

/* ===== QR lateral en sección app ===== */
.app-qr-side {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 20px; box-shadow: var(--shadow); width: fit-content; margin: 0 auto;
}
.app-qr-side img { border-radius: 12px; display: block; }
.app-qr-side span { font-size: 13px; color: var(--gray); font-weight: 600; }
.app-badges { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
@media (max-width: 900px) { .app-qr-side { margin-top: 20px; } }

/* ===== Modal de descarga: tabs Android / iPhone ===== */
.dl-tabs { display: flex; gap: 8px; margin: 16px 0; }
.dl-tab {
  flex: 1; padding: 10px; border: 1px solid var(--border); background: var(--bg-alt);
  border-radius: 10px; font-family: inherit; font-size: 14px; font-weight: 600;
  color: var(--gray); cursor: pointer; transition: all 0.2s;
}
.dl-tab.active { background: var(--primary-text); color: #fff; border-color: var(--primary-text); }
.ios-steps {
  text-align: left; margin: 16px auto; max-width: 300px; padding-left: 20px;
  color: var(--navy); font-size: 14px; line-height: 1.7;
}
.ios-steps li { margin-bottom: 6px; }

/* ===== MODO APP (PWA/APK instalada): experiencia tipo app nativa ===== */
/* Barra de navegación inferior */
.bottom-nav {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 1200;
  display: flex; background: #fff; border-top: 1px solid var(--border);
  padding-bottom: env(safe-area-inset-bottom, 0); /* respeta el notch/home bar */
  box-shadow: 0 -4px 20px rgba(31,37,68,0.06);
}
.bn-item {
  flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 2px; padding: 8px 0 10px; color: var(--gray); font-size: 11px; font-weight: 600;
  text-decoration: none; transition: color 0.15s;
}
.bn-item .bn-icon { font-size: 22px; line-height: 1; filter: grayscale(0.4); transition: all 0.15s; }
.bn-item.active { color: var(--primary-text); }
.bn-item.active .bn-icon { filter: none; transform: translateY(-1px); }

/* En modo app: dar espacio abajo para la barra, y ocultar el footer web */
body.app-mode { padding-bottom: 64px; }
body.app-mode .footer { display: none; }
/* En modo app, el header sticky se hace más compacto y sin buscador duplicado */
body.app-mode .cat-bar { position: static; }

@media (min-width: 900px) {
  /* En escritorio nunca mostramos la barra inferior aunque se fuerce */
  .bottom-nav { max-width: 480px; margin: 0 auto; border-radius: 20px 20px 0 0; }
}

/* ===== HOME TIPO APP — rediseño profesional ===== */
/* Principios: jerarquía clara, buscador prominente, grid ordenado (no absolute frágil),
   espaciado consistente (escala 4/8), microinteracciones sutiles, contraste AA. */
.app-home { padding: 0; max-width: 480px; margin: 0 auto; }

/* Hero compacto con degradado y curva inferior */
.ah-hero {
  position: relative; background: linear-gradient(160deg, #3B82F6 0%, #1E40AF 100%);
  padding: calc(env(safe-area-inset-top, 0) + var(--sp-4)) var(--sp-5) var(--sp-8);
  border-radius: 0 0 28px 28px; overflow: hidden;
}
.ah-hero-top { display: flex; align-items: center; justify-content: space-between; position: relative; z-index: 2; }
.ah-brand { color: #fff; font-weight: 800; font-size: var(--fs-xl); display: flex; align-items: center; gap: var(--sp-2); letter-spacing: -0.5px; }
.ah-gift {
  width: 42px; height: 42px; border-radius: 50%; border: none; background: rgba(255,255,255,0.2);
  color: #fff; font-size: 18px; cursor: pointer; backdrop-filter: blur(4px); transition: transform var(--dur) var(--ease);
}
.ah-gift:active { transform: scale(0.9); }
.ah-loc {
  margin-top: var(--sp-2); background: transparent; border: none; color: rgba(255,255,255,0.95);
  font-weight: 600; font-size: var(--fs-sm); cursor: pointer; padding: 0; position: relative; z-index: 2;
}
.ah-loc span { opacity: 0.75; }
/* M de marca translúcida, decorativa */
.ah-letter {
  position: absolute; top: 50%; right: -20px; transform: translateY(-40%);
  font-size: 220px; font-weight: 900; color: rgba(255,255,255,0.10); line-height: 1;
  pointer-events: none; user-select: none; z-index: 1;
}
/* Buscador prominente (CTA principal de descubrimiento) */
.ah-searchbar {
  position: relative; z-index: 2; margin-top: var(--sp-5);
  display: flex; align-items: center; gap: var(--sp-3);
  background: #fff; border-radius: var(--radius); padding: var(--sp-4) var(--sp-4);
  box-shadow: var(--shadow-lg); text-decoration: none;
}
.ah-searchbar .ic { font-size: 20px; }
.ah-searchbar .tx { color: var(--gray); font-size: var(--fs-base); font-weight: 500; }
.ah-searchbar { animation: heroIn 0.6s var(--ease-out) 0.15s both; }

/* Título de sección */
.ah-h { font-size: var(--fs-md); font-weight: 800; color: var(--navy); margin: var(--sp-6) var(--sp-5) var(--sp-4); letter-spacing: -0.3px; }

/* Grid ordenado de categorías (3 columnas, tarjetas — robusto, no absolute) */
.ah-cats { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--sp-3); padding: 0 var(--sp-5); }
.ah-cat {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: var(--sp-2);
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: var(--sp-4) var(--sp-2);
  text-decoration: none; color: var(--navy); box-shadow: var(--shadow-xs);
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease); min-height: 88px;
}
.ah-cat:active { transform: scale(0.95); box-shadow: var(--shadow-md); }
/* Entrada escalonada de las tarjetas (sensación app nativa) */
.ah-cat { animation: ahCatIn 0.5s var(--ease-out) both; }
.ah-cat:nth-child(1){animation-delay:.03s}.ah-cat:nth-child(2){animation-delay:.06s}
.ah-cat:nth-child(3){animation-delay:.09s}.ah-cat:nth-child(4){animation-delay:.12s}
.ah-cat:nth-child(5){animation-delay:.15s}.ah-cat:nth-child(6){animation-delay:.18s}
.ah-cat:nth-child(7){animation-delay:.21s}
@keyframes ahCatIn { from { opacity:0; transform: translateY(14px); } to { opacity:1; transform: translateY(0); } }
.ah-cat-ic {
  width: 48px; height: 48px; display: flex; align-items: center; justify-content: center;
  font-size: 26px; background: var(--mint); border-radius: 14px;
  transition: transform var(--dur) var(--ease);
}
.ah-cat:active .ah-cat-ic { transform: scale(1.1); }
.ah-cat-lb { font-size: var(--fs-xs); font-weight: 700; text-align: center; line-height: 1.2; }

/* Tarjeta repetir servicio */
.ah-repeat { padding: 0 var(--sp-5); margin-top: var(--sp-6); }
.ah-repeat-card {
  display: flex; align-items: center; justify-content: space-between; gap: var(--sp-3);
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: var(--sp-4);
  box-shadow: var(--shadow); text-decoration: none; color: var(--navy);
  transition: transform var(--dur) var(--ease);
}
.ah-repeat-card:active { transform: scale(0.98); }
.ah-repeat-info { display: flex; flex-direction: column; gap: 2px; }
.ah-repeat-info small { color: var(--primary-text); font-size: var(--fs-xs); font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; }
.ah-repeat-info strong { font-size: var(--fs-base); }
.ah-repeat-info span { color: var(--gray); font-size: var(--fs-xs); }
.ah-repeat-btn { background: var(--primary); color: #fff; padding: var(--sp-3) var(--sp-5); border-radius: var(--radius-sm); font-weight: 700; font-size: var(--fs-sm); box-shadow: var(--shadow-primary); }

/* ===== Desglose de precio (reserva) ===== */
.price-breakdown { margin: var(--sp-4) 0 var(--sp-2); padding-top: var(--sp-4); border-top: 1px solid var(--border); }
.pb-row { display: flex; justify-content: space-between; font-size: var(--fs-sm); color: var(--gray); padding: var(--sp-2) 0; }
.pb-free { color: var(--success); font-weight: 600; }
.pb-total { border-top: 1px solid var(--border); margin-top: var(--sp-2); padding-top: var(--sp-3); font-size: var(--fs-md); font-weight: 800; color: var(--navy); }

/* ===== Modal de confirmación de reserva ===== */
.confirm-summary { background: var(--bg-alt); border-radius: var(--radius); padding: var(--sp-4); margin: var(--sp-4) 0; text-align: left; }
.cs-row { display: flex; justify-content: space-between; align-items: baseline; gap: var(--sp-4); padding: var(--sp-2) 0; font-size: var(--fs-sm); }
.cs-row span { color: var(--gray); flex-shrink: 0; }
.cs-row strong { color: var(--navy); text-align: right; }
.cs-total { border-top: 1px solid var(--border); margin-top: var(--sp-2); padding-top: var(--sp-3); font-size: var(--fs-md); }
.cs-total strong { color: var(--primary-text); }

/* ===== SPLASH SCREEN (app instalada) ===== */
.app-splash {
  position: fixed; inset: 0; z-index: 3000;
  background: linear-gradient(160deg, #3B82F6 0%, #1E40AF 100%);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: var(--sp-3);
  opacity: 1; transition: opacity 0.4s var(--ease);
}
.app-splash.hide { opacity: 0; pointer-events: none; }
.splash-logo { display: flex; align-items: center; gap: var(--sp-2); animation: splashIn 0.5s var(--ease-out); }
.splash-icon { font-size: 52px; }
.splash-name { font-size: 42px; font-weight: 800; color: #fff; letter-spacing: -1px; }
.splash-tag { color: rgba(255,255,255,0.85); font-size: var(--fs-base); font-weight: 500; animation: splashIn 0.7s var(--ease-out); }
@keyframes splashIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
@media (prefers-reduced-motion: reduce) { .splash-logo, .splash-tag { animation: none; } }

/* ===== Sub-pestañas (Próximos / Pasados / Cancelados) ===== */
.sub-tabs { display: flex; gap: var(--sp-2); border-bottom: 1px solid var(--border); margin-bottom: var(--sp-5); }
.sub-tab {
  flex: 1; background: none; border: none; padding: var(--sp-3) var(--sp-2); font-family: inherit;
  font-size: var(--fs-sm); font-weight: 600; color: var(--gray); cursor: pointer;
  border-bottom: 2px solid transparent; transition: color var(--dur) var(--ease), border-color var(--dur) var(--ease);
  min-height: 44px;
}
.sub-tab.active { color: var(--primary-text); border-bottom-color: var(--primary); }
.sub-tab:hover { color: var(--navy); }

/* ===== Cuenta: cabecera de usuario + banner de referidos ===== */
.acc-user { display: flex; align-items: center; gap: var(--sp-4); margin: var(--sp-5) 0 var(--sp-4); }
.acc-avatar {
  width: 60px; height: 60px; border-radius: 50%; background: var(--mint); color: var(--primary-text);
  display: flex; align-items: center; justify-content: center; font-size: 26px; font-weight: 800; flex-shrink: 0;
}
.acc-uname { font-size: var(--fs-lg); font-weight: 800; color: var(--navy); letter-spacing: -0.3px; }
.acc-usub { font-size: var(--fs-sm); color: var(--gray); }
.acc-referral {
  display: flex; align-items: center; justify-content: space-between; gap: var(--sp-4);
  background: linear-gradient(135deg, var(--primary), var(--primary-dark)); color: #fff;
  border-radius: var(--radius); padding: var(--sp-4) var(--sp-5); margin-bottom: var(--sp-5); box-shadow: var(--shadow-primary);
}
.acc-referral strong { font-size: var(--fs-base); }
.acc-referral p { font-size: var(--fs-sm); opacity: 0.9; margin-top: 2px; }
.acc-referral .btn { background: #fff; color: var(--primary); font-weight: 700; flex-shrink: 0; }

/* ===== Transición de entrada de página (modo app) ===== */
body.app-mode.page-enter { animation: pageEnter 0.28s var(--ease-out); }
@keyframes pageEnter { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
@media (prefers-reduced-motion: reduce) { body.app-mode.page-enter { animation: none; } }

/* ===== ONBOARDING DE BIENVENIDA (primera vez, modo app) ===== */
body.ob-open { overflow: hidden; }
.onboarding {
  position: fixed; inset: 0; z-index: 2000;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: var(--sp-8) var(--sp-6) calc(var(--sp-8) + env(safe-area-inset-bottom));
  background: linear-gradient(160deg, var(--bg-alt) 0%, var(--mint) 100%);
  text-align: center;
  animation: obFade var(--dur) var(--ease);
}
.onboarding.hide { animation: obFadeOut var(--dur) var(--ease) forwards; }
@keyframes obFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes obFadeOut { from { opacity: 1; } to { opacity: 0; } }

.ob-skip {
  position: absolute; top: calc(var(--sp-4) + env(safe-area-inset-top)); right: var(--sp-4);
  min-height: 44px; padding: var(--sp-2) var(--sp-4);
  background: transparent; border: none; cursor: pointer;
  color: var(--gray); font-size: var(--fs-sm); font-weight: 600;
}
.ob-skip:hover { color: var(--dark); }

.ob-viewport { flex: 1; display: flex; align-items: center; justify-content: center; width: 100%; max-width: 420px; position: relative; }
.ob-slide {
  position: absolute; width: 100%;
  display: none; flex-direction: column; align-items: center; gap: var(--sp-4);
  padding: 0 var(--sp-4);
}
.ob-slide.active { display: flex; animation: obSlideIn var(--dur) var(--ease-out); }
@keyframes obSlideIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }

.ob-icon {
  width: 96px; height: 96px; display: flex; align-items: center; justify-content: center;
  font-size: 48px; background: #fff; border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md); margin-bottom: var(--sp-2);
}
.ob-title { font-size: var(--fs-2xl); font-weight: 800; color: var(--navy); line-height: 1.15; }
.ob-text { font-size: var(--fs-md); color: var(--gray); max-width: 340px; line-height: 1.5; }

.ob-dots { display: flex; gap: var(--sp-2); justify-content: center; margin: var(--sp-6) 0; }
.ob-dot { width: 8px; height: 8px; border-radius: var(--radius-pill); background: var(--primary-light); transition: all var(--dur) var(--ease); }
.ob-dot.active { width: 24px; background: var(--primary-text); }

.ob-actions { width: 100%; max-width: 420px; }
.ob-actions .ob-next { width: 100%; }

@media (prefers-reduced-motion: reduce) {
  .onboarding, .onboarding.hide, .ob-slide.active { animation: none; }
  .ob-dot { transition: none; }
}

/* ===== Aviso Safari en modal iOS ===== */
.ios-warn {
  margin-top: var(--sp-3); padding: var(--sp-3) var(--sp-4);
  background: #FFF7E6; border: 1px solid #F2D9A0; border-radius: var(--radius-sm);
  color: var(--warning-text); font-size: var(--fs-sm); line-height: 1.45; text-align: left;
}

/* ===== Banner contextual iOS: "instálame desde Safari" ===== */
.ios-hint {
  position: fixed; left: var(--sp-3); right: var(--sp-3);
  bottom: calc(var(--sp-3) + env(safe-area-inset-bottom)); z-index: 1500;
  display: flex; align-items: center; gap: var(--sp-3);
  background: var(--navy); color: #fff; padding: var(--sp-4);
  border-radius: var(--radius); box-shadow: var(--shadow-lg);
  animation: iosHintIn var(--dur) var(--ease-out);
}
@keyframes iosHintIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
.ios-hint .ih-icon { font-size: 26px; flex-shrink: 0; }
.ios-hint .ih-body { flex: 1; font-size: var(--fs-sm); line-height: 1.4; }
.ios-hint .ih-body strong { display: block; font-size: var(--fs-base); margin-bottom: 2px; }
.ios-hint .ih-arrow { font-size: 20px; }
.ios-hint .ih-close {
  min-width: 44px; min-height: 44px; display: flex; align-items: center; justify-content: center;
  background: transparent; border: none; color: #fff; font-size: 20px; cursor: pointer; flex-shrink: 0;
}
@media (prefers-reduced-motion: reduce) { .ios-hint { animation: none; } }

/* ===== Actividad / Notificaciones (mensajes.html) ===== */
.notif-item {
  display: flex; align-items: flex-start; gap: var(--sp-3);
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: var(--sp-4); margin-bottom: var(--sp-3);
  box-shadow: var(--shadow-xs); text-decoration: none; color: var(--dark);
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
  min-height: 44px;
}
.notif-item:active { transform: scale(0.99); }
.notif-item:hover { box-shadow: var(--shadow-md); }
.notif-item.is-new { border-color: var(--primary-light); background: var(--mint); }
.notif-icon {
  flex-shrink: 0; width: 44px; height: 44px; display: flex; align-items: center; justify-content: center;
  font-size: 22px; background: var(--bg-alt); border-radius: var(--radius-sm);
}
.notif-item.is-new .notif-icon { background: #fff; }
.notif-body { flex: 1; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.notif-body strong { font-size: var(--fs-base); color: var(--navy); }
.notif-svc { font-size: var(--fs-xs); color: var(--primary-text); font-weight: 600; }
.notif-text { font-size: var(--fs-sm); color: var(--gray); line-height: 1.4; }
.notif-cta { flex-shrink: 0; align-self: center; font-size: var(--fs-sm); font-weight: 700; color: var(--primary-text); white-space: nowrap; }
.notif-dot { display: inline-block; width: 8px; height: 8px; border-radius: var(--radius-pill); background: var(--primary-text); vertical-align: middle; margin-left: 4px; }

/* Badge de novedades sobre la pestaña de la barra inferior */
.bn-badge {
  position: absolute; top: -4px; right: -10px;
  min-width: 18px; height: 18px; padding: 0 4px;
  display: flex; align-items: center; justify-content: center;
  background: var(--danger); color: #fff; font-size: 11px; font-weight: 700;
  border-radius: var(--radius-pill); line-height: 1;
}
@media (max-width: 520px) {
  .notif-cta { display: none; } /* en pantallas chicas, toda la tarjeta es tappable */
}

/* ===== Corazón de favorito en tarjeta de servicio ===== */
.pro-card { position: relative; }
.pro-fav {
  position: absolute; top: var(--sp-2); right: var(--sp-2); z-index: 2;
  width: 44px; height: 44px; display: flex; align-items: center; justify-content: center;
  background: rgba(255,255,255,0.9); border: 1px solid var(--border); border-radius: var(--radius-pill);
  font-size: 18px; cursor: pointer; line-height: 1; transition: transform var(--dur) var(--ease);
}
.pro-fav:hover { transform: scale(1.1); }
.pro-fav:active { transform: scale(0.92); }

/* ===== Página de favoritos ===== */
.fav-card {
  display: flex; align-items: center; gap: var(--sp-3);
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: var(--sp-4); margin-bottom: var(--sp-3); box-shadow: var(--shadow-xs);
}
.fav-main { flex: 1; text-decoration: none; color: var(--dark); min-height: 44px; display: flex; align-items: center; }
.fav-info { display: flex; flex-direction: column; gap: 2px; }
.fav-info strong { color: var(--navy); font-size: var(--fs-base); }
.fav-info span { color: var(--gray); font-size: var(--fs-sm); }
.fav-remove {
  flex-shrink: 0; width: 44px; height: 44px; display: flex; align-items: center; justify-content: center;
  background: transparent; border: none; font-size: 22px; cursor: pointer;
}
