/* === RESET & BASE === */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --blue-dark: #1a3a5c;
  --blue-primary: #2563eb;
  --blue-medium: #3b82f6;
  --blue-light: #93c5fd;
  --blue-pale: #dbeafe;
  --blue-bg: #eff6ff;
  --white: #ffffff;
  --gray-50: #f8fafc;
  --gray-100: #f1f5f9;
  --gray-200: #e2e8f0;
  --gray-600: #475569;
  --gray-700: #334155;
  --gray-800: #1e293b;
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.12);
  --radius: 12px;
  --radius-sm: 8px;
  --transition: 0.3s ease;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: 'Roboto', sans-serif;
  color: var(--gray-700);
  background-color: var(--white);
  line-height: 1.6;
  overflow-x: hidden;
}

h1,
h2,
h3,
h4 {
  font-family: 'Fredoka One', cursive;
  color: var(--blue-dark);
  line-height: 1.2;
}

a {
  text-decoration: none;
  color: inherit;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

ul {
  list-style: none;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* === HEADER / NAV === */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: transparent;
  transition: background var(--transition), box-shadow var(--transition);
}

.header.scrolled {
  background: var(--white);
  box-shadow: var(--shadow-sm);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 160px;
  transition: height var(--transition);
}

.header.scrolled .nav {
  height: 64px;
}

.nav__logo img {
  height: 150px;
  width: auto;
  transition: height var(--transition);
}

.header.scrolled .nav__logo img {
  height: 44px;
}

.nav__logo-mobile {
  display: none;
}

.nav__logo-desktop {
  display: block;
}

.nav__brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav__brand-text {
  display: none;
  font-family: 'Fredoka One', cursive;
  font-size: 1.2rem;
  color: var(--blue-dark);
  white-space: nowrap;
}

.nav__links {
  display: flex;
  gap: 32px;
  align-items: center;
}

.nav__links a {
  font-weight: 500;
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.9);
  position: relative;
  transition: color var(--transition);
}

.nav__links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--white);
  transition: width var(--transition);
}

.header.scrolled .nav__links a {
  color: var(--gray-700);
}

.header.scrolled .nav__links a::after {
  background: var(--blue-primary);
}

.nav__links a:hover,
.nav__links a.active {
  color: var(--white);
}

.header.scrolled .nav__links a:hover,
.header.scrolled .nav__links a.active {
  color: var(--blue-primary);
}

.nav__links a:hover::after,
.nav__links a.active::after {
  width: 100%;
}

.nav__toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 8px;
}

.nav__toggle span {
  width: 24px;
  height: 2px;
  background: var(--white);
  border-radius: 2px;
  transition: var(--transition);
}

.header.scrolled .nav__toggle span {
  background: var(--blue-dark);
}

/* === HERO === */
.hero {
  padding: 200px 0 80px;
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.85) 0%, rgba(30, 58, 92, 0.9) 100%), url('../img/hero-bg.jpg') center / cover no-repeat;
  text-align: center;
  position: relative;
}

.hero__content {
  max-width: 700px;
  margin: 0 auto;
  position: relative;
}

.hero__stamp {
  position: absolute;
  top: -100px;
  right: 0;
  width: 120px;
  height: 120px;
  animation: stampFloat 3s ease-in-out infinite;
}

@keyframes stampFloat {

  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-8px);
  }
}

.hero__stamp-inner {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: linear-gradient(135deg, #f59e0b, #d97706);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(245, 158, 11, 0.4);
  position: relative;
}

.hero__stamp-inner::before {
  content: '';
  position: absolute;
  inset: 6px;
  border-radius: 50%;
  border: 2px dashed rgba(255, 255, 255, 0.5);
}

.hero__stamp-text {
  font-family: 'Fredoka One', cursive;
  font-size: 1rem;
  color: #fff;
  line-height: 1.2;
  text-align: center;
}

.hero h1 {
  font-size: 2.8rem;
  margin-bottom: 20px;
  color: var(--white);
}

.hero h1 span {
  color: var(--blue-light);
}

.hero p {
  font-size: 1.15rem;
  color: rgba(255, 255, 255, 0.85);
  margin: 0 auto 32px;
  max-width: 560px;
}

.btn {
  display: inline-block;
  padding: 14px 32px;
  border-radius: 50px;
  font-weight: 600;
  font-size: 1rem;
  transition: all var(--transition);
  cursor: pointer;
  border: none;
}

.btn--primary {
  background: var(--blue-primary);
  color: var(--white);
  box-shadow: 0 4px 16px rgba(37, 99, 235, 0.3);
}

.btn--primary:hover {
  background: var(--blue-medium);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(37, 99, 235, 0.4);
}

.btn--outline {
  background: transparent;
  color: var(--blue-primary);
  border: 2px solid var(--blue-primary);
}

.btn--outline:hover {
  background: var(--blue-primary);
  color: var(--white);
}

.hero .btn--outline {
  color: var(--white);
  border-color: var(--white);
}

.hero .btn--outline:hover {
  background: var(--white);
  color: var(--blue-primary);
}

/* === SERVICIOS === */
.servicios {
  padding: 80px 0;
  background: var(--white);
}

.section-title {
  text-align: center;
  margin-bottom: 56px;
}

.section-title h2 {
  font-size: 2.2rem;
  margin-bottom: 12px;
}

.section-title p {
  font-size: 1.05rem;
  color: var(--gray-600);
  max-width: 600px;
  margin: 0 auto;
}

.servicios__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 24px;
}

.servicio-card {
  background: var(--gray-50);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  padding: 32px 24px;
  text-align: center;
  transition: all var(--transition);
}

.servicio-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--blue-light);
}

.servicio-card__icon {
  width: 56px;
  height: 56px;
  background: var(--blue-pale);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
  font-size: 1.5rem;
}

.servicio-card h3 {
  font-size: 1.15rem;
  margin-bottom: 10px;
  font-family: 'Roboto', sans-serif;
  font-weight: 700;
  color: var(--blue-dark);
}

.servicio-card p {
  font-size: 0.9rem;
  color: var(--gray-600);
}

/* === NIVELES === */
.niveles {
  padding: 80px 0;
  background: var(--blue-bg);
}

.niveles__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 24px;
}

.nivel-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 32px 24px;
  text-align: center;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
}

.nivel-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.nivel-card__icon {
  font-size: 2.5rem;
  margin-bottom: 16px;
}

.nivel-card h3 {
  font-size: 1.2rem;
  margin-bottom: 10px;
  font-family: 'Roboto', sans-serif;
  font-weight: 700;
  color: var(--blue-dark);
}

.nivel-card p {
  font-size: 0.9rem;
  color: var(--gray-600);
  line-height: 1.5;
}

/* === POR QUE NOSOTROS === */
.porque {
  padding: 80px 0;
  background: var(--white);
}

.porque__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 32px;
}

.porque-item {
  text-align: center;
  padding: 24px;
}

.porque-item__icon {
  width: 64px;
  height: 64px;
  background: linear-gradient(135deg, var(--blue-primary), var(--blue-medium));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
  font-size: 1.6rem;
  color: var(--white);
}

.porque-item h3 {
  font-size: 1.1rem;
  margin-bottom: 8px;
  font-family: 'Roboto', sans-serif;
  font-weight: 700;
  color: var(--blue-dark);
}

.porque-item p {
  font-size: 0.9rem;
  color: var(--gray-600);
}

/* === SOBRE NOSOTROS === */
.sobre {
  padding: 80px 0;
  background: var(--blue-bg);
}

.sobre__content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}

.sobre__text h2 {
  font-size: 2rem;
  margin-bottom: 20px;
}

.sobre__text p {
  margin-bottom: 16px;
  color: var(--gray-600);
  font-size: 0.95rem;
}

.sobre__image {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.sobre__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* === TESTIMONIOS === */
.testimonios {
  padding: 80px 0;
  background: var(--white);
}

.testimonios__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.testimonio-card {
  background: var(--gray-50);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  padding: 28px;
  position: relative;
}

.testimonio-card::before {
  content: '\201C';
  font-size: 4rem;
  color: var(--blue-light);
  position: absolute;
  top: 8px;
  left: 20px;
  line-height: 1;
  font-family: Georgia, serif;
}

.testimonio-card p {
  font-style: italic;
  color: var(--gray-600);
  margin-bottom: 16px;
  padding-top: 24px;
  font-size: 0.95rem;
}

.testimonio-card__author {
  font-weight: 700;
  color: var(--blue-dark);
  font-size: 0.9rem;
}

/* === RESULTADOS === */
.resultados {
  padding: 80px 0;
  background: linear-gradient(135deg, var(--blue-dark) 0%, var(--blue-primary) 100%);
  color: var(--white);
}

.resultados .section-title h2 {
  color: var(--white);
}

.resultados .section-title p {
  color: var(--blue-light);
}

.resultados__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 32px;
  text-align: center;
}

.resultado-item h3 {
  font-size: 3rem;
  color: var(--white);
  margin-bottom: 8px;
}

.resultado-item p {
  font-size: 0.95rem;
  color: var(--blue-light);
}

/* === FAQ === */
.faq {
  padding: 80px 0;
  background: var(--white);
}

.faq__list {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.faq__item {
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-sm);
  overflow: hidden;
  transition: border-color var(--transition);
}

.faq__item.active {
  border-color: var(--blue-light);
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.08);
}

.faq__question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  background: var(--gray-50);
  border: none;
  cursor: pointer;
  font-family: 'Roboto', sans-serif;
  font-size: 1rem;
  font-weight: 600;
  color: var(--gray-800);
  text-align: left;
  transition: background var(--transition);
}

.faq__question:hover {
  background: var(--blue-pale);
}

.faq__item.active .faq__question {
  background: var(--blue-pale);
  color: var(--blue-primary);
}

.faq__icon {
  flex-shrink: 0;
  transition: transform var(--transition);
  color: var(--gray-600);
}

.faq__item.active .faq__icon {
  transform: rotate(180deg);
  color: var(--blue-primary);
}

.faq__answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, padding 0.4s ease;
  padding: 0 24px;
}

.faq__item.active .faq__answer {
  max-height: 300px;
  padding: 16px 24px 20px;
}

.faq__answer p {
  font-size: 0.95rem;
  color: var(--gray-600);
  line-height: 1.7;
}

/* === CONTACTO === */
.contacto {
  padding: 80px 0;
  background: var(--gray-50);
}

.contacto__content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
}

.contacto__info {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.contacto__info-item {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}

.contacto__info-item__icon {
  width: 44px;
  height: 44px;
  background: var(--blue-pale);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  flex-shrink: 0;
}

.contacto__info-item h4 {
  font-size: 0.95rem;
  margin-bottom: 4px;
  font-family: 'Roboto', sans-serif;
  font-weight: 700;
}

.contacto__info-item p {
  font-size: 0.9rem;
  color: var(--gray-600);
}

.contacto__form {
  background: var(--white);
  border-radius: var(--radius);
  padding: 32px;
  box-shadow: var(--shadow-sm);
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-weight: 500;
  font-size: 0.9rem;
  margin-bottom: 6px;
  color: var(--gray-700);
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-sm);
  font-family: 'Roboto', sans-serif;
  font-size: 0.95rem;
  transition: border-color var(--transition);
  outline: none;
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--blue-primary);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.form-group textarea {
  resize: vertical;
  min-height: 120px;
}

.contacto__form .btn {
  width: 100%;
}

/* === MAP === */
.map {
  width: 100%;
  height: 300px;
  border: none;
  display: block;
}

/* === FOOTER === */
.footer {
  background: var(--blue-dark);
  color: var(--blue-light);
  padding: 48px 0 24px;
}

.footer__content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 32px;
  margin-bottom: 32px;
}

.footer__col h4 {
  color: var(--white);
  font-size: 1rem;
  margin-bottom: 16px;
  font-family: 'Roboto', sans-serif;
  font-weight: 700;
}

.footer__col p,
.footer__col a {
  font-size: 0.9rem;
  color: var(--blue-light);
  line-height: 1.8;
}

.footer__col a:hover {
  color: var(--white);
}

.footer__logo img {
  height: 40px;
  margin-bottom: 12px;
}

.footer__bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 24px;
  text-align: center;
  font-size: 0.85rem;
  color: var(--blue-light);
}

/* === WHATSAPP BUTTON === */
.whatsapp-btn {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 56px;
  height: 56px;
  background: #25d366;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(37, 211, 102, 0.4);
  z-index: 999;
  transition: all var(--transition);
}

.whatsapp-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.5);
}

.whatsapp-btn svg {
  width: 28px;
  height: 28px;
  fill: var(--white);
}

/* === RESPONSIVE === */
@media (max-width: 768px) {
  .header {
    background: var(--white);
    box-shadow: var(--shadow-sm);
  }

  .nav__logo-desktop {
    display: none;
  }

  .nav__logo-mobile {
    display: block;
  }

  .nav__brand-text {
    display: block;
  }

  .nav {
    height: 80px;
  }

  .nav__logo img {
    height: 60px;
  }

  .nav__toggle span {
    background: var(--blue-dark);
  }

  .nav__links {
    position: fixed;
    top: 80px;
    left: 0;
    right: 0;
    background: var(--white);
    flex-direction: column;
    padding: 24px;
    gap: 20px;
    box-shadow: var(--shadow-md);
    transform: translateY(-150%);
    visibility: hidden;
    transition: transform var(--transition), visibility var(--transition);
  }

  .nav__links a {
    color: var(--gray-700);
  }

  .nav__links a::after {
    background: var(--blue-primary);
  }

  .nav__links a:hover,
  .nav__links a.active {
    color: var(--blue-primary);
  }

  .header.scrolled .nav__links a:hover,
  .header.scrolled .nav__links a.active {
    color: var(--blue-primary);
  }

  .nav__links.active {
    visibility: visible;
    transform: translateY(0);
  }

  .nav__toggle {
    display: flex;
  }

  .nav__toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }

  .nav__toggle.active span:nth-child(2) {
    opacity: 0;
  }

  .nav__toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
  }

  .hero {
    padding: 120px 0 60px;
  }

  .hero h1 {
    font-size: 2rem;
  }

  .hero__stamp {
    width: 96px;
    height: 96px;
    top: 10px;
    right: 10px;
  }

  .hero__stamp-text {
    font-size: 0.85rem;
  }

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

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

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

@media (max-width: 480px) {
  .hero h1 {
    font-size: 1.7rem;
  }

  .section-title h2 {
    font-size: 1.7rem;
  }

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

  .servicios__grid,
  .niveles__grid {
    grid-template-columns: 1fr;
  }
}