/* 蝓ｺ譛ｬ逧�縺ｪ繝ｪ繧ｻ繝�繝医→險ｭ螳� */
body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Hiragino Kaku Gothic ProN", "Hiragino Sans", "Meiryo", sans-serif;
    background-color: #000;
    color: #fff;
    overflow-x: hidden; /* 讓ｪ繧ｹ繧ｯ繝ｭ繝ｼ繝ｫ繧堤ｦ∵ｭ｢ */
}

/* 菴懷刀縺御ｸｦ縺ｶ繧ｳ繝ｳ繝�繝翫�ｮ繧ｹ繧ｿ繧､繝ｫ */
#works-container {
    padding: 100px 50px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 200px; /* 蜷�菴懷刀髢薙�ｮ繧ｹ繝壹�ｼ繧ｹ */
}

/* 蜷�菴懷刀繧｢繧､繝�繝�縺ｮ蝓ｺ譛ｬ繧ｹ繧ｿ繧､繝ｫ */
.work-item {
    text-align: center;
}

.work-item img {
    width: 300px;
    height: 300px;
    object-fit: cover;
    border: 2px solid white;
}

.work-item h2 {
    font-size: 2rem;
    margin: 20px 0 5px 0;
}

.work-item p {
    font-size: 1.2rem;
    color: #aaa;
} 

/* --- Step 4: 繧ｿ繧､繝昴げ繝ｩ繝輔ぅ繝ｻ繧ｨ繝輔ぉ繧ｯ繝� --- */

header {
    /* 逕ｻ髱｢蜈ｨ菴薙ｒ隕�縺�繧医≧縺ｫ險ｭ螳� */
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

.distortion-text h1 {
    font-size: 15vw; /* 逕ｻ髱｢蟷�縺ｫ蠢懊§縺ｦ譁�蟄励し繧､繧ｺ縺悟､峨ｏ繧九ｈ縺�縺ｫ */
    font-weight: 900;
    text-align: center;
    color: #fff;
    
    /* SVG繝輔ぅ繝ｫ繧ｿ繝ｼ繧帝←逕ｨ */
    filter: url(#distortion-filter);
    
    /* 繧｢繝九Γ繝ｼ繧ｷ繝ｧ繝ｳ縺ｮ縺溘ａ縺ｮ險ｭ螳� */
    transition: filter 0.1s ease-out;
}
/* --- Step 5: 3D繧ｪ繝悶ず繧ｧ繧ｯ繝� --- */
.jacket-canvas-container {
    width: 300px;
    height: 300px;
    margin: 0 auto; /* 荳ｭ螟ｮ謠�縺� */
}

/* --- Step 6: 邂｡逅�閠�繝壹�ｼ繧ｸ --- */

.admin-page {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    text-align: center;
}

.login-container, #admin-link-container {
    background-color: #111;
    padding: 40px;
    border-radius: 8px;
    border: 1px solid #333;
}

.login-container h2, #admin-link-container h3 {
    margin-top: 0;
}

.login-container input {
    display: block;
    width: 250px;
    padding: 10px;
    margin: 20px auto;
    background-color: #222;
    border: 1px solid #444;
    color: #fff;
    font-size: 1rem;
}

.login-container button {
    padding: 10px 30px;
    background-color: #fff;
    color: #000;
    border: none;
    border-radius: 4px;
    font-size: 1rem;
    cursor: pointer;
    transition: background-color 0.2s;
}

.login-container button:hover {
    background-color: #ccc;
}

.error {
    color: #ff6b6b;
    margin-top: 15px;
    height: 20px;
}





#admin-link-container a {
    display: inline-block;
    margin-top: 20px;
    padding: 15px 30px;
    background-color: #4a90e2;
    color: #fff;
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
}
#admin-link-container a:hover {
    background-color: #357abd;
}

/* --- Step 7: UI/UX 繧｢繝�繝励げ繝ｬ繝ｼ繝� --- */

/* 繧ｻ繧ｯ繧ｷ繝ｧ繝ｳ蜈ｱ騾壹せ繧ｿ繧､繝ｫ */
section {
    padding: 100px 50px;
}
section h2 {
    font-size: 3rem;
    text-align: center;
    margin-bottom: 60px;
}

/* 莉｣陦ｨ譖ｲ繧ｰ繝ｪ繝�繝� */
.works-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
}

/* 讓ｪ繧ｹ繧ｯ繝ｭ繝ｼ繝ｫ繧ｮ繝｣繝ｩ繝ｪ繝ｼ */
.scrolling-wrapper {
    overflow-x: auto;
    cursor: grab;
    padding: 20px 0;
}
.works-gallery {
    display: flex;
    gap: 30px;
}
.scrolling-wrapper::-webkit-scrollbar {
    display: none; /* 繧ｹ繧ｯ繝ｭ繝ｼ繝ｫ繝舌�ｼ繧帝國縺� */
}
/* 讓ｪ繧ｹ繧ｯ繝ｭ繝ｼ繝ｫ繧ｮ繝｣繝ｩ繝ｪ繝ｼ蜀�縺ｮ蜷�繧｢繧､繝�繝� */
.gallery-item .jacket-canvas-container {
    width: 250px;
    height: 250px;
}
.gallery-item h2 { font-size: 1.2rem; }
.gallery-item p { font-size: 1rem; }


/* 繧ｯ繝ｪ繝�繧ｯ蜿ｯ閭ｽ繧ｫ繝ｼ繧ｽ繝ｫ */
.work-item {
    cursor: pointer;
    transition: transform 0.2s ease-out;
}
.work-item:hover {
    transform: scale(1.05);
}


/* 繝｢繝ｼ繝繝ｫ繧ｦ繧｣繝ｳ繝峨え */
#modal-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    backdrop-filter: blur(10px);
}
#modal-content {
    display: flex;
    background-color: #1a1a1a;
    width: 90%;
    max-width: 900px;
    max-height: 80vh;
    border-radius: 10px;
    position: relative;
    padding: 30px;
    gap: 30px;
}
#modal-close-button {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    color: #fff;
    font-size: 2.5rem;
    cursor: pointer;
}
#modal-jacket {
    width: 300px;
    height: 300px;
    flex-shrink: 0;
}
#modal-jacket img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 5px;
}
#modal-info h3 { font-size: 2rem; margin-top: 0; }
#modal-info p { color: #ccc; }
#modal-links a {
    display: inline-block;
    margin-right: 10px;
    padding: 10px 20px;
    background-color: #1DB954; /* Spotify Green */
    color: white;
    text-decoration: none;
    border-radius: 20px;
    font-weight: bold;
}
#modal-preview {
    margin-top: 20px;
}
#modal-preview iframe {
    border-radius: 12px;
}

/* --- Step 9: スマートフォン対応 (レスポンシブ) --- */

@media (max-width: 768px) {

    /* --- 全体的な調整 --- */
    section {
        padding: 60px 20px; /* 上下の余白を狭く、左右の余白も調整 */
    }

    section h2 {
        font-size: 2.2rem; /* セクションタイトルの文字を少し小さく */
        margin-bottom: 40px;
    }

    /* --- ヘッダーのタイポグラフィ --- */
    .distortion-text h1 {
        font-size: 20vw; /* スマホ画面ではvwが効果的 */
    }

    /* --- 3Dジャケットのサイズ調整 --- */
    .jacket-canvas-container {
        display: block; /* ← 追加 */
        width: 70vw;
        height: 70vw;
        margin: 0 auto; /* ← 追加（念のため中央揃えを再指定） */
    }

    /* --- 横スクロールギャラリーの調整 --- */
    .gallery-item .jacket-canvas-container {
        width: 220px; /* ギャラリー内のアイテムサイズを少し小さく */
        height: 220px;
    }

    /* --- モーダルウィンドウのレイアウト変更 --- */
    #modal-content {
        flex-direction: column; /* 縦並びに変更 */
        align-items: center;    /* 中央揃え */
        padding: 20px;
        max-height: 90vh; /* 高さを画面の90%までに */
        overflow-y: auto;   /* 内容が多ければスクロール可能に */
    }

    #modal-jacket {
        width: 100%;
        max-width: 250px; /* ジャケット画像の最大幅を指定 */
        height: auto;
        aspect-ratio: 1 / 1; /* 縦横比を1:1に */
    }

    #modal-info {
        text-align: center; /* テキストを中央揃えに */
    }
    
    #modal-info h3 {
        font-size: 1.5rem;
    }

    #modal-links {
        display: flex;
        flex-direction: column; /* リンクボタンを縦に並べる */
        gap: 10px;
        align-items: center;
    }
    
    #modal-links a {
        width: 80%; /* ボタン幅を広げる */
        text-align: center;
    }
}

/* .hidden */
.hidden {
    display: none !important;
}