
:root {
  --mint: #3EDCB3;
  --ink: #222;
  --muted: #6b7280;
  --bg-soft: #f7f9f9;
  --border: #e6ecea;
}

/* Page shell */
.about {
  /* match app.css .wrap width for visual alignment with other pages */
  max-width: 1100px;
  margin: 0 auto;
  /* remove top padding so header sits at the same vertical position as other pages */
  padding: 0 1rem 4rem;
}

.about-header h1 {
  margin: 0 0 .25rem;
}

.about .lead {
  color: var(--muted);
  margin: 0 0 1.25rem;
}

/* TOC (wiki-style) */
.toc {
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1rem 1.25rem;
  margin: 1rem 0 1.5rem;
  font-size: larger;
}
.toc strong {
  display: block;
  font-size: 0.95rem;
  color: var(--ink);
  margin-bottom: .25rem;
}
.toc ol {
  list-style: decimal;
  margin: .25rem 0 0 1rem;
  padding: 0;
}
.toc a {
  text-decoration: none;
  color: var(--mint);
}
.toc a:hover { text-decoration: underline; }

/* Sections */
.section {
  padding: 1rem 0 1.25rem;
  border-top: 1px solid var(--border);
  scroll-margin-top: 80px; /* nice offset when jumping via anchors */
}
.section:first-of-type { border-top: 0; }
.section h2 {
  margin: 0 0 .5rem;
}

/* Details notes */
.note {
  margin: 0.75rem 0;
  border: 1px dashed var(--border);
  border-radius: 10px;
  padding: .5rem .75rem;
  background: #fff;
}
.note > summary {
  cursor: pointer;
  color: var(--mint);
  font-weight: 600;
}

/* Code block (inline sample FEN look) */
.code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  font-size: .9rem;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: .5rem .75rem;
  overflow-x: auto;
}

/* Figures grid for workflow images */
.figure-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin-top: .75rem;
}
.figure-grid figure {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: .5rem;
}
.figure-grid img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 8px;
}
.figure-grid figcaption {
  font-size: .85rem;
  color: var(--muted);
  margin-top: .35rem;
}

/* Back to top */
.back-to-top {
  margin-top: 2rem;
  text-align: right;
}
.back-to-top a {
  text-decoration: none;
  color: var(--mint);
}

/* Footer */
.about-footer {
  margin-top: 2rem;
  font-size: .9rem;
  color: var(--muted);
  text-align: center;
}
.about-footer a {
  color: var(--mint);
  text-decoration: none;
}
.about-footer a:hover { text-decoration: underline; }

/* Responsive tweaks */
@media (max-width: 900px) {
  .figure-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  .figure-grid { grid-template-columns: 1fr; }
}

/* Lightbox */
.lb {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.8);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  padding: 2rem 1rem;
}
.lb.is-open { display: flex; }

.lb-stage {
  position: relative;
  max-width: min(1000px, 95vw);
  max-height: 80vh;
  display: flex; align-items: center; justify-content: center;
}

.lb-img {
  max-width: 100%;
  max-height: 80vh;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0,0,0,.35);
  background: #fff;
}

.lb-caption, .lb-count {
  color: #f0f0f0;
  text-align: center;
  margin-top: .75rem;
}
.lb-caption { font-size: .95rem; }
.lb-count { font-size: .85rem; color: #cfd8dc; }

.lb-close {
  position: absolute; top: 1rem; right: 1rem;
  background: transparent; color: #fff; border: 0;
  font-size: 2rem; line-height: 1; cursor: pointer;
}

/* Navigation arrows */
.lb-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  align-items: center;
  justify-content: center;

  width: 44px;
  height: 44px;
  border-radius: 50%;

  background: rgba(255,255,255,.15);
  color: #fff;
  border: none;
  font-size: 1.6rem;
  line-height: 1;              /* remove baseline shift */
  cursor: pointer;
  transition: background-color 0.15s ease; /* no movement on hover */
}

.lb-nav:hover {
  background: rgba(255,255,255,.25);
  transform: translateY(-50%); /* keep exactly centered */
}

.lb-prev { left: -2.75rem; }
.lb-next { right: -2.75rem; }

@media (max-width: 640px) {
  .lb-prev { left: .25rem; }
  .lb-next { right: .25rem; }
}


/* Keep the lightbox hidden by default */
.lb { display: none; }

/* Show + layout only when open */
.lb.is-open {
  display: flex;
  flex-direction: column;     /* caption under the image */
  align-items: center;
  justify-content: center;
}

.lb-caption {
  max-width: min(1000px, 95vw);
  margin: .75rem auto 0;
  text-align: center;
  font-size: 1.1rem;
  font-weight: 600;
  color: #fff;
  line-height: 1.35;
}
.lb-count {
  max-width: min(1000px, 95vw);
  margin: .25rem auto 0;
  text-align: center;
  font-size: .9rem;
  color: #cfd8dc;
}

.social-links {
  list-style: none;
  padding: 0;
  margin: 1rem 0;
  display: flex;
  flex-wrap: wrap;
  gap: .75rem 1.25rem;
}

.social-links li {
  margin: 0;
}

.social-links a {
  text-decoration: none;
  color: var(--mint);
  font-weight: 600;
  background: var(--bg-soft);
  padding: .4rem .8rem;
  border-radius: 999px;
  transition: background .15s ease, color .15s ease;
}

.social-links a:hover {
  background: var(--mint);
  color: #fff;
}

/* Tabs bar */
.infotabs {
  display: inline-flex;
  gap: .5rem;
  margin: .75rem 0 1rem;
  border-bottom: 1px solid var(--border);
}

.infotabs .tab {
  appearance: none;
  background: transparent;
  border: 0;
  font: inherit;
  padding: .5rem .75rem;
  cursor: pointer;
  border-bottom: 2px solid transparent;
}

.infotabs .tab:is(:hover,:focus-visible) {
  text-decoration: underline;
}

.infotabs .tab.is-active {
  border-bottom-color: var(--mint, #2ecc71);
  font-weight: 600;
}


/* Keep your existing section styles */
.section {
  padding: 1rem 0 1.25rem;
  border-top: 1px solid var(--border);
  scroll-margin-top: 80px;
}
.section:first-of-type { border-top: 0; }
.section h2 { margin: 0 0 .5rem; }

