/* --- Base Styles & Theme --- */
:root {
    --primary-color: #981E32; /* 深紅 */
    --secondary-color: #fdfaf5; /* 暖かみのあるオフホワイト */
    --gold-color: #C0A062;
    --text-color: #333333;
    --light-text-color: #666666;
    --dark-charcoal: #2c2c2c;
    --font-serif: 'EB Garamond', serif;
    --font-sans-serif: 'Noto Sans JP', sans-serif;
}

#container {
    overflow-x: hidden;
}

body, h1, h2, h3, p, ul, li, table { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: var(--font-sans-serif); line-height: 1.8; color: var(--text-color); background-color: #fff; }
body.is-menu-open { overflow: hidden; }
img { max-width: 100%; height: auto; vertical-align: middle; }
a { text-decoration: none; color: inherit; transition: all 0.3s ease; }
a:hover { color: var(--gold-color); }
.container { width: 90%; max-width: 1100px; margin: 0 auto; }

/* --- Header & Navigation (Base) --- */
.header { position: fixed; top: 0; left: 0; width: 100%; z-index: 100; transition: all 0.4s ease; }
.header.scrolled { background-color: rgba(255, 255, 255, 0.98); box-shadow: 0 2px 10px rgba(0,0,0,0.08); padding: 4px 0; }
.header-inner { display: flex; justify-content: flex-start; align-items: flex-start; width: 95%; margin: 0 auto; padding: 20px 0; transition: padding 0.4s ease; }
.header.scrolled .header-inner { padding: 0; }
.logo { font-family: var(--font-serif); font-size: 1.2rem; /* Mobile Base */ font-weight: 500; color: #fff; transition: all 0.4s ease; letter-spacing: 0.05em; z-index: 101; }
.header.scrolled .logo { color: var(--dark-charcoal); font-size: 1rem; }

/* --- Mobile Navigation (Default) --- */
.hamburger-icon { display: block; position: relative; width: 30px; height: 21px; z-index: 101; cursor: pointer; }
.hamburger-icon span { display: block; position: absolute; left: 0; width: 100%; height: 3px; background-color: #fff; border-radius: 4px; transition: all .4s; }
.header.scrolled .hamburger-icon span { background-color: var(--dark-charcoal); }
.hamburger-icon span:nth-of-type(1) { top: 0; }
.hamburger-icon span:nth-of-type(2) { top: 9px; }
.hamburger-icon span:nth-of-type(3) { bottom: 0; }
.hamburger-icon.is-active span:nth-of-type(1) { transform: translateY(9px) rotate(-45deg); }
.hamburger-icon.is-active span:nth-of-type(2) { opacity: 0; }
.hamburger-icon.is-active span:nth-of-type(3) { transform: translateY(-9px) rotate(45deg); }
.nav-menu.pc-menu { display: none; }
.nav-menu.sp-menu { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background-color: rgba(0, 0, 0, 0.9); display: flex; flex-direction: column; align-items: center; justify-content: center; z-index: 100; opacity: 0; visibility: hidden; transition: opacity .4s, visibility .4s; }
.nav-menu.sp-menu.is-active { opacity: 1; visibility: visible; }
.nav-menu.sp-menu ul { list-style: none; text-align: center; }
.nav-menu.sp-menu li { margin: 0; padding: 20px 0; }
.nav-menu.sp-menu a { color: #fff; font-family: var(--font-serif); font-size: 1.8rem; font-weight: bold;}

/* --- Hero Section --- */
.hero { 
    height: 100vh; 
    position: relative; 
    overflow: hidden; 
    background-color: #000; 
}

/* Swiperコンテナの基本設定 */
.hero-swiper {
    width: 100%;
    height: 100%;
}

.swiper-slide {
    overflow: hidden; /* Ken Burnsエフェクトではみ出た部分を隠す */
}

/* 各スライドの画像用div */
.slide-image {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
}

/* Ken Burnsエフェクト用のアニメーション */
@keyframes kenburns {
    0% {
        transform: scale(1) translate(0, 0);
    }
    100% {
        transform: scale(1.1) translate(-2%, 2%);
    }
}

/* 表示中のスライド（.swiper-slide-active）内の画像にだけアニメーションを適用 */
.hero-swiper .swiper-slide-active .slide-image {
    animation: kenburns 8s linear forwards; /* 8秒かけてズーム＆移動 */
}

/* ロゴ表示用のオーバーレイ（以前のコードを流用） */
.hero-content { 
    position: absolute; 
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%; 
    display: flex; 
    justify-content: center; 
    align-items: center; 
    z-index: 2; 
    background-color: rgba(0, 0, 0, 0.3); 
}
.hero-logo-box { 
    background-color: rgba(0, 0, 0, 0.5); 
    padding: 2rem 3rem; 
    width: 90%; 
    max-width: 500px; 
    opacity: 0; 
    animation: logo-appear 1.5s 0.5s ease-out forwards; 
}
.hero-logo-box img { 
    width: 100%; 
}
@keyframes logo-appear { 
    0% { opacity: 0; transform: translateY(20px); } 
    100% { opacity: 1; transform: translateY(0); } 
}
@keyframes slidefade { 
    0% { opacity: 0; } 
    3% { opacity: 1; }
    25% { opacity: 1; }
    28% { opacity: 0; }
    100% { opacity: 0; } 
}
.slide:nth-child(1) { animation-name: kenburns-1, slidefade; }
.slide:nth-child(2) { animation-name: kenburns-2, slidefade; }
.slide:nth-child(3) { animation-name: kenburns-3, slidefade; }
.slide:nth-child(4) { animation-name: kenburns-1, slidefade; animation-direction: alternate; }

@keyframes kenburns-1 { 0% { transform: scale(1) translate(0, 0); } 100% { transform: scale(1.1) translate(-2%, 2%); } }
@keyframes kenburns-2 { 0% { transform: scale(1) translate(0, 0); } 100% { transform: scale(1.1) translate(2%, -2%); } }
@keyframes kenburns-3 { 0% { transform: scale(1) translate(0, 0); } 100% { transform: scale(1.1) translate(-2%, -2%); } }

.hero-content { position: absolute; top: 0; left: 0; width: 100%; height: 100%; display: flex; justify-content: center; align-items: center; z-index: 2; background-color: rgba(0, 0, 0, 0.3); }
.hero-logo-box { background-color: rgba(0, 0, 0, 0.5); padding: 2rem 3rem; width: 90%; max-width: 500px; opacity: 0; animation: logo-appear 1.5s 0.5s ease-out forwards; }
.hero-logo-box img { width: 100%; }
@keyframes logo-appear { 0% { opacity: 0; transform: translateY(20px); } 100% { opacity: 1; transform: translateY(0); } }

/* --- General Section & Scrolling --- */
.section { padding: 100px 0; }

#staff,
#sponsors,
#instagram,
#past-events,
#seats {
    padding-top: 40px;
}

.section-title { font-family: var(--font-serif); font-size: 3rem; text-align: center; margin-bottom: 1rem; font-weight: 500; color: var(--primary-color); }
.section-subtitle { text-align: center; color: var(--light-text-color); margin-bottom: 60px; font-size: 1rem; }
.event-date { padding-bottom: 0; text-align: center; }
.event-date h3 { font-family: var(--font-serif); font-size: 2rem; color: var(--dark-charcoal); font-weight: 500; }
.event-date p { font-size: 1.4rem; color: var(--dark-charcoal); font-weight: bold; }

/* --- Staff Section (Swiper) --- */
.staff-scroll { background-color: var(--secondary-color); padding-bottom: 0; }
.staff-card { width: 350px; margin: 0px; text-align: center; background: #fff; padding: 25px 15px; border-radius: 8px; box-shadow: 0 5px 20px rgba(0,0,0,0.05); display: flex; flex-direction: column; align-items: center; }
.staff-card img { width: 300px; height: 300px; border-radius: 50%; object-fit: cover; margin: 20px 0 15px; display: block; }
.staff-card h4 { font-family: var(--font-serif); font-size: 1.5rem; margin-bottom: 5px; }
.staff-card p { color: var(--light-text-color); }
.staff-swiper { width: 100%; padding-top: 40px; padding-bottom: 40px; }
.swiper-wrapper { transition-timing-function: linear !important; }
.staff-swiper .swiper-slide { width: 370px; }

/* --- Sponsor Section (Grid) --- */
.sponsor-list { background-color: var(--secondary-color); padding-top: 120px; }
.sponsor-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; align-items: center; }
.sponsor-logo-item { display: flex; align-items: center; justify-content: center; padding: 15px; background-color: #fff; border: 1px solid #ddd; border-radius: 6px; transition: all 0.3s ease; box-shadow: 0 2px 5px rgba(0,0,0,0.05); }
.sponsor-logo-item:hover { border-color: var(--primary-color); transform: translateY(-3px); box-shadow: 0 5px 15px rgba(0,0,0,0.1); }
.sponsor-logo-item img { max-width: 100%; height: auto; }
.section-title a { transition: color 0.3s ease; }
.section-title a:hover { color: var(--gold-color); }

/* --- Instagram Feed Section --- */
.instagram-placeholder { border: 2px dashed var(--gold-color); padding: 30px; text-align: center; background-color: var(--secondary-color); border-radius: 8px; color: var(--light-text-color); }
.instagram-placeholder iframe { display: block; }




/* --- Gallery banner on Hero Section --- */
#gallery.section.gallery-scroll { position: absolute; bottom: 0; left: 0; width: 100%; z-index: 3; padding: 15px 0; background-color: rgba(0, 0, 0, 0.6); border-top: none; overflow: hidden; }
#gallery .reveal { opacity: 1; transform: none; }
#gallery .section-title, #gallery .section-subtitle { display: none; }
.gallery-swiper { padding: 0; width: 100%; height: 130px; }
.gallery-swiper .swiper-wrapper { align-items: center; }
.gallery-slide { width: auto; height: 100%; } 

/* ▼▼▼ 修正箇所 ▼▼▼ */
.gallery-item {
    width: 230px; /* ★変更点1：画像の幅を固定 */
    height: 100%;
    margin: 0;
    background-color: rgba(0,0,0,0.3); /* 画像の背景にうっすら色を敷く */
    border-radius: 4px; /* 親要素に角丸を設定 */
    overflow: hidden; /* 親要素からはみ出ないように */
    display: flex; /* 画像を中央に配置するために追加 */
    align-items: center; /* 画像を中央に配置するために追加 */
    justify-content: center; /* 画像を中央に配置するために追加 */
}
.gallery-item a {
    display: block;
    height: 100%;
    width: 100%; /* aタグも幅いっぱいに */
    transition: opacity 0.3s ease;
}
.gallery-item a:hover {
    opacity: 0.8;
}
.gallery-item img {
    width: 100%; /* ★変更点2：幅をコンテナに合わせる */
    height: 100%;
    object-fit: contain; /* ★変更点3：「cover」から「contain」へ変更 */
}
/* ▲▲▲ 修正箇所 ▲▲▲ */




/* --- Past Events Section --- */
.past-events-scroll { background-color: var(--secondary-color); border-top: 1px solid #eee; }
.past-events-container { display: flex; justify-content: center; align-items: center; gap: 50px; flex-wrap: wrap; }
.past-events-item { width: 400px; }
.past-events-item a { display: block; background: #fff; padding: 20px; border-radius: 8px; box-shadow: 0 5px 20px rgba(0,0,0,0.05); aspect-ratio: 1700 / 1200; transition: transform 0.3s ease, box-shadow 0.3s ease; }
.past-events-item a:hover { transform: translateY(-5px); box-shadow: 0 12px 25px rgba(0,0,0,0.1); }
.past-events-item img { width: 100%; height: 100%; object-fit: contain; }

/* --- Other Sections --- */
.cta-section { background-color: var(--dark-charcoal); color: #fff; text-align: center; }
.cta-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; max-width: 900px; margin: 0 auto; }
.cta-box { border: 1px solid rgba(255,255,255,0.2); padding: 40px; border-radius: 8px; }
.cta-box h3 { font-family: var(--font-serif); font-size: 2rem; color: var(--gold-color); margin-bottom: 15px; }
.cta-button { display: inline-block; padding: 15px 40px; background: var(--primary-color); color: #fff; border-radius: 50px; font-weight: bold; }
.cta-button:hover { background: #fff; color: var(--primary-color); transform: translateY(-3px); box-shadow: 0 4px 10px rgba(0,0,0,0.1); }
.cta-button i { margin-right: 8px; }
.cta-box .cta-button { margin-top: 20px; }
.footer { background-color: #2b2b2b; color: #eee; padding: 80px 0; font-size: 0.9rem; }
.footer-grid { max-width: 600px; margin: 0 auto; }
.footer-info h4, .footer-map h4 { font-family: var(--font-serif); font-size: 1.5rem; margin-bottom: 1.5rem; color: var(--gold-color); font-weight: 500; }
.social-icons { margin-top: 20px; }
.social-icons a { font-size: 1.8rem; margin-right: 20px; color: #ccc; }
.social-icons a:hover { color: #fff; }
.copyright { text-align: center; padding: 20px 0; font-size: 0.8rem; background-color: #1a1a1a; color: #aaa; }
.pagetop { position: fixed; right: 20px; bottom: 20px; display: none; }
.pagetop a { display: block; width: 50px; height: 50px; line-height: 50px; background: var(--primary-color); color: #fff; text-align: center; border-radius: 50%; box-shadow: 0 2px 10px rgba(0,0,0,0.2); font-size: 1.2rem; }
.reveal { opacity: 0; transform: translateY(40px); transition: opacity 1s, transform 1s; transition-timing-function: ease-out; }
.reveal.visible { opacity: 1; transform: translateY(0); }

/* --- Seat Chart Section (Button Only) --- */
.seat-chart-button-area {
    text-align: center;
}

/* ===============================================
// --- Responsive Adjustments ---
=============================================== */

/* PC Styles (Large Screens) */
@media (min-width: 769px) {
    .header-inner { 
        width: 97%; 
        align-items: center; 
    }
    .logo { 
        font-size: 1.6rem;
        line-height: 1.25;
    } 
    .header.scrolled .logo { 
        font-size: 1.4rem;
    }
    .hamburger-icon { display: none; } 
    .nav-menu.pc-menu { 
        display: block; 
        margin-left: auto;
    } 
    .nav-menu ul { display: flex; list-style: none; align-items: center; }
    .nav-menu li { 
        margin-left: 20px;
    }
    .nav-menu a { 
        font-size: 1rem; 
        color: #fff; 
        font-weight: bold;
        position: relative; 
        padding-bottom: 5px; 
    }
    .nav-menu a::after { content: ''; position: absolute; bottom: 0; left: 0; width: 0; height: 1px; background-color: var(--gold-color); transition: width 0.3s ease; }
    .nav-menu a:hover::after { width: 100%; }
    .header.scrolled .nav-menu a { color: var(--text-color); }
    .header.scrolled .nav-menu a:hover { color: var(--primary-color); }
    
    .staff-swiper { max-width: 1270px; margin-left: auto; margin-right: auto; }
}

/* Tablet Styles */
@media (max-width: 1024px) {
    .sponsor-grid { grid-template-columns: repeat(3, 1fr); }
}

/* Mobile Styles (Small Screens) */
@media (max-width: 768px) {
    .header-inner {
        justify-content: space-between;
        align-items: center;
        padding-top: 15px;
        padding-bottom: 15px;
    }
    .hamburger-icon {
        margin-left: auto;
    }
    .header.scrolled .header-inner { 
        padding-top: 10px;
        padding-bottom: 10px;
    }
    .section { padding: 60px 0; }
    .section-title { font-size: 2.2rem; }
    .header.scrolled { padding-top: 0; padding-bottom: 0; }
    .hero-logo-box { padding: 1.5rem; }
    .cta-grid { grid-template-columns: 1fr; gap: 30px; }
    .event-date h3 { font-size: 2rem; }
    .staff-card { width: 200px; padding: 20px 10px; }
    .staff-swiper .swiper-slide { width: 220px; }
    .staff-card img { width: 180px; height: 180px; }
    .sponsor-list { padding-top: 40px; }
    .past-events-item { width: 300px; }
    .slide:nth-child(1) { background-image: url('../image/top/top1s.png'); }
    .slide:nth-child(2) { background-image: url('../image/top/top3s.png'); }
    .slide:nth-child(3) { background-image: url('../image/top/top2s.png'); }
    .slide:nth-child(4) { background-image: url('../image/top/top4s.png'); }
    .sponsor-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    #gallery.section.gallery-scroll { padding: 0; bottom: 60px; }
    .gallery-swiper { height: 150px; }
    .gallery-slide { width: auto !important; }
    .gallery-item { margin: 0 !important; padding: 0 !important; }
    .gallery-item a { border-radius: 2px; padding: 0; margin: 0; }
    .gallery-item img { display: block; margin: 0; padding: 0; }
}