/* danielnovas.com
   One stylesheet, no frameworks, nothing loaded from third parties. */

@font-face {
  font-family: "Mona Sans";
  src: url("fonts/MonaSans-Variable.woff2") format("woff2");
  font-weight: 200 900;
  font-stretch: 75% 125%;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Mona Sans";
  src: url("fonts/MonaSans-Variable-Italic.woff2") format("woff2");
  font-weight: 200 900;
  font-stretch: 75% 125%;
  font-style: italic;
  font-display: swap;
}

/* ---------- Tokens ---------- */
:root {
  color-scheme: dark;
  --bg: #101010;
  --surface: #171717;
  --surface-2: #1d1d1d;
  --text: #ededed;
  --text-2: #bdbdbd;
  --muted: #8d8d8d;
  --line: #242424;
  --line-strong: #383838;
  --invert-bg: #ededed;
  --invert-text: #101010;

  --font: "Mona Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --wrap: 1040px;
  --read: 660px;
  --gutter: 24px;
  --space: 168px;
}
:root[data-theme="light"] {
  color-scheme: light;
  --bg: #fafafa;
  --surface: #f0f0f0;
  --surface-2: #e9e9e9;
  --text: #141414;
  --text-2: #444444;
  --muted: #6b6b6b;
  --line: #e2e2e2;
  --line-strong: #cdcdcd;
  --invert-bg: #141414;
  --invert-text: #fafafa;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 18px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: 0.2em; text-decoration-thickness: 1px; transition: text-decoration-color .15s ease, color .15s ease; }
a:hover { text-decoration-color: currentColor; }
:focus-visible { outline: 2px solid var(--text); outline-offset: 3px; border-radius: 6px; }
::selection { background: var(--text); color: var(--bg); }
h1, h2, h3 { margin: 0; font-weight: 640; letter-spacing: -0.025em; line-height: 1.1; text-wrap: balance; }
p { margin: 0 0 1.1em; }
.skip { position: absolute; left: -9999px; top: 8px; background: var(--invert-bg); color: var(--invert-text); padding: 8px 14px; border-radius: 8px; z-index: 10; }
.skip:focus { left: 8px; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.narrow { max-width: calc(var(--read) + 2 * var(--gutter)); }

/* ---------- Buttons ---------- */
.buttons { display: flex; flex-wrap: wrap; gap: 12px; }
.center .buttons, .buttons.center { justify-content: center; }
.button {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 48px; padding: 0 24px; border-radius: 999px;
  font: inherit; font-size: 16px; font-weight: 580; line-height: 1; text-decoration: none; white-space: nowrap;
  border: 1px solid var(--line-strong); color: var(--text); background: transparent; cursor: pointer;
  transition: background .15s ease, border-color .15s ease, opacity .15s ease;
}
.button:hover { border-color: var(--text); }
.button.primary { background: var(--invert-bg); color: var(--invert-text); border-color: var(--invert-bg); }
.button.primary:hover { opacity: .86; }
.button.small { height: 38px; padding: 0 16px; font-size: 14.5px; }
.button .arrow { width: 14px; height: 14px; }

/* ---------- Header ---------- */
.site-header { position: sticky; top: 0; z-index: 5; background: color-mix(in srgb, var(--bg) 82%, transparent); backdrop-filter: saturate(160%) blur(14px); -webkit-backdrop-filter: saturate(160%) blur(14px); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 72px; }
.wordmark { font-weight: 660; font-size: 17px; letter-spacing: -0.01em; text-decoration: none; font-stretch: 110%; }
.site-nav { display: flex; align-items: center; gap: 28px; font-size: 15px; }
.site-nav .links { display: flex; gap: 28px; }
.site-nav .links a { text-decoration: none; color: var(--muted); }
.site-nav .links a:hover, .site-nav .links a[aria-current="page"] { color: var(--text); }
.site-nav .actions { display: flex; align-items: center; gap: 10px; }
.theme-toggle {
  display: inline-grid; place-items: center; width: 38px; height: 38px;
  border: 1px solid var(--line-strong); border-radius: 999px; background: transparent; color: var(--muted);
  cursor: pointer; padding: 0; transition: color .15s ease, border-color .15s ease;
}
.theme-toggle:hover { color: var(--text); border-color: var(--text); }
.theme-toggle svg { width: 15px; height: 15px; }

/* ---------- Hero ---------- */
.hero { min-height: calc(62vh - 72px); display: grid; align-items: center; padding: 96px 0 24px; text-align: center; }
.hero + .section { padding-top: 72px; }
.hero h1 {
  font-size: clamp(2.7rem, 1.2rem + 5.2vw, 5.2rem);
  font-weight: 650;
  font-stretch: 112%;
  letter-spacing: -0.042em;
  line-height: 0.98;
  margin: 0 auto 36px;
}
.hero .wrap { max-width: 1180px; }
.hero h1 .line { display: block; }
.hero h1 .soft { color: var(--muted); }
.hero .lede { font-size: clamp(1.25rem, 1rem + 1vw, 1.6rem); line-height: 1.45; color: var(--muted); max-width: 33em; margin: -12px auto 40px; font-weight: 500; letter-spacing: -0.01em; }

.hero .avatar { width: 96px; height: 96px; border-radius: 50%; object-fit: cover; margin: 0 auto 32px; border: 1px solid var(--line-strong); }

/* ---------- Sections ---------- */
.section { padding: var(--space) 0 0; }
.section:last-of-type { padding-bottom: var(--space); }
.section-head { text-align: center; max-width: 720px; margin: 0 auto 56px; }
.section-head h2 { font-size: clamp(2rem, 1.4rem + 2.2vw, 3.1rem); font-stretch: 110%; letter-spacing: -0.035em; line-height: 1.04; }
.section-head p { font-size: 19px; color: var(--muted); margin: 18px auto 0; max-width: 32em; }
.section-foot { margin-top: 40px; }
.end-space { height: var(--space); }
[id] { scroll-margin-top: 96px; }
.eyebrow { font-size: 13px; font-weight: 560; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); margin: 0 0 18px; }

/* ---------- Cards ---------- */
.cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.card {
  display: flex; flex-direction: column; align-items: flex-start;
  background: var(--surface); border: 1px solid var(--line); border-radius: 24px;
  padding: 40px 36px 36px; min-height: 280px;
}
.card .label { font-size: 13px; font-weight: 560; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); margin: 0 0 20px; }
.card h3 { font-size: 27px; font-stretch: 106%; letter-spacing: -0.025em; margin-bottom: 12px; }
.card p { color: var(--text-2); font-size: 17px; line-height: 1.6; margin: 0 0 28px; max-width: 30em; }
.card .button { margin-top: auto; }
.card.plain { min-height: 0; }
.card.plain p:not(.label) { margin-bottom: 0; }
.card.compact { min-height: 0; padding: 32px; }
.card.compact h3 { font-size: 21px; }
.card.compact p { margin-bottom: 0; }

/* ---------- Newsletter ---------- */
.signup { text-align: center; }
.signup form { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; max-width: 520px; margin: 0 auto; }
.signup label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.signup input[type="email"] {
  flex: 1 1 260px; height: 48px; padding: 0 20px; font: inherit; font-size: 16px;
  color: var(--text); background: var(--surface); border: 1px solid var(--line-strong); border-radius: 999px;
}
.signup input[type="email"]::placeholder { color: var(--muted); }
.signup input[type="email"]:focus { outline: none; border-color: var(--text); }
.signup .fine { font-size: 13.5px; color: var(--muted); margin: 18px 0 0; }
.signup .fine a { color: var(--muted); }
.signup-panel { background: var(--surface); border: 1px solid var(--line); border-radius: 28px; padding: 72px 32px; }
.signup-panel input[type="email"] { background: var(--bg); }

/* ---------- Inner pages ---------- */
.page-head { text-align: center; padding: 120px 0 72px; }
.page-head h1 { font-size: clamp(2.6rem, 1.6rem + 3.6vw, 4.4rem); font-stretch: 112%; letter-spacing: -0.04em; line-height: 1; margin-bottom: 22px; }
.page-head .lede { font-size: 20px; color: var(--text-2); max-width: 32em; margin: 0 auto; }
.page-head .buttons { margin-top: 36px; }
.page-head .stamp { font-size: 14px; color: var(--muted); margin: 18px 0 0; }

/* Prose */
.prose { max-width: var(--read); margin: 0 auto; }
.prose p, .prose li { color: var(--text-2); }
.prose strong { color: var(--text); font-weight: 600; }
.prose h2 { font-size: 26px; font-stretch: 106%; margin: 64px 0 16px; letter-spacing: -0.02em; }
.prose h2:first-child { margin-top: 0; }
.prose h3 { font-size: 20px; margin: 36px 0 10px; letter-spacing: -0.01em; }
.prose ul, .prose ol { padding-left: 1.2em; margin: 0 0 1.2em; }
.prose li { margin-bottom: 0.45em; }
.prose blockquote { margin: 1.6em 0; padding: 0 0 0 20px; border-left: 2px solid var(--text); color: var(--text); font-size: 20px; }
.prose hr { border: 0; border-top: 1px solid var(--line); margin: 56px 0; }
.prose .takeaway { margin: 2em 0; padding: 26px 30px; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; color: var(--text); font-size: 20px; line-height: 1.5; font-weight: 580; }
.note { font-size: 15px; color: var(--muted); }
.prose .note { border-top: 1px solid var(--line); padding-top: 18px; margin-top: 48px; }
.prose .buttons { margin-top: 40px; }

/* Portrait (About) */
.portrait { margin: 0 0 56px; }
.portrait img { width: 100%; max-width: 360px; height: auto; border-radius: 24px; border: 1px solid var(--line); }

/* Video link (Talks) */
.video { display: flex; align-items: center; gap: 20px; padding: 22px 24px; margin: 0 0 32px; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; text-decoration: none; transition: border-color .15s ease; }
.video:hover { border-color: var(--line-strong); }
.video .play { flex: none; display: grid; place-items: center; width: 56px; height: 56px; border-radius: 50%; background: var(--invert-bg); color: var(--invert-text); }
.video .play svg { width: 22px; height: 22px; margin-left: 3px; }
.video-text { display: grid; gap: 4px; }
.video-text strong { font-size: 19px; font-weight: 620; letter-spacing: -0.01em; color: var(--text); }
.video-text span { font-size: 15px; color: var(--muted); }

/* Lists of field notes */
.notes { list-style: none; margin: 0; padding: 0; }
.notes li { padding: 26px 0; border-bottom: 1px solid var(--line); }
.notes li:first-child { border-top: 1px solid var(--line); }
.notes h3 { font-size: 21px; font-weight: 620; letter-spacing: -0.015em; line-height: 1.3; margin-bottom: 8px; }
.notes h3 a { text-decoration: none; }
.notes h3 a:hover { text-decoration: underline; text-decoration-color: var(--line-strong); }
.meta { font-size: 14px; color: var(--muted); display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin: 0; }
.tag { display: inline-block; font-size: 12px; line-height: 1; padding: 6px 10px; border: 1px solid var(--line-strong); border-radius: 999px; color: var(--muted); letter-spacing: 0.02em; }

/* Uses page */
.uses { margin: 0 0 1.4em; padding: 0; }
.uses div { display: grid; grid-template-columns: 180px 1fr; gap: 4px 24px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.uses div:first-child { border-top: 1px solid var(--line); }
.uses dt { color: var(--text); font-weight: 600; margin: 0; }
.uses dd { color: var(--text-2); margin: 0; }

/* Copy-ready bios (Talks page) */
.bio { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 26px 28px; margin: 0 0 16px; }
.bio-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 12px; }
.bio-top span { font-size: 13px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); font-weight: 560; }
.bio p { margin: 0; color: var(--text); font-size: 17px; }

/* Article */
.article-head { text-align: center; padding: 120px 0 64px; }
.article-head .kicker { font-size: 14px; color: var(--muted); margin-bottom: 22px; }
.article-head .kicker a { text-decoration: none; }
.article-head h1 { font-size: clamp(2.2rem, 1.5rem + 2.8vw, 3.6rem); font-stretch: 108%; letter-spacing: -0.035em; line-height: 1.06; margin: 0 auto 22px; max-width: 18em; }
.article-head .summary { font-size: 20px; color: var(--text-2); margin: 0 auto; max-width: 32em; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); padding: 36px 0 44px; font-size: 15px; color: var(--muted); }
.site-footer .wrap { display: flex; justify-content: space-between; align-items: center; gap: 16px 32px; flex-wrap: wrap; }
.site-footer .who { color: var(--text); font-weight: 600; margin: 0; }
.site-footer nav { display: flex; gap: 8px 24px; flex-wrap: wrap; }
.site-footer a { text-decoration: none; color: var(--muted); }
.site-footer a:hover { color: var(--text); }

/* ---------- 404 ---------- */
.not-found { min-height: 70vh; display: grid; place-items: center; text-align: center; padding: 96px 0; }
.not-found h1 { font-size: clamp(2.4rem, 1.6rem + 3.2vw, 4rem); font-stretch: 112%; letter-spacing: -0.04em; margin-bottom: 18px; }
.not-found p { color: var(--text-2); max-width: 30em; margin: 0 auto 32px; }

/* ---------- Small screens ---------- */
@media (max-width: 820px) {
  :root { --space: 112px; }
  .cards { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  :root { --gutter: 20px; --space: 96px; }
  body { font-size: 17px; }
  .site-header .wrap { height: 64px; }
  .site-nav, .site-nav .links { gap: 16px; }
  .site-nav .links { font-size: 14.5px; }
  .site-nav .subscribe { display: none; }
  .hero { min-height: 0; padding: 72px 0 8px; }
  .hero + .section { padding-top: 64px; }
  .hero h1 { font-size: 2.6rem; font-stretch: 104%; letter-spacing: -0.035em; margin-bottom: 28px; }
  .hero .lede { font-size: 20px; }
  .video { padding: 18px; gap: 16px; }
  .section-head { margin-bottom: 40px; }
  .section-head p { font-size: 17.5px; }
  .card { padding: 32px 26px 28px; min-height: 0; border-radius: 20px; }
  .card h3 { font-size: 24px; }
  .signup-panel { padding: 52px 22px; border-radius: 22px; }
  .page-head, .article-head { padding: 80px 0 52px; }
  .page-head .lede { font-size: 18px; }
  .uses div { grid-template-columns: 1fr; }
  .buttons .button { flex: 1 1 auto; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
