/* ============================================================
   Anita Manion — Professional Website
   Design tokens: warm paper ground, garnet/brass accent pair
   Fraunces (display serif) + Public Sans (body/civic grotesk)
   ============================================================ */

:root {
  --paper: #f3efe3;
  --paper-raised: #fbf9f2;
  --ink: #1c1e26;
  --ink-soft: #4d5061;
  --ink-faint: #7b7e8c;
  --rule: #ded4b8;
  --garnet: #7c1f2d;
  --garnet-soft: #9a3a47;
  --brass: #8f6a1f;
  --brass-bright: #a9822e;
  --focus: #2f5fa8;
  --shadow: 0 1px 2px rgba(28, 30, 38, 0.06), 0 8px 24px rgba(28, 30, 38, 0.08);

  --font-display: "Fraunces", "Iowan Old Style", "Palatino Linotype", serif;
  --font-body: "Public Sans", "Segoe UI", system-ui, sans-serif;

  --measure: 66ch;
  --container: 1120px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #14151b;
    --paper-raised: #1b1d25;
    --ink: #ece8dc;
    --ink-soft: #b7b9c6;
    --ink-faint: #8a8d9c;
    --rule: #33313f;
    --garnet: #e0808d;
    --garnet-soft: #c65b6a;
    --brass: #d9b45f;
    --brass-bright: #e6c876;
    --focus: #7aa6e8;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 12px 32px rgba(0, 0, 0, 0.35);
  }
}

:root[data-theme="dark"] {
  --paper: #14151b;
  --paper-raised: #1b1d25;
  --ink: #ece8dc;
  --ink-soft: #b7b9c6;
  --ink-faint: #8a8d9c;
  --rule: #33313f;
  --garnet: #e0808d;
  --garnet-soft: #c65b6a;
  --brass: #d9b45f;
  --brass-bright: #e6c876;
  --focus: #7aa6e8;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 12px 32px rgba(0, 0, 0, 0.35);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  * {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

::selection {
  background: var(--garnet);
  color: var(--paper-raised);
}

a {
  color: var(--garnet);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--garnet-soft);
}

a:focus-visible,
button:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 3px;
  border-radius: 2px;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--ink);
  text-wrap: balance;
  margin: 0;
}

p {
  margin: 0;
}

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 28px;
}

/* ---------- Skip link ---------- */

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--ink);
  color: var(--paper);
  padding: 10px 18px;
  z-index: 100;
}

.skip-link:focus {
  left: 16px;
  top: 16px;
}

/* ---------- Nav ---------- */

.site-nav {
  position: sticky;
  top: 0;
  z-index: 40;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--rule);
}

.site-nav .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 62px;
  gap: 24px;
}

.site-nav .wordmark {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.05rem;
  letter-spacing: 0.01em;
  color: var(--ink);
  text-decoration: none;
  white-space: nowrap;
}

.site-nav .wordmark:hover {
  color: var(--ink);
}

.nav-links {
  display: flex;
  gap: 28px;
  list-style: none;
  margin: 0;
  padding: 0;
  overflow-x: auto;
}

.nav-links a {
  color: var(--ink-soft);
  text-decoration: none;
  font-size: 0.86rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
}

.nav-links a:hover {
  color: var(--garnet);
}

/* ---------- Hero ---------- */

.hero {
  padding: 68px 0 56px;
  border-bottom: 1px solid var(--rule);
}

.hero-row {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 56px;
  align-items: start;
}

.hero-copy {
  padding-top: 8px;
}

.hero-portrait {
  position: relative;
}

.hero-portrait img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 3px;
  box-shadow: var(--shadow);
}

.hero-eyebrow {
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--brass-bright);
  margin-bottom: 14px;
  display: block;
}

.hero h1 {
  font-size: clamp(2.4rem, 4.2vw, 3.4rem);
  line-height: 1.05;
  margin-bottom: 12px;
}

.hero-role {
  font-size: 1.15rem;
  color: var(--ink-soft);
  max-width: 46ch;
  margin-bottom: 22px;
}

.hero-role strong {
  color: var(--ink);
  font-weight: 600;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 34px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 20px;
  border-radius: 3px;
  font-size: 0.92rem;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  font-family: var(--font-body);
}

.btn-primary {
  background: var(--garnet);
  color: #fbf6ef;
}

.btn-primary:hover {
  background: var(--garnet-soft);
  color: #fbf6ef;
}

.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--rule);
}

.btn-ghost:hover {
  border-color: var(--ink-faint);
  color: var(--ink);
}

/* ---------- Stat strip ---------- */

.stat-strip {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 0;
  border-top: 1px solid var(--rule);
}

.stat {
  padding: 18px 20px 0 0;
  border-left: 1px solid var(--rule);
  padding-left: 20px;
}

.stat:first-child {
  border-left: none;
  padding-left: 0;
}

.stat-value {
  font-family: var(--font-display);
  font-size: 1.7rem;
  font-weight: 600;
  color: var(--garnet);
  font-variant-numeric: tabular-nums;
  line-height: 1.1;
}

.stat-label {
  font-size: 0.78rem;
  color: var(--ink-faint);
  letter-spacing: 0.02em;
  margin-top: 4px;
  line-height: 1.35;
}

/* ---------- Sections ---------- */

section {
  padding: 64px 0;
  border-bottom: 1px solid var(--rule);
}

section:last-of-type {
  border-bottom: none;
}

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 32px;
  flex-wrap: wrap;
}

.section-number {
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--brass-bright);
  letter-spacing: 0.08em;
}

.section-head h2 {
  font-size: 1.9rem;
  margin-top: 4px;
}

.section-intro {
  max-width: var(--measure);
  color: var(--ink-soft);
  margin-bottom: 36px;
  font-size: 1.02rem;
}

/* ---------- About ---------- */

.about-grid {
  display: grid;
  grid-template-columns: 1fr;
}

.about-grid .lede {
  font-family: var(--font-display);
  font-size: 1.3rem;
  line-height: 1.5;
  color: var(--ink);
  margin-bottom: 20px;
  max-width: var(--measure);
}

.about-grid p + p {
  margin-top: 16px;
}

.about-grid .prose {
  max-width: var(--measure);
  color: var(--ink-soft);
}

/* ---------- Research ---------- */

.research-tracks {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-bottom: 44px;
}

.track-card {
  background: var(--paper-raised);
  border: 1px solid var(--rule);
  border-radius: 4px;
  padding: 20px 22px;
}

.track-card h3 {
  font-size: 1.02rem;
  margin-bottom: 8px;
}

.track-card p {
  color: var(--ink-soft);
  font-size: 0.92rem;
}

.pub-block h3 {
  font-size: 1.15rem;
  margin-bottom: 4px;
  padding-top: 28px;
  border-top: 1px solid var(--rule);
}

.pub-block:first-of-type h3 {
  padding-top: 0;
  border-top: none;
}

.pub-count {
  font-size: 0.82rem;
  color: var(--ink-faint);
  margin-bottom: 16px;
  display: block;
}

.pub-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.pub-list li {
  padding: 12px 0;
  border-top: 1px solid var(--rule);
  font-size: 0.96rem;
  color: var(--ink-soft);
}

.pub-list li:first-child {
  border-top: none;
}

.pub-list .pub-title {
  color: var(--ink);
  font-weight: 600;
}

.pub-list .pub-venue {
  font-style: italic;
}

.pub-list a {
  font-weight: 600;
}

details.pub-more {
  margin-top: 4px;
}

details.pub-more summary {
  cursor: pointer;
  list-style: none;
  color: var(--garnet);
  font-weight: 600;
  font-size: 0.9rem;
  padding: 14px 0 6px;
  display: flex;
  align-items: center;
  gap: 8px;
}

details.pub-more summary::-webkit-details-marker {
  display: none;
}

details.pub-more summary::after {
  content: "Show more \2193";
}

details.pub-more[open] summary::after {
  content: "Show less \2191";
}

/* ---------- Media ---------- */

.media-highlight {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 40px;
  align-items: start;
}

.media-card {
  background: var(--ink);
  color: var(--paper-raised);
  border-radius: 4px;
  padding: 26px 28px;
}

.media-card .stat-value {
  color: var(--brass-bright);
  font-size: 2.2rem;
}

.media-card .stat-label {
  color: color-mix(in srgb, var(--paper-raised) 70%, transparent);
}

.media-card p {
  margin-top: 12px;
  font-size: 0.94rem;
  color: color-mix(in srgb, var(--paper-raised) 85%, transparent);
}

.outlet-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 18px;
}

.outlet-chip {
  border: 1px solid var(--rule);
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 0.85rem;
  color: var(--ink-soft);
  background: var(--paper-raised);
}

.appearance-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.appearance-list li {
  padding: 13px 0;
  border-top: 1px solid var(--rule);
  font-size: 0.95rem;
  color: var(--ink-soft);
  display: grid;
  grid-template-columns: 90px 1fr;
  gap: 14px;
}

.appearance-list li:first-child {
  border-top: none;
}

.appearance-list time {
  color: var(--ink-faint);
  font-size: 0.82rem;
  letter-spacing: 0.03em;
}

.appearance-list .pub-title {
  color: var(--ink);
}

.clip-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.clip-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  background: var(--paper-raised);
  border: 1px solid var(--rule);
  border-radius: 4px;
  text-decoration: none;
  color: var(--ink);
}

.clip-card:hover {
  border-color: var(--garnet);
}

.clip-icon {
  flex: none;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--garnet);
  display: flex;
  align-items: center;
  justify-content: center;
}

.clip-icon::after {
  content: "";
  display: block;
  margin-left: 3px;
  border-style: solid;
  border-width: 7px 0 7px 12px;
  border-color: transparent transparent transparent #fbf6ef;
}

.clip-title {
  display: block;
  font-weight: 600;
  font-size: 0.92rem;
  line-height: 1.35;
}

.clip-meta {
  display: block;
  font-size: 0.78rem;
  color: var(--ink-faint);
  margin-top: 4px;
}

/* ---------- Recognition (awards) ---------- */

.award-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px 40px;
}

.award-item {
  display: grid;
  grid-template-columns: 62px 1fr;
  gap: 16px;
  padding: 14px 0;
  border-top: 1px solid var(--rule);
}

.award-item:nth-child(1),
.award-item:nth-child(2) {
  border-top: none;
}

.award-year {
  font-family: var(--font-display);
  color: var(--brass-bright);
  font-weight: 600;
  font-size: 0.95rem;
}

.award-name {
  color: var(--ink);
  font-weight: 600;
  font-size: 0.96rem;
}

.award-org {
  color: var(--ink-faint);
  font-size: 0.85rem;
  margin-top: 2px;
}

/* ---------- Teaching & Service ---------- */

.ts-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
}

.ts-grid h3 {
  font-size: 1.1rem;
  margin-bottom: 14px;
}

.course-list,
.service-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.course-list li {
  padding: 10px 0;
  border-top: 1px solid var(--rule);
  font-size: 0.94rem;
  color: var(--ink-soft);
}

.course-list li:first-child {
  border-top: none;
}

.service-list li {
  padding: 8px 0 8px 18px;
  position: relative;
  font-size: 0.92rem;
  color: var(--ink-soft);
}

.service-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 16px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--brass-bright);
}

/* ---------- Contact / footer ---------- */

.contact-section {
  padding: 60px 0 40px;
}

.contact-panel {
  background: var(--ink);
  color: var(--paper-raised);
  border-radius: 6px;
  padding: 48px 52px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 32px;
  flex-wrap: wrap;
}

.contact-panel h2 {
  color: var(--paper-raised);
  font-size: 1.8rem;
  margin-bottom: 10px;
}

.contact-panel p {
  color: color-mix(in srgb, var(--paper-raised) 78%, transparent);
  max-width: 44ch;
}

.contact-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.contact-panel .btn-primary {
  background: var(--brass-bright);
  color: var(--ink);
}

.contact-panel .btn-primary:hover {
  background: var(--brass);
}

.contact-panel .btn-ghost {
  border-color: color-mix(in srgb, var(--paper-raised) 35%, transparent);
  color: var(--paper-raised);
}

.contact-panel .btn-ghost:hover {
  border-color: var(--paper-raised);
}

.site-footer {
  padding: 28px 0 48px;
  text-align: center;
  font-size: 0.82rem;
  color: var(--ink-faint);
}

/* ---------- Responsive ---------- */

@media (max-width: 880px) {
  .hero-row {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .hero-portrait {
    max-width: 240px;
  }

  .stat-strip {
    grid-template-columns: repeat(2, 1fr);
    gap: 18px 0;
  }

  .stat {
    border-left: none !important;
    padding-left: 0 !important;
  }

  .ts-grid,
  .media-highlight {
    grid-template-columns: 1fr;
  }

  .research-tracks {
    grid-template-columns: 1fr;
  }

  .clip-grid {
    grid-template-columns: 1fr;
  }

  .award-grid {
    grid-template-columns: 1fr;
  }

  .award-item:nth-child(2) {
    border-top: 1px solid var(--rule);
  }

  .nav-links {
    gap: 18px;
  }

  .contact-panel {
    padding: 36px 28px;
  }
}
