#hero {
  position: relative;
  /* isolation: isolate crea un nuevo contexto de apilamiento para que los z-index internos no choquen con el navbar */
  isolation: isolate;
}

#hero .hero-bg {
  z-index: 0;
}

#hero .hero-bg__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 45%;
  /* scale(1.03): margen para que la animación pk-hero-float no deje bordes blancos en los extremos */
  transform: scale(1.03);
  filter: saturate(1.05) contrast(1.05);
}

#hero .hero-bg__overlay {
  background:
    linear-gradient(180deg, rgba(11, 18, 32, 0.55) 0%, rgba(11, 18, 32, 0.78) 60%, rgba(11, 18, 32, 0.9) 100%),
    radial-gradient(900px 520px at 20% 25%, rgba(99, 102, 241, 0.22), transparent 60%),
    radial-gradient(900px 520px at 80% 30%, rgba(16, 185, 129, 0.16), transparent 62%);
}

#hero .hero-content {
  z-index: 2;
  min-height: 100vh;
  padding-top: calc(var(--nav-height) + clamp(1.25rem, 3vw, 2.75rem));
  padding-bottom: clamp(5rem, 10vh, 8rem);
}

#hero .hero-copy {
  max-width: 62rem;
}

/* en oscuro el texto flotaba sobre el overlay sin panel; ahora añadimos un velo
   muy sutil con el color del picker "Hero panel" para que el admin vea el cambio
   sin oscurecer demasiado el fondo. */
:root:not([data-theme="light"]) #hero .hero-copy {
  background: color-mix(in srgb, var(--hero-panel-bg) 18%, transparent);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: calc(var(--radius-lg) + 12px);
  padding: clamp(1.25rem, 2.6vw, 2rem);
  backdrop-filter: blur(8px) saturate(1.05);
  -webkit-backdrop-filter: blur(8px) saturate(1.05);
}

#hero .hero-eyebrow {
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: 0.78rem;
}

#hero .hero-title {
  letter-spacing: -0.04em;
  line-height: 0.98;
  text-wrap: balance;
  text-shadow: 0 18px 60px rgba(0, 0, 0, 0.65);
}

#hero .hero-lead {
  max-width: 48rem;
  margin-left: auto;
  margin-right: auto;
  text-wrap: pretty;
}

#hero .hero-cta-primary {
  border: 0;
  background-image: linear-gradient(135deg, var(--accent) 0%, var(--accent-hover) 55%, #312e81 100%);
  box-shadow: 0 18px 46px rgba(79, 70, 229, 0.35), 0 0 0 1px rgba(255, 255, 255, 0.08) inset;
  font-weight: 800;
  letter-spacing: 0.01em;
}

#hero .hero-cta-primary:hover {
  transform: translateY(-2px);
  filter: brightness(1.05);
  box-shadow: 0 24px 60px rgba(79, 70, 229, 0.45), 0 0 0 1px rgba(255, 255, 255, 0.12) inset;
}

#hero .hero-cta-secondary {
  border-color: rgba(255, 255, 255, 0.65);
  color: rgba(255, 255, 255, 0.92);
  background: rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  font-weight: 800;
}

#hero .hero-cta-secondary:hover {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(255, 255, 255, 0.85);
  color: #fff;
}

#hero .hero-scroll {
  z-index: 3;
  color: rgba(255, 255, 255, 0.92);
  text-decoration: none;
  animation: hero-bounce 1.35s ease-in-out infinite;
}

#hero .hero-scroll__icon {
  width: 46px;
  height: 46px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: 0 14px 44px rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

#hero .hero-scroll:hover {
  opacity: 1;
  transform: translate(-50%, -6px);
}

/* 45% baja, 70% rebota a la mitad: simula un bote físico amortiguado */
@keyframes hero-bounce {
  0%, 100% { transform: translate(-50%, 0); }
  45%      { transform: translate(-50%, -10px); }
  70%      { transform: translate(-50%, -5px); }
}

#hero .animate__animated {
  --animate-duration: 900ms;
  --animate-timing-function: var(--ease-premium, ease);
}

@media (max-width: 576px) {
  #hero .hero-title {
    line-height: 1.02;
    letter-spacing: -0.03em;
  }

  #hero .hero-content {
    padding-bottom: 6.5rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  #hero .hero-scroll {
    animation: none !important;
  }

  #hero .hero-cta-primary:hover,
  #hero .hero-cta-secondary:hover {
    transform: none;
  }
}

[data-theme="light"] #hero .hero-bg__img {
  filter: saturate(1.02) contrast(1.03);
}

[data-theme="light"] #hero .hero-bg__overlay {
  background:
    linear-gradient(180deg, rgba(248, 250, 252, 0.55) 0%, rgba(248, 250, 252, 0.25) 35%, rgba(11, 18, 32, 0.75) 100%),
    radial-gradient(900px 520px at 20% 25%, rgba(79, 70, 229, 0.18), transparent 60%),
    radial-gradient(900px 520px at 80% 30%, rgba(5, 150, 105, 0.12), transparent 62%);
}

[data-theme="light"] #hero .hero-copy {
  /* panel frosted del hero — el color base lo elige el admin desde el picker "Hero panel" */
  background: color-mix(in srgb, var(--hero-panel-bg) 78%, transparent);
  border: 1px solid rgba(15, 23, 42, 0.12);
  border-radius: calc(var(--radius-lg) + 12px);
  box-shadow: 0 18px 54px rgba(15, 23, 42, 0.12);
  padding: clamp(1.25rem, 2.6vw, 2rem);
  backdrop-filter: blur(10px) saturate(1.05);
  -webkit-backdrop-filter: blur(10px) saturate(1.05);
}

[data-theme="light"] #hero .hero-eyebrow {
  color: rgba(15, 23, 42, 0.6) !important;
}

[data-theme="light"] #hero .hero-title {
  color: #0f172a !important;
  text-shadow: 0 18px 50px rgba(15, 23, 42, 0.12);
}

[data-theme="light"] #hero .hero-lead {
  color: rgba(15, 23, 42, 0.72) !important;
}

[data-theme="light"] #hero .hero-cta-secondary {
  background: rgba(255, 255, 255, 0.75);
  border-color: rgba(15, 23, 42, 0.18);
  color: rgba(15, 23, 42, 0.88);
}

[data-theme="light"] #hero .hero-scroll__icon {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.3);
}

.mapa {
  background: var(--bg);
  color: var(--text);
}

.mapa .container {
  padding-left: 1rem;
  padding-right: 1rem;
}

.mapa h2 {
  margin-bottom: 0.25rem;
}

.mapa p {
  color: var(--muted);
}

.mapa .ratio {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  background: var(--surface);
}

.mapa .row {
  border-radius: var(--radius-lg);
  border: 1px solid var(--glass-border);
  background: var(--glass-bg);
  backdrop-filter: blur(12px) saturate(1.1);
  -webkit-backdrop-filter: blur(12px) saturate(1.1);
  box-shadow: var(--shadow-soft);
  padding: clamp(1.5rem, 3vw, 2.25rem);
}

.mapa .row + .row {
  margin-top: 1.25rem;
}

.map {
  width: 100%;
  height: 300px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  overflow: hidden;
  background: var(--surface);
}

.location-card {
  border-radius: var(--radius-lg);
  border: 1px solid var(--glass-border);
  background: var(--card-bg);
  backdrop-filter: blur(14px) saturate(1.12);
  -webkit-backdrop-filter: blur(14px) saturate(1.12);
  box-shadow: var(--shadow-soft);
  padding: clamp(1.35rem, 2.5vw, 1.75rem);
}

.location-card .btn {
  white-space: normal;
}

.location-card h2 {
  margin-bottom: 0.5rem;
}

.location-card p {
  margin-bottom: 0.4rem;
  color: var(--muted);
}

.location-card__grid {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 1.25rem;
  align-items: start;
}

.location-card__side {
  min-width: 190px;
  padding-left: 1.25rem;
  border-left: 1px solid var(--border);
}

.location-meta__label {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin-bottom: 0.35rem;
}

.location-meta__value {
  color: var(--text);
  text-decoration: none;
  display: block;
}

a.location-meta__value:hover {
  color: var(--accent);
}

@media (max-width: 768px) {
  .map {
    height: 260px;
  }

  .location-card {
    padding: 1rem 1rem;
  }

  .location-card h2 {
    font-size: 1.35rem;
  }

  .location-card .btn {
    width: 100%;
  }

  .location-card__grid {
    grid-template-columns: 1fr;
  }

  .location-card__side {
    padding-left: 0;
    border-left: 0;
    border-top: 1px solid var(--border);
    padding-top: 1rem;
    min-width: 0;
  }
}

@media (max-width: 576px) {
  .map {
    height: 300px;
  }
}

[data-theme="light"] .mapa .row,
[data-theme="light"] .location-card {
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(12px) saturate(1.05);
  -webkit-backdrop-filter: blur(12px) saturate(1.05);
  border-color: rgba(15, 23, 42, 0.1) !important;
  box-shadow: 0 8px 28px rgba(15, 23, 42, 0.06), 0 0 0 1px rgba(99, 102, 241, 0.05);
}

[data-theme="light"] .location-card {
  background: var(--card-bg) !important;
  border-color: rgba(79, 70, 229, 0.12) !important;
  box-shadow:
    0 8px 32px rgba(15, 23, 42, 0.07),
    0 0 0 1px rgba(79, 70, 229, 0.08) !important;
}

.class-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  /* Truco para fijar aspect ratio 3:2 sin aspect-ratio (soporte legacy) */
  height: 0;
  padding-bottom: 66.666%;
}

.class-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.class-card .overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.22);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  text-align: center;
  padding: 1rem;
  transition: background 0.28s ease;
}

.class-card .overlay h3 {
  margin: 0;
  font-weight: 600;
  font-size: 1.15rem;
}

.class-card .overlay p {
  margin: 0.35rem 0 0;
  color: rgba(255, 255, 255, 0.92);
  font-size: 0.95rem;
}

.class-card .overlay > div {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition:
    transform 0.32s cubic-bezier(0.2, 0.9, 0.2, 1),
    color 0.22s ease;
}

.class-card:hover .overlay {
  background: rgba(0, 0, 0, 0.48);
}

.class-card:hover .overlay > div {
  transform: translateY(-8px) scale(1.03);
  color: var(--accent);
}

.class-card--ninos {
  border: 6px solid #f472b6;
  box-shadow: 0 0 20px rgba(244, 114, 182, 0.35);
}

.class-card--ninos:hover .overlay {
  background: rgba(244, 114, 182, 0.25);
}

.class-card--ninos:hover .overlay > div {
  color: #f9a8d4;
}

.class-card--adolescentes {
  border: 6px solid #4ade80;
  box-shadow: 0 0 20px rgba(74, 222, 128, 0.35);
}

.class-card--adolescentes:hover .overlay {
  background: rgba(74, 222, 128, 0.2);
}

.class-card--adolescentes:hover .overlay > div {
  color: #86efac;
}

.class-card--adultos {
  border: 6px solid #60a5fa;
  box-shadow: 0 0 20px rgba(96, 165, 250, 0.35);
}

.class-card--adultos:hover .overlay {
  background: rgba(96, 165, 250, 0.2);
}

.class-card--adultos:hover .overlay > div {
  color: #93c5fd;
}

.metodologia-item {
  border-radius: var(--radius);
  background: var(--card-bg);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.metodologia-item:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.2);
}

.metodologia-icon {
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.metodologia-item:hover .metodologia-icon {
  transform: scale(1.3) rotate(-8deg);
}

.curso-card {
  background: var(--card-bg);
  border-radius: var(--radius);
  padding: 2rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.curso-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.4);
}

.curso-card--ninos        { border-top: 3px solid #f472b6; }
.curso-card--adolescentes { border-top: 3px solid #4ade80; }
.curso-card--adultos      { border-top: 3px solid #60a5fa; }

.curso-card__header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}

.curso-card__emoji  { font-size: 2.5rem; line-height: 1; }

.curso-card__titulo {
  font-size: 1.2rem;
  font-weight: 700;
  margin: 0;
}

.curso-card__edad {
  font-size: 0.9rem;
  opacity: 0.65;
}

.curso-card__badge {
  display: inline-block;
  font-size: 0.85rem;
  padding: 0.25rem 0.75rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
}

.cursos-tagline {
  font-size: 1.3rem;
  opacity: 0.9;
}

[data-theme="light"] .metodologia-item {
  background: var(--card-bg);
}

[data-theme="light"] .curso-card {
  background: var(--card-bg);
  border-color: rgba(15, 23, 42, 0.1) !important;
  box-shadow: 0 8px 28px rgba(15, 23, 42, 0.06);
}

[data-theme="light"] .curso-card__badge {
  background: rgba(0, 0, 0, 0.07);
}

.servicio-item-card {
  background: var(--card-bg);
  backdrop-filter: blur(14px) saturate(1.15);
  -webkit-backdrop-filter: blur(14px) saturate(1.15);
  border: 1px solid var(--glass-border) !important;
  border-radius: var(--radius-lg) !important;
  box-shadow: var(--shadow-soft);
  transition:
    transform var(--transition-fast),
    box-shadow var(--transition-fast),
    border-color var(--transition-fast);
}

.servicio-item-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: rgba(99, 102, 241, 0.22) !important;
}

.servicio-item-card__text {
  color: var(--muted);
  line-height: 1.6;
  max-width: 22rem;
}

/* primary y success usaban --accent y --accent-2 — ahora desacoplados:
   los títulos de cards no se mueven cuando el admin cambia los pickers de acento.
   El acento sigue pintándose en la regla de debajo del título (servicio-item-card__rule)
   y en el círculo, que es donde tiene sentido visualmente. */
.servicio-item-card h3.text-primary  { color: var(--text) !important; }
.servicio-item-card h3.text-danger   { color: #e11d48 !important; }
.servicio-item-card h3.text-success  { color: var(--text) !important; }
.servicio-item-card h3.text-warning  { color: #d97706 !important; }
.servicio-item-card h3.text-info     { color: #0284c7 !important; }

.servicio-item-card__rule {
  display: block;
  width: 2.5rem;
  height: 3px;
  border-radius: 999px;
  margin: 0.65rem auto 0.85rem;
  flex-shrink: 0;
}

/* primary y success ahora con color fijo (mismo tono que el default de los acentos
   en oscuro), para que NO se muevan cuando el admin cambia los pickers del Ajustes. */
.servicio-item-card__rule--primary { background: #6366f1; }
.servicio-item-card__rule--danger  { background: #e11d48; }
.servicio-item-card__rule--success { background: #10b981; }
.servicio-item-card__rule--warning { background: #d97706; }
.servicio-item-card__rule--info    { background: #0284c7; }

@media (min-width: 1400px) {
  .servicio-item-card__text {
    max-width: none;
  }
}

.servicio-circulo {
  width: 120px;
  height: 120px;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s ease;
}

.servicio-circulo img.emoji {
  width: 3rem;
  height: 3rem;
}

.servicio-circulo__img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 0.5rem;
  display: block;
}

[data-theme="light"] .servicio-item-card {
  background: var(--card-bg) !important;
  border-top: 3px solid rgba(79, 70, 229, 0.75) !important;
  border-left: 1px solid rgba(79, 70, 229, 0.10) !important;
  border-right: 1px solid rgba(79, 70, 229, 0.10) !important;
  border-bottom: 1px solid rgba(79, 70, 229, 0.10) !important;
  box-shadow:
    0 6px 24px rgba(79, 70, 229, 0.10),
    0 1px 4px rgba(79, 70, 229, 0.06) !important;
}

[data-theme="light"] .servicio-item-card:hover {
  box-shadow:
    0 20px 48px rgba(79, 70, 229, 0.18),
    0 4px 12px rgba(79, 70, 229, 0.10) !important;
}

.calendario {
  background: var(--bg);
  color: var(--text);
}

.calendario__frame {
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  overflow: hidden;
  background: var(--surface);
  width: fit-content;
  max-width: 100%;
  margin-left: auto;
  margin-right: auto;
}

.calendario__img {
  width: min(920px, 100%);
  height: auto;
  display: block;
}

.calendario__frame--clickable {
  position: relative;
  cursor: zoom-in;
}

.calendario__overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0);
  transition: background 0.2s ease;
  border-radius: var(--radius);
}

.calendario__overlay i {
  font-size: 2rem;
  color: #fff;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.calendario__frame--clickable:hover .calendario__overlay {
  background: rgba(0, 0, 0, 0.35);
}

.calendario__frame--clickable:hover .calendario__overlay i {
  opacity: 1;
}

@media (max-width: 576px) {
  .calendario__img {
    width: 100%;
  }
}

.sobre-nosotros .lead {
  line-height: 1.65;
  font-weight: 500;
}

/* Ratio 16:9 fijo con object-fit:cover para que ambas fotos
   tengan el mismo tamaño independientemente de sus dimensiones originales. */
.galeria img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  object-position: center;
  border-radius: var(--radius-lg);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
  display: block;
}

.galeria img:hover {
  transform: scale(1.02);
  box-shadow: var(--shadow);
}

.faq .accordion-flush .accordion-item {
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: 0.85rem;
  border: 1px solid var(--glass-border) !important;
  background: var(--glass-bg);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: var(--shadow-soft);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.faq .accordion-button {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.14), rgba(16, 185, 129, 0.08));
  color: var(--text);
  font-weight: 600;
  box-shadow: none;
  border-radius: var(--radius) !important;
}

.faq .accordion-button:not(.collapsed) {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.26), rgba(16, 185, 129, 0.12));
  color: var(--text);
}

.faq .accordion-body {
  background: var(--card-bg);
  color: var(--text);
  border-top: 1px solid var(--border);
  line-height: 1.6;
}

.faq .accordion-item:hover {
  /* desplazamiento leve a la derecha: sugiere que el ítem es expandible sin ser demasiado obvio */
  transform: translateX(3px);
  box-shadow: var(--shadow);
  border-color: rgba(99, 102, 241, 0.2) !important;
}

/* Bootstrap genera el chevron del acordeón como imagen SVG oscura; aquí lo invertimos a blanco para el modo oscuro */
:root:not([data-theme="light"]) .faq .accordion-button::after {
  filter: brightness(0) invert(1) opacity(0.88);
}

[data-theme="light"] .faq .accordion-flush .accordion-item {
  background: rgba(255, 255, 255, 0.95) !important;
  border-color: rgba(79, 70, 229, 0.15) !important;
  box-shadow: 0 4px 16px rgba(79, 70, 229, 0.08) !important;
}

[data-theme="light"] .faq .accordion-button {
  background: rgba(238, 242, 255, 0.85) !important;
  color: #1e1b4b;
}

[data-theme="light"] .faq .accordion-button:not(.collapsed) {
  background: rgba(224, 231, 255, 0.95) !important;
  color: #1e1b4b;
}

[data-theme="light"] .faq .accordion-body {
  background: var(--card-bg) !important;
  border-top-color: rgba(79, 70, 229, 0.12) !important;
}

.english-path-section {
  position: relative;
  background: transparent;
}

.english-path-section .animate__animated {
  --animate-duration: 900ms;
  --animate-timing-function: var(--ease-premium, ease);
}

.english-path-card {
  position: relative;
  border-radius: 18px !important;
  background: var(--ep-accent);
  border: 1px solid rgba(255, 255, 255, 0.28);
  box-shadow: var(--shadow);
  overflow: hidden;
  min-height: 160px;
  transition: transform 260ms var(--ease-premium, ease), box-shadow 260ms var(--ease-premium, ease);
}

/* brillo en la esquina superior izquierda + sombra en la inferior derecha: simula luz de techo lateral */
.english-path-card::before {
  content: "";
  position: absolute;
  inset: -1px;
  background:
    radial-gradient(700px 420px at 12% 10%, rgba(255, 255, 255, 0.35), transparent 55%),
    radial-gradient(900px 520px at 85% 85%, rgba(0, 0, 0, 0.16), transparent 60%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0));
  opacity: 1;
  pointer-events: none;
}

/* color-mix como señal de navegador moderno; en Safari < 15.4 y Firefox < 113 quitamos la sombra oscura */
@supports not (color-mix(in srgb, #000, #fff)) {
  .english-path-card::before {
    background:
      radial-gradient(700px 420px at 12% 10%, rgba(255, 255, 255, 0.35), transparent 55%),
      linear-gradient(135deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0));
  }
}

.english-path-card__inner {
  position: relative;
  padding: 0.9rem 0.9rem 1rem;
  height: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.english-path-card__top {
  display: flex;
  align-items: center;
}

.english-path-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.42);
  border: 1px solid rgba(255, 255, 255, 0.35);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.18);
  color: rgba(15, 23, 42, 0.86);
  font-size: 0.82rem;
  max-width: 100%;
}

.english-path-pill__age {
  font-weight: 900;
}

.english-path-pill__dot {
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.55);
}

.english-path-pill__label {
  font-weight: 800;
  opacity: 0.86;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 120px;
}

.english-path-card__title {
  font-size: 1.05rem;
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 1.15;
  position: relative;
  color: rgba(15, 23, 42, 0.92);
  margin-top: 0.2rem;
}

@media (max-width: 576px) {
  .english-path-card { min-height: 150px; }
}

@media (prefers-reduced-motion: reduce) {
  .english-path-card { transition: none; }
}

/* modal de matrícula */
.enroll-modal-content {
  --enroll-card-accent: var(--accent);
  /* fondo sólido — no usar --surface que es semitransparente */
  background: var(--card-bg);
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 1.25rem;
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(99, 102, 241, 0.08);
  overflow: hidden;
}

[data-theme="light"] .enroll-modal-content {
  background: var(--card-bg);
  border: 1px solid rgba(15, 23, 42, 0.1);
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.14), 0 0 0 1px rgba(124, 58, 237, 0.06);
}

/* franja de color de la card encima del encabezado */
.enroll-modal-stripe {
  height: 5px;
  background: var(--enroll-card-accent);
  border-radius: 1.25rem 1.25rem 0 0;
}

.enroll-modal-header {
  padding: 1.1rem 1.4rem 0.5rem;
  align-items: flex-start;
}

.enroll-modal-heading {
  flex: 1;
  min-width: 0;
}

/* "Matricularse" — etiqueta pequeña en el color de la card */
.enroll-modal-action-label {
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--enroll-card-accent);
  line-height: 1;
}

/* nombre del curso — protagonista */
.enroll-modal-course-name {
  font-size: 1.2rem;
  font-weight: 800;
  color: #f1f5f9;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

[data-theme="light"] .enroll-modal-course-name {
  color: #0f172a;
}

/* chip de rango de edad */
.enroll-modal-age-chip {
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.18rem 0.6rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  color: rgba(241, 245, 249, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

[data-theme="light"] .enroll-modal-age-chip {
  background: rgba(15, 23, 42, 0.06);
  color: #64748b;
  border-color: rgba(15, 23, 42, 0.1);
}

/* botón cerrar — adapta al modo claro/oscuro sin clase Bootstrap -white */
.enroll-modal-close {
  flex-shrink: 0;
  background: none;
  border: none;
  padding: 0.4rem;
  border-radius: 50%;
  cursor: pointer;
  color: rgba(148, 163, 184, 0.7);
  font-size: 1rem;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 150ms ease, background 150ms ease;
  margin-left: 0.5rem;
  margin-top: -0.15rem;
}

.enroll-modal-close:hover {
  color: #f1f5f9;
  background: rgba(255, 255, 255, 0.1);
}

[data-theme="light"] .enroll-modal-close {
  color: #64748b;
}

[data-theme="light"] .enroll-modal-close:hover {
  color: #0f172a;
  background: rgba(15, 23, 42, 0.06);
}

.enroll-modal-body {
  padding: 0.5rem 1.4rem 1.4rem;
}

/* subtítulo */
.enroll-modal-subtitle {
  color: rgba(148, 163, 184, 0.85);
  font-size: 0.82rem;
}

[data-theme="light"] .enroll-modal-subtitle {
  color: #64748b;
}

/* etiquetas del formulario */
.enroll-label {
  display: flex;
  align-items: baseline;
  gap: 0.3rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: #94a3b8;
  margin-bottom: 0.4rem;
}

[data-theme="light"] .enroll-label {
  color: #475569;
}

.enroll-required {
  color: var(--enroll-card-accent);
  font-size: 0.85em;
}

.enroll-optional {
  color: rgba(148, 163, 184, 0.6);
  font-size: 0.8em;
  font-weight: 400;
}

[data-theme="light"] .enroll-optional {
  color: #94a3b8;
}

/* campos del formulario */
.enroll-input {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(148, 163, 184, 0.2);
  color: #f1f5f9;
  border-radius: 10px;
  font-size: 0.9rem;
  transition: border-color 180ms ease, box-shadow 180ms ease;
}

.enroll-input:focus {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--enroll-card-accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--enroll-card-accent) 25%, transparent);
  color: #f1f5f9;
  outline: none;
}

.enroll-input::placeholder {
  color: rgba(148, 163, 184, 0.45);
}

[data-theme="light"] .enroll-input {
  background: #f8fafc;
  border-color: rgba(15, 23, 42, 0.12);
  color: #0f172a;
}

[data-theme="light"] .enroll-input:focus {
  background: #ffffff;
  border-color: var(--enroll-card-accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--enroll-card-accent) 18%, transparent);
  color: #0f172a;
}

[data-theme="light"] .enroll-input::placeholder {
  color: #94a3b8;
}

.enroll-textarea {
  resize: vertical;
  min-height: 140px;
}

/* zona de error */
.enroll-error-wrap {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  background: rgba(248, 113, 113, 0.1);
  border: 1px solid rgba(248, 113, 113, 0.3);
  border-radius: 10px;
  padding: 0.6rem 0.9rem;
  font-size: 0.82rem;
  color: #fca5a5;
}

[data-theme="light"] .enroll-error-wrap {
  background: rgba(239, 68, 68, 0.07);
  border-color: rgba(239, 68, 68, 0.2);
  color: #dc2626;
}

/* botón de envío — usa el color de la card como fondo */
.enroll-submit-btn {
  background: var(--enroll-card-accent);
  color: #ffffff;
  border: none;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.9rem;
  padding: 0.65rem 1rem;
  transition: filter 180ms ease, transform 120ms ease;
}

.enroll-submit-btn:hover:not(:disabled) {
  filter: brightness(1.12);
  transform: translateY(-1px);
}

.enroll-submit-btn:active:not(:disabled) {
  transform: translateY(0);
}

.enroll-submit-btn:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

/* estado de éxito */
.enroll-success-state {
  text-align: center;
  padding: 1.5rem 0.5rem 0.75rem;
}

.enroll-success-icon-wrap {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: color-mix(in srgb, var(--enroll-card-accent) 18%, transparent);
  border: 2px solid color-mix(in srgb, var(--enroll-card-accent) 35%, transparent);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
}

.enroll-success-icon {
  font-size: 1.9rem;
  color: var(--enroll-card-accent);
}

.enroll-success-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: #f1f5f9;
}

[data-theme="light"] .enroll-success-title {
  color: #0f172a;
}

.enroll-success-body {
  font-size: 0.85rem;
  color: rgba(148, 163, 184, 0.85);
}

[data-theme="light"] .enroll-success-body {
  color: #64748b;
}

@media (max-width: 400px) {
  .enroll-modal-course-name { font-size: 1rem; }
}

/* botón 'Más información' dentro de la tarjeta de etapa */
.english-path-more {
  margin-top: 0.7rem;
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.5rem 1rem;
  border-radius: 999px;
  font-weight: 800;
  font-size: 0.86rem;
  letter-spacing: 0.01em;
  background: #fff;
  border: 1.5px solid #fff;
  color: rgba(15, 23, 42, 0.92);
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.28);
  transition: background 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease, color 0.18s ease;
  cursor: pointer;
}

.english-path-more i {
  font-size: 1rem;
  color: var(--ep-accent);
}

.english-path-more:hover {
  background: var(--ep-accent);
  color: #fff;
  border-color: var(--ep-accent);
  transform: translateY(-2px);
  box-shadow: 0 14px 28px rgba(15, 23, 42, 0.34);
}

.english-path-more:hover i {
  color: #fff;
}

.english-path-more:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
  .english-path-more:hover { transform: none; }
}

/* ────────── modal de etapa ──────────
   Estructura:
   ┌─────────────────────────────────┐
   │ BANNER color etapa  [pill] [x] │  → identifica la etapa al instante
   ├─────────────────────────────────┤
   │ Imagen (contain)                │
   │                                 │
   │ Título                          │  → scrolla si el contenido es largo
   │ Descripción…                    │
   ├─────────────────────────────────┤
   │ [Cerrar]    [Matricularme →]    │
   └─────────────────────────────────┘
   Respeta tema oscuro/claro mediante var(--card-bg), var(--text), var(--border).
*/
.english-path-modal__content {
  --ep-accent: var(--accent);
  background: var(--card-bg);
  color: var(--text, #f1f5f9);
  border: 1px solid var(--border, rgba(148, 163, 184, 0.18));
  border-radius: 1.25rem;
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(99, 102, 241, 0.08);
  overflow: hidden;
}

[data-theme="light"] .english-path-modal__content {
  color: #0f172a;
}

/* ─── BANNER superior con el color de la etapa ─── */
.english-path-modal__banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.25rem;
  background: linear-gradient(120deg,
    var(--ep-accent) 0%,
    color-mix(in srgb, var(--ep-accent) 70%, #0f172a) 100%);
  border-bottom: 1px solid color-mix(in srgb, var(--ep-accent) 30%, transparent);
}

.english-path-modal__pill {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.5rem 1rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.22);
  border: 1px solid rgba(255, 255, 255, 0.35);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  color: #fff;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
}

.english-path-modal__age {
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.english-path-modal__dot {
  width: 5px; height: 5px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.7);
}

.english-path-modal__label {
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

/* botón cerrar dentro del banner — heredamos el btn-close de Bootstrap y solo
   le ponemos un círculo de fondo para que destaque sobre el color de la etapa. */
.english-path-modal__close {
  flex: 0 0 auto;
  background-color: rgba(15, 23, 42, 0.35);
  border-radius: 999px;
  padding: 0.6rem;
  opacity: 1;
  transition: background-color 0.15s ease, transform 0.15s ease;
}
.english-path-modal__close:hover {
  background-color: rgba(15, 23, 42, 0.6);
  transform: scale(1.05);
}

/* ─── BODY: imagen + texto, con scroll de Bootstrap si excede ───
   `modal-dialog-scrollable` ya hace que el body sea el único que scrolla,
   manteniendo banner y footer pegados arriba/abajo. */
.english-path-modal__body {
  padding: clamp(1.25rem, 3vw, 2rem) clamp(1.25rem, 3vw, 2.25rem);
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  font-size: 1rem;
  line-height: 1.7;
}

/* franja de imagen — fondo neutro (no del color de etapa, ya está arriba) */
.english-path-modal__figure {
  margin: 0;
  border-radius: 0.85rem;
  overflow: hidden;
  background: color-mix(in srgb, var(--text, #f1f5f9) 6%, transparent);
  border: 1px solid var(--border, rgba(148, 163, 184, 0.15));
  display: flex;
  align-items: center;
  justify-content: center;
  height: clamp(220px, 38vh, 380px);
  flex-shrink: 0;
}

[data-theme="light"] .english-path-modal__figure {
  background: rgba(15, 23, 42, 0.04);
}

.english-path-modal__image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  padding: 0.5rem;
}

.english-path-modal__title {
  font-size: clamp(1.4rem, 2.2vw, 1.85rem);
  font-weight: 800;
  line-height: 1.2;
  margin: 0;
  letter-spacing: -0.01em;
  color: var(--ep-accent);
}

.english-path-modal__text {
  min-width: 0;
}

.english-path-modal__text p {
  margin-bottom: 1.05rem;
  text-align: justify;
}
.english-path-modal__text p:last-child {
  margin-bottom: 0;
}

.english-path-modal__text strong {
  color: var(--ep-accent);
  font-weight: 800;
}

.english-path-modal__text .path-modal-claim {
  font-weight: 700;
  font-size: 1.05rem;
  line-height: 1.5;
  text-align: left;
  padding: 0.9rem 1.1rem;
  border-left: 4px solid var(--ep-accent);
  background: color-mix(in srgb, var(--ep-accent) 12%, transparent);
  border-radius: 0 0.75rem 0.75rem 0;
  margin: 1.25rem 0;
}

.english-path-modal__text .path-modal-tags {
  list-style: none;
  padding: 0;
  margin: 1.25rem 0 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.english-path-modal__text .path-modal-tags li {
  font-weight: 600;
  font-size: 0.88rem;
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  background: color-mix(in srgb, var(--ep-accent) 14%, transparent);
  border: 1px solid color-mix(in srgb, var(--ep-accent) 30%, transparent);
}

.english-path-modal__text .path-modal-emoji {
  display: inline-block;
  font-size: 0.78em;
  vertical-align: 1px;
  margin-right: 0.2em;
  line-height: 1;
}

/* ─── FOOTER ─── */
.english-path-modal__footer {
  background: rgba(15, 23, 42, 0.5);
  border-top: 1px solid rgba(148, 163, 184, 0.15);
  padding: 1rem 1.5rem;
}

[data-theme="light"] .english-path-modal__footer {
  background: rgba(241, 245, 249, 0.85);
  border-top-color: rgba(15, 23, 42, 0.08);
}

/* CTA "Matricularme": fondo color de etapa, texto siempre oscuro y legible.
   Forzamos color en todos los estados (hover/focus/active) para evitar que
   Bootstrap convierta el texto a blanco y lo deje invisible sobre el accent claro. */
.english-path-modal__cta,
.english-path-modal__cta:link,
.english-path-modal__cta:visited {
  background: var(--ep-accent);
  color: #0f172a;
  border: none;
  font-weight: 800;
  padding: 0.6rem 1.25rem;
  border-radius: 999px;
  transition: transform 0.18s ease, filter 0.18s ease, box-shadow 0.18s ease;
  box-shadow: 0 6px 16px color-mix(in srgb, var(--ep-accent) 35%, transparent);
}

.english-path-modal__cta:hover,
.english-path-modal__cta:focus,
.english-path-modal__cta:focus-visible,
.english-path-modal__cta:active {
  background: var(--ep-accent);
  color: #0f172a;
  transform: translateY(-1px);
  filter: brightness(1.08);
  box-shadow: 0 10px 22px color-mix(in srgb, var(--ep-accent) 50%, transparent);
  outline: none;
}

.english-path-modal__cta:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 2px;
}

/* ─── responsive móvil ─── */
@media (max-width: 575.98px) {
  .english-path-modal__banner { padding: 0.85rem 1rem; gap: 0.6rem; }
  .english-path-modal__pill { padding: 0.4rem 0.8rem; gap: 0.45rem; }
  .english-path-modal__age { font-size: 0.95rem; }
  .english-path-modal__label { font-size: 0.75rem; }
  .english-path-modal__close { padding: 0.5rem; }
  .english-path-modal__body { padding: 1rem 1rem 1.25rem; gap: 1rem; font-size: 0.95rem; line-height: 1.65; }
  .english-path-modal__figure { height: clamp(180px, 30vh, 240px); }
}

@media (prefers-reduced-motion: reduce) {
  .english-path-modal__cta:hover,
  .english-path-modal__close:hover { transform: none; }
}
