/* css/classificacao.css */

.classification-header {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    padding-top: 100px;
    padding-left: 5px;
    margin-bottom: 2rem;
}

.controls-wrapper {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    width: 100%;
    max-width: 400px;
}

/* Toggle Switch Styling */
.view-toggle {
    display: flex;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 4px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.toggle-btn {
    flex: 1;
    padding: 8px 16px;
    border: none;
    background: transparent;
    color: #aaa;
    cursor: pointer;
    border-radius: 6px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.toggle-btn.active {
    background: var(--primary-color, #00d4ff);
    color: white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

/* Table Container */
.classification-table-wrapper {
    background: var(--glass-bg, rgba(28, 30, 50, 0.95));
    border-radius: 12px;
    border: 1px solid var(--glass-border, rgba(255, 255, 255, 0.1));
    overflow: hidden;
    margin-bottom: 50px;
}

.table-responsive {
    overflow-x: auto;
}

.table {
    width: 100%;
    border-collapse: collapse;
    color: #e0e0e0;
}

.table th {
    background: rgba(255, 255, 255, 0.05);
    padding: 15px;
    text-align: center;
    /* Center align stage columns */
    font-weight: 600;
    border-bottom: 2px solid rgba(255, 255, 255, 0.1);
    white-space: nowrap;
}

.table th.text-left {
    text-align: left;
}

.table td {
    padding: 12px 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    vertical-align: middle;
    text-align: center;
}

.table td.text-left {
    text-align: left;
}

.table tr:hover {
    background: rgba(255, 255, 255, 0.03);
}

/* Pilot/Team Cell */
.entity-cell {
    display: flex;
    align-items: center;
    gap: 12px;
}

.entity-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    /* Circle for pilots, maybe square for teams? */
    object-fit: cover;
    object-position: top center;
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.team-avatar {
    border-radius: 8px;
    /* Square with rounded corners for teams */
    object-fit: contain;
    background: white;
    /* Teams logos often need white bg */
    padding: 2px;
}

.entity-info {
    display: flex;
    flex-direction: column;
}

.entity-name {
    font-weight: 600;
    color: white;
}

.entity-sub {
    font-size: 0.8rem;
    color: #999;
}

/* Position Badges */
.pos-circle {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    margin: 0 auto;
}

.pos-1 {
    background: #FFD700;
    color: black;
    box-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

.pos-2 {
    background: #C0C0C0;
    color: black;
}

.pos-3 {
    background: #CD7F32;
    color: black;
}

/* Total Points */
.total-points {
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--primary-color, #00d4ff);
}

/* Stage Point */
.stage-pt {
    color: #ccc;
}

.stage-pt.zero {
    color: #555;
    font-size: 0.9rem;
}