/* ==========================================================================
   markramseyphd.com — personal site of Mark Ramsey, Ph.D.
   Dark, high-tech aesthetic: deep navy base, electric cyan→indigo accents.
   No frameworks, no build step.
   ========================================================================== */

:root {
  --bg: #05070f;
  --bg-2: #0a0f1e;
  --panel: rgba(255, 255, 255, 0.03);
  --panel-border: rgba(148, 183, 255, 0.12);
  --text: #e8edf7;
  --muted: #9aa7bf;
  --accent: #38bdf8;
  --accent-2: #6366f1;
  --accent-grad: linear-gradient(100deg, #38bdf8, #6366f1);
  --font-head: "Space Grotesk", sans-serif;
  --font-body: "Inter", sans-serif;
  --max: 1140px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }

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

h1, h2, h3, h4 { font-family: var(--font-head); line-height: 1.15; letter-spacing: -0.01em; }

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

/* ---------- nav ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: rgba(5, 7, 15, 0.72);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s;
}
.nav.scrolled { border-bottom-color: var(--panel-border); }
.nav-inner {
  max-width: var(--max); margin: 0 auto; padding: 16px 24px;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
.nav-logo {
  font-family: var(--font-head); font-weight: 700; font-size: 19px;
  color: var(--text); letter-spacing: 0.02em; white-space: nowrap;
}
.nav-logo:hover { text-decoration: none; }
.nav-logo em {
  font-style: normal;
  background: var(--accent-grad);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.nav-links { display: flex; align-items: center; gap: 26px; }
.nav-links a {
  color: var(--muted); font-size: 15px; font-weight: 500;
  transition: color 0.2s;
}
.nav-links a:hover, .nav-links a.active { color: var(--text); text-decoration: none; }
.nav-toggle { display: none; background: none; border: 0; cursor: pointer; padding: 6px; }
.nav-toggle span {
  display: block; width: 24px; height: 2px; background: var(--text);
  margin: 5px 0; border-radius: 2px; transition: transform 0.25s, opacity 0.25s;
}

/* ---------- buttons ---------- */
.btn {
  display: inline-block; padding: 13px 28px; border-radius: 10px;
  font-family: var(--font-head); font-weight: 600; font-size: 15.5px;
  letter-spacing: 0.01em; transition: transform 0.15s, box-shadow 0.2s, background 0.2s;
}
.btn:hover { text-decoration: none; transform: translateY(-2px); }
.btn-primary {
  background: var(--accent-grad); color: #fff;
  box-shadow: 0 8px 28px rgba(56, 189, 248, 0.22);
}
.btn-primary:hover { box-shadow: 0 12px 34px rgba(99, 102, 241, 0.35); }
.btn-ghost {
  color: var(--text); border: 1px solid rgba(148, 183, 255, 0.28);
  background: rgba(255, 255, 255, 0.02);
}
.btn-ghost:hover { border-color: var(--accent); }
.btn-nav { padding: 9px 20px; font-size: 14px; }

/* ---------- hero ---------- */
.hero {
  position: relative; min-height: 92vh;
  display: flex; align-items: center;
  padding: 140px 0 90px;
  overflow: hidden;
}
.hero-grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(99, 140, 255, 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(99, 140, 255, 0.055) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse 90% 70% at 50% 35%, black 35%, transparent 78%);
  -webkit-mask-image: radial-gradient(ellipse 90% 70% at 50% 35%, black 35%, transparent 78%);
}
.hero-glow {
  position: absolute; width: 900px; height: 900px;
  top: -320px; right: -220px; border-radius: 50%;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.14) 0%, rgba(99, 102, 241, 0.08) 42%, transparent 70%);
  filter: blur(10px);
  animation: pulse 9s ease-in-out infinite;
}
.hero-glow.two {
  top: auto; right: auto; bottom: -380px; left: -260px;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.12) 0%, transparent 65%);
  animation-delay: -4.5s;
}
@keyframes pulse {
  0%, 100% { opacity: 0.75; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.07); }
}
.hero-content { position: relative; max-width: var(--max); margin: 0 auto; padding: 0 24px; width: 100%; }

.hero-kicker {
  font-family: var(--font-head); font-size: 14px; font-weight: 600;
  letter-spacing: 0.22em; text-transform: uppercase; color: var(--accent);
  margin-bottom: 22px;
}
.hero h1 {
  font-size: clamp(42px, 6.4vw, 76px); font-weight: 700; max-width: 900px;
}
.hero h1 span {
  background: var(--accent-grad);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.hero-lede { max-width: 680px; margin-top: 26px; font-size: 19px; color: var(--muted); }
.hero-cta { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 38px; }

.hero-proof {
  list-style: none; display: flex; flex-wrap: wrap;
  gap: 20px 56px; margin-top: 66px;
}
.hero-proof li { display: flex; flex-direction: column; }
.hero-proof strong {
  font-family: var(--font-head); font-size: 36px; font-weight: 700;
  background: var(--accent-grad);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.hero-proof strong i { font-style: normal; font-size: 26px; }
.hero-proof span { font-size: 13.5px; color: var(--muted); max-width: 170px; }

/* ---------- page hero (subpages) ---------- */
.page-hero { position: relative; padding: 170px 0 70px; overflow: hidden; }
.page-hero .hero-grid { mask-image: radial-gradient(ellipse 90% 100% at 50% 0%, black 30%, transparent 80%); -webkit-mask-image: radial-gradient(ellipse 90% 100% at 50% 0%, black 30%, transparent 80%); }
.page-hero h1 { font-size: clamp(36px, 5vw, 58px); max-width: 860px; position: relative; }
.page-hero h1 span {
  background: var(--accent-grad);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.page-hero .hero-lede { position: relative; }
.page-hero .hero-kicker { position: relative; }

/* ---------- sections ---------- */
.section { padding: 96px 0; position: relative; }
.section-alt { background: var(--bg-2); border-top: 1px solid var(--panel-border); border-bottom: 1px solid var(--panel-border); }

.eyebrow {
  font-family: var(--font-head); font-size: 13px; font-weight: 600;
  letter-spacing: 0.22em; text-transform: uppercase; color: var(--accent);
  margin-bottom: 14px;
}
.section h2 { font-size: clamp(28px, 3.6vw, 42px); margin-bottom: 18px; max-width: 780px; }
.lede { color: var(--muted); font-size: 18px; max-width: 720px; }
.center { text-align: center; margin-left: auto; margin-right: auto; }

/* ---------- cards ---------- */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 22px; margin-top: 52px; }
.cards-2 { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 720px) { .cards-2 { grid-template-columns: 1fr; } }
.card {
  background: var(--panel); border: 1px solid var(--panel-border);
  border-radius: 16px; padding: 34px 30px;
  transition: transform 0.25s, border-color 0.25s, background 0.25s;
  position: relative; overflow: hidden;
}
.card::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: var(--accent-grad); opacity: 0; transition: opacity 0.25s;
}
.card:hover { transform: translateY(-4px); border-color: rgba(148, 183, 255, 0.3); background: rgba(255, 255, 255, 0.045); }
.card:hover::before { opacity: 1; }
.card-tag {
  display: inline-block; font-family: var(--font-head); font-size: 12px;
  font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--accent); border: 1px solid rgba(56, 189, 248, 0.3);
  border-radius: 100px; padding: 5px 14px; margin-bottom: 18px;
}
.card h3 { font-size: 22px; margin-bottom: 12px; }
.card p { color: var(--muted); font-size: 15.5px; }
.card ul { margin: 16px 0 0 18px; color: var(--muted); font-size: 15px; }
.card ul li { margin-bottom: 8px; }
.card .more { display: inline-block; margin-top: 18px; font-weight: 600; font-size: 15px; }

/* ---------- split layout ---------- */
.split { display: grid; grid-template-columns: 5fr 7fr; gap: 60px; align-items: center; }
.split-rev { grid-template-columns: 7fr 5fr; }
.split-media img {
  border-radius: 18px; border: 1px solid var(--panel-border);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.5);
}
.split-copy p { color: var(--muted); margin-bottom: 16px; }
.split-copy p strong { color: var(--text); }
.split-copy h2 { margin-bottom: 20px; }

/* ---------- timeline ---------- */
.timeline { position: relative; margin-top: 64px; }
.timeline::before {
  content: ""; position: absolute; left: 19px; top: 8px; bottom: 8px; width: 2px;
  background: linear-gradient(180deg, #38bdf8, #6366f1 60%, transparent);
  opacity: 0.45;
}
.tl-item { position: relative; padding: 0 0 64px 72px; }
.tl-item:last-child { padding-bottom: 0; }
.tl-dot {
  position: absolute; left: 8px; top: 6px; width: 24px; height: 24px;
  border-radius: 50%; background: var(--bg);
  border: 2px solid var(--accent);
  box-shadow: 0 0 0 5px rgba(56, 189, 248, 0.12), 0 0 18px rgba(56, 189, 248, 0.35);
}
.tl-era {
  font-family: var(--font-head); font-size: 13px; font-weight: 600;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--accent);
}
.tl-item h3 { font-size: 26px; margin: 8px 0 4px; }
.tl-role { font-size: 16px; color: var(--text); font-weight: 600; margin-bottom: 14px; }
.tl-item p { color: var(--muted); margin-bottom: 14px; max-width: 820px; }
.tl-item p strong { color: var(--text); }
.tl-facts { list-style: none; display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 14px; margin-top: 22px; max-width: 860px; }
.tl-facts li {
  background: var(--panel); border: 1px solid var(--panel-border);
  border-radius: 12px; padding: 16px 18px; font-size: 14.5px; color: var(--muted);
}
.tl-facts li strong { display: block; color: var(--text); font-family: var(--font-head); font-size: 17px; margin-bottom: 4px; }

/* ---------- quote band ---------- */
.quote-band { padding: 84px 0; background: var(--bg-2); border-top: 1px solid var(--panel-border); border-bottom: 1px solid var(--panel-border); }
.quote-band blockquote { max-width: 860px; margin: 0 auto; text-align: center; }
.quote-band p { font-family: var(--font-head); font-size: clamp(20px, 2.6vw, 27px); line-height: 1.5; font-weight: 500; }
.quote-band cite { display: block; margin-top: 22px; font-style: normal; color: var(--muted); font-size: 15px; }

blockquote.inline-quote {
  border-left: 3px solid var(--accent); padding: 6px 0 6px 24px;
  margin: 26px 0; font-size: 17px; color: var(--text);
}
blockquote.inline-quote cite { display: block; margin-top: 10px; font-style: normal; color: var(--muted); font-size: 14.5px; }

/* ---------- lists / articles ---------- */
.pub-list { list-style: none; margin-top: 46px; display: grid; gap: 16px; }
.pub-list li {
  background: var(--panel); border: 1px solid var(--panel-border);
  border-radius: 14px; padding: 24px 28px;
  display: flex; flex-wrap: wrap; gap: 6px 18px; align-items: baseline;
  transition: border-color 0.25s;
}
.pub-list li:hover { border-color: rgba(148, 183, 255, 0.3); }
.pub-list .pub-year { font-family: var(--font-head); font-weight: 700; color: var(--accent); min-width: 56px; }
.pub-list .pub-title { font-weight: 600; color: var(--text); flex: 1 1 320px; }
.pub-list .pub-venue { color: var(--muted); font-size: 14.5px; flex-basis: 100%; padding-left: 74px; }

.prose { max-width: 800px; }
.prose h3 { font-size: 24px; margin: 44px 0 14px; }
.prose p { color: var(--muted); margin-bottom: 16px; }
.prose p strong { color: var(--text); }
.prose ul { margin: 0 0 16px 22px; color: var(--muted); }
.prose ul li { margin-bottom: 10px; }
.prose ul li strong { color: var(--text); }

/* ---------- stat band ---------- */
.stat-band { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 22px; margin-top: 52px; }
.stat {
  background: var(--panel); border: 1px solid var(--panel-border);
  border-radius: 16px; padding: 30px 26px; text-align: center;
}
.stat strong {
  display: block; font-family: var(--font-head); font-size: 40px; font-weight: 700;
  background: var(--accent-grad);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.stat span { font-size: 14px; color: var(--muted); }

/* ---------- cta band ---------- */
.cta-band {
  padding: 100px 0; text-align: center; position: relative; overflow: hidden;
  background: var(--bg-2); border-top: 1px solid var(--panel-border);
}
.cta-band .hero-glow { top: -520px; right: 15%; }
.cta-band h2 { font-size: clamp(30px, 4vw, 46px); margin-bottom: 16px; position: relative; }
.cta-band p { color: var(--muted); max-width: 620px; margin: 0 auto 34px; position: relative; }
.cta-band .hero-cta { justify-content: center; position: relative; }

/* ---------- footer ---------- */
.footer { padding: 56px 0 44px; border-top: 1px solid var(--panel-border); }
.footer-inner { display: flex; flex-direction: column; gap: 18px; align-items: center; text-align: center; }
.footer nav { display: flex; flex-wrap: wrap; gap: 10px 26px; justify-content: center; }
.footer nav a { color: var(--muted); font-size: 14.5px; }
.footer nav a:hover { color: var(--text); text-decoration: none; }
.footer p { color: #5f6b83; font-size: 13.5px; }
.footer p a { color: var(--muted); }

/* ---------- reveal animation ---------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero-glow { animation: none; }
  html { scroll-behavior: auto; }
}

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .split, .split-rev { grid-template-columns: 1fr; gap: 40px; }
  .split-rev .split-media { order: -1; }
}
@media (max-width: 780px) {
  .nav-links {
    position: fixed; top: 62px; right: 0; left: 0;
    flex-direction: column; align-items: flex-start; gap: 4px;
    background: rgba(6, 9, 18, 0.97); border-bottom: 1px solid var(--panel-border);
    padding: 12px 24px 22px; display: none;
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 10px 0; font-size: 16px; }
  .nav-toggle { display: block; }
  .hero { min-height: 0; padding: 130px 0 70px; }
  .hero-proof { gap: 22px 36px; margin-top: 50px; }
  .section { padding: 72px 0; }
  .pub-list .pub-venue { padding-left: 0; }
  .tl-item { padding-left: 56px; }
}
