/* ============================= */
/* RESET Y BASE */
/* ============================= */
* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Montserrat', sans-serif;
  margin: 0;
  background: #f4f7fb;
  color: #2C3E50;
}

a {
  color: inherit;
}

/* ============================= */
/* NAVEGACIÓN */
/* ============================= */
nav {
  background: #2C3E50;
  padding: 14px 20px;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  position: sticky;
  top: 0;
  z-index: 1000;
}

nav a {
  color: white;
  text-decoration: none;
  padding: 10px 14px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 14px;
  transition: 0.25s ease;
}

nav a:hover {
  background: rgba(255,255,255,0.12);
}

nav a.active {
  background: #1ABC9C;
}

.lang-switch {
  position: fixed;
  top: 10px;
  right: 14px;
  display: flex;
  gap: 8px;
  z-index: 1100;
}

.lang-switch a,
.lang-switch button {
  background: #1ABC9C;
  color: white;
  border: none;
  text-decoration: none;
  padding: 8px 12px;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 700;
  font-size: 14px;
}

.lang-switch a.inactive,
.lang-switch button.inactive {
  background: #d9e3ea;
  color: #2C3E50;
}

/* ============================= */
/* LAYOUT GENERAL */
/* ============================= */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 50px 20px 60px;
}

.page-header-space {
  padding-top: 44px;
}

.center {
  text-align: center;
}

.muted {
  color: #5f7183;
  font-size: 15px;
}

h1, h2, h3, h4 {
  color: #24384d;
  margin-top: 0;
}

p {
  line-height: 1.7;
}

/* ============================= */
/* HERO */
/* ============================= */
.hero,
.section-card,
.form-box,
.article-card,
.share-box,
.blog-preview-card,
.map-box,
.support-panel {
  background: white;
  border-radius: 22px;
  box-shadow: 0 10px 24px rgba(0,0,0,0.06);
}

.hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 85% 20%, rgba(26,188,156,0.10), transparent 26%),
    radial-gradient(circle at 10% 85%, rgba(44,62,80,0.08), transparent 24%),
    linear-gradient(135deg, #edf5ff, #fbfdff);
  padding: 38px 40px 34px;
  margin-bottom: 26px;
  border: 1px solid #e5edf5;
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto -90px -90px auto;
  width: 280px;
  height: 280px;
  background: radial-gradient(circle, rgba(26,188,156,0.10), transparent 68%);
  pointer-events: none;
}

.hero h1 {
  font-size: clamp(38px, 6vw, 66px);
  line-height: 1.04;
  margin-bottom: 18px;
  max-width: 760px;
}

.hero p {
  max-width: 860px;
  font-size: 18px;
  color: #536679;
  margin-bottom: 14px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #eef8f5;
  border: 1px solid rgba(26,188,156,0.22);
  color: #167d6b;
  padding: 10px 14px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 22px;
}

.hero-actions,
.cta-actions,
.bmc-actions,
.map-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.hero-actions {
  margin-top: 26px;
  align-items: center;
}

/* ============================= */
/* BOTONES */
/* ============================= */
.primary-btn,
.cta-link,
.secondary-link,
.bmc-btn,
.bmc-profile,
.share-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 56px;
  padding: 14px 22px;
  border: none;
  cursor: pointer;
  text-decoration: none;
  font-weight: 800;
  border-radius: 14px;
  transition: transform .25s ease, opacity .25s ease, box-shadow .25s ease;
  line-height: 1;
  white-space: nowrap;
}

.primary-btn {
  background: #1ABC9C;
  color: white;
  box-shadow: 0 10px 20px rgba(26,188,156,0.24);
}

.cta-link {
  background: #2C3E50;
  color: white;
  box-shadow: 0 8px 18px rgba(44,62,80,0.14);
}

.secondary-link {
  background: white;
  color: #2C3E50;
  border: 1px solid #d7dde5;
  box-shadow: 0 8px 18px rgba(0,0,0,0.06);
}

.bmc-btn {
  background: #ffdd00;
  color: #2C3E50;
  box-shadow: 0 10px 18px rgba(255,221,0,0.28);
}

.bmc-profile {
  color: #2C3E50;
  background: white;
  border: 1px solid #d7dde5;
  box-shadow: 0 8px 18px rgba(0,0,0,0.06);
}

.primary-btn:hover,
.cta-link:hover,
.secondary-link:hover,
.bmc-btn:hover,
.bmc-profile:hover,
.share-btn:hover {
  transform: translateY(-1px);
  opacity: 0.97;
}

/* ============================= */
/* HOME */
/* ============================= */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0,1fr));
  gap: 18px;
  margin-bottom: 34px;
}

.stat-card {
  background: white;
  border-radius: 20px;
  padding: 28px 22px;
  text-align: center;
  box-shadow: 0 10px 24px rgba(0,0,0,0.06);
  border: 1px solid #e8eef5;
}

.stat-card .stat-number {
  font-size: clamp(30px, 4vw, 44px);
  line-height: 1;
  color: #1ABC9C;
  font-weight: 800;
  margin-bottom: 10px;
}

.stat-card p {
  margin: 0;
  color: #536679;
  font-size: 16px;
  font-weight: 700;
}

.cta-panel {
  margin-top: 12px;
  padding: 34px 24px;
  text-align: center;
  color: white;
  background:
    radial-gradient(circle at 80% 25%, rgba(255,255,255,0.10), transparent 18%),
    linear-gradient(135deg, #2C3E50, #1ABC9C);
  border-radius: 24px;
  box-shadow: 0 10px 24px rgba(0,0,0,0.09);
}

.cta-panel h2 {
  color: white;
  font-size: clamp(34px, 4vw, 52px);
  margin-bottom: 10px;
}

.cta-panel p {
  max-width: 760px;
  margin: 0 auto 22px;
  color: rgba(255,255,255,0.96);
  font-size: 18px;
  line-height: 1.7;
}

.support-section {
  margin-top: 24px;
  text-align: center;
}

.support-title {
  color: #5f7183;
  font-size: 16px;
  margin: 0 0 14px;
  font-weight: 600;
}

.support-panel {
  max-width: 760px;
  margin: 0 auto;
  padding: 26px 24px;
  border: 1px solid #e6edf5;
}

.support-panel h3 {
  font-size: 28px;
  margin-bottom: 10px;
}

.support-panel p {
  max-width: 620px;
  margin: 0 auto 18px;
  color: #5f7183;
}

/* ============================= */
/* FORMULARIOS */
/* ============================= */
.form-box {
  padding: 25px 20px;
  max-width: 520px;
  margin: 25px auto;
}

input,
textarea,
select {
  width: 100%;
  padding: 12px 14px;
  margin: 8px 0;
  border: 1px solid #d7dde5;
  border-radius: 10px;
  font-family: 'Montserrat', sans-serif;
  font-size: 14px;
}

textarea {
  min-height: 130px;
  resize: vertical;
}

.success-message,
.error-message {
  display: none;
  margin-top: 15px;
  font-weight: 700;
}

.success-message { color: #16a085; }
.error-message { color: #c0392b; }

/* ============================= */
/* BLOG / ARTÍCULOS */
/* ============================= */
.blog-list {
  display: grid;
  gap: 24px;
  margin-top: 30px;
}

.blog-preview-card {
  overflow: hidden;
}

.blog-preview-image {
  width: 100%;
  height: 340px;
  object-fit: cover;
  display: block;
}

.blog-preview-content {
  padding: 24px 22px 28px;
}

.blog-preview-content h3 {
  margin-bottom: 10px;
  font-size: 38px;
}

.blog-meta {
  color: #5f7183;
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 12px;
}

.tag-container {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 18px 0 24px;
}

.tag {
  background: #edf8f5;
  border: 1px solid rgba(26,188,156,0.22);
  color: #167d6b;
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
}

.article-card {
  padding: 30px 28px;
}

.blog-image {
  width: 100%;
  max-width: 760px;
  height: auto;
  max-height: 560px;
  object-fit: contain;
  border-radius: 14px;
  margin: 24px auto;
  display: block;
  background: white;
  box-shadow: 0 10px 24px rgba(0,0,0,0.08);
  padding: 10px;
}

.blog-note {
  background: linear-gradient(135deg, #eefcf8, #f4fbff);
  border-left: 5px solid #1ABC9C;
  border-radius: 14px;
  padding: 18px;
  margin: 22px 0;
  font-weight: 600;
  color: #2c3e50;
}

.blog-video {
  margin: 22px auto;
  max-width: 760px;
}

.blog-video iframe {
  width: 100%;
  max-width: 100%;
  height: 420px;
  border-radius: 18px;
  border: none;
  box-shadow: 0 10px 24px rgba(0,0,0,0.09);
}

.share-box {
  margin-top: 30px;
  padding: 22px 20px;
  border-radius: 18px;
  border: 1px solid #e3ebf3;
  background: linear-gradient(135deg, #f7fbff, #ffffff);
  box-shadow: 0 8px 18px rgba(0,0,0,0.04);
}

.share-box h4 {
  margin: 0 0 8px;
  font-size: 18px;
}

.share-box p {
  margin-bottom: 14px;
  max-width: 100%;
}

.share-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}

.share-btn {
  background: white;
  color: #2C3E50;
  padding: 10px 14px;
  border: 1px solid #dbe6ef;
  box-shadow: 0 6px 14px rgba(0,0,0,0.04);
}

.share-btn img {
  width: 20px;
  height: 20px;
  vertical-align: middle;
  margin-right: 8px;
}

/* ============================= */
/* MAPAS */
/* ============================= */
.map-box {
  background: linear-gradient(135deg, #dff6f2, #eef9ff);
  border: 1px solid #dce9f4;
  padding: 40px 20px;
  margin-top: 20px;
  max-width: 1050px;
  margin-left: auto;
  margin-right: auto;
}

.storymap-frame {
  margin-top: 24px;
}

.storymap-frame iframe {
  width: 100%;
  max-width: 960px;
  height: 620px;
  border: none;
  border-radius: 18px;
  box-shadow: 0 10px 24px rgba(0,0,0,0.10);
  background: white;
}

.map-actions {
  justify-content: center;
  margin-top: 18px;
}

/* ============================= */
/* VIDEOS */
/* ============================= */
.video-section-card {
  padding: 30px;
  margin-top: 20px;
}

.video-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 10px;
  margin-bottom: 0;
}

.video-card {
  background: transparent;
}

.video-card iframe {
  width: 100%;
  max-width: 100%;
  height: 220px;
  border-radius: 14px;
  border: none;
  box-shadow: 0 10px 20px rgba(0,0,0,0.10);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.video-card iframe:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 28px rgba(0,0,0,0.15);
}

.video-more-wrap {
  text-align: center;
  margin-top: 25px;
}

/* ============================= */
/* TIMELINE */
/* ============================= */
.timeline {
  position: relative;
  display: grid;
  gap: 18px;
  margin-top: 22px;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 18px;
  top: 8px;
  bottom: 8px;
  width: 3px;
  background: linear-gradient(180deg, #1ABC9C, rgba(26,188,156,0.15));
  border-radius: 4px;
}

.timeline-item {
  position: relative;
  padding-left: 58px;
}

.timeline-item::before {
  content: "";
  position: absolute;
  left: 10px;
  top: 24px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #1ABC9C;
  box-shadow: 0 0 0 5px rgba(26,188,156,0.15);
}

.timeline-content {
  background: linear-gradient(135deg, #ffffff, #f8fbff);
  border: 1px solid #e3ebf3;
  border-radius: 18px;
  padding: 20px 22px;
  box-shadow: 0 8px 20px rgba(0,0,0,0.05);
}

.timeline-content h4 {
  margin-bottom: 8px;
  font-size: 20px;
}

.timeline-content p {
  max-width: 100%;
  margin-bottom: 0;
}

.timeline-badge {
  display: inline-block;
  background: #2C3E50;
  color: white;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  margin-bottom: 10px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.timeline-item.highlight .timeline-content {
  border: 1px solid rgba(26,188,156,0.35);
  background: linear-gradient(135deg, #eefcf8, #f6fbff);
}

.timeline-item.highlight .timeline-badge {
  background: #1ABC9C;
}

/* ============================= */
/* LEGACY BUY ME A COFFEE */
/* ============================= */
.bmc-container {
  margin-top: 28px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.bmc-qr {
  width: 120px;
  height: 120px;
  border-radius: 10px;
  box-shadow: 0 6px 14px rgba(0,0,0,0.08);
}

/* ============================= */
/* FOOTER */
/* ============================= */
footer {
  background: #2C3E50;
  color: white;
  text-align: center;
  padding: 28px 20px;
  margin-top: 50px;
}

.social {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  margin-top: 12px;
}

.social a img {
  width: 32px;
  height: 32px;
  transition: transform 0.2s ease;
}

.social a img:hover {
  transform: scale(1.08);
}

/* ============================= */
/* RESPONSIVE */
/* ============================= */
@media (max-width: 992px) {
  .stats-grid {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }

  .video-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  nav {
    padding: 12px 10px;
  }

  .lang-switch {
    top: 8px;
    right: 10px;
  }

  .container {
    padding: 35px 14px 50px;
  }

  .page-header-space {
    padding-top: 30px;
  }

  .hero {
    padding: 28px 20px 26px;
  }

  .hero p,
  .cta-panel p {
    font-size: 17px;
  }

  .stats-grid {
    grid-template-columns: 1fr;
  }

  .video-grid {
    grid-template-columns: 1fr;
  }

  .video-card iframe {
    height: 220px;
  }

  .primary-btn,
  .cta-link,
  .secondary-link,
  .bmc-btn,
  .bmc-profile {
    width: 100%;
  }

  .hero-actions,
  .cta-actions,
  .bmc-actions,
  .map-actions {
    flex-direction: column;
  }

  .timeline::before {
    left: 14px;
  }

  .timeline-item {
    padding-left: 46px;
  }

  .timeline-item::before {
    left: 6px;
  }

  .storymap-frame iframe,
  .blog-video iframe {
    height: 320px;
  }

  .blog-image {
    max-width: 100%;
    max-height: none;
    padding: 8px;
  }
}