:root {
    --white-glow: rgba(255, 255, 255, 0.9);
    --status-online: #23a55a;
    --status-idle: #f0b232;
    --status-dnd: #f23f43;
    --status-offline: #80848e;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
    user-select: none;
}

body {
    background-color: #000;
    color: #fff;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

/* SFONDO ANIMATO + CANVAS PARTICELLE */
.background-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
    overflow: hidden;
}

.bg-animated-image {
    position: absolute;
    width: 110%;
    height: 110%;
    top: -5%;
    left: -5%;
    background: url('bg.jpg') no-repeat center center/cover;
    animation: bgMovement 14s infinite alternate ease-in-out;
    filter: brightness(0.5) contrast(1.1);
}

#particle-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

@keyframes bgMovement {
    0% { transform: scale(1) translate(0, 0); }
    100% { transform: scale(1.08) translate(-10px, -10px); }
}

.bg-overlay {
    position: absolute;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(0,0,0,0.1) 0%, rgba(0,0,0,0.85) 100%);
}

/* SCHEDA CARD */
.card-container {
    perspective: 1000px;
    z-index: 2;
}

.card {
    position: relative;
    background: rgba(10, 10, 12, 0.75);
    border: 1px solid rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 24px;
    padding: 30px 25px;
    width: 370px;
    text-align: center;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.95), 0 0 30px rgba(255, 255, 255, 0.12);
    animation: cardEntrance 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.95), 0 0 45px rgba(255, 255, 255, 0.22);
}

@keyframes cardEntrance {
    from { opacity: 0; transform: translateY(30px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

/* HEADER ACTIONS */
.card-header-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.lang-selector {
    position: relative;
}

.lang-btn, .info-btn {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: rgba(255, 255, 255, 0.85);
    padding: 5px 10px;
    border-radius: 12px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.lang-btn:hover, .info-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    color: #ffffff;
    box-shadow: 0 0 10px #ffffff;
}

.lang-dropdown {
    position: absolute;
    top: 35px;
    left: 0;
    background: rgba(15, 15, 20, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    padding: 6px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: all 0.3s ease;
    z-index: 20;
    width: 120px;
}

.lang-dropdown.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.lang-dropdown span {
    font-size: 11px;
    padding: 5px 8px;
    border-radius: 6px;
    cursor: pointer;
    text-align: left;
    transition: background 0.2s;
}

.lang-dropdown span:hover {
    background: rgba(255, 255, 255, 0.15);
}

/* INFO MODAL */
.info-modal {
    position: absolute;
    top: 45px;
    right: 15px;
    background: rgba(20, 20, 25, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 12px;
    padding: 10px 14px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: all 0.3s ease;
    z-index: 20;
    box-shadow: 0 10px 25px rgba(0,0,0,0.8);
}

.info-modal.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.info-modal-content {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
}

/* AVATAR ROTONDO CON GLOW BIANCO */
.avatar-wrapper {
    position: relative;
    width: 100px;
    height: 100px;
    margin: 5px auto 12px auto;
}

.avatar-inner {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    overflow: hidden;
    position: relative;
    z-index: 2;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.avatar-inner img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.avatar-glow-ring {
    position: absolute;
    top: -6px;
    left: -6px;
    right: -6px;
    bottom: -6px;
    border-radius: 50%;
    background: #ffffff;
    z-index: 1;
    filter: blur(12px);
    opacity: 0.85;
    animation: pulseWhiteGlow 2.5s ease-in-out infinite alternate;
}

@keyframes pulseWhiteGlow {
    0% { transform: scale(0.95); opacity: 0.5; box-shadow: 0 0 15px #ffffff; }
    100% { transform: scale(1.08); opacity: 1; box-shadow: 0 0 30px #ffffff; }
}

.status-dot {
    position: absolute;
    bottom: 3px;
    right: 3px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 3px solid #0a0a0c;
    z-index: 3;
}

.status-dot.online { background-color: var(--status-online); box-shadow: 0 0 10px var(--status-online); }
.status-dot.idle { background-color: var(--status-idle); box-shadow: 0 0 10px var(--status-idle); }
.status-dot.dnd { background-color: var(--status-dnd); box-shadow: 0 0 10px var(--status-dnd); }
.status-dot.offline { background-color: var(--status-offline); }

/* TESTI CON GLOW */
.glowing-text {
    color: #ffffff;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.7), 0 0 18px rgba(255, 255, 255, 0.3);
}

.username {
    font-size: 26px;
    font-weight: 700;
}

.handle {
    font-size: 13px;
    opacity: 0.85;
    margin-bottom: 8px;
}

/* BADGES */
.badges-wrapper {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 12px;
}

.badge-item {
    font-size: 10px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 3px 8px;
    border-radius: 8px;
    color: #ddd;
}

.bio-text {
    font-size: 11.5px;
    line-height: 1.5;
    margin: 10px 0;
}

.bio-text a {
    color: #ffffff;
    font-weight: 700;
    text-decoration: underline;
}

.joined-date {
    color: #666;
    font-size: 10.5px;
    margin-bottom: 14px;
}

/* COPY DISCORD BOX */
.copy-discord-box {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px dashed rgba(255, 255, 255, 0.2);
    padding: 8px;
    border-radius: 12px;
    font-size: 11px;
    cursor: pointer;
    margin-bottom: 16px;
    transition: all 0.3s ease;
}

.copy-discord-box:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: #ffffff;
}

.toast {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(50px);
    background: #ffffff;
    color: #000;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 100;
}

.toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* SOCIAL BUTTONS */
.social-links-grid {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-bottom: 18px;
}

.social-icon {
    color: #fff;
    font-size: 20px;
    text-decoration: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.social-icon:hover {
    transform: translateY(-5px) scale(1.1);
}

.discord:hover {
    box-shadow: 0 0 20px rgba(88, 101, 242, 0.9);
    background: rgba(88, 101, 242, 0.3);
    border-color: #5865F2;
}

.tiktok:hover {
    box-shadow: 0 0 20px rgba(254, 44, 85, 0.9);
    background: rgba(254, 44, 85, 0.3);
    border-color: #fe2c55;
}

/* FOOTER */
.card-footer {
    font-size: 11px;
    color: #666;
}

.shop-link {
    color: #aaa;
    font-weight: 600;
    text-decoration: none;
}

.shop-link:hover {
    color: #fff;
    text-decoration: underline;
}