/* =========================================
   1. THE DNA (Variables & Fonts)
   ========================================= */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600&family=Space+Mono:wght@400;700&display=swap');

:root {
    /* Premium Deep Palette */
    --bg-deep:       #061426;  /* Almost black, deep ocean blue */
    --bg-surface:    #0A2342;  
    
    /* Refined Glassmorphism */
    --glass-bg:      rgba(10, 35, 66, 0.4); 
    --glass-border:  rgba(255, 255, 255, 0.05); 
    --glass-blur:    16px;
    
    /* Typography */
    --text-main:     #F3F4F6;  
    --text-muted:    #9CA3AF;  
    --accent:        #00BCD4;  /* Crisp Cyan */
    
    --font-mono:     'Space Mono', monospace;
    --font-sans:     'Inter', sans-serif;
}

/* =========================================
   2. GLOBAL RESET & BASE
   ========================================= */
* { 
    box-sizing: border-box; 
    margin: 0; 
    padding: 0; 
}

body {
    background-color: var(--bg-deep);
    color: var(--text-main);
    font-family: var(--font-sans);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

a { 
    color: inherit; 
    text-decoration: none; 
    transition: all 0.2s ease; 
}

a:hover { 
    color: var(--accent); 
}

/* =========================================
   3. HERO SECTION (Premium Editorial)
   ========================================= */
.hero-wrapper {
    position: relative;
    width: 100%;
    margin-bottom: 80px;
    animation: fadeIn 1s ease-out;
}

.surface-banner {
    width: 100%;
    height: 35vh; 
    min-height: 250px;
    background-image: url('/images/banner.jpg');
    background-size: cover;
    background-position: center;
    position: relative;
    background-color: var(--bg-surface); /* Fallback while loading */
}

/* Subtle gradient overlay to blend banner seamlessly into the deep background */
.surface-banner::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 50%;
    background: linear-gradient(to bottom, transparent, var(--bg-deep));
}

.profile-container {
    max-width: 650px;
    margin: -80px auto 0; /* Pulls profile up into the banner */
    padding: 0 20px;
    position: relative;
    z-index: 2;
    text-align: center;
}

.profile-pic {
    width: 160px;
    height: 160px;
    border-radius: 50%;
    border: 4px solid var(--bg-deep);
    object-fit: cover;
    background-color: var(--bg-surface);
    box-shadow: 0 12px 40px rgba(0,0,0,0.6);
    margin-bottom: 24px;
    transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.profile-pic:hover {
    transform: scale(1.03);
}

.identity h1 {
    font-size: 2.2rem;
    font-weight: 600;
    letter-spacing: -0.5px;
    margin-bottom: 8px;
    color: var(--text-main);
}

.subtitle {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    display: block;
    margin-bottom: 30px;
}

/* Updated Social Icon (X) */
.nav-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 24px;
}

.social-icon {
    display: inline-flex;
    color: var(--text-muted);
    transition: all 0.2s ease;
}

.social-icon svg {
    width: 22px;
    height: 22px;
    fill: currentColor;
}

.social-icon:hover {
    color: var(--text-main);
    transform: translateY(-2px); /* Slight lift effect */
}

/* =========================================
   4. THE FEED (Clean & Focused)
   ========================================= */
main {
    max-width: 650px;
    margin: 0 auto;
    padding: 0 20px 80px;
}

.feed-stream {
    display: flex;
    flex-direction: column;
    gap: 80px;
}

.post-card {
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 32px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    transition: border-color 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
    animation: fadeInUp 0.8s ease-out forwards;
    opacity: 0; /* Handled by animation */
}

.post-card:hover {
    border-color: rgba(255, 255, 255, 0.1);
    box-shadow: 0 12px 48px rgba(0, 0, 0, 0.4);
    transform: translateY(-2px);
}

/* Animation to stagger post load slightly */
.post-card:nth-child(1) { animation-delay: 0.1s; }
.post-card:nth-child(2) { animation-delay: 0.2s; }
.post-card:nth-child(3) { animation-delay: 0.3s; }
.post-card:nth-child(4) { animation-delay: 0.4s; }

.post-header {
    margin-bottom: 24px;
}

.post-date {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

.post-image {
    width: 100%;
    border-radius: 8px;
    aspect-ratio: 1/1; /* Keeps visuals perfectly square */
    object-fit: cover;
    margin-bottom: 24px;
    border: 1px solid rgba(255,255,255,0.03);
    
    /* Visual Peace / Lazy Loading Integration */
    opacity: 0;
    filter: blur(10px);
    transition: opacity 1s ease, filter 1s ease;
    background-color: var(--bg-surface);
}

.post-image.loaded {
    opacity: 1;
    filter: blur(0);
}

.post-caption {
    font-size: 1.15rem;
    color: var(--text-main);
    line-height: 1.7;
    font-weight: 300;
}

/* =========================================
   5. FOOTER
   ========================================= */
footer {
    border-top: 1px solid var(--glass-border);
    padding: 40px 20px;
    text-align: center;
}

.footer-content p {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-muted);
    opacity: 0.7;
}

/* =========================================
   6. ANIMATIONS
   ========================================= */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

/* =========================================
   7. MOBILE OPTIMIZATION
   ========================================= */
@media (max-width: 600px) {
    .surface-banner { 
        height: 25vh; 
        min-height: 200px;
    }
    
    .profile-container { 
        margin-top: -60px; 
    }
    
    .profile-pic { 
        width: 120px; 
        height: 120px; 
        border-width: 3px; 
        margin-bottom: 16px;
    }
    
    .identity h1 { 
        font-size: 1.8rem; 
    }
    
    .subtitle {
        font-size: 0.75rem;
        margin-bottom: 24px;
    }
    
    .feed-stream { 
        gap: 40px; 
    }
    
    .post-card { 
        padding: 20px; 
        border-radius: 8px; 
    }
    
    .post-caption { 
        font-size: 1.05rem; 
    }
}