/* =========================================
   Top Page CSS - Gateway Architecture
   ========================================= */

/* Header with Navigation */
.portal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--spacing-md) var(--spacing-lg);
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(20px);
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo a {
    font-family: var(--font-heading);
    font-weight: 900;
    letter-spacing: -1px;
    text-decoration: none;
}

.main-nav {
    display: flex;
    gap: var(--spacing-lg);
    align-items: center;
}

.nav-link {
    font-family: var(--font-heading);
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--color-text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    padding: var(--spacing-sm) var(--spacing-md);
    border-radius: 4px;
    text-decoration: none;
}

.nav-link:hover {
    color: var(--color-text-main);
}

.nav-link.active {
    color: var(--color-primary);
    background: rgba(0, 242, 255, 0.1);
}

/* Mobile Navigation */
@media (max-width: 768px) {
    .main-nav {
        gap: var(--spacing-sm);
    }
    
    .nav-link {
        font-size: 0.75rem;
        padding: var(--spacing-xs) var(--spacing-sm);
    }
}

/* Mesh Background for Premium Feel */
body {
    background-color: var(--color-bg);
    /* Subtle noise texture */
    background-image: url('https://www.transparenttextures.com/patterns/stardust.png'),
        radial-gradient(at 0% 0%, rgba(0, 242, 255, 0.08) 0px, transparent 50%),
        radial-gradient(at 100% 0%, rgba(112, 0, 255, 0.06) 0px, transparent 50%),
        radial-gradient(at 100% 100%, rgba(255, 0, 85, 0.04) 0px, transparent 50%);
    background-attachment: fixed;
    overflow-x: hidden;
}

/* --- Hero Section ("The Gateway") --- */
.hero-section {
    min-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-xl) var(--spacing-md);
    position: relative;
    overflow: hidden;
}

.hero-container {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--spacing-xl);
    max-width: 1400px;
    width: 100%;
    margin: 0 auto;
    align-items: center;
}

@media (min-width: 992px) {
    .hero-container {
        grid-template-columns: 1.2fr 0.8fr;
        gap: 4rem;
    }
}

.hero-content {
    position: relative;
    z-index: 10;
}

/* Typography: Massive Glass Title */
.glass-title {
    font-family: var(--font-heading);
    font-size: 4rem;
    font-weight: 900;
    line-height: 0.9;
    letter-spacing: -0.04em;
    margin-bottom: var(--spacing-md);
    color: transparent;
    -webkit-text-stroke: 1px rgba(255, 255, 255, 0.5);
    background: linear-gradient(135deg, #fff 0%, rgba(255, 255, 255, 0.2) 100%);
    background-clip: text;
    -webkit-background-clip: text;
    filter: drop-shadow(0 0 30px rgba(0, 242, 255, 0.2));
    animation: titleFloat 6s ease-in-out infinite alternate;
}

@media (min-width: 768px) {
    .glass-title {
        font-size: 7rem;
    }
}

@keyframes titleFloat {
    0% { transform: translateY(0); filter: drop-shadow(0 0 30px rgba(0, 242, 255, 0.2)); }
    100% { transform: translateY(-10px); filter: drop-shadow(0 0 50px rgba(112, 0, 255, 0.3)); }
}

.text-gradient {
    background: linear-gradient(90deg, #00f2ff, #7000ff);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-stroke: 0;
    color: transparent;
}

.hero-subtitle {
    color: var(--color-text-muted);
    font-size: 1.2rem;
    max-width: 500px;
    line-height: 1.6;
    margin-bottom: var(--spacing-lg);
    border-left: 2px solid var(--color-primary);
    padding-left: 1rem;
}

/* CTA Button */
.cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 16px 40px;
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.9rem;
    letter-spacing: 1px;
    text-transform: uppercase;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
    backdrop-filter: blur(10px);
}

.cta-btn:hover {
    background: var(--color-primary);
    color: #000;
    border-color: var(--color-primary);
    transform: translateX(10px);
    box-shadow: 0 0 40px rgba(0, 242, 255, 0.4);
}

/* Visual: Dynamic Montage */
.hero-visual {
    position: relative;
    height: 400px;
    perspective: 1000px;
}

.montage-container {
    width: 100%;
    height: 100%;
    position: relative;
    transform-style: preserve-3d;
    transform: rotateY(-10deg) rotateX(5deg);
    transition: transform 0.5s ease-out;
}

.hero-visual:hover .montage-container {
    transform: rotateY(0) rotateX(0);
}

.montage-item {
    position: absolute;
    inset: 0;
    border-radius: 20px;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1s ease;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.montage-item.active {
    opacity: 1;
}

/* Placeholder gradient until images load */
.montage-item:nth-child(1) { background: linear-gradient(45deg, #111, #333); }
.montage-item:nth-child(2) { background: linear-gradient(45deg, #003366, #111); }
.montage-item:nth-child(3) { background: linear-gradient(45deg, #4b0082, #111); }

.montage-overlay {
    position: absolute;
    bottom: 20px;
    right: 20px;
    background: rgba(0, 0, 0, 0.8);
    padding: 5px 15px;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(5px);
}

.montage-label {
    font-size: 0.7rem;
    font-family: var(--font-mono);
    color: var(--color-primary);
    letter-spacing: 1px;
}

/* --- Category Grid (Bento Layout) --- */
.category-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--spacing-md);
    padding: 0 var(--spacing-md) var(--spacing-xl);
    max-width: 1400px;
    margin: 0 auto;
}

@media (min-width: 768px) {
    .category-grid {
        grid-template-columns: repeat(4, 1fr);
        grid-auto-rows: 250px;
        gap: 1.5rem;
    }
    
    /* Bento Spans */
    .category-card:nth-child(1) { grid-column: span 2; grid-row: span 2; } /* Feature */
    .category-card:nth-child(2) { grid-column: span 1; grid-row: span 1; }
    .category-card:nth-child(3) { grid-column: span 1; grid-row: span 2; } /* Tall */
    .category-card:nth-child(4) { grid-column: span 2; grid-row: span 1; } /* Wide */
}

/* Card Style - Unified Glow */
.category-card {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.03); /* Extremely subtle */
    border: 1px solid rgba(255, 255, 255, 0.1); /* Thin & Elegant */
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 2.5rem;
    text-decoration: none;
    transition: all 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
    /* Minimal backdrop filter for readability without heavy cost */
    backdrop-filter: blur(10px); 
}

/* Remove old liquid/grid pseudo elements */
.category-card::before {
    display: none;
}

.category-card:hover {
    transform: translateY(-5px);
    background: rgba(0, 0, 0, 0.4); /* Darken for readability */
    border-color: var(--card-color, #fff); /* Unified Glow Border */
    box-shadow: 
        0 10px 40px rgba(0,0,0,0.5),
        0 0 30px var(--card-color, rgba(255,255,255,0.2)); /* Unified Glow Shadow */
    z-index: 10;
}

/* Typography in Card */
.category-card h2 {
    font-size: 2.2rem;
    font-weight: 800;
    z-index: 2;
    margin-bottom: 0.8rem;
    color: #fff;
    /* Clean text, minimal shadow */
    text-shadow: 0 2px 4px rgba(0,0,0,0.5); 
    letter-spacing: -0.02em;
    transition: color 0.3s;
}

.category-card p {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.7);
    z-index: 2;
    font-weight: 500;
    transform: translateY(10px);
    opacity: 0;
    transition: all 0.3s ease;
}

.category-card:hover h2 {
    color: var(--card-color, #fff);
}

.category-card:hover p {
    transform: translateY(0);
    opacity: 1;
    color: #fff;
}

/* Theme Accents (Injected by JS usually, but defaults) */
.theme-business { --theme-accent: #38bdf8; }
.theme-streamer { --theme-accent: #d946ef; }
.theme-lp { --theme-accent: #f43f5e; }
.theme-portfolio { --theme-accent: #fbbf24; }
