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

:root {
    --primary-700: #162542;
    --primary-600: #203359;
    --primary-500: #294170;
    --primary-400: #3f5b8f;
    --primary-300: #5575af;
}

body {
    margin: 0;
    font-family: "DM Sans", "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
    color: white;
    text-align: center;
    /* background: linear-gradient(180deg, #001a54, #011554, #001147); */
    background-color: #011234;
    min-height: 100vh;
}

/* Faixa de imagem no topo */
.top-banner {
    min-height: 37vh;
    background-image: linear-gradient(rgba(1, 18, 52, 0.8), rgba(1, 18, 52, 0.4)), url(../images/background-censo.png);
    background-repeat: no-repeat;
    background-position: center center;
    background-size: cover;

    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    padding-top: 20px;
    padding-bottom: 20px;
}

.logo {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.logo img {
    height: 80px;
    max-width: 90%;
    margin-bottom: 5px;
    /* distância da logo pro título */
}

.logo h1 {
    font-size: 28px;
    margin: 0;
    /* remove margens padrão */
    margin-bottom: 3px;
    /* distância pro subtítulo */
}

.logo .subtitle {
    font-size: 16px;
    font-weight: normal;
    margin: 0;
    /* remove margens extras */
}

.container {
    max-width: 900px;
    margin: -80px auto 20px;
    /* Move para cima para sobrepor o banner */
    background: #001543;
    border-radius: 24px;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.35);
    overflow: hidden;
    color: #e5e7eb;
    /* Set default text color for content inside the container */
    text-align: left;
    /* Reset text-align from body */
    position: relative;
    /* Garante que o container fique sobre o banner */
}

.main-content {
    padding: 30px;
    background-color: #000c24;
}

.agenda-container {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.month-group {
    /* background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%); */
    /* background-color: var(--primary-700); */
    padding: 0px 25px 0px 20px;
    border-radius: 15px;
    /* border: 1px solid rgba(255, 255, 255, 0.06); */
}

.month-title-wrapper {
    /* background-color: rgba(255, 255, 255, 0.05); */
    /* Cor de fundo para o nome do mês */
    padding: 16px 22px;
    border-radius: 12px;
    margin-bottom: 20px;
    /* Espaçamento abaixo do título do mês */
    text-align: left;
    /* Centraliza o texto dentro do wrapper */
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.4);
    /* Sombra para destaque */
}

.month-group h2 {
    color: white;
    /* Cor do texto do mês */
    margin: 0;
    /* Remove margens padrão do h2 para que o padding do wrapper funcione */
    font-size: 1.6em;
    text-transform: uppercase;
    border-bottom: none;
    /* Remove a borda inferior que estava no h2 */
    padding-bottom: 0;
    /* Remove o padding inferior que estava no h2 */
}

.event-card {
    /* background: #545454; */
    /* background: linear-gradient(135deg, var(--primary-600) 0%, var(--primary-700) 100%); */
    border-radius: 14px;
    padding: 18px 20px;
    margin-bottom: 15px;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.12);
    display: flex;
    gap: 20px;
    align-items: center;
}

.event-card:hover {
    box-shadow: 0 14px 36px rgba(0, 0, 0, 0.36);
    transform: translateY(-1px);
    transition: box-shadow .2s ease, transform .1s ease;
}

.event-date {
    text-align: center;
    color: white;
    flex-shrink: 0;
    min-width: 72px;
}

.event-date .day {
    font-size: 2em;
    font-weight: 700;
    word-break: break-word;
    /* Quebra a linha em textos longos para não estourar o layout */
    line-height: 1.1;
    /* Ajusta o espaçamento entre linhas caso o texto quebre */
}

.event-date .month {
    font-size: 1em;
    font-weight: 600;
    text-transform: uppercase;
}

.event-details h3 {
    font-size: 1.3em;
    color: white;
    margin-bottom: 6px;
    letter-spacing: 0.2px;
}

.event-details p {
    color: #d9e1eb;
}

.event-details p {
    color: white;
    font-size: 1em;
}

.no-events {
    text-align: center;
    padding: 40px;
    color: white;
    font-style: italic;
    font-size: 1.2em;
}

.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.loading-content {
    background: white;
    padding: 30px;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.loading {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid var(--primary-500);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}