/* ═══════════════════════════════════════════════════════
   LAMA — Design System
   Laboratorio de Mediaciones Algorítmicas
   Universidad del Valle, Cali, Colombia
═══════════════════════════════════════════════════════ */
:root {
  --c0: #5C8607;
  --c1: #70A309;
  --c2: #343F1E;
  --c3: #343F1E;
  --c4: #E3E9D8;
  --c5: #FDFAF1;
  --c6: rgba(53,64,31,0.24);
  --c8: #050505;
  --f-heading: 'Playfair Display', serif;
  --f-body: 'Open Sans', sans-serif;
  --max: 1200px;
}

/* ── RESET ─────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--f-body);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.7;
  background: var(--c5);
  color: var(--c3);
  overflow-x: hidden;
}
a { color: var(--c0); text-decoration: none; }
a:hover { color: var(--c1); }
img { display: block; max-width: 100%; }
h1, h2, h3, h4, h5, h6 {
  font-family: 'Playfair Display', serif !important;
  color: var(--c2);
  font-weight: 400;
}
h1 { font-size: clamp(2.8rem, 5vw, 4.5rem); line-height: 1.2em; letter-spacing: -1px; }
h2 { font-size: clamp(2rem, 3.5vw, 3rem); line-height: 1.2em; }
h3 { font-size: clamp(1.4rem, 2vw, 2rem); line-height: 1em; }
h4 { font-size: 1.375rem; line-height: 1.4em; }
p  { margin-bottom: 1.5em; }
p:last-child { margin-bottom: 0; }

/* ── BOTONES ────────────────────────────────────────── */
.btn {
  display: inline-block;
  font-family: var(--f-body);
  font-size: 16px;
  font-weight: 600;
  line-height: 1em;
  text-transform: uppercase;
  letter-spacing: .36px;
  padding: 18px 35px;
  border-radius: 100px;
  border: none;
  cursor: pointer;
  transition: background .2s, color .2s, border-color .2s, transform .15s;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--c0); color: var(--c5); border: 1px solid var(--c0); }
.btn-primary:hover { background: var(--c1); border-color: var(--c1); color: var(--c5); }
.btn-outline { background: transparent; color: var(--c2); border: 1px solid var(--c2); }
.btn-outline:hover { background: var(--c0); color: var(--c5); border-color: var(--c0); }
.btn-outline-white { background: transparent; color: #fff; border: 1.5px solid rgba(255,255,255,0.7); }
.btn-outline-white:hover { background: rgba(255,255,255,0.15); color: #fff; }
.btn-sm { padding: 12px 24px; font-size: 14px; }

/* ── NAV ────────────────────────────────────────────── */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: var(--c5);
  border-bottom: 1px solid var(--c6);
  transition: box-shadow .25s;
}
nav.scrolled { box-shadow: 0 2px 16px rgba(52,63,30,.08); }
.nav-inner {
  max-width: var(--max); margin: 0 auto;
  padding: 0 20px;
  height: 88px;
  display: flex; align-items: center; justify-content: space-between;
}
.nav-logo img { height: 54px; width: auto; display: block; }
.nav-links {
  display: flex; align-items: center;
  gap: 0; list-style: none;
}
.nav-links li a {
  font-family: var(--f-body);
  font-size: 14px; font-weight: 600;
  text-transform: uppercase; letter-spacing: .04em;
  color: var(--c3);
  padding: 0 18px;
  display: block;
  transition: color .2s;
  line-height: 88px;
}
.nav-links li a:hover,
.nav-links li a.active { color: var(--c1); }
.nav-links li.nav-cta a {
  color: var(--c2);
  background: transparent;
  border: 1px solid var(--c2);
  border-radius: 100px;
  padding: 12px 28px;
  line-height: 1em;
  font-size: 14px;
  margin-left: 10px;
  transition: background .2s, color .2s, border-color .2s;
}
.nav-links li.nav-cta a:hover { background: var(--c1); color: var(--c5); border-color: var(--c1); }

/* Hamburger */
.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 4px; }
.nav-toggle span {
  display: block; width: 24px; height: 2px;
  background: var(--c2); margin: 5px 0;
  transition: transform .2s, opacity .2s;
}

/* ── HERO ───────────────────────────────────────────── */
.hero {
  margin-top: 88px;
  position: relative;
  min-height: 56vh;
  display: flex; align-items: center;
  overflow: hidden;
}
.hero-bg {
  position: absolute; inset: 0;
  background-size: cover;
  background-position: center;
  filter: brightness(.72);
}
.hero-content {
  position: relative; z-index: 1;
  max-width: var(--max); margin: 0 auto; width: 100%;
  padding: 80px 20px;
  color: #fff;
}
.hero-content h1 { color: #fff; }
.hero-tagline {
  font-family: var(--f-heading);
  font-size: clamp(1.1rem, 2vw, 1.4rem);
  color: rgba(255,255,255,.85);
  margin: 1rem 0 .5rem;
}
.hero-sub {
  font-size: 1rem; color: rgba(255,255,255,.8);
  max-width: 560px; line-height: 1.8;
  margin-bottom: 2rem;
}
.hero-btns { display: flex; gap: 1rem; flex-wrap: wrap; }

/* Hero pequeño (subpáginas) */
.hero-sm {
  margin-top: 88px;
  position: relative;
  min-height: 36vh;
  display: flex; align-items: center;
  overflow: hidden;
}
.hero-sm .hero-bg { filter: brightness(.68); }
.hero-sm .hero-content { padding: 60px 20px; }

/* ── FRANJA INTRO ─────────────────────────────────── */
.intro-bar {
  background: #F5EFE0 !important;
  padding: 2rem 20px;
  border-bottom: 1px solid var(--c6);
}
.intro-bar-inner {
  max-width: var(--max); margin: 0 auto;
  font-family: 'Playfair Display', serif;
  font-size: 1.4rem; font-weight: 400;
  font-style: normal;
  line-height: 1.65;
  color: var(--c2);
  text-align: center;
}

/* ── SECCIONES ─────────────────────────────────────── */
.sec { padding: 100px 20px; }
.sec-sm { padding: 70px 20px; }
.wrap { max-width: var(--max); margin: 0 auto; }
.sec-cream { background: var(--c5); }
.sec-sage  { background: var(--c4); }

/* Label */
.sec-label {
  display: inline-flex; align-items: center; gap: .6rem;
  font-family: var(--f-body); font-size: .78rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: .12em;
  color: var(--c0); margin-bottom: .5rem;
}
.sec-label::before {
  content: '';
  display: inline-block; width: 28px; height: 2px;
  background: var(--c0); flex-shrink: 0;
}

/* ── WHY CARDS ─────────────────────────────────────── */
.why-intro-text {
  font-size: 1.05rem; max-width: 680px;
  margin: 0 auto 3rem; text-align: center;
  color: var(--c3); line-height: 1.8;
}
.why-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}
.why-card {
  background: var(--c5);
  border-radius: 6px;
  border-top: 3px solid var(--c0);
  padding: 2.2rem 1.8rem;
  box-shadow: 0 2px 12px rgba(52,63,30,.06);
  transition: transform .25s, box-shadow .25s;
}
.why-card:hover { transform: translateY(-4px); box-shadow: 0 8px 24px rgba(52,63,30,.12); }
.why-num {
  font-family: var(--f-heading);
  font-size: 3.5rem; line-height: 1;
  color: rgba(92,134,7,.18);
  margin-bottom: .5rem;
}
.why-card h3 { font-size: 1.3rem; margin-bottom: 1rem; color: var(--c2); }
.why-card p  { font-size: .93rem; color: var(--c3); line-height: 1.75; margin: 0; }

/* ── ARTEFACTO CARDS ──────────────────────────────── */
.art-header {
  display: flex; justify-content: space-between; align-items: flex-end;
  margin-bottom: 2.5rem; flex-wrap: wrap; gap: 1rem;
}
.link-more {
  font-family: var(--f-body); font-size: .9rem; font-weight: 600;
  color: var(--c0); text-decoration: none; white-space: nowrap;
  transition: color .2s;
}
.link-more:hover { color: var(--c1); }
.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
.card {
  background: var(--c5);
  border-radius: 6px;
  border: 1px solid var(--c6);
  overflow: hidden;
  transition: transform .25s, box-shadow .25s;
}
.card:hover { transform: translateY(-5px); box-shadow: 0 12px 32px rgba(52,63,30,.12); }
.card-thumb {
  position: relative; height: 180px;
  background: var(--c4);
  display: flex; align-items: center; justify-content: center;
  font-size: 3.5rem; overflow: hidden;
}
.card-thumb img {
  position: absolute; inset: 0;
  width: 100%; height: 100%; object-fit: cover;
}
.card-body { padding: 1.5rem; }
.card-badge {
  display: inline-block;
  font-size: .72rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: .1em;
  color: var(--c0); margin-bottom: .6rem;
}
.card-body h3 { font-size: 1.1rem; margin-bottom: .7rem; line-height: 1.2; }
.card-body p  { font-size: .88rem; color: var(--c3); line-height: 1.65; margin-bottom: 1rem; }
.card-tags { display: flex; flex-wrap: wrap; gap: .4rem; margin-bottom: 1rem; }
.tag {
  font-size: .7rem; font-weight: 500;
  background: var(--c4); color: var(--c2);
  padding: .25rem .6rem; border-radius: 100px;
  letter-spacing: .02em;
}
.card-cta {
  font-size: .85rem; font-weight: 600;
  color: var(--c0); text-decoration: none;
  transition: color .2s;
}
.card-cta:hover { color: var(--c1); }

/* ── LÍNEAS DE ACCIÓN ────────────────────────────── */
.lineas-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}
.linea-centered { padding: 1.5rem 1rem; }
.linea-check {
  width: 40px; height: 40px; background: var(--c2);
  border-radius: 100px; display: flex; align-items: center;
  justify-content: center; color: #fff;
  font-size: 1rem; font-weight: 700; margin: 0 auto 1rem;
}
.linea-centered h3 { margin-bottom: .7rem; font-size: 1.2rem; }
.linea-centered p  { font-size: .92rem; color: var(--c3); line-height: 1.75; }

/* ── TERRITORIAL ─────────────────────────────────── */
.territorial {
  position: relative; min-height: 52vh;
  display: flex; align-items: center; overflow: hidden;
}
.territorial-bg {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
  filter: brightness(.42);
}
.territorial-content {
  position: relative; z-index: 1;
  max-width: var(--max); margin: 0 auto; width: 100%;
  padding: 80px 20px;
}
.territorial-content .sec-label { color: rgba(227,233,216,.7); }
.territorial-content .sec-label::before { background: rgba(227,233,216,.7); }
.territorial-content h2 { color: #FDFAF1; max-width: 600px; margin-bottom: 1rem; }
.territorial-content p {
  color: rgba(253,250,241,.82); max-width: 560px;
  font-size: 1rem; line-height: 1.8; margin-bottom: 2rem;
}
.territorial-ctas { display: flex; gap: 1rem; flex-wrap: wrap; }

/* ── FOOTER ─────────────────────────────────────── */
.footer-above {
  background: var(--c4);
  padding: 80px 20px;
  border-top: 1px solid var(--c6);
}
.footer-above-grid {
  max-width: var(--max); margin: 0 auto;
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem; align-items: start;
}
.footer-brand img { height: 36px; margin-bottom: 1rem; }
.footer-brand p { font-size: .87rem; color: var(--c3); line-height: 1.7; max-width: 260px; }
.footer-col h4 {
  font-family: var(--f-body); font-size: .78rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: .1em;
  color: var(--c2); margin-bottom: 1rem;
}
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: .5rem; }
.footer-col ul li a { font-size: .87rem; color: var(--c3); transition: color .2s; }
.footer-col ul li a:hover { color: var(--c0); }
.footer-primary {
  background: var(--c4);
  border-top: 1px solid var(--c6);
  padding: 15px 20px;
}
.footer-primary-inner {
  max-width: var(--max); margin: 0 auto;
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: .5rem;
}
.footer-primary-inner p,
.footer-primary-inner a { font-size: 13px; color: var(--c3); }
.footer-primary-inner a:hover { color: var(--c0); }

/* ── ANIMACIONES ────────────────────────────────── */
.reveal {
  opacity: 0; transform: translateY(28px);
  transition: opacity .75s cubic-bezier(.16,1,.3,1), transform .75s cubic-bezier(.16,1,.3,1);
}
.reveal.on { opacity: 1; transform: none; }
.d1 { transition-delay: .1s; }
.d2 { transition-delay: .22s; }
.d3 { transition-delay: .34s; }
.d4 { transition-delay: .46s; }
/* fade from left */
.reveal-left {
  opacity: 0; transform: translateX(-32px);
  transition: opacity .75s cubic-bezier(.16,1,.3,1), transform .75s cubic-bezier(.16,1,.3,1);
}
.reveal-left.on { opacity: 1; transform: none; }
/* fade from right */
.reveal-right {
  opacity: 0; transform: translateX(32px);
  transition: opacity .75s cubic-bezier(.16,1,.3,1), transform .75s cubic-bezier(.16,1,.3,1);
}
.reveal-right.on { opacity: 1; transform: none; }
/* scale in */
.reveal-scale {
  opacity: 0; transform: scale(.94);
  transition: opacity .7s cubic-bezier(.16,1,.3,1), transform .7s cubic-bezier(.16,1,.3,1);
}
.reveal-scale.on { opacity: 1; transform: scale(1); }

/* ── BREADCRUMB ────────────────────────────────── */
.breadcrumb {
  background: var(--c4); padding: .7rem 20px;
  border-bottom: 1px solid var(--c6);
}
.breadcrumb-inner {
  max-width: var(--max); margin: 0 auto;
  font-size: .82rem; color: var(--c3);
  display: flex; gap: .5rem; align-items: center;
}
.breadcrumb-inner a { color: var(--c0); }
.breadcrumb-inner span { color: var(--c6); }

/* ── FILTER TABS ────────────────────────────────── */
.filter-tabs {
  display: flex; flex-wrap: wrap; gap: .5rem;
  margin-bottom: 2.5rem;
}
.filter-tab {
  font-family: var(--f-body); font-size: .82rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: .06em;
  padding: 8px 20px; border-radius: 100px;
  border: 1px solid var(--c6); background: transparent;
  color: var(--c3); cursor: pointer;
  transition: background .2s, color .2s, border-color .2s;
}
.filter-tab:hover, .filter-tab.active {
  background: var(--c0); color: #fff; border-color: var(--c0);
}

/* ── TEAM GRID ─────────────────────────────────── */
.team-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}
.team-card {
  text-align: center;
  background: var(--c5);
  border-radius: 6px;
  border: 1px solid var(--c6);
  padding: 2rem 1.5rem;
  transition: transform .25s, box-shadow .25s;
}
.team-card:hover { transform: translateY(-4px); box-shadow: 0 8px 24px rgba(52,63,30,.1); }
.team-avatar {
  width: 90px; height: 90px; border-radius: 100px;
  background: var(--c4); margin: 0 auto 1.2rem;
  display: flex; align-items: center; justify-content: center;
  font-size: 2rem; overflow: hidden;
}
.team-card h4 { font-size: 1.1rem; margin-bottom: .3rem; }
.team-role {
  font-size: .82rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: .06em;
  color: var(--c0); margin-bottom: .8rem;
}
.team-bio { font-size: .88rem; color: var(--c3); line-height: 1.6; margin: 0; }

/* ── CONTACT FORM ─────────────────────────────── */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; }
.form-group { display: flex; flex-direction: column; gap: .4rem; }
.form-group.full { grid-column: 1 / -1; }
.form-group label {
  font-size: .82rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: .06em;
  color: var(--c2);
}
.form-group input,
.form-group select,
.form-group textarea {
  font-family: var(--f-body); font-size: .95rem;
  padding: 12px 16px; border-radius: 4px;
  border: 1px solid var(--c6);
  background: var(--c5); color: var(--c3);
  transition: border-color .2s, box-shadow .2s;
  outline: none;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--c0);
  box-shadow: 0 0 0 3px rgba(92,134,7,.12);
}
.form-group textarea { resize: vertical; min-height: 140px; }

/* ── STAT ROW ──────────────────────────────────── */
.stat-row {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 1rem; margin: 3rem 0;
}
.stat-item { text-align: center; }
.stat-num {
  font-family: var(--f-heading);
  font-size: clamp(2.5rem, 4vw, 3.5rem);
  color: var(--c0); line-height: 1;
  margin-bottom: .4rem;
}
.stat-label { font-size: .85rem; font-weight: 500; color: var(--c3); }

/* ── PUB LIST ─────────────────────────────────── */
.pub-list { display: flex; flex-direction: column; gap: 1.5rem; }
.pub-item {
  padding: 1.5rem 1.8rem;
  border-radius: 6px;
  border: 1px solid var(--c6);
  background: var(--c5);
  transition: box-shadow .2s;
}
.pub-item:hover { box-shadow: 0 4px 16px rgba(52,63,30,.08); }
.pub-year { font-size: .78rem; font-weight: 600; color: var(--c0); text-transform: uppercase; letter-spacing: .1em; margin-bottom: .3rem; }
.pub-title { font-family: var(--f-heading); font-size: 1.1rem; color: var(--c2); margin-bottom: .4rem; }
.pub-authors { font-size: .88rem; color: var(--c3); margin-bottom: .4rem; }
.pub-journal { font-size: .82rem; font-style: italic; color: rgba(52,63,30,.65); }

/* ── EVENT CARD ───────────────────────────────── */
.event-list { display: flex; flex-direction: column; gap: 1.2rem; }
.event-card {
  display: grid; grid-template-columns: 80px 1fr;
  gap: 1.5rem; align-items: start;
  padding: 1.5rem 1.8rem;
  border-radius: 6px;
  border: 1px solid var(--c6);
  background: var(--c5);
  transition: box-shadow .2s;
}
.event-card:hover { box-shadow: 0 4px 16px rgba(52,63,30,.08); }
.event-date {
  text-align: center;
  background: var(--c4);
  border-radius: 4px;
  padding: .8rem .5rem;
}
.event-date-day {
  font-family: var(--f-heading);
  font-size: 2rem; line-height: 1; color: var(--c0);
}
.event-date-month { font-size: .7rem; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; color: var(--c3); }
.event-title { font-family: var(--f-heading); font-size: 1.1rem; color: var(--c2); margin-bottom: .4rem; }
.event-meta { font-size: .85rem; color: var(--c0); margin-bottom: .5rem; }
.event-desc { font-size: .88rem; color: var(--c3); line-height: 1.6; margin: 0; }

/* ── DOCENTES GUIDE CARDS ─────────────────────── */
.guide-grid {
  display: grid; grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem; margin-top: 2rem;
}
.guide-card {
  padding: 2rem;
  border-radius: 6px;
  border: 1px solid var(--c6);
  background: var(--c5);
  display: flex; gap: 1.2rem; align-items: flex-start;
  transition: transform .2s, box-shadow .2s;
}
.guide-card:hover { transform: translateY(-3px); box-shadow: 0 6px 20px rgba(52,63,30,.1); }
.guide-icon {
  width: 48px; height: 48px; flex-shrink: 0;
  background: var(--c4); border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.4rem;
}
.guide-card h4 { font-size: 1rem; margin-bottom: .4rem; }
.guide-card p { font-size: .87rem; color: var(--c3); line-height: 1.6; margin: 0; }

/* ── STEPS ────────────────────────────────────── */
.steps { display: flex; flex-direction: column; gap: 1.5rem; }
.step {
  display: grid; grid-template-columns: 48px 1fr;
  gap: 1.2rem; align-items: start;
}
.step-num {
  width: 48px; height: 48px;
  background: var(--c0); color: #fff;
  border-radius: 100px;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--f-heading); font-size: 1.1rem;
  flex-shrink: 0;
}
.step h4 { font-size: 1rem; margin-bottom: .3rem; }
.step p { font-size: .88rem; color: var(--c3); line-height: 1.6; margin: 0; }

/* ── RESPONSIVE ───────────────────────────────── */
@media (max-width: 1024px) {
  .why-cards { grid-template-columns: repeat(2, 1fr); }
  .cards { grid-template-columns: repeat(2, 1fr); }
  .team-grid { grid-template-columns: repeat(2, 1fr); }
  .stat-row { grid-template-columns: repeat(2, 1fr); }
  .footer-above-grid { grid-template-columns: 1fr 1fr; gap: 2rem; }
}
@media (max-width: 768px) {
  .nav-links { display: none; flex-direction: column; position: absolute; top: 88px; left: 0; right: 0; background: var(--c5); border-bottom: 1px solid var(--c6); padding: 1rem 0; }
  .nav-links.open { display: flex; }
  .nav-links li a { line-height: 1; padding: 12px 20px; }
  .nav-links li.nav-cta a { margin: 8px 20px; display: inline-block; line-height: 1; }
  .nav-toggle { display: block; }
  .lineas-grid { grid-template-columns: 1fr; }
  .guide-grid { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .event-card { grid-template-columns: 1fr; }
  .event-date { display: flex; gap: .5rem; align-items: center; justify-content: flex-start; }
  /* Fix any inline 2-col grids */
  [style*="grid-template-columns:1fr 1fr"] { grid-template-columns: 1fr !important; }
  [style*="grid-template-columns: 1fr 1fr"] { grid-template-columns: 1fr !important; }
}
@media (max-width: 640px) {
  .sec { padding: 64px 16px; }
  .cards { grid-template-columns: 1fr; }
  .why-cards { grid-template-columns: 1fr; }
  .team-grid { grid-template-columns: 1fr; }
  .stat-row { grid-template-columns: repeat(2, 1fr); }
  .footer-above { padding: 60px 16px; }
  .footer-above-grid { grid-template-columns: 1fr; }
  .hero-content { padding: 60px 16px; }
  .territorial-content { padding: 60px 16px; }
}
