@import url('https://fonts.googleapis.com/css2?family=Cinzel+Decorative:wght@400;700&family=Cormorant+Garamond:wght@400;600&family=Merriweather:wght@400;700&display=swap');

:root{
  --bg:#1f1a17; --bg-grad:#2a211d;
  --accent:#f6fba7; --text:#e9e6df; --muted:#b9b2a9;
  --shadow:0 12px 40px rgba(0,0,0,.35);
  --radius:16px;

  /* aur pentru shimmer */
  --gold-1:#f6fba7;  --gold-2:#fff8c9;  --gold-3:#d4c96b;

  /* controale flotante */
  --fab-shift: 24px;          /* mutare spre stânga a butoanelor */
  --fab-blur: 14px;           /* blur sticlos pentru fab/popover */
  --popover-offset-y: 50px;   /* cât de jos apare conținutul */

  /* 🔥 Zoom titluri (nou) */
  --title-zoom-min: 0.985;
  --title-zoom-max: 1.03;
}

*{box-sizing:border-box}
html,body{height:100%}
body {
  margin:0;
  color:var(--text);
  background: linear-gradient(rgba(20,16,14,0.85), rgba(20,16,14,0.85));
  font-family: system-ui,-apple-system,Segoe UI,Roboto,Ubuntu,Cantarell,Arial,"Noto Sans";
  line-height:1.5;
  transition: background .4s ease, color .4s ease;
}

#bg-img{
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    linear-gradient(rgba(20,16,14,0.85), rgba(20,16,14,0.85)),
    url("/wiki/fundal.png") center / cover no-repeat;
  transform: translateZ(0);
}

/* Header sticky */
.header{
  position:sticky; top:0; z-index:10;
  background:linear-gradient(180deg, rgba(20,16,14,.9), rgba(20,16,14,.72));
  border-bottom:1px solid rgba(255,255,255,.06);
  transition: background .4s ease, border-color .4s ease;
}
.header-inner{
  max-width:min(1400px, 92vw); margin:0 auto; padding:14px 18px;
  display:flex; align-items:center; gap:14px;
}
.logo{width:120px;height:70px;flex:0 0 auto;filter:drop-shadow(0 0 10px rgba(246,251,167,.25))}

/* Titlu */
.title{
  margin:0;
  font-family:"Cinzel",serif;
  letter-spacing:.5px; font-weight:700;
  font-size:clamp(20px,2.4vw,28px);
  color:transparent;
  background-image: linear-gradient(90deg,var(--gold-1) 0%,var(--gold-2) 20%,var(--gold-3) 40%,var(--gold-1) 60%,var(--gold-2) 80%,var(--gold-1) 100%);
  -webkit-background-clip:text; background-clip:text;
  background-size:200% auto;
  animation: shimmer 10s linear infinite, glow 4s ease-in-out infinite alternate;
  text-shadow: 0 0 2px rgba(0,0,0,.35), 0 0 14px rgba(246,251,167,.15);
}
.subtitle{
  margin:0; font-size:.92rem; color:#d9d3c8;
  animation: glow-soft 6s ease-in-out infinite alternate;
  text-shadow: 0 0 2px rgba(0,0,0,.35), 0 0 10px rgba(246,251,167,.08);
}
@keyframes shimmer{ 0%{background-position:0% center} 100%{background-position:200% center} }
@keyframes glow{
  0%{ text-shadow:0 0 2px rgba(0,0,0,.35),0 0 10px rgba(246,251,167,.15),0 0 20px rgba(246,251,167,.10); filter: drop-shadow(0 0 0 rgba(246,251,167,0)); }
  100%{ text-shadow:0 0 3px rgba(0,0,0,.35),0 0 18px rgba(246,251,167,.3),0 0 30px rgba(246,251,167,.2); filter: drop-shadow(0 0 6px rgba(246,251,167,.22)); }
}
@keyframes glow-soft{
  0%{ text-shadow:0 0 2px rgba(0,0,0,.35),0 0 6px rgba(246,251,167,.08); }
  100%{ text-shadow:0 0 2px rgba(0,0,0,.35),0 0 12px rgba(246,251,167,.16); }
}

/* Conținut */
.wrap{
  max-width:min(1400px, 92vw); margin:26px auto 120px; padding:0 18px;
  overflow: visible;
}
.panel{
  max-width:1350px; margin:0 auto;
  background: linear-gradient(180deg, rgba(255,255,255,.03), rgba(255,255,255,.01));
  border: 1px solid rgba(246,251,167,.35);
  border-radius: 12px;
  box-shadow: 0 0 14px rgba(246,251,167,.15);
  padding:22px 20px 140px;
  overflow:visible;
  transition: background .4s ease, border-color .4s ease, box-shadow .4s ease;
  position: relative;
}

/* ---------- Butoane icon reutilizabile (folosite peste tot) ---------- */
.icon-btn{
  display:inline-flex; align-items:center; justify-content:center;
  width:36px; height:36px; border-radius:12px;
  background:rgba(35,30,26,.9); color:var(--accent);
  border:1px solid rgba(246,251,167,.35); box-shadow: var(--shadow);
  cursor:pointer;
  transition: transform .15s ease, box-shadow .2s ease, background .3s ease, color .3s ease, border-color .3s ease;
  backdrop-filter: blur(var(--fab-blur)); -webkit-backdrop-filter: blur(var(--fab-blur));
}
.icon-btn:hover{ transform:translateY(-1px); box-shadow:0 0 12px rgba(246,251,167,.25); border-color:rgba(246,251,167,.45); }
.icon-btn i, .icon-btn svg{ pointer-events:none; line-height:1; font-size:16px; }

.intro-box {
  position: relative;
  max-width: 1350px;
  margin: 24px auto 14px;
  padding: 0px 18px;
  display: flex; align-items: center; gap: 10px;
  border: 1px solid rgba(246,251,167,.35);
  border-radius: 12px;
  background: rgba(35,30,26,.4);
  box-shadow: 0 0 14px rgba(246,251,167,.25);
  font-size: .95rem; text-align: center;
  transition: background .4s ease, border-color .4s ease, box-shadow .4s ease;
}
.intro-box i { color: var(--accent); font-size: 1.1rem; flex-shrink: 0; text-shadow: 0 0 6px rgba(246,251,167,.3); }
.intro {
  max-width:1350px; margin:24px auto 14px; padding:0 18px;
  font-size:.95rem; text-align:center; opacity: 1; transition: opacity 0.8s ease;
  background: linear-gradient(90deg, var(--gold-3), var(--gold-1), var(--gold-2), var(--gold-1), var(--gold-3));
  background-size: 300% auto; -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  text-shadow: 0 0 4px rgba(246,251,167,.18), 0 0 10px rgba(246,251,167,.12);
  animation: shimmer-intro 7.5s linear infinite, glow-intro 4s ease-in-out infinite alternate, intro-pop-move 600ms ease both;
  will-change: opacity, transform, filter;
}
.intro.is-hidden { opacity: 0; }
@keyframes shimmer-intro { 0%{background-position: 0% center;} 100%{background-position: 300% center;} }
@keyframes glow-intro{
  0%{ text-shadow:0 0 4px rgba(246,251,167,.18),0 0 10px rgba(246,251,167,.12),0 0 18px rgba(246,251,167,.08); transform: scale(1); filter: drop-shadow(0 0 0 rgba(246,251,167,0)); }
  100%{ text-shadow:0 0 6px rgba(246,251,167,.26),0 0 16px rgba(246,251,167,.2),0 0 24px rgba(246,251,167,.14); transform: scale(1.003); filter: drop-shadow(0 0 5px rgba(246,251,167,.22)); }
}
@keyframes intro-pop-move { 0%{ transform: translateY(8px) scale(.98);} 100%{ transform: translateY(0) scale(1);} }
@media (prefers-reduced-motion: reduce){ .intro{ animation:none!important; text-shadow:none; transition:none!important; } }

/* 🔁 GRID flexibil: până la 4 pe rând */
.img-block{
  margin: 40px auto;
  max-width: 1350px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); /* flexibil 1–4 */
  gap: 20px;
  justify-content: center;
  content-visibility: auto;
  contain-intrinsic-size: 800px 600px;
  justify-items: center;
}
@media (min-width: 1200px){
  .img-block{ grid-template-columns: repeat(4, 1fr); } /* forțează 4 pe ecrane late */
}

.img-block:last-of-type {
  margin-bottom: 140px;
}

/* 🔍 Titluri cu “breath” + zoom (nou) */
.img-title {
  font-family: 'Cinzel Decorative', serif;
  font-size: clamp(1rem, 1.2vw, 1.4rem);   /* puțin mai mic */
  margin: 20px auto;
  color: var(--accent);
  text-align: center;
  position: relative;
  line-height: 1.3;
  display: inline-block;                 /* păstrăm pt. transform */
  transform-origin: center;

  text-shadow: 0 0 6px rgba(246,251,167,.25);
  animation:
    goldenBreath 4s ease-in-out infinite,
    titlePulse 5.5s ease-in-out infinite;
}

@keyframes goldenBreath {
  0% {
    color: var(--accent);
    text-shadow: 0 0 6px rgba(246,251,167,.2),
                 0 0 12px rgba(246,251,167,.15);
    letter-spacing: 0px;
  }
  50% {
    color: #fff8c9;
    text-shadow: 0 0 12px rgba(246,251,167,.7),
                 0 0 24px rgba(246,251,167,.6),
                 0 0 40px rgba(246,251,167,.4);
    letter-spacing: 2px;
  }
  100% {
    color: var(--accent);
    text-shadow: 0 0 6px rgba(246,251,167,.2),
                 0 0 12px rgba(246,251,167,.15);
    letter-spacing: 0px;
  }
}

/* 🔥 zoom in/out */
@keyframes titlePulse{
  0%,100%{ transform: scale(var(--title-zoom-min)); }
  50%    { transform: scale(var(--title-zoom-max)); }
}

/* 🌞 Light theme pentru titluri */
body.light .img-title {
  text-shadow: 0 0 6px rgba(0,0,0,.15);
  animation:
    goldenBreathLight 4s ease-in-out infinite,
    titlePulse 5.5s ease-in-out infinite; /* menținem zoom și în light */
}

/* 🌞 Light theme pentru animația goldenBreath */
@keyframes goldenBreathLight {
  0% {
    color: var(--accent);
    text-shadow: 0 0 4px rgba(0,0,0,.15), 0 0 8px rgba(0,0,0,.1);
    letter-spacing: 0px;
  }
  50% {
    color: var(--gold-2);
    text-shadow: 0 0 10px rgba(0,0,0,.25), 0 0 18px rgba(0,0,0,.15);
    letter-spacing: 2px;
  }
  100% {
    color: var(--accent);
    text-shadow: 0 0 4px rgba(0,0,0,.15), 0 0 8px rgba(0,0,0,.1);
    letter-spacing: 0px;
  }
}

/* --- Card cu efect tilt + cadru auriu --- */
.tilt{
  display: inline-block;
  transform-style: preserve-3d;
  transform-origin: center;
  will-change: transform;
  contain: layout paint style;
  transition: transform .35s ease;
}

.frame{
  display: block;
  width: 100%;
  height: auto;
  margin: 0;
  border-radius: 16px;
  border: 2px solid rgba(246,251,167,.35);
  box-shadow:
    0 0 14px rgba(246,251,167,.25),
    0 10px 30px rgba(0,0,0,.5);
  backface-visibility: hidden;
  transform: translateZ(0);
  transition:
    box-shadow .35s ease,
    border-color .35s ease,
    transform .35s ease;
}

/* hover: ușor 3D + intensificare contur/glow */
.tilt:hover{
  transform: perspective(900px) rotateX(4deg) rotateY(-4deg) scale(1.02);
}

.tilt:hover .frame{
  border-color: rgba(246,251,167,.55);
  box-shadow:
    0 0 20px rgba(246,251,167,.35),
    0 20px 45px rgba(0,0,0,.65);
}

/* apariție lină la scroll */
.reveal{
  opacity: 0;
  transform: translateY(14px);
  transition: opacity .6s ease, transform .6s ease;
}
.reveal.visible{
  opacity: 1;
  transform: none;
}

.to-top{
  position:fixed; right:18px; bottom:18px; padding:10px 14px; border-radius:12px;
  background:rgba(35,30,26,.85); color:var(--accent); border:1px solid rgba(246,251,167,.35);
  box-shadow:var(--shadow); cursor:pointer; font-family:"Cinzel",serif; font-weight:700; display:none;
  transition: background .3s ease, border-color .3s ease, color .3s ease;
}
.to-top.show{display:inline-block}
.to-top:active{transform:translateY(1px)}
@media (prefers-reduced-motion: reduce){
  .tilt, .frame, .reveal, .title, .subtitle, .img-title{ transition:none !important; animation:none !important; }
  .title{ background-position: 100% center; }
}

.video-block{
  max-width: min(550px, 92vw);
  margin: 30px auto;
  background: linear-gradient(180deg, rgba(255,255,255,.03), rgba(255,255,255,.01));
  border: 2px solid rgba(255,255,255,.12);
  border-radius: calc(var(--radius) + 4px);
  box-shadow: var(--shadow);
  overflow: hidden;
  aspect-ratio: 16 / 9;
  position: relative;
  transition: background .4s ease, border-color .4s ease, box-shadow .4s ease;
}
.video-block iframe{ width:100%; height:100%; border:2px solid rgba(255,255,255,.12); border-radius:calc(var(--radius) + 4px); display:block; }

/* Side links */
.side-box.left {
  position: fixed; top: 50%; left: 20px; transform: translateY(-50%);
  width: 180px;
  background: linear-gradient(180deg, rgba(255,255,255,.03), rgba(255,255,255,.01));
  border: 2px solid rgba(255,255,255,.12);
  border-radius: calc(var(--radius) + 4px);
  box-shadow: var(--shadow);
  padding: 14px;
  display: flex; flex-direction: column; gap: 10px;
  z-index: 20;
  transition: background .4s ease, border-color .4s ease, box-shadow .4s ease;
}
@media (max-width: 992px){
  .side-box.left{ position: static; transform:none; width:auto; margin:10px 18px; }
}
.side-btn{
  display:flex; align-items:center; gap:10px; padding:10px 12px;
  font-family:"Cinzel",serif; font-size:.9rem; font-weight:600;
  border:1px solid rgba(246,251,167,.35); border-radius:10px;
  background:rgba(35,30,26,.85); color:var(--accent);
  cursor:pointer; text-decoration:none; transition:all .25s ease;
}
.side-btn img{ width:20px; height:20px; object-fit:contain; flex-shrink:0; }
.side-btn:hover{ background:rgba(246,251,167,.1); box-shadow:0 0 10px rgba(246,251,167,.35); transform:translateX(3px); }

.panel { position: relative; }

/* Search (fab + popover) */
.panel-search .search-fab{
  position: absolute; top: 10px; right: calc(10px + var(--fab-shift));
  display: inline-flex; align-items: center; justify-content: center;
  width: 36px; height: 36px; border-radius: 12px;
  background: rgba(35,30,26,.9); color: var(--accent);
  border: 1px solid rgba(246,251,167,.35); box-shadow: var(--shadow);
  cursor: pointer; transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease, background .3s ease, color .3s ease;
  backdrop-filter: blur(var(--fab-blur)); -webkit-backdrop-filter: blur(var(--fab-blur));
}
.panel-search .search-fab:hover{ transform: translateY(-1px); box-shadow:0 0 12px rgba(246,251,167,.25); border-color:rgba(246,251,167,.45); }

.panel-search .search-popover{
  position: absolute; top: var(--popover-offset-y); right: calc(56px + var(--fab-shift));
  display: flex; gap: 8px; align-items: center; padding: 10px;
  background: linear-gradient(180deg, rgba(255,255,255,.05), rgba(255,255,255,.02));
  border: 2px solid rgba(255,255,255,.12);
  border-radius: calc(var(--radius) - 4px);
  box-shadow: var(--shadow); z-index: 30;
  opacity: 0; transform: translateX(20px) scale(0.95); pointer-events: none;
  transition: opacity .3s ease, transform .3s ease, border-color .3s ease, box-shadow .3s ease, background .3s ease;
  backdrop-filter: blur(var(--fab-blur)); -webkit-backdrop-filter: blur(var(--fab-blur));
}
.panel-search .search-popover.show{ opacity: 1; transform: translateX(0) scale(1); pointer-events: auto; border-color: rgba(246,251,167,.35); box-shadow: 0 0 16px rgba(246,251,167,.25), var(--shadow); }

.panel-search .search-input{
  width:220px; padding:8px 10px;
  background:rgba(35,30,26,.85); color:var(--text);
  border:1px solid rgba(246,251,167,.35); border-radius:10px; outline:none;
  transition: background .3s ease, color .3s ease, border-color .3s ease;
}
.panel-search .actions{ display:inline-flex; align-items:center; gap:6px; }
/* folosim .icon-btn global pentru prev/next/close */
.panel-search .actions .icon-btn{ }

.panel-search .actions .count{ color: var(--muted); font-size: .9rem; }

/* Toast */
#toast-container{ position: fixed; top:20px; right:20px; display:flex; flex-direction:column; gap:10px; z-index:1000; }
.toast{
  background: rgba(35,30,26,.95); color: var(--accent);
  border: 1px solid rgba(246,251,167,.35); border-radius:10px;
  padding:10px 14px; font-family:"Cinzel",serif; font-size:.9rem;
  box-shadow:0 4px 12px rgba(0,0,0,.4); opacity:0; transform:translateY(-10px);
  animation: toast-in .35s ease forwards, toast-out .35s ease forwards 2.5s;
}
@keyframes toast-in { to { opacity:1; transform:translateY(0); } }
@keyframes toast-out { to { opacity:0; transform:translateY(-10px); } }

/* Audio list & player (muzica/ambient) */
.panel-audio .audio-fab{
  position:absolute; top:10px; right: calc(56px + var(--fab-shift));
  display:inline-flex; align-items:center; justify-content:center;
  width:36px; height:36px; border-radius:12px;
  background:rgba(35,30,26,.9); color:var(--accent);
  border:1px solid rgba(246,251,167,.35); box-shadow:var(--shadow);
  cursor:pointer; transition:transform .2s ease, box-shadow .2s ease, border-color .2s ease, background .3s ease, color .3s ease;
  backdrop-filter: blur(var(--fab-blur)); -webkit-backdrop-filter: blur(var(--fab-blur));
}
.panel-audio .audio-fab:hover{ transform:translateY(-1px); box-shadow:0 0 12px rgba(246,251,167,.25); border-color:rgba(246,251,167,.45); }

.panel-audio .audio-popover{
  position:absolute; top: var(--popover-offset-y); right: calc(112px + var(--fab-shift)); width:280px; max-height:320px;
  display:flex; flex-direction:column; padding:10px;
  background:linear-gradient(180deg, rgba(255,255,255,.05), rgba(255,255,255,.02));
  border:2px solid rgba(255,255,255,.12); border-radius:calc(var(--radius) - 4px);
  box-shadow:var(--shadow); z-index:31;
  contain:layout paint; overflow:hidden; overflow-anchor:none; scrollbar-gutter:stable both-edges;
  opacity:0; transform:translateX(20px) scale(.95); pointer-events:none;
  transition:opacity .3s ease, transform .3s ease, border-color .3s ease, box-shadow .3s ease, background .3s ease;
  backdrop-filter: blur(var(--fab-blur)); -webkit-backdrop-filter: blur(var(--fab-blur));
}
.panel-audio .audio-popover.show{ opacity:1; transform:translateX(0) scale(1); pointer-events:auto; border-color:rgba(246,251,167,.35); box-shadow:0 0 16px rgba(246,251,167,.25), var(--shadow); }
.audio-header{ display:flex; align-items:center; justify-content:space-between; gap:10px; padding-bottom:4px; border-bottom:1px solid rgba(255,255,255,.08); flex-shrink:0; }
.audio-header strong{ font-family:"Cinzel",serif; color:var(--accent); }
.btn-audio-close{ background:rgba(35,30,26,.85); color:var(--accent); border:1px solid rgba(246,251,167,.35); border-radius:8px; cursor:pointer; padding:4px 8px; transition: background .3s ease, color .3s ease, border-color .3s ease; }
.audio-list{ list-style:none; margin:0; padding:0 8px 0 0; flex:1 1 auto; overflow-y:auto; overscroll-behavior:contain; scrollbar-width: thin; scrollbar-color: rgba(246,251,167,.4) rgba(35,30,26,.6); }
.audio-list::-webkit-scrollbar{ width:10px; }
.audio-list::-webkit-scrollbar-track{ background:rgba(35,30,26,.5); border-radius:10px; }
.audio-list::-webkit-scrollbar-thumb{ background:rgba(246,251,167,.35); border-radius:10px; border:2px solid rgba(35,30,26,.6); box-shadow:0 0 6px rgba(246,251,167,.25); }
.audio-list::-webkit-scrollbar-thumb:hover{ background:rgba(246,251,167,.55); }
.audio-list li{
  padding:8px 10px; margin-bottom:6px; border:1px solid rgba(246,251,167,.2); border-radius:10px;
  background:rgba(35,30,26,.7); color:var(--text); cursor:pointer;
  transition: box-shadow .2s ease, border-color .2s ease, background-color .2s ease;
  display:-webkit-box; -webkit-box-orient:vertical; -webkit-line-clamp:2; overflow:hidden; white-space:normal;
}
.audio-list li:hover{ background:rgba(35,30,26,.82); box-shadow:0 0 10px rgba(246,251,167,.25); border-color:rgba(246,251,167,.45); }
.audio-list li.active{ border-color:rgba(246,251,167,.65); box-shadow:0 0 12px rgba(246,251,167,.35); color:var(--accent); }
.audio-controls{ display:flex; align-items:center; gap:10px; flex-wrap:wrap; padding-top:6px; border-top:1px solid rgba(255,255,255,.08); flex-shrink:0; }
.btn-audio-play{ background:rgba(35,30,26,.85); color:var(--accent); border:1px solid rgba(246,251,167,.35); border-radius:10px; cursor:pointer; padding:6px 10px; transition: background .3s ease, color .3s ease, border-color .3s ease; }
.vol-wrap{ display:inline-flex; align-items:center; gap:6px; }

/* slider volum */
.audio-volume{
  -webkit-appearance:none; appearance:none; width:120px; height:6px; border-radius:10px;
  background:rgba(35,30,26,.7); border:1px solid rgba(246,251,167,.35); box-shadow: inset 0 0 6px rgba(0,0,0,.6); cursor:pointer;
}
.audio-volume::-webkit-slider-runnable-track{ height:6px; border-radius:10px; background:linear-gradient(90deg, rgba(246,251,167,.6) 0%, rgba(212,201,107,.9) 100%); }
.audio-volume::-moz-range-track{ height:6px; border-radius:10px; background:linear-gradient(90deg, rgba(246,251,167,.6) 0%, rgba(212,201,107,.9) 100%); }
.audio-volume::-webkit-slider-thumb{
  -webkit-appearance:none; appearance:none; width:14px; height:14px; border-radius:50%;
  background:var(--accent); border:1px solid rgba(246,251,167,.6); box-shadow:0 0 6px rgba(246,251,167,.4);
  margin-top:-4px; cursor:grab; transition:background .2s ease, transform .2s ease;
}
.audio-volume::-webkit-slider-thumb:active{ background:#fff8c9; transform:scale(1.15); }
.audio-volume::-moz-range-thumb{
  width:14px; height:14px; border-radius:50%;
  background:var(--accent); border:1px solid rgba(246,251,167,.6); box-shadow:0 0 6px rgba(246,251,167,.4);
  cursor:grab; transition:background .2s ease, transform .2s ease;
}
.audio-volume::-moz-range-thumb:active{ background:#fff8c9; transform:scale(1.15); }
.loop-wrap{ display:inline-flex; align-items:center; gap:6px; }
.now-playing{ color:var(--muted); font-size:.9rem; }

.theme-toggle {
  position: absolute; top: 10px; right: calc(100px + var(--fab-shift));
  display: inline-flex; align-items:center; justify-content:center;
  width:36px; height:36px; border-radius:12px;
  background: rgba(35,30,26,.9); color: var(--accent);
  border: 1px solid rgba(246,251,167,.35); box-shadow: var(--shadow);
  cursor: pointer; transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease, background .3s ease, color .3s ease;
  font-size: 1rem;
  backdrop-filter: blur(var(--fab-blur)); -webkit-backdrop-filter: blur(var(--fab-blur));
}
.theme-toggle:hover { transform: translateY(-1px); box-shadow: 0 0 12px rgba(246,251,167,.25); border-color: rgba(246,251,167,.45); }

/* 🌞 Light theme */
body.light {
  --bg:#fefdf8; --bg-grad:#f4f1e7;
  --accent:#6b4e16; --text:#2b2620; --muted:#6a6357;
  --shadow:0 12px 40px rgba(0,0,0,.15);
  --gold-1:#a77d2d; --gold-2:#d4b45a; --gold-3:#f0e2b5;
  background: linear-gradient(rgba(255,255,255,0.92), rgba(255,255,255,0.92));
}
body.light #bg-img{
  background:
    linear-gradient(rgba(255,255,255,0.92), rgba(255,255,255,0.92)),
    url("/wiki/fundal.png") center / cover no-repeat;
}
body.light .header{
  background:linear-gradient(180deg, rgba(255,255,255,.92), rgba(255,255,255,.78));
  border-bottom:1px solid rgba(0,0,0,.08);
}
body.light .panel{ background:linear-gradient(180deg, rgba(0,0,0,.02), rgba(0,0,0,.01)); border:1px solid rgba(0,0,0,.15); box-shadow:0 0 14px rgba(0,0,0,.08); }
body.light .video-block{ background: linear-gradient(180deg, rgba(0,0,0,.03), rgba(0,0,0,.015)); border: 2px solid rgba(0,0,0,.12); box-shadow: 0 12px 30px rgba(0,0,0,.12); }
body.light .side-box.left{ background: linear-gradient(180deg, rgba(0,0,0,.03), rgba(0,0,0,.01)); border: 2px solid rgba(0,0,0,.12); box-shadow: 0 12px 30px rgba(0,0,0,.12); }
body.light .side-btn{ background:rgba(255,255,255,.9); color:var(--text); border:1px solid rgba(0,0,0,.18); }
body.light .side-btn:hover{ background:rgba(0,0,0,.06); box-shadow:0 0 10px rgba(0,0,0,.15); }
body.light .intro-box{ background: rgba(255,255,255,.65); border:1px solid rgba(0,0,0,.15); box-shadow: 0 0 14px rgba(0,0,0,.08); }

/* Mic polish pentru Light (Lore) */
body.light .panel-lore .lore-popover.show{
  border-color: rgba(0,0,0,.18);
  box-shadow: 0 0 16px rgba(0,0,0,.12), var(--shadow);
}

/* Firefox: thumb TTS în light */
body.light .lore-tts .tts-volume::-moz-range-thumb{
  box-shadow: 0 0 10px rgba(212,201,107,.55), 0 0 0 3px rgba(255,255,255,.55);
}

/* Light pentru fab/popover */
body.light .panel-search .search-fab,
body.light .panel-audio .audio-fab,
body.light .theme-toggle,
body.light .panel-lore .lore-fab{
  background: rgba(255,255,255,.92); color: var(--text); border: 1px solid rgba(0,0,0,.2);
}
body.light .panel-search .search-popover,
body.light .panel-audio .audio-popover{ background:linear-gradient(180deg, rgba(0,0,0,.04), rgba(0,0,0,.02)); border:2px solid rgba(0,0,0,.12); }
body.light .panel-search .search-input,
body.light .btn-audio-close,
body.light .btn-audio-play{ background:rgba(255,255,255,.9); color:var(--text); border:1px solid rgba(0,0,0,.25); }

/* ---------- Light pentru TOATE .icon-btn ---------- */
body.light .icon-btn{
  background:rgba(255,255,255,.92); color:var(--text); border:1px solid rgba(0,0,0,.25);
  box-shadow: 0 12px 40px rgba(0,0,0,.12);
}
body.light .icon-btn:hover{
  border-color: rgba(0,0,0,.30);
  box-shadow: 0 0 12px rgba(0,0,0,.12);
}

/* Poveste (Lore) – FAB */
.panel-lore .lore-fab{
  position:absolute; top:10px; right: calc(148px + var(--fab-shift));
}
.panel-lore .lore-fab.icon-btn{}

/* Lore Popover */
.panel-lore .lore-popover{
  position:absolute; top: var(--popover-offset-y); right: calc(20px + var(--fab-shift)); width:500px; max-height:500px;
  display:flex; flex-direction:column; padding:16px 18px;
  background:linear-gradient(180deg, rgba(255,255,255,.05), rgba(255,255,255,.02));
  border:2px solid rgba(255,255,255,.12); border-radius:16px;
  box-shadow:0 0 20px rgba(246,251,167,.25), var(--shadow);
  z-index:31;
  opacity:0; transform:translateY(-20px) scale(.97); pointer-events:none;
  transition: opacity .3s ease, transform .3s ease, border-color .3s ease, box-shadow .3s ease, background .3s ease;
  backdrop-filter: blur(var(--fab-blur)); -webkit-backdrop-filter: blur(var(--fab-blur));
}
.panel-lore .lore-popover.show { opacity:1; transform:translateY(0) scale(1); pointer-events:auto; border-color:rgba(246,251,167,.35); box-shadow:0 0 16px rgba(246,251,167,.25), var(--shadow); }

/* Lore Header */
.lore-header { display:flex; align-items:center; justify-content:space-between; gap:10px; padding-bottom:10px; border-bottom:1px solid rgba(255,255,255,.1); flex-shrink:0; }
.lore-header strong{ font-family:"Cinzel",serif; color:var(--accent); font-size:1.1rem; }
.btn-lore-close.icon-btn{}

/* Lore TTS */
.lore-tts { display:flex; align-items:center; gap:10px; margin-top:10px; padding-top:8px; border-top:1px solid rgba(255,255,255,.08); flex-shrink:0; }
.panel-lore .btn-tts.icon-btn{}
.lore-tts .vol-wrap{ display:inline-flex; align-items:center; gap:8px; }

body.light .audio-list::-webkit-scrollbar-track{background:rgba(0,0,0,.08)}
body.light .audio-list::-webkit-scrollbar-thumb{ background:rgba(0,0,0,.35); border:2px solid rgba(255,255,255,.6); }
body.light .audio-list li{ background:rgba(255,255,255,.9); border-color:rgba(0,0,0,.12); }
body.light .audio-list li:hover{ background:rgba(255,255,255,1); border-color:rgba(0,0,0,.2); box-shadow:0 0 10px rgba(0,0,0,.12); }
body.light .toast{ background: rgba(255,255,255,.95); color: var(--text); border: 1px solid rgba(0,0,0,.15); box-shadow: 0 4px 12px rgba(0,0,0,.15); }
body.light .to-top{ background:rgba(255,255,255,.9); color:var(--text); border:1px solid rgba(0,0,0,.18); }

/* Poveste (Lore) – popover & conținut (duplicat menținut pentru compat) */
.panel-lore .lore-fab{
  position:absolute; top:10px; right: calc(148px + var(--fab-shift));
  display:inline-flex; align-items:center; justify-content:center;
  width:36px; height:36px; border-radius:12px;
  background:rgba(35,30,26,.9); color:var(--accent);
  border:1px solid rgba(246,251,167,.35); box-shadow:var(--shadow);
  cursor:pointer;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease, background .3s ease, color .3s ease;
  backdrop-filter: blur(var(--fab-blur)); -webkit-backdrop-filter: blur(var(--fab-blur));
}
.panel-lore .lore-fab:hover{ transform:translateY(-1px); box-shadow:0 0 12px rgba(246,251,167,.25); border-color:rgba(246,251,167,.45); }

.panel-lore .lore-popover{
  position:absolute; top: var(--popover-offset-y); right: calc(20px + var(--fab-shift)); width:500px; max-height:500px;
  display:flex; flex-direction:column; padding:16px 18px;
  background:linear-gradient(180deg, rgba(255,255,255,.05), rgba(255,255,255,.02));
  border:2px solid rgba(255,255,255,.12); border-radius:16px;
  box-shadow:0 0 20px rgba(246,251,167,.25), var(--shadow);
  z-index:31;
  opacity:0; transform:translateY(-20px) scale(.97); pointer-events:none;
  transition: opacity .3s ease, transform .3s ease, border-color .3s ease, box-shadow .3s ease, background .3s ease;
  backdrop-filter: blur(var(--fab-blur)); -webkit-backdrop-filter: blur(var(--fab-blur));
}
.panel-lore .lore-popover.show { opacity: 1; transform: translateY(0) scale(1); pointer-events: auto; border-color: rgba(246, 251, 167, .35); box-shadow: 0 0 16px rgba(246, 251, 167, .25), var(--shadow); }
.lore-header { display:flex; align-items:center; justify-content:space-between; gap:10px; padding-bottom:10px; border-bottom:1px solid rgba(255,255,255,.1); flex-shrink:0; }
.lore-header strong{ font-family:"Cinzel",serif; color:var(--accent); font-size:1.1rem; }

/* ✔ Lore buttons folosesc icon-btn */
.btn-lore-close{ padding:0; }
.panel-lore .btn-lore-close.icon-btn{ width:36px; height:36px; }

.lore-content { flex:1 1 auto; overflow-y:auto; overscroll-behavior:contain; font-size:1rem; line-height:1.5; color:var(--text); padding-right:6px; }
.lore-content::-webkit-scrollbar { width: 10px; }
.lore-content::-webkit-scrollbar-thumb { background: rgba(246, 251, 167, .35); border-radius: 10px; }

.lore-tts { display:flex; align-items:center; gap:10px; margin-top:10px; padding-top:8px; border-top:1px solid rgba(255, 255, 255, .08); flex-shrink:0; }
/* ✔ Play/Pause ca icon-btn */
.panel-lore .btn-tts.icon-btn{ width:36px; height:36px; }
.lore-tts .vol-wrap{ display:inline-flex; align-items:center; gap:8px; }

/* === LORE: volum stil "auriu + glow" (dark & light) === */
.lore-tts .tts-volume{
  -webkit-appearance:none; appearance:none;
  width:180px; height:8px; border-radius:999px;
  background: transparent; border:none; outline:none; cursor:pointer;
}
/* Track (WebKit) */
.lore-tts .tts-volume::-webkit-slider-runnable-track{
  height:8px; border-radius:999px;
  background:linear-gradient(90deg, var(--gold-3) 0%, var(--gold-1) 50%, var(--gold-2) 100%);
  box-shadow: inset 0 0 0 1px rgba(246,251,167,.55), inset 0 2px 6px rgba(0,0,0,.5);
}
/* Track (Firefox) */
.lore-tts .tts-volume::-moz-range-track{
  height:8px; border-radius:999px;
  background:linear-gradient(90deg, var(--gold-3) 0%, var(--gold-1) 50%, var(--gold-2) 100%);
  box-shadow: inset 0 0 0 1px rgba(246,251,167,.55), inset 0 2px 6px rgba(0,0,0,.5);
}
/* Thumb (WebKit) */
.lore-tts .tts-volume::-webkit-slider-thumb{
  -webkit-appearance:none; appearance:none;
  width:18px; height:18px; border-radius:50%;
  background: radial-gradient(circle at 35% 35%, #fff8c9 0%, var(--gold-1) 55%, var(--gold-3) 100%);
  border:1px solid rgba(246,251,167,.8);
  box-shadow: 0 0 10px rgba(246,251,167,.65), 0 0 0 3px rgba(35,30,26,.35);
  margin-top:-5px; cursor:grab; transition:transform .15s ease, box-shadow .15s ease;
}
.lore-tts .tts-volume::-webkit-slider-thumb:hover{
  box-shadow: 0 0 12px rgba(246,251,167,.85), 0 0 0 3px rgba(35,30,26,.35);
}
.lore-tts .tts-volume::-webkit-slider-thumb:active{ transform:scale(1.1); }
/* Thumb (Firefox) */
.lore-tts .tts-volume::-moz-range-thumb{
  width:18px; height:18px; border-radius:50%;
  background: radial-gradient(circle at 35% 35%, #fff8c9 0%, var(--gold-1) 55%, var(--gold-3) 100%);
  border:1px solid rgba(246,251,167,.8);
  box-shadow: 0 0 10px rgba(246,251,167,.65), 0 0 0 3px rgba(35,30,26,.35);
  cursor:grab; transition:transform .15s ease, box-shadow .15s ease;
}
.lore-tts .tts-volume::-moz-range-thumb:active{ transform:scale(1.1); }

/* Focus accesibil */
.lore-tts .tts-volume:focus-visible{
  outline:2px solid rgba(246,251,167,.7);
  outline-offset:2px;
}

/* 🌞 Light: ajustări subtile pentru separare pe fundal deschis */
body.light .lore-tts .tts-volume::-webkit-slider-thumb,
body.light .lore-tts .tts-volume::-moz-range-thumb{
  box-shadow: 0 0 10px rgba(212,201,107,.55), 0 0 0 3px rgba(255,255,255,.55);
}
body.light .lore-tts .tts-volume::-webkit-slider-runnable-track,
body.light .lore-tts .tts-volume::-moz-range-track{
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.22), inset 0 2px 5px rgba(0,0,0,.12);
}

/* ICONS */
.inline-icon { width: 32px; height: auto; vertical-align: middle; margin-left: 4px; transition: filter .3s ease; }
.icon-thyros { filter: drop-shadow(0 0 4px rgba(255, 0, 0, .7)) drop-shadow(0 0 8px rgba(255, 0, 0, .5)); }
.icon-aquaris{ filter: drop-shadow(0 0 4px rgba(0, 128, 255, .7)) drop-shadow(0 0 8px rgba(0, 128, 255, .5)); }

/* Canvas efecte */
#bg-fx{
  position: fixed; inset: 0; z-index: 1;
  pointer-events: none; mix-blend-mode: normal; opacity: .55;
  will-change: transform; transform: translateZ(0);
}
body.light #bg-fx{ mix-blend-mode: normal; opacity:.45; }
@media (prefers-reduced-motion: reduce){ #bg-fx{ display:none !important; } }

/* Filter bar */
.filter-bar{
  max-width:min(1400px,92vw);
  margin:40px auto 8px;
  padding:8px;
  display:flex; justify-content:center; gap:10px; flex-wrap:wrap;
  background: linear-gradient(180deg, rgba(255,255,255,.03), rgba(255,255,255,.01));
  border:1px solid rgba(246,251,167,.35);
  border-radius:12px; box-shadow:0 0 14px rgba(246,251,167,.15);
}
.filter-btn{
  padding:8px 14px;
  font-family:"Cinzel",serif; font-weight:700; font-size:.95rem;
  color:var(--accent); background:rgba(35,30,26,.85);
  border:1px solid rgba(246,251,167,.35); border-radius:10px;
  cursor:pointer; transition:transform .15s ease, box-shadow .2s ease, background .3s ease, color .3s ease, border-color .3s ease;
}
.filter-btn:hover{ transform:translateY(-1px); box-shadow:0 0 12px rgba(246,251,167,.25); border-color:rgba(246,251,167,.45); }
.filter-btn.is-active{ background:rgba(246,251,167,.1); box-shadow:0 0 10px rgba(246,251,167,.35); }
.img-item{
  transition: opacity .25s ease, transform .25s ease;
  text-align: center;
}
.img-item.is-hidden{ opacity:0; transform:scale(.985); pointer-events:none; height:0; margin:0; overflow:hidden; }
 body.light .filter-bar{ background: linear-gradient(180deg, rgba(0,0,0,.02), rgba(0,0,0,.01)); border:1px solid rgba(0,0,0,.15); box-shadow:0 0 14px rgba(0,0,0,.08); }
 body.light .filter-btn{ background:rgba(255,255,255,.92); color:var(--text); border:1px solid rgba(0,0,0,.2); }
 body.light .filter-btn.is-active{ background:rgba(0,0,0,.06); box-shadow:0 0 10px rgba(0,0,0,.12); }

.img-item { display:none; }
.img-item.show { display:block; }

/* mărime iconițe FA în acțiunile de căutare */
.panel-search .actions .icon-btn i { font-size: 16px; line-height: 1; }

.img-popup {
  position: fixed;
  inset: 0;
  display: none;
  justify-content: center;
  align-items: center;
  background: rgba(0,0,0,.8);
  z-index: 999;
}
.img-popup.show { display: flex; }

/* cutia principală */
.popup-content {
  background: rgba(35,30,26,.95);
  border: 2px solid rgba(246,251,167,.4);
  border-radius: 16px;
  box-shadow: 0 0 20px rgba(246,251,167,.25), 0 20px 45px rgba(0,0,0,.65);
  width: min(900px, 92vw);
  max-height: min(80vh, 720px);
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  animation: popup-in .3s ease;
  overflow: hidden;
}

/* buton închidere */
.popup-close {
  align-self: flex-end;
  background: none;
  border: none;
  font-size: 2rem;
  line-height: 1;
  color: var(--accent);
  cursor: pointer;
}

/* layout imagine | separator | text */
.popup-body {
  display: grid;
  grid-template-columns: auto 1px 1fr;
  gap: 18px;
  margin-top: 8px;
  min-height: 0;
}

/* separator vertical discret */
.popup-body::before {
  content: "";
  grid-column: 2 / 3;
  grid-row: 1;
  width: 1px;
  background: linear-gradient(
    to bottom,
    transparent 0%,
    rgba(246,251,167,.25) 15%,
    rgba(246,251,167,.35) 50%,
    rgba(246,251,167,.25) 85%,
    transparent 100%
  );
  border-radius: 1px;
}

/* imagine stânga */
.popup-left { grid-column: 1 / 2; align-self: start; }
.popup-left img {
  display: block;
  max-width: 300px;
  width: 100%;
  height: auto;
}

/* panoul din dreapta */
.popup-right {
  grid-column: 3 / 4;
  color: var(--text);
  font-size: 1rem;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 0;
  max-height: calc(80vh - 84px);
  overflow: hidden;
}

/* titlu cu border jos */
.popup-title-box {
  text-align: center;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(246,251,167,.35);
  flex: 0 0 auto;
}
.popup-right h2 {
  font-family: "Cinzel", serif;
  color: var(--accent);
  margin: 0;
  font-size: 1.4rem;
}

/* descriere scrollabilă */
.popup-desc-box {
  flex: 1 1 auto;
  padding: 12px 14px;
  border: 1px solid rgba(246,251,167,.25);
  border-radius: 10px;
  background: rgba(0,0,0,.25);
  overflow-y: auto;
  line-height: 1.5;
  min-height: 0;
  text-align: left;
}

/* icon info centrat */
.popup-desc-box .fa-circle-info {
  display: block;
  text-align: center;
  margin-bottom: 10px;
  font-size: 1.1rem;
  opacity: .9;
  color: var(--accent);
}

/* ===== Secțiuni cu titlu centrat și linii fade ===== */
.section { margin: 10px 0 16px; }

.section-title {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin: 8px 0 10px;
  font-family: "Cinzel", serif;
  font-size: 1.05rem;
  letter-spacing: .06em;
  color: var(--accent);
  text-transform: uppercase;
  text-align: center;
}
.section-title::before,
.section-title::after{
  content:"";
  height: 1px;
  flex: 1 1;
  background: linear-gradient(
    to right,
    rgba(246,251,167,0) 0%,
    rgba(246,251,167,.55) 50%,
    rgba(246,251,167,0) 100%
  );
  border-radius: 1px;
}

.section-body {
  text-align: center;
  line-height: 1.5;
  color: var(--text);
}
.section-body * { color: inherit; }

/* grid pentru iteme drop (imagini) */
.drop-grid{
  display: inline-grid;
  grid-template-columns: repeat(auto-fit, minmax(28px, auto));
  gap: 6px;
  justify-content: center;
  align-items: center;
}
.drop-grid img{
  width: 28px;
  height: 28px;
  display: block;
  border-radius: 4px;
  box-shadow: 0 1px 6px rgba(0,0,0,.35);
}

/* variantă text pe linii dacă nu-s imagini în data-drop */
.drop-list{
  display: inline-flex;
  flex-direction: column;
  gap: 4px;
}

/* scroll custom */
.popup-desc-box::-webkit-scrollbar { width: 8px; }
.popup-desc-box::-webkit-scrollbar-track { background: rgba(0,0,0,.2); border-radius: 8px; }
.popup-desc-box::-webkit-scrollbar-thumb { background: rgba(246,251,167,.5); border-radius: 8px; }
.popup-desc-box::-webkit-scrollbar-thumb:hover { background: rgba(246,251,167,.7); }

/* animație apariție */
@keyframes popup-in {
  from { transform: scale(.9); opacity: 0; }
  to   { transform: scale(1); opacity: 1; }
}

/* 🌞 Light theme */
body.light .img-popup { background: rgba(255,255,255,.75); }

body.light .popup-content {
  background: rgba(255,255,255,.96);
  border: 1px solid rgba(0,0,0,.15);
  box-shadow: 0 12px 30px rgba(0,0,0,.15), 0 0 16px rgba(0,0,0,.08);
}

body.light .popup-body::before {
  background: linear-gradient(
    to bottom,
    transparent 0%,
    rgba(0,0,0,.12) 15%,
    rgba(0,0,0,.18) 50%,
    rgba(0,0,0,.12) 85%,
    transparent 100%
  );
}
body.light .popup-title-box { border-bottom: 1px solid rgba(0,0,0,.15); }
body.light .popup-right     { color: var(--text); }
body.light .popup-right h2  { color: var(--accent); }

body.light .popup-desc-box {
  background: rgba(255,255,255,.65);
  border: 1px solid rgba(0,0,0,.15);
}
body.light .popup-desc-box::-webkit-scrollbar-track { background: rgba(0,0,0,.08); }
body.light .popup-desc-box::-webkit-scrollbar-thumb { background: rgba(0,0,0,.35); }

body.light .popup-close { color: var(--text); }

/* linii fade – variantă light */
body.light .section-title::before,
body.light .section-title::after{
  background: linear-gradient(
    to right,
    rgba(0,0,0,0) 0%,
    rgba(0,0,0,.25) 50%,
    rgba(0,0,0,0) 100%
  );
}

/* tranziții line */
.img-popup,
.popup-content,
.popup-title-box,
.popup-desc-box,
.section-title::before,
.section-title::after{
  transition: background .3s ease, border-color .3s ease, box-shadow .3s ease, color .3s ease, opacity .3s ease;
}

/* 📱 Mobile */
@media (max-width: 700px){
  .popup-body{
    grid-template-columns: 1fr;
    gap: 12px;
  }
  .popup-body::before{ display: none; }
  .popup-left { justify-self: center; }
  .popup-left img{ max-width: min(100%, 480px); height: auto; }
  .popup-right{ max-height: none; }
}

/* text accentuit în descriere -> alb (nu auriu) */
.popup-desc-box strong { color: var(--text); }

/* container de rânduri */
.drop-rows{
  display: inline-flex;
  flex-direction: column;
  gap: 6px;
  align-items: center;
}

/* rând icon + text */
.drop-row{
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .95rem;
  line-height: 1.3;
  color: var(--text);
}

/* imaginea din rând */
.drop-row img{
  width: 28px;
  height: 28px;
  border-radius: 4px;
  box-shadow: 0 1px 6px rgba(0,0,0,.35);
  flex: 0 0 28px;
}

/* numele itemului */
.drop-row span{
  text-align: left;
  white-space: nowrap;
}

/* ===== Tooltip pentru iconițele din DROP ===== */
.a2g-tooltip{
  position: fixed;
  z-index: 10000;
  pointer-events: none;
  background: rgba(20,16,14,.95);
  color: #fff;
  font-size: 13px;
  line-height: 1.35;
  padding: 8px 10px;
  border-radius: 8px;
  border: 1px solid rgba(246,251,167,.35);
  box-shadow: 0 8px 24px rgba(0,0,0,.35);
  max-width: 320px;
  display: none;
  transform: none;
  white-space: normal;
  word-wrap: break-word;
}
body.light .a2g-tooltip{
  background: rgba(255,255,255,.98);
  color:#111;
  border: 1px solid rgba(0,0,0,.15);
  box-shadow: 0 8px 20px rgba(0,0,0,.15);
}

/* ===== A2G Cookie Consent (popup performant) ===== */

/* Backdrop: fără blur; animăm doar opacity */
.a2g-cc-backdrop {
  position: fixed; inset: 0;
  background: rgba(10,12,24,.55);
  z-index: 9998;
  opacity: 0; pointer-events: none;
  transition: opacity .2s ease;
  will-change: opacity;
}
.a2g-cc-backdrop.is-open { opacity: 1; pointer-events: auto; }

/* Modal */
.a2g-cc-modal {
  position: fixed; left: 50%; top: 50%;
  transform: translate(-50%,-46%) translateZ(0);
  width: min(720px, 92vw); z-index: 9999;
  color: #e8ebff; background: rgba(20,24,54,.85);
  overflow: hidden; opacity: 0; pointer-events: none;
  transition: opacity .2s ease, transform .2s ease;
  border-radius: 10px;
  border: 1px solid rgba(246,251,167,.25);
  box-shadow: 0 20px 60px rgba(0,0,0,.45), 0 0 8px rgba(0,128,255,.15);
  will-change: transform, opacity;
}
.a2g-cc-modal.is-open { opacity: 1; pointer-events: auto; transform: translate(-50%,-50%) translateZ(0); }

.a2g-cc-head {
  padding: 1rem 1.2rem;
  border-bottom: 1px solid rgba(95,120,255,.18);
  display: flex; align-items: center; gap: .75rem;
}
.a2g-cc-emoji { font-size: 1.25rem; }
.a2g-cc-title { margin: 0; font-size: 1.05rem; font-weight: 700; letter-spacing: .2px; }

/* Banner */
.a2g-cc-banner {
  position: relative;
  width: 100%; max-height: 137px; overflow: hidden;
  display: flex; justify-content: center; align-items: center;
  background: rgba(10,12,24,0.35);
  border-radius: 10px;
  border: 1px solid rgba(246,251,167,.25);
  box-shadow: 0 6px 18px rgba(0,0,0,.25), 0 0 6px rgba(0,128,255,.12);
}
.a2g-cc-banner img { width: 100%; height: auto; object-fit: cover; }

/* Avatar pe banner */
.a2g-cc-avatar {
  position: absolute;
  bottom: 12px; left: 20px;
  width: 72px; height: 72px; border-radius: 50%;
  border: 3px solid #fff; overflow: hidden;
  box-shadow: 0 6px 18px rgba(0,0,0,.35);
  background: #222;
}
.a2g-cc-avatar img { width: 100%; height: 100%; object-fit: cover; }

.a2g-cc-body { padding: 1rem 1.2rem; display: grid; gap: 1rem; }
.a2g-cc-desc { margin: 0; color: #b9c0ff; line-height: 1.5; }
.a2g-cc-desc a { color: #93b1ff; text-decoration: underline; }

/* Grup categorii */
.a2g-cc-cats {
  display: grid; gap: .6rem;
  border-radius: 10px;
  border: 1px solid rgba(246,251,167,.25);
  box-shadow: 0 6px 18px rgba(0,0,0,.22), 0 0 6px rgba(0,128,255,.10);
}
.a2g-cc-row {
  display: grid; grid-template-columns: 1fr auto; align-items: center; gap: .75rem;
  padding: .7rem .8rem;
  border: 1px solid rgba(95,120,255,.18);
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(40,46,92,.45), rgba(26,30,64,.35));
}
.a2g-cc-row h4 { margin: 0 0 .15rem; font-size: .95rem; }
.a2g-cc-row p { margin: 0; color: #a6aee6; font-size: .9rem; }

.a2g-cc-switch { position: relative; width: 50px; height: 28px; }
.a2g-cc-switch input { display: none; }
.a2g-cc-slider {
  position: absolute; inset: 0; background: #3b427a; border-radius: 30px; cursor: pointer; transition: .15s;
}
.a2g-cc-slider::before {
  content: ""; position: absolute; left: 3px; top: 3px; width: 22px; height: 22px;
  border-radius: 50%; background: #fff; transition: .15s;
}
.a2g-cc-switch input:checked + .a2g-cc-slider { background: #6f8dff; }
.a2g-cc-switch input:checked + .a2g-cc-slider::before { transform: translateX(22px); }
.a2g-cc-switch input:disabled + .a2g-cc-slider { opacity: .6; cursor: not-allowed; }

/* Footer */
.a2g-cc-foot {
  padding: .9rem 1.2rem;
  border-top: 1px solid rgba(95,120,255,.18);
  display: flex; gap: .5rem; justify-content: flex-end; flex-wrap: wrap;
  border-radius: 10px;
  border: 1px solid rgba(246,251,167,.25);
  box-shadow: 0 6px 18px rgba(0,0,0,.22), 0 0 6px rgba(0,128,255,.10);
}
.a2g-cc-btn { appearance: none; border: 1px solid transparent; border-radius: 12px; padding: .6rem .9rem; font-weight: 700; cursor: pointer; }
.a2g-cc-btn.primary { background: #7aa0ff; color: #0e1230; }
.a2g-cc-btn.primary:hover { filter: brightness(1.05); }
.a2g-cc-btn.ghost { background: transparent; color: #c9d2ff; }
.a2g-cc-btn.ghost:hover { text-decoration: underline; }

/* Buton manage */
.a2g-cc-manage {
  position: fixed; right: 1rem; bottom: 1rem; z-index: 9997;
  width: 46px; height: 46px; border-radius: 50%;
  background: rgba(20,24,54,.95); border: 1px solid rgba(95,120,255,.28);
  box-shadow: 0 10px 28px rgba(0,0,0,.35); color: #fff; cursor: pointer;
}

/* Blocker */
.a2g-cc-blocker {
  position: fixed; inset: 0; z-index: 9996;
  background: rgba(10,12,24,.18);
  cursor: not-allowed;
}

/* Toast ușor */
.a2g-toast{
  position: fixed; right: 16px; bottom: 16px; z-index: 10000;
  background: rgba(20,24,54,.96); color:#e8ebff; border:1px solid rgba(95,120,255,.35);
  border-radius:12px; padding:.65rem .9rem; box-shadow:0 10px 28px rgba(0,0,0,.35);
  opacity:0; transform: translateY(10px); transition: opacity .2s, transform .2s;
  pointer-events:none; font-weight:700;
}
.a2g-toast.show{ opacity:1; transform: translateY(0); }

/* Blochează scroll-ul când modalul e deschis */
html.a2g-noscroll, body.a2g-noscroll { overflow: hidden !important; }

/* Asigură-te că blocker-ul primește interacțiuni */
#a2gPageBlocker { pointer-events: auto; }

/* Cursor informativ */
#a2gPageBlocker, .a2g-cc-backdrop { cursor: not-allowed; }

/* ===== Low-effects mode ===== */
.a2g-lowfx .a2g-cc-backdrop,
.a2g-lowfx .a2g-cc-modal,
.a2g-lowfx .a2g-cc-banner,
.a2g-lowfx .a2g-cc-cats,
.a2g-lowfx .a2g-cc-foot,
.a2g-lowfx .a2g-cc-avatar { box-shadow: none !important; }
.a2g-lowfx .a2g-cc-backdrop,
.a2g-lowfx .a2g-cc-blocker { background: rgba(10,12,24,.45) !important; }
.a2g-lowfx .a2g-cc-modal { transition: opacity .15s ease, transform .15s ease; }

@media (prefers-reduced-motion: reduce) {
  .a2g-cc-modal,
  .a2g-cc-backdrop,
  .a2g-toast { transition: none !important; }
}

/* ICON dimensiuni */
.item-icon { width: 32px; height: 32px; vertical-align: middle; margin-right: 4px; }
.mob-icon  { width: 75px; height: 75px; vertical-align: middle; margin-right: 6px; }
.npc-icon  { width: 70px; height: 100px; vertical-align: middle; margin-right: 6px; }

.npc-teleporter-icon {
  width: 40px;
  height: 80px;
  vertical-align: middle;
  margin-right: 6px;
}

.ability-icon{
  width: 38px;
  height: 38px;
  margin: 4px;
  vertical-align: middle;
  cursor: pointer;
}

/* containerul tooltip-ului */
.ability-icon::after {
  content: attr(alt);              /* ia textul din atributul alt */
  position: absolute;
  bottom: -40px;                   /* spațiu sub icon */
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0,0,0,0.85);
  color: #fff;
  font-size: 0.8rem;
  padding: 4px 8px;
  border-radius: 6px;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  transition: opacity .25s ease, bottom .25s ease;
  z-index: 20;
}

/* la hover apare */
.ability-icon:hover::after {
  opacity: 1;
  bottom: -48px;
}

.a2g-tooltip .tip-title{
  text-align:center;
  font-weight:700;
}