:root {
    --bg: #050505;
    --panel: #0d0d0d;
    --panel-2: #121212;
    --text: #f4f1ea;
    --muted: #918f89;
    --line: rgba(255, 255, 255, .13);
    --line-strong: rgba(255, 255, 255, .24);
    --accent: #c8aa72;
    --accent-soft: rgba(200, 170, 114, .16);
    --max: 1440px;
    --ease: cubic-bezier(.22, 1, .36, 1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: Inter, "Helvetica Neue", Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}
body.menu-open { overflow: hidden; }
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; }
button { color: inherit; }
img, video { display: block; max-width: 100%; }
::selection { background: var(--accent); color: #050505; }
.sr-only {
    position: absolute; width: 1px; height: 1px; padding: 0;
    margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0);
    white-space: nowrap; border: 0;
}
.page-noise {
    position: fixed; inset: 0; pointer-events: none; z-index: 90; opacity: .06;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.7'/%3E%3C/svg%3E");
    mix-blend-mode: soft-light;
}
.cursor-glow {
    position: fixed; width: 420px; height: 420px; border-radius: 50%;
    background: radial-gradient(circle, rgba(200,170,114,.11), transparent 68%);
    transform: translate(-50%, -50%); pointer-events: none; z-index: 1;
    opacity: 0; transition: opacity .4s ease;
}
.scroll-progress {
    position: fixed; top: 0; left: 0; right: 0; height: 2px; z-index: 120;
}
.scroll-progress span { display: block; height: 100%; width: 0; background: var(--accent); }

.site-header {
    position: fixed; top: 0; left: 0; right: 0; z-index: 100;
    height: 82px; display: flex; align-items: center; justify-content: space-between;
    padding: 0 clamp(22px, 4vw, 72px);
    transition: background .35s ease, border-color .35s ease, height .35s ease;
    border-bottom: 1px solid transparent;
}
.site-header.is-scrolled {
    height: 68px;
    background: rgba(5, 5, 5, .78);
    backdrop-filter: blur(18px);
    border-color: var(--line);
}
.brand {
    display: inline-flex; align-items: center; gap: 10px;
    font-size: 14px; letter-spacing: .18em; font-weight: 700;
}
.brand-dot {
    width: 8px; height: 8px; border-radius: 50%; background: var(--accent);
    box-shadow: 0 0 20px rgba(200, 170, 114, .7);
}
.site-nav { display: flex; align-items: center; gap: 38px; }
.site-nav a, .admin-header nav a {
    color: var(--muted); font-size: 12px; letter-spacing: .13em; text-transform: uppercase;
    transition: color .2s ease;
}
.site-nav a:hover, .admin-header nav a:hover { color: var(--text); }
.menu-button {
    display: none; border: 0; background: none; width: 44px; height: 44px;
    padding: 13px 8px; cursor: pointer;
}
.menu-button span:not(.sr-only) {
    display: block; height: 1px; background: var(--text); margin: 6px 0;
    transition: transform .3s ease;
}

.hero {
    position: relative; min-height: 100svh; overflow: hidden;
    display: flex; flex-direction: column; justify-content: center;
    padding: 140px clamp(22px, 6vw, 96px) 42px;
    border-bottom: 1px solid var(--line);
}
.hero-grid {
    position: absolute; inset: 0; opacity: .18; pointer-events: none;
    background-image:
        linear-gradient(rgba(255,255,255,.08) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,.08) 1px, transparent 1px);
    background-size: 11vw 11vw;
    mask-image: linear-gradient(to bottom, black, transparent 86%);
}
.hero-orb {
    position: absolute; border-radius: 50%; filter: blur(2px);
    border: 1px solid rgba(255,255,255,.12);
}
.orb-one {
    width: 42vw; height: 42vw; right: -12vw; top: -10vw;
    background: radial-gradient(circle at 35% 35%, rgba(200,170,114,.19), transparent 56%);
    animation: orbit 15s ease-in-out infinite alternate;
}
.orb-two {
    width: 22vw; height: 22vw; right: 19vw; bottom: -8vw;
    background: radial-gradient(circle at 60% 40%, rgba(100,110,130,.16), transparent 58%);
    animation: orbit 11s ease-in-out infinite alternate-reverse;
}
@keyframes orbit {
    to { transform: translate3d(-3vw, 4vw, 0) scale(1.06); }
}
.hero-content { position: relative; z-index: 2; width: min(1120px, 92vw); }
.eyebrow, .section-index {
    margin: 0 0 24px; color: var(--accent); font-size: 11px;
    letter-spacing: .22em; font-weight: 700;
}
.hero-title {
    margin: 0; max-width: 1080px; font-size: clamp(54px, 8.1vw, 142px);
    line-height: .89; letter-spacing: -.065em; font-weight: 540;
}
.hero-title span {
    display: inline-block; opacity: 0; transform: translateY(55px) rotate(2deg);
    animation: titleIn .85s var(--ease) forwards;
}
.hero-title span:nth-child(n) { animation-delay: calc(var(--char, 1) * 20ms); }
@keyframes titleIn { to { opacity: 1; transform: none; } }
.hero-intro {
    max-width: 640px; color: var(--muted); font-size: clamp(16px, 1.4vw, 21px);
    line-height: 1.85; margin: 42px 0 34px;
}
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.button {
    min-height: 52px; display: inline-flex; align-items: center; justify-content: center;
    gap: 22px; padding: 0 24px; border: 1px solid var(--line-strong);
    background: transparent; color: var(--text); font-size: 12px;
    letter-spacing: .1em; text-transform: uppercase; cursor: pointer;
    transition: transform .25s var(--ease), background .25s ease, color .25s ease, border-color .25s ease;
}
.button:hover { transform: translateY(-2px); border-color: var(--text); }
.button-primary { background: var(--text); color: var(--bg); border-color: var(--text); }
.button-primary:hover { background: var(--accent); border-color: var(--accent); }
.button-ghost { background: rgba(255,255,255,.025); }
.hero-meta {
    position: absolute; left: clamp(22px, 6vw, 96px); right: clamp(22px, 6vw, 96px); bottom: 28px;
    display: flex; justify-content: space-between; color: var(--muted);
    font-size: 10px; letter-spacing: .14em; text-transform: uppercase; z-index: 2;
}
.scroll-hint {
    position: absolute; right: clamp(22px, 4vw, 72px); bottom: 22px;
    width: 22px; height: 48px; border: 1px solid var(--line-strong); border-radius: 20px; z-index: 3;
}
.scroll-hint span {
    position: absolute; left: 50%; top: 10px; width: 3px; height: 3px; border-radius: 50%;
    background: var(--accent); transform: translateX(-50%); animation: scrollHint 1.8s infinite;
}
@keyframes scrollHint { 0% { opacity: 0; transform: translate(-50%, 0); } 30% {opacity:1;} 100% {opacity:0; transform: translate(-50%, 20px);} }

.section { padding: clamp(88px, 11vw, 180px) clamp(22px, 6vw, 96px); }
.section-heading {
    display: grid; grid-template-columns: 1.7fr 1fr; align-items: end;
    gap: 60px; max-width: var(--max); margin: 0 auto 70px;
}
.section-heading h2, .about-statement h2, .contact-inner h2 {
    margin: 0; font-size: clamp(50px, 8vw, 128px); line-height: .88;
    letter-spacing: -.06em; font-weight: 520;
}
.section-heading > p {
    max-width: 460px; color: var(--muted); font-size: 16px; line-height: 1.8; margin: 0 0 8px;
}
.works-section { background: #080808; }
.filters {
    max-width: var(--max); margin: 0 auto 36px; display: flex; gap: 8px; flex-wrap: wrap;
}
.filter {
    background: transparent; color: var(--muted); border: 1px solid var(--line);
    padding: 11px 16px; font-size: 10px; letter-spacing: .12em; text-transform: uppercase; cursor: pointer;
}
.filter:hover, .filter.is-active { color: var(--bg); background: var(--text); border-color: var(--text); }
.work-grid {
    max-width: var(--max); margin: 0 auto; display: grid; grid-template-columns: repeat(12, 1fr);
    gap: clamp(28px, 4.5vw, 72px) clamp(16px, 2.2vw, 32px);
}
.work-card { grid-column: span 6; transition-delay: var(--delay); }
.work-card:nth-child(4n + 2), .work-card:nth-child(4n + 3) { transform: translateY(90px); }
.work-card.is-hidden { display: none; }
.work-media {
    position: relative; width: 100%; aspect-ratio: 4 / 5; padding: 0;
    border: 0; overflow: hidden; background: var(--panel); cursor: pointer;
}
.work-media img {
    width: 100%; height: 100%; object-fit: cover;
    transition: transform .8s var(--ease), filter .5s ease;
}
.work-card:hover .work-media img { transform: scale(1.045); filter: contrast(1.04); }
.work-action {
    position: absolute; right: 16px; top: 16px; display: grid; place-items: center;
    min-width: 68px; height: 36px; padding: 0 12px; border-radius: 30px;
    background: rgba(5,5,5,.72); backdrop-filter: blur(12px); font-size: 9px; letter-spacing: .15em;
    opacity: 0; transform: translateY(-8px); transition: .35s var(--ease);
}
.work-card:hover .work-action { opacity: 1; transform: none; }
.play-icon {
    position: absolute; inset: 0; margin: auto; width: 70px; height: 70px;
    border: 1px solid rgba(255,255,255,.45); border-radius: 50%;
    display: grid; place-items: center; background: rgba(5,5,5,.38); backdrop-filter: blur(8px);
    font-size: 16px; padding-left: 3px;
}
.empty-media {
    height: 100%; display: grid; place-items: center;
    background: radial-gradient(circle at 70% 30%, rgba(200,170,114,.25), transparent 35%), #101010;
    color: var(--muted); font-size: 11px; letter-spacing: .2em;
}
.work-copy {
    display: flex; justify-content: space-between; align-items: flex-start;
    gap: 20px; padding: 20px 0 0;
}
.work-copy p { margin: 0 0 7px; color: var(--accent); font-size: 9px; letter-spacing: .18em; text-transform: uppercase; }
.work-copy h3 { margin: 0; font-size: clamp(19px, 2vw, 28px); font-weight: 500; letter-spacing: -.025em; }
.work-copy > span { color: var(--muted); font-size: 11px; }
.work-description { margin: 12px 0 0; color: var(--muted); line-height: 1.7; font-size: 14px; max-width: 88%; }

.about-section { border-top: 1px solid var(--line); }
.about-statement { max-width: var(--max); margin: 0 auto; }
.about-statement em { color: var(--accent); font-weight: inherit; font-style: normal; }
.about-grid {
    max-width: var(--max); margin: 100px auto 0; display: grid; grid-template-columns: 1fr 1fr; gap: 10vw;
}
.about-copy p { margin: 0 0 36px; color: var(--muted); font-size: clamp(18px, 2vw, 30px); line-height: 1.65; }
.about-copy a { display: inline-block; border-bottom: 1px solid var(--line-strong); padding-bottom: 8px; font-size: 14px; }
.capabilities { border-top: 1px solid var(--line); }
.capabilities div {
    display: grid; grid-template-columns: 70px 1fr; align-items: center;
    min-height: 82px; border-bottom: 1px solid var(--line);
}
.capabilities span { color: var(--accent); font-size: 10px; }
.capabilities p { margin: 0; font-size: 18px; }

.files-section { background: #0a0a0a; border-top: 1px solid var(--line); }
.file-list { max-width: var(--max); margin: 0 auto; border-top: 1px solid var(--line); }
.file-row {
    display: grid; grid-template-columns: 1.2fr 1.5fr auto; align-items: center;
    gap: 30px; padding: 26px 0; border-bottom: 1px solid var(--line);
    transition: padding .25s var(--ease), background .25s ease;
}
.file-row:hover { padding-left: 16px; background: rgba(255,255,255,.025); }
.file-row > div { display: flex; align-items: center; gap: 22px; }
.file-row > div span { color: var(--accent); font-size: 9px; letter-spacing: .15em; width: 42px; }
.file-row h3 { margin: 0; font-size: 20px; font-weight: 500; }
.file-row p { margin: 0; color: var(--muted); font-size: 13px; }
.file-row > span { color: var(--muted); font-size: 11px; }
.file-empty { padding: 52px 0; border-bottom: 1px solid var(--line); }
.file-empty span { color: var(--accent); font-size: 10px; letter-spacing: .18em; }
.file-empty p { color: var(--muted); margin: 12px 0 0; }

.contact-section { padding: clamp(100px, 14vw, 220px) 0 0; overflow: hidden; }
.contact-inner { padding: 0 clamp(22px, 6vw, 96px); max-width: calc(var(--max) + 12vw); margin: 0 auto 110px; }
.contact-link {
    display: flex; align-items: center; justify-content: space-between;
    max-width: 680px; margin-top: 56px; border-bottom: 1px solid var(--line-strong);
    padding: 0 0 16px; font-size: clamp(18px, 2.3vw, 34px);
}
.contact-link span { color: var(--accent); }
.contact-marquee { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 20px 0; }
.contact-marquee div { display: flex; width: max-content; animation: marquee 25s linear infinite; }
.contact-marquee span {
    white-space: nowrap; font-size: clamp(28px, 5vw, 78px); letter-spacing: -.04em; padding-right: 20px;
    color: transparent; -webkit-text-stroke: 1px rgba(255,255,255,.28);
}
@keyframes marquee { to { transform: translateX(-33.333%); } }

.site-footer {
    min-height: 100px; display: flex; align-items: center; justify-content: space-between;
    gap: 20px; padding: 0 clamp(22px, 6vw, 96px); color: var(--muted);
    font-size: 10px; letter-spacing: .08em; text-transform: uppercase;
}
.site-footer p { margin: 0; }
.site-footer a:hover { color: var(--text); }

.reveal { opacity: 0; transform: translateY(34px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.reveal.in-view { opacity: 1; transform: none; }
.work-card:nth-child(4n + 2).in-view, .work-card:nth-child(4n + 3).in-view { transform: translateY(90px); }

.lightbox {
    position: fixed; inset: 0; z-index: 200; display: grid; place-items: center;
    padding: 70px clamp(18px, 5vw, 70px); background: rgba(0,0,0,.92); backdrop-filter: blur(16px);
    opacity: 0; visibility: hidden; transition: .35s ease;
}
.lightbox.is-open { opacity: 1; visibility: visible; }
.lightbox-stage { width: min(1180px, 92vw); height: min(78vh, 820px); display: grid; place-items: center; }
.lightbox-stage img, .lightbox-stage video { max-width: 100%; max-height: 100%; object-fit: contain; }
.lightbox-close {
    position: absolute; top: 22px; right: 28px; border: 0; background: none;
    color: white; font-size: 42px; font-weight: 200; cursor: pointer;
}
.lightbox-title { position: absolute; bottom: 20px; left: 50%; transform: translateX(-50%); margin: 0; color: var(--muted); }

/* Admin */
.admin-body { background: #090909; min-height: 100vh; }
.admin-shell { width: min(1440px, 94vw); margin: 0 auto; padding-bottom: 70px; }
.admin-header {
    min-height: 82px; display: flex; align-items: center; justify-content: space-between;
    border-bottom: 1px solid var(--line);
}
.admin-header nav { display: flex; gap: 28px; }
.auth-card {
    width: min(540px, 100%); margin: 12vh auto 0; padding: 42px;
    border: 1px solid var(--line); background: var(--panel);
}
.auth-card h1, .admin-hero h1 { margin: 0; font-size: clamp(38px, 5vw, 72px); letter-spacing: -.05em; font-weight: 520; }
.auth-card > p:not(.section-index), .admin-hero > p:not(.section-index) { color: var(--muted); line-height: 1.7; }
.auth-card form { margin-top: 30px; display: grid; gap: 18px; }
.notice { margin: 18px 0; padding: 14px 18px; border: 1px solid var(--line); font-size: 14px; }
.notice.success { border-color: rgba(85,190,120,.4); background: rgba(85,190,120,.08); }
.notice.error { border-color: rgba(230,90,90,.42); background: rgba(230,90,90,.08); }
.admin-main { padding-top: 80px; }
.admin-hero { margin-bottom: 60px; }
.admin-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.admin-panel { background: var(--panel); border: 1px solid var(--line); padding: clamp(24px, 3vw, 42px); }
.panel-title { display: flex; align-items: baseline; gap: 18px; margin-bottom: 28px; }
.panel-title span { color: var(--accent); font-size: 10px; }
.panel-title h2 { margin: 0; font-size: 26px; font-weight: 520; }
.admin-form { display: grid; gap: 18px; }
.admin-form label, .auth-card label {
    display: grid; gap: 8px; color: var(--muted); font-size: 12px; letter-spacing: .04em;
}
.admin-form input, .admin-form textarea, .admin-form select, .auth-card input {
    width: 100%; color: var(--text); background: #090909; border: 1px solid var(--line);
    padding: 14px 15px; outline: none; border-radius: 0;
}
.admin-form input:focus, .admin-form textarea:focus, .admin-form select:focus, .auth-card input:focus {
    border-color: var(--accent);
}
.admin-form textarea { resize: vertical; min-height: 110px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-row.three { grid-template-columns: repeat(3, 1fr); }
.upload-drop {
    min-height: 130px; border: 1px dashed var(--line-strong); padding: 22px;
    place-content: center; text-align: center; cursor: pointer;
}
.upload-drop input { padding: 0; background: none; border: 0; margin-bottom: 10px; }
.upload-drop span { color: var(--text); font-size: 16px; }
.upload-drop small { color: var(--muted); line-height: 1.6; }
.items-panel, .compact-panel { margin-top: 20px; }
.admin-items { border-top: 1px solid var(--line); }
.admin-item {
    display: grid; grid-template-columns: 84px 1fr auto; align-items: center; gap: 20px;
    padding: 16px 0; border-bottom: 1px solid var(--line);
}
.admin-thumb { width: 84px; height: 64px; background: #080808; display: grid; place-items: center; overflow: hidden; }
.admin-thumb img { width: 100%; height: 100%; object-fit: cover; }
.admin-thumb span { color: var(--muted); font-size: 9px; letter-spacing: .14em; }
.admin-item p { margin: 0 0 6px; color: var(--accent); font-size: 9px; letter-spacing: .13em; }
.admin-item h3 { margin: 0; font-size: 17px; font-weight: 500; }
.delete-button { border: 1px solid rgba(230,90,90,.38); background: none; color: #e99494; padding: 9px 14px; cursor: pointer; }
.delete-button:hover { background: rgba(230,90,90,.1); }
.admin-empty { color: var(--muted); }

@media (max-width: 900px) {
    .cursor-glow { display: none; }
    .site-nav {
        position: fixed; inset: 0; background: rgba(5,5,5,.98);
        display: flex; flex-direction: column; justify-content: center; align-items: flex-start;
        padding: 12vh 9vw; gap: 26px; opacity: 0; visibility: hidden; transform: translateY(-10px);
        transition: .35s var(--ease);
    }
    .site-nav a { font-size: 34px; color: var(--text); letter-spacing: -.03em; text-transform: none; }
    .menu-button { display: block; position: relative; z-index: 2; }
    .menu-open .site-nav { opacity: 1; visibility: visible; transform: none; }
    .menu-open .menu-button span:first-child { transform: translateY(3.5px) rotate(45deg); }
    .menu-open .menu-button span:nth-child(2) { transform: translateY(-3.5px) rotate(-45deg); }
    .hero { padding-top: 120px; }
    .hero-title { font-size: clamp(50px, 13vw, 88px); }
    .hero-meta span:first-child { display: none; }
    .hero-meta { justify-content: flex-start; }
    .scroll-hint { display: none; }
    .section-heading { grid-template-columns: 1fr; gap: 28px; }
    .section-heading > p { max-width: 580px; }
    .work-card { grid-column: span 12; }
    .work-card:nth-child(n), .work-card:nth-child(n).in-view { transform: none; }
    .work-media { aspect-ratio: 4 / 4.7; }
    .about-grid { grid-template-columns: 1fr; gap: 60px; margin-top: 70px; }
    .file-row { grid-template-columns: 1fr auto; }
    .file-row > p { display: none; }
    .admin-grid { grid-template-columns: 1fr; }
    .form-row.three { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
    .site-header { height: 68px; padding-inline: 18px; }
    .hero { padding-inline: 18px; }
    .hero-intro { margin-top: 30px; font-size: 15px; }
    .hero-actions { flex-direction: column; align-items: stretch; }
    .button { width: 100%; }
    .section { padding-inline: 18px; }
    .section-heading h2, .about-statement h2, .contact-inner h2 { font-size: 50px; }
    .section-heading { margin-bottom: 44px; }
    .filters { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 4px; }
    .filter { white-space: nowrap; }
    .work-grid { gap: 44px; }
    .work-description { max-width: 100%; }
    .about-grid { margin-top: 54px; }
    .contact-inner { padding-inline: 18px; margin-bottom: 80px; }
    .site-footer { align-items: flex-start; flex-direction: column; justify-content: center; padding-block: 28px; }
    .admin-shell { width: min(100% - 28px, 1440px); }
    .auth-card { padding: 26px 20px; }
    .admin-main { padding-top: 50px; }
    .admin-panel { padding: 22px 18px; }
    .form-row { grid-template-columns: 1fr; }
    .admin-item { grid-template-columns: 64px 1fr; }
    .admin-thumb { width: 64px; height: 54px; }
    .admin-item form { grid-column: 2; }
}
