/* ------------------------------------------------------------------- */
/* 1. ベース設定と変数 */
/* ------------------------------------------------------------------- */

:root {
    --color-black: #111111;
    --color-gray-dark: #333333;
    --color-gray-medium: #888888;
    --color-gray-light: #E0E0E0;
    --color-white: #FFFFFF;
    
    /* PCで4枚分表示 */
    --card-size: 22vw;
    --card-gap: 16px;
}

@media (max-width: 1024px) {
    :root {
        --card-size: 40vw; 
    }
}

@media (max-width: 600px) {
    :root {
        --card-size: 80vw; 
    }
}

body {
    line-height: 1.6;
    margin: 0;
    padding: 0;
    background-color: #FFFFFF;
    color: var(--color-black);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

/* ------------------------------------------------------------------- */
/* 2. ページ構造 */
/* ------------------------------------------------------------------- */
.l-container-header{
    max-width: 1200px;
    margin: 6.6rem auto 40px auto;
    padding: 0 15px;
}
.page-container {
    display: flex;
    flex-direction: column;
}

.content-wrapper {
    width: 100%;
    margin: 0;
    padding: 0;
}

/* ------------------------------------------------------------------- */
/* 3. ヘッダー (左揃え) */
/* ------------------------------------------------------------------- */

.page-header {
    background-color: transparent;
    color: var(--color-black);
    text-align: left;
    padding: 3rem 1rem;
    margin: 0 auto 2rem auto;
    max-width: 1200px;
    box-sizing: border-box;
}

.page-title {
    font-size: 4.4rem;
    margin: 0;
}

.page-subtitle {
    margin-top: 0.5rem;
    font-size: 0.9rem;
    color: var(--color-gray-medium);
}

.color-accent { color: var(--color-gray-medium); }

/* ------------------------------------------------------------------- */
/* 4. ナビゲーションエリア (左揃え) */
/* ------------------------------------------------------------------- */

.sticky-nav-wrapper {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto 2rem;
    padding: 0 1rem;
    display: flex;
    justify-content: flex-start;
    box-sizing: border-box;
}

.year-nav-wrapper {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
    justify-content: flex-start;
}

.year-nav-title {
    font-size: 0.9rem;
    margin: 0;
    white-space: nowrap;
}

.year-list {
    display: flex;
    gap: 0.5rem;
    list-style: none;
    margin: 0;
    padding: 0;
    flex-wrap: wrap;
    justify-content: flex-start;
}

.year-link {
    display: block;
    padding: 0.5rem 1.5rem;
    font-size: 0.9rem;
    border: 1px solid var(--color-gray-light);
    background-color: var(--color-white);
    color: var(--color-black);
    transition: all 0.2s;
    cursor: pointer;
    border-radius: 999px;
}

.year-link:hover { border-color: var(--color-black); }

.year-link.active {
    background-color: var(--color-black);
    color: var(--color-white);
    border-color: var(--color-black);
}

/* ------------------------------------------------------------------- */
/* 5. タイムライン (カルーセル) */
/* ------------------------------------------------------------------- */

.timeline-main {
    width: 100%;
    padding-bottom: 4rem;
    position: relative;
}

/* スクロール領域 (CSSのsmoothは削除!) */
.event-scroll-wrapper {
    width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
    -ms-overflow-style: none;
    
    display: flex;
    padding: 1rem 0 2rem 0;
    
    /* 重要: JSで瞬間移動させるためにCSSのsmoothスクロールは削除 */
    /* scroll-behavior: smooth; */
    
    -webkit-overflow-scrolling: touch;
}

.event-scroll-wrapper::-webkit-scrollbar { display: none; }

.event-timeline {
    display: flex;
    gap: var(--card-gap);
    margin: 0;
    /* 左端見切れ用のパディング */
    padding: 0 calc(50vw - var(--card-size) / 2); 
    list-style: none;
    flex-wrap: nowrap; 
}

/* ナビゲーションボタン */
.carousel-btn {
    position: absolute;
    top: 45%;
    transform: translateY(-50%);
    width: 48px;
    height: 48px;
    background-color: rgba(255, 255, 255, 0.9);
    border: 1px solid var(--color-gray-light);
    border-radius: 50%;
    color: var(--color-black);
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    transition: all 0.2s ease;
}

.carousel-btn:hover {
    background-color: var(--color-black);
    color: var(--color-white);
    border-color: var(--color-black);
}

.carousel-btn.prev { left: 2rem; }
.carousel-btn.next { right: 2rem; }

/* ページネーション */
.carousel-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 1rem;
    padding: 1rem;
}

.dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: var(--color-gray-light);
    cursor: pointer;
    transition: all 0.3s ease;
}

.dot.active {
    background-color: var(--color-black);
    transform: scale(1.2);
}

.dot:hover { background-color: var(--color-gray-medium); }

/* ------------------------------------------------------------------- */
/* 6. イベントカード */
/* ------------------------------------------------------------------- */

.event-card {
    display: block;
    position: relative;
    width: var(--card-size);
    height: var(--card-size); /* 正方形 */
    flex-shrink: 0;
    background-color: var(--color-gray-light);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    backface-visibility: hidden;
}

.event-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.15);
    z-index: 5;
}

.event-image-area {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-color: #EEEEEE;
    transition: transform 0.5s ease;
}

.event-card:hover .event-image-area { transform: scale(1.03); }

.event-content-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 1.25rem;
    box-sizing: border-box;
    background: none; 
    color: var(--color-white);
}

.event-title {
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.4;
    margin: 0 0 0.25rem 0;
    text-shadow: 0 2px 4px rgba(0,0,0,0.9);
}

.event-meta {
    font-size: 0.8rem;
    opacity: 1;
    display: flex;
    gap: 0.5rem;
    margin-top: 0;
    text-shadow: 0 2px 4px rgba(0,0,0,0.9);
}

/* 月バッジは削除済みのためスタイルなし */

/* ------------------------------------------------------------------- */
/* 7. データなしメッセージ */
/* ------------------------------------------------------------------- */

.no-data-message {
    width: 100%;
    text-align: center;
    padding: 4rem;
}

.hidden { display: none !important; }