/* =========================================================================
   Kostiantyn Derets — landing page
   No JavaScript, no external requests. Every visual effect below is CSS the
   browser can paint from this one file, which is what keeps the page fast
   and keeps a strict CSP (default-src 'none') viable.
   ========================================================================= */

/* ---------------------------------------------------------------- tokens */

:root {
  color-scheme: light dark;

  /* Layered surfaces rather than one flat background: depth is what reads as
     "modern" far more than any single accent colour does. */
  --bg: #fbfbfd;
  --surface-1: #ffffff;
  --surface-2: #f3f4f7;
  --surface-raised: #ffffff;

  --text: #0d1117;
  --text-secondary: #3d4552;
  --text-muted: #6b7383;

  --border: #e4e6ec;
  --border-strong: #d2d6df;

  --accent: #2247d8;
  --accent-hover: #1a37ad;
  --accent-contrast: #ffffff;
  --accent-soft: #eef1fe;

  --glow-a: rgba(59, 92, 246, 0.16);
  --glow-b: rgba(120, 88, 240, 0.12);

  --shadow-sm: 0 1px 2px rgba(13, 17, 23, 0.05);
  --shadow-md: 0 4px 16px -4px rgba(13, 17, 23, 0.09), 0 1px 3px rgba(13, 17, 23, 0.05);
  --shadow-lg: 0 18px 40px -12px rgba(13, 17, 23, 0.16), 0 2px 8px rgba(13, 17, 23, 0.05);

  --wrap: 68rem;
  --measure: 66ch;
  --radius: 14px;
  --radius-lg: 22px;

  --font: "Segoe UI Variable Display", ui-sans-serif, system-ui, -apple-system,
    "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: ui-monospace, "Cascadia Code", "Segoe UI Mono", "SF Mono",
    Menlo, Consolas, monospace;

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #08090c;
    --surface-1: #0e1015;
    --surface-2: #14171e;
    --surface-raised: #121620;

    --text: #f2f4f8;
    --text-secondary: #c3c9d4;
    --text-muted: #8b93a3;

    --border: #21252e;
    --border-strong: #2e3440;

    --accent: #7d9bff;
    --accent-hover: #9fb5ff;
    --accent-contrast: #07080b;
    --accent-soft: #151b2c;

    --glow-a: rgba(75, 110, 255, 0.20);
    --glow-b: rgba(140, 100, 255, 0.14);

    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.5);
    --shadow-md: 0 4px 16px -4px rgba(0, 0, 0, 0.6);
    --shadow-lg: 0 18px 44px -12px rgba(0, 0, 0, 0.75);
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

/* ------------------------------------------------------------------ base */

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  /* Anchor targets clear the sticky header instead of hiding under it. */
  scroll-padding-top: 6rem;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.65;
  font-feature-settings: "kern" 1, "liga" 1, "cv05" 1;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: 1.5rem;
}

a {
  color: var(--accent);
  text-underline-offset: 0.2em;
  text-decoration-thickness: 1px;
  transition: color 0.18s var(--ease);
}

a:hover {
  color: var(--accent-hover);
}

/* A visible, high-contrast focus ring is the single most load-bearing
   accessibility affordance on a page that is mostly links. */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  padding: 0.8rem 1.4rem;
  background: var(--accent);
  color: var(--accent-contrast);
  font-weight: 600;
  border-radius: 0 0 var(--radius) 0;
  text-decoration: none;
}

.skip-link:focus {
  left: 0;
}

.muted {
  color: var(--text-muted);
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--bg) 78%, transparent);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.25s var(--ease);
}

/* Hairline only once the page has scrolled past the hero. */
@supports (animation-timeline: scroll()) {
  @media (prefers-reduced-motion: no-preference) {
    .site-header {
      animation: header-border linear both;
      animation-timeline: scroll();
      animation-range: 0 8rem;
    }
  }
}

@keyframes header-border {
  to {
    border-bottom-color: var(--border);
  }
}

.site-header .wrap {
  display: flex;
  align-items: center;
  gap: 1rem 2rem;
  padding-block: 0.85rem;
}

.wordmark {
  font-weight: 640;
  letter-spacing: -0.015em;
  color: var(--text);
  text-decoration: none;
  white-space: nowrap;
}

.site-header nav {
  margin-inline: auto;
}

.site-header nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 1.4rem;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 0.9375rem;
}

.site-header nav a {
  position: relative;
  color: var(--text-muted);
  text-decoration: none;
}

.site-header nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.35rem;
  width: 100%;
  height: 1.5px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.28s var(--ease);
}

.site-header nav a:hover {
  color: var(--text);
}

.site-header nav a:hover::after {
  transform: scaleX(1);
}

/* Five links plus the wordmark and button need the room; below this the nav
   collapses rather than wrapping to a second row. */
@media (max-width: 60rem) {
  .site-header nav {
    display: none;
  }
  .site-header .wrap {
    justify-content: space-between;
  }
}

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

h1,
h2,
h3 {
  color: var(--text);
  text-wrap: balance;
}

h1 {
  font-size: clamp(2.6rem, 7vw, 4.5rem);
  line-height: 1.02;
  letter-spacing: -0.04em;
  font-weight: 660;
  margin: 0 0 1.25rem;
}

h2 {
  font-size: clamp(1.6rem, 3.4vw, 2.35rem);
  line-height: 1.15;
  letter-spacing: -0.028em;
  font-weight: 640;
  margin: 0 0 2rem;
  max-width: 22ch;
}

h3 {
  font-size: 1.0625rem;
  font-weight: 640;
  letter-spacing: -0.012em;
  margin: 0 0 0.5rem;
}

p {
  margin: 0 0 1.1rem;
  max-width: var(--measure);
}

.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 1rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.eyebrow::after {
  content: "";
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--border-strong), transparent);
  max-width: 8rem;
}

.prose {
  color: var(--text-secondary);
}

.prose p:last-child {
  margin-bottom: 0;
}

.prose-lead > p:first-child {
  font-size: 1.1875rem;
  line-height: 1.55;
  color: var(--text);
  letter-spacing: -0.011em;
}

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

main > section {
  padding-block: clamp(3.5rem, 8vw, 6.5rem);
  position: relative;
}

/* Hairline separators drawn as a gradient so they fade at the edges rather
   than butting hard against the viewport. */
main > section + section:not(.contact)::before {
  content: "";
  position: absolute;
  inset-inline: 1.5rem;
  top: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border), transparent);
}

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

.hero {
  padding-block: clamp(4.5rem, 12vw, 9rem) clamp(3.5rem, 8vw, 6rem);
  isolation: isolate;
}

/* Two soft colour fields behind the headline. Pure CSS gradients, so there is
   no image to download and nothing to break under the CSP. */
.hero::before {
  content: "";
  position: absolute;
  inset: -30% -20% auto -20%;
  height: 130%;
  z-index: -1;
  background:
    radial-gradient(60% 55% at 22% 28%, var(--glow-a), transparent 68%),
    radial-gradient(50% 50% at 78% 12%, var(--glow-b), transparent 70%);
  filter: blur(12px);
  pointer-events: none;
}

.hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: clamp(2rem, 5vw, 4.5rem);
}

/* Portrait drops below the text before it gets small enough to look like a
   thumbnail. */
@media (max-width: 58rem) {
  .hero-inner {
    grid-template-columns: minmax(0, 1fr);
    gap: 2.5rem;
  }
  .hero-figure {
    order: -1;
  }
}

.hero-figure {
  position: relative;
  flex: none;
}

/* Soft halo, so the portrait sits in the gradient field rather than on top. */
.hero-figure::before {
  content: "";
  position: absolute;
  inset: -14%;
  border-radius: 50%;
  background: radial-gradient(closest-side, var(--glow-a), transparent 72%);
  z-index: -1;
}

.avatar {
  display: block;
  width: clamp(9rem, 22vw, 16rem);
  height: clamp(9rem, 22vw, 16rem);
  border-radius: 50%;
  object-fit: cover;
  /* Inert for the current square source, which `cover` fits without cropping.
     Kept as a sensible default in case a portrait-orientation photo replaces
     it, where the crop should favour the face over the chest. */
  object-position: center 30%;
  border: 1px solid var(--border);
  background: var(--surface-2);
  box-shadow: var(--shadow-lg);
}

.avatar-fallback {
  display: grid;
  place-items: center;
  margin: 0;
  max-width: none;
  font-size: clamp(2.5rem, 7vw, 4.5rem);
  font-weight: 600;
  letter-spacing: -0.03em;
  color: var(--accent);
  background: linear-gradient(145deg, var(--accent-soft), var(--surface-2));
  box-shadow: var(--shadow-md);
}

.hero .headline {
  font-size: clamp(1.2rem, 2.6vw, 1.6rem);
  line-height: 1.4;
  letter-spacing: -0.018em;
  color: var(--text-secondary);
  max-width: 30ch;
  margin-bottom: 1.75rem;
  text-wrap: balance;
}

.meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem 0.9rem;
  margin-bottom: 2.25rem;
  max-width: none;
  font-size: 0.875rem;
  color: var(--text-muted);
}

.meta span + span::before {
  content: "";
  display: inline-block;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--border-strong);
  margin-right: 0.9rem;
  vertical-align: middle;
}

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

.cta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.85rem 1.75rem;
  max-width: none;
  margin-bottom: 0;
}

.button {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.8rem 1.6rem;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-contrast);
  font-size: 0.9375rem;
  font-weight: 580;
  letter-spacing: -0.005em;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: var(--shadow-md);
  transition: transform 0.2s var(--ease), background-color 0.2s var(--ease),
    box-shadow 0.2s var(--ease);
}

.button:hover {
  background: var(--accent-hover);
  color: var(--accent-contrast);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.button:active {
  transform: translateY(0);
}

/* Equal visual weight would make the pair read as one indecisive choice, so
   email leads and Telegram is offered as an outline alternative. */
.button-secondary {
  background: color-mix(in srgb, var(--surface-raised) 80%, transparent);
  color: var(--text);
  border: 1px solid var(--border-strong);
  backdrop-filter: blur(8px);
  box-shadow: var(--shadow-sm);
}

.button-secondary:hover {
  background: var(--surface-raised);
  color: var(--text);
  border-color: var(--accent);
  box-shadow: var(--shadow-md);
}

.button-sm {
  padding: 0.5rem 1.1rem;
  font-size: 0.875rem;
  box-shadow: none;
}

@media (max-width: 30rem) {
  .button-sm {
    display: none;
  }
}

.link-arrow {
  font-size: 0.9375rem;
  font-weight: 520;
  text-decoration: none;
  white-space: nowrap;
}

.link-arrow::after {
  content: " \2197";
  display: inline-block;
  transition: transform 0.2s var(--ease);
}

.link-arrow:hover {
  text-decoration: underline;
}

.link-arrow:hover::after {
  transform: translate(2px, -2px);
}

/* ----------------------------------------------------------------- cards */

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(18.5rem, 1fr));
  gap: 1.25rem;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: card;
}

.card {
  counter-increment: card;
  position: relative;
  overflow: hidden;
  padding: 1.75rem 1.6rem 1.6rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface-raised);
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease),
    border-color 0.3s var(--ease);
}

/* Accent rule that wipes across the top edge on hover. */
.card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), transparent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.45s var(--ease);
}

/* Decorative index. Generated content, so it stays out of the text a parser
   or screen reader extracts. */
.card::after {
  content: counter(card, decimal-leading-zero);
  position: absolute;
  top: 1.4rem;
  right: 1.5rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  opacity: 0.5;
}

.card:hover {
  transform: translateY(-3px);
  border-color: var(--border-strong);
  box-shadow: var(--shadow-lg);
}

.card:hover::before {
  transform: scaleX(1);
}

.card h3 {
  padding-right: 2.5rem;
  margin-bottom: 0.6rem;
}

.card p {
  font-size: 0.9375rem;
  line-height: 1.6;
  margin-bottom: 0.7rem;
  max-width: none;
}

.card p:last-child {
  margin-bottom: 0;
  color: var(--text-muted);
}

.card .card-summary {
  color: var(--text-secondary);
}

/* -------------------------------------------------------------- listings */

.two-col {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
  gap: 2.5rem 3rem;
}

.two-col h3 {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.13em;
  color: var(--text-muted);
  margin-bottom: 1.1rem;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.tags li {
  padding: 0.4rem 0.9rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface-2);
  font-size: 0.8438rem;
  color: var(--text-secondary);
  transition: border-color 0.2s var(--ease), color 0.2s var(--ease);
}

.tags li:hover {
  border-color: var(--accent);
  color: var(--text);
}

.plain {
  margin: 0;
  padding: 0;
  list-style: none;
  max-width: var(--measure);
}

.plain li {
  padding: 0.9rem 0;
  border-top: 1px solid var(--border);
  font-size: 0.9375rem;
  color: var(--text-muted);
}

.plain li:first-child {
  border-top: 0;
  padding-top: 0;
}

.plain strong {
  color: var(--text);
  font-weight: 580;
}

/* -------------------------------------------------------- certifications */

.cert-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(15.5rem, 1fr));
  gap: 1rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.cert-card {
  display: flex;
  flex-direction: column;
  padding: 1.25rem 1.3rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-raised);
  box-shadow: var(--shadow-sm);
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease),
    border-color 0.25s var(--ease);
}

.cert-card:hover {
  transform: translateY(-2px);
  border-color: var(--border-strong);
  box-shadow: var(--shadow-md);
}

/* The issuing body sits in the footer row beside the date, carrying the accent
   while the credential name stays the primary text. */
.cert-issuer {
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  background: var(--accent-soft);
  border: 1px solid color-mix(in srgb, var(--accent) 22%, transparent);
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--accent);
  line-height: 1.5;
  /* Long issuer names wrap rather than truncate: an ellipsis on a joint award
     would hide the second institution, which is usually the notable one. */
  text-align: center;
  text-wrap: balance;
}

.cert-title {
  margin: 0 0 0.9rem;
  font-size: 0.9375rem;
  font-weight: 580;
  line-height: 1.4;
  letter-spacing: -0.008em;
  color: var(--text);
  text-wrap: pretty;
}

.cert-title a {
  color: inherit;
  text-decoration: none;
}

.cert-title a:hover {
  color: var(--accent);
  text-decoration: underline;
}

/* margin-top:auto pins the date row to the bottom so cards of differing
   title lengths still line their metadata up across a row. */
.cert-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem 0.6rem;
  margin: auto 0 0;
  max-width: none;
}

/* Pushed to the trailing edge so the label reads left and the date reads
   right across the row. */
.cert-date {
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  color: var(--text-muted);
}

/* A lapsed credential is dimmed as well as tagged, so the distinction survives
   a quick scan of eighteen cards. */
.is-expired .cert-issuer {
  background: var(--surface-2);
  border-color: var(--border);
  color: var(--text-muted);
}

.is-expired .cert-title {
  color: var(--text-secondary);
}

/* An expired credential that looks identical to a current one misrepresents
   the record, so it carries its own marker rather than just a date. */
.cert-expired {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  white-space: nowrap;
  color: var(--text-muted);
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  padding: 0.05rem 0.5rem;
}

/* ------------------------------------------------------------- timeline */

.timeline {
  margin: 0;
  padding: 0;
  list-style: none;
}

.timeline li {
  position: relative;
  padding: 0 0 2.25rem 2rem;
  border-left: 1px solid var(--border);
}

.timeline li:last-child {
  padding-bottom: 0;
  border-left-color: transparent;
}

.timeline li::before {
  content: "";
  position: absolute;
  left: -0.3125rem;
  top: 0.5rem;
  width: 0.625rem;
  height: 0.625rem;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid var(--border-strong);
  transition: border-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

/* The current role reads as current without needing a label. */
.timeline li:first-child::before {
  background: var(--accent);
  border-color: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-soft);
}

.timeline li:hover::before {
  border-color: var(--accent);
}

.timeline h3 {
  font-size: 1.125rem;
  margin-bottom: 0.35rem;
}

.timeline p {
  color: var(--text-muted);
  font-size: 0.9375rem;
  margin-bottom: 0;
}

.period {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.02em;
  font-variant-numeric: tabular-nums;
  color: var(--text-muted);
  margin-bottom: 0.6rem !important;
}

/* ---------------------------------------------------------- contributions */

.contrib-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
  gap: 1.25rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.contrib {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 1.6rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface-raised);
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease),
    border-color 0.3s var(--ease);
}

.contrib:hover {
  transform: translateY(-3px);
  border-color: var(--border-strong);
  box-shadow: var(--shadow-lg);
}

/* The whole card is the hit target, but only the name is the actual link, so
   the accessible name stays the project rather than the entire paragraph. */
.contrib-link {
  text-decoration: none;
}

.contrib-link::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
}

.contrib-name {
  display: block;
  font-size: 1.125rem;
  font-weight: 640;
  letter-spacing: -0.02em;
  color: var(--text);
}

.contrib-name::after {
  content: " \2197";
  color: var(--accent);
  font-weight: 500;
  display: inline-block;
  transition: transform 0.2s var(--ease);
}

.contrib:hover .contrib-name {
  color: var(--accent);
}

.contrib:hover .contrib-name::after {
  transform: translate(2px, -2px);
}

.contrib-full {
  display: block;
  margin-top: 0.2rem;
  font-size: 0.8125rem;
  line-height: 1.4;
  color: var(--text-muted);
}

.contrib-role {
  margin: 0.9rem 0 0;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
  max-width: none;
}

.contrib-desc {
  margin: 0.9rem 0 0;
  font-size: 0.9063rem;
  line-height: 1.6;
  color: var(--text-muted);
  max-width: none;
}

/* --------------------------------------------------------------- contact */

.contact {
  isolation: isolate;
}

.contact-inner {
  position: relative;
  padding: clamp(2.5rem, 6vw, 4rem);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(90% 140% at 100% 0%, var(--accent-soft), transparent 60%),
    var(--surface-1);
  box-shadow: var(--shadow-md);
  overflow: hidden;
}

.contact-inner h2 {
  max-width: 18ch;
}

.contact-inner .prose {
  margin-bottom: 2rem;
}

/* ---------------------------------------------------------------- footer */

.site-footer {
  border-top: 1px solid var(--border);
  padding-block: 2.5rem 3.5rem;
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem 3rem;
  justify-content: space-between;
  align-items: flex-start;
}

.footer-inner p {
  margin: 0;
  max-width: none;
}

.machine {
  text-align: right;
  line-height: 1.9;
}

@media (max-width: 40rem) {
  .machine {
    text-align: left;
  }
}

/* ---------------------------------------------------------------- print */

@media print {
  .site-header,
  .skip-link,
  .cta-row,
  .hero::before,
  .hero-figure::before {
    display: none;
  }

  .avatar {
    width: 7rem;
    height: 7rem;
    box-shadow: none;
  }

  body {
    font-size: 10.5pt;
    background: #fff;
    color: #000;
  }

  main > section {
    padding-block: 1rem;
    break-inside: avoid;
  }

  .card,
  .contact-inner {
    box-shadow: none;
    border: 1px solid #ccc;
  }

  /* Printed pages lose hrefs otherwise. */
  a[href^="http"]::after {
    content: " (" attr(href) ")";
    font-size: 8.5pt;
    color: #555;
    word-break: break-all;
  }
}
