html {
    font-size: 14px;
}

@media (min-width: 768px) {
    html {
        font-size: 16px;
    }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
    box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
    position: relative;
    min-height: 100%;
}

body {
    margin-bottom: 60px;
}
/* site.css */ /* Banner superior (el que ya estaba) */

.banner-stats {
    background-color: #0C4251;
    padding: 1rem 0;
    color: white;
}

    .banner-stats h4 {
        color: #6bbdda;
        font-weight: 300;
    }

    .banner-stats h2 {
        color: #f1c864;
    }
/* T tulo principal */

.main-title {
    color: #0C4251;
    font-weight: 700;
    margin-bottom: 1.5rem;
    margin-top: 1.5rem;
}

    .main-title span {
        color: #f1c864;
    }

.subtitle {
    color: #6bbdda;
    font-size: 1.25rem;
}
/* Tarjetas */

.card-custom {
    border-left: 5px solid;
    border-radius: 0.375rem;
    box-shadow: 0 0.125rem 0.25rem rgb(0 0 0 / 0.075);
}

.card-users {
    border-color: #f1c864 !important;
}

.card-courses {
    border-color: #6bbdda !important;
}

.card-notifications {
    border-color: #0C4251 !important;
}

.card-analytics {
    border-color: #6bbdda !important;
}

.card-title {
    color: #0C4251;
}

.badge-users {
    background-color: #6bbdda;
}

.badge-courses {
    background-color: #f1c864;
    color: #0C4251;
}

.card {
    background-color: #fff;
    border-radius: 0.5rem;
}

.form-box {
    background-color: #f8f9fa;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    max-width: 600px;
    margin: auto;
}
/* Botones */

.btn-primary-custom {
    background-color: #0C4251;
    color: white;
    border: none;
}

    .btn-primary-custom:hover {
        background-color: #093641;
    }

.btn-primary-custom {
    background-color: #0C4251;
    color: white;
}

.btn-secondary-custom {
    background-color: #f1c864;
    color: #0C4251;
}

.btn-info-custom {
    background-color: #6bbdda;
    color: white;
}

.btn-edit {
    background-color: #f1c864;
    color: #0C4251;
}

.btn-see {
    background-color: #6bbdda;
    color: #0C4251;
}

.btn-yellow {
    background-color: #f1c864;
    color: #0C4251;
    border: none;
}

    .btn-yellow:hover {
        background-color: #0C4251;
        color: #f1c864;
    }

.btn-hardblue {
    background-color: #0C4251;
    color: white;
    border: none;
}

    .btn-hardblue:hover {
        background-color: #6bbdda;
        color: white;
    }

.btn-lightblue {
    background-color: #6bbdda;
    color: white;
    border: none;
}

    .btn-lightblue:hover {
        background-color: #f1c864;
        color: white;
    }

/Divisor/ .dropdown-divider {
    background-color: #6bbdda;
}
/*/Cards/ .card-zoom {     transition: transform 0.3s ease, box-shadow 0.3s ease; }  .card-zoom:hover {     transform: scale(1.06);*/ /* Agrandar un 3% */ /*box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);*/ /* sombra m s fuerte al hacer hover */ /*z-index: 2; }  .card-zoom2 {     transition: transform 0.3s ease, box-shadow 0.3s ease; }      .card-zoom2:hover {         transform: scale(1.02);*/ /* Agrandar un 3% */ /*box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);*/ /* sombra m s fuerte al hacer hover */ /*z-index: 2;     }  .card-zoom3 {     transition: transform 0.3s ease; }      .card-zoom3:hover {         transform: scale(1.06);*/ /* Agrandar un 3% */ /*z-index: 2;     }  .card-zoom4 {     transition: transform 0.3s ease; }      .card-zoom4:hover {         transform: scale(1.02);*/ /* Agrandar un 3% */ /*z-index: 2;     }  .card-zoom5 {     transition: transform 0.3s ease; }      .card-zoom5:hover {         transform: scale(1.01);*/ /* Agrandar un 3% */ /*z-index: 2;     }*/ /*.form-expand-check {     transition: transform 0.3s ease-in-out; }      .form-expand-check.expanded {         transform: scale(1.02);*/ /* o el efecto que quieras aplicar */ /*}*/

/Text/ a.nav-link {
    color: #f1c864;
    text-decoration: none;
}

a.nav-link:hover {
    color: #d1ac4f; /* color m s oscuro o el que quieras */
}
/*.nav-link.dropdown-toggle {     position: relative;     padding-right: 1.5em;  }      .nav-link.dropdown-toggle::after {         content: "";         position: absolute;         top: 50%;         right: 0.75em;         width: 0;         height: 0;         border-left: 0.3em solid transparent;         border-right: 0.3em solid transparent;         border-top: 0.4em solid currentColor;         transform: translateY(-50%) rotate(0deg);         transition: transform 0.3s ease;     }  .nav-item.dropdown.show > .nav-link.dropdown-toggle::after {     transform: translateY(-50%) rotate(180deg); }*/

.caret-icon {
    display: inline-block; /* necesario para que transform funcione bien */
    transition: transform 0.3s ease;
    margin-left: 0.3em;
}

.navbar-nav .dropdown-toggle::after {
    display: none;
}

.container-fluid.py-3 {
    border-radius: 0 0 15px 15px;
}
/* --- Estilos para el Header Responsive --- */ /* Estilo para los enlaces del menú móvil */

.mobile-nav-link {
    color: #6bbdda !important; /* Usamos tu color celeste */
    padding: 0.5rem 0; /* Espaciado vertical */
    font-size: 1.1rem;
}

    .mobile-nav-link:hover { /* Tu color dorado al pasar el mouse */
        color: #f1c864 !important;
    }
/* Estilo para los divisores en el menú móvil */

.mobile-nav-divider {
    border: 0;
    border-top: 1px solid;
    color: #f1c864 !important;
    margin: 0.5rem 0;
}
/* --- Estilos para el Menú Offcanvas --- */

.offcanvas {
    background-color: #0C4251; /* Tu color de fondo principal */
    color: white;
}

.offcanvas-header {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.offcanvas-title {
    color: #f1c864; /* Tu color dorado para el título */
}
/* Ajustes para los enlaces y divisores dentro del offcanvas */

.offcanvas-body .mobile-nav-link {
    font-size: 1.2rem;
    padding: 0.75rem 0;
}

.offcanvas-body .mobile-nav-divider {
    margin: 0.75rem 0;
}

.offcanvas-header .btn-close {
    margin-left: auto; /* Empuja el botón 'X' a la derecha */
    padding-right: 0.5rem; /* Pequeño ajuste de espaciado */
}
/* --- Estilos para la página de Login --- */ /* 1. Estilos Base (para pantallas grandes/PC) */

.login-page {
    display: flex;
    min-height: 100vh;
    width: 100%;
    overflow: hidden;
}

.login-branding {
    flex: 0 0 42%;
    background-color: #0C4251;
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 2rem;
    text-align: center;
    transition: all 0.3s ease-in-out;
}

    .login-branding img {
        width: 200px;
        margin-bottom: 1.5rem;
    }

    .login-branding .main-title {
        display: flex;
        justify-content: center;
        align-items: center;
        flex-wrap: wrap;
        gap: 0.5em;
        color: white; /* <--- ¡LA LÍNEA CLAVE! */
    }

.brand-name {
    color: #f1c864; /* Tu color amarillo/dorado */
}

.login-form {
    flex: 1;
    background-color: #f4f7f6;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem;
    transition: all 0.3s ease-in-out;
}
/* ...el resto de tu CSS sigue igual... */

.form-box {
    width: 100%;
    max-width: 450px;
    background-color: #ffffff;
    padding: 2.5rem;
    border-radius: 10px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}
/* 2. Media Query para Pantallas Medianas (Tablets, Laptops pequeños) */

@media (max-width: 1199px) {
    .login-page {
        flex-direction: column; /* Apilamos los paneles verticalmente */
    }

    .login-branding {
        flex: 0 0 auto; /* Hacemos el panel superior más compacto */
        padding: 1.5rem 0; /* Eliminamos la altura mínima para que se ajuste al contenido */
        min-height: auto;
    }
        /* Ocultamos los textos grandes en esta vista */

        .login-branding .main-title, .login-branding .subtitle {
            display: none;
        }
        /* Hacemos el logo más pequeño para esta vista */

        .login-branding img {
            width: 120px;
            margin-bottom: 0; /* Quitamos el margen inferior porque ya no hay texto */
        }

    .login-form {
        flex: 1; /* Eliminamos la altura mínima para que el centrado sea más natural */
        min-height: auto;
    }
}
/* 3. Media Query para Pantallas Pequeñas (Móviles) */

@media (max-width: 767px) { /* Hacemos visible el panel de la marca, pero súper compacto */

    .login-branding {
        display: flex; /* Lo hacemos visible de nuevo */
        padding: 1rem 0; /* Menos padding vertical para que sea más delgado */
        min-height: auto; /* La altura se ajusta al contenido */
    }
        /* Ocultamos los textos grandes (esta regla se hereda de la media query de tablet, pero la repetimos por claridad) */

        .login-branding .main-title, .login-branding .subtitle {
            display: none;
        }
        /* Hacemos el logo aún más pequeño en móviles */

        .login-branding img {
            width: 90px;
            margin-bottom: 0;
        }
    /* Ajustamos la posición del formulario */

    .login-form { /* Centramos el formulario en el espacio restante */
        align-items: center;
        padding: 2rem 1rem; /* Añadimos padding horizontal */
    }

    .form-box {
        box-shadow: none;
        padding: 1.5rem;
        width: 100%; /* El formulario ocupa todo el ancho disponible */
    }
}
/* --- Estilos para el Banner de Estadísticas --- */ /* ESTILOS PARA ESCRITORIO (por defecto) */

.stats-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    text-align: center;
    color: white;
}

.stats-main, .stats-item {
    padding: 0 10px; /* Espaciado interno */
}

    .stats-main h2 {
        color: #f1c864;
    }

    .stats-main h4 {
        color: #6bbdda;
    }

.stats-grid {
    display: flex;
    flex: 4; /* Ocupa más espacio */
    justify-content: space-around;
}

.stats-item {
    flex: 1; /* Cada item ocupa el mismo espacio */
}

    .stats-item h2 {
        color: #f1c864;
    }

    .stats-item h4 {
        color: #6bbdda;
    }
/* ESTILOS PARA MÓVIL (se activan en pantallas pequeñas) */

@media (max-width: 767px) {
    .stats-main {
        flex-basis: 40%;
        border-right: 1px solid rgba(255, 255, 255, 0.2);
        padding-right: 1rem;
        margin-right: 1rem;
    }

        .stats-main h2 {
            font-size: 3rem;
            font-weight: 700;
        }

        .stats-main h4 {
            font-size: 0.9rem;
        }

    .stats-grid {
        flex: 1;
        flex-wrap: wrap; /* Permite la cuadrícula 2x2 */
    }

    .stats-item {
        flex-basis: 45%; /* Dos items por fila */
        padding: 0.5rem 0;
    }

        .stats-item h4 {
            font-size: 0.75rem;
        }

        .stats-item h2 {
            font-size: 1.4rem;
        }
}
/* --- Estilos para hacer la tabla de Usuarios Responsive --- */ /* Se aplica solo en pantallas de 767px o menos (móviles) */

@media (max-width: 767px) { /* Ocultamos los encabezados de la tabla en móvil */

    #usersTable thead {
        display: none;
    }
    /* Cada fila <tr> se convierte en una "tarjeta" */

    #usersTable tr.user-row {
        display: block;
        margin-bottom: 1.5rem;
        border: 1px solid #ddd;
        border-radius: 0.5rem;
        box-shadow: 0 2px 4px rgba(0,0,0,0.05);
        padding: 1rem;
    }
    /* Cada celda <td> se pone una debajo de la otra */

    #usersTable td {
        display: block;
        text-align: right; /* Alineamos el contenido a la derecha */
        padding-left: 50%; /* Dejamos espacio para la etiqueta */
        position: relative;
        border: none;
    }
        /* Usamos un pseudo-elemento para crear las etiquetas (Nombre:, Correo:, etc.) */

        #usersTable td::before {
            content: attr(data-label); /* Tomamos el texto de un atributo que añadiremos */
            position: absolute;
            left: 0.5rem;
            width: 45%;
            padding-right: 10px;
            font-weight: bold;
            text-align: left; /* Alineamos la etiqueta a la izquierda */
        }
        /* La columna de acciones la centramos */

        #usersTable td:last-child {
            text-align: center;
            padding-left: 0;
        }

            #usersTable td:last-child::before {
                display: none; /* No queremos etiqueta para las acciones */
            }
}
/* --- Estilos para convertir Tablas Genéricas a Tarjetas en Móvil --- */

@media (max-width: 767px) { /* Seleccionamos cualquier tabla con la clase .table-to-cards */

    .table-to-cards thead {
        display: none;
    }

    .table-to-cards tr {
        display: block;
        margin-bottom: 1.5rem;
        border: 1px solid #ddd;
        border-radius: 0.5rem;
        box-shadow: 0 2px 4px rgba(0,0,0,0.05);
        padding: 1rem;
    }

    .table-to-cards td {
        display: block;
        text-align: right;
        padding-left: 50%;
        position: relative;
        border: none;
    }

        .table-to-cards td::before {
            content: attr(data-label); /* Usamos el atributo data-label como etiqueta */
            position: absolute;
            left: 0.5rem;
            width: 45%;
            padding-right: 10px;
            font-weight: bold;
            text-align: left;
        }
        /* La última celda (acciones) se formatea diferente */

        .table-to-cards td:last-child {
            text-align: center;
            padding-left: 0;
        }

            .table-to-cards td:last-child::before {
                display: none; /* No queremos etiqueta para las acciones */
            }
}
/* --- Estilos Globales para Tablas --- */

.table {
    width: 100%;
    table-layout: auto; /* Libre en escritorio */
}

    .table td, .table th {
        word-wrap: break-word;
        overflow-wrap: break-word;
    }
/* --- Estilos para Botones con Íconos Responsives --- */ /* Por defecto (escritorio), mostramos el texto */

.btn .icon-only {
    display: none;
}

.btn .text-with-icon {
    display: inline;
}
/* --- Media Query para Pantallas Pequeñas (móviles) --- */

@media (max-width: 767px) { /* Tabla más compacta */

    .table {
        table-layout: fixed; /* SOLO en móvil */
        font-size: 0.85rem;
    }
        /* Botones más pequeños */

        .table .btn-sm {
            padding: 0.2rem 0.4rem;
            font-size: 0.75rem;
        }
    /* Texto oculto en botones, mostramos solo íconos */

    .btn .text-with-icon {
        display: none !important;
    }

    .btn .icon-only {
        display: inline !important;
    }
    /* Acciones sin ancho fijo */

    .table .actions-column {
        width: auto !important;
        min-width: auto !important;
    }
}




/* Espacio extra al final del menú offcanvas */
.offcanvas-body {
    padding-bottom: 6rem; /* Ajusta: 4rem ≈ 2 enlaces de menú */
}


    /* Color único para "Cerrar sesión" */
    .offcanvas-body .mobile-nav-link.logout-link {
        color: #ea2833 !important;
        font-weight: 600;
    }

        /* Hover más claro */
        .offcanvas-body .mobile-nav-link.logout-link:hover {
            color: #f0666e !important;
        }

        /* (opcional) separa un pelín el ícono */
        .offcanvas-body .mobile-nav-link.logout-link i {
            margin-left: .35rem;
        }

