/**
 * Ranking Clube de Tiro - Estilos
 */

/* ==========================================
   VARIÁVEIS E RESET
   ========================================== */
:root {
    --primary: #1e293b;
    --primary-dark: #0f172a;
    --primary-light: #334155;
    --secondary: #64748b;
    --success: #10b981;
    --danger: #ef4444;
    --warning: #f59e0b;
    --info: #3b82f6;
    --light: #f8fafc;
    --dark: #0f172a;
    --white: #ffffff;
    --gray-100: #f8fafc;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-400: #94a3b8;
    --gray-500: #64748b;
    --gray-600: #475569;
    --gray-700: #334155;
    --gray-800: #1e293b;
    --gray-900: #0f172a;
    --gold: #fbbf24;
    --silver: #9ca3af;
    --bronze: #d97706;
    --shadow: 0 2px 4px rgba(0,0,0,0.1);
    --shadow-lg: 0 4px 12px rgba(0,0,0,0.15);
    --radius: 8px;
    --radius-sm: 4px;
    --transition: all 0.2s ease;
}

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

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    font-size: 16px;
    line-height: 1.5;
    color: var(--gray-800);
    background: var(--gray-100);
}

a {
    color: var(--primary);
    text-decoration: none;
}

a:hover {
    color: var(--primary-dark);
}

/* ==========================================
   LAYOUT
   ========================================== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ==========================================
   HEADER
   ========================================== */
.header {
    background: var(--primary);
    color: var(--white);
    padding: 1rem 0;
    box-shadow: var(--shadow);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo h1 {
    font-size: 1.5rem;
    font-weight: 600;
}

.nav {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.nav-link {
    color: rgba(255,255,255,0.9);
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.nav-link:hover, .nav-link.active {
    background: rgba(255,255,255,0.15);
    color: var(--white);
}

.btn-login {
    background: var(--white);
    color: var(--primary) !important;
    font-weight: 500;
}

.btn-login:hover {
    background: var(--gray-200);
}

/* Nav User Info */
.nav-user {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: rgba(255,255,255,0.1);
    border-radius: 8px;
    color: var(--white);
    font-weight: 500;
    font-size: 0.9rem;
}

.nav-user .user-name {
    color: var(--white);
}

/* ==========================================
   MAIN
   ========================================== */
.main {
    padding: 2rem 0;
    min-height: calc(100vh - 150px);
}

/* ==========================================
   STATS SECTION
   ========================================== */
.stats-section {
    margin-bottom: 2rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.25rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: var(--white);
    padding: 1.75rem;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.04);
    display: flex;
    align-items: center;
    gap: 1.25rem;
    transition: all 0.3s ease;
    border: 1px solid rgba(0,0,0,0.04);
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 30px rgba(0,0,0,0.08);
}

.stat-icon {
    font-size: 2.5rem;
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    border-radius: 16px;
}

.stat-card:nth-child(1) .stat-icon { background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%); }
.stat-card:nth-child(2) .stat-icon { background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%); }
.stat-card:nth-child(3) .stat-icon { background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%); }
.stat-card:nth-child(4) .stat-icon { background: linear-gradient(135deg, #fce7f3 0%, #fbcfe8 100%); }

.stat-value {
    font-size: 2.25rem;
    font-weight: 800;
    color: #0f172a;
    display: block;
    line-height: 1;
    letter-spacing: -1px;
}

.stat-label {
    color: #64748b;
    font-size: 0.875rem;
    font-weight: 500;
    margin-top: 0.25rem;
}

/* Top 3 */
.top3-section {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.top-item {
    background: var(--white);
    padding: 1rem 2rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    text-align: center;
    min-width: 150px;
}

.top-1 { border-top: 4px solid var(--gold); }
.top-2 { border-top: 4px solid var(--silver); }
.top-3 { border-top: 4px solid var(--bronze); }

.top-posicao {
    display: block;
    font-size: 1.5rem;
    font-weight: 700;
}

.top-1 .top-posicao { color: var(--gold); }
.top-2 .top-posicao { color: var(--silver); }
.top-3 .top-posicao { color: var(--bronze); }

.top-nome {
    display: block;
    font-weight: 600;
    margin: 0.25rem 0;
}

.top-pontos {
    color: var(--gray-600);
    font-size: 0.875rem;
}

/* ==========================================
   FILTERS
   ========================================== */
.filters-section {
    margin-bottom: 1.5rem;
}

.filters {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.filter-group label {
    font-size: 0.875rem;
    color: var(--gray-600);
}

.filters-inline {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

/* ==========================================
   TABLES - MODERN
   ========================================== */
.table-responsive {
    overflow-x: auto;
    border-radius: 12px;
}

.table, .table-ranking {
    width: 100%;
    border-collapse: collapse;
    background: var(--white);
}

.table th, .table td,
.table-ranking th, .table-ranking td {
    padding: 1rem 1.25rem;
    text-align: left;
    border-bottom: 1px solid #f1f5f9;
}

.table th, .table-ranking th {
    background: #f8fafc;
    font-weight: 600;
    color: #475569;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid #e2e8f0;
}

.table tbody tr {
    transition: all 0.15s ease;
}

.table tbody tr:hover {
    background: #f8fafc;
}

.table-ranking tbody tr {
    cursor: pointer;
    transition: all 0.15s ease;
}

.table-ranking tbody tr:hover {
    background: #f8fafc;
}

.table-ranking .posicao { width: 80px; text-align: center; }
.table-ranking .pontos { font-weight: 700; color: #0f172a; }
.table-ranking .etapas { color: #64748b; }

.apelido {
    color: var(--gray-500);
    font-size: 0.875rem;
    margin-left: 0.25rem;
}

.loading, .empty, .error {
    text-align: center;
    padding: 2rem !important;
    color: var(--gray-500);
}

/* Posição Badge */
.posicao-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-weight: 700;
    font-size: 0.875rem;
    background: var(--gray-200);
    color: var(--gray-700);
}

.posicao-badge.gold {
    background: linear-gradient(135deg, #ffd700, #ffed4a);
    color: #5a4500;
}

.posicao-badge.silver {
    background: linear-gradient(135deg, #c0c0c0, #e8e8e8);
    color: #4a4a4a;
}

.posicao-badge.bronze {
    background: linear-gradient(135deg, #cd7f32, #daa06d);
    color: #4a2c00;
}

/* ==========================================
   CARDS - MODERN
   ========================================== */
.card {
    background: var(--white);
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.04);
    margin-bottom: 1.5rem;
    border: 1px solid rgba(0,0,0,0.04);
    overflow: hidden;
}

.card-header {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid #f1f5f9;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    background: linear-gradient(180deg, #fafafa 0%, #fff 100%);
}

.card-header h3 {
    font-size: 1.125rem;
    font-weight: 700;
    color: #0f172a;
    margin: 0;
    letter-spacing: -0.25px;
}

.card-body {
    padding: 1.5rem;
}

/* ==========================================
   RANKING SECTION
   ========================================== */
.ranking-section {
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.ranking-section h2 {
    padding: 1.25rem 1.5rem;
    margin: 0;
    background: var(--primary);
    color: var(--white);
    font-size: 1.25rem;
}

/* ==========================================
   FORMS - MODERN
   ========================================== */
.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: #334155;
    font-size: 0.9rem;
}

.form-input, .form-select, .form-control {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    font-size: 1rem;
    transition: all 0.2s ease;
    background: var(--white);
}

.form-input:focus, .form-select:focus, .form-control:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 4px rgba(59,130,246,0.1);
}

.form-input::placeholder {
    color: #94a3b8;
}

/* Select/Dropdown Modernizado */
.form-select, .form-control, select.form-input {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 18px;
    padding-right: 3rem;
    cursor: pointer;
    color: #0f172a;
    font-weight: 500;
}

.form-select:hover, .form-control:hover, select.form-input:hover {
    border-color: #cbd5e1;
    background-color: #f8fafc;
}

.form-select:focus, .form-control:focus, select.form-input:focus {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%233b82f6' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
}

.form-select:disabled, .form-control:disabled, select.form-input:disabled {
    background-color: #f1f5f9;
    color: #94a3b8;
    cursor: not-allowed;
    border-color: #e2e8f0;
}

.form-select option, .form-control option {
    padding: 0.75rem 1rem;
    background: var(--white);
    color: #0f172a;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.form-row .flex-2 {
    grid-column: span 2;
}

@media (max-width: 600px) {
    .form-row .flex-2 {
        grid-column: span 1;
    }
}

.form-actions {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
}

.form-inline {
    display: flex;
    align-items: flex-end;
    gap: 1rem;
    flex-wrap: wrap;
}

.form-inline .form-group {
    margin-bottom: 0;
}

textarea.form-input {
    resize: vertical;
    min-height: 80px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

/* Autocomplete */
.autocomplete-container {
    position: relative;
}

.autocomplete-list {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    border: 2px solid var(--primary);
    border-radius: var(--radius-sm);
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    margin-top: 2px;
}

.autocomplete-list:empty {
    display: none;
}

.autocomplete-item {
    padding: 0.85rem 1rem;
    cursor: pointer;
    transition: var(--transition);
    border-bottom: 1px solid var(--gray-200);
}

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

.autocomplete-item:hover,
.autocomplete-item:focus {
    background: var(--primary);
    color: #fff;
}

.autocomplete-item strong {
    display: block;
    font-size: 1rem;
}

.autocomplete-item .apelido {
    font-size: 0.85rem;
    opacity: 0.8;
}

.autocomplete-item.no-results {
    color: var(--gray-500);
    cursor: default;
    text-align: center;
    font-style: italic;
}

.autocomplete-item.no-results:hover {
    background: transparent;
    color: var(--gray-500);
}

/* ==========================================
   BUTTONS - MODERN
   ========================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 10px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-primary {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: var(--white);
    box-shadow: 0 4px 12px rgba(59,130,246,0.3);
}

.btn-primary:hover:not(:disabled) {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(59,130,246,0.4);
}

.btn-secondary {
    background: #f1f5f9;
    color: #475569;
    border: 1px solid #e2e8f0;
}

.btn-secondary:hover:not(:disabled) {
    background: #e2e8f0;
    border-color: #cbd5e1;
}

.btn-danger {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: var(--white);
    box-shadow: 0 4px 12px rgba(239,68,68,0.3);
}

.btn-danger:hover:not(:disabled) {
    background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(239,68,68,0.4);
}

.btn-success {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: var(--white);
    box-shadow: 0 4px 12px rgba(16,185,129,0.3);
}

.btn-success:hover:not(:disabled) {
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(16,185,129,0.4);
}

.btn-outline {
    background: transparent;
    border: 2px solid #3b82f6;
    color: #3b82f6;
}

.btn-outline:hover {
    background: #3b82f6;
    color: var(--white);
}

.btn-block {
    width: 100%;
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
    border-radius: 8px;
}

/* ==========================================
   BADGES - MODERN
   ========================================== */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 0.35rem 0.85rem;
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.25px;
}

.badge-primary { background: #dbeafe; color: #1d4ed8; }
.badge-secondary { background: #f1f5f9; color: #475569; }
.badge-success { background: #d1fae5; color: #047857; }
.badge-warning { background: #fef3c7; color: #b45309; }
.badge-danger { background: #fee2e2; color: #b91c1c; }

/* ==========================================
   ALERTS
   ========================================== */
.alert {
    padding: 1rem;
    border-radius: var(--radius-sm);
    margin-bottom: 1rem;
}

.alert-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-toast {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    animation: slideIn 0.3s ease;
    box-shadow: var(--shadow-lg);
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* ==========================================
   MODAL - MODERN
   ========================================== */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    padding: 1rem;
}

.modal.active {
    opacity: 1;
    visibility: visible;
}

.modal-dialog {
    background: var(--white);
    border-radius: 20px;
    box-shadow: 0 25px 50px -12px rgba(0,0,0,0.25);
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    transform: scale(0.95) translateY(10px);
    transition: all 0.3s ease;
}

.modal.active .modal-dialog {
    transform: scale(1) translateY(0);
}

.modal-close {
    position: absolute;
    top: 1.25rem;
    right: 1.25rem;
    width: 36px;
    height: 36px;
    background: #f1f5f9;
    border: none;
    border-radius: 10px;
    font-size: 1.25rem;
    cursor: pointer;
    color: #64748b;
    line-height: 1;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.modal-close:hover {
    background: #e2e8f0;
    color: #0f172a;
}

.modal-header {
    padding: 1.75rem 1.75rem 1.25rem;
    border-bottom: 1px solid #f1f5f9;
}

.modal-header h3 {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 700;
    color: #0f172a;
    letter-spacing: -0.25px;
}

.modal-body {
    padding: 1.5rem 1.75rem 1.75rem;
}

/* Modal Detalhes */
.atirador-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.atirador-header h2 {
    margin-bottom: 0.25rem;
}

.resumo-stats {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.resumo-stats .stat {
    text-align: center;
}

.resumo-stats .stat-value {
    font-size: 1.75rem;
}

.table-resultados {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

.table-resultados th, .table-resultados td {
    padding: 0.75rem;
    border-bottom: 1px solid var(--gray-200);
}

.table-resultados th {
    background: var(--gray-100);
    text-align: left;
}

/* ==========================================
   LOGIN PAGE
   ========================================== */
.login-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #334155 100%);
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
}

.login-container {
    width: 100%;
    max-width: 420px;
    padding: 1rem;
}

.login-card {
    background: var(--white);
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0,0,0,0.25);
    overflow: hidden;
}

.login-header {
    text-align: center;
    padding: 2.5rem 2rem 2rem;
    background: linear-gradient(180deg, #f8fafc 0%, #fff 100%);
}

.login-header h1 {
    font-size: 3rem;
    margin-bottom: 0.5rem;
}

.login-header h2 {
    font-size: 2rem;
    font-weight: 800;
    color: #0f172a;
    margin-bottom: 0.25rem;
    letter-spacing: -0.5px;
}

.login-header p {
    color: #64748b;
    font-size: 0.9rem;
    font-weight: 500;
}

.login-form {
    padding: 2rem;
}

.login-form .form-group label {
    font-weight: 600;
    color: #334155;
    font-size: 0.9rem;
}

.login-form .form-input {
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 0.875rem 1rem;
    font-size: 1rem;
    transition: all 0.2s ease;
}

.login-form .form-input:focus {
    border-color: #1e293b;
    box-shadow: 0 0 0 4px rgba(30,41,59,0.1);
}

.login-form .btn-primary {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    border-radius: 12px;
    padding: 1rem;
    font-size: 1rem;
    font-weight: 600;
    box-shadow: 0 4px 14px rgba(15,23,42,0.4);
    transition: all 0.2s ease;
}

.login-form .btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(15,23,42,0.5);
}

.login-footer {
    text-align: center;
    padding: 1rem 2rem 2rem;
}

.login-footer a {
    color: #64748b;
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.2s ease;
}

.login-footer a:hover {
    color: #1e293b;
}

/* ==========================================
   ADMIN LAYOUT - MODERN
   ========================================== */
.admin-layout {
    display: flex;
    min-height: 100vh;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
}

.sidebar {
    width: 280px;
    background: linear-gradient(180deg, #0f172a 0%, #1e293b 100%);
    color: var(--white);
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
    z-index: 100;
    box-shadow: 4px 0 20px rgba(0,0,0,0.1);
}

.sidebar-header {
    padding: 1.75rem 1.5rem;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    background: rgba(0,0,0,0.2);
}

.sidebar-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.5px;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.sidebar-nav {
    flex: 1;
    padding: 1.25rem 0;
    overflow-y: auto;
}

.sidebar-nav .nav-item {
    display: flex;
    align-items: center;
    gap: 0.875rem;
    padding: 0.875rem 1.5rem;
    margin: 0.25rem 0.75rem;
    color: rgba(255,255,255,0.6);
    transition: all 0.2s ease;
    border-radius: 10px;
    font-weight: 500;
    font-size: 0.95rem;
}

.sidebar-nav .nav-item:hover {
    background: rgba(255,255,255,0.08);
    color: var(--white);
    transform: translateX(4px);
}

.sidebar-nav .nav-item.active {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: var(--white);
    box-shadow: 0 4px 12px rgba(59,130,246,0.3);
}

.nav-icon {
    font-size: 1.25rem;
    width: 24px;
    text-align: center;
}

/* Sidebar User Info */
.sidebar-user {
    display: flex;
    align-items: center;
    gap: 0.875rem;
    padding: 1.25rem 1.5rem;
    border-top: 1px solid rgba(255,255,255,0.08);
    background: rgba(255,255,255,0.03);
}

.user-avatar {
    width: 42px;
    height: 42px;
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(59,130,246,0.3);
}

.sidebar-user .user-name {
    color: var(--white);
    font-weight: 600;
    font-size: 0.95rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
}

.btn-logout-icon {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,0.1);
    border-radius: 10px;
    color: rgba(255,255,255,0.6);
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.btn-logout-icon:hover {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

.btn-logout-icon svg {
    width: 18px;
    height: 18px;
}

.admin-content {
    flex: 1;
    margin-left: 280px;
    background: linear-gradient(180deg, #f1f5f9 0%, #e2e8f0 100%);
    min-height: 100vh;
}

.admin-header {
    background: var(--white);
    padding: 1.5rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(0,0,0,0.06);
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
    position: sticky;
    top: 0;
    z-index: 50;
}

.admin-header h1 {
    font-size: 1.75rem;
    font-weight: 700;
    color: #0f172a;
    margin: 0;
    letter-spacing: -0.5px;
}

.admin-header .user-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.dashboard-content {
    padding: 2rem;
}

/* Quick Actions - Modern */
.quick-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.quick-action-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    padding: 1.75rem 2.5rem;
    background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%);
    border-radius: 16px;
    color: #334155;
    transition: all 0.3s ease;
    text-decoration: none;
    border: 1px solid rgba(0,0,0,0.04);
    font-weight: 500;
}

.quick-action-btn:hover {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: var(--white);
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(59,130,246,0.3);
}

.quick-action-btn .icon {
    font-size: 1.75rem;
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--white);
    border-radius: 14px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    transition: all 0.3s ease;
}

.quick-action-btn:hover .icon {
    background: rgba(255,255,255,0.2);
    box-shadow: none;
}

/* Pontuação Grid */
.pontuacao-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.pontuacao-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem;
    background: var(--gray-100);
    border-radius: var(--radius-sm);
}

.pontuacao-item .pontos-input {
    width: 80px;
    text-align: center;
}

.pontuacao-item .pontos-label {
    color: var(--gray-600);
    font-size: 0.875rem;
}

/* Etapa Info Box */
.etapa-info-box {
    display: flex;
    gap: 1rem;
    align-items: center;
    padding: 1rem;
    background: var(--primary);
    color: var(--white);
    border-radius: var(--radius-sm);
    margin-bottom: 1rem;
}

/* ==========================================
   FOOTER
   ========================================== */
.footer {
    background: var(--gray-800);
    color: var(--gray-400);
    padding: 1.5rem 0;
    text-align: center;
}

/* ==========================================
   RESPONSIVE
   ========================================== */
@media (max-width: 1024px) {
    .sidebar {
        width: 260px;
        transform: translateX(-100%);
        transition: all 0.3s ease;
    }
    
    .sidebar.open {
        transform: translateX(0);
    }
    
    .admin-content {
        margin-left: 0;
    }
    
    .admin-header h1 {
        font-size: 1.5rem;
    }
}

@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        gap: 1rem;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .top3-section {
        flex-direction: column;
        align-items: center;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .table th, .table td {
        padding: 0.75rem 0.5rem;
        font-size: 0.875rem;
    }
    
    .admin-header {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .dashboard-content {
        padding: 1rem;
    }
}

@media (max-width: 480px) {
    .btn {
        padding: 0.625rem 1rem;
        font-size: 0.875rem;
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    .form-actions .btn {
        width: 100%;
    }
}

/* ==========================================
   CHECKBOX GRID - MODERN
   ========================================== */
.checkbox-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 0.5rem;
    padding: 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    background: #f8fafc;
    max-height: 200px;
    overflow-y: auto;
}

.checkbox-item {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    padding: 0.625rem 0.75rem;
    background: var(--white);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.checkbox-item:hover {
    background: #dbeafe;
    border-color: #3b82f6;
}

.checkbox-item input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #3b82f6;
}

.checkbox-item span {
    font-size: 0.9rem;
    font-weight: 500;
    color: #334155;
}

/* ==========================================
   PAGINATION - MODERN
   ========================================== */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    margin-top: 1.5rem;
    padding: 1.25rem;
    background: #f8fafc;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
}

.pagination-info {
    font-size: 0.9rem;
    color: var(--gray-700);
    min-width: 200px;
    text-align: center;
}

.pagination .btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ==========================================
   UTILITIES
   ========================================== */
.text-muted { color: var(--gray-600); }
.text-center { text-align: center; }
.mb-0 { margin-bottom: 0; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }

/* ==========================================
   MODERN RANKING PAGE - CTC
   ========================================== */
.ranking-page {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%);
    min-height: 100vh;
}

/* Modern Header */
.header-modern {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #334155 100%);
    padding: 1rem 0;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-modern .header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-modern .logo {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.logo-icon {
    width: 48px;
    height: 48px;
    background: rgba(255,255,255,0.15);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(10px);
}

.logo-icon svg {
    width: 28px;
    height: 28px;
    color: #fff;
}

.logo-text {
    display: flex;
    flex-direction: column;
}

.logo-title {
    font-size: 1.75rem;
    font-weight: 800;
    color: #fff;
    letter-spacing: -0.5px;
    line-height: 1;
}

.logo-subtitle {
    font-size: 0.75rem;
    color: rgba(255,255,255,0.8);
    font-weight: 500;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.logo-image {
    width: 48px;
    height: 48px;
    object-fit: contain;
    border-radius: 8px;
}

.header-modern .nav {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.header-modern .nav-link {
    color: rgba(255,255,255,0.9);
    padding: 0.625rem 1.25rem;
    border-radius: 8px;
    font-weight: 500;
    font-size: 0.9rem;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.header-modern .nav-link:hover,
.header-modern .nav-link.active {
    background: rgba(255,255,255,0.15);
    color: #fff;
}

/* Header Badge */
.header-badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    color: #78350f;
    font-weight: 700;
    font-size: 0.85rem;
    border-radius: 30px;
    box-shadow: 0 4px 12px rgba(251,191,36,0.3);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.header-badge svg {
    color: #78350f;
}

/* Hero Banner */
.hero-banner {
    background: linear-gradient(135deg, #1e293b 0%, #334155 100%);
    padding: 3rem 0;
    position: relative;
    overflow: hidden;
}

.hero-banner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Ccircle cx='30' cy='30' r='10'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
}

.hero-banner .hero-title {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    font-size: 2.5rem;
    font-weight: 800;
    color: #fff;
    margin-bottom: 0.75rem;
    letter-spacing: -1px;
}

.hero-banner .hero-title svg {
    color: #fbbf24;
}

.hero-banner .hero-subtitle {
    font-size: 1.1rem;
    color: rgba(255,255,255,0.7);
    font-weight: 500;
    max-width: 600px;
    margin: 0 auto;
}

@media (max-width: 768px) {
    .hero-banner {
        padding: 2rem 0;
    }
    
    .hero-banner .hero-title {
        font-size: 1.75rem;
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .hero-banner .hero-title svg {
        width: 32px;
        height: 32px;
    }
    
    .hero-banner .hero-subtitle {
        font-size: 0.95rem;
    }
    
    .header-badge {
        font-size: 0.75rem;
        padding: 0.4rem 0.75rem;
    }
}

/* Hero Section */
.hero-section {
    text-align: center;
    padding: 3rem 0 2rem;
}

.hero-title {
    font-size: 2.5rem;
    font-weight: 800;
    color: #0f172a;
    margin-bottom: 0.5rem;
    letter-spacing: -1px;
}

.hero-subtitle {
    font-size: 1.1rem;
    color: #64748b;
    font-weight: 400;
}

/* Stats Section Modern */
.ranking-page .stats-section {
    margin-bottom: 2rem;
}

.ranking-page .stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    margin-bottom: 2rem;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

.ranking-page .stat-card {
    background: #fff;
    padding: 1.5rem;
    border-radius: 16px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.06);
    display: flex;
    align-items: center;
    gap: 1rem;
    border: 1px solid rgba(0,0,0,0.04);
    transition: all 0.3s ease;
}

.ranking-page .stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.1);
}

.stat-icon-wrapper {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, #e2e8f0 0%, #cbd5e1 100%);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.stat-icon-wrapper svg {
    width: 28px;
    height: 28px;
    color: #1e293b;
}

.ranking-page .stat-value {
    font-size: 2rem;
    font-weight: 800;
    color: #0f172a;
    line-height: 1;
}

.ranking-page .stat-label {
    font-size: 0.85rem;
    color: #64748b;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Podium Section */
.podium-section {
    display: flex;
    justify-content: center;
    align-items: flex-end;
    gap: 1rem;
    padding: 1rem 0 2rem;
}

.podium-item {
    background: #fff;
    border-radius: 20px;
    padding: 1.5rem;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    border: 2px solid transparent;
    transition: all 0.3s ease;
    min-width: 160px;
}

.podium-item:hover {
    transform: translateY(-4px);
}

.podium-1 {
    border-color: #fbbf24;
    background: linear-gradient(180deg, #fffbeb 0%, #fff 100%);
    order: 2;
    padding: 2rem 1.5rem;
    min-width: 180px;
}

.podium-2 {
    border-color: #9ca3af;
    background: linear-gradient(180deg, #f9fafb 0%, #fff 100%);
    order: 1;
}

.podium-3 {
    border-color: #d97706;
    background: linear-gradient(180deg, #fef3c7 0%, #fff 100%);
    order: 3;
}

.podium-position {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    font-size: 1.5rem;
    font-weight: 800;
    margin-bottom: 0.75rem;
}

.podium-1 .podium-position {
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    color: #fff;
    box-shadow: 0 4px 12px rgba(251,191,36,0.4);
}

.podium-2 .podium-position {
    background: linear-gradient(135deg, #d1d5db 0%, #9ca3af 100%);
    color: #fff;
    box-shadow: 0 4px 12px rgba(156,163,175,0.4);
}

.podium-3 .podium-position {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: #fff;
    box-shadow: 0 4px 12px rgba(217,119,6,0.4);
}

.podium-name {
    font-weight: 700;
    color: #1e293b;
    font-size: 1rem;
    margin-bottom: 0.25rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 150px;
}

.podium-score {
    font-size: 0.9rem;
    color: #64748b;
    font-weight: 600;
}

/* Filters Card */
.filters-card {
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
    margin-bottom: 1.5rem;
    border: 1px solid rgba(0,0,0,0.04);
    overflow: hidden;
}

.filters-header {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid #f1f5f9;
    background: #fafbfc;
}

.filters-header h3 {
    font-size: 1rem;
    font-weight: 600;
    color: #475569;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0;
}

.filters-header svg {
    color: #64748b;
}

.filters-body {
    padding: 1.5rem;
}

.filters-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.filters-grid .filter-group label {
    font-size: 0.8rem;
    font-weight: 600;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.5rem;
    display: block;
}

.filters-grid .form-select {
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    padding: 0.75rem 1rem;
    font-size: 0.95rem;
    font-weight: 500;
    color: #334155;
    background: #fff;
    transition: all 0.2s ease;
}

.filters-grid .form-select:focus {
    border-color: #1e293b;
    box-shadow: 0 0 0 4px rgba(30,41,59,0.1);
}

.filters-grid .form-select:disabled {
    background: #f8fafc;
    color: #94a3b8;
}

/* Ranking Card */
.ranking-card {
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
    border: 1px solid rgba(0,0,0,0.04);
    overflow: hidden;
}

.ranking-header {
    padding: 1.25rem 1.5rem;
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
}

.ranking-header h2 {
    font-size: 1.1rem;
    font-weight: 600;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin: 0;
}

.ranking-body {
    padding: 0;
}

.ranking-card .table-ranking {
    border-radius: 0;
}

.ranking-card .table-ranking th {
    background: #f8fafc;
    color: #475569;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 1rem 1.25rem;
    border-bottom: 2px solid #e2e8f0;
}

.ranking-card .table-ranking td {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid #f1f5f9;
    font-size: 0.95rem;
}

.ranking-card .table-ranking tbody tr:hover {
    background: #f8fafc;
}

.ranking-card .table-ranking .th-posicao,
.ranking-card .table-ranking .th-score,
.ranking-card .table-ranking .th-penalty,
.ranking-card .table-ranking .th-tiebreak,
.ranking-card .table-ranking .th-pontos {
    text-align: center;
    width: 100px;
}

.ranking-card .table-ranking td:nth-child(1),
.ranking-card .table-ranking td:nth-child(3),
.ranking-card .table-ranking td:nth-child(4),
.ranking-card .table-ranking td:nth-child(5),
.ranking-card .table-ranking td:nth-child(6) {
    text-align: center;
}

/* Modern Position Badge */
.ranking-card .posicao-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    height: 44px;
    padding: 0;
    border-radius: 12px;
    font-weight: 800;
    font-size: 1rem;
}

.ranking-card .posicao-badge.gold {
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    color: #fff;
    box-shadow: 0 4px 12px rgba(251,191,36,0.3);
}

.ranking-card .posicao-badge.silver {
    background: linear-gradient(135deg, #d1d5db 0%, #9ca3af 100%);
    color: #fff;
    box-shadow: 0 4px 12px rgba(156,163,175,0.3);
}

.ranking-card .posicao-badge.bronze {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: #fff;
    box-shadow: 0 4px 12px rgba(217,119,6,0.3);
}

/* Empty State */
.empty-state {
    padding: 3rem 1rem;
    text-align: center;
}

.empty-state svg {
    color: #cbd5e1;
    margin-bottom: 1rem;
}

.empty-state p {
    color: #94a3b8;
    font-size: 1rem;
    font-weight: 500;
    margin: 0;
}

/* Modern Pagination */
.ranking-card .pagination {
    padding: 1.25rem 1.5rem;
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
    margin: 0;
    border-radius: 0;
}

.btn-page {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 1.25rem;
    background: #fff;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    font-size: 0.9rem;
    font-weight: 600;
    color: #475569;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-page:hover:not(:disabled) {
    border-color: #1e293b;
    color: #1e293b;
    background: #f1f5f9;
}

.btn-page:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.ranking-card .pagination-info {
    font-size: 0.9rem;
    font-weight: 600;
    color: #64748b;
}

/* Modern Footer */
.footer-modern {
    background: #0f172a;
    padding: 1.5rem 0;
    margin-top: 3rem;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-brand {
    color: #e2e8f0;
    font-size: 0.95rem;
}

.footer-brand strong {
    color: #fff;
    font-weight: 700;
}

.footer-dev {
    color: #94a3b8;
    font-size: 0.85rem;
}

.footer-dev strong {
    color: #e2e8f0;
    font-weight: 600;
}

.footer-copy {
    color: #64748b;
    font-size: 0.85rem;
}

/* Responsive for Modern Design */
@media (max-width: 768px) {
    .header-modern .header-content {
        flex-direction: column;
        gap: 1rem;
    }
    
    .hero-title {
        font-size: 1.75rem;
    }
    
    .hero-subtitle {
        font-size: 0.95rem;
    }
    
    .ranking-page .stats-grid {
        grid-template-columns: 1fr;
        max-width: 300px;
    }
    
    .podium-section {
        flex-direction: column;
        align-items: center;
    }
    
    .podium-1, .podium-2, .podium-3 {
        order: unset;
    }
    
    .filters-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        flex-direction: column;
        text-align: center;
        gap: 0.5rem;
    }
    
    .footer-dev {
        order: 2;
    }
    
    .footer-copy {
        order: 3;
    }
}

/* Matricula style for search */
.matricula {
    color: var(--gray-500);
    font-size: 0.85rem;
    font-weight: 500;
}

/* Botão Ver Alvo */
.btn-ver-alvo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, #e2e8f0 0%, #cbd5e1 100%);
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
    color: #475569;
}

.btn-ver-alvo:hover {
    background: linear-gradient(135deg, #1e293b 0%, #334155 100%);
    color: #fff;
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(30,41,59,0.3);
}

.th-alvo {
    text-align: center;
    width: 80px;
}

.alvo-cell {
    text-align: center;
}

/* Modal Foto Alvo */
.foto-alvo-modal h3 {
    color: #1e293b;
    font-size: 1.25rem;
    font-weight: 700;
}

.foto-alvo-modal h3 svg {
    color: #64748b;
}

/* ==========================================
   FORM DIVIDER & HELP
   ========================================== */
.form-divider {
    display: flex;
    align-items: center;
    margin: 1.5rem 0 1rem;
    gap: 1rem;
}

.form-divider::before,
.form-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--gray-300);
}

.form-divider span {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-help {
    display: block;
    margin-top: 0.25rem;
    font-size: 0.8rem;
    color: var(--gray-500);
}

/* Input with multiplier info */
.input-with-info {
    position: relative;
    display: flex;
    align-items: center;
}

.input-with-info .form-input {
    flex: 1;
}

.input-multiplier {
    position: absolute;
    right: 10px;
    font-size: 0.75rem;
    color: var(--gray-500);
    pointer-events: none;
}

/* Criterios Info Box */
.criterios-info {
    display: flex;
    gap: 1.5rem;
    padding: 1rem;
    background: var(--gray-100);
    border-radius: var(--radius);
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.criterio-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
}

.criterio-label {
    color: var(--gray-600);
}

.criterio-valor {
    font-weight: 700;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
}

.criterio-max .criterio-valor {
    background: #dbeafe;
    color: #2563eb;
}

.criterio-penalidade .criterio-valor {
    background: #fee2e2;
    color: #dc2626;
}

.criterio-desempate .criterio-valor {
    background: #dcfce7;
    color: #16a34a;
}

.criterio-calc {
    color: var(--gray-500);
    font-size: 0.8rem;
}

/* Input error state */
.input-error {
    border-color: #dc2626 !important;
    background-color: #fef2f2 !important;
    animation: shake 0.3s ease-in-out;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

/* ==========================================
   SEARCH BOX
   ========================================== */
.search-box {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: var(--radius);
    padding: 0.5rem 1rem;
    transition: var(--transition);
}

.search-box:focus-within {
    background: rgba(255,255,255,0.15);
    border-color: rgba(255,255,255,0.3);
}

.search-box svg {
    color: rgba(255,255,255,0.6);
    flex-shrink: 0;
}

.search-input {
    background: transparent;
    border: none;
    outline: none;
    color: var(--white);
    font-size: 0.9rem;
    width: 180px;
}

.search-input::placeholder {
    color: rgba(255,255,255,0.5);
}

.ranking-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

@media (max-width: 480px) {
    .search-box {
        width: 100%;
        order: 2;
    }
    
    .search-input {
        width: 100%;
    }
}

/* ==========================================
   PAGINAÇÃO
   ========================================== */
.pagination-container {
    margin-top: 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
}

.pagination {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    justify-content: center;
}

.pagination-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 0.75rem;
    background: var(--white);
    border: 2px solid var(--gray-200);
    border-radius: var(--radius);
    color: var(--gray-700);
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.pagination-btn:hover:not(.disabled):not(.active) {
    background: var(--gray-100);
    border-color: var(--gray-300);
}

.pagination-btn.active {
    background: var(--primary);
    border-color: var(--primary);
    color: var(--white);
}

.pagination-btn.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.pagination-ellipsis {
    color: var(--gray-500);
    padding: 0 0.5rem;
}

.pagination-info {
    color: var(--gray-500);
    font-size: 0.875rem;
}

@media (max-width: 480px) {
    .pagination-btn {
        min-width: 36px;
        height: 36px;
        padding: 0 0.5rem;
        font-size: 0.85rem;
    }
}
