/* ═══════════════════════════════════════════════
   CREATURES STUDIO — stylesheet
   ═══════════════════════════════════════════════ */

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

:root {
  /* Base palette */
  --bg:          #0c0c0f;
  --bg-1:        #111114;
  --bg-2:        #18181e;
  --bg-3:        #222228;
  --border:      rgba(255,255,255,0.06);
  --border-mid:  rgba(255,255,255,0.10);

  /* Text */
  --text:        #e0dbd2;
  --text-2:      #948f87;
  --text-3:      #524e4a;

  /* Brand */
  --gold:        #c8a96e;
  --gold-dim:    rgba(200,169,110,0.18);
  --gold-border: rgba(200,169,110,0.30);

  /* Mars palette */
  --mars-rust:   #c1603a;
  --mars-dust:   #9a7a58;
  --mars-slate:  #7a98a8;
  --mars-bg:     #0e0b09;

  /* Xime palette */
  --xime-teal:   #4a9b8e;
  --xime-orange: #e08040;
  --xime-cream:  #f0e8d8;
  --xime-brown:  #6a5040;
  --xime-bg:     #080d0f;

  /* DnD palette */
  --dnd-parch:   #c8b890;
  --dnd-bg:      #0c0a07;

  /* Layout */
  --max-w:    1180px;
  --nav-h:    60px;
  --radius:   3px;

  /* Motion */
  --ease:     cubic-bezier(0.16, 1, 0.3, 1);
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + 24px);
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  font-size: 1rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; height: auto; }
a  { color: inherit; }
ul { list-style: none; }

/* ── Typography helpers ─────────────────────────── */
h1, h2, h3, h4 {
  font-family: 'Cinzel', 'Georgia', serif;
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: 0.02em;
}

.tag {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 2px;
  border: 1px solid;
  margin-bottom: 1.25rem;
}
.tag--gold   { color: var(--gold);       border-color: var(--gold-border); }
.tag--mars   { color: var(--mars-rust);  border-color: rgba(193,96,58,0.35); }
.tag--xime   { color: var(--xime-teal);  border-color: rgba(74,155,142,0.35); }
.tag--dnd    { color: var(--dnd-parch);  border-color: rgba(200,184,144,0.35); }

.section__title {
  font-size: clamp(2rem, 5vw, 3.5rem);
  margin-bottom: 1rem;
}

.section__lead {
  font-size: 1.05rem;
  color: var(--text-2);
  max-width: 58ch;
  line-height: 1.78;
}

/* ── Layout ─────────────────────────────────────── */
.container {
  width: min(var(--max-w), 100% - 3rem);
  margin-inline: auto;
}
.container--narrow {
  width: min(680px, 100% - 3rem);
}

.section {
  padding: clamp(5rem, 10vw, 9rem) 0;
  position: relative;
  overflow: hidden;
}

.section__header {
  margin-bottom: clamp(2.5rem, 5vw, 4rem);
}
.section__header--center { text-align: center; }
.section__header--center .section__lead { margin-inline: auto; }

/* ── Reveal animations ──────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.75s var(--ease), transform 0.75s var(--ease);
}
.reveal--delay { transition-delay: 0.15s; }
.reveal.visible {
  opacity: 1;
  transform: none;
}

/* ══════════════════════════════════════════════════
   NAV
   ══════════════════════════════════════════════════ */
#nav {
  position: fixed;
  inset: 0 0 auto;
  z-index: 200;
  height: var(--nav-h);
  transition: background 0.4s, border-color 0.4s;
  border-bottom: 1px solid transparent;
}
#nav.scrolled {
  background: rgba(12,12,15,0.88);
  backdrop-filter: blur(14px) saturate(1.4);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  border-bottom-color: var(--border);
}

.nav-inner {
  display: flex;
  align-items: center;
  height: 100%;
  width: min(var(--max-w), 100% - 3rem);
  margin-inline: auto;
  gap: 1.5rem;
}

.nav-brand {
  text-decoration: none;
  flex-shrink: 0;
  display: flex;
  align-items: center;
}

.nav-logo {
  height: 42px;
  width: auto;
  display: block;
  /* Convert dark-green logo to warm cream/gold for dark background */
  filter: brightness(0) invert(1) sepia(0.25) saturate(1.2) brightness(0.92);
  opacity: 0.9;
  transition: opacity 0.2s, filter 0.2s;
}
.nav-brand:hover .nav-logo {
  opacity: 1;
  filter: brightness(0) invert(1) sepia(0.5) saturate(1.8) brightness(0.88);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  margin-left: auto;
}
.nav-links a {
  font-size: 0.75rem;
  font-weight: 400;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--text-2);
  white-space: nowrap;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--text); }

.lang-toggle {
  flex-shrink: 0;
  background: none;
  border: 1px solid var(--border-mid);
  border-radius: 2px;
  color: var(--text-2);
  font-family: 'Space Mono', monospace;
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  padding: 5px 10px;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
}
.lang-toggle:hover { color: var(--gold); border-color: var(--gold-border); }

.nav-burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  flex-shrink: 0;
}
.nav-burger span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: var(--text-2);
  transition: all 0.3s var(--ease);
  transform-origin: center;
}
.nav-burger.open span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav-burger.open span:nth-child(2) { opacity: 0; }
.nav-burger.open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* ══════════════════════════════════════════════════
   HERO
   ══════════════════════════════════════════════════ */
.hero {
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}
#starfield { width: 100%; height: 100%; }

.hero-gradient {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 50% at 50% 110%, rgba(200,169,110,0.06) 0%, transparent 70%),
    radial-gradient(ellipse 80% 40% at 50% 0%,   rgba(12,12,15,0.6) 0%, transparent 60%);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
  padding: 0 1.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
}

.hero-logo-img {
  width: clamp(96px, 18vw, 140px);
  height: auto;
  display: block;
  margin: 0 auto 1.5rem;
  /* green logo → warm cream/gold on dark background */
  filter: brightness(0) invert(1) sepia(0.25) saturate(1.3) brightness(0.9);
}

.hero-eyebrow {
  font-size: 0.68rem;
  font-weight: 400;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-3);
  margin-bottom: 2rem;
}

.hero-title {
  display: flex;
  flex-direction: column;
  font-size: clamp(3.5rem, 12vw, 8rem);
  font-weight: 700;
  letter-spacing: 0.06em;
  line-height: 0.92;
  margin-bottom: 1.5rem;
}
.hero-title__creatures {
  color: var(--text);
}
.hero-title__studio {
  color: var(--gold);
  position: relative;
}
.hero-title__studio::after {
  content: '';
  position: absolute;
  bottom: -0.1em;
  left: 50%;
  transform: translateX(-50%);
  width: 40%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
  opacity: 0.5;
}

.hero-subtitle {
  font-size: clamp(0.75rem, 1.8vw, 0.9rem);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-2);
  margin-bottom: 2.5rem;
}

.hero-domains {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 4rem;
}
.hero-domain {
  font-family: 'Cinzel', serif;
  font-size: 0.75rem;
  color: var(--c, var(--gold));
  opacity: 0.7;
  letter-spacing: 0.05em;
  transition: opacity 0.2s;
}
.hero-domain:hover { opacity: 1; }
.hero-domain__sep { color: var(--text-3); font-size: 0.75rem; }

.hero-cta {
  color: var(--text-3);
  display: inline-flex;
  text-decoration: none;
  animation: float 2.2s ease-in-out infinite;
  transition: color 0.2s;
}
.hero-cta:hover { color: var(--gold); }
.hero-cta svg { width: 36px; height: 36px; }

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(10px); }
}

/* ══════════════════════════════════════════════════
   SECTION: HARMONIES
   ══════════════════════════════════════════════════ */
.section--harmonies {
  background: var(--mars-bg);
}

.deco--mars {
  position: absolute;
  top: -20%;
  right: -15%;
  width: 55vw;
  height: 55vw;
  border-radius: 50%;
  background: radial-gradient(circle at center,
    rgba(193,96,58,0.05) 0%,
    rgba(193,96,58,0.02) 40%,
    transparent 70%);
  pointer-events: none;
}

.harm-layout {
  display: grid;
  grid-template-columns: 1fr 260px;
  gap: 2rem;
  align-items: start;
}

/* Title lockup (logo + h2) */
.harm-title-lockup {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}
.harm-title-lockup .section__title { margin-bottom: 0; }
.harm-logo {
  width: 60px;
  height: 60px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
  border: 1px solid rgba(193,96,58,0.2);
}

/* Xime header illustration */
.xime-illu-header {
  margin-bottom: 3rem;
  border-radius: 2px;
  overflow: hidden;
  height: clamp(300px, 55vw, 500px);
  position: relative;
  z-index: 1;
}
.xime-illu-header img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
  filter: saturate(0.88) brightness(0.88);
  transition: filter 0.6s, transform 0.6s var(--ease);
}
.xime-illu-header:hover img {
  filter: saturate(1.05) brightness(1);
  transform: scale(1.02);
}

/* Visual card */
.harm-visual {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  margin: 0;
}
.harm-visual__inner {
  height: clamp(240px, 35vw, 400px);
  overflow: hidden;
  position: relative;
}
.harm-visual__inner img {
  width: 100%; height: 100%;
  object-fit: cover;
}

/* Mars gradient placeholder */
.harm-placeholder {
  width: 100%; height: 100%;
  position: relative;
  background: linear-gradient(
    180deg,
    #0a1220 0%,
    #1a1810 35%,
    #2a1a0e 55%,
    #1a1008 70%,
    #100808 100%
  );
  overflow: hidden;
}
.harm-placeholder__horizon {
  position: absolute;
  bottom: 35%;
  left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg,
    transparent 0%,
    rgba(154,122,88,0.4) 20%,
    rgba(193,96,58,0.6) 50%,
    rgba(154,122,88,0.4) 80%,
    transparent 100%);
  box-shadow: 0 0 20px 2px rgba(193,96,58,0.15);
}
.harm-placeholder__dust {
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(
      0deg,
      transparent,
      transparent 3px,
      rgba(193,96,58,0.018) 3px,
      rgba(193,96,58,0.018) 4px
    );
}
.harm-placeholder__label {
  position: absolute;
  bottom: 1rem; left: 1rem;
  font-family: 'Space Mono', monospace;
  font-size: 0.6rem;
  color: rgba(193,96,58,0.4);
  letter-spacing: 0.1em;
}

.harm-desc {
  padding: 1.5rem;
  border-top: 1px solid var(--border);
}
.harm-desc h3 {
  font-size: 1rem;
  margin-bottom: 0.6rem;
  color: var(--text);
}
.harm-desc p {
  font-size: 0.88rem;
  color: var(--text-2);
  line-height: 1.75;
}

/* Stats panel */
.harm-stats {
  display: flex;
  flex-direction: column;
}

.stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 1rem;
  border: 1px solid var(--border);
  border-bottom: none;
  background: var(--bg-2);
  position: relative;
}
.stat::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 2px;
  background: var(--mars-rust);
  opacity: 0;
  transition: opacity 0.2s;
}
.stat:hover::before { opacity: 0.6; }
.stat:last-child { border-bottom: 1px solid var(--border); }

.stat__key {
  font-family: 'Space Mono', monospace;
  font-size: 0.6rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--mars-rust);
}
.stat__val {
  font-size: 0.82rem;
  color: var(--text-2);
  line-height: 1.5;
}
.stat__val--status {
  display: flex;
  align-items: center;
  gap: 6px;
}

.status-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--mars-rust);
  box-shadow: 0 0 6px var(--mars-rust);
  animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.4; }
}

/* ══════════════════════════════════════════════════
   SECTION: XIME CREATURE
   ══════════════════════════════════════════════════ */
.section--xime {
  background: var(--xime-bg);
  position: relative;
}
/* Paper noise overlay */
.section--xime::before {
  content: '';
  position: absolute;
  inset: 0;
  opacity: 0.35;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)' opacity='0.08'/%3E%3C/svg%3E");
}

.deco--cosmic {
  position: absolute;
  top: -10%;
  left: -20%;
  width: 60vw; height: 60vw;
  border-radius: 50%;
  background: radial-gradient(circle,
    rgba(74,155,142,0.06) 0%,
    rgba(224,128,64,0.03) 40%,
    transparent 70%);
  pointer-events: none;
}

.xime-layout {
  position: relative;
  z-index: 1;
}

.xime-style {
  font-family: 'Cinzel', serif;
  font-size: 0.9rem;
  letter-spacing: 0.12em;
  color: var(--xime-teal);
  margin-bottom: 0.75rem;
}

.xime-style__desc {
  font-size: 1.05rem;
  font-weight: 300;
  font-style: italic;
  color: var(--text-2);
  line-height: 1.8;
  max-width: 65ch;
  margin-bottom: 2rem;
}

/* Portrait */
.xime-portrait {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
}

.xime-portrait__frame {
  width: 240px;
  aspect-ratio: 3/4;
  border: 1px solid rgba(74,155,142,0.2);
  border-radius: var(--radius);
  overflow: hidden;
  position: relative;
}
.xime-portrait__frame img {
  width: 100%; height: 100%;
  object-fit: cover;
}
/* Cosmic gradient placeholder */
.xime-portrait__placeholder {
  width: 100%; height: 100%;
  position: relative;
  overflow: hidden;
}
.xime-portrait__sky {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    #050e12 0%,
    #0a1a20 30%,
    #0f1e18 60%,
    #181008 100%
  );
}
.xime-portrait__sky::before {
  content: '';
  position: absolute;
  top: 10%; left: 50%;
  transform: translateX(-50%);
  width: 120px; height: 120px;
  border-radius: 50%;
  background: radial-gradient(circle,
    rgba(74,155,142,0.15) 0%,
    rgba(224,128,64,0.08) 50%,
    transparent 70%);
}
.xime-portrait__figure {
  position: absolute;
  bottom: 0; left: 50%;
  transform: translateX(-50%);
  width: 80px; height: 130px;
  background: rgba(10,20,18,0.9);
  clip-path: polygon(30% 0%, 70% 0%, 85% 30%, 100% 100%, 0% 100%, 15% 30%);
  opacity: 0.7;
}

/* Palette swatches */
.xime-palette {
  display: flex;
  gap: 8px;
}
.swatch {
  width: 20px; height: 20px;
  border-radius: 50%;
  background: var(--swatch);
  border: 1px solid rgba(255,255,255,0.1);
  display: block;
  transition: transform 0.2s;
  cursor: default;
}
.swatch:hover { transform: scale(1.25); }

/* Content */
.xime-content {
  position: relative;
  z-index: 1;
}

.xime-quote {
  font-style: italic;
  font-size: 1.05rem;
  font-weight: 300;
  color: var(--xime-cream);
  line-height: 1.8;
  border-left: 2px solid var(--xime-teal);
  padding-left: 1.25rem;
  margin-bottom: 1.75rem;
  opacity: 0.85;
}

.xime-traits {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-bottom: 2rem;
}
.xime-traits li {
  font-size: 0.82rem;
  color: var(--text-2);
  letter-spacing: 0.05em;
  padding-left: 1rem;
  position: relative;
}
.xime-traits li::before {
  content: '·';
  position: absolute;
  left: 0;
  color: var(--xime-orange);
}

.xime-releases { margin-bottom: 2rem; }
.xime-releases h3 {
  font-size: 0.85rem;
  font-family: 'Cinzel', serif;
  letter-spacing: 0.1em;
  color: var(--text-2);
  margin-bottom: 1rem;
  text-transform: uppercase;
}

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

.release-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem;
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: border-color 0.2s;
}
.release-item:hover { border-color: rgba(74,155,142,0.25); }
.release-item__cover { width: 48px; height: 48px; flex-shrink: 0; overflow: hidden; border-radius: 2px; }
.release-item__cover img { width: 100%; height: 100%; object-fit: cover; }
.release-item__body { display: flex; flex-direction: column; gap: 2px; }
.release-item__body strong { font-size: 0.88rem; font-weight: 500; }
.release-item__body span  { font-size: 0.75rem; color: var(--text-2); }

.releases-placeholder {
  font-style: italic;
  color: var(--text-3);
  font-size: 0.85rem;
}

/* Release grid */
.release-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
}

.release-card {
  display: block;
  aspect-ratio: 1;
  border-radius: 2px;
  overflow: hidden;
  border: 1px solid var(--border);
  position: relative;
  text-decoration: none;
  transition: border-color 0.3s, transform 0.3s var(--ease);
}
.release-card:hover {
  border-color: rgba(74,155,142,0.4);
  transform: translateY(-3px);
}
.release-card img { width: 100%; height: 100%; object-fit: cover; display: block; }

.release-card__overlay {
  position: absolute;
  inset: 0;
  background: rgba(8,13,15,0.7);
  display: flex;
  align-items: flex-end;
  padding: 8px;
  opacity: 0;
  transition: opacity 0.25s;
}
.release-card:hover .release-card__overlay { opacity: 1; }
.release-card__overlay span {
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  color: var(--xime-cream);
  line-height: 1.3;
}

/* Platform buttons */
.xime-platforms {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.5rem;
  align-items: center;
}

.platform-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0.45rem 0.9rem;
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-decoration: none;
  border-radius: 2px;
  border: 1px solid var(--border-mid);
  color: var(--text-2);
  transition: all 0.2s;
}
.platform-btn svg { width: 13px; height: 13px; flex-shrink: 0; fill: currentColor; }
.platform-btn:hover { color: var(--text); border-color: rgba(255,255,255,0.2); }

.platform-btn--spotify:hover  { color: #1db954; border-color: rgba(29,185,84,0.4); }
.platform-btn--youtube:hover  { color: #ff0000; border-color: rgba(255,0,0,0.35); }
.platform-btn--instagram:hover{ color: #e1306c; border-color: rgba(225,48,108,0.35); }
.platform-btn--facebook:hover { color: #1877f2; border-color: rgba(24,119,242,0.35); }

.platform-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0.45rem 0.9rem;
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  color: var(--text-3);
  border: 1px dashed rgba(255,255,255,0.1);
  border-radius: 2px;
}
.platform-badge svg { width: 13px; height: 13px; flex-shrink: 0; fill: currentColor; }

/* Portrait real image */
.xime-portrait__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Single illustration */
.xime-illu-single {
  margin-top: 3rem;
  border-radius: 2px;
  overflow: hidden;
  height: clamp(200px, 30vw, 340px);
}
.xime-illu-single img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: saturate(0.9) brightness(0.92);
  transition: filter 0.6s, transform 0.6s var(--ease);
}
.xime-illu-single:hover img {
  filter: saturate(1.05) brightness(1);
  transform: scale(1.02);
}

.platform-btn--apple:hover { color: #fc3c44; border-color: rgba(252,60,68,0.4); }

@media (max-width: 700px) {
  .release-grid { grid-template-columns: repeat(3, 1fr); }
}

/* Xime buttons */
.xime-links {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.btn {
  display: inline-block;
  padding: 0.55rem 1.4rem;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 2px;
  transition: all 0.2s;
  cursor: pointer;
  font-family: inherit;
}
.btn--xime {
  background: var(--xime-teal);
  color: #000;
  border: 1px solid var(--xime-teal);
}
.btn--xime:hover { background: #5ab8a9; border-color: #5ab8a9; }
.btn--ghost-xime {
  background: transparent;
  color: var(--xime-teal);
  border: 1px solid rgba(74,155,142,0.35);
}
.btn--ghost-xime:hover {
  background: rgba(74,155,142,0.1);
  border-color: var(--xime-teal);
}

/* ══════════════════════════════════════════════════
   SECTION: ÉCRITURE
   ══════════════════════════════════════════════════ */
.section--writing {
  background: var(--bg-1);
}

.writing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 280px));
  gap: 2rem;
}

.book-card {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.35s var(--ease), border-color 0.3s;
}
.book-card:hover {
  transform: translateY(-6px);
  border-color: var(--gold-border);
}
.book-card--upcoming { opacity: 0.5; }
.book-card--upcoming:hover { opacity: 0.75; transform: translateY(-3px); }

.book-card__cover {
  overflow: hidden;
  position: relative;
}
.book-card__cover img { width: 100%; height: auto; display: block; object-fit: contain; }

.book-card__placeholder {
  width: 100%; height: 100%;
  background: linear-gradient(160deg,
    #120e0a 0%,
    #1e1a12 40%,
    #1a1e22 70%,
    #100e10 100%);
}
.book-card__cover--empty {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-3);
}
.book-card__coming {
  font-family: 'Cinzel', serif;
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-3);
}

.book-card__body { padding: 1.25rem; }
.book-card__genre {
  display: block;
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.4rem;
}
.book-card__body h3 { font-size: 0.95rem; margin-bottom: 0.5rem; }
.book-card__body p  { font-size: 0.82rem; color: var(--text-2); line-height: 1.7; }

/* ══════════════════════════════════════════════════
   SECTION: DnD
   ══════════════════════════════════════════════════ */
.section--dnd {
  background: var(--dnd-bg);
  position: relative;
}

.deco--dnd {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 40% at 50% 100%,
      rgba(200,184,144,0.04) 0%, transparent 70%);
  pointer-events: none;
}

.dnd-layout {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.dnd-tokens {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem 2rem;
}

.dnd-token {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  cursor: default;
}
.dnd-token__ring {
  width: 88px; height: 88px;
  border-radius: 50%;
  border: 2px solid rgba(200,184,144,0.15);
  overflow: hidden;
  transition: border-color 0.3s, box-shadow 0.3s;
  background: var(--bg-2);
}
.dnd-token:hover .dnd-token__ring {
  border-color: rgba(200,184,144,0.45);
  box-shadow: 0 0 16px rgba(200,184,144,0.08);
}
.dnd-token__img { width: 100%; height: 100%; object-fit: cover; }
.dnd-token__face {
  width: 100%; height: 100%;
  background: radial-gradient(circle at 50% 35%,
    rgba(200,184,144,0.06) 0%,
    transparent 70%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  color: rgba(200,184,144,0.15);
}
.dnd-token__face--more {
  font-family: 'Cinzel', serif;
  font-size: 1rem;
  color: rgba(200,184,144,0.3);
}
.dnd-token__name {
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-3);
}

.dnd-group {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 2.5rem;
}
.dnd-group:last-of-type { margin-bottom: 0; }

.dnd-group__label {
  font-family: 'Space Mono', monospace;
  font-size: 0.62rem;
  font-weight: 400;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--dnd-parch);
  opacity: 0.55;
}

.dnd-note {
  font-style: italic;
  font-size: 0.85rem;
  color: var(--text-3);
  padding-left: 1rem;
  border-left: 1px solid rgba(200,184,144,0.12);
  max-width: 50ch;
}

.book-card__wip {
  display: block;
  font-style: italic;
  font-size: 0.72rem;
  color: var(--text-3);
  margin-top: 0.75rem;
  letter-spacing: 0.03em;
}

/* ══════════════════════════════════════════════════
   SECTION: CONTACT
   ══════════════════════════════════════════════════ */
.section--contact {
  background: var(--bg);
}

.contact-list {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  margin-top: 2.5rem;
}

.contact-item {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: var(--text-2);
  font-size: 0.95rem;
  padding: 0.75rem 1.5rem;
  border: 1px solid var(--border);
  border-radius: 2px;
  transition: color 0.2s, border-color 0.2s, background 0.2s;
}
.contact-item:hover {
  color: var(--gold);
  border-color: var(--gold-border);
  background: var(--gold-dim);
}
.contact-item--discord:hover {
  color: #7b88f5;
  border-color: rgba(88,101,242,0.4);
  background: rgba(88,101,242,0.08);
}
.contact-item__icon svg { width: 18px; height: 18px; flex-shrink: 0; }

/* ══════════════════════════════════════════════════
   FOOTER
   ══════════════════════════════════════════════════ */
.footer {
  padding: 1.5rem 0;
  border-top: 1px solid var(--border);
}
.footer__inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.footer__brand {
  font-family: 'Cinzel', serif;
  font-size: 0.82rem;
  letter-spacing: 0.12em;
  color: var(--gold);
}
.footer__copy {
  font-size: 0.72rem;
  color: var(--text-3);
}

/* ══════════════════════════════════════════════════
   SECTION DIVIDERS
   ══════════════════════════════════════════════════ */
.section--harmonies + .section--xime,
.section--xime + .section--writing,
.section--writing + .section--dnd,
.section--dnd + .section--contact {
  position: relative;
}
.section--harmonies + .section--xime::before,
.section--xime + .section--writing::before,
.section--writing + .section--dnd::before,
.section--dnd + .section--contact::before {
  content: none;
}

/* ══════════════════════════════════════════════════
   RESPONSIVE — 900px breakpoint
   ══════════════════════════════════════════════════ */
@media (max-width: 900px) {
  .harm-layout {
    grid-template-columns: 1fr;
  }
  .harm-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }
  .harm-stats .stat:nth-child(odd)  { border-right: none; }
  .harm-stats .stat:nth-child(-n+4) { border-bottom: none; }
  .harm-stats .stat--wide { grid-column: span 2; }
  .harm-stats .stat:last-child { border-bottom: 1px solid var(--border); }

  .xime-layout {
    grid-template-columns: 1fr;
  }
  .xime-portrait {
    flex-direction: row;
    align-items: flex-start;
  }
  .xime-portrait__frame { width: 160px; }
}

/* ══════════════════════════════════════════════════
   RESPONSIVE — 700px breakpoint (mobile)
   ══════════════════════════════════════════════════ */
@media (max-width: 700px) {
  .nav-links {
    display: none;
    position: fixed;
    top: var(--nav-h);
    left: 0; right: 0;
    background: rgba(12,12,15,0.96);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    padding: 1.5rem 2rem 2.5rem;
    gap: 1.5rem;
    z-index: 190;
  }
  .nav-links.open { display: flex; }
  .nav-links a { font-size: 0.9rem; letter-spacing: 0.08em; }
  .nav-burger { display: flex; }

  .hero-domains { display: none; }

  .harm-stats {
    grid-template-columns: 1fr;
  }
  .harm-stats .stat { border-bottom: none; border-right: 1px solid var(--border); }
  .harm-stats .stat:last-child { border-bottom: 1px solid var(--border); }

  .xime-portrait { flex-direction: column; align-items: flex-start; }

  .dnd-tokens { gap: 1rem 1.5rem; }
  .dnd-token__ring { width: 72px; height: 72px; }

  .footer__inner { justify-content: center; text-align: center; }
}

/* ══════════════════════════════════════════════════
   UTILITY
   ══════════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  html { scroll-behavior: auto; }
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}
