/* calvinmattson.com — shared styles */
:root {
  --paper: #EDEFF0;
  --ink: #1B2530;
  --ink-soft: #4A5661;
  --rule: #C5CBD0;
  --accent: #0F6E73;
  --plate-a: #D9DDE0;
  --plate-b: #AEB5BB;
  --plate-ink: #1E2832;
  --frame: #DADFE2;
  --todo: #FFF1B8;
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #161C22;
    --ink: #E3E7EA;
    --ink-soft: #9AA5AE;
    --rule: #2C353D;
    --accent: #4FB3B8;
    --plate-a: #4A535B;
    --plate-b: #2B3238;
    --plate-ink: #E8ECEE;
    --frame: #232B32;
    --todo: #4A4220;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Barlow", system-ui, sans-serif;
  font-size: 1.125rem;
  line-height: 1.6;
}
a { color: var(--accent); text-underline-offset: 3px; }
a:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 2px; }
img { max-width: 100%; display: block; }

.wrap { max-width: 46rem; margin: 0 auto; padding: 0 1rem; }

/* ---------- Nameplate ---------- */
.plate {
  position: relative;
  padding: 2.25rem 2.5rem 2rem;
  border-radius: 6px;
  color: var(--plate-ink);
  background:
    repeating-linear-gradient(90deg, rgba(255,255,255,.07) 0 1px, transparent 1px 3px),
    linear-gradient(160deg, var(--plate-a), var(--plate-b));
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.45),
    inset 0 -1px 0 rgba(0,0,0,.25),
    0 1px 2px rgba(0,0,0,.2),
    0 8px 24px -12px rgba(0,0,0,.35);
}
.rivet {
  position: absolute; width: 12px; height: 12px; border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #f4f6f7, #8d969d 60%, #5c656c);
  box-shadow: 0 1px 1px rgba(0,0,0,.4);
}
.rivet.tl { top: 12px; left: 12px; } .rivet.tr { top: 12px; right: 12px; }
.rivet.bl { bottom: 12px; left: 12px; } .rivet.br { bottom: 12px; right: 12px; }
.plate h1 {
  margin: 0;
  font-family: "Barlow Condensed", sans-serif;
  font-weight: 700;
  font-size: clamp(2.6rem, 8vw, 4rem);
  line-height: 1;
  letter-spacing: .06em;
  text-transform: uppercase;
  text-shadow: 0 1px 0 rgba(255,255,255,.35);
}
.plate .role {
  margin: .5rem 0 1.5rem;
  font-family: "Barlow Condensed", sans-serif;
  font-weight: 500;
  font-size: 1.35rem;
  letter-spacing: .04em;
}
.plate dl {
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: .3rem 1.25rem;
  margin: 0;
  padding-top: 1rem;
  border-top: 1px solid rgba(0,0,0,.22);
  font-family: "Barlow Condensed", sans-serif;
  font-size: 1.05rem;
  letter-spacing: .05em;
  text-transform: uppercase;
}
.plate dt { font-weight: 600; opacity: .7; }
.plate dd { margin: 0; font-weight: 600; }

/* ---------- Landing page ---------- */
.landing { min-height: 100vh; display: flex; flex-direction: column; justify-content: center; padding-top: 3rem; padding-bottom: 3rem; }
.intro { display: grid; grid-template-columns: 13rem 1fr; gap: 2rem; align-items: center; }
.portrait {
  aspect-ratio: 4 / 5;
  border-radius: 6px;
  overflow: hidden;
  background: var(--frame);
  border: 1px solid var(--rule);
  display: grid; place-items: center;
  color: var(--ink-soft);
  font-family: "Barlow Condensed", sans-serif;
  font-size: 1.1rem;
}
.portrait > * { grid-area: 1 / 1; }
.portrait img { width: 100%; height: 100%; object-fit: cover; }

.doors { list-style: none; margin: 3rem 0 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }
.doors a {
  display: block;
  height: 100%;
  padding: 1.25rem 0 0;
  border-top: 3px solid var(--ink);
  color: var(--ink);
  text-decoration: none;
}
.doors a:hover .door-title, .doors a:focus-visible .door-title { color: var(--accent); text-decoration: underline; text-underline-offset: 4px; }
.door-title {
  display: block;
  font-family: "Barlow Condensed", sans-serif;
  font-weight: 600;
  font-size: 2rem;
  line-height: 1.1;
}
.door-text { display: block; margin-top: .4rem; color: var(--ink-soft); }

/* ---------- Inner page header ---------- */
.site-head {
  display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between;
  gap: .5rem 1.5rem;
  padding: 1.5rem 0;
  border-bottom: 1px solid var(--rule);
}
.site-name {
  font-family: "Barlow Condensed", sans-serif;
  font-weight: 700;
  font-size: 1.4rem;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--ink);
  text-decoration: none;
}
.site-nav { display: flex; gap: 1.5rem; }
.site-nav a { color: var(--ink-soft); text-decoration: none; }
.site-nav a:hover { color: var(--accent); text-decoration: underline; }
.site-nav a[aria-current="page"] { color: var(--ink); font-weight: 600; }

.page-title {
  margin: 3rem 0 .5rem;
  font-family: "Barlow Condensed", sans-serif;
  font-weight: 700;
  font-size: clamp(2.4rem, 7vw, 3.25rem);
  line-height: 1.05;
}

/* ---------- Sections ---------- */
section { padding: 2.5rem 0; border-top: 1px solid var(--rule); }
.page-title + .lede + section, .page-title + section { margin-top: 2rem; }
h2 {
  margin: 0 0 1.25rem;
  font-family: "Barlow Condensed", sans-serif;
  font-weight: 600;
  font-size: 1.9rem;
  line-height: 1.15;
}
h3 { margin: 0; font-size: 1.15rem; font-weight: 600; }
p { margin: 0 0 1rem; max-width: 65ch; }
.lede { font-size: 1.3rem; line-height: 1.5; }
.muted { color: var(--ink-soft); }

/* Experience timeline */
.timeline { list-style: none; margin: 0; padding: 0; }
.timeline > li {
  display: grid;
  grid-template-columns: 8.5rem 1fr;
  gap: 1.25rem;
  padding: 1.1rem 0;
}
.timeline > li + li { border-top: 1px dashed var(--rule); }
.when { font-family: "Barlow Condensed", sans-serif; font-weight: 500; color: var(--ink-soft); padding-top: .1rem; }
.timeline .org { color: var(--ink-soft); margin: .1rem 0 .5rem; }
.timeline ul { margin: 0; padding-left: 1.1rem; }
.timeline ul li { padding: .15rem 0; }

/* Toolbox: bill-of-materials style */
.bom { width: 100%; border-collapse: collapse; }
.bom th, .bom td { text-align: left; vertical-align: top; padding: .65rem 0; border-bottom: 1px solid var(--rule); }
.bom th { width: 11rem; padding-right: 1.25rem; font-weight: 600; }
.bom tr:last-child th, .bom tr:last-child td { border-bottom: 0; }

/* Personal page */
.life { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem 2.5rem; }
.life p { margin: .35rem 0 0; }

.contact-list { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .75rem 2rem; font-size: 1.2rem; }

footer { padding: 2rem 0 3rem; border-top: 1px solid var(--rule); font-size: .95rem; color: var(--ink-soft); }
.landing footer { border-top: 0; padding: 3rem 0 0; }

/* Placeholder marker — delete these spans as you fill them in */
.todo { background: var(--todo); padding: 0 .2em; border-radius: 2px; }

@media (max-width: 640px) {
  .landing { justify-content: flex-start; padding-top: 1.5rem; padding-bottom: 2rem; }
  .intro { grid-template-columns: 1fr; gap: 1.25rem; }
  .portrait { width: 9rem; }
  .plate { padding: 2rem 1.5rem 1.6rem; }
  .doors { grid-template-columns: 1fr; margin-top: 2rem; }
  .timeline > li { grid-template-columns: 1fr; gap: .25rem; }
  .bom tr { display: block; border-bottom: 1px solid var(--rule); padding: .5rem 0; }
  .bom tr:last-child { border-bottom: 0; }
  .bom th, .bom td { display: block; width: auto; border-bottom: 0; padding: 0; }
  .bom th { padding-bottom: .1rem; }
  .life { grid-template-columns: 1fr; }
}
