body {
    background: #fff;
    min-height: 100vh;
    color: #000;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    transition: background 0.3s, color 0.3s;
}

.navbar {
    background-color: rgba(255,255,255,0.95);
    -webkit-backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0,0,0,0.1);
    transition: background 0.3s, border-bottom 0.3s;
}

.navbar-brand {
    color: #000 !important;
    font-weight: bold;
    letter-spacing: 1px;
    font-size: 1.5rem;
    transition: color 0.3s;
}

.btn-custom, .btn-success {
    background-color: #fff !important;
    color: #000 !important;
    border: 1px solid #000;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-custom:hover, .btn-success:hover {
    background-color: #000 !important;
    color: #fff !important;
    border: 1px solid #000;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.hero-section {
    padding: 100px 0;
    position: relative;
    overflow: hidden;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    color: #000;
    margin-bottom: 1.5rem;
    transition: color 0.3s;
}

.hero-subtitle {
    font-size: 1.4rem;
    color: #555;
    margin-bottom: 2rem;
    line-height: 1.6;
    transition: color 0.3s;
}

.feature-card {
    background: rgba(255,255,255,0.8);
    border-radius: 1rem;
    padding: 2rem;
    height: 100%;
    border: 1px solid #000;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    color: #000;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    border-color: #000;
}

.feature-icon {
    width: 60px;
    height: 60px;
    background: #000;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
    color: #fff;
    transition: background 0.3s, color 0.3s;
}

.feature-title {
    color: #000;
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1rem;
    transition: color 0.3s;
}

.feature-description {
    color: #555;
    line-height: 1.6;
    transition: color 0.3s;
}

.stats-section {
    background: rgba(255,255,255,0.6);
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
    padding: 4rem 0;
    margin: 4rem 0;
    border-radius: 2rem;
    border: 1px solid #000;
    transition: background 0.3s, border 0.3s;
}

.stat-item {
    text-align: center;
    margin-bottom: 2rem;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: #000;
    display: block;
    transition: color 0.3s;
}

.stat-label {
    color: #555;
    font-size: 1.1rem;
    margin-top: 0.5rem;
    transition: color 0.3s;
}

.cta-section {
    padding: 4rem 0;
    text-align: center;
}

.cta-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #000;
    margin-bottom: 1rem;
    transition: color 0.3s;
}

.cta-subtitle {
    font-size: 1.2rem;
    color: #555;
    margin-bottom: 2rem;
    transition: color 0.3s;
}

.login-form {
    background: rgba(255,255,255,0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px); /* Soporte para Safari */
    border-radius: 1rem;
    padding: 2rem;
    border: 1px solid #000;
    max-width: 400px;
    margin: 0 auto;
    color: #000;
    transition: background 0.3s, border 0.3s, color 0.3s;
}

.form-control {
    background: rgba(255,255,255,0.8);
    border: 1px solid #000;
    color: #000;
    padding: 12px 16px;
    border-radius: 8px;
    transition: background 0.3s, border 0.3s, color 0.3s;
}

.form-control:focus {
    background: rgba(255,255,255,0.9);
    border-color: #000;
    box-shadow: 0 0 0 0.2rem rgba(0,0,0,0.15);
    color: #000;
}

.form-control::placeholder {
    color: #888;
    transition: color 0.3s;
}

.form-label {
    color: #555;
    font-weight: 500;
    transition: color 0.3s;
}

.alert {
    background: rgba(0,0,0,0.05);
    border: 1px solid #000;
    color: #000;
    border-radius: 8px;
    transition: background 0.3s, border 0.3s, color 0.3s;
}

.alert-success {
    background: rgba(0,0,0,0.1);
    border: 1px solid #000;
    color: #000;
}

.floating-shapes {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    overflow: hidden;
    z-index: -1;
}

.shape {
    position: absolute;
    opacity: 0.1;
    animation: float 20s infinite linear;
}

.shape i {
    color: #000 !important;
    transition: color 0.3s;
}

.shape:nth-child(1) { top: 20%; left: 10%; animation-delay: 0s; }
.shape:nth-child(2) { top: 60%; right: 15%; animation-delay: 7s; }
.shape:nth-child(3) { bottom: 20%; left: 20%; animation-delay: 14s; }

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    25% { transform: translateY(-20px) rotate(90deg); }
    50% { transform: translateY(-10px) rotate(180deg); }
    75% { transform: translateY(-30px) rotate(270deg); }
}

@media (max-width: 768px) {
    .hero-title { font-size: 2.5rem; }
    .hero-subtitle { font-size: 1.1rem; }
    .feature-card { margin-bottom: 2rem; }
}

.user-info {
    background: rgba(255,255,255,0.8);
    backdrop-filter: blur(20px);
    border-radius: 1rem;
    padding: 1.5rem;
    border: 1px solid #000;
    margin-bottom: 2rem;
    color: #000;
    transition: background 0.3s, border 0.3s, color 0.3s;
}

.welcome-text {
    color: #000;
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    transition: color 0.3s;
}

.user-email {
    color: #555;
    font-size: 0.9rem;
    transition: color 0.3s;
}

/* Barra superior (navbar) bien ordenada y alineada */
.navbar-nav {
    display: flex;
    align-items: center;
    gap: 0.5rem; /* Espacio uniforme entre botones */
}

.navbar-text {
    margin-right: 1rem;
}

.navbar-nav .btn {
    margin-left: 0 !important;
    margin-right: 0 !important;
}

.navbar-nav .btn + .btn {
    margin-left: 0.5rem !important;
}

#toggleThemeBtn i {
    font-size: 1.2rem;
    vertical-align: middle;
}

/* --- MODO OSCURO --- */
body.dark-mode {
    background: #000 !important;
    color: #fff !important;
}
body.dark-mode .navbar {
    background-color: rgba(0,0,0,0.95) !important;
    border-bottom: 1px solid rgba(255,255,255,0.1) !important;
}
body.dark-mode .navbar-brand,
body.dark-mode .feature-title,
body.dark-mode .hero-title,
body.dark-mode .cta-title,
body.dark-mode .stat-number {
    color: #fff !important;
}
body.dark-mode .feature-card,
body.dark-mode .login-form,
body.dark-mode .user-info,
body.dark-mode .stats-section {
    background: rgba(0,0,0,0.8) !important;
    border: 1px solid #fff !important;
    color: #fff !important;
}
body.dark-mode .btn-custom, 
body.dark-mode .btn-success {
    background-color: #000 !important;
    color: #fff !important;
    border: 1px solid #fff !important;
}
body.dark-mode .btn-custom:hover, 
body.dark-mode .btn-success:hover {
    background-color: #fff !important;
    color: #000 !important;
    border: 1px solid #fff !important;
}
body.dark-mode .form-control {
    background: rgba(0,0,0,0.8) !important;
    border: 1px solid #fff !important;
    color: #fff !important;
}
body.dark-mode .form-control::placeholder {
    color: #ccc !important;
}
body.dark-mode .alert {
    background: rgba(255,255,255,0.05) !important;
    border: 1px solid #fff !important;
    color: #fff !important;
}
body.dark-mode .feature-icon {
    background: #fff !important;
    color: #000 !important;
}
body.dark-mode .shape i {
    color: #fff !important;
}

/* Color gris para el email del usuario en la navbar */
#userInfo #userEmail.navbar-text {
    color: #888 !important;
}

/* Botón logout en blanco y negro en modo oscuro */
body.dark-mode #userInfo #logoutBtn.btn.btn-outline-dark {
    color: #fff !important;
    border-color: #fff !important;
    background: #000 !important;
}

/* Al pasar el mouse: fondo blanco y texto negro */
body.dark-mode #userInfo #logoutBtn.btn.btn-outline-dark:hover {
    background: #fff !important;
    color: #000 !important;
    border-color: #fff !important;
}

/* Botón de modo oscuro (toggleThemeBtn) blanco y negro en modo oscuro */
body.dark-mode .navbar-nav .btn.btn-outline-dark.ms-2,
body.dark-mode #toggleThemeBtn.btn.btn-outline-dark.ms-2 {
    color: #fff !important;
    border-color: #fff !important;
    background: #000 !important;
}

/* Al pasar el mouse: fondo blanco y texto negro */
body.dark-mode .navbar-nav .btn.btn-outline-dark.ms-2:hover,
body.dark-mode #toggleThemeBtn.btn.btn-outline-dark.ms-2:hover {
    background: #fff !important;
    color: #000 !important;
    border-color: #fff !important;
}

/* Menú lateral (sideMenu) oscuro en modo dark, normal en modo claro */
body.dark-mode #sideMenu.offcanvas {
    background: #18181b !important;
    color: #fff !important;
    border-left: 1.5px solid #444 !important;
}

body.dark-mode #sideMenu.offcanvas .offcanvas-header,
body.dark-mode #sideMenu.offcanvas .offcanvas-body {
    background: transparent !important;
    color: #fff !important;
}

/* Opcional: enlaces y botones dentro del menú lateral en modo oscuro */
body.dark-mode #sideMenu.offcanvas a,
body.dark-mode #sideMenu.offcanvas .btn {
    color: #fff !important;
    border-color: #fff !important;
}

/* Agrega esto al final del archivo para personalizar la imagen de portada */
/* Haz la imagen de portada más grande */
.portada-img {
    border-radius: 0;
    box-shadow: none;
    max-width: 900px;
    width: 100%;
    height: auto;
}