/* Portrait project stories: a responsive 1080 × 1920 (9:16) composition. */
.story-page { margin: 0; min-height: 100svh; padding: 12px; display: grid; place-items: center; background: #070708; color: #f4f3f1; }
.story-modal { position: fixed; inset: 0; margin: 0; padding: 12px; width: 100%; height: 100%; max-width: none; max-height: none; border: 0; background: #070708f5; color: #f4f3f1; overflow: auto; overscroll-behavior: contain; }
.story-modal[open] { display: grid; place-items: center; }
.story-modal::backdrop { background: #000b; backdrop-filter: blur(16px); }
html.story-is-open { overflow: hidden; }
.story-viewer { --story-cream: #fff6ec; --story-berry: #8b1752; --story-orange: #ec651b; position: relative; isolation: isolate; width: min(1080px, calc(100vw - 24px)); margin: auto; font-family: Gilroy, sans-serif; }
.story-viewer.is-ready { width: min(1080px, calc(100vw - 24px), calc((100svh - 24px) * .5625)); aspect-ratio: 9 / 16; }
.story-viewer *, .story-viewer *::before, .story-viewer *::after { box-sizing: border-box; }
.story-viewer h1, .story-viewer h2, .story-viewer p, .story-viewer figure { margin: 0; }
.story-viewer a { color: inherit; text-decoration: none; }
.story-viewer.is-ready::before, .story-viewer.is-ready::after { content: ''; position: absolute; z-index: 2; left: 0; right: 0; pointer-events: none; border-radius: 16px; }
.story-viewer.is-ready::before { top: 0; height: 20%; background: linear-gradient(#000b, #0005 40%, transparent); }
.story-viewer.is-ready::after { bottom: 0; height: 27%; background: linear-gradient(0deg, #000e, #0009 45%, transparent); }
.story-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 44px; }
.is-ready .story-top { position: absolute; z-index: 4; top: 30px; left: 16px; right: 12px; color: #fff; }
.story-project { display: flex; align-items: baseline; gap: 12px; min-width: 0; }
.story-project strong { font-weight: 500; font-size: 17px; line-height: 1.15; letter-spacing: -.025em; }
.story-project > span { display: none; }
.story-close { display: inline-flex; align-items: center; justify-content: center; gap: 9px; min-width: 44px; min-height: 44px; font-size: 11px; flex-shrink: 0; }
.story-close > span:last-child { font-size: 27px; font-weight: 400; line-height: 1; }
.story-segments { display: none; }
.is-ready .story-segments { position: absolute; z-index: 4; top: 5px; left: 16px; right: 16px; display: grid; grid-template-columns: repeat(5, 1fr); gap: 5px; }
.story-segment { display: flex; align-items: center; height: 24px; padding: 0; border: 0; background: transparent; cursor: pointer; }
.story-segment > span { display: block; height: 2px; width: 100%; background: #ffffff60; border-radius: 3px; overflow: hidden; }
.story-segment i { display: block; height: 100%; width: 100%; transform: scaleX(0); transform-origin: left; background: #fff; }
.story-segment.is-past i { transform: scaleX(1); }
.story-segment[aria-current="step"] i { transform: scaleX(var(--story-progress, 1)); background: #fff; }
.story-canvas { position: relative; container-type: inline-size; isolation: isolate; }
.is-ready .story-canvas { aspect-ratio: 9 / 16; height: 100%; overflow: hidden; border-radius: 16px; background: var(--story-cream); touch-action: pan-y pinch-zoom; }
.story-frame { position: relative; display: grid; aspect-ratio: 9 / 16; overflow: hidden; background: var(--story-cream); color: var(--story-berry); }
.story-frame[hidden] { display: none !important; }
.is-ready .story-frame { width: 100%; height: 100%; aspect-ratio: auto; }
.story-frame picture { display: block; min-width: 0; min-height: 0; }
.story-frame img { display: block; width: 100%; height: 100%; object-fit: cover; }
.story-photo { overflow: hidden; }
.story-copy { display: flex; flex-direction: column; justify-content: center; align-items: flex-start; padding: 7%; }
.story-kicker { font-size: clamp(9px, 2.6cqw, 22px); line-height: 1.4; letter-spacing: .11em; text-transform: uppercase; opacity: .75; }
.story-frame h2 { font-weight: 800; font-size: 11.5cqw; line-height: .95; letter-spacing: -.045em; text-transform: uppercase; text-wrap: balance; }
.story-copy .story-kicker { margin-bottom: 4cqw; }
.story-copy > p:last-child { margin-top: 4cqw; max-width: 28ch; font-size: 3.4cqw; line-height: 1.5; opacity: .85; }
.story-hero { grid-template-columns: 1fr; grid-template-rows: 46% 54%; background: var(--story-berry); color: var(--story-cream); }
.story-hero .story-copy { padding: 23cqw 8% 7cqw; justify-content: center; }
.story-hero .story-copy > p:last-child { display: none; }
.story-hero .story-photo img { object-position: 42% 48%; }
.story-mark { padding: 28cqw 7% 34cqw; grid-template-rows: auto 1fr auto; }
.story-mark .story-photo { width: 100%; margin: 0 auto; }
.story-mark img { object-fit: contain; }
.story-mark-bottom p { font-size: 7cqw; line-height: 1.1; letter-spacing: -.025em; }
.story-palette { display: flex; gap: 4cqw; list-style: none; margin: 5cqw 0 0; padding: 0; }
.story-palette li { display: flex; align-items: center; gap: 1.6cqw; font-size: 2.9cqw; }
.story-palette i { width: 3cqw; height: 3cqw; border-radius: 50%; border: 1px solid #8b175230; }
.story-palette .berry { background: var(--story-berry); }
.story-palette .orange { background: var(--story-orange); }
.story-palette .cream { background: var(--story-cream); }
.story-detail { grid-template-columns: 1fr; grid-template-rows: 45% 55%; background: #fff; }
.story-detail .story-copy { padding: 25cqw 8% 3cqw; }
.story-detail h2 { font-size: 11cqw; }
.story-detail .story-copy > p:last-child { display: none; }
.story-detail .story-photo { padding: 0 7% 29cqw; }
.story-detail img { object-fit: contain; }
.story-food .story-photo { position: absolute; inset: 0; }
.story-food .story-photo img { object-position: 51% 50%; }
.story-food::after { content: ''; position: absolute; inset: 30% 0 0; background: linear-gradient(0deg, #23130aba, transparent); pointer-events: none; }
.story-food .story-copy { position: relative; z-index: 1; align-self: end; padding: 7% 8% 35cqw; color: #fff6ec; }
.story-food h2 { font-size: 13cqw; }
.story-food .story-copy .story-kicker { opacity: .95; }
.story-people { grid-template-columns: 1fr; grid-template-rows: 59% 41%; }
.story-people .story-photo { padding-top: 22cqw; background: #282021; }
.story-people .story-photo img { object-position: 48% 36%; }
.story-people .story-copy { justify-content: flex-start; padding: 5cqw 8% 30cqw; }
.story-people h2 { font-size: 9.1cqw; }
.story-people .story-copy .story-kicker { margin-bottom: 3cqw; }
.story-people .story-copy > p:last-child { display: none; }
/* Project-specific editorial stories keep the supplied artwork intact. */
.story-curated { grid-template-rows: auto minmax(0, 1fr) auto; gap: 5cqw; padding: 25cqw 0 30cqw; background: var(--project-paper); color: var(--project-ink); }
.story-curated-dark { background: var(--project-ink); color: var(--project-paper); }
.story-curated-accent { background: var(--project-accent); color: var(--project-accent-ink); }
.story-curated-heading { padding-inline: 8%; }
.story-curated-heading .story-kicker { margin-bottom: 3cqw; }
.story-curated h2 { font-size: 9cqw; line-height: 1.04; letter-spacing: -.035em; text-transform: none; text-wrap: balance; }
.story-curated .story-photo { min-height: 0; align-self: stretch; }
.story-curated .story-photo img { object-fit: contain; }
.story-curated-note { padding-inline: 8%; font-size: 3.6cqw; line-height: 1.45; text-wrap: pretty; opacity: .85; }
.story-curated-note:empty { display: none; }
.story-curated-accent :is(.story-curated-note, .story-kicker) { opacity: 1; }
.story-curated-tall { grid-template-rows: auto minmax(0, 1fr); padding-top: 25cqw; padding-bottom: 27cqw; gap: 4cqw; }
.story-curated-tall h2 { font-size: 7cqw; }
.story-curated-tall .story-curated-note { display: none; }
.story-bottom { display: flex; flex-direction: column; align-items: stretch; gap: 8px; padding-block: 12px; }
.is-ready .story-bottom { position: absolute; z-index: 4; bottom: 12px; left: 14px; right: 14px; padding: 0; color: #fff; }
.story-caption { min-width: 0; }
.story-caption p { display: flex; gap: 10px; align-items: baseline; font-size: 11px; line-height: 1.4; }
.story-caption [data-story-count] { color: #ffffffad; font-size: 10px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.story-caption > span { display: none; }
.story-actions { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.story-case-link { display: inline-flex; align-items: center; gap: 9px; min-height: 44px; font-size: 11px; white-space: nowrap; }
.story-transport { display: none; align-items: center; gap: 5px; }
.is-ready .story-transport { display: flex; }
.story-control { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; flex-shrink: 0; padding: 0; border: 1px solid #ffffff50; border-radius: 50%; background: #16131955; color: #fff; font: inherit; font-size: 18px; cursor: pointer; }
.story-control:disabled { opacity: .35; cursor: default; }
.story-auto-icon { font-size: 12px; }
.story-auto-label { display: none; }
.story-control:hover:not(:disabled) { background: #ffffff30; }
.story-viewer :is(a, button):focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
.story-segment:focus-visible { outline-offset: 0; }
.story-sr { position: absolute; width: 1px; height: 1px; clip-path: inset(50%); overflow: hidden; white-space: nowrap; }
.story-frame.is-entering { animation: story-arrive .45s cubic-bezier(.2,.7,.2,1) both; }
.story-frame.is-entering .story-photo img { animation: story-image-arrive .85s cubic-bezier(.2,.7,.2,1) both; }
@keyframes story-arrive { from { opacity: .3; transform: translateX(calc(var(--story-direction, 1) * 8px)); } to { opacity: 1; transform: none; } }
@keyframes story-image-arrive { from { transform: scale(1.015); } to { transform: scale(1); } }
.no-motion .story-frame, .no-motion .story-frame img { animation: none !important; }

/* Compact vertical covers let several projects share the viewport. */
#work .work-grid { --project-width: clamp(210px, 20vw, 280px); --project-gap: clamp(12px, 1.5vw, 22px); align-items: flex-start; }
#work .work-visual { aspect-ratio: 9 / 16; border-radius: 14px; }
#work .work-art-primary { object-fit: var(--story-cover-fit, cover); object-position: var(--story-cover-focus, 50% 50%); }
#work .work-card .work-art-secondary { display: none; }
#work .work-caption { display: flex; flex-direction: column; align-items: flex-start; gap: 5px; padding-top: 15px; }
#work .work-caption > div { min-height: 72px; }
#work .work-caption h3 { font-size: clamp(1rem, 1.35vw, 1.2rem); line-height: 1.2; font-weight: 500; letter-spacing: -.015em; }
#work .work-caption p { font-size: .75rem; line-height: 1.45; margin-top: 6px; }
#work .work-number { display: none; }
#work .work-open { font-size: .75rem; min-height: 32px; }
.work-story-badge { position: absolute; z-index: 3; left: 10px; right: 10px; top: 10px; display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 9px 8px; border: 1px solid #ffffff42; border-radius: 30px; background: #161319c9; color: #fff6ec; backdrop-filter: blur(12px); font-size: 9px; letter-spacing: .025em; text-transform: uppercase; }
.work-story-badge svg { width: 12px; height: 12px; flex-shrink: 0; fill: none; stroke: currentColor; stroke-width: 1.5; }
.work-card[data-story-open][aria-busy="true"] { cursor: progress; }
@media (max-width: 700px) {
  .story-page, .story-modal { padding: max(6px, env(safe-area-inset-top)) 0 max(6px, env(safe-area-inset-bottom)); }
  .story-viewer, .story-viewer.is-ready { width: min(100vw, calc((100svh - max(6px, env(safe-area-inset-top)) - max(6px, env(safe-area-inset-bottom))) * .5625)); }
  .is-ready .story-canvas, .story-viewer.is-ready::before, .story-viewer.is-ready::after { border-radius: 8px; }
  .story-case-link > span { display: none; }
  #work .work-grid { --project-width: clamp(146px, 45vw, 220px); --project-gap: 12px; }
  #work .work-caption > div { min-height: 78px; }
  #work .work-caption h3 { font-size: 1rem; }
  #work .work-visual { border-radius: 11px; }
}
@media (max-height: 520px) and (orientation: landscape) {
  /* A narrow portrait still remains 9:16. Extra controls move beside it. */
  .story-modal, .story-page { padding: 6px 72px; overflow: visible; }
  .story-viewer.is-ready { width: min(calc(100vw - 144px), calc((100svh - 12px) * .5625)); }
  .is-ready .story-top { top: 0; left: calc(100% + 20px); right: auto; flex-direction: column; gap: 4px; }
  .story-close > span:first-child { display: none; }
  .story-project strong { font-size: 13px; }
  .is-ready .story-segments { left: 10px; right: 10px; top: 2px; }
  .is-ready .story-bottom { bottom: 10px; left: 10px; right: 10px; }
  .story-caption { display: none; }
  .story-transport { position: absolute; left: calc(100% + 20px); bottom: 0; flex-direction: column; }
  .story-case-link { font-size: 10px; }
}
@media (prefers-reduced-motion: reduce) { .story-frame, .story-frame img { animation: none !important; } }

/* V24: lead with the selected application, keep captions secondary. */
.story-curated, .story-curated-tall { display:block; padding:0; background:var(--project-paper); color:var(--project-ink); }
.story-curated .story-photo { position:absolute; inset:13% 0 17%; width:100%; height:auto; }
.story-curated .story-photo img { object-fit:contain; }
.story-curated-heading { position:absolute; z-index:1; left:0; right:0; bottom:26cqw; padding:0 7%; }
.story-curated-heading .story-kicker, .story-curated-note { display:none; }
.story-curated h2, .story-curated-tall h2 { font-size:5.2cqw; font-weight:500; line-height:1.15; letter-spacing:-.015em; }
.story-curated-tall .story-photo { inset:0; }
.story-curated-tall .story-photo img { object-fit:cover; }
.story-curated-tall .story-curated-heading { color:#fff; text-shadow:0 2px 15px #000; }
.story-curated-tall::after { content:''; position:absolute; inset:60% 0 0; background:linear-gradient(transparent,#0009); pointer-events:none; }
.story-viewer[data-story-viewer="wingers"] .story-frame:nth-child(1) .story-photo,
.story-viewer[data-story-viewer="wingers"] .story-frame:nth-child(2) .story-photo,
.story-viewer[data-story-viewer="wingers"] .story-frame:nth-child(4) .story-photo { inset:0; }
.story-viewer[data-story-viewer="wingers"] .story-frame:nth-child(1) img,
.story-viewer[data-story-viewer="wingers"] .story-frame:nth-child(2) img,
.story-viewer[data-story-viewer="wingers"] .story-frame:nth-child(4) img { object-fit:cover; }
.story-viewer[data-story-viewer="wingers"] .story-curated-heading { color:white; text-shadow:0 2px 10px #000; }

/* V25: one reviewed hero, with per-image framing and no inherited split layout. */
#work .work-card[data-cover-layout="hero"] .work-visual { background:var(--work-mat); isolation:isolate; }
#work .work-card[data-cover-layout="hero"] .work-visual > .work-cover-photo { display:block; position:absolute; inset:0; width:100%; height:100%; background:var(--cover-bg); }
#work .work-card[data-cover-layout="hero"] .work-art-primary { display:block; position:absolute; left:50%; top:50%; width:calc(100% * var(--cover-scale,1)); height:calc(100% * var(--cover-scale,1)); object-fit:var(--cover-fit,cover); object-position:var(--cover-x,50%) var(--cover-y,50%); transform:translate(-50%,-50%); opacity:1; }
#work .work-card[data-cover-layout="hero"]:hover .work-art-primary { transform:translate(-50%,-50%); opacity:1; }
#work .work-story-badge { left:auto; right:10px; top:auto; bottom:10px; width:auto; padding:7px 10px; gap:10px; border:1px solid #ffffff35; border-radius:20px; font-size:9px; line-height:1; letter-spacing:.02em; text-transform:none; background:#101013b5; }
#work .work-story-badge span { font-size:13px; }
