/* =========================================
   基本カラー設定
   ========================================= */
:root {
    --bg-color: #111111;
    --text-main: #f0f0f0;      /* 少し柔らかい白 */
    --text-sub: #888888;
    --accent-color: #333333;
    --gold-accent: #c4a778;    /* 和風な金色のアクセント */
}

/* スクロール設定 */
html {
    scroll-behavior: smooth;
    height: auto;
    min-height: 100%;
}

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

body {
    font-family: 'Noto Serif JP', 'Inter', serif;
    background-color: var(--bg-color);
    color: var(--text-main);
    margin: 0;
    padding: 0;
    line-height: 2.2;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
    height: auto;
    min-height: 100vh;
}

a {
    color: inherit;
    text-decoration: none;
    transition: all 0.4s ease;
}

/* ローディング画面のスタイル定義を削除しました */

/* =========================================
   共通コンポーネントスタイル
   ========================================= */
/* セクション共通（ベース） */
section {
    border-bottom: 1px solid var(--accent-color);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* サイドバー要素（ベース） */
.sidebar-header {
    margin-bottom: 1.5rem;
    text-align: center;
    width: 100%;
    flex-shrink: 0;
}
.site-logo {
    width: 100%;
    max-width: 150px;
    height: auto;
    display: block;
    margin: 0 auto 1rem;
}
.site-title {
    font-size: 2rem;
    margin: 0 0 1rem;
    line-height: 1.2;
}
.nav-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    align-items: center;
    width: 100%;
}
.nav-item { width: 90%; }
.js-enabled .nav-item {
    opacity: 0;
    transform: translateY(20px);
}
.nav-item a {
    display: block;
    width: 100%;
    text-align: center;
    padding: 0.8rem 0;
    font-size: 0.95rem;
    letter-spacing: 0.15em;
    color: var(--text-sub);
    border: 1px solid var(--accent-color);
    position: relative;
    transition: all 0.4s ease;
    background-color: transparent;
}
.nav-item a:hover,
.nav-item a.active {
    color: var(--gold-accent);
    border-color: var(--gold-accent);
    background-color: rgba(196, 167, 120, 0.1);
}
.sidebar-footer {
    margin-top: auto;
    text-align: center;
    padding-top: 1.5rem;
    padding-bottom: 1rem;
    width: 100%;
    flex-shrink: 0;
}

/* セクションタイトル共通 */
.section-header {
    margin-bottom: 4rem;
    text-align: left;
}
.section-title-en {
    font-family: 'Inter', sans-serif;
    font-size: 0.8rem;
    color: var(--gold-accent);
    letter-spacing: 0.2em;
    text-transform: uppercase;
    display: block;
    margin-bottom: 0.5rem;
}
.section-title-ja {
    font-size: 2rem;
    font-weight: 500;
    letter-spacing: 0.1em;
    margin: 0;
    color: var(--text-main);
}

/* メインビジュアル共通 */
#hero-slider-section {
    position: relative;
    overflow: hidden;
    background-color: #000;
    padding: 0;
}
.slider-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}
.slide-item {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 2.5s ease-in-out;
    z-index: 1;
    background-color: #000;
}
.slide-item.active {
    opacity: 1;
    z-index: 2;
}
.slide-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.05);
    transition: transform 10s ease;
    filter: brightness(0.6);
}
.slide-item.active img { transform: scale(1.1); }
.hero-text-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    pointer-events: none;
}
.hero-text {
    color: #fff;
    font-family: 'Noto Serif JP', serif;
    font-weight: 500;
    letter-spacing: 0.3em;
    text-shadow: 0 4px 20px rgba(0,0,0,0.8);
    white-space: nowrap;
    opacity: 0;
    transform: translateY(10px) scale(0.98);
    transition: opacity 2.5s ease-out, transform 2.5s ease-out;
    transition-delay: 0.5s;
}
.slide-item.active .hero-text {
    opacity: 1;
    transform: translateY(0) scale(1);
}
.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    right: 4rem;
    z-index: 10;
    color: #fff;
    font-family: 'Inter', sans-serif;
    font-size: 0.8rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    writing-mode: vertical-rl;
    text-orientation: mixed;
    opacity: 0.7;
    display: flex;
    align-items: center;
    gap: 1rem;
}
.scroll-indicator::after {
    content: '';
    display: block;
    width: 1px;
    height: 60px;
    background-color: #fff;
    animation: scrollDown 2s infinite;
}
@keyframes scrollDown {
    0% { transform: scaleY(0); transform-origin: top; }
    50% { transform: scaleY(1); transform-origin: top; }
    51% { transform: scaleY(1); transform-origin: bottom; }
    100% { transform: scaleY(0); transform-origin: bottom; }
}

/* Concept共通 */
#concept {
    background-image: url('../img/namikaze-concept.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}
/* 追加：テキスト色と基本スタイルの復元 */
#concept .section-title-ja {
    color: #1a1a1a;
}
#concept .concept-text {
    font-family: 'Noto Serif JP', serif;
    color: #333333;
    letter-spacing: 0.15em;
    line-height: 2.6;
}

/* Course Menu共通 */
.course-list {
    list-style: none;
    padding: 0;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr;
}
.course-item { cursor: default; }
.js-enabled .course-item { opacity: 0; transform: translateY(20px); }
.course-image-container {
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background-color: #1a1a1a;
    position: relative;
    margin-bottom: 2rem;
}
.course-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s ease;
    filter: brightness(0.9);
}
.course-item:hover .course-img {
    transform: scale(1.05);
    filter: brightness(1.0);
}
.course-info { text-align: left; }
.course-title {
    font-weight: 500;
    margin-bottom: 0.5rem;
    letter-spacing: 0.1em;
    display: block;
}
.course-price {
    font-family: 'Inter', sans-serif;
    font-size: 1.1rem;
    color: var(--gold-accent);
    display: block;
    margin-bottom: 1.5rem;
    letter-spacing: 0.05em;
}
.course-desc {
    font-size: 1rem;
    color: #e0e0e0;
    line-height: 2;
    text-align: justify;
}

/* Rooms共通 */
.room-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
}
.room-item {
    display: flex;
    align-items: center;
}
.js-enabled .room-item { opacity: 0; transform: translateY(20px); }
.room-image-wrapper {
    flex: 1;
    overflow: hidden;
    background-color: #1a1a1a;
    position: relative;
    cursor: pointer;
}
.room-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s ease, filter 0.5s ease;
    filter: brightness(0.9);
}
.room-image-wrapper:hover .room-img {
    transform: scale(1.05);
    filter: brightness(1.05);
}
.room-image-wrapper::after {
    content: '+';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0);
    color: #fff;
    font-size: 2rem;
    font-weight: 300;
    background-color: rgba(0,0,0,0.3);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    border: 1px solid rgba(255,255,255,0.5);
    transition: transform 0.3s ease;
    pointer-events: none;
}
.room-image-wrapper:hover::after { transform: translate(-50%, -50%) scale(1); }
.room-info { flex: 1; text-align: left; }
.room-title {
    font-size: 1.6rem;
    font-weight: 500;
    margin-bottom: 1rem;
    letter-spacing: 0.1em;
    display: block;
    border-bottom: 1px solid var(--accent-color);
    padding-bottom: 0.5rem;
    display: inline-block;
    min-width: 150px;
}
.room-capacity {
    font-size: 0.95rem;
    color: var(--gold-accent);
    display: block;
    margin-bottom: 1rem;
    font-family: 'Inter', sans-serif;
    letter-spacing: 0.05em;
}
.room-desc {
    font-size: 0.95rem;
    color: #e0e0e0;
    line-height: 2;
    text-align: justify;
}

/* Sake共通 */
.sake-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
}
.sake-item { cursor: default; }
.js-enabled .sake-item { opacity: 0; transform: translateY(20px); }
.sake-image-wrapper {
    width: 100%;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background-color: #1a1a1a;
    margin-bottom: 1.5rem;
    position: relative;
}
.sake-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s ease;
}
.sake-item:hover .sake-img {
    transform: scale(1.05);
    filter: brightness(1.05);
}
.sake-info { text-align: center; }
.sake-title {
    font-size: 1.2rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
    display: block;
    letter-spacing: 0.1em;
}
.sake-meta {
    font-size: 0.85rem;
    color: var(--text-sub);
    letter-spacing: 0.05em;
}

/* Manager共通 */
.manager-profile {
    display: flex;
    align-items: center;
}
.js-enabled .manager-profile { opacity: 0; transform: translateY(20px); }
.manager-image-wrapper {
    flex: 1;
    width: 100%;
    height: auto;
    overflow: hidden;
    background-color: #1a1a1a;
    position: relative;
}
.manager-img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.8s ease, filter 0.5s ease;
    filter: brightness(0.9);
}
.manager-info { flex: 1; text-align: left; }
.manager-name {
    font-size: 1.6rem;
    font-weight: 500;
    margin-bottom: 1rem;
    letter-spacing: 0.1em;
    display: block;
    border-bottom: 1px solid var(--accent-color);
    padding-bottom: 0.5rem;
    display: inline-block;
    min-width: 150px;
}
.manager-desc {
    font-size: 0.95rem;
    color: #e0e0e0;
    line-height: 2;
    text-align: justify;
    writing-mode: horizontal-tb;
}

/* Info共通 */
.info-grid {
    display: grid;
    align-items: start;
}
.info-dl {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 1.5rem 2rem;
    margin: 0;
}
.info-dt {
    color: var(--text-sub);
    font-size: 1.05rem;
    font-weight: 500;
}
.info-dd {
    margin: 0;
    font-size: 1.15rem;
    line-height: 1.8;
}

/* =================================================================
   ▼▼▼ PC (1025px以上) ▼▼▼
   ================================================================= */
@media (min-width: 1025px) {
    .sp-only { display: none !important; }
    
    .layout-wrapper {
        display: flex;
        min-height: 100vh;
    }
    .sidebar {
        /* 幅を380pxに拡張してメニューの余裕をさらに確保 */
        width: 380px;
        position: fixed;
        top: 0;
        left: 0;
        height: 100vh;
        /* メニューボックスを広げるため、左右のパディングを減らして内部幅を確保 */
        padding: 2rem 0.5rem;
        display: flex;
        flex-direction: column;
        align-items: center;
        border-right: 1px solid var(--accent-color);
        z-index: 50;
        background-color: var(--bg-color);
        overflow-y: auto;
        scrollbar-width: none;
    }
    .sidebar::-webkit-scrollbar { display: none; }

    /* PC画面でのメニュー幅修正: テキスト改行防止のため幅を100%に設定 */
    .nav-item {
        width: 100%;
    }
    
    .main-content {
        /* サイドバー拡張に合わせて調整 */
        margin-left: 380px;
        width: calc(100% - 380px);
        padding: 0;
    }

    .js-enabled .sidebar { opacity: 0; }
    .js-enabled .main-content { opacity: 0; }

    section {
        padding: 6rem 4rem;
        min-height: 80vh;
    }

    /* Hero */
    #hero-slider-section { min-height: 100vh; }
    .hero-text { font-size: 3rem; }

    /* Concept (PC固有: 縦書き) */
    #concept {
        flex-direction: row-reverse;
        justify-content: center;
        align-items: flex-start;
        gap: 4rem;
    }
    #concept .section-header {
        writing-mode: vertical-rl;
        text-orientation: upright;
        height: 500px;
        margin-bottom: 0;
        margin-left: 2rem;
    }
    #concept .section-title-en {
        margin-bottom: 0;
        margin-left: 1.5rem;
        writing-mode: vertical-rl;
        text-orientation: mixed;
    }
    #concept .section-title-ja {
        font-size: 2.2rem;
        line-height: 1.8;
    }
    #concept .concept-text {
        writing-mode: vertical-rl;
        text-orientation: upright;
        height: 500px;
        width: auto;
        max-width: 90vw;
        margin: 2rem 0;
        overflow-x: auto;
        font-size: 1.15rem;
        line-height: 2.6;
    }
    #concept .concept-text p { margin: 0 0 0 2.5rem; }

    /* Course */
    .course-list { gap: 6rem; max-width: 960px; }
    .course-title { font-size: 1.8rem; }

    /* Rooms */
    .room-list { gap: 6rem; }
    .room-item { gap: 4rem; }
    .room-item:nth-child(even) { flex-direction: row-reverse; }
    .room-image-wrapper { aspect-ratio: 4 / 3; }

    /* Sake */
    .sake-list { grid-template-columns: repeat(2, 1fr); gap: 4rem; }

    /* Manager */
    .manager-profile { gap: 4rem; }

    /* Info */
    .info-grid { grid-template-columns: 1fr 1fr; gap: 4rem; }
}


/* =================================================================
   ▼▼▼ タブレット (769px 〜 1024px) ▼▼▼
   ================================================================= */
@media (min-width: 769px) and (max-width: 1024px) {
    .pc-only { display: none !important; }
    .sp-only { display: block !important; } /* フッター等はsp-onlyを使用 */

    .layout-wrapper { display: block; }
    
    /* サイドバー非表示 */
    .sidebar { display: none; }
    
    .main-content {
        width: 100%;
        margin: 0;
        padding-bottom: 0;
    }

    section {
        padding: 4rem 2rem;
        min-height: auto;
    }

    /* フッター(#sp-menu)の調整 */
    #sp-menu { padding: 3rem 1.5rem 4rem !important; }

    /* Hero */
    #hero-slider-section {
        min-height: 50vh;
        height: 50vh;
    }
    .hero-text { font-size: 1.8rem; }

    /* Concept (タブレット用特別設定) */
    #concept {
        flex-direction: column;
        align-items: center;
        /* 指示のあったパディング変更: タイトルを上に上げるため上部のpaddingを減らす */
        padding: 5rem 1.5rem; /* 8rem -> 5rem に変更 */
        background-position: 70% center;
    }
    #concept .section-header {
        writing-mode: horizontal-tb !important;
        width: 100%;
        height: auto;
        max-height: none;
        /* タイトルとテキストの距離を広げる */
        margin: 0 0 4rem 0; /* 0.5rem -> 4rem に変更 */
        align-items: center;
        text-align: center;
        flex-direction: column;
    }
    #concept .section-title-en {
        writing-mode: horizontal-tb !important;
        margin-left: 0;
        margin-bottom: 0.2rem;
        font-size: 1rem;
    }
    #concept .section-title-ja {
        writing-mode: horizontal-tb !important;
        font-size: 2.4rem; /* 大きく */
        line-height: 1.3;
    }
    #concept .concept-text {
        height: auto;
        max-height: none;
        font-size: 1.2rem; /* 大きく */
        margin: 0 auto;
        width: 100%;
        writing-mode: horizontal-tb !important;
        text-orientation: mixed;
        text-align: center;
    }
    #concept .concept-text p {
        margin: 0 0 0.5rem 0;
        text-align: center;
    }

    /* Course */
    .course-list { gap: 6rem; max-width: 960px; }
    .course-title { font-size: 1.8rem; }

    /* Rooms */
    .room-list { gap: 6rem; }
    .room-item { gap: 2rem; } /* 少し狭く */
    .room-item:nth-child(even) { flex-direction: row-reverse; }
    .room-image-wrapper { aspect-ratio: 4 / 3; }

    /* Sake (PCと同じ2列グリッド) */
    .sake-list { grid-template-columns: repeat(2, 1fr); gap: 4rem; }

    /* Manager (タブレットは縦並びにするレイアウトが多いので縦にします) */
    .manager-profile {
        flex-direction: column !important;
        gap: 1.5rem;
    }
    .manager-image-wrapper { width: 100%; }
    .manager-info { width: 100%; }
    .manager-name { font-size: 1.4rem; display: block; }
    /* Managerセクション独自のパディング調整 */
    #manager { padding: 3rem 2rem; }

    /* Info */
    .info-grid { grid-template-columns: 1fr 1fr; gap: 4rem; }
    #info { padding: 1.5rem 2rem; }
}


/* =================================================================
   ▼▼▼ スマホ (768px以下) ▼▼▼
   ================================================================= */
@media (max-width: 768px) {
    .pc-only { display: none !important; }
    
    .layout-wrapper { display: block; }
    .sidebar { display: none; }
    .main-content {
        width: 100%;
        margin: 0;
        padding-bottom: 0;
    }

    /* Loading画面設定削除 */

    section {
        padding: 4rem 1.5rem;
        min-height: auto;
    }

    /* フッター(#sp-menu)の調整 */
    #sp-menu { padding: 3rem 1.5rem 4rem !important; }

    /* Hero */
    #hero-slider-section {
        min-height: auto;
        height: auto;
        width: 100%;
        aspect-ratio: 1 / 1;
    }
    .hero-text {
        font-size: 1.3rem;
        letter-spacing: 0.1em;
        white-space: normal;
        text-align: center;
        width: 90%;
    }

    /* Concept (スマホレイアウト) */
    #concept {
        flex-direction: column;
        align-items: center;
        padding: 4rem 1.5rem; /* スマホ標準 */
        background-position: 70% center;
    }
    #concept .section-header {
        writing-mode: horizontal-tb !important;
        width: 100%;
        height: auto;
        max-height: none;
        margin: 0 0 1rem 0;
        align-items: center;
        text-align: center;
        flex-direction: column;
    }
    #concept .section-title-en {
        writing-mode: horizontal-tb !important;
        margin-left: 0;
        margin-bottom: 0.5rem;
        font-size: 0.85rem;
    }
    #concept .section-title-ja {
        writing-mode: horizontal-tb !important;
        font-size: 1.6rem;
        line-height: 1.6;
    }
    #concept .concept-text {
        height: auto;
        max-height: none;
        font-size: 1.0rem;
        margin: 0 auto;
        width: 100%;
        writing-mode: horizontal-tb !important;
        text-orientation: mixed;
        text-align: center;
    }
    #concept .concept-text p {
        margin: 0 0 1rem 0;
        text-align: center;
    }

    /* Course */
    .course-list { gap: 4rem; max-width: 100%; }
    .course-title { font-size: 1.5rem; }

    /* Rooms (縦並び) */
    .room-list { gap: 4rem; }
    .room-item,
    .room-item:nth-child(even) {
        flex-direction: column !important;
        gap: 1.5rem;
    }
    .room-image-wrapper { width: 100%; aspect-ratio: 3 / 2; }
    .room-info { width: 100%; }
    .room-title { font-size: 1.4rem; display: block; }

    /* Sake (横スクロール) */
    .sake-list {
        display: flex;
        grid-template-columns: none;
        gap: 1.5rem;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        padding: 0 10% 2rem;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }
    .sake-list::-webkit-scrollbar { display: none; }
    .sake-item {
        flex: 0 0 80%;
        scroll-snap-align: center;
        opacity: 1;
        transform: none;
    }

    /* Manager (縦並び) */
    .manager-profile {
        flex-direction: column !important;
        gap: 1.5rem;
    }
    .manager-image-wrapper { width: 100%; }
    .manager-info { width: 100%; }
    .manager-name { font-size: 1.4rem; display: block; }
    #manager { padding: 4rem 1.5rem; }

    /* Info */
    .info-grid { grid-template-columns: 1fr; gap: 2rem; }
    #info { padding: 4rem 1.5rem; }
}


/* =========================================
   モーダル (共通)
   ========================================= */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(10, 10, 10, 0.98);
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem;
}

.modal-content {
    width: 100%;
    max-width: 900px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    position: relative;
}

.modal-image-wrapper {
    flex: 1;
    width: 100%;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.modal-img {
    max-width: 100%;
    max-height: 60vh;
    object-fit: contain;
}

.modal-details {
    text-align: center;
    color: #fff;
}

.close-btn {
    position: absolute;
    top: -2rem;
    right: 0;
    background: none;
    border: none;
    color: #fff;
    font-size: 2rem;
    cursor: pointer;
    z-index: 2001;
}