/* Material Expressive 3 Tokens & Core Styles */
:root {
    /* Color Palette - Dark Theme Expressive */
    --md-sys-color-background: #000000;
    --md-sys-color-on-background: #E6E1E5;
    --md-sys-color-primary: #D0BCFF;
    --md-sys-color-on-primary: #381E72;
    --md-sys-color-primary-container: #4F378B;
    --md-sys-color-on-primary-container: #EADDFF;
    --md-sys-color-secondary: #CCC2DC;
    --md-sys-color-on-secondary: #332D41;
    --md-sys-color-tertiary: #EFB8C8;
    --md-sys-color-surface: #141218;
    --md-sys-color-surface-variant: #49454F;
    --md-sys-color-outline: #938F99;

    /* Typography */
    --md-sys-typescale-display-large: 400 57px/64px 'Roboto Flex', sans-serif;
    --md-sys-typescale-headline-large: 400 32px/40px 'Roboto Flex', sans-serif;
    --md-sys-typescale-body-large: 400 16px/24px 'Roboto Flex', sans-serif;

    /* Motion */
    --md-sys-motion-easing-emphasized: cubic-bezier(0.2, 0.0, 0.0, 1.0);
    --md-sys-motion-duration-long2: 600ms;
}

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

body {
    background-color: var(--md-sys-color-background);
    color: var(--md-sys-color-on-background);
    font-family: 'Roboto Flex', sans-serif;
    overflow: hidden;
    /* For custom slide handling */
    height: 100vh;
    width: 100vw;
}

.app-container {
    height: 100%;
    width: 100%;
    position: relative;
}

/* Ambient Background */
.ambient-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 50% 50%, #4F378B 0%, #000000 70%);
    opacity: 0.4;
    z-index: -1;
    animation: pulseBackground 10s infinite alternate var(--md-sys-motion-easing-emphasized);
}

@keyframes pulseBackground {
    0% {
        opacity: 0.3;
        transform: scale(1);
    }

    100% {
        opacity: 0.5;
        transform: scale(1.1);
    }
}

/* Slides Wrapper */
.slides-wrapper {
    height: 100%;
    width: 100%;
    display: flex;
    flex-direction: column;
    transition: transform var(--md-sys-motion-duration-long2) var(--md-sys-motion-easing-emphasized);
}

.slide {
    height: 100vh;
    width: 100vw;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding: 2rem;
}

/* Navigation Dots */
.slide-nav {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 12px;
    z-index: 100;
}

.nav-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--md-sys-color-outline);
    border: none;
    cursor: pointer;
    transition: all 0.3s var(--md-sys-motion-easing-emphasized);
}

.nav-dot.active {
    background: var(--md-sys-color-primary);
    height: 24px;
    /* elongated dot for active state */
    border-radius: 12px;
}

/* Typography styles */
.brand-name {
    font: var(--md-sys-typescale-display-large);
    font-size: 6rem;
    font-weight: 800;
    letter-spacing: -2px;
    background: linear-gradient(135deg, var(--md-sys-color-primary), var(--md-sys-color-tertiary), var(--md-sys-color-primary));
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    opacity: 0;
    transform: translateY(30px);
    animation: slideUpFade 0.8s var(--md-sys-motion-easing-emphasized) forwards 0.2s,
        shimmer 3s linear infinite;
}

@keyframes shimmer {
    to {
        background-position: 200% center;
    }
}

.brand-subtitle {
    font: var(--md-sys-typescale-headline-large);
    opacity: 0;
    transform: translateY(20px);
    animation: slideUpFade 0.8s var(--md-sys-motion-easing-emphasized) forwards 0.4s;
}

/* Animations */
@keyframes slideUpFade {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}



/* Staggered Animation Delays */
.slide .content>* {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.5s var(--md-sys-motion-easing-emphasized);
}

.slide.active .content>* {
    opacity: 1;
    transform: translateY(0);
}

.slide.active .content>*:nth-child(1) {
    transition-delay: 100ms;
}

.slide.active .content>*:nth-child(2) {
    transition-delay: 200ms;
}

.slide.active .content>*:nth-child(3) {
    transition-delay: 300ms;
}

/* Enhanced Glassmorphism Card */
.glass {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 28px;
    padding: 32px;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s var(--md-sys-motion-easing-emphasized),
        box-shadow 0.3s var(--md-sys-motion-easing-emphasized),
        background 0.3s;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    text-align: center;
}

.glass:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.2);
}

.projects-grid {
    display: grid;
    gap: 24px;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    width: 100%;
    max-width: 900px;
    margin-top: 32px;
}

/* Material Icons Placeholder Styling */
.material-icon-placeholder {
    font-size: 3rem;
    background: linear-gradient(135deg, var(--md-sys-color-secondary), var(--md-sys-color-tertiary));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Store Links Styling */
.store-links {
    display: flex;
    gap: 24px;
    margin-top: 48px;
    flex-wrap: wrap;
    justify-content: center;
}

.store-button {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 32px;
    background: rgba(255, 255, 255, 0.1);
    color: var(--md-sys-color-on-background);
    text-decoration: none;
    border-radius: 100px;
    font-weight: 500;
    font-size: 1.1rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s var(--md-sys-motion-easing-emphasized);
}

.store-button:hover {
    transform: translateY(-3px);
    background: var(--md-sys-color-primary);
    color: var(--md-sys-color-on-primary);
    box-shadow: 0 5px 20px rgba(208, 188, 255, 0.3);
    border-color: transparent;
}

.store-button svg {
    width: 24px;
    height: 24px;
    fill: currentColor;
}

/* Mouse Trail Effect */
/* Footer Styling */
.footer-bottom {
    position: absolute;
    bottom: 2rem;
    left: 0;
    right: 0;
    text-align: center;
    width: 100%;
    z-index: 10;
}

.privacy-link {
    color: var(--md-sys-color-primary);
    text-decoration: none;
    font-size: 0.85rem;
    opacity: 0.6;
    transition: opacity 0.2s var(--md-sys-motion-easing-emphasized);
    letter-spacing: 0.5px;
}

.privacy-link:hover {
    opacity: 1;
    text-decoration: underline;
}

.trail-dot {
    position: fixed;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: radial-gradient(circle, var(--md-sys-color-primary) 0%, transparent 70%);
    pointer-events: none;
    z-index: 9999;
    transform: translate(-50%, -50%);
    animation: fadeOut 1s forwards;
    opacity: 0.6;
}

@keyframes fadeOut {
    to {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.2);
    }
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .brand-name {
        font-size: 3.5rem;
        letter-spacing: -1px;
    }

    .brand-subtitle {
        font-size: 1.5rem;
    }

    .slide {
        padding: 1rem;
    }

    .glass {
        padding: 24px;
        border-radius: 20px;
    }

    .projects-grid {
        grid-template-columns: 1fr;
        /* Single column on mobile */
        gap: 16px;
        margin-top: 24px;
    }

    .store-links {
        flex-direction: column;
        gap: 16px;
        width: 100%;
        max-width: 300px;
    }

    .store-button {
        width: 100%;
        justify-content: center;
    }

    /* Adjust navigation dots for mobile */
    .slide-nav {
        right: 12px;
    }
}