/* ========================================
   リセット & ベース設定
   ブラウザのデフォルトスタイルをリセット
   ======================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* ========================================
   CSS変数定義
   サイト全体で使用するカラーやサイズを一元管理
   ======================================== */
:root {
    --primary-color: #2c3e50;         /* メインカラー（濃紺） */
    --secondary-color: #34495e;       /* サブカラー */
    --accent-color: #F2C30B;          /* アクセントカラー（黄色） */
    --text-color: #333;               /* テキストカラー */
    --text-light: #666;               /* 薄いテキストカラー */
    --bg-color: #f8f9fa;              /* 背景カラー */
    --white: #ffffff;                 /* 白色 */
    --border-color: #ddd;             /* ボーダーカラー */
    --nav-width: 50px;                /* ナビゲーションバーの幅（短縮） */
    --transition: all 0.3s ease;      /* トランジション設定 */
}

/* ========================================
   HTML要素の基本設定
   ======================================== */
html {
    scroll-behavior: smooth;  /* スムーズスクロールを有効化 */
}

body {
    font-family: 'Noto Sans JP', sans-serif;  /* フォント設定 */
    color: var(--text-color);
    line-height: 1.8;
    background-color: var(--white);
    overflow-x: hidden;  /* 横スクロールを無効化 */
}

/* コンテナの基本設定 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ========================================
   ファーストビュー（ローディング画面）
   ページ読み込み時に3
   秒間表示される
   ======================================== */
#loading {
    position: fixed;
    z-index: 9999;
    width: 100vw;
    height: 100vh;
    top: 0;
    left: 0;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 1s ease; /* フェードアウト用 */
}

#loading.hidden {
    opacity: 0;
}

#loading video {
    width: 200px;   /* 画面幅いっぱい */
    height: auto;  /* 画面高さいっぱい */
    object-fit: contain; /* 縦横比を維持して画面に収める */
}

/* 画像のフェードインアニメーション定義 */
@keyframes fadeInImage {
    0% {
        opacity: 0;
        transform: scale(0.95);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

/* ========================================
   縦帯ナビゲーション（常時表示）
   PC/SP両方で左側に固定表示
   縦書きで左から右に読む形式
   ======================================== */
.vertical-nav {
    position: fixed;          /* 画面に固定 */
    left: 0;
    top: 0;
    width: var(--nav-width);
    height: 100vh;
    background: var(--primary-color);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 1000;           /* メインコンテンツより前面 */
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
}

/* ナビゲーションメニューリスト */
.nav-menu {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 40px;               /* メニュー項目間の間隔 */
    width: 100%;
    padding: 20px 0;
}

/* ナビゲーションリンク - 縦書き（左から右） */
.nav-link {
    color: var(--white);
    text-decoration: none;
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0.05em;
    transition: var(--transition);
    opacity: 0.7;
    display: block;
    text-align: center;
    padding: 8px 5px;
    white-space: nowrap;
    /* 縦書きモード（左から右） */
    writing-mode: vertical-lr;
}

/* ナビゲーションリンクのホバー・アクティブ状態 */
.nav-link:hover,
.nav-link.active {
    opacity: 1;
    color: var(--accent-color);
}

/* ========================================
   メインコンテンツエリア
   ナビゲーションバーの右側に配置
   ======================================== */
.main-content {
    margin-left: var(--nav-width);  /* ナビゲーションバーの幅分だけマージン */
    min-height: 100vh;
}

/* ========================================
   PC/SP切り替え用クラス
   ======================================== */
.pc-only {
    display: block;
}

.sp-only {
    display: none;
}

/* ========================================
   KVセクション - PC版
   左右分割デザイン
   左：テキスト（固定）
   右：画像（スクロールで切り替わる）
   【修正版】2枚目の画像表示完了後、スクロールで画面全体が動く
   ======================================== */
.kv-section {
    position: relative;
    /* 修正: 300vh → 200vhに変更（2枚目表示完了後、次のセクションへスクロール可能にする） */
    height: 200vh;  /* 1枚目→2枚目への切り替えのみ（スクロール可能な高さ） */
    overflow: visible;
}

.kv-container-pc {
    display: flex;
    width: 100%;
    height: 100vh;
    /* sticky: KVセクション内でのみ固定、200vh分スクロールしたら解除される */
    position: sticky;
    top: 0;
    left: 0;
}

/* 左側：テキストエリア（50%、固定） */
.kv-left {
    width: 50%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 5;
}

/* PCのテキスト（1秒後にゆっくり表示） */
.kv-text-pc {
    text-align: center;
    opacity: 0;
    animation: fadeInText 1.5s ease forwards;
    animation-delay: 1s;  /* 1秒後に表示開始 */
}

@keyframes fadeInText {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.kv-title-pc {
    font-size: 72px;
    font-weight: 700;
    color: #2c3e50;
    letter-spacing: 0.1em;
    text-shadow: 6px 3px 5px rgba(0, 0, 0, 0.3);
}

.kv-name-pc {
    font-size: 20px;
    font-weight: 300;
    color: #2c3e50;
    letter-spacing: 0.2em;
}

/* 右側：画像エリア（50%） */
.kv-right {
    width: 50%;
    height: 100%;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;  /* 余白を作成 */
}

/* スクロールコンテナ - 画像のみがスクロールで動く */
.kv-scroll-container {
    width: 100%;
    height: calc(100vh - 80px);  /* パディング分を引いた高さ */
    position: relative;
}

.kv-image-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    /* transition削除 - JavaScriptで不透明度を制御 */
}

.kv-image-wrapper.active {
    opacity: 1;
    z-index: 2;
}

/* 2枚目の画像を重ねて表示 */
.kv-image-wrapper[data-index="1"] {
    z-index: 3;
}

.kv-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.3) 0%, rgba(0, 0, 0, 0.5) 100%);
    z-index: 1;
}

.kv-image {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
}

.kv-image-1 {
    background-image: url('../img/kv-01.png');
}

.kv-image-2 {
    background-image: url('../img/kv-02.png');
}

/* ========================================
   KVセクション - SP版
   【修正版】
   - 1枚目→2枚目の画像へ切り替わる
   - 2枚目の画像の上に「Portfolio NAHOKO K」のテキストが重なって表示される
   - 2枚目表示完了後、スクロールで画面全体が動く
   ======================================== */
.sp-only.kv-section {
    /* 修正: 300vh → 200vhに変更（2枚目表示完了後、次のセクションへスクロール可能にする） */
    height: 200vh;  /* 1枚目→2枚目への切り替えのみ（スクロール可能な高さ） */
    overflow: visible;
}

.kv-container-sp {
    width: 100%;
    height: 100vh;
    /* sticky: KVセクション内でのみ固定、200vh分スクロールしたら解除される */
    position: sticky;
    top: 0;
    left: 0;
    overflow: hidden;
    padding: 30px;  /* 余白を作成 */
    display: flex;
    align-items: center;
    justify-content: center;
}

.kv-sp-slide {
    position: absolute;
    top: 30px;
    left: 30px;
    right: 30px;
    bottom: 30px;
    opacity: 0;
    /* transition削除 - JavaScriptで不透明度を制御 */
    overflow: hidden;
}

.kv-sp-slide[data-slide="0"] {
    z-index: 2;
}

.kv-sp-slide[data-slide="1"] {
    z-index: 3;
}

/* 2枚目の画像のオーバーレイ（修正: fadeは不要） */
.kv-overlay-fade {
    /* 修正: 2枚目の画像は薄くならないため、transition不要 */
}

/* SPのテキスト（2枚目の画像の上に重ねて表示） */
.kv-text-sp {
    /* 修正: fixed → absolute に変更（2枚目の画像内に配置） */
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;  /* オーバーレイより前面に表示 */
    text-align: center;
    opacity: 0;  /* 初期状態は非表示 */
    /* JavaScriptで不透明度を制御 */
}

/* PC版だけオーバーレイ非表示にする */
.kv-container-pc .kv-overlay {
    display: none;
}

/* テキスト表示状態（JavaScriptで.showクラスを追加） */
.kv-text-sp.show {
    opacity: 1;
}

.kv-title-sp {
    font-size: 48px;
    font-weight: 700;
    color: var(--white);
    letter-spacing: 0.1em;
    margin-bottom: 10px;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.8);
}

.kv-name-sp {
    font-size: 20px;
    font-weight: 300;
    color: var(--white);
    letter-spacing: 0.2em;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8);
}

/* ========================================
   About Meセクション
   ======================================== */
.about-section {
    padding: 100px 0;
    background: var(--white);
}

/* セクションタイトル */
.section-title {
    font-size: 36px;
    font-weight: 500;
    color: var(--text-color);
}

/* セクションサブタイトル */
.section-subtitle {
    font-size: 14px;
    color: var(--text-light);
    margin-bottom: 20px;
}

/* 名前 */
.name {
    font-size: 18px;
    font-weight: 700;
    color: var(--primary-color);
}

/* About本文 */
.about-text {
    line-height: 2;
    color: var(--text-color);
    font-size: 15px;
}

/* ========================================
   Storyセクション（アコーディオン）
   jQueryで1つ開くと他は閉じるアコーディオンメニュー
   ======================================== */
.story-section {
    padding: 100px 0;
    background: var(--white);
}

/* アコーディオンコンテナ（dl要素） */
.accordion {
    margin-top: 30px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* アコーディオンタイトル（dt要素、クリック可能エリア） */
.accordion-title {
    position: relative;
    padding: 12px 60px 12px 30px;
    background: var(--accent-color);
    font-size: 18px;
    font-weight: 700;
    color: var(--text-color);
    cursor: pointer;
    transition: background 0.3s ease;
    margin-bottom: 2px;
    border-radius: 4px;
}

/* ホバー時の背景色変更 */
.accordion-title:hover {
    background: #e6b80a;
}

/* アコーディオンタイトルの右側にアイコン（+記号）を表示 */
.accordion-title::after {
    content: '+';
    position: absolute;
    right: 30px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 28px;
    font-weight: 300;
    color: var(--text-color);
    transition: transform 0.3s ease;
}

/* 開いている時はアイコンを-記号に変更（回転で表現） */
.accordion-title.active::after {
    content: '−';
}

/* アコーディオンコンテンツ（dd要素、展開される内容） */
.accordion-content {
    display: none;  /* jQueryのslideToggleで制御するため、初期状態はdisplay: none */
    padding: 30px;
    background: var(--white);
    border-radius: 4px;
    margin-bottom: 10px;
}

/* アコーディオン内のテキスト */
.accordion-content p {
    line-height: 2;
    color: var(--text-color);
    font-size: 14px;
    margin-bottom: 15px;
}

/* アコーディオン内のリスト */
.accordion-content ul {
    list-style: none;
    padding-left: 20px;
    margin-bottom: 15px;
}

.accordion-content li {
    line-height: 1.8;
    color: var(--text-color);
}

/* ========================================
   Likeセクション
   PC/SP両方でタッチスライド対応
   本のページをめくるようなアニメーションで切り替わる
   横長で小さい画像、画像内下部にインジケーター表示
   PCは画像外（下）にNEXT/PREVボタン付きインジケーター表示
   ======================================== */
.like-section {
    padding: 100px 0;
}

/* スライダーコンテナ */
.like-slider-container {
    max-width: 600px;  /* 横長のため幅を制限 */
    margin: 40px auto 0;
    position: relative;
    overflow: hidden;
    perspective: 1200px;  /* 3D効果のための視点距離 */
}

/* スライダー本体 */
.like-slider {
    position: relative;
    width: 100%;
    height: 300px;  /* 固定高さを設定 */
    touch-action: pan-y pinch-zoom;  /* タッチスライドを有効化 */
}

/* 各スライド - ページめくりアニメーション対応 */
.like-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;  /* 裏面を非表示 */
    transform-style: preserve-3d;  /* 3D変形を保持 */
    transform-origin: left center;  /* 左端を軸に回転 */
    transition: transform 0.8s cubic-bezier(0.645, 0.045, 0.355, 1);  /* ページめくりの滑らかさ */
}

/* アクティブなスライド */
.like-slide.active {
    z-index: 3;
    transform: rotateY(0deg);
}

/* 前のスライド（ページがめくられて裏側） */
.like-slide.prev {
    z-index: 1;
    transform: rotateY(-180deg);
}

/* 次のスライド（まだめくられていない） */
.like-slide.next {
    z-index: 2;
    transform: rotateY(0deg);
}

/* ページめくり中のアニメーション（右へめくる） */
.like-slide.flipping-next {
    z-index: 4;
    animation: pageFlipNext 0.8s cubic-bezier(0.645, 0.045, 0.355, 1) forwards;
}

/* ページめくり中のアニメーション（左へめくる） */
.like-slide.flipping-prev {
    z-index: 4;
    animation: pageFlipPrev 0.8s cubic-bezier(0.645, 0.045, 0.355, 1) forwards;
}

/* 次のページへめくるアニメーション（左から右へ） */
@keyframes pageFlipNext {
    0% {
        transform: rotateY(0deg);
    }
    100% {
        transform: rotateY(-180deg);
    }
}

/* 前のページへ戻すアニメーション（右から左へ） */
@keyframes pageFlipPrev {
    0% {
        transform: rotateY(-180deg);
    }
    100% {
        transform: rotateY(0deg);
    }
}

/* 画像ラッパー（インジケーターを内包） */
.like-image-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
    display: inline-block;
}

/* 画像 - 横長で小さく調整 */
.like-image {
    width: 100%;
    height: auto;
    max-height: 300px;  /* 高さを制限して横長に */
    object-fit: contain;  /* アスペクト比を維持しながらトリミング */
    border-radius: 8px;
    box-shadow: 0 4px 5px rgba(0, 0, 0, 0.15);  /* 影を追加してページ感を演出 */
}

/* インジケーターを画像の中央に揃える */
.like-indicator {
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    display: flex;
    justify-content: center;
    gap: 6px;
}

/* SPのみ表示（邪魔なinline-blockを消す） */
.like-indicator.sp-only {
    display: flex !important;
}


/* 丸 */
.like-indicator {
    width: 8px;
    height: 8px;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 50%;
    transition: all 0.3s ease;
    cursor: pointer;
}

/* アクティブ状態 */
.like-indicator.active {
    background: var(--accent-color);
    transform: scale(1.2);
}


.like-indicator-inner:hover {
    background: rgba(255, 255, 255, 0.9);
}

/* 画像外のコントロール（PCのみ表示） - PREV/インジケーター/NEXTを横並び */
.like-controls-outer {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 30px;
    margin-top: 30px;
    padding-bottom: 10px;
}

/* NEXT/PREVボタン */
.like-nav-button {
    padding: 12px 30px;
    background: var(--primary-color);
    color: var(--white);
    border: none;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.1em;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.like-nav-button:hover {
    background: var(--accent-color);
    color: var(--text-color);
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.15);
}

.like-nav-button:active {
    transform: translateY(0);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.like-nav-button:disabled {
    background: #ccc;
    cursor: not-allowed;
    opacity: 0.5;
}

.like-nav-button:disabled:hover {
    transform: none;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

/* 画像外のインジケーター（PCのみ表示） */
.like-indicators-outer {
    display: flex;
    justify-content: center;
    gap: 8px;
}

.like-indicator-outer {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #ccc;
    cursor: pointer;
    transition: all 0.3s ease;
}

.like-indicator-outer.active {
    background: var(--accent-color);
    transform: scale(1.3);
}

.like-indicator-outer:hover {
    background: #999;
}

/* ========================================
   Skillセクション
   スキルカードをセンター配置
   デザインカンプに従い、絵をセンターに寄せる
   ======================================== */
.skill-section {
    padding: 100px 0;
    background: var(--white);
}

/* スキルグリッド */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    margin-top: 40px;
    justify-items: center;     /* アイテムをセンター配置 */
}

/* スキルカード */
.skill-card {
    background: var(--white);
    padding: 40px 30px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    transition: var(--transition);
    text-align: center;        /* テキストをセンター配置 */
    max-width: 350px;
    width: 100%;
}

/* ホバー時のエフェクト */
.skill-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
}

/* スキルアイコン - センター配置 */
.skill-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 20px;       /* センター配置 */
    color: var(--primary-color);
}

.skill-icon svg {
    width: 100%;
    height: 100%;
}

/* スキル名 */
.skill-name {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 15px;
    color: var(--text-color);
}

/* スキルツールタグ */
.skill-tools {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
    justify-content: center;   /* タグをセンター配置 */
}

.skill-tools span {
    padding: 6px 14px;
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    font-size: 12px;
    color: var(--text-color);
}

/* スキル説明文 */
.skill-text {
    line-height: 1.9;
    color: var(--text-color);
    font-size: 14px;
    margin-bottom: 10px;
}

.skill-text:last-child {
    margin-bottom: 0;
}

/* ========================================
   Worksセクション
   ======================================== */
.works-section {
    padding: 100px 0;
    background: var(--bg-color);
}

/* Worksグリッド */
.works-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 40px;
    margin-top: 40px;
}

/* 作品アイテム */
.work-item {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    transition: var(--transition);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

/* ホバー時のエフェクト */
.work-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
}

/* 作品画像 基本形 */
/* 🎨 共通スタイル */
.work-image {
  width: 100%;
  background-size: cover;
  background-position: center;
  border-radius: 8px;
}

/* 🟣 通常（カード型） */
.work-image.card {
  height: 200px;
}

/* ⬜ 正方形 */
.work-image.square {
  aspect-ratio: 1/1;
}

/* ▭ 横長 */
.work-image.wide {
  aspect-ratio: 16/9;
}



/* 作品ラベル */
.work-label {
    display: inline-block;
    margin: 20px 0 0 20px;
    padding: 8px 20px;
    background: var(--accent-color);
    color: var(--text-color);
    font-size: 13px;
    font-weight: 600;
    border-radius: 20px;
}

/* 作品説明 */
.work-description {
    padding: 15px 25px 25px;
    font-size: 14px;
    line-height: 1.8;
    color: var(--text-color);
}

/* ========================================
   トップへ戻るボタン
   スクロール時に表示され、クリックでページトップへ
   ======================================== */
.back-to-top {
    position: fixed;
    bottom: 40px;
    right: 40px;
    width: 100px;
    height: 100px;
    background: transparent;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;                        /* 初期状態は非表示 */
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 999;
    animation: floatUpDown 2s ease-in-out infinite;  /* 浮遊アニメーション */
}

/* 表示状態 */
.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

/* ホバー時のエフェクト */
.back-to-top:hover {
    transform: translateY(-10px);
}

/* ボタン内の画像 */
.back-to-top img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* 浮遊アニメーション */
@keyframes floatUpDown {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

/* ========================================
   フッター
   ======================================== */
.footer {
    padding: 60px 0;
    background: var(--primary-color);
    color: var(--white);
    text-align: center;
}

.footer p {
    font-size: 14px;
    opacity: 0.8;
}

/* ========================================
   スクロールアニメーション用クラス
   要素がビューポートに入ったときに表示
   ======================================== */
.scroll-fade {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

/* 表示状態 */
.scroll-fade.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ========================================
   レスポンシブ対応 - タブレット
   ======================================== */
@media (max-width: 1024px) {
    .section-title {
        font-size: 32px;
    }

    .kv-title-pc {
        font-size: 56px;
    }

    .works-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .skills-grid {
        grid-template-columns: 1fr;
    }
}

/* ========================================
   レスポンシブ対応 - スマートフォン
   ======================================== */
@media (max-width: 768px) {
    /* ナビゲーションバーの幅を縮小 */
    :root {
        --nav-width: 50px;
    }

    .vertical-nav {
        width: var(--nav-width);
    }

    /* ナビゲーションのフォントサイズ調整 */
    .nav-link {
        font-size: 10px;
    }

    .nav-menu {
        gap: 30px;
    }

    /* メインコンテンツのマージン調整 */
    .main-content {
        margin-left: var(--nav-width);
    }

    /* PC版KVを非表示、SP版KVを表示 */
    .pc-only {
        display: none;
    }

    .sp-only {
        display: block;
    }

    /* SP版タイトルサイズ調整 */
    .kv-title-sp {
        font-size: 36px;
    }

    .kv-name-sp {
        font-size: 16px;
    }

    /* セクションタイトル調整 */
    .section-title {
        font-size: 28px;
    }

    /* パディング調整 */
    .about-section,
    .story-section,
    .like-section,
    .skill-section,
    .works-section {
        padding: 30px 0;
    }

    /* Worksグリッドを1カラムに */
    .works-grid {
        grid-template-columns: 1fr;
    }

    /* トップへ戻るボタンのサイズ調整 */
    .back-to-top {
        width: 70px;
        height: 70px;
        bottom: 30px;
        right: 30px;
    }

    /* アコーディオンのパディング調整 */
    .accordion-header {
        padding: 20px;
    }

    .accordion-item.active .accordion-content {
        padding: 20px;
    }

    /* Likeセクションの調整 */
    .like-slider-container {
        max-width: 100%;
    }

    /* SP版ではページめくりアニメーションを簡略化 */
    .like-slider {
        perspective: 800px;
    }
}

/* ========================================
   レスポンシブ対応 - 小型スマートフォン
   ======================================== */
@media (max-width: 480px) {
    .kv-title-sp {
        font-size: 28px;
    }

    .section-title {
        font-size: 24px;
    }

    .back-to-top {
        width: 60px;
        height: 60px;
    }

    .like-image {
        height: 280px;
    }
}


/* 初期状態（SP） */
.pc-img {
    display: none;
}
.sp-img {
    display: block;
}

/* PC（1024px〜） */
@media (min-width: 1024px) {
    .pc-img {
        display: block;
    }
    .sp-img {
        display: none;
    }
}

/* SP → 表示 */
.sp-only {
    display: inline-block;
}

/* PC → 非表示 */
@media (min-width:1024px) {
    .sp-only {
        display: none;
    }
}

/* インジケーターを画像の中央に揃える */
.like-indicator {
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    display: flex;
    justify-content: center;
    gap: 6px;
}

/* PCでは非表示 */
.like-indicator.sp-only {
    display: none;
}

/* SPのみ表示（768px以下） */
@media (max-width: 768px) {
    .like-indicator.sp-only {
        display: flex !important;
    }
}

/* PCでは非表示 */
@media (min-width:1024px) {
  .like-indicator.sp-only {
    display: none !important;
  }
}

/* SPでは中央寄せ＆表示 */
@media (max-width:1023px) {
  .like-indicator.sp-only {
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    display: flex !important;
    justify-content: center;
    gap: 6px;
    width: 100%;
  }
}

/* SP専用インジケーター設定 */
.like-indicator.sp-only {
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    display: flex !important;
    justify-content: center;
    align-items: center;
    gap: 6px;
    width: auto; /* ← width:100% いらない */
}

/* PCでは非表示 */
@media (min-width:1024px) {
    .like-indicator.sp-only {
        display: none !important;
    }
}

/* 〜768px以下はSP表示 */
@media screen and (max-width: 768px) {
    .pc-only {
        display: none;
    }
    .sp-only {
        display: block;
    }
}
