/* exhibition-detail.css – 展示会詳細ページ（CMSで自動生成）の画像ギャラリーと会場地図 */
/* news.css の後に読み込む。生成済みの全言語ページから参照される。 */

/* 上段（画像と概要）は高さがそろわないため、上端に合わせる */
.news-body > div.exh-detail-top {
    align-items: flex-start;
}

/* ── 画像ギャラリー（2枚以上のとき） ───────────────── */
.exh-gallery {
    width: 100%;
}
.exh-gallery__stage {
    position: relative;
}
.exh-gallery__track {
    display: flex;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    border: 1px solid #c0c0c0;
    background-color: #fff;
}
.exh-gallery__track::-webkit-scrollbar {
    display: none;
}
.exh-gallery__track:focus-visible {
    outline: 2px solid #e85400;
    outline-offset: 2px;
}
.exh-gallery__slide {
    flex: 0 0 100%;
    min-width: 0;
    scroll-snap-align: start;
    scroll-snap-stop: always;
}
.exh-gallery__link {
    display: block;
    cursor: zoom-in;
}
.exh-gallery__slide img {
    display: block;
    width: 100%;
    aspect-ratio: 3 / 2;
    object-fit: cover;
}

/* 前後ボタン（news.css の .news-body button より優先させる） */
.news-body .exh-gallery__arrow {
    position: absolute;
    top: 50%;
    width: 40px;
    height: 40px;
    margin-top: -20px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, .88);
    box-shadow: 0 1px 4px rgba(0, 0, 0, .3);
    cursor: pointer;
    transition: background-color .2s, box-shadow .2s;
}
.news-body .exh-gallery__arrow:hover {
    background-color: #fff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .35);
}
.news-body .exh-gallery__arrow:focus-visible {
    outline: 2px solid #e85400;
    outline-offset: 2px;
}
.exh-gallery__arrow--prev {
    left: 10px;
}
.exh-gallery__arrow--next {
    right: 10px;
}
.exh-gallery__arrow::before {
    content: "";
    width: 10px;
    height: 10px;
    border-top: 2px solid #333;
    border-right: 2px solid #333;
}
.exh-gallery__arrow--prev::before {
    transform: translateX(2px) rotate(-135deg);
}
.exh-gallery__arrow--next::before {
    transform: translateX(-2px) rotate(45deg);
}

/* 何枚目か */
.exh-gallery__count {
    position: absolute;
    right: 10px;
    bottom: 10px;
    padding: 2px 10px;
    border-radius: 999px;
    background-color: rgba(0, 0, 0, .6);
    color: #fff;
    font-size: .8rem;
    line-height: 1.6;
    pointer-events: none;
}

/* サムネイル */
.exh-gallery__thumbs {
    display: flex;
    gap: 6px;
    margin-top: 8px;
    padding-bottom: 4px;
    overflow-x: auto;
    scrollbar-width: thin;
}
.news-body .exh-gallery__thumb {
    flex: 0 0 72px;
    width: 72px;
    padding: 0;
    border: 2px solid #ddd;
    border-radius: 5px;
    overflow: hidden;
    background-color: #fff;
    cursor: pointer;
    opacity: .7;
    transition: border-color .2s, opacity .2s;
}
.news-body .exh-gallery__thumb:hover,
.news-body .exh-gallery__thumb.is-active {
    opacity: 1;
}
.news-body .exh-gallery__thumb.is-active {
    border-color: #e85400;
}
.news-body .exh-gallery__thumb:focus-visible {
    outline: 2px solid #e85400;
    outline-offset: 1px;
}
.exh-gallery__thumb img {
    display: block;
    width: 100%;
    aspect-ratio: 3 / 2;
    object-fit: cover;
}

/* ── 会場の地図 ───────────────────────────────── */
.exh-map {
    margin: 12px 0 4px;
}
.exh-map__frame {
    display: block;
    width: 100%;
    height: 300px;
    aspect-ratio: auto;
    border: 1px solid #ddd;
}

/* 中国語ページ：百度地図・高徳地図で開くボタン */
.exh-map__card,
.exh-map__baidu {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    border: 1px solid #dde1e6;
    border-radius: 6px;
    background-color: #f7f8fa;
    color: inherit;
    text-decoration: none;
}
.exh-map__pin {
    position: relative;
    flex: 0 0 auto;
    width: 30px;
    height: 30px;
    margin: 0 4px 6px;
    border-radius: 50% 50% 50% 0;
    background-color: #e85400;
    transform: rotate(-45deg);
}
.exh-map__pin::after {
    content: "";
    position: absolute;
    top: 9px;
    left: 9px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: #fff;
}
.exh-map__body {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}
.exh-map__place {
    font-weight: 700;
    overflow-wrap: anywhere;
}
.exh-map__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 8px;
}
.exh-map__button {
    display: inline-flex;
    align-items: center;
    padding: 6px 14px;
    border: 1px solid;
    border-radius: 999px;
    background-color: #fff;
    font-size: .9rem;
    font-weight: 600;
    line-height: 1.4;
    text-decoration: none;
    white-space: nowrap;
    transition: background-color .2s, color .2s;
}
.exh-map__button::after,
.exh-map__action::after {
    content: " \2192";
    white-space: pre;
}
.exh-map__button--baidu {
    border-color: #2932e1;
    color: #2932e1;
}
.exh-map__button--baidu:hover {
    background-color: #2932e1;
    color: #fff;
}
.exh-map__button--amap {
    border-color: #0b72d9;
    color: #0b72d9;
}
.exh-map__button--amap:hover {
    background-color: #0b72d9;
    color: #fff;
}
.exh-map__button:focus-visible {
    outline: 2px solid #e85400;
    outline-offset: 2px;
}
/* 百度地図のボタンだけだった頃に生成したページ用（カード全体がリンク） */
.exh-map__baidu {
    transition: border-color .2s, box-shadow .2s;
}
.exh-map__baidu:hover {
    border-color: #2932e1;
    box-shadow: 0 2px 8px rgba(41, 50, 225, .15);
}
.exh-map__action {
    color: #2932e1;
    font-weight: 600;
}
.exh-map__sub {
    display: inline-block;
    margin-top: 8px;
    color: #555;
    font-size: .85rem;
    text-decoration: underline;
}

/* ── 会場：文字（左）と地図（右）を横並びにする ── */
.exh-venue {
    display: flex;
    align-items: flex-start;
    gap: 24px;
}
.exh-venue__text {
    flex: 1 1 0;
    min-width: 0;
    overflow-wrap: anywhere;
}
.exh-venue__map {
    flex: 0 0 55%;
    min-width: 0;
    margin: 0;
}
.exh-venue__map .exh-map__frame {
    height: 260px;
}
.exh-venue__map .exh-map__card {
    gap: 12px;
    padding: 14px 16px;
}

@media screen and (max-width: 599px) {
    .news-body .exh-gallery__arrow {
        width: 34px;
        height: 34px;
        margin-top: -17px;
    }
    .news-body .exh-gallery__thumb {
        flex-basis: 60px;
        width: 60px;
    }
    .exh-map__frame,
    .exh-venue__map .exh-map__frame {
        height: 240px;
    }
    /* スマートフォンでは文字の下に地図を並べる */
    .exh-venue {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }
    .exh-venue__text,
    .exh-venue__map {
        flex: none;
        width: 100%;
    }
}
