/* Page-specific styles for About, Photography, Projects and Contact. */

/* ================= About ================= */

.about-top {
  display: flex; flex-wrap: wrap;
  align-items: flex-end; justify-content: space-between;
  gap: 32px 6vw;
}
.now { display: flex; align-items: flex-end; gap: 22px; margin: 0 6px 1.2vw 0; }
.avatar { width: 150px; height: 150px; flex: none; }
.avatar img { display: block; width: 100%; height: 100%; object-fit: cover; }
.now-text { display: flex; flex-direction: column; gap: 6px; padding-bottom: 4px; }
.now-text span:last-child { max-width: 200px; font-size: 16px; font-weight: 600; line-height: 1.3; }

.intro {
  display: flex; flex-wrap: wrap; gap: 24px 40px;
  padding-top: 64px; padding-bottom: 24px;
}
.intro .label { flex: 0 0 200px; padding-top: 10px; }
.intro p {
  flex: 999 1 520px; min-width: 0; max-width: 980px; margin: 0;
  font-size: clamp(26px, 2.8vw, 40px); font-weight: 600;
  line-height: 1.12; letter-spacing: -0.03em;
}

.details { padding-top: 40px; }
.details h2.label { margin: 0; font-weight: 400; }

.exp { display: flex; flex-direction: column; gap: 4px; }

.chips { display: flex; flex-wrap: wrap; gap: 10px; margin: 0; padding: 0; list-style: none; }

.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 18px; }
.card.is-static { box-shadow: 4px 4px 0 var(--ink); cursor: default; }
.card.is-static:hover { transform: none; box-shadow: 4px 4px 0 var(--ink); }
.card.is-static:hover .spr { background-image: var(--idle); background-size: calc(96px * var(--k)) calc(38px * var(--k)); animation: idle4 .9s steps(4) infinite; }

.code { display: flex; flex-direction: column; gap: 24px; }
.code-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.graph { margin: 0; padding: 18px; border: 2px solid var(--ink); background: #fff; }
.graph img { display: block; width: 100%; height: auto; }
.graph figcaption { margin-top: 10px; }

@media (max-width: 760px) {
  .now { margin-bottom: 0; }
  .avatar { width: 110px; height: 110px; }
  .intro { padding-top: 40px; }
}

/* ================= Projects ================= */

.list { padding-top: 48px; padding-bottom: 24px; }
.filters { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 28px; }

.proj {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 24px 4vw;
  align-items: center;
  padding: 44px 0;
  border-top: 1px solid var(--rule);
  scroll-margin-top: 24px;
}
.proj-body { display: flex; flex-direction: column; gap: 16px; }
.proj-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 22px; }
.proj-name { margin: 0; font: 800 clamp(34px, 4vw, 60px)/0.95 var(--display); letter-spacing: -0.045em; }
.proj-line { margin: 0; max-width: 620px; font-size: 18px; line-height: 1.45; color: var(--body); }
.tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; }
.proj-link { align-self: flex-start; margin-top: 4px; font-size: 15px; font-weight: 700; color: var(--ink); }

.cover {
  position: relative;
  display: flex; align-items: center; justify-content: center;
  aspect-ratio: 4 / 3;
  border: 3px solid var(--ink);
  box-shadow: 6px 6px 0 var(--ink);
  overflow: hidden;
  background: #fff;
}
a.cover { transition: transform .15s ease, box-shadow .15s ease; }
a.cover:hover { transform: translate(2px, 2px); box-shadow: 4px 4px 0 var(--ink); }
.c-tsc img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 22% center; }
.c-d2k { background-image: radial-gradient(ellipse 80% 70% at 50% 45%, #fff 0%, #eaf8ff 55%, #c9ecfb 100%); }
.c-d2k img { width: 86%; height: auto; }
.c-uv { background: #efeeea; }
.c-uv .sun { display: block; width: 30%; height: auto; }
.c-uv .ct {
  position: absolute; left: 6%; bottom: 6%;
  font-family: var(--pixel); font-size: clamp(11px, 0.9vw, 13px); letter-spacing: 0.08em;
}

@media (max-width: 820px) {
  .proj { grid-template-columns: minmax(0, 1fr); }
}

/* ================= Photography ================= */

.gallery-wrap { padding-top: 6vw; padding-bottom: 4vw; }

.gal {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: 2.2vw; row-gap: 5vw;
  align-items: start;
}
.shot { display: flex; flex-direction: column; gap: 12px; color: var(--ink); text-decoration: none; cursor: zoom-in; }
.shot:hover { color: var(--ink); }
.shot .frame { position: relative; display: block; aspect-ratio: 4 / 5; overflow: hidden; background: #e7e7e4; }
.shot.square .frame { aspect-ratio: 1 / 1; }
.shot img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .5s cubic-bezier(.2, .8, .2, 1); }
.shot:hover img { transform: scale(1.035); }
.shot .cap { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; font-weight: 600; }
.shot .date { color: var(--muted); font-weight: 500; }
.shot:focus-visible { outline-offset: 6px; }

@media (max-width: 760px) {
  .gal { row-gap: 36px; }
  .gal .shot { grid-column: 1 / -1 !important; margin-top: 0 !important; }
}

.lb {
  position: fixed; inset: 0; z-index: 40;
  display: flex; flex-direction: column;
  background: rgba(247, 247, 246, 0.97);
  animation: lbIn .2s ease;
}
.lb[hidden] { display: none; }
body.lb-open { overflow: hidden; }
.lb-bar { display: flex; justify-content: space-between; align-items: center; padding: 18px 20px; }
.lb-stage { flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; gap: 28px; padding: 0 24px; }
.lb-pic { height: min(74vh, 880px); max-width: calc(100vw - 200px); aspect-ratio: 4 / 5; }
.lb-pic picture, .lb-pic img { display: block; width: 100%; height: 100%; }
.lb-pic img { object-fit: cover; border: 3px solid var(--ink); box-shadow: 8px 8px 0 var(--ink); background: #fff; }
.lb-foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; padding: 22px 20px 26px; }
.lb-date { font-size: 22px; font-weight: 700; letter-spacing: -0.02em; }
.lb-cam { font-size: 14px; color: var(--body-2); }
@keyframes lbIn { from { opacity: 0; } to { opacity: 1; } }

@media (max-width: 760px) {
  .lb-stage { position: relative; padding: 0 16px; }
  .lb-pic { height: auto; width: 100%; max-width: none; }
  .lb-nav { position: absolute; bottom: -64px; }
  .lb-nav[data-lb="prev"] { left: 16px; }
  .lb-nav[data-lb="next"] { right: 16px; }
  .lb-foot { padding-top: 84px; }
}

/* ================= Contact ================= */

.contact {
  display: flex; flex-wrap: wrap;
  gap: 56px 6vw; align-items: flex-start;
  padding-top: 64px; padding-bottom: 72px;
  scroll-margin-top: 12px;
}
.contact h2.label { margin: 0; font-weight: 400; }
.contact-form { flex: 999 1 560px; min-width: 0; }
.contact-form form { display: flex; flex-direction: column; gap: 26px; }
.pair { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; }
.field { display: flex; flex-direction: column; gap: 8px; }
.field > span { font-size: 14px; font-weight: 700; }
.field input, .field textarea {
  width: 100%; padding: 14px 16px;
  border: 2px solid var(--ink); border-radius: 0;
  background: #fff; color: var(--ink);
  font: 500 17px var(--display);
  outline: none;
  transition: box-shadow .1s ease;
}
.field textarea { resize: vertical; min-height: 170px; line-height: 1.45; }
.field input:focus, .field textarea:focus { box-shadow: 4px 4px 0 var(--ink); }
.field input::placeholder, .field textarea::placeholder { color: #8a8a8a; }
.topics { display: flex; flex-wrap: wrap; gap: 10px; }
.send-row { display: flex; flex-wrap: wrap; align-items: center; gap: 18px; }
.hint { font-size: 14px; color: var(--muted); }

.sent {
  display: flex; flex-direction: column; align-items: flex-start; gap: 18px;
  padding: 36px;
  border: 3px solid var(--ink); box-shadow: 8px 8px 0 var(--ink); background: #fff;
  animation: pop .25s ease;
}
.sent[hidden] { display: none; }
.sent .spr { --k: 4; }
.sent-title { font: 800 44px/1 var(--display); letter-spacing: -0.04em; }
.sent p { margin: 0; max-width: 460px; font-size: 18px; line-height: 1.45; color: var(--body); }
@keyframes pop { from { transform: translateY(8px); opacity: 0; } to { transform: none; opacity: 1; } }

.direct { flex: 1 1 360px; min-width: 0; display: flex; flex-direction: column; }
.contact .direct h2.label { margin-bottom: 18px; }
.way {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 22px 0;
  border-top: 1px solid var(--rule);
  color: var(--ink); text-decoration: none;
}
.way.last { border-bottom: 1px solid var(--rule); }
.way:hover { color: var(--ink); }
.way-text { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.way-val { font-size: 22px; font-weight: 700; letter-spacing: -0.02em; overflow-wrap: anywhere; }
.way .arrow { font-size: 24px; font-weight: 700; transition: transform .15s ease; }
.way:hover .arrow { transform: translate(4px, -4px); }
.direct .px-btn { align-self: flex-start; margin-top: 28px; }

@media (prefers-reduced-motion: reduce) {
  .shot img, a.cover, .way .arrow { transition: none; }
  .lb, .sent { animation: none; }
}
