
:root {
    --menu-primary-color: #00ff9d;
    --menu-secondary-color: #ff00ff;
}

body {
    background-image: url("/assets/Background.png");
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    color: var(--text-color);
    font-family: var(--font-body);
    margin: 0;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

h1, h2, h3 {
    font-family: var(--font-display);
    color: var(--primary-color);
    text-shadow: 0 0 5px var(--primary-color);
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--secondary-color);
}

/* Header & Nav */
header {
    background-color: var(--surface-color);
    padding: 1rem 0;
    border-bottom: 2px solid var(--border-color);
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

header .logo {
    font-family: var(--font-display);
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--menu-primary-color);
}

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

header nav a {
    font-weight: 700;
    text-transform: uppercase;
    color: var(--menu-primary-color);
}

header nav a:hover {
    color: var(--menu-secondary-color);
}

.auth-links a {
    margin-left: 1rem;
    color: var(--menu-primary-color);
}

.auth-links a:hover {
    color: var(--menu-secondary-color);
}

/* Buttons */
.button, button {
    background-color: var(--primary-color);
    color: var(--bg-color);
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    font-weight: 700;
    cursor: pointer;
    text-transform: uppercase;
    transition: background-color: 0.3s ease;
}

.button:hover, button:hover {
    background-color: var(--secondary-color);
    color: var(--bg-color);
}

.button-secondary {
    background-color: #6c757d; /* A neutral gray */
    color: white;
}

.button-secondary:hover {
    background-color: #5a6268; /* A darker gray for hover */
    color: white;
}
.button-danger {
    background-color: #dc3545; /* A standard red color */
    color: white;
}

.button-danger:hover {
    background-color: #c82333; /* A darker red for hover */
    color: white;
}

/* Main Content */
main {
    padding: 2rem 0;
}

/* Footer */
footer {
    text-align: center;
    padding: 2rem 0;
    margin-top: 2rem;
    border-top: 1px solid var(--border-color);
    color: var(--text-muted);
}

/* Forms */
.form-stacked .form-group {
    margin-bottom: 1.5rem;
}

.form-stacked label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 700;
}

.form-stacked input[type="text"],
.form-stacked input[type="email"],
.form-stacked input[type="password"],
.form-stacked textarea {
    width: 100%;
    padding: 10px;
    background-color: var(--bg-color);
    border: 1px solid var(--border-color);
    color: var(--text-color);
    border-radius: 5px;
    box-sizing: border-box;
}

.form-stacked .error-text {
    color: #ff4d4d;
    font-size: 0.9rem;
    margin-top: 0.25rem;
    display: block;
}
.form-check {
    display: flex;
    align-items: center;
}

/* Merch Grid */
.merch-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
}

.merch-card {
    background-color: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}

.merch-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 0 15px var(--primary-color);
}

.merch-image {
    width: 100%;
    height: auto;
    aspect-ratio: 1 / 1;
    object-fit: cover;
}

.merch-info {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.merch-description {
    flex-grow: 1;
    margin-bottom: 1.5rem;
}

/* Admin Dashboard & Tables */
.admin-stats {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background-color: var(--surface-color);
    padding: 1.5rem;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    text-align: center;
}

.stat-card h2 {
    margin-top: 0;
    font-size: 1.2rem;
    color: var(--text-muted);
    text-shadow: none;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1.5rem;
}

th, td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

/* Homepage Featured Video */
.featured-video {
    margin: 2rem 0;
    text-align: center;
}

.featured-video h3 {
    margin-bottom: 1rem;
}

/* General Styles */
.section-divider {
    border: 0;
    height: 1px;
    background-image: linear-gradient(to right, rgba(0, 0, 0, 0), var(--primary-color), rgba(0, 0, 0, 0));
    margin: 3rem 0;
}

/* Video Player */
.video-player {
    /* This makes the video scale with its container */
    width: 100%;
    height: auto;
    /* On large screens, it won't exceed this width and will be centered */
    max-width: 960px;
    display: block;
    margin-left: auto;
    margin-right: auto;
    background-color: #000;
    border-radius: 8px;
}

/* Video Grid */
.video-grid {
    display: grid;
    /* This will create a 3-column grid on most desktops inside the container */
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.video-card {
    background-color: var(--surface-color);
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.2s ease-in-out, border-color 0.2s ease-in-out;
    border: 1px solid var(--border-color);
    cursor: pointer;
}

.video-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary-color);
}

.video-thumbnail {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    display: block; /* Removes bottom space under image */
}

.video-card-title {
    padding: 1rem;
    font-weight: bold;
    color: var(--text-color);
}


/* Video Modal */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.85);
    display: none; /* Hidden by default */
    justify-content: center;
    align-items: center;
    z-index: 1000;
    padding: 20px;
    box-sizing: border-box;
}

.modal-content {
    background-color: var(--surface-color);
    border-radius: 8px;
    padding: 1.5rem;
    width: 100%;
    max-width: 960px; /* Same as video player for consistency */
    border: 1px solid var(--border-color);
    box-shadow: 0 5px 25px rgba(0,0,0,0.5);
    animation: fadeIn 0.3s ease-in-out;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 1rem;
}

.modal-title {
    margin: 0;
    font-size: 1.5rem;
    text-shadow: none; /* Optional: tone down the glow in the modal */
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 2.5rem;
    font-weight: bold;
    line-height: 1;
    cursor: pointer;
    padding: 0;
    transition: color 0.2s ease;
}

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

.modal-body .video-player {
    max-width: 100%; /* The player should fill the modal content width */
}

@keyframes fadeIn {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}


/* Pagination */
.pagination-nav {
    display: flex;
    justify-content: center;
    margin-top: 2.5rem;
}

.pagination {
    display: flex;
    padding-left: 0;
    list-style: none;
    border-radius: 0.25rem;
}

.page-item .page-link {
    position: relative;
    display: block;
    padding: 0.5rem 1rem;
    margin-left: -1px;
    line-height: 1.25;
    color: var(--primary-color);
    background-color: var(--surface-color);
    border: 1px solid var(--border-color);
    transition: all 0.2s ease-in-out;
    font-weight: 700;
}

.page-item:first-child .page-link {
    margin-left: 0;
}

.page-item.active .page-link {
    background-color: var(--primary-color);
    color: var(--bg-color);
    border-color: var(--primary-color);
}

.page-item.disabled .page-link {
    color: var(--text-muted);
    pointer-events: none;
    background-color: var(--surface-color);
}

/* About Page */
.about-container {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    align-items: center;
    margin-top: 2rem;
}

@media (min-width: 768px) {
    .about-container {
        grid-template-columns: 1fr 2fr;
    }
}

.about-image img {
    width: 100%;
    border-radius: 50%;
    border: 3px solid var(--primary-color);
    box-shadow: 0 0 20px var(--primary-color);
}

.about-text h2 {
    margin-top: 0;
}

.about-text h3 {
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.socials-large {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.socials-large .social-link {
    background-color: var(--surface-color);
    padding: 10px 20px;
    border-radius: 5px;
    font-weight: 700;
    border: 1px solid var(--border-color);
    transition: all 0.2s ease-in-out;
}

.socials-large .social-link:hover {
    background-color: var(--primary-color);
    color: var(--bg-color);
    border-color: var(--primary-color);
}

/* Chat Page */
.chat-container {
    background-color: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    display: flex;
    flex-direction: column; /* Default for mobile */
    height: 70vh;
    max-height: 700px;
}

@media (min-width: 992px) {
    .chat-container {
        flex-direction: row; /* Side-by-side on desktop */
    }
}

.chat-main {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    min-width: 0; /* Prevents flexbox overflow */
}

.chat-header {
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
}

.chat-header h1 {
    margin: 0;
    font-size: 1.5rem;
}

.chat-messages {
    list-style-type: none;
    margin: 0;
    padding: 1rem;
    flex-grow: 1;
    overflow-y: auto;
}

.chat-messages .message {
    padding: 0.5rem 0;
    word-wrap: break-word;
}

.chat-messages .username {
    font-weight: 700;
    color: var(--primary-color);
}

.chat-messages .admin-message .username {
    color: var(--secondary-color);
    text-shadow: 0 0 5px var(--secondary-color);
}

.chat-messages .status-message {
    color: var(--text-muted);
    font-style: italic;
    text-align: center;
    padding: 0.5rem 0;
}

.chat-form {
    display: flex;
    padding: 1rem;
    border-top: 1px solid var(--border-color);
}

.chat-form input {
    flex-grow: 1;
    background-color: var(--bg-color);
    border: 1px solid var(--border-color);
    color: var(--text-color);
    padding: 10px;
    border-radius: 5px;
    margin-right: 1rem;
}

.chat-form button {
    flex-shrink: 0;
}

.status-connected {
    color: var(--primary-color);
    font-weight: bold;
}

.status-disconnected {
    color: #ff4d4d; /* Red for disconnected */
    font-weight: bold;
}

.user-list-container {
    width: 100%; /* Full width on mobile */
    flex-shrink: 0;
    border-top: 1px solid var(--border-color); /* Separator on mobile */
    padding: 1rem;
    overflow-y: auto;
    box-sizing: border-box;
}

@media (min-width: 992px) {
    .user-list-container {
        width: 250px; /* Fixed width on desktop */
        border-top: none;
        border-left: 1px solid var(--border-color);
    }
}

.user-list-container h3 {
    margin-top: 0;
    margin-bottom: 1rem;
    font-size: 1.2rem;
    text-shadow: none;
}

#user-list {
    list-style-type: none;
    padding: 0;
    margin: 0;
}

#user-list li {
    padding: 0.25rem 0;
    color: var(--text-color);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Testimonials Page */
.testimonial-actions {
    margin-bottom: 2rem;
    text-align: center;
}


.testimonial-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.testimonial-card {
    background-color: var(--surface-color);
    border: 1px solid var(--border-color);
    padding: 1.5rem;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.testimonial-text {
    font-style: italic;
    margin-bottom: 1rem;
    flex-grow: 1;
}

.testimonial-author {
    font-weight: 700;
    text-align: right;
    color: var(--primary-color);
}

/* Hamburger Menu */
.hamburger {
    display: none; /* Hidden by default */
    cursor: pointer;
    background: none;
    border: none;
    padding: 0;
    z-index: 1001;
}

.hamburger span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: #fff;
    margin: 5px 0;
    transition: 0.4s;
}

/* Responsive Styles */
@media (max-width: 768px) {
    header .container {
        flex-wrap: wrap;
        justify-content: space-between;
    }

    .nav-links {
        display: none;
        position: absolute;
        top: 70px; /* Adjust based on header height */
        left: 0;
        background-color: var(--surface-color);
        width: 100%;
        padding: 1rem 0;
        border-top: 1px solid var(--border-color);
        z-index: 1000;
    }

    .nav-links.active {
        display: block;
    }

    .nav-links ul {
        flex-direction: column;
        width: 100%;
        gap: 0;
    }

    .nav-links ul li {
        text-align: center;
        padding: 10px 0;
        width: 100%;
    }
    
    .nav-links ul li a {
        display: block;
        padding: 0.5rem 0;
    }

    .hamburger {
        display: block; /* Show hamburger on small screens */
    }

    .auth-links {
        display: none; /* Hide auth links in the header on mobile */
    }
    
    /* You might want to move auth links into the hamburger menu as well */
    .nav-links.active .auth-links {
        display: flex;
        flex-direction: column;
        align-items: center;
        margin-top: 1rem;
    }
}



/* Tooltip Styles */
.tooltip-text {
    position: fixed; /* Use fixed position to append to body */
    background-color: var(--primary-color);
    color: var(--bg-color);
    font-family: var(--font-display);
    font-size: 0.9rem;
    padding: 8px 12px;
    border-radius: 5px;
    white-space: nowrap;
    z-index: 1001;
    text-shadow: none;
    box-shadow: 0 0 10px var(--primary-color);
    transition: opacity 0.2s ease-in-out;
    opacity: 1;
}
