.comp-page {
    max-width: 56rem;
    margin: 0 auto;
    padding: 3rem 1.5rem 4rem;
}

.comp-page-hero,
.comp-detail-hero {
    margin-bottom: 2rem;
    text-align: center;
}

.comp-kicker {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #C8102E;
    margin-bottom: 0.5rem;
}

.comp-page-hero h1,
.comp-detail-hero h1 {
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 0.75rem;
}

.comp-page-hero p {
    color: #4b5563;
    max-width: 36rem;
    margin: 0 auto;
}

.comp-search {
    display: flex;
    gap: 0.5rem;
    max-width: 24rem;
    margin: 0 auto 2rem;
}

.comp-search input {
    flex: 1;
    padding: 0.65rem 1rem;
    border: 1px solid #e5e7eb;
    border-radius: 999px;
    font-size: 0.9rem;
}

.comp-search button {
    width: 2.75rem;
    height: 2.75rem;
    border-radius: 999px;
    background: #C8102E;
    color: #fff;
    border: none;
    cursor: pointer;
}

.comp-list-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(16rem, 1fr));
    gap: 1rem;
}

.comp-list-card {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 1.25rem;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    text-decoration: none;
    color: inherit;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.comp-list-card:hover {
    border-color: #C8102E;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
}

.comp-list-card-top {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.comp-list-level,
.comp-list-mod {
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    padding: 0.15rem 0.5rem;
    border-radius: 999px;
}

.comp-list-level { background: #ecfdf5; color: #1A5C4A; }
.comp-list-mod { background: #fef3c7; color: #92400e; }

.comp-list-card h3 {
    font-weight: 700;
    font-size: 1rem;
    line-height: 1.35;
}

.comp-list-meta {
    font-size: 0.8rem;
    color: #6b7280;
    margin: 0;
}

.comp-list-link {
    margin-top: auto;
    font-size: 0.8rem;
    font-weight: 600;
    color: #C8102E;
}

.comp-list-empty,
.comp-results-empty {
    text-align: center;
    color: #6b7280;
    padding: 2rem;
    background: #fff;
    border-radius: 0.75rem;
    border: 1px dashed #d1d5db;
}

.comp-back {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: #C8102E;
    text-decoration: none;
    margin-bottom: 1.5rem;
}

.comp-detail-badges {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

.comp-badge {
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.25rem 0.75rem;
    border-radius: 999px;
    background: #1A5C4A;
    color: #fff;
}

.comp-badge--mod { background: #F5C400; color: #111; }

.comp-detail-meta {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    font-size: 0.9rem;
    color: #4b5563;
    margin-top: 0.75rem;
}

.comp-detail-desc {
    margin-top: 1rem;
    color: #4b5563;
    line-height: 1.6;
    max-width: 40rem;
    margin-left: auto;
    margin-right: auto;
}

.comp-results-section h2 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #1A5C4A;
}

.comp-results-group {
    margin-bottom: 2rem;
}

.comp-results-group h3 {
    font-size: 1rem;
    font-weight: 700;
    color: #374151;
    margin-bottom: 0.75rem;
    padding-bottom: 0.35rem;
    border-bottom: 2px solid #fde68a;
}

.comp-results-table-wrap {
    overflow-x: auto;
    background: #fff;
    border-radius: 0.75rem;
    border: 1px solid #e5e7eb;
}

.comp-results-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.comp-results-table th,
.comp-results-table td {
    padding: 0.75rem 1rem;
    text-align: left;
    border-bottom: 1px solid #f3f4f6;
}

.comp-results-table th {
    background: #f9fafb;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #6b7280;
}

.comp-place {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-weight: 700;
}

.comp-medal--gold { color: #eab308; }
.comp-medal--silver { color: #9ca3af; }
.comp-medal--bronze { color: #d97706; }

.comp-athlete-link {
    font-weight: 600;
    color: #C8102E;
    text-decoration: none;
}

.comp-athlete-link:hover { text-decoration: underline; }

.comp-points { font-weight: 700; color: #1A5C4A; }
.comp-points--muted { color: #9ca3af; font-weight: 400; }
.comp-record { font-size: 0.85rem; color: #6b7280; }

.athlete-comp-link {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin-top: 0.5rem;
    font-size: 0.8rem;
    font-weight: 600;
    color: #C8102E;
    text-decoration: none;
}

.athlete-comp-link:hover { text-decoration: underline; }

.comp-pagination { display: none; }
.comp-pagination:not(.hidden) {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    margin-top: 2rem;
}

.comp-list-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.comp-list-summary article {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    padding: 1rem;
    text-align: center;
}

.comp-list-summary strong {
    display: block;
    font-size: 1.5rem;
    font-weight: 800;
    color: #C8102E;
}

.comp-list-summary span {
    font-size: 0.8rem;
    color: #6b7280;
}

.comp-filters {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    padding: 1rem 1.15rem;
    margin-bottom: 1.5rem;
    display: grid;
    gap: 0.85rem;
}

.comp-filter-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 0.75rem;
}

.comp-filter-label {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #6b7280;
    min-width: 5.5rem;
}

.comp-filter-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.comp-filter {
    font-size: 0.78rem;
    font-weight: 600;
    padding: 0.3rem 0.7rem;
    border-radius: 999px;
    border: 1px solid #e5e7eb;
    color: #374151;
    text-decoration: none;
    background: #f9fafb;
}

.comp-filter:hover {
    border-color: #C8102E;
    color: #C8102E;
}

.comp-filter--active {
    background: #C8102E;
    border-color: #C8102E;
    color: #fff;
}

.comp-status {
    font-size: 0.68rem;
    font-weight: 700;
    padding: 0.15rem 0.5rem;
    border-radius: 999px;
    text-transform: uppercase;
}

.comp-status--upcoming { background: #dbeafe; color: #1d4ed8; }
.comp-status--ongoing { background: #dcfce7; color: #166534; }
.comp-status--past { background: #f3f4f6; color: #6b7280; }
.comp-status--unknown { background: #fef3c7; color: #92400e; }

.comp-list-desc {
    font-size: 0.82rem;
    color: #6b7280;
    line-height: 1.45;
    margin: 0;
}

.comp-page--detail {
    max-width: 62rem;
}

.comp-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.comp-stat-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    padding: 1rem;
    text-align: center;
}

.comp-stat-card i {
    color: #1A5C4A;
    font-size: 1.1rem;
    margin-bottom: 0.35rem;
}

.comp-stat-value {
    font-size: 1.35rem;
    font-weight: 800;
    color: #111827;
    margin: 0;
}

.comp-stat-label {
    font-size: 0.72rem;
    color: #6b7280;
    margin: 0.15rem 0 0;
}

.comp-section-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    padding: 0.5rem;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 999px;
    justify-content: center;
}

.comp-section-nav a {
    font-size: 0.82rem;
    font-weight: 600;
    color: #374151;
    text-decoration: none;
    padding: 0.45rem 0.9rem;
    border-radius: 999px;
}

.comp-section-nav a:hover {
    background: #f3f4f6;
    color: #C8102E;
}

.comp-detail-section {
    margin-bottom: 2.5rem;
    scroll-margin-top: 5rem;
}

.comp-detail-section h2 {
    font-size: 1.2rem;
    font-weight: 700;
    color: #1A5C4A;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.comp-section-lead {
    font-size: 0.9rem;
    color: #6b7280;
    margin: -0.35rem 0 1rem;
}

.comp-overview-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.75rem;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    padding: 1rem;
}

.comp-overview-item {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.comp-overview-label {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    color: #9ca3af;
}

.comp-overview-value {
    font-size: 0.95rem;
    font-weight: 600;
    color: #111827;
}

.comp-participants-group {
    margin-bottom: 1.25rem;
}

.comp-participants-group h3 {
    font-size: 0.95rem;
    font-weight: 700;
    color: #374151;
    margin-bottom: 0.65rem;
}

.comp-participants-group h3 span {
    color: #9ca3af;
    font-weight: 600;
}

.comp-club-link {
    color: #1A5C4A;
    text-decoration: none;
}

.comp-club-link:hover {
    text-decoration: underline;
}

.comp-participants-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.comp-participant-chip {
    display: inline-flex;
    align-items: center;
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0.35rem 0.75rem;
    border-radius: 999px;
    background: #fff;
    border: 1px solid #e5e7eb;
    color: #C8102E;
    text-decoration: none;
}

.comp-participant-chip--plain {
    color: #374151;
}

.comp-participant-chip:hover {
    border-color: #C8102E;
}

@media (max-width: 768px) {
    .comp-stats-grid,
    .comp-overview-grid,
    .comp-list-summary {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}
