:root {
    --bg-gradient: linear-gradient(135deg, #2d1f66 0%, #160d33 100%);
    /* Slightly lighter deep purple gradient */
    --text-color: #ffffff;
    --accent-primary: #7c3aed;
    --accent-glow: rgba(124, 58, 237, 0.5);
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
    --font-main: 'Outfit', sans-serif;
}

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

body {
    background: linear-gradient(-45deg, #2d1f66, #160d33, #0f0824, #2d1f66);
    background-size: 400% 400%;
    animation: gradientBG 15s ease infinite;
    color: var(--text-color);
    font-family: var(--font-main);
    overflow-x: hidden;
    line-height: 1.6;
    min-height: 100vh;
}

@keyframes gradientBG {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

/* Utilities */
.text-gradient {
    background: linear-gradient(to right, #fff, #a78bfa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.glass-panel {
    background: rgba(20, 20, 35, 0.6);
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 
        0 20px 40px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    padding: 2rem 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    background: transparent;
    transition: background 0.3s, padding 0.3s;
}

.navbar.scrolled {
    background: rgba(15, 8, 36, 0.85);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    padding: 1rem 5%;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.logo {
    font-weight: 700;
    font-size: 1.5rem;
    letter-spacing: -0.02em;
}

.logo a {
    color: inherit;
    text-decoration: none;
    transition: opacity 0.3s;
}

.logo a:hover {
    opacity: 0.8;
}

.nav-links {
    display: flex;
    gap: 2.5rem;
    align-items: center;
}

.nav-links a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: white;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

.cta-button {
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 0.6rem 1.5rem;
    border-radius: 2rem;
    transition: all 0.3s;
}

.cta-button:hover {
    background: white;
    color: black !important;
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
    text-shadow: none;
}

.nav-links { position: relative; }
.nav-dropdown { position: relative; }
.link-btn { background: none; border: 0; color: rgba(255,255,255,0.85); font: inherit; cursor: pointer; padding: 0; }
.link-btn:hover { color: #fff; text-shadow: 0 0 10px rgba(255,255,255,0.5); }
.dropdown-panel { position: absolute; top: calc(100% + 10px); right: 0; display: inline-block; width: max-content; max-width: 420px; padding: 0.75rem 1rem; border-radius: 14px; opacity: 0; transform: translateY(-6px); pointer-events: none; transition: opacity .2s ease, transform .2s ease; background: rgba(12, 14, 22, 0.95); border: 1px solid rgba(255,255,255,0.08); box-shadow: 0 20px 50px rgba(0,0,0,0.5); }
.nav-dropdown.open .dropdown-panel { opacity: 1; transform: translateY(0); pointer-events: auto; }
.dropdown-title { margin: 0 0 .4rem; font-weight: 800; letter-spacing: -0.01em; }
.dropdown-text { margin: 0; color: rgba(255,255,255,0.85); }

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 0 5%;
    position: relative;
    overflow: hidden;
}

.hero-content {
    width: 50%;
    z-index: 10;
    padding-right: 2rem;
}

.hero-title {
    margin-bottom: 1.5rem;
    display: block;
    width: 100%;
    height: auto;
    min-height: 150px;
    /* Reserve space */
    position: relative;
}

#pixel-title-canvas {
    width: 100%;
    height: 100%;
    display: block;
}

.hero-subtitle {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 3rem;
    max-width: 500px;
    line-height: 1.6;
}

.hero-cta {
    background: white;
    color: black;
    text-decoration: none;
    padding: 1rem 2.5rem;
    border-radius: 3rem;
    font-weight: 700;
    font-size: 1rem;
    letter-spacing: 0.05em;
    display: inline-block;
    transition: transform 0.2s, box-shadow 0.3s;
}

.hero-cta:hover {
    transform: scale(1.05);
    box-shadow: 0 0 30px rgba(255, 255, 255, 0.4);
}

/* Floating Phones & Elements */
.hero-visuals {
    position: absolute;
    right: -5%;
    top: 50%;
    transform: translateY(-50%);
    width: 55%;
    height: 80vh;
    z-index: 5;
    perspective: 1000px;
}

.phone-mockup {
    position: absolute;
    width: 280px;
    border-radius: 40px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    border: 8px solid #1a1a1a;
    transition: all 0.6s cubic-bezier(0.25, 0.8, 0.25, 1);
    /* Smooth transition for position swaps */
    cursor: pointer;
    will-change: transform, opacity, right, top;
}

/* Stack Positions */
.phone-pos-1 {
    top: 10%;
    right: 35%;
    /* Moved further left (was 25%) */
    transform: rotate(15deg);
    z-index: 3;
    opacity: 1;
    filter: blur(0);
}

.phone-pos-2 {
    top: 20%;
    right: 20%;
    /* Moved further left (was 10%) */
    transform: rotate(10deg) translateZ(-50px) scale(0.95);
    z-index: 2;
    opacity: 0.8;
    filter: blur(1px);
}

.phone-pos-3 {
    top: 30%;
    right: 5%;
    /* Moved further left (was -5%) */
    transform: rotate(5deg) translateZ(-100px) scale(0.9);
    z-index: 1;
    opacity: 0.6;
    filter: blur(2px);
}

/* Floating Spheres */
.sphere {
    position: absolute;
    border-radius: 50%;
    background: radial-gradient(circle at 30% 30%, var(--accent-primary), transparent);
    filter: blur(20px);
    opacity: 0.6;
    z-index: 0;
    transition: transform 0.1s ease-out;
    will-change: transform;
    animation: float-sphere 8s infinite ease-in-out;
}

.sphere-1 {
    width: 100px;
    height: 100px;
    top: 10%;
    left: 10%;
    animation-delay: 0s;
}

.sphere-2 {
    width: 60px;
    height: 60px;
    bottom: 20%;
    right: 40%;
    animation-delay: 2s;
}

.sphere-3 {
    width: 40px;
    height: 40px;
    top: 40%;
    right: 10%;
    animation-delay: 4s;
}

@keyframes float-sphere {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-20px);
    }
}

/* Stats Section */
.stats-container {
    position: absolute;
    bottom: 5%;
    left: 5%;
    display: flex;
    gap: 4rem;
    z-index: 10;
}

.stat-item h3 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.2rem;
}

.stat-item p {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.6);
}

/* Showcase Section */
.showcase {
    padding: 8rem 5%;
    /* Removed solid background for continuity */
}

.section-header {
    text-align: center;
    margin-bottom: 5rem;
}

.section-header h2 {
    font-size: 3rem;
    margin-bottom: 1rem;
    font-weight: 800;
}

.app-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 4rem;
    justify-items: center;
    /* Center the phones */
}

.app-card {
    background: transparent;
    border: none;
    border-radius: 0;
    overflow: visible;
    transition: transform 0.3s;
    width: 100%;
    max-width: 320px;
    /* Phone width */
    display: flex;
    flex-direction: column;
    align-items: center;
    opacity: 0;
    /* For animation */
    transform: translateY(30px);
    /* For animation */
}

.app-card:hover {
    transform: translateY(-15px);
    background: transparent;
}

.app-image-container {
    position: relative;
    width: 100%;
    aspect-ratio: 9/19.5;
    /* iPhone aspect ratio */
    border-radius: 40px;
    border: 10px solid #1a1a1a;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    overflow: hidden;
    background: #000;
    margin-bottom: 1.5rem;
    transition: box-shadow 0.3s, border-color 0.3s;
}

.app-card:hover .app-image-container {
    box-shadow: 0 30px 60px rgba(124, 58, 237, 0.3);
    border-color: #2a2a2a;
}

/* Notch */
.app-image-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 35%;
    height: 25px;
    background: #1a1a1a;
    border-bottom-left-radius: 15px;
    border-bottom-right-radius: 15px;
    z-index: 10;
}

.app-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.app-info {
    padding: 0;
    text-align: center;
}

.app-title {
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
    font-weight: 700;
}

.app-desc {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1rem;
    margin-bottom: 1.5rem;
}

.app-link {
    color: white;
    text-decoration: none;
    font-weight: 600;
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
    padding-bottom: 2px;
    transition: border-color 0.3s;
}

.app-link:hover {
    border-color: white;
}

.reveal-text {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal-text.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Footer */
footer {
    padding: 4rem 5%;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    background: rgba(0, 0, 0, 0.2);
}

.business-info {
    margin-top: 1rem;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.95rem;
}

/* Responsive */
@media (max-width: 900px) {
    .hero {
        flex-direction: column;
        padding-top: 8rem;
        text-align: center;
    }

    .hero-content {
        width: 100%;
        padding-right: 0;
        margin-bottom: 3rem;
    }

    .hero-visuals {
        position: relative;
        width: 100%;
        height: 400px;
        right: auto;
        top: auto;
        transform: none;
    }

    .phone-1 {
        right: 50%;
        transform: translateX(50%) rotate(-10deg);
    }

    .phone-2 {
        display: none;
    }

    .stats-container {
        position: relative;
        bottom: auto;
        left: auto;
        justify-content: center;
        margin-top: 2rem;
    }
}

/* Feature Showcase Section */
.gallery-section {
    padding: 8rem 5%;
    background: linear-gradient(to bottom, #160d33, #0f0824);
    position: relative;
    overflow: hidden;
}

.gallery-title {
    font-size: 3rem;
    margin-bottom: 6rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    text-align: center;
    background: linear-gradient(to right, #fff, rgba(255, 255, 255, 0.5));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.features-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 8rem;
}

.feature-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 4rem;
    opacity: 0;
    transform: translateY(50px);
    transition: all 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}

.feature-row.visible {
    opacity: 1;
    transform: translateY(0);
}

.row-reverse {
    flex-direction: row-reverse;
}

.feature-visual {
    flex: 1;
    display: flex;
    justify-content: center;
    position: relative;
}

/* Phone Frame with Notch */
.phone-frame {
    position: relative;
    width: 300px;
    aspect-ratio: 9/19.5;
    border-radius: 45px;
    border: 10px solid #1a1a1a;
    background: #000;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
    overflow: hidden;
    transition: transform 0.5s ease;
}

.feature-row:hover .phone-frame {
    transform: scale(1.02) translateY(-10px);
    box-shadow: 0 40px 100px rgba(124, 58, 237, 0.2);
}

/* The Notch */
.phone-frame::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 35%;
    height: 25px;
    background: #1a1a1a;
    border-bottom-left-radius: 18px;
    border-bottom-right-radius: 18px;
    z-index: 10;
}

.feature-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.feature-content {
    flex: 1;
    padding: 2rem;
}

.feature-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: white;
    line-height: 1.1;
}

.feature-desc {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.7;
    max-width: 450px;
}

/* Responsive */
@media (max-width: 900px) {

    .feature-row,
    .row-reverse {
        flex-direction: column;
        text-align: center;
        gap: 3rem;
    }

    .feature-desc {
        margin: 0 auto;
    }

    .gallery-title {
        font-size: 2rem;
        margin-bottom: 4rem;
    }
}