/* ClassicFortune — layout.css : structural layout */

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1.25rem;
}

header.site-header {
  background: var(--surface);
  border-bottom: 1px solid rgba(237,239,245,0.1);
  position: sticky;
  top: 0;
  z-index: 100;
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 0.9rem;
  padding-bottom: 0.9rem;
  flex-wrap: wrap;
  gap: 0.75rem;
}
.brand {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.35rem;
  color: var(--text-on-dark);
  text-decoration: none;
}
.brand:hover { text-decoration: none; }

nav.site-nav ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.1rem;
  margin: 0;
  padding: 0;
}
nav.site-nav a {
  color: var(--text-on-dark);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
}
nav.site-nav a:hover, nav.site-nav a:focus { text-decoration: underline; }

main {
  display: block;
}

.page-hero {
  padding: 3rem 0 2rem;
  border-bottom: 1px solid rgba(237,239,245,0.08);
}
.page-hero .lede {
  max-width: 68ch;
  font-size: 1.1rem;
  color: var(--text-on-dark);
}

.content-section {
  padding: 2.5rem 0;
}
.content-section + .content-section {
  border-top: 1px solid rgba(237,239,245,0.06);
}

.two-col {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}
@media (min-width: 800px) {
  .two-col { grid-template-columns: 2fr 1fr; }
}

article.prose {
  max-width: 72ch;
}
article.prose h2 { margin-top: 2rem; }
article.prose h3 { margin-top: 1.5rem; }

aside.sidebar {
  background: var(--surface);
  border-radius: 10px;
  padding: 1.5rem;
  height: fit-content;
}
aside.sidebar h2 { font-size: 1.1rem; margin-top: 0; }
aside.sidebar ul { padding-left: 1.2rem; }

footer.site-footer {
  background: var(--surface);
  border-top: 1px solid rgba(237,239,245,0.1);
  margin-top: 3rem;
  padding: 2.5rem 0;
}
footer.site-footer .footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}
@media (min-width: 700px) {
  footer.site-footer .footer-grid { grid-template-columns: 2fr 1fr 1fr; }
}
footer.site-footer nav ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
footer.site-footer nav li { margin-bottom: 0.4em; }
footer.site-footer nav a {
  color: var(--text-on-dark);
  text-decoration: none;
}
footer.site-footer nav a:hover { text-decoration: underline; }
footer.site-footer .fine-print {
  font-size: 0.85rem;
  color: rgba(237,239,245,0.7);
  margin-top: 2rem;
  max-width: 80ch;
}

/* Timeline lanes layout */
.timeline-wrap {
  overflow-x: auto;
  padding-bottom: 1rem;
}
.year-axis {
  display: flex;
  min-width: 900px;
  border-bottom: 2px solid rgba(237,239,245,0.25);
  margin-bottom: 0.5rem;
  padding-left: 140px;
}
.year-axis span {
  flex: 1 0 0;
  font-size: 0.8rem;
  color: rgba(237,239,245,0.65);
  padding-bottom: 0.3rem;
}
.lane-row {
  display: flex;
  align-items: center;
  min-width: 900px;
  padding: 1rem 0;
  border-bottom: 1px solid rgba(237,239,245,0.08);
  transition: opacity 0.2s ease;
}
.lane-row .lane-label {
  width: 140px;
  flex: 0 0 140px;
  font-family: var(--font-head);
  font-weight: 700;
}
.lane-row .lane-track {
  position: relative;
  flex: 1 0 0;
  height: 3px;
  background: rgba(237,239,245,0.15);
  border-radius: 3px;
}
@media (prefers-reduced-motion: reduce) {
  .lane-row { transition: none; }
}

.lane-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.detail-panel {
  background: var(--surface);
  border-top: 3px solid var(--accent);
  border-radius: 10px 10px 0 0;
  padding: 1.5rem;
  margin-top: 1.5rem;
}

.no-js-tables {
  display: block;
}
.js-only { display: none; }
.js-enabled .js-only { display: block; }
.js-enabled .no-js-tables { display: none; }

@media (max-width: 640px) {
  .site-header .container { flex-direction: column; align-items: flex-start; }
}
