/* Variáveis CSS */
:root {
    --primary-color: #2c3e50;
    --secondary-color: #3498db;
    --accent-color: #e74c3c;
    --success-color: #27ae60;
    --warning-color: #f39c12;
    --light-bg: #f8f9fa;
}

/* Reset e configurações básicas */
html, body {
    min-height: 100vh;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8f9fa;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.main-content {
    flex: 1;
}

/* Navbar */
.navbar {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

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

.nav-link {
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: var(--secondary-color) !important;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 1.2rem 0;
    margin-bottom: 2rem;
}

/* Search Section */
.search-section {
    background: white;
    border-radius: 10px;
    padding: 1.6rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    margin-top: -3rem;
    position: relative;
    z-index: 10;
}

/* Cards */
.concurso-card {
    border: none;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin-bottom: 2rem;
    overflow: hidden;
}

.concurso-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0,0,0,0.2);
}

.concurso-header {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    padding: 1.5rem;
    border-bottom: 1px solid #dee2e6;
}

.concurso-logo {
    width: 60px;
    height: 60px;
    object-fit: contain;
    border-radius: 8px;
    background: white;
    padding: 5px;
}

.status-badge {
    font-size: 0.8rem;
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
}

/* Concurso Info */
.concurso-info {
    padding: 1.5rem;
}

.info-item {
    display: flex;
    align-items: center;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.info-item i {
    width: 20px;
    margin-right: 0.5rem;
    color: var(--secondary-color);
}

/* Badge específicos */
.badge-success { 
    background-color: var(--success-color) !important; 
}

.badge-warning { 
    background-color: var(--warning-color) !important; 
}

.badge-danger { 
    background-color: var(--danger-color) !important; 
}

/* Status Sections */
.status-section {
    margin-bottom: 4rem;
    position: relative;
}

.status-section::after {
    content: '';
    position: absolute;
    bottom: -2rem;
    left: 50%;
    transform: translateX(-50%);
    width: 80%;
    height: 1px;
    background: linear-gradient(90deg, transparent, #dee2e6, transparent);
}

.status-section:last-child::after {
    display: none;
}

.status-header {
    color: white;
    padding: 1.5rem 2rem;
    border-radius: 12px;
    margin-bottom: 2rem;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    position: relative;
    overflow: hidden;
}

.status-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, rgba(255,255,255,0.1) 25%, transparent 25%, transparent 50%, rgba(255,255,255,0.1) 50%, rgba(255,255,255,0.1) 75%, transparent 75%);
    background-size: 20px 20px;
    opacity: 0.3;
}

/* Status específicos */
.status-header.status-novo {
    background: linear-gradient(135deg, #27ae60, #2ecc71);
}

.status-header.status-em_andamento {
    background: linear-gradient(135deg, #f39c12, #e67e22);
}

.status-header.status-finalizado {
    background: linear-gradient(135deg, #6c757d, #495057);
}

.status-header h3 {
    margin: 0;
    font-size: 1.4rem;
    font-weight: 600;
    position: relative;
    z-index: 1;
}

.status-header small {
    position: relative;
    z-index: 1;
}

.status-header .badge {
    background: rgba(255,255,255,0.25);
    color: white;
    font-size: 0.9rem;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-weight: 500;
    position: relative;
    z-index: 1;
    backdrop-filter: blur(10px);
}

/* Cards com bordas coloridas */
.concurso-card.border-success {
    border-left: 4px solid #27ae60 !important;
    border-top: 1px solid rgba(39, 174, 96, 0.2) !important;
}

.concurso-card.border-warning {
    border-left: 4px solid #f39c12 !important;
    border-top: 1px solid rgba(243, 156, 18, 0.2) !important;
}

.concurso-card.border-secondary {
    border-left: 4px solid #6c757d !important;
    border-top: 1px solid rgba(108, 117, 125, 0.2) !important;
}

/* Badges com ícones */
.status-badge {
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
}

/* Botões coloridos */
.btn-success {
    background: linear-gradient(135deg, #27ae60, #2ecc71);
    border: none;
    border-radius: 25px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(39, 174, 96, 0.3);
}

.btn-warning {
    background: linear-gradient(135deg, #f39c12, #e67e22);
    border: none;
    border-radius: 25px;
    font-weight: 500;
    transition: all 0.3s ease;
    color: white;
}

.btn-warning:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(243, 156, 18, 0.3);
    color: white;
}

.btn-secondary {
    background: linear-gradient(135deg, #6c757d, #495057);
    border: none;
    border-radius: 25px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(108, 117, 125, 0.3);
}

/* Badges de status */
.badge.bg-success {
    background-color: var(--success-color) !important;
}

.badge.bg-primary {
    background-color: var(--secondary-color) !important;
}

.badge.bg-secondary {
    background-color: #6c757d !important;
}

/* Botões */
.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border: none;
    border-radius: 25px;
    padding: 0.6rem 1.5rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

/* Paginação */
.pagination {
    justify-content: center;
}

.page-link {
    border-radius: 25px;
    margin: 0 2px;
    border: none;
    color: var(--primary-color);
}

.page-link:hover {
    background-color: var(--secondary-color);
    color: white;
}

.page-item.active .page-link {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border: none;
}

/* Footer */
.footer {
    background: var(--primary-color);
    color: white;
    padding: 2rem 0;
    margin-top: 4rem;
    position: relative;
    z-index: 1;
    width: 100%;
    clear: both;
}

/* Sem resultados */
.no-results {
    text-align: center;
    padding: 4rem 0;
    color: #6c757d;
}

.no-results i {
    font-size: 4rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

/* Responsividade */
@media (max-width: 768px) {
    .hero-section {
        padding: 2rem 0;
    }
    
    .search-section {
        margin-top: -2rem;
        padding: 1rem;
    }
    
    .concurso-header {
        padding: 1rem;
    }
    
    .status-header {
        padding: 0.8rem 1rem;
    }
    
    .footer {
        text-align: center;
    }
    
    .footer .col-md-4 {
        margin-bottom: 2rem;
    }
}