﻿/* TEAM CALENDAR */

.team-calendar-card {
    position: relative;
    padding: 1.25rem;
    border-radius: .75rem;
    overflow: hidden;
    background: linear-gradient( rgba(var(--color-banik-rgb), .30), rgba(var(--color-banik-rgb), .40) ), url('/images/academy/calendar-field.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    box-shadow: 0 .25rem .75rem rgba(0, 0, 0, .15);
}


/* =========================
   HORNÍ ČÁST
   ========================= */

.team-calendar-top {
    position: relative;
    z-index: 3;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
    color: #fff;
}

.team-calendar-category {
    display: flex;
    align-items: center;
    gap: .75rem;
    font-size: 2.4rem;
    font-weight: 800;
    line-height: 1;
    text-transform: uppercase;
}

.team-calendar-categories {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: .5rem;
}

.team-calendar-category-button {
    min-width: 54px;
    padding: .5rem .9rem;
    border: 1px solid rgba(255, 255, 255, .75);
    border-radius: .4rem;
    background: rgba(0, 0, 0, .18);
    color: #fff;
    font-size: .9rem;
    font-weight: 700;
    line-height: 1;
    transition: background-color .15s ease, color .15s ease;
}

    .team-calendar-category-button:hover {
        background: rgba(255, 255, 255, .18);
        color: #fff;
    }

    .team-calendar-category-button.active {
        background: #fff;
        border-color: #fff;
        color: var(--color-banik);
    }

.team-calendar-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, .15);
    color: #fff;
    font-size: .9rem;
    transition: background-color .15s ease;
}

    .team-calendar-nav:hover {
        background: rgba(255, 255, 255, .3);
    }

    .team-calendar-nav:focus {
        outline: none;
        box-shadow: 0 0 0 .15rem rgba(255, 255, 255, .25);
    }

.team-calendar-month {
    display: flex;
    align-items: center;
    gap: .75rem;
    color: #fff;
}

.team-calendar-month-title {
    min-width: 106px;
    text-align: center;
    font-family: 'Mukta', sans-serif;
    font-size: 2rem;
    font-weight: 800;
    line-height: .85;
    text-transform: uppercase;
    text-shadow: 0 2px 4px rgba(0, 0, 0, .25);
}

    .team-calendar-month-title span {
        display: block;
        margin-top: .3rem;
        font-size: 1.5rem;
    }

.team-calendar-month-button {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 0;
    border: 1px solid rgba(255, 255, 255, .7);
    border-radius: 50%;
    background: rgba(0, 0, 0, .15);
    color: #fff;
    transition: .15s ease;
}

    .team-calendar-month-button:hover {
        background: #fff;
        color: var(--color-banik);
    }


/* =========================
   TĚLO KALENDÁŘE
   ========================= */

.team-calendar-body {
    position: relative;
}

/* Velké FA logo uprostřed */

.team-calendar-watermark {
    position: absolute;
    z-index: 2;
    left: 50%;
    top: 52%;
    width: 42%;
    height: 82%;
    transform: translate(-50%, -50%);
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
    opacity: .16;
    pointer-events: none;
}


/* =========================
   GRID
   ========================= */

.team-calendar {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 4px;
}


/* =========================
   DNY V TÝDNU
   ========================= */

.team-calendar-header {
    min-width: 0;
    padding: .45rem .25rem;
    border: 1px solid rgba(255, 255, 255, .9);
    border-radius: .3rem;
    background: rgba(0, 60, 40, .55);
    color: #fff;
    text-align: center;
    font-size: .8rem;
    font-weight: 700;
}


/* =========================
   JEDNOTLIVÝ DEN
   ========================= */

.team-calendar-day {
    position: relative;
    z-index: 1;
    min-width: 0;
    min-height: 110px;
    padding: .45rem;
    border-radius: .35rem;
    background: rgba(255, 255, 255, .91);
    color: #111;
    overflow: hidden;
}


/*
    Obsah musí být nad watermarkem.
    Watermark má z-index 2 a samotná buňka 1.
*/

.team-calendar-date,
.team-calendar-match,
.team-calendar-training {
    position: relative;
    z-index: 3;
}


/* Datum */

.team-calendar-date {
    font-size: .95rem;
    font-weight: 700;
    line-height: 1;
    color: #344054;
}


/* Jiný měsíc */

.team-calendar-other-month {
    background: rgba(240, 244, 243, .82);
}

    .team-calendar-other-month .team-calendar-date,
    .team-calendar-other-month .team-calendar-match,
    .team-calendar-other-month .team-calendar-training {
        opacity: .4;
    }


/* Dnešek */

.team-calendar-today {
    background: linear-gradient( rgba(var(--color-banik-rgb), .70), rgba(var(--color-banik-rgb), .100) ), rgba(255, 255, 255, .91);
    border: 1px solid black;
}

    .team-calendar-today .team-calendar-date {
        color: black;
    }

/* =========================
   ZÁPAS
   ========================= */
.team-calendar-match {
    position: absolute;
    left: .45rem;
    right: .45rem;
    top: .45rem;
    bottom: .45rem;
    z-index: 3;
}

.team-calendar-match-info {
    position: absolute;
    left: 0;
    right: 38%;
    bottom: 0;
    line-height: 1.15;
}

.team-calendar-event-title {
    font-size: .82rem;
    font-weight: 800;
}

.team-calendar-team {
    margin-top: .15rem;
    font-size: .67rem;
    font-weight: 600;
    line-height: 1.15;
    overflow-wrap: normal;
    word-break: normal;
    hyphens: none;
}


/* Logo soupeře */

.team-calendar-logo-wrapper {
    position: absolute;
    top: 0;
    right: 0;
    width: 38px;
    height: 44px;
    display: flex;
    align-items: flex-start;
    justify-content: flex-end;
    overflow: hidden;
}

    .team-calendar-logo-wrapper img {
        display: block;
        width: 100%;
        height: 100%;
        max-width: 100%;
        max-height: 100%;
        object-fit: contain;
        object-position: top right;
    }


/* =========================
   TRÉNINK
   ========================= */

.team-calendar-training {
    position: absolute;
    left: .45rem;
    right: .45rem;
    bottom: .45rem;
    z-index: 3;
    line-height: 1.2;
}

.team-calendar-training-time {
    margin-top: .15rem;
    font-size: .76rem;
    font-weight: 500;
}

.team-calendar-location {
    margin-top: .1rem;
    font-size: .72rem;
}

.team-calendar-day.js-calendar-day {
    cursor: pointer;
}

.team-calendar-more {
    position: absolute;
    right: 4%;
    bottom: 4%;
    z-index: 4;
    width: 22%;
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--color-banik);
    color: #fff;
    font-size: .65rem;
    font-weight: 700;
    line-height: 1;
}

/* =========================
   MOBIL
   ========================= */

@media (max-width: 767.98px) {

    .team-calendar-card {
        padding: .4rem;
        border-radius: .5rem;
    }

    .team-calendar-more {
        font-size: .45rem;
    }

    /* Horní část */

    .team-calendar-top {
        margin-bottom: .75rem;
        margin-top: .75rem;
        padding: 0 .15rem;
    }

    .team-calendar-category {
        gap: .3rem;
        font-size: 1.25rem;
    }

    .team-calendar-categories {
        flex-wrap: nowrap;
        gap: .3rem;
        overflow-x: auto;
        scrollbar-width: none;
    }

        .team-calendar-categories::-webkit-scrollbar {
            display: none;
        }

    .team-calendar-category-button {
        flex: 0 0 auto;
        min-width: 32px;
        padding: .35rem .5rem;
        font-size: .65rem;
    }

    .team-calendar-nav {
        width: 1.5rem;
        height: 1.5rem;
        font-size: .6rem;
    }

    .team-calendar-month {
        gap: .25rem;
    }

    .team-calendar-month-title {
        min-width: 50px;
        font-size: 1rem;
    }

        .team-calendar-month-title span {
            margin-top: .15rem;
            font-size: .8rem;
        }

    .team-calendar-month-button {
        width: 26px;
        height: 26px;
        font-size: .65rem;
    }


    /* Grid */

    .team-calendar {
        gap: 2px;
    }


    /* Po–Ne */

    .team-calendar-header {
        padding: .25rem 0;
        border-radius: .2rem;
        font-size: .55rem;
    }


    /* Den */

    .team-calendar-day {
        min-height: 60px;
        padding: .22rem;
        border-radius: .22rem;
        position: relative;
    }

    .team-calendar-date {
        font-size: .62rem;
    }


    /* Zápas */

    .team-calendar-match {
        left: .22rem;
        right: .22rem;
        top: .22rem;
        bottom: .22rem;
    }

    .team-calendar-match-info {
        right: 32%;
    }

    .team-calendar-event-title {
        font-size: .6rem;
        line-height: 1.05;
    }

    .team-calendar-team {
        margin-top: .08rem;
        font-size: .42rem;
        line-height: 1.05;
        overflow-wrap: normal;
        word-break: normal;
        hyphens: none;
    }


    /* Logo soupeře */

    .team-calendar-logo-wrapper {
        top: 0;
        right: 0;
        width: 24px;
        height: 28px;
    }


    /* Trénink */

    .team-calendar-training {
        left: .22rem;
        right: .22rem;
        bottom: .22rem;
        line-height: 1.05;
    }

    .team-calendar-training-time {
        margin-top: .08rem;
        font-size: .5rem;
    }

    .team-calendar-location {
        margin-top: .08rem;
        font-size: .5rem;
    }


    /* Watermark */

    .team-calendar-watermark {
        width: 65%;
        height: 75%;
        opacity: .13;
    }
}

@media (min-width: 1200px) {
    .team-calendar-day {
        min-height: 94px;
    }

    .team-calendar-card {
        padding: 1rem;
    }
}