/* ==========================================================================
   EXHIBITS PAGE — archive-exhibit.php + single-exhibit.php
   ========================================================================== */

/* --------------------------------------------------------------------------
   SHARED CONTAINER
   -------------------------------------------------------------------------- */

.exhibits-container,
.exhibit-container {
    width: 100%;
    max-width: 1440px;
    margin-left: auto;
    margin-right: auto;
}

.exhibits-page {
    background: transparent;
    color: #1d1c1a;
    width: 100%;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 32px;
    align-items: center;
}

.exhibits-page .exhibits-container {
    text-align: left;
}

/* --------------------------------------------------------------------------
   ARCHIVE — HERO
   -------------------------------------------------------------------------- */

.exhibits-hero {
    grid-column: 1;
    /* padding: 72px 0 56px; */
    text-align: left;
    align-self: center;
}

.exhibits-hero__title {
    font-size: clamp(2rem, 4vw, 3.25rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    color: #1a1a1a;
    margin: 0 0 16px;
    line-height: 1.15;
}

.exhibits-hero__description {
    font-size: 1.075rem;
    color: #666;
    max-width: 600px;
    margin: 0;
    line-height: 1.7;
}

/* --------------------------------------------------------------------------
   MAP SECTION
   -------------------------------------------------------------------------- */

.exhibits-map-section {
    grid-column: 2;
    padding: 40px 0 0;
    display: flex;
    flex-direction: column;
    gap: 40px;
    align-self: center;
}

.exhibits-map,
#exhibits-map {
    width: 100%;
    min-height: 500px;
    height: 500px;
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 14px 30px rgba(20, 24, 30, 0.12);
    background: transparent;
}

#exhibits-map-reset {
    position: absolute;
    left: 14px;
    bottom: 14px;
    z-index: 1001;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    min-height: 44px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    margin: 0;
    color: #fff;
    text-decoration: none;
    transition: transform 0.2s ease;
    background-color: #1FB4B6;
}

#exhibits-map .leaflet-pane,
#exhibits-map .leaflet-control-container {
    z-index: 400;
}

#exhibits-map-reset i {
    color: #fff;
    font-size: 16px;
    line-height: 1;
}

#exhibits-map-reset:hover {
    color: #fff;
    background-color: #1FB4B6;
    box-shadow: 0px 3px 11px 1px rgba(0, 0, 0, 0.2);
    transform: translateY(-1px);
}

#exhibits-map-reset:hover i {
    color: #fff;
}

/* --------------------------------------------------------------------------
   RESULTS SECTION
   -------------------------------------------------------------------------- */

.exhibits-results {
    grid-column: 1 / -1;
    padding: 56px 0 96px;
}

.exhibits-results__heading {
    font-size: clamp(1.2rem, 2.1vw, 1.55rem);
    font-weight: 700;
    color: #1a1a1a;
    letter-spacing: 0.01em;
    margin: 0 0 30px;
    text-align: center;
}

.exhibits-hero__title .exhibits-results__city {
    color: #1FB4B6;
    font-size: inherit;
    font-weight: inherit;
}

.exhibits-grid__wrapper {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 20px;
}

.exhibits-page .ast-grid-common-col {
    padding: 0 !important;
}

/* --------------------------------------------------------------------------
   EMPTY STATE
   -------------------------------------------------------------------------- */

.exhibits-empty {
    text-align: center;
    font-size: 1rem;
    color: #6b665f;
    padding: 80px 0;
    background: rgba(255, 255, 255, 0.66);
    border: 1px dashed #d8d0c3;
    border-radius: 14px;
}

/* --------------------------------------------------------------------------
   EXHIBIT CARD
   -------------------------------------------------------------------------- */

.exhibit-card {
    position: relative;
    border-radius: 18px;
    overflow: hidden;
    border: none;
    background: #0f0f0f;
    box-shadow: 0 10px 26px rgba(16, 20, 28, 0.1);
    aspect-ratio: 1 / 1;
    height: auto;
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.exhibit-card:hover {
    transform: translateY(-6px);
    border-color: rgba(184, 172, 152, 0.8);
    box-shadow: 0 18px 38px rgba(16, 20, 28, 0.16);
}

.exhibit-card__image {
    display: block;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    aspect-ratio: auto;
    overflow: hidden;
    background: #ede9e3;
}

.exhibit-card__image img {
    display: block;
    width: 100%;
    height: 100%;
    padding: 0;
    object-fit: cover;
    transition: transform 0.45s ease;
}

.exhibit-card:hover .exhibit-card__image img {
    transform: scale(1.06);
}

.exhibit-card__content {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 0;
    background: transparent;
}

.exhibit-card__location {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 2;
    margin: 0;
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(14, 210, 212, 0.78);
    color: #ffffff;
    font-size: 0.72rem;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: 0.04em;
}

.exhibit-card__title {
    margin: 0;
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.35;
    color: #111;
    display: -webkit-box;
    line-clamp: 2;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    background: #fff;
    border-radius: 0;
    padding: 12px 14px;
}

.exhibit-card__title a {
    color: inherit;
    text-decoration: none;
}

.exhibit-card__title a:hover {
    color: #000;
}

/* --------------------------------------------------------------------------
   PAGINATION
   -------------------------------------------------------------------------- */

.exhibits-grid .nav-links,
.exhibits-results .nav-links {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 44px;
    flex-wrap: wrap;
}

.exhibits-grid .nav-links a,
.exhibits-grid .nav-links span,
.exhibits-results .nav-links a,
.exhibits-results .nav-links span {
    display: inline-block;
    padding: 8px 18px;
    border-radius: 999px;
    font-size: 0.9rem;
    font-weight: 600;
    color: #3a6b4f;
    background: #edf3ef;
    text-decoration: none;
    transition: background 0.2s ease, color 0.2s ease;
}

.exhibits-grid .nav-links a:hover,
.exhibits-results .nav-links a:hover {
    background: #3a6b4f;
    color: #fff;
}

/* --------------------------------------------------------------------------
   SINGLE — HERO
   -------------------------------------------------------------------------- */

.exhibit-hero {
    padding: 64px 0 48px;
    background-color: #f9f7f4;
    border-bottom: 1px solid #e8e4de;
}

.exhibit-hero__title {
    font-size: clamp(1.4rem, 2.4vw, 2.2rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    color: #1a1a1a;
    margin: 0;
    padding-right: 64px;
    line-height: 1.15;
}

/* --------------------------------------------------------------------------
   SINGLE — CONTENT SECTION
   -------------------------------------------------------------------------- */

.exhibit-content {
    padding: 42px 0 72px;
}



.exhibit-single .exhibit-container {
    max-width: 1440px;
    margin: 0 auto;
    padding-left: 20px;
    padding-right: 20px;
}

.exhibit-edu-header {
    margin-bottom: 22px;
}

.exhibit-edu-header .breadcrumbs {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    align-items: center;
    gap: 8px;
    padding-top: 0;
    padding-bottom: 0;
    margin: 0 0 24px;
    font-size: 16px;
    line-height: 1.5;
    color: #6b7280;
}

.exhibit-edu-header .breadcrumbs a {
    color: #1da2a9;
    text-decoration: none;
}

.exhibit-edu-header .breadcrumbs a:hover {
    color: #14787f;
}

.exhibit-edu-header .exhibit-hero__title {
    margin: 0;
    padding: 0;
    font-size: clamp(1.7rem, 2.4vw, 2.25rem);
    line-height: 1.1;
    color: #111827;
}

.exhibit-edu-subtitle {
    margin: 10px 0 0;
    font-size: 0.95rem;
    color: #4b5563;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.exhibit-edu-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.6fr) minmax(300px, 0.9fr);
    gap: 20px;
    align-items: start;
}

.exhibit-edu-main {
    min-width: 0;
}

.exhibit-edu-sidebar {
    position: sticky;
    top: 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.exhibit-edu-sidebar__title {
    margin: 0;
    font-size: 1.05rem;
    line-height: 1.3;
    color: #111827;
}

.exhibit-single--no-media .exhibit-content__grid {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
        "details"
        "text";
}

.exhibit-single--no-media .exhibit-details {
    position: relative;
    top: 0;
    min-height: 0;
}

.exhibit-main-text {
    color: #2b2f36;
    font-size: 1rem;
    line-height: 1.8;
    margin-top: 0;
    background: #ffffff;
    border: 1px solid #e7eaf0;
    border-radius: 12px;
    padding: 26px;
}

.exhibit-main-text p {
    margin: 0 0 1.25em;
}

.exhibit-main-text p:last-child {
    margin-bottom: 0;
}

.exhibit-main-text h2,
.exhibit-main-text h3,
.exhibit-main-text h4 {
    color: #18171d;
    font-weight: 700;
    margin: 1.75em 0 0.6em;
    line-height: 1.25;
}

.exhibit-main-text ul,
.exhibit-main-text ol {
    padding-left: 1.5em;
    margin: 0 0 1.25em;
}

.exhibit-main-text li {
    margin-bottom: 0.4em;
}

.exhibit-main-text a {
    color: #0f766e;
    text-decoration: underline;
}

.exhibit-main-text a:hover {
    color: #0b5f59;
}

.exhibit-content__grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
        "media"
        "details"
        "text";
    gap: 18px;
    align-items: start;
}

.exhibit-media {
    position: static;
    position: relative;
    height: auto;
    margin-bottom: 18px;
}

.exhibit-media .em-share {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 3;
    margin: 0;
}

.exhibit-media .em-share,
.exhibit-media .em-share > .exhibit-video-trigger {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.exhibit-image {
    border-radius: 12px;
    overflow: hidden;
    background: #d4d8df;
    border: 1px solid #e4e7ef;
    height: auto;
    min-height: 0;
}

.exhibit-image img {
    width: 100%;
    height: auto;
    max-height: 520px;
    display: block;
    object-fit: cover;
}

.exhibit-details {
    position: relative;
    top: 0;
    display: flex;
    flex-direction: column;
    gap: 18px;
    justify-content: flex-start;
    padding: 24px;
    border-radius: 12px;
    min-height: 0;
    background: #ffffff;
    border: 1px solid #e7eaf0;
}

.exhibit-meta {
    list-style: none;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
}

.exhibit-meta__item {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    gap: 6px;
    padding: 10px 12px;
    border: 1px solid #eceff4;
    border-radius: 10px;
    background: #f9fafb;
}

.exhibit-meta__item:last-child {
    border-bottom: 1px solid #eceff4;
}

.exhibit-meta__label {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #6b7280;
    min-width: 0;
    flex-shrink: 0;
}

.exhibit-meta__value {
    font-size: 0.95rem;
    font-weight: 600;
    color: #111827;
    line-height: 1.4;
    text-align: left;
}

.exhibit-media .em-share__btn {
    width: 42px;
    height: 42px;
    border-radius: 999px;
    border: 1px solid #d7dce5;
    background: #ffffff;
    color: #111827;
    box-shadow: none;
}

.exhibit-media .em-share__btn:hover {
    transform: none;
    background: #f3f4f6;
}

.exhibit-media .exhibit-video-trigger {
    width: 42px;
    height: 42px;
    min-width: 42px;
    padding: 0;
    border-radius: 999px;
    border: 1px solid #d7dce5;
    background: #ffffff;
    color: #111827;
    box-shadow: none;
}

.exhibit-media .exhibit-video-trigger:hover {
    transform: none;
    background: #f3f4f6;
}

.exhibit-media .exhibit-video-trigger:focus-visible {
    outline: 2px solid #6b7280;
    outline-offset: 2px;
}

.exhibit-media .em-share__menu {
    top: 48px;
    right: auto;
    left: 0;
}

.exhibit-video-modal[hidden] {
    display: none !important;
}

.exhibit-video-modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.exhibit-video-modal__overlay {
    position: absolute;
    inset: 0;
    background: rgba(10, 14, 22, 0.82);
    backdrop-filter: blur(8px);
}

.exhibit-video-modal__dialog {
    position: relative;
    z-index: 1;
    width: min(980px, calc(100% - 28px));
    margin: 0;
    padding: 0;
}

.exhibit-video-modal__close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 40px;
    height: 40px;
    border: 0;
    background: transparent;
    color: #ffffff;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    z-index: 2;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.exhibit-video-modal__close:hover {
    opacity: 0.75;
}

.exhibit-video-modal__close:focus-visible {
    outline: 2px solid #ffffff;
    outline-offset: 2px;
}

.exhibit-video-modal__content {
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border-radius: 16px;
    background: #000;
}

.exhibit-video-modal__content video,
.exhibit-video-modal__content iframe {
    display: block;
    width: 100%;
    height: 100%;
    border: 0;
    background: #000;
}

/* --------------------------------------------------------------------------
   SINGLE — MICRO QUIZ
   -------------------------------------------------------------------------- */

.exhibit-quiz {
    margin-top: 20px;
    width: 100%;
    padding: 22px;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    background: #ffffff;
    box-shadow: none;
}

.exhibit-quiz__title {
    margin: 0 0 12px;
    font-size: clamp(1.1rem, 2vw, 1.45rem);
    font-weight: 700;
    color: #111827;
    letter-spacing: -0.01em;
    line-height: 1.2;
}

.exhibit-quiz__question {
    margin: 0 0 18px;
    font-size: 1rem;
    color: #374151;
    line-height: 1.65;
}

.exhibit-quiz__options {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
}

.exhibit-quiz__option {
    appearance: none;
    width: 100%;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    background: #fff;
    color: #111827;
    font-size: 0.95rem;
    font-weight: 600;
    text-align: left;
    line-height: 1.4;
    padding: 12px 14px;
    cursor: pointer;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.exhibit-quiz__option:hover {
    background: #f9fafb;
    border-color: #d1d5db;
    box-shadow: none;
    transform: none;
    color: #111827;
}

.exhibit-quiz__option:focus-visible {
    outline: 2px solid #6b7280;
    outline-offset: 2px;
}

.exhibit-quiz__feedback {
    min-height: 1.4em;
    margin-top: 16px;
    font-size: 0.95rem;
    font-weight: 700;
    color: #111827;
}

.exhibit-quiz__explanation {
    margin: 10px 0 0;
    padding-top: 12px;
    border-top: 1px solid #e5e7eb;
    font-size: 0.94rem;
    color: #4b5563;
    line-height: 1.65;
}

/* --------------------------------------------------------------------------
   RESPONSIVE — tablet
   -------------------------------------------------------------------------- */

@media (max-width: 960px) {
    .exhibits-page {
        display: block;
    }

    .exhibits-map,
    #exhibits-map {
        min-height: 380px;
        height: 380px;
    }

    .exhibits-grid__wrapper {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .exhibit-edu-layout {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .exhibit-edu-sidebar {
        position: static;
    }

    .exhibit-content__grid {
        grid-template-columns: 1fr;
        grid-template-areas:
            "media"
            "details"
            "text";
        gap: 18px;
    }

    .exhibit-media,
    .exhibit-image,
    .exhibit-image img,
    .exhibit-details {
        height: auto;
        min-height: 0;
        max-height: none;
    }

    .exhibit-details {
        padding: 20px;
        border-radius: 12px;
    }

    .exhibit-meta {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .exhibit-main-text {
        padding: 20px;
    }

    .exhibit-quiz {
        margin-top: 18px;
        padding: 18px;
        border-radius: 12px;
    }

    .exhibit-media {
        position: static;
    }
}

/* --------------------------------------------------------------------------
   RESPONSIVE — mobile
   -------------------------------------------------------------------------- */

@media (max-width: 640px) {
    .exhibits-container,
    .exhibit-container {
        padding-left: 20px;
        padding-right: 20px;
    }

    .exhibit-single .exhibit-container {
        padding-left: 16px;
        padding-right: 16px;
    }

    .exhibits-hero {
        padding: 48px 0 40px;
    }

    .exhibits-map,
    #exhibits-map {
        min-height: 280px;
        height: 280px;
        border-radius: 10px;
    }

    .exhibits-results {
        padding: 44px 0 64px;
    }

    .exhibits-grid__wrapper {
        grid-template-columns: 1fr;
    }

    .exhibit-hero {
        padding: 48px 0 36px;
    }

    .exhibit-content {
        padding: 34px 0 56px;
    }

    .exhibit-edu-header {
        margin-bottom: 16px;
    }

    .exhibit-edu-header .exhibit-hero__title {
        font-size: clamp(1.5rem, 6vw, 1.9rem);
    }

    .exhibit-details {
        padding: 16px;
        border-radius: 10px;
    }

    .exhibit-details .em-share {
        top: 10px;
        right: 10px;
    }

    .exhibit-meta {
        grid-template-columns: 1fr;
    }

    .exhibit-main-text {
        padding: 16px;
        border-radius: 10px;
    }

    .exhibit-main-text {
        margin-top: 0;
    }

    .exhibit-quiz {
        margin-top: 16px;
        padding: 16px;
        border-radius: 10px;
    }

    .exhibit-quiz__question {
        margin-bottom: 14px;
    }

    .exhibit-quiz__option {
        padding: 11px 12px;
        font-size: 0.92rem;
    }

    .exhibit-media .em-share {
        top: 10px;
        left: 10px;
    }

    .exhibit-video-modal__dialog {
        width: calc(100% - 16px);
        margin: 0;
        padding: 0;
        border-radius: 16px;
    }

    .exhibit-video-modal__close {
        top: 10px;
        right: 10px;
    }
}
