:root {
    --primary-bg: #4249CD;
    --secondary-bg: #3035A0;
    --accent-color: #2e35a0;
    --success-color: #28a745;
    --danger-color: #dc3545;
    --text-color: #444;
}

body {
    font-family: 'Poppins', sans-serif;
    background-color: var(--primary-bg);
    /* Degradê suave no fundo */
    background-image: linear-gradient(135deg, var(--primary-bg) 0%, var(--secondary-bg) 100%);
    min-height: 100vh;
    padding-top: 40px;
    padding-bottom: 40px;
    color: var(--text-color);
}

/* --- ESTRUTURA GLOBAL --- */

/* Card Principal (Container Branco) */
.main-card {
    background: #fff;
    border-radius: 15px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.25);
    border: none;
    overflow: hidden;
    width: 100%;
}

/* Cabeçalho com Logo */
.header-section {
    background-color: #f8f9fa;
    padding: 30px 20px;
    border-bottom: 1px solid #eee;
    text-align: center;
}

.header-section img {
    max-width: 100%; 
    width: 350px; 
    height: auto;
    margin-bottom: 15px;
}

/* Cabeçalho com Logo */
.header-section-logo {
    padding: 30px 20px;
    text-align: center;
}

.header-section-logo img {
    max-width: 100%; 
    width: 350px; 
    height: auto;
    margin-bottom: 15px;
}

.header-section h5 {
    color: var(--primary-bg);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin: 0;
    line-height: 1.5;
}

.content-body {
    padding: 40px;
}

/* --- FORMULÁRIOS --- */

.form-label {
    font-weight: 600;
    color: #444;
    font-size: 0.9rem;
    margin-bottom: 8px;
    display: block; /* Garante que o label ocupe a linha inteira */
}

.form-control, .form-select {
    padding: 12px 15px;
    border-radius: 8px;
    border: 1px solid #ced4da;
    background-color: #fcfcfc;
    transition: all 0.3s;
    font-size: 1rem;
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary-bg);
    box-shadow: 0 0 0 0.25rem rgba(66, 73, 205, 0.15);
    background-color: #fff;
    outline: none;
}

/* Divisor de Seções */
.section-divider {
    height: 1px;
    background-color: #eee;
    margin: 30px 0;
    width: 100%;
}

/* --- BOTÕES --- */

.btn-action {
    padding: 12px 30px;
    font-weight: 600;
    border-radius: 50px;
    transition: transform 0.2s, box-shadow 0.2s;
    min-width: 150px;
    border: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px; /* Espaço entre ícone e texto */
}

.btn-action:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.btn-success-custom {
    background-color: var(--success-color);
    color: white;
}
.btn-success-custom:hover {
    background-color: #218838;
    color: white;
}
.btn-success-custom:disabled {
    background-color: #a5d6a7;
    cursor: not-allowed;
}

.btn-cancel-custom {
    background-color: #e0e0e0;
    color: #555;
    text-decoration: none;
}
.btn-cancel-custom:hover {
    background-color: #d0d0d0;
    color: #333;
}

/* Botões do Painel (Dashboard) */
.btn-panel {
    min-width: 220px; /* Um pouco mais largos para o painel */
    margin: 5px;
}

/* --- PAINEL DO CANDIDATO (Novos Estilos) --- */

/* Seção de Boas-vindas */
.welcome-section {
    background-color: #fff;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    margin-bottom: 30px;
    border: 1px solid #f0f0f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap; /* Permite quebrar linha no mobile */
    gap: 15px;
}

.welcome-text h2 {
    font-size: 1.5rem;
    color: var(--primary-bg);
    margin: 0;
    font-weight: 700;
}

/* Cards de Inscrição (Dashboard) */
.card-inscricao {
    background: #fff;
    border-left: 5px solid var(--secondary-bg);
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    margin-bottom: 20px;
    transition: transform 0.2s, box-shadow 0.2s;
    overflow: hidden;
}

.card-inscricao:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.card-inscricao-header {
    padding: 15px 20px;
    border-bottom: 1px solid #eee;
    background-color: #fcfcfc;
}

.card-inscricao-body {
    padding: 20px;
}

/* Badges de Nota */
.score-badge {
    background-color: var(--primary-bg);
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.85rem;
    white-space: nowrap;
}

/* Lista de Histórico */
.history-list {
    font-size: 0.9rem;
    color: #666;
}

.history-item {
    padding: 10px 0;
    border-bottom: 1px dashed #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

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

/* Alertas Customizados */
.alert-custom-info {
    background-color: #eef2ff;
    border-left: 5px solid var(--primary-bg);
    color: #333;
    padding: 15px;
    border-radius: 5px;
}

/* --- RODAPÉ --- */
.footer-section {
    background-color: #f1f1f1;
    padding: 20px;
    text-align: center;
    font-size: 0.85rem;
    color: #666;
    border-top: 1px solid #ddd;
    margin-top: auto;
}

/* --- RESPONSIVIDADE (MOBILE) --- */
@media (max-width: 768px) {
    body {
        padding-top: 20px;
        padding-bottom: 20px;
    }

    .content-body { 
        padding: 20px; 
    }

    .header-section img { 
        width: 80%; 
    }
    .header-section-logo img { 
        width: 80%; 
    }

    /* Ajuste dos botões no mobile */
    .btn-action, .btn-panel { 
        width: 100%; 
        display: flex; 
        margin: 10px 0; 
    }
    
    /* Ajustes específicos do Painel no mobile */
    .welcome-section {
        flex-direction: column;
        text-align: center;
        align-items: stretch;
    }
    
    .card-inscricao-header {
        flex-direction: column;
        align-items: flex-start !important;
        gap: 10px;
    }
    
    .score-badge {
        align-self: flex-start;
    }
    
    /* Input com label à esquerda em telas grandes, mas block em pequenas */
    .input-group {
        width: 100%;
    }
}