:root {
    --primary: #2563eb;
    --primary-glow: rgba(37, 99, 235, 0.15);
    --accent: #7c3aed;
    --success: #10b981;
    --warning: #f59e0b;
    --error: #ef4444;
    --card-bg: rgba(255, 255, 255, 0.03);
    --card-border: rgba(255, 255, 255, 0.08);
    --text-main: #e2e8f0;
    --text-dim: #94a3b8;
    --heading-font: 'Outfit', sans-serif;
}

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

body {
    font-family: 'Inter', sans-serif;
    background-color: #0f172a;
    color: var(--text-main);
    line-height: 1.8;
    overflow-x: hidden;
    min-height: 100vh;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Typography */
h1, h2, h3, h4 {
    font-family: var(--heading-font);
    color: #fff;
    line-height: 1.2;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: opacity 0.2s;
}

a:hover {
    opacity: 0.8;
}

/* Hero Section */
.hero {
    padding: 4rem 0 3rem;
    text-align: center;
    background: radial-gradient(circle at top center, rgba(37, 99, 235, 0.1) 0%, transparent 70%);
}

.brand-logo, .app-thumb {
    width: 100px;
    height: 100px;
    border-radius: 1.5rem;
    object-fit: cover;
    display: block;
    margin: 0 auto 1.5rem;
    filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.3));
}

.hero h1 {
    font-size: clamp(2.5rem, 8vw, 4rem);
    font-weight: 800;
    margin: 0;
    background: linear-gradient(135deg, #fff 0%, #94a3b8 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.04em;
}

.hero p {
    font-size: 1.25rem;
    color: var(--text-dim);
    max-width: 600px;
    margin: 0.75rem auto 0;
}

/* Navigation Pill */
.nav-menu {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.6rem;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--card-border);
    border-radius: 999px;
    max-width: fit-content;
    margin: 0 auto 3.5rem;
    position: relative;
    z-index: 100;
}

.nav-link {
    padding: 0.5rem 1.25rem;
    color: var(--text-dim);
    text-decoration: none;
    border-radius: 999px;
    font-size: 0.85rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    font-weight: 600;
}

.nav-link:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.05);
}

.nav-link.active {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
}

/* Home Page Specific: App Grid */
.app-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.5rem;
    margin-top: 2rem;
}

.app-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 1.5rem;
    padding: 1.25rem 1.5rem;
    width: 340px; /* Horizontal Rectangle */
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 1.25rem;
    text-align: left;
    text-decoration: none;
}

.app-card:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--primary);
    transform: translateY(-5px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.3);
}

.app-icon {
    width: 64px;
    height: 64px;
    border-radius: 1.1rem;
    overflow: hidden;
    flex-shrink: 0;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
}

.app-details {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    flex: 1;
}

.app-name {
    font-size: 1.15rem;
    font-weight: 700;
    font-family: var(--heading-font);
    color: #fff;
    line-height: 1.2;
}

.app-card img.badge {
    height: 28px;
    width: auto;
    display: block;
}

/* Content Sections */
.content-section {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 2.5rem;
    padding: 3rem;
    margin-bottom: 3rem;
}

.content-section h2, .content-section h3 {
    margin-bottom: 1.5rem;
}

.content-section p {
    margin-bottom: 1.25rem;
}

/* Feature Grid */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.feature-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 2rem;
    padding: 2.5rem;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.feature-card:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.15);
    transform: translateY(-8px);
}

.feature-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.feature-card p {
    color: var(--text-dim);
    font-size: 1.05rem;
}

.feature-card ul {
    margin-top: 1.25rem;
    padding-left: 1.25rem;
    color: var(--text-dim);
}

.feature-card li {
    margin-bottom: 0.75rem;
}

/* Footer */
footer {
    padding: 6rem 0 4rem;
    text-align: center;
    border-top: 1px solid var(--card-border);
    color: var(--text-dim);
    font-size: 0.95rem;
}

/* Scroll to Top Button */
#scrollToTopBtn {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 3.5rem;
    height: 3.5rem;
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--card-border);
    color: #fff;
    border-radius: 50%;
    display: none;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 1000;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

#scrollToTopBtn:hover {
    background: var(--primary);
    transform: translateY(-5px);
    box-shadow: 0 12px 40px rgba(37, 99, 235, 0.4);
    border-color: rgba(255, 255, 255, 0.2);
}

#scrollToTopBtn.show {
    display: flex;
    animation: btnFadeIn 0.3s ease;
}

@keyframes btnFadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .hero {
        padding: 3rem 0 2rem;
    }
    .nav-menu {
        flex-wrap: wrap;
        justify-content: center;
        width: 100%;
        max-width: 100%;
        border-radius: 1.5rem;
        gap: 0.25rem;
        padding: 0.6rem;
        margin-bottom: 2.5rem;
    }
    .nav-link {
        padding: 0.5rem 1rem;
        font-size: 0.8rem;
    }
    .content-section {
        padding: 2rem;
        border-radius: 2rem;
    }
    .app-card {
        padding: 2rem;
    }
}