/* Hallmark · pre-emit critique: P5 H5 E4 S5 R5 V4
 * Curated portfolio; preserves the existing Merlotart brand and homepage sections. */
@import url('tokens.css?v=3');

html, body { overflow-x: clip; }
.selected-work, .work-page { color: var(--work-ink); font-family: var(--work-body); }
.selected-work { background: var(--work-paper); padding: 1rem 1.5rem 4rem; text-align: left; }
.selected-work-inner { max-width: var(--work-width); margin-inline: auto; }
#text18[data-selected-heading] { font-size: clamp(3rem, 7vw, 5.5rem); overflow-wrap: anywhere; }
.selected-intro { font-size: 1.25rem; line-height: 1.5; margin: 0 0 2rem; text-align: center; }
.work-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2.5rem 2rem; padding: 0; margin: 0; list-style: none; }
@media (min-width: 1000px) {
  .selected-work .work-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
.work-card { min-width: 0; }
.work-card > a { display: block; text-decoration: none; color: inherit; }
.work-cover { display: flex; align-items: center; justify-content: center; aspect-ratio: 4 / 3; background: var(--work-panel); overflow: clip; }
.work-cover img { display: block; width: 100%; height: 100%; object-fit: contain; }
.work-card-copy { position: relative; padding: 1rem 0 0; }
.work-card h3 { margin: 0; font-family: var(--work-label); font-size: 1.5rem; font-weight: 400; font-style: normal; line-height: 1.3; overflow-wrap: anywhere; }
.work-card p { margin: 0.35rem 0 0; font-size: 1rem; line-height: 1.4; color: var(--work-muted); }
.work-card-action { display: inline-block; margin-top: 0.75rem; font-size: 1rem; color: var(--work-accent); white-space: nowrap; }
.work-card a:hover h3, .work-card a:focus-visible h3 { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 0.2em; }
.work-card a:active { opacity: 0.8; }
.selected-work a:focus-visible, .work-page a:focus-visible { outline: 3px solid var(--work-accent); outline-offset: 5px; }
.selected-more { padding-top: 3rem; text-align: center; }
.selected-more p { margin: 1rem 0 0; font-size: 1.1rem; line-height: 1.5; color: var(--work-muted); }
.work-button { display: inline-flex; align-items: center; justify-content: center; gap: 1rem; min-height: 48px; padding: 0.8rem 1.4rem; border: 1px solid var(--work-ink); color: var(--work-ink); background: var(--work-paper); font-family: var(--work-label); font-size: 1rem; line-height: 1.2; white-space: nowrap; text-decoration: none; }
.work-button:hover { background: var(--work-ink); color: var(--work-paper); }
.work-button:active { background: var(--work-accent); color: var(--work-white); }

/* Standalone project views use the same art-first styling without the homepage router. */
body.work-page { margin: 0; background: var(--work-paper); line-height: 1.5; font-size: 18px; }
.work-page *, .work-page *::before, .work-page *::after { box-sizing: border-box; }
.work-page a { color: inherit; text-underline-offset: 0.2em; }
.work-page h1, .work-page h2 { font-family: var(--work-display); font-weight: 400; font-style: normal; line-height: 1.1; min-width: 0; overflow-wrap: anywhere; }
.work-page h1 { font-size: clamp(2.8rem, 7vw, 5rem); margin: 0.5rem 0 1rem; }
.work-page h2 { font-size: clamp(2rem, 4vw, 3rem); margin: 0 0 1.5rem; }
.work-page-nav { max-width: calc(var(--work-width) + 3rem); margin: auto; padding: 1.5rem; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 1rem 2rem; border-bottom: 1px solid var(--work-line); }
.work-wordmark { font-family: var(--work-display); font-size: 2rem; line-height: 1; text-decoration: none; }
.work-page-nav nav { display: flex; align-items: center; flex-wrap: wrap; gap: 0.5rem 1.5rem; }
.work-page-nav nav a { display: inline-flex; align-items: center; min-height: 44px; white-space: nowrap; }
.work-skip { position: absolute; left: 1rem; top: -10rem; z-index: 10; padding: 1rem; background: var(--work-white); }
.work-skip:focus { top: 1rem; }
.work-archive, .project-main { max-width: calc(var(--work-width) + 3rem); margin: auto; padding: 3rem 1.5rem; }
.archive-heading { margin-bottom: 3rem; }
.archive-heading p, .project-intro { max-width: 40rem; font-size: 1.25rem; }
.work-categories { display: flex; flex-wrap: wrap; gap: 0.75rem 1.5rem; margin-top: 1.5rem; }
.work-categories a { white-space: nowrap; min-height: 44px; display: inline-flex; align-items: center; }
.work-category { margin-bottom: 4rem; scroll-margin-top: 1.5rem; }
.work-eyebrow { margin: 0; color: var(--work-muted); font-size: 1.1rem; }
.project-heading { margin-bottom: 2rem; }
.project-figure { margin: 0; min-width: 0; }
.project-figure > a { display: block; }
.project-figure img { display: block; max-width: 100%; width: auto; height: auto; margin: 0 auto; }
.project-lead { background: var(--work-panel); padding: 1.5rem; }
.project-lead img { max-height: 80vh; object-fit: contain; }
.project-figure figcaption, .project-video figcaption { margin-top: 0.75rem; font-size: 1rem; color: var(--work-muted); }
.project-lead figcaption { text-align: center; }
.project-support { margin-top: 3rem; }
.project-image-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2rem; align-items: start; }
.project-image-grid img { max-height: 44rem; object-fit: contain; }
.project-image-grid > :only-child { max-width: 42rem; grid-column: 1 / -1; justify-self: center; }
.project-video { margin: 2rem 0; }
.project-video iframe { display: block; width: 100%; aspect-ratio: 16 / 9; border: 0; }
.project-return { margin-top: 3rem; }
.work-footer { max-width: calc(var(--work-width) + 3rem); margin: 0 auto; padding: 2rem 1.5rem; border-top: 1px solid var(--work-line); font-size: 1rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.work-footer a { white-space: nowrap; }
.work-footer p { margin: 0; }
@media (max-width: 600px) {
  .work-grid, .project-image-grid { grid-template-columns: minmax(0, 1fr); }
  .selected-work { padding-inline: 1.25rem; }
  .work-page-nav, .work-archive, .project-main, .work-footer { padding-inline: 1.25rem; }
  .work-page-nav { align-items: flex-start; flex-direction: column; gap: 0.75rem; }
  .work-page-nav nav { gap: 0.5rem 1.25rem; }
  .project-lead { padding: 1rem; }
  .work-cover { aspect-ratio: 1 / 1; }
}
