/* ia3 — IA option 3, loaded after ia2.css. Dusk tokens unchanged.
   "What we do" (home #what-we-do, about #what-we-do) reuses .services-ia2 + .split from ia2/3dc-dusk,
   so no new layout rules are needed yet. Add ia3-only rules here, not in ia2.css. */

/* ---------- Press feedback, every page (moved from about-v2.css; emil-design-eng + mobile-native) ---------- */
:root { --ease-out: cubic-bezier(0.23, 1, 0.32, 1); }
.btn, .menu-list a, .zoom, .stretch { -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
.btn, .menu-list a, .zoom { -webkit-user-select: none; user-select: none; }
/* The `scale` property (not transform) so it stacks on the dock's translateY hide instead of replacing it */
.btn { transition: scale 100ms var(--ease-out), background-color 200ms ease, border-color 200ms ease; }
.btn.dock { transition: scale 100ms var(--ease-out), background-color 200ms ease, border-color 200ms ease, transform 0.3s ease, opacity 0.3s ease; }
.menu-list a { transform-origin: left center; transition: scale 100ms var(--ease-out), color 200ms ease; }
.index-thumb, .work-card-media, .ab-work-media, .zoom { transition: scale 100ms var(--ease-out); }
/* Press 160ms, release 100ms (exit faster than enter). Scale is movement, so none for reduced motion
   (base.css only shortens transitions; the scale itself would still apply). */
@media (prefers-reduced-motion: no-preference) {
  .btn:active, .menu-list a:active { scale: 0.97; transition-duration: 160ms, 200ms, 200ms; }
  .btn.dock:active { transition-duration: 160ms, 200ms, 200ms, 0.3s, 0.3s; }
  .index-item:active .index-thumb, .work-card:active .work-card-media, .ab-work:active .ab-work-media, .zoom:active { scale: 0.98; transition-duration: 160ms; }
}
/* Motionless press cue for everyone (incl. reduced motion on touch, where tap highlight and hover are off):
   same colours as the mouse-only hover rules in 3dc-dusk.css / base.css / ia2.css / about-v2.css */
.theme-c-dusk .btn-ghost:active { background: rgb(243 235 221 / 0.12); border-color: var(--accent-text); }
.theme-c-dusk .btn-cta:active { background: var(--accent-text); }
.menu-list a:active { color: var(--menu-accent, var(--accent-text)); }
.index-item:active .index-name, .work-card:active .work-card-title, .ab-work:active .ab-work-name { color: var(--accent-text); }
.zoom:active img { opacity: 0.9; }

/* ---------- Site refresh 2026-11-21: image presentation (palette unchanged, no new image files) ---------- */
/* Grain: one static fixed layer. z-index -1 puts it under all content but over the body background
   (propagated to the canvas), so cards, images and text sit on top of it. */
body::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none; opacity: 0.06;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E") 0 0 / 180px 180px;
}
@media (prefers-contrast: more), (forced-colors: active), (prefers-reduced-transparency: reduce) { body::before { display: none; } }

/* Card images: logos/artwork sit on the card with breathing room; photos fill the frame.
   shortcut: photos matched by file name (PH I MOA sign, rentsons tile); add a class if more photos arrive. */
:is(.index-thumb, .work-card-media, .ab-work-media) img { padding: 8%; }
:is(.index-thumb, .work-card-media, .ab-work-media) img:is([src$="/work-phmoa.webp"], [src$="/work-rentsons.webp"]) { padding: 0; object-fit: cover; }

/* Warm grade on list/card thumbnails only (detail pages show the work ungraded); original colour on hover, focus, press */
:is(.index-thumb, .work-card-media) img, .ab-work .ab-work-media img { filter: sepia(0.12) saturate(0.9) brightness(0.94); }
.index-thumb img { transition: transform 0.5s ease, filter 300ms ease; }
.work-card-media img { transition: transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1), filter 300ms ease; }
.ab-work .ab-work-media img { transition: transform 250ms var(--ease-out), filter 300ms ease; }
@media (hover: hover) and (pointer: fine) { :is(.index-item, .work-card, .ab-work):hover img { filter: none; } }
:is(.index-item, .work-card, .ab-work):is(:focus-within, :active) img { filter: none; }

/* Lead images: 16:10 frame on case pages; on phones the lead image runs edge to edge (negative gutter, no 100vw) */
@media (min-width: 600px) { .case-frame { aspect-ratio: 16 / 10; } } /* phones keep 4:3 from ia2.css */
/* Every frame holds its ratio and shows the whole image: shrinkable track + image, and min-height:0 drops the
   aspect-ratio auto minimum, so a square logo can neither stretch the frame nor be cropped by overflow:hidden */
.case-frame { min-height: 0; grid-template: minmax(0, 1fr) / minmax(0, 1fr); }
.case-frame img { min-width: 0; min-height: 0; }
@media (max-width: 759px) {
  .case-figure .case-frame, .work-card:first-child .work-card-media { margin-inline: calc(-1 * var(--gutter)); }
}
@media (min-width: 760px) and (max-width: 1023px) { .work-card:first-child .work-card-media { margin-inline: calc(-1 * var(--gutter)); } }
/* Case frames as presentation: website first screens get a decorative browser bar (no text, pseudo-element),
   logos sit on a board with a faint ivory highlight. Palette transparencies only, no amber, no motion. */
.case-frame--browser {
  --bar: 32px; position: relative; overflow: hidden; /* overflow clips the bar to the rounded corner */
  border-radius: var(--r-mid) 0 0 0; /* --r-big would swallow the bar's left end */
  padding-top: calc(var(--bar) + clamp(1rem, 4vw, 3.5rem));
}
.case-frame--browser::before {
  --dot: radial-gradient(circle, rgb(207 197 180 / 0.45) 3.5px, transparent 4px);
  content: ""; position: absolute; inset: 0 0 auto; height: var(--bar); box-shadow: inset 0 -1px 0 var(--line);
  background:
    var(--dot) var(--r-mid) 50% / 12px 12px no-repeat,
    var(--dot) calc(var(--r-mid) + 18px) 50% / 12px 12px no-repeat,
    var(--dot) calc(var(--r-mid) + 36px) 50% / 12px 12px no-repeat,
    rgb(243 235 221 / 0.06);
}
.case-frame:not(.case-frame--browser) { background: radial-gradient(ellipse 70% 65% at 50% 45%, rgb(243 235 221 / 0.07), transparent) var(--card); }
@media (prefers-contrast: more), (forced-colors: active) {
  .case-frame--browser::before { display: none; }
  .case-frame:not(.case-frame--browser) { background: var(--card); }
}
/* /phmoa: the hero photo bleeds off the right edge on desktop and both edges below 1024px.
   % padding = the main column width, so the text still lines up with .wrap and a scrollbar never adds overflow. */
.case-hero-c.wrap { max-width: none; padding-inline: max(var(--gutter), (100% - var(--max)) / 2 + var(--gutter)); }
.case-hero-c .case-photo figcaption { padding-inline: var(--gutter); }
@media (max-width: 1023px) { .case-hero-c .case-photo { margin-inline: calc(-1 * var(--gutter)); } }
@media (min-width: 1024px) {
  .case-hero-c.wrap { padding-right: 0; }
  .case-hero-c .case-photo { max-width: none; justify-self: stretch; }
  .case-hero-c .case-photo figcaption { padding-left: 0; }
}
