/* michaelmclarengradinaru.com
   Executive genre. Geist throughout. Near-black ink, one accent, two alternating surfaces,
   flat blocks, no motion. Dark by default with a light toggle, per the owner. 8 px grid. */

@font-face { font-family: "Geist"; font-weight: 400; font-style: normal; font-display: swap; src: url("/fonts/geist-sans-400.woff2") format("woff2"); }
@font-face { font-family: "Geist"; font-weight: 500; font-style: normal; font-display: swap; src: url("/fonts/geist-sans-500.woff2") format("woff2"); }
@font-face { font-family: "Geist"; font-weight: 700; font-style: normal; font-display: swap; src: url("/fonts/geist-sans-700.woff2") format("woff2"); }

:root {
  --paper: #faf9f6;
  --band: #f1efe9;
  --card: #ffffff;
  --ink: #17191d;
  --ink-2: rgba(23, 25, 29, .86);
  --ink-3: rgba(23, 25, 29, .62);
  --rule: rgba(23, 25, 29, .12);
  --accent: #1f3b63;
  --sans: "Geist", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
:root[data-theme="dark"] {
  --paper: #0e0f12;
  --band: #14161b;
  --card: #1a1d23;
  --ink: #eeece7;
  --ink-2: rgba(238, 236, 231, .86);
  --ink-3: rgba(238, 236, 231, .62);
  --rule: rgba(238, 236, 231, .13);
  --accent: #a6c4ef;
}

* { box-sizing: border-box; }
html { background: var(--paper); scroll-padding-top: 4.5rem; }
body {
  margin: 0;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 18px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-variant-numeric: tabular-nums;
}
a { color: var(--accent); text-decoration: none; }
a:hover, a:focus-visible { text-decoration: underline; text-underline-offset: .15em; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
::selection { background: var(--accent); color: var(--paper); }
h1, h2, h3, p, ol, ul { margin: 0; }
strong { font-weight: 500; }

.wrap { max-width: 72rem; margin: 0 auto; padding: 0 clamp(1.25rem, 4vw, 2.5rem); }

/* Sticky bar */
.bar {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 1rem clamp(1.25rem, 4vw, 2.5rem);
  background: var(--paper);
  border-bottom: 1px solid var(--rule);
}
.brand { color: var(--ink); font-weight: 500; white-space: nowrap; }
.brand:hover { text-decoration: none; }
.nav { display: flex; gap: 1.5rem; font-size: 1rem; }
.nav a { color: var(--ink-2); }
.nav a:hover, .nav a.active { color: var(--ink); text-decoration: none; }
.nav .nav-cta { color: var(--accent); font-weight: 500; }

/* Hero */
.hero { padding: clamp(3rem, 7vw, 6rem) 0 clamp(2.5rem, 5vw, 4rem); }
.hero-grid { display: grid; grid-template-columns: 1fr auto; gap: 3rem; align-items: center; }
.kicker { font-size: 1.05rem; color: var(--ink-2); margin-bottom: 1rem; }
h1 {
  font-weight: 700;
  font-size: clamp(2.4rem, 5.2vw, 3.7rem);
  line-height: 1.02;
  letter-spacing: -.035em;
}
@media (min-width: 44rem) { h1 .surname { white-space: nowrap; } }
h1 .phd { font-size: .42em; font-weight: 400; letter-spacing: 0; color: var(--ink-3); white-space: nowrap; }
.hero-lede { margin: 1.5rem 0 0; max-width: 34rem; font-size: clamp(1.1rem, 1.5vw, 1.25rem); line-height: 1.5; color: var(--ink-2); }
.cta { margin-top: 2rem; }
.btn {
  display: inline-block;
  padding: .75rem 1.25rem;
  border-radius: 4px;
  background: var(--accent);
  color: var(--paper);
  font-weight: 500;
  font-size: 1rem;
  font-family: var(--sans);
  border: 1px solid var(--accent);
  cursor: pointer;
}
.btn:hover { text-decoration: none; filter: brightness(1.1); }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--rule); }
.btn.ghost:hover { border-color: var(--ink-3); background: transparent; }

.portrait { margin: 0; }
.portrait img {
  display: block;
  width: min(100%, 360px);
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 4px;
}

/* Sections */
section { padding: clamp(3rem, 6vw, 6rem) 0; }
section.band { background: var(--band); }
h2 {
  font-weight: 700;
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  line-height: 1.1;
  letter-spacing: -.025em;
  margin-bottom: 1.5rem;
}
.h2-gap { margin-top: 4rem; }
h3 { font-size: 1.125rem; font-weight: 500; line-height: 1.35; }
.section-lede { max-width: 42rem; font-size: 1.125rem; color: var(--ink-2); margin-bottom: 2rem; }
.two-col { display: grid; grid-template-columns: 1.5fr 1fr; gap: 4rem; align-items: start; }
.bio { max-width: 40rem; color: var(--ink); }
.bio + .bio { margin-top: 1rem; }
.bio.small { font-size: 1rem; color: var(--ink-2); margin-top: 1.5rem; }

/* Experience */
.side h3 { font-size: .875rem; font-weight: 500; color: var(--ink-3); margin-bottom: .5rem; }
.exp { list-style: none; padding: 0; }
.exp li {
  display: grid;
  grid-template-columns: 7rem 1fr;
  gap: 1rem;
  padding: .75rem 0;
  border-top: 1px solid var(--rule);
  font-size: 1rem;
  line-height: 1.5;
  color: var(--ink-2);
}
.exp li:last-child { border-bottom: 1px solid var(--rule); }
.exp .when { font-size: .875rem; color: var(--ink-3); padding-top: .1rem; white-space: nowrap; }
.exp strong { color: var(--ink); }

/* Cards: flat blocks, Ng style */
.cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.5rem; }
.cards.three { grid-template-columns: repeat(3, 1fr); }
.card {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: 4px;
  padding: 1.5rem 1.75rem 1.75rem;
}
.card .card-kicker { font-size: .875rem; color: var(--ink-3); margin-bottom: .5rem; }
.card h3 { margin-bottom: .5rem; font-size: 1.25rem; }
.card p { color: var(--ink); font-size: 1rem; line-height: 1.55; }
.card .card-link { margin-top: 1rem; font-size: 1rem; }
.card .card-link a + a { margin-left: 1rem; }
.also { max-width: 48rem; margin-top: 1.5rem; color: var(--ink); font-size: 1rem; line-height: 1.55; }

/* Papers */
.papers { list-style: none; padding: 0; max-width: 46rem; }
.papers li { display: grid; grid-template-columns: 4rem 1fr; gap: 1rem; padding: 1rem 0; border-top: 1px solid var(--rule); }
.papers li:last-child { border-bottom: 1px solid var(--rule); }
.papers .year { font-size: .875rem; color: var(--ink-3); padding-top: .15rem; }
.papers p { color: var(--ink); font-size: 1rem; line-height: 1.55; }
.papers em { font-style: italic; }
.papers a { margin-left: .25rem; }
.research-foot { max-width: 46rem; margin-top: 1.5rem; color: var(--ink); font-size: 1rem; line-height: 1.55; }
.research-foot p + p { margin-top: .75rem; }
.more { margin-top: 1.5rem; }

/* Topics */
.topics { margin-top: 1rem; padding: 0; list-style: none; max-width: 40rem; }
.topics li { padding: .875rem 0; border-top: 1px solid var(--rule); color: var(--ink); font-size: 1rem; line-height: 1.55; }
.topics li:last-child { border-bottom: 1px solid var(--rule); }
.topics strong { display: block; margin-bottom: .125rem; }

/* Contact */
#contact-form .two { display: grid; grid-template-columns: 1fr 1fr; gap: 0 1rem; }
#contact-form label { display: block; margin: 0 0 1rem; font-size: .875rem; color: var(--ink-2); }
#contact-form input, #contact-form textarea {
  display: block;
  width: 100%;
  margin-top: .375rem;
  padding: .75rem .875rem;
  font: inherit;
  font-size: 1rem;
  color: var(--ink);
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: 4px;
}
#contact-form input:focus, #contact-form textarea:focus { border-color: var(--accent); outline: none; }
#contact-form textarea { resize: vertical; }
#contact-form .hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
#contact-form .actions { display: flex; align-items: center; gap: 1rem; }
#contact-form button:disabled { opacity: .5; cursor: default; }
.status { font-size: .9375rem; color: var(--ink-2); }
.sent { display: none; margin-top: .75rem; color: var(--ink-2); }
.sent:target { display: block; }

/* Organizer kit */
.kit-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.kit-item {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: 4px;
  padding: 1.5rem 1.75rem 1.75rem;
  font-size: .9375rem;
  color: var(--ink);
  line-height: 1.55;
}
.kit-item h3 { font-size: .875rem; font-weight: 500; color: var(--ink-3); }
.kit-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: .625rem; }
.kit-item > h3 { margin-bottom: .625rem; }
.h3-gap { margin-top: 1.25rem; }
.copy {
  font: inherit;
  font-size: .875rem;
  color: var(--ink-2);
  background: transparent;
  border: 1px solid var(--rule);
  border-radius: 4px;
  padding: .25rem .75rem;
  cursor: pointer;
}
.copy:hover { color: var(--ink); border-color: var(--ink-3); }

/* Footer */
.foot { border-top: 1px solid var(--rule); padding: 2.5rem 0 3rem; }
.foot-grid { display: grid; grid-template-columns: 1.5fr 1fr; gap: 1.5rem 3rem; align-items: start; }
.foot-name { font-weight: 500; }
.foot-sub { color: var(--ink-2); font-size: 1rem; margin-top: .25rem; }
.foot-nav { display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; font-size: 1rem; }
.foot-nav a { color: var(--ink-2); }
.foot-meta { grid-column: 1 / -1; font-size: .875rem; color: var(--ink-3); display: flex; flex-wrap: wrap; align-items: center; gap: 1rem; }
.theme { font: inherit; font-size: .875rem; color: var(--ink-2); background: transparent; border: 1px solid var(--rule); border-radius: 4px; padding: .25rem .75rem; cursor: pointer; }
.theme:hover { color: var(--ink); border-color: var(--ink-3); }

@media (max-width: 60rem) {
  .two-col, .foot-grid { grid-template-columns: 1fr; gap: 2.5rem; }
  .cards.three { grid-template-columns: repeat(2, 1fr); }
  .kit-grid { grid-template-columns: 1fr; }
}
@media (max-width: 44rem) {
  .bar { padding: .875rem 1.25rem; }
  .brand { font-size: .9375rem; }
  .nav { gap: 1rem; font-size: .9375rem; }
  .nav a:not(.nav-cta) { display: none; }
  .hero-grid { grid-template-columns: 1fr; gap: 2rem; }
  .portrait { order: -1; }
  .portrait img { width: 160px; }
  .cards, .cards.three { grid-template-columns: 1fr; }
  .papers li { grid-template-columns: 3.25rem 1fr; }
  .exp li { grid-template-columns: 5.5rem 1fr; }
  #contact-form .two { grid-template-columns: 1fr; }
}
