/* =========================================================
   Juventude Vidigalense
   Rankings
   ========================================================= */

.rankings-page {
    --rankings-red: #e4002b;
    --rankings-red-dark: #b90023;
    --rankings-ink: #171717;
    --rankings-muted: #686868;
    --rankings-line: #e7e7e7;
    --rankings-surface: #f6f6f6;
    --rankings-white: #ffffff;

    background: #fff;
    color: var(--rankings-ink);
}

.rankings-page *,
.rankings-page *::before,
.rankings-page *::after {
    box-sizing: border-box;
}


/* ---------------------------------------------------------
   Shared
   --------------------------------------------------------- */

.rankings-eyebrow {
    display: block;
    margin-bottom: 9px;
    color: var(--rankings-red);
    font-size: 11px;
    font-weight: 800;
    line-height: 1.3;
    letter-spacing: 1.6px;
    text-transform: uppercase;
}

.rankings-eyebrow--light {
    color: rgba(255, 255, 255, .7);
}


/* ---------------------------------------------------------
   Hero
   --------------------------------------------------------- */

.rankings-hero {
    position: relative;
    overflow: hidden;
    padding: 80px 0 52px;
    background:
        radial-gradient(
            circle at 87% 28%,
            rgba(255, 255, 255, .075),
            transparent 23%
        ),
        linear-gradient(
            120deg,
            #101010 0%,
            #191919 58%,
            #292929 100%
        );
    color: #fff;
}

.rankings-hero::after {
    position: absolute;
    right: -105px;
    bottom: -205px;
    width: 330px;
    height: 330px;
    border: 48px solid var(--rankings-red);
    border-radius: 50%;
    content: "";
    pointer-events: none;
}

.rankings-hero__inner {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 50px;
}

.rankings-hero__content {
    max-width: 700px;
}

.rankings-hero h1 {
    margin: 0 0 13px !important;
    padding: 0 !important;
    color: #fff !important;
    font-size: 46px !important;
    font-weight: 800;
    line-height: 1.05 !important;
    letter-spacing: -1.1px;
    text-transform: none;
}

.rankings-hero__content p {
    max-width: 620px;
    margin: 0;
    color: rgba(255, 255, 255, .8);
    font-size: 16px;
    line-height: 1.6;
}

.rankings-hero__visual {
    display: flex;
    flex: 0 0 190px;
    flex-direction: column;
    align-items: center;
    gap: 11px;
    color: rgba(255, 255, 255, .7);
    font-size: 12px;
    font-weight: 700;
    text-align: center;
}

.rankings-hero__icon {
    display: flex;
    width: 82px;
    height: 82px;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255, 255, 255, .15);
    border-radius: 50%;
    background: rgba(255, 255, 255, .07);
    color: #fff;
    font-size: 30px;
}


/* ---------------------------------------------------------
   Main section
   --------------------------------------------------------- */

.rankings-section {
    padding: 70px 0 85px;
    background: #fff;
}

.rankings-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 35px;
    margin-bottom: 35px;
}

.rankings-heading > div:first-child {
    max-width: 700px;
}

.rankings-heading h2 {
    margin: 0 0 10px;
    color: var(--rankings-ink);
    font-size: 34px;
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -.5px;
}

.rankings-heading p {
    margin: 0;
    color: var(--rankings-muted);
    font-size: 15px;
    line-height: 1.65;
}


/* ---------------------------------------------------------
   Update status
   --------------------------------------------------------- */

.rankings-updated {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 10px;
    padding: 11px 14px;
    border: 1px solid var(--rankings-line);
    border-radius: 8px;
    background: var(--rankings-surface);
    color: #777;
    font-size: 11px;
    line-height: 1.35;
}

.rankings-updated i {
    color: var(--rankings-red);
    font-size: 13px;
}

.rankings-updated span,
.rankings-updated strong {
    display: block;
}

.rankings-updated strong {
    margin-top: 2px;
    color: #333;
}


/* ---------------------------------------------------------
   Ranking mode
   --------------------------------------------------------- */

.rankings-mode {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-width: 760px;
    gap: 10px;
    margin: 0 0 38px;
    padding: 6px;
    background: #f3f3f3;
    border: 1px solid #e5e5e5;
    border-radius: 12px;
}

.rankings-mode__button {
    display: flex;
    min-width: 0;
    min-height: 70px;
    align-items: center;
    gap: 13px;
    padding: 13px 17px;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 8px;
    color: #555;
    cursor: pointer;
    text-align: left;
    transition:
        background .2s ease,
        border-color .2s ease,
        box-shadow .2s ease,
        color .2s ease;
}

.rankings-mode__button > i {
    display: flex;
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(228, 0, 43, .07);
    color: var(--rankings-red);
    font-size: 15px;
}

.rankings-mode__button span {
    display: block;
    min-width: 0;
}

.rankings-mode__button strong,
.rankings-mode__button small {
    display: block;
}

.rankings-mode__button strong {
    color: #292929;
    font-size: 14px;
    font-weight: 800;
    line-height: 1.25;
}

.rankings-mode__button small {
    margin-top: 3px;
    color: #777;
    font-size: 11px;
    font-weight: 500;
    line-height: 1.3;
}

.rankings-mode__button.is-active {
    background: #fff;
    border-color: #ddd;
    box-shadow: 0 5px 15px rgba(0, 0, 0, .07);
}

.rankings-mode__button.is-active strong {
    color: var(--rankings-red);
}


/* ---------------------------------------------------------
   Panels
   --------------------------------------------------------- */

.rankings-panel {
    display: none;
}

.rankings-panel.is-active {
    display: block;
}


/* ---------------------------------------------------------
   Filters
   --------------------------------------------------------- */

.rankings-filter-group {
    min-width: 0;
}

.rankings-filter-label {
    display: block;
    margin-bottom: 8px;
    color: #777;
    font-size: 10px;
    font-weight: 800;
    line-height: 1.2;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.rankings-category-options {
    display: flex;
    width: 100%;
    flex-wrap: wrap;
    gap: 5px;
    padding: 5px;
    background: #f4f4f4;
    border: 1px solid #dfdfdf;
    border-radius: 9px;
}

.rankings-category {
    min-height: 39px;
    padding: 9px 15px;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 6px;
    color: #555;
    cursor: pointer;
    font-size: 12px;
    font-weight: 800;
    line-height: 1.2;
}

.rankings-category:hover,
.rankings-category:focus {
    color: var(--rankings-red);
    outline: none;
}

.rankings-category.is-active {
    background: #fff;
    border-color: #e2e2e2;
    box-shadow: 0 3px 10px rgba(0, 0, 0, .06);
    color: var(--rankings-red);
}

.rankings-filters-row {
    display: grid;
    grid-template-columns:
        minmax(300px, 1fr)
        minmax(260px, 305px);
    align-items: end;
    gap: 28px;
    margin-top: 20px;
}

.rankings-gender-options {
    display: inline-flex;
    padding: 4px;
    background: #f4f4f4;
    border: 1px solid #dfdfdf;
    border-radius: 8px;
}

.rankings-choice {
    display: inline-flex;
    min-height: 39px;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 9px 15px;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 5px;
    color: #555;
    cursor: pointer;
    font-size: 12px;
    font-weight: 800;
}

.rankings-choice:hover,
.rankings-choice:focus {
    color: var(--rankings-red);
    outline: none;
}

.rankings-choice.is-active {
    background: #fff;
    border-color: #e3e3e3;
    box-shadow: 0 3px 9px rgba(0, 0, 0, .06);
    color: var(--rankings-red);
}

.rankings-select {
    display: block;
    width: 100%;
    height: 47px;
    padding: 0 14px;
    background: #fff;
    border: 1px solid #dcdcdc;
    border-radius: 8px;
    color: #292929;
    font-family: inherit;
    font-size: 12px;
    font-weight: 700;
}

.rankings-select:focus {
    border-color: rgba(228, 0, 43, .55);
    outline: none;
    box-shadow: 0 0 0 3px rgba(228, 0, 43, .06);
}


/* ---------------------------------------------------------
   Ranking by event
   --------------------------------------------------------- */

.rankings-event-controls {
    display: grid;
    grid-template-columns:
        minmax(320px, 1.4fr)
        minmax(260px, .6fr);
    align-items: end;
    gap: 28px;
}

.rankings-select--large {
    max-width: 560px;
}

.rankings-event-note {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    max-width: 850px;
    margin-top: 20px;
    padding: 13px 15px;
    background: #f7f7f7;
    border-left: 3px solid var(--rankings-red);
    border-radius: 0 6px 6px 0;
    color: #666;
    font-size: 12px;
    line-height: 1.55;
}

.rankings-event-note i {
    flex: 0 0 auto;
    margin-top: 2px;
    color: var(--rankings-red);
}


/* ---------------------------------------------------------
   Summary
   --------------------------------------------------------- */

.rankings-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin: 24px 0 18px;
    padding: 16px 18px;
    background: #fafafa;
    border-left: 4px solid var(--rankings-red);
}

.rankings-summary > div {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 7px;
}

.rankings-summary strong {
    color: var(--rankings-red);
    font-size: 16px;
    font-weight: 800;
}

.rankings-summary > div span {
    color: #444;
    font-size: 12px;
    font-weight: 700;
}

.rankings-summary > span {
    flex: 0 0 auto;
    color: #777;
    font-size: 11px;
    font-weight: 800;
}


/* ---------------------------------------------------------
   Result groups / event blocks
   --------------------------------------------------------- */

.rankings-results {
    display: grid;
    gap: 24px;
}

.ranking-event {
    min-width: 0;
    overflow: hidden;
    border: 1px solid var(--rankings-line);
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 7px 24px rgba(0, 0, 0, .045);
}

.ranking-event__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 14px 18px;
    background: #1e1e1e;
    color: #fff;
}

.ranking-event__eyebrow {
    display: block;
    margin-bottom: 3px;
    color: rgba(255, 255, 255, .58);
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 1px;
    line-height: 1.2;
    text-transform: uppercase;
}

.ranking-event__header h3 {
    margin: 0 !important;
    color: #fff !important;
    font-size: 18px !important;
    font-weight: 800;
    line-height: 1.2 !important;
}

.ranking-event__count {
    flex: 0 0 auto;
    padding: 6px 9px;
    border: 1px solid rgba(255, 255, 255, .15);
    border-radius: 999px;
    background: rgba(255, 255, 255, .05);
    color: rgba(255, 255, 255, .72);
    font-size: 10px;
    font-weight: 800;
    white-space: nowrap;
}


/* ---------------------------------------------------------
   Ranking tables
   --------------------------------------------------------- */

.rankings-table-wrap {
    width: 100%;
    overflow-x: auto;
    background: #fff;
    -webkit-overflow-scrolling: touch;
}

.rankings-table {
    width: 100%;
    min-width: 900px;
    margin: 0;
    border-collapse: collapse;
    border-spacing: 0;
    background: #fff;
    table-layout: auto;
}

.rankings-table thead {
    background: #f7f7f7;
}

.rankings-table th {
    padding: 13px 15px;
    border: 0;
    border-bottom: 1px solid #e5e5e5;
    color: #777;
    font-size: 10px;
    font-weight: 800;
    line-height: 1.2;
    letter-spacing: .65px;
    text-align: left;
    text-transform: uppercase;
    white-space: nowrap;
}

.rankings-table td {
    padding: 13px 15px;
    border: 0;
    border-bottom: 1px solid #eeeeee;
    color: #4f4f4f;
    font-size: 13px;
    line-height: 1.45;
    vertical-align: middle;
}

.rankings-table tbody tr:last-child td {
    border-bottom: 0;
}

.rankings-table tbody tr:hover {
    background: #fbfbfb;
}

.rankings-table__position {
    width: 52px;
    color: #999 !important;
    font-size: 11px !important;
    font-weight: 800;
    text-align: center !important;
}

.rankings-table__athlete-heading {
    min-width: 270px;
}

.rankings-table__athlete {
    min-width: 270px;
    max-width: 480px;
    color: #202020 !important;
    font-weight: 700;
    white-space: normal;
    overflow-wrap: break-word;
    word-break: normal;
}

.rankings-table__category-heading {
    width: 115px;
}

.rankings-table__year-heading,
.rankings-table__year {
    width: 78px;
    white-space: nowrap;
}

.rankings-table__mark-heading,
.rankings-table__mark {
    width: 105px;
    white-space: nowrap;
}

.rankings-table__mark {
    color: var(--rankings-red) !important;
    font-size: 14px !important;
    font-weight: 800;
}

.rankings-table__wind-heading,
.rankings-table__wind {
    width: 80px;
    white-space: nowrap;
}

.rankings-table__location-heading {
    min-width: 135px;
}

.rankings-table__location {
    min-width: 135px;
}

.rankings-table__date-heading,
.rankings-table__date {
    width: 115px;
    white-space: nowrap;
}


/* ---------------------------------------------------------
   Category badge
   --------------------------------------------------------- */

.rankings-category-badge {
    display: inline-flex;
    align-items: center;
    padding: 5px 8px;
    background: rgba(228, 0, 43, .07);
    border-radius: 999px;
    color: #c60026;
    font-size: 10px;
    font-weight: 800;
    white-space: nowrap;
}


/* ---------------------------------------------------------
   Empty / error
   --------------------------------------------------------- */

.rankings-empty,
.rankings-error {
    padding: 42px;
    border: 1px solid var(--rankings-line);
    border-radius: 10px;
    background: var(--rankings-surface);
}

.rankings-empty {
    text-align: center;
}

.rankings-empty i {
    margin-bottom: 12px;
    color: #ccc;
    font-size: 27px;
}

.rankings-empty h3,
.rankings-error h3 {
    margin: 0 0 7px;
    color: var(--rankings-ink);
    font-size: 19px;
    font-weight: 800;
}

.rankings-empty p,
.rankings-error p {
    margin: 0;
    color: var(--rankings-muted);
    font-size: 13px;
}

.rankings-error {
    display: flex;
    max-width: 760px;
    align-items: flex-start;
    gap: 18px;
    margin: 0 auto;
}

.rankings-error > i {
    color: var(--rankings-red);
    font-size: 27px;
}


/* ---------------------------------------------------------
   Tablet
   --------------------------------------------------------- */

@media (max-width: 991px) {

    .rankings-hero {
        padding: 44px 0 48px;
    }

    .rankings-hero h1 {
        font-size: 41px !important;
    }

    .rankings-hero__visual {
        display: none;
    }

    .rankings-heading {
        align-items: flex-start;
        flex-direction: column;
    }

    .rankings-updated {
        width: auto;
    }

    .rankings-types {
        grid-template-columns: 1fr;
    }

    .rankings-filters-row,
    .rankings-event-controls {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .rankings-select--large {
        max-width: none;
    }

}


/* ---------------------------------------------------------
   Mobile
   --------------------------------------------------------- */

@media (max-width: 767px) {

    .rankings-hero {
        padding: 34px 0 38px;
    }

    .rankings-hero::after {
        right: -155px;
        bottom: -190px;
        width: 290px;
        height: 290px;
        border-width: 42px;
    }

    .rankings-hero h1 {
        font-size: 34px !important;
    }

    .rankings-hero__content p {
        font-size: 15px;
    }

    .rankings-section {
        padding: 52px 0 65px;
    }

    .rankings-heading {
        margin-bottom: 28px;
    }

    .rankings-heading h2 {
        font-size: 28px;
    }

    .rankings-updated {
        width: 100%;
    }

    .rankings-mode {
        grid-template-columns: 1fr;
        max-width: none;
    }

    .rankings-mode__button {
        min-height: 62px;
    }

    .rankings-category-options {
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .rankings-category {
        flex: 0 0 auto;
    }

    .rankings-gender-options {
        display: flex;
        width: 100%;
    }

    .rankings-choice {
        flex: 1;
    }

    .rankings-summary {
        align-items: flex-start;
        flex-direction: column;
        gap: 7px;
    }

    .ranking-event__header {
        padding: 13px 15px;
    }

    .ranking-event__header h3 {
        font-size: 16px !important;
    }

    .rankings-event-note {
        font-size: 11px;
    }

    .rankings-table {
        min-width: 820px;
    }

    .rankings-table th,
    .rankings-table td {
        padding: 12px 13px;
    }

    .rankings-table__athlete {
        min-width: 240px;
        max-width: 380px;
    }

}


/* ---------------------------------------------------------
   Very small
   --------------------------------------------------------- */

@media (max-width: 479px) {

    .rankings-mode__button {
        padding: 12px 14px;
    }

    .rankings-category-options {
        margin-right: -15px;
        margin-left: -15px;
        width: auto;
        padding-right: 15px;
        padding-left: 15px;
        border-right: 0;
        border-left: 0;
        border-radius: 0;
    }

    .rankings-table {
        min-width: 780px;
    }

}
