@charset "utf-8";

/* =========================================================
   WORLD CLASS GAMING SERVER DESIGN
   Colors: Deep Black + Electric Purple + Bright Gold
   Fonts: Cinzel (titles) + Exo 2 (body)
   ========================================================= */

@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@400;700;900&family=Exo+2:wght@300;400;600;700&display=swap');

:root {
    --purple:      #7b2fff;
    --purple-dim:  rgba(123, 47, 255, 0.15);
    --purple-glow: rgba(123, 47, 255, 0.5);
    --gold:        #d4a847;
    --gold-light:  #ffe08a;
    --gold-dark:   #8a6520;
    --gold-glow:   rgba(212, 168, 71, 0.45);
    --bg-dark:     #07060d;
    --glass:       rgba(7, 6, 14, 0.65);
    --glass-hover: rgba(15, 10, 30, 0.85);
    --border:      rgba(123, 47, 255, 0.3);
    --border-gold: rgba(212, 168, 71, 0.4);
    --text:        #dcdcdc;
    --text-dim:    #888;
    --blur:        blur(20px);
    --font-title:  'Cinzel', serif;
    --font-body:   'Exo 2', sans-serif;
    --radius:      12px;
}

/* ========== RESET ========== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
ul, li { list-style: none; }
a { text-decoration: none; color: var(--gold); transition: 0.3s ease; }
a:hover { color: #fff; text-shadow: 0 0 10px var(--gold); }
.clear { clear: both; }

body {
    font-family: var(--font-body);
    font-size: 14px;
    color: var(--text);
    background: #000 url(../images/bg-site.png) no-repeat center center fixed;
    background-size: cover;
    line-height: 1.6;
}

body::before {
    content: '';
    position: fixed;
    inset: 0;
    background: radial-gradient(circle at center, rgba(0,0,0,0.2) 0%, rgba(0,0,0,0.8) 100%);
    z-index: -1;
}

/* ========== NAVBAR ========== */
#navbar {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(5, 5, 10, 0.85);
    backdrop-filter: var(--blur);
    -webkit-backdrop-filter: var(--blur);
    border-bottom: 1px solid var(--border);
    box-shadow: 0 4px 30px rgba(0,0,0,0.5);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
    height: 80px;
}

.nav-brand {
    font-family: var(--font-title);
    font-size: 24px;
    font-weight: 900;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 2px;
    text-shadow: 0 0 15px var(--gold-glow);
}

.nav-menu {
    display: flex;
    gap: 30px;
}

.nav-menu li a {
    font-family: var(--font-title);
    font-size: 13px;
    font-weight: 700;
    color: #ccc;
    letter-spacing: 2px;
    text-transform: uppercase;
    position: relative;
    padding: 10px 0;
}

.nav-menu li a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gold);
    transition: 0.3s ease;
    box-shadow: 0 0 10px var(--gold);
}

.nav-menu li a:hover {
    color: #fff;
}

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

/* ========== HERO 3D TEXT ========== */
#hero {
    height: 400px;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero-content {
    animation: fadeInUp 1s ease-out;
}

.text-3d {
    font-family: var(--font-title);
    font-size: 5rem;
    font-weight: 900;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 5px;
    margin-bottom: 10px;
    transform: perspective(600px) rotateX(10deg);
    text-shadow: 
        0 1px 0 #ccc,
        0 2px 0 #c9c9c9,
        0 3px 0 #bbb,
        0 4px 0 #b9b9b9,
        0 5px 0 #aaa,
        0 6px 1px rgba(0,0,0,.1),
        0 0 5px rgba(0,0,0,.1),
        0 1px 3px rgba(0,0,0,.3),
        0 3px 5px rgba(0,0,0,.2),
        0 5px 10px rgba(0,0,0,.25),
        0 10px 10px rgba(0,0,0,.2),
        0 20px 20px rgba(123,47,255,.4),
        0 0 40px rgba(212,168,71,.5);
}

.hero-subtitle {
    font-family: var(--font-body);
    font-size: 16px;
    color: var(--gold);
    letter-spacing: 4px;
    text-transform: uppercase;
    text-shadow: 0 2px 4px rgba(0,0,0,0.8);
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ========== MAIN LAYOUT WRAPPER ========== */
#wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px 60px;
}

#main-layout {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 30px;
    align-items: start;
}

/* ========== WIDGETS (SIDEBAR) ========== */
.widget {
    background: var(--glass);
    backdrop-filter: var(--blur);
    -webkit-backdrop-filter: var(--blur);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    margin-bottom: 25px;
    overflow: hidden;
    transition: 0.3s ease;
}

.widget:hover {
    background: var(--glass-hover);
    border-color: var(--purple);
    box-shadow: 0 10px 40px rgba(123,47,255,0.2);
}

.widget-title {
    font-family: var(--font-title);
    font-size: 14px;
    font-weight: 700;
    color: var(--gold);
    text-transform: uppercase;
    letter-spacing: 2px;
    padding: 15px 20px;
    background: rgba(0,0,0,0.4);
    border-bottom: 1px solid var(--border);
    text-align: center;
}

.widget-body {
    padding: 20px;
}

.widget-body.p-0 {
    padding: 0;
}

/* ========== LOGIN FORM ========== */
.input-group {
    margin-bottom: 15px;
}

.input-group input, input.login {
    width: 100%;
    padding: 12px 15px;
    background: rgba(0,0,0,0.6);
    border: 1px solid var(--border);
    border-radius: 6px;
    color: #fff;
    font-family: var(--font-body);
    font-size: 13px;
    transition: 0.3s;
}

.input-group input:focus, input.login:focus {
    border-color: var(--gold);
    box-shadow: 0 0 15px rgba(212,168,71,0.3);
    outline: none;
}

.submit-btn, input[type="submit"] {
    width: 100%;
    padding: 12px;
    background: linear-gradient(135deg, var(--purple) 0%, #4a1aaa 100%);
    border: none;
    border-radius: 6px;
    color: #fff;
    font-family: var(--font-title);
    font-weight: 700;
    font-size: 13px;
    letter-spacing: 2px;
    cursor: pointer;
    transition: 0.3s;
    text-transform: uppercase;
    box-shadow: 0 5px 15px rgba(123,47,255,0.3);
}

.submit-btn:hover, input[type="submit"]:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(123,47,255,0.5);
    background: linear-gradient(135deg, #9b4fff 0%, var(--purple) 100%);
}

.form-links {
    margin-top: 15px;
    display: flex;
    justify-content: space-between;
    font-size: 12px;
}

.error-msg {
    color: #ff4d4d;
    background: rgba(255,0,0,0.1);
    padding: 10px;
    border-radius: 4px;
    text-align: center;
    margin-top: 10px;
    border: 1px solid rgba(255,0,0,0.3);
}

/* ========== USER PANEL ========== */
.user-panel {
    text-align: center;
}

.user-welcome {
    font-size: 13px;
    color: var(--text-dim);
    margin-bottom: 15px;
}

.user-welcome strong {
    font-family: var(--font-title);
    font-size: 18px;
    color: var(--gold);
    display: block;
    margin-top: 5px;
}

.action-btn {
    display: block;
    padding: 10px;
    background: rgba(255,255,255,0.05);
    border: 1px solid var(--border);
    margin-bottom: 8px;
    border-radius: 4px;
    color: #fff;
    transition: 0.3s;
}

.action-btn:hover {
    background: var(--purple-dim);
    border-color: var(--purple);
    transform: translateX(5px);
}

.logout-btn {
    background: rgba(255,0,0,0.1);
    border-color: rgba(255,0,0,0.3);
    color: #ff4d4d;
}

.logout-btn:hover {
    background: rgba(255,0,0,0.2);
    border-color: #ff4d4d;
    transform: none;
}

/* ========== STATUS LIST ========== */
.status-list {
    list-style: none;
}

.status-list li {
    display: flex;
    justify-content: space-between;
    padding: 12px 20px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.status-list li:last-child {
    border-bottom: none;
}

.status-list .lbl {
    color: var(--text-dim);
}

.status-list .val {
    color: #fff;
    font-weight: 600;
}

.text-success { color: #00ff88 !important; text-shadow: 0 0 10px rgba(0,255,136,0.5); }
.text-offline { color: #ff4d4d !important; text-shadow: 0 0 10px rgba(255,77,77,0.5); }
.text-gold { color: var(--gold) !important; }
.highlight { font-size: 16px; color: var(--purple) !important; text-shadow: 0 0 10px var(--purple-glow); }

/* ========== CONTENT AREA ARTICLES ========== */
#content_ajax {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

#content_ajax article, #content_ajax aside {
    background: var(--glass);
    backdrop-filter: var(--blur);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

#content_ajax .top {
    font-family: var(--font-title);
    font-size: 18px;
    font-weight: 700;
    color: var(--gold);
    background: rgba(0,0,0,0.4);
    padding: 20px 30px;
    border-bottom: 1px solid var(--border-gold);
}

#content_ajax .body {
    padding: 30px;
}

/* Content specific styles (Legacy support) */
.down {
    background: rgba(212,168,71,0.1);
    color: var(--gold);
    font-family: var(--font-title);
    padding: 15px;
    font-weight: 700;
    border: 1px solid var(--border-gold);
    border-radius: 6px;
    text-align: center;
    margin: 5px;
}

.down2 {
    background: rgba(0,0,0,0.4);
    color: #fff;
    padding: 15px;
    border: 1px solid var(--border);
    border-radius: 6px;
    text-align: center;
    margin: 5px;
    transition: 0.3s;
}

.down2:hover {
    background: var(--purple-dim);
    border-color: var(--purple);
}

table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 5px;
}

/* ========== FOOTER ========== */
footer {
    text-align: center;
    padding: 40px 0;
    margin-top: 40px;
    border-top: 1px solid var(--border);
}

.footer-brand {
    font-family: var(--font-title);
    color: var(--gold);
    font-size: 24px;
    margin-bottom: 10px;
}

/* ========== HOME PAGE STYLES ========== */
.welcome-text {
    text-align: center;
    padding: 20px 10px;
}

.welcome-text h3 {
    font-family: var(--font-title);
    color: var(--gold-light);
    font-size: 26px;
    margin-bottom: 20px;
    letter-spacing: 2px;
}

.welcome-text p {
    font-size: 15px;
    color: var(--text);
    max-width: 750px;
    margin: 0 auto 30px;
    line-height: 1.8;
}

.action-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 25px;
}

.btn-primary, .btn-secondary {
    padding: 12px 35px;
    border-radius: 30px;
    font-family: var(--font-title);
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    transition: 0.3s ease;
    display: inline-block;
}

.btn-primary {
    background: linear-gradient(135deg, var(--purple) 0%, #4a1aaa 100%);
    color: #fff;
    box-shadow: 0 5px 20px var(--purple-glow);
    border: none;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px var(--purple-glow);
    color: #fff;
}

.btn-secondary {
    background: transparent;
    color: var(--gold);
    border: 2px solid var(--gold);
    box-shadow: 0 5px 15px rgba(212,168,71,0.2);
}

.btn-secondary:hover {
    background: var(--gold);
    color: #000;
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(212,168,71,0.4);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 25px;
    padding: 25px;
}

.feature-card {
    background: rgba(0,0,0,0.5);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 30px 20px;
    text-align: center;
    transition: 0.3s ease;
}

.feature-card:hover {
    border-color: var(--gold);
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(212,168,71,0.15);
}

.feature-card h4 {
    font-family: var(--font-title);
    color: var(--purple);
    font-size: 18px;
    margin-bottom: 15px;
    letter-spacing: 1px;
}

.feature-card p {
    font-size: 14px;
    color: var(--text-dim);
    line-height: 1.6;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 992px) {
    #main-layout { grid-template-columns: 1fr; }
    .text-3d { font-size: 3.5rem; }
}

@media (max-width: 768px) {
    .nav-menu { display: none; /* In reality would need a mobile menu toggle */ }
    .text-3d { font-size: 2.5rem; }
}


/* ========== DOWNLOAD PAGE ========== */
.dl-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 25px;
}

.dl-card {
    background: rgba(0,0,0,0.5);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 30px 25px;
    text-align: center;
    transition: 0.3s ease;
}

.dl-card:hover {
    border-color: var(--gold);
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(212,168,71,0.15);
}

.dl-card__icon {
    font-size: 36px;
    margin-bottom: 15px;
    display: block;
    filter: drop-shadow(0 0 8px var(--gold-glow));
}

.dl-card__header {
    font-family: var(--font-title);
    font-size: 18px;
    font-weight: 700;
    color: var(--purple);
    text-align: center;
    margin-bottom: 8px;
    letter-spacing: 1px;
}

.dl-card__size {
    font-family: var(--font-body);
    font-size: 13px;
    color: var(--text-dim);
    text-align: center;
    margin-bottom: 20px;
    line-height: 1.6;
}

.dl-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.dl-btn {
    display: block;
    padding: 12px 20px;
    min-height: 44px;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: 30px;
    color: var(--gold);
    font-family: var(--font-title);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1px;
    text-align: center;
    text-transform: uppercase;
    transition: 0.3s ease;
}

.dl-btn:hover {
    background: var(--purple-dim);
    border-color: var(--purple);
    color: #fff;
    box-shadow: 0 5px 20px var(--purple-glow);
    transform: translateY(-2px);
    text-shadow: none;
}

.dl-support {
    text-align: center;
    margin-top: 30px;
    padding: 15px;
    color: var(--text-dim);
    font-size: 14px;
    border-top: 1px solid var(--border);
}

.dl-support a {
    color: var(--gold);
    font-weight: 600;
}

.dl-support a:hover {
    color: var(--gold-light);
    text-shadow: 0 0 10px var(--gold-glow);
}

@media (max-width: 768px) {
    .dl-grid { grid-template-columns: 1fr; }
}

/* ========== SHARED PAGE STYLES ========== */

/* Form pages (register, recover, change password/email) */
.page-form-wrap {
    max-width: 420px;
    margin: 0 auto;
}

.page-form-result {
    margin-top: 20px;
    padding: 15px;
    background: rgba(0,0,0,0.3);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    text-align: center;
    font-size: 14px;
    line-height: 1.8;
}

.success-msg {
    color: #00ff88;
    font-weight: bold;
    margin-bottom: 10px;
}

.text-dim-center {
    color: var(--text-dim);
    text-align: center;
}

/* Table pages (donate, contact, warztime, rankings) */
.page-table-wrap {
    width: 100%;
    overflow-x: auto;
}

.styled-table {
    width: 100%;
    border-collapse: collapse;
    font-family: var(--font-body);
    font-size: 14px;
}

.styled-table thead tr {
    background: rgba(212,168,71,0.1);
    border-bottom: 2px solid var(--border-gold);
}

.styled-table th {
    font-family: var(--font-title);
    font-size: 12px;
    font-weight: 700;
    color: var(--gold);
    letter-spacing: 2px;
    text-transform: uppercase;
    padding: 14px 16px;
    text-align: center;
}

.styled-table tbody tr {
    border-bottom: 1px solid rgba(255,255,255,0.05);
    transition: background 0.2s ease;
}

.styled-table tbody tr:last-child {
    border-bottom: none;
}

.styled-table tbody tr:hover {
    background: var(--purple-dim);
}

.styled-table td {
    padding: 12px 16px;
    color: var(--text);
    text-align: center;
    vertical-align: middle;
}

/* Ranking top 3 highlights */
.rank-top-1 td { color: #ffd700 !important; }
.rank-top-2 td { color: #c0c0c0 !important; }
.rank-top-3 td { color: #cd7f32 !important; }

.rank-num {
    font-family: var(--font-title);
    font-weight: 700;
    color: var(--text-dim);
}

/* Ranking category cards grid */
.ranking-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 20px;
}

.ranking-card {
    text-decoration: none;
    display: block;
    transition: 0.3s ease;
}

.ranking-card:hover {
    color: inherit;
    text-shadow: none;
}

/* Page subtitle */
.page-subtitle {
    text-align: center;
    color: var(--text-dim);
    margin-bottom: 25px;
    font-size: 14px;
}

/* Text helpers */
.text-danger { color: #ff4d4d !important; }

/* Vote page */
.vote-wrap {
    display: flex;
    justify-content: center;
}

#outerdiv {
    width: 100%;
    max-width: 700px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}

#inneriframe {
    width: 100%;
    min-height: 400px;
    border: none;
    display: block;
}

@media (max-width: 768px) {
    .ranking-grid { grid-template-columns: 1fr 1fr; }
    .styled-table th, .styled-table td { padding: 10px 8px; font-size: 12px; }
}

/* ========== LOADING SCREEN ========== */
#loading-screen {
    position: fixed;
    inset: 0;
    background: #07060d;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 20px;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

#loading-screen.hidden {
    opacity: 0;
    visibility: hidden;
}

.loader-brand {
    font-family: var(--font-title);
    font-size: 28px;
    font-weight: 900;
    color: var(--gold);
    letter-spacing: 4px;
    text-transform: uppercase;
    text-shadow: 0 0 20px var(--gold-glow);
}

.loader-bar-wrap {
    width: 220px;
    height: 3px;
    background: rgba(255,255,255,0.1);
    border-radius: 3px;
    overflow: hidden;
}

.loader-bar {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, var(--purple), var(--gold));
    border-radius: 3px;
    animation: loadBar 1.2s ease forwards;
}

@keyframes loadBar {
    0%   { width: 0%; }
    60%  { width: 80%; }
    100% { width: 100%; }
}

/* ========== PARTICLES CANVAS ========== */
#particles-canvas {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 0;
}

#hero {
    position: relative;
}

#hero .hero-content {
    position: relative;
    z-index: 1;
}

/* ========== SCROLL TO TOP — replaced by progress ring version below ========== */

/* ========== ANIMATED COUNTERS ========== */
.val[data-count] {
    display: inline-block;
}

/* ========== NEWS PAGE ========== */
.news-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.news-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    background: rgba(0,0,0,0.3);
    border: 1px solid var(--border);
    border-radius: 8px;
    transition: background 0.2s ease, border-color 0.2s ease;
}

.news-item:hover {
    background: var(--purple-dim);
    border-color: var(--purple);
}

.news-tag {
    font-family: var(--font-title);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
    padding: 3px 8px;
    border-radius: 4px;
    white-space: nowrap;
    text-transform: uppercase;
}

.news-tag--new    { background: rgba(0,255,136,0.15); color: #00ff88; border: 1px solid rgba(0,255,136,0.3); }
.news-tag--event  { background: rgba(123,47,255,0.2); color: #b07fff; border: 1px solid var(--border); }
.news-tag--hot    { background: rgba(255,77,77,0.15); color: #ff6b6b; border: 1px solid rgba(255,77,77,0.3); }
.news-tag--update { background: rgba(212,168,71,0.15); color: var(--gold); border: 1px solid var(--border-gold); }

.news-text {
    color: var(--text);
    font-size: 14px;
    line-height: 1.5;
}

/* ========== RATES PAGE ========== */
.rates-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 20px;
}

.rate-card {
    text-align: center;
}

.rate-value {
    font-family: var(--font-title);
    font-size: 28px;
    font-weight: 900;
    color: var(--purple);
    text-shadow: 0 0 15px var(--purple-glow);
    margin-top: 5px;
}

/* ========== GUILD WARS ========== */
.gw-today {
    background: rgba(212,168,71,0.08) !important;
    border-left: 3px solid var(--gold);
}

/* ========== PROFILE PAGE ========== */
.profile-wrap {
    display: flex;
    gap: 30px;
    align-items: flex-start;
}

.profile-avatar img {
    border-radius: var(--radius);
    border: 2px solid var(--border-gold);
    box-shadow: 0 0 20px var(--gold-glow);
    width: 96px;
    height: 96px;
}

.profile-name {
    font-family: var(--font-title);
    font-size: 22px;
    color: var(--gold-light);
    margin-bottom: 15px;
    letter-spacing: 2px;
}

.profile-stats {
    min-width: 260px;
}

/* ========== TOOLTIP ========== */
.has-tooltip {
    position: relative;
    cursor: pointer;
}

.has-tooltip .tooltip-box {
    display: none;
    position: absolute;
    bottom: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%);
    background: rgba(7,6,14,0.95);
    border: 1px solid var(--border-gold);
    border-radius: 8px;
    padding: 10px 14px;
    min-width: 180px;
    font-size: 12px;
    color: var(--text);
    z-index: 100;
    white-space: nowrap;
    box-shadow: 0 8px 20px rgba(0,0,0,0.6);
    pointer-events: none;
}

.has-tooltip .tooltip-box::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: var(--border-gold);
}

.has-tooltip:hover .tooltip-box {
    display: block;
}

.tooltip-row {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 2px 0;
}

.tooltip-row .lbl { color: var(--text-dim); }
.tooltip-row .val { color: var(--gold); font-weight: 600; }

/* ========== COPY TO CLIPBOARD ========== */
.dl-btn-wrap {
    position: relative;
    display: flex;
    align-items: center;
    gap: 8px;
}

.dl-btn-wrap .dl-btn {
    flex: 1;
}

.copy-btn {
    flex-shrink: 0;
    width: 36px;
    height: 44px;
    background: rgba(255,255,255,0.05);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text-dim);
    font-size: 14px;
    cursor: pointer;
    transition: 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.copy-btn:hover {
    background: var(--purple-dim);
    border-color: var(--purple);
    color: #fff;
}

.copy-btn.copied {
    color: #00ff88;
    border-color: rgba(0,255,136,0.4);
}

@media (max-width: 768px) {
    .profile-wrap { flex-direction: column; align-items: center; text-align: center; }
    .rates-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ========== LEADERBOARD ========== */
.leaderboard {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

/* Top 3 podium */
.leaderboard-podium {
    display: flex;
    justify-content: center;
    align-items: flex-end;
    gap: 12px;
    margin-bottom: 35px;
    padding: 10px 10px 0;
}

/* Gradient border trick via pseudo-element */
.podium-card {
    position: relative;
    border-radius: var(--radius);
    padding: 2px;
    flex: 1;
    max-width: 220px;
    transition: transform 0.3s ease;
}

.podium-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: var(--radius);
    padding: 2px;
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
}

.podium-card.rank-1::before { background: linear-gradient(135deg, #ffd700, #ff8c00, #ffd700); background-size: 200% 200%; animation: shimmerBorder 2s linear infinite; }
.podium-card.rank-2::before { background: linear-gradient(135deg, #c0c0c0, #808080, #c0c0c0); }
.podium-card.rank-3::before { background: linear-gradient(135deg, #cd7f32, #8b4513, #cd7f32); }

@keyframes shimmerBorder {
    0%   { background-position: 0% 50%; }
    50%  { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.podium-inner {
    background: rgba(5,4,12,0.92);
    border-radius: calc(var(--radius) - 2px);
    padding: 22px 15px 18px;
    text-align: center;
    height: 100%;
    position: relative;
    overflow: hidden;
}

/* Glow pulse for #1 */
.podium-card.rank-1 .podium-inner::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at 50% 0%, rgba(255,215,0,0.12) 0%, transparent 70%);
    animation: glowPulse 2.5s ease-in-out infinite;
    pointer-events: none;
}

@keyframes glowPulse {
    0%, 100% { opacity: 0.6; }
    50%       { opacity: 1; }
}

.podium-card:hover { transform: translateY(-6px); }
.podium-card.rank-1 { min-height: 210px; order: 2; }
.podium-card.rank-2 { min-height: 175px; order: 1; margin-bottom: 0; }
.podium-card.rank-3 { min-height: 160px; order: 3; margin-bottom: 0; }

/* Crown for #1 */
.podium-crown {
    font-size: 28px;
    display: block;
    margin-bottom: 4px;
    animation: crownBounce 2s ease-in-out infinite;
    filter: drop-shadow(0 0 8px rgba(255,215,0,0.8));
}

@keyframes crownBounce {
    0%, 100% { transform: translateY(0); }
    50%       { transform: translateY(-4px); }
}

.podium-badge {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-title);
    font-size: 15px;
    font-weight: 900;
    margin: 0 auto 12px;
}

.rank-1 .podium-badge { background: linear-gradient(135deg,#ffd700,#b8860b); color: #000; box-shadow: 0 0 14px rgba(255,215,0,0.6); }
.rank-2 .podium-badge { background: linear-gradient(135deg,#c0c0c0,#707070); color: #000; }
.rank-3 .podium-badge { background: linear-gradient(135deg,#cd7f32,#7a3f10); color: #fff; }

.podium-avatar { margin-bottom: 8px; }
.podium-avatar img { width: 56px; height: 56px; border-radius: 8px; border: 2px solid rgba(255,255,255,0.1); }

.podium-name {
    font-family: var(--font-title);
    font-size: 13px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 8px;
    word-break: break-all;
    line-height: 1.3;
}

.podium-value {
    font-size: 22px;
    font-weight: 900;
    font-family: var(--font-title);
    line-height: 1;
    margin-bottom: 5px;
}

.rank-1 .podium-value { color: #ffd700; text-shadow: 0 0 15px rgba(255,215,0,0.7); }
.rank-2 .podium-value { color: #c0c0c0; }
.rank-3 .podium-value { color: #cd7f32; }

.podium-sub {
    font-size: 10px;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

/* Leaderboard rows */
.leaderboard { display: flex; flex-direction: column; gap: 5px; }

.lb-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 16px;
    background: rgba(0,0,0,0.25);
    border: 1px solid rgba(255,255,255,0.04);
    border-radius: 8px;
    transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
    position: relative;
    overflow: hidden;
}

/* Watermark rank number */
.lb-row::before {
    content: attr(data-rank);
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    font-family: var(--font-title);
    font-size: 48px;
    font-weight: 900;
    color: rgba(255,255,255,0.03);
    pointer-events: none;
    line-height: 1;
}

.lb-row:hover {
    background: var(--purple-dim);
    border-color: var(--border);
    transform: translateX(4px);
}

.lb-rank {
    font-family: var(--font-title);
    font-size: 12px;
    font-weight: 700;
    color: var(--text-dim);
    min-width: 26px;
    text-align: center;
}

.lb-avatar img { width: 36px; height: 36px; border-radius: 6px; border: 1px solid var(--border); display: block; }

.lb-name { flex: 1; font-weight: 600; color: #fff; font-size: 14px; line-height: 1.3; }
.lb-sub  { font-size: 11px; color: var(--text-dim); margin-top: 2px; }

.lb-value {
    font-family: var(--font-title);
    font-size: 13px;
    font-weight: 700;
    color: var(--gold);
    text-align: right;
    white-space: nowrap;
    position: relative;
    z-index: 1;
}

.lb-class {
    font-size: 11px;
    color: var(--purple);
    background: var(--purple-dim);
    padding: 2px 8px;
    border-radius: 4px;
    border: 1px solid var(--border);
    white-space: nowrap;
    position: relative;
    z-index: 1;
}

@media (max-width: 768px) {
    .leaderboard-podium { flex-direction: column; align-items: center; }
    .podium-card { max-width: 100%; width: 100%; min-height: auto !important; order: unset !important; }
    .lb-row { flex-wrap: wrap; }
}

/* ========== PAGE TRANSITIONS ========== */
#content_ajax {
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.page-fade-in {
    animation: pageFadeIn 0.35s ease forwards;
}

.page-fade-out {
    opacity: 0;
    transform: translateY(8px);
}

@keyframes pageFadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ========== NAVBAR ACTIVE + DROPDOWN ========== */
.nav-menu li a.nav-active {
    color: var(--gold) !important;
}

.nav-menu li a.nav-active::after {
    width: 100% !important;
}

.nav-dropdown {
    position: relative;
}

.nav-submenu {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%);
    background: rgba(5,5,12,0.97);
    backdrop-filter: var(--blur);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    min-width: 160px;
    padding: 8px 0;
    z-index: 200;
    box-shadow: 0 10px 30px rgba(0,0,0,0.6);
}

.nav-dropdown:hover .nav-submenu {
    display: block;
}

.nav-submenu li a {
    display: block;
    padding: 8px 18px;
    font-size: 12px;
    color: var(--text) !important;
    letter-spacing: 1px;
    transition: 0.2s;
}

.nav-submenu li a:hover {
    color: var(--gold) !important;
    background: var(--purple-dim);
    text-shadow: none;
}

.nav-submenu li a::after { display: none; }

/* ========== LIVE TICKER ========== */
.hero-ticker {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 36px;
    background: rgba(0,0,0,0.5);
    border-top: 1px solid var(--border);
    display: flex;
    align-items: center;
    overflow: hidden;
    z-index: 2;
}

.ticker-label {
    font-family: var(--font-title);
    font-size: 11px;
    font-weight: 700;
    color: #ff4d4d;
    background: rgba(255,77,77,0.15);
    border-right: 1px solid var(--border);
    padding: 0 14px;
    height: 100%;
    display: flex;
    align-items: center;
    letter-spacing: 2px;
    flex-shrink: 0;
    animation: livePulse 1.5s ease-in-out infinite;
}

@keyframes livePulse {
    0%, 100% { opacity: 1; }
    50%       { opacity: 0.5; }
}

.ticker-track {
    flex: 1;
    overflow: hidden;
    height: 100%;
    display: flex;
    align-items: center;
}

.ticker-inner {
    display: flex;
    align-items: center;
    white-space: nowrap;
    animation: tickerScroll 30s linear infinite;
}

.ticker-item {
    font-size: 13px;
    color: var(--text);
    padding: 0 40px;
}

.ticker-item strong { color: var(--gold); }

@keyframes tickerScroll {
    0%   { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* ========== COLLAPSIBLE WIDGETS ========== */
.widget-title {
    cursor: pointer;
    user-select: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.widget-arrow {
    font-size: 12px;
    color: var(--text-dim);
    transition: transform 0.3s ease;
}

.widget-collapsible {
    overflow: hidden;
    max-height: 600px;
    transition: max-height 0.35s ease, padding 0.35s ease;
}

.widget-collapsible.collapsed {
    max-height: 0 !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
}

/* ========== 404 PAGE ========== */
.not-found-wrap {
    text-align: center;
    padding: 40px 20px;
}

.not-found-code {
    font-family: var(--font-title);
    font-size: 100px;
    font-weight: 900;
    color: transparent;
    -webkit-text-stroke: 2px var(--purple);
    text-shadow: 0 0 40px var(--purple-glow);
    line-height: 1;
    margin-bottom: 15px;
    animation: glowPulse 2.5s ease-in-out infinite;
}

.not-found-msg {
    color: var(--text-dim);
    font-size: 16px;
    margin-bottom: 10px;
}

/* ========== ANNOUNCEMENT BANNER ========== */
.ann-banner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 10px 50px 10px 20px;
    font-family: var(--font-body);
    font-size: 14px;
    font-weight: 600;
    text-align: center;
    position: relative;
    z-index: 999;
    animation: annSlideDown 0.4s ease;
}

@keyframes annSlideDown {
    from { transform: translateY(-100%); opacity: 0; }
    to   { transform: translateY(0);     opacity: 1; }
}

.ann-event  { background: linear-gradient(90deg, rgba(123,47,255,0.3), rgba(123,47,255,0.15)); border-bottom: 1px solid var(--border); color: #c9a0ff; }
.ann-hot    { background: linear-gradient(90deg, rgba(255,77,77,0.25), rgba(255,77,77,0.1));   border-bottom: 1px solid rgba(255,77,77,0.3); color: #ff9090; }
.ann-new    { background: linear-gradient(90deg, rgba(0,255,136,0.2), rgba(0,255,136,0.08));   border-bottom: 1px solid rgba(0,255,136,0.3); color: #80ffcc; }
.ann-update { background: linear-gradient(90deg, rgba(212,168,71,0.25), rgba(212,168,71,0.1)); border-bottom: 1px solid var(--border-gold); color: var(--gold-light); }

.ann-text { flex: 1; }

.ann-close {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: rgba(255,255,255,0.4);
    font-size: 14px;
    cursor: pointer;
    padding: 4px 6px;
    border-radius: 4px;
    transition: color 0.2s, background 0.2s;
}

.ann-close:hover {
    color: #fff;
    background: rgba(255,255,255,0.1);
}

/* ========== SCROLL TO TOP — PROGRESS RING ========== */
#scroll-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 44px;
    height: 44px;
    background: rgba(7,6,14,0.9);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

#scroll-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

#scroll-top:hover { transform: translateY(-3px); }

.scroll-progress-ring {
    position: absolute;
    inset: 0;
    width: 44px;
    height: 44px;
    transform: rotate(-90deg);
}

.scroll-ring-bg {
    fill: none;
    stroke: rgba(255,255,255,0.08);
    stroke-width: 3;
}

.scroll-ring-fill {
    fill: none;
    stroke: var(--purple);
    stroke-width: 3;
    stroke-linecap: round;
    transition: stroke-dashoffset 0.1s linear;
    filter: drop-shadow(0 0 4px var(--purple-glow));
}

.scroll-arrow {
    position: relative;
    z-index: 1;
    font-size: 20px;
    color: #fff;
    line-height: 1;
}

/* ========== CUSTOM SCROLLBAR ========== */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: #07060d; }
::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, var(--purple), var(--gold-dark));
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover { background: linear-gradient(180deg, #9b4fff, var(--gold)); }

/* ========== SCROLL REVEAL ========== */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* ========== GLITCH EFFECT ========== */
.text-3d {
    position: relative;
}
.text-3d::before,
.text-3d::after {
    content: attr(data-text);
    position: absolute;
    top: 0; left: 0;
    width: 100%;
    height: 100%;
    font-family: var(--font-title);
    font-size: inherit;
    font-weight: inherit;
    letter-spacing: inherit;
    text-transform: inherit;
}
.text-3d::before {
    color: #ff00ff;
    animation: glitch1 3.5s infinite;
    clip-path: polygon(0 0, 100% 0, 100% 35%, 0 35%);
    opacity: 0.7;
}
.text-3d::after {
    color: #00ffff;
    animation: glitch2 3.5s infinite;
    clip-path: polygon(0 65%, 100% 65%, 100% 100%, 0 100%);
    opacity: 0.7;
}
@keyframes glitch1 {
    0%,90%,100% { transform: translate(0); opacity: 0; }
    91%          { transform: translate(-3px, 1px); opacity: 0.7; }
    93%          { transform: translate(3px, -1px); opacity: 0.7; }
    95%          { transform: translate(-2px, 2px); opacity: 0.7; }
    97%          { transform: translate(0); opacity: 0; }
}
@keyframes glitch2 {
    0%,90%,100% { transform: translate(0); opacity: 0; }
    92%          { transform: translate(3px, 2px);  opacity: 0.7; }
    94%          { transform: translate(-3px, -1px); opacity: 0.7; }
    96%          { transform: translate(2px, -2px); opacity: 0.7; }
    98%          { transform: translate(0); opacity: 0; }
}

/* ========== RIPPLE EFFECT ========== */
.ripple-wrap { position: relative; overflow: hidden; }
.ripple-circle {
    position: absolute;
    border-radius: 50%;
    background: rgba(255,255,255,0.25);
    transform: scale(0);
    animation: rippleAnim 0.6s linear;
    pointer-events: none;
}
@keyframes rippleAnim {
    to { transform: scale(4); opacity: 0; }
}

/* ========== NEON GLOW PULSE on widget titles ========== */
.widget-title {
    animation: neonPulse 3s ease-in-out infinite;
}
@keyframes neonPulse {
    0%,100% { text-shadow: 0 0 6px var(--gold-glow); }
    50%      { text-shadow: 0 0 14px var(--gold-glow), 0 0 28px var(--gold-glow); }
}

/* ========== CARD TILT (3D perspective) ========== */
.tilt-card {
    transform-style: preserve-3d;
    transition: transform 0.1s ease;
    will-change: transform;
}

/* ========== GLOW DIVIDERS ========== */
.glow-divider {
    border: none;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--purple), var(--gold), var(--purple), transparent);
    margin: 30px 0;
    box-shadow: 0 0 8px var(--purple-glow);
}
