/* CEA Santa Rita — tipografía viva + fondos automáticos + acentos amarillo/ámbar */

:root {
  --cea-amarillo: #F5C842;
  --cea-amarillo-suave: #FFE08A;
  --cea-coral: #E86A4A;
  --cea-vino: #5C1A1E;
  --cea-miel: #D4A017;
}

/* ——— Fondos de sección que cambian solos ——— */
@keyframes ceaBgCycleA {
  0%, 100% {
    background:
      radial-gradient(720px 260px at 85% 0%, rgba(245, 200, 66, 0.16), transparent 58%),
      radial-gradient(560px 220px at 5% 100%, rgba(179, 40, 45, 0.1), transparent 60%),
      linear-gradient(165deg, #FFF9F2, #F7F0E8 50%, #F3EBE2);
  }
  50% {
    background:
      radial-gradient(720px 260px at 15% 10%, rgba(179, 40, 45, 0.12), transparent 55%),
      radial-gradient(560px 220px at 95% 90%, rgba(232, 160, 23, 0.18), transparent 60%),
      linear-gradient(195deg, #FFF4E8, #F8E9D8 48%, #F2E4D4);
  }
}
@keyframes ceaBgCycleB {
  0%, 100% {
    background:
      radial-gradient(680px 240px at 100% 0%, rgba(232, 106, 74, 0.1), transparent 55%),
      linear-gradient(180deg, #F4ECE4, #EFE5DA);
  }
  50% {
    background:
      radial-gradient(680px 240px at 0% 100%, rgba(245, 200, 66, 0.14), transparent 55%),
      linear-gradient(180deg, #F7EFE4, #F0E4D6);
  }
}

main .cea-section:nth-of-type(odd) {
  animation: ceaBgCycleA 14s ease-in-out infinite;
}
main .cea-section:nth-of-type(even),
main .cea-section.cea-section-alt {
  animation: ceaBgCycleB 16s ease-in-out infinite !important;
}

/* Marco suave de sección */
.cea-section > .container {
  padding-top: 0.35rem;
  padding-bottom: 0.35rem;
}

/* ——— TEXTOS: tipografía con efecto (faltaban estilos) ——— */
.cea-section-title,
main h1,
main h2 {
  font-family: var(--font-display) !important;
  letter-spacing: -0.02em;
  line-height: 1.15;
  text-shadow: 0 2px 0 rgba(255, 255, 255, 0.35);
}
.cea-section-title {
  background: linear-gradient(115deg, #2C2C2A 0%, #7A1B1E 35%, #B3282D 55%, #D4A017 78%, #2C2C2A 100%) !important;
  background-size: 220% 100% !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  color: transparent !important;
  animation: ceaTitleRiver 9s ease-in-out infinite !important;
  filter: drop-shadow(0 8px 14px rgba(179, 40, 45, 0.12));
}
@keyframes ceaTitleRiver {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

.cea-section-sub,
main .cea-section > .container > p {
  color: #5B524C !important;
  font-size: 1.05rem;
  line-height: 1.7;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.5);
  border-left: 3px solid transparent;
  border-image: linear-gradient(180deg, var(--cea-rojo), var(--cea-amarillo)) 1;
  padding-left: 0.9rem;
  transition: color 0.35s, border-color 0.35s, transform 0.4s, text-shadow 0.35s;
}
.cea-section-sub:hover,
main .cea-section > .container > p:hover {
  color: #3F342E !important;
  transform: translateX(4px);
  text-shadow: 0 6px 18px rgba(232, 160, 23, 0.2);
}

main h3,
main .h5,
.cea-news-card .h5,
.cea-gallery-title,
.cea-list-item h3,
.cea-panel h3 {
  font-family: var(--font-display) !important;
  letter-spacing: -0.01em;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.4);
  transition: color 0.35s, transform 0.4s, text-shadow 0.4s, letter-spacing 0.35s !important;
}
main p,
.cea-news-card p,
.cea-panel p,
.cea-gallery-desc,
.cea-gallery-meta {
  line-height: 1.65;
  color: #5A534D;
  transition: color 0.35s, opacity 0.35s;
}

/* ——— MENÚ PRINCIPAL (texto legible + login destacado) ——— */
.cea-nav .nav-item {
  opacity: 1 !important;
  transform: none !important;
  animation: none !important; /* no pisar la entrada; evita textos invisibles */
}

.cea-navbar .cea-brand-text strong {
  color: #FFE8A3 !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.45), 0 0 14px rgba(245, 200, 66, 0.3) !important;
  animation: none;
}
.cea-navbar .cea-brand-text span {
  color: rgba(255, 236, 200, 0.78) !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
}
.cea-navbar .cea-brand:hover .cea-brand-text strong {
  color: #FFF1C2 !important;
}

.cea-nav .nav-link {
  color: #F7F2EC !important;
  opacity: 1 !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
  border: 1px solid transparent;
  background: transparent;
}
.cea-nav .nav-link:hover {
  color: #FFE8A3 !important;
  border-color: rgba(245, 200, 66, 0.35);
  background: rgba(255, 255, 255, 0.08) !important;
  text-shadow: 0 0 12px rgba(245, 200, 66, 0.35), 0 1px 2px rgba(0, 0, 0, 0.4);
}
.cea-nav .nav-link.active {
  color: #1A1210 !important;
  background: linear-gradient(135deg, #F5C842 0%, #E8A017 55%, #F0C55A 100%) !important;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.35) !important;
  border: 1px solid rgba(255, 255, 255, 0.25);
  box-shadow: 0 10px 24px rgba(232, 160, 23, 0.35);
  animation: none;
}
.cea-nav .nav-link.active:hover {
  color: #1A1210 !important;
}

/* Login más notorio */
.cea-nav .nav-login {
  color: #1A1210 !important;
  background: linear-gradient(145deg, #FFE08A, #F5C842 45%, #E8A017) !important;
  border: 1.5px solid rgba(255, 236, 180, 0.85) !important;
  box-shadow:
    0 0 0 2px rgba(179, 40, 45, 0.35),
    0 10px 24px rgba(232, 160, 23, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.55) !important;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.35) !important;
  font-weight: 700 !important;
  padding: 0.48rem 1.05rem !important;
}
.cea-nav .nav-login:hover {
  color: #fff !important;
  background: linear-gradient(145deg, #B3282D, #7A1B1E) !important;
  border-color: #F5C842 !important;
  box-shadow:
    0 0 0 2px rgba(245, 200, 66, 0.55),
    0 14px 30px rgba(179, 40, 45, 0.45) !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35) !important;
  transform: translateY(-3px) scale(1.05);
}
.cea-nav .nav-login.active {
  color: #fff !important;
  background: linear-gradient(145deg, #7A1B1E, #5C1215) !important;
}

@keyframes ceaGlowText {
  0%, 100% { filter: brightness(1); }
  50% { filter: brightness(1.12); }
}
@keyframes ceaActiveGlow {
  0%, 100% { box-shadow: 0 12px 28px rgba(245, 200, 66, 0.3); }
  50% { box-shadow: 0 16px 36px rgba(245, 200, 66, 0.5), 0 0 0 4px rgba(245, 200, 66, 0.15); }
}

/* Page header: título blanco-ámbar con sombra */
.cea-page-header h1 {
  color: #FFF6E0 !important;
  text-shadow:
    0 2px 0 rgba(92, 26, 30, 0.35),
    0 12px 30px rgba(0, 0, 0, 0.35),
    0 0 28px rgba(245, 200, 66, 0.3) !important;
  border-bottom: 0;
  position: relative;
  display: inline-block;
  padding-bottom: 0.35rem;
}
.cea-page-header h1::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 55%;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--cea-amarillo), var(--cea-rojo), transparent);
  box-shadow: 0 0 12px rgba(245, 200, 66, 0.55);
  animation: ceaUnderlinePulse 2.8s ease-in-out infinite;
}
@keyframes ceaUnderlinePulse {
  0%, 100% { width: 45%; opacity: 0.75; }
  50% { width: 70%; opacity: 1; }
}
.cea-page-header p {
  color: var(--cea-amarillo-suave) !important;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.35), 0 0 16px rgba(245, 200, 66, 0.2);
  font-weight: 500;
  letter-spacing: 0.02em;
}

/* Hero texts */
.cea-hero-brand {
  text-shadow: 0 16px 40px rgba(0, 0, 0, 0.4), 0 0 30px rgba(245, 200, 66, 0.25) !important;
}
.cea-hero-eyebrow {
  color: var(--cea-amarillo) !important;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.45), 0 0 14px rgba(245, 200, 66, 0.35);
  border: 1px solid rgba(245, 200, 66, 0.35);
  border-radius: 999px;
  padding: 0.35rem 0.85rem;
  background: rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(6px);
}
.cea-hero-eyebrow::before { display: none; }
.cea-hero-lead {
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.4);
  color: rgba(255, 246, 224, 0.95) !important;
}

/* Footer textos ámbar */
.cea-footer h5 {
  color: var(--cea-amarillo-suave) !important;
  text-shadow: 0 0 16px rgba(245, 200, 66, 0.25), 0 2px 0 rgba(0, 0, 0, 0.35);
  border-bottom: 1px solid rgba(245, 200, 66, 0.25);
  padding-bottom: 0.45rem;
  display: inline-block;
}
.cea-footer p,
.cea-footer .small {
  color: rgba(255, 236, 200, 0.88) !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}
.cea-footer a {
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}
.cea-footer a:hover {
  color: var(--cea-amarillo) !important;
  text-shadow: 0 0 16px rgba(245, 200, 66, 0.5) !important;
}
.cea-footer-bottom {
  color: rgba(255, 224, 138, 0.65) !important;
  border-top-color: rgba(245, 200, 66, 0.28) !important;
}

/* ——— Cajas / contenedores / bordes elegantes ——— */
.cea-news-card,
.cea-gallery-card,
.cea-panel,
.cea-malla-viewer,
.cea-gallery-quote,
main .card,
main form.bg-white,
main .bg-white.p-3,
main .bg-white.p-4 {
  border: 1px solid rgba(212, 160, 23, 0.18) !important;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.9) inset,
    0 14px 34px rgba(44, 30, 28, 0.09),
    0 0 0 1px rgba(179, 40, 45, 0.04) !important;
  background: linear-gradient(165deg, #FFFFFF 0%, #FFFCF8 40%, #FFF8EF 100%) !important;
}

.cea-list-item {
  border: 1px solid rgba(212, 160, 23, 0.16) !important;
  background: linear-gradient(110deg, rgba(255,255,255,0.92), rgba(255, 248, 235, 0.88)) !important;
  box-shadow: 0 12px 30px rgba(44, 30, 28, 0.07) !important;
}

/* Animación automática suave de borde en tarjetas visibles */
@keyframes ceaSoftPulseBorder {
  0%, 100% {
    box-shadow:
      0 1px 0 rgba(255,255,255,0.9) inset,
      0 14px 34px rgba(44, 30, 28, 0.09),
      0 0 0 1px rgba(212, 160, 23, 0.12);
  }
  50% {
    box-shadow:
      0 1px 0 rgba(255,255,255,0.9) inset,
      0 18px 40px rgba(179, 40, 45, 0.12),
      0 0 0 1px rgba(245, 200, 66, 0.32);
  }
}
.cea-reveal.is-in.cea-news-card,
.cea-reveal.is-in.cea-panel,
.cea-reveal.is-in.cea-gallery-card {
  animation: ceaSoftPulseBorder 4.5s ease-in-out infinite;
}

/* ——— Botones: borde + sombra profesional ——— */
.btn-cea {
  border: 1px solid rgba(255, 255, 255, 0.22) !important;
  box-shadow:
    0 12px 28px rgba(122, 27, 30, 0.28),
    0 0 0 1px rgba(212, 160, 23, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.25) !important;
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.25);
}
.btn-cea-ghost {
  border: 1.5px solid rgba(179, 40, 45, 0.45) !important;
  box-shadow: 0 8px 20px rgba(232, 160, 23, 0.12);
  color: var(--cea-rojo) !important;
}
.btn-cea-ghost:hover {
  border-color: transparent !important;
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.2);
}

/* ——— Imágenes con marco y sombra ——— */
main img:not(.cea-brand img):not(.rounded-circle) {
  border: 1px solid rgba(212, 160, 23, 0.2);
  box-shadow: 0 14px 34px rgba(44, 30, 28, 0.12);
  border-radius: 0.85rem;
}
main img:not(.cea-brand img):not(.rounded-circle):hover {
  border-color: rgba(245, 200, 66, 0.55);
  box-shadow:
    0 22px 48px rgba(179, 40, 45, 0.18),
    0 0 0 3px rgba(245, 200, 66, 0.25) !important;
}

/* Divisiones / separadores animados */
.cea-section + .cea-section::before,
.cea-divider {
  content: "";
}
.cea-section + .cea-section {
  border-top: 1px solid transparent;
  border-image: linear-gradient(90deg, transparent, rgba(179,40,45,0.25), rgba(245,200,66,0.45), rgba(179,40,45,0.25), transparent) 1;
}

.cea-carousel-shell {
  border: 1px solid rgba(212, 160, 23, 0.25) !important;
  box-shadow:
    0 24px 55px rgba(44, 30, 28, 0.16),
    0 0 0 1px rgba(179, 40, 45, 0.05) !important;
}
.cea-carousel-caption h3 {
  color: #FFF3D0 !important;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.55), 0 0 18px rgba(245, 200, 66, 0.25);
}

/* Badges con borde y brillo */
.cea-badge {
  border: 1px solid rgba(212, 160, 23, 0.3);
  box-shadow: 0 4px 12px rgba(44, 30, 28, 0.06);
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.25);
}
.cea-badge-dorado {
  background: linear-gradient(135deg, rgba(245, 200, 66, 0.28), rgba(212, 160, 23, 0.18)) !important;
  color: #8A5A08 !important;
  border-color: rgba(245, 200, 66, 0.45) !important;
}

/* (flotación de ítems del menú desactivada: ocultaba textos) */

/* Tabs texto */
.cea-gallery-tabs .nav-link {
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.4);
  border: 1px solid transparent !important;
}
.cea-gallery-tabs .nav-link:hover {
  border-color: rgba(212, 160, 23, 0.35) !important;
  color: var(--cea-rojo) !important;
}
.cea-gallery-tabs .nav-link.active {
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.2) !important;
  border-color: rgba(255, 255, 255, 0.2) !important;
}

/* Empty state tipografía */
.cea-empty {
  font-family: var(--font-body);
  letter-spacing: 0.01em;
  border: 1.5px dashed rgba(212, 160, 23, 0.4) !important;
  color: #6B5A48 !important;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.5);
}

/* Form labels más claros */
main .form-label {
  font-weight: 600;
  color: #4A403A;
  letter-spacing: 0.01em;
}

/* cea-stage + pulse border: prefer scroll transform */
.cea-stage.cea-reveal.is-in.cea-news-card,
.cea-stage.cea-reveal.is-in.cea-panel,
.cea-stage.cea-reveal.is-in.cea-gallery-card {
  animation: none !important;
}

@media (prefers-reduced-motion: reduce) {
  main .cea-section:nth-of-type(odd),
  main .cea-section:nth-of-type(even),
  .cea-section-title,
  .cea-navbar .cea-brand-text strong,
  .cea-nav .nav-link.active,
  .cea-page-header h1::after,
  .cea-nav .nav-item {
    animation: none !important;
  }
}
