:root {
  --primary: #ff7043;
  --primary-dark: #ffbb00;
  --secondary: #ffa726;
  --accent: #ffe0b2;
  --dark: #263238;
  --light: #fff3e0;
  --text: #333;
  --success: #4caf50;
  --danger: #f44336;
}

body {
  font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, Arial;
  background: linear-gradient(135deg, #fff3e0 0%, #fbe9e7 50%, #ffccbc 100%);
  background-attachment: fixed;
  color: var(--text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
}

.main-container {
  flex: 1;
  padding: 1rem;
  position: relative;
  z-index: 1;
}

.logo {
  max-width: 200px;
  transition: all 0.3s ease;
}
.logo:hover {
  transform: scale(1.05);
}

/* Título */
.animated-title {
  font-size: 3rem;
  font-weight: 900;
  background: linear-gradient(135deg, var(--primary), var(--secondary), var(--primary-dark));
  background-size: 200% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  -webkit-text-stroke: 0.8px rgba(0, 0, 0, 0.2);
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  margin-bottom: 0.8rem;
  animation: gradientShift 5s ease infinite, float 6s ease-in-out infinite;
}

.subtitle {
  font-size: 1.3rem;
  color: var(--dark);
  margin-bottom: 0.1rem;
  opacity: 0.9;
  animation: fadeIn 2s ease;
}

/* Botón principal */
.btn {
  border-radius: 12px;
  padding: 0.8rem 1.5rem;
  text-shadow: 1px 1px 2px rgba(0,0,0,0.1); 
  font-weight: bold;
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.9rem;
  transition: transform 0.3s ease;
}
.btn:hover {
  transform: translateY(-3px);
}
.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #fff;
}
.btn-primary:hover {
  background: linear-gradient(135deg, var(--primary-dark), var(--primary));
}

/* Tarjetas */
.card {
  border-radius: 16px;
  background: #fff;
  border: 1px solid rgba(255, 167, 38, 0.3);
  box-shadow: 0 8px 20px rgba(255, 112, 67, 0.15);
  transition: transform 0.3s ease;
}
.card:hover {
  transform: translateY(-5px);
}

/* Footer */
footer {
  background: linear-gradient(135deg, #ffb25d 0%, #ff9830 50%, #ff7f1f 100%);
  color: #fff7ef;
  padding: 18px 0;
  text-align: center;
  font-size: 0.95rem;
  font-weight: 500;
  border-top: 1px solid rgba(255, 255, 255, 0.45);
  box-shadow: 0 -8px 24px rgba(216, 82, 18, 0.28);
  letter-spacing: 0.2px;
}

footer .footer-content {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

footer .footer-brand {
  font-weight: 700;
  color: #ffffff;
}

footer .footer-separator {
  color: rgba(255, 255, 255, 0.8);
}

footer a {
  color: #fff6e7;
  text-decoration: none;
  font-weight: 600;
  transition: color 0.2s ease, text-decoration-color 0.2s ease;
}

footer a:hover {
  color: #ffffff;
  text-decoration: underline;
  text-decoration-color: rgba(255, 255, 255, 0.9);
}

/* Animaciones */
@keyframes gradientShift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}
@keyframes float {
  0%,100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}
@keyframes fadeIn {
  0% { opacity: 0; transform: translateY(20px); }
  100% { opacity: 1; transform: translateY(0); }
}

/* Responsive */
@media (max-width: 768px) {
  .animated-title { font-size: 2rem; }
  .subtitle { font-size: 1.1rem; }
  .logo { max-width: 160px; }
}

/* Extra responsive for tablets and mobiles */
@media (max-width: 600px) {
  body {
    font-size: 15px;
    padding: 0;
  }
  .main-container {
    padding: 0.5rem;
  }
  .logo {
    max-width: 120px;
  }
  .animated-title {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
  }
  .subtitle {
    font-size: 1rem;
  }
  .card {
    border-radius: 10px;
    padding: 0.7rem;
    box-shadow: 0 4px 10px rgba(255, 112, 67, 0.12);
  }
  .btn, .btn-primary {
    padding: 0.6rem 1rem;
    font-size: 0.8rem;
    border-radius: 8px;
  }
  .action-buttons {
  margin-top: 0.3rem;   /* controla la cercanía real */
  margin-bottom: 2rem;
}
  footer {
    font-size: 0.8rem;
    padding: 14px 10px;
  }
  .particles {
    height: 100vh;
  }
}

/* Ultra small screens */
@media (max-width: 480px) {
  .main-container {
    padding: 0.2rem;
  }
  .logo {
    max-width: 80px;
  }
  .animated-title {
    font-size: 1rem;
  }
  .subtitle {
    font-size: 0.9rem;
  }
  .card {
    padding: 0.4rem;
  }
  .btn, .btn-primary {
    padding: 0.4rem 0.7rem;
    font-size: 0.7rem;
  }
  .action-buttons {
    margin-top: 0.3rem;   /* controla la cercanía real */
    margin-bottom: 2rem;
  }
  footer {
    font-size: 0.72rem;
    padding: 12px 8px;
  }
}

/*PARTICULAAAAS*/
.particles {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: -1;
}
.particle {
  position: absolute;
  border-radius: 50%;
  opacity: 0.5;
  animation: particleFloat 12s infinite linear;
}
@keyframes particleFloat {
  0%   { transform: translateY(0) rotate(0deg); opacity: 0; }
  10%  { opacity: 1; }
  90%  { opacity: 1; }
  100% { transform: translateY(-100vh) rotate(360deg); opacity: 0; }
}

/* Botón separado de la tarjeta */
.action-buttons {
  margin-top: 0.3rem;   /* controla la cercanía real */
  margin-bottom: 2rem;
}


#particles {
  pointer-events: none; /* Evita bloquear interacciones */
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1; /* Detrás de todo */
}


  .password-strength {
            height: 5px;
            border-radius: 3px;
            margin-top: 5px;
            transition: all 0.3s ease;
        }
        .strength-weak { background-color: #dc3545; width: 25%; }
        .strength-medium { background-color: #ffc107; width: 50%; }
        .strength-strong { background-color: #28a745; width: 75%; }
        .strength-very-strong { background-color: #20c997; width: 100%; }
        .form-feedback { font-size: 0.875rem; margin-top: 0.25rem; }
        .step-indicator {
            display: flex;
            justify-content: center;
            margin-bottom: 2rem;
        }
        .step {
            width: 30px;
            height: 30px;
            border-radius: 50%;
            background-color: #6c757d;
            color: white;
            display: flex;
            align-items: center;
            justify-content: center;
            margin: 0 10px;
            font-size: 0.875rem;
            font-weight: bold;
        }
        .step.active {
            background-color: #198754;
        }
        .step.completed {
            background-color: #20c997;
        }
        .step-line {
            flex: 1;
            height: 2px;
            background-color: #6c757d;
            margin: 0 5px;
            align-self: center;
        }
        .step-line.completed {
            background-color: #20c997;
        }
        .form-step {
            display: none;
        }
        .form-step.active {
            display: block;
            animation: fadeIn 0.5s ease-in;
        }
        @keyframes fadeIn {
            from { opacity: 0; transform: translateY(10px); }
            to { opacity: 1; transform: translateY(0); }
        }
        .terms-text {
            max-height: 150px;
            overflow-y: auto;
            border: 1px solid #dee2e6;
            border-radius: 0.375rem;
            padding: 1rem;
            background-color: #f8f9fa;
            font-size: 0.875rem;
        }

    .password-toggle {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #6c757d;
    cursor: pointer;
    }
    .password-input-group {
        position: relative;
    }


    /* 1. Estilos Base para todos los campos de texto */
input[type="text"],
input[type="email"],
input[type="password"] {
        width: 100%;
        max-width: 100%;
        padding: 12px 15px; /* Relleno interior */
        margin: 8px 0; /* Margen superior e inferior */
        display: inline-block;
        border: 1px solid #ccc; /* Borde gris claro */
        border-radius: 8px; /* Esquinas ligeramente redondeadas */
        box-sizing: border-box; /* Asegura que padding no aumente el ancho total */
        font-size: 16px; /* Tamaño de fuente legible */
        transition: border-color 0.3s, box-shadow 0.3s; /* Transiciones suaves */
    }

    /* 2. Estilos al Enfocarse (Focus) */
    input[type="text"]:focus,
    input[type="email"]:focus,
    input[type="password"]:focus {
        border-color: #1DB954; /* Borde verde, color similar a Spotify */
        box-shadow: 0 0 8px rgba(29, 185, 84, 0.4); /* Sombra suave */
        outline: none; /* Quita el borde de enfoque predeterminado del navegador */
    }

    /* 3. Estilo para el placeholder (texto de marcador) */
    input::placeholder {
        color: #999; /* Color de texto más tenue */
        font-style: italic; /* Texto ligeramente inclinado */
    }
        .password-toggle {
            position: absolute;
            right: 10px;
            top: 50%;
            transform: translateY(-50%);
            background: none;
            border: none;
            color: #6c757d;
            cursor: pointer;
        }
        .password-input-group {
            position: relative;
        }

/* ====== 🎨 MODAL DE INICIAR SESIÓN ======= */
#loginModal .modal-content {
  background: linear-gradient(145deg, #ffffff, #fff8f3);
  border-radius: 20px;
  border: none;
  overflow: hidden;
  box-shadow: 0 15px 35px rgba(255, 112, 67, 0.25);
  animation: modalSlideIn 0.5s ease-out;
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: translateY(-30px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

#loginModal .modal-header {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: white;
  border-bottom: 3px solid var(--primary-dark);
  padding: 1.5rem;
}

#loginModal .modal-header .modal-title {
  font-weight: 700;
  font-size: 1.5rem;
  display: flex;
  align-items: center;
  gap: 10px;
}

#loginModal .modal-header .btn-close {
  filter: invert(1) brightness(2);
  opacity: 0.8;
  transition: all 0.3s ease;
}

#loginModal .modal-header .btn-close:hover {
  opacity: 1;
  transform: rotate(90deg);
}

#loginModal .modal-body {
  padding: 2rem;
  background: linear-gradient(to bottom, #fffaf7, #fff);
}

/* Estilos para inputs del login */
#loginModal input[type="text"],
#loginModal input[type="password"] {
  width: 100%;
  max-width: 100%;
  padding: 14px 45px 14px 15px;
  border: 2px solid #ffccbc;
  border-radius: 12px;
  font-size: 16px;
  transition: all 0.3s ease;
  background: rgba(255, 255, 255, 0.9);
  color: var(--dark);
}

#loginModal input[type="text"]:focus,
#loginModal input[type="password"]:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(255, 112, 67, 0.2);
  background: white;
  transform: translateY(-2px);
}

#loginModal input[type="text"]::placeholder,
#loginModal input[type="password"]::placeholder {
  color: #999;
  font-weight: 400;
}

#loginModal .form-label {
  font-weight: 600;
  color: var(--dark);
  margin-bottom: 8px;
  display: block;
}

/* Grupo de contraseña mejorado */
#loginModal .password-input-group {
  position: relative;
  margin-bottom: 10px;
}

#loginModal .password-toggle {
  position: absolute;
  right: 15px;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  color: #777;
  cursor: pointer;
  padding: 5px;
  transition: color 0.3s ease;
  z-index: 10;
}

#loginModal .password-toggle:hover {
  color: var(--primary);
}

#loginModal .password-toggle i {
  font-size: 1.2rem;
  transition: transform 0.3s ease;
}

#loginModal .password-toggle:hover i {
  transform: scale(1.1);
}

/* Texto de ayuda */
#loginModal .form-text {
  color: #666;
  font-size: 0.85rem;
  margin-top: 5px;
}

#loginModal .link-info {
  color: var(--primary);
  text-decoration: none;
  font-weight: 500;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

#loginModal .link-info:hover {
  color: var(--primary-dark);
  text-decoration: underline;
  transform: translateX(2px);
}

/* Botón de login mejorado */
#loginModal .btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  border: none;
  border-radius: 12px;
  padding: 15px 30px;
  font-size: 1.1rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
  width: 100%;
  position: relative;
  overflow: hidden;
  margin-top: 10px;
}

#loginModal .btn-primary::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s ease;
}

#loginModal .btn-primary:hover::before {
  left: 100%;
}

#loginModal .btn-primary:hover {
  background: linear-gradient(135deg, var(--primary-dark), var(--primary));
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(255, 112, 67, 0.3);
}

#loginModal .btn-primary:active {
  transform: translateY(-1px);
}

/* Mensajes de error/éxito */
#loginMsg {
  min-height: 40px;
  padding: 8px 12px;
  border-radius: 8px;
  margin-top: 15px;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: all 0.3s ease;
}

#loginMsg .text-warning {
  background: rgba(255, 193, 7, 0.1);
  border: 1px solid rgba(255, 193, 7, 0.3);
  padding: 10px;
  border-radius: 8px;
  width: 100%;
}

/* Footer del modal */
#loginModal .modal-footer {
  background: linear-gradient(to top, #fff8f3, #fff);
  border-top: 1px solid rgba(255, 112, 67, 0.1);
  padding: 1.5rem 2rem;
}

/* Animación de iconos */
#loginModal .fa-sign-in-alt {
  animation: iconPulse 2s infinite;
}

@keyframes iconPulse {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.1);
  }
}

/* Efecto de brillo en los bordes */
#loginModal .modal-content::after {
  content: '';
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  background: linear-gradient(45deg, 
    var(--primary), 
    var(--secondary), 
    var(--primary-dark), 
    var(--secondary));
  z-index: -1;
  border-radius: 22px;
  opacity: 0.5;
  filter: blur(5px);
}

/* Responsive para el modal */
@media (max-width: 768px) {
  #loginModal .modal-content {
    margin: 10px;
    border-radius: 15px;
  }
  
  #loginModal .modal-body {
    padding: 1.5rem;
  }
  
  #loginModal input[type="text"],
  #loginModal input[type="password"] {
    padding: 12px 40px 12px 12px;
    font-size: 15px;
  }
  
  #loginModal .btn-primary {
    padding: 12px 20px;
    font-size: 1rem;
  }
}

@media (max-width: 480px) {
  #loginModal .modal-header {
    padding: 1rem;
  }
  
  #loginModal .modal-header .modal-title {
    font-size: 1.3rem;
  }
  
  #loginModal .modal-body {
    padding: 1rem;
  }
}

#registerModal .modal-header {
  background: linear-gradient(135deg, #ff4500, #ff7b29);
  color: white;
  border-bottom: 3px solid #e65100;
  padding: 0.95rem 1.1rem;
}

#registerModal .modal-content {
  background: linear-gradient(145deg, #ffffff, #fff8f3);
  border: 1px solid rgba(255, 140, 0, 0.22);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 16px 40px rgba(255, 112, 67, 0.22);
}

#registerModal .form-control:focus {
  border-color: #ff6d00;
  box-shadow: 0 0 0 3px rgba(255, 109, 0, 0.2);
}

#registerModal .modal-dialog {
  max-width: 560px;
  margin: 0.75rem auto;
}

#registerModal .modal-body {
  padding: 1rem 1.1rem 0.6rem;
}

#registerModal .modal-footer {
  padding: 0.65rem 1.1rem 1rem;
  border-top: 0;
}

#registerModal .modal-title {
  font-weight: 800;
  letter-spacing: 0.2px;
}

/* Compact grid so everything fits without scrolling */
#registerModal .form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 12px;
  align-items: start;
}

#registerModal .form-group,
#registerModal .form-group-wide {
  min-width: 0;
}

#registerModal .form-group-wide {
  grid-column: 1 / -1;
}

#registerModal .form-label {
  font-size: 0.9rem;
  font-weight: 650;
  margin-bottom: 0.25rem;
  color: #5a2500;
}

/* Override global input rules inside this modal */
#registerModal input[type="text"],
#registerModal input[type="email"],
#registerModal input[type="password"],
#registerModal input[type="tel"] {
  width: 100%;
  max-width: 100%;
  margin: 0;
}

#registerModal .form-control {
  padding: 10px 12px;
  border-radius: 12px;
  border: 2px solid rgba(255, 166, 92, 0.55);
  background: rgba(255, 255, 255, 0.95);
  font-size: 0.95rem;
  line-height: 1.15;
}

#registerModal .password-input-group .form-control {
  padding-right: 44px;
}

#registerModal .form-text {
  margin-top: 0.25rem;
  font-size: 0.82rem;
  color: rgba(90, 37, 0, 0.72);
}

#registerModal .form-check {
  margin-top: 0.65rem !important;
}

#registerModal .form-check-label {
  font-size: 0.9rem;
  color: rgba(90, 37, 0, 0.9);
}

#registerModal .btn-close {
  filter: invert(1) brightness(2);
  opacity: 0.85;
}

#registerModal .btn-primary {
  background: linear-gradient(to right, #ff6d00, #ff9100);
  border: none;
  border-radius: 14px;
  font-weight: 750;
  padding: 0.75rem 1rem;
  width: 100%;
}

#registerModal .btn-primary:hover {
  background: linear-gradient(to right, #ff5700, #ff7b00);
}

@media (max-width: 520px) {
  #registerModal .form-grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  #registerModal .modal-dialog {
    max-width: calc(100vw - 18px);
  }
  #registerModal .modal-header {
    padding: 0.85rem 0.95rem;
  }
  #registerModal .modal-body {
    padding: 0.9rem 0.95rem 0.5rem;
  }
  #registerModal .modal-footer {
    padding: 0.55rem 0.95rem 0.9rem;
  }
}

@media (max-height: 720px) {
  #registerModal .modal-body {
    padding-top: 0.85rem;
  }
  #registerModal .form-grid {
    gap: 8px 10px;
  }
  #registerModal .form-control {
    padding: 9px 11px;
  }
}

.btn-close-sm {
    width: 0.8rem;
    height: 0.8rem;
    background-size: 0.8rem;
    padding: 0.2rem;
}

/* ====== JERARQUÍA VISUAL – HERO MÁS GRANDE ======= */

/* Hero ocupa más espacio visual */
.hero-section {
  min-height: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: 1.5rem !important;
  padding-bottom: 0.1rem !important;
}

/* Logo más protagonista */
.hero-section .logo {
  max-width: 260px;
  margin-bottom: 1rem;
}

/* Título más grande */
.hero-section .animated-title {
  font-size: 3.8rem;
  margin-bottom: 1rem;
}

/* Subtítulo más legible */
.hero-section .subtitle {
  font-size: 1.5rem;
  max-width: 600px;
  margin: 0 auto 1rem;
}

/* Botones más grandes */
.action-buttons {
  margin-top: 0.1rem !important;
}

.action-buttons .btn {
  font-size: 1.05rem;
  padding: 1rem 2.2rem;
}
main.container {
  margin-top: 0.5rem !important;
  margin-bottom: 0rem !important;
}

/* =====CONTENEDOR DE INFO MÁS PEQUEÑO===== */

.help-card {
  margin-top: 2.5rem;
  transform: scale(0.95);
  opacity: 0.95;
}

/* ========== RESPONSIVE FINO ========== */

@media (max-width: 992px) {
  .hero-section {
    min-height: auto;
  }

  .hero-section .logo {
    max-width: 220px;
  }

  .hero-section .animated-title {
    font-size: 3rem;
  }

  .hero-section .subtitle {
    font-size: 1.3rem;
  }
}

@media (max-width: 768px) {
  .hero-section .logo {
    max-width: 180px;
  }

  .hero-section .animated-title {
    font-size: 2.4rem;
  }

  .hero-section .subtitle {
    font-size: 1.15rem;
  }

  .action-buttons .btn {
    width: 100%;
    margin-bottom: 0.8rem;
  }

  .help-card {
    transform: scale(1);
  }
}

@media (max-width: 480px) {
  .hero-section .logo {
    max-width: 140px;
  }

  .hero-section .animated-title {
    font-size: 1.9rem;
  }

  .hero-section .subtitle {
    font-size: 1rem;
  }
}

/*PARA 404*/
.subtitle-404 {
  font-size: 1.3rem;
  font-weight: 500;
  letter-spacing: 0.8px;
  line-height: 1.8;
  max-width: 650px;
  margin: 0 auto;
  color: var(--dark);
  opacity: 0.85;
}

.divider-404 {
  width: 80px;
  height: 4px;
  margin: 18px auto 0;
  border-radius: 20px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
}

/* FAQ MODAL */
#faqModal .modal-content {
  background: linear-gradient(180deg, #fffaf5 0%, #fff1e3 100%);
  border: 1px solid rgba(255, 138, 77, 0.35);
  box-shadow: 0 18px 34px rgba(220, 103, 38, 0.2);
}

#faqModal .modal-header {
  background: linear-gradient(135deg, #ff7b29, #ff9f52) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.35);
}

#faqModal .modal-title {
  font-weight: 800;
  letter-spacing: 0.2px;
}

#faqModal .faq-accordion .accordion-item {
  border: 1px solid rgba(255, 123, 41, 0.25);
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 10px;
  background: #fffdf9;
}

#faqModal .faq-accordion .accordion-button {
  background: #fff7ef;
  color: #8f3508;
  font-weight: 700;
  box-shadow: none;
}

#faqModal .faq-accordion .accordion-button:not(.collapsed) {
  background: linear-gradient(135deg, rgba(255, 123, 41, 0.2), rgba(255, 163, 107, 0.22));
  color: #7a2b00;
}

#faqModal .faq-accordion .accordion-button:focus {
  box-shadow: 0 0 0 0.2rem rgba(255, 123, 41, 0.25);
}

#faqModal .faq-accordion .accordion-body {
  color: #7f4a2d;
  line-height: 1.6;
}

#faqModal .modal-footer .btn-secondary {
  background: linear-gradient(135deg, #ff7b29, #ff9548);
  border: none;
  color: #fff;
  font-weight: 700;
}

/* Refines existing login layout without changing structure */
.action-buttons .btn-success {
  background: linear-gradient(135deg, #2eb76f, #1d8e54);
  border: none;
}

.action-buttons .btn-success:hover {
  background: linear-gradient(135deg, #25a363, #177747);
  border: none;
}

.help-card {
  max-width: 100%;
  margin-inline: auto;
}

.help-card .card-body {
  padding: 1.5rem;
}

.feature-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.feature-icon i {
  color: var(--primary);
  font-size: 1.45rem;
}

.feature-icon h5 {
  margin: 0;
  font-weight: 800;
  color: #6b2d0a;
}

#loginModal .modal-dialog {
  max-width: 560px;
  margin: 1rem auto;
}

#loginModal .modal-content {
  background: linear-gradient(145deg, #ffffff, #fff8f3);
}

#loginModal .modal-body {
  padding: 1.6rem 1.6rem 1.2rem;
}

#loginModal .modal-footer {
  padding: 0 1.6rem 1.4rem;
}

#loginModal .form-label {
  font-size: 0.95rem;
}

#loginModal input[type="text"],
#loginModal input[type="password"] {
  min-height: 52px;
  margin: 0;
}

#loginModal .form-text {
  color: rgba(60, 60, 60, 0.78);
}

#loginMsg {
  min-height: 0;
  padding: 0;
}

@media (max-width: 768px) {
  .hero-section {
    padding-top: 1rem !important;
    padding-bottom: 0.35rem !important;
  }

  .action-buttons {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
    margin-bottom: 1.5rem;
  }

  .action-buttons .btn,
  .action-buttons .btn.ms-2 {
    width: 100%;
    margin-left: 0 !important;
    margin-bottom: 0;
  }

  .help-card {
    margin-top: 1.4rem;
  }

  .help-card .card-body {
    padding: 1.2rem;
  }

  #loginModal .modal-dialog {
    max-width: calc(100vw - 1rem);
    margin: 0.5rem auto;
  }

  #loginModal .modal-body {
    padding: 1.2rem 1rem 1rem;
  }

  #loginModal .modal-footer {
    padding: 0 1rem 1rem;
  }
}

@media (max-width: 480px) {
  .hero-section .logo {
    max-width: 130px;
  }

  .hero-section .animated-title {
    font-size: 1.8rem;
  }

  .hero-section .subtitle {
    font-size: 0.98rem;
  }

  .action-buttons .btn {
    font-size: 0.86rem;
    padding: 0.85rem 1rem;
  }

  .feature-icon {
    align-items: flex-start;
  }

  .feature-icon h5 {
    font-size: 1rem;
  }

  #loginModal .modal-header {
    padding: 1rem;
  }

  #loginModal .modal-header .modal-title {
    font-size: 1.15rem;
  }

  #loginModal input[type="text"],
  #loginModal input[type="password"] {
    min-height: 48px;
    font-size: 15px;
  }
}

/* Ondas suaves de fondo, equilibradas con las particulas */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.5;
  background-image:
    url("data:image/svg+xml,%3Csvg width='1700' height='1000' viewBox='0 0 1700 1000' xmlns='http://www.w3.org/2000/svg'%3E%3Cg transform='rotate(-18 850 500)'%3E%3Cpath d='M-180 360 C 130 210 330 505 650 355 C 955 210 1145 480 1440 335 C 1590 260 1705 280 1840 355' fill='none' stroke='%23ff7b29' stroke-width='4' stroke-opacity='0.25'/%3E%3Cpath d='M-210 470 C 95 315 345 610 665 455 C 970 305 1190 575 1475 440 C 1625 370 1740 395 1870 465' fill='none' stroke='%23ffb15f' stroke-width='5' stroke-opacity='0.24'/%3E%3Cpath d='M-235 590 C 80 425 330 725 670 560 C 985 405 1185 700 1490 545 C 1645 465 1770 505 1900 580' fill='none' stroke='%23ffffff' stroke-width='7' stroke-opacity='0.38'/%3E%3Cpath d='M-180 700 C 150 545 375 820 695 675 C 1005 535 1225 790 1510 660 C 1665 590 1775 620 1880 685' fill='none' stroke='%23ff8a4c' stroke-width='3' stroke-opacity='0.18'/%3E%3C/g%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: 72% 10%;
  background-size: 145% 115%;
  animation: waveDrift 16s ease-in-out infinite alternate;
}

.main-container,
footer {
  position: relative;
  z-index: 1;
}

#particles {
  z-index: 0;
  opacity: 0.62;
}

.particle {
  opacity: 0.42;
  filter: blur(0.2px);
}

@keyframes waveDrift {
  from {
    transform: translate3d(2%, -1%, 0) scale(1);
  }
  to {
    transform: translate3d(-3%, 2.5%, 0) scale(1.03);
  }
}

@media (max-width: 768px) {
  body::before {
    opacity: 0.38;
    background-size: 235% 115%;
    background-position: 68% 8%;
  }

  #particles {
    opacity: 0.48;
  }
}

/* Login y recuperación: acabado naranja mas pulido */
#loginModal .modal-dialog,
#forgotPasswordModal .modal-dialog {
  max-width: 500px;
}

#loginModal .modal-content,
#forgotPasswordModal .modal-content {
  border: 1px solid rgba(255, 112, 67, 0.24);
  border-radius: 22px;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(255, 248, 243, 0.98)),
    radial-gradient(circle at top right, rgba(255, 179, 102, 0.22), transparent 42%);
  box-shadow: 0 24px 55px rgba(191, 76, 24, 0.24);
}

#loginModal .modal-header,
#forgotPasswordModal .modal-header {
  background:
    linear-gradient(135deg, #ff6d00 0%, #ff8a2a 50%, #ffae52 100%) !important;
  color: #fff;
  border-bottom: 0;
  padding: 1.25rem 1.5rem;
}

#loginModal .modal-title,
#forgotPasswordModal .modal-title {
  font-weight: 850;
  letter-spacing: 0;
}

#loginModal .modal-body,
#forgotPasswordModal .modal-body {
  padding: 1.6rem 1.5rem 1rem;
  background: transparent;
}

#loginModal .modal-footer,
#forgotPasswordModal .modal-footer {
  border-top: 0;
  padding: 0 1.5rem 1.5rem;
  background: transparent;
}

#loginModal input[type="text"],
#loginModal input[type="password"],
#forgotPasswordModal input[type="email"] {
  min-height: 52px;
  margin: 0;
  border: 2px solid rgba(255, 138, 77, 0.38);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 8px 18px rgba(255, 112, 67, 0.08);
}

#loginModal input[type="text"]:focus,
#loginModal input[type="password"]:focus,
#forgotPasswordModal input[type="email"]:focus {
  border-color: #ff7043;
  box-shadow: 0 0 0 4px rgba(255, 112, 67, 0.18);
  transform: none;
}

#loginModal .form-label,
#forgotPasswordModal .form-label {
  color: #6f2f08;
  font-weight: 750;
}

#forgotPasswordModal p {
  color: rgba(65, 43, 28, 0.82);
  line-height: 1.55;
}

#loginModal .btn-primary,
#forgotPasswordModal .btn-warning {
  background: linear-gradient(135deg, #ff6d00, #ff9a2f);
  border: 0;
  color: #fff;
  border-radius: 14px;
  box-shadow: 0 12px 22px rgba(255, 112, 67, 0.28);
}

#forgotPasswordModal .btn-warning:hover,
#loginModal .btn-primary:hover {
  background: linear-gradient(135deg, #f45f00, #ff7f1f);
}

.btn-danger {
  background: linear-gradient(135deg, #e53935, #c62828);
  border: 0;
  color: #fff;
}

.btn-danger:hover {
  background: linear-gradient(135deg, #d32f2f, #b71c1c);
  color: #fff;
}

/* Recuperación compacta: visible completa sin desplazamiento */
#forgotPasswordModal .modal-dialog {
  max-width: 390px;
  margin: 0.35rem auto;
}

#forgotPasswordModal .modal-content {
  max-height: calc(100vh - 0.7rem);
  border-radius: 18px;
}

#forgotPasswordModal .modal-header {
  padding: 0.72rem 1rem;
}

#forgotPasswordModal .modal-title {
  font-size: 1.05rem;
  line-height: 1.2;
}

#forgotPasswordModal .modal-body {
  padding: 0.75rem 1rem 0.35rem;
}

#forgotPasswordModal .recovery-copy {
  margin-bottom: 0.55rem;
  font-size: 0.88rem;
  line-height: 1.35;
}

#forgotPasswordModal .mb-3 {
  margin-bottom: 0.35rem !important;
}

#forgotPasswordModal .form-label {
  font-size: 0.86rem;
  margin-bottom: 0.25rem;
}

#forgotPasswordModal input[type="email"] {
  min-height: 40px;
  padding: 8px 11px;
  font-size: 0.92rem;
}

#forgotPasswordModal .recovery-msg {
  min-height: 18px;
  margin-top: 0.15rem;
  line-height: 1.25;
}

#forgotPasswordModal .modal-footer {
  display: grid;
  grid-template-columns: 1fr 1.25fr;
  gap: 0.55rem;
  padding: 0.25rem 1rem 0.8rem;
}

#forgotPasswordModal .modal-footer .btn {
  width: 100%;
  min-height: 38px;
  margin: 0;
  padding: 0.5rem 0.75rem;
  border-radius: 10px;
  font-size: 0.84rem;
  white-space: nowrap;
}

@media (max-width: 480px) {
  #forgotPasswordModal .modal-dialog {
    max-width: calc(100vw - 18px);
    margin: 0.35rem auto;
  }

  #forgotPasswordModal .modal-header {
    padding: 0.68rem 0.85rem;
  }

  #forgotPasswordModal .modal-body {
    padding: 0.7rem 0.85rem 0.3rem;
  }

  #forgotPasswordModal .modal-footer {
    grid-template-columns: 1fr;
    gap: 0.45rem;
    padding: 0.25rem 0.85rem 0.7rem;
  }

  #forgotPasswordModal .modal-footer .btn {
    min-height: 36px;
    font-size: 0.82rem;
  }
}

@media (max-height: 560px) {
  #forgotPasswordModal .modal-header {
    padding: 0.55rem 0.85rem;
  }

  #forgotPasswordModal .modal-body {
    padding: 0.55rem 0.85rem 0.2rem;
  }

  #forgotPasswordModal .modal-footer {
    padding: 0.2rem 0.85rem 0.55rem;
  }

  #forgotPasswordModal .recovery-copy {
    margin-bottom: 0.35rem;
  }
}

/* Login moderno */
#loginModal .modal-dialog {
  max-width: 480px;
}

#loginModal .modal-content {
  position: relative;
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: 24px;
  overflow: hidden;
  color: #3b2414;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(255, 247, 240, 0.98)),
    radial-gradient(circle at 85% 8%, rgba(255, 201, 128, 0.55), transparent 32%),
    radial-gradient(circle at 8% 95%, rgba(255, 112, 67, 0.2), transparent 35%);
  box-shadow:
    0 26px 70px rgba(146, 61, 17, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

#loginModal .modal-content::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(120deg, rgba(255, 255, 255, 0.35), transparent 35%),
    repeating-linear-gradient(135deg, rgba(255, 112, 67, 0.08) 0 1px, transparent 1px 14px);
  opacity: 0.55;
}

#loginModal .modal-header {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 112px;
  padding: 1.25rem 1.45rem;
  background:
    linear-gradient(135deg, #ff5f1f 0%, #ff812f 48%, #ffb052 100%) !important;
  border-bottom: 0;
}

#loginModal .modal-header::after {
  content: "";
  position: absolute;
  right: -42px;
  top: -54px;
  width: 150px;
  height: 150px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
}

#loginModal .modal-title {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: #fff;
  font-size: 1.45rem;
  font-weight: 900;
  line-height: 1.15;
}

#loginModal .modal-title i {
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  color: #ff6d00;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 12px 24px rgba(141, 52, 7, 0.22);
  animation: none;
}

#loginModal .btn-close {
  position: relative;
  z-index: 2;
}

#loginModal .modal-body {
  position: relative;
  z-index: 1;
  padding: 1.45rem 1.45rem 0.9rem;
}

#loginModal .mb-3 {
  margin-bottom: 1rem !important;
}

#loginModal .form-label {
  color: #64300e;
  font-size: 0.92rem;
  font-weight: 800;
}

#loginModal input[type="text"],
#loginModal input[type="password"] {
  min-height: 50px;
  border: 1px solid rgba(255, 126, 52, 0.32);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow:
    0 10px 24px rgba(255, 112, 67, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.95);
}

#loginModal input[type="text"]:focus,
#loginModal input[type="password"]:focus {
  border-color: #ff6d00;
  box-shadow:
    0 0 0 4px rgba(255, 109, 0, 0.14),
    0 12px 24px rgba(255, 112, 67, 0.14);
}

#loginModal .form-text {
  color: rgba(83, 53, 33, 0.72);
  font-size: 0.82rem;
}

#loginModal .link-info {
  color: #db5a12;
  font-weight: 800;
}

#loginModal .password-toggle {
  color: rgba(90, 54, 31, 0.72);
}

#loginModal .modal-footer {
  position: relative;
  z-index: 1;
  padding: 0 1.45rem 1.45rem;
}

#loginModal .btn-primary {
  min-height: 50px;
  border-radius: 16px;
  background: linear-gradient(135deg, #ff5f1f, #ff9a2f);
  box-shadow: 0 16px 30px rgba(255, 105, 24, 0.32);
  letter-spacing: 0;
}

#loginModal .btn-primary:hover {
  background: linear-gradient(135deg, #f25514, #ff7f1f);
  box-shadow: 0 18px 34px rgba(255, 105, 24, 0.38);
}

@media (max-width: 480px) {
  #loginModal .modal-header {
    min-height: 92px;
    padding: 1rem;
  }

  #loginModal .modal-title {
    font-size: 1.18rem;
  }

  #loginModal .modal-title i {
    width: 38px;
    height: 38px;
    border-radius: 12px;
  }

  #loginModal .modal-body {
    padding: 1rem 1rem 0.65rem;
  }

  #loginModal .modal-footer {
    padding: 0 1rem 1rem;
  }
}
