:root {
    --orange:      #AA00FF;
    --orange-lt:   #D580FF;
    --orange-dk:   #7700CC;
    --orange-glow: rgba(170,0,255,0.35);
    --violet-glow: rgba(170,0,255,0.30);
    --bg:          #110e09;
    --bg-mid:      #1a1308;
    --bg-panel:    #1e1810;
    --bg-card:     #252018;
    --bg-card-lt:  #2e2820;
    --border:      rgba(170,0,255,0.18);
    --border-lt:   rgba(170,0,255,0.35);
    --text:        #f4ebd9;
    --text-mid:    #d0c4af;
    --text-dim:    #8e826e;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
body {
    font-family: 'Rajdhani', sans-serif;
    background-color: #0d0a07;
    background-image:
        radial-gradient(ellipse 800px 500px at 15% 15%, rgba(170,0,255,0.40), transparent 65%),
        radial-gradient(ellipse 700px 450px at 85% 10%, rgba(170,0,255,0.32), transparent 65%),
        radial-gradient(ellipse 600px 400px at 50% 5%, rgba(200,100,255,0.22), transparent 55%),
        radial-gradient(ellipse 400px 250px at 50% 90%, rgba(170,0,255,0.12), transparent 60%),
        radial-gradient(circle 800px at 50% 50%, transparent 20%, #0d0a07 75%),
        linear-gradient(180deg, #1a140e 0%, #0d0a07 50%, #0a0805 100%);
    background-size: 100% 100%;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    color: var(--text);
    font-weight: 500;
    overflow: hidden;
    height: 100vh;
}

.dust-container { position: fixed; inset: 0; pointer-events: none; z-index: 0; overflow: hidden; }
.dust-particle { position: absolute; width: 3px; height: 3px; background: rgba(200,100,255,0.75); border-radius: 50%; box-shadow: 0 0 10px rgba(170,0,255,0.7), 0 0 22px rgba(170,0,255,0.4); animation: dustFloat linear infinite; }
.dust-particle:nth-child(1) { left: 8%; top: 105%; animation-duration: 10s; animation-delay: 0s; }
.dust-particle:nth-child(2) { left: 18%; top: 105%; animation-duration: 14s; animation-delay: 1s; width: 4px; height: 4px; }
.dust-particle:nth-child(3) { left: 28%; top: 105%; animation-duration: 11s; animation-delay: 3s; }
.dust-particle:nth-child(4) { left: 38%; top: 105%; animation-duration: 16s; animation-delay: 0.5s; width: 5px; height: 5px; }
.dust-particle:nth-child(5) { left: 48%; top: 105%; animation-duration: 9s; animation-delay: 2s; }
.dust-particle:nth-child(6) { left: 58%; top: 105%; animation-duration: 13s; animation-delay: 4s; width: 4px; height: 4px; }
.dust-particle:nth-child(7) { left: 68%; top: 105%; animation-duration: 15s; animation-delay: 1.5s; }
.dust-particle:nth-child(8) { left: 78%; top: 105%; animation-duration: 12s; animation-delay: 5s; width: 4px; height: 4px; }
.dust-particle:nth-child(9) { left: 88%; top: 105%; animation-duration: 17s; animation-delay: 2.5s; }
.dust-particle:nth-child(10) { left: 12%; top: 105%; animation-duration: 8s; animation-delay: 6s; width: 5px; height: 5px; }
.dust-particle:nth-child(11) { left: 42%; top: 105%; animation-duration: 19s; animation-delay: 3.5s; }
.dust-particle:nth-child(12) { left: 72%; top: 105%; animation-duration: 10s; animation-delay: 7s; width: 3px; height: 3px; }
.dust-particle:nth-child(13) { left: 3%; top: 105%; animation-duration: 13s; animation-delay: 4.5s; width: 4px; height: 4px; }
.dust-particle:nth-child(14) { left: 33%; top: 105%; animation-duration: 11s; animation-delay: 5.5s; }
.dust-particle:nth-child(15) { left: 63%; top: 105%; animation-duration: 15s; animation-delay: 6.5s; width: 4px; height: 4px; }
.dust-particle:nth-child(16) { left: 93%; top: 105%; animation-duration: 9s; animation-delay: 7.5s; width: 5px; height: 5px; }
@keyframes dustFloat {
    0% { transform: translateY(0) translateX(0) scale(1); opacity: 0; }
    8% { opacity: 1; }
    25% { transform: translateY(-30vh) translateX(20px) scale(1.2); }
    50% { transform: translateY(-55vh) translateX(-15px) scale(0.9); }
    75% { transform: translateY(-80vh) translateX(10px) scale(1.1); opacity: 0.9; }
    100% { transform: translateY(-115vh) translateX(-5px) scale(0.7); opacity: 0; }
}

.vignette-overlay { position: fixed; inset: 0; pointer-events: none; z-index: 1; background: radial-gradient(circle at 50% 45%, transparent 20%, rgba(0,0,0,0.35) 65%, rgba(0,0,0,0.65) 100%); }
.grid-overlay { position: fixed; inset: 0; pointer-events: none; z-index: 1; background-image: linear-gradient(rgba(170,0,255,0.05) 1px, transparent 1px), linear-gradient(90deg, rgba(170,0,255,0.05) 1px, transparent 1px); background-size: 60px 60px; }
.pulse-glow { position: fixed; inset: 0; pointer-events: none; z-index: 1; background: radial-gradient(circle 500px at 50% 80%, rgba(170,0,255,0.12), transparent 70%); animation: pulseGlow 4s ease-in-out infinite alternate; }
@keyframes pulseGlow { 0% { opacity: 0.5; } 100% { opacity: 1; } }

.store-container {
    display: grid;
    grid-template-columns: 280px 1fr;
    height: 100vh;
    max-width: 1600px;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
}

/* ─── SIDEBAR & LOGGED-IN DISPLAY ─── */
.sidebar {
    background-color: var(--bg-panel);
    border-right: 1px solid var(--border);
    padding: 1.5rem 1rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    box-shadow: 10px 0 30px rgba(0,0,0,0.5);
    z-index: 10;
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
}
.logo-area {
    text-align: center;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
}
.logo-title {
    font-family: 'Exo 2', sans-serif;
    font-weight: 900;
    font-size: 1.3rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: #fff;
    text-shadow: 0 0 15px var(--orange-glow);
}
.logo-title span { color: var(--orange); }

.player-display {
    display: none;
    align-items: center;
    gap: 10px;
    background: rgba(0,0,0,0.25);
    border: 1px solid var(--border);
    padding: 8px;
    border-radius: 6px;
}
.player-display img {
    width: 36px;
    height: 36px;
    object-fit: contain;
    image-rendering: pixelated;
    filter: drop-shadow(0 4px 6px rgba(0,0,0,0.4));
}
.player-info { display: flex; flex-direction: column; }
.player-info .welcome { font-size: 0.65rem; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.05em; }
.player-info .username { font-size: 0.9rem; font-weight: 700; color: #fff; }

.sidebar-menu { display: flex; flex-direction: column; gap: 8px; list-style: none; }
.sidebar-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    color: var(--text-mid);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    border-radius: 4px;
    border: 1px solid transparent;
    transition: all 0.2s ease;
    cursor: pointer;
}
.sidebar-item i { width: 18px; font-size: 1rem; color: var(--text-dim); transition: color 0.2s; }
.sidebar-item:hover { background: rgba(170,0,255,0.05); color: #fff; border-color: rgba(170,0,255,0.1); }
.sidebar-item:hover i { color: var(--orange-lt); }
.sidebar-item.active { background: linear-gradient(90deg, var(--orange-dk), var(--bg-panel)); color: #fff; border-color: var(--border); box-shadow: inset 3px 0 0 var(--orange); }
.sidebar-item.active i { color: var(--orange-lt); }

.sidebar-footer { margin-top: auto; padding-top: 1rem; border-top: 1px solid var(--border); display: flex; flex-direction: column; gap: 8px; }
.discord-widget { display: flex; align-items: center; gap: 10px; background: #181c25; border: 1px solid rgba(88,101,242,0.2); padding: 8px; border-radius: 4px; text-decoration: none; color: #fff; transition: background 0.2s; }
.discord-widget:hover { background: #1f2532; }
.discord-widget i { font-size: 1.2rem; color: #5865F2; }
.discord-title { font-size: 0.75rem; font-weight: 700; text-transform: uppercase; }
.discord-count { font-size: 0.65rem; color: #949ba4; }

/* ─── LEADERBOARD SECTION ─── */
.leaderboard-section { background: rgba(0,0,0,0.25); border: 1px solid var(--border); border-radius: 6px; padding: 1rem; margin-top: 0.5rem; }
.leaderboard-title { font-family: 'Exo 2', sans-serif; font-size: 0.8rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.05em; color: var(--orange-lt); margin-bottom: 0.75rem; text-align: center; }
.leaderboard-list { display: flex; flex-direction: column; gap: 0.5rem; }
.leaderboard-item { display: flex; align-items: center; gap: 8px; padding: 0.4rem 0.6rem; background: rgba(0,0,0,0.2); border-radius: 4px; transition: background 0.2s; }
.leaderboard-item:hover { background: rgba(170,0,255,0.1); }
.leaderboard-rank { font-family: 'Exo 2', sans-serif; font-size: 0.7rem; font-weight: 900; color: var(--orange); min-width: 18px; }
.leaderboard-head { width: 24px; height: 24px; border-radius: 4px; image-rendering: pixelated; filter: drop-shadow(0 2px 4px rgba(0,0,0,0.3)); }
.leaderboard-name { font-size: 0.75rem; font-weight: 600; color: var(--text); flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.leaderboard-amount { font-family: 'Exo 2', sans-serif; font-size: 0.7rem; font-weight: 700; color: #7CFC00; }

/* ─── MAIN CONTENT VIEWPORT ─── */
.main-content { padding: 0.75rem 1.25rem; display: flex; flex-direction: column; gap: 0.75rem; height: 100vh; overflow: hidden; }
.top-utility-bar { display: flex; justify-content: space-between; align-items: center; background: var(--bg-panel); border: 1px solid var(--border); padding: 0.5rem 1rem; border-radius: 6px; box-shadow: 0 10px 30px rgba(0,0,0,0.3); }

.site-logo { max-height: 42px; cursor: pointer; transition: all 0.25s ease; filter: drop-shadow(0 0 6px rgba(170,0,255,0.3)); }
.site-logo:hover { filter: drop-shadow(0 0 12px rgba(170,0,255,0.6)); transform: scale(1.04); }
.banner-header-area { position: relative; width: 100%; border-radius: 8px; overflow: visible; display: flex; flex-direction: column; min-height: 190px; box-shadow: 0 8px 24px rgba(0,0,0,0.5); border: 1px solid var(--border); }
.banner-bg-clip { position: absolute; inset: 0; border-radius: 8px; overflow: hidden; z-index: 0; pointer-events: none; }
.banner-bg-clip img { width: 100%; height: 100%; object-fit: cover; object-position: center; display: block; }
.banner-utility-row { position: relative; z-index: 200; display: flex; align-items: center; gap: 0.6rem; padding: 0.45rem 0.85rem; background: rgba(0,0,0,0.68); backdrop-filter: blur(6px); border-bottom: 1px solid rgba(170,0,255,0.18); flex-wrap: wrap; }
.banner-center-logo { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; position: relative; z-index: 100; padding: 0.4rem 0.5rem; perspective: 800px; transform-style: preserve-3d; }
.banner-center-logo .join-logo { max-height: 110px; width: auto; display: block; filter: drop-shadow(0 12px 24px rgba(0,0,0,0.6)) drop-shadow(0 0 12px rgba(170,0,255,0.6)); transition: all 0.3s ease; cursor: pointer; transform: translateZ(40px); }
.banner-center-logo .join-logo:hover { filter: drop-shadow(0 16px 32px rgba(0,0,0,0.7)) drop-shadow(0 0 18px rgba(170,0,255,0.85)) drop-shadow(0 0 4px #fff); transform: translateZ(60px) scale(1.03); }
.banner-center-logo .join-logo.bounce { animation: logoBounce 0.55s ease; }
.banner-center-logo .ip-banner-label { font-size: 0.7rem; color: var(--text-dim); font-weight: 700; text-transform: uppercase; display: flex; align-items: center; gap: 6px; background: rgba(0,0,0,0.6); padding: 3px 10px; border-radius: 4px; margin-top: 4px; }
.banner-center-logo .ip-copied-toast { position: absolute; bottom: 8px; left: 50%; transform: translateX(-50%); }
.ip-home-banner { display: flex; align-items: center; justify-content: center; transition: all 0.3s ease; position: relative; overflow: hidden; padding: 0.5rem; border-radius: 8px; min-height: 180px; perspective: 800px; transform-style: preserve-3d; margin-bottom: 0; }
.ip-home-banner .banner-bg-img { position: absolute; top: -5px; left: 0; width: 100%; height: calc(100% + 10px); object-fit: contain; object-position: center center; border-radius: 8px; z-index: 0; pointer-events: none; }
.ip-home-banner .join-logo { max-height: 130px; width: auto; display: block; filter: drop-shadow(0 12px 24px rgba(0,0,0,0.6)) drop-shadow(0 0 12px rgba(170,0,255,0.6)); transition: all 0.3s ease; position: relative; z-index: 100; transform: translateZ(40px); cursor: pointer; margin-top: -10px; }
.ip-home-banner .join-logo:hover { filter: drop-shadow(0 16px 32px rgba(0,0,0,0.7)) drop-shadow(0 0 18px rgba(170,0,255,0.85)) drop-shadow(0 0 4px #fff); transform: translateZ(60px) scale(1.03); }
.ip-home-banner .join-logo.bounce { animation: logoBounce 0.55s ease; }
@keyframes logoBounce {
    0%   { transform: translateZ(40px) scale(1); }
    30%  { transform: translateZ(40px) scale(0.85); }
    50%  { transform: translateZ(40px) scale(1.12); }
    70%  { transform: translateZ(40px) scale(0.95); }
    100% { transform: translateZ(40px) scale(1); }
}
.ip-home-banner .ip-banner-label { position: absolute; bottom: 6px; right: 12px; font-size: 0.7rem; color: var(--text-dim); font-weight: 700; text-transform: uppercase; display: flex; align-items: center; gap: 6px; background: rgba(0,0,0,0.6); padding: 3px 10px; border-radius: 4px; pointer-events: none; }
.ip-copied-toast {
    display: none;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: linear-gradient(135deg, #1a5c1a 0%, #2e8b2e 100%);
    color: #fff;
    font-family: 'Exo 2', sans-serif;
    font-weight: 800;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    padding: 8px 18px;
    border-radius: 20px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.4), 0 0 8px rgba(46,139,46,0.4);
    position: absolute;
    left: 50%;
    transform: translateX(-50%) scale(0.8);
    z-index: 200;
    width: fit-content;
    animation: toastPop 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    pointer-events: none;
    top: calc(100% + 4px);
}
.ip-copied-toast.visible { display: flex; transform: translateX(-50%) scale(1); }
.ip-copied-toast i { color: #7CFC00; font-size: 0.9rem; }
@keyframes toastPop {
    0%   { opacity: 0; transform: translateX(-50%) translateY(-10px) scale(0.8); }
    100% { opacity: 1; transform: translateX(-50%) translateY(0) scale(1); }
}
.persistent-gallery { display: block; margin-bottom: 0.75rem; }
.persistent-gallery.visible { display: block; }
.purchase-log-row { display: grid; grid-template-columns: 80px 1fr 80px 60px 1fr; gap: 8px; align-items: center; padding: 6px 8px; border-bottom: 1px solid rgba(255,255,255,0.03); font-size: 0.78rem; }
.purchase-log-header { font-weight: 800; color: var(--orange-lt); text-transform: uppercase; font-size: 0.7rem; }
.audit-log-row { display: grid; grid-template-columns: 120px 80px 1fr; gap: 8px; align-items: center; padding: 6px 8px; border-bottom: 1px solid rgba(255,255,255,0.03); font-size: 0.78rem; }
.audit-log-header { font-weight: 800; color: var(--orange-lt); text-transform: uppercase; font-size: 0.7rem; }
.gallery-drop-zone { border: 2px dashed rgba(170,0,255,0.35); border-radius: 8px; padding: 1.2rem; text-align: center; cursor: pointer; transition: all 0.25s ease; background: rgba(170,0,255,0.04); }
.gallery-drop-zone.dragover { border-color: var(--orange); background: rgba(170,0,255,0.12); transform: scale(1.01); }
.gallery-drop-zone:hover { border-color: var(--orange); background: rgba(170,0,255,0.08); }
.vote-site-img { width: 40px; height: 40px; object-fit: cover; border-radius: 6px; border: 1px solid var(--border); }
.forum-pop-carousel { display: flex; gap: 12px; overflow-x: auto; padding: 8px 0; margin-bottom: 1rem; }
.forum-pop-card { min-width: 220px; background: var(--bg-panel); border: 1px solid var(--border); border-radius: 8px; padding: 10px; cursor: pointer; transition: all 0.2s ease; flex-shrink: 0; }
.forum-pop-card:hover { border-color: var(--orange); transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,0.3); }
.forum-pop-img { width: 100%; height: 100px; object-fit: contain; border-radius: 6px; margin-bottom: 8px; background: var(--bg-sidebar); }
.forum-pop-title { font-size: 0.82rem; font-weight: 700; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.forum-pop-meta { font-size: 0.7rem; color: var(--text-dim); margin-top: 4px; }
.forum-staff-badge { font-size: 0.62rem; padding: 2px 6px; border-radius: 3px; font-weight: 700; text-transform: uppercase; margin-left: 6px; }
.forum-badge-owner { background: #e84c4c; color: #fff; }
.forum-badge-admin { background: var(--orange); color: #fff; }
.forum-badge-mod { background: #4c8ce8; color: #fff; }
.forum-ban-box { background: rgba(232,76,76,0.1); border: 1px solid rgba(232,76,76,0.3); padding: 8px 12px; border-radius: 4px; font-size: 0.75rem; color: #e84c4c; margin-bottom: 0.5rem; }

.cart-status-box { display: flex; align-items: center; gap: 15px; position: relative; cursor: pointer; padding: 6px 12px; border-radius: 4px; }
.cart-status-box:hover .hover-cart-dropdown,
.hover-cart-dropdown:hover { display: block; }
.cart-status-box::after { content:''; position:absolute; top:100%; left:0; right:0; height:10px; z-index:99; }
.cart-icon-wrapper { position: relative; font-size: 1.4rem; color: var(--orange-lt); }
.cart-summary-text { text-align: right; }
.cart-summary-title { font-size: 0.75rem; color: var(--text-dim); text-transform: uppercase; }
.cart-counter-value { font-size: 1.1rem; font-weight: 700; color: #fff; }
.hover-cart-dropdown { display: none; position: absolute; top: 100%; right: 0; width: 280px; background: var(--bg-panel); border: 1px solid var(--orange); border-radius: 6px; padding: 1.2rem; box-shadow: 0 15px 35px rgba(0,0,0,0.8); z-index: 100; margin-top: 5px; }
.hover-cart-dropdown h4 { font-family: 'Exo 2', sans-serif; font-size: 0.9rem; font-weight: 800; border-bottom: 1px solid var(--border); padding-bottom: 8px; margin-bottom: 10px; text-transform: uppercase; color: #fff; }
.hover-cart-row { display: flex; justify-content: space-between; font-size: 0.9rem; padding: 4px 0; border-bottom: 1px solid rgba(255,255,255,0.03); }
.hover-cart-name { color: var(--text-mid); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 180px; }
.hover-cart-price { color: #7CFC00; font-weight: 700; }
.hover-cart-footer { margin-top: 12px; padding-top: 10px; }
.hover-cart-total { text-align: right; font-family: 'Exo 2',sans-serif; font-size: 0.85rem; font-weight: 700; color: #fff; border-top: 1px solid var(--border); padding-top: 8px; margin-top: 8px; }
.hover-cart-total span { color: #7CFC00; }
.hover-cart-remove { color: #ff4444; font-size: 1rem; cursor: pointer; transition: color 0.15s; line-height:1; padding:0 4px; }
.hover-cart-remove:hover { color: #ff8888; }
.checkout-remove-btn { color: #ff4444; font-size: 1rem; cursor: pointer; background:none; border:none; padding:0 4px; margin-left:6px; line-height:1; }
.checkout-remove-btn:hover { color: #ff8888; }

/* ─── VOTE PAGE ─── */
.vote-grid { display: grid; grid-template-columns: repeat(auto-fill,minmax(220px,1fr)); gap: 1rem; }
.vote-card { background: linear-gradient(145deg, var(--bg-card), var(--bg-card-lt)); border: 1px solid var(--border); border-radius: 8px; padding: 1.25rem; display: flex; flex-direction: column; align-items: center; gap: 0.75rem; transition: all 0.25s; }
.vote-card:hover { transform: translateY(-3px); border-color: var(--orange-lt); box-shadow: 0 10px 25px rgba(0,0,0,0.5); }
.vote-icon { font-size: 2.2rem; color: var(--orange); }
.vote-title { font-family: 'Exo 2',sans-serif; font-weight: 800; font-size: 0.9rem; text-transform: uppercase; color: #fff; }
.vote-desc { font-size: 0.82rem; color: var(--text-mid); text-align: center; line-height: 1.3; }
.vote-btn { background: linear-gradient(135deg, var(--orange), var(--orange-dk)); color: #fff; font-family: 'Exo 2',sans-serif; font-size: 0.75rem; font-weight: 800; text-transform: uppercase; padding: 8px 18px; border: none; border-radius: 4px; cursor: pointer; text-decoration: none; transition: all 0.15s; }
.vote-btn:hover { filter: brightness(1.15); }
.vote-reward-badge { display:inline-flex; align-items:center; gap:5px; background:rgba(124,252,0,0.1); border:1px solid rgba(124,252,0,0.3); border-radius:5px; padding:4px 10px; font-size:0.72rem; font-weight:800; color:#7CFC00; }

/* ─── UPDATES PAGE ─── */
.updates-list { display: flex; flex-direction: column; gap: 0.5rem; overflow-y: auto; }
.update-card { background: rgba(0,0,0,0.2); border: 1px solid var(--border); border-radius: 6px; padding: 0.9rem 1.1rem; transition: all 0.2s; }
.update-card:hover { border-color: var(--orange-lt); background: rgba(170,0,255,0.04); }
.update-header { display: flex; align-items: center; gap: 10px; margin-bottom: 0.4rem; }
.update-badge { background: var(--orange); color: #fff; font-family: 'Exo 2',sans-serif; font-size: 0.6rem; font-weight: 900; padding: 2px 7px; border-radius: 3px; text-transform: uppercase; }
.update-badge.bugfix { background: #cc4444; }
.update-badge.feature { background: #4488cc; }
.update-date { font-size: 0.72rem; color: var(--text-dim); }
.update-title { font-family: 'Exo 2',sans-serif; font-weight: 700; font-size: 0.88rem; color: #fff; margin-bottom: 0.25rem; }
.update-body { font-size: 0.82rem; color: var(--text-mid); line-height: 1.4; }

/* ─── FORUMS ─── */
.forums-auth { max-width: 380px; margin: 0 auto; padding-top: 2rem; }
.forums-auth-tabs { display: flex; gap: 4px; margin-bottom: 1rem; border-bottom: 1px solid var(--border); }
.forum-auth-tab { background:none; border:none; color:var(--text-dim); font-family:'Exo 2',sans-serif; font-size:0.75rem; font-weight:800; text-transform:uppercase; padding:6px 12px; cursor:pointer; border-bottom:2px solid transparent; transition:all 0.15s; }
.forum-auth-tab:hover { color:#fff; }
.forum-auth-tab.active { color:var(--orange-lt); border-bottom-color:var(--orange); }
.forums-toolbar { display: flex; gap: 8px; align-items: center; margin-bottom: 0.75rem; flex-wrap: wrap; }
.forums-list { display: flex; flex-direction: column; gap: 0.5rem; overflow-y: auto; }
.forum-row { background: linear-gradient(135deg,#1c1610,#14110d); border: 1px solid rgba(255,255,255,0.07); border-radius: 8px; padding: 0.8rem 1rem; cursor: pointer; transition: all 0.2s; display: flex; gap: 12px; align-items: flex-start; box-shadow: 0 1px 6px rgba(0,0,0,0.35); border-left: 3px solid transparent; }
.forum-row:hover { border-color: rgba(170,0,255,0.5); border-left-color: var(--orange); background: linear-gradient(135deg,#221a0f,#1a140e); box-shadow: 0 2px 10px rgba(170,0,255,0.1); transform: translateY(-1px); }
.forum-row-meta { display: flex; gap: 8px; font-size: 0.7rem; color: var(--text-dim); margin-bottom: 0.25rem; align-items: center; flex-wrap: wrap; }
.forum-row-title { font-family: 'Exo 2',sans-serif; font-weight: 800; font-size: 0.92rem; color: #fff; line-height: 1.3; }
.forum-row-preview { font-size: 0.78rem; color: var(--text-mid); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 3px; }
.forum-row-content { flex: 1; min-width: 0; }
.forum-row-thumb { width: 56px; height: 56px; flex-shrink: 0; border-radius: 6px; overflow: hidden; border: 1px solid var(--border); background: rgba(0,0,0,0.3); display: flex; align-items: center; justify-content: center; }
.forum-row-thumb img { max-width: 100%; max-height: 100%; object-fit: cover; display: block; }
.forum-thread-view { display: flex; flex-direction: column; gap: 0.6rem; padding-right: 6px; }
.forum-thread-banner { border-radius: 8px; padding: 12px 16px; margin-bottom: 0.5rem; position: relative; overflow: hidden; }
.forum-thread-banner::before { content:''; position:absolute; inset:0; background: linear-gradient(135deg,rgba(255,255,255,0.04),transparent); pointer-events:none; }
.forum-thread-banner-cat { font-size: 0.65rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.1em; opacity: 0.9; margin-bottom: 5px; }
.forum-thread-banner-title { font-family: 'Exo 2',sans-serif; font-size: 1.1rem; font-weight: 900; color: #fff; line-height: 1.3; margin-bottom: 4px; }
.forum-thread-banner-meta { font-size: 0.7rem; opacity: 0.7; }
.forum-post-img-wrap { width: 100%; overflow: hidden; border-radius: 6px; margin-top: 0.5rem; border: 1px solid var(--border); display: block; background: rgba(0,0,0,0.3); cursor: pointer; position: relative; max-height: 320px; }
.forum-post-img-wrap img { width: 100%; height: auto; display: block; border-radius: 6px; }
.forum-post-img-wrap.forum-img-zoomed { max-height: none; }
.forum-reply-img-wrap { width: 100%; overflow: hidden; border-radius: 6px; margin-top: 0.4rem; border: 1px solid var(--border); display: block; background: rgba(0,0,0,0.3); cursor: pointer; position: relative; max-height: 220px; }
.forum-reply-img-wrap img { width: 100%; height: auto; display: block; border-radius: 6px; }
.forum-reply-img-wrap.forum-img-zoomed { max-height: none; }
.forum-zoom-hint { position: absolute; bottom: 4px; right: 6px; background: rgba(0,0,0,0.75); color: var(--orange-lt); font-size: 0.65rem; padding: 2px 8px; border-radius: 4px; pointer-events: none; opacity: 0.85; }
.forum-post-body { background: #141210; border: 1px solid rgba(255,255,255,0.08); border-radius: 8px; padding: 1rem; box-shadow: 0 2px 10px rgba(0,0,0,0.4); }
.forum-post-header { display: flex; gap: 10px; margin-bottom: 0.6rem; }
.forum-avatar { width: 32px; height: 32px; border-radius: 4px; border: 1px solid var(--border); }
.forum-author-name { font-family: 'Exo 2',sans-serif; font-weight: 700; font-size: 0.8rem; color: var(--orange-lt); }
.forum-post-time { font-size: 0.7rem; color: var(--text-dim); }
.forum-reply { border-left: 2px solid var(--border); padding-left: 12px; margin-left: 8px; }
/* ─── REACTION POPUP ─── */
.forum-react-pill { background:rgba(255,255,255,0.06); border:1px solid rgba(255,255,255,0.1); border-radius:20px; padding:3px 9px; font-size:0.7rem; cursor:pointer; color:var(--text-mid); display:inline-flex; align-items:center; gap:4px; transition:all 0.15s; font-family:inherit; }
.forum-react-pill:hover { border-color:var(--orange-lt); background:rgba(170,0,255,0.12); }
.forum-react-pill.reacted { background:rgba(170,0,255,0.22); border-color:var(--orange); color:var(--orange-lt); font-weight:700; }
.forum-react-add-btn { background:rgba(255,255,255,0.04); border:1px dashed rgba(255,255,255,0.18); border-radius:20px; padding:3px 9px; font-size:0.7rem; cursor:pointer; color:var(--text-dim); transition:all 0.15s; font-family:inherit; }
.forum-react-add-btn:hover { border-color:var(--orange-lt); color:#fff; border-style:solid; }
.forum-react-popup-wrap { position:relative; display:inline-block; }
.forum-react-popup { position:absolute; bottom:calc(100% + 6px); left:0; background:linear-gradient(135deg,#252018,#1c1810); border:1px solid rgba(170,0,255,0.3); border-radius:12px; padding:8px 10px; display:none; gap:6px; z-index:300; box-shadow:0 8px 24px rgba(0,0,0,0.7); white-space:nowrap; }
.forum-react-popup.open { display:flex; }
.forum-popup-option { background:none; border:2px solid transparent; border-radius:8px; padding:5px 7px; font-size:1.1rem; cursor:pointer; transition:all 0.15s; line-height:1; }
.forum-popup-option:hover { background:rgba(170,0,255,0.15); border-color:rgba(170,0,255,0.4); transform:scale(1.2); }
.forum-popup-option.reacted { background:rgba(170,0,255,0.25); border-color:var(--orange); }
/* ─── USERNAME LINKS & VERIFIED BADGE ─── */
.forum-username-link { color:var(--orange-lt); font-weight:700; cursor:pointer; transition:color 0.15s; }
.forum-username-link:hover { color:#fff; text-decoration:underline; }
.forum-verified-badge { display:inline-flex; align-items:center; gap:2px; background:rgba(0,200,100,0.15); border:1px solid rgba(0,200,100,0.4); color:#7CFC00; font-size:0.58rem; font-weight:800; padding:1px 5px; border-radius:3px; margin-left:4px; vertical-align:middle; letter-spacing:0.03em; cursor:default; }
/* ─── FORUM PROFILE PAGE ─── */
.forum-profile-card { background:linear-gradient(135deg,#1d1912,#151210); border:1px solid rgba(170,0,255,0.25); border-radius:12px; padding:1.2rem; margin-bottom:1rem; display:flex; gap:16px; align-items:flex-start; }
.forum-profile-avatar { border-radius:8px; border:3px solid var(--border); flex-shrink:0; }
.forum-profile-meta { flex:1; min-width:0; }
.forum-profile-username { font-family:'Exo 2',sans-serif; font-size:1.2rem; font-weight:900; color:#fff; line-height:1.2; margin-bottom:4px; }
.forum-profile-stats { display:flex; gap:14px; margin:8px 0; flex-wrap:wrap; }
.forum-profile-stat { text-align:center; }
.forum-profile-stat-val { font-family:'Exo 2',sans-serif; font-weight:800; font-size:1rem; color:var(--orange-lt); }
.forum-profile-stat-lbl { font-size:0.6rem; color:var(--text-dim); text-transform:uppercase; letter-spacing:0.06em; }
.forum-profile-mc { font-size:0.72rem; color:#7CFC00; margin-top:4px; }
.forum-profile-section { font-family:'Exo 2',sans-serif; font-size:0.72rem; font-weight:800; color:var(--text-dim); text-transform:uppercase; letter-spacing:0.08em; margin:0.8rem 0 0.4rem; }
.forum-profile-post-item { background:var(--bg-card); border:1px solid var(--border); border-radius:7px; padding:8px 12px; margin-bottom:5px; cursor:pointer; transition:border-color 0.15s; }
.forum-profile-post-item:hover { border-color:var(--orange-lt); }
.forum-profile-reply-item { background:var(--bg-card); border:1px solid var(--border); border-left:3px solid var(--orange); border-radius:7px; padding:8px 12px; margin-bottom:5px; }
.forum-profile-verify-btn { display:inline-flex; align-items:center; gap:6px; background:rgba(0,200,100,0.12); border:1px solid rgba(0,200,100,0.35); color:#7CFC00; font-size:0.72rem; font-weight:700; padding:4px 10px; border-radius:5px; cursor:pointer; margin-top:6px; transition:all 0.15s; }
.forum-profile-verify-btn:hover { background:rgba(0,200,100,0.22); }
.forum-profile-bio { background:rgba(255,255,255,0.03); border:1px solid rgba(255,255,255,0.07); border-radius:8px; padding:10px 14px; font-size:0.8rem; color:var(--text-mid); line-height:1.6; margin-bottom:0.8rem; white-space:pre-wrap; }
/* ─── FORUM PROFILE EDITOR ─── */
.forum-profile-edit-card { background:linear-gradient(135deg,#1a1814,#111008); border:1px solid rgba(170,0,255,0.25); border-radius:12px; padding:1.4rem; max-width:520px; display:flex; flex-direction:column; gap:14px; }
.forum-pe-title { font-family:'Exo 2',sans-serif; font-size:0.95rem; font-weight:900; color:var(--orange-lt); display:flex; align-items:center; gap:8px; margin-bottom:2px; }
.forum-pe-field { display:flex; flex-direction:column; gap:5px; }
.forum-pe-label { font-size:0.7rem; font-weight:700; text-transform:uppercase; letter-spacing:0.07em; color:var(--text-dim); }
.forum-pe-input { background:#0d0c0a; border:1px solid rgba(255,255,255,0.1); color:var(--text); border-radius:5px; padding:9px 12px; font-size:0.82rem; font-family:inherit; width:100%; box-sizing:border-box; resize:vertical; transition:border-color 0.15s; }
.forum-pe-input:focus { outline:none; border-color:rgba(170,0,255,0.55); }
.forum-pe-save-btn { display:inline-flex; align-items:center; gap:7px; background:linear-gradient(135deg,#7c3504,#b34a06); border:1px solid var(--orange); color:#fff; border-radius:6px; padding:10px 24px; font-size:0.8rem; font-weight:800; cursor:pointer; font-family:'Exo 2',sans-serif; text-transform:uppercase; letter-spacing:0.05em; transition:all 0.15s; align-self:flex-start; }
.forum-pe-save-btn:hover { background:linear-gradient(135deg,#9d4306,#d45a08); box-shadow:0 0 14px rgba(170,0,255,0.3); }
/* ─── MEMBER TABLE ─── */
.forum-members-table { display:flex; flex-direction:column; gap:4px; }
.forum-member-row { display:flex; align-items:center; gap:8px; background:linear-gradient(135deg,#1c1610,#14110d); border:1px solid rgba(255,255,255,0.07); border-radius:7px; padding:8px 12px; flex-wrap:wrap; }
.forum-member-row.is-banned { background:linear-gradient(135deg,#1c1010,#140d0d); border-color:rgba(232,76,76,0.2); }
.forum-member-name { font-family:'Exo 2',sans-serif; font-weight:700; font-size:0.8rem; color:var(--orange-lt); min-width:80px; }
/* ─── DONOR RANK BADGES ─── */
.forum-donor-badge { display:inline-block; font-size:0.58rem; padding:1px 5px; border-radius:3px; font-weight:800; text-transform:uppercase; margin-left:4px; letter-spacing:0.06em; vertical-align:middle; }
.forum-donor-large { display:inline-block; font-size:0.6rem; padding:2px 7px; border-radius:3px; font-weight:800; text-transform:uppercase; letter-spacing:0.07em; margin-top:3px; }
.fd-VIP { background:#c8a800; color:#000; }
.fd-MVP { background:#5865F2; color:#fff; }
.fd-ELITE { background:#e84c4c; color:#fff; }
.fd-LEGEND { background:#9B59B6; color:#fff; }
.fd-TITAN { background:#00BCD4; color:#000; }
.fd-GOD { background:linear-gradient(90deg,#ff6b35,#f7c948,#5865F2); color:#fff; }
/* ─── FORUM THREAD CARD LAYOUT ─── */
.forum-thread-post { background:linear-gradient(180deg,#1d1912 0%,#151210 100%); border:1px solid rgba(170,0,255,0.1); border-radius:10px; display:flex; overflow:visible; margin-bottom:0.5rem; box-shadow:0 3px 14px rgba(0,0,0,0.5),inset 0 1px 0 rgba(255,255,255,0.03); }
.forum-thread-post.is-reply { background:linear-gradient(180deg,#161310 0%,#100e0c 100%); border-color:rgba(255,255,255,0.05); margin-left:12px; border-left:3px solid rgba(170,0,255,0.35); box-shadow:0 2px 8px rgba(0,0,0,0.4); overflow:visible; }
.forum-user-sidebar { width:108px; flex-shrink:0; padding:12px 8px; display:flex; flex-direction:column; align-items:center; gap:4px; text-align:center; background:linear-gradient(180deg,rgba(170,0,255,0.1) 0%,rgba(120,0,200,0.04) 100%); border-right:1px solid rgba(170,0,255,0.12); border-radius:10px 0 0 10px; }
.forum-user-sidebar-avatar { border-radius:6px; border:2px solid var(--border); display:block; }
.forum-sidebar-name { font-size:0.68rem; font-weight:800; color:var(--orange-lt); word-break:break-word; line-height:1.3; margin-top:3px; }
.forum-sidebar-stat { font-size:0.58rem; color:var(--text-dim); white-space:nowrap; }
.forum-content-wrap { flex:1; padding:0.75rem 0.9rem; min-width:0; display:flex; flex-direction:column; border-radius:0 10px 10px 0; overflow:visible; }
.forum-content-meta { font-size:0.68rem; color:var(--text-dim); margin-bottom:5px; display:flex; gap:8px; flex-wrap:wrap; align-items:center; }
.forum-post-title-main { font-family:'Exo 2',sans-serif; font-size:0.96rem; font-weight:800; color:#fff; margin-bottom:6px; line-height:1.3; }
/* ─── REACTIONS ─── */
.forum-reactions { display:flex; gap:5px; margin-top:8px; flex-wrap:wrap; align-items:center; }
.forum-react-btn { background:rgba(255,255,255,0.04); border:1px solid var(--border); border-radius:20px; padding:3px 9px; font-size:0.68rem; cursor:pointer; color:var(--text-mid); transition:all 0.15s; display:inline-flex; align-items:center; gap:4px; font-family:inherit; }
.forum-react-btn:hover { border-color:var(--orange-lt); background:rgba(170,0,255,0.1); color:#fff; }
.forum-react-btn.reacted { background:rgba(170,0,255,0.2); border-color:var(--orange); color:var(--orange-lt); font-weight:700; }
.forum-react-count { font-weight:700; min-width:8px; }

.desc-cart-total { font-family: 'Exo 2',sans-serif; font-size: 0.75rem; color: var(--text-dim); margin-right: auto; }
.desc-cart-total span { color: #7CFC00; font-weight: 800; }

.drop-zone { border: 2px dashed var(--border); border-radius: 6px; padding: 1.5rem; text-align: center; color: var(--text-dim); font-size: 0.85rem; transition: all 0.2s; cursor: pointer; background: rgba(0,0,0,0.2); }
.drop-zone:hover, .drop-zone.drag-over { border-color: var(--orange-lt); background: rgba(170,0,255,0.05); color: var(--orange-lt); }
.drop-zone img { max-width: 80px; max-height: 80px; border-radius: 4px; border: 1px solid var(--border); margin-top: 8px; }

.sortable-list { display: flex; flex-direction: column; gap: 4px; }
.sortable-item { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border-radius: 4px; border: 1px solid var(--border); background: rgba(0,0,0,0.2); cursor: grab; transition: all 0.15s; }
.sortable-item:hover { border-color: var(--orange-lt); background: rgba(170,0,255,0.05); }
.sortable-item.dragging { opacity: 0.5; border-color: var(--orange); }
.sortable-item .drag-handle { color: var(--text-dim); cursor: grab; font-size: 0.8rem; }

.leaderboard-actions { display: flex; gap: 6px; margin-top: 0.5rem; }
.staff-mini-btn { background: rgba(0,0,0,0.3); border: 1px solid var(--border); color: var(--text-dim); font-size: 0.65rem; padding: 3px 8px; border-radius: 3px; cursor: pointer; transition: all 0.15s; }
.staff-mini-btn:hover { border-color: var(--orange-lt); color: #fff; }
.tab-hidden { display: none !important; }
.featured-picker-row { display: flex; align-items: center; gap: 10px; padding: 6px 8px; border-radius: 4px; border: 1px solid var(--border); background: rgba(0,0,0,0.2); margin-bottom: 4px; }
.featured-picker-row input[type="checkbox"] { accent-color: var(--orange); width: 16px; height: 16px; cursor: pointer; }
.store-tab-select { background: rgba(0,0,0,0.3); border: 1px solid var(--border); color: var(--text); font-size: 0.75rem; padding: 4px 8px; border-radius: 3px; }
.checkout-applied { font-size: 0.78rem; color: var(--orange-lt); margin: 4px 0; text-align: right; }

/* ─── SATISFYING INTERACTION EFFECTS ─── */
#descModalAddToCartBtn { transition: all 0.15s cubic-bezier(0.2, 0.8, 0.2, 1); position: relative; overflow: hidden; }
#descModalAddToCartBtn:active { transform: scale(0.95); }
#descModalAddToCartBtn.clicked-success { background: linear-gradient(135deg, #ff9a3c, #e8720c) !important; border-color: #ffffff !important; color: #ffffff !important; box-shadow: 0 0 15px rgba(255, 154, 60, 0.6) !important; transform: scale(0.98); }
.cart-float-notifier { position: absolute; pointer-events: none; z-index: 1000; font-family: 'Exo 2', sans-serif; font-size: 0.85rem; font-weight: 900; color: #7CFC00; text-shadow: 0 2px 4px rgba(0,0,0,0.8), 0 0 8px rgba(124,252,0,0.4); animation: floatUpAndVanish 0.8s cubic-bezier(0.18, 0.89, 0.32, 1.28) forwards; }
@keyframes floatUpAndVanish { 0% { opacity: 0; transform: translateY(0) scale(0.5); } 20% { opacity: 1; transform: translateY(-15px) scale(1.1); } 100% { opacity: 0; transform: translateY(-55px) scale(0.8); } }

/* ─── DISPLAY GRID CONTENT ─── */
.tab-content { display: none; animation: fadeIn 0.25s ease-out forwards; flex-direction: column; flex: 1; min-height: 0; gap: 0.75rem; }
#tab-home { display: flex; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

.category-header { margin-bottom: 0.4rem; position: relative; }
#tab-home .category-header { z-index: 10; padding-top: 0.5rem; }
#tab-home .featured-grid { position: relative; z-index: 10; }
.category-title { font-family: 'Exo 2', sans-serif; font-weight: 900; font-size: 1.3rem; text-transform: uppercase; letter-spacing: 0.02em; color: #fff; }
.category-title span { color: var(--orange); }
.category-subtitle { font-size: 0.75rem; color: var(--text-dim); margin-top: 2px; text-transform: uppercase; letter-spacing: 0.05em; }

.featured-grid { display: flex; gap: 0.75rem; align-self: flex-start; width: 100%; }
.pkg-card { background: linear-gradient(145deg, var(--bg-card), var(--bg-card-lt)); border: 1px solid var(--border); border-radius: 8px; padding: 1rem; flex: 1; display: flex; flex-direction: column; align-items: center; gap: 0.6rem; transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); cursor: pointer; position: relative; overflow: hidden; box-shadow: 0 4px 12px rgba(0,0,0,0.2); }
.pkg-card::before { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: linear-gradient(135deg, rgba(170,0,255,0.12), transparent); opacity: 0; transition: opacity 0.3s ease; }
.pkg-card:hover { transform: translateY(-4px); border-color: var(--orange-lt); box-shadow: 0 15px 30px rgba(0,0,0,0.6), 0 0 25px var(--orange-glow); }
.pkg-card:hover::before { opacity: 1; }
.pkg-icon { width: 100%; max-width: 160px; aspect-ratio: 1/1; background: linear-gradient(145deg, rgba(0,0,0,0.5), rgba(0,0,0,0.3)); border: 1px solid rgba(170,0,255,0.25); border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 2.5rem; transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); box-shadow: 0 4px 8px rgba(0,0,0,0.2), 0 0 15px rgba(170,0,255,0.15); flex-shrink: 0; overflow: hidden; margin-bottom: 0.4rem; }
.pkg-card:hover .pkg-icon { transform: scale(1.05); border-color: var(--orange); box-shadow: 0 8px 16px rgba(170,0,255,0.4), 0 0 20px rgba(170,0,255,0.3); }
.pkg-icon img { width: 100%; height: 100%; object-fit: cover; transform: none; }
.pkg-content { flex: 1; text-align: center; width: 100%; }
.pkg-name { font-family: 'Exo 2', sans-serif; font-weight: 800; font-size: 1rem; text-transform: uppercase; color: #fff; margin-bottom: 0.5rem; text-shadow: 0 2px 8px rgba(0,0,0,0.5), 0 0 2px rgba(170,0,255,0.3); }
.pkg-description { color: var(--text-mid); font-size: 0.8rem; line-height: 1.2; margin-bottom: 0.35rem; }
.pkg-info-list { text-align: left; margin: 0.5rem 0; padding-left: 1rem; }
.pkg-info-item { color: var(--text-mid); font-size: 0.8rem; line-height: 1.4; margin-bottom: 0.25rem; }
.pkg-info-item::before { content: "• "; color: var(--orange); font-weight: 900; }
.pkg-price-row { display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: auto; }
.pkg-price { font-size: 1.3rem; font-weight: 800; color: #7CFC00; text-shadow: 0 2px 8px rgba(0,0,0,0.6), 0 0 3px rgba(124,252,0,0.4); }

/* ─── OVERLAYS & DIALOG CARDS ─── */
.modal-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(10,8,5,0.85); backdrop-filter: blur(8px); display: flex; align-items: center; justify-content: center; z-index: 1000; }
.modal-card { background: var(--bg-panel); border: 1px solid var(--border); width: 100%; max-width: 450px; padding: 2.5rem; border-radius: 8px; box-shadow: 0 25px 50px rgba(0,0,0,0.6); position: relative; }
.modal-close-btn { position: absolute; top: 15px; right: 20px; background: none; border: none; color: var(--text-dim); font-size: 1.8rem; cursor: pointer; transition: color 0.15s; }
.modal-close-btn:hover { color: #fff; }
.modal-title { font-family: 'Exo 2', sans-serif; font-weight: 900; font-size: 1.8rem; text-transform: uppercase; text-align: center; margin-bottom: 0.5rem; color: #fff; }
.modal-subtitle { text-align: center; color: var(--text-dim); font-size: 1rem; text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 2rem; }
.input-group { display: flex; flex-direction: column; gap: 8px; margin-bottom: 1.5rem; }
.input-label { font-size: 0.85rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--orange-lt); }
.input-field { background: rgba(0,0,0,0.4); border: 1px solid var(--border); padding: 12px 16px; border-radius: 4px; color: #fff; font-family: 'Rajdhani', sans-serif; font-size: 1.2rem; font-weight: 600; letter-spacing: 0.03em; transition: all 0.2s; }
.input-field:focus { outline: none; border-color: var(--orange-lt); box-shadow: 0 0 12px var(--orange-glow); }
.modal-btn { background: linear-gradient(135deg, var(--orange), var(--orange-dk)); border: 1px solid rgba(255,255,255,0.1); color: #fff; font-family: 'Exo 2', sans-serif; font-weight: 800; font-size: 1.1rem; text-transform: uppercase; padding: 12px 24px; border-radius: 4px; width: 100%; cursor: pointer; box-shadow: 0 4px 15px rgba(0,0,0,0.3); transition: all 0.15s ease; display: flex; align-items: center; justify-content: center; gap: 10px; }
.modal-btn:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(170,0,255,0.3); filter: brightness(1.1); }
.modal-btn:active { transform: translateY(0); }
.modal-btn.confirm { background: linear-gradient(135deg, #7CFC00, #4ad600); color: #000; font-weight: 900; border-color: rgba(0,0,0,0.1); }
.modal-btn.confirm:hover { box-shadow: 0 6px 20px rgba(124,252,0,0.3); }
.modal-btn.cancel { background: rgba(255,255,255,0.05); border-color: rgba(255,255,255,0.08); color: var(--text-mid); width: auto; }
.modal-btn.cancel:hover { background: rgba(255,255,255,0.1); color: #fff; box-shadow: none; }

/* ─── DESCRIPTION DETAIL BOX OVERLAYS ─── */
.desc-modal-card { max-width: 550px !important; border: 1px solid var(--orange) !important; background: linear-gradient(145deg, #1e1810, #15100a) !important; box-shadow: 0 20px 50px rgba(0,0,0,0.8), 0 0 30px rgba(170,0,255,0.15) !important; padding: 2rem !important; }
.desc-modal-header { display: flex; align-items: center; gap: 20px; border-bottom: 1px solid rgba(170,0,255,0.15); padding-bottom: 1.2rem; margin-bottom: 1.2rem; }
.desc-modal-icon-box { width: 64px; height: 64px; display: flex; align-items: center; justify-content: center; background: rgba(0,0,0,0.3); border: 1px solid rgba(170,0,255,0.2); border-radius: 6px; padding: 4px; }
.desc-modal-icon-box img { width: 100%; height: 100%; object-fit: contain; }
.desc-modal-title-group { display: flex; flex-direction: column; gap: 2px; }
.desc-modal-title { font-family: 'Exo 2', sans-serif; font-size: 1.6rem; font-weight: 900; color: #ffffff; margin: 0; text-transform: uppercase; letter-spacing: 0.03em; text-align: left; }
.desc-modal-price { font-family: 'Exo 2', sans-serif; font-size: 1.25rem; font-weight: 800; color: #7CFC00; text-align: left; }
.desc-modal-body { color: var(--text-mid); font-size: 0.95rem; line-height: 1.5; }
.desc-modal-text { font-style: italic; color: var(--text-dim); margin-bottom: 1.5rem; }
.desc-perks-section h3 { font-family: 'Exo 2', sans-serif; font-size: 0.85rem; font-weight: 800; letter-spacing: 0.08em; color: var(--orange-lt); margin-bottom: 0.75rem; }
.desc-perks-list { list-style: none; padding: 0; margin: 0 0 1.5rem 0; display: flex; flex-direction: column; gap: 8px; }
.desc-perks-list li { position: relative; padding-left: 24px; color: var(--text); font-size: 0.92rem; text-align: left; }
.desc-perks-list li::before { content: "✔"; position: absolute; left: 0; color: #55ff55; font-weight: 900; }
.desc-modal-footer { display: flex; justify-content: flex-end; gap: 12px; border-top: 1px solid rgba(255,255,255,0.05); padding-top: 1.2rem; }

/* ─── CHECKOUT MODAL STYLES ─── */
.checkout-modal-card { max-width: 500px !important; border: 1px solid var(--orange) !important; max-height: 92vh; overflow-y: auto; }
#checkoutModal { align-items: flex-start; padding: 4vh 0; overflow-y: auto; }
.checkout-items-list { max-height: 300px; overflow-y: auto; margin: 1rem 0; padding: 1rem; background: rgba(0,0,0,0.2); border-radius: 4px; }
.checkout-item-row { display: flex; justify-content: space-between; align-items: center; padding: 0.5rem 0; border-bottom: 1px solid rgba(255,255,255,0.05); }
.checkout-item-name { color: var(--text); font-weight: 600; }
.checkout-item-price { color: #7CFC00; font-family: 'Exo 2', sans-serif; font-weight: 700; }
.checkout-total { font-family: 'Exo 2', sans-serif; font-size: 1.3rem; font-weight: 900; text-align: right; margin: 1rem 0; color: #fff; }
.checkout-total span { color: #7CFC00; }

/* ─── IMAGE SCROLLWHEEL CAROUSEL ─── */
.scrollwheel-container { position: relative; width: 100%; max-width: 100%; height: 320px; flex-shrink: 0; overflow: hidden; border-radius: 8px; border: 1px solid var(--border); box-shadow: 0 10px 30px rgba(0,0,0,0.5); }
.scrollwheel-line { position: absolute; bottom: 0; left: 0; right: 0; height: 3px; background: linear-gradient(90deg, transparent, var(--orange), transparent); z-index: 5; }
.scrollwheel-description { position: absolute; bottom: 0; left: 0; right: 0; background: rgba(10,8,5,0.9); backdrop-filter: blur(4px); border-top: 1px solid var(--border); padding: 0.5rem 1.5rem; z-index: 15; display: flex; align-items: center; justify-content: space-between; }
.scrollwheel-description h3 { font-family: 'Exo 2', sans-serif; font-weight: 800; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.05em; color: #fff; margin: 0; }
.scrollwheel-description h3 span { color: var(--orange); }
.scrollwheel-track { display: flex; transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1); height: 100%; }
.scrollwheel-slide { min-width: 100%; height: 100%; position: relative; overflow: hidden; }
.scrollwheel-slide img { width: 100%; height: 100%; object-fit: cover; filter: brightness(0.7); transition: filter 0.3s ease; }
.scrollwheel-slide:hover img { filter: brightness(0.9); }
.scrollwheel-nav { position: absolute; bottom: 35px; left: 50%; transform: translateX(-50%); display: flex; gap: 8px; z-index: 10; }
.scrollwheel-dot { width: 8px; height: 8px; border-radius: 50%; background: rgba(255,255,255,0.3); cursor: pointer; transition: all 0.3s ease; border: 2px solid transparent; }
.scrollwheel-dot:hover { background: rgba(255,255,255,0.5); }
.scrollwheel-dot.active { background: var(--orange); border-color: #fff; box-shadow: 0 0 10px var(--orange-glow); }
.scrollwheel-arrow { position: absolute; top: 50%; transform: translateY(-50%); background: rgba(0,0,0,0.6); color: #fff; border: none; width: 36px; height: 36px; border-radius: 50%; cursor: pointer; font-size: 1rem; display: flex; align-items: center; justify-content: center; transition: all 0.3s ease; z-index: 10; }
.scrollwheel-arrow:hover { background: var(--orange); transform: translateY(-50%) scale(1.1); }
.scrollwheel-arrow.prev { left: 15px; }
.scrollwheel-arrow.next { right: 15px; }

/* ─── ABOUT SERVER SECTION ─── */
.about-section { background: var(--bg-card); border: 1px solid var(--border); border-radius: 8px; padding: 1rem; margin-top: 2rem; margin-bottom: 2.5rem; }
.about-title { font-family: 'Exo 2', sans-serif; font-weight: 900; font-size: 1.2rem; text-transform: uppercase; letter-spacing: 0.02em; color: #fff; margin-bottom: 0.5rem; }
.about-title span { color: var(--orange); }
.about-content { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.about-text { color: var(--text-mid); line-height: 1.4; font-size: 0.85rem; }
.about-stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.5rem; }
.stat-box { background: rgba(0,0,0,0.3); border: 1px solid var(--border); padding: 0.5rem; border-radius: 4px; text-align: center; }
.stat-number { font-family: 'Exo 2', sans-serif; font-size: 1.2rem; font-weight: 900; color: var(--orange); }
.stat-label { font-size: 0.7rem; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.05em; }

/* ─── LOGIN/LOGOUT BUTTONS ─── */
.auth-buttons { display: flex; gap: 10px; }
.login-btn, .logout-btn { display: flex; align-items: center; gap: 8px; padding: 8px 16px; border-radius: 4px; font-family: 'Exo 2', sans-serif; font-size: 0.85rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.05em; cursor: pointer; transition: all 0.2s ease; border: none; }
.login-btn { background: linear-gradient(135deg, var(--orange), var(--orange-dk)); color: #fff; box-shadow: 0 4px 15px rgba(170,0,255,0.3); }
.login-btn:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(170,0,255,0.4); }
.logout-btn { background: rgba(255,255,255,0.05); color: var(--text-mid); border: 1px solid rgba(255,255,255,0.08); }
.logout-btn:hover { background: rgba(255,255,255,0.1); color: #fff; border-color: rgba(255,255,255,0.15); }

/* ─── CUSTOM THEMED SCROLLBAR ─── */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--orange-dk); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--orange); box-shadow: 0 0 6px var(--orange-glow); }
::-webkit-scrollbar-corner { background: var(--bg); }
html { scrollbar-width: thin; scrollbar-color: var(--orange-dk) var(--bg); }

/* ─── TOP NAV LINKS ─── */
.top-nav-links { display: flex; gap: 0.25rem; }
.top-nav-link { display: flex; align-items: center; gap: 6px; padding: 5px 14px; color: var(--text-mid); text-decoration: none; font-size: 0.8rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; border-radius: 4px; border: 1px solid transparent; transition: all 0.2s ease; }
.top-nav-link:hover { color: #fff; background: rgba(170,0,255,0.08); border-color: rgba(170,0,255,0.15); }
.top-nav-link i { font-size: 0.85rem; color: var(--orange-lt); }
.top-nav-link.active { color: #fff; background: rgba(170,0,255,0.12); border-color: rgba(170,0,255,0.3); }

/* ─── LEADERBOARD PAGE ─── */
.lb-page { padding: 0.5rem 0; }
.lb-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.85rem; }
@media (max-width: 1100px) { .lb-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .lb-grid { grid-template-columns: 1fr; } }
.lb-card { background: rgba(0,0,0,0.3); border: 1px solid var(--border); border-radius: 8px; overflow: hidden; }
.lb-card-header { display: flex; align-items: center; gap: 10px; padding: 10px 14px; background: rgba(170,0,255,0.08); border-bottom: 1px solid var(--border); }
.lb-card-header i { color: var(--orange); font-size: 0.9rem; }
.lb-card-title { font-family: 'Exo 2', sans-serif; font-size: 0.78rem; font-weight: 900; text-transform: uppercase; letter-spacing: 0.08em; color: #fff; }
.lb-card-body { padding: 6px 0; max-height: 480px; overflow-y: auto; }
.lb-credit-banner { display:flex; align-items:center; gap:10px; background:linear-gradient(135deg,rgba(170,0,255,0.15),rgba(120,0,200,0.08)); border:1px solid rgba(170,0,255,0.35); border-radius:6px; padding:10px 16px; margin-bottom:1rem; font-size:0.82rem; font-weight:700; color:#fff; }
.lb-credit-banner i { color:var(--orange); font-size:1rem; flex-shrink:0; }
.lb-online-badge { display: inline-flex; align-items: center; gap: 6px; background: rgba(76,175,80,0.12); border: 1px solid rgba(76,175,80,0.3); border-radius: 20px; padding: 4px 12px; font-size: 0.78rem; font-weight: 700; color: #7CFC00; margin-bottom: 1rem; }
.lb-online-badge .dot { width: 7px; height: 7px; background: #7CFC00; border-radius: 50%; box-shadow: 0 0 6px #7CFC00; animation: lbpulse 1.5s ease-in-out infinite; }
@keyframes lbpulse { 0%,100% { opacity: 1; } 50% { opacity: 0.4; } }
.lb-table { width: 100%; border-collapse: collapse; }
.lb-table th { text-align: left; font-family: 'Exo 2', sans-serif; font-size: 0.68rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-dim); padding: 6px 10px; border-bottom: 1px solid var(--border); }
.lb-table td { padding: 7px 10px; border-bottom: 1px solid rgba(170,0,255,0.06); font-size: 0.9rem; vertical-align: middle; }
.lb-table tr:hover td { background: rgba(170,0,255,0.04); }
.lb-rank { font-family: 'Exo 2', sans-serif; font-weight: 900; font-size: 0.9rem; width: 42px; }
.lb-rank.gold { color: #FFD700; text-shadow: 0 0 8px rgba(255,215,0,0.5); }
.lb-rank.silver { color: #C0C0C0; }
.lb-rank.bronze { color: #CD7F32; }
.lb-rank.rest { color: var(--text-dim); }
.lb-player { display: flex; align-items: center; gap: 9px; }
.lb-head { width: 24px; height: 24px; border-radius: 3px; image-rendering: pixelated; }
.lb-name { font-weight: 700; color: var(--text); }
.lb-value { font-family: 'Exo 2', sans-serif; font-weight: 800; color: var(--orange-lt); text-align: right; }
.lb-empty { text-align: center; color: var(--text-dim); padding: 2.5rem 0; font-size: 0.85rem; }

/* ─── STAFF BUTTON ─── */
.staff-fixed-btn { position: fixed; bottom: 14px; right: 14px; background: rgba(0,0,0,0.7); border: 1px solid rgba(255,255,255,0.07); color: var(--text-dim); font-family: 'Rajdhani', sans-serif; font-size: 0.7rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; padding: 5px 10px; border-radius: 4px; cursor: pointer; display: flex; align-items: center; gap: 5px; transition: all 0.2s ease; z-index: 500; opacity: 0.35; }
.staff-fixed-btn:hover { opacity: 1; border-color: rgba(170,0,255,0.3); color: var(--text); background: rgba(0,0,0,0.9); }
.staff-fixed-btn i { font-size: 0.7rem; color: var(--orange); }

/* ─── STAFF LOGOUT BUTTON ─── */
.staff-logout-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    background: rgba(220,38,38,0.1);
    border: 1px solid rgba(220,38,38,0.35);
    color: #fca5a5;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 5px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-family: 'Exo 2', sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    transition: all 0.15s;
}
.staff-logout-btn:hover {
    background: rgba(220,38,38,0.22);
    border-color: rgba(220,38,38,0.6);
    color: #fecaca;
}

/* ─── DISCOUNT BADGE & PRICING ─── */
.pkg-sale-badge { position: absolute; top: 10px; right: 10px; background: linear-gradient(135deg, #ff4444, #cc0000); color: #fff; font-family: 'Exo 2', sans-serif; font-size: 0.65rem; font-weight: 900; padding: 3px 7px; border-radius: 3px; text-transform: uppercase; letter-spacing: 0.05em; box-shadow: 0 2px 8px rgba(255,68,68,0.4); z-index: 2; }
.pkg-price-original { font-size: 0.8rem; font-weight: 600; color: var(--text-dim); text-decoration: line-through; margin-right: 4px; }
.pkg-price.discounted { color: #ff8c8c; }

/* ─── STAFF PANEL MODAL ─── */
.staff-panel-card { max-width: 1100px !important; width: 96vw !important; max-height: 88vh !important; border: 1px solid rgba(170,0,255,0.35) !important; overflow: hidden !important; display: flex !important; flex-direction: column !important; padding: 0 !important; }
.staff-panel-header { padding: 1rem 1.5rem; border-bottom: 1px solid var(--border); display: flex; align-items: center; justify-content: space-between; flex-shrink: 0; background: rgba(0,0,0,0.25); }
.staff-panel-body { display: flex; flex: 1; min-height: 0; overflow: hidden; height: calc(88vh - 58px); }
.staff-panel-sidebar { width: 168px; flex-shrink: 0; background: rgba(0,0,0,0.3); border-right: 1px solid var(--border); padding: 0.6rem 0.5rem; display: flex; flex-direction: column; gap: 2px; overflow-y: auto; }
.staff-sidebar-sep { font-family: 'Exo 2',sans-serif; font-size: 0.6rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-dim); padding: 8px 8px 3px; }
.staff-tab-btn { background: none; border: 1px solid transparent; color: var(--text-dim); font-family: 'Exo 2',sans-serif; font-size: 0.71rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; padding: 7px 10px; border-radius: 4px; cursor: pointer; transition: all 0.18s; text-align: left; width: 100%; display: flex; align-items: center; gap: 8px; }
.staff-tab-btn i { font-size: 0.72rem; width: 14px; text-align: center; }
.staff-tab-btn:hover { color: #fff; border-color: rgba(170,0,255,0.2); background: rgba(170,0,255,0.07); }
.staff-tab-btn:hover i { color: var(--orange-lt); }
.staff-tab-btn.active { background: linear-gradient(135deg, rgba(170,0,255,0.18), rgba(120,0,200,0.12)); color: #fff; border-color: rgba(170,0,255,0.35); }
.staff-tab-btn.active i { color: var(--orange); }
.staff-panel-content { flex: 1; overflow-y: auto; padding: 1.25rem 1.5rem; }
.staff-panel-section { display: none; }
.staff-panel-section.active { display: block; }
.staff-section-title { font-family: 'Exo 2',sans-serif; font-size: 0.76rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.06em; color: var(--orange-lt); margin-bottom: 0.55rem; margin-top: 0.1rem; }
.staff-section-sep { margin: 1.1rem 0 0.9rem; border: none; border-top: 1px solid var(--border); }
.staff-row { display: flex; gap: 8px; align-items: flex-start; margin-bottom: 0.7rem; flex-wrap: wrap; }
.staff-input { flex: 1; min-width: 80px; background: rgba(0,0,0,0.4); border: 1px solid var(--border); padding: 7px 11px; border-radius: 4px; color: #fff; font-family: 'Rajdhani',sans-serif; font-size: 0.88rem; font-weight: 600; transition: border-color 0.2s; }
.staff-input:focus { outline: none; border-color: var(--orange-lt); box-shadow: 0 0 8px var(--orange-glow); }
.staff-input option { background: #1e1810; }
.staff-btn-sm { background: linear-gradient(135deg, var(--orange), var(--orange-dk)); border: none; color: #fff; font-family: 'Exo 2',sans-serif; font-size: 0.73rem; font-weight: 800; text-transform: uppercase; padding: 7px 13px; border-radius: 4px; cursor: pointer; white-space: nowrap; transition: all 0.15s; align-self: flex-end; }
.staff-btn-sm:hover { filter: brightness(1.15); transform: translateY(-1px); }
.staff-btn-sm.danger { background: linear-gradient(135deg, #e84c4c, #a83333); }
.staff-btn-sm.success { background: linear-gradient(135deg, #4caf50, #2e7d32); }
.staff-btn-sm.neutral { background: linear-gradient(135deg, #555, #333); }
.discount-status-box { border-radius: 4px; padding: 0.6rem 0.85rem; margin-bottom: 0.7rem; }
.discount-active-box { background: rgba(76,175,80,0.1); border: 1px solid rgba(76,175,80,0.3); }
.discount-inactive-box { background: rgba(255,255,255,0.02); border: 1px solid var(--border); }
.discount-status-label { font-size: 0.8rem; font-weight: 700; }
.discount-list { display: flex; flex-direction: column; gap: 4px; max-height: 200px; overflow-y: auto; }
.discount-list-item { display: flex; align-items: center; gap: 8px; background: rgba(0,0,0,0.2); padding: 6px 10px; border-radius: 4px; border: 1px solid var(--border); }
.discount-code-tag { font-family: 'Exo 2',sans-serif; font-size: 0.78rem; font-weight: 700; color: var(--orange-lt); }
.discount-pct-tag { font-size: 0.78rem; color: #7CFC00; font-weight: 700; }
.staff-log-box { background: rgba(0,0,0,0.5); border: 1px solid var(--border); border-radius: 4px; padding: 0.75rem 1rem; font-family: 'Courier New',monospace; font-size: 0.75rem; color: #7CFC00; max-height: 220px; overflow-y: auto; line-height: 1.7; }
.staff-log-entry { margin: 0; }
.staff-log-entry.err { color: #ff6666; }
.staff-log-entry.info { color: var(--orange-lt); }
.cat-tree-item { display: flex; align-items: center; gap: 8px; padding: 6px 10px; border-radius: 4px; border: 1px solid var(--border); background: rgba(0,0,0,0.2); margin-bottom: 4px; }
.cat-sub-item { margin-left: 24px; border-left: 2px solid rgba(170,0,255,0.2); padding-left: 10px; }
.pkg-create-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-bottom: 0.5rem; }
.pkg-full-row { grid-column: 1 / -1; }
/* ─── PACKAGES SPLIT PANE ─── */
.staff-panel-content:has(#staffTab-packages.active) { overflow: hidden; padding: 0; }
#staffTab-packages.active { display: flex !important; height: 100%; overflow: hidden; }
.pkg-split-list { width: 230px; flex-shrink: 0; border-right: 1px solid var(--border); display: flex; flex-direction: column; overflow: hidden; background: rgba(0,0,0,0.18); }
.pkg-split-form { flex: 1; overflow-y: auto; padding: 0.9rem 1.1rem; min-width: 0; }
.pkg-list-row { display: flex; align-items: center; gap: 4px; padding: 5px 6px; border-radius: 4px; border: 1px solid transparent; transition: all 0.15s; margin-bottom: 2px; }
.pkg-list-row:hover { background: rgba(170,0,255,0.07); border-color: rgba(170,0,255,0.15); }
.pkg-list-row.selected { background: linear-gradient(135deg,rgba(170,0,255,0.18),rgba(120,0,200,0.12)); border-color: rgba(170,0,255,0.4); }
.pkg-list-name { font-size: 0.76rem; font-weight: 700; color: var(--text); flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pkg-list-price { font-size: 0.66rem; color: #7CFC00; font-weight: 600; flex-shrink: 0; }
.pkg-vis-dot { width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0; cursor: pointer; transition: box-shadow 0.15s; }
.pkg-vis-dot.vis-on { background: #4caf50; box-shadow: 0 0 5px rgba(76,175,80,0.7); }
.pkg-vis-dot.vis-off { background: #e84c4c; box-shadow: 0 0 5px rgba(232,76,76,0.7); }

/* ═══════════════════════════════════════════════════
   HOME FEATURED PACKAGES — PREMIUM DESIGN
   ═══════════════════════════════════════════════════ */

/* Section header accent */
#tab-home .category-title::before {
    content: '★ ';
    color: var(--orange);
    font-size: 0.85em;
}
#tab-home .category-header {
    border-left: 3px solid var(--orange);
    padding-left: 0.9rem;
    margin-bottom: 1.1rem;
}

/* Per-rarity accent color + tinted background */
#homeFeaturedGrid .pkg-card                            { --card-accent: var(--orange); --card-tint: rgba(170,0,255,0.06); }
#homeFeaturedGrid .pkg-card[data-item-key="VIP"]        { --card-accent: #22c55e; --card-tint: rgba(34,197,94,0.08); }
#homeFeaturedGrid .pkg-card[data-item-key="MVP"]        { --card-accent: #0891b2; --card-tint: rgba(8,145,178,0.08); }
#homeFeaturedGrid .pkg-card[data-item-key="LEGEND"]     { --card-accent: #eab308; --card-tint: rgba(234,179,8,0.07); }
#homeFeaturedGrid .pkg-card[data-item-key*="KEY"]       { --card-accent: #3b82f6; --card-tint: rgba(59,130,246,0.07); }
#homeFeaturedGrid .pkg-card[data-item-key*="TOKENS"]    { --card-accent: #f59e0b; --card-tint: rgba(245,158,11,0.07); }
#homeFeaturedGrid .pkg-card[data-item-key*="MONEY"]     { --card-accent: #22c55e; --card-tint: rgba(34,197,94,0.07); }
#homeFeaturedGrid .pkg-card[data-item-key*="MULTI"]     { --card-accent: #ef4444; --card-tint: rgba(239,68,68,0.07); }

@keyframes featuredPulse {
    0%,100% { box-shadow: 0 4px 22px rgba(0,0,0,0.55), 0 0 18px rgba(0,0,0,0); }
    50%     { box-shadow: 0 4px 28px rgba(0,0,0,0.55), 0 0 28px color-mix(in srgb, var(--card-accent) 20%, transparent); }
}
@keyframes sparkleFloat {
    0%   { opacity:0; transform: translateY(0)   scale(0.5); }
    25%  { opacity:1; transform: translateY(-8px) scale(1); }
    75%  { opacity:.6; transform: translateY(-20px) scale(.8); }
    100% { opacity:0; transform: translateY(-32px) scale(0); }
}
@keyframes trendingPulse {
    0%,100% { box-shadow: 0 0 6px rgba(232,76,76,0.4); }
    50%     { box-shadow: 0 0 14px rgba(232,76,76,0.75); }
}
@keyframes criticalBlink {
    0%,100% { opacity:1; } 50% { opacity:0.55; }
}

/* Card base */
#homeFeaturedGrid .pkg-card {
    background-image: radial-gradient(ellipse at 50% 0%, var(--card-tint, transparent) 0%, transparent 65%), linear-gradient(160deg, #242424 0%, #141414 100%) !important;
    border: 1px solid color-mix(in srgb, var(--card-accent) 20%, rgba(255,255,255,0.06));
    border-top: 2px solid var(--card-accent);
    border-bottom: 1px solid color-mix(in srgb, var(--card-accent) 25%, transparent);
    box-shadow: 0 4px 22px rgba(0,0,0,0.55);
    animation: featuredPulse 3.5s ease-in-out infinite;
    transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
    position: relative;
    overflow: hidden;
}
/* Star badge — reset ALL inherited base .pkg-card::before properties */
#homeFeaturedGrid .pkg-card::before {
    content: '★';
    position: absolute;
    top: 7px;
    right: 9px;
    left: auto;
    width: auto;
    height: auto;
    background: none;
    opacity: 1;
    transition: none;
    font-size: 1rem;
    color: var(--card-accent);
    filter: drop-shadow(0 0 5px var(--card-accent));
    pointer-events: none;
}
/* Prevent base hover rule from triggering the full-card gradient overlay */
#homeFeaturedGrid .pkg-card:hover::before {
    opacity: 1;
    background: none;
}
/* Sparkle particles */
.pkg-sparkle {
    position: absolute;
    font-size: 0.48rem;
    color: var(--card-accent, var(--orange));
    opacity: 0;
    pointer-events: none;
    animation: sparkleFloat 2.8s ease-in-out infinite;
}
/* Trending badge — absolute so it never affects card layout/flow */
.pkg-trending-badge {
    position: absolute;
    top: 7px;
    left: 8px;
    display: inline-flex;
    align-items: center;
    gap: 3px;
    font-size: 0.58rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #fff;
    background: linear-gradient(135deg, #e84c4c, #b91c1c);
    padding: 2px 7px;
    border-radius: 3px;
    z-index: 4;
    pointer-events: none;
    animation: trendingPulse 1.6s ease-in-out infinite;
}
/* Best-seller diagonal ribbon */
.pkg-bestseller-ribbon {
    position: absolute;
    top: 14px;
    right: -26px;
    background: linear-gradient(135deg, var(--orange), #c45a08);
    color: #fff;
    font-size: 0.48rem;
    font-weight: 900;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    padding: 3px 30px;
    transform: rotate(45deg);
    z-index: 4;
    pointer-events: none;
    white-space: nowrap;
    box-shadow: 0 2px 8px rgba(0,0,0,0.4);
}
/* Stock badges */
.pkg-stock-badge {
    display: inline-block;
    font-size: 0.6rem;
    font-weight: 900;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    padding: 2px 8px;
    border-radius: 3px;
    margin-bottom: 4px;
    width: fit-content;
}
.pkg-stock-badge.plenty  { color:#7CFC00; background:rgba(124,252,0,0.1);  border:1px solid rgba(124,252,0,0.3); }
.pkg-stock-badge.low     { color:#f97316; background:rgba(249,115,22,0.12); border:1px solid rgba(249,115,22,0.35); }
.pkg-stock-badge.critical{ color:#e84c4c; background:rgba(232,76,76,0.12); border:1px solid rgba(232,76,76,0.45); animation: criticalBlink 1s ease-in-out infinite; }
/* Sold-out overlay */
.pkg-sold-out-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.74);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 5;
    border-radius: inherit;
    cursor: not-allowed;
}
.pkg-sold-out-text {
    font-size: 0.82rem;
    font-weight: 900;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: #e84c4c;
    border: 2px solid #e84c4c;
    padding: 6px 14px;
    border-radius: 4px;
    text-shadow: 0 0 10px rgba(232,76,76,0.5);
}
/* Shimmer sweep on hover */
#homeFeaturedGrid .pkg-card::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(105deg, transparent 30%, rgba(255,255,255,0.045) 50%, transparent 70%);
    transform: translateX(-120%);
    transition: transform 0.42s ease;
    pointer-events: none;
}
#homeFeaturedGrid .pkg-card:hover {
    transform: translateY(-5px) scale(1.015);
    border-color: var(--card-accent);
    box-shadow: 0 12px 36px rgba(0,0,0,0.7), 0 0 40px color-mix(in srgb, var(--card-accent) 22%, transparent);
    animation: none;
}
#homeFeaturedGrid .pkg-card:hover::after {
    transform: translateX(120%);
}

/* Section panel — pops without being an eyesore */
#tab-home {
    background: linear-gradient(170deg, #1a1a1a 0%, #0d0d0d 100%) !important;
    border: 1px solid rgba(170,0,255,0.22);
    border-top: 3px solid var(--orange);
    border-radius: 10px;
    padding: 1.4rem 1.2rem;
    box-shadow:
        0 10px 40px rgba(0,0,0,0.65),
        0 0 0 1px rgba(170,0,255,0.06) inset,
        0 -1px 30px rgba(170,0,255,0.05) inset;
    position: relative;
    isolation: isolate;
    z-index: 1;
}
/* Stretch all cards to equal height */
#homeFeaturedGrid { align-items: stretch; }
/* Card inner layout: column flex so price pins to bottom */
#homeFeaturedGrid .pkg-content {
    display: flex;
    flex-direction: column;
    flex: 1;
}
#homeFeaturedGrid .pkg-info-list { flex: 1; }
/* Icon with accent-colored radial glow + border */
#homeFeaturedGrid .pkg-icon {
    background: radial-gradient(ellipse at center, color-mix(in srgb, var(--card-accent) 12%, transparent) 0%, transparent 68%);
    border-color: color-mix(in srgb, var(--card-accent) 35%, rgba(255,255,255,0.06)) !important;
    box-shadow: 0 0 14px color-mix(in srgb, var(--card-accent) 15%, transparent), inset 0 0 10px color-mix(in srgb, var(--card-accent) 8%, transparent) !important;
    border-radius: 10px;
    padding: 0.45rem;
    margin-bottom: 0.45rem;
}

/* Name */
#homeFeaturedGrid .pkg-name {
    color: #fff;
    font-size: 0.8rem;
    font-weight: 800;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    margin-bottom: 0.35rem;
}

/* Description + perks */
#homeFeaturedGrid .pkg-description {
    font-size: 0.71rem;
    color: rgba(200,180,160,0.55);
    line-height: 1.38;
    margin-bottom: 0.4rem;
}
#homeFeaturedGrid .pkg-info-list {
    margin-bottom: 0.4rem;
}
#homeFeaturedGrid .pkg-info-item {
    font-size: 0.69rem;
    color: rgba(200,185,165,0.55);
    line-height: 1.4;
}
#homeFeaturedGrid .pkg-info-item::before {
    content: '· ';
    color: var(--orange-lt);
}

/* Strikethrough original price — global */
.pkg-price-orig {
    font-size: 0.75rem;
    color: var(--text-dim);
    text-decoration: line-through;
    margin-right: 4px;
    white-space: nowrap;
}
/* SALE label pill — global */
.pkg-sale-label {
    font-size: 0.58rem;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    background: linear-gradient(135deg, #c45a08, var(--orange));
    color: #fff;
    padding: 2px 6px;
    border-radius: 3px;
    margin-left: 3px;
    vertical-align: middle;
    white-space: nowrap;
}
/* Featured overrides — slightly smaller */
#homeFeaturedGrid .pkg-price-orig { font-size: 0.72rem; }
#homeFeaturedGrid .pkg-sale-label { font-size: 0.55rem; padding: 1px 5px; }

/* Price row: flex so orig + price-button + SALE label sit side by side */
#homeFeaturedGrid .pkg-price-row {
    margin-top: auto;
    padding-top: 0.5rem;
    display: flex;
    align-items: center;
    gap: 5px;
    flex-wrap: wrap;
}
#homeFeaturedGrid .pkg-price-row .pkg-price {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 5px 8px;
    border: 1px solid rgba(124,252,0,0.5);
    border-radius: 5px;
    background: rgba(124,252,0,0.07);
    color: #7CFC00;
    font-size: 0.9rem;
    font-weight: 900;
    text-shadow: 0 0 8px rgba(124,252,0,0.3);
    box-shadow: 0 0 10px rgba(124,252,0,0.08) inset;
    transition: background 0.2s, box-shadow 0.2s;
    white-space: nowrap;
}
#homeFeaturedGrid .pkg-card:hover .pkg-price-row .pkg-price {
    background: rgba(124,252,0,0.13);
    box-shadow: 0 0 16px rgba(124,252,0,0.15) inset;
}

/* ═══════════════════════════════════════════════════
   STORE SECTION PANELS (Ranks / Keys / Boosters / Bundles)
   ═══════════════════════════════════════════════════ */

/* Shared panel style — matches featured section quality */
#tab-ranks, #tab-keys, #tab-boosters, #tab-bundles {
    background: linear-gradient(170deg, #1a1a1a 0%, #0d0d0d 100%) !important;
    border-radius: 10px;
    padding: 1.4rem 1.2rem;
    box-shadow: 0 8px 28px rgba(0,0,0,0.5);
    isolation: isolate;
    z-index: 1;
    position: relative;
}
/* Per-section accent colours */
#tab-ranks    { --tab-accent: #f59e0b; border: 1px solid rgba(245,158,11,0.22); border-top: 3px solid #f59e0b; }
#tab-keys     { --tab-accent: #3b82f6; border: 1px solid rgba(59,130,246,0.22); border-top: 3px solid #3b82f6; }
#tab-boosters { --tab-accent: #8b5cf6; border: 1px solid rgba(139,92,246,0.22); border-top: 3px solid #8b5cf6; }
#tab-bundles  { --tab-accent: #22c55e; border: 1px solid rgba(34,197,94,0.22); border-top: 3px solid #22c55e; }

/* Section header accent bar + icon colour */
#tab-ranks .category-header,
#tab-keys .category-header,
#tab-boosters .category-header,
#tab-bundles .category-header {
    border-left: 3px solid var(--tab-accent);
    padding-left: 0.9rem;
    margin-bottom: 1.1rem;
}
#tab-ranks .category-title i    { color: #f59e0b; margin-right: 6px; }
#tab-keys .category-title i     { color: #3b82f6; margin-right: 6px; }
#tab-boosters .category-title i { color: #8b5cf6; margin-right: 6px; }
#tab-bundles .category-title i  { color: #22c55e; margin-right: 6px; }
#tab-ranks .category-title span    { color: #f59e0b; }
#tab-keys .category-title span     { color: #3b82f6; }
#tab-boosters .category-title span { color: #8b5cf6; }
#tab-bundles .category-title span  { color: #22c55e; }

/* Auto-fill grid for store sections — large enough cards, wraps naturally */
#tab-ranks .featured-grid,
#tab-keys .featured-grid,
#tab-boosters .featured-grid,
#tab-bundles .featured-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 1rem;
    align-items: stretch;
}

/* ─── HORIZONTAL STORE CARD TILE ─── */
.store-pkg-card {
    flex-direction: row !important;
    align-items: center !important;
    gap: 0.85rem !important;
    padding: 0.85rem 1rem !important;
    border: 1px solid rgba(255,255,255,0.06) !important;
    border-left: 3px solid var(--tab-accent, var(--orange)) !important;
    border-top: 1px solid color-mix(in srgb, var(--tab-accent, var(--orange)) 20%, transparent) !important;
    background: linear-gradient(135deg, #202020 0%, #171717 100%) !important;
    box-shadow: 0 3px 12px rgba(0,0,0,0.35) !important;
    transition: transform 0.18s ease, box-shadow 0.18s ease !important;
}
.store-pkg-card:hover {
    transform: translateY(-3px) scale(1.01) !important;
    box-shadow: 0 8px 24px rgba(0,0,0,0.5), 0 0 18px color-mix(in srgb, var(--tab-accent, var(--orange)) 14%, transparent) !important;
    border-left-color: var(--tab-accent, var(--orange)) !important;
}
/* Suppress inherited full-card overlay on store cards */
.store-pkg-card::before {
    display: none !important;
}
/* Icon: compact + accent-coloured border */
.store-pkg-card .pkg-icon {
    width: 60px !important;
    height: 60px !important;
    max-width: 60px !important;
    flex-shrink: 0 !important;
    margin-bottom: 0 !important;
    border-color: color-mix(in srgb, var(--tab-accent, var(--orange)) 35%, rgba(255,255,255,0.06)) !important;
    box-shadow: 0 0 10px color-mix(in srgb, var(--tab-accent, var(--orange)) 12%, transparent) !important;
    font-size: 1.6rem !important;
}
/* Content: left-aligned */
.store-pkg-card .pkg-content {
    text-align: left !important;
    flex: 1 !important;
    min-width: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 2px !important;
}
.store-pkg-card .pkg-name {
    text-align: left !important;
    font-size: 0.82rem !important;
    margin-bottom: 2px !important;
}
.store-pkg-card .pkg-description {
    display: block !important;
    font-size: 0.69rem !important;
    color: var(--text-dim) !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    margin-bottom: 5px !important;
}
/* Stock badge row — own line under the name */
.store-pkg-card .store-stock-row {
    display: flex;
    align-items: center;
    margin-bottom: 3px;
}
/* Sale revert disclaimer */
.sale-revert-disclaimer {
    font-size: 0.62rem;
    color: rgba(245,158,11,0.65);
    font-style: italic;
    margin-top: 4px;
    line-height: 1.3;
}
/* Price: accent-coloured, compact */
.store-pkg-card .pkg-price-row {
    display: flex !important;
    align-items: center !important;
    gap: 5px !important;
    flex-wrap: wrap !important;
    padding-top: 0 !important;
    margin-top: 0 !important;
}
.store-pkg-card .pkg-price-row .pkg-price {
    display: inline-block !important;
    flex: none !important;
    padding: 3px 10px !important;
    border: 1px solid color-mix(in srgb, var(--tab-accent, #7CFC00) 45%, transparent) !important;
    border-radius: 4px !important;
    background: color-mix(in srgb, var(--tab-accent, #7CFC00) 8%, transparent) !important;
    color: var(--tab-accent, #7CFC00) !important;
    font-size: 0.82rem !important;
    font-weight: 900 !important;
    text-shadow: none !important;
    box-shadow: none !important;
    white-space: nowrap !important;
}

/* ═══════════════════════════════════════════════════
   PACKAGE EDIT MODAL (edit mode popup)
   ═══════════════════════════════════════════════════ */
.pkg-edit-modal-card {
    background: #181818;
    border: 1px solid rgba(59,130,246,0.28);
    border-radius: 10px;
    width: 500px;
    max-width: 96vw;
    box-shadow: 0 24px 64px rgba(0,0,0,0.75);
    animation: fadeScaleIn 0.15s ease;
}
.pkg-edit-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
}
.pkg-edit-modal-title {
    font-family: 'Exo 2', sans-serif;
    font-size: 0.88rem;
    font-weight: 800;
    color: #93c5fd;
    display: flex;
    align-items: center;
    gap: 8px;
}
.pkg-edit-modal-title span { color: var(--orange-lt); font-size: 0.8rem; }
.pkg-edit-modal-close {
    background: none;
    border: none;
    color: var(--text-dim);
    font-size: 1.5rem;
    cursor: pointer;
    line-height: 1;
    padding: 0 4px;
    transition: color 0.15s;
}
.pkg-edit-modal-close:hover { color: #fff; }
.pkg-edit-modal-body {
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}
.pkg-edit-field { display: flex; flex-direction: column; gap: 5px; }
.pkg-edit-field label {
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: var(--text-dim);
}
.pkg-edit-input {
    background: #0d0d0d;
    border: 1px solid var(--border);
    color: var(--text);
    border-radius: 5px;
    padding: 9px 12px;
    font-size: 0.83rem;
    font-family: inherit;
    width: 100%;
    box-sizing: border-box;
    transition: border-color 0.15s;
}
.pkg-edit-input:focus { outline: none; border-color: rgba(59,130,246,0.55); }
.pkg-edit-textarea { height: 80px; resize: vertical; }
.pkg-edit-modal-footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 10px;
    padding: 14px 20px;
    border-top: 1px solid var(--border);
}
.pkg-edit-cancel-btn {
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border);
    color: var(--text-dim);
    border-radius: 5px;
    padding: 8px 16px;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.15s;
}
.pkg-edit-cancel-btn:hover { color: #fff; border-color: rgba(255,255,255,0.2); }
.pkg-edit-save-btn {
    display: flex;
    align-items: center;
    gap: 7px;
    background: linear-gradient(135deg, #166534, #15803d);
    border: 1px solid #16a34a;
    color: #fff;
    border-radius: 5px;
    padding: 9px 22px;
    font-size: 0.8rem;
    font-weight: 800;
    cursor: pointer;
    font-family: 'Exo 2', sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    transition: all 0.15s;
}
.pkg-edit-save-btn:hover { background: linear-gradient(135deg,#15803d,#16a34a); box-shadow: 0 0 14px rgba(34,197,94,0.25); }

/* ═══════════════════════════════════════════════════
   STAFF EDIT MODE
   ═══════════════════════════════════════════════════ */

/* Edit Site floating button (shown when staff logged in) */
.edit-site-btn {
    position: fixed;
    bottom: 60px;
    right: 20px;
    z-index: 999;
    display: flex;
    align-items: center;
    gap: 6px;
    background: linear-gradient(135deg, #1e3a6e, #112040);
    border: 1px solid rgba(59,130,246,0.45);
    color: #93c5fd;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 7px 14px;
    border-radius: 5px;
    cursor: pointer;
    font-family: 'Exo 2', sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    box-shadow: 0 4px 14px rgba(0,0,0,0.5);
    transition: all 0.15s;
}
.edit-site-btn:hover {
    background: linear-gradient(135deg, #254d96, #163060);
    border-color: rgba(59,130,246,0.75);
    box-shadow: 0 6px 18px rgba(0,0,0,0.55), 0 0 14px rgba(59,130,246,0.15);
    color: #bfdbfe;
}
/* Staff button gets a green dot when logged in */
[data-staff-active] .staff-fixed-btn,
body[data-staff-active="1"] #staffFixedBtn {
    border-color: rgba(34,197,94,0.5);
    box-shadow: 0 0 10px rgba(34,197,94,0.18);
}
[data-staff-active] .staff-fixed-btn::after,
body[data-staff-active="1"] #staffFixedBtn::after {
    content: '';
    position: absolute;
    top: 4px; right: 4px;
    width: 7px; height: 7px;
    border-radius: 50%;
    background: #22c55e;
    box-shadow: 0 0 6px #22c55e;
}

/* Edit Mode Bar */
#editModeBar {
    position: sticky;
    top: 0;
    z-index: 490;
    background: linear-gradient(90deg, #1a1100 0%, #120d00 100%);
    border-bottom: 2px solid var(--orange);
    padding: 9px 18px;
    box-shadow: 0 4px 18px rgba(0,0,0,0.5);
    margin-bottom: 4px;
}
.emb-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}
.emb-left {
    display: flex;
    align-items: center;
    gap: 10px;
}
.emb-title {
    font-family: 'Exo 2', sans-serif;
    font-size: 0.78rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--orange);
}
.emb-hint {
    font-size: 0.68rem;
    color: var(--text-dim);
}
.emb-right {
    display: flex;
    align-items: center;
    gap: 8px;
}
.emb-save-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    background: linear-gradient(135deg, #166534, #15803d);
    border: 1px solid #16a34a;
    color: #fff;
    font-size: 0.78rem;
    font-weight: 800;
    padding: 6px 16px;
    border-radius: 5px;
    cursor: pointer;
    font-family: 'Exo 2', sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    transition: all 0.15s;
}
.emb-save-btn:hover { background: linear-gradient(135deg, #15803d, #16a34a); box-shadow: 0 0 12px rgba(34,197,94,0.25); }
.emb-exit-btn {
    display: flex;
    align-items: center;
    gap: 5px;
    background: rgba(255,255,255,0.05);
    border: 1px solid var(--border);
    color: var(--text-dim);
    font-size: 0.75rem;
    padding: 6px 12px;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.15s;
}
.emb-exit-btn:hover { color: #fff; border-color: rgba(255,255,255,0.2); }

/* ─── EDIT MODE BODY CLASS EFFECTS ─── */
body.edit-mode .store-pkg-card,
body.edit-mode #homeFeaturedGrid .pkg-card {
    cursor: grab !important;
    outline: 1px dashed rgba(59,130,246,0.2);
}
body.edit-mode .store-pkg-card:active,
body.edit-mode #homeFeaturedGrid .pkg-card:active { cursor: grabbing !important; }

/* SortableJS drag states */
.sortable-ghost { opacity: 0.35 !important; border: 2px dashed var(--orange) !important; }
.sortable-chosen { box-shadow: 0 12px 32px rgba(0,0,0,0.65) !important; transform: scale(1.02) rotate(0.5deg) !important; z-index: 200 !important; }

/* Sidebar drag in edit mode */
body.edit-mode ul.sidebar-menu li { cursor: grab; }
body.edit-mode ul.sidebar-menu li:active { cursor: grabbing; }
body.edit-mode ul.sidebar-menu li.sortable-chosen a { background: rgba(170,0,255,0.12) !important; border-radius: 6px; }

/* Pencil edit button on each card */
.pkg-inline-edit-btn {
    display: none;
    position: absolute;
    top: 6px;
    right: 6px;
    z-index: 15;
    align-items: center;
    gap: 4px;
    background: rgba(59,130,246,0.18);
    border: 1px solid rgba(59,130,246,0.45);
    color: #93c5fd;
    font-size: 0.65rem;
    padding: 3px 7px;
    border-radius: 3px;
    cursor: pointer;
    transition: all 0.15s;
    white-space: nowrap;
}
.pkg-inline-edit-btn:hover { background: rgba(59,130,246,0.35); border-color: rgba(59,130,246,0.7); color: #bfdbfe; }
body.edit-mode .pkg-inline-edit-btn { display: flex; }


/* ─── MOBILE-ONLY SIDEBAR NAV (hidden on desktop) ─── */
.sidebar-mobile-nav { display: none !important; }

/* ─── MOBILE HAMBURGER ─── */
.mobile-menu-btn { display: none; background: rgba(0,0,0,0.4); border: 1px solid var(--border); color: var(--text); font-size: 1.1rem; padding: 7px 11px; border-radius: 4px; cursor: pointer; flex-shrink: 0; transition: all 0.2s; line-height: 1; }
.mobile-menu-btn:hover { border-color: var(--orange-lt); color: var(--orange); }

/* ─── SIDEBAR DRAWER OVERLAY ─── */
.sidebar-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.65); z-index: 998; backdrop-filter: blur(2px); -webkit-backdrop-filter: blur(2px); }
.sidebar-overlay.visible { display: block; }

/* ─── TABLET / MOBILE (≤ 768px) ─── */
@media (max-width: 768px) {
    body { overflow-y: auto; height: auto; }

    .store-container { grid-template-columns: 1fr; height: auto; overflow: visible; }

    .sidebar {
        position: fixed;
        left: 0; top: 0; bottom: 0;
        width: 280px;
        transform: translateX(-100%);
        transition: transform 0.28s cubic-bezier(0.4, 0, 0.2, 1);
        z-index: 999;
        height: 100dvh;
        overflow-y: auto;
        border-right: 1px solid var(--border);
    }
    .sidebar.open { transform: translateX(0); box-shadow: 6px 0 30px rgba(0,0,0,0.8); }

    .mobile-menu-btn {
        display: flex;
        align-items: center;
        position: fixed;
        top: 10px;
        left: 10px;
        z-index: 997;
        background: rgba(15,10,5,0.85);
        backdrop-filter: blur(6px);
        -webkit-backdrop-filter: blur(6px);
        box-shadow: 0 2px 12px rgba(0,0,0,0.6);
    }

    .main-content { height: auto; overflow: visible; padding: 0.5rem 0.65rem; gap: 0.6rem; }

    .banner-utility-row { gap: 0.3rem; padding: 0.4rem 0.65rem; flex-wrap: nowrap; overflow-x: auto; }

    .site-logo { max-height: 30px; }

    /* Top nav: icon-only on tablet */
    .top-nav-link { font-size: 0; padding: 5px 8px; }
    .top-nav-link i { font-size: 0.85rem; }
    .top-nav-links { gap: 0; }

    /* Auth buttons: icon-only on tablet */
    .login-btn, .logout-btn { font-size: 0; padding: 7px 10px; gap: 0; min-width: 34px; justify-content: center; }
    .login-btn i, .logout-btn i { font-size: 0.9rem; }

    /* Cart: hide text */
    .cart-summary-text { display: none; }
    .cart-status-box { padding: 4px 8px; }
    .cart-icon-wrapper { font-size: 1.2rem; }
    .hover-cart-dropdown { width: min(280px, calc(100vw - 1.2rem)); right: 0; }

    /* Banner */
    .banner-header-area { min-height: 130px; }
    .banner-center-logo .join-logo { max-height: 70px; }
    .banner-center-logo .ip-banner-label { font-size: 0.62rem; padding: 2px 7px; }

    /* Content grids — 3-per-row featured packages */
    .featured-grid { flex-wrap: wrap; gap: 0.4rem; }
    .pkg-card { flex: 1 1 calc(33.333% - 0.3rem); min-width: 0; max-width: none; }
    .pkg-card-inner { padding: 0.55rem 0.5rem; }
    .pkg-name { font-size: 0.72rem; margin-bottom: 2px; }
    .pkg-price-row { font-size: 0.75rem; margin-bottom: 4px; }
    .pkg-card-btn { font-size: 0.65rem; padding: 5px 6px; }
    .pkg-icon { font-size: 1.4rem; margin-bottom: 4px; }
    .pkg-icon img { width: 36px; height: 36px; }
    .pkg-description, .pkg-info-list { display: none; }

    .about-content { grid-template-columns: 1fr; }
    .vote-grid { grid-template-columns: repeat(2, 1fr); }
    .lb-grid { grid-template-columns: repeat(2, 1fr) !important; }

    /* Modals */
    .modal-card { max-width: calc(100vw - 1.5rem) !important; padding: 1.5rem 1.2rem !important; }
    .desc-modal-card { max-width: calc(100vw - 1.5rem) !important; padding: 1.2rem !important; }
    .checkout-modal-card { max-width: calc(100vw - 1.5rem) !important; }
    #checkoutModal { padding: 2vh 0; }

    /* Staff panel */
    .staff-panel-card { width: 100vw !important; max-width: 100vw !important; max-height: 100dvh !important; border-radius: 0 !important; }
    .staff-panel-body { flex-direction: column; height: auto; overflow-y: auto; }
    .staff-panel-sidebar { width: 100%; flex-direction: row; flex-wrap: wrap; overflow-x: auto; border-right: none; border-bottom: 1px solid var(--border); padding: 0.4rem; }
    .staff-panel-content { height: auto; }
    .pkg-split-list { width: 100%; height: 160px; border-right: none; border-bottom: 1px solid var(--border); }
    #staffTab-packages.active { flex-direction: column; }

    .purchase-log-row { grid-template-columns: 70px 1fr 70px 50px; font-size: 0.72rem; }
    .audit-log-row { grid-template-columns: 90px 60px 1fr; font-size: 0.72rem; }
}

/* ─── SMALL PHONE (≤ 480px) ─── */
@media (max-width: 480px) {
    .top-nav-links { display: none; }

    .banner-utility-row { gap: 0.25rem; }

    .vote-grid { grid-template-columns: 1fr; }
    .lb-grid { grid-template-columns: 1fr !important; }

    .category-title { font-size: 1.05rem; }
    .category-subtitle { font-size: 0.68rem; }

    .modal-title { font-size: 1.3rem; }
    .modal-card { padding: 1.2rem 1rem !important; }
    .desc-modal-header { flex-direction: column; align-items: center; gap: 10px; }
    .desc-modal-title { font-size: 1.2rem; text-align: center; }
    .desc-modal-price { text-align: center; }
    .desc-modal-footer { flex-direction: column; gap: 8px; }
    .desc-modal-footer .modal-btn { width: 100%; }

    .forum-thread-post { flex-direction: column; }
    .forum-user-sidebar { width: 100%; flex-direction: row; border-right: none; border-bottom: 1px solid rgba(170,0,255,0.12); border-radius: 10px 10px 0 0; padding: 8px 12px; justify-content: flex-start; }
    .forum-content-wrap { border-radius: 0 0 10px 10px; }

    .banner-center-logo .join-logo { max-height: 56px; }
    .banner-header-area { min-height: 110px; }
}

/* ─── MOBILE: SHOW SIDEBAR NAV + GENERAL LAYOUT FIXES ─── */
@media (max-width: 768px) {
    /* Show the mobile-only nav section */
    .sidebar-mobile-nav { display: flex !important; margin-top: 0.5rem; border-top: 1px solid var(--border); padding-top: 0.5rem; }

    /* Main content: switch to block so tabs render naturally */
    .main-content { display: block !important; }
    .tab-content { flex: none !important; min-height: unset !important; overflow: visible !important; padding-top: 3rem; }
    #tab-home { flex-direction: column; padding-top: 0; }

    /* All tab sections scroll via body — remove inner overflow constraints */
    .lb-page { overflow: visible; }
    .lb-card-body { max-height: none; overflow-y: visible; }
    .forums-list, .forum-thread-view { overflow-y: visible; max-height: none; }
    .updates-list { overflow-y: visible; max-height: none; }
    .vote-grid { overflow: visible; }

    /* ── STAFF PANEL: icon-strip horizontal scrolling nav ── */
    .staff-panel-card {
        height: 100dvh !important;
        max-height: 100dvh !important;
        display: flex !important;
        flex-direction: column !important;
    }
    .staff-panel-body {
        flex-direction: column;
        flex: 1;
        min-height: 0;
        overflow: hidden;
    }
    .staff-panel-sidebar {
        flex-direction: row !important;
        flex-wrap: nowrap !important;
        overflow-x: auto !important;
        overflow-y: hidden !important;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        height: auto !important;
        flex-shrink: 0;
        border-right: none !important;
        border-bottom: 1px solid var(--border);
        padding: 6px !important;
        gap: 3px !important;
        align-items: center;
    }
    .staff-panel-sidebar::-webkit-scrollbar { display: none; }
    .staff-sidebar-sep { display: none !important; }
    .staff-tab-btn {
        flex-shrink: 0 !important;
        font-size: 0.62rem !important;
        padding: 6px 9px !important;
        gap: 4px !important;
        white-space: nowrap;
        border-radius: 6px;
        width: auto !important;
    }
    .staff-tab-btn i { font-size: 0.78rem !important; width: auto !important; }
    .staff-panel-content { overflow-y: auto; flex: 1; min-height: 0; }
    /* Staff forms: stack rows on mobile */
    .staff-row { flex-direction: column; }
    .staff-row .staff-input { width: 100%; }
    .staff-row .staff-btn-sm { width: 100%; align-self: stretch; }
    .pkg-create-grid { grid-template-columns: 1fr; }
    .staff-log-box { max-height: 180px; }

    /* ── FORUMS ── */
    .forums-auth { max-width: 100%; padding-top: 1rem; }
    .forums-toolbar { flex-direction: column; align-items: stretch; gap: 6px; }
    .forums-toolbar > * { width: 100% !important; }
    .forum-pop-card { min-width: 170px; }
    .forum-pop-carousel { gap: 8px; padding: 6px 0; }
    .forum-profile-card { flex-direction: column; align-items: center; text-align: center; }
    .forum-profile-stats { justify-content: center; }
    .forum-members-table { font-size: 0.78rem; }
    .forum-member-row { gap: 5px; }
    .forum-react-popup { position: fixed; bottom: 80px; left: 50%; transform: translateX(-50%); }
    .forums-auth-tabs { gap: 2px; }

    /* ── LEADERBOARDS ── */
    .lb-credit-banner { font-size: 0.72rem; padding: 8px 10px; gap: 8px; flex-wrap: wrap; }
    .lb-online-badge { font-size: 0.72rem; }
    .lb-grid { gap: 0.6rem !important; }
    .lb-table td, .lb-table th { padding: 5px 8px; }

    /* ── UPDATES ── */
    .update-card { padding: 0.75rem; }
    .update-title { font-size: 0.82rem; }

    /* ── VOTE ── */
    .vote-card { padding: 0.85rem; gap: 0.6rem; }
    .vote-icon { font-size: 1.8rem; }

    /* ── MODALS: ensure vertical scrolling on small screens ── */
    .modal-overlay { align-items: flex-start; padding: 10px 0; overflow-y: auto; }
    .modal-card { margin: auto; }
    .desc-modal-card { margin: auto; }

    /* ── CHECKOUT ── */
    .checkout-items-list { max-height: 200px; }

    /* ── ABOUT SECTION ── */
    .about-section { margin-top: 1rem; margin-bottom: 1.5rem; }
}

/* ── INBOX ── */
.inbox-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 16px;
    height: 16px;
    padding: 0 4px;
    border-radius: 8px;
    background: #FF4444;
    color: #fff;
    font-size: 0.6rem;
    font-weight: 800;
    margin-left: 4px;
    vertical-align: middle;
    font-family: 'Exo 2', sans-serif;
}
.inbox-row.unread {
    background: rgba(88,101,242,0.08);
    border-left: 3px solid #5865F2;
}
.inbox-row.read {
    opacity: 0.8;
    border-left: 3px solid transparent;
}
