:root {
  --bg: #fff8f0;
  --panel: #ffffff;
  --panel-soft: #fbf3e4;
  --ink: #1f1b12;
  --muted: #5f5849;
  --subtle: #8a826f;
  --line: #d0c6ae;
  --line-soft: #e8dfd0;
  --primary: #735c00;
  --primary-dark: #574500;
  --primary-soft: #fff0b6;
  --primary-container: #ffd54f;
  --primary-fixed: #ffe087;
  --inverse: #343026;
  --inverse-2: #201c13;
  --inverse-text: #f8f0e1;
  --surface-low: #fbf3e4;
  --surface: #fff8f0;
  --surface-high: #f0e7d9;
  --surface-highest: #eae2d3;
  --danger: #ba1a1a;
  --danger-soft: #ffdad6;
  --green: #2f7d3f;
  --green-soft: #e3f4e7;
  --amber: #9a6c00;
  --amber-soft: #fff0c6;
  --brick: #ba1a1a;
  --brick-soft: #ffdad6;
  --violet: #64558e;
  --violet-soft: #eee8ff;
  --shadow: 0 1rem 2.6rem rgba(52, 48, 38, 0.07);
  --shadow-soft: 0 0.5rem 1.5rem rgba(52, 48, 38, 0.045);
  --radius: 1.5rem;
  --radius-sm: 0.75rem;
  --radius-md: 1.25rem;
  --sidebar-width: 16rem;
  --topbar-height: 5rem;
}

* {
  letter-spacing: 0;
}

html {
  background: var(--surface);
}

body {
  min-width: 20rem;
  color: var(--ink);
  background: linear-gradient(135deg, #fffdf8 0%, #fff8f0 52%, #f6edde 100%);
  font-family: "Hanken Grotesk", "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 1rem;
  line-height: 1.5;
}

button,
input,
textarea,
select {
  font: inherit;
}

button,
a,
input,
textarea,
select,
summary {
  -webkit-tap-highlight-color: transparent;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
summary:focus-visible {
  outline: 0.2rem solid rgba(115, 92, 0, 0.28);
  outline-offset: 0.15rem;
}

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

.material-symbols-outlined {
  display: inline-block;
  width: 1.4rem;
  max-width: 1.4rem;
  overflow: hidden;
  font-family: "Material Symbols Outlined";
  font-size: 1.4rem;
  font-style: normal;
  font-weight: 400;
  line-height: 1;
  font-variation-settings: "FILL" 0, "wght" 400, "GRAD" 0, "opsz" 24;
  text-transform: none;
  white-space: nowrap;
}

/* Access gate: P00 */
body.access-checking,
body.access-locked {
  background-color: var(--surface);
  background-image: radial-gradient(#d0c6ae 0.06rem, transparent 0.06rem), linear-gradient(135deg, #fff8f0, #fbf3e4 55%, #eae2d3);
  background-size: 1.5rem 1.5rem, 100% 100%;
}

.access-gate {
  padding: 1.5rem;
}

.access-card {
  position: relative;
  width: min(33rem, 100%);
  padding: 2.25rem;
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 2rem;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 1.25rem 3.75rem rgba(52, 48, 38, 0.09);
  backdrop-filter: blur(1.25rem);
  text-align: center;
}

.access-card::before {
  content: "rocket_launch";
  display: grid;
  width: 4rem;
  height: 4rem;
  margin: 0 auto 1.4rem;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.75);
  border-radius: 1.15rem;
  color: var(--primary);
  background: var(--primary-container);
  box-shadow: var(--shadow-soft);
  font-family: "Material Symbols Outlined";
  font-size: 2rem;
}

.access-card > .pill:first-child {
  display: none;
}

.access-card h2 {
  max-width: 14ch;
  margin: 0 auto 0.75rem;
  font-size: clamp(2rem, 6vw, 2.75rem);
  font-weight: 700;
  line-height: 1.08;
}

.access-card p {
  max-width: 32ch;
  margin: 0 auto 2rem;
  color: var(--muted);
  font-size: 1.05rem;
}

.access-card label {
  margin: 0.8rem 0 0.45rem;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
  text-align: left;
  text-transform: uppercase;
}

.access-card input {
  min-height: 3.5rem;
  border: 0;
  border-radius: 0.9rem;
  color: var(--ink);
  background: rgba(246, 237, 222, 0.72);
  box-shadow: inset 0 0 0 1px transparent;
}

.access-card input:focus {
  box-shadow: inset 0 0 0 0.13rem var(--primary);
}

.access-card .primary-btn,
.access-card .ghost-btn,
.access-sso-btn {
  width: 100%;
  min-height: 3.5rem;
  margin-top: 0.8rem;
  justify-content: center;
  border-radius: 999px;
}

.access-card .primary-btn,
.access-sso-btn {
  color: var(--ink);
  background: var(--primary-container);
}

.access-divider {
  color: var(--subtle);
}

/* App shell */
.app-shell {
  display: block;
  min-height: 100vh;
  background: transparent;
}

.sidebar {
  position: sticky;
  top: 0;
  z-index: 80;
  display: flex;
  width: 100%;
  height: 4.5rem;
  padding: 0.75rem 1rem;
  align-items: center;
  gap: 0.75rem;
  color: var(--ink);
  background: rgba(251, 243, 228, 0.94);
  border-right: 0;
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(1.25rem);
}

.brand-block {
  display: flex;
  min-width: 0;
  padding: 0;
  align-items: center;
  gap: 0.75rem;
  border: 0;
}

.brand-mark {
  display: grid;
  flex: 0 0 auto;
  width: 2.75rem;
  height: 2.75rem;
  place-items: center;
  border-radius: 0.9rem;
  color: var(--primary);
  background: var(--primary-container);
  font-size: 1.2rem;
  font-weight: 700;
}

.brand-block > div:last-child {
  min-width: 0;
}

.brand-label {
  margin: 0;
  color: var(--primary);
  font-size: 0.66rem;
  font-weight: 700;
  line-height: 1.1;
}

.brand-block h1 {
  margin: 0.1rem 0 0;
  overflow: hidden;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.brand-block p {
  display: none;
}

.mobile-nav-toggle {
  position: relative;
  z-index: 3;
  display: inline-flex;
  min-width: 3rem;
  min-height: 3rem;
  margin-left: auto;
  padding: 0;
  align-items: center;
  justify-content: center;
  gap: 0;
  border: 0;
  border-radius: 999px;
  color: var(--ink);
  background: var(--surface-high);
}

.mobile-nav-toggle span {
  font-size: 1.35rem;
}

.mobile-nav-toggle strong {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.main-nav {
  position: fixed;
  z-index: 2;
  inset: 4.5rem 0 auto 0;
  display: none;
  max-height: calc(100vh - 4.5rem);
  margin: 0;
  padding: 1rem;
  overflow: auto;
  background: rgba(251, 243, 228, 0.98);
  border-bottom: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.sidebar.nav-open .main-nav {
  display: grid;
}

.nav-section {
  margin: 0 0 0.9rem;
}

.nav-section > span {
  display: block;
  margin: 0 0 0.45rem;
  padding: 0 0.75rem;
  color: var(--subtle);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
}

.nav-item {
  position: relative;
  display: flex;
  width: 100%;
  min-height: 3rem;
  margin: 0.2rem 0;
  padding: 0.7rem 0.9rem;
  align-items: center;
  gap: 0.75rem;
  border: 0;
  border-radius: 0.8rem;
  color: var(--muted);
  background: transparent;
  font-size: 0.9rem;
  font-weight: 600;
  text-align: left;
}

.nav-item::before {
  content: attr(data-icon);
  flex: 0 0 auto;
  font-family: "Material Symbols Outlined";
  font-size: 1.35rem;
  font-variation-settings: "FILL" 0, "wght" 400, "GRAD" 0, "opsz" 24;
  width: 1.35rem;
  max-width: 1.35rem;
  overflow: hidden;
  white-space: nowrap;
}

.nav-item:hover,
.nav-item.active,
.nav-item.role-secondary.active,
.nav-item.role-secondary:hover {
  color: var(--primary);
  background: rgba(255, 213, 79, 0.24);
}

.nav-item.active {
  box-shadow: inset -0.25rem 0 0 var(--primary);
  font-weight: 700;
}

.nav-item.active::before {
  font-variation-settings: "FILL" 1, "wght" 500, "GRAD" 0, "opsz" 24;
}

.nav-item.role-recommended::after {
  display: none;
}

.nav-item.role-secondary {
  opacity: 1;
}

.side-status {
  display: none;
}

.main {
  min-width: 0;
  padding: 0 1rem 6rem;
}

.topbar {
  position: sticky;
  top: 4.5rem;
  z-index: 60;
  display: flex;
  min-height: auto;
  margin: 0 -1rem 1.5rem;
  padding: 1rem;
  align-items: flex-start;
  gap: 0.75rem;
  background: rgba(255, 248, 240, 0.86);
  border-bottom: 1px solid rgba(208, 198, 174, 0.55);
  backdrop-filter: blur(1.25rem);
}

.topbar > div:first-child {
  min-width: 0;
  flex: 1;
}

.topbar h2 {
  margin: 0;
  font-size: clamp(1.7rem, 8vw, 2.4rem);
  font-weight: 600;
  line-height: 1.1;
}

.topbar p:last-child {
  display: none;
}

.eyebrow {
  margin: 0 0 0.25rem;
  color: var(--primary);
  font-size: 0.7rem;
  font-weight: 700;
}

.topbar-actions {
  flex: 0 0 auto;
  flex-direction: row;
  align-items: center;
  gap: 0.5rem;
}

.topbar-icon {
  display: none;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  place-items: center;
  border: 0;
  border-radius: 999px;
  color: var(--primary);
  background: var(--panel-soft);
  overflow: hidden;
}

.identity-summary {
  max-width: 10rem;
}

.identity-summary > * {
  max-width: 100%;
}

.role-tabs {
  position: fixed;
  z-index: 90;
  right: 1rem;
  bottom: 0.75rem;
  left: 1rem;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.25rem;
  padding: 0.3rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 0.75rem 2rem rgba(52, 48, 38, 0.14);
  backdrop-filter: blur(1rem);
}

.role-tab {
  min-height: 2.75rem;
  padding: 0.5rem;
  border: 0;
  border-radius: 999px;
  color: var(--muted);
  background: transparent;
  font-size: 0.78rem;
  font-weight: 700;
}

.role-tab.active {
  color: var(--ink);
  background: var(--primary-container);
}

.route-brief {
  margin: 0 0 1rem;
}

.route-brief:empty {
  display: none;
}

.page {
  max-width: 100%;
}

.section-band {
  margin: 0 0 1.5rem;
  padding: 1.15rem;
  border: 1px solid rgba(255, 255, 255, 0.82);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.73);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(1.25rem);
}

.page > .section-band {
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
}

#page-identity > .section-band > .section-head,
#page-stages > .section-band:first-child > .section-head,
#page-tasks > .section-band > .section-head,
#page-quiz > .section-band > .section-head,
#page-formal > .section-band > .section-head,
#page-quality > .section-band > .section-head,
#page-progress > .section-band > .section-head {
  display: none;
}

#page-report > .section-band > .section-head > div:first-child {
  display: none;
}

.section-band.compact-top {
  margin-top: 0;
}

.section-head {
  margin-bottom: 1.25rem;
  align-items: flex-start;
  gap: 1rem;
}

.section-head h3 {
  margin: 0;
  color: var(--ink);
  font-size: clamp(1.4rem, 5vw, 2rem);
  font-weight: 600;
  line-height: 1.2;
}

.section-head p {
  max-width: 68ch;
  margin: 0.35rem 0 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.pill,
.tag {
  border-radius: 999px;
  color: var(--primary);
  background: rgba(255, 213, 79, 0.24);
}

.pill.warning,
.tag.warning {
  color: var(--danger);
  background: var(--danger-soft);
}

.primary-btn,
.ghost-btn,
.soft-btn,
.danger-btn {
  min-height: 2.9rem;
  border-radius: 999px;
  font-weight: 700;
}

.primary-btn {
  border: 1px solid var(--primary);
  color: #fff;
  background: var(--primary);
}

.primary-btn:hover {
  color: var(--ink);
  background: var(--primary-container);
  border-color: var(--primary-container);
}

.ghost-btn {
  border-color: var(--line);
  color: var(--ink);
  background: var(--surface-low);
}

.ghost-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--primary-soft);
}

input,
textarea,
select {
  min-height: 3rem;
  border-color: var(--line);
  border-radius: var(--radius-sm);
  color: var(--ink);
  background: rgba(246, 237, 222, 0.65);
}

textarea {
  min-height: 7.5rem;
}

table {
  border-collapse: separate;
  border-spacing: 0;
}

th {
  color: var(--muted);
  background: var(--surface-low);
  font-size: 0.72rem;
  text-transform: uppercase;
}

th,
td {
  border-color: var(--line-soft);
}

.panel,
.detail-panel,
.quiz-form,
.quiz-result,
.formal-exam-panel,
.formal-exam-form,
.formal-history-panel,
.formal-readiness-panel,
.progress-person-detail {
  border: 1px solid rgba(255, 255, 255, 0.88);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.8);
  box-shadow: var(--shadow-soft);
}

.panel-head {
  padding: 1.25rem;
  border-color: var(--line-soft);
}

.panel-head h4 {
  color: var(--ink);
  font-size: 1.25rem;
  font-weight: 600;
}

.panel-head p {
  color: var(--muted);
}

.panel-body {
  padding: 1.25rem;
}

.metric-grid {
  grid-template-columns: 1fr;
  gap: 0.9rem;
}

.metric {
  min-height: 8.75rem;
  padding: 1.25rem;
  border: 1px solid rgba(255, 255, 255, 0.85);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.76);
  box-shadow: var(--shadow-soft);
}

.metric-value {
  color: var(--ink);
  font-size: clamp(2.4rem, 12vw, 3.5rem);
  font-weight: 300;
  line-height: 1;
}

.metric-label {
  margin-top: 0.75rem;
  color: var(--muted);
  font-weight: 600;
}

.dashboard-stack,
.dashboard-grid,
.quality-grid,
.report-layout,
.quiz-layout {
  gap: 1.25rem;
}

/* Stitch shared components */
.stitch-page-hero {
  display: flex;
  margin-bottom: 1.5rem;
  flex-direction: column;
  gap: 1rem;
}

.stitch-page-hero h3 {
  max-width: 18ch;
  margin: 0;
  font-size: clamp(2.25rem, 8vw, 4rem);
  font-weight: 600;
  line-height: 1.08;
}

.stitch-page-hero p {
  max-width: 62ch;
  margin: 0.75rem 0 0;
  color: var(--muted);
  font-size: 1.05rem;
}

.stitch-glass {
  border: 1px solid rgba(255, 255, 255, 0.86);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.74);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(1.25rem);
}

.stitch-dark {
  color: var(--inverse-text);
  background: var(--inverse-2);
  border-color: rgba(255, 255, 255, 0.08);
  border-radius: var(--radius);
}

.stitch-stat {
  min-height: 8.5rem;
  padding: 1.35rem;
}

.stitch-stat-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  color: var(--muted);
}

.stitch-stat-icon {
  display: grid;
  width: 3rem;
  height: 3rem;
  place-items: center;
  border-radius: 999px;
  color: var(--primary);
  background: rgba(255, 213, 79, 0.24);
}

.stitch-stat-icon.danger {
  color: var(--danger);
  background: rgba(255, 218, 214, 0.62);
}

.stitch-stat-icon.success {
  color: var(--green);
  background: var(--green-soft);
}

.stitch-stat-value {
  margin-top: 1.15rem;
  font-size: 2.8rem;
  font-weight: 300;
  line-height: 1;
}

.stitch-progress {
  height: 0.55rem;
  overflow: hidden;
  border-radius: 999px;
  background: var(--surface-highest);
}

.stitch-progress > span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--primary);
}

.stitch-empty {
  display: grid;
  min-height: 13rem;
  padding: 2rem;
  place-items: center;
  border: 1px dashed var(--line);
  border-radius: var(--radius-md);
  color: var(--muted);
  background: rgba(251, 243, 228, 0.55);
  text-align: center;
}

/* P01 registration */
.stitch-registration-layout {
  display: grid;
  gap: 1.25rem;
}

.stitch-registration-main,
.stitch-registration-aside {
  padding: 1.25rem;
}

.stitch-stepper {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-bottom: 1.75rem;
}

.stitch-step {
  position: relative;
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 0.55rem;
  color: var(--subtle);
  font-size: 0.78rem;
}

.stitch-step::after {
  content: "";
  height: 1px;
  margin: 0 0.5rem;
  flex: 1;
  background: var(--line);
}

.stitch-step:last-child::after {
  display: none;
}

.stitch-step span {
  display: grid;
  flex: 0 0 auto;
  width: 2rem;
  height: 2rem;
  place-items: center;
  border-radius: 999px;
  background: var(--surface-high);
}

.stitch-step.active {
  color: var(--ink);
}

.stitch-step.active span {
  color: #fff;
  background: var(--primary);
}

.stitch-form-grid {
  display: grid;
  gap: 1rem;
}

.stitch-field label,
.stitch-field > span {
  display: block;
  margin-bottom: 0.45rem;
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
}

.stitch-field input,
.stitch-field select {
  width: 100%;
}

.stitch-role-grid {
  display: grid;
  gap: 0.75rem;
}

.stitch-role-card {
  display: grid;
  min-height: 9.25rem;
  padding: 1rem;
  place-items: center;
  border: 2px solid transparent;
  border-radius: var(--radius-md);
  color: var(--ink);
  background: rgba(246, 237, 222, 0.68);
  text-align: center;
  cursor: pointer;
}

.stitch-role-card:has(input:checked) {
  border-color: var(--primary);
  background: rgba(255, 213, 79, 0.12);
}

.stitch-role-card input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.stitch-role-card .material-symbols-outlined {
  display: grid;
  width: 3.2rem;
  height: 3.2rem;
  place-items: center;
  border-radius: 999px;
  color: var(--primary);
  background: var(--primary-container);
}

.stitch-role-card strong {
  display: block;
  margin-top: 0.6rem;
  font-size: 1.05rem;
}

.stitch-role-card small {
  color: var(--muted);
}

.stitch-form-actions {
  display: flex;
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.75rem;
  border-top: 1px solid var(--line-soft);
}

.stitch-registration-aside {
  display: flex;
  min-height: 25rem;
  flex-direction: column;
  background: rgba(251, 243, 228, 0.82);
}

.stitch-aside-head {
  display: flex;
  margin-bottom: 1rem;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.stitch-aside-head h4 {
  margin: 0;
  font-size: 1.2rem;
}

.stitch-aside-head p {
  margin: 0.2rem 0 0;
  color: var(--muted);
}

.stitch-registration-list {
  display: grid;
  gap: 0.75rem;
}

.stitch-person-row {
  display: grid;
  grid-template-columns: 2.9rem minmax(0, 1fr) auto;
  padding: 0.85rem;
  align-items: center;
  gap: 0.8rem;
  border: 1px solid rgba(255, 255, 255, 0.82);
  border-radius: 1.25rem;
  background: rgba(255, 255, 255, 0.68);
}

.stitch-avatar {
  display: grid;
  width: 2.9rem;
  height: 2.9rem;
  place-items: center;
  border: 2px solid var(--primary-container);
  border-radius: 999px;
  color: var(--primary);
  background: var(--primary-soft);
  font-weight: 700;
}

.stitch-person-row strong,
.stitch-person-row span {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.stitch-person-row span {
  color: var(--muted);
  font-size: 0.82rem;
}

/* P02 dashboard */
.stitch-dashboard {
  display: grid;
  gap: 1.25rem;
}

.stitch-dashboard-hero h3 {
  margin: 0;
  font-size: clamp(2rem, 8vw, 3.7rem);
  font-weight: 600;
  line-height: 1.08;
}

.stitch-dashboard-hero p {
  margin: 0.55rem 0 0;
  color: var(--muted);
  font-size: 1.05rem;
}

.stitch-dashboard-stats,
.stitch-dashboard-main {
  display: grid;
  gap: 1rem;
}

.stitch-next-card {
  display: flex;
  min-height: 20rem;
  padding: 1.5rem;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.stitch-next-orbit {
  display: grid;
  width: 7.5rem;
  height: 7.5rem;
  margin-bottom: 1.2rem;
  place-items: center;
  border: 0.35rem solid var(--primary-container);
  border-radius: 999px;
  color: var(--primary-container);
  background: rgba(255, 255, 255, 0.08);
}

.stitch-next-orbit .material-symbols-outlined {
  font-size: 3rem;
}

.stitch-next-card h4 {
  margin: 0;
  color: #fff;
  font-size: 1.35rem;
}

.stitch-next-card p {
  color: #d9d0bf;
}

.stitch-next-card .primary-btn {
  width: 100%;
  margin-top: 1rem;
  color: var(--ink);
  background: var(--primary-container);
  border-color: var(--primary-container);
}

.stitch-path-card,
.stitch-pending-card,
.stitch-schedule-card {
  padding: 1.5rem;
}

.stitch-path-card h4,
.stitch-pending-card h4,
.stitch-schedule-card h4 {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 500;
}

.stitch-day-line {
  position: relative;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  margin: 2.2rem 0;
}

.stitch-day-line::before {
  content: "";
  position: absolute;
  top: 1rem;
  right: 5%;
  left: 5%;
  height: 0.25rem;
  border-radius: 999px;
  background: var(--surface-highest);
}

.stitch-day {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: center;
  gap: 0.45rem;
  color: var(--muted);
}

.stitch-day b {
  display: grid;
  width: 2rem;
  height: 2rem;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
}

.stitch-day.done b {
  color: #fff;
  background: var(--primary);
  border-color: var(--primary);
}

.stitch-day.current b {
  color: var(--ink);
  background: var(--primary-container);
  border-color: var(--primary-container);
  box-shadow: 0 0 0 0.3rem #fff;
}

.stitch-pending-card {
  color: var(--inverse-text);
}

.stitch-pending-count {
  float: right;
  color: var(--primary-fixed);
  font-size: 2.4rem;
  font-weight: 300;
}

.stitch-pending-list {
  display: grid;
  margin-top: 1.5rem;
  gap: 0.75rem;
}

.stitch-pending-item {
  display: grid;
  grid-template-columns: 1.8rem minmax(0, 1fr);
  padding: 0.9rem;
  gap: 0.7rem;
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.08);
}

.stitch-pending-item small {
  display: block;
  margin-top: 0.2rem;
  color: #bbb2a2;
}

.stitch-schedule {
  position: relative;
  min-height: 10rem;
  margin-top: 1.2rem;
  border-left: 1px solid var(--line-soft);
}

.stitch-schedule-event {
  width: min(17rem, calc(100% - 1rem));
  margin: 1rem;
  padding: 1rem;
  border-radius: 1rem;
  color: var(--inverse-text);
  background: var(--inverse-2);
}

/* P06 5-day path */
.stitch-stage-tabs {
  display: flex;
  margin: 0 -0.25rem 1.5rem;
  padding: 0.25rem;
  gap: 0.5rem;
  overflow-x: auto;
  scrollbar-width: none;
}

.stitch-stage-tab {
  flex: 0 0 auto;
  min-width: 10.5rem;
  min-height: 3.1rem;
  padding: 0.75rem 1rem;
  border: 1px solid transparent;
  border-radius: 999px;
  color: var(--muted);
  background: var(--surface-high);
  font-size: 0.8rem;
  font-weight: 700;
}

.stitch-stage-tab.active {
  color: var(--ink);
  background: var(--primary-container);
  box-shadow: 0 0 0 0.15rem #fff;
}

.stitch-stage-layout {
  display: grid;
  gap: 1rem;
}

.stitch-objective-card,
.stitch-action-card {
  padding: 1.35rem;
}

.stitch-objective-card h4,
.stitch-action-card h4 {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 500;
}

.stitch-objective-card > p {
  max-width: 65ch;
  color: var(--muted);
  font-size: 1.05rem;
}

.stitch-focus-grid,
.stitch-learning-cards {
  display: grid;
  gap: 0.8rem;
}

.stitch-focus-item {
  padding: 1rem;
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.78);
}

.stitch-focus-item span {
  display: block;
  color: var(--primary);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
}

.stitch-focus-item strong {
  display: block;
  margin-top: 0.25rem;
}

.stitch-learning-card {
  display: flex;
  min-height: 13rem;
  padding: 1.25rem;
  flex-direction: column;
  justify-content: space-between;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.72);
}

.stitch-learning-card.dark {
  color: var(--inverse-text);
  background: var(--inverse);
  border-color: var(--inverse);
}

.stitch-learning-card h5 {
  margin: 0.75rem 0 0.35rem;
  font-size: 1.2rem;
}

.stitch-learning-card p {
  color: inherit;
  opacity: 0.76;
}

.stitch-action-list {
  display: grid;
  margin-top: 1rem;
  gap: 0.7rem;
}

.stitch-action-item {
  display: grid;
  grid-template-columns: 1.7rem minmax(0, 1fr);
  padding: 0.85rem;
  gap: 0.65rem;
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.66);
}

.stitch-action-item.done {
  color: var(--subtle);
  text-decoration: line-through;
}

.stitch-ring {
  --value: 0;
  display: grid;
  width: 5.1rem;
  height: 5.1rem;
  place-items: center;
  border-radius: 999px;
  color: var(--primary);
  background: conic-gradient(var(--primary) calc(var(--value) * 1%), var(--surface-high) 0);
  box-shadow: inset 0 0 0 0.8rem #fff;
}

.stitch-stage-details,
.stitch-report-details {
  overflow: hidden;
}

.stitch-stage-details > summary,
.stitch-report-details > summary {
  display: flex;
  min-height: 3.75rem;
  padding: 1rem 1.25rem;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  color: var(--primary);
  font-weight: 700;
  cursor: pointer;
  list-style: none;
}

.stitch-stage-details > summary::-webkit-details-marker,
.stitch-report-details > summary::-webkit-details-marker {
  display: none;
}

.stitch-stage-details[open] > summary,
.stitch-report-details[open] > summary {
  border-bottom: 1px solid var(--line-soft);
}

.stitch-stage-details .stage-rich,
.stitch-report-details > div {
  padding: 1.25rem;
}

#page-stages > .section-band:nth-of-type(2) > .section-head,
#page-stages > .section-band:nth-of-type(2) > .table-wrap {
  display: none;
}

#page-stages .section-band.compact-top {
  margin-top: 0;
}

/* P07 task detail */
.stitch-task-header {
  display: flex;
  margin-bottom: 1.5rem;
  flex-direction: column;
  gap: 1rem;
}

.stitch-task-header h3 {
  max-width: 22ch;
  margin: 0.45rem 0 0;
  font-size: clamp(2rem, 8vw, 3.6rem);
  font-weight: 600;
  line-height: 1.08;
}

.stitch-crumb {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 700;
}

.stitch-feedback {
  display: grid;
  margin-bottom: 1.25rem;
  padding: 1.25rem;
  grid-template-columns: 2.8rem minmax(0, 1fr);
  gap: 1rem;
  border: 1px solid rgba(186, 26, 26, 0.22);
  border-radius: var(--radius-md);
  color: #93000a;
  background: rgba(255, 218, 214, 0.5);
}

.stitch-feedback h4 {
  margin: 0;
  font-size: 1.3rem;
}

.stitch-feedback p {
  margin: 0.35rem 0 0;
  color: var(--muted);
}

.stitch-task-layout {
  display: grid;
  gap: 1rem;
}

#page-tasks .module-guide {
  margin-bottom: 1rem;
}

#page-tasks #taskGuide,
#page-quiz #quizGuide,
#page-progress #progressGuide,
#page-report #reportGuide {
  display: none;
}

#page-tasks .task-layout {
  display: block;
}

#page-tasks .task-list {
  display: flex;
  margin-bottom: 1rem;
  padding: 0.25rem 0.1rem 0.65rem;
  gap: 0.75rem;
  overflow-x: auto;
  scroll-snap-type: x proximity;
}

#page-tasks .task-card {
  flex: 0 0 min(20rem, 82vw);
  min-height: 9.5rem;
  border: 1px solid var(--line-soft);
  border-radius: 1.25rem;
  background: rgba(255, 255, 255, 0.66);
  scroll-snap-align: start;
}

#page-tasks .task-card.active {
  border-color: var(--primary);
  background: rgba(255, 213, 79, 0.11);
  box-shadow: inset 0 -0.2rem 0 var(--primary);
}

#page-tasks #taskDetail {
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.stitch-task-submission {
  display: flex;
  flex-direction: column;
}

.stitch-task-brief,
.stitch-task-submission {
  padding: 1.25rem;
}

.stitch-card-title {
  display: flex;
  margin: 0 0 1.1rem;
  padding-bottom: 0.85rem;
  align-items: center;
  gap: 0.65rem;
  border-bottom: 1px solid var(--line-soft);
  font-size: 1.25rem;
  font-weight: 600;
}

.stitch-card-title .material-symbols-outlined {
  color: var(--primary);
}

.stitch-task-block {
  margin-top: 1.25rem;
}

.stitch-task-block h5 {
  margin: 0 0 0.55rem;
  color: var(--primary);
  font-size: 0.76rem;
  text-transform: uppercase;
}

.stitch-task-block p,
.stitch-task-block li {
  color: var(--muted);
}

.stitch-task-block li + li {
  margin-top: 0.5rem;
}

.stitch-source-data {
  padding: 1rem;
  border-radius: 0.8rem;
  background: var(--surface-high);
}

.stitch-upload {
  display: grid;
  min-height: 9.5rem;
  padding: 1.25rem;
  place-items: center;
  border: 2px dashed var(--line);
  border-radius: 0.9rem;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.38);
  text-align: center;
}

/* P10 assessment and question components */
.quiz-layout,
.report-layout {
  grid-template-columns: 1fr;
}

.quiz-form {
  padding: 1.1rem;
}

.quiz-toolbar {
  border-radius: var(--radius-md);
  background: var(--surface-low);
}

.question-card,
.formal-question {
  margin-bottom: 1rem;
  padding: 1.25rem;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.76);
}

.question-card h4,
.formal-question h4 {
  font-size: 1.1rem;
  line-height: 1.5;
}

.option-list {
  display: grid;
  gap: 0.75rem;
}

.option-list label {
  min-height: 3.4rem;
  margin: 0;
  padding: 0.9rem 1rem;
  border: 1px solid var(--line-soft);
  border-radius: 1rem;
  background: rgba(255, 248, 240, 0.62);
}

.option-list label:hover,
.option-list label:has(input:checked) {
  border-color: var(--primary);
  background: rgba(255, 213, 79, 0.1);
  box-shadow: 0 0.4rem 1.25rem rgba(115, 92, 0, 0.06);
}

.option-list input {
  min-width: 1.25rem;
  min-height: 1.25rem;
  accent-color: var(--primary);
}

.quiz-result {
  padding: 1.25rem;
}

.stitch-assessment-head {
  display: flex;
  margin-bottom: 1.25rem;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.stitch-assessment-head h3 {
  margin: 0;
  font-size: clamp(2rem, 9vw, 3.6rem);
  font-weight: 600;
  line-height: 1.05;
}

.stitch-assessment-head p {
  margin: 0.45rem 0 0;
  color: var(--muted);
}

.stitch-timer {
  flex: 0 0 auto;
  text-align: right;
}

.stitch-timer span {
  display: block;
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
}

.stitch-timer strong {
  color: var(--primary);
  font-size: clamp(1.8rem, 7vw, 3.5rem);
  font-weight: 300;
  line-height: 1;
}

.stitch-assessment-progress {
  margin-bottom: 1.25rem;
}

.stitch-assessment-question {
  display: none;
  min-height: 25rem;
  padding: 1.25rem;
}

.stitch-assessment-question.active {
  display: block;
}

.stitch-assessment-question > h4 {
  margin: 2rem 0 1.5rem;
  font-size: clamp(1.15rem, 4vw, 1.7rem);
  font-weight: 500;
  line-height: 1.45;
}

.stitch-assessment-actions {
  display: flex;
  margin-top: 1rem;
  padding-top: 1rem;
  justify-content: space-between;
  gap: 0.75rem;
  border-top: 1px solid var(--line-soft);
}

.stitch-assessment-actions button {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}

.stitch-assessment-actions button[hidden] {
  display: none;
}

.stitch-assessment-actions button:disabled {
  opacity: 0.35;
}

.quiz-scope-switch {
  display: flex;
  padding: 0.3rem;
  gap: 0.35rem;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface-high);
}

.quiz-scope-button {
  flex: 0 0 auto;
  min-width: 10rem;
  border: 0;
  border-radius: 999px;
}

.quiz-scope-button.active {
  color: #fff;
  background: var(--primary);
}

/* P11 formal exam */
.formal-entry-card,
.formal-management-intro,
.learning-progress-control {
  border-radius: var(--radius-md);
}

.formal-exam-page-layout {
  gap: 1.25rem;
}

.formal-readiness-panel {
  padding: 1.25rem;
  color: var(--inverse-text);
  background: var(--inverse);
  border-color: var(--inverse);
}

.formal-readiness-panel h4 {
  color: #fff;
}

.formal-history-panel {
  padding: 1.25rem;
}

.formal-result-strip {
  border-radius: 1rem;
}

.formal-exam-form {
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.formal-exam-panel.active {
  display: grid;
  gap: 1rem;
}

.formal-question-progress {
  position: sticky;
  top: 0.75rem;
  z-index: 3;
  display: grid;
  gap: 0.75rem;
  padding: 1rem 1.15rem;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(12px);
}

.formal-question-progress > div:first-child {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.formal-question-progress strong {
  color: var(--ink);
  font-size: 1rem;
}

.formal-question-progress span {
  color: var(--muted);
  font-size: 0.82rem;
}

.formal-question {
  display: none;
  min-height: 26rem;
  margin: 0;
}

.formal-question.active {
  display: block;
}

.formal-open-case,
.formal-open-requirements {
  margin: 1rem 0;
  padding: 1rem;
  border-left: 3px solid var(--primary);
  background: var(--surface-low);
}

.formal-open-case strong,
.formal-open-requirements strong {
  display: block;
  margin-bottom: 0.45rem;
  color: var(--ink);
}

.formal-open-case p,
.formal-open-requirements ul {
  margin: 0;
  color: var(--muted);
  line-height: 1.75;
}

.formal-open-requirements ul {
  padding-left: 1.25rem;
}

.option-list label.formal-open-answer {
  display: grid;
  width: 100%;
  max-width: 100%;
  grid-template-columns: minmax(0, 1fr);
  gap: 0.6rem;
  min-height: 0;
  padding: 0;
  border: 0;
  background: transparent;
}

.option-list label.formal-open-answer:hover {
  border: 0;
  background: transparent;
  box-shadow: none;
}

.formal-open-answer textarea {
  width: 100%;
  max-width: 100%;
  min-height: 17rem;
  resize: vertical;
  padding: 1rem;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-md);
  background: #fff;
  color: var(--ink);
  font: inherit;
  line-height: 1.7;
}

.formal-open-answer textarea:focus {
  border-color: var(--primary);
  outline: 3px solid rgba(255, 197, 44, 0.18);
}

.formal-open-answer small {
  color: var(--muted);
  line-height: 1.5;
}

.formal-question-actions {
  display: flex;
  min-height: 3rem;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.formal-question-actions [hidden] {
  display: none;
}

@media (max-width: 640px) {
  .formal-question-progress {
    top: 0.5rem;
  }

  .formal-question-progress > div:first-child {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.25rem;
  }

  .formal-question {
    min-height: 24rem;
    padding: 1rem;
  }

  .formal-open-answer textarea {
    min-height: 20rem;
  }

  .formal-question-actions button {
    min-width: 0;
    flex: 1 1 0;
  }
}

.stitch-formal-overview {
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.stitch-formal-head {
  display: flex;
  margin-bottom: 1.5rem;
  flex-direction: column;
  gap: 1rem;
}

.stitch-formal-head h3 {
  margin: 0;
  font-size: clamp(2.3rem, 9vw, 4rem);
  font-weight: 600;
  line-height: 1.05;
}

.stitch-formal-head p {
  max-width: 60ch;
  margin: 0.65rem 0 0;
  color: var(--muted);
  font-size: 1.05rem;
}

.stitch-formal-head > .pill {
  display: inline-flex;
  align-self: flex-start;
  align-items: center;
  gap: 0.4rem;
}

.stitch-formal-layout {
  display: grid;
  gap: 1rem;
}

.stitch-exam-rules {
  padding: 1.35rem;
}

.stitch-exam-rules ul {
  display: grid;
  padding: 0;
  gap: 1rem;
  list-style: none;
}

.stitch-exam-rules li {
  display: grid;
  grid-template-columns: 1.5rem minmax(0, 1fr);
  gap: 0.7rem;
  color: var(--muted);
}

.stitch-exam-rules li > .material-symbols-outlined {
  color: var(--primary);
}

.stitch-exam-rules li.danger > .material-symbols-outlined {
  color: var(--danger);
}

.stitch-final-hurdle {
  display: flex;
  min-height: 24rem;
  padding: 1.5rem;
  flex-direction: column;
  border-radius: var(--radius);
}

.stitch-final-hurdle h4 {
  margin: 1.25rem 0 0.35rem;
  color: #fff;
  font-size: 1.65rem;
}

.stitch-final-hurdle p {
  color: #cec5b5;
}

.stitch-final-hurdle > div:not(.stitch-hurdle-number) {
  margin-top: 1rem;
}

.stitch-final-hurdle > div > span,
.stitch-final-hurdle > div > strong {
  display: block;
}

.stitch-final-hurdle > div > strong {
  color: var(--primary-fixed);
}

.stitch-hurdle-number {
  margin-top: auto;
  padding: 1.25rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 1rem;
  color: var(--inverse-text);
  font-size: 4rem;
  font-weight: 300;
}

.stitch-hurdle-number small {
  font-size: 1.3rem;
}

.stitch-exam-preview {
  margin-top: 1.5rem;
}

.stitch-exam-preview h4 {
  font-size: 1.45rem;
  font-weight: 500;
}

.stitch-exam-preview > div {
  display: grid;
  gap: 0.75rem;
}

.stitch-exam-preview article {
  display: grid;
  min-height: 8.5rem;
  padding: 1.15rem;
  align-content: start;
  gap: 0.5rem;
  border: 1px solid var(--line-soft);
  border-radius: 1rem;
  background: rgba(251, 243, 228, 0.72);
}

.stitch-exam-preview article strong {
  margin-top: 0.4rem;
}

.stitch-exam-preview article > span:last-child {
  color: var(--muted);
}

/* P12 progress */
.progress-filter-grid {
  grid-template-columns: 1fr;
}

.stitch-progress-metrics,
.stitch-quality-metrics {
  display: grid;
  margin-bottom: 1.25rem;
  gap: 0.85rem;
}

.progress-duplicate-metrics {
  display: none;
}

.progress-person-head {
  align-items: flex-start;
}

.progress-person-detail {
  padding: 1rem;
}

.progress-rule-grid,
.readiness-summary-grid,
.process-score-grid,
.data-health-grid {
  gap: 0.8rem;
}

.progress-day-card,
.readiness-card,
.process-score-card,
.data-health-card {
  border-radius: var(--radius-md);
  background: rgba(251, 243, 228, 0.62);
}

/* P13 quality */
.quality-grid {
  grid-template-columns: 1fr;
}

.stitch-quality-tabs {
  display: flex;
  margin-bottom: 1.25rem;
  padding: 0.3rem;
  gap: 0.3rem;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface-high);
}

.stitch-quality-tabs button {
  flex: 0 0 auto;
  min-height: 2.65rem;
  padding: 0.55rem 1rem;
  border: 0;
  border-radius: 999px;
  color: var(--muted);
  background: transparent;
  font-size: 0.78rem;
  font-weight: 700;
}

.stitch-quality-tabs button.active {
  color: #fff;
  background: var(--primary);
}

.stitch-quality-panel {
  display: none;
}

.stitch-quality-panel.active {
  display: block;
}

.stitch-quality-panel > .panel,
.stitch-quality-panel > .quality-grid,
.stitch-quality-panel > .governance-panel {
  margin-bottom: 1rem;
}

.quality-grid .panel,
.governance-panel,
.role-auth-panel {
  border-radius: var(--radius);
}

.admin-login-grid,
.permission-grid,
.governance-grid,
.formal-unlock-grid {
  gap: 0.8rem;
}

/* P14 report */
.report-subject-panel,
.report-evidence-card,
.graduation-decision-card,
.permission-card {
  border-radius: var(--radius-md);
}

.stitch-report-hero {
  display: flex;
  margin: 1rem 0 1.5rem;
  flex-direction: column;
  gap: 1rem;
}

.stitch-report-hero h3 {
  margin: 0;
  font-size: clamp(2.3rem, 9vw, 4rem);
  font-weight: 600;
  line-height: 1.05;
}

.stitch-report-hero p {
  margin: 0.6rem 0 0;
  color: var(--muted);
}

.stitch-report-head-stats {
  display: flex;
  gap: 1.5rem;
}

.stitch-report-head-stats > span {
  display: flex;
  flex-direction: column;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
}

.stitch-report-head-stats strong {
  color: var(--ink);
  font-size: 2.6rem;
  font-weight: 300;
  line-height: 1;
}

.stitch-report-head-stats small {
  font-size: 1.1rem;
}

.stitch-report-primary,
.stitch-report-lower {
  display: grid;
  gap: 1rem;
}

.stitch-report-profile,
.stitch-report-radar-card,
.stitch-report-evidence,
.stitch-mentor-conclusion {
  padding: 1.35rem;
}

.stitch-report-person {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.stitch-report-avatar {
  display: grid;
  flex: 0 0 auto;
  width: 5rem;
  height: 5rem;
  place-items: center;
  border: 0.2rem solid var(--primary-container);
  border-radius: 1.25rem;
  color: var(--primary);
  background: var(--primary-soft);
  font-size: 1.35rem;
  font-weight: 700;
}

.stitch-report-person strong,
.stitch-report-person em {
  display: block;
}

.stitch-report-person strong {
  font-size: 1.35rem;
}

.stitch-report-person em {
  margin-top: 0.25rem;
  color: var(--muted);
  font-style: normal;
}

.stitch-report-readiness {
  display: flex;
  margin-top: 8rem;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
}

.stitch-report-readiness span {
  color: var(--muted);
}

.stitch-report-readiness strong {
  font-size: 2rem;
  font-weight: 500;
}

.stitch-report-profile > .stitch-progress {
  margin-top: 0.6rem;
}

.stitch-report-profile > p {
  color: var(--muted);
}

.stitch-report-radar-card h4,
.stitch-report-evidence h4,
.stitch-mentor-conclusion h4 {
  margin: 0 0 1rem;
  font-size: 1.45rem;
  font-weight: 500;
}

.stitch-radar-layout {
  display: grid;
  gap: 1rem;
}

.stitch-radar {
  display: block;
  width: min(100%, 24rem);
  margin: auto;
  overflow: visible;
}

.stitch-radar text {
  fill: var(--ink);
  font-family: inherit;
  font-size: 0.75rem;
  font-weight: 600;
}

.stitch-radar-area {
  fill: rgba(255, 213, 79, 0.52);
  stroke: var(--primary);
  stroke-width: 3;
  stroke-linejoin: round;
}

.stitch-radar circle {
  fill: var(--primary);
}

.stitch-radar-scores {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}

.stitch-radar-scores > div {
  padding: 0.9rem;
  border: 1px solid var(--line-soft);
  border-radius: 1rem;
  background: rgba(246, 237, 222, 0.72);
}

.stitch-radar-scores span,
.stitch-radar-scores strong {
  display: block;
}

.stitch-radar-scores span {
  color: var(--muted);
  font-size: 0.78rem;
}

.stitch-radar-scores i {
  display: inline-block;
  width: 0.5rem;
  height: 0.5rem;
  margin-right: 0.35rem;
  border-radius: 999px;
  background: var(--primary);
}

.stitch-radar-scores strong {
  margin-top: 0.25rem;
  font-size: 1.5rem;
  font-weight: 400;
}

.stitch-report-lower {
  margin-top: 1rem;
}

.stitch-report-evidence .report-evidence-section {
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
}

.stitch-report-evidence .report-evidence-section > h5 {
  display: none;
}

.stitch-mentor-conclusion blockquote {
  margin: 0;
  padding: 1.35rem;
  border-left: 0.25rem solid var(--primary);
  border-radius: 1.25rem;
  color: var(--muted);
  background: rgba(251, 243, 228, 0.78);
  font-size: 1.05rem;
  font-style: italic;
  line-height: 1.7;
}

.stitch-mentor-conclusion .stitch-person-row {
  margin-top: 1rem;
}

.stitch-report-details {
  margin-top: 1rem;
}

.stitch-authorization-card {
  display: flex;
  min-height: 31rem;
  padding: 1.5rem;
  flex-direction: column;
  color: var(--inverse-text);
  border-radius: var(--radius);
  background: var(--inverse);
}

.stitch-authorization-card h4 {
  margin: 1.5rem 0 0.45rem;
  color: #fff;
  font-size: 1.7rem;
}

.stitch-authorization-card p {
  color: #cfc7b8;
}

.stitch-clearance {
  margin-top: auto;
  padding: 1.15rem;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.08);
}

.stitch-clearance span,
.stitch-clearance strong {
  display: block;
}

.stitch-clearance span {
  color: #bdb5a7;
  font-size: 0.72rem;
  text-transform: uppercase;
}

.stitch-clearance strong {
  margin-top: 0.35rem;
  color: var(--primary-fixed);
  font-size: 1.35rem;
}

.stitch-authorization-card .primary-btn {
  margin-top: 1.25rem;
  color: var(--ink);
  background: var(--primary-container);
  border-color: var(--primary-container);
}

#graduationAdvice {
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

#page-report .report-layout {
  display: block;
}

#page-report #graduationAdvice {
  width: min(100%, 24rem);
  margin: 1rem 0 0 auto;
}

#page-report .stitch-authorization-card {
  min-height: 28rem;
}

.guide-hero,
.command-hero,
.command-hero.mentor,
.command-hero.manager {
  color: var(--inverse-text);
  background: var(--inverse);
  border-color: rgba(255, 255, 255, 0.08);
  border-radius: var(--radius);
}

.guide-hero p,
.command-hero p,
.command-hero-grid span {
  color: #d8cfbf;
}

.command-hero-grid div {
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.07);
}

.report-evidence-grid {
  grid-template-columns: 1fr;
}

.report-score {
  font-size: clamp(3rem, 13vw, 5rem);
  font-weight: 300;
}

.graduation-advice {
  color: var(--inverse-text);
  background: var(--inverse);
}

.toast {
  right: 1rem;
  bottom: 5rem;
  left: 1rem;
  border-radius: 999px;
  color: var(--inverse-text);
  background: var(--inverse);
  text-align: center;
}

@media (min-width: 640px) {
  .main {
    padding-right: 1.5rem;
    padding-left: 1.5rem;
  }

  .topbar {
    margin-right: -1.5rem;
    margin-left: -1.5rem;
    padding-right: 1.5rem;
    padding-left: 1.5rem;
  }

  .section-band,
  .stitch-registration-main,
  .stitch-registration-aside,
  .stitch-objective-card,
  .stitch-action-card,
  .stitch-task-brief,
  .stitch-task-submission {
    padding: 1.75rem;
  }

  .metric-grid,
  .stitch-dashboard-stats,
  .stitch-form-grid,
  .stitch-focus-grid,
  .stitch-learning-cards,
  .report-evidence-grid,
  .stitch-progress-metrics,
  .stitch-quality-metrics,
  .stitch-exam-preview > div {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .stitch-role-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .stitch-task-header,
  .stitch-page-hero {
    flex-direction: row;
    align-items: flex-end;
    justify-content: space-between;
  }
}

@media (min-width: 768px) {
  .topbar p:last-child {
    display: block;
  }

  .identity-summary {
    max-width: none;
  }

  .topbar-icon {
    display: grid;
  }

  .quiz-layout {
    grid-template-columns: minmax(0, 1fr) 19rem;
  }

  .quiz-result {
    position: sticky;
    top: 7rem;
    align-self: start;
  }

  .stitch-stage-layout {
    grid-template-columns: minmax(0, 1fr) 18rem;
  }

  .stitch-formal-head,
  .stitch-report-hero {
    flex-direction: row;
    align-items: flex-end;
    justify-content: space-between;
  }

  .stitch-formal-head > .pill {
    align-self: center;
  }

  .stitch-formal-layout {
    grid-template-columns: minmax(0, 1.6fr) minmax(18rem, 0.72fr);
  }

  .stitch-radar-layout {
    grid-template-columns: minmax(19rem, 1.25fr) minmax(14rem, 0.75fr);
    align-items: center;
  }

  .stitch-dashboard-stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .stitch-dashboard-main {
    grid-template-columns: minmax(13rem, 0.72fr) minmax(20rem, 1.25fr);
  }

  .stitch-pending-card {
    grid-column: 1 / -1;
  }
}

@media (min-width: 1024px) {
  .app-shell {
    display: grid;
    grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
  }

  .sidebar {
    position: sticky;
    top: 0;
    display: flex;
    width: var(--sidebar-width);
    height: 100vh;
    padding: 2rem 1rem;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    border-right: 1px solid var(--line);
    border-bottom: 0;
    overflow: hidden;
  }

  .brand-block {
    padding: 0 0.5rem 1.5rem;
    align-items: flex-start;
  }

  .brand-mark {
    width: 3.25rem;
    height: 3.25rem;
  }

  .brand-label {
    font-size: 0.7rem;
  }

  .brand-block h1 {
    margin-top: 0.25rem;
    font-size: 1.12rem;
  }

  .brand-block p {
    display: block;
    margin: 0.25rem 0 0;
    padding: 0;
    border: 0;
    color: var(--muted);
    background: transparent;
    font-size: 0.78rem;
  }

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

  .main-nav,
  .sidebar.nav-open .main-nav {
    position: static;
    display: block;
    flex: 1;
    max-height: none;
    margin: 0 -0.25rem;
    padding: 0 0.25rem;
    overflow-y: auto;
    background: transparent;
    border: 0;
    box-shadow: none;
  }

  .nav-section > span {
    margin-top: 1rem;
  }

  .nav-item {
    min-height: 2.7rem;
    padding-top: 0.58rem;
    padding-bottom: 0.58rem;
    font-size: 0.84rem;
  }

  .side-status {
    display: block;
    margin: 1rem 0.25rem 0;
    padding: 0.9rem;
    border: 1px solid var(--line);
    border-radius: 1rem;
    color: var(--muted);
    background: rgba(255, 255, 255, 0.46);
    font-size: 0.7rem;
  }

  .side-status strong {
    color: var(--ink);
  }

  .main {
    padding: 0 2rem 3rem;
  }

  .topbar {
    top: 0;
    min-height: var(--topbar-height);
    margin: 0 -2rem 2rem;
    padding: 1rem 2rem;
    align-items: center;
  }

  .topbar h2 {
    font-size: 2rem;
  }

  .role-tabs {
    position: static;
    width: auto;
    min-width: 20rem;
    box-shadow: none;
  }

  .role-tab {
    min-width: 6rem;
  }

  .route-brief {
    margin-bottom: 1.25rem;
  }

  .section-band {
    padding: 2rem;
  }

  .metric-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .metric-grid.three {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .dashboard-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .stitch-registration-layout {
    grid-template-columns: minmax(0, 2fr) minmax(19rem, 0.92fr);
  }

  .stitch-registration-main,
  .stitch-registration-aside {
    padding: 2.25rem;
  }

  .stitch-form-grid,
  .stitch-focus-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .stitch-focus-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .stitch-dashboard-main {
    grid-template-columns: minmax(14rem, 0.8fr) minmax(24rem, 1.4fr) minmax(18rem, 0.95fr);
  }

  .stitch-pending-card {
    grid-column: auto;
  }

  .stitch-schedule-card {
    grid-column: span 2;
  }

  .stitch-task-layout {
    grid-template-columns: minmax(0, 1fr) minmax(24rem, 0.95fr);
  }

  .stitch-exam-preview > div {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .stitch-progress-metrics,
  .stitch-quality-metrics {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .stitch-task-brief,
  .stitch-task-submission {
    padding: 2rem;
  }

  .progress-filter-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .quality-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .report-layout {
    grid-template-columns: minmax(0, 1.55fr) minmax(19rem, 0.65fr);
  }

  .stitch-report-primary {
    grid-template-columns: minmax(18rem, 0.72fr) minmax(0, 1.55fr);
  }

  .stitch-report-lower {
    grid-template-columns: minmax(0, 1.2fr) minmax(19rem, 0.8fr);
  }

  .report-evidence-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 1440px) {
  :root {
    --sidebar-width: 17.5rem;
  }

  .main {
    padding-right: 3rem;
    padding-left: 3rem;
  }

  .topbar {
    margin-right: -3rem;
    margin-left: -3rem;
    padding-right: 3rem;
    padding-left: 3rem;
  }

  .section-band {
    padding: 2.5rem;
  }
}

/* V73 operational polish */
:root {
  --teal: #0f675f;
  --teal-deep: #123b38;
  --teal-soft: #dcefeb;
  --cobalt: #315f8d;
  --cobalt-soft: #e4edf6;
}

body {
  background-color: #f4f6f2;
  background-image:
    linear-gradient(rgba(15, 103, 95, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(15, 103, 95, 0.025) 1px, transparent 1px);
  background-size: 2rem 2rem;
}

.topbar {
  background: rgba(250, 252, 249, 0.9);
  border-bottom-color: rgba(15, 103, 95, 0.12);
  box-shadow: 0 0.5rem 1.8rem rgba(18, 59, 56, 0.045);
}

.page.active > * {
  animation: manzi-page-enter 420ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.panel,
.stitch-glass,
.metric,
.task-card,
.open-review-card,
.formal-history-panel {
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.panel:hover,
.stitch-glass:hover,
.metric:hover {
  border-color: rgba(15, 103, 95, 0.22);
  box-shadow: 0 0.9rem 2rem rgba(18, 59, 56, 0.07);
}

.primary-btn,
.ghost-btn,
.soft-btn {
  position: relative;
  overflow: hidden;
  transition: transform 160ms ease, box-shadow 160ms ease, color 160ms ease, background-color 160ms ease, border-color 160ms ease;
}

.primary-btn:hover,
.ghost-btn:hover,
.soft-btn:hover {
  transform: translateY(-1px);
}

.primary-btn:active,
.ghost-btn:active,
.soft-btn:active {
  transform: translateY(0);
}

.primary-btn {
  box-shadow: 0 0.45rem 1rem rgba(115, 92, 0, 0.16);
}

.primary-btn::after {
  position: absolute;
  top: -40%;
  left: -35%;
  width: 24%;
  height: 180%;
  content: "";
  background: rgba(255, 255, 255, 0.28);
  transform: rotate(18deg) translateX(-220%);
  transition: transform 420ms ease;
}

.primary-btn:hover::after {
  transform: rotate(18deg) translateX(620%);
}

.formal-exam-panel.active {
  position: relative;
  overflow: clip;
  border: 1px solid rgba(15, 103, 95, 0.18);
  background: rgba(250, 252, 249, 0.88);
  box-shadow: 0 1.5rem 3.5rem rgba(18, 59, 56, 0.1);
}

.formal-exam-panel.active::before {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 0.22rem;
  content: "";
  background: var(--teal);
}

.formal-exam-panel.active .quiz-toolbar {
  color: #f7fbf8;
  background: var(--teal-deep);
  border: 1px solid rgba(255, 213, 79, 0.22);
}

.formal-exam-panel.active .quiz-toolbar strong,
.formal-exam-panel.active .quiz-toolbar span {
  color: inherit;
}

.formal-live-pill.pill.warning {
  display: inline-flex;
  min-width: 9.5rem;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  color: #173a36;
  background: #dff5ed;
  font-variant-numeric: tabular-nums;
}

.formal-live-pill.pill.warning.urgent {
  color: #7d1b19;
  background: #ffe0dc;
  animation: manzi-urgent-pulse 1.2s ease-in-out infinite;
}

.formal-live-dot {
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background: #2e9d76;
  box-shadow: 0 0 0 0.25rem rgba(46, 157, 118, 0.16);
}

.formal-question-progress {
  border-color: rgba(15, 103, 95, 0.2);
  background: rgba(252, 254, 252, 0.95);
}

.formal-question-progress .stitch-progress > span {
  position: relative;
  overflow: hidden;
  background: var(--teal);
  transition: width 300ms cubic-bezier(0.22, 1, 0.36, 1);
}

.formal-question-progress .stitch-progress > span::after {
  position: absolute;
  inset: 0;
  content: "";
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.48), transparent);
  transform: translateX(-100%);
  animation: manzi-progress-scan 2.4s ease-in-out infinite;
}

.formal-question-map {
  display: grid;
  grid-template-columns: repeat(10, minmax(2rem, 1fr));
  gap: 0.42rem;
  padding: 0.85rem;
  border: 1px solid rgba(15, 103, 95, 0.14);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.72);
}

.formal-question-map button {
  min-width: 0;
  min-height: 2.15rem;
  padding: 0.2rem;
  border: 1px solid var(--line-soft);
  border-radius: 0.4rem;
  color: var(--muted);
  background: #fff;
  font-size: 0.78rem;
  font-weight: 700;
  transition: transform 140ms ease, border-color 140ms ease, color 140ms ease, background-color 140ms ease;
}

.formal-question-map button:hover {
  transform: translateY(-1px);
  border-color: var(--teal);
  color: var(--teal);
}

.formal-question-map button.answered {
  color: #145543;
  border-color: rgba(46, 157, 118, 0.38);
  background: #e2f4ed;
}

.formal-question-map button.current {
  color: #fff;
  border-color: var(--teal);
  background: var(--teal);
  box-shadow: 0 0.4rem 0.9rem rgba(15, 103, 95, 0.2);
}

.formal-question.active {
  border-color: rgba(15, 103, 95, 0.18);
  animation: manzi-question-enter 300ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.formal-question.active .card-topline .tag:first-child {
  color: var(--teal);
  background: var(--teal-soft);
}

.formal-question .option-list label {
  transition: transform 150ms ease, border-color 150ms ease, background-color 150ms ease, box-shadow 150ms ease;
}

.formal-question .option-list label:hover {
  transform: translateX(0.2rem);
  border-color: rgba(15, 103, 95, 0.45);
}

.formal-question .option-list label:has(input:checked) {
  color: #123b38;
  border-color: var(--teal);
  background: var(--teal-soft);
  box-shadow: inset 0.2rem 0 var(--teal);
}

.formal-question .option-list input {
  accent-color: var(--teal);
}

.formal-open-case {
  border-left-color: var(--cobalt);
  background: var(--cobalt-soft);
}

.formal-open-requirements {
  border-left-color: var(--teal);
  background: var(--teal-soft);
}

.formal-reconcile-state {
  min-height: 15rem;
  place-content: center;
  justify-items: center;
  text-align: center;
}

.formal-reconcile-state > div:last-child {
  display: grid;
  gap: 0.35rem;
}

.formal-reconcile-state > div:last-child span {
  color: var(--muted);
}

.formal-reconcile-mark {
  display: grid;
  width: 3.5rem;
  height: 3.5rem;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: var(--teal);
  box-shadow: 0 0 0 0.65rem var(--teal-soft);
}

.formal-reconcile-mark .material-symbols-outlined {
  animation: manzi-spin 1.1s linear infinite;
}

@media (min-width: 768px) {
  .formal-question-map {
    grid-template-columns: repeat(15, minmax(2rem, 1fr));
  }
}

@media (min-width: 1024px) {
  .sidebar {
    color: rgba(248, 251, 249, 0.84);
    background: var(--teal-deep);
    border-right-color: rgba(255, 255, 255, 0.12);
    box-shadow: 0.8rem 0 2.4rem rgba(18, 59, 56, 0.09);
  }

  .sidebar .brand-label,
  .sidebar .brand-block h1 {
    color: #fff;
  }

  .sidebar .brand-block p,
  .sidebar .nav-section > span,
  .sidebar .side-status {
    color: rgba(232, 242, 238, 0.62);
  }

  .sidebar .nav-item {
    color: rgba(244, 249, 246, 0.74);
  }

  .sidebar .nav-item::before {
    color: #e9c95b;
  }

  .sidebar .nav-item:hover,
  .sidebar .nav-item.active {
    color: #fff;
    background: rgba(255, 213, 79, 0.16);
    box-shadow: inset 0.18rem 0 #ffd54f;
  }

  .sidebar .side-status {
    border-color: rgba(255, 255, 255, 0.14);
    background: rgba(255, 255, 255, 0.06);
  }

}

@media (min-width: 1440px) {
  .formal-question-map {
    grid-template-columns: repeat(20, minmax(2rem, 1fr));
  }
}

@media (max-width: 639px) {
  .formal-exam-panel.active .quiz-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .formal-live-pill.pill.warning {
    min-width: 0;
    align-self: stretch;
  }

  .formal-question-map {
    display: flex;
    padding-bottom: 0.75rem;
    overflow-x: auto;
    scroll-snap-type: x proximity;
  }

  .formal-question-map button {
    flex: 0 0 2.25rem;
    min-height: 2.25rem;
    scroll-snap-align: center;
  }
}

@media (max-width: 767px) {
  body.formal-focus .sidebar {
    height: 3.6rem;
    padding: 0.45rem 0.85rem;
  }

  body.formal-focus .brand-mark {
    width: 2.4rem;
    height: 2.4rem;
    border-radius: 0.65rem;
  }

  body.formal-focus .brand-label,
  body.formal-focus .brand-block p {
    display: none;
  }

  body.formal-focus .brand-block h1 {
    margin: 0;
    font-size: 0.95rem;
  }

  body.formal-focus .topbar,
  body.formal-focus .route-brief {
    display: none;
  }

  body.formal-focus .main {
    padding-top: 0.8rem;
  }

  body.formal-focus .formal-question-progress {
    top: 4.05rem;
  }
}

@keyframes manzi-page-enter {
  from { opacity: 0; transform: translateY(0.4rem); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes manzi-question-enter {
  from { opacity: 0; transform: translateX(0.45rem); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes manzi-progress-scan {
  0%, 45% { transform: translateX(-100%); }
  75%, 100% { transform: translateX(100%); }
}

@keyframes manzi-urgent-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(186, 26, 26, 0); }
  50% { box-shadow: 0 0 0 0.35rem rgba(186, 26, 26, 0.12); }
}

@keyframes manzi-spin {
  to { transform: rotate(360deg); }
}

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