:root {
  --primary: #1b4332;
  --secondary: #0c8f1e;
  --naranja-principal: #f16922;
  --amarillo-principal: #ffb600;
  --azul-principal: #2b3c96;
  --marron-principal: #442a0a;
  --verde-principal: #096d17;
  --naranja-oscuro: #d4660c;
  --naranja-claro: #ffa331;
  --naranja: #ffb600;
  --accent: #d4e157;
  --soft-green: #f1f8f3;
  --white: #ffffff;
  --text-main: #2d3436;
  --text-muted: #636e72;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Plus Jakarta Sans", sans-serif;
  background-color: var(--white);
  color: var(--text-main);
  line-height: 1.8;
}

h1,
h2,
h3,
h4 {
  font-family: "Outfit", sans-serif;
}

/* ==================== NAVIGATION ==================== */
nav {
  padding: 1.5rem 10%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: absolute;
  width: 100%;
  z-index: 1000;
}

.logo {
  font-weight: 800;
  font-size: 1.5rem;
  color: var(--white);
  text-decoration: none;
}

.navbar-logo {
  max-width: 200px;
  height: auto;
}

.back-link {
  position: fixed;
  top: 20px;
  right: 100px;
  z-index: 1000;
  background: #d4660c;
  color: var(--white);
  text-decoration: none;
  font-weight: 700;
  padding: 0.8rem 2rem;
  border-radius: 50px;
  font-size: 0.85rem;
  letter-spacing: 1px;
  transition: 0.3s;
  border: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  gap: 0.5rem; /* Espacio entre flecha y texto */
  padding: 0.8rem 2rem 0.8rem 1.5rem; /* Ajusta padding izquierdo */
}
.back-link svg {
  width: 16px;
  height: 16px;
  transition: transform 0.3s;
}

.back-link:hover {
  background: #ffb600;
  color: var(--text-main);
}

.back-link:hover svg {
  transform: translateX(-3px); /* Efecto al hover */
}

/* En pantallas pequeñas */
@media (max-width: 768px) {
  .back-link {
    top: auto; /* Quita el top fijo */
    bottom: 20px; /* Lo coloca abajo */
    right: 50%; /* Centra horizontalmente */
    transform: translateX(50%); /* Ajusta para centrar perfectamente */
  }
}

/* ==================== HERO SECTIONS ==================== */
/* Hero general para sostenibilidad */
.sus-hero {
  height: 80vh;
  background:
    linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.4)),
    url("../images/sostenibilidad.png");
  background-size: cover;
  background-position: center;
  background-attachment: fixed; /* Esto crea el efecto parallax */
  background-repeat: no-repeat; /* Recomendable añadir esto también */
  display: flex;
  align-items: center;
  padding: 0 10%;
  color: var(--white);
}
@media (max-width: 768px) {
  .sus-hero {
    background-attachment: scroll;
  }
}

/* Hero general para nosotros */
.about-hero {
  height: 80vh;
  background:
    linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.4)),
    url("../images/planta-int.png");
  background-size: cover;
  background-position: center;
  background-attachment: fixed; /* Esto crea el efecto parallax */
  background-repeat: no-repeat; /* Recomendable añadir esto también */
  display: flex;
  align-items: center;
  padding: 0 10%;
  color: var(--white);
}
@media (max-width: 768px) {
  .about-hero {
    background-attachment: scroll;
  }
}

/* Hero general para acopios */
.acopios-hero {
  height: 80vh;
  background:
    linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.4)),
    url("../images/acopios.png");
  background-size: cover;
  background-position: center;
  background-attachment: fixed; /* Esto crea el efecto parallax */
  background-repeat: no-repeat; /* Recomendable añadir esto también */
  display: flex;
  align-items: center;
  padding: 0 10%;
  color: var(--white);
}
@media (max-width: 768px) {
  .acopios-hero {
    background-attachment: scroll;
  }
}

/* Hero general para productos */
.productos-hero {
  height: 80vh;
  background:
    linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.4)),
    url("../images/productos.png");
  background-size: cover;
  background-position: center;
  background-attachment: fixed; /* Esto crea el efecto parallax */
  background-repeat: no-repeat; /* Recomendable añadir esto también */
  display: flex;
  align-items: center;
  padding: 0 10%;
  color: var(--white);
}
@media (max-width: 768px) {
  .productos-hero {
    background-attachment: scroll;
  }
}

/* Hero general para sostenibilidad */
.historia-hero {
  height: 80vh;
  background:
    linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.4)),
    url("../images/historia.png");
  background-size: cover;
  background-position: center;
  background-attachment: fixed; /* Esto crea el efecto parallax */
  background-repeat: no-repeat; /* Recomendable añadir esto también */
  display: flex;
  align-items: center;
  padding: 0 10%;
  color: var(--white);
}

@media (max-width: 768px) {
  .historia-hero {
    background-attachment: scroll;
  }
}

.hero-title {
  animation: fadeUp 0.8s ease forwards;
}

.hero-title h1 {
  font-size: clamp(3rem, 8vw, 5.5rem);
  line-height: 1.2;
  font-weight: 800;
  margin-bottom: 1.5rem;
}

.hero-title p {
  font-size: 1.2rem;
  max-width: 700px;
  opacity: 0.9;
}

/* ==================== SECCIÓN COMPROMISO ==================== */
.commitment {
  padding: 10rem 10%;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6rem;
  align-items: center;
}

.commitment-text h2 {
  font-size: 3rem;
  color: var(--primary);
  margin-bottom: 2rem;
  line-height: 1.1;
}

.commitment-text p {
  font-size: 1.1rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

.commitment-image {
  position: relative;
  transition: 0.4s ease;
}

.commitment-image:hover {
  transform: translateY(-15px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.05);
}

.commitment-image img {
  width: 100%;
  border-radius: 40px;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.1);
}

.floating-card {
  position: absolute;
  top: -20px;
  right: -20px;
  background: var(--secondary);
  color: var(--white);
  padding: 2.5rem 1.5rem;
  border-radius: 50%;
  font-weight: 800;
  text-align: center;
  line-height: 1;
  font-size: 1.2rem;
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
  width: 140px;
  height: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ==================== QUIÉNES SOMOS ==================== */
.who-we-are {
  padding: 10rem 10%;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6rem;
  align-items: center;
}

.image-stack {
  position: relative;
  transition: 0.4s ease;
}

.image-stack:hover {
  transform: translateY(-15px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.05);
}

.image-stack img {
  width: 100%;
  border-radius: 40px;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.1);
}

.badge-experience {
  position: absolute;
  top: -20px;
  right: -20px;
  background: var(--secondary);
  color: var(--white);
  padding: 2.5rem 1.5rem;
  border-radius: 50%;
  font-weight: 800;
  text-align: center;
  line-height: 1;
  font-size: 1.2rem;
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.text-content h2 {
  font-size: 3rem;
  color: var(--primary);
  margin-bottom: 2rem;
  line-height: 1.1;
}

.text-content p {
  font-size: 1.1rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

/* ==================== DASHBOARDS ==================== */
/* Dashboard de impacto (sostenibilidad) */
.impact-dashboard {
  padding: 8rem 10%;
  background: #0b1a13;
  color: var(--white);
  border-radius: 60px 60px 0 0;
  text-align: center;
  opacity: 0;
  transform: translateY(30px);
  transition:
    opacity 2s ease,
    transform 2s ease;
}

.impact-dashboard.visible {
  opacity: 1;
  transform: translateY(0);
}

.impact-dashboard h2 {
  font-size: 3rem;
  margin-bottom: 1.5rem;
}

.impact-dashboard > p {
  color: rgba(255, 255, 255, 0.8);
  max-width: 700px;
  margin: 0 auto 4rem;
}

/* Animación escalonada para las métricas */
.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
}

.metric-box {
  opacity: 0;
  transform: translateY(20px);
  transition:
    opacity 0.6s ease,
    transform 0.6s ease;
}

.impact-dashboard.visible .metric-box:nth-child(1) {
  transition-delay: 0.1s;
}
.impact-dashboard.visible .metric-box:nth-child(2) {
  transition-delay: 0.2s;
}
.impact-dashboard.visible .metric-box:nth-child(3) {
  transition-delay: 0.3s;
}
.impact-dashboard.visible .metric-box:nth-child(4) {
  transition-delay: 0.4s;
}

.impact-dashboard.visible .metric-box {
  opacity: 1;
  transform: translateY(0);
}

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
}

.metric-box {
  padding: 2.5rem 1rem;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: 0.3s;
}

.metric-box:hover {
  background: rgba(255, 255, 255, 0.1);
  transform: translateY(-5px);
}

.metric-box h4 {
  font-size: 3.5rem;
  color: var(--accent);
  margin-bottom: 0.5rem;
}

.metric-box p {
  font-weight: 600;
  opacity: 0.7;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Animaciones FADEUP */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Dashboard corporativo (conócenos) */
.corporate-data {
  background: var(--primary);
  padding: 8rem 10%;
  color: var(--white);
  border-radius: 60px 60px 0 0;
}

.data-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 4rem;
}

.data-item h3 {
  font-size: 3.5rem;
  color: var(--accent);
  margin-bottom: 0.5rem;
}

.data-item p {
  font-weight: 600;
  opacity: 0.7;
  font-size: 0.9rem;
  text-transform: uppercase;
}

/* ==================== PILARES / VALORES ==================== */
.pilares {
  padding: 10rem 10%;
  background: var(--soft-green);
}

.values-section {
  padding: 10rem 10%;
  background: var(--soft-green);
}

.section-header {
  margin-bottom: 5rem;
  text-align: center;
}

.section-header h2 {
  font-size: 3rem;
  color: var(--primary);
  margin-bottom: 1rem;
}

.section-header p {
  color: var(--text-muted);
  font-size: 1.1rem;
}

.pilar-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.5rem;
}

.values-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.5rem;
}

.pilar-card,
.value-card {
  background: var(--white);
  padding: 3.5rem;
  border-radius: 35px;
  transition: 0.4s;
}

.pilar-card:hover,
.value-card:hover {
  transform: translateY(-15px);
}

.pilar-card .icon {
  font-size: 3rem;
  margin-bottom: 1.5rem;
  display: block;
}

.pilar-card h3,
.value-card h4 {
  font-size: 1.8rem;
  color: var(--primary);
  margin-bottom: 1rem;
}

.pilar-card p {
  color: var(--text-muted);
  line-height: 1.7;
}

.value-card .dot {
  width: 40px;
  height: 10px;
  background: var(--accent);
  display: block;
  margin-bottom: 2rem;
  border-radius: 10px;
}

/* ==================== CERTIFICACIONES ==================== */
.certs {
  padding: 5rem 10%;
  border-top: 1px solid #eee;
  display: flex;
  justify-content: space-around;
  align-items: center;
  opacity: 0.6;
  filter: grayscale(1);
}

.certs span {
  font-weight: 600;
  font-size: 0.9rem;
  letter-spacing: 1px;
}

/* ==================== INTRODUCCIÓN ==================== */
.intro-history,
.acopio-intro {
  padding: 6rem 10% 4rem;
  text-align: center;
  max-width: 900px;
  margin: 0 auto;
}

.intro-history h2,
.acopio-intro h2 {
  font-size: 2.5rem;
  color: var(--primary);
  margin-bottom: 1.5rem;
}

.intro-history p,
.acopio-intro p {
  font-size: 1.1rem;
  color: var(--text-muted);
}

/* ==================== GRID DE SEDES ==================== */
.locations-grid {
  padding: 0 10% 8rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 2rem;
}

.location-card {
  background: var(--white);
  padding: 2.5rem;
  border-radius: 25px;
  border: 1px solid #eee;
  transition: 0.4s ease;
  position: relative;
  overflow: hidden;
}

.location-card:hover {
  border-color: var(--accent);
  transform: translateY(-10px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.05);
}

.location-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 5px;
  height: 100%;
  background: var(--naranja);
}

.location-number {
  font-size: 0.8rem;
  font-weight: 800;
  color: var(--naranja-oscuro);
  margin-bottom: 0.5rem;
  display: block;
}

.location-card h3 {
  font-size: 1.5rem;
  color: var(--primary);
  margin-bottom: 1rem;
}

.location-details {
  list-style: none;
}

.location-details li {
  margin-bottom: 0.8rem;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  gap: 10px;
}

.status-badge {
  background: #e8f5e9;
  color: #2e7d32;
  padding: 0.3rem 0.8rem;
  border-radius: 50px;
  font-size: 0.7rem;
  font-weight: 700;
  display: inline-block;
  margin-top: 1rem;
}

/* ==================== INFO LOGÍSTICA ==================== */
.logistics-info {
  background: var(--primary);
  color: var(--white);
  padding: 6rem 10%;
  display: flex;
  flex-wrap: wrap;
  gap: 4rem;
  align-items: center;
}

.info-box {
  flex: 1;
  min-width: 300px;
}

.info-box h2 {
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
  color: var(--accent);
}

/* ==================== CATÁLOGO ==================== */
.catalog {
  padding: 8rem 10%;
  max-width: 1400px;
  margin: 0 auto;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(500px, 1fr));
  gap: 4rem;
}

.product-card {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  background: var(--white);
  border-radius: 30px;
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.03);
  transition: 0.4s ease;
  border: 1px solid #eee;
}

.product-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.1);
}

.product-img {
  background-size: cover;
  background-position: center;
  min-height: 350px;
}

.product-info {
  padding: 3rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.product-category {
  color: var(--naranja-oscuro);
  text-transform: uppercase;
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 2px;
  margin-bottom: 0.5rem;
}

.product-info h3 {
  font-size: 2rem;
  color: var(--primary);
  margin-bottom: 1rem;
  line-height: 1.2;
}

.product-info p {
  color: var(--text-muted);
  margin-bottom: 2rem;
  font-size: 0.95rem;
}

.specs {
  list-style: none;
  border-top: 1px solid #f0f0f0;
  padding-top: 1.5rem;
}

.specs li {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.5rem;
  font-size: 0.85rem;
}

.specs li strong {
  color: var(--primary);
}

/* ==================== BANNER DE CALIDAD ==================== */
.quality-banner {
  background: var(--primary);
  color: var(--white);
  padding: 5rem 10%;
  text-align: center;
  border-radius: 50px;
  margin: 0 5% 8rem;
}

.quality-banner h2 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.quality-banner p {
  opacity: 0.8;
  max-width: 700px;
  margin: 0 auto;
}

/* ==================== TIMELINE ==================== */
.timeline {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  padding: 4rem 2rem;
}

/* Línea central */
.timeline::after {
  content: "";
  position: absolute;
  width: 2px;
  background: #e0e0e0;
  top: 0;
  bottom: 0;
  left: 50%;
  margin-left: -1px;
}

.timeline-item {
  padding: 10px 40px;
  position: relative;
  background-color: inherit;
  width: 50%;
}

/* El círculo en la línea */
.timeline-item::after {
  content: "";
  position: absolute;
  width: 20px;
  height: 20px;
  right: -10px;
  background-color: var(--accent);
  border: 4px solid var(--primary);
  top: 15px;
  border-radius: 50%;
  z-index: 1;
}

.left {
  left: 0;
  text-align: right;
}

.right {
  left: 50%;
}

.right::after {
  left: -10px;
}

.content {
  padding: 2rem;
  background-color: var(--white);
  position: relative;
  border-radius: 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
  transition: 0.3s;
}

.content:hover {
  transform: scale(1.02);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.08);
}

.year {
  display: block;
  font-size: 2rem;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 0.5rem;
}

.content h3 {
  margin-bottom: 1rem;
  color: var(--text-main);
}

/* ==================== FUNDADORES ==================== */
.founders {
  background: var(--primary);
  color: var(--white);
  padding: 8rem 10%;
  text-align: center;
}

.founders-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 3rem;
  margin-top: 4rem;
}

.founder-card img {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  background: #eee;
  margin-bottom: 1.5rem;
  object-fit: cover;
  border: 4px solid var(--accent);
}

/* ==================== CTA FINAL ==================== */
.sus-footer {
  padding: 6rem 10%;
  text-align: center;
  background: var(--primary);
  color: rgba(255, 255, 255, 0.5);
}

.sus-footer h2 {
  font-size: 3rem;
  color: var(--white);
  margin-bottom: 2rem;
}

.sus-footer > p {
  margin-bottom: 2.5rem;
  opacity: 0.8;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.download-btn {
  background: #ffa331;
  color: var(--white);
  padding: 1.2rem 3rem;
  border-radius: 50px;
  text-decoration: none;
  font-weight: 700;
  display: inline-block;
  transition: 0.3s;
  letter-spacing: 0.5px;
}

.download-btn:hover {
  background: var(--white);
  transform: scale(1.05);
  color: var(--text-main);
}

.conocenos-btn {
  background: #ffa331;
  color: var(--white);
  padding: 1.2rem 3rem;
  border-radius: 50px;
  text-decoration: none;
  font-weight: 700;
  display: inline-block;
  transition: 0.3s;
  letter-spacing: 0.5px;
}

.conocenos-btn:hover {
  background: var(--secondary);
  transform: scale(1.05);
  color: var(--white);
}

/* Footer estilo Apple */
.footer {
  background: #1d1d1f;
  color: #ffffff;
  padding: 80px 20px 40px;
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
}

.footer-column h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 25px;
  color: #86868b;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.footer-column ul {
  list-style: none;
}

.footer-column ul li {
  margin-bottom: 15px;
}

.footer-column ul li a {
  color: #ffffff;
  text-decoration: none;
  font-size: 0.95rem;
  opacity: 0.8;
  transition: opacity 0.3s ease;
}

.footer-column ul li a:hover {
  opacity: 1;
}

.footer-bottom {
  max-width: 1200px;
  margin: 60px auto 0;
  padding-top: 40px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
  color: #86868b;
  font-size: 0.9rem;
}

/* ==================== RESPONSIVE ==================== */
@media (max-width: 1100px) {
  .dashboard-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
  }
}

@media (max-width: 1024px) {
  .product-card {
    grid-template-columns: 1fr;
  }
  .product-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .commitment,
  .pilar-grid,
  .values-grid,
  .who-we-are {
    grid-template-columns: 1fr;
  }

  .commitment {
    gap: 4rem;
  }

  .commitment-image {
    order: -1;
  }

  .certs {
    flex-direction: column;
    gap: 1.5rem;
  }

  .about-hero {
    padding: 0 5%;
  }
}

@media (max-width: 768px) {
  .acopio-hero h1 {
    font-size: 2.5rem;
  }

  .timeline::after {
    left: 31px;
  }

  .timeline-item {
    width: 100%;
    padding-left: 70px;
    padding-right: 25px;
    text-align: left;
  }

  .timeline-item::after {
    left: 21px;
  }

  .right {
    left: 0%;
  }

  .left {
    text-align: left;
  }
}

@media (max-width: 600px) {
  .dashboard-grid {
    grid-template-columns: 1fr;
  }

  nav {
    padding: 1rem 5%;
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }

  .navbar-logo {
    max-width: 160px;
  }

  .hero-title h1 {
    font-size: 2.5rem;
  }

  .hero-title p {
    font-size: 1rem;
  }

  .footer-container {
    grid-template-columns: 1fr;
  }
}
