/* Import better font */
@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap");

/* Custom font faces */
@font-face {
    font-family: "RaelaGrotesque";
    src: url("fonts/RaelaGrotesque-Regular.ttf") format("truetype");
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "JazzyRabbit";
    src: url("fonts/JazzyRabbit.ttf") format("truetype");
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

/* CSS Variables for Light/Dark Mode */
:root {
    /* Default to light mode */
    --bg-dark: hsl(0 0% 90%);
    --bg: hsl(0 0% 95%);
    --bg-light: hsl(0 0% 100%);
    --text: hsl(275 100% 7%);
    --text-muted: hsl(273, 63%, 25%);
    --highlight: hsl(271 100% 100%);
    --border: hsl(272 25% 56%);
    --border-muted: hsl(271 36% 68%);
    --primary: hsl(271 54% 76%);
    --secondary: hsl(81 84% 17%);
    --danger: hsl(8 36% 41%);
    --warning: hsl(52 58% 28%);
    --success: hsl(152 45% 31%);
    --info: hsl(217 38% 43%);
}

/* Dark mode */
[data-theme="dark"] {
        --bg-dark: hsl(266 93% 3%);
        --bg: hsl(273 65% 6%);
        --bg-light: hsl(273 41% 10%);
        --text: hsl(271 100% 100%);
        --text-muted: hsl(271 47% 75%);
        --highlight: hsl(272 24% 44%);
        --border: hsl(273 31% 32%);
        --border-muted: hsl(274 45% 22%);
        --primary: hsl(273, 81%, 24%);
        --secondary: hsl(87 35% 61%);
        --danger: hsl(9 47% 65%);
        --warning: hsl(51 32% 52%);
        --success: hsl(149 31% 55%);
        --info: hsl(217 52% 67%);
}


/* Simple, Clean Design */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Inter", "Roboto", "Helvetica Neue", Arial, sans-serif;
    background: var(--bg-dark);
    color: var(--text);
    line-height: 1.6;
    font-size: 18px;
    transition:
        background-color 0.3s ease,
        color 0.3s ease;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Simple Navigation */
.navbar {
    background: var(--bg);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
    height: 70px;
    display: flex;
    align-items: center;
    border-bottom: 1px solid var(--border);
    transition: background-color 0.3s ease;
}

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

.logo {
    color: var(--text);
    text-decoration: none;
    font-size: 1.4rem !important;
    font-weight: 600 !important;
    display: flex;
    align-items: center;
    font-family:
        "Inter", "Roboto", "Helvetica Neue", Arial, sans-serif !important;
}

.logo img {
    width: 28px;
    height: 28px;
    margin-right: 0.5rem;
}

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

.nav-links a {
    color: var(--text-muted);
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: all 0.3s ease;
    font-family: "Inter", "Roboto", "Helvetica Neue", Arial, sans-serif;
    font-size: 1rem;
    font-weight: 500;
}

.nav-links a:hover,
.nav-links a.active {
    background: var(--border);
    color: var(--text);
}

/* Force consistent navbar text sizing */
.navbar * {
    font-family:
        "Inter", "Roboto", "Helvetica Neue", Arial, sans-serif !important;
}

.navbar .nav-links a {
    font-size: 1rem !important;
    font-weight: 500 !important;
}

.navbar .logo {
    font-size: 1.4rem !important;
    font-weight: 600 !important;
}

/* Improved Mobile Menu */
.mobile-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 6px;
    transition: background-color 0.3s ease;
}

.mobile-toggle:hover {
    background: var(--border);
}

.hamburger {
    width: 24px;
    height: 3px;
    background: var(--text);
    margin: 2px 0;
    transition: all 0.3s ease;
    border-radius: 2px;
}

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

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

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

/* Content */
.main-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
    flex-grow: 1;
}

h1 {
    font-size: 2.8rem;
    text-align: center;
    margin: 2rem 0;
    color: var(--text);
    font-weight: 600;
    font-family: "Inter", "Roboto", "Helvetica Neue", Arial, sans-serif;
}

h2 {
    font-size: 2.2rem;
    text-align: center;
    margin: 1.5rem 0 1rem 0;
    color: var(--text);
    font-weight: 600;
    font-family: "Inter", "Roboto", "Helvetica Neue", Arial, sans-serif;
}

p {
    font-size: 1.8rem;
    margin: 1rem 0;
    color: var(--text);
    text-align: center;
    line-height: 1.7;
    font-family: "Inter", "Roboto", "Helvetica Neue", Arial, sans-serif;
}

.btn {
    display: inline-block;
    align-self: center;
    background: var(--primary);
    color: var(--text);
    padding: 1rem 2rem;
    text-decoration: none;
    border-radius: 6px;
    margin: 0.5rem;
    transition: all 0.3s ease;
    font-size: 1.1rem;
    font-weight: 500;
    font-family: "Inter", "Roboto", "Helvetica Neue", Arial, sans-serif;
}

.btn:hover {
    background: var(--bg-light);
}

.btnsec {
    display: inline-block;
    align-self: center;
    background: var(--secondary);
    color: var(--text);
    padding: 1rem 2rem;
    text-decoration: none;
    border-radius: 6px;
    margin: 0.5rem;
    transition: all 0.3s ease;
    font-size: 1.1rem;
    font-weight: 500;
    font-family: "Inter", "Roboto", "Helvetica Neue", Arial, sans-serif;
}

.btnsec:hover {
    background: var(--bg-light);
}
.card {
    background: var(--bg);
    padding: 2rem;
    margin: 2rem 0;
    border-radius: 8px;
    border: 1px solid var(--border);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Center buttons inside cards */
.card .btn,
.card .btnsec,
.card a.btn,
.card a.btnsec {
    display: block;
    margin: 0.5rem auto;
    text-align: center;
}

/* Spotify Embed */
#spotify-embed {
    margin: 2rem auto;
    max-width: 500px;
    text-align: center;
}

#spotify-embed iframe {
    width: 100%;
    height: 352px;
    border-radius: 8px;
}
/* Dropdown */
.dropdown {
    position: relative;
}

.dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 6px;
    min-width: 180px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    overflow: hidden;
}

.dropdown:hover .dropdown-menu {
    display: block;
}

.dropdown-menu a {
    display: block;
    padding: 0.75rem 1rem;
    color: var(--text-muted);
    border-bottom: 1px solid var(--border);
    transition: all 0.3s ease;
}

.dropdown-menu a:last-child {
    border-bottom: none;
}

.dropdown-menu a:hover {
    background: var(--border);
    color: var(--text);
}

/* Lists */
ul {
    list-style: none;
    padding: 0;
}

ul li {
    padding: 0.5rem 0;
    color: var(--text-muted);
    font-family: "Inter", "Roboto", "Helvetica Neue", Arial, sans-serif;
}

/* Links */
a {
    color: #6366f1;
    text-decoration: none;
}

a:hover {
    color: #4f46e5;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .mobile-toggle {
        display: flex;
    }

    .theme-toggle {
        display: block;
        position: fixed;
        top: 15px;
        right: 60px;
        z-index: 1001;
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }

    .nav-links {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        width: 100%;
        height: 100vh;
        background: var(--bg);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 2rem;
        z-index: 9999;
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
        padding: 2rem 1rem 6rem 1rem; /* add bottom padding for comfortable scroll */
        text-align: center;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    .nav-links.active {
        display: flex;
        opacity: 1;
        visibility: visible;
        height: 100vh;
        bottom: 0;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    .nav-links a {
        font-size: 1.4rem !important;
        padding: 1.2rem 2.5rem;
        background: var(--bg);
        border: 1px solid var(--border);
        border-radius: 12px;
        width: 100%;
        max-width: 300px;
        text-align: center;
        transition: all 0.3s ease;
        display: block;
        font-weight: 500 !important;
    }

    .nav-links a:hover {
        transform: translateY(-3px);
        box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
        background: var(--primary);
        color: white;
    }

    .dropdown-menu {
        position: static;
        display: block;
        background: transparent;
        box-shadow: none;
        border: none;
        margin-top: 1rem;
        width: 100%;
    }

    .dropdown-menu a {
        background: var(--bg) !important;
        margin: 0.8rem 0;
        border-radius: 8px;
        width: 100%;
        max-width: 280px;
        font-size: 1.2rem !important;
    }

    .dropdown-menu a:hover {
        background: var(--primary) !important;
    }

    .main-content {
        padding: 1.5rem;
        text-align: center !important;
    }

    .main-content * {
        text-align: center !important;
    }

    .card {
        text-align: center !important;
        margin: 1rem auto;
    }

    .card * {
        text-align: center !important;
    }

    .card h2 {
        text-align: center !important;
        display: block !important;
        width: 100% !important;
        margin: 1rem auto !important;
    }

    .card ul {
        text-align: left !important;
        max-width: 280px;
        margin: 1rem auto !important;
        display: inline-block;
    }

    .card .btn {
        display: block !important;
        margin: 1rem auto !important;
        text-align: center !important;
        width: fit-content;
    }

    h1 {
        font-size: 2.4rem !important;
        text-align: center !important;
        margin: 1rem auto !important;
    }

    h2 {
        font-size: 2rem !important;
        text-align: center !important;
        margin: 1rem auto !important;
        display: block !important;
        width: 100% !important;
    }

    p {
        font-size: 1.6rem !important;
        text-align: center !important;
        margin: 1rem auto !important;
    }

    /* Force center all buttons on mobile */
    .btn {
        display: block !important;
        margin: 1rem auto !important;
        text-align: center !important;
        width: fit-content !important;
    }

    .card .btn {
        display: block !important;
        margin: 1rem auto !important;
        text-align: center !important;
        width: fit-content !important;
    }

    .main-content .btn {
        display: block !important;
        margin: 1rem auto !important;
        text-align: center !important;
        width: fit-content !important;
    }

    /* Hamburger menu improvements */
    .hamburger {
        width: 25px;
        height: 3px;
        background: var(--text);
        margin: 4px 0;
        transition: 0.3s;
        border-radius: 2px;
    }

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

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

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

    /* FORCE CENTER EVERYTHING ON MOBILE */
    * {
        text-align: center !important;
    }

    h1,
    h2,
    h3,
    h4,
    h5,
    h6 {
        text-align: center !important;
        display: block !important;
        width: 100% !important;
        margin-left: auto !important;
        margin-right: auto !important;
    }

    .btn,
    a.btn,
    button {
        display: block !important;
        margin: 1rem auto !important;
        text-align: center !important;
        width: fit-content !important;
        margin-left: auto !important;
        margin-right: auto !important;
    }

    .card {
        text-align: center !important;
    }

    .card * {
        text-align: center !important;
    }

    .card h2 {
        text-align: center !important;
        display: block !important;
        width: 100% !important;
    }

    .card .btn {
        display: block !important;
        margin: 1rem auto !important;
        text-align: center !important;
        width: fit-content !important;
    }

    .main-content {
        text-align: center !important;
    }

    .main-content * {
        text-align: center !important;
    }

    .main-content h2 {
        text-align: center !important;
        display: block !important;
        width: 100% !important;
    }

    .main-content .btn {
        display: block !important;
        margin: 1rem auto !important;
        text-align: center !important;
        width: fit-content !important;
    }
}

/* --- Accessible burger + unified theme toggle styles (appended) --- */
.site-nav {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
}
.site-nav .nav-content {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}
.burger {
    background: transparent;
    border: 0;
    padding: 8px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--text);
}
.burger-box {
    width: 30px;
    height: 20px;
    display: inline-block;
    position: relative;
}
.burger-inner,
.burger-inner::before,
.burger-inner::after {
    width: 100%;
    height: 2px;
    background: currentColor;
    display: block;
    position: absolute;
    left: 0;
    transition:
        transform 0.28s ease,
        opacity 0.2s ease;
}
.burger-inner {
    top: 50%;
    transform: translateY(-50%);
}
.burger-inner::before {
    content: "";
    top: -8px;
}
.burger-inner::after {
    content: "";
    top: 8px;
}
.burger[aria-expanded="true"] .burger-inner {
    transform: rotate(45deg);
}
.burger[aria-expanded="true"] .burger-inner::before {
    transform: rotate(-90deg) translateX(-6px);
    top: 0;
}
.burger[aria-expanded="true"] .burger-inner::after {
    opacity: 0;
    transform: translateX(20px);
}

.nav-menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    transform-origin: top;
    transition:
        transform 0.28s ease,
        opacity 0.2s ease;
    padding: 12px 16px;
    border-radius: 8px;
    z-index: 999;
}
.nav-menu[hidden] {
    opacity: 0;
    transform: scaleY(0.98);
    pointer-events: none;
    height: 0;
    overflow: hidden;
}
.nav-menu:not([hidden]) {
    opacity: 1;
    transform: scaleY(1);
    pointer-events: auto;
}

.nav-menu .nav-links {
    display: flex;
    gap: 12px;
    align-items: center;
}
.nav-menu .nav-links a {
    display: block;
}

@media (min-width: 720px) {
    .nav-menu {
        position: static;
        display: flex;
        gap: 12px;
        background: transparent;
        box-shadow: none;
        transform: none;
        opacity: 1;
        height: auto;
        padding: 0;
    }
    /* If menu has the hidden attribute, ensure desktop still shows it */
    .nav-menu[hidden] {
        opacity: 1 !important;
        transform: none !important;
        height: auto !important;
        pointer-events: auto !important;
        visibility: visible !important;
    }
    #nav-toggle {
        display: none;
    }
}

@media (max-width: 768px) {
    .nav-menu {
        position: static;
        background: transparent;
        box-shadow: none;
        padding: 0;
        border-radius: 0;
        transform: none !important;
    }
    .nav-menu[hidden] {
        height: auto;
    }
    .navbar {
        overflow: visible !important;
    }
}

/* ensure the existing mobile-toggle/hamburger don't conflict if present */
.mobile-toggle {
    display: none !important;
}

/* --- Upload/Download Card Styles --- */
.upload-card {
    max-width: 500px;
    margin: 3rem auto;
    transition: all 0.3s ease;
}

.input-group {
    margin: 1.5rem 0;
    opacity: 1;
    max-height: 200px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.input-group.hidden {
    opacity: 0;
    max-height: 0;
    margin: 0;
}

.input-group label {
    display: block;
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
    font-weight: 500;
}

.input-group select {
    width: 100%;
    padding: 0.8rem;
    font-size: 1rem;
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    cursor: pointer;
    font-family: "Inter", "Roboto", "Helvetica Neue", Arial, sans-serif;
    transition: all 0.3s ease;
}

.input-group select:hover {
    border-color: var(--accent-color);
}

.input-group select:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

#download-btn {
    width: 100%;
    text-align: center;
}

.warning-message {
    color: var(--warning);
    font-size: 0.9rem;
    margin-top: 1rem;
}

.info-message {
    color: var(--info);
    font-size: 0.9rem;
    margin-top: 1rem;
}

.warning-card {
    background: var(--warning);
    color: var(--text);
    padding: 1rem;
    margin-top: 1rem;
    border-radius: 8px;
    text-align: center;
}

/* --- Footer Styles --- */
.site-footer {
    background-color: var(--bg);
    border-top: 1px solid var(--border);
    padding: 2rem 0;
    text-align: center;
    color: var(--text-muted);
    margin-top: 4rem; /* Add some space above the footer */
}

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

.discord-logo {
    transition: opacity 0.3s ease;
}

.discord-logo:hover {
    opacity: 0.8;
}
