/* The portfolio's shared visual language, tailored to a readable document. */
:root {
  color-scheme: light;
  --paper: #ffffff;
  --surface: #f5f5f7;
  --ink: #111111;
  --muted: #626269;
  --line: #e4e4e7;
  --text: #52525a;
  --subtle: #929297;
  --button-hover: #363638;
  --selection: #e5e5e5;
  --sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --paper: #101012;
  --surface: #19191d;
  --ink: #f5f5f7;
  --muted: #ababb4;
  --line: #303037;
  --text: #c1c1c9;
  --subtle: #a1a1aa;
  --button-hover: #d9d9df;
  --selection: #383842;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    color-scheme: dark;
    --paper: #101012;
    --surface: #19191d;
    --ink: #f5f5f7;
    --muted: #ababb4;
    --line: #303037;
    --text: #c1c1c9;
    --subtle: #a1a1aa;
    --button-hover: #d9d9df;
    --selection: #383842;
  }
}
* { box-sizing: border-box; }
html { scroll-padding-top: 2rem; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 1rem/1.65 var(--sans); overflow-wrap: anywhere; -webkit-font-smoothing: antialiased; }
a { color: inherit; text-underline-offset: .25em; }
a:focus-visible, button:focus-visible, select:focus-visible { outline: 2px solid var(--ink); outline-offset: 5px; }
main:focus { outline: none; }
h1, h2, h3, p, ul, dl, dd { margin: 0; }
h1, h2, h3 { font-weight: 600; line-height: 1.12; letter-spacing: -.035em; }
::selection { background: var(--selection); color: var(--ink); }
.skip-link { position: absolute; top: -8rem; left: 1rem; z-index: 10; padding: .75rem 1rem; background: var(--ink); color: var(--paper); border-radius: 8px; }
.skip-link:focus { top: 1rem; }
.site-header { width: min(1120px, calc(100% - 3rem)); margin-inline: auto; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 1rem 2rem; padding-block: 1.5rem; border-bottom: 1px solid var(--line); }
.wordmark { font-size: 1.375rem; font-weight: 650; letter-spacing: -.055em; text-decoration: none; }
.wordmark span { color: var(--subtle); }
.site-header nav { display: flex; align-items: center; flex-wrap: wrap; gap: 1.75rem; min-width: 0; }
.site-header nav a { padding-block: .5rem; font-size: .875rem; text-decoration: none; color: var(--muted); }
.site-header nav a:hover, .site-header nav a[aria-current] { color: var(--ink); }
.site-header nav a[aria-current] { text-decoration: underline; }
.theme-toggle { display: inline-grid; place-items: center; flex: 0 0 44px; width: 44px; height: 44px; padding: 0; border: 1px solid var(--line); border-radius: 50%; background: var(--surface); color: var(--ink); cursor: pointer; }
.theme-toggle[hidden] { display: none; }
.theme-control { display: inline-flex; align-items: center; gap: .5rem; min-height: 44px; padding-inline: .625rem; border: 1px solid var(--line); border-radius: 8px; color: var(--ink); font-size: .8125rem; }
.theme-control[hidden] { display: none; }
.theme-control select { min-height: 42px; padding-inline: .1875rem; border: 0; background: transparent; color: inherit; font: inherit; font-size: .875rem; cursor: pointer; }
.theme-toggle svg { grid-area: 1 / 1; width: 20px; height: 20px; }
.sun-icon { display: none; }
:root[data-theme="dark"] .sun-icon { display: block; }
:root[data-theme="dark"] .moon-icon { display: none; }
main { width: min(54rem, calc(100% - 3rem)); margin: 0 auto; padding-block: 4rem 5rem; }
.resume-heading { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 1.5rem 2rem; }
.resume-heading > div { flex: 1 1 28rem; min-width: 0; }
.eyebrow { color: var(--muted); font-size: .875rem; font-weight: 500; letter-spacing: .03em; }
h1 { margin-top: .75rem; font-size: clamp(2.5rem, 5vw, 3.5rem); line-height: 1.08; letter-spacing: -.055em; }
.title { margin-top: .75rem; color: var(--text); font-size: 1.125rem; line-height: 1.5; }
.button { display: inline-block; flex: 0 1 auto; margin-top: .25rem; padding: .75rem 1.25rem; max-width: 100%; border-radius: 100px; background: var(--ink); color: var(--paper); font-size: .9375rem; line-height: 1.5; font-weight: 500; text-decoration: none; transition: background .15s ease; }
.button:hover { background: var(--button-hover); }
.button span { margin-left: .25rem; }
.contacts { padding: 0; margin-top: 1.5rem; list-style: none; display: flex; flex-wrap: wrap; gap: .375rem 1.5rem; color: var(--muted); font-size: .9375rem; }
.contacts a { display: inline-block; padding-block: .375rem; }
.contacts a:hover { color: var(--ink); }
.summary { max-width: 47rem; margin-top: 1.25rem; color: var(--text); font-size: 1.0625rem; line-height: 1.65; }
section { margin-top: 2.5rem; }
h2 { padding-bottom: .75rem; margin-bottom: 1.25rem; border-bottom: 1px solid var(--line); color: var(--muted); font-size: .8125rem; line-height: 1.5; font-weight: 500; letter-spacing: .05em; text-transform: uppercase; }
h3 { font-size: 1.125rem; line-height: 1.4; letter-spacing: -.02em; }
.entry + .entry { margin-top: 1.75rem; }
.entry-heading { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: .25rem 1.5rem; }
.period, .note { color: var(--muted); font-size: .9375rem; }
.period { font-variant-numeric: tabular-nums; }
.role { margin-top: .25rem; }
.note { margin-top: .25rem; }
.entry ul { padding-left: 1.2rem; margin-top: .75rem; color: var(--text); }
.entry li { padding-left: .15rem; }
.entry li + li { margin-top: .5rem; }
.entry li::marker { color: var(--muted); }
.project + .project { margin-top: 1.25rem; }
.project h3 a { text-decoration-thickness: 1px; }
.project p { margin-top: .375rem; color: var(--text); }
.skills > div { display: grid; grid-template-columns: 7rem minmax(0, 1fr); gap: .25rem 1.5rem; }
.skills > div + div { margin-top: .75rem; }
dt { font-weight: 500; }
dd { color: var(--text); }
section:last-child > p { margin-top: .25rem; color: var(--text); }
@media (max-width: 700px) {
  .site-header, main { width: calc(100% - min(2.5rem, 40px)); }
  .site-header { padding-block: 1.25rem; gap: 1rem; }
  .site-header nav { width: 100%; gap: 1.5rem; }
  main { padding-block: 2.5rem 3rem; }
  .resume-heading { gap: 1.25rem; }
  .resume-heading > div { flex-basis: 100%; }
  h1 { font-size: clamp(2.125rem, 8vw, 3.5rem); letter-spacing: -.045em; }
  .title { font-size: 1.0625rem; }
  .button { margin-top: 0; }
  .contacts { gap: .375rem 1.25rem; margin-top: 1.25rem; }
  .summary { font-size: 1rem; }
  section { margin-top: 2rem; }
  .entry-heading { display: block; }
  .period { margin-top: .25rem; }
  .skills > div { display: block; }
  .skills > div + div { margin-top: .875rem; }
}
@media screen and (prefers-reduced-motion: no-preference) {
  body { transition: background-color 180ms ease, color 180ms ease; }
  .theme-toggle, .button { transition: background-color 180ms ease, color 180ms ease, border-color 180ms ease, transform 180ms ease; }
  .theme-toggle svg { animation: theme-icon-enter 180ms ease-out; }
  @media (hover: hover) {
    .theme-toggle:hover, .button:hover { transform: translateY(-2px); }
  }
  .theme-toggle:active, .button:active { transform: translateY(0); }
}
@keyframes theme-icon-enter {
  from { opacity: .6; transform: rotate(-20deg) scale(.9); }
  to { opacity: 1; transform: rotate(0) scale(1); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; }
}
@media print {
  @page { size: letter; margin: .5in .55in; }
  :root, :root[data-theme], :root:not([data-theme]) { color-scheme: light; --paper: #ffffff; --ink: #111111; --muted: #626269; --line: #e4e4e7; --text: #111111; }
  body { font: 10pt/1.27 Helvetica, Arial, sans-serif; }
  .site-header, .skip-link, .button, .eyebrow { display: none; }
  main { width: 100%; margin: 0; padding: 0; }
  .resume-heading { display: block; }
  h1 { margin: 0; font-size: 25pt; line-height: 1.12; letter-spacing: -.035em; }
  .title { margin-top: 0; font-size: 11pt; line-height: 15pt; }
  .contacts, .period, .note { font-size: 9.5pt; }
  .contacts { display: flex; margin-top: 5pt; gap: 3pt 9pt; line-height: 13pt; }
  .contacts a { padding: 0; }
  .summary { max-width: none; margin-top: 8pt; font-size: 10pt; line-height: 1.27; }
  section { margin-top: 10pt; }
  h2 { font-size: 10pt; line-height: 13pt; padding-bottom: 3pt; margin-bottom: 5pt; letter-spacing: 0; font-weight: 600; }
  h3 { font-size: 10.7pt; line-height: 13pt; letter-spacing: 0; }
  .entry + .entry { margin-top: 5pt; }
  .entry-heading { display: flex; }
  .period { margin: 0; }
  .role { margin: 0 0 3pt; }
  .note { margin: 0 0 4pt; line-height: 12pt; }
  .entry ul { margin-top: 0; padding-left: 9pt; }
  .entry li { padding-left: 0; }
  .entry li + li { margin-top: 3pt; }
  .project + .project { margin-top: 5pt; }
  .project h3 { display: inline; font-size: 10pt; }
  .project h3::after { content: " - "; font-weight: 400; }
  .project p { display: inline; margin: 0; }
  .skills > div { display: block; }
  .skills > div + div { margin-top: 2pt; }
  dt, dd { display: inline; }
  dt { font-weight: 600; }
  dt::after { content: ": "; }
  section:last-child > p { margin: 0; }
  .entry, .project, .skills > div { break-inside: avoid; }
  h2 { break-after: avoid; }
  a { text-decoration: none; }
}
