/* =========================================================
   BRAGA HALF MARATHON 2027
   RESULTS
========================================================= */


/* =========================================================
   RESET
========================================================= */

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: Arial, Helvetica, sans-serif;
    background: #ffffff;
    color: #26384c;
    line-height: 1.5;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    display: block;
    max-width: 100%;
}


/* =========================================================
   TOP BAR
========================================================= */

.identity-bar {
    min-height: 38px;
    background: #26384c;
    color: #ffffff;

    display: flex;
    align-items: center;
}

.identity-inner {
    width: min(1220px, 94%);
    margin: auto;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 20px;
}

.identity-place,
.identity-date {
    font-size: 10px;
    font-weight: 800;

    letter-spacing: .15em;
    text-transform: uppercase;
}

.identity-date {
    color: #e3c3c6;
}


/* =========================================================
   HEADER
========================================================= */

.site-header {
    position: relative;
    z-index: 100;

    background: #ffffff;

    border-bottom:
        1px solid rgba(38,56,76,.12);
}

.header-inner {
    width: min(1220px, 94%);
    min-height: 100px;

    margin: auto;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 30px;
}


/* =========================================================
   LOGO
========================================================= */

.brand {
    flex: 0 0 245px;
}

.brand img {
    width: 245px;
    height: auto;
}


/* =========================================================
   MAIN MENU
========================================================= */

.main-menu {
    flex: 1;

    display: flex;
    align-items: center;
    justify-content: flex-end;

    gap: 27px;
}

.main-menu > a,
.menu-dropdown-toggle {
    position: relative;

    min-height: 42px;

    display: inline-flex;
    align-items: center;

    border: 0;
    background: transparent;

    color: #26384c;

    font-family: inherit;
    font-size: 12px;
    font-weight: 900;

    letter-spacing: .07em;
    text-transform: uppercase;

    cursor: pointer;
}

.main-menu > a::after,
.menu-dropdown-toggle::after {
    content: "";

    position: absolute;

    left: 0;
    right: 0;
    bottom: 3px;

    height: 2px;

    background: #8b1d28;

    transform: scaleX(0);
    transform-origin: left;

    transition: transform .2s ease;
}

.main-menu > a:hover::after,
.main-menu > a.active::after,
.menu-dropdown-toggle:hover::after,
.menu-dropdown-toggle.active::after {
    transform: scaleX(1);
}


/* =========================================================
   INFO DROPDOWN
========================================================= */

.menu-dropdown {
    position: relative;
}

.menu-dropdown-toggle {
    gap: 7px;
}

.menu-dropdown-panel {
    position: absolute;

    top: calc(100% + 5px);
    left: 50%;

    width: 215px;

    background: #ffffff;

    border-top: 3px solid #8b1d28;

    box-shadow:
        0 12px 32px rgba(0,0,0,.16);

    opacity: 0;
    visibility: hidden;

    transform:
        translateX(-50%)
        translateY(-7px);

    transition:
        opacity .18s ease,
        transform .18s ease,
        visibility .18s ease;
}

.menu-dropdown.open .menu-dropdown-panel {
    opacity: 1;
    visibility: visible;

    transform:
        translateX(-50%)
        translateY(0);
}

.menu-dropdown-panel a {
    display: block;

    padding: 12px 17px;

    border-bottom:
        1px solid #eeeeee;

    color: #344353;

    font-size: 12px;
    font-weight: 700;
}

.menu-dropdown-panel a:last-child {
    border-bottom: 0;
}

.menu-dropdown-panel a:hover,
.menu-dropdown-panel a.active {
    background: #f7f3f2;
    color: #8b1d28;
}


/* =========================================================
   LANGUAGE
========================================================= */

.language-selector {
    position: relative;
}

.language-button {
    min-width: 72px;
    height: 38px;

    padding: 0 13px;

    border:
        1px solid #d6dbe0;

    background: #ffffff;
    color: #26384c;

    font-family: inherit;

    font-size: 11px;
    font-weight: 900;

    letter-spacing: .09em;

    cursor: pointer;

    display: flex;
    align-items: center;
    justify-content: center;

    gap: 7px;
}

.language-button:hover {
    border-color: #8b1d28;
    color: #8b1d28;
}

.language-panel {
    position: absolute;

    top: calc(100% + 7px);
    right: 0;

    width: 170px;

    background: #ffffff;

    border-top: 3px solid #8b1d28;

    box-shadow:
        0 10px 30px rgba(0,0,0,.17);

    opacity: 0;
    visibility: hidden;

    transform: translateY(-6px);

    transition:
        opacity .18s ease,
        visibility .18s ease,
        transform .18s ease;
}

.language-selector.open .language-panel {
    opacity: 1;
    visibility: visible;

    transform: translateY(0);
}

.language-panel a {
    display: block;

    padding: 11px 16px;

    border-bottom:
        1px solid #eeeeee;

    color: #344353;

    font-size: 12px;
    font-weight: 700;
}

.language-panel a:last-child {
    border-bottom: 0;
}

.language-panel a:hover {
    background: #f7f3f2;
    color: #8b1d28;
}


/* =========================================================
   HERO
========================================================= */

.inner-hero {
    position: relative;

    min-height: 390px;

    display: flex;
    align-items: center;

    overflow: hidden;

    background-image:
        linear-gradient(
            90deg,
            rgba(25,38,52,.84) 0%,
            rgba(25,38,52,.60) 34%,
            rgba(25,38,52,.18) 65%,
            rgba(25,38,52,.03) 100%
        ),
        url("../images/results.png");

    background-size: cover;
    background-position: center center;
}

.inner-hero-inner {
    width: min(1220px, 94%);
    margin: auto;

    position: relative;
    z-index: 3;
}

.inner-hero-copy {
    max-width: 630px;
    color: #ffffff;
}

.inner-eyebrow {
    margin-bottom: 12px;

    color: #e9cdd0;

    font-size: 11px;
    font-weight: 900;

    letter-spacing: .20em;
    text-transform: uppercase;
}

.inner-hero h1 {
    font-size:
        clamp(45px, 5vw, 68px);

    line-height: .98;

    font-weight: 900;

    letter-spacing: -.03em;

    text-transform: uppercase;
}

.inner-hero p {
    max-width: 570px;

    margin-top: 18px;

    font-size: 18px;
    line-height: 1.55;

    text-shadow:
        0 2px 9px rgba(0,0,0,.35);
}


/* =========================================================
   COUNTDOWN
========================================================= */

.countdown-section {
    background: #ffffff;

    border-bottom:
        1px solid #e7e7e7;
}

.mini-countdown {
    width: min(1180px, 94%);
    min-height: 82px;

    margin: auto;

    display: grid;

    grid-template-columns:
        1.35fr
        repeat(4, .7fr)
        1.25fr;

    align-items: stretch;
}

.mini-countdown > div {
    display: flex;

    flex-direction: column;

    align-items: center;
    justify-content: center;

    text-align: center;

    padding: 13px 12px;

    border-right:
        1px solid #eeeeee;
}

.mini-countdown > div:last-child {
    border-right: 0;
}

.countdown-intro {
    align-items: flex-start !important;

    text-align: left !important;

    padding-left: 5px !important;
}

.countdown-intro strong {
    color: #26384c !important;

    font-size: 13px !important;

    letter-spacing: .09em;

    text-transform: uppercase;
}

.countdown-intro span {
    color: #8b1d28 !important;

    font-size: 10px !important;
}

.mini-countdown strong {
    color: #8b1d28;

    font-size: 27px;
    line-height: 1;

    font-weight: 900;
}

.mini-countdown span {
    margin-top: 5px;

    color: #777777;

    font-size: 8px;
    font-weight: 800;

    letter-spacing: .12em;
    text-transform: uppercase;
}

.race-day {
    background: #26384c;
}

.mini-countdown .race-day strong {
    color: #ffffff;
    font-size: 16px;
}

.mini-countdown .race-day span {
    color: #e3c3c6;
}


/* =========================================================
   RESULTS INTRO
========================================================= */

.results-intro {
    padding: 78px 20px 70px;
    background: #ffffff;
}

.results-intro-inner {
    width: min(900px, 94%);
    margin: auto;

    text-align: center;
}

.section-eyebrow {
    color: #8b1d28;

    font-size: 11px;
    font-weight: 900;

    letter-spacing: .20em;
    text-transform: uppercase;
}

.results-intro h2 {
    margin-top: 12px;

    color: #26384c;

    font-size:
        clamp(32px, 3.5vw, 40px);

    line-height: 1.1;

    font-weight: 900;
}

.results-intro p {
    max-width: 780px;

    margin: 18px auto 0;

    color: #68727c;

    font-size: 16px;
    line-height: 1.75;
}


/* =========================================================
   OFFICIAL RESULTS
========================================================= */

.official-results-section {
    padding: 0 20px 88px;
    background: #ffffff;
}

.official-results-inner {
    width: min(1180px, 94%);
    margin: auto;
}

.results-year {
    padding: 30px 32px;

    background: #f5f2ef;

    border-top: 4px solid #8b1d28;

    text-align: center;
}

.results-year > p {
    color: #68727c;

    font-size: 14px;
    line-height: 1.65;
}

.results-race-selector {
    margin-top: 24px;

    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));

    gap: 14px;
}

.race-result-link {
    min-height: 86px;

    padding: 18px 20px;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    border: 1px solid rgba(38,56,76,.14);

    background: #ffffff;

    transition:
        background .18s ease,
        border-color .18s ease,
        color .18s ease,
        transform .18s ease;
}

.race-result-link strong {
    color: #8b1d28;

    font-size: 19px;
    font-weight: 900;
}

.race-result-link span {
    margin-top: 5px;

    color: #68727c;

    font-size: 11px;
    font-weight: 800;

    letter-spacing: .08em;
    text-transform: uppercase;
}

.race-result-link:hover,
.race-result-link.active {
    background: #26384c;
    border-color: #26384c;

    transform: translateY(-1px);
}

.race-result-link:hover strong,
.race-result-link.active strong,
.race-result-link:hover span,
.race-result-link.active span {
    color: #ffffff;
}


/* =========================================================
   RESULTS IFRAME
========================================================= */

.iframe-wrapper {
    margin-top: 28px;

    overflow: hidden;

    background: #ffffff;

    border:
        1px solid rgba(38,56,76,.13);

    box-shadow:
        0 10px 32px rgba(38,56,76,.10);
}

.iframe-wrapper iframe {
    display: block;

    width: 100%;
    min-height: 760px;

    border: 0;

    background: #ffffff;
}

.iframe-help {
    padding: 24px 20px 0;

    text-align: center;
}

.iframe-help p {
    color: #68727c;

    font-size: 14px;
    line-height: 1.65;
}

.official-results-button {
    min-width: 210px;
    min-height: 48px;

    margin-top: 18px;
    padding: 0 22px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    background: #8b1d28;
    color: #ffffff;

    border: 2px solid #8b1d28;

    font-size: 11px;
    font-weight: 900;

    letter-spacing: .10em;
    text-transform: uppercase;

    transition:
        background .18s ease,
        color .18s ease,
        border-color .18s ease;
}

.official-results-button:hover {
    background: #26384c;
    border-color: #26384c;
}


/* =========================================================
   2027 RESULTS
========================================================= */

.future-results {
    padding: 76px 20px;

    background: #f5f2ef;

    text-align: center;
}

.future-results-inner {
    width: min(900px, 94%);
    margin: auto;
}

.future-results span {
    color: #8b1d28;

    font-size: 10px;
    font-weight: 900;

    letter-spacing: .18em;
    text-transform: uppercase;
}

.future-results h2 {
    max-width: 780px;

    margin: 12px auto 0;

    color: #26384c;

    font-size:
        clamp(30px, 3.4vw, 43px);

    line-height: 1.12;

    font-weight: 900;
}

.future-results p {
    max-width: 720px;

    margin: 18px auto 0;

    color: #68727c;

    font-size: 15px;
    line-height: 1.75;
}


/* =========================================================
   RUNNING PORTUGAL
========================================================= */

.running-portugal-section {
    padding: 72px 20px;

    background: #26384c;
    color: #ffffff;
}

.running-portugal-inner {
    width: min(1180px, 94%);
    margin: auto;

    display: flex;
    align-items: center;

    gap: 48px;
}

.rp-mark {
    flex: 0 0 130px;

    width: 130px;
    height: 130px;

    display: flex;
    align-items: center;
    justify-content: center;

    border: 3px solid rgba(255,255,255,.55);

    color: #ffffff;

    font-size: 40px;
    font-weight: 900;

    letter-spacing: .04em;
}

.rp-copy {
    max-width: 900px;
}

.rp-copy > span {
    display: block;

    color: #e3c3c6;

    font-size: 11px;
    font-weight: 900;

    letter-spacing: .22em;
    text-transform: uppercase;
}

.rp-copy h2 {
    margin-top: 12px;

    color: #ffffff;

    font-size:
        clamp(30px, 3.2vw, 44px);

    line-height: 1.08;

    font-weight: 900;
}

.rp-copy p {
    max-width: 880px;

    margin-top: 14px;

    color: rgba(255,255,255,.82);

    font-size: 16px;
    line-height: 1.75;
}


/* =========================================================
   FOOTER
========================================================= */

.site-footer {
    background: #1d2c3b;
    color: #ffffff;
}

.footer-main {
    width: min(1760px, 92%);
    margin: auto;

    padding: 54px 0 48px;

    display: flex;
    align-items: flex-start;
    justify-content: space-between;

    gap: 50px;
}

.footer-brand,
.footer-event {
    display: flex;
    flex-direction: column;

    gap: 7px;
}

.footer-brand strong,
.footer-event strong {
    color: #ffffff;

    font-size: 16px;
    font-weight: 900;
}

.footer-brand span,
.footer-event span {
    color: rgba(255,255,255,.68);

    font-size: 14px;
    line-height: 1.5;
}

.footer-event {
    text-align: right;
}

.footer-disclaimer {
    border-top:
        1px solid rgba(255,255,255,.10);
}

.footer-disclaimer p {
    width: min(1180px, 92%);
    margin: auto;

    padding: 30px 0 34px;

    color: rgba(255,255,255,.56);

    font-size: 11px;
    line-height: 1.65;

    text-align: center;
}


/* =========================================================
   MOBILE BUTTON
========================================================= */

.mobile-toggle {
    display: none;
}


/* =========================================================
   TABLET
========================================================= */

@media (max-width: 980px) {

    .brand {
        flex-basis: 205px;
    }

    .brand img {
        width: 205px;
    }

    .main-menu {
        gap: 16px;
    }

    .main-menu > a,
    .menu-dropdown-toggle {
        font-size: 10px;
    }

    .mini-countdown {
        grid-template-columns:
            repeat(4, 1fr);
    }

    .countdown-intro,
    .race-day {
        grid-column: span 2;
    }

}


/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 760px) {

    .identity-inner {
        min-height: 42px;

        flex-direction: column;

        justify-content: center;

        gap: 2px;

        padding: 6px 0;
    }

    .header-inner {
        min-height: 82px;
    }

    .brand {
        flex: 0 0 180px;
    }

    .brand img {
        width: 180px;
    }

    .mobile-toggle {
        display: flex;

        width: 42px;
        height: 38px;

        align-items: center;
        justify-content: center;

        border:
            1px solid #d5dade;

        background: #ffffff;
        color: #26384c;

        font-size: 20px;

        cursor: pointer;
    }

    .main-menu {
        position: absolute;

        top: 100%;
        left: 0;

        width: 100%;

        display: none;

        flex-direction: column;

        align-items: stretch;

        gap: 0;

        background: #ffffff;

        border-top:
            1px solid #eeeeee;

        box-shadow:
            0 12px 25px rgba(0,0,0,.12);
    }

    .site-header.menu-open .main-menu {
        display: flex;
    }

    .main-menu > a,
    .menu-dropdown-toggle {
        width: 100%;

        min-height: 48px;

        justify-content: center;

        border-bottom:
            1px solid #eeeeee;
    }

    .main-menu > a::after,
    .menu-dropdown-toggle::after {
        display: none;
    }

    .menu-dropdown {
        width: 100%;
    }

    .menu-dropdown-panel {
        position: static;

        width: 100%;

        display: none;

        opacity: 1;
        visibility: visible;

        transform: none;

        box-shadow: none;

        border-top: 0;
    }

    .menu-dropdown.open
    .menu-dropdown-panel {
        display: block;
        transform: none;
    }

    .menu-dropdown-panel a {
        text-align: center;
        background: #f7f5f4;
    }

    .language-selector {
        margin-left: auto;
    }

    .inner-hero {
        min-height: 350px;

        align-items: flex-end;

        padding-bottom: 45px;

        background-image:
            linear-gradient(
                180deg,
                rgba(22,33,46,.12) 0%,
                rgba(22,33,46,.32) 40%,
                rgba(22,33,46,.88) 100%
            ),
            url("../images/results.jpg");

        background-position: center center;
    }

    .mini-countdown {
        grid-template-columns:
            repeat(4, 1fr);
    }

    .countdown-intro {
        grid-column: 1 / 5;

        min-height: 58px;

        align-items: center !important;

        text-align: center !important;

        border-bottom:
            1px solid #eeeeee;
    }

    .race-day {
        grid-column: 1 / 5;

        min-height: 58px;
    }

    .results-race-selector {
        grid-template-columns: 1fr;
    }

    .iframe-wrapper iframe {
        min-height: 640px;
    }

    .running-portugal-section {
        padding: 54px 20px;
    }

    .running-portugal-inner {
        flex-direction: column;
        align-items: flex-start;

        gap: 28px;
    }

    .rp-mark {
        flex-basis: 105px;

        width: 105px;
        height: 105px;

        font-size: 32px;
    }

    .rp-copy h2 {
        font-size: 32px;
    }

    .rp-copy p {
        font-size: 15px;
    }

    .footer-main {
        flex-direction: column;
        align-items: center;

        gap: 25px;

        padding: 38px 0 34px;

        text-align: center;
    }

    .footer-brand,
    .footer-event {
        align-items: center;
    }

    .footer-event {
        text-align: center;
    }

    .footer-disclaimer p {
        padding: 22px 12px 26px;
    }

}


/* =========================================================
   SMALL MOBILE
========================================================= */

@media (max-width: 520px) {

    .brand {
        flex-basis: 150px;
    }

    .brand img {
        width: 150px;
    }

    .language-button {
        min-width: 60px;
        padding: 0 9px;
    }

    .inner-hero h1 {
        font-size: 40px;
    }

    .mini-countdown > div {
        padding: 12px 4px;
    }

    .mini-countdown strong {
        font-size: 21px;
    }

    .mini-countdown span {
        font-size: 7px;
        letter-spacing: .06em;
    }

    .results-intro,
    .future-results {
        padding-left: 16px;
        padding-right: 16px;
    }

    .official-results-section {
        padding-left: 14px;
        padding-right: 14px;
    }

    .results-year {
        padding: 25px 18px;
    }

    .iframe-wrapper iframe {
        min-height: 560px;
    }

}
