/* ═══════════════════════════════════════════════════════
   landing.css — Landing Page Principal AulaSync
   ═══════════════════════════════════════════════════════ */

/* ── Variables ────────────────────────────────────────── */
:root {
  --primary:       #4f46e5;
  --primary-dark:  #3730a3;
  --primary-mid:   #6366f1;
  --accent:        #10b981;
  --accent-dark:   #059669;
  --warn:          #f59e0b;
  --pink:          #ec4899;
  --text:          #0f172a;
  --text-sub:      #475569;
  --text-light:    #94a3b8;
  --border:        #e2e8f0;
  --bg:            #f8fafc;
  --surface:       #ffffff;
  --radius:        16px;
  --radius-lg:     24px;
  --radius-xl:     32px;
  --shadow-sm:     0 1px 4px rgba(0,0,0,.06), 0 1px 2px rgba(0,0,0,.04);
  --shadow:        0 4px 20px rgba(0,0,0,.08);
  --shadow-lg:     0 12px 40px rgba(0,0,0,.12);
  --shadow-glow:   0 0 40px rgba(79,70,229,.25);
  --navbar-h:      68px;
}

/* ── Base ─────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto,
               'Helvetica Neue', sans-serif;
  color: var(--text);
  background: var(--surface);
  /* overflow-x: clip (no "hidden") evita el scroll horizontal de los
     elementos decorativos SIN romper "position: sticky" del navbar.
     Cualquier valor de overflow distinto de "visible" en un ancestro
     (incluido overflow-x solo) impide que sticky funcione; "clip" es
     la excepción moderna pensada justo para este caso. */
  overflow-x: clip;
}
.section-py { padding: 96px 0; }
.section-py-sm { padding: 64px 0; }

/* ── Navbar override ──────────────────────────────────── */
#mainNavbar {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  height: var(--navbar-h);
  box-shadow: 0 2px 12px rgba(0,0,0,.2);
  z-index: 1030;
}
#mainNavbar .nav-link {
  color: rgba(255,255,255,.85) !important;
  font-size: .9rem;
  border-radius: 8px;
  padding: 6px 10px !important;
  transition: background .15s;
}
#mainNavbar .nav-link:hover,
#mainNavbar .nav-link.active {
  color: #fff !important;
  background: rgba(255,255,255,.12);
}

/* ── Fix: menú móvil transparente ─────────────────────────
   Igual que en styles.css: la altura fija del navbar no permite
   que el panel colapsado (hamburguesa) herede el fondo, así que
   se lo damos explícitamente y dejamos crecer el <nav>. */
@media (max-width: 991px) {
  #mainNavbar { height: auto; }
  #mainNavbar .navbar-collapse {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    margin: 0 -12px;
    padding: 10px 12px 16px;
    border-radius: 0 0 12px 12px;
    box-shadow: 0 12px 24px rgba(0,0,0,.25);
  }
}

/* ═══════════════════════════════════════════════
   SECCIÓN 1: HERO
═══════════════════════════════════════════════ */
.hero-landing {
  background: linear-gradient(135deg, #0f0c29 0%, #1e1b4b 40%, #312e81 100%);
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  padding: calc(var(--navbar-h) + 40px) 0 80px;
}

/* Rejilla de fondo */
.hero-landing::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(99,102,241,.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(99,102,241,.07) 1px, transparent 1px);
  background-size: 48px 48px;
}

/* Glow orbs */
.hero-landing::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 50% at 20% 60%, rgba(79,70,229,.3) 0%, transparent 70%),
    radial-gradient(ellipse 40% 40% at 80% 20%, rgba(16,185,129,.2) 0%, transparent 60%);
  pointer-events: none;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(99,102,241,.2);
  border: 1px solid rgba(99,102,241,.4);
  color: #a5b4fc;
  padding: 7px 18px;
  border-radius: 30px;
  font-size: .82rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  margin-bottom: 24px;
}
.hero-eyebrow .dot {
  width: 7px; height: 7px;
  background: #10b981;
  border-radius: 50%;
  box-shadow: 0 0 6px #10b981;
  animation: pulse-dot 2s infinite;
}
@keyframes pulse-dot {
  0%,100% { box-shadow: 0 0 4px #10b981; }
  50%      { box-shadow: 0 0 12px #10b981; }
}

.hero-landing h1 {
  font-size: clamp(2.6rem, 5.5vw, 4.5rem);
  font-weight: 900;
  color: #fff;
  line-height: 1.08;
  letter-spacing: -1.5px;
}
.hero-landing h1 .highlight {
  background: linear-gradient(90deg, #818cf8 0%, #a78bfa 50%, #f0abfc 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero-sub {
  font-size: 1.15rem;
  color: rgba(255,255,255,.65);
  line-height: 1.7;
  max-width: 500px;
  margin-top: 20px;
}

.hero-cta-group { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 36px; }
.btn-hero-primary {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-mid) 100%);
  color: white;
  padding: 14px 32px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 1rem;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(79,70,229,.4);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  transition: transform .2s, box-shadow .2s;
}
.btn-hero-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(79,70,229,.5);
  color: white;
}
.btn-hero-ghost {
  background: rgba(255,255,255,.08);
  color: rgba(255,255,255,.85);
  padding: 14px 28px;
  border-radius: 12px;
  font-weight: 600;
  font-size: 1rem;
  border: 1px solid rgba(255,255,255,.15);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  transition: background .2s, border-color .2s;
}
.btn-hero-ghost:hover {
  background: rgba(255,255,255,.14);
  border-color: rgba(255,255,255,.3);
  color: white;
}

.hero-stats {
  display: flex;
  gap: 32px;
  margin-top: 48px;
  flex-wrap: wrap;
}
.hero-stat-num {
  font-size: 1.8rem;
  font-weight: 900;
  color: white;
  line-height: 1;
}
.hero-stat-label {
  font-size: .78rem;
  color: rgba(255,255,255,.5);
  margin-top: 4px;
  letter-spacing: .04em;
}

/* App window mockup */
.app-window {
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 20px;
  overflow: hidden;
  backdrop-filter: blur(12px);
  box-shadow: 0 24px 80px rgba(0,0,0,.4), var(--shadow-glow);
}
.app-window-bar {
  background: rgba(255,255,255,.06);
  padding: 12px 18px;
  display: flex;
  align-items: center;
  gap: 8px;
  border-bottom: 1px solid rgba(255,255,255,.07);
}
.app-window-dot {
  width: 11px; height: 11px;
  border-radius: 50%;
  flex-shrink: 0;
}
.app-window-title {
  color: rgba(255,255,255,.4);
  font-size: .75rem;
  margin-left: 8px;
  font-family: monospace;
  letter-spacing: .04em;
}
.app-window-body { padding: 20px; }
.app-module-row {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 12px;
  padding: 12px 16px;
  margin-bottom: 8px;
  transition: background .2s;
}
.app-module-row:hover { background: rgba(255,255,255,.09); }
.app-module-icon {
  width: 36px; height: 36px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}
.app-module-name {
  color: rgba(255,255,255,.85);
  font-size: .875rem;
  font-weight: 600;
}
.app-module-badge {
  margin-left: auto;
  font-size: .65rem;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 20px;
}

/* ═══════════════════════════════════════════════
   SECCIÓN 2: PROBLEMA
═══════════════════════════════════════════════ */
.problem-section { background: #0f172a; }
.problem-card {
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: var(--radius);
  padding: 28px;
  height: 100%;
  transition: border-color .2s, background .2s;
}
.problem-card:hover {
  border-color: rgba(239,68,68,.3);
  background: rgba(239,68,68,.04);
}
.problem-card .p-icon { font-size: 2rem; margin-bottom: 14px; }
.problem-card h6 {
  color: #f1f5f9;
  font-weight: 700;
  margin-bottom: 6px;
}
.problem-card p { color: #64748b; font-size: .875rem; margin: 0; }
.solution-card {
  background: rgba(16,185,129,.07);
  border: 1px solid rgba(16,185,129,.2);
  border-radius: var(--radius-lg);
  padding: 36px;
}

/* ═══════════════════════════════════════════════
   SECCIÓN 3: CÓMO FUNCIONA
═══════════════════════════════════════════════ */
.how-section { background: var(--bg); }
.step-card {
  background: white;
  border-radius: var(--radius-lg);
  padding: 36px 28px;
  text-align: center;
  box-shadow: var(--shadow);
  height: 100%;
  position: relative;
  overflow: hidden;
  transition: transform .25s, box-shadow .25s;
}
.step-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}
.step-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
}
.step-card:nth-child(1)::before { background: linear-gradient(90deg, var(--primary), #818cf8); }
.step-card:nth-child(2)::before { background: linear-gradient(90deg, var(--accent), #34d399); }
.step-card:nth-child(3)::before { background: linear-gradient(90deg, var(--warn), #fbbf24); }
.step-num-big {
  font-size: 4.5rem;
  font-weight: 900;
  line-height: 1;
  margin-bottom: 16px;
  -webkit-text-stroke: 2px transparent;
}
.step-card:nth-child(1) .step-num-big { color: var(--primary); }
.step-card:nth-child(2) .step-num-big { color: var(--accent); }
.step-card:nth-child(3) .step-num-big { color: var(--warn); }
.step-emoji { font-size: 2.8rem; margin-bottom: 14px; display: block; }
.step-card h5 { font-weight: 800; margin-bottom: 8px; color: var(--text); }
.step-card p { color: var(--text-sub); font-size: .9rem; margin: 0; }
.step-connector-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
  font-size: 1.8rem;
  padding-top: 40px;
}

/* ═══════════════════════════════════════════════
   SECCIÓN 4: FEATURES / MÓDULOS
═══════════════════════════════════════════════ */
.features-section { background: white; }
.section-label {
  font-size: .75rem;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
  margin-bottom: 10px;
}
.section-title {
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  font-weight: 900;
  color: var(--text);
  letter-spacing: -0.5px;
  line-height: 1.2;
}
.section-desc {
  font-size: 1rem;
  color: var(--text-sub);
  max-width: 560px;
  line-height: 1.7;
}
.feature-card {
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  height: 100%;
  transition: all .25s;
  position: relative;
  overflow: hidden;
}
.feature-card:hover {
  border-color: var(--primary);
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}
.feature-card:hover .fc-icon { transform: scale(1.1) rotate(-4deg); }
.fc-icon {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  margin-bottom: 18px;
  transition: transform .25s;
}
.feature-card h6 {
  font-size: 1rem;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 6px;
}
.feature-card p {
  font-size: .875rem;
  color: var(--text-sub);
  margin: 0;
  line-height: 1.6;
}
.fc-tag {
  position: absolute;
  top: 16px; right: 16px;
  font-size: .65rem;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 20px;
  letter-spacing: .04em;
}

/* ═══════════════════════════════════════════════
   SECCIÓN 5: COMPARACIÓN / BENEFICIOS
═══════════════════════════════════════════════ */
.benefits-section {
  background: linear-gradient(135deg, #0f172a 0%, #1e1b4b 100%);
  position: relative;
  overflow: hidden;
}
.benefits-section::before {
  content: '';
  position: absolute;
  top: -100px; right: -100px;
  width: 500px; height: 500px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(79,70,229,.15) 0%, transparent 70%);
}
.benefit-item {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  padding: 20px 0;
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.benefit-item:last-child { border-bottom: none; }
.benefit-check {
  width: 28px; height: 28px;
  background: rgba(16,185,129,.15);
  border: 1px solid rgba(16,185,129,.3);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #10b981;
  font-size: .85rem;
  flex-shrink: 0;
  margin-top: 2px;
}
.benefit-title {
  font-weight: 700;
  color: #f1f5f9;
  margin-bottom: 2px;
  font-size: .95rem;
}
.benefit-desc { color: #64748b; font-size: .85rem; }

.stat-big {
  text-align: center;
  padding: 28px;
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: var(--radius);
}
.stat-big-num {
  font-size: 2.8rem;
  font-weight: 900;
  color: white;
  line-height: 1;
  margin-bottom: 4px;
}
.stat-big-label { font-size: .8rem; color: #64748b; }

/* ═══════════════════════════════════════════════
   SECCIÓN 6: USUARIOS / PERSONAS
═══════════════════════════════════════════════ */
.persona-section { background: var(--bg); }
.persona-card {
  background: white;
  border-radius: var(--radius-xl);
  padding: 40px;
  box-shadow: var(--shadow-lg);
  height: 100%;
  position: relative;
  overflow: hidden;
}
.persona-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 6px;
}
.persona-docente::before {
  background: linear-gradient(90deg, var(--primary), #818cf8);
}
.persona-estudiante::before {
  background: linear-gradient(90deg, #ec4899, #f97316);
}
.persona-avatar {
  width: 72px; height: 72px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  margin-bottom: 16px;
}
.persona-role {
  font-size: .75rem;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
  margin-bottom: 4px;
}
.persona-name {
  font-size: 1.2rem;
  font-weight: 900;
  color: var(--text);
  margin-bottom: 6px;
}
.persona-desc { color: var(--text-sub); font-size: .875rem; margin-bottom: 24px; }
.persona-feature {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
  font-size: .875rem;
}
.persona-feature:last-child { border: none; }
.persona-feature .pf-icon { font-size: 1rem; flex-shrink: 0; margin-top: 1px; }
.persona-feature .pf-text { color: var(--text-sub); }
.persona-feature .pf-text strong { color: var(--text); }

/* ═══════════════════════════════════════════════
   SECCIÓN 7: DESCARGA / REQUISITOS
═══════════════════════════════════════════════ */
.download-section { background: white; }
.req-pill {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: 14px;
  padding: 14px 18px;
  font-size: .875rem;
}
.req-pill .rp-icon { font-size: 1.4rem; flex-shrink: 0; }
.req-pill .rp-label { font-weight: 700; color: var(--text); font-size: .85rem; }
.req-pill .rp-val { color: var(--text-sub); font-size: .8rem; }
.download-box {
  background: linear-gradient(135deg, var(--primary) 0%, #6366f1 50%, #818cf8 100%);
  border-radius: var(--radius-xl);
  padding: 48px;
  text-align: center;
  box-shadow: 0 20px 60px rgba(79,70,229,.3);
  position: relative;
  overflow: hidden;
}
.download-box::before {
  content: '';
  position: absolute;
  top: -60px; right: -60px;
  width: 200px; height: 200px;
  border-radius: 50%;
  background: rgba(255,255,255,.07);
}
.download-box::after {
  content: '';
  position: absolute;
  bottom: -40px; left: -40px;
  width: 150px; height: 150px;
  border-radius: 50%;
  background: rgba(255,255,255,.05);
}
.btn-download {
  background: white;
  color: var(--primary);
  padding: 18px 42px;
  border-radius: 14px;
  font-weight: 800;
  font-size: 1.1rem;
  border: none;
  cursor: pointer;
  box-shadow: 0 8px 30px rgba(0,0,0,.2);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  transition: transform .2s, box-shadow .2s;
  position: relative;
  z-index: 1;
}
.btn-download:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 48px rgba(0,0,0,.25);
  color: var(--primary-dark);
}
.download-meta {
  color: rgba(255,255,255,.65);
  font-size: .82rem;
  margin-top: 14px;
  position: relative;
  z-index: 1;
}
.version-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.2);
  color: rgba(255,255,255,.8);
  padding: 4px 14px;
  border-radius: 20px;
  font-size: .78rem;
  font-weight: 600;
  margin-bottom: 20px;
}

/* ═══════════════════════════════════════════════
   SECCIÓN 8: FAQ
═══════════════════════════════════════════════ */
.faq-section { background: var(--bg); }
.faq-accordion .accordion-item {
  border: 1.5px solid var(--border);
  border-radius: var(--radius) !important;
  margin-bottom: 10px;
  overflow: hidden;
  background: white;
}
.faq-accordion .accordion-button {
  font-weight: 700;
  font-size: .95rem;
  color: var(--text);
  background: white;
  border-radius: var(--radius) !important;
  padding: 20px 24px;
  box-shadow: none !important;
}
.faq-accordion .accordion-button:not(.collapsed) {
  color: var(--primary);
  background: #eef2ff;
}
.faq-accordion .accordion-button::after {
  filter: none;
}
.faq-accordion .accordion-body {
  color: var(--text-sub);
  font-size: .9rem;
  padding: 0 24px 20px;
  line-height: 1.7;
}

/* ═══════════════════════════════════════════════
   SECCIÓN 9: CTA FINAL
═══════════════════════════════════════════════ */
.cta-section {
  background: linear-gradient(135deg, #0f0c29 0%, #1e1b4b 50%, #312e81 100%);
  text-align: center;
  padding: 120px 0;
  position: relative;
  overflow: hidden;
}
.cta-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 50% 60% at 50% 50%, rgba(79,70,229,.2) 0%, transparent 70%);
}
.cta-section h2 {
  font-size: clamp(2rem, 4vw, 3.2rem);
  font-weight: 900;
  color: white;
  letter-spacing: -1px;
  position: relative;
}

/* ═══════════════════════════════════════════════
   SECCIÓN 10: DONACIÓN
═══════════════════════════════════════════════ */
.donate-section { background: var(--surface); }
.donate-box {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow);
  padding: 40px 44px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
}
.donate-box__text { flex: 1; min-width: 260px; }
.donate-box__btn {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: linear-gradient(135deg, #00c2a8, #00a896);
  color: #fff;
  font-weight: 700;
  font-size: .95rem;
  padding: 14px 30px;
  border-radius: 24px;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: 0 12px 30px rgba(0,194,168,.25);
  transition: transform .18s ease, box-shadow .18s ease;
}
.donate-box__btn i { color: #ec4899; }
.donate-box__btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 36px rgba(0,194,168,.35);
  color: #fff;
}
@media (max-width: 576px) {
  .donate-box { padding: 32px 24px; text-align: center; justify-content: center; }
  .donate-box__btn { width: 100%; justify-content: center; }
}

/* ── Footer ───────────────────────────────────────────── */
.site-footer { background: #0f172a; padding: 56px 0 32px; margin-top: 0; }
.footer-links { list-style: none; padding: 0; }
.footer-links li + li { margin-top: 6px; }
.footer-links a, .footer-links li {
  color: #64748b; font-size: .875rem; text-decoration: none; transition: color .15s;
}
.footer-links a:hover { color: white; }
.footer-divider { border-color: #1e293b; }
.text-footer-sub { color: #475569; }

/* ── Botón volver arriba ──────────────────────────────── */
#btn-top {
  position: fixed;
  bottom: 28px; right: 28px;
  width: 46px; height: 46px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), #6366f1);
  color: white;
  border: none;
  cursor: pointer;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  transform: translateY(12px);
  transition: opacity .25s, transform .25s;
  z-index: 999;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}
#btn-top.visible { opacity: 1; transform: translateY(0); }
#btn-top:hover { filter: brightness(1.1); }

/* ── Responsive ───────────────────────────────────────── */
@media (max-width: 991px) {
  .hero-landing { min-height: auto; padding: calc(var(--navbar-h) + 48px) 0 64px; }
  .app-window { display: none; }
  .step-connector-arrow { display: none; }
  .section-py { padding: 64px 0; }
}
@media (max-width: 576px) {
  .hero-landing h1 { font-size: 2.1rem; }
  .hero-stats { gap: 20px; }
  .download-box { padding: 32px 20px; }
  .persona-card { padding: 28px 20px; }
}
