/* Chapter headings and content share the site's inset; artwork may bleed. */
:root { --page-gutter: max(var(--grid-gutter), var(--site-safe-inline)); }
.awards-heading, .awards-exhibitions { margin-inline: var(--page-gutter); }
.navbar2.n2-compact:not(.is-docked) { padding-inline: var(--page-gutter); }

.browse-hint {
  position: fixed;
  z-index: 31;
  inset: auto 0 max(14px, calc(env(safe-area-inset-bottom, 0px) + 8px));
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: max-content;
  min-height: 44px;
  margin-inline: auto;
  padding: 6px 15px;
  border: 1px solid #ffffff38;
  border-radius: 999px;
  background: #090a09ed;
  color: #f2f0e9;
  font: 500 13px/1.3 var(--font);
  cursor: pointer;
}
.browse-hint[hidden], .is-project-opening .browse-hint, .portfolio-dialog-open .browse-hint { display: none; }
.browse-hint > [aria-hidden] { color: #00ffce; font-size: 17px; }

/* Compact compositions follow the available space, including iPad Split View. */
@media (max-width: 1100px) and (orientation: portrait), (max-width: 960px) and (max-height: 500px) {
  :root { --grid-gutter: clamp(16px, 4.6vw, 48px); }

  #interlude.yarn-intro { min-height: 0; }
  .work-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px clamp(12px, 3vw, 28px); }
  .collection-heading { align-items: start; gap: 12px; }
  .collection-toolbar { align-items: start; flex-direction: column; gap: 10px; }
  .collection-count { margin-left: 0; font-size: 12px; }
  #collection .card-meta { font-size: 12px; }
}

@media (max-width: 1100px) and (orientation: portrait) {
  .hero {
    height: clamp(288px, 78vw, 57svh);
    min-height: 0;
  }

  .hero-vignette { background: linear-gradient(to bottom, #090a093b, transparent 24%, transparent 42%, #090a09e6); }
  .hero-identity {
    right: var(--page-gutter);
    bottom: clamp(34px, 7vw, 100px);
    max-width: none;
    transform: none;
    opacity: 1;
  }
  .hero .dot-title { font-size: clamp(42px, 15vw, 156px); }
  .hero-role-row { flex-wrap: wrap; gap: 8px 12px; }
  .hero-role { font-size: 14px; }
  .hero-tagline { font-size: 11px; line-height: 1.5; }

  .about-layout.about-layout--centered { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px; }
  .about-layout--centered > .about-portrait.has-lanyard {
    grid-column: 1 / -1;
    grid-row: 1;
    height: clamp(300px, 70vw, 620px);
  }
  .viewing-project .project-intro { grid-template-columns: 1fr; gap: 24px; }
  .project-intro .project-description { font-size: 15px; }
}

@media (max-width: 600px) and (orientation: portrait) {
  .work-grid, .about-layout.about-layout--centered { grid-template-columns: minmax(0, 1fr); }
  .about-lanyard-controls > .about-lanyard-caption { font-size: 10px; }
}

@media (max-width: 720px) and (orientation: portrait) {
  :root {
    --grid-gutter: clamp(16px, 4.8vw, 28px);
    --phone-chapter-space: 64px;
    --phone-content-space: 24px;
  }

  .work-section, .about-section, .awards-section { padding-block: var(--phone-chapter-space); }
  .collection-heading, .about-head { margin-bottom: var(--phone-content-space); }
  .collection-toolbar {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    justify-content: stretch;
    gap: 12px;
    padding: 0;
    margin: 0 0 var(--phone-content-space);
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
  }
  .filter-tabs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 12px;
  }
  .filter-tab {
    justify-content: start;
    min-height: 44px;
    min-width: 0;
    padding: 8px;
    border: 0;
    border-bottom: 1px solid var(--control-line);
    border-radius: 0;
    background: transparent;
    color: var(--ink);
    font-size: 13px;
    line-height: 1.4;
    text-align: start;
    overflow-wrap: anywhere;
  }
  .filter-tab:hover, .filter-tab.is-active {
    background: color-mix(in srgb, var(--aux) 8%, transparent);
    color: var(--aux);
    border-color: var(--aux);
    transform: none;
  }
  .filter-tab:active { transform: scale(.98); }
  .collection-count { justify-self: end; margin: 0; }
  .collection-count::before { display: none; }
  .work-grid { row-gap: 32px; }
  .has-cinematic-scroll .work-grid, .has-cinematic-scroll .about-layout {
    scale: 1;
    transform: translateY(calc((1 - var(--scene-enter)) * 24px));
  }
  #collection .card-info { padding-inline: 0; }
  .studio-footer .studio-footer-layout { padding-top: var(--phone-chapter-space); }
}

@media (max-width: 960px) and (max-height: 500px) and (orientation: landscape) {
  .hero { min-height: 360px; }
  .hero-identity { bottom: 58px; max-width: calc(100% - var(--page-gutter) * 2); }
  .hero .dot-title { font-size: clamp(40px, 10vw, 96px); }
}

@media (any-pointer: coarse) and (max-width: 1366px) {
  .tech-title, .studio-footer-wordmark, .awards-loop { touch-action: pan-y pinch-zoom; }
  .navbar2 .n2-mobile-toggle { min-width: 44px; min-height: 44px; }
  .filter-tab, .about-lanyard-controls > .about-lanyard-flip { min-height: 44px; }
  .studio-footer-inquiry input { min-height: 30px; font-size: 16px; }
  .studio-footer .studio-footer-socials a, .studio-footer-navigation a { min-height: 44px; }
  .studio-footer-navigation a { display: inline-flex; align-items: center; gap: 6px; }
}

