/* App Portfolio Styles */

/* Intro Section */
.apps-intro {
    max-width: 800px;
    margin: 0 auto 4rem;
    text-align: center;
}

.apps-intro .tagline {
    font-size: 1.5rem;
    font-weight: 300;
    opacity: 0.6;
    margin-bottom: 1rem;
    letter-spacing: 2px;
}

/* App Showcase */
.app-showcase {
    display: flex;
    flex-direction: column;
    gap: 6rem;
}

.app-feature {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2.5rem;
    align-items: center;
}

/* Phone Mockup Container - Multi-device stacked layout */
.phone-mockup {
    position: relative;
    max-width: 450px;
    margin: 0 auto;
    height: 520px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.phone-frame {
    position: absolute;
    width: 240px;
    background: linear-gradient(145deg, #2a2a2a, #1a1a1a);
    border-radius: 40px;
    padding: 10px;
    box-shadow:
        0 30px 60px rgba(0, 0, 0, 0.5),
        0 0 0 1px rgba(255, 255, 255, 0.1),
        inset 0 0 0 1px rgba(255, 255, 255, 0.05);
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* 3-Phone Stack Logic */
.phone-frame:nth-child(1) {
    z-index: 10;
    transform: translateX(0) scale(1);
}

.phone-frame:nth-child(2) {
    z-index: 5;
    transform: translateX(-100px) translateY(30px) scale(0.85) rotate(-10deg);
    opacity: 0.5;
}

.phone-frame:nth-child(3) {
    z-index: 5;
    transform: translateX(100px) translateY(30px) scale(0.85) rotate(10deg);
    opacity: 0.5;
}

/* Hover interaction to "fan out" the phones */
.phone-mockup:hover .phone-frame:nth-child(1) {
    transform: translateY(-10px) scale(1.02);
}

.phone-mockup:hover .phone-frame:nth-child(2) {
    transform: translateX(-150px) translateY(10px) scale(0.9) rotate(-15deg);
    opacity: 0.85;
}

.phone-mockup:hover .phone-frame:nth-child(3) {
    transform: translateX(150px) translateY(10px) scale(0.9) rotate(15deg);
    opacity: 0.85;
}

.phone-screen {
    aspect-ratio: 9/19.5;
    border-radius: 32px;
    overflow: hidden;
    background: linear-gradient(180deg, #1a1a2e, #16213e);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

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

.screen-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.8rem;
    opacity: 0.3;
    padding: 1rem;
    text-align: center;
}

.screen-placeholder i {
    font-size: 2.5rem;
}

.screen-placeholder span {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.phone-notch {
    position: absolute;
    top: 15px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 22px;
    background: #000;
    border-radius: 20px;
    z-index: 11;
}

/* Floating Elements */
.app-float {
    position: absolute;
    background: var(--glass-bg);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 0.8rem 1rem;
    font-size: 0.8rem;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    animation: app-float 4s ease-in-out infinite;
    z-index: 15;
}

.app-float.top-right {
    top: 5%;
    right: -10%;
    animation-delay: 0s;
}

.app-float.bottom-left {
    bottom: 15%;
    left: -10%;
    animation-delay: -2s;
}

@keyframes app-float {

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

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

/* App Details */
.app-details {
    text-align: center;
}

.app-number {
    font-size: 6rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--accent-1), var(--accent-3));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    opacity: 0.15;
    line-height: 1;
    margin-bottom: -2rem;
    position: relative;
    z-index: -1;
}

.app-details h3 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    position: relative;
}

.app-category {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 3px;
    opacity: 0.5;
    margin-bottom: 1.5rem;
}

.app-story {
    font-size: 1.1rem;
    line-height: 1.8;
    opacity: 0.8;
    max-width: 500px;
    margin: 0 auto 2rem;
}

.app-highlights {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.highlight {
    text-align: center;
}

.highlight-value {
    font-size: 2rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--accent-2), var(--accent-1));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.highlight-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    opacity: 0.5;
}

.app-cta {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 2rem;
    border-radius: 50px;
    background: linear-gradient(135deg, var(--accent-1), var(--accent-2));
    color: white;
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    box-shadow: 0 10px 30px rgba(139, 92, 246, 0.3);
}

.app-cta:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 15px 40px rgba(139, 92, 246, 0.4);
}

/* Separator */
.app-separator {
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--glass-border), transparent);
    margin: 2rem 0;
}

/* Philosophy Section */
.design-philosophy {
    text-align: center;
    padding: 4rem 2rem;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    margin-top: 4rem;
}

.design-philosophy h2 {
    font-size: 2rem;
    margin-bottom: 1.5rem;
    justify-content: center;
}

.philosophy-text {
    max-width: 600px;
    margin: 0 auto 2rem;
    font-size: 1.15rem;
    line-height: 1.8;
    opacity: 0.8;
}

.design-pillars {
    display: flex;
    justify-content: center;
    gap: 3rem;
    flex-wrap: wrap;
    margin-top: 2rem;
}

.pillar {
    text-align: center;
    max-width: 180px;
}

.pillar-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-1), var(--accent-3));
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    font-size: 1.5rem;
}

.pillar h4 {
    font-size: 1rem;
    margin-bottom: 0.5rem;
}

.pillar p {
    font-size: 0.85rem;
    opacity: 0.6;
    margin: 0;
}

/* Desktop Responsive */
@media (min-width: 768px) {
    .app-feature {
        grid-template-columns: 1fr 1fr;
        gap: 4rem;
        text-align: left;
    }

    .app-feature:nth-child(even) .phone-mockup {
        order: 2;
    }

    .app-feature:nth-child(even) .app-details {
        text-align: right;
    }

    .app-feature:nth-child(even) .app-story {
        margin-left: auto;
        margin-right: 0;
    }

    .app-feature:nth-child(even) .app-highlights {
        justify-content: flex-end;
    }

    .app-details {
        text-align: left;
    }

    .app-story {
        margin: 0 0 2rem;
    }

    .app-highlights {
        justify-content: flex-start;
    }

    .phone-mockup {
        margin: 0;
    }

    .app-float.top-right {
        right: -30%;
    }

    .app-float.bottom-left {
        left: -25%;
    }
}