/* CENTRAL MU — capa visual sobre el cliente web (sin tocar su lógica). */

/* ---------- avisos centrales (GM, eventos, anuncios) ---------- */
.cm-notices { position: fixed; left: 50%; top: 22%; transform: translateX(-50%); z-index: 40; pointer-events: none;
  display: flex; flex-direction: column; align-items: center; gap: 6px; width: min(92vw, 900px); }
.cm-notice { font: 700 clamp(15px, 2.1vw, 24px)/1.25 Cinzel, Tahoma, Verdana, serif; color: #ffd76a; text-align: center;
  letter-spacing: .02em; padding: 6px 22px; text-shadow: 0 0 8px rgba(255,140,30,.55), 2px 2px 0 #000, -1px -1px 0 #000;
  background: radial-gradient(ellipse at center, rgba(0,0,0,.62) 0%, rgba(0,0,0,.35) 55%, rgba(0,0,0,0) 75%);
  animation: cm-in .35s ease-out, cm-out .8s ease-in forwards; animation-delay: 0s, var(--life, 7s); }
@keyframes cm-in { from { opacity: 0; transform: translateY(-8px) scale(.96); } }
@keyframes cm-out { to { opacity: 0; transform: translateY(-6px); } }

/* ---------- coordenadas y mapa ---------- */
.cm-coords { position: fixed; left: 10px; top: 8px; z-index: 25; pointer-events: none; padding: 3px 10px 3px 8px;
  font: 700 clamp(11px, 1.15vw, 14px)/1.3 Tahoma, Verdana, sans-serif; color: #ffe08a; text-shadow: 1px 1px 0 #000;
  background: linear-gradient(90deg, rgba(0,0,0,.7), rgba(0,0,0,.35) 80%, rgba(0,0,0,0)); border-left: 2px solid #c8a050; }
.cm-coords span { color: #fff; font-weight: 400; margin-left: 6px; }
.cm-coords[hidden] { display: none; }

/* ---------- baúl: zen, campo y botones en dos filas prolijas ---------- */
.mu-ui .mu-storage-footer { top: 352px; gap: 3px; flex-wrap: wrap; }
.mu-ui .mu-storage-footer .mu-storage-money { flex: 0 0 160px; height: 18px; }
.mu-ui .mu-storage-footer .mu-field { flex: 0 0 auto; width: 52px; height: 16px; }
.mu-ui .mu-storage-footer .mu-text-btn { flex: 1 1 0; text-align: center; height: 16px; line-height: 16px; padding: 0 2px; }
.mu-ui .mu-text-btn { background: linear-gradient(#3e3424, #1b160e); border: 1px solid #8a7140; color: #f0dca8; border-radius: 2px;
  box-shadow: inset 0 1px 0 rgba(255,230,170,.18); cursor: pointer; }
.mu-ui .mu-text-btn:hover { border-color: #d6b060; color: #ffe08a; }
.mu-ui .mu-text-btn:active { background: linear-gradient(#1b160e, #3e3424); }
.mu-ui .mu-field::placeholder { color: #8d8064; }

/* ---------- pantallas de entrada ---------- */
.cm-entry-logo { position: absolute; left: 50%; top: 4.5%; width: 400px; transform: translateX(-50%); pointer-events: none;
  filter: drop-shadow(0 6px 18px rgba(0,0,0,.75)); animation: cm-fade 1.2s ease-out; }
@keyframes cm-fade { from { opacity: 0; } }
.mu-entry-stage .mu-e-label { font-size: 11px; text-align: right; }
.cm-hide { visibility: hidden !important; }

/* selección de personaje */
.cm-select-head { position: fixed; left: 50%; top: 12px; transform: translateX(-50%); z-index: 35; pointer-events: none; text-align: center; }
.cm-select-head img { width: clamp(180px, 22vw, 300px); filter: drop-shadow(0 4px 14px rgba(0,0,0,.8)); }
.cm-select-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 35; display: flex; justify-content: center; align-items: center;
  gap: clamp(10px, 2vw, 28px); padding: clamp(14px, 2.4vh, 26px) 16px clamp(16px, 3vh, 30px);
  background: linear-gradient(to top, rgba(0,0,0,.92), rgba(0,0,0,.55) 65%, rgba(0,0,0,0)); }
.cm-btn { font: 700 clamp(13px, 1.3vw, 17px) Cinzel, Tahoma, serif; letter-spacing: .06em; color: #f3e2b4; cursor: pointer;
  padding: .7em 1.6em; min-width: 9em; border: 1px solid #8a7140; border-radius: 3px; text-shadow: 1px 1px 0 #000;
  background: linear-gradient(#3a3022, #17130c); box-shadow: inset 0 1px 0 rgba(255,230,170,.2), 0 4px 14px rgba(0,0,0,.6); }
.cm-btn:hover { border-color: #e2bc68; color: #ffe08a; box-shadow: inset 0 1px 0 rgba(255,230,170,.3), 0 0 14px rgba(255,170,60,.35); }
.cm-btn.gold { color: #2a1a04; border-color: #ffd677; background: linear-gradient(#ffe7a0, #d9a440 55%, #a8741e); text-shadow: none; }
.cm-btn.gold:hover { filter: brightness(1.08); color: #1a0f00; }
.cm-btn.danger { color: #ffc9c0; border-color: #8a4033; }
.cm-btn:disabled { opacity: .45; cursor: default; }
.cm-select-hint { position: fixed; left: 0; right: 0; bottom: clamp(70px, 11vh, 100px); z-index: 35; text-align: center; pointer-events: none;
  font: 13px Tahoma, Verdana, sans-serif; color: #d8cba6; text-shadow: 1px 1px 0 #000; }

@media (max-width: 600px) {
  .cm-entry-logo { width: 300px; }
  .cm-btn { min-width: 0; padding: .7em 1em; }
}

/* ---------- barra inferior: coordenadas bajo el papiro, botones y barra violeta (AG) en su lugar ---------- */
.mu-ui .mu-ag { left: 553px !important; }
.cm-bar-coords { position: absolute; left: 10px; top: 27px; width: 48px; height: 16px; display: flex; flex-direction: column;
  justify-content: center; align-items: center; pointer-events: none; font: 700 6px/1.05 Tahoma, Verdana, sans-serif;
  color: #ffe08a; text-shadow: 0 0 1px #000, 1px 1px 0 #000; white-space: nowrap; overflow: hidden; }
.cm-bar-coords b { font-size: 5.5px; color: #e6d3a0; font-weight: 700; max-width: 48px; overflow: hidden; text-overflow: ellipsis; }
.cm-bar-coords span { font-size: 6.5px; color: #fff; }
.mu-ui .cm-hot { position: absolute; pointer-events: auto; background: transparent; border: 0; padding: 0; cursor: inherit; }
.mu-ui .cm-hot:hover { background: rgba(255, 220, 140, .14); box-shadow: inset 0 0 0 1px rgba(255,210,120,.45); }
.mu-ui .cm-hot:active { background: rgba(0,0,0,.25); }
.cm-hot-guide { left: 8px; top: 2px; width: 51px; height: 20px; }
.cm-hot-friends { left: 582px; top: 2px; width: 52px; height: 20px; }
.cm-hot-guild { left: 582px; top: 26px; width: 52px; height: 19px; }

/* ---------- ventanas propias (guía, mapas, amigos) ---------- */
.cm-win { position: fixed; left: 50%; top: 8vh; transform: translateX(-50%); z-index: 28; width: min(92vw, 360px); max-height: 70vh;
  display: flex; flex-direction: column; background: url(/cm-ui/Item_Back02.png) center/cover, #1a1814; border: 2px solid #6b5a3a;
  box-shadow: 0 0 0 1px #000, 0 10px 40px rgba(0,0,0,.8); font: 12px/1.35 Tahoma, Verdana, sans-serif; color: #e6e6e6; text-shadow: 1px 1px 0 #000; }
.cm-win[hidden] { display: none; }
.cm-win-title { padding: 9px 34px 8px; text-align: center; color: #ffcc66; font: 700 14px Cinzel, Tahoma, serif; letter-spacing: .05em;
  background: linear-gradient(#2b241a, #120f0a); border-bottom: 1px solid #6b5a3a; }
.cm-win-close { position: absolute; right: 6px; top: 6px; width: 22px; height: 22px; border: 1px solid #6b5a3a; background: #1b160e;
  color: #e8dcb8; cursor: pointer; font-size: 12px; line-height: 1; }
.cm-win-close:hover { color: #ffd27a; border-color: #b08a4a; }
.cm-win-body { overflow: auto; padding: 8px 10px 12px; background: rgba(0,0,0,.45); }
.cm-muted { color: #a99e86; margin: 2px 2px 8px; }
.cm-list { display: flex; flex-direction: column; gap: 3px; }
.cm-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 5px 8px; background: rgba(0,0,0,.4);
  border: 1px solid #3c3222; color: #fff; text-align: left; font: inherit; width: 100%; box-sizing: border-box; }
button.cm-row { cursor: pointer; } button.cm-row:hover { border-color: #b08a4a; background: rgba(60,48,28,.6); }
.cm-row span { font-weight: 700; color: #ffe8b0; } .cm-row small { color: #c8bc9c; text-align: right; }
.cm-mini { font: 700 11px Tahoma, sans-serif; color: #f0dca8; background: linear-gradient(#3e3424, #1b160e); border: 1px solid #8a7140; padding: 2px 8px; cursor: pointer; }
.cm-tabs { display: flex; gap: 4px; margin-bottom: 8px; }
.cm-tabs button { flex: 1; font: 700 11px Tahoma, sans-serif; color: #c8bc9c; background: #15120c; border: 1px solid #4a3f2a; padding: 4px; cursor: pointer; }
.cm-tabs button.on { color: #ffd27a; border-color: #b08a4a; background: #2b241a; }
.cm-win a { color: #ffd27a; }

/* ---------- intro, carga y placa del login ---------- */
.cm-intro, .cm-loading { display: grid; place-items: center; background: none !important; }
.cm-box-logo { width: 100%; filter: drop-shadow(0 6px 20px rgba(0,0,0,.8)); }
.cm-plate { position: absolute; left: 74px; top: 9px; width: 102px; height: 24px; white-space: nowrap; display: flex; align-items: center; justify-content: center; gap: 3px;
  background: linear-gradient(#3a3a3a, #161616); border: 1px solid #77684a; border-radius: 3px; color: #f2c75c;
  font: 700 8.5px Cinzel, Tahoma, serif; letter-spacing: .06em; text-shadow: 1px 1px 0 #000; pointer-events: none; }
.cm-plate img { width: 14px; height: 14px; }
.mu-entry-stage .cm-intro { animation: mu-e-fade 2.2s ease-in-out both; }

/* ---------- botones con texto (inicio, login, registro, servidores): estilo MU uniforme ---------- */
.mu-entry .mu-e-btn.cm-tbtn { background: linear-gradient(#4a3d29, #1d170e) !important; border: 1px solid #8a7140; border-radius: 2px;
  box-shadow: inset 0 1px 0 rgba(255,230,170,.22), 0 1px 2px rgba(0,0,0,.6); color: #f3e2b4; padding: 0 4px;
  font: bold 11px/1 Tahoma, Verdana, sans-serif; letter-spacing: 0; text-overflow: ellipsis; display: flex; align-items: center; justify-content: center; }
.mu-entry .mu-e-btn.cm-tbtn:hover { border-color: #e2bc68; color: #ffe08a; filter: none; background: linear-gradient(#5a4a30, #241c10) !important; }
.mu-entry .mu-e-btn.cm-tbtn:active { background: linear-gradient(#1d170e, #4a3d29) !important; }
.mu-entry .mu-e-input { box-sizing: border-box; }

/* ---------- ficha de ítem ---------- */
.mu-tooltip .mu-tip-req { color: #f2f2f2; }
.mu-tooltip .mu-tip-cls { color: #d8d8d8; }
.mu-tooltip .mu-tip-exc { color: #3cff9a; }
.mu-tooltip .mu-tip-opt { color: #8fb4ff; }
.mu-tooltip { line-height: 1.35; }

/* ---------- aviso de versión nueva ---------- */
.cm-update { position: fixed; left: 50%; top: 10px; transform: translateX(-50%); z-index: 60; cursor: pointer;
  font: bold 13px Tahoma, Verdana, sans-serif; color: #2a1a04; padding: 8px 16px; border: 1px solid #ffd677; border-radius: 4px;
  background: linear-gradient(#ffe7a0, #d9a440 55%, #a8741e); box-shadow: 0 4px 16px rgba(0,0,0,.6); }

/* ---------- ítems: como el MU original (sin recuadros), solo una sombra suave para que se lean bien ---------- */
.mu-ui .mu-item.cm-r { background-color: transparent; box-shadow: none; filter: drop-shadow(0 1px 1px rgba(0,0,0,.85)); }
.mu-ui .mu-item.cm-r:hover { background-color: rgba(255,255,255,.12); filter: drop-shadow(0 1px 1px rgba(0,0,0,.85)) brightness(1.12); }


/* ---------- menú del juego (Esc / ⚙) ---------- */
.cm-menu-back { position: fixed; inset: 0; z-index: 70; background: rgba(0,0,0,.55); display: grid; place-items: center; }
.cm-menu-back[hidden] { display: none; }
.cm-menu { width: min(88vw, 320px); display: flex; flex-direction: column; gap: 10px; padding: 18px 18px 20px;
  background: url(/cm-ui/Item_Back02.png) center/cover, #1a1814; border: 2px solid #6b5a3a; box-shadow: 0 0 0 1px #000, 0 14px 50px rgba(0,0,0,.85); }
.cm-menu-title { display: flex; align-items: center; justify-content: center; gap: 8px; margin-bottom: 4px; color: #ffcc66;
  font: 700 17px Cinzel, Tahoma, serif; letter-spacing: .06em; text-shadow: 1px 1px 0 #000; }
.cm-menu-title img { width: 28px; height: 28px; }
.cm-menu .cm-btn { width: 100%; min-width: 0; }
.cm-gear { position: fixed; right: 10px; top: 10px; z-index: 30; width: 44px; height: 44px; border-radius: 50%; cursor: pointer;
  font: 24px/1 sans-serif; color: #f3e2b4; border: 1px solid #8a7140; background: radial-gradient(#3a3022, #120e08);
  box-shadow: 0 2px 10px rgba(0,0,0,.7); display: grid; place-items: center; }
.cm-gear[hidden] { display: none; }
