/* ==========================================================================
    Estilos de la página de Login (index.php)
    ========================================================================== */

/* Importación de fuentes de Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;600;700&display=swap');

/* Base y tipografía */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
}

/* ESTILOS DEL MENU SUPERIOR */
.top-menu {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    padding: 20px 30px;
    z-index: 10;
    display: flex;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 10px;
}

.top-menu a {
    color: #000;
    font-size: 13px;
    text-decoration: none;
    transition: color 0.3s;
    -webkit-user-select: none; /* Para Chrome, Safari, Opera */
    -moz-user-select: none; /* Para Firefox */
    -ms-user-select: none; /* Para Internet Explorer/Edge */
    user-select: none; /* Estándar */
}

.top-menu a:hover {
    color: #3498db;
}

.top-menu .separator {
    color: #000;
    font-size: 13px;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

.login-page {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    min-height: 100vh;
    background: url('../img/backgroundlogin.jpg') no-repeat center center fixed;
    background-size: cover;
}

.login-strip {
    background-color: rgba(0, 0, 0, 0.7);
    height: 100vh;
    width: 380px;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    position: relative;
}

.login-container {
    padding: 30px 25px;
    width: 90%;
    background-color: #f4f7f6;
    border-radius: 8px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
    text-align: center;
    margin-top: 160px;
}

.login-container h2 {
    margin-bottom: 15px;
    font-size: 24px;
    font-weight: 600;
    color: #2c3e50;
}

.divider {
    border-top: 2px solid #a0a0a0;
    margin: 20px 0 15px;
}

.sub-heading {
    font-size: 14px;
    color: #34495e;
    margin-bottom: 35px;
    text-align: center;
}

.form-group {
    margin-bottom: 12px;
    text-align: left;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 400;
    color: #34495e;
    font-size: 14px;
}

.form-group input {
    width: 100%;
    padding: 10px;
    border: 1px solid #c0c0c0;
    border-radius: 5px;
    font-size: 14px;
    transition: border-color 0.3s;
}

.form-group input:focus {
    border-color: #3498db;
    outline: none;
}

.password-container {
    position: relative;
}

.password-container input {
    padding-right: 40px;
}

.password-container i {
    position: absolute;
    top: 50%;
    right: 12px;
    transform: translateY(-50%);
    cursor: pointer;
    color: #7f8c8d;
    transition: color 0.3s;
    font-size: 16px;
}

.password-container i:hover {
    color: #2c3e50;
}

.forgot-password-container {
    display: flex;
    justify-content: center;
    margin-top: 10px;
    margin-bottom: 20px;
}

.forgot-password-link {
    font-size: 13px;
    color: #7f8c8d;
    text-decoration: none;
    transition: color 0.3s;
}

.forgot-password-link:hover {
    color: #3498db;
    text-decoration: underline;
}


.honeypot {
    display: none;
    visibility: hidden;
    position: absolute;
    top: -9999px;
    left: -9999px;
    height: 1px;
    width: 1px;
    overflow: hidden;
}

.btn {
    width: 100%;
    padding: 12px;
    background-color: #3498db;
    color: #fff;
    border: none;
    border-radius: 5px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s;
    margin-top: 15px;
}

.btn:hover {
    background-color: #2980b9;
}

.login-footer {
    font-size: 12px;
    color: #ecf0f1;
    text-align: center;
    position: absolute;
    bottom: 30px;
    width: 100%;
}

@media (max-width: 768px) {
    .login-page {
        justify-content: center;
    }
    .login-strip {
        width: 100%;
        height: auto;
        padding: 50px 20px;
        margin: 0;
        position: static;
    }
    .login-container {
        width: 90%;
    }
    .login-footer {
        position: static;
        margin-top: 30px;
        color: #7f8c8d;
    }
    .top-menu {
        top: 0;
        padding: 10px 20px;
        font-size: 12px;
        gap: 8px;
    }
}


/* ==========================================================================
    Estilos del Dashboard (dashboard.php)
    ========================================================================== */

:root {
    --primary-color: #2c3e50;
    --secondary-color: #34495e;
    --accent-color: #3498db;
    --text-color: #ecf0f1;
    --background-color: #f4f7f6;
    --card-background: #ffffff;
    --border-color: #e0e4e7;
    --shadow-color: rgba(0, 0, 0, 0.08);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Poppins', sans-serif;
    background-color: var(--background-color);
    color: var(--primary-color);
    line-height: 1.6;
}

.dashboard-wrapper {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    width: 200px;
    background-color: var(--primary-color);
    color: var(--text-color);
    display: flex;
    flex-direction: column;
    padding: 1.6rem 0;
    box-shadow: 2px 0 8px var(--shadow-color);
}

.sidebar .logo {
    text-align: center;
    margin-bottom: 1.6rem;
    padding: 0 1.2rem;
}

.sidebar .logo h3 {
    font-size: 1.2rem;
    font-weight: 700;
}

.sidebar .nav-menu {
    flex-grow: 1;
}

.sidebar .nav-menu ul {
    list-style: none;
}

.sidebar .nav-menu ul li a {
    display: flex;
    align-items: center;
    padding: 0.8rem 1.2rem;
    color: var(--text-color);
    text-decoration: none;
    transition: background-color 0.3s, color 0.3s;
    font-size: 0.9rem;
}

.sidebar .nav-menu ul li a i {
    font-size: 1rem;
    margin-right: 0.8rem;
    width: 16px;
}

.sidebar .nav-menu ul li a:hover,
.sidebar .nav-menu ul li a.active {
    background-color: var(--secondary-color);
    color: var(--accent-color);
}

.sidebar .nav-menu ul li a:hover span,
.sidebar .nav-menu ul li a.active span {
    color: var(--accent-color);
}

.main-content {
    flex-grow: 1;
    padding: 1.6rem;
    display: flex;
    flex-direction: column;
}

.main-header {
    background-color: var(--card-background);
    padding: 1.2rem 1.6rem;
    margin-bottom: 1.6rem;
    border-radius: 6px;
    box-shadow: 0 1.6px 4px var(--shadow-color);
}

.main-header .header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.main-header h1 {
    font-size: 1.4rem;
    font-weight: 600;
    color: var(--primary-color);
}

.main-header .user-profile {
    display: flex;
    align-items: center;
    font-size: 0.9rem;
    color: var(--secondary-color);
}

.main-header .user-profile i {
    font-size: 1.2rem;
    margin-right: 0.4rem;
}

.main-dashboard-area {
    flex-grow: 1;
}

.card-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(224px, 1fr));
    gap: 1.6rem;
}

.card {
    background-color: var(--card-background);
    padding: 1.6rem;
    border-radius: 6px;
    box-shadow: 0 3.2px 9.6px var(--shadow-color);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    align-items: center;
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4.8px 12px rgba(0, 0, 0, 0.12);
}

.card .card-icon {
    font-size: 2rem;
    color: var(--accent-color);
    margin-right: 1.2rem;
    background-color: rgba(52, 152, 219, 0.1);
    padding: 0.8rem;
    border-radius: 50%;
}

.card-info h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.4rem;
}

.card-info p {
    font-size: 0.8rem;
    color: #7f8c8d;
}

@media (max-width: 768px) {
    .login-page {
        justify-content: center;
    }
    .login-strip {
        width: 100%;
        height: auto;
        padding: 50px 20px;
        margin: 0;
        position: static;
    }
    .login-container {
        width: 90%;
    }
    .login-footer {
        position: static;
        margin-top: 30px;
        color: #7f8c8d;
    }
    .top-menu {
        top: 0;
        padding: 10px 20px;
        font-size: 12px;
        gap: 8px;
    }
}


/* ==========================================================================
    Estilos del Mensaje Flotante (Toast)
    ========================================================================== */

.toast-message {
    visibility: hidden;
    background-color: rgba(51, 51, 51, 0.9);
    color: #fff;
    text-align: center;
    border-radius: 12px;
    padding: 20px 30px;
    position: fixed;
    z-index: 1000;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    opacity: 0;
    transition: visibility 0s 0.5s, opacity 0.5s ease-in-out;
    font-size: 1.0em;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.toast-message.show {
    visibility: visible;
    opacity: 1;
    transition-delay: 0s;
}