/* =================================
   Gallery Page Styles - 作品ページ専用スタイル
   ================================= */

/* --- 作品詳細ページ用スタイル --- */
.breadcrumb { padding: 20px 0; font-size: 0.9em; }
.breadcrumb a { color: var(--accent-color-blue); text-decoration: none; }
.breadcrumb a:hover { text-decoration: underline; }
.breadcrumb span { margin: 0 10px; color: #999; }
.work-detail-header { text-align: center; margin-bottom: 40px; }
.work-detail-header h1 { font-size: 2.8em; margin-bottom: 10px; }
.work-detail-header p { font-size: 1.2em; color: #555; }
.work-main-content { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; align-items: flex-start; }

/* 作品画像スライドショー */
.work-image-column { position: relative; }
.detail-slideshow-container { position: relative; overflow: hidden; border-radius: 12px; box-shadow: 0 10px 30px rgba(0,0,0,0.1); }
.detail-slides { display: flex; transition: transform 0.5s ease-in-out; }
.detail-slide { min-width: 100%; position: relative; }
.detail-slide img { width: 100%; display: block; }
.slideshow-nav { position: absolute; top: 50%; transform: translateY(-50%); width: 45px; height: 45px; background-color: rgba(0,0,0,0.4); color: white; border: none; border-radius: 50%; cursor: pointer; font-size: 20px; display: flex; justify-content: center; align-items: center; transition: background-color 0.3s ease; }
.slideshow-nav:hover { background-color: rgba(0,0,0,0.7); }
.slideshow-nav.prev { left: 15px; }
.slideshow-nav.next { right: 15px; }
.dots-container { position: absolute; bottom: 15px; left: 50%; transform: translateX(-50%); display: flex; gap: 10px; }
.dot { width: 10px; height: 10px; border-radius: 50%; background-color: rgba(255,255,255,0.5); cursor: pointer; transition: background-color 0.3s ease; }
.dot.active { background-color: white; }

.work-info-column h2 { font-size: 1.8em; margin-bottom: 20px; }
.work-info-column .description { margin-bottom: 30px; }
.spec-table { list-style: none; margin-bottom: 30px; }
.spec-table li { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid var(--border-color); }
.spec-table li strong { color: var(--main-color); }
.cta-button { display: inline-block; width: 100%; text-align: center; padding: 15px; background: linear-gradient(45deg, var(--accent-color-red), #FF6B6B); color: var(--background-color); border: none; border-radius: 8px; font-size: 1.1em; font-weight: 600; cursor: pointer; text-decoration: none; transition: transform 0.3s ease, box-shadow 0.3s ease; }
.cta-button:hover { transform: translateY(-3px); box-shadow: 0 7px 20px rgba(255, 59, 48, 0.3); }

/* 製作ギャラリー */
.gallery-section { background-color: var(--light-gray); }
.gallery-section h2 { text-align: center; font-size: 2em; margin-bottom: 50px; }
.gallery-step { max-width: 900px; margin: 0 auto 60px auto; }
.gallery-step:last-child { margin-bottom: 0; }
.gallery-step > .step-item + .step-item { margin-top: 60px; padding-top: 60px; border-top: 1px solid var(--border-color); }
.step-item > * + * { margin-top: 25px; }
.step-images { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.step-images img { width: 100%; border-radius: 8px; box-shadow: 0 4px 15px rgba(0,0,0,0.08); }
.step-caption h3 { font-size: 1.3em; margin-bottom: 10px; }
.step-caption p { line-height: 1.7; color: #555; }
.step-caption p + p { margin-top: 1em; }

/* YouTube動画 */
/* --- YouTube動画埋め込み用スタイル --- */
.video-section {
    padding: 60px 0;
    background-color: var(--light-gray);
    text-align: center;
}

.video-section h2 {
    font-size: 2em;
    margin-bottom: 40px;
}

/* 複数の動画をまとめるコンテナ */
.video-container {
    max-width: 800px; /* 動画全体の最大幅 */
    margin: 0 auto;
}

/* 各動画のラッパー（アスペクト比を固定） */
.video-wrapper {
    position: relative;
    width: 100%;
    padding-top: 56.25%; /* 16:9 のアスペクト比 */
    overflow: hidden;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

/* 2つ目以降の動画の上に余白を作る */
.video-wrapper + .video-wrapper {
    margin-top: 40px; /* 動画と動画の間のスペース */
}

.video-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* アフィリエイト */
.affiliate-section { max-width: 900px; margin: 0 auto 60px auto; padding: 30px; background-color: var(--background-color); border-radius: 12px; box-shadow: 0 4px 15px rgba(0,0,0,0.05); border: 1px solid var(--border-color); }
.affiliate-section h3 { text-align: center; font-size: 1.5em; margin-bottom: 25px; }
.affiliate-items { display: flex; justify-content: center; align-items: flex-start; flex-wrap: wrap; gap: 20px; }
.affiliate-items iframe { border: none !important; }

/* 関連作品 */
.related-works h2 { text-align: center; font-size: 2em; margin-bottom: 40px; }
.craft-gallery { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 30px; }
.craft-card { background: var(--background-color); border-radius: 12px; box-shadow: 0 5px 15px rgba(0,0,0,0.05); overflow: hidden; transition: transform 0.3s ease, box-shadow 0.3s ease; text-decoration: none; color: var(--text-color); }
.craft-card:hover { transform: translateY(-10px); box-shadow: 0 12px 25px rgba(0, 122, 255, 0.15); }
.craft-card-image-wrapper { width: 100%; height: 220px; overflow: hidden; }
.craft-card-image-wrapper img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }
.craft-card:hover .craft-card-image-wrapper img { transform: scale(1.05); }
.craft-card-content { padding: 20px; }
.craft-card-tag { color: var(--background-color); padding: 3px 8px; border-radius: 5px; font-size: 0.75em; font-weight: 600; display: inline-block; margin-bottom: 12px; }
/* トップページ(_Tstyle.css)と同じタグの色定義を追加 */
.craft-card .tag-mechanical {
    background-color: #007AFF; /* Blue */
}
.craft-card .tag-bosch {
    background-color: #FF3B30; /* Red */
}
.craft-card .tag-kirakira {
    background-color: #FFCC00; /* Yellow */
    color: #1d1d1f;
}
.craft-card .tag-other {
    background-color: #34C759; /* Green */
}
.craft-card h3 { margin-bottom: 10px; font-size: 1.3em; }
.craft-card p { font-size: 0.9em; line-height: 1.5; }

/* --- レスポンシブ (作品ページ専用) --- */
@media (max-width: 768px) {
    .work-main-content { grid-template-columns: 1fr; }
    .work-detail-header h1 { font-size: 2.2em; }
    .step-images { grid-template-columns: 1fr; }
}
