/* Fonts */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&family=Inter:wght@400;500;600&display=swap');

:root {
    --bg-color: #0d0d11;
    --card-bg: rgba(255, 255, 255, 0.05);
    --card-border: rgba(255, 255, 255, 0.1);
    --primary-color: #8b5cf6;
    /* Violet */
    --secondary-color: #ec4899;
    /* Pink */
    --accent-color: #3b82f6;
    /* Blue */
    --text-main: #ffffff;
    --text-muted: #9ca3af;
    --text-link: #a78bfa;

    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;

    --container-width: 1200px;
    --border-radius: 16px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
}

/* Background Gradients/Glows */
body::before {
    content: '';
    position: fixed;
    top: -20%;
    left: -10%;
    width: 50%;
    height: 50%;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.15), transparent 70%);
    filter: blur(80px);
    z-index: -1;
    pointer-events: none;
}

body::after {
    content: '';
    position: fixed;
    bottom: -20%;
    right: -10%;
    width: 60%;
    height: 60%;
    background: radial-gradient(circle, rgba(236, 72, 153, 0.1), transparent 70%);
    filter: blur(100px);
    z-index: -1;
    pointer-events: none;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

/* Layout */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
header {
    padding: 2rem 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.8rem;
    background: linear-gradient(135deg, #fff 0%, #cbd5e1 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    letter-spacing: -0.02em;
}

nav ul {
    display: flex;
    gap: 2rem;
    align-items: center;
}

nav a {
    color: var(--text-muted);
    font-weight: 500;
    font-size: 0.95rem;
}

nav a:hover {
    color: var(--text-main);
}

.lang-switch {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid var(--card-border);
    color: var(--text-main);
    padding: 0.25rem 0.75rem;
    border-radius: 6px;
    cursor: pointer;
    font-family: var(--font-body);
    font-size: 0.85rem;
    transition: var(--transition);
}

.lang-switch:hover {
    background: rgba(255, 255, 255, 0.2);
}


/* Hero Section */
.hero {
    padding: 6rem 0;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.hero h1 {
    font-family: var(--font-heading);
    font-size: 4rem;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    font-weight: 700;
}

.hero h1 span {
    background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    /* Fallback */
}

.hero p {
    color: var(--text-muted);
    font-size: 1.25rem;
    margin-bottom: 2.5rem;
}

/* App Grid */
.projects {
    padding: 4rem 0;
}

.section-title {
    font-family: var(--font-heading);
    font-size: 2rem;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.section-title i {
    color: var(--primary-color);
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
}

/* Cards */
.card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    transition: var(--transition);
    cursor: pointer;
    display: flex;
    flex-direction: column;
    height: 100%;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
}

.card:hover {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.card:hover::before {
    opacity: 1;
}

/* Shine effect on hover */
.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.05), transparent);
    transform: skewX(-25deg);
    transition: 0.5s;
    opacity: 0;
    pointer-events: none;
}

.card:hover::before {
    animation: shine 0.7s;
}

@keyframes shine {
    100% {
        left: 125%;
    }
}

.card-header {
    display: flex;
    align-items: start;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.app-icon {
    width: 64px;
    height: 64px;
    border-radius: 14px;
    object-fit: cover;
    background: #2a2a35;
}

.status-badge {
    font-size: 0.75rem;
    padding: 0.25rem 0.75rem;
    background: rgba(139, 92, 246, 0.1);
    color: var(--primary-color);
    border: 1px solid rgba(139, 92, 246, 0.2);
    border-radius: 100px;
    font-weight: 600;
}

.card h3 {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.card p {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
    flex-grow: 1;
}

.card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 1rem;
}

.date {
    font-size: 0.85rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.arrow-link {
    color: var(--text-link);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.arrow-link i {
    transition: transform 0.2s;
}

.card:hover .arrow-link i {
    transform: translateX(3px);
}

/* Detail Page */
.detail-hero {
    position: relative;
    padding: 4rem 0 2rem;
    border-bottom: 1px solid var(--card-border);
    margin-bottom: 3rem;
}

.breadcrumb {
    margin-bottom: 2rem;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.breadcrumb a:hover {
    color: var(--text-main);
}

.app-header {
    display: flex;
    gap: 2rem;
    align-items: flex-start;
}

.app-header img {
    width: 120px;
    height: 120px;
    border-radius: 24px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.app-info h1 {
    font-family: var(--font-heading);
    font-size: 3rem;
    margin-bottom: 0.5rem;
}

.app-meta {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.tag {
    background: rgba(255, 255, 255, 0.05);
    padding: 0.25rem 0.75rem;
    border-radius: 6px;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.description {
    font-size: 1.1rem;
    color: var(--text-muted);
    max-width: 700px;
    margin-bottom: 3rem;
}

.screenshots-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 4rem;
}

.screenshot-container {
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--card-border);
}

.screenshot-container img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.3s;
}

.screenshot-container:hover img {
    transform: scale(1.03);
}

/* Footer */
footer {
    border-top: 1px solid var(--card-border);
    padding: 3rem 0;
    margin-top: 4rem;
    text-align: center;
    color: var(--text-muted);
}

.tech-stack {
    margin-top: 1rem;
    font-size: 0.85rem;
    opacity: 0.5;
}

/* Loader */
#loader {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 50vh;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(139, 92, 246, 0.3);
    border-radius: 50%;
    border-top-color: var(--primary-color);
    animation: spin 1s ease-in-out infinite;
}

/* Store Buttons */
.store-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.8rem 1.5rem;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid var(--card-border);
    border-radius: 12px;
    color: var(--text-main);
    font-weight: 600;
    transition: var(--transition);
}

.store-btn:hover {
    background: var(--primary-color);
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(139, 92, 246, 0.3);
}

.store-btn i {
    font-size: 1.25rem;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.5rem;
    }

    .app-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .app-meta {
        justify-content: center;
    }

    .hero {
        padding: 4rem 0;
    }
}