/*
====================================================
 Sistema de Eventos Institucional
 Desenvolvido por: Thalia Justino
 Ano: 2026
====================================================
*/

/* =========================
   RESET BÁSICO
========================= */
* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: 'Inter', Arial, Helvetica, sans-serif;
    background: #f6f7f9;
    color: #1f2937;
}

/* =========================
   HEADER GLOBAL
========================= */
.app-header {
    background: #ffffff;
    border-bottom: 1px solid #e5e7eb;
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 14px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 14px;
}

.logo-wrapper {
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.header-logo {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.header-title {
    font-size: 18px;
    font-weight: 700;
    color: #7a0c0d;
}

/* NAV */
.header-nav {
    display: flex;
    align-items: center;
    gap: 18px;
}

.header-nav a {
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    color: #374151;
    position: relative;
}

.header-nav a:hover {
    color: #7a0c0d;
}

.header-nav a::after {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 0;
    width: 0;
    height: 2px;
    background: #7a0c0d;
    transition: width .2s ease;
}

.header-nav a:hover::after {
    width: 100%;
}

.nav-highlight {
    font-weight: 600;
    color: #7a0c0d;
}

/* =========================
   CONTAINER
========================= */
.container {
    max-width: 1100px;
    margin: 40px auto;
    padding: 0 20px;
}

/* =========================
   TÍTULOS
========================= */
h1 {
    font-size: 26px;
    color: #7a0c0d;
    margin-bottom: 20px;
}

h2 {
    font-size: 20px;
    color: #7a0c0d;
    margin-bottom: 16px;
}

/* =========================
   CARDS
========================= */
.card {
    background: #ffffff;
    border-radius: 10px;
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: 0 6px 18px rgba(0,0,0,.06);
}

/* Separação visual no admin */
.section-title {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 1px solid #e5e7eb;
}

/* =========================
   BOTÕES
========================= */
.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px 18px;
    border-radius: 6px;
    background: #7a0c0d;
    color: #ffffff;
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: all .2s ease;
}

.button:hover {
    background: #5e090a;
    transform: translateY(-1px);
}

.button.secondary {
    background: #e5e7eb;
    color: #111827;
}

.button.secondary:hover {
    background: #d1d5db;
}

/* Botões menores no admin */
.admin-btn {
    padding: 6px 12px;
    font-size: 13px;
    border-radius: 4px;
}

/* =========================
   FORMULÁRIOS
========================= */
input,
textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    margin-bottom: 14px;
    font-size: 14px;
}

textarea {
    resize: vertical;
}

/* =========================
   LISTAS
========================= */
ul,
ol {
    padding-left: 0;
    list-style: none;
}

.list-item {
    padding: 16px 0;
    border-bottom: 1px solid #e5e7eb;
}

.list-item:last-child {
    border-bottom: none;
}

.list-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 6px;
    color: #7a0c0d;
}

.list-meta {
    font-size: 13px;
    color: #6b7280;
}

/* =========================
   STATUS
========================= */
.status-ok {
    color: #065f46;
    background: #d1fae5;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
}

.status-no {
    color: #7a0c0d;
    background: #fef2f2;
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 12px;
}

/* =========================
   LOGIN
========================= */
.login-box {
    max-width: 380px;
    margin: 80px auto;
    background: #ffffff;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 6px 18px rgba(0,0,0,.1);
    text-align: center;
}

/* =========================
   ADMIN - EVENTOS
========================= */
.admin-evento-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    flex-wrap: wrap;
}

.admin-evento-left {
    flex: 1;
}

.admin-evento-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    white-space: nowrap;
}

.admin-checkbox {
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 6px;
}

/* =========================
   MOBILE
========================= */

.menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 26px;
    cursor: pointer;
    color: #7a0c0d;
}

/* MOBILE BREAKPOINT */
@media (max-width: 768px) {

    .header-container {
        flex-wrap: wrap;
    }

    .menu-toggle {
        display: block;
    }

    .header-nav {
        width: 100%;
        display: none;
        flex-direction: column;
        gap: 12px;
        margin-top: 12px;
        padding-top: 12px;
        border-top: 1px solid #e5e7eb;
    }

    .header-nav.active {
        display: flex;
    }

    .container {
        margin: 20px auto;
        padding: 0 16px;
    }

    .admin-evento-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .admin-evento-actions {
        margin-top: 10px;
        flex-wrap: wrap;
    }

    .button {
        width: 100%;
        justify-content: center;
    }
}

/* =========================
   ADMIN – EVENTOS EXPANSÍVEIS
========================= */

.admin-event {
    border-radius: 8px;
    overflow: hidden;
}

.admin-event-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    padding: 16px;
    background: #f9fafb;
}

.admin-event-header:hover {
    background: #f3f4f6;
}

.admin-event-header i {
    transition: transform .2s ease;
}

.admin-event.active .admin-event-header i {
    transform: rotate(180deg);
}

.admin-event-actions {
    display: none;
    padding: 16px;
    background: #ffffff;
    border-top: 1px solid #e5e7eb;
    gap: 12px;
    flex-wrap: wrap;
}

.admin-event.active .admin-event-actions {
    display: flex;
    align-items: center;
}

/* Ação individual */
.admin-action {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Switch bonito (visibilidade) */
.switch {
    position: relative;
    display: inline-block;
    width: 42px;
    height: 22px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    background-color: #d1d5db;
    border-radius: 999px;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    transition: .3s;
}

.slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 2px;
    bottom: 2px;
    background-color: white;
    border-radius: 50%;
    transition: .3s;
}

.switch input:checked + .slider {
    background-color: #7a0c0d;
}

.switch input:checked + .slider:before {
    transform: translateX(20px);
}
