*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --orange: #F7931A;
  --orange-dark: #d97c10;
  --orange-light: #fff3e0;
  --crimson: #C0392B;
  --gold: #d4a017;
  --bg: #ffffff;
  --bg2: #fdf8f3;
  --bg3: #fff5ea;
  --text: #180a00;
  --text-muted: #7a5530;
  --border: #ecd9c0;
  --shadow: rgba(247,147,26,0.12);
  --font: 'Space Grotesk', sans-serif;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ── NAVBAR ── */
#navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 0 2rem;
  transition: background 0.3s, box-shadow 0.3s;
}
#navbar.scrolled {
  background: rgba(255,255,255,0.95);
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 var(--border);
}
.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nav-logo {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
}
.nav-logo img { height: 62px; display: block; flex-shrink: 0; }
.nav-name-stack {
  display: flex;
  flex-direction: column;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.01em;
  color: var(--text);
}
.nav-name-stack span:nth-child(2) { color: var(--orange); }
.nav-links {
  list-style: none;
  display: flex;
  gap: 2.5rem;
}
.nav-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 1rem;
  font-weight: 600;
  transition: color 0.2s;
}
.nav-links a:hover, .nav-links a.active { color: var(--orange); }

.nav-right { display: flex; align-items: center; gap: 1rem; }
.lang-switcher { display: flex; gap: 4px; }
.lang-btn {
  background: none;
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.864rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  padding: 5px 11px;
  border-radius: 4px;
  cursor: pointer;
  font-family: var(--font);
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}
.lang-btn:hover { border-color: var(--orange); color: var(--orange); }
.lang-btn.active { border-color: var(--orange); color: var(--orange); background: var(--orange-light); }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text);
  transition: transform 0.3s, opacity 0.3s;
}

/* ── HERO ── */
#hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  text-align: center;
  padding: 7rem 2rem 5rem;
  background: var(--bg);
}
.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 60% at 50% 0%, rgba(247,147,26,0.12) 0%, transparent 70%),
    radial-gradient(ellipse 50% 40% at 0% 100%, rgba(192,57,43,0.06) 0%, transparent 60%),
    radial-gradient(ellipse 40% 30% at 100% 80%, rgba(247,147,26,0.06) 0%, transparent 55%);
  pointer-events: none;
}
.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23F7931A' fill-opacity='0.04'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}
.hero-content { position: relative; z-index: 1; max-width: 820px; }
.hero-founded {
  font-size: clamp(1.1rem, 2.2vw, 1.6rem);
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--orange);
  margin-top: 0.4rem;
  margin-bottom: 0;
}
.hero-identity {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2.5rem;
  margin-bottom: 2rem;
  flex-wrap: nowrap;
}
.hero-title-block { text-align: left; }
.hero-name-stack {
  display: flex;
  flex-direction: column;
  font-size: clamp(2.8rem, 6vw, 5rem);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.03em;
  color: var(--text);
}
.hero-name-stack span:nth-child(2) { color: var(--orange); }
.hero-logo {
  height: 403px;
  flex-shrink: 0;
  filter: drop-shadow(0 8px 32px rgba(247,147,26,0.2));
}
#hero h1 {
  font-size: clamp(2.4rem, 5.5vw, 4.2rem);
  font-weight: 700;
  line-height: 1.1;
  margin-bottom: 1.5rem;
  letter-spacing: -0.03em;
  color: var(--text);
}
.hero-sub {
  font-size: clamp(1.3rem, 2.8vw, 1.8rem);
  color: var(--text-muted);
  margin-bottom: 2.8rem;
  line-height: 1.7;
}
.btn-primary {
  display: inline-block;
  padding: 1rem 2.5rem;
  background: var(--orange);
  color: #fff;
  font-weight: 700;
  font-size: 1.1rem;
  border-radius: 8px;
  text-decoration: none;
  transition: background 0.2s, transform 0.2s, box-shadow 0.2s;
  box-shadow: 0 4px 24px rgba(247,147,26,0.3);
}
.btn-primary:hover {
  background: var(--orange-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(247,147,26,0.4);
}
.hero-scroll-hint {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  color: var(--orange);
  font-size: 1.5rem;
  animation: bounce 2s infinite;
}
@keyframes bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(8px); }
}

/* ── SHARED ── */
.container { max-width: 1100px; margin: 0 auto; padding: 0 2rem; }

section { padding: 6rem 0; }
section:nth-child(even) {
  background: var(--bg2);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.section-label {
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--orange);
  margin-bottom: 0.75rem;
}
h2 {
  font-size: clamp(2.4rem, 5vw, 3.8rem);
  font-weight: 700;
  margin-bottom: 1.25rem;
  letter-spacing: -0.025em;
  color: var(--text);
}
.section-intro {
  color: var(--text-muted);
  max-width: 620px;
  margin-bottom: 3rem;
  font-size: 1.1rem;
  line-height: 1.8;
}

/* ── MISIÓN ── */
.mission-text {
  max-width: 820px;
  font-size: 1.45rem;
  color: #3d1f00;
  line-height: 1.85;
  margin: 0 auto 3rem;
  text-align: center;
}
.pillars { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 1.5rem; }
.pillar {
  padding: 2.2rem;
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: 14px;
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s;
}
.pillar:hover {
  border-color: var(--orange);
  transform: translateY(-5px);
  box-shadow: 0 8px 32px var(--shadow);
}
.pillar-icon { font-size: 3.5rem; margin-bottom: 1.1rem; }
.pillar h3 { font-size: 1.2rem; font-weight: 700; margin-bottom: 0.6rem; color: var(--text); }
.pillar p { font-size: 1rem; color: var(--text-muted); line-height: 1.7; }

/* ── PROYECTOS ── */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
  gap: 1.5rem;
}
.project-card {
  background: var(--bg);
  border: 3px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s;
  display: flex;
  flex-direction: column;
}
.project-card:hover {
  border-color: var(--orange);
  transform: translateY(-5px);
  box-shadow: 0 8px 32px var(--shadow);
}
.project-card--highlight {
  border-color: rgba(247,147,26,0.4);
  background: var(--bg);
}
.card-img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  display: block;
}
.card-img-placeholder {
  width: 100%;
  height: 180px;
  background: linear-gradient(135deg, var(--orange) 0%, #d97c10 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}
.card-img-placeholder span { color: #fff; font-weight: 700; font-size: 1.1rem; }
.card-img-placeholder .placeholder-icon { font-size: 2.5rem; }
.labitconf-placeholder {
  background: linear-gradient(135deg, #0d0d1a 0%, #1a1025 60%, #0f1624 100%);
  flex-direction: column;
  gap: 0.3rem;
}
.labitconf-pl-icon { font-size: 2.4rem; }
.labitconf-pl-name { color: var(--orange) !important; font-size: 1.9rem !important; font-weight: 900 !important; letter-spacing: 0.04em; }
.labitconf-pl-year { color: rgba(255,255,255,0.5) !important; font-size: 0.8rem !important; font-weight: 500 !important; letter-spacing: 0.15em; text-transform: uppercase; }
.card-body { padding: 1.6rem; flex: 1; display: flex; flex-direction: column; }
.project-card h3 {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0.65rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-wrap: wrap;
  color: var(--text);
}
.tag {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  background: var(--orange-light);
  color: var(--orange-dark);
  border: 1px solid rgba(247,147,26,0.4);
  padding: 2px 9px;
  border-radius: 999px;
}
.project-card p { font-size: 0.98rem; color: var(--text-muted); line-height: 1.7; margin-bottom: 0.5rem; }
.card-links {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: auto;
  padding-top: 1rem;
  flex-wrap: wrap;
}
.card-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-muted);
  text-decoration: none;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}
.card-link:hover { border-color: var(--orange); color: var(--orange); background: var(--orange-light); }
.labif-sponsors {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  margin-top: 0.75rem;
  padding: 0.65rem 0.9rem;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 8px;
  text-align: center;
}
.labif-sponsors > span { font-size: 0.8rem; font-weight: 700; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.08em; display: block; margin-bottom: 0.75rem; }
.labif-sponsors-title {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}
.sponsor-logos {
  display: flex;
  flex-direction: row;
  gap: 0.75rem;
  align-items: stretch;
}
.sponsor-item {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1rem;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 8px;
  flex: 1;
}
@media (max-width: 600px) {
  .sponsor-logos { flex-direction: column; }
  .sponsor-item { flex: unset; width: 100%; }
}
.sponsor-logo { height: 53px; object-fit: contain; max-width: 200px; }
.sponsor-logo--dark { filter: brightness(0); }
.sponsor-name {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text);
  flex: 1;
}
.sponsor-amount {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--orange-dark);
  white-space: nowrap;
}
.labif-year-inline {
  font-size: 0.8em;
  font-weight: 600;
  color: var(--text);
  margin-right: 0.25rem;
}
.labif-total {
  margin: 0.75rem 0;
  padding: 0.6rem 1rem;
  background: var(--orange-light);
  border: 2px solid rgba(247,147,26,0.5);
  border-radius: 10px;
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--orange-dark);
  text-align: center;
  letter-spacing: 0.02em;
}
.labif-geyser-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-top: 1rem;
  flex-wrap: wrap;
}
.geyser-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: #0d1117;
  border-radius: 10px;
  padding: 0.55rem 1rem;
  text-decoration: none;
  transition: transform 0.2s, box-shadow 0.2s;
  border: 1px solid rgba(255,255,255,0.08);
}
.geyser-badge:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(0,0,0,0.5);
}
.labif-powered {
  font-size: 0.7rem;
  color: rgba(255,255,255,0.5);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  white-space: nowrap;
}
.geyser-logo { height: 52px; object-fit: contain; }
.btn-geyser {
  display: inline-block;
  padding: 0.6rem 1.2rem;
  background: var(--orange);
  color: #fff;
  font-weight: 700;
  font-size: 0.9rem;
  border-radius: 6px;
  text-decoration: none;
  transition: background 0.2s, transform 0.2s;
  margin-top: 0.25rem;
}
.btn-geyser:hover { background: var(--orange-dark); transform: translateY(-1px); }
@keyframes btcColorCycle {
  0%, 100% { color: var(--orange); }
  50%       { color: var(--text);  }
}
.btc {
  color: var(--orange);
  font-weight: 700;
  animation: btcColorCycle 3s ease-in-out infinite;
  display: inline;
}

/* ── CONTACTO ── */
#contacto { text-align: center; background: var(--bg); }
#contacto .section-intro { margin-left: auto; margin-right: auto; }
#proyectos .section-intro { font-size: 1.32rem; text-align: center; margin-left: auto; margin-right: auto; }
.contact-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 2.5rem;
}
.contact-person {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 0.25rem;
}
.contact-email {
  font-size: clamp(1.1rem, 2.5vw, 1.5rem);
  font-weight: 700;
  color: var(--orange);
  text-decoration: none;
  transition: color 0.2s;
}
.contact-email:hover { color: var(--orange-dark); text-decoration: underline; }
.contact-email-secondary {
  font-size: 1rem;
  font-weight: 500;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s;
}
.contact-email-secondary:hover { color: var(--orange); text-decoration: underline; }
.contact-note {
  font-size: 0.88rem;
  color: var(--text-muted);
  background: var(--bg3);
  border: 1px solid var(--border);
  padding: 5px 14px;
  border-radius: 999px;
}
.social-links { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }
.contact-location {
  margin-top: 1.25rem;
  font-size: 1.125rem;
  color: var(--text-muted);
  text-align: center;
}
.social-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.7rem 1.4rem;
  border: 1.5px solid var(--border);
  border-radius: 9px;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 600;
  transition: border-color 0.2s, color 0.2s, background 0.2s, box-shadow 0.2s;
}
.social-btn--icon {
  padding: 0.75rem;
  width: 52px;
  height: 52px;
}
.social-btn:hover {
  border-color: var(--orange);
  color: var(--orange);
  background: var(--orange-light);
  box-shadow: 0 4px 16px var(--shadow);
}

/* ── HONEY BADGER ── */
.hb-title-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.2rem;
  flex-wrap: wrap;
  text-align: center;
}
.hb-title-wrap { margin-bottom: 2rem; }
.hb-title-wrap h2 { margin-bottom: 0; }
#proyectos .hb-title-wrap h2 { font-size: clamp(1.68rem, 3.36vw, 3.12rem); white-space: nowrap; }

.hb-flip { transform: scaleX(-1); }
.hb-icon {
  width: 56px;
  flex-shrink: 0;
  mix-blend-mode: multiply;
}

/* ── HONEY BADGER BAND ── */
.hb-band {
  display: flex;
  align-items: center;
  justify-content: space-evenly;
  background: var(--bg2);
  border-top: 1px solid var(--border);
  padding: 1rem 0;
}
.hb-band img {
  flex: 1;
  max-width: 72px;
  height: 52px;
  object-fit: contain;
  mix-blend-mode: multiply;
}

/* ── FÉNIX DECORATIVO ── */
.phoenix-divider {
  display: flex;
  justify-content: center;
  padding: 0.5rem 0;
  background: var(--bg);
}
.phoenix-divider img {
  height: 48px;
  opacity: 0.18;
  filter: sepia(1) saturate(4) hue-rotate(5deg);
}

/* ── FOOTER ── */
footer {
  background: var(--text);
  padding: 3rem 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.footer-phoenix-bg {
  position: absolute;
  width: 500px;
  opacity: 0.06;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  filter: brightness(10);
}
.footer-inner { position: relative; z-index: 1; }
.footer-logo { height: 86px; margin-bottom: 1.2rem; }
footer p { font-size: 0.9rem; color: rgba(255,255,255,0.5); }

/* ── LABIF — CARD FULL-WIDTH ── */
.project-card--labif {
  grid-column: 1 / -1;
  border-color: rgba(247,147,26,0.5);
  box-shadow: 0 4px 32px rgba(247,147,26,0.12);
}
.project-card--labif .card-img {
  height: 260px;
}

/* LABIF — fuentes +25% */
.project-card--labif h3 { font-size: 1.38rem; }
.project-card--labif p  { font-size: 1.23rem; text-align: justify; }
.project-card--labif .tag { font-size: 0.81rem; }
.project-card--labif .labif-total { font-size: 1.44rem; }
.project-card--labif .labif-sponsors-title { font-size: 0.94rem; }
.project-card--labif .labif-powered { font-size: 0.875rem; color: rgba(255,255,255,0.5); }
.project-card--labif .btn-geyser { font-size: 1.13rem; }

/* ── EQUIPO — SUBLABELS Y GRILLA ── */
.equipo-sublabel {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin: 2.5rem 0 1rem;
}
.founders-grid--single {
  display: flex !important;
  justify-content: center;
}
.founders-grid--single .founder-card {
  width: calc((100% - 4rem) / 3);
  margin: 0 auto;
}
.founder-social {
  display: flex;
  gap: 0.4rem;
  margin-top: 0.9rem;
  justify-content: center;
}

/* ── FUNDADORES ── */
.founders-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}
.founder-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 2rem 1.5rem 1.8rem;
  background: var(--bg);
  border: 3px solid var(--border);
  border-radius: 16px;
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s;
}
.founder-card:hover {
  border-color: var(--orange);
  transform: translateY(-5px);
  box-shadow: 0 8px 32px var(--shadow);
}
.founder-photo {
  width: 134px;
  height: 134px;
  border-radius: 50%;
  object-fit: cover;
  object-position: top center;
  margin-bottom: 1.2rem;
  border: 3px solid var(--orange);
  box-shadow: 0 4px 20px rgba(247,147,26,0.25);
}
.founder-name {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.35rem;
}
.founder-role {
  font-size: 0.94rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--orange);
}

/* ── SPONSOR FBI LOGO ── */
.sponsor-logo--fbi { height: 108px !important; }

/* ── ANIMACIONES ── */

/* Canvas de partículas en el hero */
#hero-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

/* Logo: fade-in + float eterno */
@keyframes heroFadeOpacity {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes heroFloat {
  0%, 100% { transform: translateY(0px); }
  50%      { transform: translateY(-16px); }
}
.hero-logo {
  animation:
    heroFadeOpacity 0.7s 0.05s ease both,
    heroFloat 5s 0.8s ease-in-out infinite;
}

/* Nombre: palabras entran una por una desde la izquierda */
@keyframes wordSlideIn {
  from { opacity: 0; transform: translateX(-30px); }
  to   { opacity: 1; transform: translateX(0);     }
}
.hero-name-stack span {
  animation: wordSlideIn 0.65s cubic-bezier(0.22, 1, 0.36, 1) both;
}
.hero-name-stack span:nth-child(1) { animation-delay: 0.15s; }
.hero-name-stack span:nth-child(2) { animation-delay: 0.38s; }
.hero-name-stack span:nth-child(3) { animation-delay: 0.61s; }

/* Subtítulo y año */
@keyframes heroFadeUp {
  from { opacity: 0; transform: translateY(22px); }
  to   { opacity: 1; transform: translateY(0);    }
}
.hero-founded { animation: heroFadeUp 0.55s 1.0s ease both; }
.hero-sub     { animation: heroFadeUp 0.55s 1.2s ease both; }

/* CTA: fade-in + pulso de sombra */
@keyframes btnPulse {
  0%, 100% { box-shadow: 0 4px 24px rgba(247,147,26,0.3); }
  50%      { box-shadow: 0 8px 40px rgba(247,147,26,0.6), 0 0 0 6px rgba(247,147,26,0.1); }
}
.btn-primary {
  animation:
    heroFadeOpacity 0.6s 1.4s ease both,
    btnPulse 3s 2.2s ease-in-out infinite;
}

/* Subrayado animado en links del nav */
.nav-links a { position: relative; }
.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -3px; left: 0;
  width: 0; height: 2px;
  background: var(--orange);
  transition: width 0.25s ease;
}
.nav-links a:hover::after,
.nav-links a.active::after { width: 100%; }

/* ── ANIMACIONES DE SCROLL ── */
.anim-up, .anim-left, .anim-right, .anim-scale {
  opacity: 0;
  transition:
    opacity 0.8s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}
.anim-up    { transform: translateY(48px); }
.anim-left  { transform: translateX(-48px); }
.anim-right { transform: translateX(48px); }
.anim-scale { transform: scale(0.88); }

.anim-up.is-visible,
.anim-left.is-visible,
.anim-right.is-visible,
.anim-scale.is-visible {
  opacity: 1;
  transform: none;
}

/* Restaurar transición rápida en cards tras el reveal para que el tilt/hover se sientan ágiles */
.project-card.is-visible {
  transition: border-color 0.2s, transform 0.12s ease, box-shadow 0.2s;
}

/* Pulso en el badge del total LABIF */
@keyframes labifGlow {
  0%, 100% { box-shadow: 0 4px 20px rgba(247,147,26,0.2); }
  50%      { box-shadow: 0 6px 36px rgba(247,147,26,0.5); }
}
.labif-total { animation: labifGlow 2.5s ease-in-out infinite; }

/* Respeta preferencia de movimiento reducido */
@media (prefers-reduced-motion: reduce) {
  .hero-logo, .hero-name-stack span,
  .hero-founded, .hero-sub, .btn-primary {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
  .anim-up, .anim-left, .anim-right, .anim-scale {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
  .labif-total { animation: none !important; }
  #hero-canvas { display: none; }
}

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
  .nav-links { display: none; flex-direction: column; gap: 0; }
  .nav-links.open {
    display: flex;
    position: absolute;
    top: 74px; left: 0; right: 0;
    background: rgba(255,255,255,0.98);
    border-bottom: 1px solid var(--border);
    padding: 1rem 2rem 1.5rem;
    gap: 1.25rem;
    box-shadow: 0 8px 24px rgba(0,0,0,0.08);
  }
  .nav-toggle { display: flex; }
  .stat-bar { flex-direction: column; gap: 1.5rem; }
  section { padding: 4rem 0; }
  .projects-grid { grid-template-columns: 1fr; }
  .founders-grid--single .founder-card { width: 100%; }

  .hb-title-wrap {
    flex-wrap: nowrap;
    gap: 0.6rem;
  }
  .hb-icon { width: 36px; }
  .hb-title-wrap h2 {
    font-size: clamp(1.5rem, 6vw, 2.4rem);
    min-width: 0;
  }
  .hero-identity {
    flex-direction: column;
    flex-wrap: wrap;
  }
  #proyectos .hb-title-wrap h2 {
    white-space: normal;
    text-align: center;
    font-size: clamp(1.3rem, 5.5vw, 1.9rem);
  }
}
