/* Import Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;600;700&display=swap');

/* Base styles */
:root {
    --primary-color: #1795e8;
    --secondary-color: #f2ce7c;
    --accent-color: #3e1480;
    --background-color: #1a1a2e;
    --text-color: #ffffff;
    --gold-color: #ffd700;
    --silver-color: #c0c0c0;
    --bronze-color: #cd7f32;
}

/* Cosmic Background Effect */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 50% 50%, rgba(138, 43, 226, 0.4) 0%, transparent 60%),
        radial-gradient(circle at 20% 20%, rgba(155, 89, 182, 0.4) 0%, transparent 40%),
        radial-gradient(circle at 80% 80%, rgba(195, 155, 211, 0.4) 0%, transparent 40%);
    opacity: 0.6;
    z-index: -2;
    animation: cosmicPulse 15s ease infinite;
}

/* Particle Constellation Effect */
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(circle at 50% 50%, #fff 1px, transparent 1px),
        radial-gradient(circle at 20% 20%, #fff 1px, transparent 1px),
        radial-gradient(circle at 80% 80%, #fff 1px, transparent 1px),
        radial-gradient(circle at 30% 70%, #fff 1px, transparent 1px),
        radial-gradient(circle at 70% 30%, #fff 1px, transparent 1px);
    background-size: 100px 100px, 120px 120px, 80px 80px, 90px 90px, 110px 110px;
    opacity: 0.15;
    z-index: -1;
    animation: constellationMove 60s linear infinite;
}

@keyframes cosmicPulse {
    0%, 100% { transform: scale(1); opacity: 0.6; }
    50% { transform: scale(1.1); opacity: 0.4; }
}

@keyframes constellationMove {
    0% { background-position: 0 0; }
    100% { background-position: 100px 100px; }
}

body {
    margin: 0;
    padding: 0;
    font-family: 'Outfit', sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Update header styles */
header {
    background: linear-gradient(to right, var(--primary-color), var(--accent-color));
    padding: 0.75rem 2rem;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.4);
    display: flex;
    justify-content: flex-start;
    align-items: center;
    box-sizing: border-box;
    backdrop-filter: blur(5px);
    opacity: 0.95;
}

.logo-container {
    display: flex;
    align-items: center;
    margin-right: 2rem;
    padding: 0.25rem;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
}

.logo-container:hover {
    background: rgba(255, 255, 255, 0.15);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
    transform: translateY(-1px);
}

.logo {
    height: 30px;
    width: auto;
    transition: transform 0.3s ease;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5)) brightness(1.1) contrast(1.1);
}

.logo:hover {
    transform: scale(1.05);
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.7)) brightness(1.2) contrast(1.2);
}

nav {
    margin-left: auto;
    display: flex;
    justify-content: flex-end;
}

nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    gap: 2rem;
    align-items: center;
}

nav a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: bold;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

nav a:hover {
    background-color: var(--accent-color);
    transform: translateY(-2px);
}

/* Mobile dropdown slide animation */
.menu-toggle {
  display: none;
  cursor: pointer;
  font-size: 1.5rem;
  color: var(--text-color);
}
@media (max-width: 768px) {
  .menu-toggle {
    display: block;
  }
  nav {
    display: block;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease-in-out;
    background: var(--background-color);
  }
  nav ul {
    display: flex;
    flex-direction: column;
    gap: 0;
  }
  nav ul li {
    border-bottom: 1px solid rgba(255,255,255,0.1);
    margin: 0;
  }
  header.open nav {
    max-height: 500px;
  }
}

/* Update typography */
h1, h2, h3 {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.leaderboard-header h1 {
    font-size: 3rem;
    text-transform: uppercase;
    background: linear-gradient(135deg, var(--accent-color), #ffffff);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    background-size: 200% 200%;
    animation: gradientText 5s ease infinite;
}

@keyframes gradientText {
    0% { background-position: 0% 50% }
    50% { background-position: 100% 50% }
    100% { background-position: 0% 50% }
}

/* Update button styles */
.btn {
    display: inline-block;
    padding: 1rem 2rem;
    margin: 1rem;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    color: var(--text-color);
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(138, 43, 226, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(138, 43, 226, 0.5);
    border-color: rgba(255, 255, 255, 0.2);
}

.btn:active {
    transform: translateY(1px);
    box-shadow: 0 2px 10px rgba(138, 43, 226, 0.2);
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        120deg,
        transparent,
        rgba(255, 255, 255, 0.3),
        transparent
    );
    transition: 0.6s ease;
}

.btn:hover::before {
    left: 100%;
}

/* Update table styles */
.leaderboard-table {
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.37);
    background: rgba(138, 43, 226, 0.1);
    box-shadow: 0 8px 32px 0 rgba(138, 43, 226, 0.2);
}

.leaderboard-table th {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    background-size: 200% 200%;
    animation: gradientMove 5s ease infinite;
    text-transform: uppercase;
    letter-spacing: 1px;
    opacity: 0.95;
}

.leaderboard-table tr:hover {
    background-color: rgba(155, 89, 182, 0.15);
}

/* Container styles */
.container {
    max-width: 1200px;
    margin: 100px auto 2rem;
    padding: 2rem;
}

/* Leaderboard header styles */
.leaderboard-header {
    text-align: center;
    margin-bottom: 3rem;
}

.leaderboard-header h1 {
    color: var(--accent-color);
    font-size: 2.5rem;
    margin-bottom: 1rem;
    text-shadow: 0 0 10px rgba(145, 70, 255, 0.5);
}

/* Top three positions */
.top-three {
    display: flex;
    justify-content: center;
    align-items: flex-end;
    gap: 2rem;
    margin-bottom: 3rem;
}

.top-position {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    border-radius: 10px;
    padding: 1.5rem;
    text-align: center;
    position: relative;
    transition: transform 0.3s ease;
    opacity: 0.9;
    box-shadow: 0 8px 32px rgba(138, 43, 226, 0.3);
    animation: glow 2s ease-in-out infinite;
}

.top-position:hover {
    transform: translateY(-10px);
}

.position-1 {
    order: 2;
    height: 300px;
    border: 3px solid var(--gold-color);
    box-shadow: 0 0 20px var(--gold-color);
}

.position-2 {
    order: 1;
    height: 250px;
    border: 3px solid var(--silver-color);
    box-shadow: 0 0 20px var(--silver-color);
    animation: glow-silver 2s ease-in-out infinite;
}

.position-3 {
    order: 3;
    height: 200px;
    border: 3px solid var(--bronze-color);
    box-shadow: 0 0 20px var(--bronze-color);
    animation: glow-bronze 2s ease-in-out infinite;
}

@keyframes glow {
    0% { box-shadow: 0 0 20px var(--gold-color); }
    50% { box-shadow: 0 0 30px var(--gold-color); }
    100% { box-shadow: 0 0 20px var(--gold-color); }
}

.position-2 {
    animation: glow-silver 2s ease-in-out infinite;
}

.position-3 {
    animation: glow-bronze 2s ease-in-out infinite;
}

@keyframes glow-silver {
    0% { box-shadow: 0 0 20px var(--silver-color); }
    50% { box-shadow: 0 0 30px var(--silver-color); }
    100% { box-shadow: 0 0 20px var(--silver-color); }
}

@keyframes glow-bronze {
    0% { box-shadow: 0 0 20px var(--bronze-color); }
    50% { box-shadow: 0 0 30px var(--bronze-color); }
    100% { box-shadow: 0 0 20px var(--bronze-color); }
}

.user-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    margin: 0 auto 1rem;
    overflow: hidden;
    border: 3px solid var(--gold-color);
    background-color: var(--background-color);
    animation: heartbeat 1.17s ease-in-out infinite;
}

.position-2 .user-avatar {
    border-color: var(--silver-color);
    animation-delay: 0.2s;
    animation-duration: 1.95s;
}

.position-3 .user-avatar {
    border-color: var(--bronze-color);
    animation-delay: 0.4s;
    animation-duration: 2.34s;
}

@keyframes heartbeat {
    0% { transform: scale(1); }
    15% { transform: scale(1.15); }
    25% { transform: scale(1.05); }
    35% { transform: scale(1.15); }
    45% { transform: scale(1); }
    100% { transform: scale(1); }
}

/* Table styles */
.leaderboard-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 2rem;
    background: rgba(100, 65, 165, 0.1);
    border-radius: 10px;
    overflow: hidden;
}

.leaderboard-table th,
.leaderboard-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.leaderboard-table th {
    background-color: var(--primary-color);
    color: var(--text-color);
    font-weight: bold;
}

.leaderboard-table tr:hover {
    background-color: rgba(145, 70, 255, 0.1);
}

/* Rules section */
.rules-section {
    background: rgba(138, 43, 226, 0.2);
    padding: 2rem;
    border-radius: 10px;
    margin-top: 3rem;
    border: 1px solid rgba(155, 89, 182, 0.2);
    box-shadow: 0 8px 32px rgba(138, 43, 226, 0.1);
}

.rules-section h2 {
    color: var(--secondary-color);
    margin: 0 0 1rem 0;
    font-size: 1.8rem;
    text-shadow: 0 0 15px rgba(242, 206, 124, 0.5);
    letter-spacing: 1px;
}

.rules-section ul {
    list-style-type: none;
    padding-left: 0;
}

.rules-section li {
    margin-bottom: 0.5rem;
    padding-left: 1.5rem;
    position: relative;
}

.rules-section li::before {
    content: "•";
    color: var(--accent-color);
    position: absolute;
    left: 0;
}

/* Footer styles */
footer {
    background: linear-gradient(to right, var(--primary-color), var(--accent-color));
    color: var(--text-color);
    padding: 1.5rem 2rem 1rem;
    margin-top: auto;
    backdrop-filter: blur(10px);
    opacity: 0.95;
}

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

.footer-section {
    padding: 0 0.5rem;
}

.footer-logo-img {
    height: 24px;
    width: auto;
    margin-bottom: 0.5rem;
}

.footer-social {
    display: flex;
    gap: 0.75rem;
    margin-top: 0.5rem;
}

.footer-section h3 {
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links li {
    margin-bottom: 0.3rem;
}

.footer-links a {
    color: var(--text-color);
    text-decoration: none;
    transition: all 0.3s ease;
    opacity: 0.8;
    font-size: 0.9rem;
}

.footer-links a:hover {
    padding-left: 5px;
    opacity: 1;
}

.footer-bottom {
    max-width: 1200px;
    margin: 0.75rem auto 0;
    padding-top: 0.75rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
    font-size: 0.8rem;
}

.responsible-gaming {
    font-size: 0.75rem;
    opacity: 0.8;
    max-width: 800px;
    margin: 0.5rem auto 0;
}

/* Glowing text effect */
.glowing-text {
    color: var(--secondary-color);
    font-weight: bold;
    text-decoration: none;
    text-shadow: 0 0 10px rgba(242, 206, 124, 0.6),
                 0 0 20px rgba(242, 206, 124, 0.4);
    animation: glow 2s ease-in-out infinite alternate;
}

.play-now-btn {
    position: relative;
    box-sizing: border-box;
    cursor: pointer;
    user-select: none;
    vertical-align: middle;
    font-family: 'Outfit', sans-serif;
    text-align: center;
    display: flex;
    -webkit-box-pack: center;
    justify-content: center;
    -webkit-box-align: center;
    align-items: center;
    border-radius: 12px;
    transition: all 0.3s ease-in-out;
    background: linear-gradient(420deg, rgb(255, 206, 0) 0%, rgb(255, 206, 0) 49%, rgb(238, 175, 14) 49%, rgb(238, 175, 14) 100%) left center / 100% 100% no-repeat;
    padding: 6px 14px 10px;
    color: #ffffff;
    -webkit-text-stroke-color: #C56A18;
    stroke: #1a1a2e;
    stroke-width: 2px;
}

.play-now-btn:hover {            
    background-size: 180% 100%;
}

.rules-section .play-now-btn{ 
    width: 128px !important;
}

@keyframes glow {
    from {
        text-shadow: 0 0 10px rgba(242, 206, 124, 0.6),
                     0 0 20px rgba(242, 206, 124, 0.4);
    }
    to {
        text-shadow: 0 0 15px rgba(242, 206, 124, 0.8),
                     0 0 25px rgba(242, 206, 124, 0.6);
    }
}

/* Responsive design */
@media (max-width: 768px) {
    .top-three {
        flex-direction: column;
        align-items: center;
        gap: 1rem;
    }

    .position-1 {
        order: 1;
        height: auto;
        width: 100%;
        max-width: 300px;
    }

    .position-2 {
        order: 2;
        height: auto;
        width: 100%;
        max-width: 300px;
    }

    .position-3 {
        order: 3;
        height: auto;
        width: 100%;
        max-width: 300px;
    }

    .container {
        padding: 1rem;
    }

    .leaderboard-table {
        font-size: 0.9rem;
    }

    header {
        padding: 0.5rem 1rem;
    }

    .logo-container {
        padding: 0.2rem;
    }

    .logo {
        height: 24px;
        filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5)) brightness(1.1) contrast(1.1);
    }

    nav ul {
        gap: 1rem;
    }

    nav a {
        padding: 0.4rem 0.8rem;
        font-size: 0.9rem;
    }

    body::before {
        opacity: 0.2;
    }

    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 0.75rem;
    }

    .footer-social {
        justify-content: center;
    }

    .footer-section {
        padding: 0;
    }
}

.countdown {
    background: rgba(23, 149, 232, 0.2);
    padding: 1.5rem;
    border-radius: 10px;
    margin: 2rem 0;
    border: 1px solid rgba(23, 149, 232, 0.3);
    box-shadow: 0 4px 15px rgba(23, 149, 232, 0.2);
}

.countdown p {
    margin: 0;
    font-size: 1.2rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

#countdown-timer {
    font-size: 2.5rem;
    font-weight: bold;
    color: var(--secondary-color);
    text-shadow: 0 0 15px rgba(242, 206, 124, 0.5);
    margin-top: 0.5rem;
    display: block;
} 