/* ============================== */
/* PORTFOLIO PAGE STYLES          */
/* ============================== */

:root {
    --bg-dark: #1A0A04;
    --bg-section: #120702;
    --beauty-brass: #441004;
    --ancient-bronze: #79380B;
    --cobre: #AD6D15;
    --gilded-bronze: #C97E3C;
    --golden-glamor: #EFBB55;
    --lustrous-gold: #F3C17D;
    --light-scatter: #FEE39F;
    --shining-side: #FBF5D2;
    --beige-radiance: #FAE2C8;
    --deep-cocoa: #8A4E36;

    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;
    --font-accent: 'Playfair Display', serif;
}

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

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-dark);
    color: var(--beige-radiance);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
}

/* ============================== */
/* AMBIENT LIGHTS                 */
/* ============================== */
.ambient-light {
    position: fixed;
    border-radius: 50%;
    filter: blur(150px);
    z-index: -1;
    opacity: 0.25;
    pointer-events: none;
}

.light-a {
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, var(--ancient-bronze), transparent 70%);
    top: -200px;
    left: -200px;
    animation: ambientFloat 15s infinite ease-in-out alternate;
}

.light-b {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, var(--cobre), transparent 70%);
    bottom: -200px;
    right: -200px;
    animation: ambientFloat 12s infinite ease-in-out alternate-reverse;
}

@keyframes ambientFloat {
    0% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(40px, 40px) scale(1.1); }
    100% { transform: translate(-30px, 60px) scale(0.95); }
}

/* ============================== */
/* STICKY NAVIGATION              */
/* ============================== */
.sticky-nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 3%;
    background: rgba(26, 10, 4, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(239, 187, 85, 0.1);
    transition: all 0.4s ease;
}

.sticky-nav.scrolled {
    padding: 0.7rem 3%;
    background: rgba(18, 7, 2, 0.95);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.5);
}

.nav-logo {
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.4rem;
    color: var(--shining-side);
    text-decoration: none;
    letter-spacing: 2px;
    flex-shrink: 0;
}

.nav-links {
    display: flex;
    gap: 0.3rem;
    flex-wrap: wrap;
    justify-content: center;
}

.nav-link {
    color: var(--gilded-bronze);
    text-decoration: none;
    font-size: 0.82rem;
    font-weight: 500;
    padding: 0.4rem 0.8rem;
    border-radius: 50px;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.nav-link:hover,
.nav-link.active {
    color: var(--bg-dark);
    background: var(--golden-glamor);
}

.nav-back-btn {
    color: var(--lustrous-gold);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border: 1px solid rgba(239, 187, 85, 0.3);
    border-radius: 50px;
    transition: all 0.3s ease;
    white-space: nowrap;
    flex-shrink: 0;
}

.nav-back-btn:hover {
    background: var(--golden-glamor);
    color: var(--bg-dark);
    border-color: var(--golden-glamor);
}

/* ============================== */
/* HERO                           */
/* ============================== */
.portfolio-hero {
    position: relative;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
    background: linear-gradient(135deg, var(--bg-dark) 0%, var(--beauty-brass) 50%, var(--bg-dark) 100%);
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at center, transparent 0%, var(--bg-dark) 75%);
    z-index: 1;
}

.hero-inner {
    position: relative;
    z-index: 2;
    padding: 2rem;
}

.hero-label {
    font-family: var(--font-heading);
    font-size: 0.9rem;
    font-weight: 300;
    text-transform: uppercase;
    letter-spacing: 8px;
    color: var(--gilded-bronze);
    margin-bottom: 1rem;
}

.hero-title {
    font-family: var(--font-accent);
    font-size: clamp(3rem, 8vw, 7rem);
    font-weight: 700;
    background: linear-gradient(to right, var(--shining-side), var(--golden-glamor), var(--lustrous-gold));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    line-height: 1.1;
    margin-bottom: 1rem;
}

.hero-author {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 300;
    color: var(--beige-radiance);
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 2rem;
}

.hero-divider {
    width: 80px;
    height: 2px;
    background: linear-gradient(to right, transparent, var(--golden-glamor), transparent);
    margin: 0 auto 2rem auto;
}

.hero-categories {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.8rem;
    font-size: 0.85rem;
    color: var(--gilded-bronze);
    font-weight: 300;
}

.dot {
    color: var(--cobre);
}

.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    text-align: center;
}

.scroll-indicator span {
    display: block;
    font-size: 0.7rem;
    color: var(--gilded-bronze);
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 0.8rem;
}

.scroll-line {
    width: 1px;
    height: 40px;
    background: linear-gradient(to bottom, var(--golden-glamor), transparent);
    margin: 0 auto;
    animation: scrollPulse 2s infinite ease-in-out;
}

@keyframes scrollPulse {
    0%, 100% { opacity: 0.3; transform: scaleY(1); }
    50% { opacity: 1; transform: scaleY(1.3); }
}

/* ============================== */
/* ABOUT SECTION                  */
/* ============================== */
.about-section {
    padding: 6rem 5%;
    max-width: 1300px;
    margin: 0 auto;
}

.about-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.about-card {
    background: rgba(26, 10, 4, 0.6);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(239, 187, 85, 0.1);
    border-radius: 16px;
    padding: 2.5rem 2rem;
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
}

.about-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(to right, var(--golden-glamor), var(--cobre));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.5s ease;
}

.about-card:hover::before {
    transform: scaleX(1);
}

.about-card:hover {
    transform: translateY(-5px);
    border-color: rgba(239, 187, 85, 0.25);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.about-number {
    font-family: var(--font-accent);
    font-size: 3rem;
    font-weight: 700;
    color: rgba(239, 187, 85, 0.15);
    margin-bottom: 1rem;
    line-height: 1;
}

.about-card h3 {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--shining-side);
    margin-bottom: 0.8rem;
}

.about-card p {
    font-size: 0.92rem;
    color: var(--beige-radiance);
    opacity: 0.8;
    line-height: 1.7;
}

/* ============================== */
/* PROJECT SECTIONS               */
/* ============================== */
.project-section {
    padding: 4rem 5%;
    max-width: 1300px;
    margin: 0 auto;
}

.project-section:nth-child(even) {
    /* subtle alternation */
}

/* Section Header */
.section-header {
    text-align: center;
    margin-bottom: 4rem;
    padding-top: 80px; /* offset for sticky nav */
    margin-top: -80px;
}

.section-tag {
    display: inline-block;
    font-family: var(--font-heading);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 4px;
    color: var(--cobre);
    margin-bottom: 0.8rem;
    padding: 0.4rem 1.2rem;
    border: 1px solid rgba(173, 109, 21, 0.3);
    border-radius: 50px;
}

.section-title {
    font-family: var(--font-accent);
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 700;
    background: linear-gradient(to right, var(--shining-side), var(--lustrous-gold));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 0.5rem;
}

.section-subtitle {
    font-family: var(--font-heading);
    font-size: 1rem;
    color: var(--gilded-bronze);
    font-weight: 300;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.section-line {
    width: 60px;
    height: 2px;
    background: linear-gradient(to right, var(--golden-glamor), var(--cobre));
    margin: 1rem auto 0 auto;
}

/* Project Block */
.project-block {
    margin-bottom: 5rem;
    padding-bottom: 5rem;
    border-bottom: 1px solid rgba(239, 187, 85, 0.08);
}

.project-block:last-child {
    border-bottom: none;
}

.project-info {
    margin-bottom: 2rem;
}

.project-type {
    display: inline-block;
    font-family: var(--font-heading);
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: var(--golden-glamor);
    background: rgba(239, 187, 85, 0.1);
    padding: 0.35rem 1rem;
    border-radius: 50px;
    margin-bottom: 0.8rem;
}

.project-name {
    font-family: var(--font-accent);
    font-size: clamp(1.5rem, 3vw, 2.2rem);
    font-weight: 700;
    color: var(--shining-side);
    margin-bottom: 0.5rem;
}

.project-scope {
    font-size: 0.9rem;
    color: var(--gilded-bronze);
    font-weight: 300;
    line-height: 1.6;
}

/* Gallery Layouts */
.project-gallery {
    display: grid;
    gap: 1rem;
    margin-bottom: 1rem;
}

.project-gallery.single {
    grid-template-columns: 1fr;
}

.project-gallery.masonry-2 {
    grid-template-columns: repeat(2, 1fr);
}

.project-gallery.masonry-3 {
    grid-template-columns: repeat(3, 1fr);
}

.gallery-item {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    background: var(--bg-section);
    border: 1px solid rgba(239, 187, 85, 0.08);
    transition: all 0.4s ease;
}

.gallery-item::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(26, 10, 4, 0.8) 0%, transparent 50%);
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.gallery-item:hover::after {
    opacity: 1;
}

.gallery-item:hover {
    transform: translateY(-4px);
    border-color: rgba(239, 187, 85, 0.2);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.5);
}

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

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    background-color: #ffffff;
    transition: transform 0.5s ease;
}

.gallery-item.featured img {
    min-height: 400px;
}

.img-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 1rem 1.2rem;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--shining-side);
    z-index: 2;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.4s ease;
    letter-spacing: 1px;
}

.gallery-item:hover .img-caption {
    opacity: 1;
    transform: translateY(0);
}

/* ============================== */
/* FOOTER                         */
/* ============================== */
.portfolio-footer {
    text-align: center;
    padding: 8rem 5%;
    border-top: 1px solid rgba(239, 187, 85, 0.08);
}

.footer-inner {
    max-width: 600px;
    margin: 0 auto;
}

.footer-label {
    font-family: var(--font-heading);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 6px;
    color: var(--cobre);
    margin-bottom: 1rem;
}

.footer-title {
    font-family: var(--font-accent);
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 700;
    background: linear-gradient(to right, var(--shining-side), var(--golden-glamor));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 1.5rem;
}

.footer-divider {
    width: 60px;
    height: 2px;
    background: linear-gradient(to right, transparent, var(--golden-glamor), transparent);
    margin: 0 auto 1.5rem auto;
}

.footer-name {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--shining-side);
    margin-bottom: 0.3rem;
}

.footer-role {
    font-size: 0.9rem;
    color: var(--gilded-bronze);
    margin-bottom: 2.5rem;
}

/* Premium Button */
.btn-premium {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: linear-gradient(135deg, var(--golden-glamor), var(--gilded-bronze));
    color: var(--bg-dark);
    text-decoration: none;
    padding: 0.8rem 1.5rem;
    border-radius: 50px;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(239, 187, 85, 0.3);
    position: relative;
    overflow: hidden;
}

.btn-premium::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transition: all 0.5s ease;
}

.btn-premium:hover::before {
    left: 100%;
}

.btn-premium:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(239, 187, 85, 0.5);
}

.btn-large {
    padding: 1rem 2.5rem;
    font-size: 1.05rem;
}

/* ============================== */
/* LIGHTBOX                       */
/* ============================== */
.lightbox {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(10, 5, 2, 0.95);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s ease;
    cursor: zoom-out;
}

.lightbox.active {
    opacity: 1;
    visibility: visible;
}

.lightbox img {
    max-width: 90vw;
    max-height: 85vh;
    border-radius: 8px;
    background-color: #ffffff;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.7);
    transition: transform 0.4s ease;
}

.lightbox.active img {
    transform: scale(1);
}

.lightbox-close {
    position: absolute;
    top: 1.5rem;
    right: 2rem;
    background: none;
    border: none;
    color: var(--shining-side);
    font-size: 2.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10000;
    line-height: 1;
}

.lightbox-close:hover {
    color: var(--golden-glamor);
    transform: rotate(90deg);
}

#lightbox-caption {
    margin-top: 1rem;
    font-size: 0.9rem;
    color: var(--gilded-bronze);
    letter-spacing: 1px;
}

/* ============================== */
/* REVEAL ANIMATION               */
/* ============================== */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

.reveal-child {
    opacity: 0;
    transform: translateY(25px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.visible .reveal-child:nth-child(1) { transition-delay: 0.1s; opacity: 1; transform: translateY(0); }
.reveal.visible .reveal-child:nth-child(2) { transition-delay: 0.25s; opacity: 1; transform: translateY(0); }
.reveal.visible .reveal-child:nth-child(3) { transition-delay: 0.4s; opacity: 1; transform: translateY(0); }

/* ============================== */
/* RESPONSIVE                     */
/* ============================== */
@media (max-width: 900px) {
    .nav-links {
        display: none;
    }

    .project-gallery.masonry-3 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .project-gallery.masonry-2,
    .project-gallery.masonry-3 {
        grid-template-columns: 1fr;
    }

    .gallery-item.featured img {
        min-height: 250px;
    }

    .about-grid {
        grid-template-columns: 1fr;
    }

    .sticky-nav {
        padding: 0.8rem 4%;
    }
}
