/* Discography Page Specific Styles */
body {
  background-color: #f5f5f0 !important;
  color: #333 !important;
}

.discography-container {
  max-width: 1000px;
  margin: 0 auto;
  background: white !important;
  border: 1px solid #e5e5e5;
  border-radius: 16px;
  padding: clamp(1rem, 4vw, 2rem);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  color: #333 !important;
}

.page-title {
  font-size: clamp(1.5rem, 4vw, 1.75rem);
  font-weight: 300;
  text-align: center;
  color: #000 !important;
  margin-bottom: 1.5rem;
  letter-spacing: 0.1em;
}

.discography-intro {
  margin-bottom: 3rem;
}

.intro-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  font-size: clamp(0.8rem, 2.5vw, 0.9rem);
  line-height: 1.6;
}

.intro-list li {
  color: #666 !important;
  font-weight: 300;
}

.intro-link {
  color: #0066cc !important;
  text-decoration: underline;
  font-weight: 400;
}

.intro-link:hover {
  color: #0052a3 !important;
}

.intro-note {
  font-size: clamp(0.75rem, 2vw, 0.85rem) !important;
  margin-top: 0.5rem !important;
  color: #666 !important;
}

.songs-container {
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
}

.song-item {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  padding: clamp(1rem, 3vw, 1.5rem);
  background: rgba(249, 249, 249, 0.3) !important;
  border-radius: 12px;
  border: 1px solid #f0f0f0;
  align-items: flex-start;
  color: #333 !important;
}

.song-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.song-title-section {
  text-align: center;
  width: 100%;
}

.song-title {
  font-size: clamp(1rem, 3vw, 1.1rem);
  font-weight: 400;
  color: #000 !important;
  margin-bottom: 0.5rem;
  line-height: 1.3;
}

.song-type {
  font-size: clamp(0.7rem, 2vw, 0.8rem);
  padding: 0.25rem 0.75rem;
  border-radius: 12px;
  font-weight: 400;
  display: inline-block;
}

.song-type.album {
  color: #c2410c !important;
  background: #fed7aa !important;
  box-shadow: 0 2px 8px rgba(254, 215, 170, 0.5);
}

.song-type.single {
  color: #1e40af !important;
  background: #dbeafe !important;
  box-shadow: 0 2px 8px rgba(219, 234, 254, 0.5);
}

.song-image-container {
  width: 100%;
  max-width: 200px;
  aspect-ratio: 1;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  border-radius: 8px;
  cursor: pointer;
  transition: transform 0.3s ease;
  display: block;
  text-decoration: none;
  position: relative;
  background-color: #f8f8f8;
}

.song-image-container:hover {
  transform: scale(1.05);
}

.song-image-container::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg, #f0f0f0 25%, transparent 25%),
    linear-gradient(-45deg, #f0f0f0 25%, transparent 25%), linear-gradient(45deg, transparent 75%, #f0f0f0 75%),
    linear-gradient(-45deg, transparent 75%, #f0f0f0 75%);
  background-size: 20px 20px;
  background-position: 0 0, 0 10px, 10px -10px, -10px 0px;
  opacity: 0.1;
  z-index: 1;
}

.song-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  background-color: #f8f8f8;
  transition: opacity 0.3s ease;
  position: relative;
  z-index: 2;
  opacity: 0.3;
}

.song-image[src*="nenone-main-logo.png"] {
  object-fit: contain;
  padding: 20%;
  background-color: #fff;
  opacity: 0.8 !important;
}

.song-details {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding-top: 0.5rem;
  width: 100%;
}

.song-release-date {
  margin-bottom: 1rem;
}

.song-release-date h3 {
  font-size: clamp(0.8rem, 2.5vw, 0.9rem);
  font-weight: 400;
  color: #333 !important;
  margin-bottom: 0.5rem;
}

.song-release-date p {
  font-size: clamp(0.75rem, 2vw, 0.85rem);
  color: #666 !important;
  font-weight: 300;
}

.song-tracks {
  margin-bottom: 1rem;
}

.song-tracks h3 {
  font-size: clamp(0.8rem, 2.5vw, 0.9rem);
  font-weight: 400;
  color: #333 !important;
  margin-bottom: 0.75rem;
}

.tracks-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.track-item {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.track-main {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
}

.track-number {
  font-size: clamp(0.7rem, 2vw, 0.8rem);
  color: #999 !important;
  font-weight: 300;
  min-width: 20px;
  flex-shrink: 0;
  margin-top: 0.1rem;
}

.track-name {
  font-size: clamp(0.8rem, 2.5vw, 0.9rem);
  color: #666 !important;
  font-weight: 300;
  line-height: 1.5;
  flex: 1;
}

.track-tieup {
  margin-left: 28px;
  padding: 0.5rem 0;
}

.track-tieup-text {
  font-size: clamp(0.65rem, 2vw, 0.75rem);
  color: #888 !important;
  font-weight: 300;
  line-height: 1.4;
  font-style: italic;
}

.song-youtube {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
}

.youtube-container {
  width: 100%;
  max-width: 320px;
  aspect-ratio: 16 / 9;
  position: relative;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  border-radius: 8px;
  background-color: #000;
}

.youtube-iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
  border-radius: 8px;
}

.youtube-title {
  font-size: clamp(0.65rem, 2vw, 0.75rem);
  color: #666 !important;
  font-weight: 300;
  text-align: center;
  line-height: 1.3;
  margin-top: 0.5rem;
}

.discography-footer {
  text-align: center;
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid #e5e5e5;
}

.footer-note {
  font-size: clamp(0.65rem, 2vw, 0.75rem);
  color: #666 !important;
  font-weight: 300;
}

/* Loading and Error States */
.loading-container {
  text-align: center;
  padding: 3rem 1rem;
}

.loading-spinner {
  width: 2.5rem;
  height: 2.5rem;
  border: 2px solid #e5e5e5;
  border-top: 2px solid #666;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 1rem auto;
}

.loading-text {
  color: #666 !important;
  font-weight: 300;
  font-size: clamp(0.85rem, 2.5vw, 0.95rem);
}

.error-container {
  text-align: center;
  padding: 3rem 1rem;
  color: #ef4444 !important;
}

.error-text {
  font-size: clamp(0.85rem, 2.5vw, 0.95rem);
  color: #ef4444 !important;
}

.no-results {
  text-align: center;
  padding: 3rem 1rem;
  color: #666 !important;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* Image Loading States */
.song-image-container.loading::after {
  content: "画像を読み込み中...";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 0.75rem;
  color: #999;
  z-index: 3;
}

.song-image-container.error::after {
  content: "画像を読み込めませんでした";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 0.75rem;
  color: #ef4444;
  z-index: 3;
  text-align: center;
}

/* Responsive Breakpoints */

/* Small Mobile (320px - 479px) */
@media (max-width: 479px) {
  .discography-container {
    padding: 1rem;
    margin: 0 0.5rem;
  }

  .song-item {
    padding: 1rem;
    gap: 1rem;
  }

  .song-image-container {
    max-width: 150px;
  }

  .youtube-container {
    max-width: 280px;
  }

  .track-tieup {
    margin-left: 20px;
  }
}

/* Mobile (480px - 767px) */
@media (min-width: 480px) {
  .discography-container {
    padding: 1.5rem;
  }

  .song-image-container {
    max-width: 180px;
  }

  .youtube-container {
    max-width: 300px;
  }
}

/* Tablet (768px - 1023px) */
@media (min-width: 768px) {
  .discography-container {
    padding: 2rem;
  }

  .song-item {
    grid-template-columns: 220px 1fr !important;
    gap: 2rem !important;
    padding: 1.5rem;
  }

  .song-header {
    align-items: flex-start;
  }

  .song-title-section {
    text-align: left;
  }

  .song-image-container {
    max-width: 200px;
    margin: 0;
  }

  .song-details {
    padding-top: 0;
  }

  .song-youtube {
    align-items: flex-start;
    margin-top: 1rem;
  }

  .youtube-container {
    max-width: 280px;
  }
}

/* Desktop (1024px - 1439px) */
@media (min-width: 1024px) {
  .discography-container {
    padding: 2rem 1.5rem;
  }

  .song-item {
    grid-template-columns: 220px 1fr 300px !important;
    gap: 2rem !important;
  }

  .song-youtube {
    align-self: flex-start;
    align-items: center;
    margin-top: 0;
  }

  .youtube-container {
    max-width: 300px;
  }
}

/* Large Desktop (1440px+) */
@media (min-width: 1440px) {
  .discography-container {
    max-width: 1200px;
    padding: 2.5rem 2rem;
  }

  .song-item {
    grid-template-columns: 250px 1fr 350px !important;
    gap: 2.5rem !important;
    padding: 2rem;
  }

  .song-image-container {
    max-width: 220px;
  }

  .youtube-container {
    max-width: 320px;
  }
}

/* High DPI Displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
  .song-image,
  .youtube-iframe {
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
  }
}

/* Landscape Mobile */
@media (max-height: 500px) and (orientation: landscape) {
  .discography-container {
    padding: 1rem;
  }

  .song-item {
    padding: 1rem;
    gap: 1rem;
  }
}

/* Print Styles */
@media print {
  .discography-container {
    box-shadow: none;
    border: 1px solid #000;
  }

  .song-youtube,
  .youtube-container {
    display: none;
  }

  .song-image-container:hover {
    transform: none;
  }
}

/* Accessibility - Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  .song-image-container,
  .youtube-container {
    transition: none;
  }

  .song-image-container:hover,
  .youtube-container:hover {
    transform: none;
  }

  .loading-spinner {
    animation: none;
  }
}

/* Accessibility - High Contrast */
@media (prefers-contrast: high) {
  .song-item {
    border: 2px solid #000;
  }

  .song-type.album {
    border: 1px solid #c2410c;
  }

  .song-type.single {
    border: 1px solid #1e40af;
  }
}

/* Force light mode - ダークモードを完全に無効化 */
* {
  color-scheme: light only !important;
}

html {
  color-scheme: light !important;
}

/* すべての要素に対してライトモードを強制 */
*,
*::before,
*::after {
  background-color: inherit !important;
  color: inherit !important;
}

/* 特定の要素の背景色を明示的に設定 */
body,
html {
  background-color: #f5f5f0 !important;
  color: #333 !important;
}

/* Responsive grid class for compatibility */
.responsive-grid {
  /* This class is used for responsive layout compatibility */
}

/* Touch states for mobile */
.touch-active {
  opacity: 0.7;
  transform: scale(0.98);
}
