/* Dark editorial theme: Valorant-inspired red, navy, and warm white. */
:root {
  color-scheme: dark;
  --paper: #0f1923;
  --panel: #15212c;
  --deep: #0a1118;
  --ink: #ece8e1;
  --muted: #a7adb4;
  --line: #303b46;
  --accent: #ff4655;
  --on-accent: #0a1118;
  --prose: #c5c8cb;
  --inline-code: #23303c;
  --code-bg: #0a1118;
  --code-ink: #ece8e1;
  --sans: Arial, Helvetica, sans-serif;
  --display: Impact, 'Arial Narrow', 'Franklin Gothic Medium', sans-serif;
}

:root[data-theme="light"] {
  color-scheme: light;
  --paper: #f7f5f1;
  --panel: #edeae4;
  --deep: #e4e0d9;
  --ink: #18232d;
  --muted: #53616c;
  --line: #c5c9cc;
  --accent: #b92338;
  --on-accent: #ffffff;
  --prose: #34434f;
  --inline-code: #e4e8eb;
}

.header-controls { display: flex; align-items: center; gap: 12px; margin-left: auto; }
.site-nav { order: 1; }
.theme-toggle:not([hidden]) { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 44px; padding: 9px 12px; border: 1px solid var(--line); background: var(--panel); color: var(--ink); font-size: 14px; }
.theme-toggle:hover { border-color: var(--accent); }
.more-topics { flex-basis: 100%; }
.more-topics summary { width: fit-content; cursor: pointer; min-height: 44px; }
.extra-topics { display: flex; flex-wrap: wrap; gap: 8px; padding-top: 12px; }
.clear-filters { margin-bottom: 24px; }

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 24px;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 18px/1.7 var(--sans);
  -webkit-font-smoothing: antialiased;
}

::selection {
  background: var(--accent);
  color: var(--on-accent);
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

h1,
h2,
h3,
p,
figure {
  margin: 0;
}

h1,
h2,
h3 {
  line-height: 1.1;
}

h1 {
  font-family: var(--display);
  font-weight: 400;
  letter-spacing: .005em;
}

h2 {
  font-size: clamp(36px, 3.9vw, 56px);
  font-weight: 600;
  letter-spacing: -.04em;
}

h3 {
  font-weight: 500;
}

em {
  font-style: normal;
  color: var(--accent);
}

a,
button,
input {
  -webkit-tap-highlight-color: transparent;
}

a:focus-visible,
button:focus-visible,
input:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 6px;
}

.wrap {
  width: calc(100% - 112px);
  max-width: 1320px;
  margin-inline: auto;
}

.accent {
  color: var(--accent);
}

.muted {
  color: var(--muted);
}

.eyebrow {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .14em;
  line-height: 1.7;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 100;
  transform: translateY(-180%);
  background: var(--accent);
  color: var(--deep);
  padding: 12px 20px;
}

.skip-link:focus {
  transform: none;
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 25px;
  font-size: 16px;
  border-bottom: 1px solid var(--muted);
  padding: 8px 0;
}

.text-link span {
  font-size: 25px;
  line-height: 1;
  transition: transform .2s;
}

.text-link:hover {
  color: var(--accent);
  border-color: var(--accent);
}

.text-link:hover span {
  transform: translate(3px, -3px);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 36px;
  min-height: 58px;
  padding: 16px 24px;
  background: var(--accent);
  color: var(--on-accent);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: .05em;
  border: 1px solid var(--accent);
  position: relative;
  transition: background .2s, color .2s;
}

.button::after {
  content: '';
  position: absolute;
  right: 4px;
  bottom: 4px;
  width: 5px;
  height: 5px;
  background: currentColor;
}

.button:hover {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
}

.button span {
  font-size: 25px;
  line-height: 1;
}

.button-outline {
  background: transparent;
  color: var(--ink);
  border-color: var(--line);
}

.button-outline:hover {
  background: var(--accent);
  color: var(--on-accent);
  border-color: var(--accent);
}

/* Navigation */
.site-header {
  height: 108px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  border-bottom: 1px solid var(--line);
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -.04em;
  line-height: 1.2;
}

.brand-symbol {
  color: var(--accent);
  font-weight: 900;
  font-size: 32px;
  letter-spacing: -.15em;
  padding-right: 5px;
}

.brand-period {
  color: var(--accent);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 36px;
  font-size: 16px;
}

.site-nav>a {
  position: relative;
  padding: 9px 0;
  color: var(--muted);
}

.site-nav>a:hover,
.site-nav>a[aria-current] {
  color: var(--ink);
}

.site-nav>a[aria-current]::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 18px;
  height: 2px;
  background: var(--accent);
}

.site-nav .nav-contact {
  display: flex;
  align-items: center;
  gap: 35px;
  color: var(--ink);
  border: 1px solid var(--line);
  padding: 10px 18px;
  margin-left: 12px;
}

.site-nav .nav-contact[aria-current]::after {
  left: 18px;
  bottom: 5px;
}

.nav-contact span {
  color: var(--accent);
  font-size: 24px;
  line-height: 1;
}

.nav-toggle {
  display: none;
}

/* Home */
.hero {
  position: relative;
  min-height: 0;
  display: flex;
  align-items: center;
  isolation: isolate;
}

.hero-copy {
  z-index: 2;
  position: relative;
  width: 62%;
  padding: 44px 0 36px;
}

.hero-copy .eyebrow {
  font-size: 11px;
  letter-spacing: .12em;
  color: var(--muted);
  margin-bottom: 22px;
}

.status-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  margin-right: 12px;
  background: var(--accent);
  vertical-align: 2px;
}

.hero h1 {
  font-size: clamp(48px, 5.4vw, 78px);
  line-height: 1.03;
  letter-spacing: .002em;
}

.hero-description {
  font-size: 18px;
  line-height: 1.65;
  color: var(--muted);
  margin-top: 20px;
  max-width: 62ch;
}

.hero-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 34px;
  margin-top: 24px;
}

.hero-caption {
  margin-top: 28px;
  color: var(--muted);
  font-size: 11px;
  letter-spacing: .14em;
}

.hero-caption span {
  color: var(--accent);
  margin-right: 13px;
  font-weight: 700;
}

.hero-art {
  position: absolute;
  width: 60%;
  right: -25px;
  top: 0;
  bottom: 0;
  z-index: 0;
}

.hero-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 55% center;
  mask-image: linear-gradient(to right, transparent 0%, black 24%, black 83%, transparent 100%);
  opacity: .92;
}

.hero-art::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, var(--paper), transparent 23%, transparent 82%, var(--paper)), linear-gradient(90deg, var(--paper), transparent 30%);
  pointer-events: none;
}

.art-index {
  position: absolute;
  z-index: 1;
  right: 30px;
  bottom: 39px;
  font-size: 12px;
  letter-spacing: .17em;
  color: var(--muted);
  writing-mode: vertical-rl;
}

.discipline-strip {
  display: flex;
  align-items: center;
  gap: 22px;
  padding: 26px 0;
  border-block: 1px solid var(--line);
  font-size: 11px;
  letter-spacing: .12em;
  color: var(--muted);
}

.discipline-strip>a {
  margin-left: auto;
  display: flex;
  gap: 25px;
  align-items: center;
}

.discipline-strip>a>span {
  color: var(--ink);
  font-size: 20px;
}

.journal-section {
  padding-block: 100px;
}

.section-heading {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 35px;
  margin-bottom: 48px;
}

.section-heading .eyebrow {
  margin-bottom: 20px;
  color: var(--accent);
}

.section-heading>.text-link {
  white-space: nowrap;
  margin-bottom: 5px;
}

.post-list {
  border-top: 1px solid var(--line);
}

.post-row {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) 110px;
  align-items: center;
  gap: 30px;
  padding: 36px 0;
  border-bottom: 1px solid var(--line);
}

.post-number {
  font-size: 13px;
  color: var(--muted);
  align-self: start;
  margin-top: 4px;
  font-family: Consolas, monospace;
}

.post-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 13px;
  color: var(--muted);
}

.post-meta>span:first-child {
  color: var(--accent);
}

.post-row h3 {
  font-size: clamp(26px, 2.65vw, 38px);
  letter-spacing: -.03em;
  line-height: 1.2;
  margin-top: 14px;
}

.post-row h3 a:hover {
  color: var(--accent);
}

.post-row p {
  font-size: 17px;
  color: var(--muted);
  margin-top: 12px;
  max-width: 60ch;
}

.post-row-end {
  display: flex;
  align-items: end;
  flex-direction: column;
  gap: 26px;
}

.read-time {
  font-size: 12px;
  letter-spacing: .08em;
  color: var(--muted);
}

.post-arrow {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  font-size: 28px;
  transition: background .2s, color .2s;
}

.post-arrow:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--on-accent);
}

.about-preview {
  display: grid;
  grid-template-columns: 1fr 2.1fr;
  gap: 40px;
  padding-block: 68px 100px;
}

.about-preview>.eyebrow {
  padding-top: 8px;
  color: var(--muted);
}

.about-preview h2 {
  font-size: clamp(34px, 3.6vw, 50px);
  line-height: 1.2;
}

.about-preview p:not(.eyebrow) {
  color: var(--muted);
  max-width: 56ch;
  font-size: 20px;
  margin: 26px 0;
}

.contact-section {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 35px;
  padding-block: 74px;
  border-top: 1px solid var(--line);
}

.contact-section .eyebrow {
  color: var(--muted);
  font-size: 12px;
}

.contact-section h2 {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(48px, 5.3vw, 76px);
  letter-spacing: .005em;
  margin-top: 18px;
}

.contact-section .button {
  flex-shrink: 0;
}

/* Inner pages */
.page-intro {
  padding-block: 44px 36px;
}

.page-intro .eyebrow {
  color: var(--muted);
}

.page-intro h1 {
  font-size: clamp(58px, 7vw, 100px);
  margin-top: 20px;
  line-height: 1.08;
}

.page-intro>p:not(.eyebrow) {
  color: var(--muted);
  font-size: 21px;
  max-width: 62ch;
  margin-top: 18px;
}

.back-link {
  display: inline-block;
  font-size: 16px;
  color: var(--muted);
}

.back-link:hover {
  color: var(--accent);
}

.blog-content {
  padding-bottom: 100px;
}

.blog-tools {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
  border-top: 1px solid var(--line);
  padding: 28px 0;
}

.filter-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.filter-pill {
  padding: 8px 14px;
  border: 1px solid var(--line);
  font-size: 14px;
  transition: color .2s, background .2s;
}

.filter-pill.active,
.filter-pill:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--on-accent);
}

.search-form {
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--muted);
  min-width: 230px;
  max-width: 320px;
}

.search-form input {
  background: transparent;
  color: var(--ink);
  border: 0;
  padding: 12px 0;
  width: 100%;
  min-width: 0;
  font-size: 16px;
  border-radius: 0;
}

.search-form button {
  background: transparent;
  color: var(--accent);
  font-size: 26px;
  padding: 5px 12px;
  border: 0;
}

.results-count {
  font-size: 14px;
  color: var(--muted);
  margin: 10px 0 25px;
}

.empty-state {
  padding: 45px 0;
}

.empty-state p {
  margin: 18px 0;
  color: var(--muted);
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 18px;
}

.tag {
  display: inline-block;
  padding: 5px 12px;
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
}

a.tag:hover {
  color: var(--ink);
  border-color: var(--accent);
}

.about-page {
  display: grid;
  grid-template-columns: 1fr 1.8fr;
  gap: 90px;
  margin-bottom: 100px;
  padding-top: 35px;
  border-top: 1px solid var(--line);
  align-items: start;
}

.identity-mark {
  height: 270px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  background: var(--panel);
  border: 1px solid var(--line);
  font-family: var(--display);
  font-size: 100px;
}

.identity-mark>span:first-child {
  color: var(--accent);
  letter-spacing: -.18em;
  margin-right: 12px;
}

.about-facts {
  margin: 28px 0 0;
}

.about-facts>div {
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
}

.about-facts dt {
  font-size: 11px;
  letter-spacing: .1em;
  color: var(--accent);
  margin-bottom: 6px;
}

.about-facts dd {
  margin: 0;
  font-size: 17px;
}

.contact-page {
  padding-bottom: 110px;
}

.contact-email-panel {
  padding: 40px 0 46px;
  border-block: 1px solid var(--line);
}

.contact-email-panel .eyebrow {
  color: var(--accent);
}

.email-link {
  display: inline-flex;
  align-items: center;
  gap: 35px;
  font-size: clamp(25px, 4.5vw, 64px);
  letter-spacing: -.04em;
  font-weight: 500;
  margin: 17px 0 8px;
  overflow-wrap: anywhere;
  max-width: 100%;
  line-height: 1.35;
}

.email-link strong {
  min-width: 0;
  font-weight: inherit;
  overflow-wrap: anywhere;
}

.email-link:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 6px;
}

.email-link:hover {
  color: var(--accent);
}

.email-link>span {
  color: var(--accent);
  flex-shrink: 0;
}

.contact-email-panel>p:last-child {
  font-size: 17px;
  color: var(--muted);
}

.contact-details {
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: 100px;
  padding-top: 55px;
  align-items: start;
}

.contact-socials>a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px 0;
  border-bottom: 1px solid var(--line);
  font-size: 27px;
}

.contact-socials>a:first-child {
  padding-top: 0;
}

.contact-socials small {
  display: block;
  font-size: 12px;
  letter-spacing: .1em;
  color: var(--muted);
  margin-bottom: 7px;
}

.contact-socials>a>span:last-child {
  color: var(--accent);
}

.contact-socials>a:hover {
  color: var(--accent);
}

/* Articles */
.article-page {
  padding-top: 45px;
  padding-bottom: 55px;
}

.article-header {
  max-width: 1000px;
  margin: 0 auto 45px;
}

.article-header>.back-link {
  margin-bottom: 45px;
}

.article-header h1 {
  font-family: var(--sans);
  font-size: clamp(40px, 5.2vw, 72px);
  font-weight: 600;
  line-height: 1.08;
  letter-spacing: -.045em;
  margin-top: 25px;
  text-wrap: balance;
}

.article-deck {
  font-size: 23px;
  line-height: 1.7;
  color: var(--muted);
  margin-top: 28px;
  max-width: 62ch;
}

.article-byline {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 16px;
  margin-top: 30px;
}

.avatar {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  background: var(--panel);
  border-left: 2px solid var(--accent);
  font-size: 25px;
}

.article-byline strong {
  font-weight: 500;
}

.article-byline div>span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  margin-top: 2px;
}

.article-cover {
  background: var(--panel);
  border: 1px solid var(--line);
}

.article-cover img {
  width: 100%;
  max-height: 440px;
  object-fit: cover;
}

.article-layout {
  display: grid;
  grid-template-columns: 170px minmax(0, 780px);
  justify-content: center;
  gap: 60px;
  margin: 65px auto;
}

.article-aside {
  color: var(--muted);
}

.article-aside .tag-list {
  flex-direction: column;
  align-items: start;
}

.aside-star {
  display: none;
}

.article-pagination {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-top: 1px solid var(--line);
  padding-top: 30px;
  gap: 45px;
  margin-top: 65px;
}

.article-pagination a>span {
  display: block;
  font-size: 12px;
  letter-spacing: .08em;
  color: var(--accent);
  margin-bottom: 14px;
}

.article-pagination strong {
  display: block;
  font-size: 26px;
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: -.025em;
  max-width: 32ch;
}

.article-pagination a:hover strong {
  color: var(--accent);
}

.prose {
  font-size: 20px;
  line-height: 1.85;
  min-width: 0;
  overflow-wrap: anywhere;
}

.prose p {
  margin: 0 0 1.5em;
  color: var(--prose);
}

.prose h2 {
  font-size: 36px;
  line-height: 1.2;
  margin: 1.8em 0 .8em;
  letter-spacing: -.03em;
}

.prose h2:first-child {
  margin-top: 0;
}

.prose h3 {
  font-size: 27px;
  line-height: 1.3;
  margin: 1.7em 0 .7em;
}

.prose h4,
.prose h5,
.prose h6 {
  font-size: 22px;
  line-height: 1.4;
  margin: 1.6em 0 .7em;
}

.prose strong {
  color: var(--ink);
  font-weight: 600;
}

.prose em {
  color: inherit;
  font-style: italic;
}

.prose a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 5px;
}

.prose ul,
.prose ol {
  margin: 0 0 1.5em;
  padding-left: 1.4em;
  color: var(--prose);
}

.prose li {
  padding-left: .2em;
  margin-bottom: .5em;
}

.prose blockquote {
  border-left: 3px solid var(--accent);
  margin: 35px 0;
  padding: 7px 0 7px 26px;
  font-size: 26px;
  line-height: 1.6;
}

.prose blockquote p:last-child {
  margin: 0;
  color: var(--ink);
}

.prose code {
  font-family: Consolas, 'Courier New', monospace;
  font-size: .85em;
  background: var(--inline-code);
  padding: 3px 7px;
  color: var(--ink);
}

.prose pre {
  overflow: auto;
  max-width: 100%;
  background: var(--code-bg);
  color: var(--code-ink);
  border: 1px solid var(--line);
  padding: 26px;
  font-size: 15px;
  line-height: 1.8;
  margin: 30px 0;
  tab-size: 4;
}

.prose pre code {
  background: none;
  padding: 0;
  color: inherit;
  font-size: inherit;
}

.prose img {
  margin: 30px 0;
  width: 100%;
  height: auto;
}

.prose hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 40px 0;
}

.table-scroll {
  overflow-x: auto;
  max-width: 100%;
  margin: 30px 0;
}

.prose table {
  border-collapse: collapse;
  width: 100%;
  font-size: 17px;
  text-align: left;
}

.prose th,
.prose td {
  padding: 14px 17px;
  border-bottom: 1px solid var(--line);
  min-width: 110px;
}

.prose th {
  background: var(--panel);
  font-weight: 600;
}

.prose input[type=checkbox] {
  accent-color: var(--accent);
  margin-right: 9px;
  width: 16px;
  height: 16px;
}

.prose .task-list-item {
  list-style: none;
}

.code-block {
  position: relative;
}

.code-block pre {
  padding-top: 56px;
}

.copy-code {
  position: absolute;
  right: 12px;
  top: 12px;
  border: 1px solid #53616f;
  background: var(--code-bg);
  color: var(--code-ink);
  padding: 5px 12px;
  font-size: 12px;
}

.highlight .c,
.highlight .c1,
.highlight .cm {
  color: #98a9b5;
  font-style: italic;
}

.highlight .k,
.highlight .kn,
.highlight .kd,
.highlight .ow {
  color: #ff8993;
}

.highlight .s,
.highlight .s1,
.highlight .s2,
.highlight .sa,
.highlight .sd {
  color: #e2cea0;
}

.highlight .nf,
.highlight .nc {
  color: #a5d2db;
}

.highlight .nb,
.highlight .mi,
.highlight .mf {
  color: #d2b1e9;
}

.highlight .o,
.highlight .p {
  color: #c5c8cb;
}

/* Footer and empty state */
.site-footer {
  border-top: 1px solid var(--line);
  display: grid;
  grid-template-columns: 1fr 1fr auto;
  align-items: center;
  gap: 30px;
  padding-top: 40px;
}

.site-footer>.wordmark {
  font-size: 21px;
}

.site-footer>p {
  font-size: 15px;
  color: var(--muted);
}

.social-links {
  display: flex;
  gap: 24px;
  font-size: 14px;
}

.social-links a:hover {
  color: var(--accent);
}

.footer-bottom {
  grid-column: 1/-1;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  font-size: 12px;
  color: var(--muted);
  padding: 23px 0 27px;
  border-top: 1px solid var(--line);
}

.not-found {
  text-align: center;
  padding-block: 60px 95px;
}

.error-art {
  display: block;
  font-family: var(--display);
  font-size: clamp(140px, 21vw, 280px);
  line-height: 1.25;
  color: var(--ink);
}

.error-art>span {
  color: var(--accent);
}

.not-found h1 {
  font-family: var(--sans);
  font-size: clamp(32px, 4vw, 52px);
  letter-spacing: -.04em;
}

.not-found p {
  color: var(--muted);
  margin: 25px auto;
  font-size: 18px;
}

.not-found>.text-link {
  display: table;
  margin: 28px auto 0;
}

/* Lightweight credentials and article navigation */
.credentials-section { padding-block: 56px; }
.credentials-section h2.eyebrow { font-family: var(--sans); font-size: 13px; letter-spacing: .12em; }
.achievement-list { list-style: none; padding: 0; margin: 24px 0 0; columns: 2; column-gap: 48px; }
.achievement-list li { display: grid; grid-template-columns: 54px minmax(0, 1fr); gap: 18px; padding-block: 12px; break-inside: avoid; }
.achievement-year { color: var(--muted); font-size: 16px; }
.achievement-list h3, .certification h3 { font-size: 19px; font-weight: 500; line-height: 1.5; }
.achievement-list p, .certification p { color: var(--muted); font-size: 15px; line-height: 1.6; margin-top: 6px; }
.credential-heading { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 28px; }
.carousel-controls:not([hidden]) { display: flex; gap: 8px; }
.carousel-controls button { width: 44px; height: 44px; background: transparent; color: var(--ink); border: 1px solid var(--line); }
.carousel-controls button:disabled { opacity: .35; cursor: default; }
.certification-track { display: flex; gap: 24px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: 4px; list-style: none; padding: 4px 4px 20px; margin: 0; overscroll-behavior-x: contain; }
.certification { flex: 0 0 calc((100% - 48px) / 3); min-width: 0; scroll-snap-align: start; display: flex; flex-direction: column; align-items: flex-start; }
.certification img { display: block; width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: contain; margin-bottom: 18px; }
.certification .text-link { font-size: 14px; margin-top: auto; padding-top: 16px; }
.article-layout { grid-template-columns: 220px minmax(0, 780px); gap: 40px; }
.article-aside { align-self: start; position: sticky; top: 30px; max-height: calc(100vh - 60px); overflow-y: auto; }
.table-of-contents { margin-bottom: 32px; font-size: 14px; line-height: 1.6; }
.table-of-contents summary { font-size: 15px; color: var(--ink); cursor: pointer; margin-bottom: 16px; }
.table-of-contents ul { list-style: none; padding: 0; }
.table-of-contents ul ul { padding-left: 14px; border-left: 1px solid var(--line); margin-left: 2px; }
.table-of-contents a { display: block; padding: 5px 3px; overflow-wrap: anywhere; }
.table-of-contents a:hover, .table-of-contents a[aria-current="location"] { color: var(--accent); }
.prose :is(h1, h2, h3, h4, h5, h6) { scroll-margin-top: 100px; }
summary:focus-visible, .certification-track:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
@media (max-width: 1100px) {
  .certification { flex-basis: calc((100% - 24px) / 2); }
}
@media (max-width: 720px) {
  .credentials-section { padding-block: 36px; }
  .achievement-list li { grid-template-columns: 48px minmax(0, 1fr); gap: 16px; }
  .certification { flex-basis: 90%; }
  .article-aside { position: static; max-height: none; overflow: visible; }
}

/* Responsive layouts */
@media (max-width: 1100px) {
  .wrap {
    width: calc(100% - 64px);
  }

  .hero {
    min-height: 0;
  }

  .hero-copy {
    width: 62%;
  }

  .hero h1 {
    font-size: clamp(42px, 5.4vw, 60px);
  }

  .hero-description {
    max-width: 62ch;
    font-size: 17px;
  }

  .hero-art {
    width: 62%;
  }

  .hero-actions {
    gap: 22px;
  }

  .hero-copy .eyebrow {
    font-size: 12px;
  }

  .discipline-strip {
    gap: 15px;
    font-size: 12px;
  }

  .about-page {
    gap: 45px;
  }

  .blog-tools {
    align-items: start;
    flex-direction: column;
    gap: 22px;
  }

  .search-form {
    width: 100%;
  }

  .article-layout {
    grid-template-columns: 125px minmax(0, 1fr);
    gap: 35px;
  }

  .contact-details {
    gap: 55px;
  }

  .site-footer {
    grid-template-columns: 1fr auto;
  }

  .site-footer>p {
    grid-row: 2;
  }

  .footer-bottom {
    grid-row: 3;
  }
}

@media (max-width: 720px) {
  body {
    font-size: 18px;
  }

  .wrap {
    width: calc(100% - 40px);
  }

  .site-header {
    height: auto;
    min-height: 88px;
    flex-wrap: wrap;
    gap: 0;
  }

  .wordmark {
    font-size: 21px;
    gap: 13px;
  }

  .brand-symbol {
    font-size: 29px;
  }

  .site-nav {
    width: 100%;
    gap: 0;
    justify-content: space-between;
    padding: 18px 0;
    border-top: 1px solid var(--line);
    font-size: 15px;
  }

  .site-nav .nav-contact {
    border: 0;
    padding: 9px 0;
    margin: 0;
    gap: 8px;
  }

  .site-nav .nav-contact[aria-current]::after {
    left: 0;
    bottom: 0;
  }

  .js .nav-toggle {
    display: flex;
    align-items: center;
    gap: 12px;
    border: 1px solid var(--line);
    padding: 10px 12px;
    background: transparent;
    color: var(--ink);
    font-size: 14px;
  }

  .menu-icon {
    width: 14px;
    height: 8px;
    border-top: 1px solid;
    border-bottom: 1px solid;
  }

  .js .site-nav {
    display: none;
  }

  .js .site-nav.is-open {
    display: flex;
  }

  .hero {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    min-height: 0;
  }

  .hero-copy {
    width: 100%;
    padding: 30px 0 0;
  }

  .hero-copy .eyebrow {
    font-size: 12px;
    letter-spacing: .09em;
    margin-bottom: 18px;
  }

  .hero h1 {
    font-size: clamp(38px, 8.8vw, 56px);
    line-height: 1.09;
  }

  .hero-description {
    font-size: 18px;
    line-height: 1.75;
    margin-top: 24px;
  }

  .hero-description br {
    display: none;
  }

  .hero-actions {
    gap: 18px 25px;
    margin-top: 25px;
  }

  .hero-actions .button {
    font-size: 12px;
    gap: 22px;
    padding: 14px 18px;
    min-height: 54px;
  }

  .hero-actions .text-link {
    font-size: 14px;
    gap: 14px;
  }

  .hero-caption {
    display: none;
  }

  .hero-art {
    position: relative;
    width: calc(100% + 40px);
    margin-left: -20px;
    height: 410px;
    right: auto;
    margin-top: 10px;
  }

  .hero-art img {
    object-position: center 37%;
    mask-image: linear-gradient(to right, transparent, black 12%, black 88%, transparent);
  }

  .hero-art::after {
    background: linear-gradient(0deg, var(--paper), transparent 27%, transparent 73%, var(--paper));
  }

  .art-index {
    right: 25px;
    bottom: 36px;
    font-size: 12px;
  }

  .discipline-strip {
    justify-content: center;
    gap: 13px;
    font-size: 12px;
    letter-spacing: .05em;
    padding-block: 22px;
    flex-wrap: wrap;
  }

  .discipline-strip>a {
    display: none;
  }

  .journal-section {
    padding-block: 60px;
  }

  .section-heading {
    gap: 22px;
    flex-wrap: wrap;
    margin-bottom: 30px;
  }

  .section-heading .eyebrow {
    font-size: 12px;
    margin-bottom: 15px;
  }

  h2 {
    font-size: 36px;
  }

  .section-heading>.text-link {
    font-size: 14px;
  }

  .post-row {
    grid-template-columns: minmax(0, 1fr) 42px;
    gap: 15px;
    padding-block: 27px;
  }

  .post-number {
    display: none;
  }

  .post-meta {
    font-size: 11px;
    gap: 10px;
  }

  .post-row h3 {
    font-size: 27px;
    margin-top: 12px;
  }

  .post-row p {
    font-size: 16px;
    margin-top: 13px;
  }

  .post-row-end {
    align-self: center;
  }

  .post-arrow {
    width: 42px;
    height: 42px;
    font-size: 25px;
  }

  .read-time {
    display: none;
  }

  .about-preview {
    grid-template-columns: 1fr;
    gap: 25px;
    padding-block: 28px 65px;
  }

  .about-preview h2 {
    font-size: 34px;
  }

  .about-preview p:not(.eyebrow) {
    font-size: 18px;
    margin-block: 22px;
  }

  .about-preview>.eyebrow {
    font-size: 12px;
  }

  .contact-section {
    flex-direction: column;
    align-items: start;
    padding-block: 50px;
    gap: 25px;
  }

  .contact-section .eyebrow {
    font-size: 12px;
  }

  .contact-section h2 {
    font-size: clamp(43px, 9.5vw, 66px);
  }

  .site-footer {
    gap: 20px;
    padding-top: 32px;
    grid-template-columns: 1fr;
  }

  .site-footer>p {
    grid-row: auto;
    font-size: 14px;
  }

  .social-links {
    gap: 28px;
    font-size: 14px;
  }

  .footer-bottom {
    grid-row: auto;
    font-size: 11px;
  }

  .page-intro {
    padding-block: 30px 28px;
  }

  .page-intro .eyebrow {
    font-size: 12px;
  }

  .page-intro h1 {
    font-size: clamp(45px, 8.8vw, 64px);
    margin-top: 18px;
  }

  .page-intro>p:not(.eyebrow) {
    font-size: 19px;
    margin-top: 16px;
  }

  .page-intro>p br {
    display: none;
  }

  .blog-content {
    padding-bottom: 60px;
  }

  .filter-pill {
    font-size: 13px;
    padding: 7px 12px;
  }

  .results-count {
    font-size: 13px;
  }

  .about-page {
    grid-template-columns: 1fr;
    gap: 42px;
    margin-bottom: 60px;
  }

  .identity-mark {
    height: 220px;
    font-size: 96px;
  }

  .about-facts dd {
    font-size: 16px;
  }

  .contact-page {
    padding-bottom: 65px;
  }

  .contact-email-panel {
    padding-block: 28px;
  }

  .email-link {
    gap: 15px;
    font-size: clamp(23px, 6vw, 36px);
  }

  .contact-email-panel .eyebrow {
    font-size: 12px;
  }

  .contact-email-panel>p:last-child {
    font-size: 16px;
  }

  .contact-details {
    grid-template-columns: 1fr;
    gap: 30px;
    padding-top: 40px;
  }

  .article-page {
    padding-top: 28px;
    padding-bottom: 30px;
  }

  .article-header>.back-link {
    margin-bottom: 30px;
  }

  .article-header h1 {
    font-size: 42px;
    margin-top: 20px;
  }

  .article-deck {
    font-size: 20px;
  }

  .article-byline {
    font-size: 15px;
  }

  .article-byline div>span {
    font-size: 12px;
  }

  .article-layout {
    grid-template-columns: 1fr;
    gap: 30px;
    margin-block: 35px;
  }

  .article-aside .tag-list {
    flex-direction: row;
    margin-top: 12px;
  }

  .article-aside .eyebrow {
    font-size: 12px;
  }

  .prose {
    font-size: 18px;
    line-height: 1.85;
  }

  .prose h2 {
    font-size: 30px;
  }

  .prose h3 {
    font-size: 25px;
  }

  .prose blockquote {
    font-size: 23px;
    padding-left: 20px;
  }

  .prose pre {
    font-size: 14px;
    padding-inline: 18px;
  }

  .prose table {
    font-size: 16px;
  }

  .article-pagination {
    gap: 24px;
    margin-top: 40px;
    grid-template-columns: 1fr;
  }

  .article-pagination strong {
    font-size: 23px;
  }

  .article-pagination a>span {
    font-size: 11px;
  }

  .not-found {
    padding-block: 40px 65px;
  }

  .not-found p {
    font-size: 17px;
  }
}

@media (max-width: 380px) {
  .wordmark {
    font-size: 18px;
    gap: 10px;
  }

  .brand-symbol {
    font-size: 25px;
  }

  .nav-toggle {
    font-size: 13px;
  }

  .hero h1 {
    font-size: 38px;
  }

  .hero-copy .eyebrow {
    font-size: 12px;
  }

  .hero-actions {
    flex-direction: column;
    align-items: start;
  }

  .hero-art {
    height: 340px;
  }

  .page-intro h1 {
    font-size: 39px;
  }

  .contact-section h2 {
    font-size: 40px;
  }

  .post-row {
    grid-template-columns: minmax(0, 1fr);
  }

  .post-row-end {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}

@media print {
  body {
    background: white;
    color: black;
  }

  .site-header,
  .site-footer,
  .contact-section,
  .article-aside,
  .article-pagination,
  .copy-code,
  .back-link {
    display: none;
  }

  .wrap {
    width: 100%;
  }

  .article-layout {
    display: block;
  }

  .article-header h1 {
    font-size: 36px;
  }

  .prose,
  .prose p,
  .prose li,
  .prose strong {
    color: black;
    font-size: 11pt;
  }

  .prose pre {
    white-space: pre-wrap;
    background: #eee;
    color: black;
  }

  .article-cover {
    max-height: 200px;
    overflow: hidden;
  }
}

/* Keep theme controls and light artwork comfortable on smaller screens. */
@media (max-width: 1100px) {
  .site-nav { gap: 20px; }
  .site-nav .nav-contact { margin-left: 0; gap: 12px; }
}
@media (max-width: 720px) {
  .header-controls { gap: 8px; }
  .site-nav { order: 2; }
  .filter-pill, .tag { min-height: 44px; display: inline-flex; align-items: center; }
  .search-form { max-width: none; }
  .search-form button { min-width: 44px; min-height: 44px; display: grid; place-items: center; }
  .post-meta { font-size: 12px; }
  .hero-copy .eyebrow { font-size: 12px; }
}
@media (max-width: 380px) {
  .theme-toggle:not([hidden]) { padding-inline: 8px; gap: 5px; }
  .wordmark { font-size: 16px; gap: 8px; }
  .brand-symbol { font-size: 22px; }
}

/* Shared geometry in both themes; depth comes from perspective and shadows. */
.hero-personal {
  width: 38%;
  right: 0;
  top: 32px;
  bottom: 32px;
  display: grid;
  place-items: center;
  perspective: 1000px;
}
.hero-personal::after {
  inset: 12% 4%;
  border-radius: 50%;
  background: radial-gradient(ellipse, color-mix(in srgb, var(--accent) 14%, transparent), transparent 70%);
  transform: translateZ(-30px);
  z-index: -1;
}
.hero-personal img {
  display: block;
  width: 88%;
  max-width: 320px;
  height: auto;
  max-height: 100%;
  object-fit: contain;
  mask-image: none;
  opacity: 1;
  border-radius: 0;
  transform: translateZ(24px) rotateY(-7deg) rotateX(3deg);
  filter: drop-shadow(12px 20px 16px #0003);
}
.hero-personal .art-index { right: 0; bottom: 8px; }
@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  .hero-personal img { transition: transform 350ms ease; }
  .hero-personal:hover img { transform: translateZ(32px) rotateY(-3deg) rotateX(1deg); }
}
@media (max-width: 720px) {
  .hero-personal {
    width: 100%;
    height: auto;
    top: auto;
    bottom: auto;
    margin: 18px 0 24px;
    padding: 8px 28px 20px;
  }
  .hero-personal img { width: 100%; max-width: 230px; }
  .hero-personal .art-index { right: 4px; }
  .achievement-list li { grid-template-columns: 1fr; gap: 4px; }
  .achievement-list { columns: 1; }
}

/* Allow content to shrink inside its existing grid and flex layouts. */
.about-page > *, .contact-details > *, .article-layout > *,
.post-row > *, .article-pagination > *, .site-footer > * {
  min-width: 0;
}
.prose img { height: auto; }
.tag, .filter-pill, .certification h3, .about-facts dd {
  overflow-wrap: anywhere;
}
@media (min-width: 721px) and (max-width: 820px) {
  .site-header { gap: 12px; }
  .site-header .wordmark { flex-shrink: 0; }
  .site-nav { gap: 14px; }
}
@media (max-width: 720px) {
  .search-form { min-width: 0; }
  .article-byline > div { min-width: 0; }
  .avatar { flex-shrink: 0; }
  .social-links { flex-wrap: wrap; }
}
