/* ============================================================
   Delphine — Photography & Visual Design
   Design tokens: rose #88013B / ink #141414 / paper #fff
   ============================================================ */

@font-face {
  font-family: 'Archivo Black';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/archivo-black.woff2') format('woff2');
}

:root {
  --rose: #88013B;
  --rose-deep: #6d0130;
  --ink: #141414;
  --paper: #ffffff;
  --mut: #5a5a5a;
  --line: #e8e8e8;
  --sans: -apple-system, BlinkMacSystemFont, 'Helvetica Neue', 'PingFang SC', 'Segoe UI', Arial, sans-serif;
  --display: 'Archivo Black', 'Arial Black', 'Helvetica Neue', var(--sans);
  --nav-h: 56px;
  --ease: cubic-bezier(.22, .61, .36, 1);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--sans);
  background: var(--paper);
  color: var(--ink);
  font-size: 15px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

body.page-rose { background: var(--rose); }

::selection { background: var(--rose); color: #fff; }

img { max-width: 100%; }

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

/* ---------------- Navigation ---------------- */

.site-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 90;
  height: var(--nav-h);
  background: var(--paper);
  border-bottom: 1px solid var(--line);
  color: var(--ink);
}

.nav-inner {
  max-width: 1280px;
  height: 100%;
  margin: 0 auto;
  padding: 0 28px;
  display: flex;
  align-items: center;
  gap: 34px;
}

.nav-inner a {
  font-size: 12px;
  letter-spacing: .14em;
  text-transform: lowercase;
  color: var(--mut);
  padding: 4px 0;
  border-bottom: 1px solid transparent;
  transition: color .25s, border-color .25s;
}

.nav-inner a:hover { color: var(--ink); }

.nav-inner a.active { color: var(--ink); border-bottom-color: var(--rose); }

.nav-brand {
  margin-left: auto;
  font-size: 12px;
  letter-spacing: .14em;
  color: var(--ink);
  white-space: nowrap;
}

.nav-brand em { font-style: normal; font-family: var(--display); }

/* ghost nav (cover page) */
.site-nav.nav-ghost {
  background: transparent;
  border-bottom: none;
  color: #fff;
  transition: background .35s, color .35s, border-color .35s;
}

.site-nav.nav-ghost .nav-inner a { color: rgba(255, 255, 255, .75); }
.site-nav.nav-ghost .nav-inner a:hover,
.site-nav.nav-ghost .nav-inner a.active { color: #fff; }
.site-nav.nav-ghost .nav-brand { color: #fff; }

.site-nav.nav-ghost.scrolled {
  background: var(--paper);
  border-bottom: 1px solid var(--line);
  color: var(--ink);
}

.site-nav.nav-ghost.scrolled .nav-inner a { color: var(--mut); }
.site-nav.nav-ghost.scrolled .nav-inner a:hover,
.site-nav.nav-ghost.scrolled .nav-inner a.active { color: var(--ink); }
.site-nav.nav-ghost.scrolled .nav-brand { color: var(--ink); }

/* ---------------- Hero / cover ---------------- */

.hero {
  position: relative;
  height: 100vh;
  height: 100svh;
  min-height: 560px;
  background: var(--rose);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.hero-meta {
  position: absolute;
  top: calc(var(--nav-h) + 22px);
  left: 28px;
  font-size: 11px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, .82);
  line-height: 1.9;
}

.hero-meta strong { font-weight: 400; display: block; font-family: var(--display); letter-spacing: .1em; }

.hero-no {
  position: absolute;
  right: 28px;
  bottom: 26px;
  font-size: 11px;
  letter-spacing: .18em;
  color: rgba(255, 255, 255, .55);
}

.hero-frame {
  position: relative;
  width: min(1080px, 66vw);
  aspect-ratio: 26 / 9;
  margin-top: -5vh;
}

.hero-svg { width: 100%; height: 100%; display: block; }

/* film grain over the frame */
.hero-frame::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: .09;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='120' height='120' filter='url(%23n)'/%3E%3C/svg%3E");
}

.hero-slide { opacity: 0; transition: opacity .9s var(--ease); }
.hero-slide.is-active { opacity: 1; }

.hero-img {
  transform: scale(1.01);
  transform-box: fill-box;
  transform-origin: center;
  transition: transform 3.6s var(--ease);
  filter: saturate(1.06) contrast(1.05);
}

.hero-slide.is-active .hero-img { transform: scale(1.075); }

.hero-slide.is-active { animation: hero-glitch .26s steps(2, end) 1; }

@keyframes hero-glitch {
  0%   { transform: translateX(-5px); filter: brightness(1.7) saturate(.3); }
  35%  { transform: translateX(4px);  filter: brightness(.65); }
  70%  { transform: translateX(-2px); filter: brightness(1.25); }
  100% { transform: translateX(0);    filter: none; }
}

.hero-scroll {
  position: absolute;
  bottom: 26px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  font-size: 10px;
  letter-spacing: .3em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, .7);
}

.hero-scroll::after {
  content: '';
  width: 1px;
  height: 44px;
  background: rgba(255, 255, 255, .55);
  animation: drip 1.8s var(--ease) infinite;
  transform-origin: top;
}

@keyframes drip {
  0%   { transform: scaleY(0); }
  45%  { transform: scaleY(1); }
  100% { transform: scaleY(1); opacity: 0; }
}

/* ---------------- Generic section shell ---------------- */

.section { padding: 110px 28px; }

.section-inner { max-width: 1280px; margin: 0 auto; }

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  border-bottom: 1px solid var(--ink);
  padding-bottom: 18px;
  margin-bottom: 56px;
}

.section-head h2 {
  font-family: var(--display);
  font-size: clamp(26px, 3.4vw, 40px);
  font-weight: 400;
  letter-spacing: .01em;
}

.section-head .head-meta {
  font-size: 11px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--mut);
}

/* ---------------- Selected works (index) ---------------- */

.works { background: var(--paper); }

.works-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 30px;
}

.work-item { position: relative; }

.work-item a { display: block; }

.work-item .ph {
  overflow: hidden;
  background: #f2f2f2;
}

.work-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .8s var(--ease);
}

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

.work-item figcaption {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-top: 12px;
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--mut);
  transition: color .3s;
}

.work-item figcaption .no {
  font-family: var(--display);
  color: var(--ink);
  letter-spacing: 0;
}

.work-item figcaption .t { color: var(--ink); font-weight: 500; }

.work-item:hover figcaption .t { color: var(--rose); }

/* editorial collage placement */
.w1 { grid-column: 1 / 6;  margin-top: 0; }
.w2 { grid-column: 7 / 13; margin-top: 96px; }
.w3 { grid-column: 2 / 5;  margin-top: 64px; }
.w4 { grid-column: 6 / 10; margin-top: 32px; }
.w5 { grid-column: 10 / 13; margin-top: 160px; }
.w6 { grid-column: 1 / 7;  margin-top: 48px; }
.w7 { grid-column: 7 / 13; margin-top: 112px; }

.w1 .ph, .w3 .ph { aspect-ratio: 3 / 4; }
.w2 .ph, .w4 .ph, .w5 .ph, .w6 .ph, .w7 .ph { aspect-ratio: 4 / 3; }
.w5 .ph { aspect-ratio: 16 / 10; }

/* ---------------- Photography entry band (index) ---------------- */

.entry { background: var(--rose); color: #fff; padding: 120px 28px; }

.entry-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  max-width: 1280px;
  margin: 0 auto 70px;
}

.entry-link h2 {
  font-family: var(--display);
  font-size: clamp(44px, 8vw, 110px);
  font-weight: 400;
  line-height: 1;
  transition: opacity .3s;
}

.entry-link .arrow {
  font-size: clamp(40px, 6vw, 76px);
  font-family: var(--display);
  transition: transform .45s var(--ease);
}

.entry-link:hover .arrow { transform: translateX(18px); }
.entry-link:hover h2 { opacity: .75; }

.preview-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
  max-width: 1280px;
  margin: 0 auto;
}

.preview-card { display: block; }

.preview-card .ph { aspect-ratio: 4 / 5; overflow: hidden; background: rgba(255, 255, 255, .08); }
.preview-card img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.preview-card:hover img { transform: scale(1.05); }

.preview-card .cap {
  display: flex;
  justify-content: space-between;
  margin-top: 14px;
  font-size: 11px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, .85);
}

.preview-card .cap .n { font-family: var(--display); }

/* ---------------- Footer ---------------- */

.site-foot {
  background: var(--ink);
  color: rgba(255, 255, 255, .82);
  padding: 44px 28px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  font-size: 12px;
  letter-spacing: .12em;
}

.site-foot a { border-bottom: 1px solid transparent; transition: border-color .3s, color .3s; }
.site-foot a:hover { color: #fff; border-bottom-color: var(--rose); }

.foot-wechat { cursor: pointer; transition: color .3s; }
.foot-wechat:hover { color: #fff; }

.foot-copy { color: rgba(255, 255, 255, .4); }

/* ---------------- Sheet (inner pages) ---------------- */

.page { padding-top: var(--nav-h); }

.sheet {
  background: var(--paper);
  max-width: 1120px;
  margin: 84px auto 120px;
  padding: 72px 64px 80px;
}

.sheet-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  border-bottom: 1px solid var(--ink);
  padding-bottom: 26px;
  margin-bottom: 72px;
}

.sheet-title {
  font-family: var(--display);
  font-size: clamp(42px, 6vw, 76px);
  font-weight: 400;
  line-height: 1;
}

.sheet-meta {
  font-size: 11px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--mut);
  text-align: right;
}

.sheet-end {
  margin-top: 90px;
  text-align: center;
  font-size: 11px;
  letter-spacing: .3em;
  text-transform: uppercase;
  color: var(--mut);
}

/* ---------------- Series ---------------- */

.series { margin-bottom: 110px; }

.series-head { margin-bottom: 34px; }

.series-no {
  font-size: 11px;
  letter-spacing: .2em;
  color: var(--rose);
  font-family: var(--display);
}

.series-title {
  font-family: var(--display);
  font-size: clamp(34px, 4.6vw, 58px);
  font-weight: 400;
  line-height: 1.05;
  margin: 6px 0 4px;
}

.series-sub {
  font-size: 12px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--rose);
  margin-bottom: 12px;
}

.series-desc {
  max-width: 520px;
  color: var(--mut);
  font-size: 14px;
}

.subgroup { margin-bottom: 44px; }

.subgroup-title {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .24em;
  text-transform: uppercase;
  color: var(--ink);
  border-top: 1px solid var(--line);
  padding-top: 18px;
  margin-bottom: 22px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 14px;
}

.cell {
  position: relative;
  overflow: hidden;
  cursor: zoom-in;
  background: #f4f4f4;
}

.cell img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform .7s var(--ease);
}

.cell:hover img { transform: scale(1.04); }

.cell::after {
  content: attr(data-caption);
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 10px 12px;
  font-size: 10px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: #fff;
  background: linear-gradient(transparent, rgba(20, 0, 8, .72));
  opacity: 0;
  transition: opacity .35s;
  pointer-events: none;
}

.cell:hover::after { opacity: 1; }

/* ---------------- Lightbox ---------------- */

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(18, 0, 7, .97);
  display: none;
  align-items: center;
  justify-content: center;
}

.lightbox.open { display: flex; }

.lb-stage { position: relative; max-width: 94vw; max-height: 92vh; }

.lb-stage img {
  max-width: 92vw;
  max-height: 86vh;
  display: block;
  object-fit: contain;
  box-shadow: 0 30px 80px rgba(0, 0, 0, .5);
}

.lb-caption {
  position: absolute;
  left: 0; right: 0;
  bottom: -38px;
  text-align: center;
  font-size: 11px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, .75);
}

.lb-btn {
  position: absolute;
  background: none;
  border: none;
  color: rgba(255, 255, 255, .8);
  font-size: 28px;
  font-family: var(--display);
  cursor: pointer;
  padding: 18px;
  line-height: 1;
  transition: color .25s, transform .25s;
  user-select: none;
}

.lb-btn:hover { color: #fff; }

.lb-close { top: 18px; right: 24px; font-size: 32px; }
.lb-prev { left: 12px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 12px; top: 50%; transform: translateY(-50%); }
.lb-prev:hover { transform: translateY(-50%) translateX(-4px); }
.lb-next:hover { transform: translateY(-50%) translateX(4px); }

.lb-counter {
  position: absolute;
  top: 26px;
  left: 28px;
  font-size: 11px;
  letter-spacing: .2em;
  color: rgba(255, 255, 255, .6);
  font-family: var(--display);
}

/* ---------------- Toast ---------------- */

.toast {
  position: fixed;
  left: 50%;
  bottom: 42px;
  transform: translate(-50%, 16px);
  background: var(--ink);
  color: #fff;
  font-size: 12px;
  letter-spacing: .14em;
  padding: 12px 26px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .35s, transform .35s var(--ease);
  z-index: 300;
}

.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------------- About / Contact / Art ---------------- */

.prose { max-width: 640px; }

.prose .lead {
  font-size: clamp(19px, 2.2vw, 24px);
  line-height: 1.6;
  margin-bottom: 28px;
}

.prose p { margin-bottom: 20px; color: #333; }

.prose .kicker {
  font-size: 11px;
  letter-spacing: .24em;
  text-transform: uppercase;
  color: var(--rose);
  margin-bottom: 14px;
}

.skill-list {
  list-style: none;
  text-align: center;
  margin: 70px auto;
  max-width: 520px;
}

.skill-list li {
  font-size: clamp(15px, 1.8vw, 18px);
  line-height: 2.1;
  letter-spacing: .06em;
}

.skill-list li::before { content: '· '; color: var(--rose); }

.ellipse-wrap { display: flex; justify-content: center; margin: 60px 0; }

.ellipse { width: min(420px, 70%); height: auto; }

.about-figure { margin: 70px 0; }

.about-figure .ph { aspect-ratio: 16 / 10; overflow: hidden; background: #f4f4f4; }
.about-figure img { width: 100%; height: 100%; object-fit: cover; display: block; }

.about-figure figcaption {
  margin-top: 12px;
  font-size: 11px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--mut);
}

.edu {
  border-top: 1px solid var(--line);
  padding-top: 26px;
  margin-top: 60px;
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 18px;
  font-size: 14px;
}

.edu dt {
  font-size: 11px;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--mut);
  padding-top: 3px;
}

.edu dd { color: #333; }

/* contact */
.contact-rows { max-width: 640px; }

.contact-row {
  display: flex;
  align-items: baseline;
  gap: 22px;
  padding: 30px 0;
  border-bottom: 1px solid var(--line);
}

.contact-row .k {
  width: 90px;
  flex: none;
  font-size: 11px;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--mut);
}

.contact-row .v { font-size: clamp(17px, 2.4vw, 24px); word-break: break-all; }

.contact-row .v a { border-bottom: 1px solid var(--ink); transition: color .3s, border-color .3s; }
.contact-row .v a:hover { color: var(--rose); border-bottom-color: var(--rose); }

.copy-btn {
  margin-left: auto;
  flex: none;
  border: 1px solid var(--ink);
  background: none;
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: .16em;
  text-transform: uppercase;
  padding: 9px 18px;
  cursor: pointer;
  transition: background .3s, color .3s;
}

.copy-btn:hover { background: var(--ink); color: #fff; }

.contact-note { margin-top: 44px; color: var(--mut); font-size: 14px; max-width: 520px; }

.contact-portraits {
  margin: 56px auto 10px;
  max-width: 520px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.contact-portrait .ph { overflow: hidden; background: #f4f4f4; aspect-ratio: 2 / 3; }
.contact-portrait img { width: 100%; height: 100%; object-fit: cover; display: block; }
.contact-portraits figcaption {
  grid-column: 1 / -1;
  margin-top: 8px;
  text-align: center;
  font-size: 11px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--mut);
}

/* art page */
.art-projects {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px 44px;
}

.art-item { scroll-margin-top: calc(var(--nav-h) + 30px); }

.art-item .ph { overflow: hidden; background: #f4f4f4; }

.art-item img { width: 100%; display: block; transition: transform .8s var(--ease); }
.art-item:hover img { transform: scale(1.03); }

.art-item figcaption {
  display: flex;
  align-items: baseline;
  gap: 14px;
  margin-top: 14px;
  font-size: 11px;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.art-item .no { font-family: var(--display); }
.art-item .t { font-weight: 600; }
.art-item .tag { color: var(--rose); margin-left: auto; }

/* ---------------- Reveal on scroll ---------------- */

.reveal { opacity: 0; transform: translateY(26px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.reveal.in { opacity: 1; transform: none; }

/* ---------------- Responsive ---------------- */

@media (max-width: 960px) {
  .works-grid { grid-template-columns: repeat(6, 1fr); }
  .w1 { grid-column: 1 / 7; }
  .w2 { grid-column: 1 / 7; margin-top: 0; }
  .w3 { grid-column: 1 / 4; margin-top: 0; }
  .w4 { grid-column: 4 / 7; margin-top: 0; }
  .w5 { grid-column: 1 / 7; margin-top: 0; }
  .w6 { grid-column: 1 / 7; margin-top: 0; }
  .w7 { grid-column: 1 / 7; margin-top: 0; }
  .w1 .ph, .w3 .ph { aspect-ratio: 3 / 4; }
  .w2 .ph, .w4 .ph, .w5 .ph, .w6 .ph, .w7 .ph { aspect-ratio: 4 / 3; }
  .preview-grid { grid-template-columns: 1fr; gap: 40px; }
  .art-projects { grid-template-columns: 1fr; gap: 50px; }
  .sheet { padding: 48px 26px 60px; margin: 56px 16px 80px; }
  .section { padding: 76px 22px; }
}

@media (max-width: 640px) {
  :root { --nav-h: 52px; }
  .nav-inner { gap: 20px; padding: 0 20px; }
  .nav-brand { display: none; }
  .hero-frame { width: 86vw; margin-top: -3vh; }
  .hero-meta { left: 20px; font-size: 10px; }
  .hero-no { right: 20px; }
  .works-grid { grid-template-columns: 1fr; gap: 44px; }
  .w1, .w2, .w3, .w4, .w5, .w6, .w7 { grid-column: 1 / -1; margin-top: 0; }
  .grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
  .entry-link { flex-direction: column; align-items: flex-start; gap: 8px; }
  .sheet-top { flex-direction: column; gap: 10px; }
  .sheet-meta { text-align: left; }
  .edu { grid-template-columns: 1fr; gap: 4px; }
  .contact-row { flex-wrap: wrap; gap: 10px; }
  .copy-btn { margin-left: 0; }
  .lb-prev { left: 0; }
  .lb-next { right: 0; }
}

/* ---------------- Reduced motion ---------------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
  .hero-slide { transition: none; }
}
