:root {
    --primary-lime: #00FF7F;
    --primary-cyan: #00CED1;
    --primary-violet: #6A5ACD;
    --primary-lavender: #7B68EE;
    --dark-bg: #1e1b2e;
    
    --glass-bg: rgba(18, 16, 29, 0.75);
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-shadow: 0 12px 32px 0 rgba(0, 0, 0, 0.4);
    
    --text-dark: #F0F0F0;
    --text-muted: #A0AAB8;
    --text-light: #FFFFFF;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
    color: var(--text-dark);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    position: relative;
}

/* Fundo */
.bg-layer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-image: url('background.jpeg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: -2;
}

.bg-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: radial-gradient(circle at 50% 50%, rgba(15, 12, 27, 0.65) 0%, rgba(10, 8, 18, 0.9) 100%);
    z-index: -1;
}

/* Vidro Glassmorphism */
.card-glass {
    background: var(--glass-bg);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border: 1px solid var(--glass-border);
    border-radius: 18px;
    box-shadow: var(--glass-shadow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* Cabeçalho */
.page-header {
    background: linear-gradient(135deg, var(--primary-violet), var(--primary-lavender));
    color: var(--text-light);
    padding: 16px 24px;
    box-shadow: 0 4px 20px rgba(106, 90, 205, 0.3);
}

.header-content {
    max-width: 1300px;
    margin: 0 auto;
    display: flex;
    align-items: baseline;
    gap: 12px;
}

.brand-text {
    font-size: 1.8rem;
    font-weight: 800;
    letter-spacing: 4px;
}

.brand-subtext {
    font-size: 0.8rem;
    font-weight: 600;
    opacity: 0.85;
    letter-spacing: 2px;
}

/* Core Layout */
.main-wrapper {
    flex: 1;
    display: flex;
    justify-content: center;
    padding: 24px;
}

.app-layout {
    display: grid;
    grid-template-columns: 390px 1fr 300px; /* Alarga bastante a coluna da esquerda (390px) */
    gap: 24px;
    width: 100%;
    max-width: 1420px; /* Aumenta levemente a largura máxima geral para acomodar bem */
}
}

/* Sidebar Esquerda */
.sidebar-left {
    padding: 24px 18px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.brand-box {
    background: transparent !important; /* Remove o fundo preto sólido */
    border: none !important;
    padding: 10px 0 !important;
    margin-bottom: 24px !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
}

.brand-logo {
    width: 100% !important;
    max-width: 280px !important; /* Logotipo bem maior e legível */
    height: auto !important;
    object-fit: contain !important;
    filter: drop-shadow(0 4px 12px rgba(0,0,0,0.5)); /* Sombra suave para destacar no vidro */
}

.nav-menu {
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: 100%;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: var(--text-light);
    border: 1px solid rgba(0,0,0,0.05);
    border-radius: 12px;
    color: var(--text-dark);
    font-weight: 600;
    font-size: 0.92rem;
    cursor: pointer;
    transition: all 0.25s ease;
}

.nav-item i {
    color: var(--primary-violet);
    font-size: 1.1rem;
    transition: color 0.25s ease;
}

.nav-item:hover {
    background: var(--primary-cyan);
    color: var(--text-light);
    transform: translateX(4px);
    box-shadow: 0 4px 12px rgba(0, 206, 209, 0.3);
}

.nav-item:hover i {
    color: var(--text-light);
}

/* Carrossel */
.main-content {
    display: flex;
    flex-direction: column;
}

.carousel-card {
    position: relative;
    overflow: hidden;
    padding: 12px;
}

.carousel-window {
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: 14px;
    overflow: hidden;
    position: relative;
}

.carousel-track {
    display: flex;
    width: 100%;
    height: 100%;
    transition: transform 0.5s cubic-bezier(0.25, 1, 0.5, 1);
}

.carousel-slide {
    min-width: 100%;
    height: 100%;
    position: relative;
    flex-shrink: 0;
}

.carousel-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.slide-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 32px 24px 20px 24px;
    background: linear-gradient(180deg, transparent 0%, rgba(15, 12, 35, 0.88) 100%);
    color: var(--text-light);
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
}

.slide-badge {
    background: var(--primary-cyan);
    color: var(--text-light);
    font-size: 0.75rem;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 20px;
    text-transform: uppercase;
}

.slide-overlay h3 {
    font-size: 1.4rem;
    font-weight: 700;
}

.slide-overlay p {
    font-size: 0.9rem;
    opacity: 0.9;
    max-width: 90%;
}

.btn-link {
    color: var(--primary-lime);
    text-decoration: none;
    font-weight: 700;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 4px;
    transition: gap 0.2s;
}

.btn-link:hover {
    gap: 10px;
}

/* Controles do Carrossel */
.carousel-control {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.85);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.1rem;
    color: var(--text-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
    transition: all 0.2s;
    z-index: 10;
}

.carousel-control:hover {
    background: var(--primary-lime);
    color: var(--text-dark);
}

.carousel-control.prev { left: 24px; }
.carousel-control.next { right: 24px; }

.carousel-dots {
    position: absolute;
    bottom: 24px;
    right: 28px;
    display: flex;
    gap: 8px;
    z-index: 10;
}

.dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255,255,255,0.4);
    cursor: pointer;
    transition: all 0.3s;
}

.dot.active {
    background: var(--primary-lime);
    width: 24px;
    border-radius: 10px;
}

/* Sidebar Direita */
.sidebar-right {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.widget-box {
    padding: 20px;
}

.widget-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
    color: var(--primary-violet);
}

.widget-header i {
    font-size: 1.2rem;
}

.widget-header h3 {
    font-size: 1.05rem;
    font-weight: 700;
}

.widget-desc {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 14px;
}

/* Formulários */
.input-group {
    position: relative;
    margin-bottom: 12px;
}

.input-group i {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 0.9rem;
}

.input-group input {
    background: rgba(25, 22, 40, 0.8);
    color: var(--text-light);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.input-group input::placeholder {
    color: var(--text-muted);
}

.input-group input:focus {
    border-color: var(--primary-cyan);
}

/* Botões */
.btn-primary, .btn-secondary {
    width: 100%;
    padding: 12px;
    border: none;
    border-radius: 10px;
    font-weight: 700;
    font-size: 0.9rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.25s ease;
}

.btn-primary {
    background: var(--primary-cyan);
    color: var(--text-light);
    box-shadow: 0 4px 12px rgba(0, 206, 209, 0.25);
}

.btn-primary:hover {
    background: var(--primary-lime);
    color: var(--text-dark);
}

.btn-secondary {
    background: var(--primary-violet);
    color: var(--text-light);
}

.btn-secondary:hover {
    background: var(--primary-lavender);
}

.forgot-link {
    display: block;
    text-align: right;
    font-size: 0.78rem;
    color: var(--text-muted);
    margin-top: 8px;
    text-decoration: none;
}

.forgot-link:hover {
    color: var(--primary-violet);
}

/* Lista de Enquetes */
.poll-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.poll-list li a {
    background: rgba(25, 22, 40, 0.6);
    color: var(--text-light);
}

.poll-list li a i {
    font-size: 0.7rem;
    color: var(--primary-cyan);
}

.poll-list li a:hover {
    background: rgba(35, 30, 55, 0.9);
    color: var(--primary-cyan);
}

/* Modal */
.modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(6px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal-backdrop.active {
    display: flex;
}

.modal-card {
    background: #161326;
    color: var(--text-light);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

@keyframes modalUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.modal-close {
   color: var(--text-muted);
}

/* Toast */
.toast-notification {
    position: fixed;
    bottom: 24px;
    right: 24px;
    background: var(--dark-bg);
    color: var(--text-light);
    padding: 12px 20px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.9rem;
    box-shadow: 0 8px 20px rgba(0,0,0,0.2);
    transform: translateY(100px);
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 2000;
}

.toast-notification.show {
    transform: translateY(0);
    opacity: 1;
}

.toast-notification i {
    color: var(--primary-lime);
}

/* Rodapé */
.page-footer {
    background: var(--dark-bg);
    color: var(--text-light);
    text-align: center;
    padding: 16px;
    font-size: 0.85rem;
    opacity: 0.95;
    margin-top: auto;
}

/* Responsividade */
@media (max-width: 1024px) {
    .app-layout {
        grid-template-columns: 1fr;
    }

    .sidebar-left {
        flex-direction: row;
        justify-content: space-between;
    }

    .brand-box {
        width: auto;
        margin-bottom: 0;
    }

    .nav-menu {
        flex-direction: row;
        width: auto;
    }
}

@media (max-width: 640px) {
    .sidebar-left {
        flex-direction: column;
    }
    
    .nav-menu {
        flex-direction: column;
        width: 100%;
    }

    .slide-overlay h3 {
        font-size: 1.1rem;
    }

    .carousel-control {
        display: none;
    }
}

/* --- TRATAMENTO DO LOGO --- */
.brand-box {
    background: #000000 !important;
    border: 1px solid rgba(106, 90, 205, 0.4) !important;
    padding: 12px !important;
    border-radius: 14px !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    overflow: hidden !important;
}

.brand-logo {
    max-width: 100% !important;
    height: auto !important;
    max-height: 120px !important;
    object-fit: contain !important;
    mix-blend-mode: screen !important; /* Remove o fundo preto escuro em telas escuras */
}

/* --- BOTÕES DO MENU (CONTRASTE) --- */
.nav-item {
    background: rgba(255, 255, 255, 0.08) !important;
    border: 1px solid rgba(255, 255, 255, 0.15) !important;
    color: #FFFFFF !important;
    font-weight: 600 !important;
}

.nav-item i {
    color: var(--primary-cyan) !important;
}

.nav-item:hover {
    background: var(--primary-cyan) !important;
    color: #0F0C1B !important;
}

.nav-item:hover i {
    color: #0F0C1B !important;
}

/* --- INPUTS DE LOGIN --- */
.input-group {
    position: relative !important;
    margin-bottom: 12px !important;
}

.input-group i {
    position: absolute !important;
    left: 14px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    color: var(--primary-cyan) !important;
    z-index: 2 !important;
}

.input-group input {
    background: rgba(255, 255, 255, 0.1) !important;
    color: #FFFFFF !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    padding-left: 40px !important;
}

.input-group input::placeholder {
    color: rgba(255, 255, 255, 0.6) !important;
}

/* --- AJUSTE NO CARROSSEL --- */
.carousel-window {
    min-height: 380px !important;
    background: #0f0c1b !important;
}

.carousel-slide img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    display: block !important;
}

/* --- CORREÇÃO DA LEGENDA E ITENS DO MODAL --- */
.modal-card p {
    color: var(--text-muted) !important;
}

.modal-card ul li {
    background: rgba(255, 255, 255, 0.08) !important; /* Fundo escuro translúcido para os itens */
    color: #FFFFFF !important;                          /* Texto branco visível */
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    padding: 10px 14px !important;
    border-radius: 8px !important;
    margin-bottom: 8px !important;
}

.modal-card ul li i {
    color: var(--primary-cyan) !important;              /* Ícones em tom ciano para destacar */
}

/* --- CORREÇÃO GERAL PARA AVISOS E CAIXAS INTERNAS NOS MODAIS --- */
.modal-card div[style*="background"],
.modal-card div[style*="border-left"] {
    background: rgba(0, 206, 209, 0.1) !important; /* Fundo ciano escuro e translúcido */
    color: #FFFFFF !important;                     /* Texto branco bem visível */
    border: 1px solid rgba(0, 206, 209, 0.3) !important;
    border-left: 4px solid var(--primary-cyan) !important;
    padding: 14px !important;
    border-radius: 8px !important;
}