.page-choice-judge .container {
    max-width: 1400px;
}

.page-choice-judge .filters-bar {
    background: white;
    border-radius: 32px;
    padding: 20px 24px;
    margin-bottom: 32px;
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    align-items: center;
    gap: 16px;
    border: 1px solid #edf2f7;
}

.page-choice-judge .filter-group {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.page-choice-judge .filter-group-level {
    margin-right: auto;
}

.page-choice-judge .filter-group-type {
    justify-content: center;
}

.page-choice-judge .filter-label {
    font-weight: 500;
    color: #374151;
}

.page-choice-judge .enter-program-btn {
    margin-left: auto;
    background: #10b981;
    color: white;
    border: none;
    padding: 8px 24px;
    border-radius: 40px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s;
}

.page-choice-judge .enter-program-btn:hover {
    background: #059669;
}

.page-choice-judge select,
.page-choice-judge input {
    padding: 8px 16px;
    border-radius: 40px;
    border: 1px solid #d1d5db;
    background: #f9fafb;
    font-size: 0.9rem;
}

.page-choice-judge .search-input {
    width: 200px;
}

.page-choice-judge .topic-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 24px;
    margin-bottom: 40px;
    align-items: stretch;
}

.page-choice-judge .topic-grid > .empty-state {
    grid-column: 1 / -1;
}

.page-choice-judge .topic-card {
    background: white;
    border-radius: 32px;
    padding: 24px;
    min-width: 0;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.05);
    border: 1px solid #edf2f7;
    transition: transform 0.2s, box-shadow 0.2s;
    cursor: pointer;
}

.page-choice-judge .topic-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 25px -12px rgba(0, 0, 0, 0.1);
}

.page-choice-judge .topic-title {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.page-choice-judge .topic-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px 16px;
    font-size: 0.8rem;
    color: #6b7280;
    margin-bottom: 16px;
}

.page-choice-judge .topic-difficulty {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.page-choice-judge .topic-difficulty-label {
    font-size: 0.75rem;
    font-weight: 600;
    color: #374151;
}

.page-choice-judge .topic-difficulty-stars {
    display: inline-flex;
    align-items: center;
    gap: 3px;
}

.page-choice-judge .diff-star {
    font-size: 1.15rem;
    line-height: 1;
    user-select: none;
}

.page-choice-judge .diff-star--full {
    color: #fbbf24;
    text-shadow: 0 1px 2px rgba(217, 119, 6, 0.45);
}

.page-choice-judge .diff-star--empty {
    color: #e5e7eb;
}

.page-choice-judge .topic-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
}

.page-choice-judge .tag {
    background: #eef2ff;
    color: #1e40af;
    padding: 4px 12px;
    border-radius: 30px;
    font-size: 0.7rem;
}

.page-choice-judge .topic-desc {
    color: #4b5563;
    font-size: 0.85rem;
    margin-bottom: 20px;
    line-height: 1.4;
}

.page-choice-judge .topic-stats {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    font-size: 0.8rem;
    color: #6b7280;
    flex-wrap: wrap;
}

.page-choice-judge .topic-actions {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    justify-content: flex-end;
    margin-left: auto;
}

.page-choice-judge .topic-action-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 14px;
    border-radius: 40px;
    font-family: inherit;
    font-size: 0.75rem;
    font-weight: 600;
    line-height: 1.2;
    white-space: nowrap;
    border: 1px solid transparent;
    cursor: pointer;
    margin: 0;
    appearance: none;
    -webkit-appearance: none;
    transition: background 0.2s, border-color 0.2s, color 0.2s;
    box-sizing: border-box;
}

.page-choice-judge .topic-action-btn:focus-visible {
    outline: 2px solid #2563eb;
    outline-offset: 2px;
}

.page-choice-judge .topic-action-btn--timed:focus-visible {
    outline-color: #fdba74;
}

.page-choice-judge .topic-action-btn--free {
    background: #ffffff;
    border-color: #cbd5e1;
    color: #475569;
}

.page-choice-judge .topic-action-btn--free:hover {
    border-color: #2563eb;
    color: #2563eb;
    background: #eff6ff;
}

.page-choice-judge .topic-action-btn--feynman {
    background: #f0fdf4;
    border-color: #86efac;
    color: #166534;
}

.page-choice-judge .topic-action-btn--feynman:hover {
    border-color: #22c55e;
    color: #14532d;
    background: #dcfce7;
}

.page-choice-judge .topic-action-btn--timed {
    background: #ea580c;
    border-color: #ea580c;
    color: #ffffff;
}

.page-choice-judge .topic-action-btn--timed:hover {
    background: #c2410c;
    border-color: #c2410c;
    color: #ffffff;
}

.page-choice-judge .empty-state {
    width: 100%;
    padding: 40px;
    text-align: center;
    color: #6b7280;
    background: white;
    border: 1px dashed #d1d5db;
    border-radius: 24px;
}

.page-choice-judge .pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.page-choice-judge .page-btn {
    padding: 8px 14px;
    border-radius: 40px;
    background: #f3f4f6;
    border: 1px solid #e5e7eb;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.9rem;
}

.page-choice-judge .page-btn.active {
    background: #2563eb;
    color: white;
    border-color: #2563eb;
}

.page-choice-judge .page-btn:hover:not(.active):not(:disabled) {
    background: #e5e7eb;
}

.page-choice-judge .page-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.page-choice-judge .page-info {
    color: #6b7280;
    font-size: 0.9rem;
    margin: 0 8px;
}

@media (max-width: 768px) {
    .page-choice-judge .navbar {
        flex-direction: column;
        align-items: stretch;
    }

    .page-choice-judge .nav-links {
        justify-content: center;
    }

    .page-choice-judge .filters-bar {
        flex-direction: column;
        align-items: stretch;
    }

    .page-choice-judge .filter-group {
        justify-content: space-between;
    }

    .page-choice-judge .filter-group-level {
        margin-right: 0;
    }

    .page-choice-judge .enter-program-btn {
        margin-left: 0;
        width: 100%;
    }

    .page-choice-judge .topic-grid {
        grid-template-columns: 1fr;
        justify-items: stretch;
    }

    .page-choice-judge .topic-card {
        width: 100%;
        max-width: 400px;
        justify-self: center;
    }

}