@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,400;0,600;0,700;1,400&family=IBM+Plex+Sans:wght@300;400;500&display=swap');

:root {
  --navy:      #0a1628;
  --navy-mid:  #0f2040;
  --navy-lt:   #1a3058;
  --bone:      #e8e0d0;
  --bone-lt:   #f5f1ea;
  --accent:    #5b9bd5;
  --accent-lt: #8ec3f0;
  --text-dark: #d8d0c0;
  --text-body: #a8a098;
  --border:    rgba(255,255,255,.08);
  --gold:      #c8a84b;
  --gold-lt:   #e8c86b;
  --card-bg:   rgba(255,255,255,.03);
  --red:       #c05040;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: 'IBM Plex Sans', sans-serif;
  background: var(--navy);
  color: var(--text-dark);
  font-size: 15.5px;
  line-height: 1.75;
}

/* ── GRID OVERLAY ── */
body::before {
  content: '';
  position: fixed; inset: 0;
  background-image:
    linear-gradient(rgba(91,155,213,.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(91,155,213,.04) 1px, transparent 1px);
  background-size: 60px 60px;
  pointer-events: none; z-index: 0;
}

/* ── HEADER ── */
.site-header {
  background: linear-gradient(160deg, #04090f 0%, #0a1628 40%, #0d1f3a 100%);
  position: relative; overflow: hidden;
  border-bottom: 1px solid var(--border);
}

.header-inner {
  max-width: 1000px;
  margin: auto;
  padding: 70px 40px 60px;
  position: relative; z-index: 1;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 40px;
  align-items: end;
}

.header-text {}

.header-eyebrow {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 4px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 16px;
  display: flex; align-items: center; gap: 12px;
}
.header-eyebrow::before {
  content: '';
  width: 24px; height: 1px;
  background: var(--accent);
}

.header-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(56px, 9vw, 100px);
  font-weight: 600;
  line-height: .95;
  letter-spacing: -2px;
  color: var(--bone-lt);
  margin-bottom: 22px;
}

.header-subtitle {
  font-size: 15px;
  font-weight: 300;
  color: var(--text-body);
  max-width: 500px;
  line-height: 1.7;
}

/* Skull wireframe illustration */
.header-skull {
  width: 160px; height: 160px;
  opacity: .18;
  flex-shrink: 0;
}

/* Decorative crosshair */
.header-crosshair {
  position: absolute;
  right: 100px; bottom: 60px;
  width: 120px; height: 120px;
  opacity: .07;
}

/* ── STICKY NAV ── */
.topic-nav {
  background: var(--navy-mid);
  border-bottom: 1px solid var(--border);
  position: sticky; top: 0; z-index: 100;
  backdrop-filter: blur(12px);
}
.topic-nav-inner {
  max-width: 1000px; margin: auto;
  padding: 0 40px;
  display: flex; gap: 2px;
  overflow-x: auto; scrollbar-width: none;
}
.topic-nav-inner::-webkit-scrollbar { display: none; }
.nav-pill {
  flex-shrink: 0;
  padding: 14px 18px;
  font-size: 12px; font-weight: 500;
  color: var(--text-body);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: all .2s;
  white-space: nowrap;
  background: none; border-top: none; border-left: none; border-right: none;
  letter-spacing: .5px;
}
.nav-pill:hover, .nav-pill.active {
  color: var(--accent-lt);
  border-bottom-color: var(--accent);
}

/* ── LAYOUT ── */
.main { max-width: 1000px; margin: auto; padding: 56px 40px 80px; }

/* ── SECTION ── */
.section { margin-bottom: 64px; opacity: 0; transform: translateY(28px); transition: opacity .65s, transform .65s; }
.section.visible { opacity: 1; transform: none; }

.section-label {
  font-size: 10px; font-weight: 500;
  letter-spacing: 4px; text-transform: uppercase;
  color: var(--accent); margin-bottom: 12px;
  display: flex; align-items: center; gap: 12px;
}
.section-label::after {
  content: ''; flex: 1; height: 1px;
  background: var(--border);
}

.section-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 30px; font-weight: 600;
  margin-bottom: 20px;
  color: var(--bone-lt);
}

p { color: var(--text-body); margin-bottom: 14px; }
p strong { color: var(--bone); }

/* ── CARDS ── */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 16px; margin-top: 24px;
}

.card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 12px; padding: 22px;
  transition: transform .25s, border-color .25s, box-shadow .25s;
}
.card:hover {
  transform: translateY(-4px);
  border-color: rgba(91,155,213,.3);
  box-shadow: 0 12px 32px rgba(0,0,0,.4);
}

.card-tag {
  display: inline-block;
  padding: 3px 10px; border-radius: 4px;
  font-size: 10px; font-weight: 500;
  letter-spacing: 2px; text-transform: uppercase;
  background: rgba(91,155,213,.12);
  color: var(--accent-lt);
  margin-bottom: 12px;
}

.card-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 18px; font-weight: 600;
  color: var(--bone); margin-bottom: 8px;
}
.card-body { font-size: 13.5px; color: var(--text-body); line-height: 1.65; }

/* ── OS TABLE ── */
.bones-table { width: 100%; border-collapse: collapse; margin-top: 24px; font-size: 13.5px; }
.bones-table th {
  text-align: left; padding: 11px 16px;
  font-size: 10px; letter-spacing: 2.5px; text-transform: uppercase;
  color: var(--accent); border-bottom: 1px solid var(--border);
  font-weight: 500;
}
.bones-table td {
  padding: 13px 16px; border-bottom: 1px solid rgba(255,255,255,.04);
  vertical-align: top; color: var(--text-body);
}
.bones-table tr:hover td { background: rgba(91,155,213,.04); }
.bones-table td:first-child { color: var(--bone); font-weight: 500; }

/* ── SUTURES ── */
.sutures-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 14px; margin-top: 20px;
}
.suture-card {
  border-left: 3px solid var(--accent);
  padding: 16px 18px;
  background: var(--card-bg);
  border-radius: 0 10px 10px 0;
}
.suture-name {
  font-family: 'Cormorant Garamond', serif;
  font-size: 16px; color: var(--bone);
  margin-bottom: 4px; font-weight: 600;
}
.suture-detail { font-size: 12.5px; color: var(--text-body); }

/* ── HIGHLIGHT ── */
.highlight-box {
  background: rgba(91,155,213,.07);
  border: 1px solid rgba(91,155,213,.2);
  border-radius: 10px;
  padding: 20px 24px; margin: 24px 0;
}
.highlight-box strong { color: var(--accent-lt); }

.warn-box {
  background: rgba(192,80,64,.07);
  border: 1px solid rgba(192,80,64,.25);
  border-radius: 10px;
  padding: 20px 24px; margin: 24px 0;
}
.warn-box strong { color: #e09080; }

/* ── STATS ── */
.stats-row {
  display: flex; flex-wrap: wrap; gap: 14px;
  margin-bottom: 50px;
}
.stat-pill {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 14px 22px;
  display: flex; flex-direction: column; gap: 4px;
}
.stat-num {
  font-family: 'Cormorant Garamond', serif;
  font-size: 26px; font-weight: 600;
  color: var(--accent-lt);
}
.stat-label { font-size: 11.5px; color: var(--text-body); }

/* ── BADGE ── */
.badge {
  display: inline-block; padding: 3px 10px;
  border-radius: 4px; font-size: 11px; font-weight: 500;
}
.badge-blue  { background: rgba(91,155,213,.15); color: var(--accent-lt); }
.badge-gold  { background: rgba(200,168,75,.15); color: var(--gold-lt); }
.badge-red   { background: rgba(192,80,64,.15); color: #e09080; }
.badge-bone  { background: rgba(232,224,208,.1); color: var(--bone); }

/* ── FONTANELLES ── */
.fontanelle-list { list-style: none; margin-top: 20px; }
.fontanelle-list li {
  display: flex; gap: 16px; align-items: flex-start;
  padding: 14px 0; border-bottom: 1px solid var(--border);
}
.fontanelle-list li:last-child { border-bottom: none; }
.fon-dot {
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--accent); flex-shrink: 0; margin-top: 6px;
}
.fon-name { font-family: 'Cormorant Garamond', serif; font-size: 17px; color: var(--bone); font-weight: 600; }
.fon-info { font-size: 13px; color: var(--text-body); }

/* ── FOOTER ── */
footer {
  text-align: center; padding: 28px;
  font-size: 11.5px; color: var(--text-body);
  border-top: 1px solid var(--border);
}

/* ── RESPONSIVE ── */
@media (max-width: 640px) {
  .header-inner { grid-template-columns: 1fr; padding: 40px 20px; }
  .header-skull { display: none; }
  .main { padding: 30px 20px 60px; }
  .topic-nav-inner { padding: 0 20px; }
}
