/* ==================================================================
   Svetlozar Apostolov — portfolio
   Blush light theme. Pink banner tone from the LinkedIn profile, plum accent, ink text.
   Newsreader (display) + DM Sans (interface) + IBM Plex Mono (figures).
   ================================================================== */

:root {
  --blush:     #fcf7fa;
  --blush-2:   #f6ebf1;
  --blush-3:   #ebd9e3;
  --banner:    #e0ccd8;
  --mauve:     #a58b96;
  --ink:       #2b2128;
  --ink-2:     #5e4f58;
  --ink-3:     #76666f;
  --rose:      #8a4b6b;
  --rose-2:    #6f3654;
  --rose-tint: #f1dfe8;
  --line:      #e6d3de;
  --line-soft: #f0e3ea;

  --sh-sm: 0 1px 2px rgba(70,40,58,.05);
  --sh:    0 1px 2px rgba(70,40,58,.04), 0 10px 30px -12px rgba(70,40,58,.16);
  --sh-lg: 0 2px 4px rgba(70,40,58,.04), 0 24px 60px -24px rgba(70,40,58,.24);

  --r-sm: 8px;
  --r:    16px;
  --r-lg: 24px;

  --measure: 66ch;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--blush);
  color: var(--ink);
  font-family: "DM Sans", ui-sans-serif, system-ui, sans-serif;
  font-size: 1.0625rem;
  line-height: 1.62;
  letter-spacing: -0.005em;
  -webkit-font-smoothing: antialiased;
}

::selection { background: var(--rose); color: #fff; }

a { color: inherit; }
:focus-visible { outline: 2px solid var(--rose-2); outline-offset: 3px; border-radius: 4px; }

img, svg { max-width: 100%; height: auto; display: block; }

/* ---------------- typography ---------------- */

h1, h2, h3, h4 {
  font-family: "Newsreader", Georgia, serif;
  font-weight: 400;
  line-height: 1.06;
  letter-spacing: -0.022em;
  margin: 0 0 .5em;
  text-wrap: balance;
}

h1 { font-size: clamp(2.7rem, 6.6vw, 5rem); }
h2 { font-size: clamp(2rem, 4vw, 3rem); }
h3 { font-size: clamp(1.4rem, 2.4vw, 1.85rem); line-height: 1.16; }
h4 { font-size: 1.2rem; line-height: 1.25; letter-spacing: -0.012em; }

p { margin: 0 0 1.15em; max-width: var(--measure); }
p:last-child { margin-bottom: 0; }

.lede { font-size: clamp(1.15rem, 1.9vw, 1.4rem); line-height: 1.5; color: var(--ink-2); }
.quiet { color: var(--ink-2); }

ul, ol { max-width: var(--measure); padding-left: 1.2rem; margin: 0 0 1.3em; }
li { margin-bottom: .55em; padding-left: .15rem; }
li::marker { color: var(--rose); }

strong { font-weight: 500; color: var(--ink); }

.num {
  font-family: "IBM Plex Mono", ui-monospace, monospace;
  font-feature-settings: "tnum" 1;
  letter-spacing: -0.02em;
}

.tag {
  display: inline-block;
  font-size: .8rem;
  line-height: 1;
  padding: .45rem .7rem;
  border-radius: 999px;
  background: var(--rose-tint);
  color: var(--rose-2);
  letter-spacing: 0;
}

/* ---------------- layout ---------------- */

.wrap { width: min(100% - 2.5rem, 72rem); margin-inline: auto; }
.narrow { width: min(100% - 2.5rem, 46rem); margin-inline: auto; }
.measure { max-width: var(--measure); }

section { padding-block: clamp(3.5rem, 8vw, 7rem); }

.rule { border: 0; border-top: 1px solid var(--line); margin: 0; }

.sec-head { margin-bottom: clamp(2rem, 4vw, 3.5rem); }
.sec-head h2 { margin-bottom: .35em; }

/* ---------------- header ---------------- */

.site-head {
  position: sticky; top: 0; z-index: 50;
  background: rgba(252, 247, 250, .86);
  backdrop-filter: saturate(1.5) blur(12px);
  -webkit-backdrop-filter: saturate(1.5) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s ease;
}
.site-head.stuck { border-bottom-color: var(--line); }

.site-head .bar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1.5rem; padding-block: 1.05rem;
}
.sig {
  font-family: "Newsreader", Georgia, serif;
  font-size: 1.3rem; letter-spacing: -.02em;
  text-decoration: none;
}
.site-head nav { display: flex; gap: 1.6rem; font-size: .95rem; }
.site-head nav a { color: var(--ink-2); text-decoration: none; transition: color .15s ease; }
.site-head nav a:hover { color: var(--ink); }
.site-head nav a[aria-current="page"] {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--rose);
  text-underline-offset: 6px;
  text-decoration-thickness: 2px;
}

/* ---------------- buttons ---------------- */

.btn {
  display: inline-flex; align-items: center; gap: .5rem;
  font: inherit; font-size: .98rem;
  padding: .78rem 1.35rem;
  border-radius: 999px;
  text-decoration: none;
  border: 1px solid transparent;
  transition: background .16s ease, border-color .16s ease, transform .16s ease;
}
.btn-primary { background: var(--rose); color: #fff; }
.btn-primary:hover { background: var(--rose-2); transform: translateY(-1px); }
.btn-ghost { border-color: var(--line); color: var(--ink); background: transparent; }
.btn-ghost:hover { background: var(--blush-2); border-color: var(--blush-3); }

/* ---------------- hero ---------------- */

.hero { background: var(--banner); padding-block: clamp(3rem, 7vw, 5.5rem); }
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, .9fr);
  gap: clamp(2rem, 6vw, 5rem);
  align-items: center;
}
.hero h1 { max-width: 24ch; margin-bottom: .34em; }
.hero .lede { max-width: 50ch; color: var(--ink); }
.hero .tag { background: rgba(255,255,255,.55); color: var(--rose-2); }
.hero-actions { display: flex; gap: .75rem; flex-wrap: wrap; margin-top: 2rem; }
.hero .btn-ghost { border-color: var(--mauve); }
.hero .btn-ghost:hover { background: rgba(255,255,255,.5); border-color: var(--rose); }

.motif { position: relative; width: 100%; max-width: 22rem; margin-inline: auto; aspect-ratio: 360 / 300; }
.piece { position: absolute; cursor: grab; touch-action: none; user-select: none; -webkit-user-select: none; transform: translate(var(--x, 0px), var(--y, 0px)); will-change: transform; }
.piece svg { display: block; width: 100%; height: 100%; overflow: visible; animation: drift var(--dur, 8s) ease-in-out var(--d, 0s) infinite; }
.piece.dragging { cursor: grabbing; }
.piece.dragging svg { animation-play-state: paused; }
@keyframes drift {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  33%      { transform: translate(4px, -9px) rotate(1.2deg); }
  66%      { transform: translate(-5px, 5px) rotate(-1deg); }
}
@media (prefers-reduced-motion: reduce) { .piece svg { animation: none; } }
.motto { margin: 1.5rem 0 0; font-size: 1.05rem; max-width: none; color: var(--ink); }
.motto span { display: block; color: var(--ink-2); }

.rise { animation: rise .7s cubic-bezier(.2,.7,.3,1) backwards; }
.rise:nth-child(1) { animation-delay: .04s; }
.rise:nth-child(2) { animation-delay: .12s; }
.rise:nth-child(3) { animation-delay: .2s; }
.rise:nth-child(4) { animation-delay: .28s; }
.rise:nth-child(5) { animation-delay: .36s; }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } }
@media (prefers-reduced-motion: reduce) { .rise { animation: none; } }

/* experience */
.roles { list-style: none; padding: 0; margin: 0; max-width: 48rem; }
.roles li { margin: 0; padding: 0 0 1.6rem 1.9rem; position: relative; border-left: 1px solid var(--blush-3); }
.roles li:last-child { padding-bottom: 0; border-left-color: transparent; }
.roles li::before { content: ""; position: absolute; left: -5px; top: .5rem; width: 9px; height: 9px; border-radius: 50%; background: var(--rose); }
.roles h3 { margin-bottom: .05em; font-size: 1.25rem; }
.roles .meta { font-size: .85rem; color: var(--ink-3); margin-bottom: .5rem; }
.roles ul { padding-left: 1.1rem; margin: 0; }
.roles ul li { padding: 0 0 0 .15rem; border: 0; margin-bottom: .3em; color: var(--ink-2); font-size: .94rem; line-height: 1.5; }
.roles ul li::before { display: none; }
.company { font-size: .95rem; color: var(--ink-2); margin: 0 0 1.6rem; }

.about-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: clamp(2rem, 5vw, 4rem); align-items: start; }
.skills { display: flex; flex-wrap: wrap; gap: .5rem; list-style: none; padding: 0; margin: 0 0 1.5rem; max-width: none; }
.skills li { margin: 0; padding: .45rem .8rem; border-radius: 999px; background: var(--rose-tint); color: var(--rose-2); font-size: .9rem; }
.skills li::marker { content: none; }

/* ---------------- work index ---------------- */

.work { display: flex; flex-direction: column; gap: clamp(1.5rem, 3vw, 2.25rem); }

.project {
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(0, 1fr);
  gap: clamp(1.5rem, 4vw, 3.25rem);
  align-items: center;
  text-decoration: none;
  background: var(--blush-2);
  border: 1px solid var(--line-soft);
  border-radius: var(--r-lg);
  padding: clamp(1.5rem, 3.4vw, 2.75rem);
  transition: background .2s ease, border-color .2s ease, box-shadow .25s ease, transform .25s ease;
}
.project:hover, .project:focus-visible {
  background: #fff;
  border-color: var(--blush-3);
  box-shadow: var(--sh-lg);
  transform: translateY(-3px);
}
.project:nth-child(even) .project-art { order: -1; }

.project h3 { margin-bottom: .4em; }
.project .kicker { font-size: .9rem; color: var(--ink-3); margin-bottom: 1rem; }
.project p { color: var(--ink-2); margin-bottom: 1.4rem; }

.project-art {
  background: var(--blush);
  border: 1px solid var(--line-soft);
  border-radius: var(--r);
  padding: clamp(1rem, 2.4vw, 1.6rem);
  box-shadow: var(--sh-sm);
}

.specs { display: flex; flex-wrap: wrap; gap: 1.75rem; margin: 0; }
.specs dt { font-size: .82rem; color: var(--ink-3); margin-bottom: .1rem; }
.specs dd {
  margin: 0; font-size: 1.15rem;
  font-family: "IBM Plex Mono", ui-monospace, monospace;
  font-feature-settings: "tnum" 1; letter-spacing: -.03em;
}

.readmore { display: inline-block; margin-top: 1.5rem; font-size: .95rem; color: var(--rose-2); }
.project:hover .readmore { text-decoration: underline; text-underline-offset: 4px; }

/* ---------------- prose columns ---------------- */

.cols {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
  gap: clamp(1.75rem, 4vw, 3rem);
}
.cols h4 { margin-bottom: .45em; }
.cols p { color: var(--ink-2); font-size: 1rem; }

.chips { display: grid; grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); gap: 1rem; }
.chip {
  background: var(--blush-2);
  border: 1px solid var(--line-soft);
  border-radius: var(--r);
  padding: 1.4rem 1.5rem;
}
.chip h4 {
  font-family: "DM Sans", sans-serif; font-size: 1rem; font-weight: 500;
  letter-spacing: -.01em; margin-bottom: .35em;
}
.chip p { font-size: .95rem; color: var(--ink-2); }

/* ---------------- case study ---------------- */

.case-hero { padding-block: clamp(2.5rem, 6vw, 5rem) clamp(2rem, 4vw, 3rem); }
.case-hero .tag { margin-bottom: 1.4rem; }
.case-hero h1 { max-width: 18ch; }
.case-hero .lede { max-width: 54ch; margin-top: .9em; }

.facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(9rem, 1fr));
  gap: 1.25rem 2rem;
  margin-top: clamp(2rem, 4vw, 3rem);
  padding-top: 1.6rem;
  border-top: 1px solid var(--line);
}
.facts dt { font-size: .82rem; color: var(--ink-3); }
.facts dd { margin: 0; font-size: 1rem; }

.case section { padding-block: clamp(2.5rem, 5vw, 4rem); }
.case section > h2 { margin-bottom: .6em; }
.case section + section { border-top: 1px solid var(--line-soft); }

figure {
  margin: clamp(2rem, 4vw, 3rem) 0;
  background: var(--blush-2);
  border: 1px solid var(--line-soft);
  border-radius: var(--r-lg);
  padding: clamp(1.25rem, 3vw, 2.25rem);
}
figure svg { margin-inline: auto; }
figcaption { font-size: .93rem; color: var(--ink-2); margin-top: 1.25rem; max-width: 60ch; }

.slot {
  border: 1px dashed var(--blush-3);
  border-radius: var(--r);
  background: var(--blush);
  padding: 2.6rem 1.5rem;
  text-align: center; color: var(--ink-3); font-size: .92rem;
}
.slot strong { display: block; color: var(--ink-2); margin-bottom: .3rem; }

.callout {
  background: var(--rose-tint);
  border-radius: var(--r);
  padding: 1.4rem 1.6rem;
  margin: 2rem 0;
  max-width: var(--measure);
}
.callout p { color: #5a2d44; font-size: 1rem; }

.tbl-wrap { overflow-x: auto; margin: 1.8rem 0; }
table { border-collapse: collapse; width: 100%; min-width: 34rem; font-size: .97rem; }
caption { text-align: left; color: var(--ink-3); font-size: .88rem; padding-bottom: .85rem; }
th, td { text-align: left; padding: .8rem 1rem .8rem 0; border-bottom: 1px solid var(--line-soft); vertical-align: top; }
th { font-weight: 500; color: var(--ink-3); font-size: .85rem; }
td.n { font-family: "IBM Plex Mono", monospace; font-feature-settings: "tnum" 1; color: var(--rose-2); white-space: nowrap; }
tbody tr:last-child td { border-bottom: 1px solid var(--line); }

.tally {
  display: flex; align-items: baseline; gap: 1rem; flex-wrap: wrap;
  background: var(--blush-2); border-radius: var(--r);
  padding: 1.5rem 1.75rem; margin-top: 1.75rem;
}
.tally b {
  font-family: "Newsreader", Georgia, serif; font-weight: 400;
  font-size: clamp(2rem, 4vw, 2.8rem); line-height: 1; color: var(--rose-2);
  letter-spacing: -.02em;
}
.tally span { color: var(--ink-2); font-size: 1rem; max-width: 40ch; }

.pager {
  display: flex; justify-content: space-between; gap: 1.5rem; flex-wrap: wrap;
  padding-block: clamp(2.5rem, 5vw, 4rem);
  border-top: 1px solid var(--line);
}
.pager .next-label { font-size: .85rem; color: var(--ink-3); display: block; margin-bottom: .2rem; }
.pager a { text-decoration: none; }
.pager .next-title { font-family: "Newsreader", Georgia, serif; font-size: 1.35rem; letter-spacing: -.02em; }
.pager a:hover .next-title { color: var(--rose-2); }

/* ---------------- contact + footer ---------------- */

.contact {
  background: var(--blush-2);
  border: 1px solid var(--line-soft);
  border-radius: var(--r-lg);
  padding: clamp(2rem, 5vw, 3.75rem);
}
.contact h2 { max-width: 16ch; }
.contact .hero-actions { margin-top: 1.75rem; }

.site-foot {
  border-top: 1px solid var(--line);
  margin-top: clamp(3rem, 6vw, 5rem);
  padding-block: 2rem 3rem;
  color: var(--ink-3); font-size: .92rem;
  display: flex; justify-content: space-between; gap: 1.5rem; flex-wrap: wrap;
}
.site-foot a { color: var(--ink-3); }
.site-foot a:hover { color: var(--ink); }

/* ---------------- responsive ---------------- */

@media (max-width: 62rem) {
  .hero-grid, .about-grid { grid-template-columns: 1fr; }
  .motif { display: none; }
}
@media (max-width: 52rem) {
  .project { grid-template-columns: 1fr; }
  .project:nth-child(even) .project-art { order: 0; }
  .site-head nav { gap: 1.1rem; font-size: .9rem; }
  .site-head .bar { flex-wrap: wrap; gap: .6rem 1.2rem; }
}
@media (max-width: 30rem) {
  .specs { gap: 1.1rem; }
  .hero-actions .btn { flex: 1 1 auto; justify-content: center; }
}

/* in-page contents rail on case studies */
.case-body { display: grid; grid-template-columns: 11.5rem minmax(0, 1fr); column-gap: clamp(2rem, 4vw, 4rem); }
.case-body > section { grid-column: 2; }
.rail { grid-column: 1; grid-row: 1 / span 30; position: sticky; top: 5.5rem; align-self: start; margin-top: clamp(2.5rem, 5vw, 4rem); padding-left: 1.1rem; }
.rail-track { position: absolute; left: 0; top: 0; bottom: 0; width: 2px; background: var(--line); border-radius: 2px; }
.rail-fill { position: absolute; left: 0; top: 0; width: 100%; height: var(--p, 0%); background: var(--rose); border-radius: 2px; }
.rail ol { list-style: none; margin: 0; padding: 0; max-width: none; }
.rail li { margin: 0; padding: 0; }
.rail a { display: block; padding: .32rem 0; font-size: .88rem; line-height: 1.35; color: var(--ink-3); text-decoration: none; transition: color .15s ease; }
.rail a:hover { color: var(--ink); }
.rail a.on { color: var(--rose-2); font-weight: 500; }
.case section { scroll-margin-top: 5rem; }
@media (max-width: 64rem) {
  .case-body { display: block; }
  /* below desktop the rail becomes a slim sticky strip under the header:
     section names scroll sideways, the progress line runs along its bottom edge */
  .rail {
    position: sticky; top: var(--head-h, 4rem); z-index: 40;
    margin: 0 0 .5rem; padding: 0;
    background: var(--blush);
  }
  .rail-track { top: auto; bottom: 0; left: 0; right: 0; width: auto; height: 2px; }
  .rail-fill  { width: var(--p, 0%); height: 100%; }
  .rail ol {
    display: flex; gap: 1.4rem; overflow-x: auto; white-space: nowrap;
    padding: .15rem 0 .1rem; scrollbar-width: none; -webkit-overflow-scrolling: touch;
  }
  .rail ol::-webkit-scrollbar { display: none; }
  .rail a { padding: .7rem 0; font-size: .9rem; }
  .case section { scroll-margin-top: 9rem; }
}
code { font-family: "IBM Plex Mono", ui-monospace, monospace; font-size: .9em; background: var(--blush-2); padding: .1em .35em; border-radius: 5px; }

/* "chaos" glitches briefly, every few seconds */
.glitch { position: relative; display: inline-block; animation: glitch-main 6s steps(1, end) .7s infinite; }
.glitch::before, .glitch::after {
  content: attr(data-text);
  position: absolute; inset: 0;
  opacity: 0; pointer-events: none;
}
.glitch::before { color: var(--rose); animation: glitch-a 6s steps(1, end) .7s infinite; }
.glitch::after  { color: #2f7f86;     animation: glitch-b 6s steps(1, end) .7s infinite; }

@keyframes glitch-main {
  0%   { transform: translate(-2px, 0) skewX(-5deg); }
  2%   { transform: translate(2px, 1px) skewX(4deg); }
  4%   { transform: translate(-1px, -1px) skewX(-2deg); }
  6%, 100% { transform: none; }
}
@keyframes glitch-a {
  0%   { opacity: .9; clip-path: inset(8% 0 62% 0);  transform: translate(-5px, 0); }
  2%   { opacity: .9; clip-path: inset(58% 0 12% 0); transform: translate(4px, 0); }
  4%   { opacity: .9; clip-path: inset(30% 0 40% 0); transform: translate(-3px, 1px); }
  6%, 100% { opacity: 0; }
}
@keyframes glitch-b {
  0%   { opacity: .85; clip-path: inset(48% 0 22% 0); transform: translate(5px, 0); }
  2%   { opacity: .85; clip-path: inset(14% 0 58% 0); transform: translate(-4px, -1px); }
  4%   { opacity: .85; clip-path: inset(66% 0 6% 0);  transform: translate(3px, 0); }
  6%, 100% { opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .glitch, .glitch::before, .glitch::after { animation: none; }
}

/* "legible" sweeps thin -> black -> normal right after the first glitch (~1.1s) */
.legible { animation: legible-sweep 2.6s cubic-bezier(.4,0,.2,1) 1.1s 1 both; }
@keyframes legible-sweep {
  0%   { font-weight: 400; }
  22%  { font-weight: 200; }
  60%  { font-weight: 800; }
  100% { font-weight: 400; }
}
@media (prefers-reduced-motion: reduce) { .legible { animation: none; } }

/* keep the second line whole at every width so the weight sweep can't push "legible." onto a third line.
   The size is capped so the line still fits the screen at its widest (black) weight: ~8.4em wide. */
.hero h1 { font-size: min(clamp(2.7rem, 6.6vw, 4.4rem), calc((100vw - 2.5rem) / 8.6)); }
.hero h1 .line2 { display: block; white-space: nowrap; }

/* phones: the two-row header scrolls away so only the progress strip stays pinned */
@media (max-width: 52rem) {
  .site-head { position: static; }
  .rail { top: 0; }
  .case section { scroll-margin-top: 4rem; }
}

/* breathing room between the role tag and the headline */
.hero .tag { margin-bottom: 1rem; }

/* diagrams that would shrink to unreadable text on a phone swap to a stacked version */
.svg-narrow { display: none; max-width: 24rem; }
@media (max-width: 40rem) {
  .svg-wide { display: none; }
  .svg-narrow { display: block; }
}

/* Experience groups: Ant Design-style bordered collapse */
details.exp { background: #fff; border: 1px solid var(--blush-3); margin: 0; }
details.exp + details.exp { border-top: 0; }
details.exp:first-of-type { border-radius: 8px 8px 0 0; }
details.exp:last-of-type { border-radius: 0 0 8px 8px; }
details.exp summary { list-style: none; cursor: pointer; display: grid; grid-template-columns: auto 1fr; column-gap: 1rem; row-gap: .15rem; align-items: center; padding: 1.1rem 1.4rem; background: rgba(80,40,60,.035); transition: background .2s; }
details.exp:first-of-type summary { border-radius: 7px 7px 0 0; }
details.exp:last-of-type:not([open]) summary { border-radius: 0 0 7px 7px; }
details.exp summary::-webkit-details-marker { display: none; }
details.exp summary:hover { background: rgba(80,40,60,.06); }
details.exp summary::before { content: ""; grid-column: 1; grid-row: 1 / span 2; width: .55rem; height: .55rem; border-top: 2px solid var(--ink-2); border-right: 2px solid var(--ink-2); transform: rotate(45deg); transition: transform .2s; margin: 0 .1rem 0 .1rem; }
details.exp[open] summary::before { transform: rotate(135deg); }
details.exp .t { grid-column: 2; font-family: "DM Sans", sans-serif; font-weight: 600; font-size: 1.1rem; color: var(--ink); }
details.exp .s { grid-column: 2; font-size: .88rem; color: var(--ink-3); }
details.exp[open] summary { border-bottom: 1px solid var(--blush-3); }
details.exp summary:focus-visible { outline: 2px solid var(--rose); outline-offset: -2px; }
details.exp .roles { max-width: none; padding: 1.5rem 1.6rem 1.6rem 1.9rem; }
@media (max-width: 40rem) { details.exp summary { padding: 1rem 1rem; } details.exp .roles { padding: 1.25rem 1rem 1.25rem 1.4rem; } }


.contact-grid { display: grid; grid-template-columns: 1fr minmax(10rem, 17rem); gap: 2.5rem; align-items: center; }
.contact .portrait { width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; border-radius: 16px; display: block; }
@media (max-width: 52rem) { .contact-grid { grid-template-columns: 1fr; } .contact .portrait { order: -1; max-width: 12rem; } }
