/* Panorama Müllentsorgung – Rennbahn-Auswertung */

.pe-race-board {
    background: linear-gradient(180deg, #f5e6c8 0%, #e8d4a8 8%, #f8f0e0 100%);
    border: 3px solid #8b6914;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(61, 40, 10, 0.15);
    padding: 1.25rem 1rem 1.5rem;
}

.pe-race-board__header {
    text-align: center;
    margin-bottom: 1rem;
}

.pe-race-board__title {
    display: inline-block;
    background: linear-gradient(180deg, #c49a3c 0%, #8b6914 100%);
    color: #fff8e7;
    font-weight: 700;
    font-size: 1.15rem;
    padding: 0.35rem 1.5rem;
    border-radius: 6px;
    border: 2px solid #6d4c12;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}

.pe-race-row {
    display: grid;
    grid-template-columns: 88px auto 1fr;
    gap: 0.5rem 0.75rem;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px dashed rgba(139, 105, 20, 0.35);
}

.pe-race-row:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.pe-race-row__profile {
    text-align: center;
    min-width: 0;
}

.pe-race-row__avatar {
    width: 56px;
    height: 56px;
    object-fit: cover;
    border-radius: 50%;
    border: 2px solid #fff;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
    background: #e0e0e0;
}

.pe-race-row__avatar--placeholder {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #a5d6a7, #81c784);
    color: #1b5e20;
    font-size: 1.5rem;
}

.pe-race-row__name {
    font-size: 0.72rem;
    font-weight: 600;
    margin-top: 0.25rem;
    line-height: 1.2;
    word-break: break-word;
    color: #3e2723;
}

.pe-race-row__trophy {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 28px;
    font-size: 1.35rem;
}

.pe-race-row__trophy--empty {
    min-width: 28px;
}

.pe-track-wrap {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 88px auto 1fr 28px;
    gap: 0.5rem 0.75rem;
    align-items: center;
}

@media (min-width: 576px) {
    .pe-race-row {
        grid-template-columns: 88px 32px 1fr;
    }

    .pe-track-wrap {
        grid-column: auto;
        grid-template-columns: 1fr 28px;
    }

    .pe-race-row__profile {
        grid-row: 1;
    }

    .pe-race-row__trophy {
        grid-row: 1;
    }
}

.pe-track {
    position: relative;
    height: 44px;
    border-radius: 22px;
    background: linear-gradient(180deg, #d4c4a0 0%, #c4b090 45%, #b8a480 100%);
    border: 2px solid #fff;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.08);
    overflow: visible;
}

.pe-track::before,
.pe-track::after {
    content: '';
    position: absolute;
    top: -4px;
    bottom: -4px;
    width: 12px;
    border-radius: 4px;
    background: repeating-linear-gradient(
        180deg,
        #4caf50 0,
        #4caf50 6px,
        #2e7d32 6px,
        #2e7d32 12px
    );
    opacity: 0.85;
    z-index: 0;
}

.pe-track::before {
    left: -2px;
}

.pe-track::after {
    right: -2px;
}

.pe-track__inner {
    position: absolute;
    left: 10px;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    height: 28px;
    border-radius: 14px;
    background: linear-gradient(180deg, #efe4c8 0%, #e0d0a8 100%);
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.06);
}

.pe-marker {
    position: absolute;
    top: 50%;
    transform: translate(-50%, -50%);
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: left 0.4s ease-out;
    pointer-events: none;
}

.pe-marker__icon {
    width: 40px;
    height: 40px;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.25));
}

.pe-marker__metric {
    margin-top: -2px;
    background: #fff;
    border: 2px solid #5d4037;
    border-radius: 10px;
    padding: 0 6px;
    font-size: 0.7rem;
    font-weight: 700;
    color: #3e2723;
    white-space: nowrap;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
}

.pe-finish {
    width: 24px;
    height: 44px;
    border-radius: 4px;
    background: repeating-conic-gradient(#fff 0% 25%, #1b5e20 0% 50%) 0 0 / 12px 12px;
    border: 2px solid #fff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.pe-race-row__badges {
    grid-column: 1 / -1;
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    margin-top: 0.15rem;
    padding-left: 0.25rem;
}

@media (min-width: 576px) {
    .pe-race-row__badges {
        grid-column: 3;
        margin-top: 0;
        padding-left: 0;
    }
}

.pe-empty {
    text-align: center;
    padding: 2rem 1rem;
    color: #6d4c41;
}

.pe-info-panel {
    font-size: 0.85rem;
}
