:root {
  --primary: #12377a;
  --primary-dark: #0c2a5e;
  --primary-light: #1d4ed8;
  --accent: #f5b301;
  --accent-dark: #d99f00;
  --wa: #25d366;
  --ink: #1e293b;
  --muted: #64748b;
  --bg: #ffffff;
  --bg-alt: #f4f7fb;
  --line: #e2e8f0;
  --radius: 16px;
  --shadow: 0 10px 30px rgba(18, 55, 122, 0.10);
  --shadow-lg: 0 20px 50px rgba(18, 55, 122, 0.18);
  --font-head: "Poppins", sans-serif;
  --font-body: "Inter", sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { text-decoration: none; color: inherit; }
button { font-family: inherit; cursor: pointer; }
ul { list-style: none; }

.container {
  width: min(1160px, 92%);
  margin-inline: auto;
}

/* ===== TOP BAR ===== */
.topbar {
  background: var(--primary-dark);
  color: #fff;
  font-size: 0.82rem;
  padding: 0.45rem 0;
}
.topbar__inner {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: wrap;
}
.topbar__item {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  opacity: 0.92;
  transition: opacity 0.2s;
}
.topbar__item:hover { opacity: 1; }
.topbar__item svg { flex-shrink: 0; }

/* ===== NAVBAR ===== */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
  transition: box-shadow 0.3s;
}
.nav.is-scrolled { box-shadow: 0 4px 20px rgba(18, 55, 122, 0.10); }
.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  height: 70px;
}
.nav__brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-head);
  font-weight: 700;
  color: var(--primary);
  white-space: nowrap;
  min-width: 0;
}
.nav__logo {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  object-fit: cover;
  flex-shrink: 0;
}
.nav__name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.nav__links {
  display: flex;
  gap: 1.6rem;
  font-weight: 500;
  font-size: 0.95rem;
}
.nav__links a {
  color: var(--ink);
  position: relative;
  padding: 0.25rem 0;
}
.nav__links a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: width 0.25s;
}
.nav__links a:hover::after { width: 100%; }
.nav__actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.lang {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  background: var(--bg-alt);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.25rem 0.6rem;
}
.lang__btn {
  border: none;
  background: transparent;
  font-weight: 700;
  font-size: 0.8rem;
  color: var(--muted);
  padding: 0.15rem 0.35rem;
  border-radius: 999px;
  transition: all 0.2s;
}
.lang__btn.is-active { color: #fff; background: var(--primary); }
.lang__divider { color: var(--line); }

.nav__burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  padding: 8px;
}
.nav__burger span {
  width: 24px;
  height: 2.5px;
  background: var(--primary);
  border-radius: 2px;
  transition: transform 0.3s, opacity 0.3s;
}
.nav__burger.is-open span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.nav__burger.is-open span:nth-child(2) { opacity: 0; }
.nav__burger.is-open span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.7rem 1.4rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  border: none;
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); }
.btn--accent { background: var(--accent); color: var(--primary-dark); }
.btn--accent:hover { background: var(--accent-dark); box-shadow: 0 10px 25px rgba(245, 179, 1, 0.4); }
.btn--primary { background: var(--primary); color: #fff; }
.btn--primary:hover { background: var(--primary-light); box-shadow: var(--shadow); }
.btn--ghost {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  border: 1.5px solid rgba(255, 255, 255, 0.6);
}
.btn--ghost:hover { background: rgba(255, 255, 255, 0.22); }
.btn--wa { background: var(--wa); color: #fff; }
.btn--wa:hover { background: #1eb958; box-shadow: 0 10px 25px rgba(37, 211, 102, 0.4); }
.btn--lg { padding: 0.9rem 1.9rem; font-size: 1.02rem; }
.btn--block { width: 100%; }

/* ===== HERO ===== */
.hero {
  position: relative;
  min-height: 88vh;
  display: flex;
  align-items: center;
  color: #fff;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("../images/hero.png") center / cover no-repeat;
}
.hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, rgba(12, 42, 94, 0.95) 0%, rgba(18, 55, 122, 0.82) 45%, rgba(18, 55, 122, 0.35) 100%);
}
.hero__content {
  position: relative;
  z-index: 2;
  padding: 6rem 0;
  max-width: 720px;
  margin-left: max(4%, calc((100vw - 1160px) / 2));
}
.hero__badge {
  display: inline-block;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 999px;
  padding: 0.35rem 1rem;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 1.3rem;
}
.hero__title {
  font-family: var(--font-head);
  font-size: clamp(2rem, 5vw, 3.4rem);
  line-height: 1.15;
  font-weight: 800;
  margin-bottom: 1.1rem;
}
.hero__title-accent { color: var(--accent); }
.hero__sub {
  font-size: 1.08rem;
  opacity: 0.92;
  max-width: 560px;
  margin-bottom: 2rem;
}
.hero__actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 3rem;
}
.hero__stats {
  display: flex;
  gap: 2.5rem;
  flex-wrap: wrap;
}
.hero__stat strong {
  display: block;
  font-family: var(--font-head);
  font-size: 1.9rem;
  color: var(--accent);
}
.hero__stat span { font-size: 0.9rem; opacity: 0.9; }

/* ===== SECTION ===== */
.section { padding: 5.5rem 0; }
.section--alt { background: var(--bg-alt); }
.section__head {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 3rem;
}
.section__tag {
  display: inline-block;
  color: var(--primary-light);
  font-weight: 700;
  font-size: 0.82rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 0.7rem;
}
.section__title {
  font-family: var(--font-head);
  font-size: clamp(1.6rem, 3.5vw, 2.3rem);
  color: var(--primary);
  line-height: 1.2;
  margin-bottom: 0.8rem;
}
.section__sub { color: var(--muted); }

/* ===== CARDS ===== */
.cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}
.cards--cols3 { grid-template-columns: repeat(3, 1fr); }
.card {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.8rem 1.5rem;
  box-shadow: var(--shadow);
  transition: transform 0.25s, box-shadow 0.25s;
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.card__icon {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 14px;
  background: rgba(29, 78, 216, 0.1);
  color: var(--primary);
  margin-bottom: 1.1rem;
}
.card__title {
  font-family: var(--font-head);
  color: var(--primary);
  font-size: 1.12rem;
  margin-bottom: 0.5rem;
}
.card__text { color: var(--muted); font-size: 0.94rem; }

.card--testimonial { display: flex; flex-direction: column; }
.stars { display: flex; gap: 0.15rem; color: var(--accent); margin-bottom: 0.9rem; }
.card__who { margin-top: auto; padding-top: 1.2rem; }
.card__who strong { display: block; color: var(--primary); }
.card__who span { font-size: 0.85rem; color: var(--muted); }

/* ===== FORMULARIO DE RESEÑAS ===== */
.review__wrap {
  max-width: 760px;
  margin: 3.5rem auto 0;
}
.review__wrap .section__head { margin-bottom: 1.6rem; }
.rating {
  display: flex;
  gap: 0.35rem;
}
.rating__star {
  border: none;
  background: transparent;
  font-size: 1.9rem;
  line-height: 1;
  color: var(--line);
  transition: transform 0.15s, color 0.15s;
}
.rating__star:hover,
.rating__star.is-hover {
  color: var(--accent);
  transform: scale(1.12);
}
.rating__star.is-active {
  color: var(--accent);
}
.form__success {
  margin-top: 1rem;
  padding: 0.9rem 1.1rem;
  border-radius: 12px;
  background: rgba(37, 211, 102, 0.12);
  border: 1px solid rgba(37, 211, 102, 0.4);
  color: #15803d;
  font-weight: 600;
  text-align: center;
}

/* ===== SPLIT / ABOUT ===== */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3.5rem;
  align-items: center;
}
.split__media {
  position: relative;
  border-radius: var(--radius);
  min-height: 420px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
}
.split__media-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.split__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(12, 42, 94, 0.55), transparent 40%);
}
.media-ph__badge {
  position: absolute;
  left: 1.5rem;
  bottom: 1.5rem;
  z-index: 2;
  background: rgba(255, 255, 255, 0.95);
  color: var(--primary);
  border-radius: 14px;
  padding: 0.8rem 1.2rem;
  box-shadow: var(--shadow);
}
.media-ph__badge strong { display: block; }
.media-ph__badge span { font-size: 0.8rem; color: var(--muted); }
.checklist {
  display: grid;
  gap: 0.85rem;
  margin: 1.6rem 0 2rem;
}
.checklist li {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  color: var(--ink);
  font-weight: 500;
}
.checklist li::before {
  content: "";
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  margin-top: 2px;
  border-radius: 50%;
  background: rgba(37, 211, 102, 0.15);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2316a34a' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 12px;
}

/* ===== GALERÍA ===== */
.gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
.gallery__item { position: relative; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.gallery__img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  display: block;
  transition: transform 0.4s;
}
.gallery__item:hover .gallery__img { transform: scale(1.05); }
.gallery__cap {
  position: absolute;
  inset: auto 0 0 0;
  padding: 2.2rem 1rem 0.9rem;
  background: linear-gradient(transparent, rgba(12, 42, 94, 0.85));
  color: #fff;
  font-weight: 600;
  font-size: 0.92rem;
}

/* ===== CONTACTO ===== */
.contact {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 2.5rem;
  align-items: start;
}
.contact__form {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: var(--shadow);
}
.form__row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.2rem;
}
.form__group { margin-bottom: 1.2rem; }
.form__group label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--primary);
  margin-bottom: 0.4rem;
}
.form__group input,
.form__group textarea {
  width: 100%;
  padding: 0.75rem 0.95rem;
  border: 1.5px solid var(--line);
  border-radius: 12px;
  font-family: inherit;
  font-size: 0.95rem;
  color: var(--ink);
  background: var(--bg-alt);
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}
.form__group input:focus,
.form__group textarea:focus {
  outline: none;
  border-color: var(--primary-light);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(29, 78, 216, 0.12);
}
.form__group textarea { resize: vertical; }
.form__hint { margin-top: 1rem; font-size: 0.85rem; color: var(--muted); text-align: center; }

.contact__info { display: grid; gap: 1rem; }
.info-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.1rem 1.3rem;
  box-shadow: var(--shadow);
}
.info-card__icon {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  flex-shrink: 0;
  border-radius: 12px;
  background: rgba(29, 78, 216, 0.1);
  color: var(--primary);
}
.info-card h4 { font-family: var(--font-head); font-size: 0.95rem; color: var(--primary); }
.info-card a { color: var(--ink); font-weight: 500; }
.info-card a:hover { color: var(--primary-light); }
.info-card span { color: var(--ink); }
.contact__actions { display: grid; gap: 0.85rem; margin-top: 0.4rem; }

/* ===== FOOTER ===== */
.footer { background: var(--primary-dark); color: rgba(255, 255, 255, 0.85); }
.footer__inner {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr;
  gap: 2.5rem;
  padding: 3.5rem 0 2.5rem;
}
.footer__brand { display: grid; gap: 0.6rem; justify-items: start; }
.footer__brand strong { font-family: var(--font-head); color: #fff; font-size: 1.1rem; }
.footer__brand p { font-size: 0.9rem; max-width: 320px; }
.footer__col { display: grid; gap: 0.6rem; align-content: start; }
.footer__col h5 {
  font-family: var(--font-head);
  color: var(--accent);
  text-transform: uppercase;
  font-size: 0.82rem;
  letter-spacing: 0.1em;
  margin-bottom: 0.4rem;
}
.footer__col a { font-size: 0.92rem; }
.footer__col a:hover { color: #fff; }
.footer__col span { font-size: 0.92rem; }
.footer__bottom { border-top: 1px solid rgba(255, 255, 255, 0.12); padding: 1.2rem 0; }
.footer__bottom .container {
  display: flex;
  justify-content: space-between;
  gap: 0.8rem;
  flex-wrap: wrap;
  font-size: 0.85rem;
}

/* ===== FABs ===== */
.fab {
  position: fixed;
  right: 1.3rem;
  z-index: 90;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  border: none;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.25);
  transition: transform 0.2s, opacity 0.3s, visibility 0.3s;
}
.fab:hover { transform: scale(1.08); }
.fab--wa { bottom: 1.3rem; background: var(--wa); color: #fff; animation: pulse 2.4s infinite; }
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.5); }
  70% { box-shadow: 0 0 0 16px rgba(37, 211, 102, 0); }
  100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
}
.fab--top {
  bottom: 5.3rem;
  background: var(--primary);
  color: #fff;
  opacity: 0;
  visibility: hidden;
}
.fab--top.is-visible { opacity: 1; visibility: visible; }

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
  .cards { grid-template-columns: repeat(2, 1fr); }
  .split { grid-template-columns: 1fr; }
  .split__media { min-height: 320px; }
}

@media (max-width: 1024px) {
.nav__links {
    position: fixed;
    top: 70px;
    left: 0;
    right: 0;
    flex-direction: column;
    background: #fff;
    border-bottom: 1px solid var(--line);
    padding: 1.2rem 6%;
    gap: 1rem;
    box-shadow: var(--shadow);
    transform: translateY(-140%);
    transition: transform 0.3s;
  }
  .nav__links.is-open { transform: translateY(0); }
  .nav__burger { display: flex; }
  .nav__cta { display: none; }
  .topbar__item--hide-sm { display: none; }
}

@media (max-width: 640px) {
  .cards, .cards--cols3, .gallery { grid-template-columns: 1fr; }
  .form__row { grid-template-columns: 1fr; }
  .contact { grid-template-columns: 1fr; }
  .hero { min-height: 92vh; }
  .hero__content { padding: 4.5rem 0; }
  .hero__stats { gap: 1.4rem; }
  .footer__inner { grid-template-columns: 1fr; }
  .footer__bottom .container { flex-direction: column; align-items: center; text-align: center; }
}

@media (max-width: 480px) {
  .container { width: min(1160px, 95%); }
  .nav__inner { gap: 0.5rem; }
  .nav__brand { font-size: 0.9rem; gap: 0.4rem; }
  .nav__logo { width: 36px; height: 36px; }
  .nav__actions { gap: 0.5rem; }
  .topbar__inner { gap: 0.9rem; }
}
