:root {
    --radius: 10px;
    --background-color: #ffffff;
    --card-color: #f6f6f6;
    --hover-color: #fafafa;
    --primary-color: #d0ebff;
    --icon-color: #6e6e6e;
    --text-color: #121212;
}

html[theme="dark"] {
    --background-color: #282828;
    --card-color: #383838;
    --hover-color: #454545;
    --primary-color: #4f8aab;
    --icon-color: #a6a6a6;
    --text-color: #e9e9e9;
}

html {
    font-family: "Montserrat", sans-serif;
    overflow-y: scroll;
    background-color: var(--background-color);
    color: var(--text-color);
}

a,
a:visited,
a:hover,
a:active,
a:focus {
    text-decoration: none;
    color: inherit;
    display: inline;
}

.hover:hover {
    background-color: var(--hover-color);
    border-radius: var(--radius);
}

.pointer:hover {
    cursor: pointer;
}

.match_card {
    justify-content: space-between;
    display: grid;
    grid-template-areas:
        "hl home hp hs schedule"
        "al away ap as schedule";
    grid-template-columns: 2rem 10fr 2rem 2rem 4.2rem;
    background-color: var(--card-color);
    border-radius: var(--radius);
}

.hl {
    grid-area: hl;
}

.home {
    grid-area: home;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.hp {
    grid-area: hp;
}

.hs {
    grid-area: hs;
}

.al {
    grid-area: al;
}

.away {
    grid-area: away;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.ap {
    grid-area: ap;
}

.as {
    grid-area: as;
}

.hl,
.al {
    align-self: center;
    display: flex;
}

.hs,
.hp,
.as,
.ap {
    text-align: center;
    align-self: center;
}

.schedule {
    grid-area: schedule;
    text-align: center;
    border-left: 0.01px solid;
    align-self: center; 
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%;
}

.event_item {
    flex: 1;
}

.shaded > *:nth-child(2n) {
    background-color: var(--card-color);
}

.teams_row {
    width: 12rem;
}

.stat {
    white-space: pre-line;
    flex: 1 0 0;
}

.event {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.team_and_logo {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 30%;
    text-align: center;
}

.match_header {
    display: flex;
    justify-content: center;
    align-items: center;
}

.match_status {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 20%;
}

.loader_dots {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    height: 40px;
}

.loader_dots>span {
    width: 10px;
    height: 10px;
    background: var(--primary-color);
    border-radius: 50%;
    animation: bounce 1.4s infinite ease-in-out both;
}

.loader_dots span:nth-child(1) {
    animation-delay: -0.32s;
}

.loader_dots span:nth-child(2) {
    animation-delay: -0.16s;
}

.loader_dots span:nth-child(3) {
    animation-delay: 0;
}

@keyframes bounce {

    0%,
    100% {
        transform: scale(0);
    }

    50% {
        transform: scale(1);
    }
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    margin: 0;
}

@media screen and (min-width: 800px) {
    body {
        width: 80vw;
        max-width: 1000px;
        margin-left: auto;
        margin-right: auto;
        display: grid;
        grid-template-columns: minmax(0, 1fr) 3fr;
        grid-template-rows: auto 1fr auto;
        grid-template-areas:
            "header header"
            "sidebar main"
            "footer footer";
    }
}

.period_delimiter {
    height: 0.5px;
    border: none;
    background-color: var(--text-color);
}

header {
    grid-area: header;
    border-bottom: 0.01rem solid;
}

main {
    flex: 1;
}

aside {
    grid-area: sidebar;
    display: flex;
    flex-direction: column;
}

main {
    grid-area: main;
}

footer {
    grid-area: footer;
    border-top: 0.01rem solid;
}

.standings_teams {
    flex-grow: 1;
    flex-shrink: 1;
    flex-basis: auto;
}

.standings_stats {
    overflow-x: auto;
    flex-grow: 1;
    flex-shrink: 1;
    flex-basis: auto;
    width: max-content;
}

.standings_teams> :nth-child(even),
.standings_stats> :nth-child(even),
.standings_stats> :nth-child(even)>* {
    background-color: var(--card-color);
}

.stat_cell {
    flex: 0 0 2rem;
    text-align: center;
}

.stat_padding {
    flex: 1 1 0;
}

.section {
    border-bottom: 0.1px solid;
}

.tabbar {
    display: flex;
    justify-content: center;
    align-items: center;
}

.tab {
    background-color: var(--card-color);
}

a.tab {
    border-radius: var(--radius);
    padding: 0.25rem 0.75rem;
}

a.tab.selected {
    background-color: var(--primary-color);
}

.score_label {
    text-align: center;
}

.country {
    background-color: var(--card-color);
    border-radius: var(--radius);
}

.main_leagues {
    border: 0.01px solid;
    border-radius: var(--radius);
}