/* ===== Additions (Oct 2026) ===== */

/* Navigation font */
nav a, .menu-toggle {
  font-family: "Inter", var(--sans);
  font-size: 13.5px;
  font-weight: 500;
  letter-spacing: -0.01em;
}
nav a:not(.nav-button) { color: #24395c; transition: color .2s; }
nav a:not(.nav-button):hover { color: #2872ed; }
.nav-button { font-weight: 500; }

.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* Problem stats */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 46px;
  border-top: 1px solid var(--line);
}
.stat-grid > div {
  padding: 26px 22px 6px 0;
  border-right: 1px solid var(--line);
  margin-right: 22px;
}
.stat-grid > div:last-child { border-right: 0; margin-right: 0; }
.stat-grid strong {
  display: block;
  font-size: clamp(30px, 3.1vw, 44px);
  font-weight: 400;
  letter-spacing: -1.6px;
  line-height: 1;
  color: var(--ink);
}
.stat-grid > div:first-child strong { color: #2872ed; }
.stat-grid span {
  display: block;
  margin-top: 14px;
  font-size: 12px;
  line-height: 1.65;
  color: var(--muted);
  max-width: 210px;
}
.stat-note {
  font-size: 13px;
  line-height: 1.8;
  color: var(--muted);
  max-width: 640px;
  margin: 30px 0 0;
}
.source-row { display: flex; flex-wrap: wrap; gap: 0 28px; }

/* How it works: four steps */
.steps { grid-template-columns: repeat(4, 1fr); gap: 34px; }
.steps p { max-width: 250px; }

/* Why Turnwise comparison */
.compare-wrap {
  margin-top: 38px;
  border: 1px solid #d3e1f3;
  border-radius: 7px;
  overflow-x: auto;
  background: #fff;
  box-shadow: 0 15px 45px #10213d08;
}
.compare-table { width: 100%; border-collapse: collapse; font-size: 12.5px; min-width: 620px; }
.compare-table th, .compare-table td {
  text-align: left;
  padding: 17px 20px;
  border-bottom: 1px solid #e6eef8;
  vertical-align: top;
  line-height: 1.5;
}
.compare-table tbody tr:last-child th, .compare-table tbody tr:last-child td { border-bottom: 0; }
.compare-table thead th {
  font-size: 13px;
  font-weight: 500;
  color: var(--ink);
  background: #f7faff;
  border-bottom: 1px solid #d9e6f5;
}
.compare-table thead small {
  display: block;
  font-size: 10px;
  font-weight: 400;
  color: var(--muted);
  margin-top: 4px;
}
.compare-table tbody th { font-weight: 400; color: #526d94; width: 28%; }
.compare-table td { color: #2a3f60; }
.compare-table .is-turnwise { background: #eef5ff; }
.compare-table thead .is-turnwise { background: #2872ed; color: #fff; }
.compare-table thead .is-turnwise small { color: #d6e6ff; }
.compare-table .yes, .compare-table .no { display: inline-flex; align-items: center; gap: 8px; }
.compare-table .yes:before, .compare-table .no:before {
  content: '';
  width: 7px; height: 7px; border-radius: 50%;
  flex: none;
}
.compare-table .yes:before { background: #2872ed; }
.compare-table .no:before { background: #c3cfdf; }
.compare-table .no { color: #7d8fa8; }
.compare-note { font-size: 10.5px; line-height: 1.7; color: #6b82a3; margin: 18px 0 0; max-width: 720px; }
.compare-note a { text-decoration: underline; text-underline-offset: 3px; }

/* Testing log */
.test-log { padding: 0 0 28px; }
.test-log ol { list-style: none; margin: 0; padding: 0; position: relative; }
.test-log ol:before {
  content: '';
  position: absolute; left: 52px; top: 8px; bottom: 8px;
  width: 1px; background: linear-gradient(#2872ed, #cfe0f6);
}
.test-log li {
  display: grid;
  grid-template-columns: 52px 1fr;
  column-gap: 30px;
  padding: 0 0 26px;
  position: relative;
}
.test-log li:after {
  content: '';
  position: absolute; left: 48px; top: 6px;
  width: 9px; height: 9px; border-radius: 50%;
  background: #fff; border: 2px solid #2872ed;
}
.test-log time {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 10px;
  letter-spacing: .5px;
  color: #3476cc;
  padding-top: 3px;
}
.test-log h3 { font-size: 14px; font-weight: 500; margin: 0 0 7px; color: var(--ink); }
.test-log p { font-size: 12px; line-height: 1.8; color: var(--muted); margin: 0; max-width: 640px; }
.test-next {
  font-size: 12px; line-height: 1.8; color: #2a3f60;
  background: #f2f7ff; border-left: 2px solid #2872ed;
  padding: 14px 18px; margin: 4px 0 0;
}
.test-next strong { font-weight: 600; }

/* Layer scroll intro */
.product-visual.intro-instant .stack-layer,
.product-visual.intro-instant .sheet-stack,
.product-visual.intro-instant .bed-stack,
.product-visual.intro-instant .stack-label,
.product-visual.intro-instant .scene-callouts { transition: none !important; }
.product-visual .stack-label { transition: opacity .6s ease .5s; }
.product-visual.is-assembled .stack-label { transition-delay: 0s; }

/* Responsive */
@media (max-width: 900px) {
  .stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stat-grid > div:nth-child(2) { border-right: 0; margin-right: 0; }
  .stat-grid > div:nth-child(n+3) { border-top: 1px solid var(--line); }
  .steps { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .stat-grid > div { padding-right: 14px; margin-right: 14px; }
  .steps { grid-template-columns: 1fr; }
  .test-log ol:before { left: 4px; }
  .test-log li { grid-template-columns: 1fr; padding-left: 26px; }
  .test-log li:after { left: 0; }
  .test-log time { margin-bottom: 6px; }
}

/* Comparison table becomes cards on phones */
@media (max-width: 640px) {
  .compare-wrap { overflow: visible; }
  .compare-table { min-width: 0; }
  .compare-table thead { display: none; }
  .compare-table, .compare-table tbody, .compare-table tr, .compare-table th, .compare-table td { display: block; width: auto; }
  .compare-table tr { padding: 16px 18px; border-bottom: 1px solid #e6eef8; }
  .compare-table tbody tr:last-child { border-bottom: 0; }
  .compare-table tbody th { width: auto; padding: 0 0 10px; border: 0; color: var(--ink); font-weight: 500; }
  .compare-table td { display: flex; justify-content: space-between; gap: 16px; padding: 7px 10px; border: 0; font-size: 12px; text-align: right; }
  .compare-table td:before { content: attr(data-label); color: #7d8fa8; text-align: left; flex: none; }
  .compare-table td.is-turnwise { border-radius: 4px; }
  .compare-table td.is-turnwise:before { color: #2872ed; font-weight: 600; }
}

/* ===== Tabs ===== */
.page[hidden] { display: none !important; }
.page-enter { animation: page-in .55s cubic-bezier(.2,.8,.2,1) both; }
@keyframes page-in { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .page-enter { animation: none; } }
.header nav a[aria-current=page]:not(.nav-button) { color: #2872ed; }
.header nav a[aria-current=page]:after { transform: scaleX(1); }

/* first section on a tab page gets breathing room under the header */
.page:not(#overview) > section:first-child { padding-top: 80px; }

.page-next { padding: 70px 0 90px; }
.page-next-link {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 30px 34px;
  border: 1px solid #d3e1f3;
  border-radius: 7px;
  background: #f7faff;
  transition: background .3s, border-color .3s, transform .3s;
}
.page-next-link span {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 10px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--muted);
}
.page-next-link strong {
  font-size: clamp(24px, 2.6vw, 34px);
  font-weight: 400;
  letter-spacing: -1px;
  color: var(--ink);
}
.page-next-link i {
  margin-left: auto;
  font-style: normal;
  font-size: 26px;
  color: #2872ed;
  transition: transform .3s;
}
.page-next-link:hover { background: #eef5ff; border-color: #a9c8f1; }
.page-next-link:hover i { transform: translateX(6px); }
@media (max-width: 640px) {
  .page-next { padding: 40px 0 60px; }
  .page-next-link { padding: 22px 20px; flex-wrap: wrap; gap: 6px 14px; }
  .page:not(#overview) > section:first-child { padding-top: 50px; }
}

/* Explore the data tab: highlight the button when active */
.header nav a.nav-button[aria-current=page] { background: #0f3f9a; border-color: #0f3f9a; color: #fff; }

/* Testing log without dates */
.test-log ol:before { left: 4px; }
.test-log li { grid-template-columns: 1fr; padding-left: 34px; }
.test-log li:after { left: 0; }

/* Our story */
.story-placeholder p.story-copy { color: #3b506f; font-size: 14px; line-height: 1.85; max-width: 760px; margin: 14px 0 0; }
.story-placeholder p.story-copy + p.story-copy { margin-top: 12px; }
.section-intro.team-split{margin-top:14px}

/* ===== Multi-page ===== */
h1.page-h1 { font-size: clamp(30px, 3.2vw, 45px); font-weight: 400; line-height: 1.15; letter-spacing: -1.8px; margin: 0 0 24px; }
.section-heading h1.page-h1 { margin: 0; }
.subpage > section:first-child { padding-top: 80px; }
@media (max-width: 640px) { .subpage > section:first-child { padding-top: 50px; } }
.header nav a[aria-current=page]:not(.nav-button) { color: #2872ed; }
.header nav a[aria-current=page]:after { transform: scaleX(1); }
.footer-nav { display: flex; flex-wrap: wrap; gap: 10px 22px; font-family: "Inter", var(--sans); font-size: 12px; }
.footer .footer-nav a { color: #bfd1eb; font-weight: 400; }
.footer .footer-nav a:hover { color: #fff; text-decoration: underline; text-underline-offset: 4px; }
@media (max-width: 900px) { .footer-main { flex-wrap: wrap; } .footer-nav { order: 3; width: 100%; } }
