/* General Page Styles */
html, body {
    height: 100%;
    margin: 0;
    padding: 0;
    font-family: 'Consolas', 'Courier New', monospace;
    color: #ffffff;
    overflow-x: hidden; /* Prevents horizontal scroll issues */
}

/* Disable text selection & copying */
body {
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

/* Disable dragging images */
img {
    pointer-events: none;
}

/* Full-Screen Loading Screen */
#loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #121212;
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    font-size: 20px;
    z-index: 9999;
}

/* Loader Animation */
.loader {
    border: 8px solid #ff9800;
    border-top: 8px solid white;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
    margin-bottom: 10px;
}

/* Spin Animation */
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Progress Bar */
.progress-bar-container {
    width: 30%;
    height: 10px;
    background: #333;
    border-radius: 5px;
    overflow: hidden;
    margin-top: 10px;
}

.progress-bar {
    width: 0%;
    height: 100%;
    background: #ff9800;
    transition: width 0.4s ease;
}

/* Background Fix */
body {
    background: url('background.gif') no-repeat center center fixed;
    background-size: cover;
}

/* Fix scrolling issues */
main {
    min-height: 100vh; /* Ensures the page fills the viewport */
    padding: 20px; /* Adds space at the top */
}

/* Header Styling */
header {
    background-color: #1e1e1e;
    padding: 0.5rem;
    text-align: center;
}

header h1 a {
    color: #ff9800;
    text-decoration: none;
}

/* Navigation Styling */
nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

nav ul li {
    display: inline;
    margin: 0 1rem;
}

nav a {
    color: #ffffff;
    text-decoration: none;
}

nav a:hover {
    color: #ff9800;
}

/*Logo Styling*/
.logo {
    height: 75px; /* Adjust the size as needed */
    vertical-align: middle; /* Align it with the text */
    margin-right: 10px; /* Add spacing between the logo and text */
}

/*Welcome Message*/
.welcome-container {
    display: flex; /* Arrange items side by side */
    align-items: center; /* Vertically align items */
    justify-content: flex-start; /* Ensure items stay left-aligned */
}

/*Visitor Counter*/
.visitor-counter {
    margin-right: 20px; /* Add space between counter and the welcome message */
}

.visitor-counter {
    margin-top: -70px; /* Add some spacing */
    text-align: center; /* Center it if needed */
}


/* Main Content */
main {
    flex: 1; /* Makes the main content take up remaining space */
    padding: 2rem;
    text-align: center;
}

/* Chat Page - Wider Container */
#chat-container {
    max-width: 800px; /* Increased from 600px */
    margin: 20px auto;
    padding: 15px;
    background: #1e1e1e;
    border-radius: 8px;
    text-align: center;
}

/* Chat Box - Wider */
#chat-box {
    height: 400px; /* Increased from 300px */
    overflow-y: auto;
    border: 1px solid #444;
    padding: 10px;
    background: #2e2e2e;
    display: flex;
    flex-direction: column;
}

/* Message Styling - Wider */
.message {
    background: #444;
    padding: 10px;
    margin: 8px;
    border-radius: 5px;
    position: relative;
    transition: background 0.3s ease-in-out;
    width: 95%;
    max-width: 750px; /* Adjusted for wider container */
    margin-left: auto;
    margin-right: auto;
}

/* Show delete button only when hovering */
.message:hover {
    background: #555;
}

/* Admin Name Styling */
.admin-name {
    color: #ff9800;
    font-weight: bold;
}

/* Admin Tag */
.admin-tag {
    color: #ff9800;
    font-weight: bold;
}

/* Timestamp */
.timestamp {
    font-size: 0.8rem;
    color: #bbb;
    margin-left: 5px;
    opacity: 0.8;
}

/* Delete Button (Admin Only) */
.delete-btn {
    position: absolute;
    top: 5px;
    right: 8px;
    color: red;
    font-size: 16px;
    cursor: pointer;
    font-weight: bold;
    background: none;
    border: none;
    display: none;
}

/* Show delete button only when hovering */
.message:hover .delete-btn {
    display: inline;
}

/* Chat Input */
#chat-input {
    width: 80%;
    padding: 10px;
    margin-top: 10px;
    border: 1px solid #666;
    background: #222;
    color: white;
}

/* Buttons */
button {
    padding: 10px;
    margin: 5px;
    background: #ff9800;
    color: white;
    border: none;
    cursor: pointer;
    transition: 0.3s;
}

button:hover {
    background: #e68900;
}

/* Login Popup */
#login-popup {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #1e1e1e;
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    z-index: 9999;
}

#login-popup input {
    width: 80%;
    padding: 10px;
    margin: 10px 0;
}

/* Welcome Popup */
#welcome-popup {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(30, 30, 30, 0.9);
    color: white;
    padding: 15px 20px;
    border-radius: 8px;
    font-size: 18px;
    font-weight: bold;
    opacity: 1;
    transition: opacity 0.5s ease-out;
    display: none;
}

/* Username Display Bar */
#username-display {
    background: #333;
    color: white;
    padding: 8px;
    text-align: center;
    font-size: 16px;
    border-radius: 8px;
    margin-bottom: 10px;
}

/* Settings Cards */
.background-buttons {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 10px;
}

.settings-button {
    background-color: #ff9800;
    color: white;
    border: none;
    padding: 10px 20px;
    cursor: pointer;
    font-size: 1rem;
    transition: 0.3s;
    border-radius: 5px;
}

.settings-button:hover {
    background-color: #ff7600;
}

/* Game Cards */
.card-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.game-card {
    background-color: #1e1e1e;
    color: #ffffff;
    width: 222px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    text-align: center;
    transition: transform 0.3s, box-shadow 0.3s;
    cursor: pointer;
}

.game-card img {
    width: 100%;
    height: 130px;
    object-fit: cover;
}

.game-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.5);
}

.game-card h3 {
    margin: 0.5rem 0;
    font-size: 1.2rem;
    color: #ff9800;
    text-decoration: none;
}

/*Proxy Cards*/
.card-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.proxy-card {
    background-color: #1e1e1e;
    color: #ffffff;
    width: 250px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    text-align: center;
    transition: transform 0.3s, box-shadow 0.3s;
    cursor: pointer;
}

.proxy-card img {
    width: 100%;
    height: 150px;
    object-fit: cover;
}

.proxy-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.5);
}

.proxy-card h3 {
    margin: 0.5rem 0;
    font-size: 1.5rem;
    color: #ff9800;
}

.proxy-card p {
    font-size: 1rem;
    padding: 0 1rem 1rem;
}

.card-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.form-card {
    background-color: #1e1e1e;
    color: #ffffff;
    width: 500px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    text-align: center;
    transition: transform 0.3s, box-shadow 0.3s;
    cursor: pointer;
}

.form-card img {
    width: 100%;
    height: 110px;
    object-fit: cover;
}

.form-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.5);
}

.form-card h3 {
    margin: 0.5rem 0;
    font-size: 1.2rem;
    color: #ff9800;
    text-decoration: none;
}

/*Link Card*/
.card-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.link-card {
    background-color: #1e1e1e;
    color: #ffffff;
    width: 200px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    text-align: center;
    transition: transform 0.3s, box-shadow 0.3s;
    cursor: pointer;
}

.link-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.5);
}

.link-card h3 {
    margin: 0.5rem 0;
    font-size: 1.2rem;
    color: #ff9800;
    text-decoration: none;
}

/* Search Bar */
#search-bar {
    top: 0;
    width: 100%;
    background: #1e1e1e;
    padding: 10px 0;
    text-align: center;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    z-index: 1000;
}

/* 🔍 Search Input */
#gameSearch {
    width: 50%;
    max-width: 800px;
    padding: 8px; /* Reduced thickness */
    font-size: 14px;
    border: 2px solid #ff9800;
    border-radius: 5px;
    outline: none;
    background: #222;
    color: white;
    transition: box-shadow 0.3s ease-in-out;
}

/* Glow Effect */
#gameSearch:focus {
    box-shadow: 0 0 10px rgba(255, 152, 0, 0.7);
}

/*  Search Icon */
.search-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 5px; /* Reduced spacing */
}

/*  Fix Search Icon Alignment */
.search-icon {
    font-size: 16px;
    color: #ff9800;
}

/*In case of no results*/
#no-results {
    text-align: center;
    font-size: 18px;
    color: #b3b3b3;
    margin: 20px 0;
    display: none;
}

/* Fullscreen iframe container */
#game-container {
    position: fixed; /* Fixed to the viewport */
    top: 0;
    left: 0;
    width: 100%; /* Full width */
    height: 100%; /* Full height */
    background-color: #000; /* Optional: black background behind the iframe */
    z-index: 1000; /* Ensure it appears above everything */
}

/* Fullscreen iframe */
#game-frame {
    width: 100%;
    height: 100%;
    border: none;
}

/* Footer Styling */
footer {
    background-color: #1e1e1e;
    padding: 0.5rem;
    text-align: center;
    font-size: 0.8rem;
    margin-top: 2rem;
}

/* Settings Page Styling */
.settings-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    margin-top: 2rem;
}

.settings-button {
    background-color: #ff9800;
    color: #ffffff;
    font-size: 1.2rem;
    padding: 1rem 2rem;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    text-decoration: none;
    text-align: center;
    transition: background-color 0.3s, transform 0.2s;
}

.settings-button:hover {
    background-color: #e68900;
    transform: translateY(-3px);
}
