/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #0a0a0a 0%, #1a1a1a 100%);
    color: #ffffff;
    line-height: 1.6;
    overflow-x: hidden;
}

/* Loading Screen */
#loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #000000 0%, #1a0000 50%, #000000 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease-out;
}

.loading-content {
    text-align: center;
}

.loading-logo h1 {
    font-size: 3rem;
    color: #ff0000;
    margin-bottom: 2rem;
    text-shadow: 0 0 20px rgba(255, 0, 0, 0.5);
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 3px solid rgba(255, 255, 255, 0.1);
    border-top: 3px solid #ff0000;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 2rem;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-content p {
    color: #cccccc;
    font-size: 1.2rem;
}

/* Navigation */
.navbar {
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    padding: 1rem 0;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    border-bottom: 2px solid #ff0000;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-brand h2 {
    color: #ff0000;
    font-size: 1.8rem;
    text-shadow: 0 0 10px rgba(255, 0, 0, 0.3);
}

.nav-links {
    display: flex;
    gap: 2rem;
}

.nav-link {
    color: #ffffff;
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.nav-link:hover,
.nav-link.active {
    color: #ff0000;
    background: rgba(255, 0, 0, 0.1);
}

/* Main Content */
#main-content {
    margin-top: 80px;
    min-height: calc(100vh - 80px);
}

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

/* Page System */
.page {
    display: none;
}

.page.active {
    display: block;
}

/* Hero Section */
.hero {
    text-align: center;
    padding: 4rem 0;
    background: linear-gradient(135deg, rgba(255, 0, 0, 0.1) 0%, rgba(0, 0, 0, 0.5) 100%);
    border-radius: 15px;
    margin-bottom: 3rem;
}

.hero h1 {
    font-size: 3.5rem;
    color: #ff0000;
    margin-bottom: 1rem;
    text-shadow: 0 0 20px rgba(255, 0, 0, 0.5);
}

.hero p {
    font-size: 1.3rem;
    color: #cccccc;
    margin-bottom: 2rem;
}

/* Social Buttons */
.social-buttons {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 2rem;
}

.social-btn {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 1rem 2rem;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.discord-btn {
    background: linear-gradient(135deg, #5865F2 0%, #4752C4 100%);
    color: #ffffff;
    box-shadow: 0 4px 15px rgba(88, 101, 242, 0.3);
}

.discord-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(88, 101, 242, 0.5);
    border-color: rgba(88, 101, 242, 0.5);
}

.youtube-btn {
    background: linear-gradient(135deg, #FF0000 0%, #CC0000 100%);
    color: #ffffff;
    box-shadow: 0 4px 15px rgba(255, 0, 0, 0.3);
}

.youtube-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(255, 0, 0, 0.5);
    border-color: rgba(255, 0, 0, 0.5);
}

.social-btn i {
    font-size: 1.3rem;
}

/* Hidden Admin Access */
.hidden-admin-access {
    position: fixed;
    bottom: 20px;
    left: 20px;
    width: 30px;
    height: 30px;
    background: rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 50%;
    color: rgba(255, 255, 255, 0.1);
    cursor: pointer;
    font-size: 0.8rem;
    transition: all 0.3s ease;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hidden-admin-access:hover {
    background: rgba(255, 0, 0, 0.1);
    color: rgba(255, 0, 0, 0.3);
    border-color: rgba(255, 0, 0, 0.1);
}

/* Search and Filter */
.search-filter-section {
    display: flex;
    gap: 2rem;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.search-container {
    flex: 1;
    position: relative;
    min-width: 300px;
}

.search-icon {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #888;
}

.search-input {
    width: 100%;
    padding: 15px 15px 15px 45px;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    color: #ffffff;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.search-input:focus {
    outline: none;
    border-color: #ff0000;
    background: rgba(255, 255, 255, 0.15);
}

.search-input::placeholder {
    color: #888;
}

.filter-container {
    min-width: 200px;
}

.filter-select {
    width: 100%;
    padding: 15px;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    color: #ffffff;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-select:focus {
    outline: none;
    border-color: #ff0000;
}

.filter-select option {
    background: #1a1a1a;
    color: #ffffff;
}

/* Scripts Grid */
.scripts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.script-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.05) 100%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    padding: 2rem;
    transition: all 0.3s ease;
    cursor: pointer;
    overflow: hidden;
    position: relative;
}

.script-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #ff0000, #cc0000);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.script-card:hover::before {
    transform: scaleX(1);
}

.script-card:hover {
    transform: translateY(-5px);
    background: linear-gradient(135deg, rgba(255, 0, 0, 0.1) 0%, rgba(255, 255, 255, 0.1) 100%);
    border-color: rgba(255, 0, 0, 0.3);
}

.script-card h3 {
    color: #ff0000;
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.script-card p {
    color: #cccccc;
    margin-bottom: 1.5rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.script-card .script-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #888;
    font-size: 0.9rem;
}

/* Script Detail Page */
.back-button {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #ffffff;
    padding: 1rem 2rem;
    border-radius: 10px;
    cursor: pointer;
    margin-bottom: 2rem;
    transition: all 0.3s ease;
    font-size: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.back-button:hover {
    background: rgba(255, 0, 0, 0.1);
    border-color: #ff0000;
}

.script-detail {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.05) 100%);
    border-radius: 15px;
    padding: 3rem;
    margin-bottom: 2rem;
}

.script-detail h1 {
    color: #ff0000;
    font-size: 2.5rem;
    margin-bottom: 1rem;
    text-shadow: 0 0 10px rgba(255, 0, 0, 0.3);
}

.script-detail .description {
    color: #cccccc;
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 2rem;
}

/* Image Gallery */
.image-gallery-container {
    margin: 2rem 0;
}

.image-gallery-container h3 {
    color: #ff0000;
    margin-bottom: 1rem;
}

.image-thumbnails {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 2rem;
}

.image-thumbnail {
    width: 150px;
    height: 100px;
    object-fit: cover;
    border-radius: 10px;
    cursor: pointer;
    border: 2px solid transparent;
    transition: all 0.3s ease;
}

.image-thumbnail:hover {
    border-color: #ff0000;
    transform: scale(1.05);
}

/* Video Section */
.video-section {
    margin: 2rem 0;
}

.video-section h3 {
    color: #ff0000;
    margin-bottom: 1rem;
}

.video-embed {
    width: 100%;
    height: 400px;
    border-radius: 15px;
    margin-bottom: 1rem;
}

/* Get Script Button */
.get-script-button {
    background: linear-gradient(135deg, #ff0000 0%, #cc0000 100%);
    color: #ffffff;
    border: none;
    padding: 1.5rem 3rem;
    font-size: 1.3rem;
    font-weight: bold;
    border-radius: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 5px 15px rgba(255, 0, 0, 0.3);
    display: block;
    margin: 3rem auto 0;
    text-decoration: none;
    text-align: center;
    width: fit-content;
}

.get-script-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(255, 0, 0, 0.5);
    background: linear-gradient(135deg, #ff3333 0%, #ff0000 100%);
}

/* Admin Section */
.login-container {
    max-width: 400px;
    margin: 5rem auto;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.05) 100%);
    padding: 3rem;
    border-radius: 15px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.login-container h2 {
    color: #ff0000;
    text-align: center;
    margin-bottom: 2rem;
}

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

.login-form input {
    width: 100%;
    padding: 15px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    color: #ffffff;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.login-form input:focus {
    outline: none;
    border-color: #ff0000;
    background: rgba(255, 255, 255, 0.15);
}

.login-form input::placeholder {
    color: #888;
}

/* Admin Dashboard */
.admin-section {
    display: none;
}

.admin-section.active {
    display: block;
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 3rem;
    padding-bottom: 2rem;
    border-bottom: 2px solid rgba(255, 0, 0, 0.3);
}

.dashboard-header h2 {
    color: #ff0000;
    font-size: 2.5rem;
}

.dashboard-content {
    display: grid;
    gap: 3rem;
}

.dashboard-section {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.05) 100%);
    padding: 2rem;
    border-radius: 15px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.dashboard-section h3 {
    color: #ff0000;
    font-size: 1.8rem;
    margin-bottom: 2rem;
}

/* Script Form */
.script-form .form-group {
    margin-bottom: 1.5rem;
}

.script-form label {
    display: block;
    color: #cccccc;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.script-form input,
.script-form textarea {
    width: 100%;
    padding: 15px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    color: #ffffff;
    font-size: 1rem;
    font-family: inherit;
    transition: all 0.3s ease;
    resize: vertical;
}

.script-form input:focus,
.script-form textarea:focus {
    outline: none;
    border-color: #ff0000;
    background: rgba(255, 255, 255, 0.15);
}

.script-form input::placeholder,
.script-form textarea::placeholder {
    color: #888;
}

/* Admin Scripts List */
.admin-scripts-list {
    display: grid;
    gap: 1rem;
}

.admin-script-item {
    background: rgba(255, 255, 255, 0.05);
    padding: 1.5rem;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.admin-script-info h4 {
    color: #ff0000;
    margin-bottom: 0.5rem;
}

.admin-script-info p {
    color: #cccccc;
    font-size: 0.9rem;
}

.admin-script-actions {
    display: flex;
    gap: 1rem;
}

/* Buttons */
.btn-primary {
    background: linear-gradient(135deg, #ff0000 0%, #cc0000 100%);
    color: #ffffff;
    border: none;
    padding: 1rem 2rem;
    border-radius: 10px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 0, 0, 0.3);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 0.8rem 1.5rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    background: rgba(255, 0, 0, 0.1);
    border-color: #ff0000;
}

.btn-danger {
    background: linear-gradient(135deg, #cc0000 0%, #990000 100%);
    color: #ffffff;
    border: none;
    padding: 0.8rem 1.5rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.btn-danger:hover {
    background: linear-gradient(135deg, #ff0000 0%, #cc0000 100%);
    transform: translateY(-1px);
}

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

.modal.active {
    display: flex;
    justify-content: center;
    align-items: center;
}

.modal-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
}

.modal-close {
    position: absolute;
    top: -40px;
    right: 0;
    color: #ffffff;
    font-size: 2rem;
    cursor: pointer;
    z-index: 2001;
}

.modal-close:hover {
    color: #ff0000;
}

.image-gallery {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

#gallery-image {
    max-width: 100%;
    max-height: 80vh;
    border-radius: 10px;
}

.gallery-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.7);
    color: #ffffff;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.gallery-nav:hover {
    background: rgba(255, 0, 0, 0.8);
}

.prev-btn {
    left: -60px;
}

.next-btn {
    right: -60px;
}

.gallery-indicators {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 1rem;
}

.gallery-indicator {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
}

.gallery-indicator.active,
.gallery-indicator:hover {
    background: #ff0000;
}

/* Error Messages */
.error-message {
    color: #ff4444;
    background: rgba(255, 68, 68, 0.1);
    padding: 1rem;
    border-radius: 8px;
    border: 1px solid rgba(255, 68, 68, 0.3);
    margin-top: 1rem;
    display: none;
}

.error-message.show {
    display: block;
}

/* Success Messages */
.success-message {
    color: #44ff44;
    background: rgba(68, 255, 68, 0.1);
    padding: 1rem;
    border-radius: 8px;
    border: 1px solid rgba(68, 255, 68, 0.3);
    margin-top: 1rem;
    display: none;
}

.success-message.show {
    display: block;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 1rem;
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .social-buttons {
        flex-direction: column;
        gap: 1rem;
        align-items: center;
    }
    
    .social-btn {
        width: 200px;
        justify-content: center;
    }
    
    .search-filter-section {
        flex-direction: column;
        gap: 1rem;
    }
    
    .search-container,
    .filter-container {
        min-width: auto;
    }
    
    .scripts-grid {
        grid-template-columns: 1fr;
    }
    
    .script-detail {
        padding: 2rem;
    }
    
    .script-detail h1 {
        font-size: 2rem;
    }
    
    .nav-container {
        padding: 0 1rem;
    }
    
    .nav-links {
        gap: 1rem;
    }
    
    .dashboard-header {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
    
    .admin-script-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .prev-btn {
        left: -30px;
    }
    
    .next-btn {
        right: -30px;
    }
    
    .video-embed {
        height: 250px;
    }
}

@media (max-width: 480px) {
    .hero h1 {
        font-size: 2rem;
    }
    
    .hero p {
        font-size: 1.1rem;
    }
    
    .script-card {
        padding: 1.5rem;
    }
    
    .script-detail {
        padding: 1.5rem;
    }
    
    .login-container {
        padding: 2rem;
        margin: 3rem auto;
    }
    
    .dashboard-section {
        padding: 1.5rem;
    }
    
    .get-script-button {
        padding: 1rem 2rem;
        font-size: 1.1rem;
    }
    
    .prev-btn,
    .next-btn {
        display: none;
    }
    
    .video-embed {
        height: 200px;
    }
}