/* Base Theme Colors */
:root {
    --pink-primary: #FFB6C1; /* Light pink (Elysia-like) */
    --pink-secondary: #FF85A1; /* Slightly deeper pink */
    --pink-accent: #C71585; /* Darker pink/magenta */
    --dark-bg: #1A1A1D;
    --dark-secondary: #2C2C2E;
    --dark-accent: #3A3A3D;
    --text-light: #FFFFFF;
    --text-pink: #FFB6C1;
    --red-accent: #C41E3A;
    --green-accent: #00A36C;
}

/* Global Styles */
body {
    background-color: var(--dark-bg);
    color: var(--text-light);
    font-family: 'Poppins', sans-serif;
    margin: 0;
    padding: 0;
    min-height: 100vh;
}

/* Preloader */
#preloader {
    position: fixed;
    width: 100%;
    height: 100%;
    background: var(--dark-bg);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

/* Fade-out Animation */
@keyframes fadeOut {
    from {
        opacity: 1;
        visibility: visible;
    }
    to {
        opacity: 0;
        visibility: hidden;
    }
}

/* Apply fade-out animation */
#preloader.fade-out {
    animation: fadeOut 0.5s ease forwards;
}

/* Spinner Styles */
.spinner {
    border: 4px solid var(--text-muted);
    border-top: 4px solid var(--pink-primary);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

/* Spinner Animation */
@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}
.fallback-loader {
    border: 4px solid var(--dark-accent);
    border-top: 4px solid var(--pink-primary);
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
}

/* Navigation */
.dynamic-island-horizontal {
    background: var(--dark-secondary);
    border-radius: 25px;
    margin: 20px auto;
    padding: 10px;
    width: 90%;
    max-width: 600px;
    box-shadow: 0 8px 32px rgba(255, 182, 193, 0.15); /* Adjusted shadow to pink */
}

.navbar {
    padding: 0;
}

.nav-links {
    display: flex;
    justify-content: space-around;
    width: 100%;
    margin: 0;
    padding: 0;
    list-style: none;
}

.nav-item {
    position: relative;
}

.nav-link {
    color: var(--text-light);
    font-size: 1.2em;
    padding: 10px 20px;
    transition: all 0.3s ease;
}

.nav-link:hover {
    color: var(--pink-primary);
    text-shadow: 0 0 10px var(--pink-secondary);
}

.nav-item.active .nav-link {
    color: var(--pink-primary);
}

/* Content Sections */
.content {
    padding: 20px;
}

.tutorial-section {
    background: var(--dark-secondary);
    border-radius: 15px;
    margin: 20px auto;
    padding: 30px;
    max-width: 800px;
    box-shadow: 0 4px 20px rgba(255, 182, 193, 0.1); /* Adjusted shadow to pink */
}

.section-title {
    color: var(--pink-primary);
    font-size: 2.5em;
    text-align: center;
    margin-bottom: 30px;
    text-shadow: 0 0 10px rgba(255, 182, 193, 0.3); /* Adjusted shadow to pink */
}

/* Instructions */
.instructions {
    list-style: none;
    padding: 0;
}

.instructions li {
    margin-bottom: 25px;
    padding: 20px;
    background: var(--dark-accent);
    border-radius: 10px;
    border-left: 4px solid var(--pink-primary);
}

.instructions strong {
    color: var(--pink-secondary);
}

/* Buttons */
.btn-primary {
    background-color: var(--pink-primary);
    border: none;
    color: var(--dark-bg);
    padding: 8px 16px;
    margin: 5px;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    background-color: var(--pink-secondary);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(255, 182, 193, 0.3); /* Adjusted shadow to pink */
}

/* Images - Updated for smaller size */
.image-container {
    margin: 15px auto;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    max-width: 300px; /* Reduced from full width */
}

.tutorial-image {
    width: 100%;
    height: auto;
    border-radius: 8px;
    transition: transform 0.3s ease;
    display: block; /* Ensures no extra space */
    object-fit: contain; /* Maintains aspect ratio */
    max-height: 400px; /* Maximum height limit */
}

.tutorial-image:hover {
    transform: scale(1.02);
}

/* Copy URL Box */
pre#url {
    background: var(--dark-accent);
    color: var(--pink-secondary);
    padding: 15px;
    border-radius: 8px;
    border: 1px solid var(--pink-primary);
    cursor: pointer;
    transition: all 0.3s ease;
    overflow-x: auto;
}

pre#url:hover {
    background: var(--dark-secondary);
    border-color: var(--pink-secondary);
    box-shadow: 0 0 15px rgba(255, 182, 193, 0.2); /* Adjusted shadow to pink */
}

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

/* Responsive Design */
@media (max-width: 768px) {
    .dynamic-island-horizontal {
        width: 95%;
        margin: 10px auto;
    }

    .section-title {
        font-size: 2em;
    }

    .nav-link {
        padding: 8px 15px;
        font-size: 1em;
    }

    .image-container {
        max-width: 250px; /* Even smaller on mobile */
    }

    .tutorial-image {
        max-height: 300px; /* Smaller height on mobile */
    }
}

/* Sweet Alert Customization */
.swal2-popup {
    background: var(--dark-secondary) !important;
    border: 1px solid var(--pink-primary) !important;
}

.swal2-title {
    color: var(--pink-primary) !important;
}

.swal2-content {
    color: var(--text-light) !important;
}

/* Additional Casino/Poker Elements */
.instructions li::before {
    font-family: "Font Awesome 5 Free";
    margin-right: 10px;
    color: var(--pink-primary);
}

.tutorial-section::after {
    content: "♠ ♥ ♣ ♦";
    display: block;
    text-align: center;
    color: var(--pink-primary);
    font-size: 1.5em;
    margin-top: 20px;
    letter-spacing: 10px;
    opacity: 0.5;
}

/* Hover Effects */
.nav-item::after {
    content: "";
    position: absolute;
    bottom: -5px;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--pink-primary);
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-item:hover::after {
    width: 80%;
}