/*
 Theme Name:   UAE Team ADQ
 Theme URI:    https://xioagency.com
 Description:  Custom theme for UAE Team ADQ
 Author:       XIO Agency
 Author URI:   https://xioagency.com
 Template:     hello-elementor
 Version:      1.0
 License:      GNU General Public License v2 or later
 License URI:  http://www.gnu.org/licenses/gpl-2.0.html
 Text Domain:  hello-elementor-child
*/

.xio-hidden {
    display: none !important;
}

a {
    color: var(--e-global-color-accent);
}

footer,
.xio-bg-gr {
    background: linear-gradient(170deg, #081F59 0%, #895881 40%, #D18655 80%, #D5AD61 95%);
}

/* Banner Follow Us*/
.xio-follow-us::after {
    background: linear-gradient(170deg, #081F59 0%, #895881 40%, #D18655 80%, #D5AD61 95%);
    content: '';
    display: inline-block;
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    mix-blend-mode: multiply;
}

/* Single Rider */
.xio-riders-bg {
    background: linear-gradient(90deg, #081F59 0%, #895881 20%, #D18655 40%, #D5AD61 60%, #fff 60%);
}

@media (max-width: 768px) {
    .xio-riders-bg {
        background: linear-gradient(90deg, #081F59 0%, #895881 20%, #D18655 40%, #D5AD61 60%, #fff 60%);
    }
}

.xio-raider-quote::after,
.xio-raider-quote::before {
    content: url("/wp-content/themes/uaeteamadq/assets/image/quote-uae.svg");
    width: 100%;
    opacity: .3;
    display: inline-block;
}

.xio-raider-quote::after {
    transform: rotate(180deg);
}

.xio-raider-quote .elementor-widget-container {
    height: fit-content !important;
    right: 0;
}

/* STAFF */
.staff-section {
    margin: 3em 0;
}

.staff-role-title h2 {
    font-size: 25px;
    font-weight: bold;
    color: var(--e-global-color-primary);
    margin: 0;
}

/* Contenedor general */
.staff-member {
    display: flex;
    flex-direction: column;
    width: calc(100% / 4 - 20px);
    gap: 10px;
}

.staff-member h3 {
    font-size: 18px;
    font-weight: bold;
    margin: 0;
}

.staff-member h3 a {
    color: var(--e-global-color-primary) !important;
    text-transform: uppercase !important;
}

.staff-member h3 a:hover {
    color: var(--e-global-color-primary) !important;
    text-decoration: none;
}

.group-staff {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 2em;
}

/* Imagen destacada */
.staff-feature-image img {
    width: 100%;
    object-fit: cover;
    object-position: top;
    border-radius: 10px !important;
    height: 350px !important;
}

/* Título y posición */
.staff-position {
    font-size: 14px;
    font-weight: bold;
    color: var(--e-global-color-642d59f);
    margin: 0px;
}

.collapse-toggle {
    font-size: 18px;
    font-weight: bold;
    color: #0073aa;
    text-decoration: none;
    cursor: pointer;
}

.collapse-toggle:hover {
    text-decoration: underline;
}

/* Contenido colapsable */
.collapse-content {
    margin-top: 16px;
    display: none;
    /* Oculto por defecto */
}

.collapse-content.active {
    display: block;
}

/* Fila de colapso */
.collapse-row {
    width: 100%;
    background-color: var(--e-global-color-cc91e23);
    border-radius: 10px;
    padding: 20px;
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-content: center;
    position: relative;
}

/* Columna izquierda (60%) */
.collapse-left {
    width: 60%;
    padding-right: 16px;
    color: #fff;
}

.staff-description {
    line-height: 1.6;
    margin-bottom: 16px;
    color: #fff;
    font-size: 15px;
}

/* Redes sociales */
.staff-socials {
    display: flex;
    gap: 8px;
}

.social-icon {
    display: inline-block;
    font-size: 25px;
    color: #fff;
    text-align: center;
    line-height: 32px;
    border-radius: 50%;
}

/* Iconos individuales */

/* Columna derecha (40%) */
.collapse-right {
    width: 40%;
}

.staff-quote {
    font-size: 16px;
    font-style: italic;
    color: #fff;
}

.staff-quote::after,
.staff-quote::before {
    content: url("/wp-content/themes/uaeteamadq/assets/image/quote-uae.svg");
    width: 100%;
    opacity: .3;
    display: inline-block;
}

.staff-quote::after {
    transform: rotate(180deg);
}

/* Responsive */
@media (max-width: 768px) {
    .staff-member {
        width: calc(100% / 2 - 20px);
    }

    .collapse-left,
    .collapse-right {
        width: 100%;
        padding-right: 0;
    }

    .collapse-row {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .staff-member {
        width: 100%;
    }
}


/* Footer Sponsors*/

.sponsor-grid {
    display: flex;
    flex-direction: column;
    gap: 10px;
    text-align: center;
    margin: 20px 0;
    align-items: center;
}

.logo-header {
    justify-content: center;
    max-width: 30%;
}

.main-sponsors,
.regular-sponsors {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px 50px;
    width: 100%;
}

.main-sponsors .sponsor-item img {
    width: auto;
    max-width: 160px;
    height: 80px;
    object-fit: contain;
}

.regular-sponsors .sponsor-item img {
    width: auto;
    max-width: 80px;
    height: 60px;
    object-fit: contain;
}

@media (max-width: 768px) {

    .main-sponsors,
    .regular-sponsors {
        gap: 10px 20px;
    }

    .main-sponsors .sponsor-item img {
        max-width: 80px;
        height: 60px;
    }

    .regular-sponsors .sponsor-item img {
        max-width: 60px;
        height: 40px;
    }
}


/* Banner Page */

.xio-banner-page {
    height: 75vh !important;
}

@media (max-width: 768px) {
    .xio-banner-page {
        height: 30vh !important;
    }

}

/* Contenedor principal */
#xio-posts-container {
    display: grid;
    grid-template-areas:
        "large small-1"
        "large small-2";
    grid-template-columns: 1fr 1.2fr;
    gap: 30px;
    margin: 20px 0;
}

/* Post grande (izquierda) */
.xio-post-large {
    background: #ffffff;
    border-radius: 10px;
}

.xio-post-large:hover,
.xio-post-small:hover {
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    transition-duration: 0.5s;
}

.xio-post-large:hover h2,
.xio-post-small:hover h2 {
    color: var(--e-global-color-cc91e23);
    transition-duration: 0.2s;
}

.xio-post-content {
    padding: 20px;
}

.xio-post-content h2 {
    color: var(--e-global-color-primary);
}

.xio-post-content p {
    font-size: 16px;
    color: var(--e-global-color-text);
}

.xio-post-large img,
.xio-post-small img {
    aspect-ratio: 549 / 398;
}

.xio-post-small .xio-post-image {
    width: 60%;
}

.xio-post-small .xio-post-content {
    width: 40%;
}

.xio-post-image img {
    border-radius: 10px !important;
    width: 100% !important;
    height: auto !important;
    object-fit: cover !important;
}

.xio-post-large h2 {
    font-size: 30px;
    font-weight: bold;
    color: var(--e-global-color-primary);
    margin: 10px 0;
}

/* Posts pequeños (derecha) */
.xio-post-small {
    background: #ffffff;
    border-radius: 8px;
    display: flex;
    flex-direction: row;
    align-items: flex-start;
}

.xio-post-content {
    align-self: center;
}

.xio-post-small h2 {
    font-size: 22px;
    font-weight: bold;
    margin: 8px 0;
}

/* Fechas */
.xio-post-large .post-date,
.xio-post-small .post-date {
    font-size: 14px;
    color: var(--e-global-color-642d59f);
    margin-bottom: 10px;
}

/* Paginación */
/* Contenedor principal del paginador */
#xio-post-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin: 20px 0;
    font-family: Arial, sans-serif;
}

/* Botones Prev y Next */
.xio-pagination-btn {
    padding: 5px 10px;
    background: none;
    border: none;
    font-size: 20px;
    color: #333;
    cursor: pointer;
    transition: color 0.3s;
}

.xio-pagination-btn:disabled {
    color: #ccc;
    cursor: not-allowed;
}

.xio-pagination-btn:hover:not(:disabled) {
    color: #0073aa;
}

/* Números de página */
.xio-pagination-numbers {
    display: flex;
    list-style: none;
    padding: 0;
    margin: 0;
    gap: 10px;
}

.xio-pagination-number {
    font-size: 16px;
    font-weight: bold;
    color: var(--e-global-color-text);
    cursor: pointer;
    transition: color 0.3s;
    border-bottom: 2px solid transparent;
}

.xio-pagination-number.active {
    color: var(--e-global-color-accent);
    border-color: var(--e-global-color-accent);
    cursor: default;
}

.xio-pagination-number:hover:not(.active) {
    color: var(--e-global-color-accent);
    border-color: var(--e-global-color-accent);
}


/* Responsive */
@media (max-width: 768px) {
    #xio-posts-container {
        grid-template-areas:
            "large"
            "small-1"
            "small-2";
        grid-template-columns: 1fr;
    }

    .xio-post-small {
        flex-direction: column;
    }

    .xio-post-small .xio-post-image,
    .xio-post-small .xio-post-content {
        width: 100%;
    }
}


/* Single race */

.xio-race-container {
    display: flex;
    margin: auto;
    gap: 20px;

    & .xio-race-stages {
        width: 50%;
    }

    & .xio-stage {
        border-bottom: 2px solid #e00000;
    }

    & .xio-toggle {
        width: 100%;
        text-align: left;
        background: none;
        border: none;
        padding: 10px;
        font-size: 16px;
        cursor: pointer;
        outline: none;
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    & .xio-toggle-icon {
        transition: transform 0.3s ease;
    }

    & .xio-content {
        display: none;
        padding: 10px;
        border-radius: 5px;
    }

    & .xio-result {
        display: flex;
        align-items: center;
        padding: 10px;
        background: var(--e-global-color-9a2cd0f);
        border-radius: 5px;
        font-size: 14px;
        font-weight: bold;
        margin-bottom: 5px;
    }

    & .xio-position {
        font-size: 18px;
        margin-right: 10px;
    }

    & .xio-country {
        margin-right: 10px;
        text-transform: uppercase;
    }

    & .xio-rider-name {
        margin-left: auto;
    }

    & .xio-rider-name a {
        color: var(--e-global-color-primary) !important;
    }

    & .xio-rider-name a {
        position: relative;
        color: var(--e-global-color-primary) !important;
        text-decoration: none;
    }

    & .xio-rider-link {
        color: var(--e-global-color-primary) !important;

        & .xio-rider-country {
            font-size: 16px;
        }

        & .xio-rider-name {
            font-weight: bold;
        }

        & h4 {
            font-size: 18px;
        }
    }

    & .xio-rider-name a::after {
        content: '';
        position: absolute;
        left: 0;
        bottom: -2px;
        width: 100%;
        height: 2px;
        background-color: var(--e-global-color-primary);
        transform: scaleX(0);
        transform-origin: left;
        transition: transform 0.3s ease;
    }

    & .xio-rider-name a:hover::after {
        transform: scaleX(1);
    }

    & .xio-rider-slider-container {
        width: 50%;
        position: relative;
        overflow: hidden;
    }

    & p.xio-rider-country {
        font-size: 16px;
    }

    & h3.xio-rider-name {
        font-weight: bold;
    }

    & .swiper-container.xio-rider-slider {
        width: 100%;
        max-width: 300px;
        margin: auto;
    }

    & .swiper-slide {
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    & .swiper-slide img {
        width: 200px;
        border-radius: 10px;
    }

    & .swiper-button-prev,
    .swiper-button-next {
        color: #000;
    }

}



/* Single Rider - Results */

.xio-timeline {
    margin: 20px auto;

    & .xio-timeline-year {
        position: relative;
        margin: 40px 0 20px;
    }

    & .xio-timeline-year h2 {
        font-size: 48px;
        color: var(--e-global-color-primary);
        margin: 0;
        padding-left: 60px;
    }

    & .xio-timeline-year h2::before {
        content: "";
        position: absolute;
        left: 0;
        top: 50%;
        transform: translateY(-50%);
        width: 40px;
        height: 40px;
        background: linear-gradient(170deg, #081F59 0%, #895881 40%, #D18655 80%, #D5AD61 95%);
        clip-path: polygon(0 0, 100% 50%, 0 100%);
    }

    & .xio-timeline-item {
        margin-bottom: 30px;
    }

    & .xio-item-date {
        font-size: 16px;
        font-weight: 500;
        color: #999;
        margin-bottom: 8px;
    }

    & .xio-item-card {
        background: #fff;
        border: 1px solid #ddd;
        border-radius: 5px;
        padding: 15px 20px;
        box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    }

    & .xio-race-logo img {
        height: 30px;
        object-fit: contain;
        display: block;
        margin-bottom: 10px;
    }

    & .xio-race-name {
        margin: 0 0 5px;
        font-size: 20px;
        color: #333;
    }

    & .xio-stage-details {
        margin: 0 0 5px;
        color: #555;
    }

    & .xio-race-type {
        margin: 0 0 5px;
        font-weight: bold;
        color: #666;
    }

    & .xio-position {
        margin: 0;
        font-weight: bold;
        color: var(--e-global-color-cc91e23);
    }
}


.xio_calendar__navigation--wrapper {
    display: flex;
    flex-wrap: nowrap;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    padding: 10px 20px;
    border-radius: 8px;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.1);
}

.xio_calendar__table--main,
.xio_calendar__table--main th,
.xio_calendar__table--main td {
    border: none !important;
}

.xio_calendar__table-cell--link {
    display: flex;
    justify-content: space-around;
    align-items: center;
    flex-direction: row;
    flex-wrap: nowrap;
}

table.xio_calendar__table--main tbody>tr:nth-child(odd)>td {
    background: transparent;
}

.xio_calendar__button--prev::before {
    content: "\2190";
    display: inline-block;
    font-size: 20px;
    margin-right: 5px;
}

.xio_calendar__button--next::after {
    content: "\2192";
    display: inline-block;
    font-size: 20px;
    margin-left: 5px;
}

.xio_calendar__button--prev,
.xio_calendar__button--next {
    cursor: pointer;
    padding: 8px 12px;
    color: var(--e-global-color-primary);
    font-weight: bold;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    transition: all 0.3s ease;
    border: none;
}

.xio_calendar__button--prev:hover,
.xio_calendar__button--next:hover {
    color: var(--e-global-color-accent);
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.05);
}

.xio_calendar__current--display {
    font-size: 20px;
    font-weight: bold;
    color: var(--e-global-color-primary);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.xio_calendar__table--wrapper {
    width: 100%;
    margin: 20px auto;
    border-collapse: collapse;
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0px 4px 12px rgba(0, 0, 0, 0.1);
}

.xio_calendar__table-row--header {
    background: linear-gradient(170deg, #081F59 0%, #895881 40%, #D18655 80%, #D5AD61 95%);
    color: #fff;
    font-weight: bold;
}

.xio_calendar__table-row--header th {
    padding: 16px;
    font-weight: bold;
    text-align: left;
    font-size: 16px;
    text-transform: uppercase;
}

.xio_calendar__table-row--item {
    transition: background-color 0.3s ease, transform 0.2s ease;
}

.xio_calendar__table-row--item:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.xio_calendar__table-cell--item {
    padding: 14px 18px;
    vertical-align: middle;
}

.xio_calendar__table-cell--logo {
    width: 80px;
    text-align: center;
}

.xio_calendar__table-cell--logo img {
    max-height: 45px;
    max-width: 70px;
    object-fit: contain;
    border-radius: 4px;
    transition: transform 0.3s ease;
}

.xio_calendar__table-cell--logo img:hover {
    transform: scale(1.1);
}

.xio_calendar__table-cell--link {
    display: flex;
}

.xio_calendar__no-results--text {
    display: flex;
    align-items: center;
    flex-direction: column;
    padding: 10px 0 0;
}

/* Responsive */
@media (max-width: 768px) {
    .xio_calendar__navigation--wrapper {
        flex-direction: column;
        gap: 10px;
    }

    .xio_calendar__table--wrapper {
        display: block;
        overflow-x: auto;
        border-radius: 6px;
    }

    .xio_calendar__table-cell--item {
        padding: 12px;
    }

    .xio_calendar__table-cell--logo {
        width: 60px;
    }
}

/* Race calendar race name link style */
.xio_calendar__race-link {
    text-decoration: underline;
    color: inherit;
}

.xio_calendar__race-link:hover {
    opacity: 0.8;
}