@font-face {
    font-family: Inter;
    src: url("../fonts/Inter.woff2") format("woff2");
    font-weight: 100 900;
    font-style: oblique 0deg 10deg;
    font-display: swap;
}

@font-face {
    font-family: Cardo;
    src: url("../fonts/cardo-400.woff2") format("woff2");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: Cardo;
    src: url("../fonts/cardo-400i.woff2") format("woff2");
    font-weight: 400;
    font-style: italic;
    font-display: swap;
}

@font-face {
    font-family: Cardo;
    src: url("../fonts/cardo-700.woff2") format("woff2");
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

:root {
    --base: #f9f9f9;
    --base-2: #ffffff;
    --contrast: #111111;
    --contrast-2: #636363;
    --contrast-3: #a4a4a4;
    --accent: #cfcabe;
    --accent-2: #c2a990;
    --accent-3: #d8613c;
    --font-body: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    --font-heading: Cardo, "Iowan Old Style", Georgia, serif;
    --wrap: 1120px;
    --header-h: 72px;
    --radius: 4px;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: var(--font-body);
    font-size: 1.05rem;
    line-height: 1.7;
    color: var(--contrast);
    background: var(--base-2);
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
}

img {
    max-width: 100%;
    height: auto;
}

a {
    color: inherit;
}

h1, h2, h3, h4 {
    font-family: var(--font-heading);
    font-weight: 400;
    line-height: 1.25;
    color: var(--contrast);
}

h1 { font-size: clamp(1.85rem, 3vw, 2.55rem); margin: 0 0 1.1rem; }
h2 { font-size: 1.55rem; margin: 0 0 1rem; }
h3 { font-size: 1.25rem; }

.skip-link {
    position: absolute;
    left: -999px;
    top: 0;
    background: #000;
    color: #fff;
    padding: 0.6rem 1rem;
    z-index: 100;
}

.skip-link:focus {
    left: 0;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 40;
    background: var(--base-2);
    border-bottom: 1px solid #ececec;
}

.header-inner {
    max-width: var(--wrap);
    margin: 0 auto;
    min-height: var(--header-h);
    padding: 0.65rem 1.25rem;
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.brand {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.98rem;
    white-space: nowrap;
}

.brand img {
    width: 40px;
    height: 40px;
    object-fit: contain;
}

.nav-toggle {
    margin-left: auto;
    width: 44px;
    height: 44px;
    border: 0;
    background: transparent;
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    cursor: pointer;
    padding: 10px;
}

.nav-toggle span {
    display: block;
    height: 2px;
    background: var(--contrast);
    transition: transform 0.2s, opacity 0.2s;
}

.site-nav {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 0.15rem 1.15rem;
}

.site-nav a {
    text-decoration: none;
    font-size: 0.98rem;
    padding: 0.35rem 0;
    border-bottom: 2px solid transparent;
}

.site-nav a:hover,
.site-nav a.is-active {
    border-bottom-color: var(--contrast);
}

.nav-item {
    position: relative;
    display: flex;
    align-items: center;
}

.sub-toggle {
    width: 28px;
    height: 28px;
    border: 0;
    background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23111' d='M1 1l5 5 5-5'/%3E%3C/svg%3E") no-repeat center;
    cursor: pointer;
}

.sub-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 180px;
    background: var(--base-2);
    border: 1px solid #ececec;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.08);
    padding: 0.4rem 0;
    z-index: 5;
}

.sub-nav a {
    display: block;
    padding: 0.45rem 0.9rem;
    border-bottom: 0;
}

.sub-nav a:hover,
.sub-nav a.is-active {
    background: var(--base);
}

.nav-item:hover .sub-nav,
.nav-item.is-open .sub-nav {
    display: block;
}

.hero {
    position: relative;
    min-height: 360px;
    height: 46vh;
    max-height: 560px;
    display: flex;
    align-items: center;
    color: #fff;
    overflow: hidden;
}

.hero img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.42);
}

.hero-inner {
    position: relative;
    z-index: 1;
    width: min(var(--wrap), 100%);
    margin: 0 auto;
    padding: 2rem 1.25rem;
}

.hero-title {
    font-family: var(--font-heading);
    font-size: clamp(2rem, 4.2vw, 3.15rem);
    margin: 0 0 0.4rem;
    font-weight: 400;
}

.hero-sub {
    margin: 0;
    font-size: 1.02rem;
    max-width: 28rem;
}

.page-shell {
    flex: 1;
    background: var(--base-2);
}

.layout {
    max-width: var(--wrap);
    margin: 0 auto;
    padding: 2.4rem 1.25rem 3.5rem;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 280px;
    gap: 3rem;
}

.layout.is-wide {
    grid-template-columns: minmax(0, 1fr);
}

.layout.is-wide .sidebar {
    display: none;
}

.app-loading,
.error-box {
    color: var(--contrast-2);
}

.lead {
    font-size: 1.05rem;
}

.prose p {
    margin: 0 0 1.05rem;
}

.prose h2,
.prose h3 {
    margin: 1.6rem 0 0.7rem;
}

.prose ul {
    padding-left: 1.2rem;
}

.slideshow {
    position: relative;
    background: #111;
    overflow: hidden;
    margin: 0.4rem 0 0.6rem;
    min-height: 280px;
}

.slideshow--frameless {
    background: transparent;
    overflow: visible;
    min-height: 0;
}

.slideshow-stage {
    position: relative;
    aspect-ratio: 4 / 3;
    max-height: 72vh;
}

.slideshow--frameless .slideshow-stage {
    aspect-ratio: auto;
    max-height: none;
    min-height: 220px;
}

.slideshow-stage img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    opacity: 0;
    transition: opacity 0.7s ease;
}

.slideshow--frameless .slideshow-stage img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.slideshow--frameless .slideshow-stage {
    position: relative;
    width: 100%;
    height: 0;
    padding-bottom: 75%;
}

.slideshow-stage img.is-active {
    opacity: 1;
}

.slideshow-caption {
    background: #1a1a1a;
    color: #f3f3f3;
    font-size: 0.86rem;
    padding: 0.65rem 0.85rem 0.8rem;
    min-height: 3.2rem;
}

.slideshow--frameless .slideshow-caption {
    background: transparent;
    color: var(--contrast-2);
    padding: 0.7rem 0 0;
    min-height: 0;
    font-size: 0.92rem;
    line-height: 1.45;
}

.slide-btn {
    position: absolute;
    top: 42%;
    transform: translateY(-50%);
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.88);
    color: #111;
    font-size: 1.6rem;
    cursor: pointer;
    z-index: 2;
}

.slideshow--frameless .slide-btn {
    background: rgba(255, 255, 255, 0.72);
    box-shadow: 0 1px 6px rgba(0, 0, 0, 0.12);
    top: 50%;
    margin-top: -1.4rem;
}

.slide-btn.prev { left: 10px; }
.slide-btn.next { right: 10px; }

.slideshow--frameless .slide-btn.prev { left: 0; }
.slideshow--frameless .slide-btn.next { right: 0; }

.slide-dots {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 3.9rem;
    display: flex;
    justify-content: center;
    gap: 6px;
    z-index: 2;
    pointer-events: none;
}

.slideshow--frameless .slide-dots {
    bottom: auto;
    top: calc(100% - 2.2rem);
    transform: translateY(-100%);
}

.slide-dots button {
    pointer-events: auto;
    width: 8px;
    height: 8px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.45);
    cursor: pointer;
}

.slide-dots button.is-active {
    background: #fff;
}

.slideshow--frameless .slide-dots button {
    background: rgba(17, 17, 17, 0.25);
}

.slideshow--frameless .slide-dots button.is-active {
    background: var(--contrast);
}

.slide-auto {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 2;
    border: 0;
    background: rgba(0, 0, 0, 0.45);
    color: #fff;
    font-size: 0.78rem;
    padding: 0.35rem 0.6rem;
    cursor: pointer;
}

.slideshow--frameless .slide-auto {
    background: rgba(255, 255, 255, 0.8);
    color: var(--contrast);
    border: 1px solid #e5e5e5;
}

.slideshow--auto {
    cursor: zoom-in;
}

.slideshow--auto .slideshow-stage {
    pointer-events: none;
}

.sidebar h2 {
    font-size: 1.35rem;
    margin-bottom: 1.1rem;
}

.event-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.event-list li + li {
    border-top: 1px solid #ececec;
}

.event-link {
    display: flex;
    gap: 0.9rem;
    padding: 0.85rem 0;
    text-decoration: none;
}

.date-block {
    flex: 0 0 54px;
    text-align: center;
    line-height: 1.1;
}

.date-month {
    display: block;
    font-size: 0.72rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--contrast-2);
    font-weight: 600;
}

.date-day {
    display: block;
    font-size: 1.7rem;
    font-weight: 700;
}

.event-meta {
    min-width: 0;
}

.event-time {
    display: block;
    color: var(--contrast-2);
    font-size: 0.9rem;
}

.event-title {
    display: block;
    font-weight: 600;
    font-size: 0.98rem;
}

.calendar-link {
    display: inline-block;
    margin-top: 0.5rem;
    color: var(--contrast-2);
    font-size: 0.92rem;
}

.year-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin: 0 0 0.85rem;
}

.year-nav-label {
    margin: 0;
    flex: 1;
    text-align: center;
    font-size: clamp(1.35rem, 2.5vw, 1.7rem);
    border-bottom: 0;
}

.year-nav-btn {
    width: 44px;
    height: 44px;
    border: 1px solid #ddd;
    background: #fff;
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
    color: var(--contrast);
    border-radius: var(--radius);
}

.year-nav-btn:hover:not(:disabled) {
    background: var(--base);
}

.year-nav-btn:disabled {
    opacity: 0.35;
    cursor: default;
}

.month-group {
    margin: 0 0 2rem;
}

.month-group h2 {
    border-bottom: 1px solid #ececec;
    padding-bottom: 0.4rem;
}

.empty-year {
    color: var(--contrast-2);
    margin: 0.4rem 0 0;
}

.event-row {
    display: grid;
    grid-template-columns: 88px minmax(0, 1fr);
    gap: 1rem;
    padding: 1rem 0;
    border-bottom: 1px solid #f0f0f0;
    text-decoration: none;
    align-items: start;
}

.event-row.has-image {
    grid-template-columns: 88px minmax(0, 1fr) 120px;
}

.event-thumb {
    width: 120px;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: #f0f0f0;
}

.event-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.event-row .dow {
    color: var(--contrast-2);
    font-size: 0.85rem;
}

.event-row h3 {
    margin: 0 0 0.25rem;
    font-family: var(--font-body);
    font-size: 1.05rem;
    font-weight: 650;
}

.muted {
    color: var(--contrast-2);
    font-size: 0.95rem;
}

.toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    align-items: center;
    margin: 0 0 1.4rem;
}

.chip {
    border: 1px solid #ddd;
    background: #fff;
    padding: 0.35rem 0.75rem;
    cursor: pointer;
    font: inherit;
    font-size: 0.92rem;
}

.chip.is-active {
    background: var(--contrast);
    color: #fff;
    border-color: var(--contrast);
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 6px;
}

.gallery-grid button {
    margin: 0;
    padding: 0;
    border: 0;
    background: #111;
    cursor: pointer;
    aspect-ratio: 4 / 3;
    overflow: hidden;
}

.gallery-grid img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.35s ease;
}

.gallery-grid button:hover img,
.gallery-grid button:focus-visible img {
    transform: scale(1.04);
}

.cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1rem;
    margin-top: 1.2rem;
}

.card {
    display: block;
    text-decoration: none;
    border: 1px solid #ececec;
    padding: 1.2rem 1.15rem 1.3rem;
    background: var(--base);
}

.card h2 {
    font-size: 1.4rem;
    margin-bottom: 0.4rem;
}

.form {
    display: grid;
    gap: 0.85rem;
    max-width: 520px;
}

.form label {
    display: grid;
    gap: 0.3rem;
    font-weight: 600;
    font-size: 0.95rem;
}

.form input,
.form textarea {
    font: inherit;
    padding: 0.65rem 0.7rem;
    border: 1px solid #cfcfcf;
    border-radius: var(--radius);
    width: 100%;
}

.form textarea {
    min-height: 140px;
    resize: vertical;
}

.hp {
    position: absolute;
    left: -9999px;
}

.btn {
    justify-self: start;
    background: #4279b8;
    color: #fff;
    border: 0;
    padding: 0.7rem 1.2rem;
    font: inherit;
    cursor: pointer;
    border-radius: var(--radius);
}

.btn:hover {
    filter: brightness(0.95);
}

.form-msg {
    margin: 0.4rem 0 0;
    font-size: 0.95rem;
}

.form-msg.is-error { color: #a33; }
.form-msg.is-ok { color: #2a6b3a; }

.site-footer {
    border-top: 1px solid #ececec;
    padding: 1.4rem 1.25rem 1.7rem;
    background: var(--base-2);
}

.footer-inner {
    max-width: var(--wrap);
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    color: var(--contrast-2);
    font-size: 0.95rem;
}

.footer-inner nav {
    display: flex;
    gap: 1.1rem;
}

.footer-inner a {
    text-decoration: none;
}

.footer-inner a:hover {
    text-decoration: underline;
}

.lightbox {
    position: fixed;
    inset: 0;
    background: rgba(8, 8, 8, 0.94);
    z-index: 80;
    display: grid;
    grid-template-columns: 52px 1fr 52px;
    align-items: center;
    padding: 1.5rem 0.4rem 4.5rem;
}

.lightbox[hidden] {
    display: none;
}

.lightbox figure {
    margin: 0;
    text-align: center;
    max-height: 100%;
}

.lightbox img {
    max-height: min(78vh, 860px);
    max-width: 100%;
    object-fit: contain;
}

.lightbox figcaption {
    color: #ddd;
    font-size: 0.9rem;
    margin-top: 0.7rem;
}

.lb-close,
.lb-prev,
.lb-next,
.lb-auto {
    border: 0;
    background: transparent;
    color: #fff;
    cursor: pointer;
}

.lb-close {
    position: absolute;
    top: 8px;
    right: 12px;
    font-size: 2rem;
    width: 44px;
    height: 44px;
}

.lb-prev, .lb-next {
    font-size: 2.4rem;
    height: 100%;
}

.lb-auto {
    position: absolute;
    bottom: 16px;
    left: 50%;
    transform: translateX(-50%);
    border: 1px solid rgba(255, 255, 255, 0.4);
    padding: 0.4rem 0.9rem;
}

.lb-auto[aria-pressed="true"] {
    background: #fff;
    color: #111;
}

.noscript {
    max-width: var(--wrap);
    margin: 0 auto;
    padding: 2rem 1.25rem 3rem;
}

.noscript ul {
    padding-left: 1.2rem;
}

@media (max-width: 860px) {
    .nav-toggle { display: flex; }
    .site-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--base-2);
        flex-direction: column;
        align-items: stretch;
        padding: 0.4rem 1rem 1rem;
        border-bottom: 1px solid #ececec;
        gap: 0;
    }
    .site-nav.is-open { display: flex; }
    .site-nav a {
        padding: 0.75rem 0;
        border-bottom: 1px solid #f1f1f1;
    }
    .nav-item { flex-wrap: wrap; }
    .sub-nav {
        position: static;
        display: none;
        border: 0;
        box-shadow: none;
        width: 100%;
        padding-left: 0.6rem;
    }
    .nav-item.is-open .sub-nav { display: block; }
    .layout {
        grid-template-columns: 1fr;
        gap: 2.2rem;
        padding-top: 1.6rem;
    }
    .layout.is-wide .sidebar { display: block; }
    .hero {
        height: 34vh;
        min-height: 220px;
    }
    .event-row {
        grid-template-columns: 70px 1fr;
    }
    .event-row.has-image {
        grid-template-columns: 70px 1fr 88px;
    }
    .event-thumb {
        width: 88px;
    }
    .lightbox {
        grid-template-columns: 40px 1fr 40px;
        padding-bottom: 5rem;
    }
}

@media (max-width: 480px) {
    .brand span { font-size: 0.9rem; }
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .slideshow-stage {
        aspect-ratio: 1 / 1;
    }
    .slideshow--frameless .slideshow-stage {
        padding-bottom: 100%;
    }
}

body.nav-open {
    overflow: hidden;
}
