/* --- 1. GLOBAL & BACKGROUND --- */
body {
    margin: 0;
    padding: 20px;
    display: flex;
    justify-content: center;
    background-color: #0d0d0d;
    color: #d1d1d1;
    font-family: 'Courier New', Courier, monospace;
    min-height: 100vh;
}

/* Main background image */
body::before {
    content: "";
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), 
                url('https://codehs.com/uploads/3d0a83761caa973fdc8bfdc587011634');
    background-size: cover;
    background-position: center;
    z-index: -1;
}

.game-container {
    max-width: 1100px;
    width: 100%;
    text-align: center;
}

/* --- 2. RESTORED DARK UI (Stats & Evidence) --- */
h1 {
    letter-spacing: 5px;
    color: #ffffff;
    text-transform: uppercase;
    animation: flicker 4s infinite;
}

@keyframes flicker {
    0%, 18%, 22%, 25%, 53%, 57%, 100% { opacity: 1; }
    20%, 24%, 55% { opacity: 0.3; }
}

.stat-bar {
    display: flex;
    justify-content: space-around;
    background: rgba(26, 26, 26, 0.9);
    padding: 15px;
    border-radius: 5px;
    margin-bottom: 20px;
    border: 1px solid #333;
}

.stat-item span { color: #ff4444; font-weight: bold; }

.badge-container {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 25px;
}

.badge {
    padding: 8px 12px;
    background-color: #1a1a1a;
    color: #444;
    border: 1px solid #444;
    font-size: 0.7rem;
}

.badge.unlocked {
    background-color: #ff4444;
    color: white;
    border-color: #fff;
    box-shadow: 0 0 15px rgba(255, 68, 68, 0.6);
}

.evidence-screen {
    background-color: rgba(22, 22, 22, 0.9);
    border-left: 5px solid #ff4444;
    padding: 25px;
    margin-bottom: 30px;
    text-align: left;
}

/* --- 3. BULLETIN BOARD AREA --- */
.board-area {
    background-image: url('PASTE_YOUR_BOARD_IMAGE_URL_HERE');
    background-size: cover;
    background-position: center;
    padding: 60px 20px;
    border: 10px solid #3d2b1f;
    border-radius: 4px;
    margin-top: 30px;
}

#button-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
}

/* --- 4. LINED PAPER BUTTONS WITH "PICK UP" FEATURE --- */
.ghost-btn {
    position: relative;
    width: 155px;
    height: 75px;
    border: none;
    cursor: pointer;
    font-family: 'Permanent Marker', cursive;
    font-size: 1.1rem;
    color: #2c3e50;
    
    /* Lined Paper Gradient */
    background-color: #fdf6e3;
    background-image: repeating-linear-gradient(
        transparent, 
        transparent 24px, 
        #a0c1d1 25px
    );
    background-size: 100% 25px;
    
    padding: 20px 5px 5px 5px;
    box-shadow: 2px 5px 10px rgba(0,0,0,0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease-in-out;
}

/* The Red Pin */
.ghost-btn::before {
    content: "";
    position: absolute;
    top: -6px;
    left: 50%;
    transform: translateX(-50%);
    width: 12px;
    height: 12px;
    background: radial-gradient(circle, #ff4d4d 30%, #b30000 100%);
    border-radius: 50%;
    box-shadow: 1px 2px 3px rgba(0,0,0,0.5);
    z-index: 10;
    transition: opacity 0.1s ease; /* Smooth pin removal */
}

/* Random rotations */
.ghost-btn:nth-child(odd) { transform: rotate(1.5deg); }
.ghost-btn:nth-child(even) { transform: rotate(-2deg); }

/* "PICK UP" HOVER EFFECT */
.ghost-btn:hover {
    transform: scale(1.15) rotate(0deg) translateY(-5px) !important;
    background-color: #ffffff;
    z-index: 100;
    box-shadow: 10px 15px 25px rgba(0,0,0,0.7);
}

/* Remove the pin when hovering */
.ghost-btn:hover::before {
    opacity: 0;
}

/* --- 5. FEEDBACK & FOOTER --- */
#feedback {
    font-family: 'Permanent Marker', cursive;
    font-size: 1.6rem;
    height: 2rem;
    margin: 20px 0;
}

footer {
    margin-top: 50px;
    font-size: 0.8rem;
    color: #666;
}

/* Contact Form Styling */
.contact-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
    max-width: 500px;
    margin: 20px auto;
    text-align: left;
}

.contact-form input, .contact-form textarea {
    background: #111;
    border: 1px solid #444;
    color: white;
    padding: 10px;
    font-family: inherit;
}

.contact-form input:focus {
    border-color: #ff4444;
    outline: none;
}

/* Privacy Policy Styling */
.policy-text {
    text-align: left;
    line-height: 1.6;
    color: #bbb;
    background: #111;
    padding: 20px;
    border-radius: 5px;
    font-size: 0.9rem;
}

.policy-text h3 {
    color: #ff4444;
    margin-top: 20px;
}

/* --- BIG HOME MENU BUTTONS --- */

.home-btn {
    position: relative;
    width: 350px;  /* Doubled from 155px */
    height: 250px; /* Doubled from 75px */
    border: none;
    cursor: pointer;
    font-family: 'Permanent Marker', cursive;
    font-size: 4.0rem; /* Doubled font size */
    color: #2c3e50;
    
    /* Lined Paper Gradient - Scaled up the lines slightly for big text */
    background-color: #fdf6e3;
    background-image: repeating-linear-gradient(
        transparent, 
        transparent 48px, /* Doubled line spacing */
        #a0c1d1 50px     /* Doubled line thickness positioning */
    );
    background-size: 100% 50px; /* Doubled background size */
    
    padding: 40px 10px 10px 10px; /* Adjusted padding */
    box-shadow: 4px 10px 20px rgba(0,0,0,0.4); /* Stronger shadow */
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease-in-out;
    text-decoration: none; /* Important since these are likely <a> tags */
}

/* The Big Red Pin */
.home-btn::before {
    content: "";
    position: absolute;
    top: -12px; /* Adjusted for size */
    left: 50%;
    transform: translateX(-50%);
    width: 24px;  /* Doubled size */
    height: 24px; /* Doubled size */
    background: radial-gradient(circle, #ff4d4d 30%, #b30000 100%);
    border-radius: 50%;
    box-shadow: 2px 4px 6px rgba(0,0,0,0.5);
    z-index: 10;
    transition: opacity 0.1s ease;
}



/* "PICK UP" HOVER EFFECT - SCALED */
.home-btn:hover {
    transform: scale(1.1) rotate(0deg) translateY(-10px) !important;
    background-color: #ffffff;
    z-index: 100;
    box-shadow: 15px 25px 40px rgba(0,0,0,0.6);
    color: #8B0000; /* Ensure text stays dark on hover */
}

/* Remove the pin when hovering */
.home-btn:hover::before {
    opacity: 0;
}

/* Widen the main container to fit 3 big buttons */
.game-container {
    max-width: 1200px; /* Increased from 900px */
}

/* The Grid Container */
.menu-grid {
    display: grid;
    /* This creates 3 equal columns */
    grid-template-columns: repeat(3, 1fr); 
    gap: 50px; /* Space between the buttons */
    justify-items: center; /* Centers the buttons inside their grid slots */
    margin-top: 20px;
}

/* Mobile Responsiveness: If the screen is too small, stack them */
@media (max-width: 1000px) {
    .menu-grid {
        grid-template-columns: repeat(2, 1fr); /* Drop to 2 columns */
    }
}

@media (max-width: 700px) {
    .menu-grid {
        grid-template-columns: 1fr; /* Drop to 1 column on phones */
    }
}
