/* ==========================================================================
   Diljot Singh — Portfolio Stylesheet
   Pure, clean, lightweight CSS. Zero baggage.
   ========================================================================== */

/* --- Typography (PP Neue Montreal) --- */
@font-face {
  font-family: 'PP Neue Montreal';
  src: url('../fonts/PPNeueMontreal-Regular.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'PP Neue Montreal';
  src: url('../fonts/PPNeueMontreal-Medium.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'PP Neue Montreal';
  src: url('../fonts/PPNeueMontreal-SemiBold.woff2') format('woff2');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

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

html {
  scroll-behavior: smooth;
}

body {
  background-color: #000000;
  color: #ffffff;
  font-family: 'PP Neue Montreal', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.4;
  overflow-x: hidden;
}

/* --- Section Layout --- */
.section {
  min-height: 100svh;
  max-width: 1300px;
  margin: 0 auto;
  padding: 3.5rem 2.5rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  width: 100%;
}

.section-header__empty {
  flex: 1;
}

/* --- Brand Typography --- */
.brand {
  font-size: clamp(1rem, 1.35vw, 1.25rem);
  letter-spacing: -0.015em;
  color: #efeeec;
  display: inline-flex;
  align-items: baseline;
  flex-wrap: wrap;
  cursor: default;
}

.brand-name {
  color: #ffffff;
  font-weight: 500;
}

.brand-roles {
  color: #f2f2f7;
  font-weight: 400;
}

/* --- Chroma Text Refraction Animation (Exact 1:1 from LeetFeedback) --- */
.chroma-text {
  display: inline-flex;
  vertical-align: baseline;
  padding-bottom: 0.16em;
  padding-right: 0.15em;
  margin-left: 0.35em;
  line-height: 1.12;
  background-size: 300% 100%;
  background-position: 100% 0;
  will-change: background-position;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  background-image: linear-gradient(
    90deg,
    rgb(255, 255, 255) 0px,
    rgb(255, 255, 255) 33.33%,
    rgb(255, 182, 193) 40%,
    rgb(240, 40, 50) 45%,
    rgb(255, 190, 20) 50%,
    rgb(235, 235, 255) 55%,
    rgb(20, 90, 230) 60%,
    transparent 66.67%,
    transparent
  );
  font-weight: 500;
}

.chroma-text-animate {
  animation: chroma-sweep 1.1s ease-in-out 0.2s forwards;
  filter: blur(1px);
}

@keyframes chroma-sweep {
  0% {
    background-position: 100% 0;
    filter: blur(1px);
  }
  100% {
    background-position: 0 0;
    filter: blur(0);
  }
}

/* --- Section Tag --- */
.section-tag {
  font-size: 0.82rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #d1d1d6;
  font-weight: 500;
  white-space: nowrap;
}

/* --- Navigation Lists --- */
.list-container {
  display: flex;
  margin: auto 0;
}

.list-container.is--right {
  justify-content: flex-end;
}

.list-container.is--left {
  justify-content: flex-start;
}

.nav-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
}

.is--right .nav-list {
  align-items: flex-end;
}

.is--left .nav-list {
  align-items: flex-start;
}

.nav-item {
  display: flex;
  align-items: baseline;
  transition: opacity 0.3s ease;
}

/* --- Item Links & Titles --- */
.item-link {
  text-decoration: none;
  /* systemGray at rest, pure white once selected or hovered — a resting row
     has to be visibly dimmer than white or the selection cannot be read. */
  color: #8e8e93;
  display: inline-flex;
  align-items: baseline;
  gap: 1.4rem;
  transition: color 0.25s ease;
  cursor: pointer;
}

.item-title {
  position: relative;
  font-size: clamp(2.4rem, 4.4vw, 3.8rem);
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1.1;
  white-space: nowrap;
  color: inherit;
  transition: color 0.25s ease;
}

.nav-item.is--active .item-link,
.item-link:hover {
  color: #ffffff;
}

/* Item Meta Tags — inherits the row colour, so a project is systemGray6 at
   rest and pure white the moment it is hovered. */
.item-meta {
  font-size: clamp(1rem, 1.3vw, 1.16rem);
  letter-spacing: 0.01em;
  color: inherit;
  font-weight: 400;
  white-space: nowrap;
  transition: color 0.25s ease;
}

/* --- Footer --- */
.footer {
  padding: 3rem 2.5rem;
  max-width: 1300px;
  margin: 0 auto;
  display: flex;
  justify-content: center;
  align-items: center;
  border: none;
}

.footer-links {
  display: flex;
  align-items: center;
  gap: 2.5rem;
}

.footer-link {
  color: #d1d1d6;
  text-decoration: none;
  font-size: 0.95rem;
  letter-spacing: -0.01em;
  transition: color 0.2s;
}

.footer-link:hover {
  color: #ffffff;
}

/* --- Responsive Layout --- */
@media screen and (max-width: 768px) {
  .section {
    padding: 2.5rem 1.5rem;
  }

  .section-header {
    flex-direction: column;
    gap: 0.75rem;
  }

  .list-container.is--right,
  .list-container.is--left {
    justify-content: flex-start;
  }

  .is--right .nav-list,
  .is--left .nav-list {
    align-items: flex-start;
  }

  .item-link {
    flex-direction: column;
    gap: 0.35rem;
  }

  .item-title {
    font-size: clamp(2rem, 7.5vw, 2.8rem);
  }

  .item-meta {
    font-size: 0.85rem;
  }
}

/* ==========================================================================
   PROJECT PREVIEWS
   A live "touch" of each project's own site, shown to the left of the list.
   ========================================================================== */

body {
  position: relative;
}

.section,
.footer {
  position: relative;
  z-index: 2;
}

/* --- Page-wide brand aura ------------------------------------------------ */
.brand-aura {
  position: fixed;
  inset: -12%;
  z-index: 0;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.8s ease;
  background: transparent;
  will-change: opacity;
}

.brand-aura.is--on {
  opacity: 1;
}

/* Some projects wash the page with a picture instead of a gradient — SwiftTerm
   uses its own hero wallpaper, blurred past recognition. */
.brand-aura.is--image {
  inset: -30%;
  background-size: cover;
  background-position: center;
  opacity: 0.72;
  filter: blur(90px) brightness(0.5) saturate(1.1);
}

/* --- Two-column body ----------------------------------------------------- */
.projects-body {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: clamp(1.5rem, 4vw, 4rem);
  width: 100%;
  margin: auto 0;
}

.projects-body .list-container {
  margin: 0;
}

/* --- Preview pane -------------------------------------------------------- */
.preview-pane {
  /* The pane keeps one footprint for every project. The *frame* inside it is
     what reshapes, so the list never shifts under the pointer mid-hover —
     a resizing column made the items jump and the hover flicker. */
  flex: 0 0 auto;
  width: clamp(360px, 46%, 660px);
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  opacity: 0.5;
  transition: opacity 0.45s ease;
}

/* Frame + controls + caption as one column, so the caption is always as wide
   as the frame — including when the frame turns portrait. */
.preview-stack {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  width: 100%;
}

.preview-stack.is--portrait {
  width: auto;
}

.preview-pane.is--live {
  opacity: 1;
}

.preview-frame {
  position: relative;
  width: 100%;
  margin: 0 auto;
  aspect-ratio: var(--frame-aspect, 16 / 11);
  border-radius: 16px;
  overflow: hidden;
  isolation: isolate;
  border: 1px solid rgba(255, 255, 255, 0.09);
  background-color: #000000;
  background-image:
    radial-gradient(120% 95% at 18% 12%, var(--brand-a, transparent) 0%, transparent 58%),
    radial-gradient(130% 100% at 88% 88%, var(--brand-b, transparent) 0%, transparent 62%),
    radial-gradient(90% 80% at 60% 40%, var(--brand-c, transparent) 0%, transparent 70%);
  box-shadow: 0 40px 90px -50px rgba(0, 0, 0, 0.95);
  transition: border-color 0.6s ease;
}

/* Phone captures: derive the width from a capped height so the frame turns
   portrait inside a pane that stays the same width. */
.preview-frame.is--portrait {
  width: auto;
  height: min(62vh, 580px);
  max-width: 100%;
}

/* --- Scenes -------------------------------------------------------------- */
.scene {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  /* Only opacity is transitioned. Transitioning `visibility` alongside it left
     the wrong scene painted on touch viewports. */
  transition: opacity 0.5s ease;
  pointer-events: none;
  overflow: hidden;
}

.scene.is--active {
  opacity: 1;
  visibility: visible;
}

.scene canvas {
  display: block;
  width: 100%;
  height: 100%;
}

.scene-vignette {
  position: absolute;
  inset: 0;
  background: radial-gradient(125% 125% at 50% 50%, transparent 42%, rgba(0, 0, 0, 0.6) 100%);
}

/* --- Caption --------------------------------------------------------------
   One style for every project, sitting *under* the frame rather than over it.
   Nothing is drawn on top of the screenshots, so nothing has to be dimmed to
   keep the copy legible. */
.preview-caption {
  margin: 0;
  width: 100%;
  padding: 0;
  font-size: clamp(0.92rem, 1.15vw, 1.06rem);
  line-height: 1.45;
  letter-spacing: -0.01em;
  color: #ffffff;
  text-align: left;
  background: none;
  opacity: 0;
  transform: translateY(6px);
  pointer-events: none;
  transition: opacity 0.5s ease, transform 0.5s ease, color 0.4s ease;
}

.preview-caption.is--on {
  opacity: 1;
  transform: none;
}

/* --- Empty state --------------------------------------------------------- */
.preview-empty {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  color: #8e8e93;
  /* Never eat a click meant for the carousel controls underneath. */
  pointer-events: none;
  transition: opacity 0.4s ease;
}

.preview-empty.is--hidden {
  opacity: 0;
}

.preview-empty__mark {
  font-size: 1.3rem;
  line-height: 1;
}

.preview-empty__label {
  font-size: 0.74rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

/* ==========================================================================
   PAGE-WIDE SIGNATURE EFFECTS
   Each project's own site effect, played across the whole portfolio.
   ========================================================================== */

/* SentinalCore · pixel merge / unmerge, behind the copy */
.page-glitch {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.6s ease;
}

.page-glitch.is--on {
  opacity: 1;
}

/* LNReader · pixelated petals, over the copy — the way the real site does it */
.page-petals {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 40;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.6s ease;
}

.page-petals.is--on {
  opacity: 1;
}

/* Traverse · the screen-wide chroma burst, once per selection */
.page-chroma {
  position: fixed;
  left: 50%;
  top: 50%;
  /* Same 430vmax square the real site uses. */
  width: 430vmax;
  height: 430vmax;
  transform: translate(-50%, -50%) scale(5.75);
  transform-origin: 78% 50%;
  opacity: 0;
  pointer-events: none;
  z-index: 90;
  will-change: transform, opacity;
  background: radial-gradient(
    ellipse 30% 25% at 80% 50%,
    transparent 0%,
    transparent 35%,
    rgb(20, 90, 230) 50%,
    rgb(255, 255, 255) 57%,
    rgb(255, 255, 255) 64%,
    rgb(255, 190, 20) 70%,
    rgb(240, 40, 50) 77%,
    rgb(255, 182, 193) 46%,
    transparent 100%
  );
  filter: blur(65px);
}

@keyframes pageChromaCollapse {
  0%   { opacity: 1; transform: translate(-50%, -50%) scale(10); }
  90%  { opacity: 1; }
  100% { opacity: 0; transform: translate(-50%, -50%) scale(0.2); }
}

/* Zoth · two thin lines that trace themselves across the page background.
   The trace is a stroke-dashoffset reveal, so the line is drawn rather than
   faded in — same idea as the hero edges sweeping in on zoth-landing. */
.page-lines {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.5s ease;
}

.page-lines.is--on {
  opacity: 1;
}

.zline {
  fill: none;
  stroke: rgba(255, 255, 255, 0.5);
  stroke-width: 1;
  stroke-linecap: round;
  /* --len is measured per path in JS so the reveal finishes exactly at the end. */
  stroke-dasharray: var(--len, 1400);
  stroke-dashoffset: var(--len, 1400);
}

.page-lines.is--on .zline {
  animation: zlineTrace 2.4s cubic-bezier(0.42, 0, 0.2, 1) forwards;
}

.page-lines.is--on .zline:nth-child(2) {
  animation-delay: 0.18s;
}

@keyframes zlineTrace {
  from { stroke-dashoffset: var(--len, 1400); }
  to   { stroke-dashoffset: 0; }
}

/* ==========================================================================
   SCENE 01 — Traverse · hero shot in the box (burst plays page-wide)
   ========================================================================== */
.scene--traverse {
  display: flex;
  align-items: center;
  justify-content: center;
}

.traverse-shot {
  position: absolute;
  inset: 0;
}

.traverse-shot img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
}

/* ==========================================================================
   SCENE 02 — Zoth · olive glow + light sweeping the hero screenshot
   ========================================================================== */
.scene--zoth {
  display: flex;
  align-items: center;
  justify-content: center;
}

.zoth-glow {
  position: absolute;
  left: 50%;
  top: 56%;
  width: 150%;
  height: 135%;
  transform: translate(-50%, -50%);
  background: radial-gradient(
    ellipse at center,
    rgba(136, 146, 123, 0.95) 0%,
    rgba(136, 146, 123, 0.55) 34%,
    rgba(121, 128, 113, 0.22) 60%,
    transparent 88%
  );
  filter: blur(34px);
  animation: zothGlowPulse 7s ease-in-out infinite;
}

@keyframes zothGlowPulse {
  0%, 100% { opacity: 0.72; }
  50%      { opacity: 1; }
}

.zoth-shot {
  position: relative;
  width: 84%;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(237, 236, 233, 0.14);
  box-shadow:
    0 40px 90px -34px rgba(0, 0, 0, 0.95),
    0 0 70px -14px rgba(136, 146, 123, 0.4);
  transform: translateY(3%);
}

.zoth-shot img {
  display: block;
  width: 100%;
  height: auto;
}

.zoth-edge {
  position: absolute;
  inset: 0;
  border-radius: 12px;
  padding: 1px;
  opacity: 0.8;
  background: linear-gradient(
    130deg,
    rgba(255, 255, 255, 0.55) 0%,
    transparent 26%,
    transparent 74%,
    rgba(214, 209, 162, 0.45) 100%
  );
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask-composite: exclude;
}

/* ==========================================================================
   SCENE 03 — LNReader iOS · real phone screens, stepped with the arrows
   ========================================================================== */
.scene--lnreader {
  background: #000;
}

.shot-track {
  position: absolute;
  inset: 0;
}

.shot {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  opacity: 0;
  transition: opacity 0.45s ease;
}

.shot.is--active {
  opacity: 1;
}

.scene--lnreader .petal-canvas {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
}

/* Controls sit in the column *under* the frame, never on the screenshot. */
.shot-controls {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 0.85rem;
}

.shot-controls.is--on {
  display: flex;
}

.shot-count {
  color: #999999;
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.shot-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  color: #ffffff;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.shot-btn:hover {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.45);
}

.shot-btn:active {
  transform: scale(0.92);
}

.shot-btn:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.8);
  outline-offset: 2px;
}

.shot-btn svg {
  width: 15px;
  height: 15px;
}

/* ==========================================================================
   SCENE 04 — SentinalCore · pixel merge / unmerge glitch
   ========================================================================== */
.scene-scanlines {
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    to bottom,
    rgba(11, 255, 129, 0.06) 0 1px,
    transparent 1px 3px
  );
  mix-blend-mode: screen;
  opacity: 0.55;
}

/* The box would otherwise be an empty grid of pixels — say what it won. */
.sentinal-badge {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  text-align: center;
  pointer-events: none;
}

.sentinal-badge__count {
  font-size: clamp(2.6rem, 5.2vw, 4rem);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.04em;
  color: #0bff81;
  text-shadow: 0 0 34px rgba(11, 255, 129, 0.45);
}

.sentinal-badge__label {
  font-size: 0.76rem;
  font-weight: 500;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: #8dffc4;
}

/* ==========================================================================
   SCENE 05 — macTilt · its own site hero, slow metal sheen
   ========================================================================== */
.scene--mactilt {
  display: flex;
  align-items: center;
  justify-content: center;
}

.mactilt-shot {
  position: absolute;
  inset: 7% 6% 24%;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 30px 70px -30px rgba(0, 0, 0, 0.95);
}

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

/* macTilt · the lid fold, page-wide.
   Three backdrop-filter bands ride the viewport from top to bottom. Because
   each band's backdrop includes the ones already painted, the blur compounds
   as the group passes — content frosts over and comes back sharp, with no
   fade to black.

   Nothing above these bands may animate opacity, clip-path or filter: any of
   those makes the ancestor a backdrop root and the blur silently stops
   sampling the page. Visibility is the only thing toggled up here. */
.page-fold {
  position: fixed;
  inset: 0;
  z-index: 95;
  pointer-events: none;
  visibility: hidden;
}

.page-fold.is--on {
  visibility: visible;
  animation: foldHold 1.9s steps(1, end) forwards;
}

.fold-band {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  backdrop-filter: blur(var(--b));
  -webkit-backdrop-filter: blur(var(--b));
  will-change: transform;
}

.fold-band:nth-child(1) {
  height: 92vh;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 42%, #000 58%, transparent 100%);
  mask-image: linear-gradient(to bottom, transparent 0%, #000 42%, #000 58%, transparent 100%);
}

.fold-band:nth-child(2) {
  height: 58vh;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 38%, #000 62%, transparent 100%);
  mask-image: linear-gradient(to bottom, transparent 0%, #000 38%, #000 62%, transparent 100%);
}

.fold-band:nth-child(3) {
  height: 30vh;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 32%, #000 68%, transparent 100%);
  mask-image: linear-gradient(to bottom, transparent 0%, #000 32%, #000 68%, transparent 100%);
}

.page-fold.is--on .fold-band {
  animation: foldTravel 1.9s cubic-bezier(0.45, 0, 0.25, 1) forwards;
}

@keyframes foldTravel {
  from { transform: translateY(-100vh); }
  to   { transform: translateY(100vh); }
}

@keyframes foldHold {
  0%   { visibility: visible; }
  99%  { visibility: visible; }
  100% { visibility: hidden; }
}

/* ==========================================================================
   SCENE 06 — SwiftTerm · the mark pops in and bounces
   ========================================================================== */
.scene--swiftterm {
  display: flex;
  align-items: center;
  justify-content: center;
  padding-bottom: 34%;
}

.swiftterm-shot {
  position: absolute;
  inset: 0;
}

.swiftterm-shot img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
}

/* The hero is bright artwork, so it gets dimmed just enough for the white copy. */
.swiftterm-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.42) 0%,
    rgba(0, 0, 0, 0.56) 55%,
    rgba(0, 0, 0, 0.8) 100%
  );
}

.term-icon {
  position: relative;
  z-index: 2;
  width: clamp(84px, 14vw, 138px);
  color: #ffffff;
  animation: iconPop 3.8s cubic-bezier(0.2, 0.9, 0.3, 1.25) infinite;
  filter: drop-shadow(0 0 26px rgba(255, 255, 255, 0.28));
}

.term-icon svg {
  display: block;
  width: 100%;
  height: auto;
}

@keyframes iconPop {
  0%        { opacity: 0; transform: translateY(26px) scale(0.55); }
  14%       { opacity: 1; transform: translateY(-14px) scale(1.1); }
  22%       { transform: translateY(0) scale(1); }
  30%       { transform: translateY(-8px) scale(1.03); }
  38%       { transform: translateY(0) scale(1); }
  80%       { opacity: 1; transform: translateY(0) scale(1); }
  94%, 100% { opacity: 0; transform: translateY(18px) scale(0.6); }
}

/* ==========================================================================
   Preview · responsive
   ========================================================================== */
@media screen and (max-width: 980px) {
  .projects-body {
    flex-direction: column;
    align-items: stretch;
    gap: 1.75rem;
  }

  .preview-pane {
    width: 100%;
    max-width: 100%;
  }

  .preview-stack {
    width: 100%;
    gap: 0.85rem;
  }

  /* Portrait frames take their width from a capped height, so the phone
     screenshots stay whole instead of being cropped to fit a box. */
  .preview-frame.is--portrait {
    width: auto;
    height: min(56vh, 450px);
    margin: 0 auto;
  }
}

@media screen and (max-width: 600px) {
  .section {
    padding: 2.5rem 1.25rem;
  }

  .section-header {
    gap: 0.5rem;
  }

  .preview-frame.is--portrait {
    height: min(50vh, 390px);
  }

  .preview-caption {
    font-size: 0.95rem;
  }

  .item-title {
    font-size: clamp(1.9rem, 9.5vw, 2.6rem);
  }

  .item-meta {
    font-size: 0.95rem;
  }

  .shot-btn {
    width: 34px;
    height: 34px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .page-chroma,
  .zoth-glow,
  .term-icon {
    animation: none !important;
  }
}
