@font-face {
  font-family: "Newsreader";
  font-style: normal;
  font-weight: 300 600;
  font-display: swap;
  src: url("fonts/newsreader-latin.woff2") format("woff2");
}

:root {
  color-scheme: light;
  --bg: #f7f3ee;
  --text: #1b1b1b;
  --muted: #5d5b59;
  --accent: #d9764a;
  --accent-dark: #b35a32;
  --surface: #ffffff;
  --shadow: 0 20px 50px rgba(27, 27, 27, 0.12);
  --radius: 28px;
  --grid: rgba(27, 27, 27, 0.08);
  --line: rgba(27, 27, 27, 0.16);
  --ink: #1b1b1b;
  --page-bg: #f7f3ee;
  --page-bg-muted: rgba(247, 243, 238);
}

* {
  box-sizing: border-box;
}

html {
  max-width: 100%;
  overflow-x: hidden;
  overscroll-behavior-x: auto;
}

body {
  margin: 0;
  width: 100%;
  max-width: 100%;
  font-family: Georgia, 'Times New Roman', Times, serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
  overflow-x: clip;
}

body::-webkit-scrollbar {
    display: none;
}

h1,
h2,
h3 {
  letter-spacing: -0.02em;
  margin: 0 0 0.6rem;
}

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

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0;
  padding: 0.8rem 6vw;
  background: transparent;
  border-bottom: none;
  backdrop-filter: none;
  z-index: 10;
}

.topbar__contact {
  position: relative;
}

.topbar__contact summary {
  list-style: none;
  cursor: pointer;
  color: var(--ink);
  font-size: 0.95rem;
  padding: 0.5rem 1rem;
  border: 1px solid rgba(27, 27, 27, 0.2);
  border-radius: 999px;
  transition: color 0.3s ease, background 0.3s ease, transform 0.3s ease;
}

.topbar__contact summary:hover {
  background: rgba(217, 118, 74, 0.12);
  color: var(--accent-dark);
  transform: translateY(-1px);
}

.topbar__contact summary::-webkit-details-marker {
  display: none;
}

.topbar__contact-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  min-width: 280px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 12px;
  display: grid;
  gap: 6px;
  box-shadow: var(--shadow);
  z-index: 20;
}

.topbar__contact-panel a {
  color: var(--ink);
  text-decoration: none;
  font-size: 14px;
  line-height: 1.3;
}

.topbar__contact-panel a:hover {
  opacity: 0.75;
}

.mobile-nav .topbar__contact {
  position: static;
}

.mobile-nav .topbar__contact summary {
  width: 100%;
  text-align: left;
}

.mobile-nav .topbar__contact-panel {
  position: static;
  min-width: 0;
  margin-top: 0.5rem;
  box-shadow: none;
}

.menu-toggle {
  display: inline-flex;
  border: 1px solid rgba(27, 27, 27, 0.2);
  background: var(--surface);
  padding: 0.45rem 0.75rem;
  border-radius: 999px;
  font-size: 0.9rem;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.menu-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  border-radius: 999px;
  background: var(--text);
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.menu-toggle.is-open {
  transform: translateY(-1px);
  box-shadow: 0 10px 24px rgba(27, 27, 27, 0.12);
}

.menu-toggle.is-open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.menu-toggle.is-open span:nth-child(2) {
  opacity: 0;
}

.menu-toggle.is-open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.mobile-nav {
  position: fixed;
  top: 76px;
  right: 6vw;
  background: var(--surface);
  border-radius: 20px;
  padding: 1rem 1.2rem;
  display: grid;
  gap: 0.8rem;
  box-shadow: var(--shadow);
  z-index: 9;
  opacity: 0;
  transform: translateY(-10px) scale(0.98);
  pointer-events: none;
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.mobile-nav.is-open {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

/* ===== Hero ===== */
.hero {
  position: relative;
  height: 100svh;
  min-height: 640px;
  overflow: hidden;
  padding-top: 0;
}

.hero__bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
  background: var(--ink);
  z-index: 0;
}

.hero__bg img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center bottom;
  opacity: 0;
  z-index: 0;
  transition: opacity 0.85s ease;
}

.hero__bg img.is-active {
  opacity: 1;
}

.hero__bg img.is-entering {
  z-index: 1;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(143, 139, 136, 0.35), rgba(125, 120, 115, 0.75));
  z-index: 1;
  display: none;
}

.hero__inner {
  position: relative;
  z-index: 2;
  max-width: 1200px;
  margin: 0 auto;
  height: 100%;
  padding: 0 22px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  color: var(--ink);
  transform: translateY(-16.667svh);
}

.hero__title {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  line-height: 0.88;
  font-size: clamp(56px, 7vw, 86px);
  text-shadow: 1px 1px 10px black;
  color: var(--page-bg);
}

.hero__subtitle {
  margin: 10px 0 0;
  font-size: 26px;
  text-shadow: 1px 1px 10px black;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--page-bg-muted);
}

.section {
  padding: 5rem 6vw;
}

.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 1.15s ease, transform 1.15s ease;
}

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

.section-header {
  max-width: 560px;
  margin-bottom: 2.5rem;
}



.about {
  background: #f2ede6;
}

.about-layout {
  display: grid;
  gap: 2rem;
  grid-template-columns: minmax(280px, 420px) 1fr;
  align-items: start;
}

.about-portrait {
  display: grid;
  gap: 0.8rem;
  width: 100%;
  max-width: 420px;
}

.portrait-frame {
  border-radius: 24px;
  overflow: hidden;
  border: 1px solid rgba(27, 27, 27, 0.08);
}

.portrait-frame img {
  width: 100%;
  height: auto;
  object-fit: contain;
  display: block;
}

.portrait-caption {
  margin: 0;
  font-size: 0.9rem;
  color: var(--muted);
}

.about-grid {
  display: grid;
  align-items: start;
  gap: 1.5rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  max-width: 900px;
}

.about-card {
  align-self: start;
  padding: 0;
  border-radius: 20px;
  background: var(--surface);
  border: 1px solid rgba(27, 27, 27, 0.08);
  overflow: hidden;
}

.about-card-trigger {
  width: 100%;
  text-align: left;
  border: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.2rem 1.4rem;
  font: inherit;
}

.about-card-title {
  font-family: "Newsreader", serif;
  font-size: 1.25rem;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.about-card-trigger::after {
  content: "+";
  font-size: 1.4rem;
  color: var(--accent-dark);
  transition: transform 0.45s ease;
}


.about-card-content {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.35s ease;
}

.about-card-content-inner {
  overflow: hidden;
  padding: 0 1.4rem;
  opacity: 0;
  transform: translateY(-8px);
  transition: opacity 0.28s ease, transform 0.28s ease, padding 0.28s ease;
}

.about-card.is-open .about-card-trigger::after {
  content: "−";
  transform: rotate(180deg);
}

.about-card.is-open .about-card-content {
  grid-template-rows: 1fr;
}

.about-card.is-open .about-card-content-inner {
  padding: 0 1.4rem 1.4rem;
  opacity: 1;
  transform: translateY(0);
}

.about-card-content-inner p {
  margin: 0 0 0.8rem;
}

.about-card-content-inner ul {
  margin: 0.2rem 0 0;
  padding-left: 1.1rem;
}

.about-card-content-inner li {
  margin-bottom: 0.35rem;
}

.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--ink);
  text-decoration: none;
  font-size: 12px;
  flex: 0 0 auto;
}

.pill:hover {
  opacity: 0.85;
}

.pill svg {
  width: 28px;
  height: 28px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.footer-contact {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  flex-wrap: wrap;
}

.footer-contact__links {
  display: grid;
  gap: 0.2rem;
}

.footer-contact a,
.footer__copyright,
.footer__credit,
.footer__legal-link {
  font-size: 0.9rem;
  line-height: 1.45;
  text-align: center;
}

.footer__copyright,
.footer__credit {
  margin: 0;
}

.footer__credit {
  text-align: left;
}

.footer a:not(.pill) {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: rgba(217, 118, 74, 0.55);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.22em;
}

.footer a:not(.pill):hover {
  color: var(--accent-dark);
  text-decoration-color: currentColor;
}

.footer__credit a {
  color: inherit;
}

.transform {
  background: #fbf7f2;
}

.project-description {
  display: grid;
  align-items: start;
  gap: 1.25rem;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  margin: 0 0 2.5rem;
}

.project-description .about-card-title {
  font-size: 1.12rem;
}

.compare-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 2rem;
  width: 100%;
  min-width: 0;
  align-items: center;
}

.compare {
  position: relative;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: var(--shadow);
  background: transparent;
  min-height: 0;
  aspect-ratio: 4 / 3;
  --pos: 55%;
  touch-action: pan-y;
}

.compare img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
  -webkit-user-drag: none;
  user-select: none;
}

.compare .compare-left {
  clip-path: inset(0 45% 0 0);
  transition: none;
}

.compare-handle {
  position: absolute;
  top: 0;
  bottom: 0;
  left: calc(var(--pos) - 1px);
  width: 2px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.4);
  pointer-events: none;
}

.compare-handle::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 36px;
  height: 36px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: #fff;
  border: 2px solid var(--accent);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.25);
}

.compare input[type="range"] {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  appearance: none;
  background: transparent;
  cursor: ew-resize;
  z-index: 3;
  touch-action: none;
  pointer-events: none;
  -webkit-user-select: none;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.compare.is-portrait .compare-handle {
  top: calc(var(--pos) - 1px);
  left: 0;
  right: 0;
  bottom: auto;
  width: auto;
  height: 2px;
}

.compare.is-portrait input[type="range"] {
  cursor: ns-resize;
}

.compare input[type="range"]::-webkit-slider-runnable-track {
  background: transparent;
  height: 100%;
}

.compare input[type="range"]::-moz-range-track {
  background: transparent;
  height: 100%;
}

.compare input[type="range"]::-webkit-slider-thumb {
  appearance: none;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: transparent;
  border: none;
  box-shadow: none;
}

.compare input[type="range"]::-moz-range-thumb {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: transparent;
  border: none;
  box-shadow: none;
}

.image-sequence {
  position: relative;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: var(--shadow);
  background: #000;
  cursor: pointer;
  isolation: isolate;
}

.compare-grid .image-sequence {
  width: 100%;
  height: auto;
  min-width: 0;
  aspect-ratio: var(--sequence-ratio, 4 / 3);
  align-self: center;
  justify-self: center;
}

.compare-grid .image-sequence--wide {
  grid-column: span 2;
}

.project-media {
  display: grid;
  gap: 0.55rem;
  width: 100%;
  min-width: 0;
  margin: 0;
  align-content: center;
  align-self: center;
}

.project-media--wide {
  grid-column: span 2;
  justify-items: center;
  min-width: min(100%, 31rem);
}

.sequence-pair-row {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: auto auto;
  gap: 2rem;
  justify-content: center;
  align-items: center;
}

.sequence-pair-row .project-media {
  width: max-content;
  max-width: 100%;
  justify-self: center;
}

.sequence-pair-row .project-media--wide {
  grid-column: auto;
}

.project-media > .compare,
.project-media > .image-sequence {
  width: 100%;
}

.project-media .image-sequence--wide {
  grid-column: auto;
}

.project-media figcaption {
  color: var(--muted);
  font-size: 0.85rem;
  line-height: 1.3;
  text-align: center;
}

.image-sequence img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  opacity: 0;
  transition: none;
}

.image-sequence img.is-active {
  opacity: 1;
}

.image-sequence::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 45%;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.6), transparent);
  pointer-events: none;
}

.image-sequence-hint {
  position: absolute;
  left: 1rem;
  right: 1rem;
  bottom: 0.9rem;
  z-index: 2;
  margin: 0;
  color: #fff;
  font-size: 0.86rem;
  letter-spacing: 0.02em;
}

.footer {
  padding: 2rem 6vw 3rem;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 1.5rem;
  font-size: 0.9rem;
  color: var(--muted);
}

.footer-contact {
  justify-self: start;
}

.footer__copyright {
  justify-self: center;
  text-align: center;
}

.footer__legal-link {
  justify-self: end;
  text-align: right;
}

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

@media (max-width: 980px) {
  .site-header {
    flex-wrap: wrap;
  }

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

  .about-portrait {
    max-width: none;
  }

  .about-grid {
    max-width: 100%;
    grid-template-columns: 1fr;
  }

  .footer {
    grid-template-columns: 1fr;
    justify-items: center;
    gap: 0.8rem;
  }

  .footer-contact,
  .footer__copyright,
  .footer__credit,
  .footer__legal-link {
    justify-self: center;
    text-align: center;
  }
}

@media (min-width: 981px) and (max-width: 1280px) {
  .about-grid {
    grid-template-columns: 1fr;
    max-width: 640px;
  }

  .transform .compare {
    height: auto;
    justify-self: stretch;
  }
}

@media (min-width: 1200px) {
  .project-media--wide:last-child {
    grid-column: 2 / span 2;
  }
}

@media (max-width: 1199px) {
  .transform .compare-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 961px) and (max-width: 1199px) {
  .project-media--wide {
    grid-column: 1 / -1;
  }

  .sequence-pair-row .project-media--wide {
    grid-column: auto;
  }
}

@media (max-width: 960px) {
  .transform .compare-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .sequence-pair-row {
    grid-template-columns: minmax(0, 1fr);
    justify-items: center;
  }
}

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

  .project-media--wide {
    grid-column: 1 / -1;
    min-width: 0;
  }
}

@media (max-width: 640px) {
  .site-header {
    padding: 1rem 5vw;
  }

  .hero {
    min-height: 520px;
  }

  .hero__inner {
    padding: 0 16px;
  }

  .hero__title {
    font-size: clamp(48px, 14vw, 72px);
  }

  .section {
    padding: 3.5rem 5vw;
  }
}

@media (max-width: 640px) {
  .hero__bg img {
    object-position: 72% bottom;
  }
}
