/* Cosplay ページ専用CSS */

/* ページヘッダー */
.page-header {
  height: 50vh;
  min-height: 400px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  margin-top: 0;
}

.page-header-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 120%;
  background: linear-gradient(135deg, #2c5f7d 0%, #4a7c9e 30%, #6b9ab8 60%, #5a8aa8 100%);
  z-index: 1;
}

.page-header-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at center, transparent 0%, rgba(0, 0, 0, 0.3) 100%);
  z-index: 2;
}

.page-header-content {
  position: relative;
  z-index: 3;
  text-align: center;
  animation: fadeInUp 1.2s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 30px;
}

.page-title {
  font-size: 4.5rem;
  font-weight: 200;
  letter-spacing: 0.4em;
  margin: 0;
  color: white;
  text-shadow: 0 4px 30px rgba(0, 0, 0, 0.4);
}

.title-line {
  width: 150px;
  height: 2px;
  background: linear-gradient(90deg, transparent, white, transparent);
  margin: 0 auto;
  animation: expandLine 1.5s ease;
}

@keyframes expandLine {
  from { width: 0; opacity: 0; }
  to { width: 150px; opacity: 1; }
}

.header-intro {
  font-size: 1.1rem;
  line-height: 1.8;
  color: rgba(255, 255, 255, 0.9);
  letter-spacing: 0.08em;
  animation: fadeInUp 1.4s ease;
}

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

/* メインコンテンツセクション */
.cosplay-content-section {
  padding: 80px 50px;
  position: relative;
  background: linear-gradient(180deg, #000 0%, #0a1929 50%, #000 100%);
  min-height: 50vh;
}

.cosplay-container {
  max-width: 1200px;
  margin: 0 auto;
}

/* タブコンテナ */
.cosplay-tabs {
  display: flex;
  gap: 20px;
  margin-bottom: 40px;
  border-bottom: 2px solid rgba(255, 255, 255, 0.1);
  padding-bottom: 0;
  justify-content: center;
  flex-wrap: wrap;
}

/* 個別タブボタン */
.cosplay-tab {
  background: none;
  border: none;
  padding: 16px 28px;
  color: rgba(255, 255, 255, 0.6);
  font-size: 1.1rem;
  font-weight: 400;
  letter-spacing: 0.1em;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  font-family: 'Hiragino Kaku Gothic ProN', 'Hiragino Sans', 'Yu Gothic', 'Meiryo', sans-serif;
}

.cosplay-tab:hover {
  color: rgba(255, 255, 255, 0.85);
}

/* アクティブタブ */
.cosplay-tab.active {
  color: white;
}

/* アクティブタブのインジケーター */
.cosplay-tab.active::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, #6b9ab8, #4a7c9e);
  animation: slideIn 0.3s ease;
}

@keyframes slideIn {
  from {
    width: 0;
    left: 50%;
  }
  to {
    width: 100%;
    left: 0;
  }
}

/* タブコンテンツコンテナ */
.cosplay-content {
  display: none;
}

/* アクティブなコンテンツを表示 */
.cosplay-content.active {
  display: block;
  animation: fadeIn 0.4s ease;
}

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

/* ギャラリーグリッド */
.cosplay-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 25px;
  margin-bottom: 50px;
}

/* 写真カード */
.cosplay-card {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  aspect-ratio: 1;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
  transition: all 0.4s ease;
  opacity: 0;
  transform: translateY(20px);
}

.cosplay-card.fade-in {
  opacity: 1;
  transform: translateY(0);
}

.cosplay-card:hover {
  transform: scale(1.03);
  box-shadow: 0 12px 40px rgba(74, 124, 158, 0.5);
}

/* 写真画像 */
.cosplay-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.cosplay-card:hover .cosplay-image {
  transform: scale(1.08);
}

/* 写真情報表示 */
.cosplay-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.8) 100%);
  padding: 20px;
  transform: translateY(100%);
  transition: transform 0.3s ease;
  z-index: 2;
}

.cosplay-card:hover .cosplay-overlay {
  transform: translateY(0);
}

.cosplay-title {
  font-size: 1.1rem;
  font-weight: 400;
  color: white;
  letter-spacing: 0.08em;
  margin-bottom: 4px;
}

.cosplay-character {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.8);
  letter-spacing: 0.06em;
}

/* ライトボックス */
.lightbox {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.95);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(10px);
  animation: fadeIn 0.3s ease;
}

.lightbox.active {
  display: flex;
}

.lightbox-content {
  position: relative;
  max-width: 90%;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  animation: scaleIn 0.4s ease;
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* ライトボックス画像 */
.lightbox-image {
  max-width: 100%;
  max-height: 70vh;
  object-fit: contain;
  border-radius: 8px;
  margin-bottom: 30px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

/* ライトボックス情報 */
.lightbox-info {
  text-align: center;
  color: white;
  max-width: 500px;
}

.lightbox-title {
  font-size: 1.4rem;
  font-weight: 400;
  color: white;
  margin-bottom: 16px;
  letter-spacing: 0.08em;
}

.lightbox-details {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.85);
  letter-spacing: 0.06em;
  line-height: 1.8;
}

.detail-line {
  display: flex;
  justify-content: center;
  gap: 8px;
}

.detail-label {
  color: #6b9ab8;
  font-weight: 500;
}

.detail-value {
  color: rgba(255, 255, 255, 0.85);
}

/* ライトボックスナビゲーション */
.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 100%;
  display: flex;
  justify-content: space-between;
  padding: 0 20px;
  pointer-events: none;
}

.lightbox-prev,
.lightbox-next {
  pointer-events: all;
  background: rgba(255, 255, 255, 0.1);
  border: none;
  color: white;
  font-size: 2rem;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 300;
}

.lightbox-prev:hover,
.lightbox-next:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: scale(1.1);
}

/* ライトボックス閉じるボタン */
.lightbox-close {
  position: absolute;
  top: 30px;
  right: 30px;
  background: rgba(255, 255, 255, 0.1);
  border: none;
  color: white;
  font-size: 1.8rem;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1001;
}

.lightbox-close:hover {
  background: rgba(255, 255, 255, 0.2);
}

/* ページネーション */
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  margin-top: 60px;
  padding-top: 40px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.pagination-btn,
.pagination-item {
  padding: 10px 14px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.05);
  color: rgba(255, 255, 255, 0.7);
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 0.9rem;
  font-weight: 300;
  letter-spacing: 0.08em;
}

.pagination-btn:hover,
.pagination-item.active {
  background: rgba(107, 154, 184, 0.3);
  border-color: rgba(107, 154, 184, 0.6);
  color: white;
}

.pagination-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.pagination-item.active {
  background: rgba(107, 154, 184, 0.5);
  border-color: rgba(107, 154, 184, 0.8);
}

.pagination-dots {
  color: rgba(255, 255, 255, 0.3);
}

/* HOMEリンク */
.back-link {
  text-align: center;
  margin-top: 70px;
  padding-top: 50px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.back-button {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  font-size: 1.05rem;
  letter-spacing: 0.15em;
  padding: 16px 40px;
  border: 2px solid rgba(255, 255, 255, 0.2);
  border-radius: 50px;
  transition: all 0.4s ease;
  font-weight: 300;
  background: rgba(255, 255, 255, 0.05);
}

.back-button:hover {
  background: rgba(107, 154, 184, 0.25);
  border-color: rgba(107, 154, 184, 0.6);
  color: white;
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(107, 154, 184, 0.35);
}

.back-arrow {
  font-size: 1.3rem;
  transition: transform 0.3s ease;
}

.back-button:hover .back-arrow {
  transform: translateX(-5px);
}

/* レスポンシブ */
@media (max-width: 1024px) {
  .cosplay-gallery {
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 20px;
  }
}

@media (max-width: 768px) {
  .page-title {
    font-size: 3rem;
    letter-spacing: 0.3em;
  }
  
  .header-intro {
    font-size: 1rem;
  }
  
  .cosplay-content-section {
    padding: 70px 20px;
  }
  
  .cosplay-tabs {
    gap: 0;
    padding: 0;
    border-bottom: none;
  }
  
  .cosplay-tab {
    flex: 1;
    text-align: center;
    padding: 14px 16px;
    font-size: 1rem;
    border-bottom: 2px solid rgba(255, 255, 255, 0.1);
  }
  
  .cosplay-tab.active {
    border-bottom: 2px solid #6b9ab8;
  }
  
  .cosplay-tab.active::after {
    display: none;
  }
  
  .cosplay-gallery {
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 15px;
  }
  
  .cosplay-title {
    font-size: 1rem;
  }
  
  .cosplay-character {
    font-size: 0.85rem;
  }
  
  .lightbox-image {
    max-height: 50vh;
  }
  
  .lightbox-title {
    font-size: 1.2rem;
  }
  
  .lightbox-details {
    font-size: 0.95rem;
  }
  
  .lightbox-close,
  .lightbox-prev,
  .lightbox-next {
    width: 40px;
    height: 40px;
    font-size: 1.4rem;
  }
  
  .lightbox-close {
    top: 20px;
    right: 20px;
  }
  
  .pagination-btn,
  .pagination-item {
    padding: 8px 12px;
    font-size: 0.85rem;
  }
}

@media (max-width: 480px) {
  .page-header {
    height: 40vh;
    min-height: 300px;
  }
  
  .page-title {
    font-size: 2.2rem;
    letter-spacing: 0.2em;
  }
  
  .cosplay-gallery {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }
  
  .cosplay-tab {
    padding: 12px 12px;
    font-size: 0.95rem;
  }
  
  .lightbox-content {
    max-width: 95%;
  }
  
  .lightbox-image {
    max-height: 40vh;
    margin-bottom: 20px;
  }
  
  .lightbox-nav {
    padding: 0 10px;
  }
  
  .lightbox-close,
  .lightbox-prev,
  .lightbox-next {
    width: 36px;
    height: 36px;
    font-size: 1.2rem;
  }
}