/* =========================================================================
   PLAYERZONEBD — DESIGN SYSTEM
   Look & feel: night-arena esports HUD. Deep ink backgrounds for "stage"
   moments (splash, auth, wallet, podium), warm amber for action/brand,
   cool teal for money-in / wins, condensed "Rajdhani" for scoreboard-style
   numbers & headings, Lato/Hind Siliguri for reading text.
   ========================================================================= */

/* =========================================================================
   PLAYERZONEBD — DESIGN SYSTEM (Light + Dark themes)
   Toggle via [data-theme="light"] / [data-theme="dark"] on <html>.
   Look & feel: night-arena esports HUD. Deep ink "stage" panels (hero,
   wallet vault, podium) stay dramatic in both themes; everyday surfaces
   (cards, forms, lists) fully adapt between light and dark.
   Amber = brand/action. Teal = money-in / wins. Rajdhani = HUD numerals.
   ========================================================================= */

:root {
    /* --- brand (theme-independent) --- */
    --primary: #FFB300;
    --primary-dark: #E6960A;
    --primary-light: #FFF2D6;
    --on-primary: #17140A;

    --secondary: #00C2A8;
    --secondary-dark: #00A088;

    --success: #2BB673;
    --danger: #E5484D;
    --danger-light: #FDEBEC;
    --live: #FF3B4E;

    --ink: #12141C;
    --ink-soft: #1B1F2A;
    --white: #ffffff;

    --wallet-gradient: linear-gradient(135deg, #1B1035 0%, #3B1F78 55%, #6A3FD8 100%);

    --bkash-color: #E2136E;
    --rocket-color: #8C3494;
    --nagad-color: #F7941D;
    --bkash-dark: #b00e56;
    --rocket-dark: #6a2670;
    --nagad-dark: #c97612;

    --auth-bg-dark: #0B0D14;
    --auth-card-bg: #ffffff;

    --radius-sm: 10px;
    --radius-md: 16px;
    --radius-lg: 22px;
    --ease: cubic-bezier(.22,1,.36,1);
    --fast: .18s;
    --med: .32s;

    /* --- LIGHT THEME (default) --- */
    --bg-color: #F3F4F8;
    --surface: #FFFFFF;
    --surface-alt: #F1F2F7;
    --text-dark: #171923;
    --text-muted: #6B7280;
    --text-faint: #9AA1B1;
    --border-soft: #EBEDF3;
    --skeleton-a: #eceef3;
    --skeleton-b: #f7f8fb;
    --shadow-sm: 0 2px 10px rgba(18,20,28,.06);
    --shadow-md: 0 8px 24px rgba(18,20,28,.10);
    --shadow-lg: 0 18px 45px rgba(18,20,28,.16);
}

html[data-theme="dark"] {
    --bg-color: #0A0C13;
    --surface: #171A26;
    --surface-alt: #1E2231;
    --text-dark: #F1F2F7;
    --text-muted: #A6ACBD;
    --text-faint: #6E7488;
    --border-soft: rgba(255,255,255,.08);
    --skeleton-a: #1c2030;
    --skeleton-b: #242942;
    --shadow-sm: 0 2px 10px rgba(0,0,0,.35);
    --shadow-md: 0 10px 26px rgba(0,0,0,.45);
    --shadow-lg: 0 22px 50px rgba(0,0,0,.55);
    --ink: #1E2140;
    --tint-good-bg: rgba(43,182,115,.14);
    --tint-good-text: #6FE3A8;
    --tint-warn-bg: rgba(255,179,0,.14);
    --tint-warn-text: #FFCB61;
    --tint-bad-bg: rgba(229,72,77,.16);
    --tint-bad-text: #FF8489;
    color-scheme: dark;
}

html[data-theme="light"] {
    color-scheme: light;
    --tint-good-bg: #E7F7EF;
    --tint-good-text: #256B48;
    --tint-warn-bg: #FFF6E5;
    --tint-warn-text: #8A5A00;
    --tint-bad-bg: var(--danger-light);
    --tint-bad-text: #B3261E;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Lato', 'Hind Siliguri', sans-serif;
    -webkit-tap-highlight-color: transparent;
    -webkit-touch-callout: none;
    user-select: none;
}

input, textarea, select {
    user-select: text;
}

.hud, .wg-balance, .mc-stat-value, .rd-podium-prize, .wb-amount, .ws-amount,
.auth-title-large, .wallet-section-title, .category-title, .md-count-badge,
.join-badge, .refer-code-box, h1.num, .rd-main-title {
    font-family: 'Rajdhani', 'Hind Siliguri', sans-serif;
}

html { scroll-behavior: smooth; }

body {
    background-color: var(--bg-color);
    color: var(--text-dark);
    padding-bottom: 90px;
    overflow-x: hidden;
    min-height: 100vh;
    animation: pageFade .35s var(--ease);
    transition: background-color var(--med) var(--ease), color var(--med) var(--ease);
}

@keyframes pageFade {
    from { opacity: 0; }
    to   { opacity: 1; }
}

body.sub-page { }
body.no-tabbar { padding-bottom: 0; }

a { color: inherit; }

/* --- SITE-WIDE FOOTER TEXT --- */
.site-footer-text {
    text-align: center;
    font-size: 11px;
    font-weight: 600;
    color: #9aa0ac;
    letter-spacing: .2px;
    padding: 10px 15px 6px;
}

/* =========================================================================
   SPLASH SCREEN
   ========================================================================= */
#app-splash {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background:
        radial-gradient(circle at 30% 20%, rgba(255,179,0,.10), transparent 55%),
        linear-gradient(180deg, #0c0e16 0%, #05060a 100%);
    z-index: 10000;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: white;
    transition: opacity 0.1s ease-out;
    overflow: hidden;
}

.splash-logo-box {
    width: 120px;
    height: 120px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px;
    margin-bottom: 20px;
    border: 2px solid rgba(255,179,0,.25);
    box-shadow: 0 0 35px rgba(255,179,0,.25);
    z-index: 2;
    animation: splashPop .6s var(--ease);
}

.splash-logo-box img { width: 100%; height: 100%; object-fit: contain; border-radius: 50%; }

@keyframes splashPop {
    from { transform: scale(.6); opacity: 0; }
    to   { transform: scale(1); opacity: 1; }
}

.splash-app-name { font-size: 24px; font-weight: 700; letter-spacing: 1px; margin-bottom: 5px; text-align: center; z-index: 2; }
.splash-version { font-size: 14px; color: #888; margin-bottom: 100px; z-index: 2; }

.splash-bottom-area { position: absolute; bottom: 50px; width: 100%; text-align: center; display: flex; flex-direction: column; align-items: center; z-index: 2; }
.splash-welcome { font-size: 14px; font-weight: 300; letter-spacing: 1px; margin-bottom: 10px; opacity: 0.8; }
.splash-line { width: 150px; height: 3px; background: var(--primary); border-radius: 2px; margin-bottom: 15px; animation: lineExpand 1.1s ease-in-out infinite alternate; }
.splash-dots-container { display: flex; gap: 5px; }
.splash-dot { width: 8px; height: 8px; background: var(--primary); border-radius: 50%; animation: dotBounce 1s infinite ease-in-out both; }
.splash-dot:nth-child(1) { animation-delay: -0.32s; }
.splash-dot:nth-child(2) { animation-delay: -0.16s; }

.particle { position: absolute; width: 4px; height: 4px; background: rgba(255,179,0,.55); border-radius: 50%; animation: floatUp linear infinite; bottom: -10px; z-index: 1; }

@keyframes floatUp { 0% { transform: translateY(0) scale(1); opacity: 0; } 20% { opacity: .8; } 100% { transform: translateY(-100vh) scale(.5); opacity: 0; } }
@keyframes lineExpand { 0% { width: 50px; opacity: .5; } 100% { width: 150px; opacity: 1; } }
@keyframes dotBounce { 0%, 80%, 100% { transform: scale(0); opacity: .3; } 40% { transform: scale(1); opacity: 1; } }

/* =========================================================================
   GLOBAL LOADER
   ========================================================================= */
#global-loader { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(11,13,20,.55); backdrop-filter: blur(2px); z-index: 9999; display: none; justify-content: center; align-items: center; }
#global-loader.active { display: flex; }
.spinner { width: 46px; height: 46px; border: 4px solid rgba(255,179,0,.25); border-top: 4px solid var(--primary); border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* skeleton shimmer for images while loading */
img { background-color: var(--skeleton-a); }
img.lazy-loading { animation: shimmer 1.3s ease-in-out infinite; background: linear-gradient(100deg, var(--skeleton-a) 30%, var(--skeleton-b) 50%, var(--skeleton-a) 70%); background-size: 200% 100%; }
img.lazy-loaded { animation: imgReveal .4s var(--ease); }
@keyframes shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
@keyframes imgReveal { from { opacity: 0; filter: blur(6px); } to { opacity: 1; filter: blur(0); } }

/* =========================================================================
   AUTH PAGES (login.php / signup.php)
   ========================================================================= */
#login-container, #register-container {
    width: 100%;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background:
        radial-gradient(circle at top left, #2b1a00, #111),
        linear-gradient(135deg, #000, #14151a, #000);
    overflow: hidden;
    position: relative;
    padding: 20px;
}

#login-container::before, #register-container::before {
    content: ''; position: absolute; width: 350px; height: 350px; background: var(--primary);
    border-radius: 50%; filter: blur(140px); opacity: .18; top: -120px; left: -120px;
    animation: floatGlow 8s infinite alternate;
}
#login-container::after, #register-container::after {
    content: ''; position: absolute; width: 300px; height: 300px; background: var(--secondary);
    border-radius: 50%; filter: blur(140px); opacity: .13; bottom: -120px; right: -120px;
    animation: floatGlow2 10s infinite alternate;
}

.login-card, .register-card {
    width: 100%; max-width: 430px;
    background: rgba(18,18,22,.8);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255,179,0,.22);
    border-radius: 28px;
    padding: 40px 28px;
    box-shadow: 0 0 30px rgba(255,179,0,.12), 0 25px 60px rgba(0,0,0,.85);
    position: relative;
    overflow: hidden;
    animation: cardShow .55s var(--ease);
    max-height: 92vh;
    overflow-y: auto;
}

.login-card::before, .register-card::before {
    content: ''; position: absolute; width: 100%; height: 3px; left: 0; top: 0;
    background: linear-gradient(90deg, transparent, var(--primary), transparent);
}

.game-logo { width: 90px; height: 90px; margin: auto; margin-bottom: 20px; border-radius: 50%; border: 3px solid var(--primary); overflow: hidden; box-shadow: 0 0 25px rgba(255,179,0,.45); }
.game-logo img { width: 100%; height: 100%; object-fit: cover; }

.auth-title-large { color: #fff; font-size: 32px; font-weight: 700; text-align: center; letter-spacing: .5px; }
.auth-title-large span { color: var(--primary); }
.auth-subtitle { color: #aaa; text-align: center; margin-top: 10px; margin-bottom: 32px; font-size: 14px; }

.auth-input-group { position: relative; margin-bottom: 16px; }
.auth-input-field {
    width: 100%; height: 56px; background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.09);
    border-radius: 14px; padding: 0 20px; color: #fff; font-size: 15px; outline: none; transition: var(--fast);
}
.auth-input-field::placeholder { color: #888; }
.auth-input-field:focus { border-color: var(--primary); background: rgba(255,179,0,.07); box-shadow: 0 0 0 4px rgba(255,179,0,.10); transform: translateY(-1px); }
.auth-input-field[type="number"]::-webkit-outer-spin-button, .auth-input-field[type="number"]::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.auth-input-field[type="number"] { -moz-appearance: textfield; }

.auth-password-eye { position: absolute; right: 20px; top: 50%; transform: translateY(-50%); color: #999; cursor: pointer; }
.auth-checkbox-row { display: flex; gap: 10px; align-items: flex-start; color: #aaa; font-size: 13px; margin-bottom: 24px; }
.auth-checkbox-row input { accent-color: var(--primary); margin-top: 2px; flex-shrink: 0; }

.auth-black-btn {
    width: 100%; height: 56px; border: none; border-radius: 14px;
    background: linear-gradient(90deg, var(--primary-dark), var(--primary));
    color: var(--on-primary); font-size: 17px; font-weight: 700; cursor: pointer;
    transition: var(--fast); box-shadow: 0 10px 28px rgba(255,179,0,.28); letter-spacing: .3px;
    position: relative; overflow: hidden;
}
.auth-black-btn:hover { transform: translateY(-3px); box-shadow: 0 15px 34px rgba(255,179,0,.4); }
.auth-black-btn:active { transform: translateY(-1px) scale(.98); }

.auth-forget-link { text-align: center; color: #bbb; margin-top: 20px; cursor: pointer; transition: var(--fast); }
.auth-forget-link:hover { color: var(--primary); }
.auth-footer-link { text-align: center; color: #999; margin-top: 22px; }
.auth-footer-link span { color: var(--primary); font-weight: 700; cursor: pointer; }

@keyframes cardShow { from { opacity: 0; transform: translateY(36px) scale(.96); } to { opacity: 1; transform: translateY(0) scale(1); } }
@keyframes floatGlow { from { transform: translate(-40px,-20px); } to { transform: translate(40px,40px); } }
@keyframes floatGlow2 { from { transform: translate(40px,20px); } to { transform: translate(-40px,-40px); } }

/* --- AUTH SOCIAL LINKS --- */
.auth-social-links { display: flex; justify-content: center; gap: 12px; margin-top: 24px; padding-top: 18px; border-top: 1px solid rgba(255,255,255,0.12); }
.auth-social-btn { display: flex; align-items: center; justify-content: center; width: 42px; height: 42px; border-radius: 50%; color: #fff; font-size: 18px; text-decoration: none; transition: transform var(--fast), box-shadow var(--fast); box-shadow: 0 2px 8px rgba(0,0,0,.3); }
.auth-social-btn:hover { transform: scale(1.12) translateY(-2px); box-shadow: 0 6px 16px rgba(0,0,0,.4); }
.auth-social-btn.whatsapp { background: #25D366; }
.auth-social-btn.facebook { background: #1877F2; }
.auth-social-btn.youtube { background: #FF0000; }
.auth-social-btn.tiktok { background: #000000; }
.auth-social-btn.instagram { background: linear-gradient(45deg,#f09433,#e6683c,#dc2743,#cc2366,#bc1888); }

/* =========================================================================
   LAYOUT
   ========================================================================= */
.page-wrap { background: var(--bg-color); min-height: 100vh; }

/* =========================================================================
   HOME PAGE — hero banner + categories
   ========================================================================= */
.home-content-wrapper { padding: 16px; }

.hero-banner { border-radius: 0; overflow: hidden; background: var(--ink); margin-bottom: 0; position: relative; }

.slider-container { width: 100%; max-width: var(--banner-max-w, 500px); height: var(--banner-h, 500px); margin: 0 auto; position: relative; overflow: hidden; background: var(--ink-soft); }
.slider-wrapper { position: absolute; top: 0; left: 0; width: 100%; height: 100%; display: flex; transition: transform .5s var(--ease); }
.slide { min-width: 100%; height: 100%; flex-shrink: 0; cursor: pointer; }
.slide img { width: 100%; height: 100%; object-fit: cover; display: block; }

.slider-dots { display: flex; justify-content: center; gap: 6px; padding: 10px 0; background: var(--ink); position: relative; z-index: 10; }
.dot { width: 7px; height: 7px; background: rgba(255,255,255,.25); border-radius: 50%; transition: all var(--med); }
.dot.active { background: var(--primary); width: 20px; border-radius: 10px; }

.marquee-container { background: var(--ink-soft); padding: 9px 5px; font-weight: 700; font-size: 15px; width: 100%; overflow: hidden; position: relative; white-space: nowrap; display: flex; align-items: center; border-top: 1px solid rgba(255,255,255,.06); }
#dynamic-notice { color: var(--primary); font-weight: 700; display: inline-block; padding-left: 100%; animation: marqueeScroll 22s linear infinite; }
@keyframes marqueeScroll { 0% { transform: translate(0,0); } 100% { transform: translate(-100%,0); } }

.category-title { font-weight: 700; font-size: 20px; margin: 18px 0 16px; letter-spacing: .3px; text-align: left; color: var(--text-dark); }

.category-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; padding: 0 3px; }

.cat-card-new {
    background: var(--surface); border-radius: var(--radius-md); overflow: hidden; cursor: pointer;
    display: flex; flex-direction: column; box-shadow: var(--shadow-sm); border: 1px solid var(--border-soft);
    transition: transform var(--fast) var(--ease), box-shadow var(--fast) var(--ease);
    opacity: 0; transform: translateY(10px); animation: cardIn .45s var(--ease) forwards;
}
.category-grid .cat-card-new:nth-child(1) { animation-delay: .02s; }
.category-grid .cat-card-new:nth-child(2) { animation-delay: .08s; }
.category-grid .cat-card-new:nth-child(3) { animation-delay: .14s; }
.category-grid .cat-card-new:nth-child(4) { animation-delay: .2s; }
.category-grid .cat-card-new:nth-child(5) { animation-delay: .26s; }
.category-grid .cat-card-new:nth-child(6) { animation-delay: .32s; }
@keyframes cardIn { to { opacity: 1; transform: translateY(0); } }

.cat-card-new:active { transform: scale(.97); }

.cat-card-img { width: 100%; height: 148px; object-fit: cover; background: var(--ink-soft); }
.cat-card-info { padding: 12px; background: var(--surface); flex: 1; display: flex; flex-direction: column; justify-content: center; }
.cat-card-title { font-weight: 800; font-size: 15px; color: var(--text-dark); margin-bottom: 3px; line-height: 1.2; }
.cat-card-count { font-size: 11.5px; color: var(--secondary-dark); font-weight: 700; display: flex; align-items: center; gap: 5px; transition: var(--fast); }
.cat-card-count::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--secondary); box-shadow: 0 0 0 3px rgba(0,194,168,.18); flex-shrink: 0; }
.cat-card-count.has-matches::before { animation: matchDotPulse 1.6s ease-in-out infinite; }
.cat-card-count.no-matches { color: var(--text-faint); }
.cat-card-count.no-matches::before { background: var(--text-faint); box-shadow: 0 0 0 3px rgba(120,120,130,.14); animation: none; }
@keyframes matchDotPulse { 0%,100% { transform: scale(1); box-shadow: 0 0 0 3px rgba(0,194,168,.18); } 50% { transform: scale(1.35); box-shadow: 0 0 0 5px rgba(0,194,168,.28); } }

/* =========================================================================
   PROFILE HEADER
   ========================================================================= */
.profile-header-bg { background: linear-gradient(135deg, var(--ink) 0%, #2b1f4a 100%); padding: 42px 20px 32px; text-align: center; color: white; margin-bottom: 20px; border-radius: 0 0 26px 26px; position: relative; overflow: hidden; }
.profile-header-bg::before { content: ''; position: absolute; inset: 0; background: radial-gradient(circle at 80% -10%, rgba(255,179,0,.25), transparent 55%); }
.profile-avatar-box { position: relative; z-index: 1; }
.profile-avatar-box img { width: 82px; height: 82px; border-radius: 50%; object-fit: cover; border: 3px solid var(--primary); box-shadow: 0 0 0 4px rgba(255,179,0,.18); }
.profile-header-bg h3, .profile-header-bg p, .profile-header-bg > div { position: relative; z-index: 1; }

/* =========================================================================
   EDIT PROFILE
   ========================================================================= */
.ep-container { padding: 20px; }
.ep-avatar-section { text-align: center; margin-bottom: 25px; }
.ep-avatar-ring { width: 100px; height: 100px; border-radius: 50%; border: 4px solid var(--primary); padding: 5px; margin: 0 auto 10px; display: flex; align-items: center; justify-content: center; box-shadow: 0 0 0 5px rgba(255,179,0,.12); }
.ep-avatar-icon { font-size: 50px; color: var(--primary); }
.ep-username { font-size: 20px; font-weight: 800; color: var(--text-dark); }
.ep-email { font-size: 13px; color: var(--text-muted); }

.ep-card { background: var(--surface); border-radius: var(--radius-md); padding: 20px; margin-bottom: 18px; box-shadow: var(--shadow-sm); border: 1px solid var(--border-soft); }
.ep-card-title { font-size: 16px; font-weight: 800; color: var(--text-dark); margin-bottom: 15px; display: flex; align-items: center; gap: 8px; }
.ep-card-title i { color: var(--primary); }

.ep-input-group { position: relative; margin-bottom: 14px; }
.ep-input-icon { position: absolute; left: 15px; top: 50%; transform: translateY(-50%); color: var(--text-faint); font-size: 17px; }
.ep-input { width: 100%; padding: 13px 14px 13px 45px; border: 1.5px solid var(--border-soft); border-radius: 12px; font-size: 14px; outline: none; transition: var(--fast); color: var(--text-dark); }
.ep-input:focus { border-color: var(--primary); box-shadow: 0 0 0 4px rgba(255,179,0,.12); }
.ep-btn { width: 100%; padding: 15px; background: var(--ink); color: white; font-weight: 800; border: none; border-radius: 12px; cursor: pointer; transition: var(--fast); }
.ep-btn:hover { background: #22263a; transform: translateY(-1px); }
.ep-btn:active { transform: translateY(0) scale(.98); }

/* =========================================================================
   MATCH CARD  (ticket-stub styling — the site's signature card)
   ========================================================================= */
.match-card {
    background: var(--surface);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    margin-bottom: 18px;
    overflow: hidden;
    border: 1px solid var(--border-soft);
    cursor: pointer;
    transition: transform var(--fast) var(--ease), box-shadow var(--fast) var(--ease);
    opacity: 0; transform: translateY(12px);
    animation: cardIn .5s var(--ease) forwards;
}
.match-card:nth-child(1) { animation-delay: .02s; }
.match-card:nth-child(2) { animation-delay: .08s; }
.match-card:nth-child(3) { animation-delay: .14s; }
.match-card:nth-child(4) { animation-delay: .2s; }
.match-card:nth-child(5) { animation-delay: .26s; }
.match-card:nth-child(n+6) { animation-delay: .3s; }
.match-card:hover { box-shadow: var(--shadow-md); }
.match-card:active { transform: scale(.99); }

.mc-header { display: flex; padding: 12px; gap: 12px; align-items: flex-start; }
.mc-thumb { width: 108px; height: 108px; border-radius: 12px; object-fit: cover; }
.mc-header-info { flex: 1; min-width: 0; }
.mc-title-row { font-size: 16px; font-weight: 800; color: var(--text-dark); margin-bottom: 3px; line-height: 1.25; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mc-date-row { font-size: 13px; color: var(--danger); font-weight: 700; }
.mc-date-row.muted { color: var(--text-muted); }

.mc-stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); text-align: center; padding: 6px 12px 14px; gap: 10px 0; border-top: 1px dashed var(--border-soft); margin-top: 4px; position: relative; }
.mc-stats-grid::before, .mc-stats-grid::after {
    content: ''; position: absolute; top: -6px; width: 12px; height: 12px; background: var(--bg-color); border-radius: 50%;
}
.mc-stats-grid::before { left: -6px; }
.mc-stats-grid::after { right: -6px; }
.mc-stat-box { display: flex; flex-direction: column; align-items: center; }
.mc-stat-label { font-size: 10px; color: var(--text-faint); font-weight: 700; text-transform: uppercase; letter-spacing: .3px; }
.mc-stat-value { font-size: 17px; font-weight: 700; color: var(--text-dark); margin-top: 1px; }

.mc-join-row { display: flex; justify-content: space-between; align-items: flex-end; padding: 0 12px 14px; }
.mc-progress-wrapper { flex: 1; margin-right: 15px; }
.mc-prog-bar { height: 7px; background: var(--border-soft); border-radius: 4px; overflow: hidden; margin-bottom: 5px; }
.mc-prog-fill { height: 100%; background: linear-gradient(90deg, var(--secondary), var(--secondary-dark)); border-radius: 4px; width: 0; transition: width 1s var(--ease); position: relative; overflow: hidden; }
.mc-prog-fill::after { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, transparent, rgba(255,255,255,.5), transparent); animation: progShine 2.2s ease-in-out infinite; }
@keyframes progShine { 0% { transform: translateX(-100%); } 100% { transform: translateX(100%); } }
.mc-spots-info { display: flex; justify-content: space-between; font-size: 11px; color: var(--text-muted); font-weight: 700; }

.btn-join-main {
    border: none; color: var(--on-primary); background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    padding: 6px 26px; border-radius: 10px; font-size: 14px; font-weight: 800; cursor: pointer; height: 34px;
    display: flex; align-items: center; justify-content: center; transition: var(--fast); box-shadow: 0 6px 14px rgba(255,179,0,.3);
}
.btn-join-main:hover { transform: translateY(-2px); box-shadow: 0 10px 18px rgba(255,179,0,.4); }
.btn-join-main:active { transform: translateY(0) scale(.96); }
.btn-join-main.disabled { background: var(--surface-alt); color: var(--text-faint); box-shadow: none; pointer-events: none; }

.mc-details-row { display: flex; justify-content: space-between; padding: 0 12px 14px; gap: 10px; align-items: center; }
.btn-details {
    border: 1.5px solid var(--text-dark); color: var(--text-dark); background: transparent; padding: 9px 10px;
    border-radius: 10px; font-size: 13px; font-weight: 700; display: flex; align-items: center; gap: 7px;
    cursor: pointer; flex: 1; justify-content: center; transition: background var(--fast), color var(--fast), transform var(--fast), box-shadow var(--fast);
}
.btn-details i { transition: transform var(--med) var(--ease); }
.btn-details:hover { background: var(--text-dark); color: var(--surface); box-shadow: 0 6px 16px rgba(0,0,0,.18); transform: translateY(-1px); }
.btn-details:hover i { transform: translateX(-2px) scale(1.1); }
.btn-details:active { transform: translateY(0) scale(.96); }

/* ---- redesigned "Starts In" countdown strip (segmented HUD chips) ---- */
.mc-footer-timer { background: var(--ink); color: white; text-align: center; padding: 8px 10px; letter-spacing: .2px; }
.mc-footer-timer .fa-circle { color: var(--live); animation: livePulse 1.1s infinite; }
@keyframes livePulse { 0%,100% { opacity: 1; transform: scale(1); } 50% { opacity: .35; transform: scale(1.4); } }
.cd-inner { display: flex; align-items: center; justify-content: center; gap: 8px; }
.cd-clock { color: var(--primary); font-size: 13px; animation: cdClockTick 2s ease-in-out infinite; }
@keyframes cdClockTick { 0%,100% { transform: rotate(0deg); } 25% { transform: rotate(-12deg); } 75% { transform: rotate(12deg); } }
.cd-units { display: flex; align-items: center; gap: 5px; }
.cd-unit { display: flex; flex-direction: column; align-items: center; min-width: 26px; }
.cd-num {
    font-family: 'Rajdhani', sans-serif; font-size: 15px; font-weight: 700; line-height: 1; color: #fff;
    background: rgba(255,255,255,.08); border-radius: 6px; padding: 3px 5px; min-width: 20px; display: inline-block;
}
.cd-num.cd-pulse { animation: cdNumPulse .4s var(--ease); }
@keyframes cdNumPulse { 0% { transform: scale(1.3); color: var(--primary); } 100% { transform: scale(1); color: #fff; } }
.cd-lbl { font-size: 8.5px; font-weight: 700; text-transform: uppercase; opacity: .55; margin-top: 2px; letter-spacing: .3px; }
.cd-colon { font-weight: 700; opacity: .4; font-size: 13px; }
.cd-started-inner { display: flex; align-items: center; justify-content: center; gap: 7px; font-weight: 800; font-size: 13px; animation: menuItemIn .4s var(--ease); }
.cd-started-inner i { color: var(--secondary); animation: badgePop 1s ease-in-out infinite; }

/* --- MATCH TABS --- */
.match-tabs-container { display: flex; justify-content: space-between; background: var(--surface); padding: 8px; box-shadow: var(--shadow-sm); position: sticky; top: 55px; z-index: 90; gap: 6px; border-radius: 0 0 14px 14px; }
.m-tab { flex: 1; text-align: center; padding: 10px 0; font-weight: 700; font-size: 13px; color: var(--text-muted); cursor: pointer; border-radius: 10px; transition: var(--fast); }
.m-tab.active { color: var(--on-primary); font-weight: 800; background: var(--primary); }

/* =========================================================================
   MATCH DETAILS / JOIN
   ========================================================================= */
.md-info-card {
    background:
        radial-gradient(circle at 15% -20%, rgba(255,179,0,.20), transparent 45%),
        radial-gradient(circle at 100% 10%, rgba(0,194,168,.12), transparent 40%),
        var(--ink);
    color: #fff; padding: 22px 20px; text-align: center; border-radius: 0 0 20px 20px;
}
.md-title { font-size: 19px; font-weight: 800; margin-bottom: 5px; }
.md-time { font-size: 13px; color: rgba(255,255,255,.65); margin-bottom: 10px; }

.md-table-container { padding: 16px; background: var(--surface); margin: 12px; border-radius: var(--radius-md); box-shadow: var(--shadow-sm); }
.md-table-header { display: flex; justify-content: space-between; align-items: center; font-weight: 800; padding-bottom: 10px; border-bottom: 2px solid var(--primary); margin-bottom: 10px; color: var(--text-dark); }
.md-count-badge { background: var(--primary-light); color: var(--primary-dark); font-size: 12px; font-weight: 800; padding: 4px 12px; border-radius: 20px; }

.md-players-list { display: flex; flex-direction: column; gap: 8px; }
.md-player-row { display: flex; align-items: center; gap: 10px; padding: 9px 10px; background: var(--surface-alt); border: 1px solid var(--border-soft); border-radius: 12px; opacity: 0; transform: translateY(8px); animation: mdRowIn .35s ease forwards; transition: background .15s, border-color .15s; }
.md-player-row.is-me { background: var(--primary-light); border-color: #ffdf9e; }
@keyframes mdRowIn { to { opacity: 1; transform: translateY(0); } }
.md-player-slot { flex: 0 0 auto; width: 20px; height: 20px; border-radius: 50%; background: var(--ink); color: #fff; font-size: 9px; font-weight: 800; display: flex; align-items: center; justify-content: center; }
.md-player-avatar { flex: 0 0 auto; width: 30px; height: 30px; border-radius: 50%; overflow: hidden; border: 1.5px solid #fff; box-shadow: 0 0 0 1.5px var(--primary-light); background: #e0e2ec; position: relative; }
.md-player-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.md-player-avatar-fallback { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 12px; color: #fff; background: linear-gradient(135deg, var(--primary), var(--primary-dark)); }
.md-player-info { flex: 1; min-width: 0; }
.md-player-name { font-size: 13px; font-weight: 800; color: var(--text-dark); display: flex; align-items: center; gap: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.md-me-badge { background: var(--success); color: #fff; font-size: 9px; font-weight: 800; padding: 2px 7px; border-radius: 10px; text-transform: uppercase; letter-spacing: .3px; flex: 0 0 auto; }
.md-player-meta { display: flex; align-items: center; gap: 10px; font-size: 10.5px; color: var(--text-muted); font-weight: 600; margin-top: 1px; flex-wrap: wrap; }
.md-player-meta i { margin-right: 3px; color: var(--primary-dark); }
.md-player-ign { color: var(--text-faint); }

.md-locked-list { text-align: center; padding: 30px 15px; color: #999; animation: mdRowIn .35s ease forwards; }
.md-locked-list i { font-size: 26px; margin-bottom: 10px; display: block; color: var(--text-faint); }
.md-locked-list p { font-size: 13px; font-weight: 600; max-width: 260px; margin: 0 auto; }

/* =========================================================================
   JOIN PAGE
   ========================================================================= */
.join-card { background: var(--surface); margin: 15px; border-radius: var(--radius-md); padding: 22px; box-shadow: var(--shadow-md); }
.join-input-field { width: 100%; height: 54px; background: var(--bg-color); border: 1.5px solid var(--border-soft); border-radius: 12px; padding: 0 16px; color: #111; font-size: 15px; font-weight: 600; outline: none; transition: var(--fast); }
.join-input-field::placeholder { color: #999; }
.join-input-field:focus { border-color: var(--primary); background: var(--surface); box-shadow: 0 0 0 4px rgba(255,179,0,.12); }
.join-match-title { font-size: 18px; font-weight: 800; color: var(--text-dark); margin-bottom: 5px; }
.join-meta { font-size: 13px; color: var(--text-muted); margin-bottom: 15px; }
.join-info-row { display: flex; justify-content: space-between; margin-bottom: 10px; font-size: 14px; font-weight: 700; color: var(--text-dark); }
.join-warning { border: 1.5px dashed var(--primary); color: var(--primary-dark); font-size: 13px; font-weight: 700; text-align: center; padding: 10px; border-radius: 10px; margin: 15px 0; background: var(--primary-light); }
.join-badge-container { text-align: center; margin-bottom: 20px; }
.join-badge { background: var(--ink); color: var(--primary); padding: 6px 22px; border-radius: 20px; font-weight: 800; font-size: 14px; display: inline-block; letter-spacing: .3px; }
.join-inputs { margin-bottom: 20px; display: flex; flex-direction: column; gap: 12px; }

.join-btn-full { position: fixed; bottom: 85px; left: 5%; width: 90%; background: linear-gradient(135deg, var(--primary), var(--primary-dark)); color: var(--on-primary); padding: 16px; border-radius: 16px; border: none; font-size: 17px; font-weight: 800; cursor: pointer; box-shadow: 0 10px 24px rgba(255,179,0,.4); z-index: 100; transition: var(--fast); }
.join-btn-full:hover { transform: translateY(-2px); }
.join-btn-full:active { transform: translateY(0) scale(.97); }

/* =========================================================================
   RESULT DETAILS
   ========================================================================= */
.rd-card { background: var(--surface); margin: 15px; border-radius: var(--radius-md); overflow: hidden; box-shadow: var(--shadow-sm); }
.rd-title-box { padding: 18px; text-align: center; border-bottom: 1px solid var(--border-soft); }
.rd-main-title { font-weight: 800; font-size: 18px; margin-bottom: 4px; }
.rd-sub-title { font-size: 12px; color: var(--text-muted); }

.rd-stats-row { display: flex; justify-content: space-around; padding: 16px 0; text-align: center; }
.rd-stat-item div:first-child { font-size: 11px; color: var(--text-faint); font-weight: 700; margin-bottom: 5px; text-transform: uppercase; }
.rd-stat-item div:last-child { font-size: 16px; font-weight: 800; color: var(--text-dark); }

.rd-header-blue { background: var(--ink); color: white; text-align: center; font-weight: 800; font-size: 14px; padding: 10px; letter-spacing: .3px; }

.rd-table-head { display: flex; background: var(--surface-alt); color: var(--text-muted); padding: 9px 12px; font-size: 11.5px; font-weight: 800; text-transform: uppercase; }
.rd-row { display: flex; padding: 11px 12px; background: var(--surface); border-bottom: 1px solid var(--border-soft); font-size: 13px; align-items: center; color: var(--text-dark); }
.rd-row:nth-child(odd) { background: var(--surface-alt); }

.col-hash { width: 10%; text-align: center; font-weight: 800; color: var(--text-faint); }
.col-name { width: 50%; font-weight: 700; color: var(--text-dark); }
.col-kill { width: 20%; text-align: center; }
.col-win { width: 20%; text-align: right; font-weight: 800; color: var(--secondary-dark); }

/* --- RESULT PODIUM --- */
.rd-podium { display: flex; align-items: flex-end; justify-content: center; gap: 10px; padding: 28px 15px 12px; background: linear-gradient(180deg, var(--ink), #05060a); position: relative; overflow: hidden; }
.rd-podium::before { content: ''; position: absolute; inset: 0; background: radial-gradient(circle at 50% 0%, rgba(255,179,0,.16), transparent 60%); }
.rd-podium-item { flex: 1; max-width: 110px; text-align: center; color: #fff; position: relative; z-index: 1; opacity: 0; transform: translateY(14px); animation: mdRowIn .5s var(--ease) forwards; }
.rd-podium-item.second { animation-delay: .05s; }
.rd-podium-item.first { animation-delay: .15s; }
.rd-podium-item.third { animation-delay: .25s; }
.rd-podium-avatar { width: 56px; height: 56px; border-radius: 50%; background: var(--white); color: var(--ink); display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 20px; margin: 0 auto 8px; border: 3px solid rgba(255,255,255,.5); }
.rd-podium-item.first .rd-podium-avatar { width: 72px; height: 72px; font-size: 26px; border-color: var(--primary); box-shadow: 0 0 24px rgba(255,179,0,.4); }
.rd-podium-name { font-size: 12px; font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rd-podium-prize { font-size: 14px; font-weight: 800; color: var(--primary); margin-top: 2px; }
.rd-podium-bar { margin-top: 10px; border-radius: 10px 10px 0 0; background: rgba(255,255,255,.12); display: flex; align-items: flex-start; justify-content: center; padding-top: 6px; font-weight: 800; }
.rd-podium-item.first .rd-podium-bar { height: 70px; background: linear-gradient(180deg, var(--primary), var(--primary-dark)); color: var(--on-primary); }
.rd-podium-item.second .rd-podium-bar { height: 50px; background: linear-gradient(180deg, #CFD8DC, #90A4AE); color: #000; }
.rd-podium-item.third .rd-podium-bar { height: 36px; background: linear-gradient(180deg, #D7A16B, #A9714B); color: #000; }

/* =========================================================================
   WALLET
   ========================================================================= */
.wallet-redesign-container {
    background:
        radial-gradient(circle at 20% 0%, rgba(255,179,0,.14), transparent 40%),
        radial-gradient(circle at 100% 15%, rgba(106,63,216,.28), transparent 45%),
        var(--ink);
    background-attachment: fixed;
    min-height: 100vh; color: white; padding-bottom: 50px;
}

.wallet-gradient-card {
    background: var(--wallet-gradient); margin: 15px; border-radius: var(--radius-lg); padding: 22px; position: relative;
    color: white; box-shadow: 0 15px 35px rgba(59,31,120,.4); border: 1px solid rgba(255,255,255,.1); overflow: hidden;
}
.wallet-gradient-card::after { content: ''; position: absolute; top: -40%; left: -20%; width: 60%; height: 180%; background: linear-gradient(115deg, transparent, rgba(255,255,255,.12), transparent); animation: walletSheen 4.5s ease-in-out infinite; }
@keyframes walletSheen { 0% { transform: translateX(-120%) rotate(8deg); } 60%,100% { transform: translateX(220%) rotate(8deg); } }
.wg-header { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 15px; margin-bottom: 30px; position: relative; z-index: 1; }
.wg-header i { color: var(--primary); font-size: 19px; }
.wg-wallet-text { color: var(--primary); margin-left: 5px; font-weight: 800; letter-spacing: .5px; }
.wg-label { font-size: 13px; opacity: .85; font-weight: 500; color: #E7DBFF; position: relative; z-index: 1; }
.wg-balance { font-size: 40px; font-weight: 700; margin-top: 4px; letter-spacing: .5px; display: flex; align-items: center; gap: 5px; position: relative; z-index: 1; }
.wg-footer { position: absolute; bottom: 15px; right: 20px; font-size: 11px; font-weight: 800; letter-spacing: 1.5px; opacity: .6; z-index: 1; }

.wallet-stats-white-card { background: var(--surface); margin: 0 15px; border-radius: var(--radius-lg); padding: 20px 10px; display: flex; justify-content: space-around; color: var(--text-dark); box-shadow: var(--shadow-md); }
.ws-item { text-align: center; flex: 1; }
.ws-item:first-child { border-right: 1px solid var(--border-soft); }
.ws-icon { font-size: 22px; margin-bottom: 8px; }
.ws-label { font-size: 11.5px; font-weight: 800; color: var(--text-muted); letter-spacing: .3px; margin-bottom: 4px; }
.ws-amount { font-size: 22px; font-weight: 700; color: var(--text-dark); }

.wallet-action-row { display: flex; gap: 14px; padding: 20px 15px; }
.wa-btn { flex: 1; padding: 15px; border-radius: 14px; border: none; color: white; font-weight: 800; font-size: 15px; display: flex; align-items: center; justify-content: center; gap: 8px; cursor: pointer; box-shadow: var(--shadow-md); transition: var(--fast); }
.wa-btn:hover { transform: translateY(-2px); }
.wa-btn:active { transform: translateY(0) scale(.97); }
.wa-btn.add { background: linear-gradient(135deg, #6A3FD8, #4B2AAE); }
.wa-btn.withdraw { background: linear-gradient(135deg, var(--secondary), var(--secondary-dark)); }

.wallet-section-title { padding: 6px 20px 0; font-size: 17px; font-weight: 700; color: white; margin-bottom: 14px; }
.quick-action-card { background: var(--surface); margin: 0 15px 18px; border-radius: var(--radius-md); padding: 15px 18px; display: flex; align-items: center; justify-content: space-between; color: var(--text-dark); transition: var(--fast); box-shadow: var(--shadow-sm); }
.quick-action-card:active { transform: scale(.98); }
.qa-info { display: flex; align-items: center; gap: 14px; }
.qa-icon { width: 42px; height: 42px; background: var(--primary-light); color: var(--primary-dark); border-radius: 12px; display: flex; align-items: center; justify-content: center; font-size: 18px; flex-shrink: 0; }
.qa-text div:first-child { font-weight: 800; font-size: 14.5px; }
.qa-text div:last-child { font-size: 12px; color: var(--text-muted); margin-top: 2px; }

.learn-list { padding: 0 15px 30px; display: flex; flex-direction: column; gap: 12px; }
.learn-item { background: var(--surface); border-radius: var(--radius-md); padding: 14px 18px; display: flex; align-items: center; justify-content: space-between; color: var(--text-dark); cursor: pointer; transition: var(--fast); box-shadow: var(--shadow-sm); }
.learn-item:active { transform: scale(.98); }
.li-icon { width: 40px; height: 40px; display: flex; align-items: center; justify-content: center; font-size: 22px; margin-right: 12px; color: var(--primary-dark); flex-shrink: 0; }

/* =========================================================================
   MONEY FLOW — Add Money / Withdraw / Forms (shared card + form kit)
   ========================================================================= */
.pay-hero { background: linear-gradient(135deg, var(--ink), #241a3d); border-radius: var(--radius-md); padding: 20px; margin-bottom: 18px; text-align: center; color: white; }
.pay-hero-title { color: var(--primary); font-weight: 800; font-size: 16px; }
.pay-hero-sub { color: #b9b9c9; font-size: 13px; margin-top: 5px; }

.pay-tabs { display: flex; gap: 8px; margin-bottom: 18px; }
.pay-tab-btn { flex: 1; padding: 12px; background: var(--surface-alt); border: none; border-radius: 12px; font-weight: 700; color: var(--text-muted); cursor: pointer; font-size: 14px; transition: var(--fast); }
.pay-tab-btn.active { background: linear-gradient(135deg, var(--primary), var(--primary-dark)); color: var(--on-primary); box-shadow: 0 6px 14px rgba(255,179,0,.3); }

.pay-methods-card { background: var(--surface); border-radius: var(--radius-md); padding: 16px; margin-bottom: 16px; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; gap: 10px; }
.pay-methods-card .pm-row { display: flex; justify-content: space-between; align-items: center; padding-bottom: 8px; border-bottom: 1px dashed var(--border-soft); }
.pay-methods-card .pm-row:last-child { border-bottom: none; padding-bottom: 0; }
.pm-instruction { font-size: 11px; color: var(--text-faint); }

.pay-card { background: var(--surface); border-radius: var(--radius-md); padding: 20px; box-shadow: var(--shadow-sm); }
.form-label { font-weight: 800; font-size: 13.5px; color: var(--text-dark); display: block; margin-bottom: 9px; }
.form-select, .form-input {
    width: 100%; padding: 13px 14px; border: 1.5px solid var(--border-soft); border-radius: 12px; font-size: 15px;
    outline: none; margin-bottom: 16px; box-sizing: border-box; color: var(--text-dark); transition: var(--fast); background: var(--surface);
}
.form-select:focus, .form-input:focus { border-color: var(--primary); box-shadow: 0 0 0 4px rgba(255,179,0,.12); }
.form-input.amount { font-size: 21px; font-weight: 800; }

.quick-amounts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 20px; }
.quick-amount-btn { background: var(--surface); border: 1.5px solid var(--border-soft); border-radius: 12px; padding: 12px; font-weight: 800; font-size: 15px; color: var(--text-dark); cursor: pointer; transition: var(--fast); }
.quick-amount-btn:hover { border-color: var(--primary); color: var(--primary-dark); }
.quick-amount-btn:active { transform: scale(.95); }

.btn-block {
    width: 100%; padding: 16px; border: none; border-radius: 14px; font-size: 17px; font-weight: 800;
    cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 8px; transition: var(--fast);
    box-shadow: var(--shadow-md);
}
.btn-block:active { transform: scale(.98); }
.btn-block.gold { background: linear-gradient(135deg, var(--primary), var(--primary-dark)); color: var(--on-primary); }
.btn-block.teal { background: linear-gradient(135deg, var(--secondary), var(--secondary-dark)); color: #fff; }
.btn-block.ink { background: var(--ink); color: #fff; }
.btn-block:hover { transform: translateY(-2px); }

.info-note { margin-top: 16px; padding: 14px; border-radius: 12px; font-size: 13px; line-height: 1.6; display: flex; gap: 8px; }
.info-note.good { background: var(--tint-good-bg); color: var(--tint-good-text); }
.info-note.warn { background: var(--tint-warn-bg); color: var(--tint-warn-text); }

.min-notice { background: var(--tint-warn-bg); color: var(--tint-warn-text); padding: 12px 14px; font-size: 12.5px; border-radius: 12px; display: flex; align-items: center; gap: 8px; font-weight: 700; margin-bottom: 20px; }

.alert-box { padding: 11px 15px; border-radius: 12px; font-size: 13px; margin-bottom: 14px; text-align: center; font-weight: 600; }
.alert-box.error { background: var(--tint-bad-bg); color: var(--tint-bad-text); }
.alert-box.error a { color: var(--tint-bad-text); }
.alert-box.success { background: var(--tint-good-bg); color: var(--tint-good-text); }

/* =========================================================================
   TRANSACTION HISTORY / NOTIFICATIONS
   ========================================================================= */
.list-page-pad { padding: 15px; }
.txn-card {
    background: var(--surface); border-radius: var(--radius-md); box-shadow: var(--shadow-sm); margin-bottom: 12px; padding: 15px 16px;
    display: flex; justify-content: space-between; align-items: center; border-left: 4px solid var(--border-soft);
    opacity: 0; transform: translateY(8px); animation: cardIn .4s var(--ease) forwards;
}
.txn-card.in { border-left-color: var(--secondary); }
.txn-card.out { border-left-color: var(--danger); }
.txn-card:nth-child(1), .notif-card:nth-child(1) { animation-delay: .02s; }
.txn-card:nth-child(2), .notif-card:nth-child(2) { animation-delay: .07s; }
.txn-card:nth-child(3), .notif-card:nth-child(3) { animation-delay: .12s; }
.txn-card:nth-child(n+4), .notif-card:nth-child(n+4) { animation-delay: .16s; }
.txn-title { font-weight: 800; font-size: 14px; color: var(--text-dark); }
.txn-date { font-size: 11.5px; color: var(--text-faint); margin-top: 2px; }
.txn-method { font-size: 11.5px; color: var(--text-faint); margin-top: 2px; }
.txn-amount { font-size: 15.5px; font-weight: 800; text-align: right; }
.txn-amount.in { color: var(--secondary-dark); }
.txn-amount.out { color: var(--danger); }
.txn-status { font-size: 10.5px; font-weight: 800; text-transform: uppercase; text-align: right; margin-top: 3px; letter-spacing: .3px; }

.notif-card { background: var(--surface); border-radius: var(--radius-md); padding: 15px 16px; margin-bottom: 12px; box-shadow: var(--shadow-sm); opacity: 0; transform: translateY(8px); animation: cardIn .4s var(--ease) forwards; }
.notif-title { font-weight: 800; font-size: 14px; color: var(--text-dark); margin-bottom: 5px; display: flex; align-items: center; gap: 7px; }
.notif-title i { color: var(--primary-dark); }
.notif-image { display: block; width: 100%; max-height: 220px; object-fit: cover; border-radius: 12px; margin: 8px 0; cursor: pointer; transition: var(--fast); }
.notif-image:active { transform: scale(.98); }
.notif-msg { font-size: 13px; color: var(--text-muted); line-height: 1.55; }
.notif-footer { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 7px; }
.notif-time { font-size: 11px; color: var(--text-faint); }
.notif-link-btn { font-size: 11.5px; font-weight: 800; color: var(--primary-dark); display: flex; align-items: center; gap: 5px; text-decoration: none; flex-shrink: 0; }

.empty-msg { text-align: center; padding: 40px 20px; color: var(--text-faint); font-weight: 600; }

/* =========================================================================
   POPUPS / MODALS
   ========================================================================= */
.modal { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(11,13,20,.65); backdrop-filter: blur(2px); z-index: 3000; display: none; align-items: center; justify-content: center; }
.modal.active { display: flex; animation: pageFade .2s ease; }
.modal-box { background: var(--surface); color: var(--text-dark); width: 90%; max-width: 350px; border-radius: var(--radius-md); overflow: hidden; box-shadow: var(--shadow-lg); animation: cardShow .3s var(--ease); }
.startup-btn { background: linear-gradient(135deg, var(--primary), var(--primary-dark)); color: var(--on-primary); font-weight: 800; font-size: 16px; width: 100%; padding: 13px; border: none; border-radius: 30px; cursor: pointer; }

/* =========================================================================
   REFER PAGE
   ========================================================================= */
.refer-page-container { display: flex; flex-direction: column; min-height: 100vh; background: var(--surface); }
.refer-header {
    background:
        radial-gradient(circle at 15% -10%, rgba(255,179,0,.18), transparent 45%),
        radial-gradient(circle at 100% 100%, rgba(0,194,168,.10), transparent 40%),
        linear-gradient(160deg, var(--ink), #221a38);
    padding: 44px 20px 24px; text-align: center; border-bottom-left-radius: 26px; border-bottom-right-radius: 26px;
}
.refer-avatar-circle { width: 110px; height: 110px; background: var(--primary-light); border-radius: 50%; margin: 0 auto 18px; display: flex; align-items: center; justify-content: center; border: 4px solid rgba(255,255,255,.15); overflow: hidden; }
.refer-avatar-circle img { width: 100%; height: 100%; object-fit: cover; }
.refer-title { color: var(--primary); font-weight: 700; font-size: 21px; margin-bottom: 10px; letter-spacing: .3px; }
.refer-desc { color: rgba(255,255,255,.85); font-size: 14px; line-height: 1.6; }
.refer-body { padding: 30px 20px; text-align: center; flex: 1; background: var(--surface); }
.refer-label { font-size: 15px; font-weight: 700; color: var(--text-muted); margin-bottom: 15px; letter-spacing: .4px; }
.refer-code-box { background: var(--primary-light); border: 2px dashed var(--primary); padding: 16px; font-size: 22px; font-weight: 700; color: var(--text-dark); display: inline-block; margin-bottom: 28px; letter-spacing: 1px; min-width: 250px; border-radius: 14px; cursor: pointer; transition: var(--fast); }
.refer-code-box:active { transform: scale(.97); }
.refer-illustration { width: 100%; max-width: 400px; margin: 0 auto 28px; display: block; border-radius: var(--radius-md); }
.refer-btn-fixed { background: linear-gradient(135deg, #6A3FD8, #4B2AAE); color: white; font-size: 17px; font-weight: 800; padding: 15px; width: 90%; border: none; border-radius: 14px; cursor: pointer; margin-bottom: 20px; box-shadow: 0 10px 24px rgba(75,42,174,.35); transition: var(--fast); }
.refer-btn-fixed:hover { transform: translateY(-2px); }
.refer-btn-fixed:active { transform: translateY(0) scale(.97); }

/* =========================================================================
   NAV & UTILS
   ========================================================================= */
.back-nav { padding: 15px 60px 15px 15px; color: var(--text-dark); font-weight: 800; cursor: pointer; display: flex; align-items: center; gap: 10px; background: var(--surface); border-bottom: 1px solid var(--border-soft); font-size: 16px; width: 100%; position: sticky; top: 0; z-index: 100; transition: var(--fast); box-sizing: border-box; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.back-nav:active { background: var(--bg-color); }
.back-nav.dark-mode { background: var(--ink); color: white; border-bottom: 1px solid rgba(255,255,255,.08); }
.hidden { display: none !important; }
.primary-btn { background: linear-gradient(135deg, var(--primary), var(--primary-dark)); color: var(--on-primary); padding: 13px; width: 100%; border: none; border-radius: 12px; font-weight: 800; cursor: pointer; transition: var(--fast); }
.primary-btn:hover { transform: translateY(-1px); }
.btn-copy { background: var(--surface-alt); border: none; padding: 6px 12px; border-radius: 8px; font-size: 12px; font-weight: 800; color: var(--text-dark); cursor: pointer; transition: var(--fast); }
.btn-copy:active { transform: scale(.94); }

/* =========================================================================
   TAB BAR
   ========================================================================= */
.tab-bar { position: fixed; bottom: 0; left: 0; width: 100%; height: 65px; background: var(--surface); display: flex; justify-content: space-around; align-items: center; box-shadow: 0 -4px 20px rgba(18,20,28,.07); z-index: 1000; border-top: 1px solid var(--border-soft); }
.tab-item { display: flex; flex-direction: column; align-items: center; width: 20%; color: var(--text-dark); opacity: 1; cursor: pointer; text-decoration: none; }
.tab-icon-box { display: flex; justify-content: center; align-items: center; margin-bottom: 2px; transition: all var(--med) var(--ease); width: 42px; height: 30px; border-radius: 15px; }
.tab-item img { width: 22px; height: 22px; opacity: .75; filter: none; transition: var(--fast); }
.tab-item span { font-size: 10px; margin-top: 2px; font-weight: 700; color: var(--text-faint); transition: var(--fast); }
.tab-item.active img { opacity: 1; }
.tab-item.active span { font-weight: 800; color: var(--text-dark); }
.tab-item.active .tab-icon-box { background-color: var(--primary-light); width: 54px; }

.menu-list { background: var(--surface); border-radius: var(--radius-md); border: 1px solid var(--border-soft); overflow: hidden; box-shadow: var(--shadow-sm); }
.menu-item { padding: 13px 15px; display: flex; align-items: center; gap: 13px; border-bottom: 1px solid var(--border-soft); cursor: pointer; color: var(--text-dark); font-weight: 700; text-decoration: none; transition: background var(--fast), transform var(--fast); }
.menu-item:last-child { border-bottom: none; }
.menu-item:active { background: var(--bg-color); transform: scale(.985); }
.menu-item img { width: 20px; }

/* ---- menu row entrance stagger (Profile menu list) ---- */
.mi-animated { opacity: 0; transform: translateX(-14px); animation: menuItemIn .5s var(--ease) forwards; animation-delay: calc(var(--mi-delay, 0) * .06s); }
@keyframes menuItemIn { to { opacity: 1; transform: translateX(0); } }

/* ---- circular gradient icon badges for each menu row ---- */
.menu-icon-box {
    width: 36px; height: 36px; min-width: 36px; border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    font-size: 15px; color: #fff; transition: transform var(--med) var(--ease), box-shadow var(--fast);
}
.menu-item:hover .menu-icon-box { transform: scale(1.08) rotate(-4deg); }
.menu-item:active .menu-icon-box { transform: scale(.92); }
.mi-wallet  { background: linear-gradient(135deg, #00d4a8, #00a088); box-shadow: 0 6px 14px rgba(0,194,168,.32); }
.mi-edit    { background: linear-gradient(135deg, #4fb3ff, #1f6fe0); box-shadow: 0 6px 14px rgba(31,111,224,.32); }
.mi-refer   { background: linear-gradient(135deg, #ff5fa2, #d8306f); box-shadow: 0 6px 14px rgba(216,48,111,.32); }
.mi-history { background: linear-gradient(135deg, #ffb300, #e6960a); box-shadow: 0 6px 14px rgba(255,179,0,.32); }
.mi-notif   { background: linear-gradient(135deg, #b06bff, #7b3ee0); box-shadow: 0 6px 14px rgba(123,62,224,.32); }
.mi-push    { background: linear-gradient(135deg, #4fd1ff, #1897d6); box-shadow: 0 6px 14px rgba(24,151,214,.32); }
.mi-logout  { background: linear-gradient(135deg, #ff6b73, #e5484d); box-shadow: 0 6px 14px rgba(229,72,77,.32); }

/* ---- chevron slides on hover/active, badges & status text ---- */
.menu-item-arrow { margin-left: auto; color: var(--text-faint); transition: transform var(--fast), color var(--fast); }
.menu-item:hover .menu-item-arrow { transform: translateX(4px); color: var(--primary-dark); }
.menu-item-badge {
    margin-left: auto; background: linear-gradient(135deg, var(--live), #c4222f); color: #fff; font-size: 10.5px;
    font-weight: 800; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; display: flex;
    align-items: center; justify-content: center; box-shadow: 0 0 0 3px rgba(255,59,78,.18); animation: badgePop 1.8s ease-in-out infinite;
}
@keyframes badgePop { 0%,100% { transform: scale(1); } 50% { transform: scale(1.15); } }
.menu-item-status { margin-left: auto; font-size: 12px; color: var(--text-faint); font-weight: 700; transition: color var(--fast); }

.fab-telegram { position: fixed; bottom: 80px; right: 20px; width: 50px; height: 50px; border-radius: 50%; box-shadow: var(--shadow-md); z-index: 999; cursor: pointer; background: var(--primary-light); padding: 5px; transition: var(--fast); }
.fab-telegram:active { transform: scale(.92); }
.fab-telegram img { width: 100%; height: 100%; }

/* =========================================================================
   RIPPLE (added dynamically by app-common.js on tappable elements)
   ========================================================================= */
.rz-ripple { position: absolute; border-radius: 50%; transform: scale(0); background: rgba(255,255,255,.45); animation: rzRipple .55s ease-out; pointer-events: none; }
@keyframes rzRipple { to { transform: scale(2.6); opacity: 0; } }
.btn-join-main, .btn-details, .auth-black-btn, .join-btn-full, .wa-btn, .refer-btn-fixed, .btn-block, .startup-btn, .ep-btn, .primary-btn, .menu-item, .mc-info-btn { position: relative; overflow: hidden; }

/* count-up pulse for balance figures */
.count-pulse { animation: countPulse .4s var(--ease); }
@keyframes countPulse { 0% { transform: scale(1); } 40% { transform: scale(1.06); } 100% { transform: scale(1); } }

/* =========================================================================
   ACCESSIBILITY & MOTION
   ========================================================================= */
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, .tab-item:focus-visible, .menu-item:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
}

/* =========================================================================
   RESPONSIVE (small phones / larger tablets)
   ========================================================================= */
@media (max-width: 360px) {
    .mc-thumb { width: 88px; height: 88px; }
    .wg-balance { font-size: 34px; }
}

@media (min-width: 720px) {
    .page-wrap, .wallet-redesign-container, .refer-page-container { max-width: 640px; margin: 0 auto; box-shadow: 0 0 60px rgba(0,0,0,.06); }
    .tab-bar, .fab-telegram { left: 50%; transform: translateX(-50%); max-width: 640px; width: 100%; }
    .fab-telegram { transform: none; left: auto; right: calc(50% - 320px + 20px); }
    .join-btn-full { left: calc(50% - 320px + 5%); width: calc(640px * .9); max-width: 576px; }
}

/* =========================================================================
   THEME-COLOR TRANSITIONS (smooth cross-fade when the toggle is used)
   ========================================================================= */
.match-card, .cat-card-new, .cat-card-info, .ep-card, .pay-card, .pay-methods-card,
.form-select, .form-input, .txn-card, .notif-card, .menu-list, .menu-item,
.tab-bar, .quick-action-card, .learn-item, .wallet-stats-white-card,
.md-table-container, .rd-card, .rd-row, .join-card, .join-input-field,
.back-nav, .modal-box, .pay-tab-btn, .quick-amount-btn, .md-player-row,
.mc-prog-bar, .rd-table-head {
    transition: background-color var(--med) var(--ease), color var(--med) var(--ease), border-color var(--med) var(--ease), box-shadow var(--med) var(--ease);
}

/* =========================================================================
   THEME TOGGLE — floating pill switch, always reachable
   ========================================================================= */
.theme-fab {
    position: fixed;
    top: 14px;
    right: 14px;
    z-index: 1200;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid var(--border-soft);
    background: var(--surface);
    box-shadow: var(--shadow-md);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--primary-dark);
    font-size: 17px;
    transition: transform var(--fast) var(--ease), background-color var(--med), border-color var(--med), box-shadow var(--fast);
}
.theme-fab:active { transform: scale(.88); }
.theme-fab i { transition: transform .45s var(--ease), opacity .25s ease; }
.theme-fab .fa-sun { position: absolute; }
.theme-fab .fa-moon { position: absolute; }
html[data-theme="dark"] .theme-fab .fa-sun,
html[data-theme="light"] .theme-fab .fa-moon { opacity: 0; transform: rotate(-90deg) scale(.4); }
html[data-theme="dark"] .theme-fab .fa-moon,
html[data-theme="light"] .theme-fab .fa-sun { opacity: 1; transform: rotate(0) scale(1); }

@media (min-width: 720px) {
    .theme-fab { right: calc(50% - 320px + 14px); }
}

/* =========================================================================
   AMBIENT "ARENA" ATMOSPHERE — cheap, GPU-friendly glow + scanline texture
   for the always-dark stage panels (profile header, wallet vault, room
   info card, refer header). No blur filters on repeating list items, so
   scrolling stays smooth on low-end phones.
   ========================================================================= */
.marquee-container {
    position: relative;
    background-image:
        radial-gradient(circle at 15% -10%, rgba(255,179,0,.16), transparent 45%),
        radial-gradient(circle at 100% 0%, rgba(0,194,168,.10), transparent 40%),
        repeating-linear-gradient(115deg, rgba(255,255,255,.025) 0px, rgba(255,255,255,.025) 1px, transparent 1px, transparent 5px);
}
.mc-footer-timer.is-live { background: var(--live); box-shadow: inset 0 0 0 1px rgba(255,59,78,.5), 0 0 18px rgba(255,59,78,.3); }
.mc-footer-timer.is-done { background: var(--text-faint); }

/* ---- "Watch Now Live" clickable CTA (ongoing match with a live link) ---- */
.btn-watch-live {
    text-decoration: none; display: flex; align-items: center; justify-content: center; gap: 10px;
    background: linear-gradient(120deg, #ff3b4e, #c4222f 65%, #ff3b4e); background-size: 220% 100%;
    position: relative; overflow: hidden; cursor: pointer;
    animation: watchLiveGlow 2.2s ease-in-out infinite, watchLiveSheen 3.6s linear infinite;
    transition: transform var(--fast), box-shadow var(--fast);
}
.btn-watch-live:hover { transform: translateY(-2px); box-shadow: inset 0 0 0 1px rgba(255,59,78,.5), 0 0 26px rgba(255,59,78,.55); }
.btn-watch-live:active { transform: translateY(0) scale(.97); }
.btn-watch-live::after {
    content: ''; position: absolute; inset: 0; background: linear-gradient(115deg, transparent 40%, rgba(255,255,255,.35) 50%, transparent 60%);
    animation: watchLiveShine 2.6s ease-in-out infinite;
}
.wl-dot { display: inline-flex; align-items: center; gap: 5px; background: rgba(0,0,0,.22); padding: 3px 9px; border-radius: 20px; font-size: 11px; font-weight: 800; letter-spacing: .4px; position: relative; z-index: 1; }
.wl-dot .fa-circle { font-size: 7px; animation: livePulse 1.1s infinite; }
.wl-cta { display: inline-flex; align-items: center; gap: 6px; font-weight: 800; font-size: 13px; position: relative; z-index: 1; }
.wl-cta i { animation: watchLivePlayPulse 1.4s ease-in-out infinite; }
@keyframes watchLiveGlow { 0%,100% { box-shadow: inset 0 0 0 1px rgba(255,59,78,.5), 0 0 18px rgba(255,59,78,.3); } 50% { box-shadow: inset 0 0 0 1px rgba(255,59,78,.6), 0 0 28px rgba(255,59,78,.55); } }
@keyframes watchLiveSheen { 0% { background-position: 0% 50%; } 100% { background-position: 220% 50%; } }
@keyframes watchLiveShine { 0% { transform: translateX(-120%); } 55%,100% { transform: translateX(120%); } }
@keyframes watchLivePlayPulse { 0%,100% { transform: scale(1); } 50% { transform: scale(1.22); } }

/* small colored eyebrow rule for section headings (structural, not decorative) */
.category-title, .wallet-section-title {
    position: relative;
    padding-left: 14px;
}
.category-title::before, .wallet-section-title::before {
    content: '';
    position: absolute;
    left: 0; top: 50%;
    transform: translateY(-50%);
    width: 5px; height: 62%;
    border-radius: 3px;
    background: linear-gradient(180deg, var(--primary), var(--secondary));
}

.appearance-row { padding: 15px; display: flex; align-items: center; gap: 15px; border-bottom: 1px solid var(--border-soft); }
.appearance-row > span:first-of-type { flex: 1; font-weight: 700; color: var(--text-dark); display: flex; align-items: center; gap: 15px; }
.appearance-switch { display: flex; background: var(--surface-alt); border-radius: 20px; padding: 3px; gap: 2px; }
.appearance-switch button { border: none; background: transparent; padding: 6px 12px; border-radius: 16px; font-size: 12px; font-weight: 700; color: var(--text-muted); cursor: pointer; display: flex; align-items: center; gap: 5px; transition: var(--fast); }
.appearance-switch button.active { background: var(--primary); color: var(--on-primary); box-shadow: 0 3px 8px rgba(255,179,0,.35); }

/* =====================================================================
 * PLAYER ZONE BD — feature-update styles (v3)
 * Match card badges, Room/Prize popups, Results tabs, winner cards,
 * profile stat pills, refer page polish.
 * ===================================================================== */

/* ---- match card badges (Free/Paid, Version) ---- */
.mc-badge-row { display: flex; gap: 6px; margin-top: 6px; flex-wrap: wrap; }
.mc-badge { font-size: 10px; font-weight: 800; letter-spacing: .4px; padding: 3px 9px; border-radius: 20px; text-transform: uppercase; }
.mc-badge-free { background: rgba(43,182,115,.15); color: var(--success); }
.mc-badge-paid { background: rgba(255,179,0,.15); color: var(--primary-dark); }
.mc-badge-version { background: var(--surface-alt); color: var(--text-muted); }

/* ---- Room Details / Total Prize Details buttons on every card ---- */
.mc-info-btn-row { display: flex; gap: 8px; padding: 0 12px 12px; }
.mc-info-btn {
    flex: 1; display: flex; align-items: center; justify-content: center; gap: 6px;
    border: 1.5px solid var(--border-soft); background: var(--surface-alt); color: var(--text-dark);
    font-size: 12px; font-weight: 800; padding: 9px 6px; border-radius: 12px; cursor: pointer;
    transition: transform var(--fast) var(--ease), box-shadow var(--fast) var(--ease), background var(--fast);
}
.mc-info-btn i { color: var(--primary-dark); }
.mc-info-btn:active { transform: scale(.96); }
.mc-info-btn:hover { background: var(--primary-light); box-shadow: 0 4px 12px rgba(255,179,0,.18); }
.btn-room-details i { color: var(--secondary-dark); }

/* ---- generic info modal (Room Details / Total Prize Details) ---- */
.info-modal-box { max-width: 380px; }
.info-modal-head {
    display: flex; align-items: center; gap: 10px; padding: 16px 18px; font-weight: 800; font-size: 16px;
    background: linear-gradient(135deg, var(--ink), #241a3d); color: #fff;
}
.info-modal-head i { color: var(--primary); }
.info-modal-close { margin-left: auto; background: rgba(255,255,255,.12); border: none; color: #fff; width: 28px; height: 28px; border-radius: 50%; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: var(--fast); }
.info-modal-close:hover { background: rgba(255,255,255,.25); }
.info-modal-body { padding: 18px; max-height: 60vh; overflow-y: auto; }
.info-modal-empty { text-align: center; padding: 20px 10px; color: var(--text-faint); }
.info-modal-empty i { font-size: 26px; display: block; margin-bottom: 10px; color: var(--text-faint); }
.info-modal-empty p { font-size: 13px; font-weight: 600; margin: 0; }

.room-detail-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; background: var(--surface-alt); border-radius: 12px; padding: 12px 14px; margin-bottom: 10px; animation: cardIn .3s var(--ease) forwards; }
.room-detail-row:last-child { margin-bottom: 0; }
.room-detail-label { display: block; font-size: 10.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .3px; color: var(--text-faint); }
.room-detail-value { display: block; font-size: 16px; font-weight: 800; color: var(--text-dark); margin-top: 2px; letter-spacing: .5px; }

#prize-modal .info-modal-head { display: none; }
#prize-modal .info-modal-body { padding-top: 22px; }
.prize-modal-emoji { text-align: center; font-size: 34px; margin-bottom: 2px; }
.prize-modal-heading { text-align: center; font-weight: 900; font-size: 19px; color: var(--text-dark); line-height: 1.25; margin-bottom: 16px; }
.prize-pool-row { display: flex; gap: 10px; margin-bottom: 16px; }
.prize-pool-box { flex: 1; border-radius: 14px; padding: 14px 8px; text-align: center; color: #fff; }
.prize-pool-box .ppb-label { font-size: 10.5px; font-weight: 800; letter-spacing: .3px; text-transform: uppercase; opacity: .92; }
.prize-pool-box .ppb-value { font-size: 19px; font-weight: 900; margin-top: 4px; }
.prize-pool-box.ppb-total { background: linear-gradient(135deg, #1fbf77, #12945c); box-shadow: 0 8px 18px rgba(18,148,92,.3); }
.prize-pool-box.ppb-perkill { background: linear-gradient(135deg, #3a8dff, #2360c9); box-shadow: 0 8px 18px rgba(35,96,201,.3); }
.prize-ranks-label { font-size: 12px; font-weight: 800; color: var(--primary-dark); text-transform: uppercase; letter-spacing: .4px; margin-bottom: 10px; display: flex; align-items: center; gap: 6px; }
.prize-list { display: flex; flex-direction: column; gap: 8px; margin-bottom: 6px; }
.prize-list-item { display: flex; justify-content: space-between; align-items: center; background: var(--surface-alt); border-radius: 12px; padding: 12px 14px; font-size: 13.5px; font-weight: 700; color: var(--text-dark); opacity: 0; transform: translateY(6px); animation: cardIn .3s var(--ease) forwards; }
.prize-list-rank { display: flex; align-items: center; gap: 8px; }
.prize-list-rank i { color: var(--primary); }
.prize-list-medal { font-size: 17px; }
.prize-list-amt { color: #17a262; font-weight: 900; font-size: 14.5px; }
.prize-modal-gotit { width: 100%; margin-top: 14px; padding: 14px; border: none; border-radius: 12px; background: linear-gradient(135deg, #1c2b6b, #10173b); color: #fff; font-weight: 800; font-size: 15px; cursor: pointer; box-shadow: 0 8px 18px rgba(16,23,59,.3); transition: var(--fast); }
.prize-modal-gotit:hover { transform: translateY(-2px); }
.prize-modal-gotit:active { transform: translateY(0) scale(.97); }

.btn-proof { color: var(--live) !important; border-color: var(--live) !important; }
.btn-proof:hover { background: var(--live) !important; color: #fff !important; }

/* ---- Results page: All Match Result / My Joined Match tabs ---- */
.result-tabs { display: flex; gap: 8px; padding: 15px; }
.result-tab { flex: 1; text-align: center; padding: 12px 0; font-weight: 800; font-size: 13.5px; border-radius: 12px; background: var(--surface); color: var(--text-muted); box-shadow: var(--shadow-sm); cursor: pointer; transition: var(--fast); border: 1.5px solid var(--border-soft); }
.result-tab.active { background: linear-gradient(135deg, var(--primary), var(--primary-dark)); color: var(--on-primary); border-color: transparent; box-shadow: 0 8px 18px rgba(255,179,0,.3); }
.result-panel { animation: pageFade .3s var(--ease); }

/* ---- winner list (Result & Prize detail + My Joined Match) ---- */
.winner-card { display: flex; align-items: center; gap: 12px; background: var(--surface); border-radius: 14px; padding: 12px 14px; margin-bottom: 10px; box-shadow: var(--shadow-sm); opacity: 0; transform: translateY(8px); animation: cardIn .35s var(--ease) forwards; border: 1px solid var(--border-soft); }
.winner-card.top1 { border: 1.5px solid var(--primary); background: linear-gradient(90deg, var(--primary-light), var(--surface) 40%); }
.winner-avatar { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; border: 2px solid var(--primary); flex: 0 0 auto; background: var(--surface-alt); }
.winner-avatar-fallback { width: 44px; height: 44px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 800; color: #fff; background: linear-gradient(135deg, var(--primary), var(--primary-dark)); flex: 0 0 auto; }
.winner-info { flex: 1; min-width: 0; }
.winner-name { font-weight: 800; font-size: 14px; color: var(--text-dark); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.winner-meta { font-size: 11.5px; color: var(--text-muted); font-weight: 600; margin-top: 2px; }
.winner-rank-badge { flex: 0 0 auto; font-size: 11px; font-weight: 800; background: var(--ink); color: #fff; padding: 4px 10px; border-radius: 20px; }
.winner-prize { flex: 0 0 auto; text-align: right; font-weight: 800; color: var(--secondary-dark); font-size: 15px; }

/* ---- My Joined Match summary card (item 4) ---- */
.mj-summary-card { background: var(--surface); border-radius: var(--radius-md); padding: 16px; margin: 0 15px 14px; box-shadow: var(--shadow-sm); }
.mj-summary-row { display: flex; justify-content: space-around; text-align: center; padding-top: 10px; margin-top: 10px; border-top: 1px dashed var(--border-soft); }
.mj-summary-row div div:first-child { font-size: 10.5px; color: var(--text-faint); font-weight: 700; text-transform: uppercase; }
.mj-summary-row div div:last-child { font-size: 16px; font-weight: 800; color: var(--text-dark); margin-top: 3px; }

/* ---- profile: joined/win match counters (item 6) ---- */
.profile-stat-pills { display: flex; justify-content: center; gap: 12px; margin-top: 14px; }
.profile-stat-pill { background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.15); border-radius: 14px; padding: 8px 16px; text-align: center; backdrop-filter: blur(4px); }
.profile-stat-pill-num { font-size: 17px; font-weight: 800; color: var(--primary); }
.profile-stat-pill-label { font-size: 10px; opacity: .85; text-transform: uppercase; letter-spacing: .3px; margin-top: 1px; }

/* ---- refer page polish ---- */
.refer-stats-row { display: flex; gap: 10px; margin: 18px 0; }
.refer-stat-box { flex: 1; background: var(--surface-alt); border-radius: 14px; padding: 14px 8px; text-align: center; }
.refer-stat-box b { display: block; font-size: 20px; font-weight: 800; color: var(--primary-dark); }
.refer-stat-box span { font-size: 11px; color: var(--text-muted); font-weight: 700; }
.refer-code-box { position: relative; }
.refer-code-copy-icon { margin-left: 10px; color: var(--primary-dark); }

/* =====================================================================
 * PLAYER ZONE BD — v4 visual pass: match this to the reference screenshots
 * (category/ID/status badge strip, 6-box stat grid, glossy result buttons,
 * dark refer & profile pages).
 * ===================================================================== */

/* ---- badge strip on top of every card (category / match ID / status) ---- */
.mc-badge-strip { display: flex; flex-wrap: wrap; gap: 6px; padding: 12px 12px 0; }
.mc-tag { font-size: 10.5px; font-weight: 800; letter-spacing: .3px; padding: 5px 11px; border-radius: 20px; display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; }
.mc-tag-cat { background: linear-gradient(135deg, #6a4bd8, #4527a0); color: #fff; box-shadow: 0 4px 10px rgba(69,39,160,.3); }
.mc-tag-id { background: linear-gradient(135deg, #ffb020, #e6870a); color: #fff; box-shadow: 0 4px 10px rgba(230,135,10,.3); }
.mc-tag-status { background: linear-gradient(135deg, #22c07a, #159a5f); color: #fff; box-shadow: 0 4px 10px rgba(21,154,95,.3); animation: tagGlow 2s ease-in-out infinite; }
.mc-tag-joined { background: linear-gradient(135deg, #ff8f3c, #e6690a); color: #fff; box-shadow: 0 4px 10px rgba(230,105,10,.3); }
@keyframes tagGlow { 0%, 100% { filter: brightness(1); } 50% { filter: brightness(1.18); } }

/* ---- 6-box stat grid used on browse/my-matches cards ---- */
.mc-stats-grid-6 { grid-template-columns: repeat(3, 1fr); gap: 12px 4px; }
.mc-stats-grid-3 { grid-template-columns: repeat(3, 1fr); }
.mc-stat-box { border-radius: 10px; padding: 6px 2px; transition: var(--fast); }
.mc-stat-highlight { background: rgba(34,192,122,.1); border: 1.5px solid rgba(34,192,122,.35); }
.mc-stat-highlight .mc-stat-value { color: #159a5f; }
.mc-stat-value-sm { font-size: 13.5px; }
.mc-stat-label i { margin-right: 3px; color: #159a5f; }

/* ---- result-mode full-width action buttons (Result & Prize / Match Proof) ---- */
.mc-result-btn-row { display: flex; gap: 10px; padding: 0 12px 14px; }
.btn-result-action { flex: 1; display: flex; align-items: center; justify-content: center; gap: 7px; padding: 12px 8px; border-radius: 12px; font-size: 13.5px; font-weight: 800; border: none; cursor: pointer; transition: var(--fast); }
.btn-result-view { background: linear-gradient(135deg, #22c07a, #159a5f); color: #fff; box-shadow: 0 8px 16px rgba(21,154,95,.3); }
.btn-result-view:hover { transform: translateY(-2px); box-shadow: 0 12px 20px rgba(21,154,95,.4); }
.btn-result-proof { background: linear-gradient(135deg, #3a8dff, #1f5fd6); color: #fff; box-shadow: 0 8px 16px rgba(31,95,214,.3); }
.btn-result-proof:hover { transform: translateY(-2px); box-shadow: 0 12px 20px rgba(31,95,214,.4); }
.match-card-result .mc-header { padding-top: 10px; }

/* =====================================================================
 * Dark glossy "Refer & Earn" page (matches reference screenshot)
 * ===================================================================== */
.refer-page-dark { background: linear-gradient(180deg, #0b0e1c, #12162b 40%, #0b0e1c); min-height: 100vh; color: #fff; padding-bottom: 40px; }
.refer-dark-header { padding: 60px 20px 24px; text-align: center; position: relative; }
.refer-dark-back { position: absolute; top: 18px; left: 18px; width: 36px; height: 36px; border-radius: 50%; background: rgba(255,255,255,.08); display: flex; align-items: center; justify-content: center; color: #fff; text-decoration: none; }
.refer-invited-box { margin: 0 16px 20px; background: linear-gradient(135deg, #6a3fd8, #3d1f96); border-radius: 16px; padding: 14px 18px; font-size: 13.5px; font-weight: 700; box-shadow: 0 10px 24px rgba(61,31,150,.35); display: flex; align-items: center; gap: 10px; }
.refer-invited-box i { color: #ffd35c; }
.refer-dark-stats { display: flex; gap: 14px; padding: 0 16px; margin-bottom: 22px; }
.refer-dark-stat { flex: 1; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.1); border-radius: 16px; padding: 22px 10px; text-align: center; backdrop-filter: blur(6px); }
.refer-dark-stat i { font-size: 20px; margin-bottom: 8px; display: block; }
.refer-dark-stat.rd-invited i { color: #4fb3ff; }
.refer-dark-stat.rd-earning i { color: #2be08a; }
.refer-dark-stat-num { font-size: 22px; font-weight: 900; }
.refer-dark-stat-label { font-size: 11px; opacity: .75; margin-top: 3px; font-weight: 700; }
.refer-dark-code-label { text-align: center; font-size: 12px; opacity: .7; font-weight: 700; letter-spacing: .4px; margin-bottom: 12px; }
.refer-dark-code-box { margin: 0 16px 22px; border: 2px dashed #d84fc9; border-radius: 16px; padding: 20px; text-align: center; background: rgba(216,79,201,.08); box-shadow: 0 0 24px rgba(216,79,201,.25); cursor: pointer; position: relative; }
.refer-dark-code-box .rd-code-text { font-size: 26px; font-weight: 900; letter-spacing: 3px; color: #f472e8; text-shadow: 0 0 18px rgba(244,114,232,.5); }
.refer-dark-btn-row { display: flex; gap: 12px; padding: 0 16px; }
.refer-dark-btn { flex: 1; padding: 15px; border: none; border-radius: 14px; font-weight: 800; font-size: 14px; color: #fff; cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 8px; transition: var(--fast); }
.refer-dark-btn.rd-copy { background: linear-gradient(135deg, #3a8dff, #1f5fd6); box-shadow: 0 10px 20px rgba(31,95,214,.35); }
.refer-dark-btn.rd-share { background: linear-gradient(135deg, #ff5fa2, #d8306f); box-shadow: 0 10px 20px rgba(216,48,111,.35); }
.refer-dark-btn:hover { transform: translateY(-2px); }
.refer-dark-btn:active { transform: translateY(0) scale(.96); }

/* =====================================================================
 * Dark glossy Profile page with a "Platinum" wallet card
 * ===================================================================== */
.profile-dark-wrap { background: linear-gradient(180deg, #0b0e1c, #12162b 40%, #171a2c); min-height: 100vh; padding-bottom: 20px; }
.profile-dark-wrap .menu-list { background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.08); }
.profile-dark-wrap .menu-item { color: #fff; border-bottom-color: rgba(255,255,255,.07); }
.profile-dark-wrap .menu-item span { color: #fff; }
.profile-dark-wrap .menu-item:active { background: rgba(255,255,255,.06); }
.profile-dark-wrap .menu-item-arrow { color: rgba(255,255,255,.35); }
.profile-dark-wrap .menu-item:hover .menu-item-arrow { color: var(--primary); }
.profile-dark-wrap .menu-item-status { color: rgba(255,255,255,.45); }
.profile-dark-wrap .appearance-row { border-bottom-color: rgba(255,255,255,.07); }
.profile-dark-wrap .appearance-row > span:first-of-type { color: #fff; }
.profile-dark-wrap .appearance-switch { background: rgba(255,255,255,.08); }
.profile-dark-top { padding: 55px 18px 14px; text-align: center; color: #fff; }
.profile-dark-name { font-size: 20px; font-weight: 900; margin-bottom: 8px; }
.profile-uid-pill { display: inline-flex; align-items: center; gap: 8px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.15); border-radius: 20px; padding: 6px 14px; font-size: 12.5px; font-weight: 700; margin-bottom: 12px; }
.profile-uid-pill i { color: #2be08a; }
.profile-uid-copy { color: #4fb3ff; cursor: pointer; }
.profile-id-ref-row { font-size: 11.5px; opacity: .75; margin-bottom: 18px; }
.profile-id-ref-row b { color: #f472e8; }

.platinum-card {
    margin: 0 18px 18px; border-radius: 22px; padding: 22px; position: relative; overflow: hidden;
    background: linear-gradient(135deg, #1a2140, #0d1226 60%, #241b45);
    border: 1px solid rgba(255,255,255,.08); box-shadow: 0 16px 34px rgba(0,0,0,.45), inset 0 1px 0 rgba(255,255,255,.06);
    color: #fff; animation: cardShow .6s var(--ease); transition: transform var(--med) var(--ease), box-shadow var(--med) var(--ease);
}
.platinum-card:active { transform: scale(.985); }
.platinum-card::before { content: ''; position: absolute; top: -40%; right: -20%; width: 220px; height: 220px; background: radial-gradient(circle, rgba(255,179,0,.18), transparent 70%); animation: platinumGlowFloat 6s ease-in-out infinite alternate; }
.platinum-card-glow { position: absolute; top: -50%; left: -30%; width: 65%; height: 200%; background: linear-gradient(115deg, transparent, rgba(255,255,255,.08), transparent); animation: walletSheen 5s ease-in-out infinite; pointer-events: none; }
@keyframes platinumGlowFloat { from { transform: translate(-10px,-10px) scale(1); } to { transform: translate(15px,20px) scale(1.15); } }
.platinum-card-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; position: relative; z-index: 1; }
.platinum-tier { display: flex; align-items: center; gap: 7px; font-size: 12px; font-weight: 800; letter-spacing: .4px; text-transform: uppercase; opacity: .95; }
.platinum-tier i { color: #ffd35c; animation: tagGlow 2.4s ease-in-out infinite; }
.platinum-chip { width: 36px; height: 27px; border-radius: 6px; background: linear-gradient(135deg, #f2c14e, #c9922a); position: relative; overflow: hidden; box-shadow: 0 2px 6px rgba(0,0,0,.35), inset 0 0 0 1px rgba(255,255,255,.25); }
.platinum-chip::before { content: ''; position: absolute; inset: 0; background: linear-gradient(115deg, transparent 30%, rgba(255,255,255,.55) 48%, transparent 65%); animation: chipShine 3.2s ease-in-out infinite; }
@keyframes chipShine { 0% { transform: translateX(-120%); } 55%,100% { transform: translateX(120%); } }
.platinum-balance-label { font-size: 11px; opacity: .7; font-weight: 700; letter-spacing: .3px; text-transform: uppercase; position: relative; z-index: 1; display: flex; align-items: center; gap: 6px; }
.platinum-balance-label i { color: #ffd35c; font-size: 10px; }
.platinum-balance-value { font-size: 32px; font-weight: 900; margin: 4px 0 16px; position: relative; z-index: 1; text-shadow: 0 0 22px rgba(255,211,92,.28); }
.platinum-sub-row { display: flex; justify-content: space-between; gap: 10px; border-top: 1px dashed rgba(255,255,255,.18); padding-top: 12px; position: relative; z-index: 1; }
.platinum-sub-row > div { flex: 1; display: flex; align-items: center; gap: 9px; padding: 8px 9px; border-radius: 12px; background: rgba(255,255,255,.04); transition: background var(--fast), transform var(--fast); }
.platinum-sub-row > div:active { transform: scale(.95); background: rgba(255,255,255,.09); }
.psr-icon { width: 27px; height: 27px; min-width: 27px; border-radius: 9px; display: flex; align-items: center; justify-content: center; font-size: 11.5px; box-shadow: 0 4px 10px rgba(0,0,0,.25); }
.psr-deposit .psr-icon { background: linear-gradient(135deg, #ffd35c, #e6960a); color: #1a1200; }
.psr-winning .psr-icon { background: linear-gradient(135deg, #2be08a, #00a088); color: #062018; }
.platinum-sub-row .psr-text span:first-child { display: block; font-size: 10px; opacity: .65; text-transform: uppercase; font-weight: 700; }
.platinum-sub-row .psr-text span:last-child { display: block; font-size: 15px; font-weight: 800; margin-top: 2px; }
.platinum-sub-row .psr-deposit span:last-child { color: #ffd35c; }
.platinum-sub-row .psr-winning span:last-child { color: #2be08a; }

.profile-dark-stats-row { display: flex; margin: 0 18px 18px; background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.08); border-radius: 18px; padding: 16px 4px; color: #fff; }
.profile-dark-stats-row .pds-item { flex: 1; text-align: center; }
.profile-dark-stats-row .pds-item i { font-size: 16px; margin-bottom: 6px; display: block; }
.pds-item.pds-matches i { color: #4fb3ff; }
.pds-item.pds-wins i { color: #ffd35c; }
.pds-item.pds-earned i { color: #2be08a; }
.pds-item.pds-rank i { color: #f472e8; }
.pds-item-num { font-size: 16px; font-weight: 900; }
.pds-item-label { font-size: 9.5px; opacity: .7; font-weight: 700; text-transform: uppercase; margin-top: 2px; }

.activity-history-label { padding: 0 18px; font-size: 12px; font-weight: 800; letter-spacing: .4px; text-transform: uppercase; color: var(--text-faint); margin-bottom: 10px; }
