/* Base Reset & Typography */
html {
    scroll-behavior: smooth;
}

body {
    background-color: #2A0A0A;
    color: #F5F5DC;
    font-family: 'Inter', sans-serif;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #2A0A0A;
}
::-webkit-scrollbar-thumb {
    background: #4A1010;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #C5A059;
}

/* Grain Texture Overlay */
.grain-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 9999;
    opacity: 0.05;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
}

/* Navbar Styles */
#navbar {
    background: transparent;
    transition: background 0.4s ease, padding 0.4s ease;
}
#navbar.scrolled {
    background: rgba(42, 10, 10, 0.85);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(197, 160, 89, 0.2);
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
}

/* Hero Background */
.hero-bg {
    background: url('https://images.unsplash.com/photo-1532012197267-da84d127e765?q=80&w=1920&auto=format&fit=crop') no-repeat center center/cover;
    filter: brightness(0.4) sepia(0.4) hue-rotate(-20deg) saturate(1.2);
    transform: scale(1.1);
    animation: slowZoom 20s infinite alternate;
}

@keyframes slowZoom {
    0% { transform: scale(1.1); }
    100% { transform: scale(1.2); }
}

/* Glass Cards */
.glass-card {
    background: rgba(74, 16, 16, 0.3);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(197, 160, 89, 0.2);
    transition: all 0.4s ease;
}
.glass-card:hover {
    border-color: rgba(197, 160, 89, 0.6);
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

/* Resource Cards */
.resource-card {
    background: rgba(42, 10, 10, 0.6);
    backdrop-filter: blur(6px);
    border: 1px solid rgba(197, 160, 89, 0.15);
    padding: 1.5rem;
    transition: all 0.4s ease;
    display: block;
}
.resource-card:hover {
    border-color: rgba(197, 160, 89, 0.5);
    background: rgba(74, 16, 16, 0.4);
    transform: translateY(-3px);
}

/* Reveal Animations */
.reveal-up {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.9s cubic-bezier(0.16, 1, 0.3, 1), transform 0.9s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal-up.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Event Card Specifics */
.event-card {
    background: linear-gradient(145deg, rgba(74, 16, 16, 0.4), rgba(42, 10, 10, 0.6));
    border: 1px solid rgba(197, 160, 89, 0.1);
    padding: 1.5rem;
    position: relative;
    transition: all 0.5s ease;
    cursor: pointer;
    overflow: hidden;
}
.event-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at top right, rgba(197, 160, 89, 0.1), transparent 60%);
    opacity: 0;
    transition: opacity 0.5s ease;
}
.event-card:hover {
    border-color: rgba(197, 160, 89, 0.4);
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.4);
}
.event-card:hover::before {
    opacity: 1;
}

/* Modal Animation */
#event-modal, #rules-modal, #faq-modal {
    animation: fadeIn 0.4s ease forwards;
}
#modal-content {
    animation: slideUp 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
@keyframes slideUp {
    from { transform: translateY(40px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

/* Decorative Line */
.flourish {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 1rem 0;
}
.flourish::before, .flourish::after {
    content: '';
    height: 1px;
    width: 40px;
    background: #C5A059;
    margin: 0 10px;
}

/* Prevent body scroll when modal open */
body.modal-open {
    overflow: hidden;
}
