@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@500;600;700&family=Inter:wght@400;600&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Figtree:ital,wght@0,300..900;1,300..900&display=swap');

html.preload *,
html.preload *::before,
html.preload *::after {
  transition: none !important;
  animation: none !important;
}

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

html, body {
    width: 100%;
    min-height: 100%;
    font-family: "Inter", "Figtree", sans-serif;
    background-color: #0e0e0e;
    color: #f1f1f1;
    transition: background-color 1s ease, color 1s ease;
    overflow-x: hidden;
}

body.menu-open {
    overflow: hidden;
}

.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 70px;
    height: 100vh;
    background: #0e0e0e;
    display: flex;
    align-items: center;
    z-index: 20;
    transition: background 0.45s;
}

body.light-theme .sidebar {
    background: #f1f1f1;
}

.sidebar-bar {
    position: absolute;
    left: 55px;
    top: 5vh;
    height: 90vh;
    width: 1px;
    background: #fff;
    border-radius: 1px;
    transition: background 0.45s;
}

body.light-theme .sidebar-bar {
    background: #111;
}

.sidebar-icons {
    position: absolute;
    left: 0;
    top: calc(5vh + 20px);
    width: 55px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
}

.icon-link {
    border: none;
    background: none;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    cursor: pointer;
    outline: none;
    width: 38px;
    height: 38px;
    transition: background 0.2s;
    border-radius: 50%;
}

.icon-link:active, .icon-link:focus {
    background: rgba(255,255,255,0.09);
}

.icon {
    width: 28px;
    height: 28px;
    transition: filter 0.17s, opacity 0.45s;
    filter: invert(1);
    opacity: 1;
}

body.light-theme .icon {
    filter: none;
}

.icon-link:hover .icon,
.icon-link:focus .icon {
    filter: brightness(2.2) invert(1);
    opacity: 0.85;
}

body.light-theme .icon-link:hover .icon,
body.light-theme .icon-link:focus .icon {
    filter: brightness(0.6);
    opacity: 0.85;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    width: 40px;
    height: 40px;
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1002;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 6px;
}

.hamburger-line {
    width: 28px;
    height: 3px;
    background-color: #fff;
    border-radius: 2px;
    transition: all 0.3s ease;
    display: block;
}

body.light-theme .hamburger-line {
    background-color: #0e0e0e;
}

.mobile-menu-btn.active .hamburger-line:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
}

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

.mobile-menu-btn.active .hamburger-line:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
}

.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: linear-gradient(135deg, #0e0e0e 0%, #1a1a1a 100%);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

body.light-theme .mobile-menu-overlay {
    background: linear-gradient(135deg, #ffffff 0%, #f5f5f5 100%);
}

.mobile-menu-overlay.active {
    opacity: 1;
    pointer-events: all;
}

.mobile-menu-content {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    align-items: center;
    padding: 2rem;
    transform: translateY(30px);
    opacity: 0;
    transition: all 0.4s ease 0.1s;
}

.mobile-menu-overlay.active .mobile-menu-content {
    transform: translateY(0);
    opacity: 1;
}

.mobile-menu-item {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1rem 2rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    text-decoration: none;
    color: #f1f1f1;
    font-size: 1.2rem;
    font-weight: 500;
    border: 2px solid transparent;
    transition: all 0.3s ease;
    width: 100%;
    max-width: 400px;
    backdrop-filter: blur(10px);
}

body.light-theme .mobile-menu-item {
    background: rgba(0, 0, 0, 0.05);
    color: #0e0e0e;
}

.mobile-menu-item:hover {
    transform: translateX(10px);
    border-color: #1db954;
    background: rgba(29, 185, 84, 0.1);
}

body.light-theme .mobile-menu-item:hover {
    border-color: #4caf50;
    background: rgba(76, 175, 80, 0.1);
}

.mobile-menu-item img {
    width: 32px;
    height: 32px;
    filter: brightness(0) invert(1);
}

body.light-theme .mobile-menu-item img {
    filter: brightness(0) invert(0);
}

.header {
    width: 100%;
    display: flex;
    justify-content: center;
    padding: 40px 0 30px 0;
}

.header-logo {
    width: 250px;
    height: auto;
    transition: all 0.5s ease;
}

body.light-theme .header-logo {
    content: url('../assets/playlistconverter-logo-b.png');
}

.content {
    margin-left: 70px;
    padding: 40px 80px;
    max-width: 1200px;
    margin-right: auto;
    margin-left: auto;
    text-align: left;
    line-height: 1.7;
}

.content h1 {
    font-size: 2rem;
    margin: 40px 0 15px;
    color: #fff;
    line-height: 1.2;
}

.content h2 {
    font-size: 1.4rem;
    margin-top: 25px;
    color: #ccc;
}

.content p {
    margin-bottom: 18px;
    font-size: 1.05rem;
    color: #ddd;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

body.light-theme {
    background-color: #f1f1f1;
    color: #111;
}

body.light-theme .content h1 {
    color: #111;
}

body.light-theme .content h2 {
    color: #444;
}

body.light-theme .content p {
    color: #333;
}

@media (max-width: 768px) {
    .sidebar {
        display: none;
    }

    .mobile-menu-btn {
        display: flex;
    }

    .header {
        padding: 30px 0 20px 0;
    }

    .content {
        margin-left: 0;
        padding: 20px 24px 80px 24px;
        width: 100%;
    }

    .content h1 {
        font-size: 1.75rem;
        margin: 20px 0 12px;
        text-align: center;
    }

    .content h2 {
        font-size: 1.25rem;
        margin-top: 20px;
    }

    .content p {
        font-size: 1rem;
        text-align: left;
    }

    .header-logo {
        width: 200px;
    }
}