:root {
  /* Hauteur minimale du Hero (modifiable ici) */
  --hero-min-height: 620px;

  /* Fonds */
  --bg-void:        #0A0A0B;
  --bg-charcoal:    #151517;
  --bg-panel:       #1C1C1F;
  --bg-panel-hover: #232326;

  /* Séparateurs */
  --hairline:        rgba(255, 255, 255, 0.08);
  --hairline-strong: rgba(255, 255, 255, 0.14);

  /* Texte */
  --ink:       #F3F2ED;
  --ink-dim:   #A8A7A2;
  --ink-faint: #6E6D68;

  /* Accents */
  --red:     #E7342A;
  --red-dim: #8F2018;
  --gold:    #D9A65A;

  /* Lecteur */
  --paper:      #EDEAE1;
  --paper-line: #161513;
}

/* Reset minimal */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { background: var(--bg-void); }
body {
  background: var(--bg-void);
  color: var(--ink);
  font-family: 'Inter', sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }

/* Utilitaires typographiques */
.display {
  font-family: 'Bebas Neue', sans-serif;
  letter-spacing: 0.02em;
  font-weight: 400;
}
.eyebrow {
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-faint);
  font-weight: 600;
}

/* Boutons */
.btn-primary {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--red); color: #fff;
  font-size: 14px; font-weight: 600;
  padding: 12px 24px; border-radius: 10px;
  border: none; cursor: pointer;
  transition: background 0.15s ease;
}
.btn-primary:hover { background: var(--red-dim); }

.btn-ghost {
  display: inline-flex; align-items: center; gap: 8px;
  background: transparent; color: var(--ink);
  font-size: 14px; font-weight: 600;
  padding: 11px 22px; border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.18); cursor: pointer;
  transition: background 0.15s ease;
}
.btn-ghost:hover { background: rgba(255,255,255,0.06); }

/* Wrapper centré */
.wrap { max-width: 1320px; margin: 0 auto; padding: 0 40px; }

/* ========== NAV ========== */
.nav { position: sticky; top: 0; z-index: 50; background: rgba(10,10,11,0.85); backdrop-filter: blur(14px); border-bottom: 1px solid var(--hairline); }
.nav-inner { max-width: 1320px; margin: 0 auto; padding: 0 40px; height: 72px; display: flex; align-items: center; gap: 44px; }
.logo { display: flex; align-items: center; gap: 10px; }
.logo-img { height: 40px; width: auto; display: block; }
.nav-links { display: flex; gap: 32px; flex: 1; }
.nav-links a { font-size: 14px; font-weight: 500; color: var(--ink-dim); padding: 8px 2px; border-bottom: 2px solid transparent; transition: color .15s, border-bottom-color .15s; }
.nav-links a.active { color: var(--ink); border-bottom-color: var(--red); }
.nav-links a:hover { color: var(--ink); border-bottom-color: var(--red); }
.nav-right { display: flex; align-items: center; gap: 18px; }
.search { display: flex; align-items: center; gap: 8px; background: var(--bg-panel); border: 1px solid var(--hairline); border-radius: 8px; padding: 8px 14px; width: 230px; }
.search input { background: transparent; border: none; outline: none; color: var(--ink); font-size: 13px; width: 100%; font-family: 'Inter', sans-serif; }
.search input::placeholder { color: var(--ink-faint); }
.avatar { width: 36px; height: 36px; border-radius: 50%; background: #2c2c2f; border: 1px solid var(--hairline-strong); display: flex; align-items: center; justify-content: center; overflow: hidden; color: var(--ink-faint); }

/* ========== FOOTER ========== */
footer { margin-top: 72px; border-top: 1px solid var(--hairline); padding: 28px 0; }
.foot-inner { display: flex; align-items: center; justify-content: space-between; font-size: 13px; color: var(--ink-faint); }
.foot-links { display: flex; gap: 24px; }
.foot-links a:hover { color: var(--ink); }

/* ========== CARTES MANGA ========== */
.card { display: block; flex-shrink: 0; width: 160px; cursor: pointer; }
.card-cover { position: relative; width: 160px; height: 224px; border-radius: 10px; overflow: hidden; background: var(--bg-panel); }
.card-cover img { width: 100%; height: 100%; object-fit: cover; transition: transform .25s ease; }
.card:hover .card-cover img { transform: scale(1.04); }
.card-info { padding: 10px 2px 0; }
.card-title { font-size: 13px; font-weight: 600; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.card-sub { display: flex; align-items: center; gap: 8px; margin-top: 4px; font-size: 11.5px; }
.card-genre { color: var(--ink-faint); }

/* ========== PILLS ========== */
.pill-row { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 24px; }
.pill { padding: 8px 16px; border-radius: 20px; background: var(--bg-panel); border: 1px solid var(--hairline); font-size: 13px; font-weight: 500; color: var(--ink-dim); cursor: pointer; transition: all .15s; }
.pill:hover, .pill.active { background: rgba(231,52,42,0.12); border-color: rgba(231,52,42,0.4); color: var(--red); }

/* ========== HERO ========== */
.hero { position: relative; margin: 28px 40px 0; border-radius: 18px; overflow: hidden; min-height: var(--hero-min-height); display: flex; align-items: flex-end; background: linear-gradient(120deg,#1a1a1c,#0f0f10); }
.hero-art { position: absolute; inset: 0; }
.hero-art img { width: 100%; height: 100%; object-fit: cover; filter: saturate(0.85) brightness(0.62); }
.hero-scrim { position: absolute; inset: 0; background: linear-gradient(to top, rgba(10,10,11,0.95) 0%, rgba(10,10,11,0.3) 55%, transparent 100%); }
.hero-content { position: relative; padding: 40px 44px; max-width: 600px; }
.hero-tag { display: inline-flex; align-items: center; gap: 8px; background: rgba(231,52,42,0.18); border: 1px solid rgba(231,52,42,0.4); border-radius: 20px; padding: 5px 12px; font-size: 12px; font-weight: 600; color: var(--red); margin-bottom: 14px; }
.hero-title { font-size: clamp(40px,6vw,72px); line-height: 0.95; margin-bottom: 16px; }
.hero-meta { display: flex; align-items: center; gap: 16px; margin-bottom: 14px; font-size: 13px; color: var(--ink-dim); }
.hero-note { color: var(--gold); font-weight: 600; }
.hero-desc { font-size: 14px; color: var(--ink-dim); line-height: 1.6; margin-bottom: 24px; max-width: 480px; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* ========== ROWS / SCROLL ========== */
.row { margin-top: 52px; }
.row-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 20px; padding: 0 40px; }
.row-title { font-size: 22px; }
.row-link { font-size: 13px; color: var(--ink-dim); font-weight: 500; }
.row-link:hover { color: var(--ink); }
.scroll-row { display: flex; gap: 16px; overflow-x: auto; padding: 4px 40px 16px; scrollbar-width: none; }
.scroll-row::-webkit-scrollbar { display: none; }

/* ========== GRID CATALOGUE ========== */
.grid-section { margin-top: 52px; padding: 0 40px; }
.grid-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; }
.grid-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(155px, 1fr)); gap: 20px; }

/* ========== BURGER / MENU MOBILE ========== */
.nav-burger {
  display: none;
  align-items: center; justify-content: center;
  width: 38px; height: 38px; border-radius: 8px;
  background: transparent; border: 1px solid var(--hairline);
  color: var(--ink-dim); cursor: pointer; margin-left: 8px;
  transition: background .15s;
}
.nav-burger:hover { background: var(--bg-panel); color: var(--ink); }

/* Barre de recherche inline mobile (masquée sur desktop) */
.nav-search-mobile {
  display: none;
  align-items: center; gap: 8px;
  background: var(--bg-panel); border: 1px solid var(--hairline);
  border-radius: 8px; padding: 8px 12px;
  flex: 1; min-width: 0; margin-left: auto; margin-right: 4px;
}
.nav-search-mobile input {
  background: transparent; border: none; outline: none;
  color: var(--ink); font-size: 13px; width: 100%; font-family: 'Inter', sans-serif;
}
.nav-search-mobile input::placeholder { color: var(--ink-faint); }

.nav-mobile-panel {
  background: var(--bg-charcoal);
  border-top: 1px solid var(--hairline);
  padding: 12px 16px 20px;
  display: flex; flex-direction: column; gap: 4px;
}
.nav-mobile-search {
  display: flex; align-items: center; gap: 8px;
  background: var(--bg-panel); border: 1px solid var(--hairline);
  border-radius: 8px; padding: 10px 14px; margin-bottom: 8px;
}
.nav-mobile-search input {
  background: transparent; border: none; outline: none;
  color: var(--ink); font-size: 14px; width: 100%; font-family: 'Inter', sans-serif;
}
.nav-mobile-search input::placeholder { color: var(--ink-faint); }
.nav-mobile-link {
  display: flex; align-items: center; gap: 10px;
  padding: 13px 8px; font-size: 15px; font-weight: 500;
  color: var(--ink-dim); border-radius: 8px;
  transition: background .15s, color .15s;
}
.nav-mobile-link:hover { background: var(--bg-panel); color: var(--ink); }
.nav-mobile-divider {
  height: 1px; background: var(--hairline); margin: 8px 0;
}

/* ========== PAGE MANGA DÉTAIL ========== */
.manga-detail { max-width: 900px; margin: 48px auto; padding: 0 40px; }
.manga-header { display: flex; flex-wrap: wrap; gap: 32px; margin-bottom: 40px; }
.manga-cover { width: 200px; flex-shrink: 0; align-self: center; border-radius: 12px; overflow: hidden; }
.manga-cover img { width: 100%; height: auto; display: block; }
.manga-info { flex: 1; }
.manga-title { flex: 1 0 100%; font-size: 48px; line-height: 1; }
.manga-meta { display: flex; gap: 16px; align-items: center; margin-bottom: 16px; font-size: 13px; color: var(--ink-dim); flex-wrap: wrap; }
.manga-note { color: var(--gold); font-weight: 600; }
.manga-synopsis { font-size: 14px; color: var(--ink-dim); line-height: 1.7; margin-bottom: 24px; }
.manga-cta-row { display: flex; gap: 12px; align-items: center; }
.manga-cta-row .btn-primary { flex: 1; justify-content: center; min-width: 0; }
.chapter-list { border: 1px solid var(--hairline); border-radius: 12px; overflow: hidden; }
.chapter-item { display: flex; align-items: center; justify-content: space-between; padding: 14px 20px; border-bottom: 1px solid var(--hairline); transition: background .15s; }
.chapter-item:last-child { border-bottom: none; }
.chapter-item:hover { background: var(--bg-panel); }
.ch-num { font-family: 'Bebas Neue', sans-serif; font-size: 15px; color: var(--red); letter-spacing: 0.03em; width: 60px; flex-shrink: 0; }
.ch-name { flex: 1; font-size: 13px; font-weight: 500; }
.ch-badge-free { background: rgba(231,52,42,0.15); color: var(--red); font-size: 11px; font-weight: 700; padding: 3px 8px; border-radius: 4px; white-space: nowrap; }
.ch-badge-read { background: rgba(255,255,255,0.07); color: var(--ink-dim); font-size: 11px; font-weight: 700; padding: 3px 8px; border-radius: 4px; white-space: nowrap; }
.ch-badge-lock { color: var(--ink-faint); font-size: 13px; }
.ch-badge-done { color: var(--gold); display: flex; align-items: center; flex-shrink: 0; }

/* ========== RESPONSIVE ========== */
@media (max-width: 768px) {
  .wrap, .nav-inner { padding: 0 16px; }
  .nav-inner { gap: 8px; }
  .nav-links, .search, .avatar { display: none; }
  .nav-wordmark { display: none; }
  .nav-burger, .nav-search-mobile { display: flex; }
  /* Accueil */
  .hero { margin: 12px 16px 0; min-height: min(340px, var(--hero-min-height)); }
  .hero-content { padding: 24px 20px; }
  .hero-title { font-size: clamp(32px, 8vw, 56px); }
  .hero-actions { flex-direction: row; align-items: center; }
  .hero-actions .btn-primary { flex: 1; justify-content: center; min-width: 0; }
  .hero-actions .btn-ghost:not(.library-btn--compact) { width: 100%; justify-content: center; }
  .row-head { padding: 0 16px; }
  .scroll-row { padding: 4px 16px 16px; }
  .grid-section { padding: 0 16px; }
  .foot-inner { flex-direction: column; gap: 12px; text-align: center; }
  /* Manga détail */
  .manga-detail { margin: 24px auto; padding: 0 16px; }
  /* Catalogue */
  .cat-header { padding-top: 24px; }
  .cat-title { font-size: 36px; }
  .manga-header { flex-direction: column; align-items: center; gap: 20px; }
  .manga-title { width: 100%; text-align: center; font-size: 32px; }
  .manga-cover { width: 140px; align-self: center; }
  .manga-cover img { height: 196px; }
  .manga-info { width: 100%; text-align: center; }
  .manga-meta { justify-content: center; }
  .rating-widget { justify-content: center; }
  .manga-synopsis { text-align: left; }
  .chapter-item { padding: 12px 14px; }
  .ch-num { width: 46px; font-size: 13px; }
}


/* Bouton bibliothèque */
.library-btn { transition: all .15s; }
.library-btn--compact { padding: 11px 14px; flex-shrink: 0; }
.library-btn--active {
  background: rgba(217,166,90,0.12);
  border-color: rgba(217,166,90,0.4);
  color: var(--gold);
}
.library-btn--active:hover {
  background: rgba(217,166,90,0.2);
}
/* Bouton retirer sur la carte dans le profil */
.library-remove-btn {
  position: absolute; top: 8px; left: 8px;
  width: 24px; height: 24px; border-radius: 50%;
  background: rgba(10,10,11,0.75); border: 1px solid var(--hairline-strong);
  color: var(--ink-dim); display: flex; align-items: center; justify-content: center;
  cursor: pointer; transition: background .15s, color .15s;
  backdrop-filter: blur(4px);
}
.library-remove-btn:hover { background: var(--red); color: #fff; border-color: var(--red); }

/* ========== AUTHENTIFICATION / PROFIL ========== */
.auth-page { display: flex; justify-content: center; padding: 60px 0 80px; }
.auth-card {
  width: 100%; max-width: 420px;
  background: var(--bg-panel); border: 1px solid var(--hairline);
  border-radius: 16px; padding: 36px 32px;
}
.auth-title { font-size: 36px; margin-bottom: 6px; }
.auth-sub { font-size: 13px; color: var(--ink-faint); margin-bottom: 28px; }
.auth-sub a { color: var(--red); }
.auth-sub a:hover { text-decoration: underline; }
.auth-form p { margin-bottom: 16px; }
.auth-form label { display: block; font-size: 12px; font-weight: 600; color: var(--ink-dim); margin-bottom: 6px; letter-spacing: 0.05em; text-transform: uppercase; }
.auth-form input[type="email"],
.auth-form input[type="text"],
.auth-form input[type="password"] {
  width: 100%; background: var(--bg-charcoal);
  border: 1px solid var(--hairline); border-radius: 8px;
  padding: 10px 14px; color: var(--ink); font-size: 14px;
  font-family: 'Inter', sans-serif; outline: none;
  transition: border-color .15s;
}
.auth-form input:focus { border-color: var(--red); }
.auth-form .helptext { font-size: 11px; color: var(--ink-faint); margin-top: 4px; display: block; }
.auth-form .errorlist { list-style: none; color: var(--red); font-size: 12px; margin-top: 4px; }
.profil-page { padding-top: 48px; padding-bottom: 80px; }
.profil-header {
  display: flex; align-items: center; gap: 24px;
  margin-bottom: 48px; flex-wrap: wrap;
}
.profil-identity { flex: 1; min-width: 0; }
.profil-title { font-size: 40px; line-height: 1; margin-bottom: 4px; }
.profil-email { color: var(--ink-faint); font-size: 14px; }
.username-edit { margin-bottom: 4px; }
.username-display { display: flex; align-items: center; gap: 8px; }
.username-value { font-size: 16px; font-weight: 600; color: var(--ink); }
.username-edit-btn {
  display: inline-flex; align-items: center; justify-content: center;
  background: transparent; border: none; cursor: pointer;
  color: var(--ink-faint); padding: 2px; transition: color .15s;
}
.username-edit-btn:hover { color: var(--ink); }
.username-form { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.username-input {
  background: var(--bg-panel); border: 1px solid var(--hairline-strong);
  border-radius: 8px; padding: 7px 12px; font-size: 14px;
  color: var(--ink); font-family: 'Inter', sans-serif; outline: none;
  transition: border-color .15s; width: 200px;
}
.username-input:focus { border-color: var(--red); }
.username-error { font-size: 13px; color: var(--red); margin-bottom: 6px; }
.profil-actions { margin-left: auto; }
.profil-avatar-wrap { flex-shrink: 0; }
.profil-avatar {
  position: relative; display: flex;
  width: 80px; height: 80px; border-radius: 50%;
  background: var(--bg-panel); border: 2px solid var(--hairline-strong);
  align-items: center; justify-content: center;
  color: var(--ink-faint); overflow: visible;
  cursor: pointer; transition: border-color .15s;
}
.profil-avatar:hover { border-color: var(--red); }
.profil-avatar img {
  width: 100%; height: 100%; object-fit: cover;
  border-radius: 50%; display: block;
}
.avatar-badge {
  position: absolute; bottom: 2px; right: 2px;
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--red); color: #fff;
  display: flex; align-items: center; justify-content: center;
  border: 2px solid var(--bg-void);
}
.avatar-badge--add { background: var(--ink-dim); }
.profil-section { border-top: 1px solid var(--hairline); padding-top: 32px; }
.profil-section-title { font-size: 26px; margin-bottom: 20px; }

@media (max-width: 768px) {
  .profil-page { padding-top: 28px; }
  .profil-header { gap: 16px; }
  .profil-title { font-size: 28px; }
  .profil-actions { width: 100%; margin-left: 0; }
  .profil-actions .btn-ghost { width: 100%; justify-content: center; }
}

@media (max-width: 768px) {
  .auth-card { padding: 28px 20px; }
}

/* ========== CATALOGUE ========== */
.catalogue-page { padding-bottom: 60px; }
.cat-header { padding-top: 40px; margin-bottom: 24px; }
.cat-title { font-size: 52px; line-height: 1; margin-bottom: 6px; }
.cat-subtitle { font-size: 14px; color: var(--ink-faint); }
.cat-filters { margin-bottom: 32px; display: flex; flex-direction: column; gap: 16px; }
.cat-search {
  display: flex; align-items: center; gap: 10px;
  background: var(--bg-panel); border: 1px solid var(--hairline);
  border-radius: 10px; padding: 12px 16px;
}
.cat-search input {
  background: transparent; border: none; outline: none;
  color: var(--ink); font-size: 14px; width: 100%; font-family: 'Inter', sans-serif;
}
.cat-search input::placeholder { color: var(--ink-faint); }
.cat-grid-wrap { margin-top: 8px; }
.cat-results-header { margin-bottom: 20px; }
.cat-count { font-size: 13px; color: var(--ink-faint); }
.cat-empty {
  grid-column: 1 / -1; display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  padding: 60px 20px; color: var(--ink-faint); font-size: 14px; text-align: center;
}

/* ========== PROTECTION PLANCHES ========== */
/* Protection planches (clic droit + drag + sélection) */
.pages-area {
  user-select: none;
  -webkit-user-select: none;
}
.pages-area img {
  -webkit-user-drag: none;
  user-drag: none;
}

/* ========== LECTEUR ========== */
.reader-top {
  display: flex; align-items: center; gap: 12px;
  padding: 0 20px; height: 60px;
  border-bottom: 1px solid var(--hairline);
  background: var(--bg-charcoal); position: sticky; top: 0; z-index: 40;
}
.r-back {
  width: 34px; height: 34px; border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  color: var(--ink-dim); border: 1px solid var(--hairline); flex-shrink: 0;
}
.r-back:hover { background: var(--bg-panel); color: var(--ink); }
.chapter-select {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 14px; background: var(--bg-panel);
  border: 1px solid var(--hairline); border-radius: 9px;
  cursor: pointer; position: relative; flex: 1; min-width: 0;
}
.chapter-select .num { font-family: 'Bebas Neue', sans-serif; font-size: 15px; color: var(--red); letter-spacing: 0.03em; white-space: nowrap; flex-shrink: 0; }
.chapter-select .name { font-size: 13px; font-weight: 500; color: var(--ink); white-space: nowrap; }
.chapter-select .chev { color: var(--ink-faint); }
.chapter-menu {
  position: absolute; top: calc(100% + 8px); left: 0; width: 270px;
  background: var(--bg-panel); border: 1px solid var(--hairline-strong);
  border-radius: 10px; box-shadow: 0 20px 40px rgba(0,0,0,0.5);
  z-index: 10
}
.ch-item {
  display: flex; align-items: center; justify-content: space-between;
  padding: 11px 14px; font-size: 12.5px; border-bottom: 1px solid var(--hairline);
  color: inherit;
}
a.ch-item:hover { background: var(--bg-charcoal); }
.ch-item:last-child { border-bottom: none; }
.ch-item.current { background: rgba(231,52,42,0.1); }
.ch-item.current .ch-name { color: var(--ink); font-weight: 600; }
.ch-item.current .ch-num { color: var(--red); }
.ch-name { color: var(--ink-dim); }
.ch-num { font-family: 'Bebas Neue', sans-serif; color: var(--ink-faint); font-size: 13px; }
.ch-item.locked { opacity: 0.45; }
.r-spacer { flex: 1; }
.mode-btn {
  padding: 6px 12px; border-radius: 7px; font-size: 12px; font-weight: 600;
  border: 1px solid var(--hairline); color: var(--ink-dim); cursor: pointer;
  background: transparent; transition: all .15s; flex-shrink: 0; white-space: nowrap;
}
.mode-btn.active, .mode-btn:hover { background: var(--bg-panel); color: var(--ink); border-color: var(--hairline-strong); }
.reader-body { display: flex; min-height: calc(100vh - 72px - 57px); }
.pages-area {
  flex: 1; padding: 32px 20px; background: var(--bg-void);
  display: flex; flex-direction: column; align-items: center;
}
.pages-area.mode-page { justify-content: center; }
.page-single-img {
  display: block; border-radius: 4px; margin: 0 auto;
  width: auto; height: auto;
  max-width: 100%;
  max-height: calc(100vh - 60px - 64px - 28px);
  object-fit: contain;
}
.m-bottom {
  display: none; position: fixed; bottom: 0; left: 0; right: 0;
  background: var(--bg-charcoal); border-top: 1px solid var(--hairline);
  padding: 12px 20px; align-items: center; justify-content: center; gap: 8px; z-index: 30;
}
.page-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--hairline-strong); transition: background .15s; }
.page-dot.active { background: var(--red); }

@media (max-width: 768px) {
  .m-bottom { display: flex; }
  .pages-area { padding: 16px 8px 80px; }
  .reader-top { top: 0; height: auto; min-height: 56px; padding: 10px 14px; gap: 8px; }
  .chapter-select { padding: 8px 10px; }
  .chapter-select .name { font-size: 13px; overflow: hidden; text-overflow: ellipsis; }
  .mode-btn { padding: 6px 10px; font-size: 11px; }
  .page-single-img { max-height: calc(100vh - 56px - 32px - 28px - 76px); }
}

/* ========== COMMENTAIRES ========== */
.comments-section { border-top: 1px solid var(--hairline); padding-top: 32px; }
.comments-title { font-size: 22px; margin-bottom: 20px; }
.comments-count { color: var(--ink-faint); font-size: 16px; font-weight: 400; }
.comment-form { display: flex; flex-direction: column; gap: 10px; margin-bottom: 28px; }
.comment-input {
  background: var(--bg-panel); border: 1px solid var(--hairline-strong);
  border-radius: 10px; padding: 12px 14px; font-size: 14px;
  color: var(--ink); font-family: 'Inter', sans-serif; outline: none;
  resize: vertical; transition: border-color .15s;
}
.comment-input:focus { border-color: var(--red); }
.comment-login-hint { font-size: 14px; color: var(--ink-dim); margin-bottom: 28px; }
.comment-login-hint a { color: var(--red); font-weight: 600; }
.comment-list { display: flex; flex-direction: column; gap: 20px; }
.comment-item { display: flex; gap: 12px; position: relative; }
.comment-avatar {
  width: 34px; height: 34px; border-radius: 50%; flex-shrink: 0;
  background: #2c2c2f; border: 1px solid var(--hairline-strong);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden; color: var(--ink-faint);
}
.comment-avatar img { width: 100%; height: 100%; object-fit: cover; }
.comment-body { flex: 1; min-width: 0; }
.comment-head { display: flex; align-items: baseline; gap: 10px; margin-bottom: 4px; }
.comment-username { font-size: 13px; font-weight: 600; color: var(--ink); }
.comment-date { font-size: 12px; color: var(--ink-faint); }
.comment-text { font-size: 14px; color: var(--ink-dim); line-height: 1.6; white-space: pre-wrap; word-break: break-word; }
.comment-delete-btn {
  background: transparent; border: none; cursor: pointer;
  color: var(--ink-faint); padding: 4px; align-self: flex-start;
  transition: color .15s;
}
.comment-delete-btn:hover { color: var(--red); }
.comment-empty { color: var(--ink-faint); font-size: 14px; }

/* ========== NOTATION MANGA ========== */
.rating-widget { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }
.rating-average { display: flex; align-items: center; gap: 6px; }
.rating-average-value { color: var(--gold); font-weight: 600; font-size: 14px; }
.rating-count { color: var(--ink-faint); font-size: 13px; }
.rating-stars { display: flex; flex-direction: row-reverse; justify-content: flex-end; gap: 2px; }
.rating-star {
  background: transparent; border: none; cursor: pointer;
  font-size: 20px; line-height: 1; color: var(--hairline-strong);
  padding: 2px; transition: color .15s;
}
.rating-star--filled { color: var(--gold); }
.rating-stars .rating-star:hover,
.rating-stars .rating-star:hover ~ .rating-star { color: var(--gold); }
.rating-login-hint { font-size: 13px; color: var(--ink-dim); }
.rating-login-hint a { color: var(--red); font-weight: 600; }
.rating-remove-btn {
  background: transparent; border: none; cursor: pointer;
  color: var(--ink-faint); font-size: 12px; font-weight: 600;
  padding: 2px; transition: color .15s; text-decoration: underline;
}
.rating-remove-btn:hover { color: var(--red); }

/* ========== BADGE ULULE ========== */
.badge-ulule {
  display: inline-flex; align-items: center; gap: 4px;
  background: rgba(217,166,90,0.15); color: var(--gold);
  border: 1px solid rgba(217,166,90,0.4); border-radius: 20px;
  font-size: 11px; font-weight: 700; letter-spacing: 0.03em;
  padding: 3px 10px; text-transform: uppercase; white-space: nowrap;
}
.badge-ulule--sm { font-size: 10px; padding: 2px 8px; }

/* ========== MESSAGES SITE ========== */
.site-message {
  padding: 12px 16px; border-radius: 10px; font-size: 13px;
  background: var(--bg-panel); border: 1px solid var(--hairline-strong); color: var(--ink);
}
.site-message--success { border-color: rgba(217,166,90,0.4); color: var(--gold); }
.site-message--error { border-color: rgba(231,52,42,0.4); color: var(--red); }
.site-message--warning { border-color: rgba(217,166,90,0.4); color: var(--gold); }

/* ========== PAGES LÉGALES ========== */
.legal-page { max-width: 760px; margin: 0 auto; padding: 56px 40px 80px; }
.legal-title { font-size: 40px; margin-bottom: 8px; }
.legal-updated { font-size: 13px; color: var(--ink-faint); margin-bottom: 32px; }
.legal-page h2 { font-size: 18px; margin: 32px 0 12px; color: var(--ink); }
.legal-page p { font-size: 14px; color: var(--ink-dim); line-height: 1.7; margin-bottom: 12px; }
.legal-page a { color: var(--red); text-decoration: underline; }
.legal-list { margin: 0 0 12px 20px; }
.legal-list li { font-size: 14px; color: var(--ink-dim); line-height: 1.7; margin-bottom: 6px; }
.legal-todo {
  background: rgba(217,166,90,0.15); color: var(--gold);
  padding: 1px 6px; border-radius: 4px; font-weight: 600; font-size: 13px;
}
