/*
================================================================
benchmarks.iqintel.io — page styles
================================================================
Builds on iqintel-tokens.css (imported separately). This file
defines the layout and component primitives specific to the
benchmarks site. Whitepaper-leaning: narrow prose columns,
generous vertical rhythm, restrained color, more disciplined
typographic hierarchy than the marketing site.

Inherits from iqintel-tokens.css:
  - All CSS custom properties (--iq-*)
  - Base resets, body, heading defaults
  - .iq-container, .iq-section, .iq-eyebrow, .iq-btn, .iq-card
================================================================
*/

.research-findings {
  margin: 3rem 0;
  padding: 2rem;
  background: #f8f9fa;
  border-radius: 8px;
  border-left: 5px solid #0d6efd;
}

.research-findings h2 {
  color: #0d6efd;
  margin-bottom: 1.5rem;
}

.finding-content ul {
  margin: 1.2rem 0;
  padding-left: 1.5rem;
}

.finding-content li {
  margin-bottom: 0.8rem;
}

.data-availability {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid #dee2e6;
}

.data-availability h3 {
  color: #495057;
  margin-bottom: 1rem;
}

/* ============================================================
   NAV (mirrors iqintel.io exactly so the experience carries over)
   ============================================================ */

html {
  scroll-padding-top: 72px;
}

.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(140%) blur(10px);
  -webkit-backdrop-filter: saturate(140%) blur(10px);
  border-bottom: var(--iq-border-thin);
}

/* Autohide: slides up on scroll; reveal at top edge or when menu open */
header.nav.nav-autohide {
  transition: transform 0.22s ease;
  will-change: transform;
}
body.nav-is-hidden header.nav.nav-autohide:not(.is-open) {
  transform: translateY(-100%);
  pointer-events: none;
}
body.has-autohide-nav {
  --nav-offset: 72px;
}
body.has-autohide-nav.nav-is-hidden {
  --nav-offset: 0px;
}
body.has-autohide-nav:not(.viewer-app) {
  scroll-padding-top: var(--nav-offset);
}

/* Viewer: autohide only (keep full desktop nav); fixed overlay for full-screen layout */
body.viewer-app .bench-dataset-nav { display: none; }
body.viewer-app header.nav.nav-autohide {
  position: fixed;
  left: 0;
  right: 0;
  top: 0;
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--iq-space-5);
}

.nav-brand {
  font-family: var(--iq-font-serif);
  font-size: var(--iq-h4);
  color: var(--iq-text-primary);
  letter-spacing: -0.01em;
  text-decoration: none;
}
.nav-brand:hover { color: var(--iq-text-primary); }

.nav-links {
  display: flex;
  gap: var(--iq-space-5);
  align-items: center;
}
.nav-links > a {
  font-family: var(--iq-font-sans);
  font-size: var(--iq-body-sm);
  color: var(--iq-text-body);
  font-weight: 400;
  text-decoration: none;
  transition: color var(--iq-dur-fast) var(--iq-ease);
}
.nav-links > a:hover,
.nav-links > a.is-active {
  color: var(--iq-accent);
}

.nav-cta {
  font-size: var(--iq-body-sm);
}

.nav-menu-btn {
  display: none;
  background: none;
  border: 0;
  padding: 8px;
  cursor: pointer;
  color: var(--iq-text-primary);
  border-radius: var(--iq-radius-sm);
  transition: background var(--iq-dur-fast) var(--iq-ease);
}
.nav-menu-btn:hover { background: var(--iq-bg-secondary); }
.nav-menu-btn:focus-visible {
  outline: none;
  box-shadow: var(--iq-focus-ring);
}


/* ============================================================
   NAV DROPDOWN (desktop) — Blog item with two-column flyout
   ============================================================ */

.nav-dropdown {
  position: relative;
  display: inline-flex;
  align-items: center;
}
.nav-dropdown-trigger {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: transparent;
  border: 0;
  padding: 0;
  margin: 0;
  font-family: var(--iq-font-sans);
  font-size: var(--iq-body-sm);
  font-weight: 400;
  color: var(--iq-text-body);
  line-height: var(--iq-lh-ui);
  cursor: pointer;
  transition: color var(--iq-dur-fast) var(--iq-ease);
}
.nav-dropdown-trigger:hover,
.nav-dropdown.is-open .nav-dropdown-trigger { color: var(--iq-accent); }
.nav-dropdown-trigger:focus-visible {
  outline: none;
  box-shadow: var(--iq-focus-ring);
  border-radius: var(--iq-radius-sm);
}
.nav-dropdown-caret { transition: transform var(--iq-dur) var(--iq-ease); }
.nav-dropdown.is-open .nav-dropdown-caret { transform: rotate(180deg); }

.nav-dropdown-panel {
  position: absolute;
  top: 100%;
  right: 0;
  margin-top: var(--iq-space-3);
  min-width: 560px;
  background: var(--iq-bg-primary);
  border: var(--iq-border-1);
  border-radius: var(--iq-radius-lg);
  box-shadow: 0 8px 32px rgba(10, 10, 10, 0.08);
  padding: var(--iq-space-5);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-4px);
  transition: opacity var(--iq-dur) var(--iq-ease),
              transform var(--iq-dur) var(--iq-ease),
              visibility var(--iq-dur) var(--iq-ease);
  z-index: 60;
}
.nav-dropdown.is-open .nav-dropdown-panel {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.nav-dropdown-panel::before {
  content: "";
  position: absolute;
  top: calc(-1 * var(--iq-space-3));
  left: 0;
  right: 0;
  height: var(--iq-space-3);
}
.nav-dropdown-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--iq-space-5);
}
.nav-dropdown-group-title {
  display: block;
  font-family: var(--iq-font-sans);
  font-size: var(--iq-eyebrow);
  font-weight: 500;
  letter-spacing: var(--iq-ls-eyebrow);
  text-transform: uppercase;
  color: var(--iq-accent);
  text-decoration: none;
  padding-bottom: var(--iq-space-3);
  margin-bottom: var(--iq-space-3);
  border-bottom: var(--iq-border-thin);
  transition: color var(--iq-dur-fast) var(--iq-ease);
}
.nav-dropdown-group-title:hover { color: var(--iq-accent-hover); }
.nav-dropdown-group-sub {
  display: block;
  margin-top: 4px;
  font-size: var(--iq-body-sm);
  font-weight: 400;
  letter-spacing: 0;
  text-transform: none;
  color: var(--iq-text-secondary);
}
.nav-dropdown-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: var(--iq-space-2); }
.nav-dropdown-list a {
  display: block;
  font-size: var(--iq-body-sm);
  color: var(--iq-text-body);
  text-decoration: none;
  line-height: 1.45;
  padding: 4px 0;
  transition: color var(--iq-dur-fast) var(--iq-ease);
}
.nav-dropdown-list a:hover { color: var(--iq-accent); }
.nav-dropdown-list .is-forthcoming {
  display: block;
  font-size: var(--iq-body-sm);
  color: var(--iq-text-tertiary);
  font-style: italic;
  padding: 4px 0;
  cursor: default;
}
@media (max-width: 900px) {
  .nav-dropdown-panel { min-width: 360px; }
  .nav-dropdown-grid { grid-template-columns: 1fr; gap: var(--iq-space-4); }
}


/* ============================================================
   MOBILE PANEL (≤600px)
   ============================================================ */

.nav-mobile-panel { display: none; }

@media (max-width: 600px) {

  .nav-brand img { height: 48px !important; width: auto; }
  .nav-cta { display: none; }
  .nav-inner { gap: var(--iq-space-3); }
  .nav-links { display: none; }
  .nav-menu-btn { display: inline-flex; align-items: center; justify-content: center; }

  .nav-mobile-panel {
    display: block;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: saturate(140%) blur(10px);
    -webkit-backdrop-filter: saturate(140%) blur(10px);
    border-bottom: var(--iq-border-thin);
    border-top: var(--iq-border-thin);
    padding: var(--iq-space-3) var(--iq-space-5) var(--iq-space-5);
    max-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    opacity: 0;
    transition: max-height var(--iq-dur-slow) var(--iq-ease),
                opacity var(--iq-dur) var(--iq-ease),
                padding var(--iq-dur-slow) var(--iq-ease);
  }
  .nav.is-open .nav-mobile-panel {
    max-height: calc(100vh - 80px);
    opacity: 1;
  }

  .nav-mobile-panel > a,
  .nav-mobile-group-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: var(--iq-space-3) 0;
    font-family: var(--iq-font-sans);
    font-size: var(--iq-body);
    font-weight: 400;
    color: var(--iq-text-body);
    text-decoration: none;
    text-align: left;
    background: transparent;
    border: 0;
    border-bottom: var(--iq-border-thin);
    cursor: pointer;
  }
  .nav-mobile-panel > a.is-active,
  .nav-mobile-panel > a:hover,
  .nav-mobile-group-toggle:hover { color: var(--iq-accent); }

  .nav-mobile-caret { transition: transform var(--iq-dur) var(--iq-ease); flex-shrink: 0; }
  .nav-mobile-group.is-expanded > .nav-mobile-group-toggle .nav-mobile-caret,
  .nav-mobile-subgroup.is-expanded > .nav-mobile-subgroup-toggle .nav-mobile-caret { transform: rotate(180deg); }

  .nav-mobile-group-children,
  .nav-mobile-subgroup-children {
    max-height: 0;
    overflow: hidden;
    transition: max-height var(--iq-dur-slow) var(--iq-ease);
  }
  .nav-mobile-group.is-expanded > .nav-mobile-group-children { max-height: 2000px; }
  .nav-mobile-subgroup.is-expanded > .nav-mobile-subgroup-children { max-height: 1000px; }

  .nav-mobile-subgroup-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: var(--iq-space-3) 0 var(--iq-space-3) var(--iq-space-4);
    font-family: var(--iq-font-sans);
    font-size: var(--iq-body-sm);
    font-weight: 500;
    color: var(--iq-text-primary);
    background: transparent;
    border: 0;
    border-bottom: var(--iq-border-thin);
    text-align: left;
    cursor: pointer;
  }
  .nav-mobile-subgroup:last-child > .nav-mobile-subgroup-toggle { border-bottom: 0; }

  .nav-mobile-subgroup-children a,
  .nav-mobile-subgroup-children span {
    display: block;
    padding: var(--iq-space-2) 0 var(--iq-space-2) var(--iq-space-7);
    font-size: var(--iq-body-sm);
    color: var(--iq-text-body);
    text-decoration: none;
    line-height: 1.45;
    border-bottom: var(--iq-border-thin);
  }
  .nav-mobile-subgroup-children a:hover { color: var(--iq-accent); }
  .nav-mobile-subgroup-children .nav-mobile-view-all { color: var(--iq-accent); font-weight: 500; }
  .nav-mobile-subgroup-children .nav-mobile-forthcoming {
    color: var(--iq-text-tertiary);
    font-style: italic;
    cursor: default;
  }
  .nav-mobile-subgroup-children > *:last-child { border-bottom: 0; }

  .nav-mobile-cta {
    display: block;
    margin-top: var(--iq-space-4);
    padding-top: var(--iq-space-4);
    border-top: var(--iq-border-thin);
    border-bottom: 0 !important;
    color: var(--iq-accent) !important;
    font-weight: 500;
  }
}


/* ============================================================
   HERO
   ============================================================
   Whitepaper-leaning: text-heavy left column, restrained
   visual on the right. No big-energy CTA stack; two buttons,
   secondary visually deprioritized.
*/

.bench-hero {
  padding-top: var(--iq-space-8);
  padding-bottom: var(--iq-section-y);
}

.bench-hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--iq-space-7);
  align-items: center;
}

.bench-hero-copy h1 {
  font-size: var(--iq-h1);
  line-height: var(--iq-lh-tight);
  letter-spacing: var(--iq-ls-heading);
  margin-top: var(--iq-space-3);
  margin-bottom: var(--iq-space-4);
}

.bench-hero-lede {
  font-size: var(--iq-body-lg);
  line-height: 1.55;
  color: var(--iq-text-body);
  margin-bottom: var(--iq-space-6);
  max-width: 540px;
}

.bench-hero-ctas {
  display: flex;
  gap: var(--iq-space-3);
  flex-wrap: wrap;
}

.bench-hero-figure {
  margin: 0;
}
.bench-hero-figure-frame {
  border-radius: var(--iq-radius-xl);
  overflow: hidden;
  border: var(--iq-border-thin);
  background: var(--iq-bg-secondary);
}
.bench-hero-figure figcaption {
  margin-top: var(--iq-space-3);
  font-size: var(--iq-caption);
  color: var(--iq-text-secondary);
  line-height: 1.55;
}


/* ============================================================
   SECTIONS — generous vertical rhythm
   ============================================================ */

.bench-section {
  padding-top: var(--iq-section-y);
  padding-bottom: var(--iq-section-y);
}
.bench-section--gray { background: var(--iq-bg-secondary); }
.bench-section--cta {
  background: var(--iq-bg-tint);
  padding-top: var(--iq-section-y);
  padding-bottom: var(--iq-section-y);
}

/* Prose sections — narrow reading column, serif-heavy */
.bench-prose {
  max-width: var(--iq-prose);
}
.bench-prose h2 {
  font-size: var(--iq-h2);
  line-height: var(--iq-lh-snug);
  margin-top: var(--iq-space-3);
  margin-bottom: var(--iq-space-5);
}
.bench-prose p {
  font-size: var(--iq-body);
  line-height: var(--iq-lh-body);
  color: var(--iq-text-body);
  margin-bottom: var(--iq-space-5);
}
.bench-prose p:last-child { margin-bottom: 0; }
.bench-prose a {
  color: var(--iq-accent);
  text-decoration: underline;
  text-decoration-thickness: 0.5px;
  text-underline-offset: 3px;
}
.bench-prose a:hover { color: var(--iq-accent-hover); }

.bench-prose--article {
  max-width: min(720px, 100%);
}
.bench-prose--article h3 {
  font-size: var(--iq-h3);
  margin: var(--iq-space-6) 0 var(--iq-space-4);
}
.bench-prose--article em {
  font-style: italic;
}
.bench-prose-divider {
  border: 0;
  border-top: var(--iq-border-thin);
  margin: var(--iq-space-7) 0;
}
.bench-prose-note {
  font-size: var(--iq-body-sm);
  color: var(--iq-text-muted, #5c6570);
}
.bench-prose-footnote {
  font-size: var(--iq-body-sm);
  color: var(--iq-text-muted, #5c6570);
  line-height: 1.6;
}
.bench-prose-refs {
  margin: 0;
  padding-left: 1.25rem;
  font-size: var(--iq-body-sm);
  line-height: 1.65;
  color: var(--iq-text-body);
}
.bench-prose-refs li {
  margin-bottom: var(--iq-space-3);
}
.bench-prose-refs li:last-child {
  margin-bottom: 0;
}
.bench-use-more {
  margin: var(--iq-space-7) 0 0;
  max-width: var(--iq-prose);
  font-size: var(--iq-body-lg);
}
.bench-use-more a {
  color: var(--iq-accent);
  text-decoration: underline;
  text-decoration-thickness: 0.5px;
  text-underline-offset: 3px;
  font-weight: 600;
}
.bench-use-more a:hover {
  color: var(--iq-accent-hover);
}

/* Section headers with eyebrow + h2 + optional lede */
.bench-section-header {
  max-width: var(--iq-prose);
  margin-bottom: var(--iq-space-7);
}
.bench-section-header h2 {
  font-size: var(--iq-h2);
  line-height: var(--iq-lh-snug);
  margin-top: var(--iq-space-3);
  margin-bottom: var(--iq-space-4);
}
.bench-section-lede {
  font-size: var(--iq-body-lg);
  line-height: 1.55;
  color: var(--iq-text-body);
}


/* ============================================================
   DATASETS GRID
   ============================================================ */

.bench-datasets-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--iq-space-5);
}

.bench-dataset-card {
  display: flex;
  flex-direction: column;
  gap: var(--iq-space-3);
  padding: var(--iq-space-6);
  background: var(--iq-bg-primary);
  border: var(--iq-border-1);
  border-radius: var(--iq-radius-lg);
  text-decoration: none;
  color: var(--iq-text-body);
  transition: border-color var(--iq-dur) var(--iq-ease),
              box-shadow var(--iq-dur) var(--iq-ease),
              transform var(--iq-dur) var(--iq-ease);
}
a.bench-dataset-card:hover {
  border-color: var(--iq-border-strong);
  box-shadow: var(--iq-shadow-hover);
  transform: translateY(-1px);
}
.bench-dataset-card.is-forthcoming {
  background: var(--iq-bg-secondary);
  border-style: dashed;
  cursor: default;
}

.bench-dataset-status {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--iq-space-3);
  flex-wrap: wrap;
  margin-bottom: var(--iq-space-2);
}

.bench-status-pill {
  display: inline-block;
  padding: 4px 10px;
  border-radius: var(--iq-radius-sm);
  font-family: var(--iq-font-sans);
  font-size: var(--iq-caption);
  font-weight: 500;
  letter-spacing: var(--iq-ls-eyebrow);
  text-transform: uppercase;
}
.bench-status-pill--open {
  background: var(--iq-success);
  color: var(--iq-accent-on);
}
.bench-status-pill--soon {
  background: var(--iq-bg-tint);
  color: var(--iq-accent);
  border: 0.5px solid var(--iq-accent);
}

.bench-dataset-range {
  font-size: var(--iq-caption);
  color: var(--iq-text-secondary);
}

.bench-dataset-card h3 {
  font-size: var(--iq-h3);
  font-family: var(--iq-font-serif);
  font-weight: 400;
  margin: 0;
  color: var(--iq-text-primary);
}

.bench-dataset-tagline {
  font-size: var(--iq-body-sm);
  color: var(--iq-text-secondary);
  margin: 0;
}

.bench-dataset-body {
  font-size: var(--iq-body);
  line-height: var(--iq-lh-body);
  color: var(--iq-text-body);
  margin: 0;
  flex: 1;
}

.bench-dataset-cta {
  margin-top: var(--iq-space-3);
  font-size: var(--iq-body-sm);
  font-weight: 500;
  color: var(--iq-accent);
  transition: color var(--iq-dur-fast) var(--iq-ease);
}
a.bench-dataset-card:hover .bench-dataset-cta { color: var(--iq-accent-hover); }
.bench-dataset-cta.is-forthcoming {
  color: var(--iq-text-tertiary);
  font-style: italic;
}


/* ============================================================
   ACCESS TIERS
   ============================================================ */

.bench-tiers-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--iq-space-5);
}

.bench-tier {
  padding: var(--iq-space-6);
  background: var(--iq-bg-secondary);
  border-radius: var(--iq-radius-lg);
}
.bench-tier--accent {
  background: var(--iq-bg-tint);
  border-left: 3px solid var(--iq-accent);
}

.bench-tier-label {
  font-family: var(--iq-font-sans);
  font-size: var(--iq-eyebrow);
  font-weight: 500;
  letter-spacing: var(--iq-ls-eyebrow);
  text-transform: uppercase;
  color: var(--iq-accent);
  margin-bottom: var(--iq-space-3);
}

.bench-tier h3 {
  font-size: var(--iq-h3);
  margin: 0 0 var(--iq-space-3);
}

.bench-tier p {
  font-size: var(--iq-body);
  line-height: var(--iq-lh-body);
  color: var(--iq-text-body);
  margin-bottom: var(--iq-space-4);
}

.bench-tier-list {
  list-style: none;
  padding: 0;
  margin: 0 0 var(--iq-space-5);
  display: flex;
  flex-direction: column;
  gap: var(--iq-space-2);
}
.bench-tier-list li {
  padding-left: var(--iq-space-4);
  position: relative;
  font-size: var(--iq-body-sm);
  color: var(--iq-text-body);
  line-height: 1.5;
}
.bench-tier-list li::before {
  content: "·";
  position: absolute;
  left: var(--iq-space-2);
  color: var(--iq-accent);
  font-weight: 700;
}


/* ============================================================
   INTENDED USES — numbered list
   ============================================================ */

.bench-uses-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--iq-space-6);
  counter-reset: bench-uses;
}

.bench-use {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: var(--iq-space-5);
  padding-bottom: var(--iq-space-6);
  border-bottom: var(--iq-border-thin);
}
.bench-use:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.bench-use-num {
  font-family: var(--iq-font-serif);
  font-size: var(--iq-h2);
  font-weight: 400;
  color: var(--iq-accent);
  line-height: 1;
  letter-spacing: var(--iq-ls-heading);
}

.bench-use-body {
  max-width: var(--iq-prose);
}
.bench-use-body h3 {
  font-size: var(--iq-h3);
  margin: 0 0 var(--iq-space-3);
}
.bench-use-body p {
  font-size: var(--iq-body);
  line-height: var(--iq-lh-body);
  color: var(--iq-text-body);
  margin: 0;
}
.bench-use-body a {
  color: var(--iq-accent);
  text-decoration: underline;
  text-decoration-thickness: 0.5px;
  text-underline-offset: 3px;
}


/* ============================================================
   FINAL CTA
   ============================================================ */

.bench-cta-inner {
  max-width: var(--iq-prose);
  margin: 0 auto;
  text-align: center;
}
.bench-cta-inner h2 {
  font-size: var(--iq-h2);
  margin: var(--iq-space-3) 0 var(--iq-space-4);
}
.bench-cta-inner p {
  font-size: var(--iq-body-lg);
  line-height: 1.55;
  color: var(--iq-text-body);
  margin: 0 0 var(--iq-space-6);
}
.bench-cta-actions {
  display: flex;
  gap: var(--iq-space-3);
  justify-content: center;
  flex-wrap: wrap;
}


/* ============================================================
   FOOTER
   ============================================================ */

.footer {
  background: var(--iq-text-primary);
  color: var(--iq-bg-primary);
  padding: var(--iq-space-7) 0 var(--iq-space-6);
}
.footer-inner {
  display: flex;
  flex-direction: column;
  gap: var(--iq-space-5);
}
.footer-brand-block {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--iq-space-4);
}
.footer-brand-block .nav-brand img {
  filter: brightness(0) invert(1);
}
.footer-tagline {
  max-width: 480px;
  font-size: var(--iq-body-sm);
  color: rgba(255, 255, 255, 0.7);
  line-height: 1.5;
}
.footer-cta-block { margin-top: var(--iq-space-2); }
.footer-meta {
  font-size: var(--iq-caption);
  color: rgba(255, 255, 255, 0.5);
  padding-top: var(--iq-space-4);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}


/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 900px) {
  .iq-container {
    padding-left: var(--iq-space-4, 1rem);
    padding-right: var(--iq-space-4, 1rem);
  }

  .bench-hero-grid { grid-template-columns: 1fr; gap: var(--iq-space-6); }
  .bench-datasets-grid { grid-template-columns: 1fr; }
  .bench-tiers-grid { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
  .bench-hero { padding-top: var(--iq-space-6); padding-bottom: var(--iq-section-y-mobile); }
  .bench-section { padding-top: var(--iq-section-y-mobile); padding-bottom: var(--iq-section-y-mobile); }
  .bench-section--cta { padding-top: var(--iq-section-y-mobile); padding-bottom: var(--iq-section-y-mobile); }
  .bench-use { grid-template-columns: 60px 1fr; gap: var(--iq-space-4); }
  .bench-use-num { font-size: 24px; }
  .bench-hero-copy h1 { font-size: 30px; }
  .bench-datasets-grid,
  .bench-tiers-grid {
    gap: var(--iq-space-4);
  }
  .bench-datasets-grid > *,
  .bench-tiers-grid > * {
    min-width: 0;
  }
  .bench-dataset-card,
  .bench-tier {
    padding: var(--iq-space-4);
  }
  .bench-dataset-status {
    flex-direction: column;
    align-items: flex-start;
  }
  .bench-dataset-range {
    line-height: 1.45;
  }
}

/* ============================================================
   ACCESS FORM (homepage)
   ============================================================ */

.bench-access-grid {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: var(--iq-space-8);
  align-items: start;
}
.bench-access-form label {
  display: flex;
  flex-direction: column;
  gap: var(--iq-space-2);
  font-size: var(--iq-body-sm);
  margin-bottom: var(--iq-space-4);
}
.bench-access-form input,
.bench-access-form select,
.bench-access-form textarea {
  font: inherit;
  padding: 0.65rem 0.75rem;
  border: 1px solid var(--iq-border, #d8dee9);
  border-radius: 6px;
  background: #fff;
}
.bench-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--iq-space-4);
}
.bench-hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
}
.bench-access-aside {
  font-size: var(--iq-body-sm);
  color: var(--iq-text-muted, #5c6570);
  line-height: 1.6;
}
.bench-access-aside p { margin: 0 0 var(--iq-space-3); }
.status { margin: var(--iq-space-3) 0; font-size: var(--iq-body-sm); }
.status.success { color: #0d6a3a; }
.status.error { color: #b42318; }

/* ============================================================
   LOGIN / SET PASSWORD
   ============================================================ */

.bench-login-page {
  display: flex;
  justify-content: center;
  padding-top: var(--iq-space-7);
}
.bench-login-card {
  width: min(480px, 100%);
  padding: var(--iq-space-6);
  background: #fff;
  border: 1px solid var(--iq-border, #d8dee9);
  border-radius: 8px;
}
.bench-login-card .bench-page-head {
  margin-bottom: var(--iq-space-5);
}
.bench-login-form {
  margin-top: var(--iq-space-4);
}
.bench-login-form .iq-btn {
  margin-top: var(--iq-space-2);
}
.bench-login-forgot {
  margin: calc(-1 * var(--iq-space-2)) 0 var(--iq-space-2);
  font-size: var(--iq-body-sm);
  text-align: right;
}
.bench-login-forgot a {
  color: var(--iq-accent, #0d6efd);
  text-decoration: underline;
  text-decoration-thickness: 0.5px;
  text-underline-offset: 3px;
}
.bench-login-actions {
  margin-top: var(--iq-space-4);
}
.bench-login-fine {
  margin: var(--iq-space-5) 0 0;
  font-size: var(--iq-caption, 0.875rem);
  line-height: 1.55;
  color: var(--iq-text-muted, #5c6570);
}

/* ============================================================
   BENCHMARK BROWSE PAGES (PHP templates)
   ============================================================ */

.bench-dataset-nav {
  position: sticky;
  top: var(--nav-offset, 72px);
  z-index: 45;
  background: var(--iq-bg-secondary, #f0f2f5);
  border-bottom: 1px solid var(--iq-border, #d8dee9);
  padding-left: 1em;
}
.bench-dataset-nav-inner {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--iq-space-3) var(--iq-space-5);
  padding: var(--iq-space-3) 0;
  font-size: var(--iq-body-sm);
}
.bench-dataset-nav-label {
  font-weight: 600;
  color: var(--iq-text-muted, #5c6570);
  letter-spacing: 0.02em;
  text-transform: uppercase;
  font-size: var(--iq-caption);
}
.bench-dataset-nav a {
  color: var(--iq-text, #1a1f26);
  text-decoration: none;
  padding: 0.2rem 0;
  border-bottom: 2px solid transparent;
}
.bench-dataset-nav a:hover { color: var(--iq-accent, #0d6efd); }
.bench-dataset-nav a.is-active {
  color: var(--iq-accent, #0d6efd);
  border-bottom-color: var(--iq-accent, #0d6efd);
  font-weight: 600;
}
.bench-page-content {
  padding-top: var(--iq-space-8);
  padding-bottom: var(--iq-space-10);
}
@media (max-width: 900px) {
  .bench-page-content {
    padding-top: var(--iq-space-6);
    padding-bottom: var(--iq-space-8);
  }
  .bench-page-head h1 {
    font-size: clamp(1.75rem, 7vw, 2.25rem);
    line-height: 1.2;
  }
  .bench-prose--article {
    overflow-wrap: anywhere;
  }
}
@media (min-width: 1200px) {
  .iq-container.bench-page-content {
    max-width: min(1440px, 96vw);
  }
}
.bench-account-actions {
  margin-top: var(--iq-space-6);
  font-size: var(--iq-body-sm);
}
.bench-page-head { margin-bottom: var(--iq-space-6); }
.bench-page-head h1 { margin: var(--iq-space-2) 0; }
.bench-lede { color: var(--iq-text-muted, #5c6570); max-width: 60ch; }

/* Microstate page — breadcrumb + compact 3-column identity row */
.bench-microstate-crumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.5rem;
  margin: 0 0 var(--iq-space-4);
  font-size: var(--iq-body-sm);
  color: var(--iq-text-muted, #5c6570);
}
.bench-microstate-crumb a {
  color: var(--iq-accent);
  text-decoration: underline;
  text-decoration-thickness: 0.5px;
  text-underline-offset: 3px;
}
.bench-microstate-crumb a:hover {
  color: var(--iq-accent-hover);
}
.bench-microstate-crumb-sep {
  color: var(--iq-text-muted, #5c6570);
  user-select: none;
}
.bench-microstate-crumb-current {
  color: var(--iq-text, #1a1f26);
}
.bench-microstate-crumb-current code {
  font-size: 0.95em;
}
.bench-microstate-identity {
  position: relative;
  margin-bottom: var(--iq-space-6);
  padding: var(--iq-space-4) var(--iq-space-5);
  background: #fff;
  border: 1px solid var(--iq-border, #d8dee9);
  border-radius: 8px;
}
.bench-microstate-identity-actions {
  position: absolute;
  top: var(--iq-space-4);
  right: var(--iq-space-5);
}
.bench-microstate-identity-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--iq-space-5) var(--iq-space-6);
  padding-right: min(12rem, 28%);
}
.bench-microstate-identity-col {
  margin: 0;
  font-size: var(--iq-body-sm);
}
.bench-microstate-identity-col dt {
  margin: 0 0 0.15rem;
  font-weight: 600;
  color: var(--iq-text-muted, #5c6570);
}
.bench-microstate-identity-col dd {
  margin: 0 0 var(--iq-space-3);
  font-family: ui-monospace, monospace;
  word-break: break-all;
}
.bench-microstate-identity-col dd:last-child {
  margin-bottom: 0;
}
.bench-microstate-identity-note {
  margin: var(--iq-space-4) 0 0;
  padding-top: var(--iq-space-3);
  border-top: 1px solid var(--iq-border, #e8ecf1);
  font-size: 0.8rem;
  line-height: 1.55;
  color: var(--iq-text-muted, #5c6570);
}
.bench-microstate-identity-note strong {
  color: var(--iq-text, #1a1f26);
  font-weight: 600;
}
.bench-microstate-identity + .bench-microstate-context,
.bench-microstate-identity + .bench-viewer-embed {
  margin-top: 0;
}
.bench-microstate-context + .bench-viewer-embed {
  margin-top: 0;
}
.bench-microstate-context {
  margin-bottom: var(--iq-space-5);
  padding: var(--iq-space-4) var(--iq-space-5);
  background: #fff;
  border: 1px solid var(--iq-border, #d8dee9);
  border-radius: 8px;
}
.bench-microstate-context-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--iq-space-3) var(--iq-space-5);
  margin: 0;
}
@media (min-width: 768px) {
  .bench-microstate-context-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
.bench-microstate-context-item {
  min-width: 0;
}
.bench-microstate-context-item dt {
  margin: 0 0 0.15rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--iq-text-muted, #5c6570);
}
.bench-microstate-context-item dd {
  margin: 0;
  font-size: var(--iq-body-sm);
  font-variant-numeric: tabular-nums;
  word-break: break-word;
}

/* Catalog metadata above lattice preview */
.bench-catalog-meta {
  margin-bottom: var(--iq-space-6);
}
.bench-catalog-meta-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--iq-space-5);
}
.bench-catalog-meta-block {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.35rem 1.25rem;
  margin: 0;
  padding: var(--iq-space-4) var(--iq-space-5);
  background: #fff;
  border: 1px solid var(--iq-border, #d8dee9);
  border-radius: 8px;
  font-size: var(--iq-body-sm);
}
.bench-catalog-meta-block dt {
  margin: 0;
  font-weight: 600;
  color: var(--iq-text-muted, #5c6570);
}
.bench-catalog-meta-block dd {
  margin: 0;
  font-family: ui-monospace, monospace;
  word-break: break-word;
}
.bench-catalog-meta-note {
  margin: var(--iq-space-3) 0 0;
  font-size: 0.8rem;
  line-height: 1.55;
  color: var(--iq-text-muted, #5c6570);
  max-width: 52rem;
}
.bench-catalog-meta-note strong {
  color: var(--iq-text, #1a1f26);
}

.bench-panel {
  background: #fff;
  border: 1px solid var(--iq-border, #d8dee9);
  border-radius: 8px;
  padding: var(--iq-space-5);
  margin-bottom: var(--iq-space-5);
}
.bench-table { width: 100%; border-collapse: collapse; font-size: var(--iq-body-sm); }
.bench-table th,
.bench-table td {
  text-align: left;
  padding: 0.6rem 0.75rem;
  border-bottom: 1px solid var(--iq-border, #e8ecf1);
}
.bench-table th { font-weight: 600; color: var(--iq-text-muted, #5c6570); }
.bench-table th.bench-table-sortable a {
  color: inherit;
  text-decoration: none;
}
.bench-table th.bench-table-sortable a:hover,
.bench-table th.bench-table-sortable.is-sorted a {
  color: var(--iq-accent, #0d6efd);
}
.bench-table a { color: var(--iq-accent, #0d6efd); }
@media (max-width: 900px) {
  .bench-table-col--desktop {
    display: none;
  }
}
/* Microstate report (grouped observables, iqintel.io layout) */
.bench-report-intro {
  max-width: 42rem;
  margin-bottom: var(--iq-space-5);
}
.bench-report-intro h2 {
  margin: 0 0 var(--iq-space-3);
  font-size: 1.35rem;
}
.bench-report-intro p {
  margin: 0;
  color: var(--iq-text-muted, #5c6570);
  line-height: 1.55;
}
.bench-report-meta {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, auto) 1fr);
  gap: 0.35rem 1.5rem;
  margin: 0 0 var(--iq-space-6);
  padding: var(--iq-space-4) var(--iq-space-5);
  background: #fff;
  border: 1px solid var(--iq-border, #d8dee9);
  border-radius: 8px;
  font-size: var(--iq-body-sm);
}
.bench-report-meta dt {
  margin: 0;
  font-weight: 600;
  color: var(--iq-text-muted, #5c6570);
}
.bench-report-meta dd {
  margin: 0;
  font-family: ui-monospace, monospace;
}
.bench-report-group {
  margin-top: var(--iq-space-6);
}
.bench-report-group:first-of-type {
  margin-top: var(--iq-space-5);
}
.bench-report-group-label {
  display: block;
  margin-bottom: var(--iq-space-3);
  padding-bottom: var(--iq-space-2);
  border-bottom: 1px solid var(--iq-border, #d8dee9);
}
.bench-report-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: var(--iq-space-3);
}
@media (min-width: 1200px) {
  .bench-report-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .bench-report-card.is-wide {
    grid-column: 1 / -1;
  }
}
.bench-report-card {
  padding: var(--iq-space-4);
  background: #fff;
  border: 1px solid var(--iq-border, #d8dee9);
  border-radius: 6px;
  min-width: 0;
}
.bench-report-card.is-wide {
  grid-column: 1 / -1;
}
.bench-report-name {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.95rem;
  font-weight: 600;
  margin: 0 0 var(--iq-space-2);
  line-height: 1.35;
}
.bench-report-desc {
  font-size: 0.875rem;
  line-height: 1.5;
  color: var(--iq-text-muted, #5c6570);
  margin: 0 0 var(--iq-space-3);
}
.bench-report-value {
  font-family: ui-monospace, monospace;
  font-size: 1rem;
  font-weight: 500;
  color: var(--iq-text, #1a1f26);
  margin: 0;
  word-break: break-word;
}
.bench-obs-value--bitstring.bench-report-value {
  white-space: pre-wrap;
  word-break: break-all;
  overflow-wrap: anywhere;
  line-height: 1.5;
  font-weight: 400;
  font-size: clamp(0.7rem, 2.2vw, 0.85rem);
  max-height: 14rem;
  overflow-x: hidden;
  overflow-y: auto;
  padding: 0.65rem 0.85rem;
  background: var(--iq-bg-muted, #f4f6f8);
  border: 1px solid var(--iq-border, #e8ecf1);
  border-radius: 4px;
  -webkit-overflow-scrolling: touch;
}
.bench-report-note {
  margin-top: var(--iq-space-6);
  padding: var(--iq-space-4);
  background: #fff;
  border-left: 3px solid var(--iq-accent, #0d6efd);
  max-width: 42rem;
  font-size: var(--iq-body-sm);
  color: var(--iq-text-muted, #5c6570);
  line-height: 1.55;
}
.bench-report-note p { margin: 0; }

/* Microstate report — grid / table view tabs */
.bench-report-views {
  margin-top: var(--iq-space-5);
}
.bench-report-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: var(--iq-space-2);
  margin-bottom: var(--iq-space-5);
  padding-bottom: var(--iq-space-3);
  border-bottom: 1px solid var(--iq-border, #d8dee9);
}
.bench-report-tab {
  appearance: none;
  font: inherit;
  font-size: var(--iq-body-sm);
  font-weight: 500;
  color: var(--iq-text-muted, #5c6570);
  background: #fff;
  border: 1px solid var(--iq-border, #d8dee9);
  border-radius: 6px;
  padding: 0.45rem 0.85rem;
  cursor: pointer;
  transition: color 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}
.bench-report-tab:hover {
  color: var(--iq-accent, #0d6efd);
  border-color: var(--iq-accent, #0d6efd);
}
.bench-report-tab.is-active {
  color: var(--iq-accent, #0d6efd);
  border-color: var(--iq-accent, #0d6efd);
  background: var(--iq-bg-tint, #eef4ff);
}
.bench-report-view[hidden] {
  display: none;
}
.bench-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.bench-seam-playlist {
  margin-top: var(--iq-space-6);
}
.bench-seam-playlist .bench-section-header {
  margin-bottom: var(--iq-space-4);
}
.bench-seam-frames tr.is-li-violation td {
  background: rgba(226, 75, 74, 0.12);
}
.bench-seam-frames tr.is-li-violation td:nth-child(5) {
  color: #c0392b;
  font-weight: 600;
}
.bench-report-table th,
.bench-report-table td {
  vertical-align: top;
}
.bench-report-table-group {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--iq-text-muted, #5c6570);
  white-space: nowrap;
}
.bench-report-table-name code {
  font-size: 0.85rem;
  font-weight: 600;
}
.bench-report-table-desc {
  color: var(--iq-text-muted, #5c6570);
  line-height: 1.5;
  min-width: 12rem;
}
.bench-report-table-cell {
  min-width: 10rem;
  max-width: 28rem;
}
.bench-report-table-value {
  font-family: ui-monospace, monospace;
  font-size: 0.9rem;
  font-weight: 500;
  word-break: break-word;
  margin: 0;
}
.bench-obs-value--bitstring.bench-report-table-value {
  white-space: pre-wrap;
  word-break: break-all;
  overflow-wrap: anywhere;
  font-weight: 400;
  font-size: clamp(0.68rem, 2vw, 0.8rem);
  max-height: 10rem;
  overflow: auto;
  padding: 0.5rem 0.65rem;
  background: var(--iq-bg-muted, #f4f6f8);
  border: 1px solid var(--iq-border, #e8ecf1);
  border-radius: 4px;
}
.bench-obs-value--bitstring-table.bench-report-table-value {
  white-space: normal;
  word-break: break-all;
  overflow-wrap: anywhere;
  line-height: 1;
  letter-spacing: 0;
  max-width: 60ch;
  padding: 0.35rem 0.5rem;
}

.bench-actions { display: flex; flex-wrap: wrap; gap: var(--iq-space-3); margin-bottom: var(--iq-space-5); }
.bench-plot { max-width: 100%; height: auto; border-radius: 6px; border: 1px solid var(--iq-border, #e8ecf1); }
.bench-muted { color: var(--iq-text-muted, #5c6570); font-size: var(--iq-body-sm); }
.bench-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: var(--iq-space-5);
  margin: 2em;
}
.bench-card {
  display: block;
  background: #fff;
  border: 1px solid var(--iq-border, #d8dee9);
  border-radius: 8px;
  padding: var(--iq-space-5);
  text-decoration: none;
  color: inherit;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.bench-card:hover { border-color: var(--iq-accent, #0d6efd); box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06); }
.bench-card.is-disabled { opacity: 0.55; pointer-events: none; }
.bench-card h2 { margin: 0 0 var(--iq-space-2); font-size: 1.15rem; }
.bench-card p { margin: 0; color: var(--iq-text-muted, #5c6570); font-size: var(--iq-body-sm); }
.bench-card-cta { display: inline-block; margin-top: var(--iq-space-4); font-weight: 600; color: var(--iq-accent, #0d6efd); }

/* Inline microstate lattice embed (replaces legacy PNG plot) */
.bench-viewer-embed {
  margin-top: 0;
  margin-bottom: var(--iq-space-7);
  padding: var(--iq-space-4);
  background: #fff;
  border: 1px solid var(--iq-border, #d8dee9);
  border-radius: 8px;
  max-width: 100%;
  overflow: hidden;
}
.bench-viewer-embed-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--iq-space-3);
  margin-bottom: var(--iq-space-4);
}
.bench-viewer-embed-head h2 { margin: 0; font-size: 1.25rem; }
.bench-viewer-embed-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--iq-space-3);
  max-width: 100%;
}
.bench-viewer-embed-grid--microstate {
  --embed-primary-h: clamp(160px, 24vw, 240px);
  --embed-short-h: clamp(96px, 12vw, 132px);
}
@media (min-width: 900px) {
  .bench-viewer-embed-grid,
  .bench-viewer-embed-grid--microstate {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  /* Microstate embed: lattice 2 rows tall; corr/hist under heatmaps; metrics spans 2 cols */
  .bench-viewer-embed-grid--microstate > .bench-viewer-embed-cell--lattice {
    grid-column: 1;
    grid-row: 1 / span 2;
    align-self: stretch;
  }
  .bench-viewer-embed-grid--microstate > .bench-viewer-embed-cell--lattice .bench-viewer-lattice-wrap {
    flex: 1 1 auto;
    aspect-ratio: auto;
    min-height: 0;
  }
  .bench-viewer-embed-grid--microstate > .bench-viewer-embed-cell--mid {
    grid-column: 2;
    grid-row: 1;
  }
  .bench-viewer-embed-grid--microstate > .bench-viewer-embed-cell--bits {
    grid-column: 3;
    grid-row: 1;
  }
  .bench-viewer-embed-grid--microstate > .bench-viewer-embed-cell--corr {
    grid-column: 2;
    grid-row: 2;
  }
  .bench-viewer-embed-grid--microstate > .bench-viewer-embed-cell--hist {
    grid-column: 3;
    grid-row: 2;
  }
  .bench-viewer-embed-grid--microstate > .bench-viewer-embed-cell--spin {
    grid-column: 1;
    grid-row: 3;
  }
  .bench-viewer-embed-grid--microstate > .bench-viewer-embed-cell--prof {
    grid-column: 2;
    grid-row: 3;
  }
  .bench-viewer-embed-grid--microstate > .bench-viewer-embed-cell--energy {
    grid-column: 3;
    grid-row: 3;
  }
  .bench-viewer-embed-grid--microstate > .bench-viewer-embed-cell--metrics {
    grid-column: 1 / span 2;
    grid-row: 4;
  }
  .bench-viewer-embed-cell--span-2 {
    grid-column: span 2;
  }
  .bench-viewer-embed-cell--span-3 {
    grid-column: 1 / -1;
  }
}
.bench-viewer-embed-cell {
  display: flex;
  flex-direction: column;
  min-width: 0;
  max-width: 100%;
  padding: 0.55rem 0.65rem;
  background: var(--iq-bg-muted, #f4f6f8);
  border: 1px solid var(--iq-border, #e8ecf1);
  border-radius: 6px;
}
.bench-viewer-embed-cell-head,
.bench-viewer-embed-cell-title {
  flex-shrink: 0;
  margin: 0 0 0.35rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--iq-text-muted, #5c6570);
  letter-spacing: 0.02em;
}
.bench-viewer-embed-cell-head {
  margin-bottom: 0.35rem;
}
.bench-viewer-embed-cell-body {
  position: relative;
  width: 100%;
  min-height: 0;
}
.bench-viewer-embed-cell-body--primary {
  height: var(--embed-primary-h, 220px);
  max-height: var(--embed-primary-h, 220px);
}
.bench-viewer-embed-grid--microstate .bench-viewer-embed-cell-body.dash-embed-plot:not(.bench-viewer-embed-cell-body--short) {
  height: var(--embed-primary-h, clamp(160px, 24vw, 240px));
  max-height: var(--embed-primary-h, clamp(160px, 24vw, 240px));
}
.bench-viewer-embed-grid--microstate .bench-viewer-embed-cell-body.dash-embed-plot.bench-viewer-embed-cell-body--short {
  height: var(--embed-short-h, clamp(96px, 12vw, 132px));
  max-height: var(--embed-short-h, clamp(96px, 12vw, 132px));
}
.bench-viewer-embed-cell-body--short {
  height: var(--embed-short-h, 120px);
  max-height: var(--embed-short-h, 120px);
}
.bench-viewer-embed-cell-body--metrics {
  height: auto;
  max-height: none;
}
.bench-viewer-embed-cell--lattice {
  display: flex;
  flex-direction: column;
  min-height: 0;
}
.bench-viewer-embed-cell--lattice .bench-viewer-embed-cell-toolbar {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  margin-bottom: 0.35rem;
  min-width: 0;
  flex-shrink: 0;
}
.bench-viewer-embed-cell--lattice .bench-viewer-embed-cell-toolbar .bench-viewer-embed-cell-title {
  margin: 0;
  flex-shrink: 0;
  line-height: 1.5;
}
.bench-viewer-embed-cell--lattice .bench-viewer-embed-cell-toolbar .bench-viewer-mode-bar {
  flex: 1;
  min-width: 0;
  margin: 0;
}
.bench-viewer-embed-cell--lattice .bench-viewer-lattice-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: #0a0e14;
  border-radius: 4px;
}
.bench-viewer-embed-cell--lattice .bench-viewer-lattice-wrap #embed-lattice-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.bench-viewer-embed-cell--lattice .bench-viewer-lattice-wrap #embed-lattice-canvas canvas {
  display: block;
  width: 100% !important;
  height: 100% !important;
}
.bench-viewer-embed-cell--lattice .bench-viewer-status {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  padding: 0.5rem;
  text-align: center;
  pointer-events: none;
}
.dash-embed-plot {
  position: relative;
  overflow: hidden;
}
.bench-viewer-embed-cell--energy .bench-viewer-embed-cell-body {
  overflow-y: auto;
}
.bench-viewer-embed .soc-panel-head {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 0.5rem;
}
.bench-viewer-embed .soc-panel-title {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--iq-text-muted, #5c6570);
}
.bench-viewer-embed .soc-head-bar {
  min-width: 0;
}
.bench-viewer-embed .soc-head-pct {
  font-size: 0.85rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--iq-text, #1a1f26);
}
.bench-viewer-embed .band-badge {
  display: inline-block;
  padding: 0.1rem 0.45rem;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 600;
}
.bench-viewer-embed .band-badge.band-ok {
  background: #e6f4ef;
  color: #0f6e56;
  border: 1px solid #9fd4c0;
}
.bench-viewer-embed .band-badge.band-warn {
  background: #fef6e8;
  color: #9a6700;
  border: 1px solid #e8c98a;
}
.bench-viewer-embed .band-badge.band-muted {
  background: #eef1f5;
  color: #5c6570;
  border: 1px solid #d8dee9;
}
.dash-embed-plot canvas {
  position: absolute;
  inset: 0;
  width: 100% !important;
  height: 100% !important;
  display: block;
}
.bench-viewer-mode-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}
.bench-viewer-embed-cell--lattice .bench-viewer-mode-bar .mode-btn {
  font-size: 0.68rem;
  padding: 2px 6px;
  line-height: 1.25;
}
.bench-viewer-embed .player-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  padding: 8px 10px;
  background: var(--iq-bg-muted, #f4f6f8);
  border: 1px solid var(--iq-border, #e8ecf1);
  border-radius: 6px;
}
.bench-viewer-embed .player-bar .player-slider {
  flex: 1;
  min-width: 80px;
}
.bench-viewer-embed .player-bar .player-fps {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.75rem;
  color: var(--iq-text-muted, #5c6570);
}
.bench-viewer-embed .player-bar .player-fps select {
  font-size: 0.75rem;
  padding: 3px 6px;
  border: 1px solid var(--iq-border, #d8dee9);
  border-radius: 4px;
  background: #fff;
}
.bench-viewer-embed .player-bar .btn {
  font-size: 0.75rem;
  padding: 4px 10px;
  border: 1px solid var(--iq-border, #d8dee9);
  border-radius: 4px;
  background: #fff;
  cursor: pointer;
}
.bench-viewer-embed .player-bar .btn:hover:not(:disabled) {
  border-color: var(--iq-accent, #0d6efd);
  color: var(--iq-accent, #0d6efd);
}
.bench-viewer-embed .player-bar .btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
.bench-viewer-embed .player-bar .player-label {
  font-size: 0.75rem;
  font-variant-numeric: tabular-nums;
  margin-left: auto;
  color: var(--iq-text-muted, #5c6570);
}
.bench-viewer-embed .player-bar .player-hint {
  font-size: 0.68rem;
  color: var(--iq-text-muted, #5c6570);
}
.bench-viewer-embed .mode-btn {
  font-size: 0.75rem;
  padding: 4px 8px;
  border: 1px solid var(--iq-border, #d8dee9);
  border-radius: 4px;
  background: #fff;
  cursor: pointer;
}
.bench-viewer-embed .mode-btn.is-active {
  border-color: var(--iq-accent, #0d6efd);
  color: var(--iq-accent, #0d6efd);
}
.bench-viewer-embed .metrics-grid--embed {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.35rem var(--iq-space-4);
}
@media (min-width: 900px) {
  .bench-viewer-embed .metrics-grid--embed {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
.bench-viewer-embed .metric-cell {
  display: grid;
  grid-template-columns: max-content minmax(0, max-content);
  column-gap: 0.5rem;
  align-items: baseline;
  justify-content: start;
  min-width: 0;
}
.bench-viewer-embed .metric-cell .k {
  color: var(--iq-text-muted, #5c6570);
  font-size: 0.75rem;
  white-space: nowrap;
}
.bench-viewer-embed .metric-cell .v {
  font-weight: 600;
  font-size: 0.75rem;
  font-variant-numeric: tabular-nums;
  word-break: break-word;
  text-align: left;
}
/* Light-theme dashboard panels inside embed (app.css is for full viewer only) */
.bench-viewer-embed .panel {
  background: var(--iq-bg-muted, #f4f6f8);
  border: 1px solid var(--iq-border, #e8ecf1);
  border-radius: 6px;
  padding: 0.65rem 0.75rem;
  margin-bottom: 0.65rem;
}
.bench-viewer-embed .panel h3 {
  margin: 0 0 0.5rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--iq-text-muted, #5c6570);
  letter-spacing: 0.02em;
}
.bench-viewer-embed .panel canvas { width: 100%; display: block; }
.bench-viewer-embed .grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.65rem;
}
.bench-viewer-embed .metrics-grid {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.2rem 0.75rem;
  font-variant-numeric: tabular-nums;
}
.bench-viewer-embed .metrics-grid .k {
  color: var(--iq-text-muted, #5c6570);
  font-size: 0.75rem;
}
.bench-viewer-embed .metrics-grid .v {
  font-weight: 600;
  text-align: right;
  font-size: 0.75rem;
  color: var(--iq-text, #1a1f26);
}
.bench-viewer-embed .energy-row {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  margin: 0.25rem 0;
  font-size: 0.75rem;
}
.bench-viewer-embed .energy-row .lab { color: var(--iq-text-muted, #5c6570); min-width: 7rem; }
.bench-viewer-embed .energy-row .val { font-weight: 700; color: var(--iq-text, #1a1f26); }
.bench-viewer-embed .badge {
  display: inline-block;
  padding: 0.1rem 0.5rem;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 600;
}
.bench-viewer-embed .badge.validated {
  background: #e6f4ef;
  color: #0f6e56;
  border: 1px solid #9fd4c0;
}
.bench-viewer-embed .badge.tail {
  background: #fef6e8;
  color: #9a6700;
  border: 1px solid #e8c98a;
}
.bench-viewer-embed .disclosure {
  color: #9a6700;
  font-size: 0.7rem;
  margin-top: 0.35rem;
  line-height: 1.35;
}
.bench-viewer-embed .soc-bar-bg {
  background: var(--iq-border, #e8ecf1);
  border-radius: 4px;
  height: 12px;
  overflow: hidden;
  margin: 0.35rem 0;
}
.bench-viewer-embed .soc-bar-bg--compact {
  height: 10px;
  margin: 0;
}
.bench-viewer-embed .soc-bar-fill { height: 100%; }
.bench-viewer-embed .soc-line {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
  margin: 0.15rem 0;
  color: var(--iq-text, #1a1f26);
}
.bench-viewer-embed .soc-line .muted { color: var(--iq-text-muted, #5c6570); }
.bench-viewer-status {
  position: absolute;
  left: 12px;
  bottom: 12px;
  margin: 0;
  color: #c8d0dc;
}

@media (max-width: 900px) {
  .bench-access-grid { grid-template-columns: 1fr; }
  .bench-form-row { grid-template-columns: 1fr; }
}

@media (max-width: 900px) {
  .bench-microstate-identity-grid {
    grid-template-columns: 1fr;
  }
  .bench-microstate-identity-actions {
    position: static;
    margin-bottom: var(--iq-space-4);
  }
  .bench-microstate-identity-grid {
    padding-right: 0;
  }
  .bench-catalog-meta-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .bench-report-meta {
    grid-template-columns: 1fr;
  }
  .bench-report-grid {
    grid-template-columns: 1fr;
  }
  .bench-obs-value--bitstring.bench-report-value {
    max-height: 10rem;
    font-size: 0.72rem;
  }
}
