/* main.css - Premium Dark Theme for Yadawa Store */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&display=swap');

:root {
    --bg-dark: #07050a;
    --bg-darker: #030208;
    --bg-card: rgba(10, 5, 0, 0.55);
    --bg-card-hover: rgba(255, 200, 50, 0.06);
    --border-glow: rgba(255, 190, 40, 0.18);
    --primary-cyan: #00cfff;
    --primary-purple: #2255dd;
    --primary-magenta: #ff6600;
    --accent-gold: #ffd700;
    --accent-fire: #ff6b00;
    --text-main: #f8f5e8;
    --text-muted: #b8a880;
    --success: #00e676;
    --warning: #ffb300;
    --danger: #ff1744;
    --font: 'Outfit', sans-serif;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* === YADAWA CORP BACKGROUND === */
body {
    background-color: #030208;
    background-image: url('assets/images/yadawa_bg.png');
    background-attachment: fixed;
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    color: var(--text-main);
    font-family: var(--font);
    line-height: 1.5;
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

/* Dark overlay to keep content readable over the epic background */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background: linear-gradient(
        135deg,
        rgba(3, 2, 8, 0.82) 0%,
        rgba(5, 3, 15, 0.75) 40%,
        rgba(3, 2, 8, 0.82) 100%
    );
    z-index: 0;
    pointer-events: none;
}

/* Ensure all content appears above the overlay */
header, main, footer, .hero-section, .main-content {
    position: relative;
    z-index: 1;
}

/* Animated ember particles */
body::after {
    content: '';
    position: fixed;
    inset: 0;
    background-image: 
        radial-gradient(circle at 8% 30%, rgba(255, 107, 0, 0.12) 0%, transparent 30%),
        radial-gradient(circle at 92% 20%, rgba(0, 100, 255, 0.12) 0%, transparent 25%),
        radial-gradient(circle at 50% 50%, transparent 0%, rgba(3, 2, 8, 0.3) 100%);
    z-index: 0;
    pointer-events: none;
    animation: fireFlicker 6s ease-in-out infinite alternate;
}

@keyframes fireFlicker {
    0%   { opacity: 0.6; }
    50%  { opacity: 1; }
    100% { opacity: 0.7; }
}

a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition);
}


/* Header & Navbar */
header {
    background: rgba(4, 4, 10, 0.8);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-glow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1.25rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-weight: 800;
    font-size: 1.6rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, #ffd700 0%, #ff6b00 60%, #ffd700 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-transform: uppercase;
    letter-spacing: 2px;
    text-shadow: none;
    filter: drop-shadow(0 0 8px rgba(255, 215, 0, 0.6));
}

.logo span {
    -webkit-text-fill-color: var(--text-main);
}

.nav-links {
    display: flex;
    gap: 1.5rem;
    align-items: center;
    list-style: none;
}

.nav-item {
    font-weight: 500;
    color: var(--text-muted);
}

.nav-item:hover, .nav-item.active {
    color: var(--primary-cyan);
}

.nav-btn {
    background: linear-gradient(135deg, #ffd700 0%, #ff6b00 100%);
    padding: 0.6rem 1.2rem;
    border-radius: 50px;
    color: #000;
    font-weight: 700;
    font-size: 0.9rem;
    box-shadow: 0 0 15px rgba(255, 215, 0, 0.4);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.nav-btn:hover {
    box-shadow: 0 0 30px rgba(255, 107, 0, 0.8);
    transform: translateY(-2px);
    color: #000;
}

/* Banner Slider & Promo */
.hero-section {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 1.5rem;
}

.promo-banner {
    background: linear-gradient(135deg, rgba(255, 107, 0, 0.15) 0%, rgba(10, 10, 30, 0.8) 50%, rgba(34, 85, 221, 0.15) 100%);
    border: 1px solid rgba(255, 215, 0, 0.3);
    box-shadow: 0 0 40px rgba(255, 107, 0, 0.1), inset 0 0 60px rgba(0, 0, 0, 0.3);
    border-radius: 20px;
    padding: 3rem 2.5rem;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 250px;
}

.promo-banner::after {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 300px;
    height: 300px;
    background: var(--primary-cyan);
    filter: blur(120px);
    opacity: 0.2;
    pointer-events: none;
}

.promo-banner h1 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 0.5rem;
    line-height: 1.2;
}

.promo-banner p {
    color: var(--text-muted);
    font-size: 1.1rem;
    max-width: 600px;
}

/* Categories / Games Section */
.main-content {
    max-width: 1200px;
    margin: 3rem auto;
    padding: 0 1.5rem;
}

.section-title {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.section-title::before {
    content: '';
    display: inline-block;
    width: 6px;
    height: 24px;
    background: linear-gradient(to bottom, #ffd700, #ff6b00);
    border-radius: 3px;
    box-shadow: 0 0 8px rgba(255, 215, 0, 0.5);
}

.games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 1.5rem;
}

.game-card {
    background: var(--bg-card);
    border: 1px solid var(--border-glow);
    border-radius: 18px;
    overflow: hidden;
    transition: var(--transition);
    position: relative;
}

.game-card:hover {
    transform: translateY(-8px);
    border-color: var(--accent-gold);
    box-shadow: 0 12px 40px rgba(255, 215, 0, 0.2), 0 0 20px rgba(255, 107, 0, 0.15);
    background: var(--bg-card-hover);
}

.game-thumbnail-wrapper {
    position: relative;
    width: 100%;
    padding-top: 130%; /* 4:3 or similar ratio */
    overflow: hidden;
}

.game-thumbnail {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.game-card:hover .game-thumbnail {
    transform: scale(1.08);
}

.game-info {
    padding: 1rem;
    text-align: center;
}

.game-name {
    font-size: 1.05rem;
    font-weight: 600;
}

/* Detail Game Page */
.detail-layout {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 2rem;
    margin-top: 2rem;
}

@media (max-width: 900px) {
    .detail-layout {
        grid-template-columns: 1fr;
    }
}

.column-left {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.game-detail-card {
    background: var(--bg-card);
    border: 1px solid var(--border-glow);
    border-radius: 24px;
    padding: 2rem;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    position: sticky;
    top: 100px;
}

.detail-img {
    width: 120px;
    height: 120px;
    border-radius: 20px;
    object-fit: cover;
    margin-bottom: 1.5rem;
    border: 2px solid var(--border-glow);
}

.detail-title {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.detail-desc {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
}

.step-card {
    background: var(--bg-card);
    border: 1px solid var(--border-glow);
    border-radius: 20px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.step-header {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    margin-bottom: 1.25rem;
}

.step-number {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--primary-cyan);
    color: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
    box-shadow: 0 0 10px rgba(0, 240, 255, 0.4);
}

.step-title {
    font-size: 1.15rem;
    font-weight: 600;
}

/* Form Styling */
.form-group {
    margin-bottom: 1rem;
}

.form-control {
    width: 100%;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-glow);
    border-radius: 10px;
    padding: 0.8rem 1rem;
    color: #fff;
    font-family: var(--font);
    font-size: 0.95rem;
    transition: var(--transition);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-cyan);
    box-shadow: 0 0 10px rgba(0, 240, 255, 0.2);
    background: rgba(255, 255, 255, 0.05);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

/* Nominal Selector Grid */
.nominal-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 1rem;
}

.nominal-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-glow);
    border-radius: 15px;
    padding: 1.2rem;
    cursor: pointer;
    transition: var(--transition);
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
}

.nominal-card:hover {
    border-color: var(--primary-purple);
    background: rgba(255, 255, 255, 0.05);
}

.nominal-card.selected {
    border-color: var(--primary-cyan);
    background: rgba(0, 240, 255, 0.05);
    box-shadow: 0 0 15px rgba(0, 240, 255, 0.1);
}

.nominal-title {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-muted);
}

.nominal-card.selected .nominal-title {
    color: var(--primary-cyan);
}

.nominal-name {
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0.25rem 0;
}

.nominal-price {
    font-size: 0.95rem;
    color: var(--accent-gold);
    font-weight: 600;
}

/* Payment Method Accordion */
.payment-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.payment-group {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-glow);
    border-radius: 12px;
    overflow: hidden;
}

.payment-group-header {
    padding: 1rem;
    cursor: pointer;
    font-weight: 600;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255, 255, 255, 0.03);
}

.payment-channels {
    padding: 1rem;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
    border-top: 1px solid var(--border-glow);
}

.payment-card {
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--border-glow);
    border-radius: 10px;
    padding: 1rem;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition);
}

.payment-card:hover {
    border-color: var(--primary-purple);
}

.payment-card.selected {
    border-color: var(--primary-cyan);
    background: rgba(0, 240, 255, 0.03);
}

.payment-logo-name {
    display: flex;
    flex-direction: column;
}

.payment-name-lbl {
    font-size: 0.9rem;
    font-weight: 600;
}

.payment-fee-lbl {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.payment-price-tag {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--accent-gold);
}

/* Submit Section button */
.checkout-btn {
    width: 100%;
    background: linear-gradient(135deg, #ffd700 0%, #ff8c00 50%, #ffd700 100%);
    background-size: 200% auto;
    border: none;
    border-radius: 12px;
    padding: 1rem;
    font-size: 1.1rem;
    font-weight: 800;
    color: #000;
    cursor: pointer;
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.4), 0 4px 15px rgba(255, 107, 0, 0.3);
    transition: var(--transition);
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 1px;
    animation: goldShimmer 3s linear infinite;
}

@keyframes goldShimmer {
    0% { background-position: 0% center; }
    100% { background-position: 200% center; }
}

.checkout-btn:hover {
    box-shadow: 0 0 40px rgba(255, 215, 0, 0.8), 0 0 20px rgba(255, 107, 0, 0.6);
    transform: translateY(-3px);
    color: #000;
}

.checkout-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
    box-shadow: none !important;
}

/* Invoice View */
.invoice-card {
    max-width: 700px;
    margin: 3rem auto;
    background: var(--bg-card);
    border: 1px solid var(--border-glow);
    border-radius: 24px;
    padding: 2.5rem;
    backdrop-filter: blur(10px);
}

.invoice-header {
    text-align: center;
    border-bottom: 1px solid var(--border-glow);
    padding-bottom: 1.5rem;
    margin-bottom: 1.5rem;
}

.status-badge {
    display: inline-block;
    padding: 0.4rem 1.2rem;
    border-radius: 50px;
    font-weight: 700;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 0.5rem;
}

.status-badge.unpaid {
    background: rgba(255, 179, 0, 0.15);
    color: var(--warning);
    border: 1px solid rgba(255, 179, 0, 0.3);
}

.status-badge.processing {
    background: rgba(0, 240, 255, 0.15);
    color: var(--primary-cyan);
    border: 1px solid rgba(0, 240, 255, 0.3);
}

.status-badge.success {
    background: rgba(0, 230, 118, 0.15);
    color: var(--success);
    border: 1px solid rgba(0, 230, 118, 0.3);
}

.status-badge.failed {
    background: rgba(255, 23, 68, 0.15);
    color: var(--danger);
    border: 1px solid rgba(255, 23, 68, 0.3);
}

.invoice-details {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 2rem;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.25rem 0;
}

.detail-lbl {
    color: var(--text-muted);
}

.detail-val {
    font-weight: 600;
}

.detail-val.copyable {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.detail-val.copyable:hover {
    color: var(--primary-cyan);
}

.qr-payment-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 2rem 0;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 18px;
    border: 1px solid var(--border-glow);
}

.qr-code {
    background: white;
    padding: 1rem;
    border-radius: 12px;
    width: 220px;
    height: 220px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.qr-code img {
    max-width: 100%;
}

.instruction-section {
    margin-top: 1.5rem;
}

.instruction-title {
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.instruction-step {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 0.4rem;
    padding-left: 1rem;
    position: relative;
}

.instruction-step::before {
    content: '•';
    position: absolute;
    left: 0;
    color: var(--primary-cyan);
}

/* Toast alert notification */
.toast-msg {
    position: fixed;
    bottom: 24px;
    right: 24px;
    background: rgba(157, 78, 221, 0.95);
    border-left: 4px solid var(--primary-cyan);
    color: #fff;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
    z-index: 10000;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    animation: slideIn 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes slideIn {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

/* History Page */
.history-card {
    max-width: 800px;
    margin: 3rem auto;
    background: var(--bg-card);
    border: 1px solid var(--border-glow);
    border-radius: 24px;
    padding: 2.5rem;
}

.history-search-bar {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
}

/* Footer Section */
footer {
    background: #04040a;
    border-top: 1px solid var(--border-glow);
    padding: 3rem 1.5rem;
    margin-top: 5rem;
    color: var(--text-muted);
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.footer-title {
    color: var(--text-main);
    font-weight: 700;
    font-size: 1.2rem;
    margin-bottom: 1rem;
}

.footer-desc {
    font-size: 0.9rem;
    line-height: 1.6;
}

.footer-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    font-size: 0.9rem;
}

.footer-links a:hover {
    color: var(--primary-cyan);
}

.footer-bottom {
    text-align: center;
    margin-top: 3rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    font-size: 0.85rem;
}

/* Sim payment btn helper */
.sim-pay-btn {
    background: var(--success);
    color: #000;
    font-weight: 700;
    border: none;
    border-radius: 8px;
    padding: 0.5rem 1rem;
    cursor: pointer;
    font-size: 0.9rem;
    margin-top: 1rem;
    display: inline-block;
    transition: var(--transition);
}

.sim-pay-btn:hover {
    box-shadow: 0 0 15px rgba(0, 230, 118, 0.6);
    transform: translateY(-2px);
}
