:root {
  --proto-bg: #f5f2ed;
  --proto-ink: #251918;
  --proto-muted: #695b55;
  --proto-card: #fffdf9;
  --proto-card-solid: #fffdf9;
  --proto-line: rgba(61, 41, 36, .14);
  --proto-teal: #1f9b84;
  --proto-blue: #476cff;
  --proto-violet: #8756d9;
  --proto-coral: #d85d45;
  --proto-gold: #c99418;
  --proto-shadow: 0 1px 2px rgba(47, 31, 27, .06);
  --proto-glow: 0 2px 8px rgba(47, 31, 27, .08);
}

html {
  color-scheme: light;
}

body {
  background: #f7f4ef !important;
  color: var(--proto-ink) !important;
}

body::before {
  display: none !important;
}

.proto-header,
.prototype-header {
  position: sticky;
  top: 0;
  z-index: 40;
  border-bottom: 1px solid rgba(255, 255, 255, .1) !important;
  background: #251918 !important;
  color: #fffdf9;
  box-shadow: none;
  backdrop-filter: none;
}

.proto-header::after,
.prototype-header::after {
  display: none !important;
}

.ph-back,
.back-link {
  border-color: rgba(255, 255, 255, .18) !important;
  background: rgba(255, 255, 255, .06) !important;
  color: rgba(255, 253, 249, .78) !important;
}

.ph-back:hover,
.back-link:hover {
  border-color: rgba(255, 255, 255, .42) !important;
  color: #fffdf9 !important;
}

.ph-badge,
.badge {
  box-shadow: none;
}

.suite-bar,
.tab-bar {
  position: sticky;
  z-index: 30;
  backdrop-filter: blur(18px);
}

.suite-bar {
  top: 68px;
  background: #2a1c18 !important;
}

.tab-bar {
  top: 104px;
  border-bottom-color: var(--proto-line) !important;
  background: #fffdf9 !important;
}

.tab-btn,
.segmented button,
.action-buttons button,
.tmpl-btn,
.score-btn,
button,
select,
input {
  transition: transform .18s ease, border-color .18s ease, background .18s ease, box-shadow .18s ease, color .18s ease;
}

.tab-btn.active,
.tab-btn.is-active,
.segmented button.is-active,
.tmpl-btn.sel,
.score-btn.sel,
button.is-active {
  background: var(--proto-ink) !important;
  color: #fffdf9 !important;
  box-shadow: none;
}

.tab-btn:hover,
.segmented button:hover,
.action-buttons button:hover,
.tmpl-btn:hover,
.score-btn:hover,
.ra-btn:hover {
  transform: none;
}

.proto-main,
.tracker,
.roadmap-app {
  animation: none;
}

.panel-header {
  position: relative;
  padding: 2px 0 4px;
}

.panel-title {
  color: var(--proto-ink) !important;
  font-size: clamp(1.42rem, 2vw, 2rem) !important;
  letter-spacing: -.02em;
  line-height: 1.12;
}

.panel-sub {
  max-width: 820px;
  color: var(--proto-muted) !important;
}

.proto-main {
  padding-block: 30px 56px !important;
}

.tracker,
.roadmap-app {
  margin-block: 18px 34px !important;
}

.panel-header,
.stats-row,
.hero,
.readiness-hero,
.ai-card,
.form-card,
.gen-bar,
.impact-grid,
.input-grid,
.bu-grid,
.prog-detail-grid,
.signals-grid {
  margin-bottom: 18px !important;
}

.stats-row,
.input-grid,
.impact-grid,
.bu-grid,
.prog-detail-grid,
.signals-grid,
.card-grid,
.program-grid,
.roadmap-board,
.quarterly-plan {
  gap: 10px !important;
}

.stat-card,
.metric {
  min-height: auto !important;
  padding: 14px 16px !important;
}

.stat-val,
.metric strong,
.rh-num,
.bu-score,
.ssb-num {
  font-size: clamp(1.3rem, 2.2vw, 1.9rem) !important;
}

.program-card,
.ai-card,
.form-card,
.input-card,
.impact-card,
.pd-card,
.sig-card,
.action-card,
.initiative-card,
.lib-card,
.readiness-hero,
.hero-main,
.section-card {
  padding: 18px !important;
}

.program-card {
  gap: 14px 22px !important;
}

.queue-tbl th,
.queue-tbl td,
.data-tbl th,
.data-tbl td,
.risk-tbl th,
.risk-tbl td {
  padding-block: 10px !important;
}

.tab-bar {
  padding-block: 8px !important;
}

.tab-btn {
  min-height: 36px !important;
  padding-block: 0 !important;
}

.panel-eyebrow,
.ph-eyebrow {
  letter-spacing: .12em !important;
}

.hero,
.readiness-hero,
.ai-card,
.form-card,
.gen-bar,
.impact-card,
.input-card,
.queue-wrap,
.section-card,
.risk-wrap,
.roadmap-app,
.group,
.pd-card,
.sig-card,
.action-card,
.program-card,
.stat-card,
.metric,
.bu-card,
.initiative-card,
.lib-card {
  border-color: var(--proto-line) !important;
  background: var(--proto-card) !important;
  box-shadow: var(--proto-shadow);
}

.hero-main,
.prototype-card-main {
  position: relative;
  overflow: hidden;
  background: #eef6f1 !important;
}

.hero-main::after,
.prototype-card-main::after {
  display: none !important;
}

.hero-main > *,
.prototype-card-main > * {
  position: relative;
  z-index: 1;
}

.stats-row {
  align-items: stretch;
}

.stat-card,
.metric {
  position: relative;
  overflow: hidden;
}

.stat-card::before,
.metric::before {
  position: absolute;
  inset: 0 0 auto;
  height: 3px;
  content: "";
  background: var(--proto-teal);
  opacity: .9;
}

.stat-val,
.metric strong,
.rh-num,
.bu-score,
.ssb-num {
  letter-spacing: -.05em;
}

.stat-card:hover,
.metric:hover,
.bu-card:hover,
.initiative-card:hover,
.lib-card:hover,
.program-card:hover,
.input-card:hover,
.section-card:hover,
.pd-card:hover,
.sig-card:hover,
.action-card:hover {
  border-color: rgba(31, 155, 132, .32) !important;
  box-shadow: var(--proto-glow);
  transform: none;
}

.risk-tbl th,
.queue-tbl th,
.data-tbl th {
  background: rgba(237, 245, 241, .9) !important;
  color: var(--proto-muted) !important;
}

.risk-tbl tr:hover td,
.queue-tbl tr:hover td,
.data-tbl tr:hover td {
  background: rgba(204, 232, 221, .18) !important;
}

.hb-fill,
.rh-fill,
.bu-fill,
.sr-fill,
.srd-fill,
.cap-fill,
.lb-fill {
  position: relative;
  overflow: hidden;
}

.hb-fill::after,
.rh-fill::after,
.bu-fill::after,
.sr-fill::after,
.srd-fill::after,
.cap-fill::after,
.lb-fill::after {
  display: none !important;
}

.status-badge,
.q-status,
.sev,
.ai-tag,
.lc-pill,
.bu-badge,
.sig-badge,
.proto-tag,
.ph-badge,
.badge {
  border-radius: 6px !important;
  letter-spacing: .035em;
}

.gen-btn,
.analyze-btn,
.prototype-cta,
.ra-primary {
  border: 0 !important;
  background: var(--proto-teal) !important;
  color: #fffdf9 !important;
  box-shadow: none;
}

.gen-btn:hover,
.analyze-btn:hover,
.prototype-cta:hover,
.ra-primary:hover {
  box-shadow: var(--proto-glow);
  transform: none;
}

.ai-pulse,
.proto-pulse {
  box-shadow: 0 0 0 0 rgba(31, 155, 132, .55);
  animation: proto-pulse 1.8s ease-in-out infinite !important;
}

.is-revealed {
  animation: none;
}

@keyframes proto-rise {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes proto-sheen {
  0% { transform: translateX(-110%); }
  46%, 100% { transform: translateX(110%); }
}

@keyframes proto-pulse {
  0%, 100% {
    opacity: 1;
    box-shadow: 0 0 0 0 rgba(31, 155, 132, .45);
  }
  50% {
    opacity: .55;
    box-shadow: 0 0 0 8px rgba(31, 155, 132, 0);
  }
}

@media (max-width: 760px) {
  .proto-header,
  .prototype-header {
    align-items: flex-start;
    flex-direction: column;
    padding-inline: 16px !important;
  }

  .suite-bar {
    top: 95px;
  }

  .tab-bar {
    top: 132px;
  }

  .panel-title {
    font-size: clamp(1.35rem, 6.5vw, 1.78rem) !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: .001ms !important;
  }
}
