/* Modern CSS Variables */
:root {
    --primary-color: #007bff;
    --secondary-color: #6c757d;
    --success-color: #28a745;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --dark-color: #343a40;
    --light-color: #f8f9fa;
    --gradient-primary: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gradient-secondary: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    --gradient-success: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    --shadow-sm: 0 2px 4px rgba(0,0,0,0.1);
    --shadow-md: 0 4px 6px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 15px rgba(0,0,0,0.1);
    --border-radius: 12px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Global Styles */
html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #333;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
}

/* Hero Section with Video Background */
.hero-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
    background: var(--gradient-primary); /* Fallback */
}

.hero-video-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.8) 0%, rgba(118, 75, 162, 0.8) 100%);
    z-index: -1;
}

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

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    color: white;
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.text-gradient {
    background: linear-gradient(45deg, #ffd700, #ffed4e);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-description {
    font-size: 1.2rem;
    color: rgba(255,255,255,0.9);
    margin-bottom: 2rem;
    line-height: 1.8;
}

.hero-buttons .btn {
    padding: 15px 30px;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: var(--border-radius);
    margin-right: 1rem;
    margin-bottom: 1rem;
    transition: var(--transition);
    box-shadow: var(--shadow-md);
}

.hero-buttons .btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* Feature Items */
.feature-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 1.5rem;
    padding: 1rem;
    border-radius: var(--border-radius);
    backdrop-filter: blur(10px);
    transition: var(--transition);
}

.feature-item:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.feature-item i {
    font-size: 1.5rem;
    margin-right: 1rem;
    margin-top: 0.25rem;
}

/* Hero Visual Stats Grid */
.hero-visual {
    position: relative;
}

.hero-stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    animation: fadeInUp 0.8s ease-out 0.3s both;
}

.stat-card {
    padding: 1.5rem;
    border-radius: var(--border-radius);
    text-align: center;
    transition: var(--transition);
    border: 1px solid rgba(255,255,255,0.2);
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

.stat-icon {
    font-size: 2rem;
    color: #ffd700;
    margin-bottom: 0.5rem;
}

.stat-number {
    font-size: 1.5rem;
    font-weight: 800;
    color: white;
    margin-bottom: 0.25rem;
}

.stat-label {
    font-size: 0.85rem;
    color: rgba(255,255,255,0.8);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Sections */
.news-section, .transactions-section {
    background: white;
    position: relative;
    z-index: 1;
}

.games-section {
    background: var(--dark-color);
    position: relative;
    z-index: 1;
}

/* Cards */
.news-card, .game-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 2rem;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    border: none;
    height: 100%;
}

.news-card:hover, .game-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.game-card {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    overflow: hidden;
}

/* Game Images */
.game-image img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 8px;
    transition: transform 0.3s ease;
}

.game-image img:hover {
    transform: scale(1.05);
}

.game-image img[src*="default-game.svg"] {
    border: 2px solid #4a90e2;
    box-shadow: 0 2px 8px rgba(74, 144, 226, 0.3);
}

/* Modal Styles */
.modal-xl {
    max-width: 1200px;
}

.modal-header.bg-primary {
    border-bottom: none;
}

.modal-footer.bg-light {
    border-top: 1px solid #dee2e6;
}

/* Game Info Card */
.game-info-card {
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
    border: 1px solid #e9ecef;
    border-radius: var(--border-radius);
    padding: 1.5rem;
}

.game-image-wrapper {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
}

.game-image-wrapper img {
    width: 100%;
    height: 120px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.game-image-wrapper:hover img {
    transform: scale(1.05);
}

.game-links .btn {
    font-size: 0.85rem;
    padding: 0.375rem 0.75rem;
}

/* Purchase Form */
.purchase-form {
    background: white;
    border: 1px solid #e9ecef;
    border-radius: var(--border-radius);
    padding: 1.5rem;
}

/* Pricing Summary */
.pricing-summary {
    position: sticky;
    top: 20px;
}

.pricing-card {
    background: white;
    border: 1px solid #e9ecef;
    border-radius: var(--border-radius);
    padding: 1.25rem;
    box-shadow: var(--shadow-sm);
}

.pricing-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
    font-size: 0.95rem;
}

.pricing-row:last-child {
    margin-bottom: 0;
}

.pricing-row.total-row {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    margin: 0 -1.25rem 0.75rem -1.25rem;
    padding: 0.75rem 1.25rem;
    border-radius: 6px;
}

.pricing-row.discount-row {
    color: var(--success-color);
}

/* Previous Keys List */
.previous-keys-list {
    max-height: 300px;
    overflow-y: auto;
}

.previous-keys-list::-webkit-scrollbar {
    width: 4px;
}

.previous-keys-list::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 2px;
}

.previous-keys-list::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 2px;
}

.previous-keys-list::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* Purchase Items - Compact Design */
.purchase-item {
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 0.75rem;
    margin-bottom: 0.75rem;
    transition: all 0.3s ease;
    font-size: 0.85rem;
}

.purchase-item:hover {
    border-color: var(--primary-color);
    box-shadow: 0 2px 8px rgba(0,123,255,0.15);
    transform: translateY(-1px);
}

.purchase-item:last-child {
    margin-bottom: 0;
}

.purchase-item .key-header {
    display: flex;
    justify-content: between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.purchase-item .key-title {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--primary-color);
    margin: 0;
}

.purchase-item .key-badge {
    font-size: 0.7rem;
    padding: 0.2rem 0.5rem;
}

.purchase-item .key-info {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.25rem;
    margin-bottom: 0.5rem;
    font-size: 0.75rem;
}

.purchase-item .key-info-item {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    color: #666;
}

.purchase-item .key-info-item i {
    width: 12px;
    font-size: 0.7rem;
}

.purchase-item .key-display {
    background: #f8f9fa;
    border: 1px dashed #dee2e6;
    border-radius: 4px;
    padding: 0.5rem;
}

.purchase-item .key-display .input-group {
    margin-bottom: 0;
}

.purchase-item .key-display input {
    font-size: 0.75rem;
    font-family: 'Courier New', monospace;
    background: white;
    border: none;
    padding: 0.25rem 0.5rem;
}

.purchase-item .key-display .btn {
    font-size: 0.7rem;
    padding: 0.25rem 0.5rem;
    border: none;
}

.purchase-item .key-actions {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.purchase-item .key-actions .btn {
    font-size: 0.7rem;
    padding: 0.25rem 0.5rem;
    flex: 1;
}

/* Warnings Section */
.warnings-section .alert-sm {
    padding: 0.5rem 0.75rem;
    margin-bottom: 0.5rem;
    font-size: 0.85rem;
}

.warnings-section .alert-sm:last-child {
    margin-bottom: 0;
}

/* Empty State */
.empty-keys-state {
    text-align: center;
    padding: 2rem 1rem;
    color: #6c757d;
}

.empty-keys-state i {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    opacity: 0.5;
}

.empty-keys-state h6 {
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
}

.empty-keys-state p {
    font-size: 0.8rem;
    margin: 0;
}

/* Buttons */
.btn-buy-tool:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }

    .hero-buttons .btn {
        padding: 12px 24px;
        font-size: 1rem;
    }

    .hero-stats-grid {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }

    .stat-card {
        padding: 1rem;
    }

    .feature-item {
        padding: 0.75rem;
        margin-bottom: 1rem;
    }

    .purchase-item .info-grid {
        grid-template-columns: 1fr;
    }

    /* Video optimization for mobile */
    .hero-video-background {
        object-position: center center;
    }
}

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

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

/* Loading States */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

.spinner-border-sm {
    width: 1rem;
    height: 1rem;
}

/* Utility Classes */
.text-shadow {
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.bg-glass {
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.2);
}
