@import url('game.css');

:root {
    --bg-color: #0a0a0a;
    --text-color: #e0e0e0;
    --accent-color: #ff0055;
    --secondary-color: #00f3ff;
    --purple-color: #bc13fe;
    --panel-bg: #151515;
    --gradient-primary: linear-gradient(135deg, #bc13fe 0%, #ff0055 100%);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Raleway', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    overflow-x: hidden;
}

.container {
    width: 100%;
    max-width: 1200px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

header {
    text-align: center;
    margin-top: 2rem;
    margin-bottom: 2rem;
    position: relative;
    /* Needed for absolute positioning of auth container */
}

h1 {
    font-family: 'Orbitron', sans-serif;
    font-size: clamp(2.5rem, 8vw, 5rem);
    /* Responsive font size */
    background: var(--gradient-primary);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-transform: uppercase;
    letter-spacing: 4px;
    position: relative;
    text-shadow: none;
    /* Removed for gradient text */
    margin-bottom: 10px;
    font-weight: 900;
}

/* Fallback/Shadow for readability if gradient fails or for effect */
h1::after {
    content: attr(data-text);
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: none;
    -webkit-text-fill-color: var(--accent-color);
    text-shadow: 0 0 20px var(--accent-color);
    opacity: 0.5;
}

.subtitle {
    font-size: 1.2rem;
    color: var(--secondary-color);
    letter-spacing: 2px;
    text-transform: uppercase;
}

/* Auth Container */
.auth-container {
    position: absolute;
    top: -50px;
    right: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    gap: 15px;
}

@media (max-width: 768px) {
    .auth-container {
        position: static;
        justify-content: center;
        margin-bottom: 1rem;
        top: auto;
    }
}

/* Navigation */
.game-nav {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.nav-btn {
    background: transparent;
    border: 2px solid var(--secondary-color);
    color: var(--secondary-color);
    padding: 10px 25px;
    font-family: 'Orbitron', sans-serif;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    border-radius: 30px;
    /* Rounded corners */
    position: relative;
    overflow: hidden;
    font-weight: bold;
}

.nav-btn:hover,
.nav-btn.active {
    background: var(--secondary-color);
    color: var(--bg-color);
    box-shadow: 0 0 20px var(--secondary-color);
}

/* Game Panels */
.game-panel {
    display: none;
    animation: fadeIn 0.5s ease;
    width: 100%;
}

.game-panel.active {
    display: block;
}

.game-card {
    background: var(--panel-bg);
    border: 1px solid #333;
    padding: 2rem;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.game-card h2 {
    font-family: 'Orbitron', sans-serif;
    color: var(--text-color);
    margin-bottom: 1rem;
}

.game-card.locked {
    opacity: 0.5;
    border-style: dashed;
}

.play-btn {
    background: var(--gradient-primary);
    color: white;
    border: none;
    padding: 15px 40px;
    font-size: 1.2rem;
    font-family: 'Orbitron', sans-serif;
    cursor: pointer;
    margin-top: 1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s;
    border-radius: 50px;
    font-weight: bold;
    box-shadow: 0 4px 15px rgba(255, 0, 85, 0.4);
}

.play-btn:hover {
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 0 30px var(--accent-color);
}

footer {
    text-align: center;
    margin-top: auto;
    padding: 2rem;
    color: #666;
    font-size: 0.9rem;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Glitch Effect - Modified for gradient text */
.glitch {
    position: relative;
}

/* Simplified glitch for gradient text to avoid masking issues */
.glitch:hover {
    animation: shake 0.5s cubic-bezier(.36, .07, .19, .97) both;
}

@keyframes shake {

    10%,
    90% {
        transform: translate3d(-1px, 0, 0);
    }

    20%,
    80% {
        transform: translate3d(2px, 0, 0);
    }

    30%,
    50%,
    70% {
        transform: translate3d(-4px, 0, 0);
    }

    40%,
    60% {
        transform: translate3d(4px, 0, 0);
    }
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 3000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
}

.modal-content {
    background-color: var(--panel-bg);
    margin: 15% auto;
    padding: 2rem;
    border: 2px solid var(--accent-color);
    width: 90%;
    max-width: 400px;
    border-radius: 20px;
    box-shadow: 0 0 30px rgba(255, 0, 85, 0.3);
    position: relative;
}

.close-modal {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close-modal:hover {
    color: var(--secondary-color);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group input {
    width: 100%;
    padding: 12px;
    background: #0a0a0a;
    border: 1px solid #333;
    color: #fff;
    font-family: 'Raleway', sans-serif;
    font-size: 1rem;
    border-radius: 8px;
}

.form-group input:focus {
    outline: none;
    border-color: var(--secondary-color);
    box-shadow: 0 0 10px rgba(0, 243, 255, 0.2);
}

.full-width {
    width: 100%;
}

.switch-auth {
    margin-top: 1rem;
    font-size: 0.9rem;
    text-align: center;
}

.switch-auth a {
    color: var(--secondary-color);
    text-decoration: none;
}

/* Personal Photos Toggle */
.personal-photos-toggle {
    margin: 1.5rem 0;
    text-align: center;
}

.toggle-label {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    user-select: none;
}

.toggle-label input[type="checkbox"] {
    position: relative;
    width: 50px;
    height: 26px;
    -webkit-appearance: none;
    appearance: none;
    background: rgba(255, 255, 255, 0.2);
    outline: none;
    border-radius: 20px;
    box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2);
    transition: 0.3s;
    cursor: pointer;
}

.toggle-label input[type="checkbox"]:checked {
    background: #00f3ff;
}

.toggle-label input[type="checkbox"]::before {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    top: 3px;
    left: 3px;
    background: #fff;
    transition: 0.3s;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.toggle-label input[type="checkbox"]:checked::before {
    left: 27px;
}

.toggle-text {
    font-family: 'Orbitron', sans-serif;
    color: #00f3ff;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.photo-status {
    display: inline-block;
    margin-left: 0.75rem;
    font-size: 0.85rem;
    font-weight: 500;
}

/* Mobile adjustments for container */
@media (max-width: 600px) {
    .container {
        padding: 10px;
        gap: 1rem;
    }

    h1 {
        letter-spacing: 2px;
    }
}