:root {
    --bg-dark: #0c0a12;
    --card-bg: rgba(26, 23, 38, 0.7);
    --card-border: rgba(255, 189, 30, 0.15);
    --text-primary: #ffffff;
    --text-secondary: #bab5c8;
    --gold: #ffbd1e;
    --gold-glow: rgba(255, 189, 30, 0.35);
    --cyan: #ffbd1e;
    --cyan-glow: rgba(255, 189, 30, 0.25);
    --accent: #ffbd1e;
    --accent-glow: rgba(255, 189, 30, 0.3);
    --success: #10b981;
    --danger: #ef4444;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Outfit', sans-serif;
    -webkit-tap-highlight-color: transparent;
}

body {
    background-image: linear-gradient(rgba(7, 3, 17, 0.78), rgba(7, 3, 17, 0.88)), url('mafia_bg.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    color: var(--text-primary);
    min-height: 100vh;
    padding: 16px;
    padding-bottom: 40px;
    overflow-x: hidden;
    position: relative;
}

/* Background Animated Orbs */
.glow-orb {
    position: absolute;
    width: 250px;
    height: 250px;
    border-radius: 50%;
    filter: blur(100px);
    z-index: -1;
    opacity: 0.4;
    pointer-events: none;
    animation: pulse 6s infinite alternate;
}

.orb-1 {
    background: var(--accent);
    top: -50px;
    left: -50px;
}

.orb-2 {
    background: var(--cyan);
    bottom: 100px;
    right: -50px;
    animation-delay: 3s;
}

@keyframes pulse {
    0% {
        transform: scale(1) translate(0, 0);
        opacity: 0.3;
    }

    100% {
        transform: scale(1.2) translate(20px, 20px);
        opacity: 0.5;
    }
}

.app-container {
    max-width: 480px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 20px;
    animation: fadeIn 0.6s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(15px);
    }

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

/* Card Slide animation class */
.card-slide {
    animation: slideUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.card-slide:nth-child(2) {
    animation-delay: 0.1s;
}

.card-slide:nth-child(3) {
    animation-delay: 0.2s;
}

.card-slide:nth-child(4) {
    animation-delay: 0.3s;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(25px);
    }

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

/* Profile Header Card */
.profile-header {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: 24px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    box-shadow: 0 12px 40px 0 rgba(0, 0, 0, 0.4);
}

.user-row {
    display: flex;
    align-items: center;
    gap: 16px;
}

.avatar-container {
    position: relative;
    width: 68px;
    height: 68px;
}

.avatar-container img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 2px solid var(--accent);
    box-shadow: 0 0 15px var(--accent-glow);
    object-fit: cover;
    background: #110722;
}

.rank-badge {
    position: absolute;
    bottom: -6px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #aa00ff, var(--accent));
    color: white;
    font-size: 0.65rem;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    white-space: nowrap;
    text-transform: uppercase;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
}

.user-details h2 {
    font-size: 1.35rem;
    font-weight: 900;
    letter-spacing: 0.5px;
    background: linear-gradient(to right, #ffffff, #dcd1ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.user-details span {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* XP/Level Bar */
.xp-container {
    display: flex;
    flex-direction: column;
    gap: 6px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.04);
    padding: 10px;
    border-radius: 12px;
}

.xp-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    font-weight: 600;
}

.xp-level {
    color: #e5dbff;
}

.xp-pct {
    color: var(--cyan);
}

.xp-bar-bg {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 4px;
    overflow: hidden;
}

.xp-bar-fill {
    height: 100%;
    background: linear-gradient(to right, var(--accent), var(--cyan));
    border-radius: 4px;
    box-shadow: 0 0 8px var(--cyan-glow);
    transition: width 1s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Balance Cards */
.balance-cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.balance-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 16px;
    padding: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: transform 0.2s, border-color 0.2s;
}

.balance-card:active {
    transform: scale(0.96);
    border-color: rgba(255, 255, 255, 0.15);
}

.icon-circle {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
}

.gold-circle {
    background: rgba(255, 189, 30, 0.1);
    color: var(--gold);
    border: 1px solid rgba(255, 189, 30, 0.2);
    box-shadow: 0 0 10px rgba(255, 189, 30, 0.15);
}

.cyan-circle {
    background: rgba(0, 240, 255, 0.1);
    color: var(--cyan);
    border: 1px solid rgba(0, 240, 255, 0.2);
    box-shadow: 0 0 10px rgba(0, 240, 255, 0.15);
}

.balance-info {
    display: flex;
    flex-direction: column;
}

.balance-info .label {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.balance-info .value {
    font-size: 1.15rem;
    font-weight: 700;
}

/* Sections */
.section-container {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: 24px;
    padding: 20px;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.2);
}

.section-title {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    color: #e5dbff;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    padding-bottom: 10px;
    letter-spacing: 0.5px;
}

.section-title i {
    color: var(--cyan);
    filter: drop-shadow(0 0 5px var(--cyan-glow));
}

/* Stats */
.stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 12px;
}

.stat-box {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 14px;
    padding: 14px 10px;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 6px;
    transition: background 0.2s;
}

.stat-box:hover {
    background: rgba(255, 255, 255, 0.04);
}

.stat-val {
    font-size: 1.4rem;
    font-weight: 900;
    font-family: 'Outfit', sans-serif;
}

.stat-val.success {
    color: var(--success);
    text-shadow: 0 0 10px rgba(16, 185, 129, 0.3);
}

.stat-val.danger {
    color: var(--danger);
    text-shadow: 0 0 10px rgba(239, 68, 68, 0.3);
}

.stat-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
    font-weight: 500;
}

/* Inventory List */
.inventory-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.inventory-item {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    padding: 14px 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: background 0.2s, transform 0.2s;
}

.inventory-item:hover {
    background: rgba(255, 255, 255, 0.03);
}

.item-left {
    display: flex;
    align-items: center;
    gap: 14px;
}

.item-icon {
    font-size: 1.4rem;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.item-name-qty {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.item-name {
    font-size: 0.95rem;
    font-weight: 700;
}

.item-qty {
    font-size: 0.75rem;
    color: var(--text-secondary);
    font-weight: 500;
}

/* Toggle Switch */
.switch {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 26px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #221a30;
    transition: .3s;
    border-radius: 26px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: #887fa3;
    transition: .3s;
    border-radius: 50%;
}

input:checked+.slider {
    background-color: var(--accent);
    box-shadow: 0 0 10px var(--accent-glow);
}

input:checked+.slider:before {
    transform: translateX(22px);
    background-color: #fff;
}

input:disabled+.slider {
    opacity: 0.4;
    cursor: not-allowed;
}

/* Shop Layout */
.shop-grid {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.shop-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 18px;
    padding: 14px 18px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: transform 0.2s, background 0.2s, border-color 0.2s;
}

.shop-card:hover {
    background: rgba(255, 255, 255, 0.03);
    border-color: rgba(138, 43, 226, 0.15);
}

.shop-card:active {
    transform: scale(0.98);
}

.shop-card-left {
    display: flex;
    align-items: center;
    gap: 14px;
}

.shop-card-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.shop-card-title {
    font-size: 0.95rem;
    font-weight: 700;
}

.shop-card-price {
    font-size: 0.8rem;
    color: var(--gold);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 4px;
}

.shop-card-price.diamond-price {
    color: var(--cyan);
}

.buy-btn {
    background: linear-gradient(135deg, var(--accent), #aa33ff);
    color: var(--text-primary);
    border: none;
    border-radius: 10px;
    padding: 8px 16px;
    font-size: 0.85rem;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(138, 43, 226, 0.25);
    transition: transform 0.2s, filter 0.2s;
}

.buy-btn:hover {
    filter: brightness(1.1);
}

.buy-btn:active {
    transform: scale(0.95);
}

/* Global Stats Card */
.global-stats-row {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: 16px;
    padding: 12px 16px;
    display: flex;
    justify-content: space-around;
    align-items: center;
    font-size: 0.82rem;
    font-weight: 600;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.gstat-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.gstat-item b {
    font-size: 0.95rem;
    font-weight: 900;
}

.text-cyan {
    color: var(--cyan);
    filter: drop-shadow(0 0 4px var(--cyan-glow));
}

.pulse-indicator {
    width: 8px;
    height: 8px;
    background-color: var(--success);
    border-radius: 50%;
    box-shadow: 0 0 8px var(--success);
    animation: beacon 1.8s infinite;
}

@keyframes beacon {
    0% {
        transform: scale(1);
        opacity: 1;
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.6);
    }

    70% {
        transform: scale(1.1);
        opacity: 0.8;
        box-shadow: 0 0 0 6px rgba(16, 185, 129, 0);
    }

    100% {
        transform: scale(1);
        opacity: 1;
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
    }
}

/* Subscriptions Layout */
.subs-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
}

.sub-tier-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 18px;
    padding: 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: transform 0.2s;
}

.sub-tier-card:active {
    transform: scale(0.98);
}

.sub-card-details {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.sub-card-title {
    font-weight: 800;
    font-size: 1rem;
    display: flex;
    align-items: center;
    gap: 6px;
}

.sub-card-desc {
    font-size: 0.72rem;
    color: var(--text-secondary);
    line-height: 1.3;
    max-width: 260px;
}

.sub-card-price {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--cyan);
}

.vip-card {
    border-color: rgba(0, 240, 255, 0.25);
    background: linear-gradient(135deg, rgba(0, 240, 255, 0.03), rgba(0, 0, 0, 0));
}

.vip-card .sub-card-title {
    color: var(--cyan);
    text-shadow: 0 0 10px var(--cyan-glow);
}

.vip-card .sub-card-price {
    color: var(--cyan);
}

/* Glowing Profile Card upgrades */
.profile-header.vip-active {
    border: 2px solid var(--cyan);
    box-shadow: 0 0 25px rgba(0, 240, 255, 0.25), 0 12px 40px 0 rgba(0, 0, 0, 0.4);
}

/* Shop Discount styles */
.discount-badge {
    background: var(--danger);
    color: white;
    font-size: 0.65rem;
    font-weight: 800;
    padding: 2px 6px;
    border-radius: 6px;
    text-transform: uppercase;
    display: inline-block;
    box-shadow: 0 0 8px rgba(239, 68, 68, 0.4);
}

.original-price {
    text-decoration: line-through;
    opacity: 0.5;
    margin-right: 6px;
    font-size: 0.75rem;
}

/* Creative rainy night background overlays */
.rain-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="20" height="40" viewBox="0 0 20 40"><line x1="0" y1="0" x2="20" y2="40" stroke="rgba(255,255,255,0.06)" stroke-width="1"/></svg>');
    opacity: 0.85;
    z-index: -2;
    pointer-events: none;
    animation: rain-fall 0.8s linear infinite;
}

@keyframes rain-fall {
    0% {
        background-position: 0 0;
    }

    100% {
        background-position: 100px 200px;
    }
}

.scanlines-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(18, 16, 16, 0) 50%,
            rgba(0, 0, 0, 0.25) 50%), linear-gradient(90deg,
            rgba(157, 78, 221, 0.03),
            rgba(0, 240, 255, 0.01),
            rgba(157, 78, 221, 0.03));
    background-size: 100% 4px, 6px 100%;
    z-index: 999;
    pointer-events: none;
    opacity: 0.35;
}

.vip-text-badge {
    background: linear-gradient(135deg, #ffd700, #ffa500);
    color: #000000 !important;
    -webkit-text-fill-color: #000000 !important;
    font-size: 0.65rem;
    font-weight: 900;
    padding: 2px 6px;
    border-radius: 4px;
    margin-left: 6px;
    vertical-align: middle;
    text-transform: uppercase;
    box-shadow: 0 0 10px rgba(255, 215, 0, 0.4);
    display: inline-block;
    background-clip: unset !important;
    -webkit-background-clip: border-box !important;
}

.text-gold {
    color: #ffd700 !important;
}

.text-avatar-circle {
    width: 68px;
    height: 68px;
    border-radius: 50%;
    border: 2px solid var(--accent);
    box-shadow: 0 0 15px var(--accent-glow);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    font-weight: 900;
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    font-family: 'Outfit', sans-serif;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.vip-star-icon {
    display: inline-block;
    vertical-align: middle;
    margin-left: 6px;
    filter: drop-shadow(0 0 4px rgba(217, 70, 239, 0.6));
    animation: vipPulse 2s infinite ease-in-out;
}

@keyframes vipPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.15); filter: drop-shadow(0 0 8px rgba(217, 70, 239, 0.9)); }
}

/* Roles Section styling */
.roles-search-container {
    margin-bottom: 12px;
}
.roles-search-container input {
    width: 100%;
    padding: 12px 16px;
    background: rgba(22, 12, 42, 0.6);
    border: 1px solid var(--card-border);
    border-radius: 12px;
    color: #fff;
    font-size: 15px;
    outline: none;
    transition: all 0.3s ease;
}
.roles-search-container input:focus {
    border-color: var(--accent);
    box-shadow: 0 0 10px rgba(157, 78, 221, 0.3);
}

.roles-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 400px;
    overflow-y: auto;
    padding-right: 4px;
}

/* Custom Scrollbar for Roles List */
.roles-list::-webkit-scrollbar {
    width: 5px;
}
.roles-list::-webkit-scrollbar-track {
    background: rgba(22, 12, 42, 0.2);
}
.roles-list::-webkit-scrollbar-thumb {
    background: var(--accent);
    border-radius: 10px;
}

.role-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: rgba(22, 12, 42, 0.4);
    border: 1px solid var(--card-border);
    border-radius: 12px;
    transition: all 0.3s ease;
}
.role-card:hover {
    background: rgba(157, 78, 221, 0.08);
    border-color: var(--accent);
    transform: translateX(3px);
}
.role-emoji-container {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(157, 78, 221, 0.15);
    border-radius: 10px;
    font-size: 24px;
}
.role-info {
    flex: 1;
}
.role-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4px;
}
.role-name {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
}
.role-side {
    font-size: 11px;
    font-weight: bold;
    text-transform: uppercase;
    padding: 2px 6px;
    border-radius: 4px;
}
.role-side.mafia {
    background: rgba(239, 68, 68, 0.2);
    color: var(--danger);
}
.role-side.tinch {
    background: rgba(16, 185, 129, 0.2);
    color: var(--success);
}
.role-side.erkin {
    background: rgba(255, 189, 30, 0.2);
    color: var(--gold);
}
.role-desc {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.4;
}

/* Role Card 3D Flip Structure */
.role-card-wrapper {
    perspective: 1000px;
    height: 76px;
    position: relative;
    margin-bottom: 10px;
    flex-shrink: 0;
}

.role-card-inner {
    position: absolute;
    width: 100%;
    height: 100%;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    transform-style: preserve-3d;
}

.role-card-inner.flipped {
    transform: rotateY(180deg);
}

.role-card-front, .role-card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    border-radius: 12px;
    padding: 12px;
    display: flex;
    align-items: center;
    background: rgba(22, 12, 42, 0.4);
    border: 1px solid var(--card-border);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.role-card-back {
    transform: rotateY(180deg);
    background: rgba(26, 10, 36, 0.85);
    border-color: rgba(161, 0, 255, 0.4);
    box-shadow: 0 4px 20px rgba(161, 0, 255, 0.15);
}

/* Tab content visibility */
.tab-content {
    display: none;
    flex-direction: column;
    gap: 20px;
    animation: fadeIn 0.4s ease-out;
}
.tab-content.active {
    display: flex;
}

/* Sticky Bottom Navigation Bar */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 480px;
    height: 65px;
    background: rgba(13, 8, 28, 0.92);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border-top: 1px solid var(--card-border);
    display: flex;
    justify-content: space-around;
    align-items: center;
    z-index: 1000;
    padding: 0 10px;
    padding-bottom: env(safe-area-inset-bottom, 0); /* Support safe areas on iPhones */
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    color: var(--text-secondary);
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    flex: 1;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    padding: 8px 0;
}

.nav-item i {
    font-size: 20px;
}

.nav-item.active {
    color: var(--cyan);
    transform: translateY(-2px);
    text-shadow: 0 0 10px var(--cyan-glow);
}

.nav-item.active::after {
    content: '';
    position: absolute;
    bottom: 2px;
    width: 15px;
    height: 3px;
    background: var(--cyan);
    border-radius: 2px;
    box-shadow: 0 0 8px var(--cyan);
}

/* Compensate body padding-bottom for the sticky navigation */
body {
    padding-bottom: 95px !important;
}

/* Toast Notification */
.toast-notification {
    position: fixed;
    top: -100px;
    left: 50%;
    transform: translateX(-50%) scale(0.9);
    background: rgba(13, 8, 28, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid var(--card-border);
    padding: 14px 24px;
    border-radius: 16px;
    z-index: 9999;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    opacity: 0;
    width: 90%;
    max-width: 400px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.toast-notification.active {
    top: 24px;
    transform: translateX(-50%) scale(1);
    opacity: 1;
}

.toast-content {
    display: flex;
    align-items: center;
    gap: 12px;
}

.toast-notification.success {
    border-color: rgba(16, 185, 129, 0.4);
    box-shadow: 0 0 15px rgba(16, 185, 129, 0.2);
}
.toast-notification.success i {
    color: var(--success);
    font-size: 20px;
}

.toast-notification.error {
    border-color: rgba(239, 68, 68, 0.4);
    box-shadow: 0 0 15px rgba(239, 68, 68, 0.2);
}
.toast-notification.error i {
    color: var(--danger);
    font-size: 20px;
}

/* ==========================================
   Premium Cyberpunk & 3D Cards Styles
   ========================================== */

/* Theme Override - Neon Crimson/Violet */
:root {
    --bg-dark: #08080a;
    --card-bg: rgba(14, 10, 24, 0.6);
    --card-border: rgba(255, 42, 95, 0.25);
    --accent: #ff2a5f;
    --accent-glow: rgba(255, 42, 95, 0.4);
    --cyan-glow: rgba(0, 240, 255, 0.3);
}

/* 3D Card Flip Structure */
.shop-card-wrapper, .inventory-item-wrapper {
    perspective: 1000px;
    height: 76px;
    position: relative;
    margin-bottom: 12px;
}

.shop-card-inner, .inventory-item-inner {
    position: absolute;
    width: 100%;
    height: 100%;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    transform-style: preserve-3d;
}

.shop-card-inner.flipped, .inventory-item-inner.flipped {
    transform: rotateY(180deg);
}

.shop-card-front, .shop-card-back,
.inventory-item-front, .inventory-item-back {
    position: absolute;
    width: 100%;
    height: 100%;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    border-radius: 18px;
    padding: 12px 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.shop-card-back, .inventory-item-back {
    transform: rotateY(180deg);
    background: rgba(26, 10, 36, 0.85);
    border-color: rgba(161, 0, 255, 0.4);
    box-shadow: 0 4px 20px rgba(161, 0, 255, 0.15);
}

/* Daily Mine Styles */
.daily-mine-section {
    background: linear-gradient(135deg, rgba(20, 10, 35, 0.7), rgba(10, 5, 20, 0.7));
    border-color: rgba(0, 240, 255, 0.3);
    box-shadow: 0 8px 32px rgba(0, 240, 255, 0.1);
    margin-bottom: 20px;
}

.mine-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    padding: 10px 0;
}

.mine-visual {
    position: relative;
    width: 120px;
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 50%;
    border: 2px dashed rgba(0, 240, 255, 0.2);
    box-shadow: inset 0 0 20px rgba(0, 240, 255, 0.1);
}

.pickaxe-icon {
    font-size: 2.5rem;
    color: var(--cyan);
    position: absolute;
    top: 10px;
    right: 10px;
    transform: rotate(45deg);
    transform-origin: bottom left;
    filter: drop-shadow(0 0 6px var(--cyan-glow));
    z-index: 2;
    pointer-events: none;
}

.ore-block {
    font-size: 3rem;
    filter: drop-shadow(0 0 10px rgba(0, 240, 255, 0.4));
    user-select: none;
    z-index: 1;
    transition: transform 0.1s;
}

/* Animations */
.pickaxe-swing {
    animation: swing 0.4s ease-in-out;
}

.ore-shake {
    animation: shake 0.3s ease-in-out;
}

@keyframes swing {
    0% { transform: rotate(45deg); }
    50% { transform: rotate(-25deg); }
    100% { transform: rotate(45deg); }
}

@keyframes shake {
    0% { transform: scale(1) translate(0, 0); }
    20% { transform: scale(0.9) translate(-4px, 2px); }
    40% { transform: scale(1.1) translate(4px, -2px); }
    60% { transform: scale(0.95) translate(-2px, -2px); }
    80% { transform: scale(1.05) translate(2px, 2px); }
    100% { transform: scale(1) translate(0, 0); }
}

/* Mining Button */
.mine-btn {
    background: linear-gradient(135deg, var(--cyan), #00bcff);
    color: #000;
    border: none;
    border-radius: 12px;
    padding: 10px 24px;
    font-size: 0.95rem;
    font-weight: 800;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(0, 240, 255, 0.35);
    transition: transform 0.2s, box-shadow 0.2s;
}

.mine-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(0, 240, 255, 0.5);
}

.mine-btn:active {
    transform: translateY(1px);
}

.mine-btn:disabled {
    background: #333;
    color: #666;
    box-shadow: none;
    cursor: not-allowed;
}

.mine-timer {
    font-size: 0.85rem;
    color: var(--text-secondary);
    font-weight: 600;
    margin-top: 4px;
    display: block;
    text-align: center;
}

/* Sparkle particles */
.particle-container {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    pointer-events: none;
}

.particle {
    position: absolute;
    width: 6px;
    height: 6px;
    background: var(--cyan);
    border-radius: 50%;
    pointer-events: none;
    top: 50%;
    left: 50%;
    animation: flyOut 0.6s ease-out forwards;
}

@keyframes flyOut {
    0% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 1;
    }
    100% {
        transform: translate(calc(var(--dx) - 50%), calc(var(--dy) - 50%)) scale(0);
        opacity: 0;
    }
}

/* Partner Tab specific styles */
.partner-info-box {
    background: rgba(22, 12, 42, 0.4);
    border: 1px solid var(--card-border);
    border-radius: 18px;
    padding: 20px;
    text-align: center;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    margin-bottom: 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.partner-info-box p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin: 0;
}

.partner-info-box h4 {
    font-size: 1.3rem;
    color: var(--cyan);
    font-weight: 800;
    text-shadow: 0 0 10px var(--cyan-glow);
    margin: 0;
}

.partner-inventory-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-top: 10px;
}

.partner-item-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    padding: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.partner-item-card:hover {
    border-color: rgba(0, 240, 255, 0.2);
    box-shadow: 0 0 15px rgba(0, 240, 255, 0.1);
}

.partner-item-icon {
    font-size: 1.8rem;
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.3));
}

.partner-item-name {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--text-primary);
}

.partner-item-qty {
    font-size: 0.7rem;
    color: var(--text-secondary);
}

.partner-send-btn {
    width: 100%;
    background: linear-gradient(135deg, var(--accent), #7b2cbf);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 6px 12px;
    font-size: 0.75rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 4px 10px rgba(157, 78, 221, 0.3);
}

.partner-send-btn:active {
    transform: scale(0.95);
}

/* Pulsing heart animation */
.animate-pulse {
    animation: pulse 1.8s infinite ease-in-out;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        filter: drop-shadow(0 0 2px rgba(239, 68, 68, 0.5));
    }
    50% {
        transform: scale(1.12);
        filter: drop-shadow(0 0 8px rgba(239, 68, 68, 0.9));
    }
}

/* Achievements (Unvonlar) Grid */
.unvonlar-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.unvon-card {
    background: rgba(22, 12, 42, 0.4);
    border: 1px solid var(--card-border);
    border-radius: 14px;
    padding: 10px 12px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.unvon-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.75rem;
    font-weight: 800;
}

.unvon-name {
    color: var(--text-primary);
}

.unvon-level {
    color: var(--gold);
    font-size: 0.7rem;
    background: rgba(255, 189, 30, 0.15);
    padding: 1px 5px;
    border-radius: 4px;
    font-weight: 900;
}

.unvon-progress-bg {
    width: 100%;
    height: 6px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 3px;
    overflow: hidden;
    position: relative;
}

.unvon-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--accent), var(--cyan));
    border-radius: 3px;
    width: 0%;
    transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.unvon-footer {
    display: flex;
    justify-content: space-between;
    font-size: 0.65rem;
    color: var(--text-secondary);
}

/* Role Filters styling */
.role-filters-container {
    display: flex;
    gap: 8px;
    margin-bottom: 12px;
    overflow-x: auto;
    padding-bottom: 4px;
}

.role-filters-container::-webkit-scrollbar {
    height: 3px;
}

.filter-pill {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    color: var(--text-secondary);
    border-radius: 20px;
    padding: 6px 14px;
    font-size: 0.75rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.filter-pill:hover {
    color: #fff;
    border-color: rgba(255, 255, 255, 0.1);
}

.filter-pill.active {
    background: linear-gradient(135deg, var(--accent), #7b2cbf);
    color: white;
    border-color: transparent;
    box-shadow: 0 0 10px rgba(157, 78, 221, 0.3);
}

/* Floating Support FAB Button */
.support-fab-btn {
    position: fixed;
    bottom: 80px;
    right: 18px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--cyan), #0077b6);
    box-shadow: 0 4px 18px rgba(0, 240, 255, 0.45);
    border: 1px solid rgba(0, 240, 255, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-decoration: none;
    z-index: 1000;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    animation: fabPulse 2.5s infinite ease-in-out;
}

.support-fab-btn i {
    font-size: 1.4rem;
}

.support-fab-btn:hover {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 6px 22px rgba(0, 240, 255, 0.6);
}

.support-fab-btn:active {
    transform: scale(0.95);
}

@keyframes fabPulse {
    0%, 100% {
        box-shadow: 0 4px 16px rgba(0, 240, 255, 0.45);
    }
    50% {
        box-shadow: 0 4px 25px rgba(0, 240, 255, 0.85);
    }
}

/* Ads Carousel & Placeholder */
.ads-container {
    position: relative;
    background: rgba(22, 12, 42, 0.4);
    border: 1px solid var(--card-border);
    border-radius: 14px;
    padding: 14px;
    min-height: 90px;
    overflow: hidden;
}

.ad-slide {
    display: none;
    flex-direction: column;
    gap: 6px;
    animation: fadeIn 0.5s ease-in-out;
}

.ad-slide.active {
    display: flex;
}

.ad-badge {
    align-self: flex-start;
    background: var(--gold);
    color: #000;
    font-size: 0.55rem;
    font-weight: 900;
    padding: 2px 6px;
    border-radius: 4px;
    letter-spacing: 0.5px;
}

.ad-title {
    font-size: 0.85rem;
    font-weight: 800;
    color: var(--text-primary);
    margin: 0;
}

.ad-desc {
    font-size: 0.72rem;
    color: var(--text-secondary);
    line-height: 1.4;
    margin: 0;
}

.ad-dots {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-top: 10px;
}

.ad-dot {
    width: 6px;
    height: 6px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s;
}

.ad-dot.active {
    background: var(--gold);
    transform: scale(1.2);
    box-shadow: 0 0 6px var(--gold-glow);
}

.placeholder-ad {
    border: 1px dashed rgba(255, 189, 30, 0.2);
    background: rgba(255, 189, 30, 0.02);
    border-radius: 12px;
    padding: 18px 14px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
}

.placeholder-ad:hover {
    border-color: rgba(255, 189, 30, 0.4);
    background: rgba(255, 189, 30, 0.04);
}

.placeholder-ad p {
    font-size: 0.85rem;
    font-weight: 800;
    color: var(--gold);
    margin: 0 0 4px 0;
    text-shadow: 0 0 10px var(--gold-glow);
}

.placeholder-ad span {
    font-size: 0.72rem;
    color: var(--text-secondary);
}

/* Sidebar Menu Styling */
.sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(5px);
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.sidebar-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.sidebar-menu {
    position: fixed;
    top: 0;
    left: -280px;
    width: 280px;
    height: 100vh;
    background: #0f0d1a;
    border-right: 1px solid var(--card-border);
    z-index: 1001;
    display: flex;
    flex-direction: column;
    box-shadow: 10px 0 30px rgba(0, 0, 0, 0.6);
    transition: left 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.sidebar-menu.active {
    left: 0;
}

.sidebar-header {
    padding: 24px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.sidebar-user-row {
    display: flex;
    align-items: center;
    gap: 12px;
}

.sidebar-avatar-container {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 2px solid var(--gold);
    overflow: hidden;
    box-shadow: 0 0 10px var(--gold-glow);
}

.sidebar-avatar-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.sidebar-user-info {
    display: flex;
    flex-direction: column;
}

.sidebar-user-name {
    font-weight: 700;
    color: #fff;
    font-size: 1rem;
}

.sidebar-user-uname {
    font-size: 0.8rem;
    color: var(--gold);
}

.sidebar-links {
    flex: 1;
    overflow-y: auto;
    padding: 15px 0;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 20px;
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.sidebar-link i {
    width: 20px;
    text-align: center;
    color: var(--gold);
    font-size: 1.1rem;
}

.sidebar-link:hover {
    color: #fff;
    background: rgba(255, 189, 30, 0.05);
}

.sidebar-link.active {
    color: var(--gold);
    background: rgba(255, 189, 30, 0.08);
    border-left: 3px solid var(--gold);
}

.sidebar-footer {
    padding: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.btn-vip-gold {
    width: 100%;
    background: linear-gradient(135deg, #ffbd1e, #d97706);
    color: #000;
    font-weight: 800;
    border: none;
    border-radius: 12px;
    padding: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(255, 189, 30, 0.3);
    transition: all 0.2s ease;
}

.btn-vip-gold:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 189, 30, 0.45);
}

/* Form Styles for Transfer tab */
.transfer-form {
    display: flex;
    flex-direction: column;
}

.form-label {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-secondary);
    margin-bottom: 8px;
    margin-top: 15px;
}

.form-toggle-group {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-bottom: 12px;
}

.toggle-btn {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.06);
    color: var(--text-secondary);
    border-radius: 10px;
    padding: 8px;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s ease;
    outline: none;
}

.toggle-btn.active {
    background: rgba(255, 189, 30, 0.1);
    border-color: var(--gold);
    color: var(--gold);
}

.form-input, .form-select {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: #fff;
    border-radius: 12px;
    padding: 12px 16px;
    font-size: 0.95rem;
    width: 100%;
    outline: none;
    transition: border-color 0.2s;
}

.form-input:focus, .form-select:focus {
    border-color: var(--gold);
}

.btn-gold {
    background: linear-gradient(135deg, #ffbd1e, #d97706);
    color: #000;
    font-weight: 800;
    border: none;
    border-radius: 12px;
    padding: 12px;
    cursor: pointer;
    transition: transform 0.2s;
}

.btn-gold:hover {
    background: linear-gradient(135deg, #ffd053, #f59e0b);
}

.btn-gold:active {
    transform: scale(0.98);
}

/* User meta details */
.user-meta-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 4px;
}

.user-title-badge {
    border: 1px solid var(--gold);
    color: var(--gold);
    font-size: 0.7rem;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 6px;
    background: rgba(255, 189, 30, 0.05);
}

.vip-text-badge {
    background: var(--gold);
    color: #000;
    font-size: 0.7rem;
    font-weight: 800;
    padding: 2px 8px;
    border-radius: 6px;
    box-shadow: 0 0 10px rgba(255, 189, 30, 0.3);
}

/* Custom rounded cards with gold border */
.balance-card {
    border-color: var(--card-border) !important;
}

.balance-card:hover {
    border-color: var(--gold) !important;
}

.info-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 40px 20px;
}

.info-card h4 {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.info-card p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.4;
}

.table-wrapper {
    overflow-x: auto;
    border-radius: 16px;
}

.leaderboard-table {
    width: 100%;
    border-collapse: collapse;
}

.leaderboard-table th, .leaderboard-table td {
    padding: 14px 18px;
    text-align: left;
}

.leaderboard-table th {
    background: rgba(255, 189, 30, 0.05);
    font-weight: 700;
    color: var(--text-secondary);
    font-size: 0.85rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.leaderboard-table td {
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
    font-size: 0.9rem;
    font-weight: 600;
}

.rank {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 0.8rem;
}

.rank-1 { background-color: var(--gold); color: #000; }
.rank-2 { background-color: #c0c0c0; color: #000; }
.rank-3 { background-color: #cd7f32; color: #000; }

.history-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.hist-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.02);
    font-size: 0.95rem;
}

.hist-details {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.hist-details span {
    font-weight: 600;
    font-size: 0.9rem;
}

.hist-details small {
    color: var(--text-secondary);
    font-size: 0.75rem;
}

.hist-val {
    font-weight: 700;
    font-size: 0.95rem;
}

.tab-title-area {
    margin-bottom: 16px;
    padding: 4px;
}

.tab-title-area h3 {
    font-size: 1.4rem;
    font-weight: 900;
    color: #fff;
}

.tab-title-area p {
    font-size: 0.82rem;
    color: var(--text-secondary);
}

/* Override active state colors for gold layout */
.nav-item.active {
    color: var(--gold) !important;
}

.xp-pct {
    color: var(--gold) !important;
}

.xp-bar-fill {
    background: linear-gradient(to right, var(--gold), #ffd053) !important;
    box-shadow: 0 0 8px var(--gold-glow) !important;
}

.avatar-container img {
    border-color: var(--gold) !important;
    box-shadow: 0 0 15px var(--gold-glow) !important;
}

.rank-badge {
    background: linear-gradient(135deg, #d97706, var(--gold)) !important;
    color: #000 !important;
    border-color: var(--gold) !important;
}

.mine-btn {
    background: linear-gradient(135deg, #ffbd1e, #d97706) !important;
    color: #000 !important;
}

.mine-btn:hover {
    background: linear-gradient(135deg, #ffd053, #f59e0b) !important;
    box-shadow: 0 4px 15px var(--gold-glow) !important;
}

.filter-pill.active {
    background: var(--gold) !important;
    color: #000 !important;
    box-shadow: 0 4px 12px var(--gold-glow) !important;
}

