/* MU Eclipse - efectos propios (Tailwind hace el resto) */
:root {
  --gold: #d9b45a; --gold-2: #f3dd9a; --gold-3: #8a6a2a;
  --ember: #ff7a1a; --crimson: #b3122e; --azure: #4cc3ff;
  --bg: #07060b; --surface: #110f18; --text: #ece6d6; --muted: #b3a990;
}
html { scroll-behavior: smooth; }
body { background: var(--bg); color: var(--text); }
::selection { background: rgba(217, 180, 90, .35); }

/* Texto dorado metalico con brillo que recorre */
.text-gold {
  background: linear-gradient(100deg, #7a5a22 0%, var(--gold) 22%, var(--gold-2) 40%, #fff6d8 50%, var(--gold-2) 60%, var(--gold) 78%, #7a5a22 100%);
  background-size: 250% 100%;
  -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: shimmer 7s linear infinite;
}
@keyframes shimmer { from { background-position: 150% 0; } to { background-position: -100% 0; } }
.title-glow { filter: drop-shadow(0 0 18px rgba(217, 180, 90, .35)) drop-shadow(0 2px 0 rgba(0, 0, 0, .8)); }

/* Marco tipo interfaz de MU: borde dorado biselado + esquinas */
.mu-frame {
  position: relative; background: linear-gradient(180deg, rgba(24, 20, 32, .92), rgba(10, 9, 15, .94));
  border: 1px solid rgba(217, 180, 90, .35);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .7), inset 0 1px 0 rgba(255, 230, 160, .08), 0 20px 50px -20px rgba(0, 0, 0, .9);
}
.mu-frame::before, .mu-frame::after {
  content: ""; position: absolute; width: 18px; height: 18px; border: 2px solid var(--gold); pointer-events: none; opacity: .9;
}
.mu-frame::before { top: -2px; left: -2px; border-right: 0; border-bottom: 0; }
.mu-frame::after { bottom: -2px; right: -2px; border-left: 0; border-top: 0; }

/* Boton dorado */
.btn-gold {
  position: relative; overflow: hidden; color: #1a1206; font-weight: 700; letter-spacing: .08em;
  background: linear-gradient(180deg, #fbe7a8 0%, #d9b45a 45%, #9c7428 100%);
  border: 1px solid #fff0c0; box-shadow: 0 0 0 1px #5c4313, 0 8px 24px -8px rgba(217, 180, 90, .6);
  transition: box-shadow .25s, filter .25s;
}
.btn-gold:hover { filter: brightness(1.08); box-shadow: 0 0 0 1px #5c4313, 0 0 32px rgba(255, 200, 100, .55); }
.btn-gold::after {
  content: ""; position: absolute; inset: 0; transform: translateX(-120%) skewX(-20deg);
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .65), transparent); transition: transform .7s;
}
.btn-gold:hover::after { transform: translateX(160%) skewX(-20deg); }
.btn-ghost { border: 1px solid rgba(217, 180, 90, .55); color: var(--gold-2); background: rgba(10, 8, 14, .55); transition: background .25s, color .25s, box-shadow .25s; }
.btn-ghost:hover { background: rgba(217, 180, 90, .14); color: #fff; box-shadow: 0 0 22px rgba(217, 180, 90, .25); }

/* Hero: zoom lento + niebla */
.kenburns { animation: kenburns 28s ease-in-out infinite alternate; transform-origin: 60% 40%; }
@keyframes kenburns { from { transform: scale(1.06) translate3d(0, 0, 0); } to { transform: scale(1.18) translate3d(-1.5%, -1%, 0); } }
.mist { position: absolute; inset: -20% -50%; background: radial-gradient(ellipse at 30% 60%, rgba(140, 120, 200, .16), transparent 55%), radial-gradient(ellipse at 70% 70%, rgba(255, 140, 60, .10), transparent 60%); animation: mist 22s ease-in-out infinite alternate; pointer-events: none; }
.mist.m2 { animation-duration: 34s; animation-direction: alternate-reverse; opacity: .7; }
@keyframes mist { from { transform: translateX(-6%); } to { transform: translateX(6%); } }
.vignette { background: radial-gradient(ellipse at center, transparent 35%, rgba(4, 3, 7, .75) 80%, #07060b 100%); }

/* Rayo que cruza el hero de vez en cuando */
.lightning { position: absolute; inset: 0; background: radial-gradient(circle at 30% 10%, rgba(200, 210, 255, .55), transparent 40%); opacity: 0; animation: flash 9s infinite; mix-blend-mode: screen; pointer-events: none; }
@keyframes flash { 0%, 91%, 100% { opacity: 0; } 92% { opacity: .9; } 93% { opacity: .1; } 94% { opacity: .7; } 96% { opacity: 0; } }

/* Aparicion al hacer scroll */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .8s cubic-bezier(.2, .7, .2, 1), transform .8s cubic-bezier(.2, .7, .2, 1); }
.reveal.in { opacity: 1; transform: none; }
.reveal.d1 { transition-delay: .1s; } .reveal.d2 { transition-delay: .2s; } .reveal.d3 { transition-delay: .3s; }

/* Tarjeta de evento */
.event-card img { transition: transform .8s cubic-bezier(.2, .7, .2, 1), filter .5s; filter: saturate(.9) brightness(.75); }
.event-card:hover img { transform: scale(1.08); filter: saturate(1.15) brightness(.95); }
.event-card { transition: box-shadow .3s, border-color .3s; }
.event-card:hover { box-shadow: 0 0 0 1px rgba(217, 180, 90, .7), 0 0 40px -6px rgba(217, 180, 90, .45); }
.event-card.live { box-shadow: 0 0 0 1px rgba(255, 90, 60, .9), 0 0 36px -4px rgba(255, 70, 40, .55); }
.pulse-dot { position: relative; }
.pulse-dot::after { content: ""; position: absolute; inset: -4px; border-radius: 9999px; border: 2px solid currentColor; animation: ping 1.6s cubic-bezier(0, 0, .2, 1) infinite; }
@keyframes ping { 75%, 100% { transform: scale(2.2); opacity: 0; } }

/* Cartel de buscado */
.wanted {
  background: radial-gradient(ellipse at 50% 40%, #e9d6a8 0%, #cdb27a 60%, #9c7d45 100%);
  color: #2b1d0b; box-shadow: inset 0 0 40px rgba(80, 50, 10, .55), 0 25px 50px -15px rgba(0, 0, 0, .9);
  transform: rotate(-2deg); animation: sway 6s ease-in-out infinite;
}
@keyframes sway { 0%, 100% { transform: rotate(-2deg); } 50% { transform: rotate(1.2deg); } }
.wanted-photo { box-shadow: inset 0 0 18px rgba(40, 25, 5, .7); }
.wanted-photo img { filter: sepia(.55) contrast(1.08) brightness(.92); mix-blend-mode: multiply; transition: filter .4s; }
.wanted:hover .wanted-photo img { filter: sepia(.15) contrast(1.1); }
.wanted .stamp { border: 3px solid #8b1a1a; color: #8b1a1a; transform: rotate(-12deg); }

/* Anillo del Eclipse */
.eclipse-ring { animation: spin 40s linear infinite; }
.eclipse-core { box-shadow: 0 0 60px 18px rgba(179, 18, 46, .55), inset 0 0 40px rgba(0, 0, 0, .9); }
@keyframes spin { to { transform: rotate(360deg); } }
.champion {
  background: radial-gradient(circle at 50% 35%, #2a2233, #0b0910 70%);
  border: 1px solid rgba(217, 180, 90, .5);
  box-shadow: 0 0 0 3px rgba(0, 0, 0, .55), 0 8px 20px -6px #000, inset 0 0 12px rgba(217, 180, 90, .12);
  transition: transform .3s, border-color .3s, box-shadow .3s;
}
.champion:hover { transform: scale(1.08); }
/* Derrotado: anillo carmesi, nombre apagado y un tajo rojo cruzado */
.champion.down {
  background: radial-gradient(circle at 50% 35%, #2c0e14, #0a0608 70%);
  border-color: rgba(208, 28, 52, .75); color: rgba(240, 220, 190, .45);
  box-shadow: 0 0 0 3px rgba(0, 0, 0, .55), 0 0 16px rgba(208, 28, 52, .45), inset 0 0 14px rgba(208, 28, 52, .25);
}
.champion.down::before {
  content: ""; position: absolute; left: 10%; right: 10%; top: 50%; height: 2px; margin-top: -1px;
  background: linear-gradient(90deg, transparent, #e0213c 20%, #e0213c 80%, transparent);
  box-shadow: 0 0 6px #e0213c; transform: rotate(-35deg); pointer-events: none;
}

/* Tabla de rankings */
.rank-row { transition: background .2s; }
.rank-row:hover { background: rgba(217, 180, 90, .08); }
.medal-1 { background: linear-gradient(180deg, #ffe9a3, #c99a2e); color: #2a1a00; }
.medal-2 { background: linear-gradient(180deg, #f2f4f7, #9aa3ad); color: #1c2026; }
.medal-3 { background: linear-gradient(180deg, #f3c9a1, #a86a36); color: #2a1406; }

/* Separador ornamental */
.divider { height: 1px; background: linear-gradient(90deg, transparent, rgba(217, 180, 90, .8), transparent); }

/* Lienzo de brasas */
#embers { position: absolute; inset: 0; pointer-events: none; }

/* Inputs */
.mu-input { background: rgba(6, 5, 10, .8); border: 1px solid rgba(217, 180, 90, .3); color: var(--text); transition: border-color .2s, box-shadow .2s; }
.mu-input:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px rgba(217, 180, 90, .2); }
.mu-input.bad { border-color: #e2465a; box-shadow: 0 0 0 3px rgba(226, 70, 90, .18); }

:focus-visible { outline: 2px solid var(--gold-2); outline-offset: 3px; }
[x-cloak] { display: none !important; }


/* Popup fin de semana */
.wk-card { box-shadow: 0 0 0 1px rgba(217, 180, 90, .5), 0 30px 90px -20px rgba(255, 90, 30, .45), 0 0 120px -30px rgba(179, 18, 46, .6); }
.wk-seal { padding: .55rem .9rem; color: #2a1606; background: linear-gradient(180deg, #fbe7a8, #c99a2e); border: 1px solid #fff0c0;
  box-shadow: 0 0 0 1px #5c4313, 0 10px 30px -8px rgba(0, 0, 0, .8), 0 0 30px rgba(255, 190, 90, .35); transform: rotate(-4deg); animation: seal 3.2s ease-in-out infinite; }
@keyframes seal { 0%, 100% { transform: rotate(-4deg) scale(1); } 50% { transform: rotate(-2deg) scale(1.04); } }
.wk-hint { opacity: 0; transform: translateX(14px); filter: blur(4px); animation: hint .7s cubic-bezier(.2, .7, .2, 1) forwards; }
@keyframes hint { to { opacity: 1; transform: none; filter: none; } }

/* Gema del Eclipse */
.gem-icon { filter: drop-shadow(0 0 12px rgba(255, 110, 60, .55)); animation: gem 4s ease-in-out infinite; }
@keyframes gem { 0%, 100% { transform: translateY(0) rotate(-4deg); } 50% { transform: translateY(-4px) rotate(4deg); filter: drop-shadow(0 0 22px rgba(255, 170, 80, .8)); } }

/* Webshop */
.shop-card { transition: box-shadow .25s, transform .25s; }
.shop-card:hover { box-shadow: 0 0 0 1px rgba(217, 180, 90, .7), 0 0 34px -8px rgba(217, 180, 90, .5); transform: translateY(-2px); }
.shop-ico { filter: drop-shadow(0 0 10px currentColor); transition: transform .4s; }
.shop-card:hover .shop-ico { transform: scale(1.12) rotate(-6deg); }
.opt-chip { display: flex; align-items: center; min-height: 2.75rem; padding: 0 .9rem; border-radius: .375rem; border: 1px solid rgba(217, 180, 90, .2);
  background: rgba(0, 0, 0, .3); color: rgba(236, 230, 214, .75); font-size: .875rem; cursor: pointer; transition: border-color .2s, background .2s, color .2s; }
.opt-chip:hover { border-color: rgba(217, 180, 90, .5); }
.opt-chip.on { border-color: rgba(217, 180, 90, .9); background: rgba(217, 180, 90, .14); color: #f3dd9a; }
.opt-chip.exc.on { border-color: rgba(52, 211, 153, .8); background: rgba(52, 211, 153, .1); color: #6ee7b7; }
.mu-tooltip { background: rgba(4, 4, 8, .92); border: 1px solid rgba(160, 140, 90, .45); padding: .9rem 1rem; font-size: .82rem; line-height: 1.55;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .8), 0 10px 30px -10px rgba(0, 0, 0, .9); }

/* Imagenes de items (renders del cliente) */
.item-stage { background: radial-gradient(circle at 50% 55%, rgba(217, 180, 90, .14), transparent 62%); border-radius: .5rem; }
.item-img { filter: drop-shadow(0 6px 14px rgba(0, 0, 0, .7)) drop-shadow(0 0 10px rgba(217, 180, 90, .15)); transition: transform .35s cubic-bezier(.2, .7, .2, 1), filter .35s; }
.shop-card:hover .item-img, .item-stage:hover .item-img { transform: scale(1.08) rotate(-3deg); filter: drop-shadow(0 8px 18px rgba(0, 0, 0, .8)) drop-shadow(0 0 16px rgba(243, 221, 154, .35)); }
.shop-card .item-img + .shop-ico { display: none; }

/* Editor del logo de clan */
.gm-grid { background: rgba(217, 180, 90, .25); }
.gm-cell { transition: filter .12s; }
.gm-cell:hover { filter: brightness(1.35); outline: 1px solid rgba(243, 221, 154, .8); outline-offset: -1px; }
.gm-canvas { image-rendering: pixelated; }

/* Panel lateral "Top del server" */
.tops-tab { box-shadow: -6px 0 24px -6px rgba(217, 180, 90, .35); }
.tops-tab::before { content: ""; position: absolute; inset: -1px; border-radius: inherit; pointer-events: none; box-shadow: 0 0 0 1px rgba(217, 180, 90, .25); animation: topsPulse 2.8s ease-in-out infinite; }
@keyframes topsPulse { 0%, 100% { opacity: .2; } 50% { opacity: 1; } }
.tops-panel { background-image: radial-gradient(120% 60% at 100% 0%, rgba(179, 18, 46, .18), transparent 60%), radial-gradient(90% 50% at 0% 100%, rgba(217, 180, 90, .08), transparent 60%); }
[x-show="open"]:not([style*="none"]) .tops-card { animation: topsIn .35s ease-out both; }
@keyframes topsIn { from { opacity: 0; transform: translateX(16px); } to { opacity: 1; transform: none; } }

/* Asistente "Caren": lanzador con levitacion, aura y despertar al abrir el chat */
.caren { display: block; width: max-content; }
.caren-img { animation: carenFloat 3.6s ease-in-out infinite; filter: drop-shadow(0 6px 14px rgba(0, 0, 0, .7)) drop-shadow(0 0 10px rgba(217, 180, 90, .25)); transform-origin: 50% 100%; transition: filter .3s; }
.caren:hover .caren-img, .caren:focus-visible .caren-img { filter: drop-shadow(0 6px 14px rgba(0, 0, 0, .7)) drop-shadow(0 0 16px rgba(243, 221, 154, .65)); }
.caren:hover .caren-tag { color: #fff; border-color: #d9b45a; }
@keyframes carenFloat { 0%, 100% { transform: translateY(0) rotate(-1deg); } 50% { transform: translateY(-8px) rotate(1deg); } }
.caren-shadow { position: absolute; left: 50%; bottom: 0; width: 70%; height: 10px; margin-left: -35%; border-radius: 50%; background: radial-gradient(rgba(0, 0, 0, .65), transparent 70%); animation: carenShadow 3.6s ease-in-out infinite; }
@keyframes carenShadow { 0%, 100% { transform: scaleX(1); opacity: .9; } 50% { transform: scaleX(.75); opacity: .5; } }
.caren-aura { position: absolute; left: 50%; bottom: 8%; width: 150%; aspect-ratio: 1; transform: translateX(-50%); border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle, rgba(217, 180, 90, .28), rgba(179, 18, 46, .12) 45%, transparent 68%); animation: carenAura 3.6s ease-in-out infinite; }
@keyframes carenAura { 0%, 100% { opacity: .55; transform: translateX(-50%) scale(.92); } 50% { opacity: 1; transform: translateX(-50%) scale(1.05); } }
/* Despertar: salto con giro, destello y chispas */
.caren.is-waking .caren-img { animation: carenWake .65s cubic-bezier(.3, 1.6, .5, 1) both; }
@keyframes carenWake { 0% { transform: translateY(0) scale(1); } 35% { transform: translateY(-26px) scale(1.12) rotate(-6deg); filter: brightness(1.6) drop-shadow(0 0 24px #f3dd9a); } 70% { transform: translateY(-6px) scale(1.04) rotate(3deg); } 100% { transform: translateY(0) scale(1); } }
.caren.is-waking .caren-aura { animation: carenFlash .65s ease-out both; }
@keyframes carenFlash { 0% { opacity: 1; transform: translateX(-50%) scale(.6); } 60% { opacity: 1; transform: translateX(-50%) scale(1.7); } 100% { opacity: 0; transform: translateX(-50%) scale(2.1); } }
.caren-burst { position: absolute; left: 50%; top: 40%; pointer-events: none; }
.caren-burst i { position: absolute; width: 6px; height: 6px; border-radius: 50%; background: #f3dd9a; box-shadow: 0 0 8px #ff7a1a, 0 0 2px #fff; opacity: 0; }
.caren.is-waking .caren-burst i { animation: carenSpark .7s ease-out both; }
.caren-burst i:nth-child(1) { --x: -70px; --y: -60px; } .caren-burst i:nth-child(2) { --x: 60px; --y: -75px; animation-delay: .05s !important; }
.caren-burst i:nth-child(3) { --x: -85px; --y: 10px; animation-delay: .08s !important; } .caren-burst i:nth-child(4) { --x: 80px; --y: -5px; animation-delay: .03s !important; }
.caren-burst i:nth-child(5) { --x: -30px; --y: -100px; animation-delay: .1s !important; } .caren-burst i:nth-child(6) { --x: 30px; --y: -110px; animation-delay: .06s !important; }
@keyframes carenSpark { 0% { opacity: 1; transform: translate(0, 0) scale(1.4); } 100% { opacity: 0; transform: translate(var(--x), var(--y)) scale(.3); } }
/* Con el chat abierto: inclinada hacia el chat, aura constante */
.caren.is-open .caren-img { animation: carenTalk 2.4s ease-in-out infinite; }
@keyframes carenTalk { 0%, 100% { transform: translateY(-2px) rotate(-3deg); } 50% { transform: translateY(-6px) rotate(-1deg); } }
.caren.is-open .caren-tag { opacity: 0; }
.caren-tag { transition: opacity .2s, color .2s, border-color .2s; }
@media (max-width: 639px) { .caren.is-open { opacity: 0; pointer-events: none; } }
/* Chat */
.caren-chat { background-image: radial-gradient(110% 50% at 100% 0%, rgba(179, 18, 46, .14), transparent 60%); }
.caren-log a, .caren-log [data-contact] { color: #f3dd9a; text-decoration: underline; text-underline-offset: 2px; cursor: pointer; }
.caren-log code { color: #ff7a1a; font-family: ui-monospace, monospace; font-size: .85em; }
.caren-msg { animation: carenMsg .25s ease-out both; }
@keyframes carenMsg { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.caren-typing { display: flex; gap: 4px; }
.caren-typing i { width: 6px; height: 6px; border-radius: 50%; background: #d9b45a; animation: carenDot 1s infinite ease-in-out; }
.caren-typing i:nth-child(2) { animation-delay: .15s; } .caren-typing i:nth-child(3) { animation-delay: .3s; }
@keyframes carenDot { 0%, 80%, 100% { opacity: .3; transform: translateY(0); } 40% { opacity: 1; transform: translateY(-4px); } }
.caren-chips { scrollbar-width: thin; scrollbar-color: rgba(217, 180, 90, .4) transparent; }
