/* === DESIGN TOKENS === */
:root {
  --background: 220 10% 8%;
  --foreground: 30 100% 95%;
  --card: 220 10% 12%;
  --card-foreground: 30 100% 95%;
  --primary: 40 70% 60%;
  --primary-foreground: 220 10% 8%;
  --accent: 30 80% 65%;
  --muted: 220 5% 45%;
  --border: 220 10% 20%;
  --ring: 40 70% 60%;
  --radius: 8px;

  --font-display: 'Amiri', serif;
  --font-body: 'IBM Plex Sans Arabic', system-ui, sans-serif;
  --container: 1200px;
  --gutter: clamp(1rem, 4vw, 2rem);
  --section-y: clamp(5rem, 12vw, 9rem);
}

/* === RESET / BASE === */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  color: hsl(var(--foreground));
  background-color: hsl(var(--background));
  direction: rtl;
  min-height: 100vh;
  overflow-x: hidden;
}
img, picture, svg, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { background: none; border: 0; cursor: pointer; font: inherit; color: inherit; }

/* === TYPOGRAPHY === */
h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 700; line-height: 1.1; letter-spacing: -0.02em; color: hsl(var(--foreground)); }
h1 em, h2 em, h3 em { font-style: normal; color: hsl(var(--accent)); }
.display-xxl { font-size: clamp(4rem, 12vw, 10rem); line-height: 1; letter-spacing: -0.05em; }
.display-xl { font-size: clamp(2.5rem, 7vw, 5rem); line-height: 1.1; }
.title-section { font-size: clamp(2.25rem, 5.5vw, 4rem); }
.title-subsection { font-size: clamp(1.75rem, 4vw, 2.75rem); border-bottom: 2px solid hsl(var(--border)); padding-bottom: 1rem;}
.lead { font-size: clamp(1.1rem, 1.8vw, 1.5rem); line-height: 1.5; color: hsl(var(--foreground) / 0.85); max-width: 60ch; }
.lead-sm { font-size: clamp(1rem, 1.4vw, 1.25rem); line-height: 1.6; color: hsl(var(--foreground) / 0.75); max-width: 55ch; }
.bio-prose { font-size: clamp(1.05rem, 1.5vw, 1.2rem); line-height: 1.9; text-align: justify; max-width: 75ch; margin-inline: auto; }
.bio-prose p + p { margin-top: 2rem; }
.drop-cap { font-size: clamp(4rem, 8vw, 6rem); line-height: 0.8; font-family: var(--font-display); color: hsl(var(--accent)); float: right; margin-left: 1rem; margin-top: 0.5rem; margin-right: -0.5rem; }

/* === LAYOUT PRIMITIVES === */
.container { max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.container-narrow { max-width: 800px; margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: var(--section-y); position: relative; }
.page-header { padding-top: var(--section-y); }

/* === COMPONENTS === */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.75rem; padding: 0.875rem 1.75rem; border-radius: var(--radius); font-weight: 500; font-family: var(--font-body); transition: transform 250ms ease, background-color 250ms ease; }
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: hsl(var(--primary)); color: hsl(var(--primary-foreground)); }
.btn-ghost { color: hsl(var(--foreground)); border: 1px solid hsl(var(--border)); }
.btn-ghost:hover { background-color: hsl(var(--border)); }

.card { background: hsl(var(--card)); border: 1px solid hsl(var(--border) / 0.5); border-radius: var(--radius); padding: 1.5rem; transition: transform 280ms ease, border-color 280ms ease, box-shadow 280ms ease; }
.card:hover { transform: translateY(-4px); border-color: hsl(var(--border)); box-shadow: 0 10px 25px -5px hsl(var(--background) / 0.5); }

.img-cover { width: 100%; height: 100%; object-fit: cover; display: block; }
.img-frame { overflow: hidden; border-radius: var(--radius); background: hsl(var(--card)); }
.aspect-square { aspect-ratio: 1/1; }

/* === HEADER / FOOTER === */
.site-header { position: sticky; top: 0; z-index: 50; width: 100%; backdrop-filter: saturate(140%) blur(14px); background: hsl(var(--background) / 0.8); border-bottom: 1px solid hsl(var(--border) / 0.8); }
.nav-row { display: flex; align-items: center; justify-content: space-between; padding-block: 1.25rem; }
.wordmark { font-family: var(--font-display); font-size: 1.25rem; font-weight: 700; letter-spacing: -0.01em; }
.main-nav { display: flex; gap: 2rem; font-size: 1rem; }
.main-nav a { position: relative; padding-block: .25rem; color: hsl(var(--muted)); transition: color .2s; }
.main-nav a:hover, .main-nav a.active { color: hsl(var(--foreground)); }
.main-nav a.active::after { content: ''; position: absolute; bottom: -2px; right: 0; width: 100%; height: 2px; background-color: hsl(var(--accent)); }

.site-footer { padding-block: 4rem; text-align: center; border-top: 1px solid hsl(var(--border)); margin-top: var(--section-y); background-color: hsl(var(--card)); }
.footer-content { display: flex; flex-direction: column; align-items: center; gap: 1rem; }
.footer-meta { color: hsl(var(--muted)); font-size: 0.9rem; }

/* === HERO === */
.hero-fullbleed-image { min-height: 90vh; display: flex; align-items: center; justify-content: center; background-size: cover; background-position: center 30%; color: hsl(var(--foreground)); text-align: center; padding: 4rem var(--gutter); }
.hero-fullbleed-image::before { content: ''; position: absolute; inset: 0; background: linear-gradient(to top, hsl(var(--background)) 5%, transparent 50%), radial-gradient(circle at center, transparent 30%, hsl(var(--background) / 0.8) 100%); z-index: 1; }
.hero-content { position: relative; z-index: 2; display: flex; flex-direction: column; align-items: center; gap: 1.5rem; text-shadow: 0 4px 20px hsl(var(--background) / 0.7); }
.scroll-hint { opacity: 0.8; transition: opacity 0.3s ease; margin-top: 2rem; color: hsl(var(--muted)); font-size: 0.9rem; }

/* === BIO PAGE === */
.pull-quote { display: flex; align-items: center; justify-content: center; gap: clamp(2rem, 5vw, 4rem); max-width: 100ch; margin: 0 auto; flex-wrap: wrap; background-color: hsl(var(--card)); padding: var(--gutter); border-radius: var(--radius); margin-block: var(--section-y); }
.pull-quote-img { width: clamp(120px, 18vw, 200px); flex-shrink: 0; border-radius: 50%; overflow: hidden; border: 3px solid hsl(var(--accent)); }
.pull-quote blockquote { font-family: var(--font-display); font-size: clamp(1.5rem, 4vw, 2.5rem); line-height: 1.4; font-style: italic; color: hsl(var(--primary)); text-align: center; }
.pull-quote footer { font-size: clamp(1rem, 2vw, 1.25rem); color: hsl(var(--muted)); font-family: var(--font-body); margin-top: 1.5rem; }

/* === DISCOGRAPHY PAGE === */
.discography-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1.5rem; }
.album-card .card-title { margin-top: 1rem; font-size: 1.25rem; font-family: var(--font-body); font-weight: 500; color: hsl(var(--card-foreground)); }
.album-card .card-year { font-size: 0.9rem; color: hsl(var(--muted)); }

.songs-list { max-width: 90ch; margin: 0 auto; }
.song-item { display: flex; align-items: center; padding: 1.2rem 1rem; border-bottom: 1px solid hsl(var(--border) / 0.5); transition: background-color 0.3s ease; border-radius: var(--radius); }
.song-item:hover { background-color: hsl(var(--card-foreground) / 0.04); }
.song-index { font-weight: bold; color: hsl(var(--accent)); font-family: var(--font-body); width: 4ch; }
.song-title { flex-grow: 1; margin-inline: 1.5rem; font-size: 1.1rem; color: hsl(var(--primary-foreground)); font-weight: 500; }
.song-meta { color: hsl(var(--muted)); font-size: 0.9rem; }
.play-btn { margin-left: auto; margin-right: 0.5rem; color: hsl(var(--accent)); border: 1px solid hsl(var(--accent)); border-radius: 50%; width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; transition: background-color 0.3s ease, color 0.3s ease; }
.play-btn:hover { background-color: hsl(var(--accent)); color: hsl(var(--background)); }

/* === GALLERY PAGE === */
.gallery-mosaic { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); grid-auto-rows: 200px; gap: 1rem; grid-auto-flow: dense; }
.gallery-mosaic .img-frame { border: 1px solid hsl(var(--border) / 0.5); }
.gallery-mosaic .img-frame img { transition: transform 0.5s ease-in-out; }
.gallery-mosaic .img-frame:hover img { transform: scale(1.05); }

/* === ANIMATIONS === */
[data-animate] { opacity: 0; transform: translateY(24px); transition: opacity 700ms cubic-bezier(.2,.8,.2,1) 100ms, transform 700ms cubic-bezier(.2,.8,.2,1) 100ms; }
[data-animate][data-in="true"] { opacity: 1; transform: none; }

/* === ACCESSIBILITY & RESPONSIVE === */
:focus-visible { outline: 2px solid hsl(var(--ring)); outline-offset: 3px; border-radius: 4px; }
@media (max-width: 720px) {
  .main-nav { gap: 1rem; font-size: 0.9rem; }
  .display-xxl { font-size: clamp(3.5rem, 18vw, 10rem); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
