/* Theme Imports */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;500;700&display=swap');

:root {
    --primary: #5b1c8d;
    --accent: #ffcc70;
    --text-glow: #ff4ecd;
    --glass: rgba(255, 255, 255, 0.05);
    --border: rgba(255, 255, 255, 0.1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: 'Poppins', sans-serif; color: white; overflow-x: hidden; }

/* The Background */
canvas#bg { position: fixed; inset: 0; z-index: -1; background: linear-gradient(135deg, #3a145f 0%, #5b1c8d 40%, #2a0a4a 75%, #120318 100%); }

/* Navbar */
nav {
    position: fixed; top: 0; width: 100%; padding: 20px 50px;
    display: flex; justify-content: space-between; align-items: center;
    background: rgba(18, 3, 24, 0.8); backdrop-filter: blur(10px);
    z-index: 100; border-bottom: 1px solid var(--border);
}
.nav-links a {
    color: white; text-decoration: none; margin: 0 15px;
    font-weight: 500; transition: 0.3s;
}
.nav-links a:hover { color: var(--accent); text-shadow: 0 0 10px var(--accent); }

/* Discord / Social Buttons */
.discord-btn {
    background: #5865F2; color: white; padding: 10px 20px;
    border-radius: 20px; text-decoration: none; font-weight: bold;
    transition: transform 0.2s; display: flex; align-items: center; gap: 8px;
}
.discord-btn:hover { transform: scale(1.05); box-shadow: 0 0 15px #5865F2; }

/* Layouts */
.container { padding: 120px 20px 50px; max-width: 1200px; margin: 0 auto; text-align: center; }
.section-divider { height: 2px; background: linear-gradient(90deg, transparent, var(--accent), transparent); margin: 60px 0; width: 100%; }

/* Titles */
h1.title {
    font-size: 3.5rem; margin-bottom: 20px;
    background: linear-gradient(120deg, #ffcc70, #ff4ecd);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}

/* Number Counters (Box UI) */
.counter-box { display: inline-flex; align-items: center; gap: 5px; margin: 20px 0; }
.digit {
    background: var(--glass); border: 1px solid var(--accent);
    color: var(--accent); padding: 10px 15px; font-size: 2rem;
    font-weight: bold; border-radius: 8px; box-shadow: 0 0 10px rgba(255, 204, 112, 0.2);
}

/* --- NEW: ADD DOLLAR SIGN TO COUNTERS --- */
/* This automatically adds a '$' before the Giveaway and Wager counters */
#giveaway-counter::before, 
#total-wager-counter::before {
    content: '$';
    font-size: 2.2rem;
    color: var(--accent);
    font-weight: bold;
    margin-right: 8px;
    text-shadow: 0 0 15px var(--accent);
}

/* Leaderboard Cards */
.top-ranks { display: flex; justify-content: center; align-items: flex-end; gap: 20px; margin-bottom: 50px; }
.rank-card {
    background: var(--glass); border: 1px solid var(--border);
    padding: 20px; border-radius: 15px; width: 200px; text-align: center;
    position: relative; backdrop-filter: blur(5px);
}
.rank-1 { height: 300px; border-color: gold; box-shadow: 0 0 20px rgba(255, 215, 0, 0.3); order: 2; }
.rank-2 { height: 250px; border-color: silver; order: 1; }
.rank-3 { height: 250px; border-color: #cd7f32; order: 3; }
.rank-avatar { width: 60px; height: 60px; background: #333; border-radius: 50%; margin: 0 auto 10px; }

/* Tables */
table { width: 100%; border-collapse: collapse; margin-top: 20px; background: var(--glass); border-radius: 12px; overflow: hidden; }
th, td { padding: 15px; text-align: left; border-bottom: 1px solid var(--border); }
th { background: rgba(0,0,0,0.3); color: var(--accent); }

/* Guess Page */
.locked-input { opacity: 0.5; pointer-events: none; }
.unlocked { opacity: 1; pointer-events: all; transition: 0.3s; }

/* Professional Footer */
.site-footer {
    width: 100%;
    background: #0f1016; /* Dark background */
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding: 40px 0 30px;
    margin-top: 80px;
    font-family: sans-serif;
    position: relative;
    z-index: 10;
}
.footer-container { max-width: 1200px; margin: 0 auto; padding: 0 40px; }
.footer-top { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; margin-bottom: 25px; border-bottom: 1px solid rgba(255,255,255,0.1); padding-bottom: 20px; }
.footer-nav a { color: #aaa; text-decoration: none; font-size: 0.85rem; font-weight: 600; letter-spacing: 1px; margin-right: 25px; transition: 0.3s; }
.footer-nav a:hover { color: #ffcc70; }
.footer-socials a { color: #eee; font-size: 1.3rem; margin-left: 20px; transition: 0.3s; }
.footer-socials a:hover { color: #ffcc70; transform: translateY(-3px); }
.footer-bottom { text-align: center; color: #777; font-size: 0.85rem; line-height: 1.6; }
.footer-bottom a { color: #ffcc70; text-decoration: none; }
.footer-bottom a:hover { text-decoration: underline; }

/* --- ANIMATIONS --- */
.rank-card { transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease; cursor: default; }
.rank-card:hover { transform: translateY(-10px) scale(1.03); z-index: 10; }
.rank-1:hover { box-shadow: 0 0 50px rgba(255, 215, 0, 0.6), inset 0 0 20px rgba(255, 215, 0, 0.1); border-color: #ffffff; }
.rank-2:hover { box-shadow: 0 0 40px rgba(192, 192, 192, 0.5), inset 0 0 15px rgba(192, 192, 192, 0.1); border-color: #ffffff; }
.rank-3:hover { box-shadow: 0 0 40px rgba(205, 127, 50, 0.6), inset 0 0 15px rgba(205, 127, 50, 0.1); border-color: #ffffff; }

@keyframes simpleFloat { 0% { opacity: 0; transform: translateY(30px); } 100% { opacity: 1; transform: translateY(0); } }
.title, nav, .logo { opacity: 0; animation: simpleFloat 0.8s ease-out forwards; animation-delay: 0.1s; }
h3, h4, .nav-links { opacity: 0; animation: simpleFloat 0.8s ease-out forwards; animation-delay: 0.2s; }
.counter-box, .guess-box, .timer-container { opacity: 0; animation: simpleFloat 0.8s ease-out forwards; animation-delay: 0.3s; }
.rank-card { opacity: 0; animation: simpleFloat 0.6s ease-out forwards; }
.rank-card:nth-of-type(1) { animation-delay: 0.3s; }
.rank-card:nth-of-type(2) { animation-delay: 0.4s; }
.rank-card:nth-of-type(3) { animation-delay: 0.5s; }
table, ul#guess-list { opacity: 0; animation: simpleFloat 0.8s ease-out forwards; animation-delay: 0.6s; }

/* 1. Logo Styling */
img[src="images/logo.png"] { border-radius: 20px; box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5); transition: transform 0.3s ease, box-shadow 0.3s ease; }
img[src="images/logo.png"]:hover { transform: translateY(-2px) scale(1.05); box-shadow: 0 0 20px rgba(255, 204, 112, 0.6); }

/* 2. Navbar Logo Sizing */
.logo img { height: 50px; width: auto; cursor: pointer; }

/* 3. The "Contact Us" Blue Pill Button */
.cta-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white; padding: 10px 25px; border: none; border-radius: 50px;
    font-weight: 600; cursor: pointer; font-family: 'Poppins', sans-serif;
    transition: transform 0.3s, box-shadow 0.3s;
    box-shadow: 0 4px 15px rgba(118, 75, 162, 0.4);
}
.cta-btn:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(118, 75, 162, 0.6); }

/* =========================================
   NEW: INDIVIDUAL SOCIAL CARDS UI
   ========================================= */

/* The Grid Container */
.social-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); /* Auto-responsive */
    gap: 20px;
    max-width: 1000px;
    margin: 40px auto;
    padding: 0 20px;
}

/* Base Card Style */
.social-card {
    background: rgba(25, 20, 40, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 30px 20px;
    text-align: center;
    text-decoration: none;
    color: white;
    backdrop-filter: blur(10px);
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.social-card i {
    font-size: 2.5rem;
    margin-bottom: 15px;
    transition: 0.3s;
}

.social-card h3 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 5px;
}

.social-card span {
    font-size: 0.85rem;
    color: #aaa;
}

/* --- BRAND SPECIFIC HOVER EFFECTS --- */

/* Discord (Blurple) */
.card-discord:hover {
    border-color: #5865F2;
    box-shadow: 0 10px 30px rgba(88, 101, 242, 0.4);
    transform: translateY(-5px);
}
.card-discord:hover i { color: #5865F2; }

/* Kick (Bright Green) */
.card-kick:hover {
    border-color: #53FC18;
    box-shadow: 0 10px 30px rgba(83, 252, 24, 0.4);
    transform: translateY(-5px);
}
.card-kick:hover i { color: #53FC18; }

/* X / Twitter (White/Grey) */
.card-x:hover {
    border-color: #ffffff;
    box-shadow: 0 10px 30px rgba(255, 255, 255, 0.3);
    transform: translateY(-5px);
}
.card-x:hover i { color: #ffffff; }

/* Instagram (Pink/Gradient) */
.card-insta:hover {
    border-color: #E1306C;
    box-shadow: 0 10px 30px rgba(225, 48, 108, 0.4);
    transform: translateY(-5px);
}
.card-insta:hover i { color: #E1306C; }

/* --- MOBILE FIXES --- */
@media screen and (max-width: 768px) {
    
    /* 1. Fix the Main Container width */
    .container, body, html {
        width: 100%;
        overflow-x: hidden; /* Stops side-scrolling */
    }

    /* 2. Shrink the Giant Text */
    h1, .hero-text { 
        font-size: 30px !important; /* Forces text to be smaller */
        word-wrap: break-word; /* Prevents text cutting off */
    }

    /* 3. Make Images fit the screen */
    img {
        max-width: 100%;
        height: auto;
    }
}

/* --- MOBILE NAVIGATION & FOOTER FIX --- */
@media screen and (max-width: 768px) {

    /* 1. Stack the Navbar items vertically */
    header, nav, .navbar {
        flex-direction: column; /* Stacks Logo, Links, Button */
        height: auto; /* Lets it grow tall */
        padding: 20px 10px;
        gap: 15px; /* Space between items */
    }

    /* 2. Center the Navigation Links */
    .nav-links, ul {
        flex-direction: column; /* Stacks the words "Home, Leaderboard..." */
        text-align: center;
        width: 100%;
        gap: 10px;
        padding: 0;
    }

    /* 3. Adjust the Logo Size */
    .logo img {
        height: 60px; /* Make logo smaller for phone */
        width: auto;
    }

    /* 4. Fix the "Contact Us" Button */
    .cta-button, .btn {
        width: 80%; /* Make button wide and easy to tap */
        margin: 10px auto;
        display: block;
    }

    /* 5. Clean up the Footer */
    footer {
        text-align: center;
        padding: 30px 15px;
    }
    
    footer .footer-content {
        flex-direction: column;
        gap: 20px;
    }

    footer .social-icons {
        justify-content: center; /* Centers the Discord/Twitter icons */
        margin-top: 10px;
    }
}

