/* ===================================================
   Aafaq Sabir — Personal Academic Website
   Inspired by dwermke.com
   =================================================== */

/* ---------- Google Font ---------- */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

/* ---------- CSS Custom Properties ---------- */
:root {
  /* Light theme (default) */
  --bg-primary: #ffffff;
  --bg-secondary: #f7f8fa;
  --bg-nav: rgba(255, 255, 255, 0.92);
  --bg-table-even: #f3f4f6;
  --bg-table-odd: transparent;
  --bg-card: #ffffff;
  --bg-badge: #cc0000;
  --bg-btn: #f3f4f6;
  --bg-btn-hover: #e5e7eb;
  --bg-callout: #eff6ff;
  --border-callout: #3b82f6;

  --text-primary: #1a1a2e;
  --text-secondary: #4a4a6a;
  --text-muted: #6b7280;
  --text-link: #2563eb;
  --text-link-hover: #1d4ed8;
  --text-nav: #374151;
  --text-nav-active: #2563eb;
  --text-badge: #ffffff;
  --text-label: #1e40af;

  --border-color: #e5e7eb;
  --border-section: #d1d5db;
  --shadow-nav: 0 1px 3px rgba(0, 0, 0, 0.06);
  --shadow-card: 0 1px 3px rgba(0, 0, 0, 0.04);

  --transition-speed: 0.25s;
}

[data-theme="dark"] {
  --bg-primary: #0f1117;
  --bg-secondary: #161822;
  --bg-nav: rgba(15, 17, 23, 0.92);
  --bg-table-even: #1a1d2e;
  --bg-table-odd: transparent;
  --bg-card: #161822;
  --bg-badge: #cc0000;
  --bg-btn: #1e2235;
  --bg-btn-hover: #2a2f48;
  --bg-callout: #141829;
  --border-callout: #3b82f6;

  --text-primary: #e4e4f0;
  --text-secondary: #a0a0c0;
  --text-muted: #6b7294;
  --text-link: #60a5fa;
  --text-link-hover: #93c5fd;
  --text-nav: #c0c0d8;
  --text-nav-active: #60a5fa;
  --text-badge: #ffffff;
  --text-label: #93c5fd;

  --border-color: #2a2d40;
  --border-section: #2a2d40;
  --shadow-nav: 0 1px 3px rgba(0, 0, 0, 0.3);
  --shadow-card: 0 1px 3px rgba(0, 0, 0, 0.2);
}

/* ---------- Reset & Base ---------- */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-primary);
  background-color: var(--bg-primary);
  transition: background-color var(--transition-speed), color var(--transition-speed);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: var(--text-link);
  text-decoration: none;
  transition: color var(--transition-speed);
}

a:hover {
  color: var(--text-link-hover);
  text-decoration: underline;
}

/* ---------- Navigation ---------- */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg-nav);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  box-shadow: var(--shadow-nav);
  transition: background var(--transition-speed), border-color var(--transition-speed), box-shadow var(--transition-speed);
}

.nav-inner {
  max-width: 780px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 52px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
  list-style: none;
}

.nav-links a {
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--text-nav);
  text-decoration: none;
  padding: 6px 12px;
  border-radius: 6px;
  border-bottom: 2px solid transparent;
  transition: color var(--transition-speed), border-color var(--transition-speed);
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text-nav-active);
  text-decoration: none;
}

.nav-links a.active {
  border-bottom-color: var(--text-nav-active);
}

.theme-toggle {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 1.25rem;
  color: var(--text-muted);
  padding: 6px;
  border-radius: 6px;
  transition: color var(--transition-speed), background var(--transition-speed);
  display: flex;
  align-items: center;
  justify-content: center;
}

.theme-toggle:hover {
  color: var(--text-primary);
  background: var(--bg-btn);
}

/* ---------- Main Container ---------- */
.container {
  max-width: 780px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Hero / Header ---------- */
.hero {
  padding: 48px 0 12px;
}

.hero-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}

.hero-text {
  flex: 1;
  min-width: 0;
}

.hero-photo {
  width: 156px;
  height: 156px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--border-color);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
  flex-shrink: 0;
  transition: border-color var(--transition-speed), box-shadow var(--transition-speed);
}

.hero-photo:hover {
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.15);
}

.hero-name {
  font-size: 2.8rem;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin-bottom: 4px;
}

.hero-name .first-name {
  font-weight: 800;
}

.hero-name .last-name {
  font-weight: 300;
  color: var(--text-secondary);
}

.hero-subtitle {
  font-size: 1.15rem;
  font-weight: 400;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 0;
}

.badge {
  display: inline-flex;
  align-items: center;
  background: var(--bg-badge);
  color: var(--text-badge);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 4px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none;
  transition: opacity var(--transition-speed);
}

.badge:hover {
  opacity: 0.9;
  color: var(--text-badge);
  text-decoration: none;
}

/* ---------- Info Table ---------- */
.info-table {
  width: 100%;
  border-collapse: collapse;
  margin: 24px 0 28px;
  font-size: 0.93rem;
}

.info-table tr:nth-child(even) {
  background: var(--bg-table-even);
}

.info-table td {
  padding: 9px 16px;
  vertical-align: middle;
}

.info-table td:first-child {
  color: var(--text-muted);
  font-style: italic;
  width: 120px;
  white-space: nowrap;
}

.info-table td:last-child {
  color: var(--text-primary);
}

.info-table a {
  text-decoration: none;
}

.info-table a:hover {
  text-decoration: underline;
}

.info-icon {
  width: 16px;
  height: 16px;
  vertical-align: middle;
  margin-right: 5px;
  display: inline-block;
}

.separator {
  margin: 0 6px;
  color: var(--text-muted);
}

/* ---------- About / Bio ---------- */
.bio {
  margin: 8px 0 16px;
  font-size: 0.97rem;
  line-height: 1.75;
  color: var(--text-primary);
}

/* ---------- News ---------- */
.news-list {
  list-style: none;
}

.news-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 14px 16px;
  border-left: 3px solid var(--border-callout);
  background: var(--bg-callout);
  border-radius: 0 8px 8px 0;
  margin-bottom: 12px;
  transition: background var(--transition-speed);
}

.news-icon {
  font-size: 1.25rem;
  flex-shrink: 0;
  line-height: 1.5;
}

.news-body {
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 0.94rem;
  line-height: 1.6;
}

.news-date {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.news-text {
  color: var(--text-primary);
}

/* ---------- Section Headers ---------- */
.section {
  padding: 40px 0 0;
}

.section-title {
  font-size: 1.65rem;
  font-weight: 700;
  margin-bottom: 4px;
  color: var(--text-primary);
  letter-spacing: -0.01em;
}

.section-title .anchor {
  color: var(--text-muted);
  font-weight: 400;
  text-decoration: none;
  margin-left: 8px;
  opacity: 0;
  transition: opacity var(--transition-speed);
  font-size: 0.85em;
}

.section-title:hover .anchor {
  opacity: 1;
}

.section-divider {
  border: none;
  border-top: 2px dashed var(--border-section);
  margin: 6px 0 28px;
  opacity: 0.45;
}

/* ---------- Research Interests ---------- */
.research-intro {
  font-size: 0.97rem;
  line-height: 1.75;
  color: var(--text-primary);
  margin-bottom: 20px;
}

.interest-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 8px;
}

.interest-table td {
  padding: 10px 16px;
  vertical-align: top;
  font-size: 0.94rem;
  line-height: 1.7;
}

.interest-table td:first-child {
  color: var(--text-muted);
  font-style: italic;
  width: 120px;
  white-space: nowrap;
}

.interest-table tr:nth-child(even) {
  background: var(--bg-table-even);
}

/* ---------- Publications ---------- */
.pub-intro {
  font-size: 0.95rem;
  color: var(--text-secondary);
  margin-bottom: 24px;
}

.pub-year {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-primary);
  margin: 32px 0 16px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border-color);
}

.pub-year:first-of-type {
  margin-top: 8px;
}

.pub-entry {
  display: flex;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--border-color);
}

.pub-entry:last-child {
  border-bottom: none;
}

.pub-label {
  flex-shrink: 0;
  width: 42px;
  text-align: right;
}

.pub-label span {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-label);
  background: var(--bg-btn);
  padding: 3px 7px;
  border-radius: 4px;
  white-space: nowrap;
}

.pub-content {
  flex: 1;
  min-width: 0;
}

.pub-title {
  font-size: 0.97rem;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.45;
  margin-bottom: 5px;
}

.pub-title a {
  color: var(--text-primary);
  text-decoration: none;
}

.pub-title a:hover {
  text-decoration: underline;
}

.pub-authors {
  font-size: 0.88rem;
  color: var(--text-secondary);
  margin-bottom: 4px;
  line-height: 1.55;
}

.pub-authors .me {
  font-weight: 600;
  color: var(--text-primary);
}

.pub-authors a {
  color: var(--text-secondary);
}

.pub-authors a:hover {
  color: var(--text-link);
}

.pub-venue {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 8px;
  line-height: 1.5;
}

.pub-venue .venue-name {
  font-weight: 600;
  color: var(--text-secondary);
}

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

.pub-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.pub-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-secondary);
  background: var(--bg-btn);
  border: 1px solid var(--border-color);
  padding: 4px 10px;
  border-radius: 5px;
  text-decoration: none;
  transition: background var(--transition-speed), color var(--transition-speed), border-color var(--transition-speed);
}

.pub-btn:hover {
  background: var(--bg-btn-hover);
  color: var(--text-primary);
  text-decoration: none;
}

.pub-btn svg {
  width: 13px;
  height: 13px;
  flex-shrink: 0;
}

/* ---------- Experience ---------- */
.exp-list {
  list-style: none;
}

.exp-item {
  padding: 18px 0;
  border-bottom: 1px solid var(--border-color);
}

.exp-item:last-child {
  border-bottom: none;
}

.exp-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 4px;
}

.exp-org {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
}

.exp-date {
  font-size: 0.84rem;
  color: var(--text-muted);
  white-space: nowrap;
}

.exp-role {
  font-size: 0.93rem;
  color: var(--text-secondary);
}

.exp-detail {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-top: 2px;
}

/* ---------- CV Download Button ---------- */
.cv-download {
  margin: 12px 0 4px;
}

.cv-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 20px;
  border-radius: 8px;
  background: var(--text-link);
  color: #fff;
  font-size: 0.88rem;
  font-weight: 600;
  text-decoration: none;
  transition: opacity var(--transition-speed), transform var(--transition-speed);
}

.cv-btn:hover {
  opacity: 0.88;
  transform: translateY(-1px);
}

.cv-btn svg {
  flex-shrink: 0;
}

/* ---------- Education ---------- */
.edu-card {
  padding: 18px 0;
  border-bottom: 1px solid var(--border-color);
}

.edu-card:last-child {
  border-bottom: none;
}

.edu-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 4px;
}

.edu-degree {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
}

.edu-date {
  font-size: 0.84rem;
  color: var(--text-muted);
  white-space: nowrap;
}

.edu-institution {
  font-size: 0.94rem;
  color: var(--text-secondary);
}

.edu-institution a {
  color: var(--text-link);
  text-decoration: none;
}

.edu-institution a:hover {
  text-decoration: underline;
}

.edu-meta {
  display: flex;
  gap: 16px;
  margin-top: 6px;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.edu-gpa {
  font-weight: 500;
}

.edu-details {
  margin-top: 6px;
  padding-left: 18px;
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ---------- Posters ---------- */
.poster-list {
  list-style: none;
}

.poster-item {
  padding: 14px 0;
  border-bottom: 1px solid var(--border-color);
}

.poster-item:last-child {
  border-bottom: none;
}

.poster-title {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.poster-authors {
  font-size: 0.88rem;
  color: var(--text-secondary);
}

.poster-venue {
  font-size: 0.84rem;
  color: var(--text-muted);
  font-style: italic;
  margin-top: 2px;
}

/* ---------- Teaching ---------- */
.teaching-list {
  list-style: none;
}

.teaching-item {
  padding: 14px 0;
  border-bottom: 1px solid var(--border-color);
}

.teaching-item:last-child {
  border-bottom: none;
}

.teaching-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 2px;
}

.teaching-role {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-primary);
}

.teaching-date {
  font-size: 0.84rem;
  color: var(--text-muted);
  white-space: nowrap;
}

.teaching-course {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.teaching-detail {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 2px;
}

/* ---------- Subsection Titles ---------- */
.subsection-title {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-top: 32px;
  margin-bottom: 8px;
  padding-bottom: 4px;
  border-bottom: 1px dashed var(--border-color);
}

/* ---------- Awards ---------- */
.awards-grid {
  list-style: none;
  display: grid;
  gap: 0;
}

.award-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border-color);
}

.award-item:last-child {
  border-bottom: none;
}

.award-icon {
  font-size: 1.2rem;
  flex-shrink: 0;
  line-height: 1.4;
}

.award-body {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.award-title {
  font-size: 0.93rem;
  font-weight: 600;
  color: var(--text-primary);
}

.award-detail {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* ---------- Publication Award Badge ---------- */
.pub-award {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 600;
  color: #b45309;
  background: #fef3c7;
  padding: 2px 10px;
  border-radius: 12px;
  margin-left: 6px;
  vertical-align: middle;
}

[data-theme="dark"] .pub-award {
  color: #fbbf24;
  background: rgba(251, 191, 36, 0.15);
}

/* ---------- Fellowships ---------- */
.fellowship-list {
  list-style: none;
}

.fellowship-item {
  padding: 12px 0;
  border-bottom: 1px solid var(--border-color);
}

.fellowship-item:last-child {
  border-bottom: none;
}

.fellowship-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 6px;
}

.fellowship-title {
  font-size: 0.93rem;
  font-weight: 600;
  color: var(--text-primary);
}

.fellowship-date {
  font-size: 0.84rem;
  color: var(--text-muted);
  white-space: nowrap;
}

.fellowship-detail {
  font-size: 0.87rem;
  color: var(--text-secondary);
  margin-top: 4px;
  line-height: 1.6;
}

/* ---------- Service ---------- */
.service-list {
  list-style: none;
}

.service-item {
  display: flex;
  align-items: baseline;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border-color);
  font-size: 0.93rem;
}

.service-item:last-child {
  border-bottom: none;
}

.service-role {
  font-weight: 600;
  color: var(--text-primary);
  background: var(--bg-table-even);
  padding: 2px 10px;
  border-radius: 6px;
  font-size: 0.82rem;
  white-space: nowrap;
}

.service-venue {
  color: var(--text-secondary);
}

/* ---------- Mentoring ---------- */
.mentoring-list {
  list-style: none;
}

.mentoring-item {
  padding: 12px 0;
  border-bottom: 1px solid var(--border-color);
}

.mentoring-item:last-child {
  border-bottom: none;
}

.mentoring-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 6px;
}

.mentoring-program {
  font-size: 0.93rem;
  font-weight: 600;
  color: var(--text-primary);
}

.mentoring-year {
  font-size: 0.84rem;
  color: var(--text-muted);
}

.mentoring-mentees {
  font-size: 0.87rem;
  color: var(--text-secondary);
  margin-top: 2px;
}

/* ---------- Skills ---------- */
.skill-group {
  margin-bottom: 20px;
}

.skill-group:last-child {
  margin-bottom: 0;
}

.skill-category {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.skill-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.skill-pill {
  display: inline-block;
  font-size: 0.82rem;
  padding: 5px 14px;
  border-radius: 20px;
  background: var(--bg-table-even);
  color: var(--text-secondary);
  border: 1px solid var(--border-color);
  transition: background var(--transition-speed), color var(--transition-speed);
}

.skill-pill:hover {
  background: var(--text-link);
  color: #fff;
  border-color: var(--text-link);
}

/* ---------- Contact ---------- */
.contact-grid {
  display: grid;
  gap: 0;
}

.contact-item {
  display: flex;
  gap: 16px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border-color);
  font-size: 0.94rem;
}

.contact-item:last-child {
  border-bottom: none;
}

.contact-label {
  color: var(--text-muted);
  font-style: italic;
  width: 100px;
  flex-shrink: 0;
}

.contact-value {
  color: var(--text-primary);
}

.contact-value a {
  text-decoration: none;
}

.contact-value a:hover {
  text-decoration: underline;
}

/* ---------- Mail Address ---------- */
.mail-address {
  font-family: 'Courier New', Courier, monospace;
  font-size: 0.9rem;
  color: var(--text-secondary);
  background: var(--bg-table-even);
  padding: 16px 20px;
  border-radius: 8px;
  line-height: 1.7;
  margin-top: 16px;
  border: 1px solid var(--border-color);
}

/* ---------- Footer ---------- */
.site-footer {
  margin-top: 60px;
  padding: 24px 0;
  border-top: 1px solid var(--border-color);
  text-align: center;
}

.footer-inner {
  max-width: 780px;
  margin: 0 auto;
  padding: 0 24px;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 20px;
  list-style: none;
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.footer-links a {
  font-size: 0.85rem;
  color: var(--text-muted);
  text-decoration: none;
  transition: color var(--transition-speed);
}

.footer-links a:hover {
  color: var(--text-link);
}

.footer-copy {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ---------- Citation Modal ---------- */
.cite-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.cite-dialog {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
  max-width: 600px;
  width: 100%;
  overflow: hidden;
  animation: fadeInUp 0.2s ease-out;
}

.cite-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-color);
}

.cite-title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
}

.cite-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0 4px;
  line-height: 1;
  transition: color var(--transition-speed);
}

.cite-close:hover {
  color: var(--text-primary);
}

.cite-code {
  margin: 0;
  padding: 20px;
  font-family: 'Courier New', Courier, monospace;
  font-size: 0.85rem;
  line-height: 1.6;
  color: var(--text-primary);
  background: var(--bg-table-even);
  overflow-x: auto;
  white-space: pre;
  max-height: 320px;
  overflow-y: auto;
}

.cite-copy {
  display: block;
  width: calc(100% - 40px);
  margin: 16px 20px 20px;
  padding: 10px;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  background: var(--bg-btn);
  color: var(--text-primary);
  font-size: 0.88rem;
  font-weight: 500;
  cursor: pointer;
  transition: background var(--transition-speed), border-color var(--transition-speed);
}

.cite-copy:hover {
  background: var(--bg-btn-hover);
}

.cite-btn {
  cursor: pointer;
  font-family: inherit;
}

/* ---------- Callout Box ---------- */
.callout {
  background: var(--bg-callout);
  border-left: 3px solid var(--border-callout);
  padding: 16px 20px;
  border-radius: 0 8px 8px 0;
  margin: 24px 0;
  font-size: 0.93rem;
  line-height: 1.65;
  color: var(--text-primary);
}

.callout strong {
  font-weight: 600;
}

/* ---------- Responsive ---------- */
@media (max-width: 640px) {
  .hero-name {
    font-size: 2rem;
  }

  .hero-subtitle {
    font-size: 1rem;
  }

  .nav-links {
    gap: 2px;
  }

  .nav-links a {
    font-size: 0.82rem;
    padding: 6px 8px;
  }

  .info-table td:first-child,
  .interest-table td:first-child {
    width: 90px;
    font-size: 0.82rem;
  }

  .pub-entry {
    flex-direction: column;
    gap: 6px;
  }

  .pub-label {
    width: auto;
    text-align: left;
  }

  .exp-header {
    flex-direction: column;
    gap: 2px;
  }

  .section-title {
    font-size: 1.35rem;
  }

  .container {
    padding: 0 16px;
  }

  .nav-inner {
    padding: 0 16px;
  }
}

/* ---------- Animations ---------- */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(16px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero,
.section {
  animation: fadeInUp 0.5s ease-out both;
}

.section:nth-child(2) {
  animation-delay: 0.05s;
}

.section:nth-child(3) {
  animation-delay: 0.1s;
}

.section:nth-child(4) {
  animation-delay: 0.15s;
}

.section:nth-child(5) {
  animation-delay: 0.2s;
}

/* ---------- Selection ---------- */
::selection {
  background: #3b82f6;
  color: #fff;
}

/* ---------- Scrollbar (Webkit) ---------- */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: var(--bg-secondary);
}

::-webkit-scrollbar-thumb {
  background: var(--border-color);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--text-muted);
}

/* ---------- Mobile hamburger ---------- */
.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
  color: var(--text-nav);
  font-size: 1.3rem;
}

@media (max-width: 500px) {
  .mobile-menu-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 52px;
    left: 0;
    right: 0;
    background: var(--bg-nav);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    flex-direction: column;
    padding: 12px 24px;
    border-bottom: 1px solid var(--border-color);
    box-shadow: var(--shadow-nav);
    gap: 4px;
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links a {
    padding: 10px 12px;
    width: 100%;
    border-radius: 6px;
  }
}