/* ===== CSS Variables ===== */
:root {
    --bg-dark: #0a0a0f;
    --bg-darker: #050508;
    --bg-card: #12121a;
    --bg-card-hover: #1a1a25;
    --bg-input: #1a1a25;

    --purple-primary: #8b5cf6;
    --purple-hover: #7c3aed;
    --purple-glow: rgba(139, 92, 246, 0.3);
    --purple-light: #a78bfa;

    --cyan-primary: #22d3ee;
    --cyan-glow: rgba(34, 211, 238, 0.3);

    --green-primary: #22c55e;
    --green-glow: rgba(34, 197, 94, 0.3);

    --text-primary: #ffffff;
    --text-secondary: #a1a1aa;
    --text-muted: #71717a;

    --border-color: #27272a;
    --border-light: #3f3f46;

    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;

    --transition-fast: 150ms ease;
    --transition-base: 200ms ease;
    --transition-slow: 300ms ease;

    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-full: 9999px;

    --shadow-glow: 0 0 30px var(--purple-glow);
    --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.3);
}

/* ===== Reset & Base ===== */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family);
    background: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
}

a {
    color: inherit;
    text-decoration: none;
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: none;
}

input {
    font-family: inherit;
    border: none;
    outline: none;
}

img {
    max-width: 100%;
    height: auto;
}

/* ===== Container ===== */
.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ===== Buttons ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 600;
    border-radius: var(--radius-md);
    transition: all var(--transition-base);
    white-space: nowrap;
}

.btn-primary {
    background: linear-gradient(135deg, var(--purple-primary), var(--purple-hover));
    color: white;
    box-shadow: 0 0 20px var(--purple-glow);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 30px var(--purple-glow);
}

.btn-ghost {
    color: var(--text-secondary);
    background: transparent;
}

.btn-ghost:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--border-light);
    color: var(--text-primary);
}

.btn-outline:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--purple-primary);
}

.btn-lg {
    padding: 14px 28px;
    font-size: 16px;
}

.btn-full {
    width: 100%;
}

/* ===== Header ===== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    background: rgba(10, 10, 15, 0.8);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 72px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo-icon {
    width: 32px;
    height: 32px;
    color: var(--purple-primary);
}

.logo-text {
    font-size: 22px;
    font-weight: 700;
    background: linear-gradient(135deg, var(--purple-primary), var(--cyan-primary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-link {
    padding: 10px 16px;
    font-size: 15px;
    font-weight: 500;
    color: var(--text-secondary);
    border-radius: var(--radius-md);
    transition: all var(--transition-base);
}

.nav-link:hover,
.nav-link.active {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.mobile-menu-btn {
    display: none;
    color: var(--text-primary);
    padding: 8px;
}

.mobile-menu {
    display: none;
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    background: var(--bg-dark);
    border-bottom: 1px solid var(--border-color);
    padding: 20px;
}

.mobile-menu.active {
    display: block;
}

.mobile-nav {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 16px;
}

.mobile-nav-link {
    padding: 12px 16px;
    font-size: 16px;
    font-weight: 500;
    color: var(--text-secondary);
    border-radius: var(--radius-md);
    transition: all var(--transition-base);
}

.mobile-nav-link:hover,
.mobile-nav-link.active {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

.mobile-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* ===== Hero Section ===== */
.hero {
    position: relative;
    min-height: 90vh;
    display: flex;
    align-items: center;
    padding-top: 72px;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    z-index: -1;
}

.hero-gradient {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 80% 50% at 50% 100%, rgba(139, 92, 246, 0.15), transparent),
        radial-gradient(ellipse 60% 40% at 20% 80%, rgba(34, 211, 238, 0.1), transparent),
        radial-gradient(ellipse 50% 30% at 80% 60%, rgba(236, 72, 153, 0.1), transparent);
}

.hero-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(139, 92, 246, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(139, 92, 246, 0.03) 1px, transparent 1px);
    background-size: 60px 60px;
    mask-image: radial-gradient(ellipse 70% 60% at 50% 100%, black, transparent);
}

.hero-content {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
    padding: 60px 20px;
    position: relative;
    z-index: 1;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: rgba(139, 92, 246, 0.15);
    border: 1px solid rgba(139, 92, 246, 0.3);
    border-radius: var(--radius-full);
    font-size: 14px;
    font-weight: 600;
    color: var(--purple-light);
    margin-bottom: 24px;
}

.hero-badge svg {
    color: #fbbf24;
}

.hero-title {
    font-size: clamp(36px, 6vw, 64px);
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 24px;
}

.gradient-text {
    background: linear-gradient(135deg, var(--purple-primary), var(--cyan-primary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 18px;
    color: var(--text-secondary);
    margin-bottom: 40px;
    line-height: 1.7;
}

.hero-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin-bottom: 48px;
    flex-wrap: wrap;
}

.hero-stats {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 32px;
    flex-wrap: wrap;
}

.hero-stat {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: var(--text-secondary);
}

.stat-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.stat-dot.green {
    background: var(--green-primary);
    box-shadow: 0 0 10px var(--green-glow);
}

.stat-dot.purple {
    background: var(--purple-primary);
    box-shadow: 0 0 10px var(--purple-glow);
}

.stat-dot.cyan {
    background: var(--cyan-primary);
    box-shadow: 0 0 10px var(--cyan-glow);
}

/* ===== Search Section ===== */
.search-section {
    padding: 40px 0;
    background: var(--bg-darker);
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.search-box {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 8px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    flex-wrap: wrap;
}

.search-input-wrapper {
    flex: 1;
    min-width: 250px;
    display: flex;
    align-items: center;
    gap: 12px;
    padding-left: 16px;
}

.search-icon {
    width: 20px;
    height: 20px;
    color: var(--text-muted);
    flex-shrink: 0;
}

.search-input {
    flex: 1;
    padding: 12px 0;
    background: transparent;
    color: var(--text-primary);
    font-size: 15px;
}

.search-input::placeholder {
    color: var(--text-muted);
}

.search-filters {
    display: flex;
    align-items: center;
    gap: 12px;
}

.filter-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
    transition: all var(--transition-base);
}

.filter-btn:hover {
    border-color: var(--purple-primary);
    color: var(--text-primary);
}

.search-btn {
    padding: 12px 24px;
}

.category-chips {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.chip {
    padding: 8px 16px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-full);
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
    transition: all var(--transition-base);
}

.chip:hover,
.chip.active {
    background: rgba(139, 92, 246, 0.15);
    border-color: var(--purple-primary);
    color: var(--purple-light);
}

/* ===== Stats Ticker ===== */
.stats-ticker {
    overflow: hidden;
    background: linear-gradient(90deg, var(--bg-darker), var(--bg-card), var(--bg-darker));
    border-bottom: 1px solid var(--border-color);
    padding: 12px 0;
}

.ticker-track {
    display: flex;
}

.ticker-content {
    display: flex;
    animation: ticker 30s linear infinite;
}

@keyframes ticker {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

.ticker-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 40px;
    white-space: nowrap;
    color: var(--text-secondary);
    font-size: 14px;
}

.ticker-item svg {
    color: var(--purple-primary);
}

.ticker-item strong {
    color: var(--text-primary);
    font-weight: 600;
}

/* ===== Listings Section ===== */
.listings-section {
    padding: 80px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 48px;
}

.section-title {
    font-size: clamp(28px, 4vw, 40px);
    font-weight: 700;
    margin-bottom: 16px;
}

.section-subtitle {
    font-size: 16px;
    color: var(--text-secondary);
    max-width: 500px;
    margin: 0 auto;
}

.listings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}

.section-footer {
    text-align: center;
    margin-top: 48px;
}

/* ===== Game Card ===== */
.game-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: all var(--transition-slow);
    position: relative;
}

.game-card:hover {
    transform: translateY(-4px);
    border-color: var(--purple-primary);
    box-shadow: var(--shadow-glow);
}

.card-image {
    position: relative;
    aspect-ratio: 16/10;
    background: var(--bg-darker);
    overflow: hidden;
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

.game-card:hover .card-image img {
    transform: scale(1.05);
}

.card-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 4px 10px;
    background: rgba(139, 92, 246, 0.9);
    border-radius: var(--radius-sm);
    font-size: 12px;
    font-weight: 600;
    color: white;
}

.card-favorite {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(10px);
    border-radius: 50%;
    color: var(--text-secondary);
    transition: all var(--transition-base);
}

.card-favorite:hover,
.card-favorite.active {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

.card-content {
    padding: 16px;
}

.card-game {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}

.game-icon {
    width: 24px;
    height: 24px;
    border-radius: var(--radius-sm);
    background: var(--bg-input);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
}

.game-name {
    font-size: 13px;
    color: var(--text-muted);
}

.card-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.card-rank,
.card-level {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 13px;
    color: var(--text-secondary);
}

.card-rank svg,
.card-level svg {
    width: 14px;
    height: 14px;
    color: var(--purple-primary);
}

.card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 12px;
    border-top: 1px solid var(--border-color);
}

.card-price {
    font-size: 20px;
    font-weight: 700;
    color: var(--cyan-primary);
}

.card-seller {
    display: flex;
    align-items: center;
    gap: 8px;
}

.seller-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--purple-primary), var(--cyan-primary));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 600;
}

.seller-rating {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 13px;
    color: var(--text-secondary);
}

.seller-rating svg {
    width: 14px;
    height: 14px;
    color: #fbbf24;
    fill: #fbbf24;
}

/* ===== Features Section ===== */
.features-section {
    padding: 60px 0;
    background: var(--bg-darker);
    border-top: 1px solid var(--border-color);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.feature-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 24px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    transition: all var(--transition-base);
}

.feature-card:hover {
    border-color: var(--purple-primary);
}

.feature-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-md);
    flex-shrink: 0;
}

.feature-icon svg {
    width: 24px;
    height: 24px;
}

.feature-icon.purple {
    background: rgba(139, 92, 246, 0.15);
    color: var(--purple-primary);
}

.feature-icon.cyan {
    background: rgba(34, 211, 238, 0.15);
    color: var(--cyan-primary);
}

.feature-icon.green {
    background: rgba(34, 197, 94, 0.15);
    color: var(--green-primary);
}

.feature-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 4px;
}

.feature-desc {
    font-size: 14px;
    color: var(--text-secondary);
}

/* ===== Footer ===== */
.footer {
    padding: 60px 0 24px;
    background: var(--bg-dark);
    border-top: 1px solid var(--border-color);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr repeat(3, 1fr);
    gap: 48px;
    margin-bottom: 48px;
}

.footer-desc {
    color: var(--text-secondary);
    font-size: 14px;
    margin-top: 16px;
    max-width: 300px;
}

.footer-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 16px;
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-link {
    font-size: 14px;
    color: var(--text-secondary);
    transition: color var(--transition-base);
}

.footer-link:hover {
    color: var(--purple-primary);
}

.footer-bottom {
    padding-top: 24px;
    border-top: 1px solid var(--border-color);
    text-align: center;
}

.footer-bottom p {
    font-size: 14px;
    color: var(--text-muted);
}

/* ===== Modal ===== */
.modal {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: none;
    align-items: flex-start;
    justify-content: center;
    padding: 0;
    overflow-y: auto;
}

.modal.active {
    display: flex;
}

.modal-backdrop {
    position: fixed;
    inset: 0;
    background: var(--bg-dark);
}

.modal-content {
    position: relative;
    width: 100%;
    max-width: 100%;
    min-height: 100vh;
    background: var(--bg-dark);
    border: none;
    border-radius: 0;
    padding: 24px;
    animation: modalIn 0.3s ease;
}

@keyframes modalIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Centered Modal Override */
.modal.modal-center {
    align-items: center;
    padding: 20px;
}

.modal.modal-center .modal-backdrop {
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(4px);
}

.modal.modal-center .modal-content {
    min-height: auto;
    height: auto;
    width: 100%;
    max-width: 400px;
    border-radius: var(--radius-xl);
    transform-origin: center;
    box-shadow: var(--shadow-card);
    display: flex;
    flex-direction: column;
}

.modal.modal-center .modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: transparent;
    padding: 8px;
    border-radius: var(--radius-full);
}

.modal.modal-center .modal-close:hover {
    background: var(--bg-input);
    color: var(--text-primary);
}

.modal-close {
    position: fixed;
    top: 24px;
    right: 24px;
    z-index: 210;
    color: var(--text-muted);
    padding: 8px;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 50%;
    backdrop-filter: blur(4px);
    transition: all var(--transition-base);
}

.modal-close:hover {
    color: var(--text-primary);
}

.modal-header {
    text-align: center;
    margin-bottom: 32px;
    padding-top: 40px;
}

.modal-title {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 12px;
}

.modal-subtitle {
    font-size: 16px;
    color: var(--text-secondary);
}

.modal-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-label {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
}

.form-input {
    padding: 12px 16px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 15px;
    transition: border-color var(--transition-base);
}

.form-input:focus {
    border-color: var(--purple-primary);
}

.form-input::placeholder {
    color: var(--text-muted);
}

.modal-footer-text {
    text-align: center;
    font-size: 14px;
    color: var(--text-secondary);
    margin-top: 16px;
}

.modal-link {
    color: var(--purple-primary);
    font-weight: 500;
}

.modal-link:hover {
    text-decoration: underline;
}

/* ===== Responsive ===== */
@media (max-width: 1024px) {
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {

    .nav,
    .header-actions {
        display: none;
    }

    .mobile-menu-btn {
        display: block;
    }

    .hero-subtitle br {
        display: none;
    }

    .hero-stats {
        flex-direction: column;
        gap: 16px;
    }

    .search-box {
        flex-direction: column;
    }

    .search-input-wrapper {
        width: 100%;
        padding: 0 16px;
    }

    .search-filters {
        width: 100%;
        flex-direction: column;
    }

    .filter-btn,
    .search-btn {
        width: 100%;
        justify-content: center;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .footer-brand {
        text-align: center;
    }

    .footer-desc {
        margin: 16px auto 0;
    }

    .footer-links {
        text-align: center;
    }
}

@media (max-width: 480px) {
    .hero-actions {
        flex-direction: column;
        width: 100%;
    }

    .hero-actions .btn {
        width: 100%;
    }

    .category-chips {
        justify-content: center;
    }
}

/* ===== Product Detail Modal ===== */
.modal-lg {
    max-width: 100%;
    min-height: 100vh;
    overflow-y: visible;
}

.modal-sm {
    max-width: 100%;
    min-height: 100vh;
}

.product-breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.product-breadcrumb a {
    color: var(--text-secondary);
    transition: color var(--transition-base);
}

.product-breadcrumb a:hover {
    color: var(--purple-primary);
}

.product-breadcrumb svg {
    flex-shrink: 0;
}

.product-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
}

/* Gallery */
.product-gallery {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.gallery-main {
    position: relative;
    aspect-ratio: 16/12;
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: var(--bg-darker);
}

.gallery-main img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-nav {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    transform: translateY(-50%);
    display: flex;
    justify-content: space-between;
    padding: 0 12px;
    pointer-events: none;
}

.gallery-nav-btn {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    border-radius: 50%;
    color: white;
    pointer-events: auto;
    transition: all var(--transition-base);
}

.gallery-nav-btn:hover {
    background: rgba(139, 92, 246, 0.8);
}

.gallery-nav-btn svg {
    width: 20px;
    height: 20px;
}

.gallery-views {
    position: absolute;
    bottom: 12px;
    left: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    border-radius: var(--radius-full);
    font-size: 13px;
    color: white;
}

.gallery-counter {
    position: absolute;
    bottom: 12px;
    right: 12px;
    padding: 6px 12px;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    border-radius: var(--radius-full);
    font-size: 13px;
    color: white;
}

.gallery-thumbs {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 4px;
}

.gallery-thumb {
    width: 64px;
    height: 48px;
    border-radius: var(--radius-sm);
    overflow: hidden;
    cursor: pointer;
    border: 2px solid transparent;
    flex-shrink: 0;
    transition: border-color var(--transition-base);
}

.gallery-thumb:hover,
.gallery-thumb.active {
    border-color: var(--purple-primary);
}

.gallery-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Product Info */
.product-info {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.product-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.product-badge {
    padding: 4px 12px;
    border-radius: var(--radius-full);
    font-size: 12px;
    font-weight: 600;
}

.product-badge.game {
    background: rgba(139, 92, 246, 0.15);
    border: 1px solid rgba(139, 92, 246, 0.3);
    color: var(--purple-light);
}

.product-badge.rank {
    background: rgba(236, 72, 153, 0.15);
    border: 1px solid rgba(236, 72, 153, 0.3);
    color: #f472b6;
}

.product-badge.status {
    background: rgba(34, 197, 94, 0.15);
    border: 1px solid rgba(34, 197, 94, 0.3);
    color: var(--green-primary);
}

.product-badge.featured {
    background: rgba(251, 191, 36, 0.15);
    border: 1px solid rgba(251, 191, 36, 0.3);
    color: #fbbf24;
}

.product-title {
    font-size: 24px;
    font-weight: 700;
    line-height: 1.3;
}

.product-price-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px;
    background: var(--bg-input);
    border-radius: var(--radius-lg);
}

.price-section {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.price-label {
    font-size: 13px;
    color: var(--text-muted);
}

.price-value {
    font-size: 32px;
    font-weight: 800;
    color: var(--cyan-primary);
}

.price-actions {
    display: flex;
    gap: 8px;
}

.action-btn {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    transition: all var(--transition-base);
}

.action-btn:hover {
    border-color: var(--purple-primary);
    color: var(--purple-primary);
}

.action-btn.active {
    background: rgba(239, 68, 68, 0.15);
    border-color: #ef4444;
    color: #ef4444;
}

/* Buy Button with Glow Effect */
.btn-buy {
    padding: 16px 32px;
    font-size: 18px;
    font-weight: 700;
    background: linear-gradient(135deg, #ec4899, #8b5cf6);
    color: white;
    border-radius: var(--radius-lg);
    position: relative;
    overflow: hidden;
    transition: all var(--transition-base);
    box-shadow: 0 0 30px rgba(236, 72, 153, 0.3);
}

.btn-buy::before {
    content: '';
    position: absolute;
    inset: -2px;
    background: linear-gradient(135deg, #ec4899, #8b5cf6, #22d3ee, #ec4899);
    background-size: 300% 300%;
    border-radius: inherit;
    z-index: -1;
    opacity: 0;
    transition: opacity var(--transition-base);
    animation: gradientShift 3s ease infinite;
}

@keyframes gradientShift {

    0%,
    100% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }
}

.btn-buy:hover {
    transform: translateY(-2px);
    box-shadow:
        0 0 40px rgba(236, 72, 153, 0.5),
        0 0 80px rgba(139, 92, 246, 0.3),
        0 0 120px rgba(34, 211, 238, 0.2);
}

.btn-buy:hover::before {
    opacity: 1;
}

.payment-note {
    font-size: 13px;
    color: var(--text-muted);
    text-align: center;
}

.product-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.stat-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 16px;
    background: var(--bg-input);
    border-radius: var(--radius-lg);
}

.stat-box .stat-label {
    font-size: 13px;
    color: var(--text-muted);
}

.stat-box .stat-value {
    font-size: 24px;
    font-weight: 700;
}

.stat-box .stat-value.rank {
    color: #f472b6;
}

.product-description {
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
}

.product-description h3 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 8px;
}

.product-description p {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.7;
}

/* Seller Section */
.seller-section {
    padding: 16px;
    background: var(--bg-input);
    border-radius: var(--radius-lg);
}

.seller-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.seller-info-main {
    display: flex;
    align-items: center;
    gap: 12px;
}

.seller-avatar-lg {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--purple-primary), var(--cyan-primary));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: 700;
    color: white;
}

.seller-details {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.seller-name-row {
    display: flex;
    align-items: center;
    gap: 6px;
}

.seller-name {
    font-size: 16px;
    font-weight: 600;
}

.verified-badge {
    color: var(--cyan-primary);
}

.seller-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 13px;
    color: var(--text-secondary);
}

.seller-meta span {
    display: flex;
    align-items: center;
    gap: 4px;
}

.seller-profile-btn {
    padding: 8px;
}

/* Warning Box */
.warning-box {
    display: flex;
    gap: 12px;
    padding: 16px;
    background: rgba(251, 191, 36, 0.1);
    border: 1px solid rgba(251, 191, 36, 0.3);
    border-radius: var(--radius-lg);
}

.warning-box svg {
    color: #fbbf24;
    flex-shrink: 0;
}

.warning-box p {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.6;
}

.warning-box strong {
    color: #fbbf24;
}

/* ===== Share Modal ===== */
.share-buttons {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-bottom: 24px;
}

.share-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 16px 24px;
    border-radius: var(--radius-lg);
    transition: all var(--transition-base);
}

.share-btn span {
    font-size: 13px;
    font-weight: 500;
}

.share-btn.whatsapp {
    background: rgba(37, 211, 102, 0.1);
    border: 1px solid rgba(37, 211, 102, 0.3);
    color: #25d366;
}

.share-btn.whatsapp:hover {
    background: rgba(37, 211, 102, 0.2);
    border-color: #25d366;
}

.share-btn.telegram {
    background: rgba(0, 136, 204, 0.1);
    border: 1px solid rgba(0, 136, 204, 0.3);
    color: #0088cc;
}

.share-btn.telegram:hover {
    background: rgba(0, 136, 204, 0.2);
    border-color: #0088cc;
}

.share-btn.other {
    background: rgba(34, 211, 238, 0.1);
    border: 1px solid rgba(34, 211, 238, 0.3);
    color: var(--cyan-primary);
}

.share-btn.other:hover {
    background: rgba(34, 211, 238, 0.2);
    border-color: var(--cyan-primary);
}

.share-link {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.share-link-label {
    font-size: 13px;
    color: var(--text-muted);
}

.share-link-box {
    display: flex;
    gap: 8px;
}

.share-link-input {
    flex: 1;
    padding: 12px 16px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 13px;
}

.share-copy-btn {
    width: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--cyan-primary);
    border-radius: var(--radius-md);
    color: var(--bg-dark);
    transition: all var(--transition-base);
}

.share-copy-btn:hover {
    opacity: 0.9;
}

/* ===== Views Counter ===== */
.card-views {
    position: absolute;
    bottom: 12px;
    left: 12px;
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 4px 8px;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    border-radius: var(--radius-sm);
    font-size: 12px;
    color: white;
}

.card-views svg {
    width: 14px;
    height: 14px;
}

/* ===== Product Modal Responsive ===== */
@media (max-width: 768px) {
    /* Modal responsive styles removed as they are now full-page by default */

    .product-layout {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .product-title {
        font-size: 20px;
    }

    .price-value {
        font-size: 28px;
    }

    .share-buttons {
        gap: 8px;
    }

    .share-btn {
        padding: 12px 16px;
    }
}

/* ===== Similar Products ===== */
.similar-products-section {
    margin-top: 48px;
    padding-top: 32px;
    border-top: 1px solid var(--border-color);
}

.similar-title {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 24px;
}

.similar-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 20px;
}

.similar-grid .game-card {
    border-color: var(--border-light);
    box-shadow: none;
}

.similar-grid .game-card:hover {
    border-color: var(--purple-primary);
    transform: translateY(-4px);
    box-shadow: var(--shadow-card);
}

/* ===== Sell Modal Styles ===== */
.sell-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.form-select {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23a1a1aa' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 40px;
}

.form-textarea {
    resize: vertical;
    min-height: 80px;
}

.form-hint {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 4px;
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 8px;
}

/* ===== Checkout Modal Styles ===== */
.checkout-summary {
    padding: 16px;
    background: var(--bg-input);
    border-radius: var(--radius-lg);
    margin-bottom: 20px;
}

.checkout-item {
    display: flex;
    align-items: center;
    gap: 12px;
}

.checkout-item img {
    width: 60px;
    height: 45px;
    border-radius: var(--radius-sm);
    object-fit: cover;
}

.checkout-item-info {
    flex: 1;
}

.checkout-item-info h4 {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 2px;
}

.checkout-item-info p {
    font-size: 12px;
    color: var(--text-muted);
}

.checkout-price {
    font-size: 18px;
    font-weight: 700;
    color: var(--cyan-primary);
}

.checkout-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.payment-methods {
    display: flex;
    gap: 12px;
}

.payment-option {
    flex: 1;
    cursor: pointer;
}

.payment-option input {
    display: none;
}

.payment-label {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px;
    background: var(--bg-input);
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 500;
    transition: all var(--transition-base);
}

.payment-option input:checked+.payment-label {
    border-color: var(--purple-primary);
    background: rgba(139, 92, 246, 0.1);
}

.payment-icon {
    font-size: 20px;
}

.checkout-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px;
    background: var(--bg-input);
    border-radius: var(--radius-lg);
    font-size: 16px;
    font-weight: 600;
}

.total-price {
    font-size: 24px;
    font-weight: 800;
    color: var(--cyan-primary);
}

.checkout-secure {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 8px;
}

.checkout-secure svg {
    color: var(--green-primary);
}

/* ===== Success Modal Styles ===== */
.success-content {
    text-align: center;
    padding: 20px 0;
}

.success-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(34, 197, 94, 0.15);
    border-radius: 50%;
    color: var(--green-primary);
}

.success-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 12px;
}

.success-message {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 16px;
    line-height: 1.6;
}

.success-order-id {
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: 24px;
}

.success-order-id strong {
    color: var(--purple-primary);
}

/* ===== Form Responsive ===== */
@media (max-width: 480px) {
    .form-row {
        grid-template-columns: 1fr;
    }

    .form-actions {
        flex-direction: column-reverse;
    }

    .form-actions .btn {
        width: 100%;
    }

    .payment-methods {
        flex-direction: column;
    }
}

/* Checkout Flow Styles */
.payment-instructions {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 24px;
}

.instruction-step {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 16px;
    position: relative;
    padding-left: 50px;
}

.step-number {
    position: absolute;
    left: 16px;
    top: 16px;
    width: 24px;
    height: 24px;
    background: var(--purple-primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 600;
}

.code-display {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px dashed var(--purple-primary);
    padding: 10px 16px;
    border-radius: 8px;
    margin-top: 10px;
    justify-content: space-between;
}

.code-display span {
    font-family: monospace;
    font-size: 20px;
    font-weight: 700;
    color: var(--purple-primary);
    letter-spacing: 2px;
}

.copy-btn {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 4px;
    transition: color 0.3s ease;
}

.copy-btn:hover {
    color: white;
}

.payment-details-box {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 10px;
}

.payment-row {
    display: flex;
    justify-content: space-between;
    font-size: 14px;
}

.payment-row .label {
    color: var(--text-secondary);
}

.payment-row .value {
    color: white;
    font-weight: 500;
}

.payment-alert {
    margin-top: 8px;
    font-size: 12px;
    color: #ef4444;
    background: rgba(239, 68, 68, 0.1);
    padding: 8px;
    border-radius: 6px;
}

.file-upload-box {
    margin-top: 10px;
    position: relative;
    height: 100px;
    border: 2px dashed rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    transition: border-color 0.3s ease;
    overflow: hidden;
}

.file-upload-box:hover {
    border-color: var(--purple-primary);
}

.file-upload-box input[type="file"] {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
    z-index: 2;
}

.upload-placeholder {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: var(--text-secondary);
    pointer-events: none;
    text-align: center;
    width: 100%;
}

.file-preview {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    background-size: cover;
    background-position: center;
    display: none;
}


/* User Dropdown Styles */
.user-menu-container {
    position: relative;
    display: inline-block;
}

.user-btn-content {
    display: flex;
    align-items: center;
    gap: 8px;
}

.user-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 10px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    min-width: 200px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s ease;
    z-index: 1000;
}

.user-dropdown.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-item {
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s ease;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.dropdown-item:last-child {
    border-bottom: none;
}

.dropdown-item:hover {
    background: rgba(139, 92, 246, 0.1);
    color: white;
}


/* Admin Panel Styles */
.modal-xl {
    max-width: 1200px;
    width: 90%;
}

.admin-orders-container {
    overflow-x: auto;
    margin-top: 20px;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
    white-space: nowrap;
}

.admin-table th,
.admin-table td {
    padding: 12px 16px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.admin-table th {
    background: rgba(255, 255, 255, 0.03);
    color: var(--text-secondary);
    font-weight: 500;
}

.admin-table td {
    color: var(--text-primary);
}

.status-badge {
    padding: 4px 8px;
    border-radius: var(--radius-sm);
    font-size: 12px;
    font-weight: 600;
}

.status-pending {
    background: rgba(234, 179, 8, 0.15);
    color: #eab308;
}

.status-completed {
    background: rgba(34, 197, 94, 0.15);
    color: #22c55e;
}

.status-rejected {
    background: rgba(239, 68, 68, 0.15);
    color: #ef4444;
}

.receipt-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: rgba(139, 92, 246, 0.1);
    color: var(--purple-primary);
    border-radius: var(--radius-sm);
    font-size: 12px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.receipt-btn:hover {
    background: var(--purple-primary);
    color: white;
}

.action-btn-group {
    display: flex;
    gap: 8px;
}

.action-icon-btn {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    transition: all 0.2s ease;
}

.action-icon-btn.approve:hover {
    background: rgba(34, 197, 94, 0.1);
    color: #22c55e;
    border-color: #22c55e;
}

.action-icon-btn.reject:hover {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
    border-color: #ef4444;
}


/* Profile Modal Styles */
.profile-info {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
    padding: 20px 0;
}

.profile-avatar-large {
    width: 100px;
    height: 100px;
    background: var(--bg-body);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 10px;
    border: 2px solid var(--purple-primary);
    color: var(--purple-primary);
}

.profile-details {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.detail-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: var(--radius-sm);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.detail-item .label {
    color: var(--text-secondary);
    font-size: 14px;
}

.detail-item .value {
    color: white;
    font-weight: 500;
}