/*
  Product and solution page visual standard.
  Loaded after page-specific CSS so retained legacy layouts resolve to current tokens.
*/

body[data-page-family] {
  background: var(--site-bg);
  color: var(--text-primary);
}

body[data-page-file="cadence.html"] .hero,
body[data-page-file="score.html"] .hero {
  width: min(calc(100% - 48px), var(--site-container));
  max-width: var(--site-container);
  min-height: auto;
  margin: 0 auto;
  padding: 112px 0 92px;
  display: grid;
  grid-template-columns: minmax(0, 0.96fr) minmax(460px, 1.04fr);
  gap: 64px;
  align-items: center;
  border: 0;
  background: transparent;
}

body[data-page-file="maestro.html"] .hero,
body[data-page-file="opus.html"] .hero,
body[data-page-family="solution"] .hero {
  min-height: auto;
  padding: 112px 0 92px;
  border: 0;
  background: transparent;
}

body[data-page-file="maestro.html"] .hero .container,
body[data-page-file="opus.html"] .hero .container,
body[data-page-family="solution"] .hero .container {
  width: min(calc(100% - 48px), var(--site-container));
  max-width: var(--site-container);
  margin-inline: auto;
  padding: 0;
}

body[data-page-file="maestro.html"] .hero-grid,
body[data-page-file="opus.html"] .hero-inner,
body[data-page-family="solution"] .hero-layout,
body[data-page-family="solution"] .hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.96fr) minmax(460px, 1.04fr);
  gap: 64px;
  align-items: center;
}

body[data-page-family] .hero-content {
  min-width: 0;
  max-width: 760px;
}

body[data-page-family] .hero-title,
body[data-page-family] .hero-content h1 {
  max-width: 760px;
  margin: 22px 0 20px;
  color: var(--text-primary);
  font-family: var(--site-font);
  font-size: clamp(40px, 5vw, 60px);
  font-weight: 900;
  line-height: 1.16;
  letter-spacing: 0;
  overflow-wrap: anywhere;
}

body[data-page-family] .hero-title:first-child,
body[data-page-family] .hero-content h1:first-child {
  margin-top: 0;
}

body[data-page-family] .hero-title em,
body[data-page-family] .hero-title .accent,
body[data-page-family] .hero-title-accent,
body[data-page-family] .solution-hero-title__line.is-accent,
body[data-page-family] .hero-content h1 .accent {
  display: inline;
  color: transparent;
  background: linear-gradient(135deg, var(--brand) 0%, var(--title-highlight-gradient-end) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

body[data-page-family] .hero-subtitle,
body[data-page-family] .hero-content h2 {
  max-width: 720px;
  margin: 0 0 18px;
  color: var(--text-secondary);
  font-family: var(--site-font);
  font-size: clamp(18px, 1.8vw, 20px);
  font-weight: 600;
  line-height: 1.62;
  letter-spacing: 0;
}

body[data-page-family] .hero-description,
body[data-page-family] .hero-text,
body[data-page-family] .hero-content > p:not(.hero-subtitle) {
  max-width: 720px;
  margin: 0 0 32px;
  color: var(--text-secondary);
  font-size: 17px;
  font-weight: 500;
  line-height: 1.78;
  overflow-wrap: anywhere;
  word-break: normal;
  white-space: normal;
}

body[data-page-family] .hero-label,
body[data-page-family] .hero-tag,
body[data-page-family] .hero-badge,
body[data-page-family] .eyebrow,
body[data-page-family] .hero-badges .badge {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 22px;
  padding: 0 14px;
  border: 1px solid color-mix(in srgb, var(--brand) 26%, transparent);
  border-radius: 999px;
  background: color-mix(in srgb, var(--brand) 8%, transparent);
  color: var(--brand-strong);
  font-family: var(--site-font);
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

body[data-page-family] .hero-label::before,
body[data-page-family] .hero-tag::before,
body[data-page-family] .hero-badge::before,
body[data-page-family] .eyebrow::before,
body[data-page-family] .hero-badges .badge::before {
  content: none;
  display: none;
}

body[data-page-family] .hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 22px;
}

body[data-page-family] .hero-actions,
body[data-page-family] .hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 30px;
}

body[data-page-family] .cards-grid--spaced,
body[data-page-family] .value-grid--compact {
  margin-top: 48px;
}

body[data-page-family] .value-grid--compact {
  margin-top: 16px;
}

body[data-page-family] .section-label,
body[data-page-family] .section-kicker,
body[data-page-family] .legacy-block-kicker {
  color: var(--brand-strong);
  font-family: var(--site-font);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

body[data-page-family] .section-title,
body[data-page-family] .section h2 {
  color: var(--text-primary);
  font-family: var(--site-font);
  font-size: clamp(30px, 4vw, 42px);
  font-weight: 800;
  line-height: 1.24;
  letter-spacing: 0;
}

body[data-page-family] .section-subtitle,
body[data-page-family] .section-copy,
body[data-page-family] .section-text,
body[data-page-family] .section-description {
  color: var(--text-secondary);
  font-size: 17px;
  line-height: 1.72;
}

body[data-page-family] .card,
body[data-page-family] .workflow-step,
body[data-page-family] .scenario-card,
body[data-page-family] .capability,
body[data-page-family] .capability-card,
body[data-page-family] .problem-card,
body[data-page-family] .industry-item,
body[data-page-family] .compliance-badge,
body[data-page-family] .asset-card,
body[data-page-family] .risk-card,
body[data-page-family] .value-card,
body[data-page-family] .review-card,
body[data-page-family] .evidence-card-lite,
body[data-page-family] .compare-row,
body[data-page-family] .arch-box,
body[data-page-family] .arch-node,
body[data-page-family] .arch-card,
body[data-page-family] .product-visual,
body[data-page-family] .agent-console,
body[data-page-family] .console {
  border-color: var(--site-border);
  background:
    radial-gradient(circle at 82% 0, var(--card-glow-soft), transparent 42%),
    linear-gradient(180deg, var(--site-surface-solid), var(--bg-deep)),
    var(--site-surface-solid);
  background:
    radial-gradient(circle at 82% 0, color-mix(in srgb, var(--card-glow) 8%, transparent), transparent 42%),
    linear-gradient(180deg, color-mix(in srgb, var(--site-surface-solid) 78%, transparent), color-mix(in srgb, var(--bg-deep) 82%, transparent));
  box-shadow:
    0 22px 64px color-mix(in srgb, var(--bg-deep) 70%, transparent),
    inset 0 1px 0 color-mix(in srgb, var(--text-primary) 7%, transparent);
  -webkit-backdrop-filter: blur(18px) saturate(1.18);
  backdrop-filter: blur(18px) saturate(1.18);
}

body[data-page-family] .card-icon,
body[data-page-family] .scenario-icon,
body[data-page-family] .capability-icon,
body[data-page-family] .problem-icon,
body[data-page-family] .workflow-icon,
body[data-page-family] .industry-icon,
body[data-page-family] .compliance-icon,
body[data-page-family] .asset-icon,
body[data-page-family] .arch-box-icon,
body[data-page-family] .arch-node-icon {
  width: 38px;
  height: 38px;
  display: inline-grid;
  place-items: center;
  border: 1px solid color-mix(in srgb, var(--brand) 24%, transparent);
  border-radius: 14px;
  background:
    radial-gradient(circle at 50% 0, color-mix(in srgb, var(--card-glow) 22%, transparent), transparent 66%),
    color-mix(in srgb, var(--brand) 10%, transparent);
  color: var(--brand-strong);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 900;
  line-height: 1;
  box-shadow: inset 0 1px 0 color-mix(in srgb, var(--text-primary) 14%, transparent);
}

body[data-page-family] .card--tone-green,
body[data-page-family] .card--tone-green .card-icon {
  --standard-tone: var(--brand);
}

body[data-page-family] .card--tone-blue,
body[data-page-family] .card--tone-blue .card-icon {
  --standard-tone: var(--accent-2);
}

body[data-page-family] .card--tone-yellow,
body[data-page-family] .card--tone-yellow .card-icon {
  --standard-tone: var(--accent-3);
}

body[data-page-family] .card--tone-purple,
body[data-page-family] .card--tone-purple .card-icon {
  --standard-tone: var(--accent-4);
}

body[data-page-family] .card--tone-red,
body[data-page-family] .card--tone-red .card-icon {
  --standard-tone: var(--accent-5);
}

body[data-page-family] .card--tone-muted,
body[data-page-family] .card--tone-muted .card-icon {
  --standard-tone: var(--text-tertiary);
}

body[data-page-family] .card--tone-green,
body[data-page-family] .card--tone-blue,
body[data-page-family] .card--tone-yellow,
body[data-page-family] .card--tone-purple,
body[data-page-family] .card--tone-red,
body[data-page-family] .card--tone-muted {
  border-color: color-mix(in srgb, var(--standard-tone, var(--brand)) 26%, transparent);
}

body[data-page-family] .card--tone-green .card-icon,
body[data-page-family] .card--tone-blue .card-icon,
body[data-page-family] .card--tone-yellow .card-icon,
body[data-page-family] .card--tone-purple .card-icon,
body[data-page-family] .card--tone-red .card-icon,
body[data-page-family] .card--tone-muted .card-icon {
  border-color: color-mix(in srgb, var(--standard-tone, var(--brand)) 32%, transparent);
  background:
    radial-gradient(circle at 50% 0, color-mix(in srgb, var(--standard-tone, var(--brand)) 22%, transparent), transparent 66%),
    color-mix(in srgb, var(--standard-tone, var(--brand)) 12%, transparent);
  color: color-mix(in srgb, var(--standard-tone, var(--brand)) 76%, var(--text-primary));
}

body[data-page-family] .integration-card-title {
  color: var(--text-tertiary);
  font-size: 14px;
}

body[data-page-family] .integration-card-text {
  margin-top: 12px;
  color: var(--text-secondary);
  font-size: 13px;
  line-height: 1.6;
}

body[data-page-family] .arch-column-title--highlight {
  color: var(--brand-strong);
}

body[data-page-family] .arch-node-meta {
  margin-top: 4px;
  color: var(--text-tertiary);
  font-size: 12px;
}

body[data-page-family] .arch-node-meta--running {
  color: var(--accent-3);
}

body[data-page-family] .arch-node-meta--passed {
  color: var(--brand-strong);
}

body[data-page-file="score.html"] .score-value-section {
  background: color-mix(in srgb, var(--site-surface-solid) 64%, transparent);
}

body[data-page-family] .card-title,
body[data-page-family] .scenario-title,
body[data-page-family] .capability-content h3,
body[data-page-family] .capability-title,
body[data-page-family] .problem-title,
body[data-page-family] .industry-name,
body[data-page-family] .compliance-name,
body[data-page-family] .asset-name {
  color: var(--text-primary);
}

body[data-page-family] .card-desc,
body[data-page-family] .scenario-desc,
body[data-page-family] .capability-content p,
body[data-page-family] .capability-text,
body[data-page-family] .capability-desc,
body[data-page-family] .capability-description,
body[data-page-family] .problem-text,
body[data-page-family] .industry-desc,
body[data-page-family] .compliance-desc,
body[data-page-family] .asset-desc {
  color: var(--text-secondary);
}

body[data-page-family] .text-green,
body[data-page-family] .live,
body[data-page-family] .state,
body[data-page-family] .console-line .cmd,
body[data-page-family] .console-line .success,
body[data-page-family] .product-visual__status {
  color: var(--brand-strong);
}

body[data-page-family] .text-blue,
body[data-page-family] .console-line .arg,
body[data-page-family] .card-kicker {
  color: var(--accent-2);
}

body[data-page-family] .text-yellow,
body[data-page-family] .warn,
body[data-page-family] .state.warn {
  color: var(--accent-3);
}

body[data-page-family] .text-red,
body[data-page-family] .error {
  color: var(--accent-5);
}

body[data-page-family] .product-visual__row,
body[data-page-family] .gate-row,
body[data-page-family] .risk-card,
body[data-page-family] .product-visual__metric,
body[data-page-family] .product-visual__panel,
body[data-page-family] .product-visual__asset,
body[data-page-family] .asset-tag,
body[data-page-family] .event-chip,
body[data-page-family] .demand-step {
  border-color: var(--site-border);
  background: color-mix(in srgb, var(--site-surface) 54%, transparent);
}

@media (max-width: 980px) {
  body[data-page-file="cadence.html"] .hero,
  body[data-page-file="score.html"] .hero,
  body[data-page-file="maestro.html"] .hero-grid,
  body[data-page-file="opus.html"] .hero-inner,
  body[data-page-family="solution"] .hero-layout,
  body[data-page-family="solution"] .hero-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 42px;
  }

  body[data-page-family] .product-visual,
  body[data-page-family] .agent-console,
  body[data-page-family] .console,
  body[data-page-family] .live-system {
    order: 2;
  }
}

@media (max-width: 640px) {
  body[data-page-file="cadence.html"] .hero,
  body[data-page-file="score.html"] .hero,
  body[data-page-file="maestro.html"] .hero .container,
  body[data-page-file="opus.html"] .hero .container,
  body[data-page-family="solution"] .hero .container {
    width: min(calc(100% - 32px), var(--site-container));
  }

  body[data-page-family] .hero-title,
  body[data-page-family] .hero-content h1 {
    font-size: clamp(34px, 10vw, 44px);
  }

  body[data-page-family] .hero-content,
  body[data-page-family] .hero-subtitle,
  body[data-page-family] .hero-description,
  body[data-page-family] .hero-text,
  body[data-page-family] .hero-content > p:not(.hero-subtitle),
  body[data-page-family] .product-visual,
  body[data-page-family] .agent-console,
  body[data-page-family] .console,
  body[data-page-family] .live-system {
    width: 100%;
    max-width: 100%;
    min-width: 0;
  }

  body[data-page-family] .hero-subtitle,
  body[data-page-family] .hero-content h2 {
    font-size: 18px;
  }

  body[data-page-family] .hero-description,
  body[data-page-family] .hero-text,
  body[data-page-family] .hero-content > p:not(.hero-subtitle) {
    font-size: 16px;
  }

  body[data-page-family] .hero-actions,
  body[data-page-family] .hero-ctas {
    width: 100%;
    max-width: 100%;
    flex-direction: column;
    align-items: stretch;
  }

  body[data-page-family] .hero-actions > a,
  body[data-page-family] .hero-ctas > a {
    width: 100%;
    justify-content: center;
  }

}
