/* Reset y variables */
:root {
  --bg: #ffffff;
  --black: #000000;
  --text: #22221c;
  --gold: #bf930d;
  --card-height: 220px;
  --card-gap: 0;
  --max-width: 1200px;
  --vh: 1vh;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
html,
body {
  height: 100%;
}
body {
  font-family: "Poppins", system-ui, -apple-system, "Segoe UI", Roboto,
    "Helvetica Neue", Arial;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: calc(var(--vh) * 100);
}

/* SPLASH / LOADER */
#splash {
  position: fixed;
  inset: 0;
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  overflow: hidden;
}

#splash-inner {
  display: flex;
  align-items: center;
  justify-content: center;
}

#splash-logo {
  width: 520px;
  height: auto;
  will-change: transform, opacity;
}

/* Header (logo top center after splash) */
.site-header {
  position: static;
  top: 0;
  width: 100%;
  z-index: 50;
  background: transparent;
  padding: 18px 0;
  display: flex;
  justify-content: center;
  align-items: center;
}

#header-logo {
  height: 60px;
  width: auto;
  opacity: 0;
  transform: scale(0.9);
}

/* ================================
   BOTÓN CONOCENOS
================================ */

.header-inner {
  position: relative;
  width: 100%;
  max-width: var(--max-width);
  padding: 0 20px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.btn-conocenos {
  position: absolute;
  right: 20px;
  margin-top: 18px;
  transform: translateY(-50%);
  padding: 8px 18px;
  border: 1px solid #4e84a7;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 500;
  text-decoration: none;
  color: #4e84a7;
  background: transparent;
  transition: all 0.25s ease;
  letter-spacing: 0.3px;
}

.btn-conocenos:hover {
  background: #00224e;
  color: #fff;
  transform: translateY(-50%) scale(1.05);
}

/* Layout */
.container {
  max-width: var(--max-width);
  margin: 40px auto;
  padding: 0 20px;
}

/* Rows and columns (grid) */
.row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
  align-items: start;
  margin-bottom: 4px;
}

/* RUBROS */
.rubros-section {
  padding: 0.5rem;
  text-align: center;
}

.rubros-title,
.marketing-title {
  font-size: 2.2rem;
  margin: 1.7rem 0;
  font-weight: 600;
  color: #00224e;
  letter-spacing: 0.7px;
  overflow: hidden;
  display: inline-block;
}

.rubros-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem;
}

.rubro-card {
  color: #22221c;
  padding: 1rem 1.2rem;
  min-width: 140px;
  border: 1px solid #4e84a7;
  border-radius: 12px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  align-items: center;
  font-weight: 500;
  font-size: 1rem;
  opacity: 0;
  transform: translateY(50px) rotateX(20deg);
}

.rubro-card i {
  color: #00224e;
  font-size: 1.3rem;
  margin-bottom: 0.3rem;
}

.rubro-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 25px rgba(0, 0, 0, 0.4);
}

/* MARKETING 360 SECTION */
.marketing360-section {
  padding: 20px;
  margin-top: 60px;
  max-width: var(--max-width);
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.marketing-title {
  font-size: 3rem;
  margin-bottom: 1rem;
}

.marketing-wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  align-items: center;
}

.marketing-img img {
  width: 100%;
  height: 80%;
  filter: drop-shadow(1px 1px 8px #22221c63);
  opacity: 0;
  transform: translateY(120px);
}

.marketing-content {
  text-align: left;
  opacity: 0;
  transform: translateY(100px);
}

.marketing-content p {
  font-size: 1.1rem;
  letter-spacing: 0.7px;
  line-height: 1.5;
  margin-bottom: 16px;
  color: var(--text);
}

.marketing-list {
  list-style: none;
  margin: 0 0 20px 0;
  padding: 0;
}

.marketing-list li {
  font-size: 1rem;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.marketing-list i {
  color: #00224e;
  font-size: 1.1rem;
}

.btn-gold {
  display: inline-block;
  padding: 12px 20px;
  background: #00224e;
  color: white;
  border-radius: 8px;
  font-weight: 600;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn-gold:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

/* Procesos */
.procesos {
  padding: 4rem 2rem;
  text-align: center;
}

.procesos h2 {
  text-align: center;
  font-size: 2rem;
  color: #00224e;
  margin-bottom: 2rem;
}

.grid-procesos h3 {
  font-weight: 600;
  color: #00224e;
}

.procesos p {
  color: #22221c;
}

.grid-procesos {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.proceso {
  padding: 1.5rem;
  background: none;
  border: 1px solid #4e84a7;
  border-radius: 14px;
  text-align: left;
  cursor: pointer;
  transition: transform 0.3s, box-shadow 0.3s;
}

.proceso:hover {
  transform: translateY(-5px); /* Movimiento hacia arriba */
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3); /* Sombra suave */
}

/* HERRAMIENTAS */

.tools-section {
  margin-top: 80px;
  text-align: center;
}

.tools-title {
  color: #00224e;
  font-size: 2rem;
  font-weight: 600;
  margin-bottom: 40px;
}

.tools-slider {
  width: 100%;
  overflow: hidden;
  position: relative;
}

.tools-track {
  display: flex;
  width: max-content;
  gap: 60px;
  animation: scroll 25s linear infinite;
}

.tool img {
  height: 55px;
  filter: grayscale(100%);
  opacity: 0.7;
  transition: 0.3s ease;
}

.tool img:hover {
  filter: grayscale(0%);
  opacity: 1;
}

@keyframes scroll {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

/* ================================
   FOOTER
================================ */

.main-footer {
  position: relative;
  padding: 60px 20px 30px;
  color: #fff;
  background: #111;
  overflow: hidden;
}

/* Fondo tipo mapa con red */
.main-footer::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("/figles-landing/assets/footer-map.jpg");
  background-size: cover;
  background-position: center;
  opacity: 0.16;
  z-index: 1;
}

.footer-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.6),
    rgba(0, 0, 0, 0.9)
  );
  z-index: 2;
}

/* GRID */
.footer-grid {
  position: relative;
  z-index: 3;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
  max-width: 1200px;
  margin: auto;
}

/* COLUMNAS */
.footer-col {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.footer-title {
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: 4px;
}

/* LOGO */
.footer-logo {
  margin-top: 2rem;
  width: 180px;
  transition: transform 0.3s ease;
}
.footer-logo:hover {
  transform: scale(1.06);
}

/* LINKS */
.footer-link,
.footer-contact {
  color: #eaeaea;
  text-decoration: none;
  font-size: 0.95rem;
  transition: color 0.3s ease;
}

.footer-link:hover,
.footer-contact:hover {
  color: #bf930d;
}

/* ÍCONOS DE CONTACTO */
.footer-contact i {
  font-size: 1.1rem;
}

/* REDES SOCIALES */
.footer-socials {
  justify-content: center;
  align-items: center;
  display: flex;
  gap: 34px;
}

.social-icon {
  font-size: 32px;
  color: #eaeaea;
  transition: transform 0.3s ease, color 0.3s ease;
}
.social-icon:hover {
  transform: scale(1.15);
  color: #bf930d;
}

/* COPYRIGHT */
.footer-copy {
  position: relative;
  z-index: 3;
  margin-top: 30px;
  text-align: center;
  font-size: 0.9rem;
  opacity: 0.8;
}

/* Slogan */
.slogan {
  font-size: 2.2rem;
  line-height: 1.2;
  font-weight: 600;
  color: #00224e;
  opacity: 0;
  transform: translateX(-40px);
  max-width: 100%;
}

/* Cards */
.card {
  display: block;
  position: relative;
  height: var(--card-height);
  border-radius: 14px;
  overflow: hidden;
  background-size: cover;
  background-position: center;
  text-decoration: none;
  color: white;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
  transform-origin: center;
  will-change: transform, opacity;
}

/* large card occupies two cols width on desktop */
.large-card {
  height: var(--card-height);
}

.col-2-3 {
  grid-column: 2 / 4;
}

.card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.12), rgba(0, 0, 0, 0.25));
  transition: background 300ms ease, opacity 300ms ease;
  pointer-events: none;
}

/* Title centered */
.card-title {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  font-size: 1.25rem;
  font-weight: 700;
  text-align: center;
  transition: transform 250ms ease, font-size 250ms ease;
  z-index: 2;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.45);
}

/* Hover effects for the 3 cards */
.card:hover .card-overlay {
  background: rgba(0, 0, 0, 0.45);
  transition: background 220ms ease;
}
.card:hover {
  transform: translateY(-6px) scale(1.02);
  transition: transform 220ms ease;
}
.card:hover .card-title {
  transform: translate(-50%, -50%) scale(1.06);
}

/* CTA block */
.cta-block {
  display: flex;
  flex-direction: column;
  gap: 8px;
  justify-content: center;
  padding: 12px;
  opacity: 0;
  transform: translateY(10px);
}

.subtitle {
  color: #00224e;
  font-size: 1.1rem;
  font-weight: 600;
}

/* Contenedor botones */
.cta-buttons {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-left: 30px;
}

/* Botón base */
.btn-icon {
  width: 78px;
  height: 78px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
  transition: transform 150ms ease, box-shadow 150ms ease,
    background-color 150ms ease;
  font-size: 50px; /* tamaño del icono */
  text-decoration: none;
  background: transparent;
}

.btn-icon i {
  line-height: 1;
}

.icon-mail {
  width: 94px;   /* mismo “peso visual” que FA */
  height: 94px;
  display: block;
}

/* Colores */
.btn-wpp,
.btn-mail {
  color: #4e84a7;
}

/* Hover */
.btn-icon:hover {
  color: #00224e;
  transform: translateY(-3px);
}

/* Overlay */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

/* Caja */
.modal-content {
  background: #fff;
  width: 90%;
  max-width: 420px;
  padding: 24px;
  border-radius: 16px;
  position: relative;
  animation: modalZoom 0.35s ease;
}

@keyframes modalZoom {
  0% {
    transform: scale(0.7);
    opacity: 0;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

/* Cerrar */
.modal-close {
  position: absolute;
  right: 12px;
  top: 8px;
  font-size: 28px;
  cursor: pointer;
}

/* Form */
.modal-content form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.modal-content input,
.modal-content textarea {
  padding: 10px;
  border-radius: 8px;
  border: 1px solid #ccc;
}

.modal-submit {
  display: flex;
  padding: 10px;
  border: none;
  border-radius: 8px;
  background: #4e84a7;
  color: white;
  font-weight: bold;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.3s ease;
}


.modal-submit:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

/* small footer */
.site-footer {
  text-align: center;
  padding: 28px 0 80px 0;
  color: #6b6b6b;
  font-size: 0.9rem;
}

/* Animations initial state for cards & slogan */
.col .card {
  transform: translateY(-150px);
  opacity: 0;
}

.card-title {
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.7); /* más chico al iniciar */
  will-change: transform, opacity;
}

.cta-block {
  opacity: 0;
  transform: translateY(0); /* sin desplazamiento */
}

/* Utility spacing for first column to look like column height */
.col-1 {
  min-height: var(--card-height);
  padding: 6px;
}
.col-2,
.col-3 {
  padding: 6px;
}

/* accessibility focus state for cards */
.card:focus {
  outline: 3px solid rgba(191, 147, 13, 0.25);
  transform: translateY(-6px) scale(1.02);
}

.floating-wpp {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 42px;
  height: 42px;
  background-color: none;
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.3rem;
  z-index: 999;
  opacity: 0;
  pointer-events: none;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.25);
  transform: scale(0.85);
  text-decoration: none;
}

/* Ícono centrado perfecto */
.floating-wpp i {
  color: var(--text);
  text-decoration: none;
  line-height: 1;
}

/* Latido */
@keyframes pulse {
  0% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.6);
  }
  70% {
    transform: scale(1.08);
    box-shadow: 0 0 0 14px rgba(37, 211, 102, 0);
  }
  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(37, 211, 102, 0);
  }
}

.floating-wpp.is-visible {
  opacity: 1;
  pointer-events: auto;
  animation: pulse 2.2s infinite;
}

/******* RESPONSIVE *******/

/** TABLETS **/

@media (min-width: 768px) and (max-width: 1024px) {
  .site-header {
    display: flex;
    align-items: center;
    padding: 18px 24px;
  }

  .header-inner {
    display: flex;
    justify-content: center;
    flex: 1;
  }

  #header-logo {
    height: 75px;
  }

  .btn-conocenos {
    position: static;
    margin-left: auto; /* 🔑 ESTO ES LO QUE FALTABA */
    font-size: 0.85rem;
    padding: 6px 14px;
  }

  .slogan {
    font-size: 2.2rem;
    transform: none;
    text-align: left;
  }

  .card {
    height: 320px;
  }

  .col .card {
    transform: none;
  }

  /* =========================
     OTRAS SECCIONES
  ========================= */
  .marketing-wrapper {
    grid-template-columns: 1fr 1fr;
    gap: 20px;
  }

  .grid-procesos {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/** MOVIL GRANDE **/

@media (min-width: 481px) and (max-width: 767px) {
  .site-header {
    position: relative;
    padding: 14px 18px;
    min-height: 70px;
  }

  .header-inner {
    display: flex;
    align-items: center;
    justify-content: flex-start;
  }

  #header-logo {
    height: 64px;
  }

  .btn-conocenos {
    position: absolute;
    margin-top: 2rem;
    right: 18px;
    transform: translateY(-50%);
    font-size: 0.9rem;
    padding: 7px 16px;
  }
  /* ---------------- HERO ---------------- */
  .slogan {
    font-size: 2rem;
    text-align: center;
    transform: translateX(-15px);
  }

  .cta-block {
    text-align: center;
    align-items: center;
    margin-top: 12px;
  }

  .cta-block .subtitle {
    font-size: 1.6rem;
    text-align: center;
  }

  .cta-buttons {
    justify-content: center;
    margin-left: 0;
  }

  /* ---------------- GRID PRINCIPAL ---------------- */
  .row {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .col-2-3 {
    grid-column: auto;
  }

  /* ---------------- CARDS ---------------- */
  .card {
    height: 210px;
  }

  .col .card {
    transform: translateY(-60px);
  }

  .card-title {
    font-size: 1.05rem;
  }

  /* ---------------- ORDEN VISUAL ---------------- */
  .top-row .col-1 {
    order: 1;
  }

  .top-row .col-2-3 {
    order: 2;
  }

  .second-row .col-2 {
    order: 3;
  }

  .second-row .col-3 {
    order: 4;
  }

  .second-row .cta-block {
    order: 5;
  }

  /* ---------------- MARKETING ---------------- */
  .marketing-wrapper {
    grid-template-columns: 1fr;
    text-align: center;
  }

  /* ---------------- PROCESOS ---------------- */
  .grid-procesos {
    grid-template-columns: 1fr;
  }

  /* ---------------- FOOTER ---------------- */
  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
    text-align: center;
  }

  .footer-socials {
    justify-content: center;
  }
}

/** MOVIL CHICO **/

@media (max-width: 480px) {
  #splash-inner img {
    width: 20rem;
  }

  /* ---------------- HEADER ---------------- */
  #header-logo {
    height: 52px;
  }

  .header-inner {
    flex-direction: column;
    gap: 12px;
  }

  .btn-conocenos {
    position: static;
    transform: none;
    font-size: 0.85rem;
    margin: 1rem;
    padding: 6px 14px;
  }

  /* ---------------- HERO ---------------- */
  .slogan {
    font-size: 1.8rem;
    text-align: center;
    transform: translateX(-10px);
  }

  .cta-block {
    text-align: center;
    align-items: center;
    margin-top: 5px;
  }

  .cta-block .subtitle {
    font-size: 1.5rem;
    text-align: center;
  }

  .cta-buttons {
    justify-content: center;
    margin-left: 0;
  }

  /* ---------------- GRID PRINCIPAL ---------------- */
  .row {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .col-2-3 {
    grid-column: auto;
  }

  /* ---------------- CARDS ---------------- */
  .card {
    height: 180px;
  }

  .col .card {
    transform: translateY(-60px);
  }

  .card-title {
    font-size: 1rem;
  }

  .top-row .col-1 {
    order: 1; /* slogan */
  }

  .top-row .col-2-3 {
    order: 2; /* Desarrollo Web */
  }

  .second-row .col-2 {
    order: 3; /* Social Media */
  }

  .second-row .col-3 {
    order: 4; /* Publicidad Digital */
  }

  .second-row .cta-block {
    order: 5; /* CTA al final */
  }

  /* ---------------- RUBROS ---------------- */
  .rubros-title,
  .marketing-title {
    font-size: 1.8rem;
  }

  .rubro-card {
    min-width: 120px;
    font-size: 0.9rem;
    transform-style: flat;
    will-change: transform, opacity;
  }

  /* ---------------- MARKETING 360 ---------------- */
  .marketing-wrapper {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .marketing-content {
    text-align: center;
  }

  .marketing-img img {
    height: auto;
  }

  /* ---------------- PROCESOS ---------------- */
  .grid-procesos {
    grid-template-columns: 1fr;
  }

  /* ---------------- FOOTER ---------------- */
  .footer-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .footer-socials {
    justify-content: center;
  }

  /* ---------------- PERFORMANCE / TOUCH ---------------- */
  .card,
  .rubro-card {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.18);
  }
}

/** META VIEW **/

@media (max-width: 600px) and (hover: none) and (pointer: coarse) {
  /* Evitar problemas de viewport */
  html,
  body {
    height: auto;
    min-height: 100%;
    overscroll-behavior: none;
  }

  /* Splash / overlays centrados correctamente */
  #splash,
  .modal-overlay {
    position: fixed;
    inset: 0;
  }

  /* Evitar saltos al abrir teclado */
  .modal-content {
    max-height: 90vh;
    overflow-y: auto;
  }

  /* Cards: evitar zoom excesivo */
  .card {
    transform: none;
  }

  /* Botones touch */
  .btn-icon {
    min-width: 56px;
    min-height: 56px;
  }

  /* Desactivar efectos hover residuales */
  .card:hover,
  .rubro-card:hover,
  .btn-icon:hover {
    transform: none;
    box-shadow: none;
  }

  /* ScrollTrigger se ve mejor con menos sombras */
  .card,
  .rubro-card {
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.16);
  }
}
