@keyframes petEvolvePulse {
    0%,100% { box-shadow: 0 0 6px rgba(74,222,128,.4); }
    50%      { box-shadow: 0 0 16px rgba(74,222,128,.9), 0 0 30px rgba(74,222,128,.3); }
}

/* ── Buff Tooltip ── */
.buff-tooltip {
    position: fixed;
    z-index: 9999;
    background: linear-gradient(160deg, #0d1117 0%, #1a1040 100%);
    border: 1px solid rgba(167,139,250,.4);
    border-radius: 9px;
    padding: 10px 13px;
    font-family: 'Outfit', sans-serif;
    color: #e2e8f0;
    pointer-events: none;
    min-width: 170px;
    max-width: 220px;
    box-shadow: 0 8px 28px rgba(0,0,0,.7), 0 0 0 1px rgba(0,0,0,.5);
    transition: opacity .1s;
}
.buff-tooltip.hidden { opacity: 0; pointer-events: none; }

:root {
    --bg-color: #0d0d1a;
    --panel-bg: linear-gradient(180deg, #1a2a4a 0%, #0d1a2d 100%);
    --accent-color: #f9d423; /* Gold */
    --accent-secondary: #ff4e50;
    --text-color: #f0f0f0;
    --glass-border: #f9d423;
    --panel-shadow: 0 0 0 2px #000, 0 0 0 4px #f9d423, 0 0 20px rgba(0,0,0,0.8);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Outfit', 'Inter', -apple-system, sans-serif;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    overflow: hidden;
    width: 100vw;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: url('assets/cursor.png') 0 0, default;
}

#game-container {
    position: relative;
    width: 100%;
    height: 100%;
    background: #050508;
    overflow: hidden;
}

#parallax-bg {
    position: absolute;
    top: -10%;
    left: -10%;
    width: 120%;
    height: 120%;
    background: url('aetheria_mountain_bg.png') center/cover no-repeat;
    filter: blur(2px) brightness(0.4) saturate(0.8);
    z-index: 1;
    pointer-events: none;
    transition: background 1.5s ease;
}

#parallax-bg::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at center, transparent 20%, #050508 100%);
    opacity: 0.8;
}

.vignette {
    position: fixed;
    inset: 0;
    pointer-events: none;
    background: radial-gradient(circle, transparent 40%, rgba(0,0,0,0.7) 100%);
    z-index: 150; 
}

canvas {
    position: relative;
    z-index: 5;
    display: block;
    cursor: url('assets/target_reticle.png') 16 16, crosshair;
    image-rendering: pixelated;
    image-rendering: crisp-edges;
}

/* Scanlines Effect */
#game-container::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.1) 50%), linear-gradient(90deg, rgba(255, 0, 0, 0.02), rgba(0, 255, 0, 0.01), rgba(0, 0, 255, 0.02));
    background-size: 100% 3px, 3px 100%;
    pointer-events: none;
    z-index: 101;
    opacity: 0.5;
}

/* UI Elements */
.hud {
    position: absolute;
    top: 0;
    left: 0;
    pointer-events: none;
    z-index: 200; /* Asegura que esté por encima de la viñeta y las scanlines (z-index: 101) */
    width: 100%;
    height: 100%;
    padding: 2rem;
}

.hud-panel {
    pointer-events: auto;
    background: var(--panel-bg);
    border-radius: 4px;
    padding: 1rem;
    box-shadow: var(--panel-shadow);
    border: 2px solid #000;
}

/* Top Left: Character Info */
.char-info {
    position: absolute;
    top: 2rem;
    left: 2rem;
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    pointer-events: auto;
}

.avatar {
    width: 64px;
    height: 64px;
    background: #1a2a4a;
    border: 3px solid var(--accent-color);
    box-shadow: 0 0 10px rgba(249, 212, 35, 0.5);
    border-radius: 4px;
    overflow: hidden;
}

.stats-container {
    display: flex;
    flex-direction: column;
    gap: 4px;
    background: rgba(0,0,0,0.4);
    padding: 0.5rem;
    border-radius: 4px;
    border: 1px solid rgba(255,255,255,0.1);
}

.bar {
    width: 150px;
    height: 10px;
    background: #000;
    border: 1px solid #444;
    border-radius: 2px;
    overflow: hidden;
    position: relative;
}

.hp-fill {
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, #d31027, #ea384d);
    box-shadow: inset 0 0 5px rgba(0,0,0,0.5);
}

.mp-fill {
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, #0052d4, #6fb1fc);
    box-shadow: inset 0 0 5px rgba(0,0,0,0.5);
}

/* ── Energy Bars HUD (HP/MP/SP redesign) ── */
.energy-frame {
    display: flex;
    flex-direction: column;
    gap: 5px;
    padding: 8px 10px;
    background: linear-gradient(160deg, rgba(8,8,20,0.92) 0%, rgba(20,10,30,0.88) 100%);
    border-radius: 6px;
    border: 1px solid rgba(180,140,60,0.45);
    box-shadow:
        0 0 0 1px rgba(0,0,0,0.8),
        inset 0 1px 0 rgba(255,220,100,0.08),
        0 4px 12px rgba(0,0,0,0.6);
}

.energy-row {
    display: flex;
    align-items: center;
    gap: 6px;
}

.energy-label {
    font-size: 0.65rem;
    font-weight: bold;
    width: 20px;
    text-align: right;
    text-shadow: 0 1px 3px rgba(0,0,0,0.9);
    flex-shrink: 0;
    letter-spacing: 0.5px;
}

.energy-label.lbl-hp { color: #ff7070; }
.energy-label.lbl-mp { color: #6fb1fc; }
.energy-label.lbl-sp { color: #38ea5b; }

.energy-bar {
    position: relative;
    width: 140px;
    height: 16px;
    background: rgba(0,0,0,0.7);
    border-radius: 3px;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,0.08);
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.8);
    flex-shrink: 0;
}

.energy-fill {
    position: absolute;
    top: 0; left: 0;
    height: 100%;
    width: 100%;
}

.energy-fill.hp-fill {
    background: linear-gradient(90deg, #8b0000 0%, #d31027 50%, #ea384d 100%);
    box-shadow: inset 0 1px 0 rgba(255,180,180,0.25), 0 0 6px rgba(211,16,39,0.4);
}

.energy-fill.mp-fill {
    background: linear-gradient(90deg, #001a6e 0%, #0052d4 50%, #6fb1fc 100%);
    box-shadow: inset 0 1px 0 rgba(150,200,255,0.2), 0 0 6px rgba(0,82,212,0.4);
}

.energy-fill.sp-fill {
    background: linear-gradient(90deg, #005c1a 0%, #10d33a 50%, #38ea5b 100%);
    box-shadow: inset 0 1px 0 rgba(100,255,140,0.2), 0 0 6px rgba(16,211,58,0.4);
}

.energy-bar-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 0.6rem;
    font-weight: bold;
    color: #fff;
    text-shadow: 0 0 3px rgba(0,0,0,1), 1px 1px 2px rgba(0,0,0,0.9);
    white-space: nowrap;
    pointer-events: none;
    letter-spacing: 0.3px;
    z-index: 1;
}

/* ── Status Effects Bar (Shaiya style) — fuera del recuadro, columnas ── */
.effect-slot {
    position: relative;
    width: 34px;
    height: 34px;
    border-radius: 6px;
    border: 1px solid var(--slot-color, #555);
    background: rgba(10, 14, 28, 0.88);
    box-shadow: 0 0 6px var(--slot-glow, rgba(0,0,0,0));
    cursor: default;
    flex-shrink: 0;
    overflow: hidden;
}
.effect-slot .effect-icon {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.05rem;
    z-index: 2;
    pointer-events: none;
    line-height: 1;
}
/* Radial countdown sweep — drawn with conic-gradient */
.effect-slot .effect-sweep {
    position: absolute;
    inset: 0;
    border-radius: 5px;
    background: conic-gradient(
        rgba(0,0,0,0) calc(var(--pct, 1) * 360deg),
        rgba(0,0,0,0.62) calc(var(--pct, 1) * 360deg)
    );
    z-index: 3;
    pointer-events: none;
}
/* Remaining seconds at bottom */
.effect-slot .effect-timer {
    position: absolute;
    bottom: 1px;
    left: 0; right: 0;
    text-align: center;
    font-size: 0.55rem;
    font-weight: 700;
    color: #fff;
    text-shadow: 0 0 3px #000, 0 0 6px #000;
    z-index: 4;
    pointer-events: none;
    line-height: 1;
}
/* Tooltip on hover */
.effect-slot::after {
    content: attr(data-tip);
    position: absolute;
    bottom: calc(100% + 6px);
    left: 50%;
    transform: translateX(-50%);
    background: rgba(10,14,28,0.95);
    border: 1px solid rgba(255,255,255,0.2);
    color: #e0e0e0;
    font-size: 0.65rem;
    white-space: nowrap;
    padding: 3px 7px;
    border-radius: 5px;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.15s;
    z-index: 9999;
}
.effect-slot:hover::after { opacity: 1; }

/* Buff slots — green/gold border */
.effect-slot.is-buff  { --slot-color: rgba(39,174,96,0.8);  --slot-glow: rgba(39,174,96,0.3); }
/* Debuff slots — red border */
.effect-slot.is-debuff { --slot-color: rgba(231,76,60,0.8); --slot-glow: rgba(231,76,60,0.3); }

/* Admin HUD button */
#_adm-hud-btn:hover {
    background: linear-gradient(135deg, #2a2a4e, #3a2a1e) !important;
    border-color: #f9d423 !important;
    color: #f9d423 !important;
    box-shadow: 0 0 16px rgba(200,169,110,0.5) !important;
}

/* Bottom Center: Action Bar */
.action-bar {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 0.75rem;
    pointer-events: auto; /* Permite hacer clic en las habilidades */
}

.skill-slot {
    width: 50px;
    height: 50px;
    background: rgba(40, 40, 50, 0.8);
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 0.8rem;
    font-weight: bold;
    color: rgba(255, 255, 255, 0.5);
    transition: all 0.2s ease;
    cursor: url('assets/cursor.png') 0 0, pointer;
    position: relative;
    overflow: hidden;
}

.skill-slot:hover {
    border-color: var(--accent-color);
    transform: translateY(-5px);
    color: white;
}

/* Skill tooltip flotante */
#skill-tooltip {
    display: none;
    position: fixed;
    z-index: 9999;
    background: rgba(10, 14, 28, 0.97);
    border: 1px solid rgba(249, 212, 35, 0.45);
    border-radius: 8px;
    padding: 9px 12px;
    min-width: 190px;
    max-width: 240px;
    pointer-events: none;
    font-size: 0.72rem;
    color: #d0d8e8;
    box-shadow: 0 4px 18px rgba(0,0,0,0.6);
    line-height: 1.4;
}
#skill-tooltip .st-name {
    font-size: 0.82rem;
    font-weight: 700;
    color: #f9d423;
    margin-bottom: 5px;
}
#skill-tooltip .st-desc {
    margin-bottom: 7px;
    color: #b8c4d8;
}
#skill-tooltip .st-costs {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    font-size: 0.68rem;
    color: #7ec8e3;
    border-top: 1px solid rgba(255,255,255,0.08);
    padding-top: 5px;
}
#skill-tooltip .st-lock {
    margin-top: 5px;
    color: #f87171;
    font-size: 0.68rem;
}

.skill-icon {
    position: relative;
    z-index: 2;
    pointer-events: none;
}

/* Radial sweep de cooldown — se muestra sobre el botón mientras el cooldown está activo */
.cd-overlay {
    display: none;
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: conic-gradient(from -90deg, rgba(0,0,0,0.78) var(--cd-pct, 0%), transparent var(--cd-pct, 0%));
    pointer-events: none;
    z-index: 1;
}

/* Bottom Left: Chat */
.chat-panel {
    position: absolute;
    bottom: 2rem;
    left: 2rem;
    width: 380px;
    height: 160px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    background: rgba(15, 20, 35, 0.1); /* Prácticamente transparente por defecto */
    border: 2px solid transparent; /* Sin borde molesto */
    box-shadow: none; /* Sin sombra por defecto */
    padding: 1rem;
    border-radius: 6px;
    pointer-events: auto; /* Permite enfocar el input y escribir */
    transition: background 0.3s cubic-bezier(0.4, 0, 0.2, 1), border-color 0.3s, box-shadow 0.3s;
    backdrop-filter: blur(0px);
    -webkit-backdrop-filter: blur(0px);
}

/* Cuando el usuario enfoca el chat o su input, se activa el fondo premium translúcido */
.chat-panel:focus-within {
    background: var(--panel-bg);
    border: 2px solid #000;
    box-shadow: var(--panel-shadow);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.chat-messages {
    flex-grow: 1;
    font-size: 0.9rem;
    overflow-y: hidden;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    color: #fff;
    text-shadow: 1px 1px 2px #000; /* Mejor legibilidad de las letras sobre el fondo transparente */
}

#chat-input {
    width: 100%;
    margin-top: 1rem;
    padding: 0.75rem;
    background: rgba(255, 255, 255, 0.95);
    border: 2px solid var(--accent-color);
    border-radius: 6px;
    color: #000;
    font-size: 1rem;
    font-weight: bold;
    outline: none;
    box-shadow: 0 0 15px rgba(249, 212, 35, 0.2);
    font-family: 'Outfit', sans-serif;
    position: relative;
    z-index: 1000;
    pointer-events: auto;
    opacity: 0.3; /* Transparente hasta que se interactúa */
    transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.3s;
}

/* El input se ilumina por completo al enfocarse */
#chat-input:focus {
    opacity: 1;
    box-shadow: 0 0 25px var(--accent-color);
}

/* Al pasar el cursor por encima o enfocar el chat, revela la barra de input */
.chat-panel:hover #chat-input {
    opacity: 0.7;
}
.chat-panel:focus-within #chat-input {
    opacity: 1;
}

.chat-msg {
    animation: fadeIn 0.3s ease;
}

.msg-npc {
    color: #4df3ff;
    font-style: italic;
    text-shadow: 0 0 5px rgba(77, 243, 255, 0.4);
    border-left: 2px solid #4df3ff;
    padding-left: 8px;
    margin: 4px 0;
}
.msg-system { color: #aaa; font-size: 0.9em; }
.msg-player { color: #a8e6cf; }
.msg-whisper { color: #f472b6; font-style: italic; font-weight: bold; }
.msg-gold { color: #ffd700; font-weight: bold; font-size: 0.9em; }
.msg-guild { color: #2ecc71; font-weight: 500; }

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(5px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Instructions */
.controls-hint {
    position: absolute;
    top: 2rem;
    right: 2rem;
    text-align: right;
    font-size: 0.9rem;
    opacity: 0.7;
}

/* Glassmorphism Window Style */
.window { 
    position: absolute; 
    background: rgba(15, 20, 35, 0.85); 
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.1); 
    border-top: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 12px; 
    box-shadow: 0 15px 35px rgba(0,0,0,0.5), inset 0 0 20px rgba(255,255,255,0.05); 
    display: flex; 
    flex-direction: column; 
    pointer-events: auto; 
    z-index: 3000; 
    overflow: hidden;
    transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.2s ease;
}

.window.hidden { 
    display: none; 
    opacity: 0;
    transform: translate(-50%, -45%) scale(0.95);
}

.window-header { 
    background: rgba(255, 255, 255, 0.05);
    padding: 10px 15px; 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    border-bottom: 1px solid rgba(255,255,255,0.1); 
    font-weight: 700; 
    font-size: 0.9rem;
    color: var(--accent-color);
    letter-spacing: 0.5px;
    cursor: move;
    user-select: none;
}

.window-header button { 
    background: rgba(255, 77, 77, 0.2); 
    border: 1px solid rgba(255, 77, 77, 0.4); 
    color: #ff4d4d; 
    font-weight: bold; 
    border-radius: 6px; 
    padding: 4px 8px; 
    cursor: url('assets/cursor.png') 0 0, pointer; 
    transition: 0.2s;
}
.window-header button:hover {
    background: #ff4d4d;
    color: white;
}

.window-content { display: flex; flex: 1; padding: 15px; gap: 15px; overflow: hidden; min-height: 0; }

/* Slots Re-Design */
.bag-slot, .eq-slot {
    width: 38px;
    height: 38px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    cursor: url('assets/cursor.png') 0 0, pointer;
    transition: transform 0.15s ease;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: inset 0 0 5px rgba(0,0,0,0.3);
    position: relative; /* CRÍTICO: Para que el +X se quede dentro */
}

/* Slot de equipo con objeto equipado: Fondo suave y sin cambio de tamaño */
.eq-slot.active-item {
    background: rgba(255, 255, 255, 0.2) !important;
    border-color: rgba(255, 255, 255, 0.5);
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.2);
    z-index: 5;
}

.eq-slot.active-item span {
    filter: drop-shadow(0 0 3px rgba(255,255,255,0.4));
}

.eq-slot.active-item span {
    filter: drop-shadow(0 0 2px rgba(0,0,0,0.5));
}

.bag-slot:hover, .eq-slot:hover { 
    background: rgba(255, 255, 255, 0.08); 
    border-color: var(--accent-color);
    transform: scale(1.05);
    z-index: 10;
    box-shadow: 0 0 15px rgba(249, 212, 35, 0.3);
}

.eq-slot {
    background: rgba(0, 0, 0, 0.4);
    border-color: rgba(249, 212, 35, 0.4);
}

.eq-slot::before { 
    content: attr(data-placeholder); 
    position: absolute; 
    font-size: 18px; 
    opacity: 0.2; 
    pointer-events: none; 
}

/* Drag & Drop Visuals */
.dragging {
    opacity: 0.4;
    transform: scale(0.8);
}

.drag-over {
    border: 2px solid var(--accent-color) !important;
    background: rgba(249, 212, 35, 0.1) !important;
    box-shadow: 0 0 20px rgba(249, 212, 35, 0.4) !important;
}

/* Enchantment Specific */
.enchant-slot {
    background: rgba(142, 68, 173, 0.05);
    border-color: rgba(142, 68, 173, 0.3);
}

.enchant-slot.active {
    border-color: #9b59b6;
    box-shadow: 0 0 15px rgba(155, 89, 182, 0.5);
    animation: pulseEnchant 2s infinite;
}

@keyframes pulseEnchant {
    0% { box-shadow: 0 0 5px rgba(155, 89, 182, 0.4); }
    50% { box-shadow: 0 0 20px rgba(155, 89, 182, 0.8); }
    100% { box-shadow: 0 0 5px rgba(155, 89, 182, 0.4); }
}

.bag-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 4px;
    overflow-y: auto;
    overflow-x: hidden;
    align-content: start;
    min-height: 0;
}

/* Tabs de Inventario */
.inventory-tabs {
    display: flex;
    gap: 4px;
    margin-bottom: 8px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    padding-bottom: 4px;
}

.inv-tab {
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    color: #888;
    padding: 4px 8px;
    border-radius: 4px 4px 0 0;
    font-size: 0.6rem;
    cursor: url('assets/cursor.png') 0 0, pointer;
    transition: all 0.2s;
    font-family: 'Outfit', sans-serif;
    font-weight: bold;
}

.inv-tab.active {
    background: rgba(155, 89, 182, 0.2);
    color: #f1c40f;
    border-bottom: 2px solid #f1c40f;
}

.inv-tab.locked-tab {
    opacity: 0.4;
    cursor: not-allowed;
}

.inv-tab:hover:not(.locked-tab) {
    background: rgba(255,255,255,0.12);
    color: white;
}

/* Minimap wrapper */
#minimap-area {
    position: absolute;
    top: 2rem;
    right: 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    pointer-events: auto;
    z-index: 350;
}
#minimap-container { position: relative; width: 160px; height: 160px; border-radius: 50%; border: 3px solid #f9d423; box-shadow: 0 0 15px rgba(0,0,0,0.8), inset 0 0 20px rgba(0,0,0,0.9); overflow: hidden; background: rgba(10,10,15,0.9); }
#minimap-canvas { width: 100%; height: 100%; }
#minimap-actions { display: flex; gap: 5px; }
.minimap-action-btn {
    background: rgba(6,6,18,0.88);
    border: 1px solid rgba(249,212,35,0.45);
    color: #f9d423;
    border-radius: 5px;
    font-size: 10px;
    font-family: 'Outfit', sans-serif;
    cursor: url('assets/cursor.png') 0 0, pointer;
    padding: 2px 8px;
    transition: background 0.15s, border-color 0.15s;
}
.minimap-action-btn:hover { background: rgba(249,212,35,0.14); border-color: #f9d423; }
.minimap-zoom-btn { min-width: 22px; padding: 3px 6px; font-size: 14px; font-weight: 700; }

/* Full Map Modal */
#fullmap-modal {
    position: fixed;
    inset: 0;
    z-index: 9100;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,0.72);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}
#fullmap-modal.hidden { display: none; }
#fullmap-panel {
    position: relative;
    background: linear-gradient(150deg, #150f22 0%, #0d0a18 55%, #150f22 100%);
    border: 2px solid rgba(160, 100, 28, 0.65);
    border-radius: 14px;
    padding: 12px 14px 10px;
    box-shadow:
        0 0 60px rgba(0,0,0,0.95),
        0 0 30px rgba(160,90,10,0.12),
        0 0 0 1px rgba(200,140,40,0.08) inset;
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-width: 95vw;
    max-height: 96vh;
    overflow: hidden;
}
#fullmap-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid rgba(160,100,28,0.3);
    padding-bottom: 6px;
}
#fullmap-title {
    color: #d4a84b;
    font-family: 'Outfit', sans-serif;
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-shadow: 0 0 12px rgba(212,168,75,0.4);
}
#fullmap-hint {
    text-align: center;
    font-family: 'Outfit', sans-serif;
    font-size: 10px;
    color: rgba(180,130,50,0.45);
    margin: 0;
    padding-top: 2px;
}
#fullmap-close {
    background: none;
    border: 1px solid rgba(255,255,255,0.18);
    color: #888;
    border-radius: 6px;
    width: 28px;
    height: 28px;
    cursor: url('assets/cursor.png') 0 0, pointer;
    font-size: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: border-color 0.15s, color 0.15s;
}
#fullmap-close:hover { border-color: #e74c3c; color: #e74c3c; }
#fullmap-canvas { display: block; border-radius: 6px; max-width: 100%; }

/* Filter bar */
#fullmap-filters {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    align-items: center;
}
.fm-f {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 4px 10px;
    border-radius: 20px;
    font-family: 'Outfit', sans-serif;
    font-size: 11px;
    font-weight: 600;
    cursor: url('assets/cursor.png') 0 0, pointer;
    border: 1.5px solid rgba(255,255,255,0.12);
    background: rgba(255,255,255,0.04);
    color: rgba(255,255,255,0.35);
    transition: background 0.15s, border-color 0.15s, color 0.15s;
    user-select: none;
}
.fm-f i {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
    opacity: 0.4;
    transition: opacity 0.15s;
}
.fm-f.fm-f-on {
    border-color: rgba(255,255,255,0.3);
    background: rgba(255,255,255,0.10);
    color: rgba(255,255,255,0.88);
}
.fm-f.fm-f-on i { opacity: 1; }
.fm-f:hover { border-color: rgba(255,255,255,0.4); color: white; }

/* Legend */
#fullmap-legend {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
    border-top: 1px solid rgba(255,255,255,0.07);
    padding-top: 8px;
}
.fm-leg {
    display: flex;
    align-items: center;
    gap: 5px;
    font-family: 'Outfit', sans-serif;
    font-size: 11px;
    color: #666;
}
.fm-leg i {
    display: inline-block;
    width: 9px;
    height: 9px;
    border-radius: 50%;
    flex-shrink: 0;
}

/* Instance Enemy Tracker */
#instance-tracker {
    position: absolute;
    top: 2rem;
    right: calc(2rem + 235px);
    z-index: 299;
}

/* Settings Button */
#settings-btn {
    position: absolute;
    top: 2rem;
    right: calc(2rem + 175px);
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(15, 20, 35, 0.75);
    border: 2px solid var(--accent-color);
    color: var(--accent-color);
    font-size: 1.3rem;
    cursor: url('assets/cursor.png') 0 0, pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 0 10px rgba(0,0,0,0.5);
    transition: all 0.2s ease;
    z-index: 301;
    pointer-events: auto;
}

#settings-btn:hover {
    transform: scale(1.1) rotate(45deg);
    border-color: #fff;
    color: #fff;
    box-shadow: 0 0 15px var(--accent-color);
}

.locked { filter: grayscale(1) opacity(0.5); pointer-events: none; }
.hidden { display: none !important; }

/* ==========================================================================
   MOBILE & TOUCH DEVICE STYLES
   ========================================================================== */

/* Touch Controls Layout - Oculto por defecto en pantallas grandes */
#mobile-controls {
    display: none !important;
}

#mobile-controls.hidden {
    display: none !important;
}

/* Joystick Overlay */
#joystick-container {
    position: absolute;
    bottom: max(1.5rem, env(safe-area-inset-bottom));
    left: max(1.5rem, env(safe-area-inset-left));
    width: 130px;
    height: 130px;
    display: flex;
    justify-content: center;
    align-items: center;
    pointer-events: auto;
}

#joystick-base {
    width: 110px;
    height: 110px;
    border-radius: 50%;
    background: rgba(15, 20, 35, 0.4);
    border: 2px solid rgba(249, 212, 35, 0.25);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4), inset 0 0 15px rgba(255, 255, 255, 0.05);
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    transition: border-color 0.3s, box-shadow 0.3s;
}

#joystick-base.active {
    border-color: rgba(249, 212, 35, 0.6);
    box-shadow: 0 0 25px rgba(249, 212, 35, 0.35), inset 0 0 20px rgba(255, 255, 255, 0.1);
}

#joystick-knob {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(249, 212, 35, 0.75), rgba(255, 78, 80, 0.75));
    border: 1.5px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
}

/* Chat toggle — flotante sobre el joystick, lado izquierdo */
#mobile-btn-chat {
    width: 44px;
    height: 44px;
    bottom: calc(max(1.5rem, env(safe-area-inset-bottom)) + 138px);
    left: max(1.5rem, env(safe-area-inset-left));
    font-size: 1.3rem;
    border-color: rgba(56, 189, 248, 0.5);
    background: rgba(15, 30, 50, 0.6);
    box-shadow: 0 0 14px rgba(56, 189, 248, 0.2);
    transition: transform 0.1s cubic-bezier(0.175, 0.885, 0.32, 1.275),
                border-color 0.2s, background 0.2s, box-shadow 0.2s;
}
#mobile-btn-chat.chat-is-open {
    border-color: rgba(56, 189, 248, 0.9);
    background: rgba(56, 189, 248, 0.2);
    box-shadow: 0 0 22px rgba(56, 189, 248, 0.55);
}

/* Action & Skill Buttons Overlay */
#mobile-actions {
    position: absolute;
    bottom: max(1.5rem, env(safe-area-inset-bottom));
    right: max(1.5rem, env(safe-area-inset-right));
    width: 200px;
    height: 200px;
    pointer-events: none;
}

.mobile-btn {
    pointer-events: auto;
    position: absolute;
    border-radius: 50%;
    overflow: hidden;
    background: rgba(15, 20, 35, 0.55);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 2px solid rgba(255, 255, 255, 0.15);
    color: white;
    font-size: 1.2rem;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4), inset 0 0 5px rgba(255, 255, 255, 0.15);
    cursor: url('assets/cursor.png') 0 0, pointer;
    transition: transform 0.1s cubic-bezier(0.175, 0.885, 0.32, 1.275), border-color 0.2s, background-color 0.2s, box-shadow 0.2s;
    user-select: none;
    -webkit-user-select: none;
    touch-action: none;
    outline: none;
}

.mobile-btn:active {
    transform: scale(0.85) !important;
    background: rgba(249, 212, 35, 0.25);
    border-color: rgba(249, 212, 35, 0.8);
    box-shadow: 0 0 20px rgba(249, 212, 35, 0.6);
}

/* Large Attack Button */
#mobile-btn-attack {
    width: 80px;
    height: 80px;
    bottom: 5px;
    right: 5px;
    font-size: 2.2rem;
    border: 2px solid var(--accent-color);
    background: linear-gradient(135deg, rgba(26, 42, 74, 0.75), rgba(13, 26, 45, 0.75));
    box-shadow: 0 0 20px rgba(249, 212, 35, 0.3);
}

/* Arc Positioned Skill Buttons */
#mobile-btn-skill2 {
    width: 48px;
    height: 48px;
    bottom: 100px;
    right: 10px;
    border-color: rgba(255, 107, 107, 0.45);
    text-shadow: 0 0 5px rgba(255, 107, 107, 0.8);
}

#mobile-btn-skill3 {
    width: 48px;
    height: 48px;
    bottom: 90px;
    right: 85px;
    border-color: rgba(79, 172, 254, 0.45);
    text-shadow: 0 0 5px rgba(79, 172, 254, 0.8);
}

#mobile-btn-skill4 {
    width: 48px;
    height: 48px;
    bottom: 10px;
    right: 105px;
    border-color: rgba(176, 141, 87, 0.45);
    text-shadow: 0 0 5px rgba(176, 141, 87, 0.8);
}

/* Inventory / Character & Stats Utility buttons */
#mobile-btn-inv {
    width: 42px;
    height: 42px;
    bottom: 160px;
    right: 10px;
    font-size: 1.1rem;
    border-color: rgba(155, 89, 182, 0.45);
    background: rgba(26, 42, 74, 0.45);
}

#mobile-btn-stats {
    width: 42px;
    height: 42px;
    bottom: 150px;
    right: 70px;
    font-size: 1.1rem;
    border-color: rgba(241, 196, 15, 0.45);
    background: rgba(42, 26, 26, 0.45);
}

.mobile-btn.locked {
    filter: grayscale(1) opacity(0.25);
    pointer-events: none !important;
}

/* ── NPC Dialogue buttons ─────────────────────────────────────────── */
.dialog-btn {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    padding: 12px 16px;
    background: rgba(159, 122, 234, 0.1);
    border: 1px solid rgba(159, 122, 234, 0.3);
    border-radius: 8px;
    color: #c4b5d8;
    font-family: 'Outfit', sans-serif;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: url('assets/cursor.png') 0 0, pointer;
    transition: background 0.15s, border-color 0.15s, transform 0.1s;
    text-align: left;
    box-sizing: border-box;
}
.dialog-btn:hover {
    background: rgba(159, 122, 234, 0.2);
    border-color: rgba(159, 122, 234, 0.6);
    color: #e2d9f3;
    transform: translateX(2px);
}
.dialog-btn:active {
    transform: translateX(0) scale(0.98);
}
.dialog-btn-primary {
    background: linear-gradient(135deg, rgba(99,102,241,0.35), rgba(139,92,246,0.25));
    border-color: rgba(139, 92, 246, 0.5);
    color: #e2d9f3;
    box-shadow: 0 4px 14px rgba(99,102,241,0.2);
}
.dialog-btn-primary:hover {
    background: linear-gradient(135deg, rgba(99,102,241,0.5), rgba(139,92,246,0.4));
    border-color: rgba(139,92,246,0.8);
}

/* Portrait-mode overlay — shows when phone is held vertically */
#rotate-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: rgba(5, 10, 25, 0.97);
    justify-content: center;
    align-items: center;
    flex-direction: column;
    color: #f9d423;
    font-family: 'Outfit', sans-serif;
    text-align: center;
}
#rotate-overlay-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}
#rotate-phone-icon {
    font-size: 3.5rem;
    animation: rotate-hint 1.5s ease-in-out infinite alternate;
}
@keyframes rotate-hint {
    from { transform: rotate(-30deg); }
    to   { transform: rotate(30deg); }
}
@media (orientation: portrait) and (max-width: 900px) {
    #rotate-overlay { display: flex; }
}

/* Responsive UI Tuning for Mobile Devices */
@media (max-width: 900px), (max-height: 550px) {
    /* Activar los controles de móvil solo en pantallas pequeñas responsivas */
    #mobile-controls:not(.hidden) {
        display: block !important;
        position: absolute;
        inset: 0;
        pointer-events: none;
        z-index: 500;
        user-select: none;
        -webkit-user-select: none;
        touch-action: none;
    }

    /* Hide desktop action-bar; mobile-actions replaces it */
    .action-bar { display: none !important; }

    /* Scale down windows so they fit short landscape screens */
    .window {
        width: 90% !important;
        height: 90% !important;
        max-width: 460px;
        max-height: 380px;
        left: 50% !important;
        top: 50% !important;
        transform: translate(-50%, -50%) scale(0.85) !important;
    }
    
    /* Posicionamiento y escalado del Altar (siempre a la derecha del centro en móvil) */
    #enchant-window {
        width: 320px !important;
        height: 380px !important;
        max-width: 320px !important;
        max-height: 380px !important;
        left: calc(50% + 10px) !important;
        right: auto !important;
        top: 50% !important;
        transform: translateY(-50%) scale(0.68) !important;
        transform-origin: left center !important;
        z-index: 99999 !important; /* Asegura estar visualmente por encima de los controles táctiles */
    }

    /* Inventario en móvil: centrado por defecto con dimensiones completas para evitar recortes de slots */
    #inventory-window {
        width: 500px !important;
        height: 420px !important;
        max-width: 500px !important;
        max-height: 420px !important;
        left: calc(50% + 50px) !important; /* Desplazado 50px a la derecha para no solapar el joystick de movimiento izquierdo */
        top: calc(50% - 20px) !important; /* Desplazado ligeramente hacia arriba */
        transform: translate(-50%, -50%) scale(0.72) !important;
        transform-origin: center center !important;
        z-index: 99999 !important; /* Asegura estar visualmente por encima de cualquier control táctil */
    }

    /* Si el Altar está abierto, desplazar el Inventario a la izquierda para dejar 20px de separación */
    body.altar-open #inventory-window {
        width: 500px !important;
        height: 420px !important;
        max-width: 500px !important;
        max-height: 420px !important;
        left: auto !important;
        right: calc(50% + 10px) !important;
        top: 50% !important;
        transform: translateY(-50%) scale(0.68) !important;
        transform-origin: right center !important;
        z-index: 99999 !important; /* Mantiene la prioridad de capas */
    }
    
    /* Shrink the HUD and elevate its z-index above mobile controls so windows cover the joystick */
    .hud {
        padding: 0.75rem;
        z-index: 1000 !important;
    }
    
    .char-info {
        top: 0.75rem;
        left: 0.75rem;
        transform: scale(0.8);
        transform-origin: top left;
    }
    
    #minimap-area {
        top: 0.75rem;
        right: 0.75rem;
        transform: scale(0.7);
        transform-origin: top right;
    }

    #settings-btn {
        top: 0.75rem;
        right: calc(0.75rem + 120px);
        transform: scale(0.8);
        transform-origin: top right;
    }

    #mobile-btn-stats {
        position: absolute;
        top: 0.75rem !important;
        right: calc(0.75rem + 165px) !important;
        bottom: auto !important;
        transform: scale(0.8);
        transform-origin: top right;
        z-index: 301;
    }

    #instance-tracker {
        top: 0.75rem !important;
        right: calc(0.75rem + 215px) !important;
        transform: scale(0.8);
        transform-origin: top right;
    }
    
    /* Chat panel oculto por defecto en móvil — toggle con botón 💬 */
    .chat-panel.mobile-hidden {
        display: none !important;
    }

    /* Chat panel expandido — aparece encima del botón 💬, anclado a la izquierda */
    .chat-panel.mobile-open {
        display: flex !important;
        position: fixed;
        bottom: calc(max(1.5rem, env(safe-area-inset-bottom)) + 192px);
        left: max(1.5rem, env(safe-area-inset-left));
        width: min(300px, calc(100vw - 3rem));
        height: 38vh;
        transform: none;
        background: rgba(10, 15, 30, 0.96) !important;
        border: 1px solid rgba(56, 189, 248, 0.35) !important;
        border-radius: 10px !important;
        box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(56,189,248,0.1) !important;
        backdrop-filter: blur(14px) !important;
        -webkit-backdrop-filter: blur(14px) !important;
        z-index: 600;
        padding: 0.75rem;
        animation: chat-slide-up 0.18s cubic-bezier(0.22, 1, 0.36, 1);
    }
    @keyframes chat-slide-up {
        from { opacity: 0; transform: translateY(12px); }
        to   { opacity: 1; transform: translateY(0); }
    }
    .chat-panel.mobile-open .chat-messages {
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    /* Relocate original action-bar under mobile to avoid conflicts */
    .action-bar {
        display: none !important; /* Hidden on mobile in favor of dedicated buttons */
    }
    
    /* Scale up canvas rendering clarity on mobile screens */
    #game-canvas {
        touch-action: none;
    }
    
    /* Adjust victory & level selectors */
    #victory-modal, #portal-selector, #npc-dialog-overlay {
        transform: translate(-50%, -50%) scale(0.8) !important;
    }
}

/* Stat Points Badge Notification */
.stat-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #e74c3c;
    color: white;
    font-size: 0.75rem;
    font-weight: bold;
    border-radius: 50%;
    width: 16px;
    height: 16px;
    display: flex;
    justify-content: center;
    align-items: center;
    border: 1px solid #000;
    box-shadow: 0 0 6px rgba(231, 76, 60, 0.8);
    pointer-events: none;
    z-index: 10;
    animation: badgePulse 1.2s infinite alternate;
}

@keyframes badgePulse {
    from {
        transform: scale(0.95);
        box-shadow: 0 0 4px rgba(231, 76, 60, 0.6);
    }
    to {
        transform: scale(1.15);
        box-shadow: 0 0 12px rgba(231, 76, 60, 1);
    }
}

/* Screen Notifications */
.screen-notification-container {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 99999;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    pointer-events: none;
}

.screen-notification {
    background: rgba(10, 15, 25, 0.95);
    border: 1px solid rgba(241, 196, 15, 0.6);
    border-radius: 8px;
    padding: 12px 24px;
    color: #fff;
    font-family: 'Outfit', sans-serif;
    font-size: 1rem;
    font-weight: bold;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5), 0 0 15px rgba(241, 196, 15, 0.2);
    backdrop-filter: blur(8px);
    opacity: 0;
    transform: translateY(-20px);
    transition: opacity 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.screen-notification.show {
    opacity: 1;
    transform: translateY(0);
}

.screen-notification.fade-out {
    opacity: 0;
    transform: translateY(-20px) scale(0.9);
    transition: opacity 0.4s ease, transform 0.4s ease;
}

@keyframes greenPulse {
    0% {
        transform: scale(0.9);
        box-shadow: 0 0 3px rgba(46, 204, 113, 0.6);
        opacity: 0.8;
    }
    50% {
        transform: scale(1.2);
        box-shadow: 0 0 10px rgba(46, 204, 113, 1);
        opacity: 1;
    }
    100% {
        transform: scale(0.9);
        box-shadow: 0 0 3px rgba(46, 204, 113, 0.6);
        opacity: 0.8;
    }
}

/* ========================
   ZONE TITLE OVERLAY
   ======================== */
#zone-title-overlay {
    position: fixed;
    top: 0; left: 0; right: 0;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding-top: 7vh;
    z-index: 8000;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.6s ease;
}
#zone-title-overlay.zone-title-hidden  { opacity: 0; }
#zone-title-overlay.zone-title-visible { opacity: 1; }
#zone-title-overlay.zone-title-fadeout { opacity: 0; transition: opacity 0.9s ease; }

#zone-title-fog {
    position: absolute;
    top: 0; left: 50%;
    transform: translateX(-50%);
    width: 480px; height: 140px;
    background: radial-gradient(ellipse at center, rgba(0,0,0,0.55) 0%, transparent 75%);
    border-radius: 50%;
}

/* Contenedor de los dos slots — clipa el efecto push */
#zone-title-content {
    position: relative;
    width: 520px;
    height: 78px;
    overflow: hidden;
}

/* Cada slot ocupa la misma posición y empieza invisible */
.zone-slot {
    position: absolute;
    top: 0; left: 0; right: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    opacity: 0;
}

/* ── Badge ── */
.zone-slot-badge {
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    padding: 2px 12px;
    border-radius: 20px;
    font-family: 'Outfit', sans-serif;
    opacity: 0.9;
}
.zone-slot-badge.badge-safe {
    color: #a8ffb0;
    background: rgba(40,160,60,0.25);
    border: 1px solid rgba(100,220,100,0.35);
    text-shadow: 0 0 8px rgba(80,255,100,0.5);
}
.zone-slot-badge.badge-dungeon {
    color: #ffb347;
    background: rgba(160,80,20,0.25);
    border: 1px solid rgba(220,130,60,0.35);
    text-shadow: 0 0 8px rgba(255,150,50,0.5);
}
.zone-slot-badge.badge-boss {
    color: #ff8a8a;
    background: rgba(160,20,20,0.3);
    border: 1px solid rgba(220,60,60,0.4);
    text-shadow: 0 0 10px rgba(255,80,80,0.6);
}
.zone-slot-badge.badge-hostile {
    color: #f4c2c2;
    background: rgba(120,30,30,0.25);
    border: 1px solid rgba(200,80,80,0.3);
    text-shadow: 0 0 8px rgba(220,80,80,0.4);
}

/* ── Nombre y subtítulo ── */
.zone-slot-name {
    font-family: 'Outfit', sans-serif;
    font-size: 1.7rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    color: #f5e6c0;
    text-shadow:
        0 0 18px rgba(255,220,120,0.55),
        0 0 36px rgba(200,160,60,0.28),
        0 2px 4px rgba(0,0,0,0.9);
    line-height: 1.1;
    white-space: nowrap;
}
.zone-slot-sub {
    font-family: 'Outfit', sans-serif;
    font-size: 0.78rem;
    font-weight: 400;
    color: rgba(220,205,175,0.75);
    letter-spacing: 0.06em;
    font-style: italic;
    text-shadow: 0 1px 3px rgba(0,0,0,0.8);
}

/* ── Animaciones ── */
@keyframes zone-push-out {
    0%   { transform: translateY(0);    opacity: 1; }
    100% { transform: translateY(56px); opacity: 0; }
}
@keyframes zone-push-in {
    0%   { transform: translateY(-56px); opacity: 0; }
    100% { transform: translateY(0);     opacity: 1; }
}
@keyframes zone-appear {
    0%   { transform: translateY(-12px); opacity: 0; }
    100% { transform: translateY(0);     opacity: 1; }
}

@media (max-width: 600px) {
    .zone-slot-name { font-size: 1.2rem; }
    .zone-slot-sub  { font-size: 0.68rem; }
    #zone-title-fog { width: 320px; height: 100px; }
    #zone-title-content { width: 340px; }
}

/* ==========================================================================
   WEATHER HUD WIDGET STYLES (PREMIUM GLASSMORPHISM)
   ========================================================================== */
.weather-widget-premium {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    background: rgba(10, 14, 26, 0.78);
    border: 1.5px solid rgba(255, 255, 255, 0.12);
    border-radius: 20px;
    padding: 5px 12px;
    margin-bottom: 6px;
    font-family: 'Outfit', sans-serif;
    font-size: 0.72rem;
    font-weight: 700;
    color: #e2e8f0;
    text-shadow: 0 1px 2px rgba(0,0,0,0.9);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.6);
    user-select: none;
    pointer-events: auto;
    transition: all 0.5s ease;
}

#weather-icon {
    font-size: 0.85rem;
    display: inline-block;
    filter: drop-shadow(0 0 2px rgba(0,0,0,0.5));
}

#weather-name {
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

/* Tarjeta de información emergente (Hover Tooltip) */
.weather-tooltip-card {
    position: absolute;
    top: 50%;
    right: calc(100% + 10px);
    width: 210px;
    background: rgba(15, 23, 42, 0.95);
    border: 1.5px solid rgba(255, 255, 255, 0.15);
    border-radius: 12px;
    padding: 12px 14px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.7);
    color: #f1f5f9;
    font-family: 'Outfit', sans-serif;
    font-size: 0.75rem;
    font-weight: 500;
    line-height: 1.35;
    text-shadow: none;
    z-index: 10000;
    pointer-events: none;
    opacity: 0;
    transform: translateY(-50%) translateX(8px);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    text-align: left;
}

.weather-widget-premium:hover .weather-tooltip-card {
    opacity: 1;
    transform: translateY(-50%) translateX(0);
}

/* Animación de pulso general */
@keyframes weatherGlowPulse {
    0%   { box-shadow: 0 4px 12px rgba(0,0,0,0.6), 0 0 0px var(--weather-glow, rgba(0,0,0,0)); }
    50%  { box-shadow: 0 4px 12px rgba(0,0,0,0.6), 0 0 8px var(--weather-glow, rgba(0,0,0,0)); }
    100% { box-shadow: 0 4px 12px rgba(0,0,0,0.6), 0 0 0px var(--weather-glow, rgba(0,0,0,0)); }
}

/* Modificadores de clima específicos */
.weather-clear, .weather-sunny {
    --weather-glow: rgba(249, 212, 35, 0.35);
    border-color: rgba(249, 212, 35, 0.55);
    color: #ffd83b;
    animation: weatherGlowPulse 3s infinite;
}

.weather-cloudy, .weather-fog {
    --weather-glow: rgba(148, 163, 184, 0.2);
    border-color: rgba(148, 163, 184, 0.4);
    color: #e2e8f0;
    animation: weatherGlowPulse 4s infinite;
}

.weather-rain {
    --weather-glow: rgba(56, 189, 248, 0.35);
    border-color: rgba(56, 189, 248, 0.5);
    color: #7dd3fc;
    animation: weatherGlowPulse 2.5s infinite;
}

.weather-storm {
    --weather-glow: rgba(168, 85, 247, 0.45);
    border-color: rgba(168, 85, 247, 0.65);
    color: #c084fc;
    animation: weatherGlowPulse 2s infinite;
}

.weather-snow, .weather-snowstorm {
    --weather-glow: rgba(186, 230, 253, 0.4);
    border-color: rgba(186, 230, 253, 0.65);
    color: #e0f2fe;
    animation: weatherGlowPulse 3s infinite;
}

.weather-sandstorm {
    --weather-glow: rgba(200, 134, 10, 0.35);
    border-color: rgba(200, 134, 10, 0.55);
    color: #fbbf24;
    animation: weatherGlowPulse 2.5s infinite;
}

.weather-ash {
    --weather-glow: rgba(239, 68, 68, 0.4);
    border-color: rgba(239, 68, 68, 0.6);
    color: #fca5a5;
    animation: weatherGlowPulse 2s infinite;
}

/* Social Window Styles */
.social-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 6px;
    padding: 8px 12px;
    transition: all 0.2s ease;
}

.social-row:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(46, 204, 113, 0.3);
}

.social-row-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: inline-block;
}

.status-dot.online {
    background: #2ecc71;
    box-shadow: 0 0 6px #2ecc71;
}

.status-dot.offline {
    background: #95a5a6;
}

.social-row-name {
    font-weight: bold;
    font-size: 0.85rem;
    color: #f1f5f9;
}

.social-row-lvl {
    font-size: 0.7rem;
    color: #94a3b8;
    background: rgba(255, 255, 255, 0.05);
    padding: 2px 6px;
    border-radius: 4px;
}

.social-row-actions {
    display: flex;
    gap: 6px;
}

.social-row-actions button {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #e2e8f0;
    border-radius: 4px;
    width: 26px;
    height: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: url('assets/cursor.png') 0 0, pointer;
    font-size: 0.8rem;
    transition: all 0.15s ease;
}

.social-row-actions button:hover {
    background: rgba(46, 204, 113, 0.2);
    border-color: #2ecc71;
    color: #fff;
    transform: scale(1.05);
}

.social-row-actions button.btn-remove:hover {
    background: rgba(231, 76, 60, 0.2);
    border-color: #e74c3c;
    color: #fff;
}



