/* ==========================================================================
   ExplicationParoles.com — Style principal
   Mobile-first, responsive, typographie moderne
   ========================================================================== */

/* --- Reset & Base --- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 100%;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji";
  font-size: 1rem;
  line-height: 1.7;
  color: #1a1a2e;
  background-color: #fafafa;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: #4361ee;
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: #3a0ca3;
  text-decoration: underline;
}

/* --- Layout --- */
.container {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1rem;
}

/* --- Header --- */
.site-header {
  background: #1a1a2e;
  color: #fff;
  padding: 1rem 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.site-logo {
  font-size: 1.25rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.02em;
}

.site-logo:hover {
  color: #e2e2e2;
  text-decoration: none;
}

.site-logo span {
  color: #4cc9f0;
}

.site-nav a {
  color: #ccc;
  font-size: 0.875rem;
  margin-left: 1.5rem;
}

.site-nav a:hover {
  color: #fff;
}

/* --- Breadcrumb --- */
.breadcrumb {
  padding: 1rem 0;
  font-size: 0.85rem;
  color: #666;
}

.breadcrumb ol {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
}

.breadcrumb li::after {
  content: "›";
  margin-left: 0.4rem;
  color: #999;
}

.breadcrumb li:last-child::after {
  content: "";
}

.breadcrumb a {
  color: #4361ee;
}

.breadcrumb span {
  color: #555;
}

/* --- Page layout (article + sidebar) --- */
.page-content {
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
  padding: 1.5rem 0 3rem;
}

/* --- Article --- */
.article-header {
  margin-bottom: 2rem;
}

.article-title {
  font-size: 1.75rem;
  font-weight: 800;
  line-height: 1.25;
  color: #1a1a2e;
  letter-spacing: -0.02em;
  margin-bottom: 0.5rem;
}

.article-meta {
  font-size: 0.85rem;
  color: #777;
}

.article-meta a {
  color: #4361ee;
  font-weight: 600;
}

/* --- YouTube Embed (lazy) --- */
.video-container {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%; /* 16:9 */
  margin-bottom: 2rem;
  border-radius: 12px;
  overflow: hidden;
  background: #000;
  cursor: pointer;
}

.video-container img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity 0.3s ease;
}

.video-container:hover img {
  opacity: 0.85;
}

.video-play-btn {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 68px;
  height: 48px;
  pointer-events: none;
}

.video-play-btn svg {
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 2px 8px rgba(0,0,0,0.4));
}

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

/* --- Article body --- */
.article-body h2 {
  font-size: 1.35rem;
  font-weight: 700;
  color: #1a1a2e;
  margin: 2rem 0 0.75rem;
  padding-bottom: 0.4rem;
  border-bottom: 2px solid #4cc9f0;
}

.article-body p {
  margin-bottom: 1.25rem;
  color: #2d2d44;
}

.article-body p:last-child {
  margin-bottom: 0;
}

/* --- Sidebar --- */
.sidebar {
  border-top: 2px solid #eee;
  padding-top: 2rem;
}

.sidebar-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: #1a1a2e;
  margin-bottom: 1rem;
}

.sidebar-list {
  list-style: none;
}

.sidebar-list li {
  margin-bottom: 0.5rem;
}

.sidebar-list a {
  display: block;
  padding: 0.6rem 0.85rem;
  background: #fff;
  border: 1px solid #e8e8e8;
  border-radius: 8px;
  font-size: 0.9rem;
  color: #1a1a2e;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.sidebar-list a:hover {
  background: #f0f4ff;
  border-color: #4361ee;
  text-decoration: none;
}

.sidebar-list .current {
  background: #f0f4ff;
  border-color: #4361ee;
  font-weight: 600;
  pointer-events: none;
}

/* --- Footer --- */
.site-footer {
  background: #1a1a2e;
  color: #aaa;
  padding: 2rem 0;
  font-size: 0.85rem;
  margin-top: 2rem;
}

.site-footer .container {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  text-align: center;
}

.footer-links {
  list-style: none;
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.footer-links a {
  color: #ccc;
  font-size: 0.85rem;
}

.footer-links a:hover {
  color: #fff;
}

.footer-copy {
  color: #777;
}

/* ==========================================================================
   Responsive — Tablet (≥ 640px)
   ========================================================================== */
@media (min-width: 640px) {
  .article-title {
    font-size: 2rem;
  }

  .container {
    padding: 0 1.5rem;
  }
}

/* ==========================================================================
   Responsive — Desktop (≥ 900px)
   ========================================================================== */
@media (min-width: 900px) {
  .page-content {
    flex-direction: row;
  }

  .article-main {
    flex: 1;
    min-width: 0;
  }

  .sidebar {
    width: 280px;
    flex-shrink: 0;
    border-top: none;
    border-left: 2px solid #eee;
    padding-top: 0;
    padding-left: 2rem;
  }

  .article-title {
    font-size: 2.25rem;
  }

  .container {
    padding: 0 2rem;
  }
}


/* ==========================================================================
   Additional article body elements
   ========================================================================== */
.article-body h3 {
  font-size: 1.15rem;
  font-weight: 700;
  color: #1a1a2e;
  margin: 1.75rem 0 0.6rem;
}

.article-body h4 {
  font-size: 1.05rem;
  font-weight: 600;
  color: #2d2d44;
  margin: 1.5rem 0 0.5rem;
}

.article-body blockquote {
  border-left: 4px solid #4cc9f0;
  margin: 1.5rem 0;
  padding: 0.75rem 1.25rem;
  background: #f0f8ff;
  color: #2d2d44;
  font-style: italic;
  border-radius: 0 8px 8px 0;
}

.article-body ul,
.article-body ol {
  margin: 1rem 0 1.25rem 1.5rem;
  color: #2d2d44;
}

.article-body li {
  margin-bottom: 0.4rem;
}

.article-body hr {
  border: none;
  border-top: 1px solid #e0e0e0;
  margin: 2rem 0;
}

/* ==========================================================================
   Homepage
   ========================================================================== */
.hero {
  text-align: center;
  padding: 3rem 0 2rem;
}

.hero h1 {
  font-size: 2rem;
  font-weight: 800;
  color: #1a1a2e;
  letter-spacing: -0.02em;
  margin-bottom: 0.5rem;
}

.hero p {
  color: #555;
  font-size: 1.05rem;
  max-width: 600px;
  margin: 0 auto;
}

.search-box {
  max-width: 500px;
  margin: 2rem auto;
  position: relative;
}

.search-box input {
  width: 100%;
  padding: 0.85rem 1.2rem 0.85rem 3rem;
  border: 2px solid #e0e0e0;
  border-radius: 12px;
  font-size: 1rem;
  font-family: inherit;
  background: #fff;
  transition: border-color 0.2s ease;
}

.search-box input:focus {
  outline: none;
  border-color: #4361ee;
}

.search-box svg {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  color: #999;
}

.alpha-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.4rem;
  margin-bottom: 2.5rem;
  padding: 0 1rem;
}

.alpha-nav a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: #fff;
  border: 1px solid #e0e0e0;
  font-weight: 600;
  font-size: 0.9rem;
  color: #1a1a2e;
  transition: all 0.2s ease;
}

.alpha-nav a:hover {
  background: #4361ee;
  color: #fff;
  border-color: #4361ee;
  text-decoration: none;
}

.letter-group {
  margin-bottom: 2.5rem;
}

.letter-group h2 {
  font-size: 1.5rem;
  font-weight: 800;
  color: #1a1a2e;
  padding-bottom: 0.5rem;
  border-bottom: 3px solid #4cc9f0;
  margin-bottom: 1rem;
}

.artist-entry {
  margin-bottom: 1.5rem;
}

.artist-entry h3 {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
}

.artist-entry h3 a {
  color: #1a1a2e;
}

.artist-entry h3 a:hover {
  color: #4361ee;
}

.artist-entry .song-list {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.artist-entry .song-list a {
  display: inline-block;
  padding: 0.35rem 0.75rem;
  background: #fff;
  border: 1px solid #e8e8e8;
  border-radius: 6px;
  font-size: 0.85rem;
  color: #2d2d44;
  transition: all 0.2s ease;
}

.artist-entry .song-list a:hover {
  background: #f0f4ff;
  border-color: #4361ee;
  text-decoration: none;
}

.homepage-stats {
  text-align: center;
  padding: 1.5rem 0;
  color: #777;
  font-size: 0.9rem;
}

.homepage-stats strong {
  color: #1a1a2e;
}

/* ==========================================================================
   Artist pages
   ========================================================================== */
.artist-page {
  padding: 2rem 0 3rem;
}

.artist-page h1 {
  font-size: 2rem;
  font-weight: 800;
  color: #1a1a2e;
  margin-bottom: 0.5rem;
}

.artist-page .artist-subtitle {
  color: #777;
  font-size: 0.95rem;
  margin-bottom: 2rem;
}

.song-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

.song-card {
  display: flex;
  gap: 1rem;
  background: #fff;
  border: 1px solid #e8e8e8;
  border-radius: 12px;
  padding: 1rem;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  text-decoration: none;
  color: inherit;
}

.song-card:hover {
  border-color: #4361ee;
  box-shadow: 0 4px 12px rgba(67, 97, 238, 0.1);
  text-decoration: none;
}

.song-card .song-thumb {
  width: 120px;
  height: 68px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
  background: #eee;
}

.song-card .song-info h2 {
  font-size: 1rem;
  font-weight: 600;
  color: #1a1a2e;
  margin-bottom: 0.25rem;
  border: none;
  padding: 0;
}

.song-card .song-info p {
  font-size: 0.85rem;
  color: #777;
}

/* ==========================================================================
   404 page
   ========================================================================== */
.error-page {
  text-align: center;
  padding: 5rem 1rem;
}

.error-page h1 {
  font-size: 5rem;
  font-weight: 800;
  color: #e0e0e0;
  margin-bottom: 1rem;
}

.error-page h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: #1a1a2e;
  margin-bottom: 1rem;
}

.error-page p {
  color: #777;
  margin-bottom: 2rem;
}

.error-page a {
  display: inline-block;
  padding: 0.75rem 2rem;
  background: #4361ee;
  color: #fff;
  border-radius: 8px;
  font-weight: 600;
  transition: background 0.2s ease;
}

.error-page a:hover {
  background: #3a0ca3;
  text-decoration: none;
  color: #fff;
}

/* ==========================================================================
   Responsive additions
   ========================================================================== */
@media (min-width: 640px) {
  .hero h1 {
    font-size: 2.5rem;
  }

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

@media (min-width: 900px) {
  .hero h1 {
    font-size: 3rem;
  }

  .song-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .artist-page h1 {
    font-size: 2.5rem;
  }
}
