/* Final presentation layer. Existing content and components remain authoritative. */
:root{--ease:200ms cubic-bezier(.2,.8,.2,1);--focus:#d2edb8}
:root.light{--focus:#285633}
.hero{column-gap:clamp(36px,6vw,88px)}
.hero h1{max-width:15ch;line-height:1.08}
.intro,.about-copy p,.workflow p,.project-body p,.project-facts dd{max-width:65ch}
.portrait{padding-top:24px}
.portrait img{border-radius:100px 20px 4px 4px}
.section-heading h2,.about h2,.workflow h2,.experience h2{max-width:20ch}
.section-heading>.section-heading{min-width:0}
.project-body,.hero-copy,.about-copy,.timeline{min-width:0}
.project-body h3,.timeline h3,.skill-grid h3{overflow-wrap:anywhere}
.brand{min-height:44px}
nav a{position:relative}
nav a::after{content:'';position:absolute;bottom:2px;left:0;width:100%;height:2px;background:var(--accent);transform:scaleX(0);transform-origin:left;transition:transform var(--ease)}
nav a:hover::after,nav a:focus-visible::after{transform:scaleX(1)}
:focus-visible{outline:3px solid var(--focus);outline-offset:5px}
.button:active{transform:translateY(0)}
#project-list:not(.project-reader) .project{transition:border-color var(--ease),box-shadow var(--ease)}
#project-list:not(.project-reader) .project-body{background:var(--panel)}
#project-list:not(.project-reader) .project-facts{gap:18px}
#project-list:not(.project-reader) .project-facts dt{font-size:13px}
#project-list:not(.project-reader) .case-link{gap:8px}
.image-open{transition:transform 240ms cubic-bezier(.16,1,.3,1)}
.asset-caption{overflow-wrap:anywhere}
.real-gallery .image-open:focus-visible{outline-offset:3px}
.reader-nav{flex-wrap:wrap}
.project-reader .project-body>p{max-width:65ch}
.project-reader .project-facts{border-left:3px solid var(--accent)}
.skill-grid article{padding-block:32px}
.contact .actions{row-gap:16px}
@media(hover:hover) and (pointer:fine){
 #project-list:not(.project-reader) .project:hover{border-color:var(--accent);box-shadow:0 12px 32px #0000000d}
 .image-open:hover{transform:translateY(-2px)}
 .filters button:hover,#theme:hover,#language:hover{background:var(--panel)}
 .filters button[aria-pressed=true]:hover{background:var(--accent)}
}
@media(min-width:1001px){
 #project-list:not(.project-reader){grid-template-columns:1.08fr .92fr;column-gap:40px;row-gap:40px}
 #project-list:not(.project-reader) .project.featured{grid-template-columns:1.12fr 1fr;padding:16px;gap:24px}
 #project-list:not(.project-reader) .compact:nth-child(odd){margin-top:48px}
 .about,.workflow,.experience{grid-template-columns:.85fr 1.35fr}
 .portrait-label{padding-left:20px;border-left:1px solid var(--line);margin-top:16px}
}
@media(max-width:680px){
 .hero h1{max-width:100%;font-size:clamp(34px,8.8vw,52px)}
 .portrait{padding-top:0}.portrait img{border-radius:24px 4px 4px 4px}
 .hero .eyebrow{flex-wrap:wrap}.hero .eyebrow span:last-child{min-width:0;overflow-wrap:anywhere}
 #project-list:not(.project-reader) .project-body h3{font-size:clamp(25px,7.5vw,30px)}
 .project-reader .project-body h3{font-size:clamp(29px,8.5vw,36px)}
 .project-reader .real-gallery{top:auto}
 .project-reader .project-facts{padding:18px}
 .tags span{overflow-wrap:anywhere;max-width:100%}
 .reader-nav span{letter-spacing:.04em}
}
@media(prefers-reduced-motion:reduce){
 *,*::before,*::after{transition:none!important;animation:none!important}
 nav a::after{transition:none}.image-open:hover,.button:hover{transform:none}
}

/* Project media has its own layout: no percentage heights or legacy illustration classes. */
.ui-icon{display:inline-block;width:1.15em;height:1.15em;flex:none;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round;vertical-align:-.16em}
.tags [data-icon],.media-demo summary{display:inline-flex;align-items:center;gap:8px}
a>.ui-icon{margin-left:.35em}.reader-nav a>.ui-icon{margin:0 .35em 0 0}
#theme{display:grid;place-items:center}
.project-media{min-width:0;padding:18px;background:var(--media);align-self:stretch;border-radius:8px}
.media-grid{display:grid;gap:18px;min-width:0}
.media-grid figure{margin:0;min-width:0}
.media-open{display:block;width:100%;padding:0;border:0;border-radius:6px;background:transparent;position:relative;cursor:zoom-in;line-height:0}
.media-open img{display:block;width:100%;height:auto;max-width:100%;border-radius:6px}
.media-zoom{position:absolute;right:10px;bottom:10px;display:grid;place-items:center;width:34px;height:34px;border-radius:50%;background:var(--bg);color:var(--ink);border:1px solid var(--line);line-height:1}
.media-credit,.media-grid figcaption{font-size:12px;line-height:1.5;color:var(--muted);margin:14px 0 0;text-align:left;max-width:65ch}
.media-portrait .media-grid{grid-template-columns:1fr 1fr;align-items:start;justify-items:center}
.media-portrait figure{width:100%;max-width:300px}
#project-list:not(.project-reader) .project-media{border-radius:0;display:flex;flex-direction:column;justify-content:center}
#project-list:not(.project-reader) .media-open{aspect-ratio:16/10;display:grid;place-items:center}
#project-list:not(.project-reader) .media-open img{width:100%;height:100%;object-fit:contain;min-height:0}
#project-list:not(.project-reader) .media-portrait .media-open{aspect-ratio:390/844;height:340px;max-width:100%}
#project-list:not(.project-reader) .project.featured{grid-template-columns:1.2fr 1fr;align-items:center}
#project-list:not(.project-reader) .featured .project-media{border-radius:6px;align-self:center}
.project-reader .project{display:block}
.project-reader .project-body{max-width:100%}
.project-reader .project-media{margin:30px 0;max-width:100%}
.project-reader .media-grid{grid-template-columns:1fr}
.project-reader .media-portrait .media-grid{grid-template-columns:repeat(2,minmax(0,1fr));max-width:680px;margin:auto}
.project-reader .media-open img{max-height:80vh;object-fit:contain}
.media-demo{width:100%}.media-demo summary{cursor:pointer;min-height:48px;font-size:15px}
.media-demo video{display:block;width:100%;max-height:75vh;background:#101b15;border-radius:6px}
.media-demo p{font-size:13px;margin-top:12px}
/* Keep the image inside the dialog padding, including narrow mobile viewports. */
#lightbox{width:min(1000px,94vw);overflow-x:hidden}
#lightbox img{max-width:100%;width:auto;height:auto}
#lightbox p{overflow-wrap:anywhere}
@media(max-width:800px){#project-list:not(.project-reader) .project.featured{grid-template-columns:1fr}#project-list:not(.project-reader) .featured .project-media{align-self:stretch}}
@media(max-width:680px){.project-media{padding:12px}#project-list:not(.project-reader) .media-portrait .media-open{height:auto;max-height:340px}.media-zoom{width:28px;height:28px;right:6px;bottom:6px}.media-credit{font-size:12px}.project-reader .project{display:block}}
