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

/* Global Styles - Match Game Fantasy Dark Theme */
body {
    font-family: 'Roboto', sans-serif;
    background: #0a0a23 url('../images/bg.webp') no-repeat center center fixed;
    background-size: cover;
    color: #f0f0f0;
    line-height: 1.6;
}

h1, h2, h3, h4 {
    font-family: 'MedievalSharp', cursive;
    color: #ffd700; /* Gold accent matching game UI */
}

a {
    color: #87ceeb;
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: #ffd700;
}

/* Loading Animation */
.loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #0a0a23;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 0.5s ease;
}

.loader.hidden {
    opacity: 0;
    pointer-events: none;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 5px solid rgba(255, 215, 0, 0.3);
    border-top: 5px solid #ffd700;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Navigation Bar */
.navbar {
    background: rgba(10, 10, 35, 0.9);
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid #ffd700;
    position: sticky;
    top: 0;
    z-index: 100;
    transition: all 0.3s ease;
}

.navbar.scrolled {
    background: rgba(10, 10, 35, 0.95);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.logo {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.logo img {
    width: 60px;
    height: 60px;
    border-radius: 15px; /* Rounded icon corners */
}

.logo h1 {
    font-size: 1.8rem;
}

/* Hamburger Menu for Mobile */
.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: #ffd700;
    transition: all 0.3s ease;
}

.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

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

.nav-links a {
    font-size: 1.1rem;
    padding: 0.5rem 0;
    border-bottom: 2px solid transparent;
}

.nav-links a.active {
    border-bottom: 2px solid #ffd700;
    color: #ffd700;
}

.nav-links.open {
    display: flex !important;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(10, 10, 35, 0.95);
    padding: 1rem;
    border-bottom: 2px solid #ffd700;
    gap: 1rem;
}

/* Hero Section */
.hero {
    height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 2rem;
    background: rgba(10, 10, 35, 0.7);
}

.hero-content {
    max-width: 800px;
}

.hero h2 {
    font-size: 3rem;
    margin-bottom: 1.5rem;
    text-shadow: 2px 2px 4px #000;
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    text-shadow: 1px 1px 2px #000;
}

.rating {
    display: inline-block;
    background: rgba(255, 215, 0, 0.2);
    border: 1px solid #ffd700;
    padding: 0.25rem 0.75rem;
    border-radius: 8px;
    font-weight: bold;
    margin-right: 1rem;
    margin-bottom: 1rem;
}

/* App Store Download Button */
.app-store-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    background: #000;
    color: #fff;
    padding: 0.5rem 1rem;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.app-store-btn:hover {
    background: #222;
    color: #fff;
    transform: translateY(-2px);
}

.app-store-text {
    display: flex;
    flex-direction: column;
    text-align: left;
}

.app-store-text .small {
    font-size: 0.75rem;
    line-height: 1;
}

.app-store-text .big {
    font-size: 1.2rem;
    font-weight: bold;
    line-height: 1;
}

/* Game Features */
.features {
    padding: 4rem 2rem;
    background: rgba(10, 10, 35, 0.8);
}

.features h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
}

.feature-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.card {
    background: rgba(20, 20, 50, 0.9);
    border-radius: 10px;
    padding: 1.5rem;
    border: 1px solid #ffd700;
    text-align: center;
    transition: transform 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
}

.card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 1rem;
    border: 2px solid #ffd700;
}

/* Changelog */
.changelog {
    padding: 4rem 2rem;
    background: rgba(10, 10, 35, 0.8);
}

.changelog h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 2rem;
}

.changelog-card {
    background: rgba(20, 20, 50, 0.9);
    border-radius: 10px;
    padding: 2rem;
    border: 1px solid #ffd700;
    max-width: 800px;
    margin: 0 auto;
}

.changelog-card h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.changelog-card ul {
    margin-left: 2rem;
    margin-top: 1rem;
}

/* Support Page */
.support-section {
    padding: 4rem 2rem;
    background: rgba(10, 10, 35, 0.8);
}

.support-container {
    max-width: 1000px;
    margin: 0 auto;
}

.support-section h2 {
    font-size: 2.5rem;
    margin-bottom: 2rem;
    text-align: center;
}

.support-card {
    background: rgba(20, 20, 50, 0.9);
    border-radius: 10px;
    padding: 2rem;
    margin-bottom: 2rem;
    border: 1px solid #ffd700;
}

.support-card h3 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    color: #ffd700;
}

.support-card h4 {
    font-size: 1.2rem;
    margin: 1rem 0 0.5rem;
    color: #87ceeb;
}

.support-card ul, .support-card ol {
    margin-left: 2rem;
    margin-bottom: 1rem;
}

.contact-list {
    list-style: none;
    margin-left: 0 !important;
}

/* Support Form */
.support-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-weight: bold;
}

.form-group input, .form-group select, .form-group textarea {
    padding: 0.75rem;
    border-radius: 8px;
    border: 1px solid #ffd700;
    background: rgba(10, 10, 35, 0.8);
    color: #f0f0f0;
    font-size: 1rem;
}

.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
    outline: none;
    border-color: #87ceeb;
    box-shadow: 0 0 5px rgba(135, 206, 235, 0.5);
}

.submit-btn {
    background: #ffd700;
    color: #0a0a23;
    padding: 1rem;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
}

.submit-btn:hover {
    background: #e6c800;
    transform: translateY(-2px);
}

/* Privacy Page */
.privacy-section {
    padding: 4rem 2rem;
    background: rgba(10, 10, 35, 0.8);
}

.privacy-container {
    max-width: 1000px;
    margin: 0 auto;
}

.privacy-section h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    text-align: center;
}

.update-date {
    text-align: center;
    margin-bottom: 2rem;
    color: #ccc;
}

.privacy-card {
    background: rgba(20, 20, 50, 0.9);
    border-radius: 10px;
    padding: 2rem;
    margin-bottom: 2rem;
    border: 1px solid #ffd700;
}

.privacy-card h3 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    color: #ffd700;
}

.privacy-card h4 {
    font-size: 1.2rem;
    margin: 1rem 0 0.5rem;
    color: #87ceeb;
}

.privacy-card ul, .privacy-card ol {
    margin-left: 2rem;
    margin-bottom: 1rem;
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: #ffd700;
    color: #0a0a23;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    font-size: 1.5rem;
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 99;
    transition: all 0.3s ease;
}

.back-to-top:hover {
    background: #e6c800;
    transform: translateY(-3px);
}

/* Footer */
footer {
    background: rgba(10, 10, 35, 0.9);
    padding: 2rem;
    text-align: center;
    border-top: 2px solid #ffd700;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    .nav-links {
        display: none;
    }

    .navbar {
        flex-direction: row;
    }

    .hero h2 {
        font-size: 2rem;
    }

    .hero p {
        font-size: 1rem;
    }

    .features h2, .support-section h2, .privacy-section h2, .changelog h2 {
        font-size: 2rem;
    }
}

@media (max-width: 480px) {
    .logo h1 {
        font-size: 1.5rem;
    }

    .logo img {
        width: 45px;
        height: 45px;
    }

    .hero {
        height: auto;
        padding: 2rem 1rem;
    }

    .features, .support-section, .privacy-section, .changelog {
        padding: 2rem 1rem;
    }

    .support-card, .privacy-card {
        padding: 1.5rem;
    }
}