/* ============================================================
   SOULFULSYNC — ORB LANGUAGE SWITCHER (2026 QUANTUM EDITION)
   Micro Orb S • Quantum Glow • Gravity Ascend • 3D Capsules
   ============================================================ */

.ssx-orb-wrapper {
    position: fixed;
    bottom: 36px;
    right: 36px;
    z-index: 999999;
    perspective: 1600px;
}

/* ===============================
   QUANTUM ORB BUTTON — SMALL SIZE
   =============================== */

.ssx-orb-btn {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    position: relative;

    display: flex;
    justify-content: center;
    align-items: center;

    background: radial-gradient(circle at 30% 30%, #7e3af2, #4d2b9b, #1c1c25);
    background-size: 200% 200%;

    box-shadow:
        0 0 24px rgba(126,58,242,0.7),
        0 0 70px rgba(255,99,255,0.4);

    backdrop-filter: blur(18px) saturate(180%);
    -webkit-backdrop-filter: blur(18px) saturate(180%);

    transition: transform .3s ease, box-shadow .3s ease, background-position .5s ease;
    animation: ssxOrbBreath 5s ease-in-out infinite;
}

/* Icon */
.ssx-orb-icon {
    font-size: 22px;
    color: #b3d9ff;
    position: relative;
    z-index: 2;
}

/* Halo cuántico */
.ssx-orb-btn::after {
    content: "";
    position: absolute;
    width: 95px;
    height: 95px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(126,58,242,0.22), rgba(255,99,255,0.18));
    filter: blur(25px);
    z-index: -1;
    animation: ssxHalo 6s linear infinite;
}

/* Hover */
.ssx-orb-btn:hover {
    transform: scale(1.12) rotate3d(1,1,0,6deg);
    box-shadow:
        0 0 40px rgba(126,58,242,0.9),
        0 0 110px rgba(255,99,255,0.6);
}

/* Animations */
@keyframes ssxOrbBreath {
    0%,100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

@keyframes ssxHalo {
    0% { transform: scale(1); opacity: .6; }
    100% { transform: scale(1.15); opacity: .9; }
}

/* ===============================
   LANGUAGE LIST
   =============================== */

.ssx-orb-langs {
    position: absolute;
    bottom: 70px;
    right: 0;
    display: flex;
    flex-direction: column;
    gap: 14px;

    opacity: 0;
    transform: translateY(24px) scale(.9);
    pointer-events: none;
    transition: opacity .35s ease, transform .35s ease;
}

.ssx-orb-langs.active {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}

/* ===============================
   LANGUAGE ITEM — Quantum Capsule
   =============================== */

.ssx-lang-item {
    display: flex;
    align-items: center;
    gap: 12px;

    padding: 10px 18px;
    min-width: 155px;

    background: rgba(255,255,255,0.20);
    border-radius: 14px;

    box-shadow:
        0 4px 14px rgba(0,0,0,0.15);

    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);

    cursor: pointer;
    transform: translateY(16px) rotateX(20deg) scale(.92);
    opacity: 0;

    animation: ssxItemLift .55s forwards cubic-bezier(.18,.78,.32,1.26);
}

.ssx-orb-langs.active .ssx-lang-item:nth-child(1) { animation-delay: .05s; }
.ssx-orb-langs.active .ssx-lang-item:nth-child(2) { animation-delay: .15s; }
.ssx-orb-langs.active .ssx-lang-item:nth-child(3) { animation-delay: .25s; }
.ssx-orb-langs.active .ssx-lang-item:nth-child(4) { animation-delay: .35s; }

@keyframes ssxItemLift {
    to {
        transform: translateY(0) rotateX(0) scale(1);
        opacity: 1;
    }
}

/* Hover */
.ssx-lang-item:hover {
    transform: translateX(-6px) scale(1.05) rotate3d(1,1,0,5deg);
    box-shadow:
        0 6px 24px rgba(126,58,242,0.45),
        0 0 18px rgba(255,99,255,0.38);
}

/* Active */
.ssx-lang-item.active {
    background: rgba(126,58,242,0.28);
    box-shadow:
        0 6px 32px rgba(126,58,242,0.75);
}

/* Flag */
.ssx-lang-flag {
    width: 36px;
    height: 24px;
    border-radius: 6px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.3);
    transition: transform .25s ease;
}

.ssx-lang-item:hover .ssx-lang-flag {
    transform: scale(1.12);
}

/* Label */
.ssx-lang-label {
    font-size: 15.5px;
    font-weight: 600;
    color: #1a1a1a;
}

html[data-theme="dark"] .ssx-lang-label {
    color: #fff;
}

@media (max-width: 1024px) {
    .ssx-orb-wrapper { display: none !important; }
}
