/* --- VARIABLES --- */
:root {
    --bg-color: #000000;
    --text-color: #FFFFFF;
    --text-muted: #B0B0B0;
    --accent-blue: #0038FF;
    
    /* 
       UPDATED FONTS: 
       1. Tries to use 'Aether' first.
       2. Falls back to 'Outfit' (Google Font) which looks very similar.
    */
    --font-heading: 'Aether', 'Outfit', sans-serif;
    --font-body: 'Aether', 'Outfit', sans-serif;
    
    --nav-height: 80px;
}

/* --- RESET & GLOBAL --- */
html {
    scroll-behavior: smooth;
}

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

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-body);
    font-weight: 300;
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

a { text-decoration: none; color: inherit; transition: opacity 0.3s ease; }
a:hover { opacity: 0.7; }
ul { list-style: none; }
img { display: block; width: 100%; height: auto; }

/* --- HEADER --- */
header {
    position: fixed;
    top: 0;
    width: 100%;
    height: var(--nav-height);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 50px;
    background-color: rgba(0, 0, 0, 0.95);
    z-index: 1000;
    border-bottom: 1px solid #1a1a1a;
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.4rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.nav-links { display: flex; gap: 30px; }
.nav-links a {
    font-size: 0.9rem;
    font-weight: 400;
    color: #ccc;
    text-transform: uppercase;
    letter-spacing: 1px;
}
.nav-links a.active { color: #fff; }

/* --- HERO SECTION --- */
.hero-wrapper {
    position: relative;
    min-height: 100vh;
    width: 100%;
    background: linear-gradient(180deg, #000000 0%, #000000 60%, var(--accent-blue) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 100px 12px 12px 12px; 
}

.hero-container {
    width: 100%;
    height: 80vh; 
    max-width: none; 
    position: relative;
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    grid-template-rows: repeat(6, 1fr);
}

/* Image Layer */
.hero-image-container {
    grid-column: 1 / -1; 
    grid-row: 1 / -1;
    z-index: 1;
    width: 100%;
    height: 100%;
    overflow: hidden;
    background-color: #111;
}

.hero-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
}

/* Blue Box Layer */
.hero-content-box {
    grid-column: 1 / 6; 
    grid-row: 4 / 7; 
    z-index: 2; 

    background-color: rgba(0, 56, 255, 0.6); 
    backdrop-filter: blur(10px); 
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);

    margin-left: 60px;
    margin-bottom: 60px;
    align-self: end; 

    padding: 50px 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    
    height: auto;
    min-height: 350px; 
    position: relative;
}

/* Arrow Decoration */
.hero-content-box::after {
    content: '»»»';
    position: absolute;
    top: 30px;
    right: 30px;
    font-size: 1.2rem;
    letter-spacing: -2px;
    opacity: 0.8;
}

.hero-content-box h1 {
    font-family: var(--font-heading);
    font-size: clamp(2rem, 3vw, 3.5rem);
    line-height: 1.1;
    font-weight: 600;
    margin-bottom: auto; 
    padding-top: 10px;
}

.hero-text { margin-top: 20px; }
.hero-text p {
    font-size: 1rem;
    margin-bottom: 8px;
    font-weight: 400;
    line-height: 1.6;
}

/* --- PORTFOLIO INTRO TEXT --- */
.portfolio-intro {
    text-align: center;
    padding: 120px 20px 60px 20px; 
    max-width: 800px;
    margin: 0 auto;
}

.portfolio-intro h2 {
    font-family: var(--font-heading);
    font-size: 3.5rem;
    font-weight: 400;
    margin-bottom: 25px;
    color: var(--text-color);
}

.portfolio-intro p {
    font-family: var(--font-body);
    font-size: 1.1rem;
    color: var(--text-color);
    line-height: 1.6;
    max-width: 650px;
    margin: 0 auto;
}

/* --- GALLERY SECTION --- */
.gallery-section {
    width: 100%;
    max-width: none;
    padding: 0 12px 100px 12px;
    margin: 0;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px; 
    width: 100%;
}

.gallery-item {
    position: relative;
    aspect-ratio: 1 / 1; 
    overflow: hidden;
    cursor: pointer;
    width: 100%;
    display: block;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
    display: block;
}

.gallery-item:hover img { transform: scale(1.05); }

.item-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}
.gallery-item:hover .item-overlay { opacity: 1; }
.item-overlay span {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    text-transform: uppercase;
    letter-spacing: 2px;
}

/* --- BIO SECTION --- */
.bio-section {
    /* 1. Dark Gray Background (matches screenshot) */
    background-color: #1f1f1f; 
    padding: 150px 20px;
    color: #ffffff;
    width: 100%;
}

/* The Title "Bio" */
.bio-section h2 {
    font-family: var(--font-heading);
    font-size: 4.5rem; /* Larger title */
    font-weight: 400;
    margin-bottom: 70px;
    text-align: center; /* Title stays centered */
    letter-spacing: -1px;
}

/* The Text Container */
.bio-content {
    max-width: 680px; /* Constrains width for readability */
    margin: 0 auto;   /* Centers the block on the screen */
    
    /* 2. Left Alignment for text paragraphs */
    text-align: left; 
}

.bio-content p {
    font-family: var(--font-body);
    font-size: 1.2rem;
    color: #ffffff; /* Pure white text */
    margin-bottom: 35px; /* Spacing between paragraphs */
    line-height: 1.5;
    font-weight: 400; /* Regular weight, not thin */
}

/* --- FOOTER --- */
footer {
    text-align: center;
    padding: 60px 20px;
    background-color: #000;
    color: #666;
    font-size: 0.85rem;
    border-top: 1px solid #222;
}

/* --- PROJECT PAGE STYLES --- */
.project-intro { padding: 150px 20px 80px 20px; text-align: center; max-width: 900px; margin: 0 auto; }
.project-intro h1 { font-family: var(--font-heading); font-size: 4rem; font-weight: 400; margin-bottom: 40px; }
.project-meta { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid #333; border-bottom: 1px solid #333; padding: 20px 0; text-align: left; }
.meta-item h3 { font-size: 0.8rem; text-transform: uppercase; color: var(--text-muted); margin-bottom: 5px; letter-spacing: 1px; }
.meta-item p { font-size: 1.1rem; font-weight: 400; }
.project-images { max-width: 1000px; margin: 0 auto; padding: 0 20px 100px 20px; display: flex; flex-direction: column; gap: 80px; }
.project-nav-buttons { max-width: 1000px; margin: 0 auto; display: flex; justify-content: space-between; padding: 40px 20px; border-top: 1px solid #333; }
.nav-btn { display: flex; align-items: center; gap: 10px; font-size: 1rem; font-weight: 600; text-transform: uppercase; }

/* --- RESPONSIVE MEDIA QUERIES --- */
@media (max-width: 1024px) {
    .hero-content-box { grid-column: 1 / 8; } 
    .gallery-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    .hero-wrapper {
        padding: 80px 12px 12px 12px;
        min-height: auto;
    }
    .hero-container {
        display: flex;
        flex-direction: column;
        height: auto;
    }
    .hero-image-container {
        height: 50vh;
        width: 100%;
    }
    .hero-content-box {
        width: 100%;
        margin-left: 0;
        margin-bottom: 0;
        margin-top: -50px; 
        padding: 30px;
        min-height: auto;
        background-color: rgba(0, 56, 255, 0.9);
    }
    .gallery-grid { grid-template-columns: 1fr; gap: 12px; }
    .portfolio-intro h2 { font-size: 2.5rem; }
    .project-meta { grid-template-columns: 1fr; gap: 20px; text-align: center; }
}

/* --- PROJECT MASONRY GALLERY (The Wix "Mosaic" Look) --- */
.masonry-grid {
    column-count: 3; /* 3 Columns on desktop */
    column-gap: 20px; /* Space between columns */
    width: 100%;
    padding: 0 20px; /* Slight padding from edges */
    max-width: 1800px; /* Allow it to get very wide */
    margin: 0 auto;
}

.masonry-item {
    break-inside: avoid; /* Prevents image from being cut in half */
    margin-bottom: 20px; /* Space below each image */
    position: relative;
    cursor: pointer;
}

.masonry-item img {
    width: 100%;
    height: auto;
    display: block;
    transition: opacity 0.3s ease;
}

.masonry-item:hover img {
    opacity: 0.8;
}

/* --- LIGHTBOX (Full Screen View) --- */
.lightbox {
    position: fixed;
    z-index: 9999;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.95); /* Deep black background */
    display: none; /* Hidden by default */
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.lightbox.active {
    display: flex;
    opacity: 1;
}

.lightbox-content {
    /* 1. Reset global image styles to prevent stretching */
    width: auto;
    height: auto;
    
    /* 2. Constrain it within the screen */
    max-width: 90%;
    max-height: 90vh;
    
    /* 3. Ensure aspect ratio is preserved */
    object-fit: contain;
    
    box-shadow: 0 0 20px rgba(0,0,0,0.5);
    user-select: none;
}

/* Lightbox Controls */
.lightbox-close {
    position: absolute;
    top: 20px;
    right: 30px;
    color: #fff;
    font-size: 2.5rem;
    cursor: pointer;
    z-index: 10000;
}

.lightbox-prev,
.lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: #fff;
    font-size: 3rem;
    cursor: pointer;
    padding: 20px;
    user-select: none;
    transition: color 0.3s;
}

.lightbox-prev:hover, .lightbox-next:hover, .lightbox-close:hover {
    color: var(--accent-blue);
}

.lightbox-prev { left: 20px; }
.lightbox-next { right: 20px; }

.lightbox-caption {
    position: absolute;
    top: 20px;
    left: 30px;
    color: #fff;
    font-family: var(--font-body);
    font-size: 1.1rem;
}



/* --- RESPONSIVE PROJECT --- */
@media (max-width: 1024px) {
    .masonry-grid { column-count: 2; }
}

@media (max-width: 600px) {
    .masonry-grid { column-count: 1; }
    .lightbox-prev, .lightbox-next { font-size: 2rem; padding: 10px; }
}

/* --- CONTACT SECTION --- */
.contact-section {
    padding: 100px 20px;
    background-color: #000; /* Keeps it seamless with the page */
    color: var(--text-color);
}

.contact-container {
    max-width: 600px;
    margin: 0 auto;
    text-align: center;
}

.contact-container h2 {
    font-family: var(--font-heading);
    font-size: 3rem;
    font-weight: 400;
    margin-bottom: 20px;
}

.contact-container p {
    font-family: var(--font-body);
    color: var(--text-muted);
    margin-bottom: 50px;
}

/* Form Styling */
.form-group {
    margin-bottom: 30px;
}

input, textarea {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 1px solid #333;
    padding: 15px 0;
    color: #fff;
    font-family: var(--font-body);
    font-size: 1rem;
    transition: border-color 0.3s ease;
    border-radius: 0; /* Removes default IOS styling */
}

input:focus, textarea:focus {
    outline: none;
    border-bottom: 1px solid var(--accent-blue);
}

textarea {
    resize: vertical; /* Allows resizing vertically only */
}

/* Submit Button */
.submit-btn {
    background-color: transparent;
    color: #fff;
    border: 1px solid #fff;
    padding: 12px 40px;
    font-family: var(--font-heading);
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 10px;
}

.submit-btn:hover {
    background-color: #fff;
    color: #000;
}

#form-result {
    margin-top: 20px;
    font-size: 0.9rem;
    min-height: 20px;
}