/* Locket Gold Tool - Core Stylesheet */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    background: #0a0a1a;
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    color: #fff;
    overflow-x: clip;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    font-feature-settings: 'cv02', 'cv03', 'cv04', 'cv11';
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    letter-spacing: -0.02em;
    font-weight: 800;
}

input,
button,
select,
textarea {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

button,
.btn {
    font-family: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    user-select: none;
    -webkit-user-select: none;
    -webkit-touch-callout: none;
}

/* ═══════════════════════════════════════════
   MOBILE TOUCH & INTERACTIVE TAP OPTIMIZATION
   ═══════════════════════════════════════════ */
html,
body,
button,
a,
input,
select,
textarea,
.btn,
.client-tab-btn,
.admin-nav-link,
.topup-option,
.page-btn,
.stat,
.alert-close {
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

/* ═══════════════════════════════════════════
   ANIMATED BACKGROUND
   ═══════════════════════════════════════════ */
.bg-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    background: linear-gradient(135deg, #0a0a1a 0%, #1a0a2e 50%, #0a0a1a 100%);
}

:root {
    --primary-gold: #ffd700;
    --primary-accent: #ffaa00;
    --bg-orb-opacity: 0.45;
    --text-primary: #ffffff;
    --text-body: #e2e8f0;
    --text-muted: #cbd5e1;
    --text-sub: #94a3b8;
    --card-bg: rgba(255, 255, 255, 0.045);
    --card-border: rgba(255, 255, 255, 0.12);
}

.orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(85px);
    opacity: var(--bg-orb-opacity, 0.4);
    pointer-events: none;
    will-change: transform;
}

.orb-1 {
    width: 480px;
    height: 480px;
    background: radial-gradient(circle, var(--primary-gold, #ffd700) 0%, rgba(255, 215, 0, 0.2) 50%, transparent 70%);
    top: -80px;
    left: -80px;
    animation: orbFloat1 22s cubic-bezier(0.45, 0.05, 0.55, 0.95) infinite alternate;
}

.orb-2 {
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, #ff6b6b 0%, rgba(255, 107, 107, 0.2) 50%, transparent 70%);
    top: 45%;
    right: -80px;
    animation: orbFloat2 26s cubic-bezier(0.45, 0.05, 0.55, 0.95) infinite alternate;
}

.orb-3 {
    width: 420px;
    height: 420px;
    background: radial-gradient(circle, #667eea 0%, rgba(102, 126, 234, 0.2) 50%, transparent 70%);
    bottom: -100px;
    left: 25%;
    animation: orbFloat3 24s cubic-bezier(0.45, 0.05, 0.55, 0.95) infinite alternate;
}

.orb-4 {
    width: 320px;
    height: 320px;
    background: radial-gradient(circle, #f093fb 0%, rgba(240, 147, 251, 0.2) 50%, transparent 70%);
    top: 15%;
    left: 55%;
    animation: orbFloat4 30s cubic-bezier(0.45, 0.05, 0.55, 0.95) infinite alternate;
}

/* ═══════════════════════════════════════════
   TỐI ƯU HIỆU NĂNG CHO THIẾT BỊ YẾU & MẠNG CHẬM
   ═══════════════════════════════════════════ */
@media (max-width: 768px) {
    .orb {
        filter: blur(35px) !important;
        animation: none !important;
        transform: none !important;
        will-change: auto !important;
        opacity: 0.28 !important;
    }
    .orb-3,
    .orb-4 {
        display: none !important;
    }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
        scroll-behavior: auto !important;
    }
    .orb {
        animation: none !important;
        transform: none !important;
    }
}

/* Tăng tốc render danh sách off-screen, tiết kiệm RAM/CPU trên điện thoại */
.transaction-item,
.faq-item,
.ctv-tier-card,
.feature-card,
.wizard-step {
    content-visibility: auto;
    contain-intrinsic-size: 0 80px;
}

@keyframes orbFloat1 {
    0% {
        transform: translate(0, 0) scale(1) rotate(0deg);
    }

    33% {
        transform: translate(60px, 80px) scale(1.12) rotate(15deg);
    }

    66% {
        transform: translate(-30px, 120px) scale(0.95) rotate(-10deg);
    }

    100% {
        transform: translate(40px, -20px) scale(1.05) rotate(5deg);
    }
}

@keyframes orbFloat2 {
    0% {
        transform: translate(0, 0) scale(1);
    }

    40% {
        transform: translate(-90px, -60px) scale(1.15);
    }

    75% {
        transform: translate(-50px, 80px) scale(0.92);
    }

    100% {
        transform: translate(30px, -40px) scale(1.08);
    }
}

@keyframes orbFloat3 {
    0% {
        transform: translate(0, 0) scale(1);
    }

    35% {
        transform: translate(80px, -70px) scale(1.1);
    }

    70% {
        transform: translate(-60px, -40px) scale(0.94);
    }

    100% {
        transform: translate(40px, 50px) scale(1.05);
    }
}

@keyframes orbFloat4 {
    0% {
        transform: translate(0, 0) scale(1);
    }

    50% {
        transform: translate(-100px, 80px) scale(1.18);
    }

    100% {
        transform: translate(70px, -50px) scale(0.9);
    }
}

.grid-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 50px 50px;
    pointer-events: none;
}

/* ═══════════════════════════════════════════
   CONTAINER & FLUID LAYOUT
   ═══════════════════════════════════════════ */
.container {
    max-width: 980px;
    width: 95%;
    margin: 0 auto;
    padding: 20px 16px 4px 16px;
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    flex: 1 0 auto;
    min-height: 100vh;
    min-height: 100dvh;
}

.container.admin-container-wide {
    max-width: 1440px;
    width: 96%;
    padding: 20px 16px 4px 16px;
    display: flex;
    flex-direction: column;
    flex: 1 0 auto;
    min-height: 100vh;
    min-height: 100dvh;
}

main,
.tab-content-wrapper,
.admin-container {
    flex: 1 0 auto;
}

/* ═══════════════════════════════════════════
   HEADER
   ═══════════════════════════════════════════ */
.header {
    position: sticky;
    top: 12px;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(15, 15, 28, 0.88);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 20px;
    padding: 14px 22px;
    margin-bottom: 24px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.45);
    transition: all 0.3s ease;
}

.logo {
    display: flex;
    align-items: center;
    gap: 14px;
    text-decoration: none;
}

.logo-icon {
    width: 44px;
    height: 44px;
    background: radial-gradient(circle at 35% 30%, rgba(255, 245, 157, 0.25), rgba(255, 160, 0, 0.08));
    border: 1.5px solid rgba(255, 215, 0, 0.45);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 20px rgba(255, 215, 0, 0.3), inset 0 0 12px rgba(255, 215, 0, 0.15);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s ease;
}

.logo-icon:hover {
    transform: scale(1.08) rotate(-4deg);
    box-shadow: 0 6px 24px rgba(255, 215, 0, 0.45);
}

.logo-icon svg {
    width: 26px;
    height: 26px;
    filter: drop-shadow(0 2px 6px rgba(255, 170, 0, 0.5));
}

.logo-text {
    display: flex;
    flex-direction: column;
    line-height: 1.15;
}

.logo-main {
    font-family: 'Outfit', sans-serif;
    font-size: 20px;
    font-weight: 900;
    letter-spacing: 1.5px;
    color: #fff;
}

.logo-gold {
    font-family: 'Outfit', sans-serif;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 4px;
    background: linear-gradient(135deg, #FFF59D 0%, #FFD700 50%, #FFA000 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}


.header-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 215, 0, 0.1);
    color: #ffd700;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1px;
    border: 1px solid rgba(255, 215, 0, 0.2);
}

.header-sub-tagline {
    text-align: center;
    font-size: 13px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.85);
    margin: -10px auto 20px auto;
    padding: 6px 18px;
    background: rgba(255, 215, 0, 0.05);
    border: 1px solid rgba(255, 215, 0, 0.18);
    border-radius: 999px;
    width: fit-content;
    max-width: 96%;
    letter-spacing: 0.15px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

main {
    min-height: 520px;
}

.pulse-dot {
    width: 8px;
    height: 8px;
    background: #ffd700;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
        transform: scale(1);
    }

    50% {
        opacity: 0.5;
        transform: scale(0.8);
    }
}

/* ═══════════════════════════════════════════
   HERO SECTION
   ═══════════════════════════════════════════ */
.hero {
    text-align: center;
    margin-bottom: 30px;
    padding: 20px 0;
}

.hero-title {
    font-size: 42px;
    font-weight: 900;
    margin-bottom: 12px;
    line-height: 1.2;
    background: linear-gradient(135deg, #fff 0%, #ffd700 50%, #ffaa00 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: shimmer 3s ease-in-out infinite;
}

@keyframes shimmer {

    0%,
    100% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }
}

.hero-subtitle {
    color: rgba(255, 255, 255, 0.7);
    font-size: 16px;
    margin-bottom: 24px;
    line-height: 1.6;
}

.hero-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    align-items: center;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 18px;
    padding: 16px 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    width: 100%;
    box-sizing: border-box;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.25);
    margin-top: 18px;
}

.stat {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 6px 12px;
    text-align: center;
    position: relative;
}

.stat:not(:last-child)::after {
    content: '';
    position: absolute;
    right: 0;
    top: 15%;
    height: 70%;
    width: 1px;
    background: rgba(255, 255, 255, 0.12);
}

.stat-icon-mini {
    font-size: 26px;
    flex-shrink: 0;
    filter: drop-shadow(0 2px 8px rgba(255, 215, 0, 0.3));
}

.stat-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.stat-value {
    font-family: 'Outfit', 'Inter', -apple-system, sans-serif;
    font-size: 22px;
    font-weight: 800;
    color: #ffd700;
    line-height: 1.15;
    letter-spacing: -0.5px;
    text-align: center;
    width: 100%;
}

.stat-label {
    font-size: 12px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.75);
    margin-top: 3px;
    white-space: nowrap;
    text-align: center;
}

/* ═══════════════════════════════════════════
   CARDS
   ═══════════════════════════════════════════ */
.card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    border-radius: 24px;
    padding: 28px;
    margin-bottom: 24px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}

.card-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
}

.card-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.2), rgba(255, 170, 0, 0.1));
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    border: 1px solid rgba(255, 215, 0, 0.2);
}

.card-title {
    font-size: 20px;
    font-weight: 800;
    color: #fff;
    margin-bottom: 4px;
}

.card-subtitle {
    color: rgba(255, 255, 255, 0.6);
    font-size: 14px;
}

/* ═══════════════════════════════════════════
   PROGRESS BAR
   ═══════════════════════════════════════════ */
.progress-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 30px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.progress-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    flex: 1;
    position: relative;
}

.progress-circle {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.5);
    transition: all 0.3s ease;
}

.progress-step.active .progress-circle {
    background: linear-gradient(135deg, #ffd700, #ffaa00);
    border-color: #ffd700;
    color: #1a1a2e;
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.4);
}

.progress-step.completed .progress-circle {
    background: linear-gradient(135deg, #28a745, #20c997);
    border-color: #28a745;
    color: #fff;
}

.progress-label {
    font-size: 11px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.5);
    text-align: center;
}

.progress-step.active .progress-label {
    color: #ffd700;
}

.progress-step.completed .progress-label {
    color: #28a745;
}

.progress-line {
    flex: 1;
    height: 2px;
    background: rgba(255, 255, 255, 0.1);
    margin: 0 8px;
    margin-bottom: 24px;
    position: relative;
    overflow: hidden;
}

.progress-line::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, #ffd700, transparent);
    animation: progress-shimmer 2s infinite;
}

@keyframes progress-shimmer {
    0% {
        left: -100%;
    }

    100% {
        left: 100%;
    }
}

/* ═══════════════════════════════════════════
   STEP SECTIONS
   ═══════════════════════════════════════════ */
.step-section {
    margin-bottom: 20px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    opacity: 0.5;
    transition: all 0.3s ease;
}

.step-section.active {
    opacity: 1;
    border-color: rgba(255, 215, 0, 0.3);
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.05);
}

.step-section:last-child {
    margin-bottom: 0;
}

.step-header {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 16px;
}

.step-number {
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, #ffd700, #ffaa00);
    color: #1a1a2e;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 800;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(255, 215, 0, 0.3);
}

.step-title {
    font-size: 16px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 4px;
}

.step-desc {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.5);
}

.step-content {
    padding-left: 44px;
}

/* ═══════════════════════════════════════════
   INPUT GROUP
   ═══════════════════════════════════════════ */
.input-group {
    display: flex;
    gap: 10px;
}

.input-wrapper {
    flex: 1;
    position: relative;
}

.input-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 16px;
    opacity: 0.5;
}

.input-wrapper input {
    width: 100%;
    padding: 14px 16px 14px 42px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    font-size: 14px;
    color: #fff;
    outline: none;
    transition: all 0.3s ease;
    font-family: 'Inter', sans-serif;
}

.input-wrapper input::placeholder {
    color: rgba(255, 255, 255, 0.3);
}

.input-wrapper input:focus {
    border-color: #ffd700;
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.1);
    background: rgba(255, 255, 255, 0.08);
}

/* ═══════════════════════════════════════════
   BUTTONS
   ═══════════════════════════════════════════ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 24px;
    border: none;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.25s ease;
    white-space: nowrap;
    font-family: 'Inter', sans-serif;
    text-decoration: none;
    touch-action: manipulation;
    user-select: none;
    -webkit-user-select: none;
    -webkit-tap-highlight-color: transparent;
    position: relative;
}

/* Ensure inner elements never intercept clicks / touches on buttons */
.btn > *,
.btn span,
.btn-icon,
.btn-text {
    pointer-events: none;
}

/* Re-allow pointer events when admin live edit mode is active */
.live-editable-active [data-edit-key] {
    pointer-events: auto !important;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
    pointer-events: none !important;
}

/* Instant tactile feedback on touch/click */
.btn:active:not(:disabled) {
    transform: scale(0.97) !important;
    opacity: 0.92;
    transition: transform 0.05s ease, opacity 0.05s ease;
}

.btn-icon {
    font-size: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.btn-secondary {
    background: linear-gradient(135deg, #6c757d, #495057);
    color: white;
    box-shadow: 0 4px 15px rgba(108, 117, 125, 0.3);
}

.btn-gold {
    background: linear-gradient(135deg, #ffd700, #ffaa00, #ff8c00);
    color: #1a1a2e;
    font-size: 16px;
    padding: 16px 32px;
    width: 100%;
    box-shadow: 0 4px 20px rgba(255, 215, 0, 0.3);
    position: relative;
    overflow: hidden;
}

.btn-gold::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    animation: btn-shine 2s infinite;
    pointer-events: none !important;
}

@keyframes btn-shine {
    0% {
        left: -100%;
    }

    100% {
        left: 100%;
    }
}

.btn-download {
    background: linear-gradient(135deg, #28a745, #20c997);
    color: white;
    width: 100%;
    margin-top: 16px;
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.3);
}

/* Hover effects ONLY on desktop/fine pointers to prevent two-tap bug on mobile devices */
@media (hover: hover) and (pointer: fine) {
    .btn-primary:hover:not(:disabled) {
        transform: translateY(-2px);
        box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
    }

    .btn-secondary:hover:not(:disabled) {
        transform: translateY(-2px);
        box-shadow: 0 6px 20px rgba(108, 117, 125, 0.4);
    }

    .btn-gold:hover:not(:disabled) {
        transform: translateY(-2px) scale(1.02);
        box-shadow: 0 8px 30px rgba(255, 215, 0, 0.4);
    }

    .btn-download:hover {
        transform: translateY(-2px);
        box-shadow: 0 6px 20px rgba(40, 167, 69, 0.4);
    }
}

/* ═══════════════════════════════════════════
   RESULT BOX
   ═══════════════════════════════════════════ */
.result-box {
    margin-top: 12px;
    padding: 14px 16px;
    border-radius: 12px;
    font-size: 14px;
    line-height: 1.6;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.result-box.success {
    background: rgba(40, 167, 69, 0.1);
    color: #28a745;
    border: 1px solid rgba(40, 167, 69, 0.3);
}

.result-box.error {
    background: rgba(220, 53, 69, 0.1);
    color: #dc3545;
    border: 1px solid rgba(220, 53, 69, 0.3);
}

.result-box.info {
    background: rgba(23, 162, 184, 0.1);
    color: #17a2b8;
    border: 1px solid rgba(23, 162, 184, 0.3);
}

.result-box.loading {
    background: rgba(255, 255, 255, 0.05);
    color: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.result-box code {
    background: rgba(255, 255, 255, 0.1);
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 13px;
    color: #ffd700;
}

/* Profile Card Styling */
.profile-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 6px 4px;
}

.profile-card-media {
    position: relative;
    width: 60px;
    height: 60px;
    min-width: 60px;
    border-radius: 50%;
    border: 3px solid #FFB800;
    box-shadow: 0 0 16px rgba(255, 184, 0, 0.35);
    overflow: hidden;
    background: rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
}

.profile-card-avatar {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.profile-card-initials {
    font-size: 20px;
    font-weight: 700;
    color: #FFB800;
    text-transform: uppercase;
}

.profile-card-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    text-align: left;
}

.profile-card-name {
    font-size: 17px;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: 0.3px;
}

.profile-card-sub {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.profile-badge {
    background: rgba(255, 184, 0, 0.15);
    color: #FFB800;
    border: 1px solid rgba(255, 184, 0, 0.4);
    font-size: 11px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 12px;
    text-transform: uppercase;
}

.profile-uid-text {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.45);
    font-family: monospace;
}

.hidden {
    display: none !important;
}

/* ═══════════════════════════════════════════
   KEEP GOLD SECTION
   ═══════════════════════════════════════════ */
.keep-gold-content {
    animation: slideIn 0.5s ease;
}

.keep-gold-card {
    display: flex;
    gap: 16px;
    background: rgba(255, 215, 0, 0.05);
    border-radius: 12px;
    padding: 16px;
    border: 1px solid rgba(255, 215, 0, 0.2);
    margin-bottom: 16px;
}

.keep-gold-icon {
    font-size: 32px;
    flex-shrink: 0;
}

.keep-gold-info h4 {
    font-size: 15px;
    font-weight: 700;
    color: #ffd700;
    margin-bottom: 8px;
}

.keep-gold-steps {
    padding-left: 20px;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.8);
    line-height: 2;
}

.keep-gold-steps li strong {
    color: #ffd700;
}

.keep-gold-detailed-steps {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-top: 12px;
    margin-bottom: 16px;
}

.step-guide-item {
    display: flex;
    gap: 12px;
    background: rgba(255, 255, 255, 0.025);
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 12px;
    padding: 12px 14px;
    transition: all 0.25s ease;
}

.step-guide-item:hover {
    background: rgba(255, 255, 255, 0.045);
    border-color: rgba(255, 215, 0, 0.3);
    transform: translateX(3px);
}

.step-guide-num {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: linear-gradient(135deg, #ffd700, #f59e0b);
    color: #000;
    font-weight: 800;
    font-size: 13px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(255, 215, 0, 0.25);
}

.step-guide-body {
    flex: 1;
    font-size: 13px;
    color: #e2e8f0;
    line-height: 1.6;
}

.step-guide-body strong {
    color: #ffd700;
}

.step-guide-body p {
    margin: 4px 0 0 0;
    color: #cbd5e1;
    font-size: 12.5px;
}

.step-note-box {
    margin-top: 8px;
    padding: 7px 11px;
    border-radius: 8px;
    background: rgba(255, 215, 0, 0.08);
    border-left: 3px solid #ffd700;
    font-size: 12px;
    color: #f1f5f9;
    line-height: 1.5;
}

.step-sub-note {
    margin-top: 5px;
    font-size: 11.5px;
    color: #94a3b8;
    font-style: italic;
}

.tag-gold {
    display: inline-block;
    padding: 2px 7px;
    background: rgba(255, 215, 0, 0.15);
    border: 1px solid rgba(255, 215, 0, 0.35);
    border-radius: 5px;
    color: #ffd700;
    font-weight: 700;
    font-size: 11.5px;
}

.badge-critical {
    display: inline-block;
    padding: 1px 6px;
    background: rgba(239, 68, 68, 0.2);
    border: 1px solid rgba(239, 68, 68, 0.4);
    border-radius: 4px;
    color: #ef4444;
    font-size: 10.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    vertical-align: middle;
}

.keep-gold-tips-card {
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.9), rgba(10, 15, 30, 0.95));
    border: 1px dashed rgba(255, 215, 0, 0.35);
    border-radius: 12px;
    padding: 14px 16px;
    margin-top: 14px;
}

/* ═══════════════════════════════════════════
   STEP 4 OPTION SELECTOR (VIDEO VS TEXT)
   ═══════════════════════════════════════════ */
.step4-mode-tabs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    background: rgba(15, 23, 42, 0.75);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 215, 0, 0.25);
    border-radius: 16px;
    padding: 6px;
    margin: 16px 0 20px 0;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.step4-mode-tab {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 16px;
    border-radius: 12px;
    border: 1px solid transparent;
    background: rgba(255, 255, 255, 0.03);
    color: rgba(255, 255, 255, 0.75);
    cursor: pointer;
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    font-size: 13.5px;
    transition: all 0.25s ease;
    user-select: none;
    outline: none;
    box-sizing: border-box;
}

.step4-mode-tab:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.07);
    border-color: rgba(255, 255, 255, 0.12);
}

.step4-mode-tab.active {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.22) 0%, rgba(245, 158, 11, 0.12) 100%);
    border: 1px solid rgba(255, 215, 0, 0.55);
    color: #ffd700;
    box-shadow: 0 4px 18px rgba(255, 215, 0, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.step4-tab-icon {
    font-size: 17px;
    line-height: 1;
}

.step4-tab-pill {
    font-size: 10.5px;
    padding: 2px 8px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.85);
    font-weight: 800;
    letter-spacing: 0.3px;
}

.step4-tab-pill.gold {
    background: rgba(255, 215, 0, 0.22);
    color: #ffd700;
    border: 1px solid rgba(255, 215, 0, 0.4);
}

.step4-pane {
    display: none;
}

.step4-pane.active {
    display: block;
    animation: fadeInStep4 0.3s ease;
}

@keyframes fadeInStep4 {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}

.step4-video-box {
    background: rgba(10, 15, 30, 0.85);
    border: 1px solid rgba(255, 215, 0, 0.28);
    border-radius: 16px;
    padding: 16px;
    margin-bottom: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.step4-video-wrapper {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    background: #000;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.step4-native-video {
    width: 100%;
    max-height: 480px;
    display: block;
    outline: none;
    background: #000;
}

.step4-iframe-video {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
}

.step4-iframe-video iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.step4-video-empty-box {
    text-align: center;
    padding: 36px 20px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px dashed rgba(255, 215, 0, 0.3);
    border-radius: 16px;
}

.step4-empty-icon-wrap {
    font-size: 38px;
    margin-bottom: 12px;
    display: inline-block;
}

.step4-empty-title {
    color: #ffd700;
    margin: 0 0 8px 0;
    font-size: 16.5px;
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
}

.step4-empty-desc {
    color: #94a3b8;
    font-size: 13px;
    max-width: 460px;
    margin: 0 auto 18px auto;
    font-family: 'Inter', sans-serif;
    line-height: 1.65;
}

.keep-gold-info {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.keep-gold-info h4 {
    font-family: 'Outfit', sans-serif;
    letter-spacing: -0.01em;
}

.keep-gold-detailed-steps {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 14px;
}

.step-guide-item {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    background: rgba(255, 255, 255, 0.025);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 14px 16px;
    transition: all 0.25s ease;
}

.step-guide-item:hover {
    background: rgba(255, 255, 255, 0.045);
    border-color: rgba(255, 215, 0, 0.3);
}

.step-guide-num {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: linear-gradient(135deg, #ffd700 0%, #ff9100 100%);
    color: #0b0f19;
    font-family: 'Outfit', sans-serif;
    font-size: 14px;
    font-weight: 900;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 3px 10px rgba(255, 215, 0, 0.3);
    margin-top: 2px;
}

.step-guide-body {
    flex: 1;
    font-family: 'Inter', sans-serif;
    color: #e2e8f0;
    font-size: 13px;
    line-height: 1.6;
}

.step-guide-heading {
    display: block;
    color: #fff;
    font-size: 14px;
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    margin-bottom: 4px;
}

.step-guide-body p {
    margin: 0;
    color: #cbd5e1;
    font-size: 12.5px;
    line-height: 1.6;
}

.step-guide-body p strong {
    color: #ffd700;
    font-weight: 700;
}

.step-note-box {
    margin-top: 8px;
    background: rgba(255, 215, 0, 0.06);
    border-left: 3px solid var(--primary-gold, #ffd700);
    border-radius: 0 8px 8px 0;
    padding: 8px 12px;
    font-size: 12px;
    color: #f1f5f9;
    line-height: 1.55;
}

.step-note-box.danger {
    background: rgba(239, 68, 68, 0.08);
    border-left-color: #ef4444;
}

.tag-gold {
    display: inline-block;
    background: rgba(255, 215, 0, 0.15);
    color: #ffd700;
    border: 1px solid rgba(255, 215, 0, 0.35);
    padding: 1px 7px;
    border-radius: 6px;
    font-weight: 700;
    font-size: 11.5px;
}

@media (max-width: 640px) {
    .step4-mode-tabs {
        grid-template-columns: 1fr;
    }
    .step4-mode-tab {
        padding: 10px 14px;
        font-size: 13px;
    }
}

/* ═══════════════════════════════════════════
   CONFIG INFO
   ═══════════════════════════════════════════ */
.config-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px;
}

.config-item {
    background: rgba(255, 255, 255, 0.03);
    padding: 16px;
    border-radius: 12px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s ease;
}

.config-item:hover {
    background: rgba(255, 255, 255, 0.06);
    transform: translateY(-2px);
}

.config-label {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.5);
    margin-bottom: 8px;
    font-weight: 500;
}

.config-value {
    font-size: 18px;
    font-weight: 800;
    color: #fff;
}

.config-value.active {
    color: #28a745;
}

.config-value.inactive {
    color: #dc3545;
}

/* ═══════════════════════════════════════════
   LOADING
   ═══════════════════════════════════════════ */
.loading {
    text-align: center;
    color: rgba(255, 255, 255, 0.5);
    padding: 20px;
    font-size: 14px;
}

/* ═══════════════════════════════════════════
   FOOTER
   ═══════════════════════════════════════════ */
.footer {
    text-align: center;
    color: rgba(255, 255, 255, 0.45);
    font-size: 12px;
    margin-top: auto;
    padding: 12px 0 2px 0;
}

/* ═══════════════════════════════════════════
   HEADER ACTIONS
   ═══════════════════════════════════════════ */
.header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.header-actions .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 38px;
    padding: 0 14px;
    font-size: 13px;
    font-weight: 600;
    border-radius: 10px;
    white-space: nowrap;
    box-sizing: border-box;
    transition: all 0.25s ease;
}

.header-actions .btn-icon {
    font-size: 14px;
    line-height: 1;
}

.btn-sm {
    padding: 8px 14px;
    font-size: 12px;
    border-radius: 8px;
}

/* ═══════════════════════════════════════════
   ALERTS
   ═══════════════════════════════════════════ */
.alert {
    padding: 14px 16px;
    border-radius: 12px;
    margin-bottom: 20px;
    font-size: 14px;
    line-height: 1.5;
    animation: slideIn 0.3s ease;
}

.alert-success {
    background: rgba(40, 167, 69, 0.1);
    color: #28a745;
    border: 1px solid rgba(40, 167, 69, 0.3);
}

.alert-error {
    background: rgba(220, 53, 69, 0.1);
    color: #dc3545;
    border: 1px solid rgba(220, 53, 69, 0.3);
}

.alert-info {
    background: rgba(23, 162, 184, 0.1);
    color: #17a2b8;
    border: 1px solid rgba(23, 162, 184, 0.3);
}

/* ═══════════════════════════════════════════
   STEP ALERT NOTICE (BƯỚC 3 - KÍCH HOẠT)
   ═══════════════════════════════════════════ */
.step-alert-notice {
    display: flex;
    align-items: center;
    gap: 14px;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.16) 0%, rgba(153, 27, 27, 0.1) 100%);
    border: 1.5px solid rgba(239, 68, 68, 0.45);
    border-radius: 14px;
    padding: 14px 18px;
    margin: 0 0 16px 0;
    box-shadow: 0 4px 20px rgba(239, 68, 68, 0.15);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    animation: fadeInNotice 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.step-alert-notice.hidden {
    display: none !important;
}

@keyframes fadeInNotice {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.step-alert-icon {
    font-size: 24px;
    line-height: 1;
    flex-shrink: 0;
    filter: drop-shadow(0 2px 6px rgba(239, 68, 68, 0.5));
}

.step-alert-text {
    font-size: 13.5px;
    line-height: 1.6;
    color: #fca5a5;
    font-weight: 500;
}

.step-alert-highlight {
    color: #ffd700 !important;
    font-weight: 800 !important;
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.35);
}

@media (max-width: 480px) {
    .step-alert-notice {
        padding: 12px 14px;
        gap: 10px;
    }
    .step-alert-icon {
        font-size: 20px;
    }
    .step-alert-text {
        font-size: 12.5px;
    }
}

/* ═══════════════════════════════════════════
   AUTH PAGES
   ═══════════════════════════════════════════ */
.auth-card {
    max-width: 480px;
    margin: 0 auto 24px;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-size: 13px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.8);
}

.btn-full {
    width: 100%;
}

.auth-links {
    text-align: center;
    margin-top: 20px;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.6);
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.auth-links a {
    color: #ffd700;
    text-decoration: none;
    font-weight: 600;
}

.auth-links a:hover {
    text-decoration: underline;
}

/* ═══════════════════════════════════════════
   WALLET PAGE
   ═══════════════════════════════════════════ */
.wallet-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-bottom: 24px;
}

.wallet-balance-card {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.1), rgba(255, 170, 0, 0.05));
    border-color: rgba(255, 215, 0, 0.2);
}

.balance-display {
    text-align: center;
    padding: 20px 0;
}

.balance-amount {
    font-size: 42px;
    font-weight: 900;
    background: linear-gradient(135deg, #ffd700, #ffaa00);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 8px;
}

.balance-label {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.6);
}

.credits-display {
    text-align: center;
    padding: 16px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.credits-count {
    font-size: 32px;
    font-weight: 800;
    color: #ffd700;
}

.credits-label {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.6);
    margin-top: 4px;
}

.wallet-action-card {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.topup-options {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}

.topup-option {
    padding: 12px 8px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    color: #fff;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Inter', sans-serif;
}

.topup-option:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
}

.topup-option.active {
    background: rgba(255, 215, 0, 0.1);
    border-color: #ffd700;
    color: #ffd700;
}

.credit-price {
    text-align: center;
    padding: 16px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.credit-price-value {
    font-size: 32px;
    font-weight: 800;
    color: #ffd700;
}

.credit-price-label {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.6);
    margin-top: 4px;
}

/* ═══════════════════════════════════════════
   TRANSACTIONS
   ═══════════════════════════════════════════ */
.transactions-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.transaction-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s ease;
}

.transaction-item:hover {
    background: rgba(255, 255, 255, 0.06);
}

.transaction-icon {
    font-size: 20px;
    flex-shrink: 0;
}

.transaction-info {
    flex: 1;
}

.transaction-desc {
    font-size: 14px;
    font-weight: 600;
    color: #fff;
}

.transaction-date {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.5);
    margin-top: 2px;
}

.transaction-amount {
    font-size: 14px;
    font-weight: 700;
}

.amount-positive {
    color: #28a745;
}

.amount-negative {
    color: #dc3545;
}

.amount-neutral {
    color: rgba(255, 255, 255, 0.6);
}

.transaction-status {
    font-size: 11px;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 20px;
    text-transform: capitalize;
}

.status-success,
.status-active,
.status-resolved {
    background: rgba(40, 167, 69, 0.1);
    color: #28a745;
    border: 1px solid rgba(40, 167, 69, 0.3);
}

.status-failed,
.status-cancelled,
.status-canceled,
.status-closed {
    background: rgba(220, 53, 69, 0.1);
    color: #dc3545;
    border: 1px solid rgba(220, 53, 69, 0.3);
}

.status-pending,
.status-in_progress,
.status-processing,
.status-open {
    background: rgba(255, 193, 7, 0.1);
    color: #ffc107;
    border: 1px solid rgba(255, 193, 7, 0.3);
}

.empty-state {
    text-align: center;
    color: rgba(255, 255, 255, 0.5);
    padding: 30px;
    font-size: 14px;
}

/* ═══════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════ */
@media (max-width: 768px) {
    .container {
        padding: 12px;
    }

    .hero-title {
        font-size: 32px;
    }

    .hero-stats {
        gap: 16px;
        padding: 12px 16px;
    }

    .stat-value {
        font-size: 20px;
    }

    .input-group {
        flex-direction: column;
    }

    .input-wrapper input,
    input[type="text"],
    input[type="password"],
    input[type="email"],
    input[type="number"],
    select,
    textarea {
        font-size: 16px !important; /* Ngăn iOS Safari tự động zoom trang khi người dùng chạm vào ô nhập */
    }

    .btn {
        width: 100%;
    }

    .input-group .btn,
    .auth-form .btn,
    .step-content .btn {
        min-height: 48px !important;
        font-size: 15px !important;
    }

    .step-content {
        padding-left: 0;
    }

    .progress-bar {
        padding: 12px;
    }

    .progress-label {
        font-size: 9px;
    }

    .progress-circle {
        width: 28px;
        height: 28px;
        font-size: 12px;
    }

    .card {
        padding: 20px;
    }

    .keep-gold-card {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .header {
        padding: 12px 16px;
    }

    .logo-main {
        font-size: 16px;
    }

    .header-badge {
        font-size: 10px;
        padding: 6px 10px;
    }

    .hero-title {
        font-size: 28px;
    }

    .hero-subtitle {
        font-size: 14px;
    }

    .stat-value {
        font-size: 18px;
    }

    .stat-label {
        font-size: 10px;
    }
}

/* ═══════════════════════════════════════════
   ADMIN PAGE
   ═══════════════════════════════════════════ */
.admin-nav {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.admin-nav-link {
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.admin-nav-link:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #ffd700;
}

.admin-container {
    max-width: 960px;
    margin: 0 auto;
}

.admin-title {
    font-size: 28px;
    font-weight: 900;
    margin-bottom: 24px;
    background: linear-gradient(135deg, #fff 0%, #ffd700 50%, #ffaa00 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.admin-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.admin-stat-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 20px;
    text-align: center;
}

.admin-stat-value {
    font-size: 32px;
    font-weight: 900;
    color: #ffd700;
    margin-bottom: 4px;
}

.admin-stat-label {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.6);
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 24px;
}

.admin-table th {
    text-align: left;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.05);
    color: rgba(255, 255, 255, 0.7);
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.admin-table td {
    padding: 12px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    font-size: 14px;
    color: rgba(255, 255, 255, 0.9);
}

.admin-table tr:hover td {
    background: rgba(255, 255, 255, 0.02);
}

.admin-table .actions {
    display: flex;
    gap: 8px;
}

.admin-table .btn-sm {
    padding: 6px 12px;
    font-size: 11px;
}

.admin-section-title {
    font-size: 18px;
    font-weight: 800;
    margin-bottom: 16px;
    color: #fff;
}

.admin-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 24px;
}

.admin-form .form-control {
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    font-size: 14px;
    color: #fff;
    outline: none;
    font-family: 'Inter', sans-serif;
    transition: all 0.3s ease;
}

.admin-form .form-control:focus {
    border-color: #ffd700;
}

.admin-form .form-control::placeholder {
    color: rgba(255, 255, 255, 0.3);
}

.admin-form textarea.form-control {
    resize: vertical;
    min-height: 80px;
}

/* ═══════════════════════════════════════════
   SUPPORT PAGE
   ═══════════════════════════════════════════ */
.support-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 24px;
}

.support-form-card,
.support-tickets-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 24px;
}

.support-card-title {
    font-size: 18px;
    font-weight: 800;
    margin-bottom: 16px;
    color: #fff;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    display: flex;
    align-items: center;
    gap: 8px;
}

.support-form-card form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.support-form-card .form-control {
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    font-size: 14px;
    color: #fff;
    outline: none;
    font-family: 'Inter', sans-serif;
    transition: all 0.3s ease;
    width: 100%;
}

.support-form-card .form-control:focus {
    border-color: #ffd700;
}

.support-form-card .form-control::placeholder {
    color: rgba(255, 255, 255, 0.3);
}

.support-form-card textarea.form-control {
    resize: vertical;
}

.tickets-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.ticket-item {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 16px;
}

.ticket-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.ticket-subject {
    font-size: 14px;
    font-weight: 700;
    color: #fff;
}

.ticket-message {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.6;
    margin-bottom: 8px;
}

.ticket-reply {
    font-size: 13px;
    color: #28a745;
    background: rgba(40, 167, 69, 0.05);
    border-radius: 8px;
    padding: 10px;
    margin-bottom: 8px;
    border-left: 3px solid #28a745;
}

.ticket-date {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.4);
}

.status-open {
    background: rgba(255, 193, 7, 0.1);
    color: #ffc107;
    border: 1px solid rgba(255, 193, 7, 0.3);
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
}

.status-answered {
    background: rgba(40, 167, 69, 0.1);
    color: #28a745;
    border: 1px solid rgba(40, 167, 69, 0.3);
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
}

.status-closed {
    background: rgba(108, 117, 125, 0.1);
    color: #6c757d;
    border: 1px solid rgba(108, 117, 125, 0.3);
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
}

/* ═══════════════════════════════════════════
   ADMIN & DASHBOARD WIDE CONTAINER
   ═══════════════════════════════════════════ */
.container.admin-container-wide {
    max-width: 1320px;
    width: 95%;
    margin: 0 auto;
    padding: 24px 16px;
}

/* ═══════════════════════════════════════════
   AUTH & FORM LAYOUTS
   ═══════════════════════════════════════════ */
.auth-card {
    max-width: 460px;
    margin: 0 auto 30px auto;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    text-align: left;
}

.form-group label,
label {
    font-family: 'Inter', sans-serif;
    font-size: 13.5px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.85);
    letter-spacing: 0.01em;
}

.btn-full {
    width: 100%;
}

.auth-links {
    margin-top: 24px;
    text-align: center;
    font-size: 13.5px;
    color: rgba(255, 255, 255, 0.6);
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.auth-links a {
    color: #ffd700;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s ease, text-shadow 0.2s ease;
}

.auth-links a:hover {
    color: #fff;
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

/* ═══════════════════════════════════════════
   FLASH ALERTS & AUTO-DISMISS TOAST
   ═══════════════════════════════════════════ */
.alerts-container {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - 32px);
    max-width: 480px;
    z-index: 999999;
    pointer-events: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    transition: all 0.3s ease;
}

.admin-container-wide .alerts-container {
    max-width: 520px;
}

.alert {
    pointer-events: auto;
    position: relative;
    width: 100%;
    padding: 13px 18px;
    border-radius: 14px;
    font-family: 'Inter', sans-serif;
    font-size: 13.5px;
    font-weight: 600;
    line-height: 1.45;
    margin-bottom: 0;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.7), 0 0 20px rgba(0, 0, 0, 0.4);
    box-sizing: border-box;
    transition: opacity 0.35s ease, transform 0.35s ease;
}

/* Auto-dismiss toast animation: Thông báo mờ nổi cố định, tự biến mất mượt mà sau 3.6s không giật */
.alert-success,
.alert-info,
.alert-warning,
.alert-auto-dismiss {
    animation: alertToastFadeInOut 3.8s forwards cubic-bezier(0.16, 1, 0.3, 1);
}

.alert:hover {
    animation-play-state: paused;
}

@keyframes alertToastFadeInOut {
    0% {
        opacity: 0;
        transform: translateY(-16px) scale(0.96);
    }
    10% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
    82% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
    100% {
        opacity: 0;
        transform: translateY(-16px) scale(0.96);
        visibility: hidden;
        pointer-events: none;
    }
}

.alert-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 2.5px;
    width: 100%;
    border-radius: 0 0 14px 14px;
    animation: alertProgressBar 3.5s linear forwards;
    opacity: 0.85;
}

.alert:hover .alert-progress {
    animation-play-state: paused;
}

@keyframes alertProgressBar {
    0% { width: 100%; }
    100% { width: 0%; }
}

.alert.alert-fading {
    opacity: 0 !important;
    transform: translateY(-16px) scale(0.96) !important;
    visibility: hidden !important;
    pointer-events: none !important;
    transition: opacity 0.35s ease, transform 0.35s ease !important;
}

.alert-icon {
    font-size: 15px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    flex-shrink: 0;
    line-height: 1;
}

.alert-text {
    flex: 1;
}

.alert-close {
    background: transparent;
    border: none;
    color: inherit;
    font-size: 15px;
    line-height: 1;
    padding: 2px 6px;
    cursor: pointer;
    opacity: 0.6;
    border-radius: 6px;
    transition: opacity 0.2s, background 0.2s;
    margin-left: auto;
}

.alert-close:hover {
    opacity: 1;
    background: rgba(255, 255, 255, 0.12);
}

.alert-success {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.25) 0%, rgba(5, 150, 105, 0.16) 100%);
    border: 1.5px solid rgba(16, 185, 129, 0.55);
    color: #ecfdf5;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4), 0 0 16px rgba(16, 185, 129, 0.25);
}
.alert-success .alert-icon {
    background: rgba(16, 185, 129, 0.35);
    color: #34d399;
    font-weight: 800;
    box-shadow: 0 0 8px rgba(16, 185, 129, 0.4);
}
.alert-success .alert-progress {
    background: linear-gradient(90deg, #10b981, #34d399, #6ee7b7);
    box-shadow: 0 0 6px rgba(52, 211, 153, 0.6);
}

.alert-danger,
.alert-error {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.2) 0%, rgba(185, 28, 28, 0.12) 100%);
    border: 1.5px solid rgba(239, 68, 68, 0.45);
    color: #fca5a5;
    box-shadow: 0 4px 20px rgba(239, 68, 68, 0.18);
}
.alert-danger .alert-icon,
.alert-error .alert-icon {
    background: rgba(239, 68, 68, 0.3);
    color: #ef4444;
}

.alert-warning {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.2) 0%, rgba(217, 119, 6, 0.12) 100%);
    border: 1.5px solid rgba(245, 158, 11, 0.45);
    color: #fde68a;
    box-shadow: 0 4px 20px rgba(245, 158, 11, 0.18);
}
.alert-warning .alert-icon {
    background: rgba(245, 158, 11, 0.3);
    color: #f59e0b;
}

.alert-info {
    background: linear-gradient(135deg, rgba(56, 189, 248, 0.2) 0%, rgba(14, 165, 233, 0.12) 100%);
    border: 1.5px solid rgba(56, 189, 248, 0.45);
    color: #bae6fd;
    box-shadow: 0 4px 20px rgba(56, 189, 248, 0.18);
}
.alert-info .alert-icon {
    background: rgba(56, 189, 248, 0.3);
    color: #38bdf8;
}

/* ═══════════════════════════════════════════
   ADMIN NAVIGATION
   ═══════════════════════════════════════════ */
.admin-nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-bottom: 28px;
    padding: 12px 18px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    backdrop-filter: blur(16px);
}

.admin-nav-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 18px;
    border-radius: 12px;
    font-family: 'Outfit', sans-serif;
    font-size: 13.5px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    transition: all 0.25s ease;
}

.admin-nav-link:hover {
    color: #ffd700;
    background: rgba(255, 215, 0, 0.1);
    border-color: rgba(255, 215, 0, 0.35);
    transform: translateY(-1px);
}

/* ═══════════════════════════════════════════
   ADMIN MAIN CONTAINER
   ═══════════════════════════════════════════ */
.admin-container {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 24px;
    padding: 30px;
    backdrop-filter: blur(20px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
    margin-bottom: 36px;
}

.admin-title {
    font-family: 'Outfit', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 28px;
    font-weight: 800;
    margin-bottom: 24px;
    color: #fff;
    letter-spacing: -0.02em;
    display: flex;
    align-items: center;
    gap: 12px;
}

/* ═══════════════════════════════════════════
   ADMIN STATS GRID
   ═══════════════════════════════════════════ */
.admin-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 16px;
    margin-bottom: 28px;
}

.admin-stats .stat-card {
    background: rgba(255, 255, 255, 0.035);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 18px;
    padding: 18px 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.admin-stats .stat-card:hover {
    transform: translateY(-3px);
    border-color: rgba(255, 215, 0, 0.35);
    background: rgba(255, 215, 0, 0.04);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.admin-stats .stat-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.2), rgba(255, 170, 0, 0.08));
    border: 1px solid rgba(255, 215, 0, 0.25);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    flex-shrink: 0;
}

.admin-stats .stat-info {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.admin-stats .stat-value {
    font-family: 'Outfit', sans-serif;
    font-size: 22px;
    font-weight: 800;
    color: #ffd700;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.admin-stats .stat-label {
    font-family: 'Inter', sans-serif;
    font-size: 12px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.6);
    margin-top: 4px;
}

/* ═══════════════════════════════════════════
   ADMIN TABS
   ═══════════════════════════════════════════ */
.admin-tabs {
    display: flex;
    gap: 8px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    padding-bottom: 12px;
    margin-bottom: 24px;
    overflow-x: auto;
    scrollbar-width: thin;
    cursor: grab;
    user-select: none;
    -webkit-user-select: none;
}

.admin-tabs.is-dragging {
    cursor: grabbing !important;
}

.admin-tab {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    color: rgba(255, 255, 255, 0.7);
    font-family: 'Outfit', sans-serif;
    font-size: 13.5px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.25s ease;
}

.admin-tab:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.15);
}

.admin-tab.active {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.2), rgba(255, 170, 0, 0.08));
    border-color: rgba(255, 215, 0, 0.45);
    color: #ffd700;
    box-shadow: 0 4px 16px rgba(255, 215, 0, 0.15);
}

.admin-tab-content {
    display: none;
    animation: fadeInAdminTab 0.3s ease-out;
}

.admin-tab-content.active {
    display: block;
}

@keyframes fadeInAdminTab {
    from {
        opacity: 0;
        transform: translateY(6px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ═══════════════════════════════════════════
   ADMIN MOBILE TAB DROPDOWN (MENU XỔ XUỐNG)
   ═══════════════════════════════════════════ */
.admin-mobile-tab-nav,
.client-mobile-tab-nav {
    display: none;
    margin-bottom: 22px;
}

.admin-mobile-tab-card {
    background: linear-gradient(135deg, rgba(20, 24, 42, 0.95), rgba(12, 14, 28, 0.95));
    border: 1.5px solid rgba(255, 215, 0, 0.35);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5), 0 0 20px rgba(255, 215, 0, 0.1);
    border-radius: 16px;
    padding: 14px 16px;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.admin-mobile-tab-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 11.5px;
    font-weight: 800;
    letter-spacing: 0.6px;
    color: #ffd700;
    margin-bottom: 10px;
    text-transform: uppercase;
}

.admin-mobile-tab-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #ffd700;
    box-shadow: 0 0 10px #ffd700;
    display: inline-block;
}

.admin-mobile-select-wrap {
    position: relative;
    display: flex;
    align-items: center;
    background: rgba(10, 12, 22, 0.95);
    border: 1.5px solid rgba(255, 255, 255, 0.15);
    border-radius: 12px;
    padding: 2px 14px;
    transition: all 0.25s ease;
}

.admin-mobile-select-wrap:focus-within {
    border-color: #ffd700;
    box-shadow: 0 0 16px rgba(255, 215, 0, 0.35);
}

.admin-mobile-select-icon {
    font-size: 20px;
    margin-right: 10px;
    flex-shrink: 0;
}

.admin-mobile-select {
    width: 100%;
    background: transparent;
    border: none;
    color: #ffffff;
    font-family: 'Outfit', sans-serif;
    font-size: 15px;
    font-weight: 700;
    padding: 12px 30px 12px 0;
    outline: none;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
}

.admin-mobile-select option {
    background: #141424;
    color: #ffffff;
    font-size: 14px;
    padding: 10px;
}

.admin-mobile-select-chevron {
    position: absolute;
    right: 14px;
    color: #ffd700;
    pointer-events: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ═══════════════════════════════════════════
   CTV ADMIN KPI & TIERS
   ═══════════════════════════════════════════ */
.ctv-admin-kpi-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
    margin-bottom: 22px;
}

.ctv-kpi-box {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 14px;
    padding: 16px;
    position: relative;
    overflow: hidden;
    transition: transform 0.25s ease, border-color 0.25s ease;
}

.ctv-kpi-box:hover {
    transform: translateY(-2px);
}

.ctv-kpi-badge {
    font-size: 11.5px;
    font-weight: 800;
    color: #ffd700;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}

.ctv-kpi-val {
    font-size: 24px;
    font-weight: 900;
    font-family: 'Outfit', sans-serif;
    color: #ffffff;
    margin-bottom: 4px;
}

.ctv-kpi-desc {
    font-size: 11.5px;
    color: #94a3b8;
    line-height: 1.4;
}

.ctv-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 10px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 700;
}

.badge-tier-gold {
    background: rgba(255, 215, 0, 0.15);
    border: 1px solid rgba(255, 215, 0, 0.4);
    color: #ffd700;
    box-shadow: 0 0 10px rgba(255, 215, 0, 0.15);
}

.badge-tier-silver {
    background: rgba(203, 213, 225, 0.15);
    border: 1px solid rgba(203, 213, 225, 0.35);
    color: #f1f5f9;
}

.badge-tier-bronze {
    background: rgba(246, 173, 85, 0.15);
    border: 1px solid rgba(246, 173, 85, 0.35);
    color: #fbd38d;
}

.badge-tier-member {
    background: rgba(148, 163, 184, 0.12);
    border: 1px solid rgba(148, 163, 184, 0.25);
    color: #cbd5e1;
}

/* ═══════════════════════════════════════════
   UID LOCKET BADGE
   ═══════════════════════════════════════════ */
.uid-locket-badge {
    transition: all 0.2s ease;
}

.uid-locket-badge:hover {
    background: rgba(255, 215, 0, 0.22) !important;
    border-color: rgba(255, 215, 0, 0.55) !important;
    box-shadow: 0 0 12px rgba(255, 215, 0, 0.25);
    transform: translateY(-1px);
}

/* ═══════════════════════════════════════════
   ADMIN TABLES
   ═══════════════════════════════════════════ */
.admin-table-wrap {
    background: rgba(10, 10, 26, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 18px;
    overflow-x: auto;
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.25);
    -webkit-overflow-scrolling: touch;
}

.admin-table {
    width: 100%;
    min-width: 860px;
    border-collapse: collapse;
    font-family: 'Inter', sans-serif;
    font-size: 13px;
    text-align: left;
}

.admin-table thead th {
    background: rgba(255, 255, 255, 0.04);
    color: rgba(255, 255, 255, 0.65);
    font-family: 'Outfit', sans-serif;
    font-size: 11.5px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 14px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    white-space: nowrap;
}

.admin-table tbody td {
    padding: 14px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    vertical-align: middle;
    color: rgba(255, 255, 255, 0.85);
    line-height: 1.5;
}

.admin-table tbody tr {
    transition: background 0.2s ease;
}

.admin-table tbody tr:hover {
    background: rgba(255, 215, 0, 0.035);
}

.admin-table tbody tr:last-child td {
    border-bottom: none;
}

/* ═══════════════════════════════════════════
   ACTION BUTTONS & STATUS PILLS
   ═══════════════════════════════════════════ */
.btn-sm {
    padding: 6px 12px;
    font-size: 11.5px;
    font-weight: 600;
    border-radius: 8px;
    margin-right: 4px;
    margin-bottom: 4px;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid transparent;
    font-family: 'Outfit', sans-serif;
    text-decoration: none;
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.btn-success {
    background: linear-gradient(135deg, #10b981, #059669);
    color: #fff;
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.btn-danger {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: #fff;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

@media (hover: hover) and (pointer: fine) {
    .btn-secondary:hover {
        background: rgba(255, 255, 255, 0.15);
        color: #fff;
    }

    .btn-success:hover {
        box-shadow: 0 4px 12px rgba(16, 185, 129, 0.35);
        transform: translateY(-1px);
    }

    .btn-danger:hover {
        box-shadow: 0 4px 12px rgba(239, 68, 68, 0.35);
        transform: translateY(-1px);
    }
}

.status-active,
.status-resolved {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: rgba(16, 185, 129, 0.12);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.3);
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
}

.status-failed,
.status-cancelled,
.status-canceled {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: rgba(239, 68, 68, 0.12);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.3);
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
}

.status-in_progress,
.status-pending {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: rgba(245, 158, 11, 0.12);
    color: #f59e0b;
    border: 1px solid rgba(245, 158, 11, 0.3);
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
}

/* ═══════════════════════════════════════════
   RESPONSIVE OVERRIDES
   ═══════════════════════════════════════════ */
@media (max-width: 768px) {
    .container.admin-container-wide {
        width: 100%;
        max-width: 100%;
        padding: 12px 10px 4px 10px;
        box-sizing: border-box;
    }

    .admin-container {
        width: 100%;
        max-width: 100%;
        padding: 16px 10px;
        box-sizing: border-box;
    }

    .support-grid {
        grid-template-columns: 1fr;
    }
}

/* ═══════════════════════════════════════════
   HIGH CONTRAST & READABILITY ENHANCEMENTS
   ═══════════════════════════════════════════ */
.hero-subtitle,
.card-subtitle,
.step-desc,
.stat-label,
.admin-table th,
.feature-box-desc,
.faq-answer,
.transaction-date {
    color: #cbd5e1 !important;
}

.step-title,
.card-title,
.feature-box-title,
.faq-question {
    color: #ffffff !important;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
}

/* ═══════════════════════════════════════════
   CLIENT NAVIGATION TABS
   ═══════════════════════════════════════════ */
.client-tabs-nav {
    position: sticky;
    top: 88px;
    z-index: 990;
    display: flex;
    gap: 10px;
    background: rgba(15, 15, 28, 0.92);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    padding: 8px;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    margin-bottom: 24px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
    cursor: grab;
    user-select: none;
    -webkit-user-select: none;
}

.client-tabs-nav.is-dragging {
    cursor: grabbing !important;
}

.client-tab-btn {
    flex: 1;
    min-width: 140px;
    padding: 12px 18px;
    border-radius: 12px;
    background: transparent;
    border: 1px solid transparent;
    color: #cbd5e1;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.25s ease;
    white-space: nowrap;
    touch-action: manipulation;
    user-select: none;
    -webkit-user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.client-tab-btn > * {
    pointer-events: none;
}

.client-tab-btn:active {
    transform: scale(0.96) !important;
    opacity: 0.9;
    transition: transform 0.05s ease;
}

@media (hover: hover) and (pointer: fine) {
    .client-tab-btn:hover {
        color: #ffffff;
        background: rgba(255, 255, 255, 0.08);
    }
}

.client-tab-btn.active {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.22) 0%, rgba(255, 170, 0, 0.12) 100%);
    color: #ffd700;
    border-color: rgba(255, 215, 0, 0.45);
    box-shadow: 0 4px 16px rgba(255, 215, 0, 0.18);
}

.client-tab-pane {
    display: none;
    animation: fadeInTab 0.22s ease-out;
}

.client-tab-pane.active {
    display: block;
}

@keyframes fadeInTab {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* ═══════════════════════════════════════════
   FEATURE CARDS GRID (BELOW STATUS)
   ═══════════════════════════════════════════ */
.feature-cards-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
    margin-top: 30px;
    margin-bottom: 26px;
}

.feature-card-box {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 18px;
    padding: 22px 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    backdrop-filter: blur(16px);
    transition: all 0.3s ease;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
    position: relative;
    overflow: hidden;
}

.feature-card-box::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, transparent, rgba(255, 215, 0, 0.5), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.feature-card-box:hover {
    transform: translateY(-4px);
    border-color: rgba(255, 215, 0, 0.35);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4), 0 0 20px rgba(255, 215, 0, 0.15);
}

.feature-card-box:hover::before {
    opacity: 1;
}

.feature-card-header {
    display: flex;
    align-items: center;
    gap: 12px;
}

.feature-card-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: rgba(255, 215, 0, 0.12);
    border: 1px solid rgba(255, 215, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    flex-shrink: 0;
}

.feature-card-title {
    font-size: 17px;
    font-weight: 800;
    color: #ffffff;
    margin: 0;
}

.feature-card-desc {
    font-size: 14px;
    line-height: 1.6;
    color: #cbd5e1;
    margin: 0;
}

/* ═══════════════════════════════════════════
   FAQ SECTION (CLEAN BOXES BELOW STATUS)
   ═══════════════════════════════════════════ */
.faq-section-wrap {
    margin-bottom: 30px;
}

.faq-section-title {
    font-size: 22px;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 18px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.faq-cards-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.faq-card-item {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 20px 22px;
    backdrop-filter: blur(14px);
    transition: all 0.25s ease;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.faq-card-item:hover {
    border-color: rgba(255, 215, 0, 0.3);
    background: rgba(255, 255, 255, 0.06);
}

.faq-card-q {
    font-size: 16px;
    font-weight: 700;
    color: #ffd700;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.faq-card-a {
    font-size: 14px;
    line-height: 1.65;
    color: #e2e8f0;
    margin: 0;
}

/* ═══════════════════════════════════════════
   WALLET KPI 4-GRID (VIEWS/VI.PHP)
   ═══════════════════════════════════════════ */
.wallet-kpi-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-bottom: 24px;
}

.wallet-kpi-card {
    background: rgba(255, 255, 255, 0.045);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 18px;
    padding: 20px 16px;
    text-align: center;
    backdrop-filter: blur(16px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
    text-decoration: none;
    position: relative;
    overflow: hidden;
}

.wallet-kpi-card.clickable {
    cursor: pointer;
    border-color: rgba(255, 215, 0, 0.3);
}

.wallet-kpi-card.clickable:hover {
    transform: translateY(-4px) scale(1.02);
    border-color: #ffd700;
    box-shadow: 0 12px 30px rgba(255, 215, 0, 0.22);
    background: rgba(255, 215, 0, 0.08);
}

.wallet-kpi-icon {
    font-size: 24px;
    margin-bottom: 6px;
}

.wallet-kpi-val {
    font-family: 'Outfit', sans-serif;
    font-size: 24px;
    font-weight: 800;
    color: #ffd700;
    line-height: 1.2;
    margin-bottom: 4px;
}

.wallet-kpi-lbl {
    font-size: 12px;
    font-weight: 600;
    color: #cbd5e1;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.wallet-kpi-hint {
    font-size: 11px;
    color: #ffaa00;
    margin-top: 6px;
    display: flex;
    align-items: center;
    gap: 4px;
    font-weight: 600;
}

/* ═══════════════════════════════════════════
   COLLABORATOR (CTV) DASHBOARD STYLING
   ═══════════════════════════════════════════ */
.ctv-card-banner {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.15) 0%, rgba(255, 107, 107, 0.1) 100%);
    border: 1px solid rgba(255, 215, 0, 0.35);
    border-radius: 20px;
    padding: 24px;
    margin-bottom: 24px;
    position: relative;
    overflow: hidden;
}

.ctv-progress-wrapper {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    height: 16px;
    position: relative;
    overflow: hidden;
    margin: 12px 0 8px 0;
}

.ctv-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #ffd700, #ffaa00, #ff6b6b);
    border-radius: 12px;
    transition: width 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.ctv-tier-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
    margin-top: 20px;
}

.ctv-tier-card {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 18px 14px;
    text-align: center;
    position: relative;
    transition: all 0.25s ease;
}

.ctv-tier-card.current {
    border-color: #ffd700;
    background: rgba(255, 215, 0, 0.09);
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.18);
}

.ctv-tier-badge {
    display: inline-block;
    padding: 3px 8px;
    background: rgba(255, 215, 0, 0.2);
    color: #ffd700;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 700;
    margin-bottom: 8px;
}

.ctv-tier-name {
    font-size: 15px;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 4px;
}

.ctv-tier-req {
    font-size: 12px;
    color: #cbd5e1;
    margin-bottom: 8px;
}

.ctv-tier-discount {
    font-size: 18px;
    font-weight: 800;
    color: #10b981;
}

.ctv-tier-price {
    font-size: 12px;
    color: #cbd5e1;
}

/* ═══════════════════════════════════════════
   PAGINATION CONTROLS
   ═══════════════════════════════════════════ */
.pagination-wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 4px;
    gap: 12px;
    flex-wrap: wrap;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    margin-top: 12px;
}

.pagination-info {
    font-size: 13px;
    color: #cbd5e1;
}

.pagination-buttons {
    display: flex;
    gap: 6px;
    align-items: center;
}

.page-btn {
    min-width: 34px;
    height: 34px;
    padding: 0 10px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #e2e8f0;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.page-btn:active:not(:disabled) {
    transform: scale(0.94);
}

@media (hover: hover) and (pointer: fine) {
    .page-btn:hover:not(:disabled) {
        background: rgba(255, 255, 255, 0.14);
        color: #ffffff;
        border-color: rgba(255, 215, 0, 0.4);
    }
}

.page-btn.active {
    background: #ffd700;
    color: #000;
    border-color: #ffd700;
    font-weight: 800;
}

.page-btn:disabled {
    opacity: 0.35;
    cursor: not-allowed;
    pointer-events: none;
}

/* ═══════════════════════════════════════════
   FLOATING TELEGRAM SUPPORT WIDGET & POPUP
   ═══════════════════════════════════════════ */
#telegram-support-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 9995;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 12px;
    pointer-events: none !important;
}

.telegram-widget-trigger,
.telegram-widget-btn,
.telegram-popup-card.open {
    pointer-events: auto !important;
}

.telegram-popup-card {
    width: 320px;
    background: #111827;
    border: 1.5px solid rgba(34, 158, 217, 0.45);
    border-radius: 20px;
    box-shadow: 0 16px 45px rgba(0, 0, 0, 0.7), 0 0 25px rgba(34, 158, 217, 0.25);
    backdrop-filter: blur(20px);
    overflow: hidden;
    transform: scale(0.85) translateY(20px);
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.telegram-popup-card.open {
    transform: scale(1) translateY(0);
    opacity: 1;
    pointer-events: auto !important;
}

.telegram-popup-header {
    background: linear-gradient(135deg, rgba(34, 158, 217, 0.25) 0%, rgba(15, 23, 42, 0.7) 100%);
    padding: 14px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.telegram-popup-close {
    background: transparent;
    border: none;
    color: #94a3b8;
    font-size: 16px;
    cursor: pointer;
    padding: 4px;
    border-radius: 6px;
    transition: color 0.2s;
}

.telegram-popup-close:hover {
    color: #ffffff;
}

.telegram-popup-body {
    padding: 16px 18px;
}

.telegram-widget-trigger {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    background: transparent;
    border: none;
    padding: 0;
}

.telegram-widget-btn {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, #229ED9 0%, #1782b6 100%);
    box-shadow: 0 6px 24px rgba(34, 158, 217, 0.45), 0 0 0 0 rgba(34, 158, 217, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border: none;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    animation: telePulse 3s infinite;
}

.telegram-widget-btn:hover {
    transform: scale(1.1) rotate(6deg);
    box-shadow: 0 8px 30px rgba(34, 158, 217, 0.65);
}

.telegram-widget-btn svg {
    width: 28px;
    height: 28px;
    fill: #ffffff;
}

.telegram-widget-bubble {
    display: none !important;
}

@keyframes telePulse {
    0% {
        box-shadow: 0 6px 24px rgba(34, 158, 217, 0.4), 0 0 0 0 rgba(34, 158, 217, 0.5);
    }

    70% {
        box-shadow: 0 6px 24px rgba(34, 158, 217, 0.4), 0 0 0 14px rgba(34, 158, 217, 0);
    }

    100% {
        box-shadow: 0 6px 24px rgba(34, 158, 217, 0.4), 0 0 0 0 rgba(34, 158, 217, 0);
    }
}

@keyframes bubbleFloat {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-3px);
    }
}

/* ═══════════════════════════════════════════
   ADMIN LIVE EDIT FLOATING BAR & EDITABLE
   ═══════════════════════════════════════════ */
#admin-live-editor-bar {
    position: fixed;
    bottom: 24px;
    left: 24px;
    top: auto;
    right: auto;
    transform: none;
    z-index: 10002;
    background: rgba(15, 15, 28, 0.96);
    border: 1.5px solid rgba(255, 215, 0, 0.65);
    border-radius: 20px;
    padding: 10px 18px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.75), 0 0 25px rgba(255, 215, 0, 0.2);
    display: flex;
    align-items: center;
    gap: 12px;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@media (max-width: 640px) {
    #admin-live-editor-bar {
        left: 10px;
        right: 10px;
        bottom: 12px;
        padding: 8px 12px;
        flex-wrap: wrap;
        justify-content: center;
        border-radius: 16px;
    }
}

.live-editable-active [data-edit-key] {
    outline: 1.5px dashed rgba(255, 215, 0, 0.7) !important;
    outline-offset: 3px;
    border-radius: 4px;
    cursor: text !important;
    transition: all 0.2s ease;
    display: inline-block;
    min-width: 14px;
}

.live-editable-active a:has([data-edit-key]),
.live-editable-active button:has([data-edit-key]) {
    cursor: text;
}

.live-editable-active [data-edit-key]:hover {
    outline: 2px solid #ffd700 !important;
    background: rgba(255, 215, 0, 0.2) !important;
}

.live-editable-active [data-edit-key]:focus {
    outline: 2px solid #00e5ff !important;
    background: rgba(0, 229, 255, 0.16) !important;
}

/* ═══════════════════════════════════════════
   LOGOUT CONFIRMATION MODAL
   ═══════════════════════════════════════════ */
.modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    z-index: 10005;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.25s ease;
}

.modal-backdrop.show {
    opacity: 1;
    visibility: visible;
}

.modal-box {
    background: #141424;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 20px;
    padding: 28px 24px;
    max-width: 420px;
    width: 90%;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.6);
    transform: scale(0.92);
    transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
    text-align: center;
}

.modal-backdrop.show .modal-box {
    transform: scale(1);
}

.modal-title {
    font-size: 20px;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 8px;
}

.modal-desc {
    font-size: 14px;
    color: #cbd5e1;
    line-height: 1.5;
    margin-bottom: 22px;
}

.modal-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
}

/* ═══════════════════════════════════════════
   DISCLAIMER FOOTER
   ═══════════════════════════════════════════ */
.footer-disclaimer {
    margin-top: 0;
    padding-top: 6px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 11.5px;
    line-height: 1.45;
    color: #94a3b8;
    text-align: center;
}

.footer-copyright {
    margin-top: 2px;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.55);
    text-align: center;
    margin-bottom: 0;
    padding-bottom: 0;
}

/* ═══════════════════════════════════════════
   COMPACT USERS TABLE (ADMIN TAB WITHOUT SCROLL)
   ═══════════════════════════════════════════ */
.compact-user-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.compact-user-title {
    font-weight: 700;
    color: #ffffff;
    font-size: 14px;
}

.compact-user-sub {
    font-size: 11.5px;
    color: #94a3b8;
}

.compact-asset-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.compact-action-btns {
    display: inline-grid;
    grid-template-columns: repeat(2, 42px);
    gap: 6px;
    justify-content: flex-end;
    align-items: center;
}

.compact-action-btns .btn-sm {
    width: 42px !important;
    height: 32px !important;
    padding: 0 !important;
    margin: 0 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    border-radius: 8px !important;
    box-sizing: border-box !important;
    line-height: 1 !important;
    text-align: center !important;
}

#tab-users .admin-table-wrap {
    overflow-x: hidden;
}

#tab-users .admin-table {
    min-width: 100%;
    width: 100%;
    table-layout: auto;
}

@media (max-width: 800px) {
    #tab-users .admin-table-wrap {
        overflow-x: auto;
    }
}

/* ═══════════════════════════════════════════
   BACKGROUND PARTICLES (SNOW & ICONS)
   ═══════════════════════════════════════════ */
#bg-particles-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

/* ═══════════════════════════════════════════
   RESPONSIVE OVERRIDES (MOBILE & TABLET)
   ═══════════════════════════════════════════ */
@media (max-width: 900px) {
    .hero-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 14px;
        padding: 14px 16px;
    }

    .stat:nth-child(2)::after {
        display: none;
    }

    .wallet-kpi-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .ctv-tier-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    /* Header & Action Buttons on Mobile - Ổn định 100%, chạm là ăn ngay, touch target 44px chuẩn công thái học */
    .header {
        position: relative !important;
        top: auto !important;
        z-index: 1000 !important;
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
        padding: 12px 14px;
        border-radius: 18px;
        margin-bottom: 16px;
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.35);
        pointer-events: auto !important;
    }

    .header .logo {
        justify-content: center;
        padding-bottom: 6px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.06);
        cursor: pointer;
        touch-action: manipulation;
        -webkit-tap-highlight-color: transparent;
    }

    .header-actions {
        display: grid !important;
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 8px !important;
        width: 100% !important;
        max-height: none !important;
        opacity: 1 !important;
        transform: none !important;
        overflow: visible !important;
        box-sizing: border-box !important;
        margin: 0 !important;
        pointer-events: auto !important;
    }

    .header-actions .btn {
        width: 100% !important;
        min-width: 0 !important;
        height: 44px !important;
        min-height: 44px !important;
        padding: 0 10px !important;
        font-size: 13.5px !important;
        font-weight: 700 !important;
        justify-content: center !important;
        border-radius: 12px !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        box-sizing: border-box !important;
        margin: 0 !important;
        touch-action: manipulation !important;
        -webkit-tap-highlight-color: transparent !important;
        cursor: pointer !important;
        pointer-events: auto !important;
    }

    .header-actions .btn:active {
        transform: scale(0.96) !important;
        opacity: 0.9 !important;
        transition: transform 0.05s ease !important;
    }

    /* Nếu có số nút lẻ (ví dụ 3 nút khi chưa đăng nhập, hoặc 5 nút khi đã đăng nhập), nút cuối cùng trải rộng cả hàng cân đối 100% */
    .header-actions .btn:nth-child(odd):last-child,
    .header-actions .btn-logout-trigger:nth-child(odd):last-child,
    .header-actions #header-btn-register:last-child {
        grid-column: 1 / -1 !important;
        width: 100% !important;
    }

    .header-actions #header-btn-register {
        background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 50%, #d946ef 100%) !important;
        border: 1px solid rgba(255, 255, 255, 0.25) !important;
        box-shadow: 0 4px 14px rgba(139, 92, 246, 0.4) !important;
        font-weight: 700 !important;
        color: #ffffff !important;
    }

    .header-actions .btn-logout-trigger {
        border-color: rgba(239, 68, 68, 0.35) !important;
        color: #fca5a5 !important;
        background: rgba(239, 68, 68, 0.08) !important;
    }

    @media (hover: hover) and (pointer: fine) {
        .header-actions .btn-logout-trigger:hover {
            background: rgba(239, 68, 68, 0.2) !important;
            border-color: rgba(239, 68, 68, 0.6) !important;
        }
    }

    /* Vô hiệu hóa spacer chống layout shift hoàn toàn */
    #header-mobile-spacer {
        display: none !important;
        height: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    /* Admin Navigation on mobile: 2x2 grid + full-width logout button */
    .admin-nav {
        display: grid !important;
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 8px !important;
        padding: 10px !important;
        margin-bottom: 18px !important;
        border-radius: 14px !important;
        width: 100% !important;
        box-sizing: border-box !important;
        overflow: hidden !important;
    }

    .admin-nav .admin-nav-link {
        font-size: 12px !important;
        padding: 9px 8px !important;
        justify-content: center !important;
        text-align: center !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        border-radius: 10px !important;
        min-width: 0 !important;
        margin: 0 !important;
    }

    .admin-nav .admin-nav-link.btn-logout-trigger {
        grid-column: 1 / -1 !important;
        margin-left: 0 !important;
        background: rgba(239, 68, 68, 0.1) !important;
        border-color: rgba(239, 68, 68, 0.3) !important;
        color: #fca5a5 !important;
    }

    /* Admin Main Containers on Mobile: Strict 100% viewport fit */
    .container.admin-container-wide {
        width: 100% !important;
        max-width: 100% !important;
        padding: 12px 10px 4px 10px !important;
        box-sizing: border-box !important;
        overflow-x: hidden !important;
    }

    .admin-container {
        width: 100% !important;
        max-width: 100% !important;
        padding: 16px 10px !important;
        border-radius: 18px !important;
        box-sizing: border-box !important;
        overflow-x: hidden !important;
        margin-bottom: 24px !important;
    }

    .admin-title {
        font-size: 21px !important;
        margin-bottom: 16px !important;
        gap: 8px !important;
        line-height: 1.3 !important;
        word-break: break-word !important;
    }

    /* Admin Real-time KPI Stats Grid on Mobile: Zero overflow, elegant 2-column cards */
    .admin-stats {
        display: grid !important;
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 8px !important;
        margin-bottom: 18px !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    .admin-stats .stat-card {
        min-width: 0 !important;
        width: 100% !important;
        padding: 10px 8px !important;
        gap: 8px !important;
        border-radius: 14px !important;
        box-sizing: border-box !important;
        display: flex !important;
        align-items: center !important;
        overflow: hidden !important;
    }

    .admin-stats .stat-icon {
        width: 36px !important;
        height: 36px !important;
        min-width: 36px !important;
        font-size: 17px !important;
        border-radius: 10px !important;
        flex-shrink: 0 !important;
    }

    .admin-stats .stat-info {
        min-width: 0 !important;
        flex: 1 1 auto !important;
        overflow: hidden !important;
    }

    .admin-stats .stat-value {
        font-size: 16px !important;
        font-weight: 800 !important;
        line-height: 1.2 !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }

    .admin-stats .stat-label {
        font-size: 10.5px !important;
        font-weight: 500 !important;
        line-height: 1.25 !important;
        margin-top: 2px !important;
        white-space: normal !important;
        word-break: break-word !important;
        display: -webkit-box !important;
        -webkit-line-clamp: 2 !important;
        -webkit-box-orient: vertical !important;
        overflow: hidden !important;
    }

    /* Chế độ Mobile: Ẩn thanh tabs cuộn ngang, Hiển thị thanh menu xổ xuống */
    .admin-tabs,
    .client-tabs-nav {
        display: none !important;
    }

    .admin-mobile-tab-nav,
    .client-mobile-tab-nav {
        display: block !important;
    }

    .admin-mobile-tab-card {
        padding: 12px 12px !important;
        border-radius: 14px !important;
        margin-bottom: 16px !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    .ctv-admin-kpi-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 8px !important;
    }

    .admin-table-wrap {
        width: 100% !important;
        max-width: 100% !important;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch !important;
        border-radius: 14px !important;
        box-sizing: border-box !important;
    }

    .admin-container .card {
        padding: 14px 12px !important;
        border-radius: 14px !important;
        box-sizing: border-box !important;
    }

    /* Responsive cho các hàng cấu hình và grid trong admin */
    .admin-container form div[style*="grid-template-columns"] {
        grid-template-columns: 1fr !important;
        gap: 10px !important;
    }
}

@media (max-width: 640px) {
    .container {
        padding: 14px 10px 2px 10px;
    }

    .footer {
        padding: 8px 0 2px 0;
    }

    .feature-cards-grid {
        grid-template-columns: 1fr;
    }

    .wallet-kpi-grid {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }

    .wallet-kpi-val {
        font-size: 20px;
    }

    .ctv-tier-grid {
        grid-template-columns: 1fr;
    }

    #telegram-support-container {
        bottom: 16px;
        right: 16px;
    }

    .hero-title {
        font-size: 32px;
    }

    .hero-stats {
        grid-template-columns: 1fr 1fr;
        gap: 8px;
        padding: 12px 10px;
    }

    .stat {
        gap: 8px;
        padding: 4px 6px;
    }

    .stat-icon-mini {
        font-size: 20px;
    }

    .stat-value {
        font-size: 18px;
    }

    .stat-label {
        font-size: 11px;
    }

    #desktop-qr-download {
        display: none !important;
    }
}

/* ═══════════════════════════════════════════
   BƯỚC 4: HÌNH ẢNH QR CODE TẢI PROFILE (PC / LAPTOP)
   ═══════════════════════════════════════════ */
.desktop-qr-card {
    display: flex;
    align-items: center;
    gap: 20px;
    background: rgba(15, 23, 42, 0.85);
    border: 1px solid rgba(255, 215, 0, 0.35);
    border-radius: 16px;
    padding: 18px 20px;
    margin: 16px 0 20px 0;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45), inset 0 0 18px rgba(255, 215, 0, 0.06);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.desktop-qr-card:hover {
    border-color: rgba(255, 215, 0, 0.65);
    transform: translateY(-2px);
    box-shadow: 0 14px 35px rgba(0, 0, 0, 0.55), 0 0 20px rgba(255, 215, 0, 0.15);
}

.desktop-qr-box {
    position: relative;
    width: 150px;
    height: 150px;
    min-width: 150px;
    background: #ffffff;
    border-radius: 12px;
    padding: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.4);
    overflow: hidden;
}

.desktop-qr-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    border-radius: 8px;
}

.desktop-qr-scan-line {
    position: absolute;
    top: 4px;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, #eab308, #ffd700, transparent);
    box-shadow: 0 0 10px #ffd700;
    animation: qrScanLaser 2.4s ease-in-out infinite alternate;
    pointer-events: none;
}

@keyframes qrScanLaser {
    0% { top: 4px; opacity: 0.3; }
    50% { opacity: 1; }
    100% { top: calc(100% - 7px); opacity: 0.3; }
}

.desktop-qr-content {
    flex: 1;
}

.desktop-qr-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(255, 215, 0, 0.12);
    border: 1px solid rgba(255, 215, 0, 0.4);
    color: #ffd700;
    font-size: 11px;
    font-weight: 800;
    padding: 3px 10px;
    border-radius: 999px;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.desktop-qr-tag-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #ffd700;
    box-shadow: 0 0 8px #ffd700;
}

.desktop-qr-title {
    font-size: 16px;
    font-weight: 700;
    color: #ffffff;
    margin: 0 0 6px 0;
    line-height: 1.3;
}

.desktop-qr-desc {
    font-size: 13px;
    color: #cbd5e1;
    line-height: 1.5;
    margin: 0 0 8px 0;
}

.desktop-qr-tip {
    font-size: 12px;
    color: #ffd700;
    background: rgba(255, 215, 0, 0.08);
    border-left: 3px solid #ffd700;
    padding: 6px 10px;
    border-radius: 0 6px 6px 0;
}