/* --- RESET & VARIABLES --- */
:root {
    /* Dark Theme (Default) */
    --bg-color: #0a0b1e;
    --card-bg: rgba(19, 21, 44, 0.6);
    --text-color: #e0e0e0;
    --text-muted: #a0a0a0;
    --accent-primary: #dacc16;
    /* Gold */
    --accent-secondary: #ffffff;
    /* White accents */
    --gradient-main: linear-gradient(135deg, #dacc16, #f0e68c);
    --font-main: 'Inter', sans-serif;
    --transition-speed: 0.3s;
    --card-border: rgba(255, 255, 255, 0.05);
    --blur-amount: 10px;
}

[data-theme="light"] {
    --bg-color: #f4f4f9;
    --card-bg: rgba(255, 255, 255, 0.7);
    --text-color: #1a1a1a;
    --text-muted: #666666;
    --accent-primary: #dacc16;
    /* Gold remains */
    --accent-secondary: #333333;
    --gradient-main: linear-gradient(135deg, #dacc16, #c5b358);
    --card-border: rgba(0, 0, 0, 0.05);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-main);
    background-color: var(--bg-color);
    color: var(--text-color);
    overflow-x: hidden;
    line-height: 1.6;
    /* Default to auto, only hidden when loading class is present */
    overflow-y: auto;
    transition: background-color 0.5s, color 0.5s;
}

body.loading {
    overflow: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-speed);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

/* --- UTILS --- */
.logo-round {
    border-radius: 50%;
    object-fit: cover;
    /* Optional: subtle border for dark mode contrast */
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* --- TYPOGRAPHY --- */
h1,
h2,
h3 {
    color: var(--text-color);
    font-weight: 700;
    margin-bottom: 1rem;
}

h2 {
    font-size: 2.5rem;
    text-align: center;
    background: var(--gradient-main);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 0.5rem;
}

.section-subtitle {
    text-align: center;
    color: var(--text-muted);
    margin-bottom: 3rem;
    font-size: 1.1rem;
}

/* --- UTILITIES --- */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 4px;
    /* Minimal radius */
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all var(--transition-speed);
    border: none;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn-primary {
    background: var(--accent-primary);
    color: #000;
    box-shadow: 0 4px 15px rgba(218, 204, 22, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(218, 204, 22, 0.5);
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--accent-primary);
    color: var(--text-color);
}

.btn-outline:hover {
    background: var(--accent-primary);
    color: #000;
}

.btn-disabled {
    background: #444;
    color: #888;
    cursor: not-allowed;
    box-shadow: none;
}

.btn-disabled:hover {
    transform: none;
    box-shadow: none;
}

/* --- TICKER --- */
.ticker-wrap {
    position: fixed;
    top: 0;
    width: 100%;
    overflow: hidden;
    height: 40px;
    /* Increased slightly for better vertical centering */
    background-color: #111;
    padding-left: 100%;
    box-sizing: border-box;
    z-index: 1101;
    border-bottom: 1px solid var(--accent-primary);
    display: flex;
    align-items: center;
}

.ticker {
    display: inline-flex;
    /* Changed to flex for vertical alignment */
    align-items: center;
    height: 100%;
    white-space: nowrap;
    padding-right: 100%;
    box-sizing: border-box;
    animation: ticker 40s linear infinite;
    /* Faster speed as requested */
}

.ticker-item {
    display: inline-flex;
    /* Flex for image alignment */
    align-items: center;
    padding: 0 1.5rem;
    font-size: 0.9rem;
    color: #fff;
    font-family: monospace;
}

.ticker-item img {
    margin-right: 8px;
    width: 20px;
    height: 20px;
    vertical-align: middle;
}

.ticker-item span.up {
    color: #00ff00;
}

.ticker-item span.down {
    color: #ff0000;
}

@keyframes ticker {
    0% {
        transform: translate3d(0, 0, 0);
    }

    100% {
        transform: translate3d(-100%, 0, 0);
    }
}

/* --- THEME TOGGLE (iPhone Style) --- */
.theme-switch-wrapper {
    position: fixed;
    top: 55px;
    /* Below ticker */
    right: 20px;
    z-index: 1100;
    display: flex;
    align-items: center;
}

.theme-switch {
    display: inline-block;
    height: 34px;
    position: relative;
    width: 60px;
}

.theme-switch input {
    display: none;
}

.slider {
    background-color: #ccc;
    bottom: 0;
    cursor: pointer;
    left: 0;
    position: absolute;
    right: 0;
    top: 0;
    transition: .4s;
    border-radius: 34px;
}

.slider:before {
    background-color: #fff;
    bottom: 4px;
    content: "";
    height: 26px;
    left: 4px;
    position: absolute;
    transition: .4s;
    width: 26px;
    border-radius: 50%;
}

/* Dark mode default state (unchecked) */
input:checked+.slider {
    background-color: var(--accent-primary);
}

input:checked+.slider:before {
    transform: translateX(26px);
}

/* Icons inside slider */
.slider .icon-sun,
.slider .icon-moon {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-size: 14px;
    color: #555;
    transition: opacity 0.3s;
}

.slider .icon-moon {
    left: 8px;
    opacity: 1;
}

.slider .icon-sun {
    right: 8px;
    opacity: 0;
}

input:checked+.slider .icon-moon {
    opacity: 0;
}

input:checked+.slider .icon-sun {
    opacity: 1;
}


/* --- PRELOADER & CURTAIN ANIMATION --- */
#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    pointer-events: none;
}

.curtain-panel {
    position: absolute;
    top: 0;
    width: 50%;
    height: 100%;
    background: var(--bg-color);
    z-index: 10000;
    transition: transform 1.5s cubic-bezier(0.77, 0, 0.175, 1);
}

.curtain-left {
    left: 0;
    transform-origin: left;
}

.curtain-right {
    right: 0;
    transform-origin: right;
}

.preloader-content {
    position: relative;
    z-index: 10001;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: opacity 0.5s ease-out;
}

body.loaded .curtain-left {
    transform: translateX(-100%);
}

body.loaded .curtain-right {
    transform: translateX(100%);
}

body.loaded .preloader-content {
    opacity: 0;
}

.logo-3d-container {
    position: relative;
    width: 150px;
    height: 150px;
    perspective: 1000px;
    transform-style: preserve-3d;
    margin-bottom: 40px;
}

.logo-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('assets/logocs.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    opacity: 0;
}

.layer-1 {
    filter: drop-shadow(0 0 10px var(--accent-primary)) hue-rotate(180deg);
    animation: assemble-1 2.5s cubic-bezier(0.19, 1, 0.22, 1) forwards;
}

.layer-2 {
    filter: drop-shadow(0 0 10px var(--accent-secondary)) hue-rotate(90deg);
    animation: assemble-2 2.5s cubic-bezier(0.19, 1, 0.22, 1) forwards;
}

.layer-3 {
    animation: assemble-3 2.5s cubic-bezier(0.19, 1, 0.22, 1) forwards;
    z-index: 10;
}

@keyframes assemble-1 {
    0% {
        opacity: 0;
        transform: translateZ(-500px) translateX(-200px) rotateY(-45deg);
    }

    20% {
        opacity: 0.6;
    }

    80% {
        opacity: 0;
        transform: translateZ(0) translateX(0) rotateY(0);
    }

    100% {
        opacity: 0;
        transform: translateZ(0) translateX(0) rotateY(0);
    }
}

@keyframes assemble-2 {
    0% {
        opacity: 0;
        transform: translateZ(-500px) translateX(200px) rotateY(45deg);
    }

    20% {
        opacity: 0.6;
    }

    80% {
        opacity: 0;
        transform: translateZ(0) translateX(0) rotateY(0);
    }

    100% {
        opacity: 0;
        transform: translateZ(0) translateX(0) rotateY(0);
    }
}

@keyframes assemble-3 {
    0% {
        opacity: 0;
        transform: scale(0.1) rotateZ(180deg);
    }

    40% {
        opacity: 1;
        transform: scale(1.2) rotateZ(0);
    }

    60% {
        transform: scale(0.9);
    }

    80% {
        transform: scale(1);
        filter: drop-shadow(0 0 20px rgba(218, 204, 22, 0.5));
    }

    100% {
        transform: scale(1);
        filter: drop-shadow(0 0 0 rgba(0, 0, 0, 0));
    }
}

.loading-bar-container {
    width: 200px;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    overflow: hidden;
}

.loading-bar {
    width: 0%;
    height: 100%;
    background: var(--gradient-main);
    animation: loadProgress 2.2s ease-in-out forwards;
}

@keyframes loadProgress {
    0% {
        width: 0%;
    }

    100% {
        width: 100%;
    }
}

/* --- HEADER --- */
header {
    position: fixed;
    top: 40px;
    /* Space for ticker */
    width: 100%;
    z-index: 1000;
    background: rgba(10, 11, 30, 0.7);
    backdrop-filter: blur(15px);
    border-bottom: 1px solid var(--card-border);
    padding: 15px 0;
    transition: padding 0.3s, background 0.3s;
}

[data-theme="light"] header {
    background: rgba(255, 255, 255, 0.8);
}

header.scrolled {
    padding: 10px 0;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 10px;
}

.header-logo-img {
    height: 40px;
    width: auto;
}

.logo {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--accent-primary);
    letter-spacing: -0.5px;
    line-height: 1.2;
}

.logo span:first-child {
    color: #ffffff;
}

[data-theme="light"] .logo span:first-child {
    color: #333;
}

.logo-subtitle {
    display: block;
    font-size: 0.7rem;
    color: var(--text-muted);
    font-weight: 400;
}

.nav-links {
    display: flex;
    gap: 25px;
}

.nav-links a {
    font-size: 0.95rem;
    font-weight: 500;
    position: relative;
    color: var(--text-color);
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 0;
    background: var(--accent-primary);
    transition: width 0.3s;
}

.nav-links a:hover::after {
    width: 100%;
}

.hamburger {
    display: none;
    cursor: pointer;
    font-size: 1.5rem;
    color: var(--text-color);
}

/* --- HERO SECTION --- */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    overflow: hidden;
    padding-top: 80px;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: var(--bg-color);
}

.hero-bg::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(218, 204, 22, 0.15) 0%, rgba(0, 0, 0, 0) 70%);
    border-radius: 50%;
    animation: pulseBlob 10s infinite alternate;
}

@keyframes pulseBlob {
    0% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.5;
    }

    100% {
        transform: translate(-50%, -50%) scale(1.2);
        opacity: 0.8;
    }
}

.hero-content {
    max-width: 800px;
    padding: 20px;
    z-index: 2;
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 1s forwards 0.5s;
}

.hero h1 {
    font-size: 3.5rem;
    line-height: 1.2;
    margin-bottom: 1.5rem;
}

.hero p {
    font-size: 1.2rem;
    color: var(--text-muted);
    margin-bottom: 2.5rem;
}

/* --- SECTIONS GENERAL --- */
section {
    padding: 80px 0;
}

.card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 12px;
    padding: 25px;
    transition: transform 0.1s ease-out, box-shadow 0.3s;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(var(--blur-amount));
}

.card:hover {
    border-color: var(--accent-primary);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* --- PROJECTS SECTION --- */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.project-card {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.project-logo {
    width: 80px;
    height: 80px;
    object-fit: cover;
    margin-bottom: 20px;
}

.social-links {
    margin-top: 15px;
    display: flex;
    gap: 8px;
    justify-content: center;
    flex-wrap: nowrap;
    width: 100%;
    margin-bottom: 20px;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.social-links::-webkit-scrollbar {
    display: none;
}

.social-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 0 10px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-color);
    transition: all 0.3s;
    gap: 5px;
}

.social-icon:hover {
    background: var(--accent-primary);
    color: #000;
    transform: translateY(-3px);
}

.badge-telegram {
    display: inline-block;
    background-color: #24A1DE;
    color: white;
    font-size: 0.75rem;
    font-weight: bold;
    padding: 6px 12px;
    border-radius: 20px;
    margin-top: 10px;
    text-transform: uppercase;
    text-decoration: none;
    transition: transform 0.2s;
}

.badge-telegram:hover {
    transform: scale(1.05);
}

/* --- PROMO BANNER 1 --- */
.promo-banner-section .banner {
    background-size: cover;
    background-position: center;
    border-radius: 12px;
    padding: 60px 40px;
    text-align: center;
    position: relative;
    border: 1px solid var(--card-border);
    backdrop-filter: blur(5px);
}

.promo-banner-section .banner h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: #fff;
}

.promo-banner-section .banner p {
    color: #ddd;
}

/* --- TIME LIMITED PROMO (COMPACT) --- */
.promo-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    /* Reduced gap */
}

.promo-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 20px;
    /* Reduced padding */
}

.promo-card h3 {
    font-size: 1.2rem;
    /* Smaller font */
    margin-bottom: 0.5rem;
}

.promo-card p {
    font-size: 0.85rem;
    /* Smaller font */
    margin-bottom: 10px;
}

.countdown {
    display: inline-flex;
    gap: 10px;
    margin-top: 10px;
    font-family: monospace;
    color: var(--accent-primary);
    font-size: 1rem;
    /* Smaller font */
}

.countdown.expired {
    color: #ff4444;
}

/* --- EXCHANGE BUBBLES --- */
.bubbles-container {
    position: relative;
    height: 400px;
    width: 100%;
    overflow: hidden;
    background: transparent;
    border-radius: 12px;
    border: none;
}

.bubble {
    position: absolute;
    width: 90px;
    height: 90px;
    border-radius: 50%;
    background: var(--card-bg);
    border: 2px solid var(--card-border);
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transition: transform 0.3s, border-color 0.3s;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    z-index: 10;
}

.bubble:hover {
    transform: scale(1.1);
    border-color: var(--accent-primary);
    z-index: 20;
}

.bubble img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

/* Modal Styles */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(5px);
    z-index: 10000;
    display: none;
    /* Hidden by default */
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.modal-content {
    background: #13152c;
    border: 1px solid var(--accent-primary);
    border-radius: 12px;
    padding: 30px;
    max-width: 500px;
    width: 100%;
    position: relative;
    max-height: 90vh;
    overflow-y: auto;
    animation: modalPop 0.3s ease-out;
}

@keyframes modalPop {
    from {
        opacity: 0;
        transform: scale(0.9);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    font-size: 1.5rem;
    color: #aaa;
    cursor: pointer;
    background: none;
    border: none;
}

.modal-close:hover {
    color: #fff;
}

.modal-body h3 {
    color: var(--accent-primary);
    margin-bottom: 15px;
    text-align: center;
}

.modal-body ul {
    margin-bottom: 20px;
    padding-left: 20px;
}

.modal-body li {
    list-style: disc;
    margin-bottom: 5px;
    color: #ddd;
}

/* --- NO KYC (COMPACT) --- */
.no-kyc-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
}

.kyc-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 15px;
}

.kyc-card h3 {
    font-size: 1.2rem;
}

.kyc-card p {
    font-size: 0.85rem;
}

.badges {
    display: flex;
    gap: 5px;
    margin: 10px 0;
    flex-wrap: wrap;
    justify-content: center;
}

.badge {
    background: rgba(218, 204, 22, 0.1);
    color: var(--accent-primary);
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.7rem;
    border: 1px solid rgba(218, 204, 22, 0.3);
}

/* --- DEGATE BANNER --- */
.degate-banner {
    background: linear-gradient(90deg, #2c0b4a, #4b1a7a);
    border: 1px solid #8a2be2;
    border-radius: 12px;
    padding: 30px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    box-shadow: 0 0 20px rgba(138, 43, 226, 0.2);
}

.degate-content {
    flex: 1;
}

.degate-content h3 {
    margin-bottom: 10px;
    color: #fff;
    text-align: left;
}

.degate-content p {
    color: #ccc;
    margin-bottom: 0;
}

/* --- OTHER PROMOS --- */
.other-promos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.other-card .tag {
    display: inline-block;
    background: var(--text-color);
    color: var(--bg-color);
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.75rem;
    margin-bottom: 10px;
    font-weight: bold;
}

/* --- CONTATTI --- */
.contacts-wrapper {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
}

.contact-btn {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 20px 40px;
    background: var(--card-bg);
    border-radius: 12px;
    transition: all 0.3s;
    border: 1px solid var(--card-border);
    backdrop-filter: blur(var(--blur-amount));
}

.contact-btn:hover {
    border-color: var(--accent-primary);
    transform: translateY(-5px);
}

.contact-icon {
    font-size: 2rem;
    color: var(--accent-primary);
}

.disclaimer {
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 50px;
    padding: 20px;
    border-top: 1px solid var(--card-border);
}

/* --- FOOTER --- */
footer {
    background: var(--bg-color);
    padding: 40px 0;
    text-align: center;
    border-top: 1px solid var(--card-border);
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

/* --- MOBILE QUERIES --- */
@media (max-width: 768px) {

    .promo-grid,
    .no-kyc-grid {
        grid-template-columns: 1fr;
    }

    .degate-banner {
        flex-direction: column;
        text-align: center;
    }

    .degate-content h3 {
        text-align: center;
    }

    .bubbles-container {
        height: 300px;
    }

    .bubble {
        width: 70px;
        height: 70px;
    }
}

/* --- ANIMATIONS --- */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Fix for legal pages header */
.static-header {
    position: relative !important;
    top: 0 !important;
    background: var(--bg-color) !important;
}

/* Hot Badge for BingX */
.hot-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: linear-gradient(45deg, #ff0000, #ff8c00);
    color: white;
    padding: 5px 10px;
    border-radius: 20px;
    font-weight: bold;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    gap: 5px;
    box-shadow: 0 0 10px rgba(255, 69, 0, 0.5);
    animation: pulse-hot 1.5s infinite alternate;
    z-index: 10;
}

.fire-icon {
    font-size: 1rem;
    animation: flicker 0.5s infinite alternate;
}

@keyframes pulse-hot {
    0% {
        transform: scale(1);
        box-shadow: 0 0 10px rgba(255, 69, 0, 0.5);
    }

    100% {
        transform: scale(1.1);
        box-shadow: 0 0 20px rgba(255, 69, 0, 0.8);
    }
}

@keyframes flicker {
    0% {
        opacity: 0.8;
        transform: scale(1);
    }

    100% {
        opacity: 1;
        transform: scale(1.2) rotate(5deg);
    }
}

/* Saber Effect */
@keyframes saber-pulse {
    0% {
        box-shadow: 0 0 10px rgba(255, 255, 255, 0.5), 0 0 20px rgba(0, 0, 255, 0.5);
        border-color: rgba(255, 255, 255, 0.8);
    }

    50% {
        box-shadow: 0 0 20px rgba(255, 255, 255, 0.8), 0 0 40px rgba(0, 0, 255, 0.8);
        border-color: #0047ff;
    }

    100% {
        box-shadow: 0 0 10px rgba(255, 255, 255, 0.5), 0 0 20px rgba(0, 0, 255, 0.5);
        border-color: rgba(255, 255, 255, 0.8);
    }
}

.saber-effect {
    animation: saber-pulse 2s infinite;
    border: 2px solid white;
}

/* Green Badge */
.badge-green {
    background-color: #28a745 !important;
    color: white !important;
    font-weight: bold;
}

/* Exchange Groups */
.exchange-group-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.exchange-group {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--card-border);
    border-radius: 12px;
    padding: 20px;
    position: relative;
    /* To handle absolute positioning of title if needed, though we use static flow here */
}

/* Mobile responsive for exchange groups */
@media (max-width: 768px) {
    .exchange-group-container {
        grid-template-columns: 1fr;
    }
}

.exchange-group-title {
    text-align: center;
    font-size: 1.2rem;
    color: var(--accent-primary);
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: bold;
    border-bottom: 1px solid var(--card-border);
    padding-bottom: 10px;
}

.exchange-group-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

/* Legal Popup */
.legal-popup {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: #1a1b3a;
    border-top: 2px solid var(--accent-primary);
    padding: 20px;
    z-index: 10000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 -5px 20px rgba(0, 0, 0, 0.5);
    transform: translateY(100%);
    animation: slideUp 0.5s forwards 1s;
    /* Delay 1s */
}

.legal-popup-content {
    max-width: 1200px;
    margin: 0 auto;
    font-size: 0.9rem;
    color: #ccc;
    padding-right: 20px;
}

.legal-popup-btn {
    background: var(--accent-primary);
    color: #000;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
    white-space: nowrap;
}

@keyframes slideUp {
    to {
        transform: translateY(0);
    }
}

/* Moving Hot Labels for Bubbles */
.bubble-hot-label {
    position: absolute;
    top: -25px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(45deg, #ff0000, #ff8c00);
    color: white;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 0.7rem;
    white-space: nowrap;
    font-weight: bold;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
    z-index: 25;
    /* Higher than bubble hover */
    pointer-events: none;
    animation: bounce-small 2s infinite;
}

@keyframes bounce-small {

    0%,
    100% {
        transform: translateX(-50%) translateY(0);
    }

    50% {
        transform: translateX(-50%) translateY(-3px);
    }
}

/* Social Count */
.social-count {
    font-size: 0.8rem;
    font-weight: bold;
}

/* Saber Spin Animation for Badges */
@keyframes rotateSaber {
    0% {
        transform: translate(-50%, -50%) rotate(0deg);
    }

    100% {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

.saber-spin {
    position: relative;
    z-index: 1;
    overflow: hidden;
    border: none !important;
    background: transparent !important;
    /* Ensure text is visible and pops */
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.8);
}

.saber-spin::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 600%;
    height: 600%;
    background: conic-gradient(transparent 0deg,
            transparent 270deg,
            var(--accent-primary) 320deg,
            #ffffff 340deg,
            var(--accent-primary) 360deg);
    transform: translate(-50%, -50%);
    animation: rotateSaber 3s linear infinite;
    z-index: -2;
}

.saber-spin::after {
    content: '';
    position: absolute;
    inset: 1.5px;
    border-radius: 3px;
    background: #151730;
    /* Dark background to contrast with glow */
    z-index: -1;
}

.saber-spin.saber-spin-green::before {
    background: conic-gradient(transparent 0deg,
            transparent 270deg,
            #28a745 320deg,
            #ffffff 340deg,
            #28a745 360deg);
}

.saber-spin.saber-spin-green::after {
    background: #28a745;
}