:root{
  --bg:#09090b; --bg2:#121214; --panel:#18181b; --panel2:#27272a;
  --line:#3f3f46; --txt:#e4e4e7; --muted:#a1a1aa; --accent:#8b5cf6;
  --accent2:#c084fc; --ok:#57c98a; --shadow:0 8px 30px rgba(0,0,0,.6);
  --r0:#c7d0da; --r1:#57c98a; --r2:#4ea1ff; --r3:#b06bff; --r4:#f2a03d; --r5:#ff5d5d;
}
*{box-sizing:border-box}
html,body{margin:0;padding:0}
body{
  background:radial-gradient(1200px 500px at 50% -10%,#2e1065 0%,var(--bg) 60%) fixed;
  color:var(--txt);font:15px/1.5 "Segoe UI",Roboto,system-ui,sans-serif;
  min-height:100vh;
}
b{color:var(--accent)}
/* topbar */
.topbar{
  position:sticky;top:0;z-index:20;display:flex;align-items:center;gap:24px;
  padding:12px 22px;background:rgba(13,16,20,.9);backdrop-filter:blur(8px);
  border-bottom:1px solid var(--line);
}
.brand{font-size:20px;font-weight:600;letter-spacing:.3px;display:flex;align-items:center;gap:10px}
.logo{
  width:30px;height:30px;border-radius:8px;display:grid;place-items:center;
  background:linear-gradient(135deg,var(--accent),#5b21b6);color:#fff;font-weight:800;
}
.tabs{display:flex;gap:6px}
.tab{
  background:transparent;border:1px solid transparent;color:var(--muted);
  padding:8px 16px;border-radius:8px;cursor:pointer;font-size:14px;font-weight:600;
}
.tab:hover{color:var(--txt);background:var(--panel)}
.tab.active{color:#fff;background:linear-gradient(135deg,var(--accent),#5b21b6)}
.container{max-width:1180px;margin:0 auto;padding:22px}
.panel{display:none;animation:fade .25s ease}
.panel.active{display:block}
@keyframes fade{from{opacity:0;transform:translateY(6px)}to{opacity:1}}
/* search */
.searchrow{display:flex;align-items:center;gap:14px;margin-bottom:18px}
.searchrow input{
  flex:1;background:var(--panel);border:1px solid var(--line);color:var(--txt);
  padding:12px 16px;border-radius:10px;font-size:15px;outline:none;
}
.searchrow input:focus{border-color:var(--accent2);box-shadow:0 0 0 3px rgba(78,161,255,.15)}
.count{color:var(--muted);font-size:13px;white-space:nowrap}
/* grid */
.grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:12px}
.card{
  background:var(--panel);border:1px solid var(--line);border-radius:12px;
  padding:12px;cursor:pointer;transition:.15s;display:flex;gap:10px;align-items:center;
}
.card:hover{border-color:var(--accent2);transform:translateY(-2px);box-shadow:var(--shadow)}
.icon{
  width:46px;height:46px;flex:0 0 46px;border-radius:8px;
  background:linear-gradient(160deg,#0a0d11,#12181f);border:1px solid #0a0d11;
  display:grid;place-items:center;overflow:hidden;
}
.icon img{width:42px;height:42px;image-rendering:auto;display:block}
.icon.miss{color:#3a4756;font-size:11px}
.card .meta{min-width:0}
.card .nm{font-weight:600;font-size:14px;line-height:1.2}
.card .sub{color:var(--muted);font-size:12px}
.tag{display:inline-block;font-size:11px;padding:1px 7px;border-radius:20px;background:var(--panel2);color:var(--muted);margin-left:6px}
.tag.box{background:rgba(242,160,61,.15);color:var(--accent)}
.tag.drop{background:rgba(87,201,138,.15);color:var(--ok)}
/* rarity dot */
.r{border-left:3px solid var(--r0)}
.r0{border-left-color:var(--r0)}.r1{border-left-color:var(--r1)}.r2{border-left-color:var(--r2)}
.r3{border-left-color:var(--r3)}.r4{border-left-color:var(--r4)}.r5{border-left-color:var(--r5)}
/* mobs */
.mobgrid{display:grid;grid-template-columns:repeat(auto-fill,minmax(220px,1fr));gap:12px}
.mobcard{background:var(--panel);border:1px solid var(--line);border-radius:12px;padding:14px;cursor:pointer;transition:.15s}
.mobcard:hover{border-color:var(--accent2);transform:translateY(-2px);box-shadow:var(--shadow)}
.mobcard .mn{font-weight:600}
.mobcard .ms{color:var(--muted);font-size:12px;margin-top:4px}
.loadmore{text-align:center;margin:22px 0}
.btn{background:var(--accent);color:#fff;border:0;padding:10px 22px;border-radius:9px;font-weight:700;cursor:pointer}
.btn:hover{filter:brightness(1.08)}
.btn.ghost{background:var(--panel);color:var(--txt);border:1px solid var(--line)}
/* drawer */
.overlay{position:fixed;inset:0;background:rgba(0,0,0,.55);z-index:40}
.drawer{
  position:fixed;top:0;right:0;height:100vh;width:min(520px,100%);z-index:41;
  background:var(--bg2);border-left:1px solid var(--line);box-shadow:var(--shadow);
  overflow-y:auto;padding:26px 24px;animation:slide .22s ease;
}
@keyframes slide{from{transform:translateX(30px);opacity:.5}to{transform:none;opacity:1}}
.drawer-close{position:absolute;top:14px;right:16px;background:var(--panel);border:1px solid var(--line);
  color:var(--txt);width:34px;height:34px;border-radius:8px;font-size:20px;cursor:pointer;line-height:1}
.dh{display:flex;gap:16px;align-items:center;margin-bottom:6px}
.dh .icon{width:66px;height:66px;flex-basis:66px}
.dh .icon img{width:60px;height:60px}
.dh h2{margin:0;font-size:20px}
.dh .den{color:var(--muted);font-size:13px}
.pill{display:inline-block;font-size:12px;padding:2px 9px;border-radius:20px;background:var(--panel2);color:var(--muted);margin:3px 6px 3px 0}
.sec{margin-top:22px}
.sec h3{font-size:13px;text-transform:uppercase;letter-spacing:.6px;color:var(--accent);margin:0 0 10px;border-bottom:1px solid var(--line);padding-bottom:6px}
.stats{display:grid;grid-template-columns:1fr 1fr;gap:8px}
.stat{display:flex;justify-content:space-between;background:var(--panel);border:1px solid var(--line);border-radius:8px;padding:8px 12px;font-size:13px}
.stat b{color:var(--txt)}
.stat-icon{margin-right:5px;font-size:14px}
.desc{color:var(--muted);font-size:13px;font-style:italic;line-height:1.6}
.row{display:flex;align-items:center;gap:10px;padding:8px;border-radius:9px;cursor:pointer;transition:.12s}
.row:hover{background:var(--panel)}
.row .icon{width:38px;height:38px;flex-basis:38px}
.row .icon img{width:34px;height:34px}
.row .rn{flex:1;min-width:0;font-size:14px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.row .rc{font-size:13px;font-weight:700;display:flex;align-items:center;gap:5px;white-space:nowrap}
.row .rc .icon.coin-mini{width:20px;height:20px;flex-basis:20px}
.row .rc .icon.coin-mini img{width:20px;height:20px}
.chance{color:var(--ok)}
.tier-h{font-size:12px;color:var(--muted);margin:12px 0 4px;font-weight:700}
.empty{color:var(--muted);text-align:center;padding:40px 0}
.reliq-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:16px}
.reliq-head h2{margin:0;font-size:20px}
.nation{background:var(--panel);border:1px solid var(--line);border-radius:12px;padding:16px;margin-bottom:14px}
.nation h4{margin:0 0 12px;font-size:15px}
.skel{color:var(--muted);text-align:center;padding:50px 0}
@media(max-width:640px){.tabs .tab{padding:8px 10px}.stats{grid-template-columns:1fr}}

.note{font-size:11.5px;color:var(--muted);font-style:italic;margin:-2px 0 8px}
.tier-h.tier-normal{color:var(--r0)}
.tier-h.tier-superior{color:var(--r1)}
.tier-h.tier-rare{color:var(--r2)}
.tier-h.tier-legendary{color:var(--r4)}

.map-separator { grid-column: 1 / -1; padding: 10px; background: var(--bg-hover); font-weight: bold; font-size: 1.1em; border-radius: 4px; margin-top: 15px; margin-bottom: 5px; color: var(--primary); text-transform: uppercase; letter-spacing: 1px; border-bottom: 2px solid var(--border); }

/* Map view com lista lateral */
.mapview{display:flex;gap:14px;align-items:flex-start}
.mapwrap{position:relative;flex:1;min-width:0;background:#111;border-radius:10px;overflow:hidden}
.mapimg {position:absolute!important;top:0!important;left:0!important;width:100%!important;height:100%!important;object-fit:fill!important;display:block!important}
.map-section-preview {position:relative;overflow:hidden}
.map-section-preview img {position:absolute;top:0;left:0;width:100%;height:100%;object-fit:cover;object-position:top left;display:block}
.mapside{width:280px;flex:0 0 280px;max-height:78vh;overflow-y:auto;background:var(--panel);border:1px solid var(--line);border-radius:12px;padding:8px}
.side-head{font-size:12px;text-transform:uppercase;letter-spacing:.5px;color:var(--muted);padding:6px 8px 8px;position:sticky;top:0;background:var(--panel);z-index:1}
.side-row{display:flex;align-items:center;gap:8px;padding:7px 8px;border-radius:8px;cursor:pointer;transition:.12s;border:1px solid transparent}
.side-row:hover{background:var(--panel2)}
.side-row.sel{background:rgba(139,92,246,.18);border-color:var(--accent)}
.side-mark{width:9px;height:9px;border-radius:50%;background:#555;flex:0 0 9px}
.side-row.sel .side-mark{background:red;box-shadow:0 0 4px red}
.side-txt{flex:1;min-width:0;display:flex;flex-direction:column;line-height:1.2}
.side-nm{min-width:0;font-size:13px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.side-sub{font-size:11px;color:var(--muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.side-lv{font-size:11px;color:var(--muted)}
.side-cnt{font-size:12px;font-weight:700;background:var(--panel2);color:var(--txt);border-radius:20px;padding:1px 8px;min-width:22px;text-align:center}
.allmap-block{margin-bottom:26px}
.allmap-h{font-weight:700;font-size:15px;color:var(--accent);margin:0 0 8px;padding-bottom:6px;border-bottom:1px solid var(--line)}
/* Fabricação */
.craftgrid{display:grid;grid-template-columns:repeat(auto-fill,minmax(320px,1fr));gap:12px}
.craftcard{background:var(--panel);border:1px solid var(--line);border-radius:12px;padding:12px;cursor:pointer;transition:.15s}
.craftcard:hover{border-color:var(--accent2);transform:translateY(-2px);box-shadow:var(--shadow)}
.craft-head{display:flex;gap:10px;align-items:center}
.craft-ht{min-width:0;flex:1}
.craft-nm{font-weight:600;font-size:14px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.craft-meta{color:var(--muted);font-size:12px;margin-top:2px}
.craft-ings{display:flex;flex-wrap:wrap;gap:6px;margin-top:10px;padding-top:10px;border-top:1px solid var(--line)}
.ing-chip{position:relative;width:38px;height:38px;border-radius:8px;overflow:visible;cursor:pointer}
.ing-chip .icon{width:38px;height:38px;flex-basis:38px}
.ing-chip .icon img{width:34px;height:34px}
.ing-chip:hover{outline:2px solid var(--accent2);border-radius:8px}
.ing-amt{position:absolute;right:-3px;bottom:-3px;background:var(--panel2);border:1px solid var(--line);color:var(--txt);font-size:10px;font-weight:700;border-radius:8px;padding:0 4px;line-height:1.4}
.ing-none{color:var(--muted);font-size:12px}
/* bolinha destacada ao "Ver no Mapa": maior, dourada, pulsando */
.mob-dot.pulse{width:14px!important;height:14px!important;background:#ffd34d!important;border:2px solid #fff!important;box-shadow:0 0 10px 4px rgba(255,211,77,.95)!important;z-index:6;animation:wikipulse 1s ease-in-out infinite}
@keyframes wikipulse{
  0%{transform:translate(-50%,-50%) scale(1)}
  50%{transform:translate(-50%,-50%) scale(2)}
  100%{transform:translate(-50%,-50%) scale(1)}
}
@media(max-width:760px){.mapview{flex-direction:column}.mapside{width:100%;flex-basis:auto;max-height:320px}}

.map-back-btn { display: flex; align-items: center; gap: 6px; width: 100%; padding: 8px 12px; margin-bottom: 8px; background: var(--panel2); border: 1px solid var(--line); color: var(--txt); border-radius: 8px; font-size: 13px; font-weight: 600; cursor: pointer; transition: .15s; }
.map-back-btn:hover { background: var(--accent); color: #fff; border-color: var(--accent); }
.map-overlay-back { position: absolute; top: 10px; left: 10px; z-index: 10; display: flex; align-items: center; gap: 6px; padding: 6px 12px; background: rgba(24,24,27,0.85); backdrop-filter: blur(4px); border: 1px solid var(--line); color: var(--txt); border-radius: 8px; font-size: 12px; font-weight: 600; cursor: pointer; transition: .15s; }
.map-overlay-back:hover { background: var(--accent); color: #fff; border-color: var(--accent); }

.map-vignette { position: absolute; inset: 0; pointer-events: none; z-index: 5; opacity: 1; transition: opacity 0.6s ease; border-radius: 10px; }
.map-vignette.fade-out { opacity: 0; }

/* ---------------- Skill Simulator ---------------- */
.skill-sim-header { display: flex; flex-direction: column; gap: 16px; margin-bottom: 22px; }
.class-selector { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.class-btn { display: flex; align-items: center; gap: 8px; padding: 10px 18px; background: var(--panel); border: 1px solid var(--line); color: var(--muted); border-radius: 10px; font-weight: 700; font-size: 14px; cursor: pointer; transition: .2s ease; }
.class-btn:hover { color: var(--txt); border-color: var(--accent2); background: var(--panel2); }
.class-btn.active { color: #fff; background: linear-gradient(135deg, var(--accent), #5b21b6); border-color: var(--accent2); box-shadow: 0 4px 15px rgba(139,92,246,.35); }
.class-icon { font-size: 16px; }

.skill-stats-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 12px 18px; }
.stat-pill { font-size: 14px; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.stat-pill strong { color: #fff; font-size: 16px; font-weight: 800; }
.stat-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.btn-sm { padding: 7px 14px; font-size: 13px; border-radius: 8px; }

.skill-tree-wrap { display: flex; flex-direction: column; gap: 24px; }
.skill-section { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 18px; position: relative; }
.skill-section-title { font-size: 15px; font-weight: 700; color: var(--accent2); text-transform: uppercase; letter-spacing: .5px; margin: 0 0 16px 0; border-bottom: 1px solid var(--line); padding-bottom: 8px; display: flex; align-items: center; gap: 8px; }

.skill-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 14px; }

.skill-node { display: flex; gap: 12px; align-items: center; background: var(--bg2); border: 1px solid var(--line); border-radius: 10px; padding: 10px; position: relative; cursor: pointer; transition: all .15s ease; user-select: none; }
.skill-node:hover { border-color: var(--accent2); transform: translateY(-2px); box-shadow: var(--shadow); }
.skill-node.learned { border-color: var(--accent); background: rgba(139,92,246,.08); }
.skill-node.maxed { border-color: var(--ok); background: rgba(87,201,138,.1); }
.skill-node.locked { opacity: .4; cursor: not-allowed; filter: grayscale(80%); }

.skill-node-icon { width: 44px; height: 44px; flex: 0 0 44px; border-radius: 8px; overflow: hidden; border: 1px solid var(--line); background: #000; position: relative; display: grid; place-items: center; }
.skill-node-icon img { width: 100%; height: 100%; object-fit: cover; display: block; }
.skill-node.learned .skill-node-icon { border-color: var(--accent); box-shadow: 0 0 8px rgba(139,92,246,.5); }
.skill-node.maxed .skill-node-icon { border-color: var(--ok); box-shadow: 0 0 8px rgba(87,201,138,.6); }

.skill-node-meta { flex: 1; min-width: 0; }
.skill-node-name { font-size: 13px; font-weight: 700; color: var(--txt); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; line-height: 1.3; }
.skill-node-req { font-size: 11px; color: var(--muted); margin-top: 2px; }
.skill-node-rank { font-size: 12px; font-weight: 800; color: var(--accent2); margin-top: 3px; }
.skill-node.maxed .skill-node-rank { color: var(--ok); }

.skill-node-ctrls { display: flex; flex-direction: column; gap: 3px; }
.skill-btn { width: 22px; height: 22px; border-radius: 5px; border: 1px solid var(--line); background: var(--panel2); color: var(--txt); font-weight: 800; font-size: 13px; cursor: pointer; display: grid; place-items: center; padding: 0; line-height: 1; }
.skill-btn:hover { background: var(--accent); color: #fff; border-color: var(--accent); }

/* Skill Tooltip */
.skill-tooltip { position: absolute; z-index: 50; width: 320px; background: rgba(18,18,20,.96); backdrop-filter: blur(10px); border: 1px solid var(--accent); border-radius: 12px; padding: 14px; box-shadow: 0 10px 35px rgba(0,0,0,.8); pointer-events: none; opacity: 0; transition: opacity .15s ease; }
.skill-tooltip.active { opacity: 1; }
.st-head { display: flex; gap: 12px; align-items: center; margin-bottom: 10px; border-bottom: 1px solid var(--line); padding-bottom: 8px; }
.st-head img { width: 40px; height: 40px; border-radius: 6px; border: 1px solid var(--line); }
.st-name { font-weight: 700; font-size: 15px; color: #fff; }
.st-sub { font-size: 12px; color: var(--muted); }
.st-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; font-size: 12px; margin-bottom: 10px; background: var(--panel); padding: 8px; border-radius: 8px; }
.st-desc { font-size: 12.5px; color: var(--txt); line-height: 1.4; }
.st-req { font-size: 11px; color: #f87171; margin-top: 8px; font-weight: 600; }

/* ---------------- Informação do Personagem (Char Builder) ---------------- */
.char-builder-top { display: flex; justify-content: center; margin-bottom: 20px; }
.char-controls { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 12px 20px; }
.char-select, .char-num-input { background: var(--panel2); border: 1px solid var(--line); color: var(--txt); padding: 8px 12px; border-radius: 8px; font-size: 14px; outline: none; }
.char-num-input { width: 70px; font-weight: 700; text-align: center; }

.char-window-wrapper { display: flex; justify-content: center; padding: 10px; }
.char-window { width: 380px; background: #15191d; border: 2px solid #3c4856; border-radius: 10px; box-shadow: 0 15px 45px rgba(0,0,0,.9); font-family: "Segoe UI", Tahoma, sans-serif; overflow: hidden; color: #c3cfdd; user-select: none; }
.char-win-title { background: linear-gradient(180deg, #2a333d 0%, #1a2027 100%); padding: 8px 14px; font-size: 14px; font-weight: 700; color: #e2e8f0; display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid #374352; }
.char-win-close { background: transparent; border: none; color: #94a3b8; font-size: 18px; font-weight: 700; cursor: pointer; line-height: 1; }
.char-win-close:hover { color: #f87171; }

.char-win-body { display: flex; padding: 12px; gap: 10px; position: relative; }
.char-eq-col { display: flex; flex-direction: column; gap: 10px; }

.char-slot { width: 44px; height: 44px; background: #0c0f12; border: 1px solid #333d4a; border-radius: 6px; position: relative; cursor: pointer; transition: all .15s ease; display: grid; place-items: center; }
.char-slot:hover { border-color: #60a5fa; box-shadow: 0 0 10px rgba(96,165,250,.4); }
.char-slot.active { border-color: #f59e0b; background: rgba(245,158,11,.1); }
.slot-num { position: absolute; top: -6px; left: -6px; background: #6366f1; color: #fff; font-size: 10px; font-weight: 800; border-radius: 50%; width: 18px; height: 18px; display: grid; place-items: center; border: 1px solid #fff; z-index: 2; }
.slot-icon-box { width: 100%; height: 100%; display: grid; place-items: center; overflow: hidden; border-radius: 5px; }
.slot-icon-box img { width: 38px; height: 38px; object-fit: contain; }
.slot-refine-badge { position: absolute; bottom: 1px; right: 2px; background: rgba(0,0,0,.85); color: #fbbf24; font-size: 10px; font-weight: 800; padding: 0 3px; border-radius: 4px; border: 1px solid #78350f; }

.char-profile-center { position: relative; flex: 1; display: flex; flex-direction: column; justify-content: space-between; }
.char-profile-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.char-profile-table td { padding: 3px 4px; }
.char-profile-table td:first-child { color: #8292a4; text-align: left; width: 35%; }
.char-profile-table td:last-child { color: #e2e8f0; font-weight: 600; text-align: left; padding-left: 8px; }
.char-inline-input { background: transparent; border: none; border-bottom: 1px dashed #475569; color: #60a5fa; font-weight: 700; font-size: 12px; width: 110px; text-align: left; outline: none; }

.char-eq-row { display: flex; gap: 8px; justify-content: center; margin-top: 10px; }

.char-stats-panel { background: #0c0f12; border-top: 1px solid #28313d; padding: 10px 12px; }
.char-stats-grid { width: 100%; border-collapse: collapse; font-size: 12px; table-layout: fixed; }
.char-stats-grid td { padding: 4px 2px; white-space: nowrap; }
.char-stats-grid td:nth-child(1) { color: #8292a4; text-align: left; width: 26%; }
.char-stats-grid td:nth-child(2) { color: #e2e8f0; font-weight: 700; text-align: right; width: 30%; }
.char-stats-grid td:nth-child(3) { color: #8292a4; text-align: left; width: 26%; padding-left: 12px; }
.char-stats-grid td:nth-child(4) { color: #e2e8f0; font-weight: 700; text-align: right; width: 18%; }
.char-exp-row { border-top: 1px solid #1e293b; padding-top: 6px !important; text-align: center !important; color: #94a3b8 !important; font-size: 11px !important; }
.char-exp-row span { color: #38bdf8; font-weight: 600; }

.stat-val-cell { display: flex; align-items: center; justify-content: flex-end; gap: 6px; width: 100%; white-space: nowrap; text-align: right; }
.stat-val-cell > span { display: inline-block; text-align: right; margin-right: 2px; }
.stat-btn-group { display: inline-flex; gap: 2px; }
.stat-btn { width: 16px; height: 16px; background: #1e293b; border: 1px solid #475569; color: #cbd5e1; font-size: 10px; font-weight: 800; border-radius: 3px; display: grid; place-items: center; cursor: pointer; padding: 0; line-height: 1; transition: all .15s; }
.stat-btn:hover { background: #3b82f6; border-color: #60a5fa; color: #fff; }
.stat-btn:active { transform: scale(0.92); }

/* Detalhes do Personagem Sub-Window (Print 3) */
.char-win-header-actions { display: flex; align-items: center; gap: 8px; }
.char-win-more-btn { position: absolute; top: 2px; right: 4px; background: #334155; border: 1px solid #475569; color: #fbbf24; font-size: 11px; font-weight: 800; border-radius: 4px; width: 18px; height: 18px; display: grid; place-items: center; cursor: pointer; line-height: 1; z-index: 5; }
.char-win-more-btn:hover { background: #f59e0b; color: #000; border-color: #fcf003; }

.char-details-window { width: 420px; background: #111519; border: 2px solid #333d4a; border-radius: 10px; box-shadow: 0 15px 45px rgba(0,0,0,.95); font-family: "Segoe UI", Tahoma, sans-serif; overflow: hidden; color: #c3cfdd; margin-top: 16px; user-select: none; }
.char-details-grid { width: 100%; border-collapse: collapse; font-size: 12px; }
.char-details-grid td { padding: 5px 10px; border-bottom: 1px solid #1e293b; }
.char-details-grid tr:last-child td { border-bottom: none; }
.char-details-grid td:nth-child(1), .char-details-grid td:nth-child(3) { color: #94a3b8; text-align: left; width: 35%; }
.char-details-grid td:nth-child(2), .char-details-grid td:nth-child(4) { color: #e2e8f0; font-weight: 700; text-align: right; width: 15%; }

/* In-Game Item Hover Tooltip (Matching User Screenshots) */
#itemHoverTooltip { position: fixed; z-index: 99999; display: flex; gap: 8px; pointer-events: none; opacity: 0; transition: opacity .1s ease; font-family: "Segoe UI", Arial, sans-serif; font-size: 12px; user-select: none; }
#itemHoverTooltip.visible { opacity: 1; }

.item-tt-box { background: rgba(9, 12, 14, 0.96); border: 2px solid #3d4956; border-radius: 6px; box-shadow: 0 10px 30px rgba(0,0,0,0.95); padding: 12px 14px; width: 310px; color: #cbd5e1; line-height: 1.45; }
.item-tt-title { color: #e59a2a; font-size: 14px; font-weight: 700; margin-bottom: 2px; }
.item-tt-subname { color: #d97706; font-size: 11px; margin-bottom: 8px; font-style: italic; }
.item-tt-line { color: #e2e8f0; margin-bottom: 3px; }
.item-tt-red { color: #ef4444; font-weight: 700; }
.item-tt-green { color: #4ade80; }
.item-tt-gold { color: #f59e0b; font-weight: 600; }
.item-tt-sub { color: #94a3b8; font-size: 11px; margin-top: 6px; border-top: 1px solid #1e293b; padding-top: 6px; }

.item-tt-flags { margin-top: 8px; border-top: 1px solid #1e293b; padding-top: 6px; font-size: 11px; display: flex; flex-direction: column; gap: 2px; color: #a1a1aa; }
.item-tt-flag-no { color: #ea580c; }
.item-tt-flag-yes { color: #38bdf8; }

.item-tt-set { width: 330px; }
.item-tt-set-list { margin: 8px 0; display: flex; flex-direction: column; gap: 2px; }
.item-tt-set-item { color: #94a3b8; padding-left: 12px; }
.item-tt-set-item.equipped { color: #f8fafc; font-weight: 700; text-shadow: 0 0 5px rgba(255,255,255,0.4); }
.item-tt-set-eff { color: #fcf003; margin-top: 8px; border-top: 1px dashed #334155; padding-top: 6px; }
.item-tt-set-eff-title { color: #f59e0b; font-weight: 700; margin-bottom: 4px; }

.stat-modal-overlay[hidden] { display: none !important; }
.stat-modal-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.75); backdrop-filter: blur(4px); z-index: 999999; display: flex; align-items: center; justify-content: center; }
.stat-modal-card { width: 380px; background: #111519; border: 2px solid #333d4a; border-radius: 10px; box-shadow: 0 20px 50px rgba(0,0,0,0.9); padding: 18px; color: #cbd5e1; font-family: "Segoe UI", Tahoma, sans-serif; user-select: none; }
.stat-modal-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; border-bottom: 1px solid #1e293b; padding-bottom: 8px; }
.stat-modal-header h3 { font-size: 15px; color: #fbbf24; margin: 0; font-weight: 700; }
.stat-modal-close { background: none; border: none; color: #94a3b8; font-size: 20px; cursor: pointer; }
.stat-modal-close:hover { color: #fff; }
.stat-modal-info { font-size: 12px; background: #0b0e11; padding: 10px 12px; border-radius: 6px; border: 1px solid #1e293b; display: flex; flex-direction: column; gap: 4px; }



/* ---------------- Títulos ---------------- */
.titlegrid{display:grid;grid-template-columns:repeat(auto-fill,minmax(220px,1fr));gap:12px}
.title-card{background:var(--panel);border:1px solid var(--line);border-radius:12px;padding:14px;cursor:pointer;transition:.15s;display:flex;flex-direction:column;gap:6px}
.title-card:hover{border-color:var(--accent);transform:translateY(-2px)}
.title-name{font-weight:800;font-size:16px;text-shadow:0 1px 3px rgba(0,0,0,.7);letter-spacing:.2px}
.title-sub{color:var(--muted);font-size:12px}
.title-swatches{display:flex;gap:5px;margin-top:2px}
.title-swatches .tsw{width:22px;height:10px;border-radius:3px;border:1px solid rgba(255,255,255,.15)}
.title-act-hint{margin-top:4px;font-size:12px;color:var(--muted)}

.title-detail .td-head{margin-bottom:14px}
.title-detail .td-title{font-size:24px;font-weight:800;text-shadow:0 1px 4px rgba(0,0,0,.7)}
.title-detail .td-meta{color:var(--muted);font-size:13px;margin-top:4px}
.td-levels{display:flex;flex-direction:column;gap:10px}
.tlevel{background:var(--panel);border:1px solid var(--line);border-radius:10px;padding:10px 12px}
.tlevel-top{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.tlevel-badge{font-size:11px;font-weight:800;color:#000;padding:2px 9px;border-radius:20px;text-shadow:0 1px 1px rgba(255,255,255,.35)}
.tlevel-name{font-weight:700;text-shadow:0 1px 3px rgba(0,0,0,.7)}
.tlevel-goal{color:var(--muted);font-size:13px;margin-left:auto}
.tlevel-goal b{color:var(--txt)}
.tlevel-color{font-family:ui-monospace,Consolas,monospace;font-size:11px;color:var(--muted);background:var(--panel2);padding:1px 7px;border-radius:5px}
.tlevel-effects{margin-top:8px;display:flex;flex-direction:column;gap:5px}
.teff{display:flex;gap:10px;align-items:baseline;font-size:13px;background:var(--bg2);border:1px solid var(--line);border-radius:7px;padding:5px 10px}
.teff-name{font-weight:700;color:var(--accent);min-width:130px}
.teff-desc{color:var(--muted)}
.td-activators{margin-top:18px}
.td-activators h4{font-size:13px;text-transform:uppercase;letter-spacing:.6px;color:var(--accent);margin:0 0 10px;border-bottom:1px solid var(--line);padding-bottom:6px}
.td-act-grid{display:flex;flex-direction:column;gap:8px}
.act-chip{display:flex;align-items:center;gap:10px;background:var(--panel);border:1px solid var(--line);border-radius:9px;padding:7px 10px;cursor:pointer;transition:.15s}
.act-chip:hover{border-color:var(--accent);background:var(--panel2)}
.act-name{font-size:13px}
.td-note{color:var(--muted);font-size:13px;font-style:italic}
