:root{
  --bg:#000;
  --text:#fff;
  --sub:#a3a3a3;
  --border:#1e1e1e;
  --shadow:0 12px 26px rgba(0,0,0,.55);
}

/* Base */
*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  background:var(--bg);
  color:var(--text);
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  overflow-x:hidden;
}

.safe{min-height:100%;display:flex;justify-content:center}
.wrap{width:100%;max-width:980px;padding:26px 18px 84px;position:relative;z-index:1}

/* Sang au-dessus de TOUT */
.bloodOnScreen{
  position:fixed;inset:0;width:100vw;height:100vh;object-fit:cover;
  z-index:9999;opacity:.45;pointer-events:none;
}

/* Header */
.header{margin-bottom:18px}
.header-row{display:flex;align-items:center;justify-content:space-between;gap:16px}
.identity{display:flex;align-items:center;gap:12px}
.avatar-wrap{position:relative;width:56px;height:56px;flex:0 0 auto}
.avatar{
  width:100%;height:100%;border-radius:50%;object-fit:cover;
  border:2px solid #000;box-shadow:0 4px 14px rgba(0,0,0,.35);background:#111
}
.presence{
  position:absolute;right:-2px;bottom:-2px;width:14px;height:14px;border-radius:50%;
  background:#22c55e; box-shadow:0 0 0 2px #0b0b0b, 0 2px 6px rgba(0,0,0,.35)
}
.presence::after{content:"";position:absolute;inset:-6px;border-radius:inherit;background:rgba(34,197,94,.35);animation:ping 2.2s cubic-bezier(0,0,.2,1) infinite}

.title{font-size:32px;font-weight:800;letter-spacing:.2px;margin:0}
.handle{margin-top:2px;color:var(--sub);font-size:14px}

.actions{display:flex;gap:10px}
.action-btn{
  display:inline-flex;align-items:center;gap:8px;padding:10px 12px;border-radius:12px;border:1px solid var(--border);
  background:#111;color:#fff;text-decoration:none;font-weight:700;
  transition:transform .22s ease, box-shadow .22s ease, filter .22s ease;
}
.action-btn .icon{width:18px;height:18px}
.action-btn:hover{transform:translateY(-1px);box-shadow:var(--shadow);filter:brightness(1.06)}

/* Card */
.card{
  background:#0b0b0b;
  border:1px solid var(--border);
  border-radius:16px;
  padding:16px;
  margin-bottom:20px;
  box-shadow:0 0 15px rgba(0,0,0,.6);
}
.section-head{margin-bottom:12px}
.section-row{display:flex;align-items:center;gap:8px;justify-content:space-between}
.section-row .icon{width:20px;height:20px}
.section-title{font-size:18px;font-weight:800;margin:0}
.section-sub{color:var(--sub);margin:6px 0 0}

/* Gallery grid — vignettes carrées, espace réduit */
.gallery{
  display: grid;
  gap: 6px; /* espace entre les images */
  grid-template-columns: repeat(2, 1fr); /* 2 colonnes fixes */
  padding: 8px;
}

.g-item{
  position:relative;
  margin:0;
  border-radius:12px;
  overflow:hidden;
  cursor:zoom-in;
  border:1px solid var(--border);
  background:#000;

  /* apparition douce (stagger) */
  transform:translateY(8px);
  opacity:0;
  transition:transform .35s ease, opacity .35s ease, box-shadow .25s ease, border-color .25s ease;
}
.g-item.in{transform:translateY(0);opacity:1}

/* Carré avant clic */
.g-item{ aspect-ratio: 1 / 1; }   /* ← force la tuile au format carré */

.g-item img{
  position:absolute; inset:0;
  width:100%; height:100%;
  object-fit:cover; display:block;
  transform:scale(1); transition:transform .35s cubic-bezier(.2,.8,.2,1), filter .25s ease;
}
.g-item:hover img{ transform:scale(1.03); filter:brightness(1.05) }

/* Légende */
.g-item figcaption{
  position:absolute; left:8px; bottom:8px;
  background:rgba(0,0,0,.5); backdrop-filter:blur(4px);
  padding:5px 8px; border-radius:8px; font-size:12px;
  border:1px solid rgba(255,255,255,.12);
}

/* Footer */
.footer{text-align:center;margin-top:24px}
.footer-text{color:var(--sub);margin:0 0 10px}
.footer-line{height:1px;background:linear-gradient(90deg,transparent,#444,transparent);margin-bottom:8px}
.copyright{color:var(--sub);font-size:13px;margin:0}

/* Lightbox */
.lightbox{ position:fixed; inset:0; display:none; z-index:100000; }
.lightbox.open{ display:block; }

.lb-backdrop{
  position:absolute; inset:0;
  background:rgba(0,0,0,.78); backdrop-filter:blur(6px);
  opacity:0; animation:fade .25s ease forwards; z-index:1;
}

.lb-dialog{
  position:absolute; inset:0; display:grid; place-items:center; padding:24px; z-index:2;
  /* IMPORTANT : on désactive les clics ici */
  pointer-events:none;
}
/* ... mais on les réactive sur les éléments interactifs */
.lb-dialog img,
.lb-caption,
.lb-prev, .lb-next,
.lb-close { pointer-events:auto; }

.lb-dialog img{
  max-width:min(92vw,1100px);
  max-height:70vh;
  border-radius:14px;
  border:1px solid #333;
  background:#000;
  box-shadow:0 20px 60px rgba(0,0,0,.9);
  opacity:0;
  transform:translateY(12px) scale(.98);
  animation:pop .28s cubic-bezier(.2,.8,.2,1) .05s forwards;
}

.lb-caption{
  margin-top:12px;
  max-width:min(92vw,1100px);
  background:rgba(10,10,10,.7);
  border:1px solid #2a2a2a;
  padding:12px 14px; border-radius:12px; color:var(--sub)
}
.lb-title{font-weight:800;color:#fff;margin-bottom:4px}
.lb-desc{font-size:14px}

.lb-close{
  position:absolute; top:16px; right:16px;
  height:36px; width:36px; border-radius:10px;
  border:1px solid #333;
  background:#111; color:#fff; font-weight:800; cursor:pointer;
  z-index:10;
  transition:filter .2s ease, transform .15s ease;
}
.lb-close:hover{ filter:brightness(1.15); transform:translateY(-1px) }

.lb-nav{
  position:absolute; inset:0; display:flex; align-items:center; justify-content:space-between;
  padding:24px; z-index:5;
}
.lb-prev,.lb-next{
  height:42px; width:42px; border-radius:12px; border:1px solid #333;
  background:#111; color:#fff; font-weight:900; cursor:pointer; opacity:.95;
  transition:filter .2s ease, transform .15s ease;
}
.lb-prev:hover,.lb-next:hover{ filter:brightness(1.15); transform:translateY(-1px) }

/* Animations */
@keyframes ping{0%{transform:scale(.6);opacity:.7}80%,100%{transform:scale(1.6);opacity:0}}
@keyframes fade{to{opacity:1}}
@keyframes pop{to{opacity:1;transform:translateY(0) scale(1)}}

/* Apparitions */
[data-animate="fade-up"]{opacity:0;transform:translateY(12px);transition:opacity .55s ease, transform .55s ease}
[data-animate="fade-up"].in-view{opacity:1;transform:translateY(0)}
[data-animate="stagger"] > *{opacity:0;transform:translateY(12px)}
[data-animate="stagger"].in-view > *{opacity:1;transform:translateY(0)}
[data-animate="stagger"].in-view > *:nth-child(1){transition:.45s .05s ease}
[data-animate="stagger"].in-view > *:nth-child(2){transition:.45s .12s ease}
[data-animate="stagger"].in-view > *:nth-child(3){transition:.45s .19s ease}
[data-animate="stagger"].in-view > *:nth-child(4){transition:.45s .26s ease}
[data-animate="stagger"].in-view > *:nth-child(5){transition:.45s .33s ease}
[data-animate="stagger"].in-view > *:nth-child(6){transition:.45s .40s ease}

/* Focus visible */
a:focus-visible,button:focus-visible,.g-item:focus-visible{outline:2px solid #fff;outline-offset:2px}
