/* ========================================
   LENS — 极简黑白摄影作品集
   ======================================== */

/* --- Reset & Base --- */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --black: #0a0a0a;
    --white: #f5f5f5;
    --gray-100: #e8e8e8;
    --gray-200: #d0d0d0;
    --gray-400: #888;
    --gray-600: #555;
    --gray-800: #222;
    --font-serif: 'Cormorant Garamond', 'Georgia', serif;
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

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

a {
    color: inherit;
    text-decoration: none;
}

img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* --- Loader --- */
#loader {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: var(--black);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 24px;
    transition: opacity 0.8s var(--ease), visibility 0.8s;
}

#loader.hidden {
    opacity: 0;
    visibility: hidden;
}

.loader-text {
    font-family: var(--font-serif);
    font-size: 3rem;
    font-weight: 300;
    letter-spacing: 0.4em;
    color: var(--white);
    animation: fadeInUp 1s var(--ease);
}

.loader-line {
    width: 60px;
    height: 1px;
    background: var(--gray-600);
    position: relative;
    overflow: hidden;
}

.loader-line::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: var(--white);
    animation: loaderSlide 1.2s var(--ease) infinite;
}

@keyframes loaderSlide {
    to { left: 100%; }
}

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

/* --- Navigation --- */
#navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    padding: 20px 40px;
    transition: background 0.4s, backdrop-filter 0.4s, padding 0.4s;
}

#navbar.scrolled {
    background: rgba(10, 10, 10, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 14px 40px;
}

.nav-inner {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-logo {
    font-family: var(--font-serif);
    font-size: 1.4rem;
    font-weight: 300;
    letter-spacing: 0.25em;
    transition: opacity 0.3s;
}

.nav-logo:hover { opacity: 0.7; }

.nav-dot {
    color: var(--gray-400);
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 40px;
}

.nav-links a {
    font-size: 0.8rem;
    font-weight: 400;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--gray-200);
    position: relative;
    transition: color 0.3s;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--white);
    transition: width 0.4s var(--ease);
}

.nav-links a:hover {
    color: var(--white);
}

.nav-links a:hover::after {
    width: 100%;
}

#menuToggle {
    display: none;
    background: none;
    border: none;
    color: var(--white);
    font-size: 1.6rem;
    cursor: pointer;
    padding: 4px;
}

/* --- Mobile Menu --- */
.mobile-menu {
    position: fixed;
    inset: 0;
    z-index: 99;
    background: rgba(10, 10, 10, 0.97);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 40px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.5s var(--ease), visibility 0.5s;
}

.mobile-menu.active {
    opacity: 1;
    visibility: visible;
}

.mobile-link {
    font-family: var(--font-serif);
    font-size: 2.5rem;
    font-weight: 300;
    letter-spacing: 0.15em;
    color: var(--gray-200);
    transition: color 0.3s, transform 0.3s;
}

.mobile-link:hover {
    color: var(--white);
    transform: translateX(10px);
}

/* --- Hero --- */
#hero {
    position: relative;
    height: 100vh;
    min-height: 600px;
    display: flex;
    align-items: flex-end;
    overflow: hidden;
}

.hero-image {
    position: absolute;
    inset: 0;
}

.hero-image img {
    filter: grayscale(100%) contrast(1.1);
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(10, 10, 10, 0.2) 0%,
        rgba(10, 10, 10, 0.1) 40%,
        rgba(10, 10, 10, 0.7) 80%,
        rgba(10, 10, 10, 1) 100%
    );
}

.hero-content {
    position: relative;
    z-index: 2;
    padding: 0 40px 80px;
    max-width: 1400px;
    margin: 0 auto;
    width: 100%;
}

.hero-eyebrow {
    font-size: 0.75rem;
    font-weight: 400;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--gray-400);
    margin-bottom: 16px;
    opacity: 0;
    transform: translateY(20px);
}

.hero-title {
    font-family: var(--font-serif);
    font-size: clamp(3.5rem, 8vw, 7rem);
    font-weight: 300;
    line-height: 1.05;
    letter-spacing: -0.02em;
    margin-bottom: 20px;
    opacity: 0;
    transform: translateY(30px);
}

.hero-subtitle {
    font-size: 1.05rem;
    font-weight: 300;
    color: var(--gray-200);
    margin-bottom: 48px;
    opacity: 0;
    transform: translateY(20px);
}

.hero-scroll {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 0.75rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--gray-400);
    transition: color 0.3s;
    opacity: 0;
    transform: translateY(20px);
}

.hero-scroll i {
    font-size: 1rem;
    animation: bounceDown 2s var(--ease) infinite;
}

.hero-scroll:hover { color: var(--white); }

@keyframes bounceDown {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(6px); }
}

/* --- Sections --- */
section {
    padding: 120px 40px;
}

.section-label {
    font-size: 0.7rem;
    font-weight: 400;
    letter-spacing: 0.35em;
    text-transform: uppercase;
    color: var(--gray-400);
    margin-bottom: 20px;
}

.section-heading {
    font-family: var(--font-serif);
    font-size: clamp(2rem, 4vw, 3.2rem);
    font-weight: 300;
    line-height: 1.2;
    letter-spacing: -0.01em;
    margin-bottom: 32px;
}

/* --- About --- */
#about {
    max-width: 1400px;
    margin: 0 auto;
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.about-image {
    aspect-ratio: 4/5;
    overflow: hidden;
    position: relative;
}

.about-image img {
    filter: grayscale(100%);
    transition: transform 0.8s var(--ease);
}

.about-image:hover img {
    transform: scale(1.04);
}

.about-body {
    font-size: 0.95rem;
    font-weight: 300;
    line-height: 1.8;
    color: var(--gray-200);
    margin-bottom: 20px;
}

.about-stats {
    display: flex;
    gap: 48px;
    margin-top: 40px;
    padding-top: 32px;
    border-top: 1px solid var(--gray-800);
}

.stat-num {
    display: block;
    font-family: var(--font-serif);
    font-size: 2.2rem;
    font-weight: 300;
    color: var(--white);
    line-height: 1;
    margin-bottom: 8px;
}

.stat-label {
    font-size: 0.72rem;
    font-weight: 400;
    letter-spacing: 0.1em;
    color: var(--gray-400);
    text-transform: uppercase;
}

/* --- Portfolio --- */
#portfolio {
    max-width: 1400px;
    margin: 0 auto;
}

.portfolio-header {
    text-align: center;
    margin-bottom: 64px;
}

.portfolio-intro {
    font-size: 0.95rem;
    font-weight: 300;
    color: var(--gray-400);
    max-width: 500px;
    margin: 0 auto;
}

/* --- Gallery Grid --- */
.gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-auto-rows: 300px;
    gap: 12px;
}

.gallery-item {
    position: relative;
    overflow: hidden;
    cursor: pointer;
    background: var(--gray-800);
}

.gallery-item img {
    filter: grayscale(100%);
    transition: filter 0.6s var(--ease), transform 0.8s var(--ease);
}

.gallery-item:hover img {
    filter: grayscale(0%);
    transform: scale(1.06);
}

.gallery-tall {
    grid-row: span 2;
}

.gallery-wide {
    grid-column: span 2;
}

.gallery-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 24px;
    background: linear-gradient(to top, rgba(10,10,10,0.85) 0%, transparent 100%);
    transform: translateY(20px);
    opacity: 0;
    transition: all 0.5s var(--ease);
}

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

.gallery-title {
    display: block;
    font-family: var(--font-serif);
    font-size: 1.2rem;
    font-weight: 300;
    margin-bottom: 4px;
}

.gallery-meta {
    display: block;
    font-size: 0.7rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--gray-400);
}

/* --- Services --- */
#services {
    max-width: 1400px;
    margin: 0 auto;
}

.services-header {
    text-align: center;
    margin-bottom: 64px;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.service-card {
    padding: 40px 32px;
    border: 1px solid var(--gray-800);
    transition: border-color 0.4s, background 0.4s;
}

.service-card:hover {
    border-color: var(--gray-600);
    background: rgba(255,255,255,0.02);
}

.service-card i {
    font-size: 2rem;
    color: var(--gray-400);
    margin-bottom: 24px;
    display: block;
    transition: color 0.3s;
}

.service-card:hover i {
    color: var(--white);
}

.service-card h3 {
    font-family: var(--font-serif);
    font-size: 1.3rem;
    font-weight: 300;
    margin-bottom: 14px;
}

.service-card p {
    font-size: 0.85rem;
    font-weight: 300;
    line-height: 1.7;
    color: var(--gray-400);
}

/* --- Quote --- */
#quote {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
    padding: 100px 40px;
}

#quote blockquote p {
    font-family: var(--font-serif);
    font-size: clamp(1.4rem, 3vw, 2.2rem);
    font-weight: 300;
    font-style: italic;
    line-height: 1.5;
    color: var(--gray-200);
    margin-bottom: 24px;
}

#quote cite {
    font-style: normal;
    font-size: 0.75rem;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: var(--gray-600);
}

/* --- Contact --- */
#contact {
    text-align: center;
    max-width: 1400px;
    margin: 0 auto;
    padding-bottom: 80px;
}

.contact-heading {
    margin-bottom: 40px;
}

.contact-cta {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-family: var(--font-serif);
    font-size: clamp(1.2rem, 2.5vw, 1.8rem);
    font-weight: 300;
    padding: 20px 0;
    border-bottom: 1px solid var(--gray-600);
    transition: border-color 0.3s, gap 0.3s;
}

.contact-cta:hover {
    border-color: var(--white);
    gap: 18px;
}

.contact-info {
    display: flex;
    justify-content: center;
    gap: 48px;
    margin-top: 40px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.85rem;
    font-weight: 300;
    color: var(--gray-400);
}

.contact-item i {
    font-size: 1.1rem;
    color: var(--gray-600);
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 32px;
    margin-top: 40px;
}

.social-links a {
    font-size: 1.5rem;
    color: var(--gray-600);
    transition: color 0.3s, transform 0.3s;
}

.social-links a:hover {
    color: var(--white);
    transform: translateY(-2px);
}

/* --- Footer --- */
footer {
    border-top: 1px solid var(--gray-800);
    padding: 32px 40px;
}

.footer-inner {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.footer-logo {
    font-family: var(--font-serif);
    font-size: 1rem;
    letter-spacing: 0.2em;
    color: var(--gray-600);
}

.footer-copy {
    font-size: 0.72rem;
    color: var(--gray-600);
    letter-spacing: 0.05em;
}

/* --- Scroll Reveal --- */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}

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

/* --- Lightbox --- */
.lightbox {
    position: fixed;
    inset: 0;
    z-index: 200;
    background: rgba(10,10,10,0.96);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.5s var(--ease), visibility 0.5s;
    cursor: zoom-out;
}

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

.lightbox img {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
    filter: grayscale(100%);
    transition: filter 0.6s var(--ease);
}

.lightbox-close {
    position: absolute;
    top: 32px;
    right: 32px;
    background: none;
    border: none;
    color: var(--gray-400);
    font-size: 2rem;
    cursor: pointer;
    transition: color 0.3s;
    padding: 8px;
}

.lightbox-close:hover { color: var(--white); }

/* ========================================
   Responsive
   ======================================== */

@media (max-width: 1024px) {
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .gallery {
        grid-auto-rows: 260px;
    }
}

@media (max-width: 768px) {
    section { padding: 80px 24px; }
    #navbar { padding: 16px 24px; }
    #navbar.scrolled { padding: 12px 24px; }

    .nav-links { display: none; }
    #menuToggle { display: block; }

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

    .about-stats {
        gap: 32px;
    }

    .gallery {
        grid-template-columns: repeat(2, 1fr);
        grid-auto-rows: 220px;
    }

    .gallery-wide { grid-column: span 2; }
    .gallery-tall { grid-row: span 1; }

    .services-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .service-card {
        padding: 28px 24px;
    }

    .contact-info {
        flex-direction: column;
        align-items: center;
        gap: 16px;
    }

    .footer-inner {
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }

    .hero-content {
        padding: 0 24px 60px;
    }
}

@media (max-width: 480px) {
    .gallery {
        grid-template-columns: 1fr;
        grid-auto-rows: 280px;
    }
    .gallery-wide { grid-column: span 1; }

    .about-stats {
        flex-direction: column;
        gap: 20px;
    }
}
