@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@100;200;300;400;500;600;700;800;900&display=swap');

body {
    font-family: 'Poppins', sans-serif;
    color: #FFFFFF;
    background-color: #000000;
}

.header {
    background-color: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(10px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1002;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    position: fixed;
    width: 100%;
    top: 0;
    height: 70px;
}

@media (min-width: 1024px) {
    .header {
        height: 90px;
    }
}

.header-transparent {
    background-color: transparent;
    backdrop-filter: none;
    border-bottom: none;
}

.header-transparent.scrolled {
    background-color: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.desktop-menu {
    display: none;
}

@media (min-width: 1024px) {
    .desktop-menu {
        display: flex;
    }

    .desktop-menu-item {
        position: relative;
        padding: 1rem;
        cursor: pointer;
        color: #FFFFFF;
        font-weight: 350;
        transition: all 0.3s ease;
        border-radius: 12px;
    }

    .desktop-menu-item:hover {
        color: rgba(255, 255, 255, 0.7);
        background: rgba(255, 255, 255, 0.1);
    }
}

/* Desktop overlay styles */
.desktop-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    display: flex;
    justify-content: center;
    align-items: flex-start;
}

.desktop-overlay.active {
    opacity: 1;
    visibility: visible;
}

.overlay-container {
    max-width: 1200px;
    width: 100%;
    padding: 40px;
    margin-top: 90px;
}

.overlay-content {
    background: rgba(20, 20, 20, 0.95);
    border-radius: 24px;
    padding: 30px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.overlay-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.overlay-title {
    font-size: 1.5rem;
    font-weight: 600;
}

.overlay-close {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.2s ease;
}

.overlay-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

.overlay-links {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 30px;
}

.overlay-link {
    display: block;
    padding: 15px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    text-align: center;
    transition: all 0.2s ease;
}

.overlay-link:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-3px);
}

.stories-title {
    font-size: 1.2rem;
    font-weight: 500;
    margin-bottom: 15px;
}

.stories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
}

.story-item {
    height: 200px;
    border-radius: 20px;
    overflow: hidden;
    position: relative;
    background-size: cover;
    background-position: center;
    transition: all 0.3s ease;
}

.story-item:hover {
    transform: scale(1.02);
}

.story-content {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 20px;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
}

.story-content h5 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 5px;
}

.story-content p {
    font-size: 0.9rem;
    opacity: 0.8;
}

.mobile-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
}

.mobile-overlay.active {
    opacity: 1;
    visibility: visible;
}

.mobile-menu {
    position: fixed;
    top: 70px;
    left: 0;
    width: 100%;
    height: calc(100vh - 70px);
    background: #000000;
    transform: translateY(-100%);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1001;
    opacity: 0;
    visibility: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

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

.mobile-menu-header {
    position: sticky;
    top: 0;
    background: #000000;
    z-index: 2;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
}

.menu-title {
    font-size: 1.25rem;
    font-weight: 600;
}

.mobile-menu-items {
    padding: 20px;
    padding-bottom: 40px;
}

.mobile-menu-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px;
    margin-bottom: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.mobile-menu-item:active {
    transform: scale(0.98);
    background: rgba(255, 255, 255, 0.12);
}

.mobile-submenu-panel {
    position: fixed;
    top: 70px;
    left: 0;
    width: 100%;
    height: calc(100vh - 70px);
    background: #000000;
    z-index: 1002;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    transform: translateX(100%);
    opacity: 0;
    visibility: hidden;
    overflow-y: auto;
}

.mobile-submenu-panel.active {
    transform: translateX(0);
    opacity: 1;
    visibility: visible;
}

.mobile-submenu-header {
    position: sticky;
    top: 0;
    background: #000000;
    z-index: 2;
    display: flex;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    gap: 15px;
    backdrop-filter: blur(10px);
}

.mobile-submenu-content {
    padding: 20px;
    padding-bottom: 40px;
}

.mobile-submenu-link {
    display: block;
    padding: 16px;
    margin-bottom: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.mobile-submenu-link:active {
    transform: scale(0.98);
    background: rgba(255, 255, 255, 0.12);
}

.hamburger {
    width: 40px;
    height: 40px;
    position: relative;
    cursor: pointer;
    z-index: 1003;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

@media (max-width: 1023px) {
    .hamburger {
        display: flex;
    }
}

.hamburger span {
    display: block;
    position: absolute;
    height: 2px;
    width: 20px;
    background: #FFFFFF;
    border-radius: 2px;
    opacity: 1;
    left: 10px;
    transition: transform 0.3s ease-in-out;
}

.hamburger span:nth-child(1) {
    top: 14px;
    transform-origin: center;
}

.hamburger span:nth-child(2) {
    top: 24px;
    transform-origin: center;
}

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

.hamburger.active span:nth-child(2) {
    transform: translateY(-5px) rotate(-45deg);
}

.close-button {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Mobile stories styles */
.featured-cards-section {
    padding: 20px;
    margin-bottom: 20px;
}

.stories-container {
    width: 100%;
    overflow: hidden;
}

.stories-grid-mobile {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.story-card {
    aspect-ratio: 1 / 1;
    border-radius: 20px;
    padding: 15px;
    position: relative;
    overflow: hidden;
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.story-card:active {
    transform: scale(0.98);
}

.story-card-content {
    position: relative;
    z-index: 2;
}

.story-card-content h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 5px;
}

.story-card-content p {
    font-size: 0.8rem;
    opacity: 0.9;
    margin-bottom: 10px;
}

.story-card-content a {
    display: inline-block;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 9999px;
    font-size: 0.75rem;
    transition: all 0.3s ease;
}

.story-card-content a:active {
    background: rgba(255, 255, 255, 0.3);
}

.imators-account-btn {
    display: inline-flex;
    align-items: center;
    padding: 0.5rem 1rem;
    font-weight: 500;
    color: #000000;
    background-color: #FFFFFF;
    border-radius: 12px;
    transition: all 0.2s ease;
}

.imators-account-btn:hover {
    opacity: 0.9;
}

.header-content {
    height: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-container {
    display: flex;
    align-items: center;
}

.logo-container img {
    height: 28px;
    transition: all 0.3s ease;
}

@media (min-width: 1024px) {
    .logo-container img {
        height: 36px;
    }
}

@media (max-width: 640px) {
    .stories-grid-mobile {
        grid-template-columns: repeat(2, 1fr);
    }
}

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInDown {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}