body {
    font-family: 'Inter', sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}
:root {
    --primary-magenta: #D0006F;
    --dark-gray: #374151;
    --light-gray: #f3f4f6;
}
.bg-primary-magenta { background-color: var(--primary-magenta); }
.text-primary-magenta { color: var(--primary-magenta); }
.border-primary-magenta { border-color: var(--primary-magenta); }

::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: #f1f1f1; }
::-webkit-scrollbar-thumb { background: #888; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #555; }

#login-view, #restricted-view, .modal, #loading-overlay {
    display: none;
}
.modal.active { display: flex; }

.post-image {
    display: block;
    max-width: 100%;
    height: auto;
    cursor: pointer;
    transition: opacity: 0.2s ease-in-out;
}

.post-image:hover {
    opacity: 0.85;
}

/* --- ESTILOS DO CALENDÁRIO DE EVENTOS --- */
#calendario-container {
    background-color: white;
    padding: 1.5rem;
    border-radius: 0.5rem;
    box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
}

.calendario-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.calendario-header h3 {
    font-size: 1.25rem;
    font-weight: 700;
}

.calendario-nav button {
    background-color: #f3f4f6;
    border-radius: 9999px;
    padding: 0.5rem;
    line-height: 1;
}

.calendario-nav button:hover {
    background-color: #e5e7eb;
}

.calendario-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 4px;
}

.calendario-dias-semana {
    font-weight: 600;
    text-align: center;
    font-size: 0.875rem;
    color: #6b7280;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #e5e7eb;
}

.dia-calendario {
    border: 1px solid #f3f4f6;
    padding: 0.5rem;
    text-align: right;
    min-height: 120px;
    position: relative;
    font-size: 0.875rem;
}

.dia-calendario.outro-mes {
    color: #d1d5db;
    background-color: #f9fafb;
}

.dia-com-evento .numero-dia {
    color: var(--primary-magenta);
    font-weight: 700;
}

.titulo-evento {
    display: block;
    font-size: 0.75rem;
    font-weight: 500;
    background-color: #fce7f3;
    color: #9d174d;
    padding: 2px 6px;
    border-radius: 4px;
    margin-top: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: left;
    cursor: pointer;
}

.titulo-evento:hover {
    background-color: #fbcfe8;
}

.categoria-indicacao {
    font-size: 0.75rem;
    font-weight: 500;
    padding: 0.25rem 0.5rem;
    border-radius: 9999px;
    background-color: #e0e7ff;
    color: #3730a3;
    white-space: nowrap;
    flex-shrink: 0;
}

/* --- ESTILOS DOS MODAIS CUSTOMIZADOS --- */
#custom-alert-modal.active #custom-alert-box,
#custom-confirm-modal.active #custom-confirm-box {
    transform: translateY(0);
    opacity: 1;
}

.prioridade-normal { background-color: white; }
.prioridade-relevante { background-color: #dcfce7; }
.prioridade-atencao { background-color: #fef9c3; }
.prioridade-urgente { 
    background-color: #fee2e2;
}


/* --- ESTILOS PARA RESPONSIVIDADE --- */
.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    transform: translateX(-100%);
    transition: transform 0.3s ease-in-out;
    z-index: 40;
}
.sidebar.sidebar-open {
    transform: translateX(0);
}

/* --- ALTERAÇÃO AQUI: Garante que tabelas complexas rolem em vez de quebrar o layout --- */
.table-responsive-wrapper {
    overflow-x: auto;
}
/* A regra acima é aplicada no JS. Esta aqui é um fallback para os elementos já existentes. */
.overflow-x-auto {
    -webkit-overflow-scrolling: touch;
}

@media (min-width: 1024px) { /* lg */
    .sidebar {
        position: static;
        transform: translateX(0);
    }
    main {
        flex: 1;
    }
    #mobile-overlay {
        display: none !important;
    }
}


@media print {
    body {
        background-color: white !important;
    }
    .no-print {
        display: none !important;
    }
    main {
        width: 100%;
        height: auto;
        overflow: visible;
    }
    #app-content {
        padding: 0 !important;
    }
    #relatorio-resultado {
        box-shadow: none !important;
        border: none !important;
    }
    table {
        width: 100%;
        font-size: 10pt !important;
    }
    tr, td, th {
        page-break-inside: avoid;
    }
}