/* Motion preferences and responsive layout rules. */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .marquee-track {
    animation: none;
  }

  .btn {
    transition: none;
  }

  .product-shot,
  .light-toggle,
  .light-toggle::before,
  .light-icon {
    transition: none;
  }

  .axis-ring {
    animation: none !important;
  }

  .part,
  .model-axis,
  .axis-ring,
  .model-note {
    transition: none;
  }
}

@media (max-width: 1100px) {
  :root {
    --topbar-offset: 116px;
  }

  .topbar {
    grid-template-columns: auto minmax(0, 1fr);
    justify-items: stretch;
    gap: clamp(18px, 3vw, 32px);
  }

  .nav-links {
    justify-content: center;
    flex-wrap: nowrap;
    gap: clamp(14px, 2.1vw, 28px);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .exploded-board,
  .proof-layout,
  .story-board,
  .cta-box {
    grid-template-columns: 1fr;
  }

  .editorial-head {
    grid-template-columns: 1fr;
  }

  .collection-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .details-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .detail-card:nth-child(2) {
    border-right: 0;
  }

  .detail-card:nth-child(3),
  .detail-card:nth-child(4) {
    border-top: var(--hairline);
  }

  .part-callouts {
    align-content: stretch;
  }

  .step {
    grid-template-columns: 1fr;
    grid-template-rows: auto minmax(188px, auto);
    min-height: auto;
  }

  .step-art {
    aspect-ratio: 1 / 1;
    min-height: 0;
    border-right: 0;
    border-bottom: var(--line);
  }

  .drop-merch {
    grid-template-columns: 138px minmax(0, 1fr);
  }

  .callout::before {
    display: none;
  }

}

@media (max-width: 760px) {
  :root {
    --topbar-offset: 24px;
  }

  .topbar {
    position: relative;
    grid-template-columns: 1fr;
    gap: 10px;
    padding: 10px;
  }

  .brand-lockup {
    justify-content: space-between;
  }

  .nav-links {
    justify-content: flex-start;
    gap: 10px 18px;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .hero {
    min-height: auto;
    grid-template-rows: auto minmax(720px, auto) auto;
  }

  .hero-stage {
    min-height: 720px;
  }

  .hero-photo img {
    object-position: 56% center;
  }

  .hero-photo::after {
    background:
      linear-gradient(0deg, rgba(0, 0, 0, 0.88) 0%, rgba(0, 0, 0, 0.46) 56%, rgba(0, 0, 0, 0.12) 100%),
      linear-gradient(90deg, rgba(0, 0, 0, 0.32), rgba(0, 0, 0, 0.08));
  }

  .hero-content {
    width: calc(100% - 32px);
    min-height: 720px;
    gap: 18px;
    padding: 28px 0 132px;
  }

  .hero-float-cta {
    display: none;
  }

  .hero h1 {
    max-width: 100%;
    font-size: clamp(34px, 10.2vw, 48px);
    line-height: 1;
    text-shadow: 3px 3px 0 var(--ink);
  }

  .hero-lede {
    font-size: 16px;
  }

  .proof-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, max-content));
    align-items: flex-start;
    gap: 10px 16px;
  }

  .proof-chip {
    font-size: 17px;
  }

  .sticker-note {
    display: none;
  }

  .section {
    padding: 58px 16px;
  }

  .section-title,
  .proof-copy h2 {
    font-size: 48px;
  }

  .story-main h2,
  .cta-copy h2 {
    font-size: 56px;
  }

  .story-main::after {
    right: -30px;
    bottom: 16px;
    font-size: 44px;
  }

  .section-copy {
    font-size: 16px;
  }

  .exploded-board,
  .how-grid,
  .collection-grid,
  .details-grid,
  .proof-layout,
  .photo-grid,
  .story-gallery,
  .story-board {
    gap: 12px;
  }

  .collection-grid {
    grid-template-columns: 1fr;
  }

  .style-card {
    grid-template-rows: 230px auto;
  }

  .model-zone {
    min-height: 500px;
  }

  .exploded-board.has-inline-notes .model-zone {
    min-height: 680px;
  }

  .model-zone::after {
    right: 12px;
    bottom: 14px;
    font-size: 32px;
  }

  .model-toolbar {
    align-items: center;
    flex-direction: row;
    top: 12px;
    left: 12px;
    right: 12px;
    gap: 8px;
  }

  .model-kicker {
    max-width: calc(100% - 88px);
  }

  .model-canvas-shell {
    inset: 74px 12px 28px;
  }

  .model-zone::before {
    inset: 0;
  }

  .model-note {
    width: min(44%, 164px);
    padding: 8px 9px 9px;
    box-shadow: 2px 2px 0 rgba(17, 17, 17, 0.15);
    --note-h: 26px;
    --note-d: 42px;
  }

  .model-note strong {
    font-size: 18px;
  }

  .model-note p {
    margin-top: 4px;
    font-size: 10.5px;
    line-height: 1.18;
  }

  .model-note-cone {
    top: 4%;
    right: 2%;
    --note-line-y: 60%;
    --note-angle: -18deg;
  }

  .model-note-topper {
    top: 25%;
    left: 2%;
    --note-line-y: 48%;
    --note-angle: 18deg;
  }

  .model-note-core {
    top: 57%;
    right: 2%;
    --note-line-y: 42%;
    --note-angle: 14deg;
  }

  .model-note-strap {
    top: 76%;
    left: 2%;
    --note-line-y: 38%;
    --note-angle: -16deg;
  }

  .exploded-model {
    inset: 92px -56px 32px;
    transform: scale(0.76);
  }

  .axis-ring {
    width: 330px;
    height: 96px;
  }

  .model-label {
    display: none;
  }

  .model-label strong {
    font-size: 28px;
  }

  .exploded-board.is-exploded .bun-top { --x: -4px; --y: -118px; --z: 48px; --rx: 8deg; --r: -5deg; }
  .exploded-board.is-exploded .lettuce { --x: 4px; --y: -88px; --z: 40px; --rx: 10deg; --r: -5deg; }
  .exploded-board.is-exploded .tomato { --x: -4px; --y: -58px; --z: 34px; --rx: 10deg; --r: -5deg; }
  .exploded-board.is-exploded .cheese { --x: 4px; --y: -26px; --z: 24px; --rx: 10deg; --r: -5deg; }
  .exploded-board.is-exploded .light-core { --x: -2px; --y: 30px; --z: 12px; --rx: 12deg; --r: -5deg; }
  .exploded-board.is-exploded .base-unit { --x: 2px; --y: 84px; --z: -18px; --rx: 8deg; --r: -5deg; }
  .exploded-board.is-exploded .mount-rail { --x: 0; --y: 96px; --z: -28px; --rx: 8deg; --r: -5deg; }

  .part-callouts {
    padding: 12px;
  }

  .drop-merch {
    grid-template-columns: 96px minmax(0, 1fr);
    gap: 10px;
  }

  .drop-merch img {
    height: 126px;
  }

  .drop-merch strong {
    font-size: 32px;
  }

  .callout {
    min-height: auto;
  }

  .step {
    grid-template-columns: 1fr;
    grid-template-rows: auto minmax(188px, auto);
    min-height: auto;
  }

  .step-art {
    aspect-ratio: 1 / 1;
    min-height: 0;
    border-right: 0;
    border-bottom: var(--line);
  }

  .step-art img {
    max-height: none;
  }

  .manual-illustration svg {
    min-height: 330px;
  }

  .install-artboard {
    min-height: auto;
    padding: 8px;
  }

  .install-sheet {
    display: none;
  }

  .install-crop-grid {
    position: relative;
    z-index: 1;
    display: grid;
    gap: 8px;
  }

  .install-crop {
    position: relative;
    display: grid;
    place-items: center;
    min-height: 240px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.42);
    border: var(--hairline);
    border-radius: var(--radius-md);
  }

  .install-crop span {
    position: absolute;
    top: 8px;
    right: 8px;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: var(--taxi);
    color: var(--ink);
    border: var(--line);
    border-radius: 50%;
    font: 900 19px/1 "Barlow Condensed", Arial, sans-serif;
  }

  .install-crop img {
    width: 100%;
    height: clamp(220px, 68vw, 280px);
    padding: 8px;
    object-fit: contain;
    filter: contrast(1.2) saturate(1.12);
  }

  .details-grid,
  .proof-note-grid {
    grid-template-columns: 1fr;
  }

  .detail-card,
  .detail-card:nth-child(2),
  .detail-card:nth-child(3),
  .detail-card:nth-child(4) {
    border-right: 0;
    border-top: var(--hairline);
  }

  .detail-card:first-child {
    border-top: 0;
  }

  .proof-copy {
    min-height: auto;
  }

  .story-gallery {
    --story-main-height: clamp(260px, 76vw, 320px);
  }

  .story-gallery-main {
    height: var(--story-main-height);
  }

  .story-gallery-thumbs {
    gap: 6px;
    padding-bottom: 5px;
  }

  .story-thumb {
    flex-basis: clamp(70px, 24vw, 92px);
    width: clamp(70px, 24vw, 92px);
  }

  .photo-tile,
  .photo-tile.large {
    grid-column: auto;
    min-height: 230px;
  }

  .photo-grid {
    grid-template-columns: 1fr;
  }

  .cta-copy,
  .story-main {
    padding: 22px;
  }

  .cta-form-link {
    align-items: flex-start;
    flex-direction: column;
    min-height: 0;
    padding: 20px 22px;
    font-size: 46px;
  }

  .cta-form-link::after {
    width: 52px;
    height: 52px;
    box-shadow: 2px 2px 0 var(--white);
    font-size: 34px;
  }

  .footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .footer-links {
    justify-content: flex-start;
  }

  .site-shell {
    padding-bottom: 86px;
  }

  .mobile-preorder {
    position: fixed;
    left: 10px;
    right: 10px;
    bottom: 10px;
    z-index: 90;
    display: grid;
    grid-template-columns: 1fr;
    align-items: center;
    gap: 10px;
    min-height: 64px;
    padding: 9px 10px;
    background: var(--signal-red);
    color: var(--white);
    border: var(--line);
    border-radius: var(--radius-lg);
    box-shadow: 3px 3px 0 var(--ink);
    overflow: hidden;
  }

  .mobile-preorder div {
    display: none;
  }

  .mobile-preorder strong,
  .mobile-preorder span {
    display: block;
  }

  .mobile-preorder strong {
    font: 900 13px/1 "Barlow Condensed", Arial, sans-serif;
    text-transform: uppercase;
  }

  .mobile-preorder span {
    margin-top: 4px;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.1;
  }

  .mobile-preorder a {
    position: static;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 0 10px;
    background: transparent;
    color: var(--white);
    border: 0;
    border-radius: 0;
    text-decoration: none;
    font: 900 16px/1 "Barlow Condensed", Arial, sans-serif;
    text-align: center;
    text-transform: uppercase;
    white-space: nowrap;
  }
}

@media (max-width: 640px) {
  .how-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 420px) {
  .brand-mark {
    width: 46px;
    height: 46px;
  }

  .nav-links a {
    min-height: 34px;
    font-size: 15px;
    line-height: 1;
  }

  .hero h1 {
    font-size: clamp(34px, 10.2vw, 42px);
  }

  .model-note {
    width: min(45%, 148px);
  }

  .model-note p {
    font-size: 10px;
  }

}
