:root {
    --cwta-accent: #b63600;
    --cwta-red: #a70000;
    --cwta-ink: #414141;
    --cwta-border: #e3e3e3;
    --cwta-panel: #f1f1f1;
    --cwta-gutter: clamp(.9rem, 2.5vw, 1.9rem);
    --cassiopeia-color-primary: var(--cwta-accent);
    --cassiopeia-color-link: var(--cwta-accent);
    --cassiopeia-color-hover: var(--cwta-red);
}

html {
    background: #ad5f40 url('../images/court-background.jpg') no-repeat center top;
    background-size: max(112rem, 100%) auto;
}
body.cwta-theme {
    width: min(100%, 65rem);
    min-height: 100vh;
    margin-inline: auto;
    background: #fff;
    color: var(--cwta-ink);
    font-family: system-ui, sans-serif;
    box-shadow: 0 0 2rem #1e0d0640;
}
.cwta-theme a { color: var(--cwta-accent); }
.cwta-theme a:hover { color: var(--cwta-red); }
.cwta-theme :focus-visible { outline: 3px solid #6d2500; outline-offset: 3px; }

.cwta-theme .container-header {
    display: block;
    padding-inline: var(--cwta-gutter);
    background: #fff;
    box-shadow: none;
}
.cwta-masthead {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: .3rem 1rem;
    padding: .75rem clamp(.4rem, 3vw, 2.3rem);
    background: linear-gradient(#eee, #fff);
}
.cwta-masthead .container-topbar,
.cwta-masthead .container-below-top {
    width: auto;
    margin: 0;
    padding: 0;
    background: none;
    color: var(--cwta-ink);
}
.cwta-masthead p { margin: 0; }
.cwta-masthead br { display: none; }
.cwta-masthead img { display: block; width: min(310px, 76vw); height: auto; }
.cwta-masthead .container-below-top p { text-align: start !important; }
.cwta-masthead .container-below-top span { color: var(--cwta-accent) !important; }

.cwta-banner { margin: 0 0 .6rem; }
.cwta-slideshow { position: relative; overflow: hidden; background: #eee; }
.cwta-slide img { display: block; width: 100%; height: auto; aspect-ratio: 916 / 315; object-fit: cover; }
.cwta-slide:not(:first-child) { display: none; }
.cwta-slideshow.is-ready .cwta-slide { display: block; }
.cwta-slideshow.is-ready .cwta-slide[hidden] { display: none; }
.cwta-slideshow-controls:not([hidden]) { display: flex; gap: .35rem; position: absolute; inset: auto .55rem .55rem auto; }
.cwta-slideshow-controls button {
    min-width: 2.75rem;
    min-height: 2.75rem;
    padding: 0;
    border: 1px solid #fff;
    border-radius: .2rem;
    background: #333e;
    color: #fff;
    font-size: 1.45rem;
}
.cwta-slideshow-controls button:focus-visible { outline-color: #fff; }

.cwta-theme .container-header .container-nav {
    max-width: none;
    padding: 0 .3rem;
    background: linear-gradient(var(--cwta-accent), #a53000);
}
.cwta-theme .container-header .container-nav nav { width: 100%; margin: 0; }
.cwta-theme .container-header .mod-menu { gap: 0; color: #fff; }
.cwta-theme .container-header .metismenu > li { flex-wrap: nowrap; padding: 0; }
.cwta-theme .container-header .mod-menu > li > :is(a, span, button),
.cwta-theme .container-header .navbar-toggler { color: #fff; }
.cwta-theme .container-header .mod-menu > li > :is(a, span) {
    padding: .7rem .45rem;
    font-size: .875rem;
    font-weight: 650;
    text-decoration: none;
}
.cwta-theme .container-header .mod-menu > li:is(.active, :hover) { background: #ffffff24; }
.cwta-theme .container-header .mod-menu > li > button { padding-inline: .3rem; }
.cwta-theme .container-header .navbar-toggler { margin: .3rem; border-color: #ffffff9c; }
.cwta-theme .container-header .mod-menu :focus-visible,
.cwta-theme .container-header .navbar-toggler:focus-visible { outline-color: #fff; outline-offset: -3px; }
.cwta-theme .container-header .metismenu .mm-collapse {
    background: #fff;
    border: 1px solid var(--cwta-border);
    color: var(--cwta-ink);
}
.cwta-theme .container-header .metismenu .mm-collapse :is(a, button, span) { color: var(--cwta-ink); }
.cwta-theme .container-header .metismenu .mm-collapse a:hover { color: var(--cwta-red); }
.cwta-theme .container-header .metismenu .mm-collapse :focus-visible { outline-color: var(--cwta-accent); }

.cwta-theme .site-grid { padding: .5rem var(--cwta-gutter) 1.5rem; }
.cwta-theme .container-component { min-width: 0; padding: .5rem 0 1rem; overflow-wrap: anywhere; }
.cwta-theme .card { border-color: var(--cwta-border); border-radius: .2rem; }
.cwta-theme .card-header { background: var(--cwta-panel); color: var(--cwta-accent); font-size: 1.25rem; }
.cwta-theme .sidebar-left.card._menu > .card-header {
    color: #fff;
    background: var(--cwta-accent);
    text-align: center;
}
.cwta-theme .sidebar-left .mod-menu a::before {
    content: '';
    display: inline-block;
    width: .4rem;
    height: .4rem;
    margin-inline-end: .55rem;
    border-radius: 50%;
    background: #4f962f;
    vertical-align: .15em;
}
.cwta-theme .sidebar-left img,
.cwta-theme .com-content-article img,
.cwta-theme .blog-item img { max-width: 100%; height: auto; }
.cwta-theme .blog-item .item-title {
    margin: 0 0 .85rem;
    padding: .75rem 1rem;
    font-size: clamp(1.15rem, 2.3vw, 1.55rem);
    border-radius: .2rem;
    background: var(--cwta-accent);
    color: #fff;
}
.cwta-theme .blog-item .item-title a { color: #fff; }
.cwta-theme .blog-item .item-title a:focus-visible { outline-color: #fff; }
.cwta-theme .pagination { flex-wrap: wrap; row-gap: .35rem; }
.cwta-theme .com-content-article table { display: block; max-width: 100%; overflow: auto; }
.cwta-theme iframe { max-width: 100%; }
.cwta-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 140px), 1fr)); gap: .8rem; }
.cwta-gallery figure { margin: 0; }
.cwta-gallery img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.cwta-theme .footer { margin: 0; padding-inline: var(--cwta-gutter); background: #333; color: #eee; }
.cwta-theme .footer a { color: #fff; }
.cwta-theme .footer a:focus-visible { outline-color: #fff; }

@media (min-width: 992px) {
    .cwta-theme.has-sidebar-left .site-grid {
        grid-template-columns: [full-start main-start] 0 minmax(11rem, .9fr) repeat(3, minmax(0, 1fr)) 0 [full-end main-end];
        column-gap: 1.25rem;
    }
    .cwta-theme .container-header .metismenu > li > :is(a, span) {
        padding-inline: .35rem;
        font-size: .82rem;
    }
}
@media (max-width: 991.98px) {
    html { background: #fff; }
    body.cwta-theme { box-shadow: none; }
    .cwta-theme .container-header .navbar-collapse.show { display: block; }
    .cwta-theme .container-header .metismenu > li { flex-wrap: wrap; }
    .cwta-theme .container-header .metismenu .metismenu-item > :is(a, span) { white-space: normal; }
    .cwta-theme .container-header .metismenu .mm-collapse { width: 100%; position: static; }
}

.cwta-theme .container-header .navbar-collapse { min-width: 0; }
.cwta-theme .container-header .metismenu { flex-wrap: wrap; }
.cwta-theme .container-header .metismenu > li + li { margin-inline-start: 0; }
.cwta-theme .container-header .metismenu > li > .mm-toggler {
    flex: 0 0 auto;
    width: 1.25rem;
    font-size: .75rem;
}

.cwta-news-list { list-style: none; padding: 0; margin-block: 1rem 1.5rem; }
.cwta-news-list li { display: grid; gap: .2rem .75rem; padding: .75rem 0; border-bottom: 1px solid var(--cwta-border); }
.cwta-news-list time { color: #555; font-size: .9rem; white-space: nowrap; }
@media (min-width: 576px) {
    .cwta-news-list li { grid-template-columns: 6.5rem minmax(0, 1fr); }
    .cwta-news-list li > a { grid-column: 2; }
}
