/* =====================
   VARIABLES
===================== */
:root {
    --verde_medio: #178369;
    --verde_claro: #3AB394;
    --verde_oscuro: #0B3827;
    --otro_verde: #145c44;;
    --bg-main: #f5f6f7;
    --bg-surface: #ffffff;
    --text-main: #1f2937;
    --text-muted: #6b7280;
    --border: #e5e7eb;
    --shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    --font: "citrine-variable", sans-serif;
    --red-border: #dc2626;
}
/* =====================
   BODY
===================== */
body {
    margin: 0;
    min-height: 100vh;
    background: var(--bg-main);
    font-family: var(--font);
    color: var(--text-main);
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    /* width: 100%; */
}



.main-content {
    display: flex;
    flex-direction: column;
    justify-content: center; /* centra verticalmente la tarjeta */
    align-items: center;
    flex: 1; /* ocupa todo el espacio disponible */
}

.logo {
    margin-bottom: 32px;
    padding: 24px 48px;
    box-sizing: border-box;
}

.logo img {
    height: 40px;
    width: auto;
}

.layout {
    width: 100%;
    max-width: 1200px;
    padding: 32px 48px 64px;
    box-sizing: border-box;
    margin: 0 auto;
}


/* =====================
   FORM CARDS
===================== */

.card {
    background: var(--bg-surface);
    border-radius: 12px;
    box-shadow: var(--shadow);
    padding: 32px 32px 28px;
    margin-bottom: 40px;
    width: 100%;
    box-sizing: border-box;
}

.card-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-main);
    margin-bottom: 24px;
}

.card p {
    font-size: 14px;
    margin-top: 12px;
    text-align: center;

}

.card p.success-message {
    color: var(--verde_medio);
}

.card p.error-message {
    color: var(--red-border);
}

/* =====================
   FOOTER
===================== */
footer {
    margin-top: 40px;
    font-size: 12px;
    color: var(--text-muted);
    text-align: center;
    text-decoration: none;
}

footer a {
    color: var(--text-muted);
    text-decoration: none;
    padding: 7px;
}

footer a:hover {
    text-decoration: underline;
}

/* =====================
   subtitle
===================== */
.section-subtitle {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #8a8a8a;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 6px;
}

.section-title {
    margin: 0;
    font-size: 28px;
    font-weight: 700;
    color: #1f1f1f;
}

@media (max-width: 1024px) {
    .layout {
        padding: 28px 20px;
    }
    .card {
        padding: 28px 20px;
    }
    .section-title {
        font-size: 24px;
    }
    .card p {
        font-size: 13px;
    }
}

@media (max-width: 768px) {
    .logo {
        padding: 16px 20px;
        margin-bottom: 24px;
    }
    .logo img {
        height: 36px;
    }
    .layout {
        padding: 24px 16px;
    }
    .card {
        padding: 24px 16px;
    }
    .section-title {
        font-size: 20px;
    }
    .card p {
        font-size: 12px;
    }
}

/* =====================
   Errors
===================== */
/* Input con error */
.form-group.is-invalid input,
.form-group.is-invalid select,
.form-group.is-invalid textarea {
    border-color: var(--red-border);
}

/* Label con error */
.form-group.is-invalid label {
    color: var(--red-border);
}

/* Mensaje de error */
.form-group .field-error {
    color: var(--red-border);
    font-size: 14px;
    margin-top: 4px;
}


/* =====================
   Barra de admins
===================== */

.admin-topbar {
    height: 60px;
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 24px;
}

.admin-left {
    display: flex;
    align-items: center;
    gap: 30px;
}

.admin-nav a {
    color: black;
    text-decoration: none;
    margin-right: 16px;
    font-weight: 500;
    padding: 6px 10px;
    border-radius: 4px;
    transition: background 0.2s;
    font-size: 15px;
}

.admin-nav a:hover {
    color: black;
    background: rgba(255,255,255,0.15);
}

.admin-nav a.active,
.admin-nav a.current {
    background: rgba(255,255,255,0.2);
    font-weight: 600;
}

/* ensure topbar elements align nicely */
.admin-topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.admin-left {
    display: flex;
    align-items: center;
    gap: 30px;
}

.admin-right {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-left: auto; /* push to the far right */
}

.admin-name {
    font-weight: 600;
    color: black;
    font-size: 14px;
}

.admin-logout {
    background: #ef4444;
    padding: 6px 12px;
    border-radius: 6px;
    color: white;
    text-decoration: none;
    font-size: 14px;
}

.admin-logout:hover {
    background: #dc2626;
}

.admin-logout {
    background: #ef4444;
    padding: 6px 12px;
    border-radius: 6px;
    color: white;
    text-decoration: none;
}

.admin-logout:hover {
    background: #dc2626;
}



/* ======================
    Mensajes
    ===================== */
.messages-container {
    position: fixed;
    top: calc(var(--topbar-height) + 8px);
    left: 50%;
    transform: translateX(-50%);
    z-index: 1300;
    min-width: 280px;
    max-width: 90vw;
    width: max-content;
    pointer-events: none;
}

.message {
    padding: 10px 15px;
    border-radius: 4px;
    margin-bottom: 10px;
    font-weight: 500;
    pointer-events: auto;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
    text-align: center;
}

.message.error {
    background-color: #f8d7da;
    color: #721c24;
}

.message.success {
    background-color: #d1fae5;
    color: #178369;
}

.message.warning {
    background-color: #fef3c7;
    color: #92400e;
}

.message.info {
    background-color: #dbeafe;
    color: #1e40af;
}
@keyframes messageFadeOut {
    0%   { opacity: 1; transform: translateY(0); }
    80%  { opacity: 1; transform: translateY(0); }
    100% { opacity: 0; transform: translateY(-12px); }
}

.message.fade-out {
    animation: messageFadeOut 0.5s ease forwards;
}


/* =====================
   Tabs
===================== */
.tabs {
    display: flex;
    gap: 24px; /* espacio entre tabs */
}

.tab-item {
    padding: 10px 0;
    text-decoration: none;
    color: var(--text-muted);
    font-weight: 500;
}

.tab-item.active {
    color: var(--verde_medio);
    border-bottom: 2px solid var(--verde_medio);
}
