/*
report_votos.css - Estilos elegantes para a página de relatório de votos
*/
:root {
    --primary: #CC0000;
    --primary-dark: #8B0000;
    --primary-light: #FFE6E6;
    --accent: #FFD700;
    --text-dark: #333333;
    --text-light: #FFFFFF;
    --border-radius: 12px;
    --box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    --transition: all 0.3s ease;
    --card-bg: #FFFFFF;
    --secondary-bg: #F9F9F9;
    --border-color: #EEEEEE;
    --success: #28a745;
    --info: #17a2b8;
}

body {
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, Roboto, Oxygen, Ubuntu, 'Helvetica Neue', sans-serif;
    color: var(--text-dark);
    background: linear-gradient(135deg, #f8f9fa 0%, var(--primary-light) 100%);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    line-height: 1.6;
}

/* Navbar */
.navbar {
    background-color: var(--primary);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    margin-bottom: 0;
}

.navbar-brand {
    font-weight: 700;
    color: var(--text-light);
    display: flex;
    align-items: center;
    gap: 10px;
}

.navbar-brand i {
    font-size: 1.5rem;
}

/* Page Container */
.page-container {
    flex: 1;
    padding: 3rem 0;
    background: url('data:image/svg+xml;utf8,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><path d="M0 0h100v100H0z" fill="%23f8f9fa"/><path d="M100 0H0v100h100V0zM10 10h80v80H10V10z" fill="%23fff" fill-opacity="0.5"/></svg>') repeat;
}

/* Main Card */
.main-card {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    overflow: hidden;
    margin-bottom: 2rem;
    border: none;
    transition: var(--transition);
    position: relative;
}

.header-stripe {
    height: 5px;
    background: linear-gradient(90deg, var(--primary) 0%, var(--accent) 100%);
}

.card-header {
    padding: 1.5rem 2rem;
    border-bottom: 1px solid var(--border-color);
    background: var(--card-bg);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.section-title {
    font-size: 1.6rem;
    font-weight: 600;
    color: var(--primary);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.section-title i {
    font-size: 1.8rem;
}

.card-body {
    padding: 2rem !important;
}

/* Select Election Section */
.select-container {
    margin-bottom: 2rem;
}

.select-election-card {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    border: 1px solid var(--border-color);
}

.select-header {
    background: linear-gradient(135deg, #f5f7fa 0%, #eef2f7 100%);
    padding: 1.2rem 2rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    gap: 15px;
}

.select-header i {
    font-size: 1.5rem;
    color: var(--primary);
}

.select-header h2 {
    font-size: 1.2rem;
    font-weight: 600;
    margin: 0;
    color: var(--text-dark);
}

.select-body {
    padding: 2rem;
}

.select-instruction {
    text-align: center;
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    color: #555;
}

.current-election {
    text-align: center;
    margin-bottom: 1.5rem;
}

.current-election span {
    display: block;
    font-size: 0.9rem;
    color: #777;
    margin-bottom: 0.5rem;
}

.current-election h3 {
    font-size: 1.4rem;
    font-weight: 600;
    margin: 0;
    color: var(--primary);
}

.election-form {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.election-form .form-group {
    flex: 1;
    min-width: 250px;
}

.election-select {
    padding: 0.75rem 1.25rem;
    border: 1px solid #ced4da;
    border-radius: 8px;
    font-size: 1rem;
    transition: var(--transition);
    height: auto;
    background-size: 16px 12px;
}

.election-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 0.25rem rgba(204, 0, 0, 0.25);
}

.election-btn {
    padding: 0.75rem 1.5rem;
    background: var(--primary);
    border-color: var(--primary);
    border-radius: 8px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
    min-width: 220px;
}

.election-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(204, 0, 0, 0.2);
}

/* Statistics */
.stats-row {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 2rem;
}

.stat-card {
    flex: 1;
    min-width: 200px;
    background: var(--card-bg);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    text-align: center;
    border-left: 5px solid var(--primary);
    transition: var(--transition);
    opacity: 0;
    transform: translateY(20px);
}

.stat-card.animated {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.stat-card.utilized {
    border-left-color: var(--success);
}

.stat-card.percentage {
    border-left-color: var(--info);
}

.stat-icon {
    font-size: 2.2rem;
    margin-bottom: 1rem;
    color: var(--primary);
}

.utilized .stat-icon {
    color: var(--success);
}

.percentage .stat-icon {
    color: var(--info);
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--text-dark);
}

.stat-label {
    color: #666;
    font-size: 1rem;
    font-weight: 500;
}

/* Results Section */
.results-container {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    border: 1px solid var(--border-color);
    margin-bottom: 2rem;
}

.results-header {
    background: linear-gradient(135deg, #f5f7fa 0%, #eef2f7 100%);
    padding: 1.2rem 2rem;
    border-bottom: 1px solid var(--border-color);
}

.results-header h2 {
    font-size: 1.2rem;
    font-weight: 600;
    margin: 0;
    color: var(--text-dark);
    display: flex;
    align-items: center;
    gap: 10px;
}

.results-header h2 i {
    color: var(--primary);
}

/* Table */
.table-container {
    padding: 1.5rem;
}

.custom-table {
    width: 100%;
    background: var(--card-bg);
    border-collapse: separate;
    border-spacing: 0;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid var(--border-color);
}

.custom-table th {
    background: #f8f9fa;
    padding: 1.2rem 1.5rem;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
    color: #555;
    border-bottom: 2px solid #eaecef;
}

.custom-table td {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
    vertical-align: middle;
}

.custom-table tr:last-child td {
    border-bottom: none;
}

.custom-table tr.first-place {
    background-color: rgba(255, 215, 0, 0.05);
}

.custom-table tr:hover td {
    background-color: rgba(204, 0, 0, 0.02);
}

.votes-badge {
    background: rgba(204, 0, 0, 0.1);
    color: var(--primary);
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-weight: 600;
    display: inline-block;
    transition: var(--transition);
}

.votes-badge:hover {
    transform: scale(1.05);
    background: rgba(204, 0, 0, 0.15);
}

.progress-wrapper {
    display: flex;
    align-items: center;
    gap: 15px;
}

.progress {
    flex: 1;
    height: 8px;
    border-radius: 4px;
    background-color: #f0f0f0;
}

.progress-bar {
    background-color: var(--primary);
    border-radius: 4px;
}

.progress-text {
    font-weight: 600;
    min-width: 45px;
    text-align: right;
}

/* Actions */
.actions-container {
    display: flex;
    gap: 15px;
    padding: 1rem 1.5rem 1.5rem;
    justify-content: center;
}

.btn {
    padding: 0.6rem 1.5rem;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
    border-radius: 8px;
}

.btn-outline-primary {
    color: var(--primary);
    border-color: var(--primary);
}

.btn-outline-primary:hover {
    background-color: var(--primary);
    border-color: var(--primary);
    color: white;
    box-shadow: 0 4px 10px rgba(204, 0, 0, 0.2);
}

.btn-outline-success:hover {
    box-shadow: 0 4px 10px rgba(25, 135, 84, 0.2);
}

/* Info Container */
.info-container {
    background: #f8f9fa;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    display: flex;
    gap: 20px;
    margin-top: 2rem;
    border-left: 4px solid #17a2b8;
}

.info-icon {
    font-size: 2rem;
    color: #17a2b8;
}

.info-content h5 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-top: 0;
    margin-bottom: 0.8rem;
    color: #444;
}

.info-content ul {
    margin-bottom: 0;
    padding-left: 1.2rem;
}

.info-content li {
    margin-bottom: 0.5rem;
    color: #666;
}

.info-content li:last-child {
    margin-bottom: 0;
}

/* Footer */
.footer {
    background-color: #FFFFFF;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    padding: 1.5rem 0;
    margin-top: auto;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(204, 0, 0, 0.6);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(204, 0, 0, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(204, 0, 0, 0);
    }
}

.pulse-animation {
    animation: pulse 1.5s infinite;
}

/* Select focused effect */
.select-focused .election-select {
    border-color: var(--primary);
    box-shadow: 0 0 0 0.25rem rgba(204, 0, 0, 0.25);
}

.fade-in {
    opacity: 0;
    animation: fadeIn 0.6s ease-out forwards;
}

/* No Results Message */
.no-results {
    padding: 2rem 0;
    text-align: center;
}

.no-results .alert {
    display: inline-flex;
    align-items: center;
    padding: 1rem 2rem;
    border-radius: 8px;
    font-size: 1.1rem;
}

/* Print Styles */
@media print {
    body {
        background: white;
    }

    .navbar,
    .select-container,
    .actions-container,
    .footer,
    .info-container {
        display: none;
    }

    .page-container {
        padding: 0;
    }

    .main-card {
        box-shadow: none;
    }

    .results-container {
        break-inside: avoid;
        border: none;
        box-shadow: none;
    }

    .custom-table {
        border: 1px solid #ddd;
    }

    .progress-wrapper {
        gap: 5px;
    }
}