:root {
  --paper: #f3f0e8;
  --ink: #171717;
  --muted: #625e56;
  --line: #c7c2b7;
  --yellow: #ffd43b;
  --blue: #1f6feb;
  --red: #ff5a36;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--paper);
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}
* { box-sizing: border-box; }
html { scroll-padding-top: 32px; }
body { margin: 0; }
::selection { background: var(--yellow); color: var(--ink); }
a { color: inherit; text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 1px; }
a:hover { color: var(--blue); }
button { font: inherit; color: inherit; cursor: pointer; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 5px; }
[hidden] { display: none !important; }
img { max-width: 100%; display: block; }
h1, h2, h3, p { margin: 0; }
p { line-height: 1.6; }
.skip-link { position: fixed; top: 8px; left: 8px; z-index: 20; transform: translateY(-160%); background: var(--yellow); padding: 14px; border: 2px solid; }
.skip-link:focus { transform: translateY(0); }
.topbar, .page, .footer { width: min(100% - 64px, 1000px); margin-inline: auto; }
.topbar { min-height: 72px; display: flex; justify-content: flex-end; align-items: center; border-bottom: 2px solid var(--ink); }
nav { display: flex; gap: 28px; font-size: 14px; }
nav a { display: inline-flex; align-items: center; min-height: 44px; text-decoration: none; }
nav a[aria-current="page"] { text-decoration: underline; }
h1 { font-size: clamp(48px, 7.4vw, 94px); font-weight: 950; line-height: .92; letter-spacing: -.07em; }
h2 { font-size: 36px; font-weight: 900; line-height: 1.1; letter-spacing: -.055em; }
.intro { display: grid; grid-template-columns: minmax(0, 1fr) 270px; column-gap: 64px; row-gap: 25px; padding: 62px 0 50px; }
.intro__identity { grid-column: 1; grid-row: 1; }
.intro__location { margin-top: 20px; font-size: 16px; color: var(--muted); }
.portrait { grid-column: 2; grid-row: 1 / 3; width: 270px; height: auto; aspect-ratio: 1; padding: 12px; background: #fffdf7; border: 2px solid var(--ink); box-shadow: 6px 6px 0 var(--ink); }
.intro__text { grid-column: 1; grid-row: 2; font-size: 16px; }
.intro__text p + p { margin-top: 18px; }
.intro__text strong { font-weight: 750; }
.intro__text a, .project-row h3 a { color: var(--blue); }
.work { padding: 28px 0 0; }
.work > h2 { margin-bottom: 21px; }
.project-row { display: grid; grid-template-columns: 225px minmax(0, 1fr); gap: 26px; padding: 28px 0; border-top: 1px solid var(--ink); }
.project-row h3 { font-size: 30px; font-weight: 900; line-height: 1.2; letter-spacing: -.055em; }
.project-row h3 a { display: inline-flex; align-items: center; gap: 14px; min-height: 44px; padding: 3px 0; text-decoration: none; }
.project-row h3 a:hover { text-decoration: underline; }
.project-row .external-arrow { display: grid; place-items: center; width: 32px; height: 32px; margin: 0; border: 1px solid var(--ink); background: var(--yellow); color: var(--ink); font: 500 22px/1 ui-sans-serif, sans-serif; }
.project-row h3 a:hover .external-arrow { background: var(--ink); color: var(--yellow); }
.project-row p { font-size: 16px; }
.project-row .project-row__stack { margin-top: 9px; font: 500 12px/1.6 ui-monospace, SFMono-Regular, Consolas, monospace; color: var(--muted); }
.external-arrow { display: inline-block; margin-left: 5px; font-size: .85em; font-weight: 500; }
.details { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; margin-top: 12px; padding: 32px 0 46px; }
.details h2 { font-size: 28px; margin-bottom: 14px; }
.details p { font-size: 15px; color: var(--muted); margin-bottom: 7px; }
.text-link { display: inline-flex; align-items: center; min-height: 44px; font-size: 15px; }
.footer { min-height: 152px; padding: 24px 0; border-top: 1px solid var(--line); display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 10px; color: var(--ink); font: 500 12px/1.5 ui-monospace, monospace; }
.tower-mark { width: 36px; height: 54px; overflow: visible; fill: none; stroke: currentColor; stroke-width: 3; stroke-linecap: square; stroke-linejoin: miter; }
.tower-mark__sphere { fill: var(--red); }
.footer a { display: inline-flex; align-items: center; min-height: 44px; }
.button { display: inline-flex; align-items: center; min-height: 44px; padding: 10px 16px; border: 2px solid var(--ink); background: var(--paper); font-size: 14px; font-weight: 750; text-decoration: none; }
.button:hover { color: var(--ink); background: var(--yellow); }
.cv-header { padding: 36px 0 30px; border-bottom: 2px solid var(--ink); }
.cv-header__top { display: flex; justify-content: flex-end; align-items: center; gap: 20px; margin-bottom: 32px; }
.cv-header__role { font-size: 20px; margin-top: 22px; }
.cv-header__contacts { display: flex; flex-wrap: wrap; gap: 8px 22px; margin-top: 16px; font: 500 12px/1.7 ui-monospace, monospace; color: var(--muted); }
.cv-section { display: grid; grid-template-columns: 160px minmax(0, 1fr); gap: 34px; padding: 30px 0; border-bottom: 1px solid var(--line); }
.cv-section > h2 { font: 650 12px/1.5 ui-monospace, monospace; padding-top: 5px; }
.cv-section p, .cv-section li { font-size: 15px; line-height: 1.65; }
.cv-section p + p { margin-top: 12px; }
.cv-section h3 { font-size: 22px; letter-spacing: -.025em; margin-bottom: 5px; }
.cv-section h4 { font-size: 17px; margin: 23px 0 8px; }
.cv-section ul { padding-left: 19px; margin: 16px 0 0; }
.cv-section li + li { margin-top: 8px; }
.cv-section .cv-meta { font: 500 11px/1.6 ui-monospace, monospace; color: var(--muted); margin-bottom: 16px; }
.cv-section article + article { margin-top: 28px; }
.cv-section--last { border: none; padding-bottom: 48px; }
.error-page { min-height: 75vh; padding-top: 90px; padding-bottom: 60px; }
.error-page h1 { margin: 30px 0; }
.error-page p { margin-bottom: 30px; }
.eyebrow { font: 600 12px/1.5 ui-monospace, monospace; color: var(--muted); }
@media (max-width: 760px) {
  .topbar, .page, .footer { width: calc(100% - 40px); }
  .topbar { flex-wrap: wrap; gap: 0 20px; padding: 16px 0 8px; }
  nav { gap: 28px; }
  .intro { grid-template-columns: minmax(0, 1fr) 140px; column-gap: 24px; row-gap: 25px; padding: 38px 0; }
  .portrait { width: 140px; grid-row: 1; padding: 7px; box-shadow: 4px 4px 0 var(--ink); }
  .intro__text { grid-column: 1 / -1; }
  h1 { font-size: clamp(40px, 7.3vw, 56px); }
  .intro__location { font-size: 14px; margin-top: 15px; }
  .project-row { grid-template-columns: 190px minmax(0, 1fr); gap: 22px; }
  .project-row h3 { font-size: 26px; }
  .work { padding: 22px 0 0; }
  .cv-section { grid-template-columns: 1fr; gap: 16px; }
  .cv-header__top { flex-wrap: wrap; }
}
@media (max-width: 440px) {
  .intro { grid-template-columns: minmax(0, 1fr) 92px; column-gap: 16px; }
  .portrait { width: 92px; }
  h1 { font-size: clamp(33px, 9vw, 40px); }
  .intro__location { font-size: 12px; }
  .project-row { grid-template-columns: 1fr; gap: 5px; padding: 20px 0; }
  .details { grid-template-columns: 1fr; gap: 28px; }
  .details h2 { margin-bottom: 8px; }
  .cv-header h1 { font-size: 48px; }
}
@media print {
  @page { size: A4; margin: 14mm; }
  :root { background: white; color: black; }
  .topbar, .footer, .skip-link, .print-button { display: none !important; }
  .page { width: 100%; max-width: none; }
  .cv-header { padding: 0 0 18px; }
  .cv-header__top { display: none; }
  .cv-header h1 { font-size: 42px; }
  .cv-header__role { font-size: 18px; margin-top: 12px; }
  .cv-header__contacts { font-size: 9px; }
  .cv-section { grid-template-columns: 105px minmax(0, 1fr); gap: 18px; padding: 17px 0; }
  .cv-section p, .cv-section li { font-size: 10px; line-height: 1.45; }
  .cv-section h3 { font-size: 17px; break-after: avoid; }
  .cv-section h4 { font-size: 12px; margin-top: 14px; break-after: avoid; }
  .cv-section .cv-meta { font-size: 9px; margin-bottom: 9px; }
  .cv-section article { break-inside: avoid; }
  .cv-section li + li { margin-top: 5px; }
  .cv-section article + article { margin-top: 16px; }
  .cv-section--earlier { break-before: page; border-top: 0; }
}
