:root {
  --ecosystem-page-bg: #ffffff;
  --ecosystem-surface: #ffffff;
  --ecosystem-soft-surface: #f8fafc;
  --ecosystem-border: #d8dee8;
  --ecosystem-ink: #18212f;
  --ecosystem-muted: #5b6472;
  --ecosystem-footer: #111827;
  --ecosystem-shadow: 0 10px 25px rgba(15, 23, 42, 0.08);
  --ecosystem-radius: 8px;
}

html { background: var(--ecosystem-page-bg); }

body {
  color: var(--ecosystem-ink);
  background: var(--ecosystem-page-bg) !important;
  accent-color: var(--service-primary);
}

main,
.section { background: transparent; }

.navbar,
nav {
  background: var(--ecosystem-surface);
  color: var(--ecosystem-ink);
  border-bottom: 1px solid var(--ecosystem-border);
}

.nav-link,
.navlinks a,
a { color: inherit; }

.nav-container,
.container,
.wrap {
  width: min(1200px, calc(100% - 40px));
  margin-inline: auto;
}

.logo,
.btn,
.button.primary,
.cta-button.primary {
  background: var(--service-primary);
  border-color: var(--service-primary);
  color: #ffffff;
}

.nav-btn,
.button,
.cta-button,
.btn-secondary {
  border-color: var(--ecosystem-border);
}

.card,
.cert-card,
.panel,
.auth-card,
.compliance-card,
.security-card,
.privacy-card,
.feature-card,
.usecase-card,
.pricing-card,
.module-card,
.dashboard-card,
.fusion-action-form,
.calibration-guide,
.calibration-results,
.calibration-diagnosis {
  background: var(--ecosystem-surface);
  color: var(--ecosystem-ink);
  border-color: var(--ecosystem-border);
  border-radius: var(--ecosystem-radius);
  box-shadow: var(--ecosystem-shadow);
}

.card p,
.cert-card p,
.panel p,
.section-subtitle,
.hero-subtitle,
.lead,
.muted,
.footer-tagline {
  color: var(--ecosystem-muted);
}

.hero,
header.hero {
  background: var(--ecosystem-surface) !important;
  color: var(--ecosystem-ink) !important;
  border-bottom: 1px solid var(--ecosystem-border);
  padding-block: clamp(44px, 7vw, 78px);
}

.hero h1,
.hero h2,
.hero h3,
.hero p,
.hero .hero-title,
.hero .hero-subtitle {
  color: var(--ecosystem-ink) !important;
}

.hero .highlight,
.highlight,
.section-title i,
.card h3,
.cert-card h3,
.footer-col h4,
.kicker {
  color: var(--service-primary) !important;
}

.hero .badge,
.badge {
  color: var(--service-primary);
  background: color-mix(in srgb, var(--service-primary) 10%, #ffffff);
  border-color: color-mix(in srgb, var(--service-primary) 35%, transparent);
}

.hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 24px;
}

.stat {
  background: var(--ecosystem-soft-surface);
  border: 1px solid var(--ecosystem-border);
  border-radius: var(--ecosystem-radius);
  padding: 14px 18px;
  min-width: 128px;
}

.stat-number {
  color: var(--service-primary);
  font-weight: 800;
  font-size: 1.35rem;
}

.stat-label {
  color: var(--ecosystem-muted);
  font-size: 0.9rem;
}

.certificate-grid,
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
}

.cta-container,
.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 20px;
}

.band {
  background: linear-gradient(135deg, var(--service-primary) 0%, var(--service-secondary) 100%);
  color: #ffffff;
}

.band h1,
.band h2,
.band h3,
.band p { color: #ffffff; }

input,
select,
textarea {
  background: #ffffff;
  color: var(--ecosystem-ink);
  border-color: var(--ecosystem-border);
}

.footer,
footer {
  background: var(--ecosystem-footer);
  color: #f8fafc;
}

.footer a,
.footer-link,
.footer-col a,
footer a,
.footer-tagline { color: #d8dee8; }

body.dark-mode {
  --ecosystem-page-bg: #0f141c;
  --ecosystem-surface: #151b23;
  --ecosystem-soft-surface: #101923;
  --ecosystem-border: #334155;
  --ecosystem-ink: #f1f5f9;
  --ecosystem-muted: #cbd5e1;
  --ecosystem-footer: #090d14;
  --ecosystem-shadow: 0 12px 28px rgba(0, 0, 0, 0.36);
  background: var(--ecosystem-page-bg) !important;
  color: var(--ecosystem-ink);
}

body.dark-mode .navbar,
body.dark-mode nav,
body.dark-mode .hero,
body.dark-mode header.hero,
body.dark-mode .card,
body.dark-mode .cert-card,
body.dark-mode .panel,
body.dark-mode .auth-card,
body.dark-mode .compliance-card,
body.dark-mode .security-card,
body.dark-mode .privacy-card,
body.dark-mode .feature-card,
body.dark-mode .usecase-card,
body.dark-mode .pricing-card,
body.dark-mode .module-card,
body.dark-mode .dashboard-card,
body.dark-mode .fusion-action-form,
body.dark-mode .calibration-guide,
body.dark-mode .calibration-results,
body.dark-mode .calibration-diagnosis {
  background: var(--ecosystem-surface) !important;
  color: var(--ecosystem-ink) !important;
  border-color: var(--ecosystem-border);
  box-shadow: var(--ecosystem-shadow);
}

body.dark-mode main,
body.dark-mode .section {
  background: transparent;
  color: var(--ecosystem-ink);
}

body.dark-mode h1,
body.dark-mode h2,
body.dark-mode h3,
body.dark-mode h4,
body.dark-mode .section-title,
body.dark-mode .card h2,
body.dark-mode .card h3,
body.dark-mode .cert-card h3,
body.dark-mode .hero h1,
body.dark-mode .hero h2,
body.dark-mode .hero h3,
body.dark-mode .hero p,
body.dark-mode .hero .hero-title,
body.dark-mode .hero .hero-subtitle {
  color: var(--ecosystem-ink) !important;
}

body.dark-mode .highlight,
body.dark-mode .hero .highlight,
body.dark-mode .section-title i,
body.dark-mode .footer-col h4,
body.dark-mode .kicker {
  color: var(--service-accent) !important;
}

body.dark-mode p,
body.dark-mode li,
body.dark-mode label,
body.dark-mode .muted,
body.dark-mode .lead,
body.dark-mode .section-subtitle,
body.dark-mode .hero-subtitle,
body.dark-mode .footer-tagline,
body.dark-mode .footer-col a,
body.dark-mode .nav-link,
body.dark-mode .navlinks a {
  color: var(--ecosystem-muted);
}

body.dark-mode .hero .badge,
body.dark-mode .badge {
  color: var(--service-accent);
  background: color-mix(in srgb, var(--service-primary) 18%, #0f141c);
  border-color: var(--ecosystem-border);
}

body.dark-mode .band {
  background: linear-gradient(135deg, var(--service-secondary) 0%, #0f141c 100%);
  color: #ffffff;
}

body.dark-mode .band h1,
body.dark-mode .band h2,
body.dark-mode .band h3,
body.dark-mode .band p { color: #ffffff; }

body.dark-mode input,
body.dark-mode select,
body.dark-mode textarea,
body.dark-mode pre,
body.dark-mode code {
  background: #0f172a;
  color: var(--ecosystem-ink);
  border-color: var(--ecosystem-border);
}

body.dark-mode .btn,
body.dark-mode .button.primary,
body.dark-mode .cta-button.primary {
  background: var(--service-primary);
  color: #ffffff;
}

body.dark-mode .button,
body.dark-mode .cta-button,
body.dark-mode .nav-btn,
body.dark-mode .btn-secondary {
  background: #0f172a;
  color: var(--ecosystem-ink);
  border-color: var(--ecosystem-border);
}

body.dark-mode .footer,
body.dark-mode footer {
  background: var(--ecosystem-footer);
  color: #f8fafc;
}

/* Hero claim hierarchy */
.hero .hero-title {
  margin-bottom: 0;
}

.hero .hero-claim,
body.dark-mode .hero .hero-claim {
  color: var(--ecosystem-ink) !important;
  font-size: clamp(1.65rem, 3.2vw, 3.1rem);
  font-weight: 850;
  line-height: 1.08;
  max-width: 980px;
  margin: 8px 0 6px;
}

.hero .hero-kicker,
body.dark-mode .hero .hero-kicker {
  color: var(--service-primary) !important;
  font-size: clamp(1rem, 1.6vw, 1.3rem);
  font-weight: 700;
  line-height: 1.3;
  margin: 0 0 14px;
}

.hero .hero-claim + .hero-kicker {
  margin-top: 0;
}

/* SITANO official SVG mark: geometry is fixed in /static/brand assets. */
.nav-brand {
  min-width: 0;
  flex-shrink: 0;
}

.logo {
  width: 46px !important;
  min-width: 46px;
  height: 46px;
  padding: 0;
  box-sizing: border-box;
  display: inline-block;
  flex: 0 0 46px;
  overflow: hidden;
  color: transparent !important;
  font-size: 0;
  line-height: 0;
  text-indent: -9999px;
  background-color: transparent !important;
  background-image: url('/static/brand/sitano-nav-symbol.svg?v=3.0.1');
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  border: 0;
  border-radius: 0;
}

.brand-name {
  min-width: 0;
  line-height: 1.15;
}

@media (max-width: 640px) {
  .nav-brand {
    gap: 8px;
  }

  .logo {
    width: 42px !important;
    min-width: 42px;
    height: 42px;
    flex-basis: 42px;
    padding: 0;
    font-size: 0;
  }

  .brand-name {
    font-size: 0.95rem;
  }
}

/* SITANO master horizontal logo override. Use fixed SVG assets, never redraw. */
.nav-brand .logo {
  width: 154px !important;
  min-width: 154px !important;
  height: 44px !important;
  flex: 0 0 154px !important;
  background-image: url('/static/brand/sitano-master-horizontal-small.svg?v=3.0.1') !important;
  background-size: contain !important;
  background-position: center left !important;
  background-repeat: no-repeat !important;
  background-color: transparent !important;
  border: 0 !important;
  border-radius: 0 !important;
  color: transparent !important;
  font-size: 0 !important;
  line-height: 0 !important;
  text-indent: -9999px !important;
}

.footer .nav-brand .logo,
footer .nav-brand .logo,
.footer-brand .logo {
  background-image: url('/static/brand/sitano-white.svg?v=3.0.1') !important;
  filter: none !important;
}

.footer .brand-name,
footer .brand-name,
.footer-brand .brand-name {
  color: #f8fafc !important;
}

@media (max-width: 640px) {
  .nav-brand .logo {
    width: 128px !important;
    min-width: 128px !important;
    height: 42px !important;
    flex-basis: 128px !important;
  }
}

/* SITANO master horizontal logo alignment and monochrome mode. */
.nav-brand {
  display: inline-flex !important;
  align-items: center !important;
  gap: 2px !important;
  min-width: 0;
  flex-shrink: 0;
}

.nav-brand .logo {
  width: 132px !important;
  min-width: 132px !important;
  height: 42px !important;
  flex: 0 0 132px !important;
  align-self: center !important;
  background-image: url('/static/brand/sitano-master-horizontal-small.svg?v=3.0.1') !important;
  background-size: contain !important;
  background-position: center left !important;
  background-repeat: no-repeat !important;
  background-color: transparent !important;
  border: 0 !important;
  border-radius: 0 !important;
  color: transparent !important;
  font-size: 0 !important;
  line-height: 0 !important;
  text-indent: -9999px !important;
}

.nav-brand .brand-name {
  display: inline-flex !important;
  align-items: center !important;
  line-height: 1 !important;
  margin: 0 !important;
}

body.dark-mode .navbar .nav-brand .logo,
body.dark-mode nav .nav-brand .logo {
  background-image: url('/static/brand/sitano-silver.svg?v=3.0.1') !important;
}

.footer .nav-brand,
footer .nav-brand,
.footer-brand {
  align-items: center !important;
  gap: 2px !important;
}

.footer .nav-brand .logo,
footer .nav-brand .logo,
.footer-brand .logo {
  background-image: url('/static/brand/sitano-silver.svg?v=3.0.1') !important;
  filter: none !important;
}

.footer .brand-name,
footer .brand-name,
.footer-brand .brand-name {
  color: #f8fafc !important;
}

@media (max-width: 640px) {
  .nav-brand {
    gap: 2px !important;
  }

  .nav-brand .logo {
    width: 126px !important;
    min-width: 126px !important;
    height: 47px !important;
    flex-basis: 126px !important;
  }
}

/* SITANO logo middle alignment correction. */
.navbar .nav-brand,
nav .nav-brand,
.footer .nav-brand,
footer .nav-brand,
.footer-brand {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 2px !important;
  line-height: 1 !important;
}

.navbar .nav-brand .logo,
nav .nav-brand .logo,
.footer .nav-brand .logo,
footer .nav-brand .logo,
.footer-brand .logo {
  display: block !important;
  align-self: center !important;
  margin: 0 !important;
  transform: translateY(0) !important;
  background-position: center center !important;
}

.navbar .nav-brand .brand-name,
nav .nav-brand .brand-name,
.footer .nav-brand .brand-name,
footer .nav-brand .brand-name,
.footer-brand .brand-name {
  display: inline-flex !important;
  align-items: center !important;
  align-self: center !important;
  margin: 0 !important;
  padding: 0 !important;
  line-height: 1 !important;
}

@media (max-width: 640px) {
  .navbar .nav-brand,
  nav .nav-brand,
  .footer .nav-brand,
  footer .nav-brand,
  .footer-brand {
    gap: 2px !important;
  }
}

/* SITANO logo same-axis correction. */
.navbar .nav-brand,
nav .nav-brand,
.footer .nav-brand,
footer .nav-brand,
.footer-brand {
  display: inline-flex !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 2px !important;
  line-height: 1 !important;
  vertical-align: middle !important;
}

.navbar .nav-brand .logo,
nav .nav-brand .logo,
.footer .nav-brand .logo,
footer .nav-brand .logo,
.footer-brand .logo,
.navbar .nav-brand .brand-name,
nav .nav-brand .brand-name,
.footer .nav-brand .brand-name,
footer .nav-brand .brand-name,
.footer-brand .brand-name {
  align-self: center !important;
  margin-top: 0 !important;
  margin-bottom: 0 !important;
  vertical-align: middle !important;
}

/* SITANO header/footer optical alignment correction. */
.navbar .nav-container,
nav .nav-container {
  display: flex !important;
  align-items: center !important;
}

.navbar .nav-links,
nav .nav-links {
  display: flex !important;
  align-items: center !important;
}

.navbar .nav-brand,
nav .nav-brand {
  display: inline-flex !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 0 !important;
  line-height: 1 !important;
  min-height: 44px !important;
}

.navbar .nav-brand .logo,
nav .nav-brand .logo {
  width: 142px !important;
  min-width: 142px !important;
  height: 47px !important;
  flex: 0 0 142px !important;
  align-self: center !important;
  margin: 2px -8px 0 0 !important;
  background-position: center center !important;
  background-size: contain !important;
}

.navbar .nav-brand .brand-name,
nav .nav-brand .brand-name {
  display: inline-flex !important;
  align-items: center !important;
  align-self: center !important;
  margin: 0 !important;
  padding: 0 !important;
  line-height: 1 !important;
}

.navbar .nav-brand .brand-copy,
nav .nav-brand .brand-copy {
  display: inline-flex !important;
  flex-direction: column !important;
  justify-content: center !important;
  align-items: flex-start !important;
  gap: 4px !important;
  min-width: 0 !important;
  line-height: 1 !important;
}

.navbar .nav-brand .brand-tagline,
nav .nav-brand .brand-tagline {
  display: block !important;
  color: rgba(15, 23, 42, 0.62) !important;
  font-size: 0.68rem !important;
  font-weight: 600 !important;
  line-height: 1.1 !important;
  white-space: nowrap !important;
}

body.dark-mode .navbar .nav-brand .brand-tagline,
body.dark-mode nav .nav-brand .brand-tagline {
  color: rgba(226, 232, 240, 0.72) !important;
}

@media (max-width: 900px) {
  .navbar .nav-brand .brand-tagline,
  nav .nav-brand .brand-tagline {
    display: none !important;
  }
}

.footer .footer-grid,
footer .footer-grid {
  align-items: flex-start !important;
}

.footer .nav-brand,
footer .nav-brand,
.footer-brand {
  display: inline-flex !important;
  flex-direction: row !important;
  align-items: flex-start !important;
  justify-content: flex-start !important;
  gap: 0 !important;
  line-height: 1 !important;
  margin-top: 0 !important;
}

.footer .nav-brand .logo,
footer .nav-brand .logo,
.footer-brand .logo {
  width: 142px !important;
  min-width: 142px !important;
  height: 47px !important;
  flex: 0 0 142px !important;
  align-self: center !important;
  margin: -4px -8px 0 0 !important;
  background-position: center center !important;
  background-size: contain !important;
}

.footer .nav-brand .brand-name,
footer .nav-brand .brand-name,
.footer-brand .brand-name {
  display: inline-flex !important;
  align-items: flex-start !important;
  align-self: flex-start !important;
  margin: 0 !important;
  padding: 0 !important;
  line-height: 1 !important;
}

@media (max-width: 640px) {
  .navbar .nav-brand .logo,
  nav .nav-brand .logo,
  .footer .nav-brand .logo,
  footer .nav-brand .logo,
  .footer-brand .logo {
    width: 126px !important;
    min-width: 126px !important;
    height: 42px !important;
    flex-basis: 126px !important;
    margin-right: -8px !important;
  }
}

/* SITANO subtle logo vertical reading adjustment. */
.navbar .nav-brand .logo,
nav .nav-brand .logo {
  transform: translateY(2px) !important;
}

.footer .nav-brand .logo,
footer .nav-brand .logo,
.footer-brand .logo {
  transform: translateY(4px) !important;
}

/* SITANO Data Fusion brand lockup: 2 x 2, no visible borders. */
.navbar .nav-brand {
  display: grid !important;
  grid-template-columns: minmax(138px, auto) auto !important;
  grid-template-areas:
    "brand-logo brand-name"
    "brand-tagline brand-tagline" !important;
  align-items: center !important;
  justify-content: start !important;
  justify-items: center !important;
  column-gap: 8px !important;
  row-gap: 2px !important;
  min-height: 62px !important;
  line-height: 1 !important;
}

.navbar .nav-brand .logo {
  grid-area: brand-logo !important;
  width: 154px !important;
  min-width: 154px !important;
  height: 51px !important;
  flex-basis: auto !important;
  align-self: center !important;
  justify-self: end !important;
  margin: 0 -6px 0 0 !important;
  transform: translateX(8px) !important;
}

.navbar .nav-brand .brand-name {
  grid-area: brand-name !important;
  align-self: center !important;
  justify-self: start !important;
  margin: 0 !important;
  line-height: 1 !important;
  transform: translateX(-4px) !important;
  transform: translateY(-4px) !important;
}

.navbar .nav-brand .brand-tagline {
  grid-area: brand-tagline !important;
  display: block !important;
  justify-self: center !important;
  max-width: 100% !important;
  color: rgba(15, 23, 42, 0.66) !important;
  font-size: 0.68rem !important;
  font-weight: 650 !important;
  line-height: 1.15 !important;
  text-align: center !important;
  white-space: nowrap !important;
}

body.dark-mode .navbar .nav-brand .brand-tagline {
  color: rgba(226, 232, 240, 0.76) !important;
}

@media (max-width: 900px) {
  .navbar .nav-brand {
    grid-template-columns: minmax(122px, auto) auto !important;
    column-gap: 6px !important;
    min-height: 58px !important;
  }

  .navbar .nav-brand .brand-tagline {
    display: block !important;
    font-size: 0.62rem !important;
    white-space: normal !important;
  }
}

@media (max-width: 640px) {
  .navbar .nav-brand .logo {
    width: 122px !important;
    min-width: 122px !important;
    height: 41px !important;
    flex-basis: auto !important;
  }
}

/* Footer uses the same SITANO Data Fusion lockup as the header. */
.footer .nav-brand,
footer .nav-brand,
.footer-brand {
  display: grid !important;
  grid-template-columns: minmax(138px, auto) auto !important;
  grid-template-areas:
    "brand-logo brand-name"
    "brand-tagline brand-tagline" !important;
  align-items: center !important;
  justify-content: start !important;
  justify-items: center !important;
  column-gap: 8px !important;
  row-gap: 2px !important;
  min-height: 62px !important;
  line-height: 1 !important;
  margin-top: 0 !important;
}

.footer .nav-brand .logo,
footer .nav-brand .logo,
.footer-brand .logo {
  grid-area: brand-logo !important;
  width: 154px !important;
  min-width: 154px !important;
  height: 51px !important;
  flex-basis: auto !important;
  align-self: center !important;
  justify-self: end !important;
  margin: 0 -6px 0 0 !important;
  transform: translateX(8px) !important;
}

.footer .nav-brand .brand-name,
footer .nav-brand .brand-name,
.footer-brand .brand-name {
  grid-area: brand-name !important;
  align-self: center !important;
  justify-self: start !important;
  margin: 0 !important;
  padding: 0 !important;
  line-height: 1 !important;
  transform: translateY(-4px) !important;
}

.footer .nav-brand .brand-tagline,
footer .nav-brand .brand-tagline,
.footer-brand .brand-tagline {
  grid-area: brand-tagline !important;
  display: block !important;
  justify-self: center !important;
  max-width: 100% !important;
  color: rgba(226, 232, 240, 0.76) !important;
  font-size: 0.68rem !important;
  font-weight: 650 !important;
  line-height: 1.15 !important;
  text-align: center !important;
  white-space: nowrap !important;
}

.footer .container > .nav-brand,
footer .container > .nav-brand {
  margin-bottom: 24px !important;
}

.footer .container > .nav-brand + p,
footer .container > .nav-brand + p {
  margin-top: 0 !important;
}

.footer .footer-col > .nav-brand,
footer .footer-col > .nav-brand {
  margin-bottom: 14px !important;
}

@media (max-width: 900px) {
  .footer .nav-brand,
  footer .nav-brand,
  .footer-brand {
    grid-template-columns: minmax(122px, auto) auto !important;
    column-gap: 6px !important;
    min-height: 58px !important;
  }

  .footer .nav-brand .brand-tagline,
  footer .nav-brand .brand-tagline,
  .footer-brand .brand-tagline {
    display: block !important;
    font-size: 0.62rem !important;
    white-space: normal !important;
  }
}

@media (max-width: 640px) {
  .footer .nav-brand .logo,
  footer .nav-brand .logo,
  .footer-brand .logo {
    width: 122px !important;
    min-width: 122px !important;
    height: 41px !important;
    flex-basis: auto !important;
  }
}

/* Mobile containment for shared public, demo and dashboard chrome. */
html,
body {
  max-width: 100%;
}

.navbar,
nav,
.footer,
footer {
  max-width: 100%;
  overflow-x: clip;
}

.nav-container,
.container,
.wrap,
.footer .container,
footer .container {
  box-sizing: border-box;
  max-width: 100%;
}

@media (max-width: 760px) {
  .navbar .nav-container,
  nav .nav-container {
    width: 100% !important;
    max-width: 100% !important;
    padding: 10px 14px !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    justify-content: flex-start !important;
    gap: 10px !important;
    overflow-x: hidden !important;
  }

  .navbar .nav-brand,
  nav .nav-brand {
    align-self: center !important;
    justify-content: center !important;
    grid-template-columns: minmax(96px, 112px) auto !important;
    column-gap: 5px !important;
    row-gap: 1px !important;
    min-height: 52px !important;
    max-width: 100% !important;
  }

  .navbar .nav-brand .logo,
  nav .nav-brand .logo {
    width: 112px !important;
    min-width: 112px !important;
    height: 37px !important;
    flex-basis: auto !important;
    justify-self: end !important;
    margin: 0 -6px 0 0 !important;
    transform: translateY(1px) !important;
  }

  .navbar .nav-brand .brand-name,
  nav .nav-brand .brand-name {
    font-size: clamp(1rem, 4.2vw, 1.18rem) !important;
    transform: translateY(-2px) !important;
  }

  .navbar .nav-brand .brand-tagline,
  nav .nav-brand .brand-tagline {
    max-width: min(92vw, 320px) !important;
    font-size: 0.58rem !important;
    line-height: 1.18 !important;
    white-space: normal !important;
    overflow-wrap: anywhere !important;
    text-wrap: balance;
  }

  .navbar .nav-center,
  nav .nav-center,
  .navbar .nav-links,
  nav .nav-links {
    width: 100% !important;
    max-width: 100% !important;
  }

  .navbar .nav-links,
  nav .nav-links {
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    overflow-x: hidden !important;
  }

  .navbar .nav-link,
  nav .nav-link,
  .navbar .nav-btn,
  nav .nav-btn,
  #logoutBtn.nav-link {
    flex: 0 1 auto !important;
    min-width: 0 !important;
    max-width: 100% !important;
    padding: 8px 10px !important;
    font-size: 0.82rem !important;
    line-height: 1.15 !important;
    text-align: center !important;
    white-space: normal !important;
    overflow-wrap: anywhere !important;
  }

  #organization-selector-container {
    width: 100% !important;
    max-width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
  }

  #organization-selector-container * {
    max-width: 100% !important;
  }

  .container,
  .wrap,
  .footer .container,
  footer .container {
    width: 100% !important;
    padding-left: 16px !important;
    padding-right: 16px !important;
  }

  .footer,
  footer {
    padding: 42px 0 24px !important;
  }

  .footer .footer-grid,
  footer .footer-grid {
    grid-template-columns: 1fr !important;
    gap: 22px !important;
    margin-bottom: 24px !important;
  }

  .footer .nav-brand,
  footer .nav-brand,
  .footer-brand {
    margin-left: auto !important;
    margin-right: auto !important;
    justify-content: center !important;
    grid-template-columns: minmax(96px, 112px) auto !important;
    column-gap: 5px !important;
    row-gap: 1px !important;
    min-height: 52px !important;
    max-width: 100% !important;
  }

  .footer .nav-brand .logo,
  footer .nav-brand .logo,
  .footer-brand .logo {
    width: 112px !important;
    min-width: 112px !important;
    height: 37px !important;
    flex-basis: auto !important;
    margin: 0 -6px 0 0 !important;
    transform: translateY(1px) !important;
  }

  .footer .nav-brand .brand-name,
  footer .nav-brand .brand-name,
  .footer-brand .brand-name {
    font-size: clamp(1rem, 4.2vw, 1.18rem) !important;
    transform: translateY(-2px) !important;
  }

  .footer .nav-brand .brand-tagline,
  footer .nav-brand .brand-tagline,
  .footer-brand .brand-tagline {
    max-width: min(92vw, 320px) !important;
    font-size: 0.58rem !important;
    line-height: 1.18 !important;
    white-space: normal !important;
    overflow-wrap: anywhere !important;
    text-wrap: balance;
  }

  .footer p,
  footer p,
  .footer-link,
  .footer-col,
  .footer-col h4 {
    max-width: 100% !important;
    overflow-wrap: anywhere !important;
    text-align: center;
  }

  .footer-bottom,
  footer .footer-bottom {
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    gap: 12px !important;
  }

  .social-links {
    justify-content: center !important;
    flex-wrap: wrap !important;
  }
}

@media (max-width: 420px) {
  .navbar .nav-container,
  nav .nav-container {
    padding-left: 10px !important;
    padding-right: 10px !important;
  }

  .navbar .nav-brand,
  nav .nav-brand,
  .footer .nav-brand,
  footer .nav-brand,
  .footer-brand {
    grid-template-columns: minmax(84px, 98px) auto !important;
  }

  .navbar .nav-brand .logo,
  nav .nav-brand .logo,
  .footer .nav-brand .logo,
  footer .nav-brand .logo,
  .footer-brand .logo {
    width: 98px !important;
    min-width: 98px !important;
    height: 33px !important;
  }

  .navbar .nav-brand .brand-tagline,
  nav .nav-brand .brand-tagline,
  .footer .nav-brand .brand-tagline,
  footer .nav-brand .brand-tagline,
  .footer-brand .brand-tagline {
    max-width: 88vw !important;
    font-size: 0.55rem !important;
  }

  .navbar .nav-link,
  nav .nav-link,
  .navbar .nav-btn,
  nav .nav-btn,
  #logoutBtn.nav-link {
    padding: 7px 8px !important;
    font-size: 0.78rem !important;
  }
}

.mobile-nav-toggle {
  display: none;
}

@media (max-width: 760px) {
  .navbar .nav-container,
  nav .nav-container {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    align-items: center !important;
    justify-content: stretch !important;
    gap: 10px !important;
  }

  .navbar .nav-brand,
  nav .nav-brand {
    grid-column: 1 !important;
    justify-self: start !important;
    align-self: center !important;
  }

  .mobile-nav-toggle {
    grid-column: 2 !important;
    display: inline-flex !important;
    width: 42px !important;
    height: 42px !important;
    padding: 0 !important;
    align-items: center !important;
    justify-content: center !important;
    flex-direction: column !important;
    gap: 5px !important;
    border: 1px solid var(--ecosystem-border) !important;
    border-radius: 8px !important;
    background: var(--ecosystem-surface) !important;
    color: var(--ecosystem-ink) !important;
    cursor: pointer !important;
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.08) !important;
  }

  .mobile-nav-toggle span {
    display: block !important;
    width: 19px !important;
    height: 2px !important;
    border-radius: 999px !important;
    background: currentColor !important;
    transition: transform 160ms ease, opacity 160ms ease !important;
  }

  .nav-container.nav-open .mobile-nav-toggle span:nth-child(1) {
    transform: translateY(7px) rotate(45deg) !important;
  }

  .nav-container.nav-open .mobile-nav-toggle span:nth-child(2) {
    opacity: 0 !important;
  }

  .nav-container.nav-open .mobile-nav-toggle span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg) !important;
  }

  body.dark-mode .mobile-nav-toggle {
    background: #0f172a !important;
    color: var(--ecosystem-ink) !important;
    border-color: var(--ecosystem-border) !important;
  }

  .navbar .nav-center,
  nav .nav-center,
  .navbar .nav-links,
  nav .nav-links {
    grid-column: 1 / -1 !important;
  }

  .navbar .nav-links,
  nav .nav-links {
    display: none !important;
    padding: 10px 0 2px !important;
    border-top: 1px solid var(--ecosystem-border) !important;
  }

  .navbar .nav-container.nav-open .nav-links,
  nav .nav-container.nav-open .nav-links,
  .navbar .nav-links.is-open,
  nav .nav-links.is-open {
    display: flex !important;
  }

  .navbar .nav-link,
  nav .nav-link,
  .navbar .nav-btn,
  nav .nav-btn,
  #logoutBtn.nav-link {
    border: 1px solid var(--ecosystem-border) !important;
    border-radius: 8px !important;
    background: color-mix(in srgb, var(--ecosystem-surface) 92%, var(--service-primary)) !important;
  }

  body.dark-mode .navbar .nav-link,
  body.dark-mode nav .nav-link,
  body.dark-mode .navbar .nav-btn,
  body.dark-mode nav .nav-btn,
  body.dark-mode #logoutBtn.nav-link {
    background: #0f172a !important;
  }

  .hero,
  header.hero,
  .section,
  .cta-section {
    max-width: 100% !important;
    overflow-x: hidden !important;
  }

  .hero-content,
  .hero-title,
  .hero-claim,
  .hero-kicker,
  .hero-subtitle,
  .section-title,
  .section-subtitle {
    max-width: 100% !important;
    overflow-wrap: anywhere !important;
  }

  .hero-title,
  .section-title {
    line-height: 1.14 !important;
  }

  .hero-stats {
    width: 100% !important;
    justify-content: center !important;
    gap: 10px !important;
  }

  .stat {
    flex: 1 1 135px !important;
    min-width: 0 !important;
    max-width: 100% !important;
    text-align: center !important;
  }

  .certificate-grid,
  .usecase-grid,
  .features-grid,
  .pricing-grid,
  .dashboard-grid,
  .persona-insights-grid,
  main .section [style*="grid-template-columns"] {
    grid-template-columns: 1fr !important;
    width: 100% !important;
    max-width: 100% !important;
    gap: 16px !important;
  }

  .cert-card,
  .usecase-card,
  .feature-card,
  .pricing-card,
  .dashboard-card,
  .card,
  .panel {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    padding: 18px !important;
    box-sizing: border-box !important;
    overflow-wrap: anywhere !important;
  }

  .cert-card h3,
  .usecase-card h3,
  .feature-card h3,
  .pricing-card h3,
  .dashboard-card h3,
  .card h3,
  .panel h3,
  .cert-card p,
  .usecase-card p,
  .feature-card p,
  .pricing-card p,
  .dashboard-card p,
  .card p,
  .panel p {
    max-width: 100% !important;
    overflow-wrap: anywhere !important;
  }

  .cert-card ul,
  .usecase-card ul,
  .feature-card ul,
  .pricing-card ul {
    width: 100% !important;
    max-width: 100% !important;
    padding-left: 0 !important;
    box-sizing: border-box !important;
  }

  .cert-card li,
  .usecase-card li,
  .feature-card li,
  .pricing-card li {
    display: block !important;
    max-width: 100% !important;
    overflow-wrap: anywhere !important;
    line-height: 1.4 !important;
  }

  .cta-container,
  .actions {
    width: 100% !important;
    max-width: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    justify-content: center !important;
    gap: 10px !important;
  }

  .cta-button,
  .btn,
  .button,
  .btn-secondary {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    justify-content: center !important;
    text-align: center !important;
    white-space: normal !important;
    overflow-wrap: anywhere !important;
    box-sizing: border-box !important;
  }

  .cta-section {
    margin: 32px 0 !important;
    padding: 32px 16px !important;
    border-radius: 8px !important;
  }

  .auth-card,
  .auth-container,
  .login-card,
  .signup-card,
  .form-block,
  .feedback-form,
  form {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
  }

  .auth-card {
    margin: 28px auto !important;
    padding: 22px 16px !important;
  }

  .auth-card h1,
  .auth-card h2,
  .auth-card p,
  .auth-card a,
  .auth-card .error {
    max-width: 100% !important;
    overflow-wrap: anywhere !important;
  }

  .auth-card form,
  .form-block,
  .feedback-form,
  .inline-fields,
  .inline-fields .form-row {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 12px !important;
  }

  input,
  select,
  textarea,
  .auth-card input,
  .auth-card select,
  .auth-card textarea,
  .form-block input,
  .form-block select,
  .form-block textarea,
  .feedback-form input,
  .feedback-form textarea {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
  }

  button,
  .auth-card button,
  .form-block button,
  .feedback-form button {
    max-width: 100% !important;
    min-width: 0 !important;
    white-space: normal !important;
    overflow-wrap: anywhere !important;
  }

  .auth-card button,
  .form-block button,
  .feedback-form button {
    width: 100% !important;
    justify-content: center !important;
  }

  table,
  pre,
  code {
    max-width: 100% !important;
  }

  table,
  pre {
    display: block !important;
    overflow-x: auto !important;
    box-sizing: border-box !important;
  }

  code {
    white-space: pre-wrap !important;
    overflow-wrap: anywhere !important;
  }

  .doc-card,
  .compliance-card,
  .security-card,
  .privacy-card,
  .calibration-guide,
  .calibration-results,
  .calibration-diagnosis {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    padding: 18px !important;
    box-sizing: border-box !important;
    overflow-wrap: anywhere !important;
  }
}

@media (min-width: 761px) {
  .navbar .nav-links,
  nav .nav-links {
    display: flex !important;
  }
}

.evidence-capability-grid,
.benchmark-scenario-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.evidence-capability-card,
.benchmark-scenario-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 16px;
  min-width: 0;
}

.evidence-capability-card h3,
.benchmark-scenario-card h3 {
  margin: 0 0 8px;
  font-size: 1rem;
}

.evidence-capability-card p,
.benchmark-scenario-card p {
  margin: 0 0 12px;
  color: #475569;
  line-height: 1.5;
}

.evidence-capability-card code {
  display: block;
  overflow-wrap: anywhere;
  margin: 10px 0;
  font-size: 0.82rem;
  color: #334155;
}

.metric-badge,
.scenario-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 8px;
  border-radius: 999px;
  background: #e0f2fe;
  color: #075985;
  font-size: 0.78rem;
  font-weight: 800;
}

.module-header-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.module-header-row p {
  margin: 6px 0 0;
  color: #475569;
}

.scenario-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 10px 0 14px;
}

body.dark-mode .evidence-capability-card,
body.dark-mode .benchmark-scenario-card {
  background: #111827;
  border-color: #334155;
}

body.dark-mode .evidence-capability-card p,
body.dark-mode .benchmark-scenario-card p,
body.dark-mode .module-header-row p,
body.dark-mode .evidence-capability-card code {
  color: #cbd5e1;
}

@media (max-width: 760px) {
  .module-header-row {
    display: grid;
  }
}
/* Dashboard phase 2: persona x processing mode product routing */
.evidence-product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.evidence-product-card {
    border: 1px solid rgba(148, 163, 184, 0.28);
    border-radius: 8px;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.86);
}

.evidence-product-card h3 {
    margin: 0;
    color: #0f172a;
}

.evidence-product-card p {
    margin: 0.55rem 0 0.75rem;
    color: #475569;
}

.processing-mode-control {
    min-width: 180px;
}

.evidence-context-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin: 1rem 0;
}

.evidence-context-strip span {
    display: inline-flex;
    gap: 0.35rem;
    align-items: center;
    border: 1px solid rgba(148, 163, 184, 0.28);
    border-radius: 999px;
    padding: 0.4rem 0.65rem;
    color: #334155;
    background: rgba(248, 250, 252, 0.88);
}

.product-view-panel {
    margin-top: 1rem;
    border: 1px solid rgba(14, 165, 233, 0.28);
    border-radius: 8px;
    padding: 1rem;
    background: rgba(240, 249, 255, 0.72);
}

.product-view-panel h3 {
    margin: 0 0 0.75rem;
    color: #0f172a;
}

body.dark-mode .evidence-product-card {
    background: rgba(15, 23, 42, 0.86);
    border-color: rgba(148, 163, 184, 0.24);
}

body.dark-mode .evidence-product-card h3 {
    color: #f8fafc;
}

body.dark-mode .evidence-product-card p {
    color: #cbd5e1;
}

body.dark-mode .evidence-context-strip span {
    background: rgba(15, 23, 42, 0.72);
    border-color: rgba(148, 163, 184, 0.24);
    color: #cbd5e1;
}

body.dark-mode .product-view-panel {
    background: rgba(8, 47, 73, 0.28);
    border-color: rgba(14, 165, 233, 0.26);
}

body.dark-mode .product-view-panel h3 {
    color: #f8fafc;
}

@media (max-width: 720px) {
    .evidence-product-grid {
        grid-template-columns: 1fr;
    }

    .processing-mode-control,
    .processing-mode-control select {
        width: 100%;
    }

    .evidence-context-strip {
        display: grid;
    }
}

/* V3 logo optical alignment using the source SVG's real 1380:580 ratio. */
.navbar .nav-brand .logo,
nav .nav-brand .logo,
.footer .nav-brand .logo,
footer .nav-brand .logo,
.footer-brand .logo {
  --sitano-logo-width: clamp(112px, 19vw, 185.22px);
  width: var(--sitano-logo-width) !important;
  min-width: var(--sitano-logo-width) !important;
  height: auto !important;
  aspect-ratio: 69 / 29 !important;
  flex: 0 0 var(--sitano-logo-width) !important;
  background-size: contain !important;
  background-position: center !important;
  transform: translateY(-10px) !important;
}

