.news-page { max-width: 920px; margin: 0 auto; padding: 32px 24px 80px; }

/* ── Onglets Global / KR ── */
.news-tabs { display: flex; gap: 8px; margin-bottom: 28px; }
.news-tab {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 22px; border-radius: 99px; font-size: .82rem; font-weight: 700;
  cursor: pointer; border: 1px solid rgba(255,255,255,.1);
  background: rgba(255,255,255,.04); color: rgba(160,180,220,.65);
  transition: background .18s, border-color .18s, color .18s;
}
.news-tab:hover { background: rgba(255,255,255,.08); color: #dce8f8; }
.news-tab.active { background: rgba(58,139,186,.18); border-color: rgba(58,139,186,.45); color: #5aadd4; }

/* Tag KR/TW — orange ambré */
.nc-tag--kr { background: rgba(210,130,30,.18); color: #e8a84a; border-color: rgba(210,130,30,.38); }
.nd-tag--kr { background: rgba(210,130,30,.20); color: #e8a84a; border-color: rgba(210,130,30,.42); }

/* ── Liste ── */
.news-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px; }
.nc-card {
  display: flex; flex-direction: column;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 12px; overflow: hidden; cursor: pointer;
  text-decoration: none; transition: border-color .2s, transform .18s;
}
.nc-card:hover { border-color: rgba(100,160,220,.28); transform: translateY(-3px); }
.nc-card-img { width: 100%; aspect-ratio: 16/8; object-fit: cover; background: rgba(58,139,186,.1); display: block; }
.nc-card-body { padding: 16px 18px 18px; flex: 1; display: flex; flex-direction: column; }
.nc-meta { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.nc-tag { font-size: .6rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; background: rgba(58,139,186,.15); color: #5aadd4; border: 1px solid rgba(58,139,186,.28); padding: 2px 8px; border-radius: 20px; }
.nc-date { font-size: .68rem; color: rgba(160,180,220,.45); }
.nc-title { font-family: 'Cinzel', serif; font-size: 1rem; font-weight: 700; color: #dce8f8; line-height: 1.35; margin-bottom: 8px; }
.nc-excerpt { font-size: .8rem; color: rgba(180,200,235,.65); line-height: 1.65; flex: 1; }

/* ── Page detail : background + layout ── */
.news-page.is-detail { max-width: none; padding: 0; min-height: 100vh;
  background: radial-gradient(circle at 16% 0%, rgba(105,187,255,.13), transparent 28%),
              radial-gradient(circle at 86% 10%, rgba(216,180,106,.13), transparent 26%),
              linear-gradient(180deg, #050b14, #07101d 50%, #04080f); }
.nd-article-wrap { max-width: 1060px; margin: 0 auto; padding: 32px 20px 80px; margin-top: 62px; width: 100%; box-sizing: border-box; }

/* ── Shell ── */
.nd-shell {
  border: 1px solid rgba(216,180,106,.22); border-radius: 22px;
  background: radial-gradient(circle at 18% 8%, rgba(105,187,255,.1), transparent 28%),
              linear-gradient(180deg, rgba(11,21,37,.97), rgba(5,11,20,.99));
  box-shadow: 0 24px 72px rgba(0,0,0,.5);
  overflow: clip; width: 100%; box-sizing: border-box;
}

/* ── Hero ── */
.nd-hero {
  position: relative; padding: 36px 42px 32px;
  min-height: 320px; display: flex; flex-direction: column; justify-content: flex-end;
  border-radius: 22px 22px 0 0; overflow: hidden;
  background: radial-gradient(circle at 20% 50%, rgba(105,187,255,.18), transparent 36%),
              radial-gradient(circle at 82% 20%, rgba(216,180,106,.18), transparent 32%),
              linear-gradient(135deg, #030a15, #071628 60%, #030a15);
  border-bottom: 1px solid rgba(216,180,106,.28);
}
.nd-hero::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(216,180,106,.65), transparent); }

/* Image de couverture en <img> absolu — fonctionne avec tous les CDN */
.nd-hero-img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; object-position: center 35%;
  display: block; margin: 0 !important; border-radius: 0 !important; z-index: 0;
}
/* Overlay sombre par-dessus l'image pour la lisibilité */
.nd-hero:has(.nd-hero-img)::before {
  content: ''; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(180deg, rgba(3,10,21,.72) 0%, rgba(5,14,28,.5) 40%, rgba(3,10,21,.88) 100%);
}
/* Bouton retour et kicker au-dessus de l'overlay */
.nd-hero .nd-back, .nd-hero .nd-kicker { position: relative; z-index: 2; }

/* ── Kicker pill ── */
.nd-kicker {
  display: inline-flex; align-items: center; gap: 9px; padding: 7px 14px;
  border: 1px solid rgba(216,180,106,.44); border-radius: 999px;
  background: rgba(7,15,27,.78); color: #f4d88d;
  font-size: .7rem; font-weight: 900; letter-spacing: .08em; text-transform: uppercase;
  margin-bottom: 16px;
}
.nd-kicker::before { content: ''; width: 7px; height: 7px; border-radius: 99px;
  background: #f4d88d; box-shadow: 0 0 16px rgba(244,216,141,.85); }

/* ── Hero title (articles sans design embarqué) ── */
.nd-hero-title {
  font-family: 'Cinzel', serif; font-size: 1.7rem; font-weight: 700;
  color: #fff; line-height: 1.25; margin: 0 0 14px;
  text-shadow: 0 2px 20px rgba(0,0,0,.8);
}
.nd-hero-meta { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }

/* ── Body wrap ── */
.nd-body-wrap { padding: 32px 42px 48px; }
.nd-body-wrap.rich { padding: 0; }
.nd-body-wrap.plain { padding: 0; }

/* ── Header article non-rich (titre + date en haut du body, pas dans le hero) ── */
.nd-article-header { padding: 28px 42px 20px; border-bottom: 1px solid rgba(255,255,255,.06); }
.nd-article-header .nd-hero-title { font-size: 1.55rem; margin-bottom: 12px; }
.nd-article-header .nd-hero-meta { margin: 0; }

/* ── Body et footer pour articles plain ── */
.nd-body-wrap.plain .nd-body { padding: 28px 42px 40px; }
.nd-body-wrap.plain .nd-author { padding: 0 42px 32px; margin-top: 28px; }

/* ── Contenu Froala converti en <p> ── */
.nd-body p { margin: 0 0 12px; }
.nd-body p + p { margin-top: 0; }

/* ── Rich meta bar (date + share pour les articles rich) ── */
.nd-rich-meta {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  padding: 18px 42px; border-bottom: 1px solid rgba(255,255,255,.06);
}

/* ── Détail ── */
.nd-back { display: inline-flex; align-items: center; gap: 6px; font-size: .75rem; color: #5aadd4; cursor: pointer; margin-bottom: 22px; text-decoration: none; opacity: .8; transition: opacity .15s; background: none; border: none; padding: 0; }
.nd-back:hover { opacity: 1; }

.nd-meta { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.nd-tag { font-size: .62rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; background: rgba(58,139,186,.18); color: #5aadd4; border: 1px solid rgba(58,139,186,.3); padding: 2px 10px; border-radius: 20px; }
.nd-date { font-size: .72rem; color: rgba(160,180,220,.5); }
.nd-title { font-family: 'Cinzel', serif; font-size: 1.55rem; font-weight: 700; color: #dce8f8; line-height: 1.28; margin-bottom: 24px; letter-spacing: .02em; }
.nd-body { color: rgba(200,215,240,.82); font-size: .95rem; line-height: 1.85; }
.nd-body p { margin: 0 0 16px; }
.nd-body strong { color: #d4dff5; }
.nd-body em { color: rgba(200,215,240,.7); font-style: italic; }

/* Neutralise le layout 2 colonnes des articles importés */
.nd-body .a2-layout { display: block !important; }
.nd-body .a2-quick-menu { display: none !important; }
.nd-body .aion2-article-fr { padding: 0 !important; max-width: 100% !important; }
.nd-body .pn-layout { display: block !important; }
.nd-body .pn-menu { display: none !important; }

/* Images importées depuis le CMS KR */
.nd-body img { max-width: 100%; height: auto; display: block; border-radius: 4px; margin: 8px auto; }
/* Ne pas toucher aux icônes de skills dans les articles a2p26 */
.nd-body .a2-skill img { display: inline; margin: 0; max-width: none; border-radius: 0; }
.nd-body .fe-image-inner { max-width: 100%; overflow: hidden; }
.nd-body .fr-image { margin: 16px 0; text-align: center; }

/* Tableaux importés depuis le CMS KR — limités aux articles sans style propre */
.nd-body .tableWrapper { overflow-x: auto; margin: 16px 0; border-radius: 6px; width: 100% !important; box-sizing: border-box; }
.nd-body .tableWrapper table,
.nd-body:not(:has(.a2p26)) table { width: 100% !important; border-collapse: collapse; font-size: .85rem; table-layout: auto; }
.nd-body .tableWrapper td,
.nd-body .tableWrapper th,
.nd-body:not(:has(.a2p26)) td,
.nd-body:not(:has(.a2p26)) th { padding: 8px 12px; border: 1px solid rgba(255,255,255,.15); vertical-align: middle; width: auto !important; }
.nd-body .tableWrapper tr:first-child td,
.nd-body .tableWrapper th,
.nd-body:not(:has(.a2p26)) tr:first-child td,
.nd-body:not(:has(.a2p26)) th { background: rgba(58,139,186,.12); color: #c8dff5; font-weight: 600; }
.nd-body .tableWrapper tr:not(:first-child) td,
.nd-body:not(:has(.a2p26)) tr:not(:first-child) td { background: rgba(255,255,255,.02); color: rgba(200,215,240,.82); }

/* Icônes de compétences : float left dans la cellule */
.nd-body .tableWrapper td img { border-radius: 5px; }
.nd-body .tableWrapper td div img { float: left; margin-right: 10px; width: 48px; height: 48px; border-radius: 5px; vertical-align: middle; }

.nd-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin: 24px 0; }
.nd-fact { background: rgba(58,139,186,.08); border: 1px solid rgba(58,139,186,.18); border-radius: 8px; padding: 13px 15px; }
.nd-fact-lbl { font-size: .6rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: #5aadd4; margin-bottom: 4px; }
.nd-fact-val { font-family: 'Cinzel', serif; font-size: .86rem; font-weight: 600; color: #dce8f8; }

.nd-cta-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; margin-bottom: 40px; }
.nd-cta { display: inline-flex; align-items: center; gap: 7px; background: linear-gradient(135deg,rgba(58,139,186,.25),rgba(58,139,186,.12)); border: 1px solid rgba(58,139,186,.4); color: #5aadd4; border-radius: 8px; padding: 10px 20px; font-size: .82rem; font-weight: 600; text-decoration: none; transition: background .2s, border-color .2s; }
.nd-cta:hover { background: rgba(58,139,186,.35); border-color: rgba(58,139,186,.7); color: #8dcfef; }

.nd-author { display: flex; align-items: center; gap: 10px; margin-top: 40px; padding-top: 18px; border-top: 1px solid rgba(255,255,255,.08); }
.nd-author-label { font-size: .72rem; color: rgba(160,180,220,.45); text-transform: uppercase; letter-spacing: .1em; }
.nd-author-name { font-size: .82rem; font-weight: 700; color: #5aadd4; letter-spacing: .04em; }

.nd-disclaimer { margin-top: 0; padding: 13px 17px; background: rgba(255,255,255,.03); border-left: 2px solid rgba(160,180,220,.15); border-radius: 0 6px 6px 0; font-size: .74rem; color: rgba(160,180,220,.4); line-height: 1.6; }
.nd-disclaimer a { color: inherit; opacity: .7; }

/* Image cover skeleton + fade-in */
.nd-img-wrap { width: 100%; aspect-ratio: 16/7; border-radius: 10px; margin-bottom: 28px; overflow: hidden; background: linear-gradient(90deg,rgba(255,255,255,.04) 25%,rgba(255,255,255,.09) 50%,rgba(255,255,255,.04) 75%); background-size: 200% 100%; animation: nd-sk 1.4s infinite; }
.nd-img-wrap.loaded { animation: none; background: none; }
.nd-img { width: 100%; height: 100%; object-fit: cover; display: block; opacity: 0; transition: opacity .55s ease; }
.nd-img-wrap.loaded .nd-img { opacity: 1; }

/* ── États vide / chargement ── */
.news-empty { text-align: center; padding: 60px 20px; color: rgba(160,180,220,.4); }
.news-empty svg { margin-bottom: 16px; opacity: .3; }
.news-empty p { font-size: .9rem; line-height: 1.7; }
.news-loading { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px; }
.nc-skel { border-radius: 12px; overflow: hidden; background: rgba(255,255,255,.03); border: 1px solid rgba(255,255,255,.06); }
.nc-skel-img { width: 100%; aspect-ratio: 16/8; background: linear-gradient(90deg,rgba(255,255,255,.04) 25%,rgba(255,255,255,.09) 50%,rgba(255,255,255,.04) 75%); background-size:200% 100%; animation: nd-sk 1.4s infinite; }
.nc-skel-body { padding: 14px 16px 18px; }
.nc-skel-line { height: 10px; border-radius: 5px; margin-bottom: 8px; background: linear-gradient(90deg,rgba(255,255,255,.04) 25%,rgba(255,255,255,.09) 50%,rgba(255,255,255,.04) 75%); background-size:200% 100%; animation: nd-sk 1.4s infinite; }
.nc-skel-line.wide { width: 80%; }
.nc-skel-line.med  { width: 55%; }
@keyframes nd-sk { 0% { background-position:200% 0; } 100% { background-position:-200% 0; } }

/* ── TOC automatique sur les articles ── */
.news-page:has(.nd-toc-layout) { max-width: none; }
.nd-body-wrap:has(.nd-toc-layout) { padding-left: 0; padding-right: 0; }
.nd-body-wrap.rich:has(.nd-toc-layout) { padding: 0; }

.nd-toc-layout {
  display: flex;
  align-items: flex-start;
  gap: 0;
}
.nd-toc-layout > .nd-body {
  flex: 1;
  min-width: 0;
}
#nd-toc-wrap {
  width: 220px;
  flex-shrink: 0;
  position: sticky;
  top: 78px;
  max-height: calc(100vh - 100px);
  overflow-y: auto;
  padding: 0 22px 64px 0;
  scrollbar-width: none;
  order: -1;
}
#nd-toc-wrap::-webkit-scrollbar { display: none; }
#nd-toc {
  display: block !important;
  flex: none !important;
  padding: 4px 0;
}
#nd-toc a {
  display: block !important;
  padding: 6px 14px !important;
  font-size: .77rem !important;
  font-weight: 400 !important;
  letter-spacing: normal !important;
  text-transform: none !important;
  white-space: normal !important;
  color: rgba(180,200,240,.5) !important;
  text-decoration: none !important;
  line-height: 1.45 !important;
  transition: color .15s, background .15s, border-color .15s !important;
  border-left: 2px solid transparent !important;
  margin-left: -1px;
  background: none !important;
}
#nd-toc a::after { display: none !important; }
#nd-toc a:hover { color: #c8d8f0 !important; background: rgba(255,255,255,.03) !important; }
#nd-toc a.toc-active { color: #5aadd4 !important; border-left-color: #5aadd4 !important; background: rgba(58,139,186,.07) !important; }
#nd-toc a.toc-h3 { padding-left: 22px !important; font-size: .73rem !important; color: rgba(180,200,240,.38) !important; }
#nd-toc a.toc-h3:hover { color: #c8d8f0 !important; }
#nd-toc a.toc-h3.toc-active { color: #5aadd4 !important; }

@media (max-width: 960px) {
  #nd-toc-wrap { display: none !important; }
  .nd-toc-layout { display: block; }
  .news-page:has(.nd-toc-layout) { max-width: 920px; }
}

/* ── Responsive : tablette ── */
@media (max-width: 768px) {
  .nd-article-wrap { padding: 20px 12px 60px; margin-top: 62px; }
  .nd-shell { border-radius: 16px; }
  .nd-hero { padding: 28px 24px 24px; min-height: 240px; border-radius: 16px 16px 0 0; }
  .nd-hero-title { font-size: 1.35rem; }
  .nd-article-header { padding: 20px 24px 16px; }
  .nd-article-header .nd-hero-title { font-size: 1.25rem; }
  .nd-rich-meta { padding: 14px 24px; }
  .nd-body-wrap { padding: 22px 24px 40px; }
  .nd-body-wrap.plain .nd-body { padding: 20px 24px 32px; }
  .nd-body-wrap.plain .nd-author { padding: 0 24px 24px; }
  .nd-body-wrap.rich .nd-body { padding: 20px 24px 32px; }
  .nd-body { font-size: .9rem; }
  .nd-body-wrap.rich:has(.nd-body) .nd-body { padding: 20px 24px 32px; }
}

/* ── Responsive : mobile ── */
@media (max-width: 480px) {
  .nd-article-wrap { padding: 12px 8px 48px; }
  .nd-shell { border-radius: 12px; }
  .nd-hero { padding: 22px 18px 20px; min-height: 180px; border-radius: 12px 12px 0 0; }
  .nd-hero-title { font-size: 1.15rem; }
  .nd-article-header { padding: 16px 18px 14px; }
  .nd-article-header .nd-hero-title { font-size: 1.1rem; }
  .nd-rich-meta { padding: 12px 18px; }
  .nd-body-wrap { padding: 18px 18px 32px; }
  .nd-body-wrap.plain .nd-body { padding: 16px 18px 24px; }
  .nd-body-wrap.plain .nd-author { padding: 0 18px 20px; }
  .nd-body { font-size: .88rem; line-height: 1.75; }
  .nd-hero-meta { flex-direction: column; align-items: flex-start; gap: 8px; }
  .nd-hero-meta .share-btn { margin-left: 0 !important; }
  .nd-back { font-size: .7rem; }
  .nd-kicker { font-size: .65rem; padding: 5px 11px; }
  .nd-body-wrap.rich:has(.nd-body) .nd-body { padding: 16px 18px 24px; }
}

/* ── Responsive : très petit (≤ 360px) ── */
@media (max-width: 360px) {
  .nd-article-wrap { padding: 8px 4px 40px; }
  .nd-hero { padding: 18px 14px 16px; min-height: 150px; }
  .nd-article-header { padding: 14px 14px 12px; }
  .nd-rich-meta { padding: 10px 14px; }
  .nd-body-wrap.plain .nd-body { padding: 14px 14px 20px; }
}

/* ── Patch Note : titres de sections générés par enhancePatchNote ── */
.nd-body h2.pn-section {
  font-family: 'Cinzel', serif;
  font-size: 1rem;
  font-weight: 700;
  color: #d4bc5a;
  border-bottom: 1px solid rgba(216,180,106,.25);
  padding-bottom: 10px;
  margin: 36px 0 18px;
  letter-spacing: .03em;
}
.nd-body h2.pn-subsection {
  font-size: .9rem;
  font-weight: 700;
  color: #c8d8f0;
  margin: 26px 0 12px;
  padding-left: 10px;
  border-left: 3px solid rgba(58,139,186,.55);
  letter-spacing: .01em;
}
.nd-body h3.pn-class-header {
  display: flex;
  align-items: center;
  gap: 7px;
  font-family: inherit;
  font-size: .88rem;
  font-weight: 700;
  color: #dce8f8;
  margin: 28px 0 6px;
  padding: 0;
}
.nd-body .pn-class-bullet { color: rgba(58,139,186,.6); font-size: .75em; line-height: 1; }
.nd-body .pn-class-name { color: #5aadd4; font-size: .9rem; font-weight: 700; }

/* ── Lightbox ── */
#lb-overlay {
  display: none;
  position: fixed; inset: 0; z-index: 9000;
  background: rgba(4, 8, 20, 0.92);
  backdrop-filter: blur(6px);
  align-items: center; justify-content: center;
  cursor: zoom-out;
}
#lb-overlay.lb-open { display: flex; animation: lb-in .18s ease; }
@keyframes lb-in { from { opacity: 0; } to { opacity: 1; } }

#lb-img {
  max-width: min(92vw, 1200px);
  max-height: 90vh;
  object-fit: contain;
  border-radius: 6px;
  box-shadow: 0 8px 48px rgba(0,0,0,.7);
  cursor: default;
}
#lb-close {
  position: absolute; top: 18px; right: 22px;
  background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.15);
  color: #dce8f8; font-size: 1.6rem; line-height: 1;
  width: 38px; height: 38px; border-radius: 50%;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  transition: background .15s;
}
#lb-close:hover { background: rgba(255,255,255,.18); }
