@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;600;800&family=Inter:wght@400;500;600;700&display=swap');

:root {
    --bg-color: #0a0a0c;
    --card-bg: rgba(26, 26, 30, 0.85);
    --border-color: rgba(255, 215, 0, 0.15);
    --border-highlight: rgba(255, 215, 0, 0.6);
    --primary-color: #eab308;
    --primary-gradient: linear-gradient(135deg, #fef08a 0%, #eab308 50%, #d97706 100%);
    --primary-hover-gradient: linear-gradient(135deg, #fde047 0%, #ca8a04 100%);
    --success-color: #22c55e;
    --success-glow: rgba(34, 197, 94, 0.6);
    --danger-color: #ef4444;
    --text-main: #f9fafb;
    --text-muted: #d1d5db;
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;
    --gold-glow: rgba(234, 179, 8, 0.4);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-body);
    background-color: #0b0505;
    color: var(--text-main);
    min-height: 100vh;
    background-image: 
        /* Top red glow */
        radial-gradient(ellipse at 50% 0%, rgba(220, 38, 38, 0.4), transparent 50%),
        /* Bottom left gold glow */
        radial-gradient(ellipse at 0% 100%, rgba(234, 179, 8, 0.15), transparent 40%),
        /* Bottom right red glow */
        radial-gradient(ellipse at 100% 100%, rgba(220, 38, 38, 0.2), transparent 40%),
        /* Subtle casino diagonal stripes */
        repeating-linear-gradient(45deg, rgba(255, 215, 0, 0.015) 0px, rgba(255, 215, 0, 0.015) 1px, transparent 1px, transparent 20px),
        /* Deep dark red/black base */
        linear-gradient(135deg, #0a0202 0%, #170505 100%);
    background-attachment: fixed;
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

input, textarea, select {
    -webkit-user-select: text;
    -moz-user-select: text;
    -ms-user-select: text;
    user-select: text;
}

h1, h2, h3, h4, h5, h6, .nav-brand {
    font-family: var(--font-heading);
    letter-spacing: -0.02em;
}

/* Glassmorphism */
.glass {
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
}

.navbar {
    display: flex;
    justify-content: space-between;
    padding: 1.25rem 5%;
    align-items: center;
    border-bottom: 1px solid var(--border-color);
    background: rgba(5, 5, 5, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-brand {
    font-size: 1.5rem;
    font-weight: 800;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-links a {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

.nav-links a i {
    font-size: 1.1rem;
}

.nav-links a:hover {
    color: var(--text-main);
    transform: translateY(-2px);
    text-shadow: 0 0 10px rgba(255,255,255,0.3);
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 3rem 2rem;
}

.page-title {
    font-size: 3rem;
    margin-bottom: 2.5rem;
    font-weight: 800;
    text-transform: uppercase;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 4px 15px var(--gold-glow);
    text-align: center;
}

.raffle-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
}

.card {
    padding: 1.5rem;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: pointer;
    position: relative;
    border-radius: 24px;
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4), 0 0 20px rgba(96, 165, 250, 0.1);
    border-color: var(--border-highlight);
}

.card img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: 16px;
    margin-bottom: 1.25rem;
    transition: transform 0.5s ease;
}

.card:hover img {
    transform: scale(1.03);
}

.card h2 {
    font-size: 1.4rem;
    margin-bottom: 0.5rem;
    color: white;
}

.card p {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
    line-height: 1.5;
}

.btn {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    padding: 1rem 1.5rem;
    background: var(--primary-gradient);
    color: #111827;
    text-align: center;
    border: none;
    border-radius: 12px;
    font-weight: 800;
    font-size: 1.1rem;
    cursor: pointer;
    text-transform: uppercase;
    transition: all 0.3s ease;
    text-decoration: none;
    box-shadow: 0 4px 20px var(--gold-glow);
    letter-spacing: 0.5px;
}

.btn:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 8px 30px rgba(234, 179, 8, 0.6);
    background: var(--primary-hover-gradient);
}

.btn:active {
    transform: translateY(1px) scale(0.98);
}

/* Pulsing CTA effect for massive conversion */
@keyframes pulseGlow {
    0% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7); }
    70% { box-shadow: 0 0 0 15px rgba(34, 197, 94, 0); }
    100% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0); }
}

.btn-cta {
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    color: white;
    font-size: 1.3rem;
    padding: 1.2rem;
    box-shadow: 0 5px 20px rgba(34, 197, 94, 0.4);
    animation: pulseGlow 2s infinite;
}
.btn-cta:hover {
    background: linear-gradient(135deg, #16a34a 0%, #15803d 100%);
    box-shadow: 0 8px 30px rgba(34, 197, 94, 0.6);
}

/* Detail page */
.detail-layout {
    display: flex;
    gap: 3rem;
    flex-wrap: wrap;
    align-items: flex-start;
}

.detail-img {
    flex: 1;
    min-width: 320px;
    position: sticky;
    top: 100px;
}

.detail-img img {
    width: 100%;
    border-radius: 24px;
    border: 1px solid var(--border-color);
}

.detail-info {
    flex: 1.2;
    min-width: 320px;
    padding: 2.5rem !important;
}

.form-group {
    margin-bottom: 1.5rem;
}
.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    font-size: 0.95rem;
    color: #e5e7eb;
}
.form-input {
    width: 100%;
    padding: 1rem 1.2rem;
    background: rgba(0, 0, 0, 0.5);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: white;
    font-family: var(--font-body);
    font-size: 1.1rem;
    transition: all 0.3s;
}
.form-input:focus {
    outline: none;
    border-color: var(--primary-color);
    background: rgba(0, 0, 0, 0.7);
    box-shadow: 0 0 15px var(--gold-glow);
}

.modal-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.modal-content {
    background: #0d1117;
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 24px;
    padding: 2.5rem;
    max-width: 500px;
    width: 90%;
    max-height: 85vh;
    overflow-y: auto;
    box-shadow: 0 25px 50px -12px rgba(0,0,0,0.8);
    position: relative;
}

.modal-close {
    position: absolute;
    top: 1.5rem; right: 1.5rem;
    cursor: pointer;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    color: var(--text-muted);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    font-weight: bold;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.modal-close:hover {
    background: rgba(255,255,255,0.15);
    color: white;
}

/* Beautiful Lottery Grid */
.lottery-grid {
    display: flex;
    flex-wrap: wrap;
    max-height: 400px;
    overflow-y: auto;
    border: 1px solid rgba(255,255,255,0.05);
    padding: 1.5rem;
    border-radius: 16px;
    margin-bottom: 2rem;
    background: rgba(0, 0, 0, 0.3);
    gap: 8px;
    box-shadow: inset 0 4px 20px rgba(0,0,0,0.3);
}

.lottery-grid::-webkit-scrollbar {
    width: 8px;
}
.lottery-grid::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 8px;
}
.lottery-grid::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.2);
    border-radius: 8px;
}
.lottery-grid::-webkit-scrollbar-thumb:hover {
    background: rgba(255,255,255,0.4);
}

.ticket-number {
    display: inline-flex;
    width: 48px;
    height: 48px;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 12px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    user-select: none;
    background: rgba(255, 255, 255, 0.02);
    color: #d1d5db;
    position: relative;
    overflow: hidden;
}

.ticket-number:hover:not(.sold) {
    background: rgba(234, 179, 8, 0.2);
    border-color: rgba(234, 179, 8, 0.6);
    color: var(--primary-color);
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 4px 15px var(--gold-glow);
}

.ticket-number.selected {
    background: var(--success-color);
    color: white;
    border-color: #34d399;
    transform: scale(1.08);
    box-shadow: 0 0 15px var(--success-glow);
    font-weight: 800;
    z-index: 2;
}

.ticket-number.sold {
    background: rgba(0, 0, 0, 0.5);
    color: rgba(255,255,255,0.15);
    border-color: transparent;
    cursor: not-allowed;
    text-decoration: line-through;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.5);
}

/* Custom styles for specific elements in JS */
#pricing-info {
    border-left: 4px solid #6366f1 !important;
    background: linear-gradient(to right, rgba(99, 102, 241, 0.1), transparent) !important;
}

#selected-numbers-display {
    border: 1px solid rgba(16, 185, 129, 0.3);
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.1);
}

/* ==========================================================================
   Mobile / Responsive Design
   ========================================================================== */
@media (max-width: 768px) {
    .navbar {
        flex-direction: column;
        padding: 1rem;
        gap: 0.8rem;
    }

    .nav-links {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 1.2rem;
    }
    
    .nav-links a {
        margin-left: 0;
        font-size: 1.2rem; /* Larger touch target for the icon on mobile */
        flex-direction: column;
        gap: 0.2rem;
    }

    .nav-links a span {
        font-size: 0.7rem; /* Tiny text below the icon for better spacing */
        font-weight: normal;
    }

    .container {
        padding: 1.5rem 1rem;
    }

    .page-title {
        font-size: 2rem;
        margin-bottom: 1.5rem;
    }

    .raffle-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .detail-layout {
        flex-direction: column;
        gap: 1.5rem;
    }

    .detail-img, .detail-info {
        min-width: 100%;
        width: 100%;
    }

    .detail-img {
        position: relative;
        top: 0;
    }

    .detail-info {
        padding: 1.5rem !important;
    }

    .lottery-grid {
        padding: 1rem;
        gap: 6px;
    }

    .ticket-number {
        width: 40px;
        height: 40px;
        font-size: 0.8rem;
    }

    .modal-content {
        padding: 1.5rem;
        width: 95%;
    }

    .form-group {
        margin-bottom: 1rem;
    }

    .form-input {
        padding: 0.8rem 1rem;
        font-size: 1rem;
    }

    .glass {
        padding: 1.5rem !important;
    }
    
    .btn {
        padding: 0.8rem 1.2rem;
        font-size: 1rem;
    }
}

/* ==========================================================================
   FAQ Accordion
   ========================================================================== */
.faq-accordion {
    display: flex;
    flex-direction: column;
}

.faq-item {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.faq-item:last-child {
    border-bottom: none;
}

.faq-question {
    width: 100%;
    background: transparent;
    border: none;
    color: var(--text-main);
    font-size: 1.1rem;
    font-weight: 600;
    text-align: left;
    padding: 1.5rem;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.3s ease;
    font-family: var(--font-body);
}

.faq-question:hover {
    color: var(--primary-color);
    background: rgba(255, 255, 255, 0.02);
}

.faq-question i {
    color: var(--primary-color);
    transition: transform 0.3s ease;
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease-out;
    background: rgba(0, 0, 0, 0.2);
}

.faq-answer p {
    padding: 0 1.5rem 1.5rem 1.5rem;
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.6;
}

.faq-item.active .faq-question {
    color: var(--primary-color);
}

.faq-item.active .faq-question i {
    transform: rotate(180deg);
}
