/* ============================================================
   kay2.dev — curriculum vitae.
   Document-first: sober palette, editorial type, print-clean.
   Vanilla, no build step.
   ============================================================ */
:root {
  --paper:  #fdfdfb;
  --desk:   #eceae5;
  --ink:    #17191d;
  --body:   #33373f;
  --muted:  #6b7078;
  --faint:  #9aa0a8;
  --rule:   #e3e1dc;
  --rule-2: #cfccc5;
  --accent: #2f4858;
  --max: 60rem;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: Inter, system-ui, -apple-system, sans-serif;
  background: var(--desk);
  color: var(--body);
  font-size: 16px;
  line-height: 1.62;
  -webkit-font-smoothing: antialiased;
}

.sheet {
  max-width: var(--max);
  margin: 2.5rem auto;
  background: var(--paper);
  padding: 4rem 4.5rem 3rem;
  border: 1px solid var(--rule-2);
  box-shadow: 0 1px 3px rgba(0, 0, 0, .06);
}

h1, h2, h3 { font-family: "Source Serif 4", Georgia, serif; color: var(--ink); font-weight: 600; }
a { color: var(--accent); text-decoration: none; border-bottom: 1px solid rgba(47, 72, 88, .3); }
a:hover { border-bottom-color: var(--accent); }

/* ---------- masthead ---------- */
.masthead {
  display: flex; justify-content: space-between; align-items: flex-start;
  gap: 3rem; padding-bottom: 1.6rem; border-bottom: 2px solid var(--ink);
}
.masthead h1 {
  font-size: 2.6rem; font-weight: 700; letter-spacing: -.02em; line-height: 1.05;
}
.masthead .title {
  font-size: 1.05rem; color: var(--ink); font-weight: 500; margin-top: .35rem;
}
.masthead .focus { font-size: .92rem; color: var(--muted); margin-top: .2rem; }
.masthead-side {
  display: flex; flex-direction: column; align-items: flex-end; gap: .3rem;
  font-size: .88rem; white-space: nowrap; padding-top: .4rem;
}
.masthead-side .site { font-weight: 600; }

.print-btn {
  font: inherit; font-size: .82rem; color: var(--muted); cursor: pointer;
  background: transparent; border: 1px solid var(--rule-2); border-radius: 3px;
  padding: .3rem .7rem; margin-top: .5rem; transition: all .15s ease;
}
.print-btn:hover { color: var(--ink); border-color: var(--muted); }

/* ---------- sections ---------- */
.section { padding-top: 2.4rem; }
.section h2 {
  font-family: Inter, sans-serif; font-size: .78rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: .13em; color: var(--muted);
  padding-bottom: .5rem; margin-bottom: 1.4rem; border-bottom: 1px solid var(--rule);
}
.summary { color: var(--body); }
.lede { font-size: 1.03rem; }
.note { font-size: .88rem; color: var(--muted); margin-bottom: 1rem; }

.principles { margin-top: 1.3rem; }
.principles-label {
  font-size: .78rem; font-weight: 600; text-transform: uppercase;
  letter-spacing: .1em; color: var(--faint); margin-bottom: .5rem;
}

/* ---------- bullets ---------- */
.points { list-style: none; display: grid; gap: .45rem; margin-top: .85rem; }
.points li { position: relative; padding-left: 1.1rem; font-size: .95rem; }
.points li::before {
  content: ''; position: absolute; left: 0; top: .62em;
  width: 4px; height: 4px; border-radius: 50%; background: var(--faint);
}

/* ---------- skills ---------- */
.skills { display: grid; gap: .1rem; }
.skill-row {
  display: grid; grid-template-columns: 11rem 1fr; gap: 1.5rem;
  padding: .5rem 0; border-bottom: 1px solid var(--rule);
}
.skill-row:last-child { border-bottom: 0; }
.skill-row dt { font-weight: 600; color: var(--ink); font-size: .9rem; }
.skill-row dd { font-size: .92rem; color: var(--body); }

/* ---------- work entries ---------- */
.entry { padding: 1.6rem 0; border-bottom: 1px solid var(--rule); }
.entry:last-child { border-bottom: 0; padding-bottom: .5rem; }
.entry-head {
  display: flex; justify-content: space-between; align-items: baseline;
  gap: 2rem; margin-bottom: .6rem;
}
.entry-head h3 { font-size: 1.22rem; font-weight: 600; letter-spacing: -.01em; }
.entry .meta { font-size: .87rem; color: var(--muted); margin-top: .12rem; }
.entry .period {
  font-size: .85rem; color: var(--muted); white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.entry .stack { margin-top: .9rem; font-size: .84rem; color: var(--muted); }
.stack-label {
  font-weight: 600; color: var(--faint); text-transform: uppercase;
  letter-spacing: .09em; font-size: .72rem; margin-right: .6rem;
}
.entry-slim { padding: 1.1rem 0; }

/* ---------- currently ---------- */
.current { display: grid; gap: 1.6rem 2.5rem; grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr)); }
.current-col h3 { font-size: .98rem; font-weight: 600; margin-bottom: .5rem; }
.todo { list-style: none; display: grid; gap: .35rem; }
.todo li { position: relative; padding-left: 1.25rem; font-size: .9rem; color: var(--body); }
.todo li::before {
  content: ''; position: absolute; left: 0; top: .3em;
  width: 11px; height: 11px; border: 1px solid var(--rule-2); border-radius: 2px;
}

/* ---------- footer ---------- */
.foot {
  margin-top: 3rem; padding-top: 1.2rem; border-top: 1px solid var(--rule);
  display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
  font-size: .82rem; color: var(--faint);
}

/* ---------- responsive ---------- */
@media (max-width: 720px) {
  .sheet { margin: 0; padding: 2.25rem 1.4rem 2rem; border: 0; }
  .masthead { flex-direction: column; gap: 1rem; }
  .masthead-side { align-items: flex-start; padding-top: 0; }
  .masthead h1 { font-size: 2rem; }
  .skill-row { grid-template-columns: 1fr; gap: .15rem; }
  .entry-head { flex-direction: column; gap: .2rem; }
}

/* ---------- print / save as PDF ---------- */
@page { margin: 16mm 14mm; }
@media print {
  body { background: #fff; color: #000; font-size: 10.5pt; line-height: 1.45; }
  .sheet { margin: 0; padding: 0; border: 0; box-shadow: none; max-width: none; }
  .print-btn { display: none; }
  a { color: #000; border-bottom: 0; }
  h1, h2, h3 { color: #000; }
  .section { padding-top: 1.1rem; }
  .section h2 { color: #000; }
  .entry, .current-col, .skill-row { break-inside: avoid; page-break-inside: avoid; }
  .masthead { border-bottom-color: #000; }
  .foot { color: #444; }
}
