
.works-theme .grid{gap:40px;align-items:start}
.works-theme .card{background:#fff;min-height:0;grid-template-columns:minmax(0,1fr);overflow:hidden}
.works-theme .card .content{padding:28px;grid-column:1;grid-row:2}
.works-theme .card h2{font-size:28px;line-height:1.2;margin:0 0 16px;display:block;overflow:visible;text-wrap:balance}
.works-theme .card .description{font-size:16px;line-height:1.6;display:block;overflow:visible;max-width:60ch;margin:0 0 28px;color:#51494b;text-wrap:pretty}
.works-theme .card .role{font-size:13px;line-height:1.6;display:block;overflow:visible;margin:12px 0 24px;color:#51494b}
.works-theme .card-heading{margin:0;height:44px}
.works-theme .card .bottom{padding-top:20px;gap:12px}
.works-theme .skill-label,.works-theme .card-challenges{font-size:12px;line-height:1.6}
.works-theme .card-challenges{display:flex!important}
.works-theme .preview{grid-column:1;grid-row:1;min-height:0;aspect-ratio:16/10;border-left:0;border-bottom:1px solid #00000015}
.works-theme .preview img{object-fit:contain;padding:20px;box-sizing:border-box}
.works-theme .card-arrow{display:none}
.works-theme .card::before{display:none}
.works-theme .card:hover,.works-theme .card:hover .preview img{transform:none}
.works-theme .card-link:after{content:'View project ↗';position:absolute;right:24px;bottom:20px;font:12px/1.6 var(--mono);background:white;padding:8px;color:var(--palette-accent)}
.works-theme .bottom{padding-bottom:44px}
.works-theme main{padding-bottom:160px}

.works-theme .grid{grid-template-columns:minmax(0,1fr)}
@media(min-width:900px){.works-theme .grid{grid-template-columns:repeat(2,minmax(0,1fr))}.works-theme .card .content{padding:32px}}


/* Feedback for the image-first project link. */
.works-theme .card-link:after{content:none}
.works-theme .card-link{touch-action:manipulation}
.works-theme .project-action{position:absolute;right:24px;bottom:20px;display:inline-flex;align-items:center;justify-content:center;gap:12px;min-height:44px;padding:10px 16px;box-sizing:border-box;border:1px solid #087f8c;border-radius:6px;background:#fff;color:#087f8c;font:500 12px/1.5 var(--mono);pointer-events:none;transition:background-color 150ms ease-out,color 150ms ease-out,transform 150ms ease-out}
.works-theme .project-action-icon{display:inline-block;font-size:18px;line-height:1;transition:transform 150ms ease-out}
.works-theme .card .bottom{padding-bottom:60px}
@media(hover:hover) and (pointer:fine){
 .works-theme .card-link:hover .project-action{background:#087f8c;color:#fff}
 .works-theme .card-link:hover .project-action-icon{transform:translate(2px,-2px)}
}
.works-theme .card-link:active .project-action{background:#087f8c;color:#fff;transform:scale(.97)}
.works-theme .card-link:focus-visible .project-action{background:#087f8c;color:#fff;outline:2px solid #24262b;outline-offset:3px;transition:none;transform:none}
.works-theme .card-link:focus-visible .project-action-icon{transition:none;transform:none}
@media(prefers-reduced-motion:reduce){
 .works-theme .card-link .project-action,.works-theme .card-link .project-action-icon{transition:none;transform:none}
 .works-theme .card-link:hover .project-action-icon,.works-theme .card-link:active .project-action{transform:none}
}


/* Compact image-first cards: shared tracks keep every action aligned. */
.works-theme .grid{gap:24px;grid-template-columns:minmax(0,1fr);align-items:stretch}
.works-theme .card{display:grid;grid-template-rows:210px 1fr;height:100%;box-shadow:0 2px 8px #00000005}
.works-theme .preview{height:210px;aspect-ratio:auto}
.works-theme .card .content{display:grid;grid-template-rows:86px 72px 36px 42px 76px;gap:8px;padding:24px}
.works-theme .card h2{font-size:24px;line-height:1.18;margin:0;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:3;overflow:hidden;text-wrap:pretty}
.works-theme .card .description{font-size:15px;line-height:1.6;margin:0;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:3;overflow:hidden}
.works-theme .card-heading,.works-theme .logo-badge{height:36px;margin:0}
.works-theme a.logo-badge{min-height:44px}
.works-theme .card .role{font-size:12px;line-height:1.6;margin:0;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden}
.works-theme .card .bottom{margin:0;padding:12px 0 0;align-content:start;display:flex;gap:8px}
.works-theme .card .card-challenges{display:none!important}
.works-theme .project-action{right:24px;bottom:20px}
@media(min-width:700px){.works-theme .grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(min-width:1200px){.works-theme .grid{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(forced-colors:active){.works-theme .card{border:1px solid CanvasText}}
