/* =========================
   CONTAINER GLOBAL
========================= */
.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 40px;
}

/* HEADER interno */
.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: stretch;
}

/* Footer grid ajuste */
.footer-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
}

/* Responsive container */
@media (max-width: 768px) {
  .container {
    padding: 0 20px;
  }
}

/* =========================
   RESET / BASE
========================= */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: Arial, Helvetica, sans-serif;
  color: #1f1f1f;
  line-height: 1.5;
}

a {
  text-decoration: none;
  color: inherit;
}

button {
  cursor: pointer;
  border: none;
  background: none;
  font-family: inherit;
}

/* =========================
   VARIABLES
========================= */
:root {
  --gray-dark: #4b515c;
  --gray-medium: #6b6f78;
  --gray-light: #f2f2f2;
  --yellow: #f5b82e;
  --white: #ffffff;
  --black: #000000;
}


/* =========================
   HEADER
========================= */
.header {
  position: sticky;
  top: 0;
  z-index: 1000;
  display: flex;
  justify-content: space-between;
  align-items: center; /* 🔴 NO stretch */
  background: var(--gray-dark);
  height: 80px; /* altura estable escritorio */
}

/* ----- LEFT ----- */
.header-left {
  display: flex;
  align-items: center;
  padding: 0 40px;
  gap: 40px;
}

.logo {
  font-size: 42px;
  font-weight: bold;
  color: var(--yellow);
}

/* ----- DESKTOP NAV ----- */
.nav-desktop {
  display: flex;
  gap: 30px;
}

.nav-desktop a {
  color: var(--white);
  font-size: 14px;
  letter-spacing: 1px;
  line-height: 1;
}

/* ----- RIGHT ----- */
.header-right {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 0 40px;
  background: transparent; /* 🔴 CLAVE: no amarillo aquí */
  flex-shrink: 0;
}

/* ----- HOME BUTTON ----- */
.home-btn {
  padding: 8px 22px;
  border: 1px solid var(--black);
  border-radius: 20px;
  font-size: 13px;
  background: var(--yellow); /* 🔴 amarillo SOLO aquí */
  color: #000;
  white-space: nowrap;
}

/* ----- HAMBURGER ----- */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
}

.hamburger span {
  width: 24px;
  height: 2px;
  background: var(--black);
}

/* ----- MOBILE NAV ----- */
.nav-mobile {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  background: var(--gray-dark);
  flex-direction: column;
}

.nav-mobile a {
  padding: 15px 30px;
  color: var(--white);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.nav-mobile.open {
  display: flex;
}

/* =========================
   RESPONSIVE (NO TOCAR)
========================= */
@media (max-width: 768px) {
  .nav-desktop {
    display: none;
  }

  .hamburger {
    display: flex;
  }

  .header {
    height: auto;
  }
}


/* =========================
   HERO
========================= */
.hero {
  position: relative;
  height: 90vh;
  overflow: hidden;
}

.hero-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
}

.hero-social {
  position: absolute;
  left: 40px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 18px;
  z-index: 2;
}

.social-icon {
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.social-icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.hero-text {
  position: absolute;
  left: 140px;
  bottom: 120px;
  z-index: 2;
  max-width: 700px;
}

.hero-text h1 {
  color: var(--white);
  font-size: clamp(26px, 4vw, 42px);
  font-weight: 300;
  line-height: 1.2;
  max-width: 100%;
}

/* =========================
   UNIDADES DE NEGOCIO
========================= */
.units {
  width: 100%;
}

/* ===== BLOQUE GRIS ===== */
.units-top {
  background: var(--gray-dark);
  padding: 80px 0 120px; /* MÁS BAJO */
  text-align: center;
  position: relative;
  z-index: 1;
}

.units-title {
  display: inline-block;
  padding: 10px 30px;
  border: 1px solid var(--white);
  color: var(--white);
  letter-spacing: 2px;
  font-size: 14px;
}

/* ===== FONDO BLANCO ===== */
.units-bg {
  background-image: url("../assets/placeholders/Fondo.png");
  background-repeat: repeat;
  background-position: center;
  background-size: auto;
  position: relative;
  z-index: 2;
}

/* ===== CONTENIDO ===== */
.units-content {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 80px 60px; /* 🔴 ya NO depende del círculo */
}

/* ===== ITEM ===== */
.unit {
  text-align: center;
}

/* ===== CÍRCULO (CLAVE) ===== */
.unit-circle {
  width: 240px;
  height: 240px;
  background: var(--black);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;

  position: relative;
  top: -120px; /* 🔴 controla superposición SIN inflar fondo */
  margin: 0 auto 20px;
}

.unit-circle img {
  max-width: 165px;
  max-height: 165px;
  object-fit: contain;
}

/* ===== LABEL ===== */
.unit-label {
  display: inline-block;
  padding: 8px 26px;
  border: 1px solid var(--black);
  border-radius: 20px;
  margin-bottom: 14px;
  font-size: 13px;
}

/* ===== TEXTO ===== */
.unit p {
  font-size: 14px;
  color: #555;
  max-width: 260px;
  margin: 0 auto;
  line-height: 1.5;
}

/* =========================
   RESPONSIVE
========================= */
@media (max-width: 1024px) {
  .units-content {
    grid-template-columns: 1fr;
    padding: 60px 40px 40px;
  }

  .unit-circle {
    top: 0; /* móvil SIN superposición */
    margin-bottom: 20px;
  }
}

@media (max-width: 768px) {
  .units-top {
    padding-bottom: 100px;
  }

  .units-content {
    padding: 40px 30px 40px;
  }

  .unit {
    margin-bottom: 50px;
  }
}


/* =========================
   PROYECTOS
========================= */
.projects-editorial {
  background: #f5b82e;
  padding: 120px 0;
  position: relative;
  overflow: hidden;
}


/* ===== PROYECTO BASE ===== */
.project {
  position: relative;
  min-height: 520px;
  margin-bottom: 120px;
}

.project:last-child {
  margin-bottom: 0;
}

.project-content {
  width: 42%;
  padding: 80px;
  position: relative;
  z-index: 2;
}

.project-content h2 {
  font-size: 34px;
  margin-bottom: 12px;
}

.project-line {
  display: block;
  width: 40px;
  height: 2px;
  background: #000;
  margin-bottom: 30px;
}

.project-content p {
  font-size: 14px;
  line-height: 1.6;
  margin-bottom: 40px;
  max-width: 420px;
}

.project-btn {
  display: inline-block;
  padding: 12px 32px;
  background: #fff;
  color: #000;
  font-size: 13px;
  border-radius: 4px;
}

/* ===== IMÁGENES ===== */
.project-image {
  position: absolute;
  top: 0;
  width: 55%;
  height: 100%;
  background-size: cover;
  background-position: center;
}

/* ===== PROYECTO A ===== */
.project-a .project-content {
  margin-left: 80px;
}

.project-a .project-image {
  right: 0;
}

.img-tortugas {
  background-image: url("../assets/placeholders/tortugas.png");
}

/* ===== PROYECTO B ===== */
.project-b {
  display: flex;
  justify-content: flex-end;
}

.project-b .project-content {
  margin-right: 80px;
  text-align: left;
}

.project-b .project-image {
  left: 0;
}

.img-portal {
  background-image: url("../assets/placeholders/portal.png");
}

/* =========================
   FIX DEFINITIVO PROYECTOS MOBILE
========================= */
@media (max-width: 768px) {

  .projects-editorial {
    padding: 48px 16px;
    overflow: visible;
  }

  .project {
    display: block;
    margin-bottom: 40px;
    min-height: auto;
    overflow: visible;
  }

  .project-image {
    position: relative;
    width: 100%;
    height: 220px;
    margin: 0;
  }

  .project-content {
    width: 100% !important;     /* 🔴 MATA el 42% */
    max-width: 100%;
    padding: 24px 0 !important; /* 🔴 MATA el padding 80px */
    margin: 0 !important;
    box-sizing: border-box;
    text-align: left;
  }

  .project-content h2,
  .project-content p {
    max-width: 100%;
    margin-left: 0;
    margin-right: 0;
  }

}




/* =========================
   POR QUÉ NOSOTROS
========================= */
.why {
  position: relative;
  padding: 120px 0;
  text-align: center;
  background: linear-gradient(
    to bottom,
    #f5b82e 0px,
    #f5b82e 260px,   /* TÍTULO + TEXTO */
    #ffffff 340px,  /* BLANCO ANTES DE ICONOS */
    #ffffff 100%
  );
}

/* TÍTULO */
.why h2 {
  font-size: 36px;
  margin-bottom: 20px;
  color: #111;
}

/* TEXTO INTRODUCTORIO */
.why-intro {
  max-width: 900px;
  margin: 0 auto 80px;
  color: #666;
  font-size: 14px;
  line-height: 1.6;
}

/* GRID */
.why-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 60px;
  margin-bottom: 80px;
}

/* ITEM */
.why-item {
  text-align: center;
}

/* ICONOS */
.why-icon {
  width: 90px;
  height: 90px;
  margin: 0 auto 25px;
}

.why-icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* LABEL */
.why-label {
  display: inline-block;
  background: var(--yellow);
  color: var(--white);
  padding: 10px 26px;
  border-radius: 20px;
  font-size: 13px;
  margin-bottom: 20px;
}

/* TEXTO */
.why-item p {
  font-size: 13px;
  color: #666;
  line-height: 1.5;
}

/* CTA */
.why-cta {
  display: inline-block;
  padding: 14px 40px;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-size: 13px;
  color: #666;
  transition: all 0.3s ease;
}

.why-cta:hover {
  background: var(--yellow);
  color: #000;
  border-color: var(--yellow);
}

/* =========================
   RESPONSIVE
========================= */
@media (max-width: 1024px) {
  .why-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .why {
    padding-top: 60px;
    background: linear-gradient(
      to bottom,
      #f5b82e 0px,
      #f5b82e 320px,   /* MÁS TEXTO EN MOBILE */
      #ffffff 420px,
      #ffffff 100%
    );
  }

  .why-grid {
    grid-template-columns: 1fr;
    gap: 50px;
  }
}
/* =========================
   GALERÍA
========================= */
.gallery {
  width: 100%;
  background: #ffffff;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}

.gallery-item {
  width: 100%;
  height: 220px;
  overflow: hidden;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* =========================
   RESPONSIVE
========================= */
@media (max-width: 1024px) {
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .gallery-item {
    height: 240px;
  }
}

@media (max-width: 768px) {
  .gallery-grid {
    grid-template-columns: 1fr;
  }

  .gallery-item {
    height: 220px;
  }
}


/* =========================
   CONTACTO
========================= */
.contact {
  padding: 120px 60px;
}

.contact h2 {
  font-size: 36px;
  margin-bottom: 60px;
}

.contact-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
}

.contact-form label {
  display: block;
  font-size: 13px;
  color: #333;
  margin-bottom: 18px;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 12px;
  margin-top: 6px;
  border: 1px solid #333;
  font-family: inherit;
  font-size: 14px;
}

.contact-form textarea {
  height: 220px;
  resize: none;
}

.contact-btn {
  margin-top: 20px;
  padding: 14px 40px;
  border: 1px solid #000;
  background: var(--yellow);
  font-size: 13px;
  cursor: pointer;
}

/* RESPONSIVE */
@media (max-width: 768px) {
  .contact-form {
    grid-template-columns: 1fr;
  }
}


/* =========================
   FOOTER
========================= */
.footer {
  background: var(--gray-dark);
  color: var(--white);
  padding: 80px 0;
}

/* GRID REAL */
.footer-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 60px;
}

/* COLUMNA */
.footer-col h4 {
  margin-bottom: 20px;
  font-size: 16px;
}

.footer-col p {
  font-size: 14px;
  margin-bottom: 8px;
  color: #e0e0e0;
}

/* SUBSCRIBE */
.footer-subscribe input {
  width: 100%;
  padding: 14px;
  border: none;
  font-size: 14px;
}

/* =========================
   RESPONSIVE FOOTER
========================= */
@media (max-width: 1024px) {
  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 40px;
  }

  .footer-subscribe {
    grid-column: span 2;
  }
}

@media (max-width: 768px) {
  .footer {
    padding: 60px 0;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .footer-subscribe {
    grid-column: auto;
  }
}
