:root {
  --coral: #ed3e30;
  --cream: #ffe4b4;
  --peach: #f6c986;
  --ink: #171716;
  --muted: #514332;
  --serif: Georgia, 'Times New Roman', serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 24px; }
body { overflow-x: clip; margin: 0; background: var(--cream); color: var(--ink); font: 1rem/1.6 Arial, Helvetica, sans-serif; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; }
button:focus-visible, a:focus-visible { outline: 3px solid var(--ink); outline-offset: 5px; }
.wrap { width: min(1296px, 89%); margin-inline: auto; }
header { background: var(--cream); border-bottom: 1px solid #17171630; }
.bar, .brand, nav, .label, .dialog-head, footer { display: flex; align-items: center; }
.bar { min-height: 88px; justify-content: space-between; gap: 20px; }
.brand { gap: 14px; }
.brand b { font: bold 2.5rem/.9 var(--serif); letter-spacing: -.11em; }
.brand b span { color: var(--coral); }
.brand strong { font-size: .94rem; }
nav { gap: 32px; }
nav a, footer a { font-size: .95rem; }
nav a:hover, footer a:hover { text-decoration: underline; text-underline-offset: 5px; }
.hero { position: relative; display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 5%; min-height: 620px; padding-block: 64px; isolation: isolate; }
.hero::before { content: ''; position: absolute; inset: 0 calc((100% - 100vw) / 2); z-index: -2; background: var(--coral); }
.intro { padding-block: 15px; color: var(--cream); }
.label, .meta, .dialog-head span { font-size: .875rem; letter-spacing: .07em; }
.label { gap: 12px; }
.label i { width: 22px; height: 2px; background: currentColor; }
h1, h2, h3, p { margin: 0; }
h1 { max-width: 590px; font: 500 clamp(3rem, 5.25vw, 5.2rem)/1.03 var(--serif); letter-spacing: -.055em; margin: 24px 0 20px; }
h1 em { font-weight: 500; }
h1 span { color: var(--ink); }
.hero-rule { width: min(270px, 75%); height: 1px; background: var(--cream); margin: 22px 0 18px; }
.intro .label { color: var(--ink); }
.intro p { color: var(--ink); max-width: 370px; font-size: 1.12rem; line-height: 1.65; }
.cta { display: inline-block; background: var(--ink); color: var(--cream); padding: 14px 24px; margin-top: 28px; font-size: .95rem; font-weight: bold; border-radius: 2px; transition: background .2s; }
.cta:hover { background: #393028; }
.intro a:focus-visible { outline-color: var(--cream); }
.canvas { position: relative; aspect-ratio: 1.07; }
.hero-disc { position: absolute; inset: -5% -4% 1% 0; background: var(--peach); border-radius: 48% 52% 36% 64% / 51% 40% 60% 49%; transform: rotate(-8deg); }
.hero-main { position: absolute; width: 94%; top: 11%; left: -3%; transform: rotate(-7deg); border: 7px solid var(--cream); box-shadow: 8px 16px 24px #51221338; }
.hero-detail { position: absolute; width: 42%; right: 0; bottom: -1%; transform: rotate(8deg); border: 6px solid var(--cream); box-shadow: 8px 16px 24px #51221338; }
.projects { padding-block: 70px 80px; }
h2 { font: 500 clamp(2.3rem, 4.3vw, 4.3rem)/1.08 var(--serif); letter-spacing: -.045em; }
h2 span { color: var(--coral); }
.heading h2 { font-style: italic; }
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; margin-top: 38px; }
.card { text-align: left; border: 0; background: transparent; padding: 0 0 18px; border-bottom: 1px solid #17171645; }
.thumb { display: grid; place-items: center; aspect-ratio: 1.24; overflow: hidden; background: var(--peach); }
.thumb img { width: 100%; height: 100%; object-fit: contain; transition: transform .45s; }
.card:hover img { transform: scale(1.035); }
.meta { display: block; color: var(--muted); margin: 19px 0 5px; letter-spacing: .02em; }
.name { display: block; font: 500 clamp(1.7rem, 2.4vw, 2.5rem)/1.15 var(--serif); letter-spacing: -.035em; }
.card-description { display: block; margin-top: 9px; color: var(--muted); font-size: .96rem; line-height: 1.55; }
.profile { display: grid; grid-template-columns: 1fr 2fr; gap: 30px; position: relative; isolation: isolate; padding-block: 75px; }
.profile::before { content: ''; position: absolute; inset: 0 calc((100% - 100vw) / 2); background: var(--peach); z-index: -1; }
.profile .label { padding-top: 12px; }
.profile h2 { font-style: italic; }
.profile p { font-size: 1.12rem; color: var(--muted); max-width: 680px; margin-top: 22px; }
footer { justify-content: space-between; gap: 20px; padding-block: 26px; }
footer > span { font: italic 1.25rem var(--serif); }
dialog { color: var(--ink); background: var(--cream); border: 0; border-top: 7px solid var(--coral); width: min(860px, 94%); max-height: 90dvh; padding: clamp(20px, 4vw, 44px); overscroll-behavior: contain; }
dialog::backdrop { background: #171716e8; }
.dialog-head { justify-content: space-between; gap: 20px; margin-bottom: 16px; }
.dialog-head button { background: var(--ink); color: var(--cream); border: 0; border-radius: 50%; width: 44px; height: 44px; flex-shrink: 0; font-size: 1.8rem; line-height: 1; }
dialog p { color: var(--muted); margin: 18px 0 28px; }
dialog figure { margin: 0; }
dialog figure img { display: block; width: auto; max-width: 100%; height: auto; max-height: 60dvh; margin: 0 auto; object-fit: contain; }
dialog figcaption { color: var(--muted); text-align: center; font-size: .875rem; margin-top: 10px; }
.gallery-controls { display: flex; align-items: center; justify-content: space-between; margin: 0 0 16px; }
.gallery-controls button { width: 42px; height: 42px; border: 0; border-radius: 50%; background: var(--ink); color: var(--cream); font-size: 1.25rem; }
.gallery-controls span { color: var(--muted); font-size: .9rem; font-variant-numeric: tabular-nums; }
body:has(dialog[open]) { overflow: hidden; }
@media (max-width: 900px) {
  .hero { min-height: 520px; }
  .cards { gap: 20px; }
}
@media (min-width: 768px) and (max-width: 1023px) {
  .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 767px) {
  .bar { min-height: 76px; gap: 12px; }
  .brand { gap: 10px; }
  .brand strong { max-width: 85px; line-height: 1.2; font-size: .875rem; }
  nav { gap: 18px; }
  .hero { grid-template-columns: 1fr; gap: 34px; padding-block: 40px 55px; }
  h1 { font-size: clamp(2.8rem, 12vw, 4.4rem); }
  .canvas { width: 91%; margin: 0 auto; }
  .hero-main { top: 12%; }
  .projects { padding-block: 48px; }
  .cards { grid-template-columns: 1fr; gap: 32px; margin-top: 28px; }
  .thumb { aspect-ratio: 1.24; }
  .name { font-size: 2rem; }
  .profile { grid-template-columns: 1fr; gap: 20px; padding-block: 48px; }
  .profile .label { padding-top: 0; }
  .profile p { font-size: 1rem; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .thumb img, .cta { transition: none; }
}
