/* Questionários — extensão do sistema visual da Home. */
.questionnaires-hero {
  position: relative;
  display: flex;
  min-height: min(680px, 76vh);
  align-items: center;
  overflow: hidden;
  color: #fff;
  background: var(--navy);
}

.questionnaires-hero > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.questionnaires-hero::before {
  z-index: 1;
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0, 31, 81, .98) 0%, rgba(0, 31, 81, .86) 39%, rgba(0, 31, 81, .34) 68%, rgba(0, 31, 81, .08) 100%);
  content: "";
}

.questionnaires-hero__copy { position: relative; z-index: 2; padding-block: clamp(80px, 9vw, 136px); }
.questionnaires-hero h1 { max-width: 900px; margin: 12px 0 25px; font-size: clamp(2.9rem, 5.3vw, 5.6rem); line-height: .88; letter-spacing: -.072em; hyphens: manual; overflow-wrap: normal; word-break: normal; text-wrap: balance; }
.questionnaires-hero__copy > p:not(.eyebrow) { max-width: 590px; margin: 0 0 30px; color: rgba(255,255,255,.78); font-size: clamp(1rem, 1.3vw, 1.2rem); line-height: 1.62; }

.questionnaires-context { display: grid; grid-template-columns: minmax(0, 1fr) minmax(440px, .78fr); gap: 80px; align-items: end; padding-block: clamp(78px, 9vw, 128px); }
.questionnaires-context h2 { max-width: 800px; margin: 10px 0 0; font-size: clamp(3rem, 5vw, 5.5rem); line-height: .94; letter-spacing: -.06em; }
.questionnaires-context__stats { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); }
.questionnaires-context__stats div { padding: 22px 14px 4px 0; border-right: 1px solid var(--line); }
.questionnaires-context__stats div + div { padding-left: 20px; }
.questionnaires-context__stats div:last-child { border-right: 0; }
.questionnaires-context__stats strong { display: block; color: var(--navy); font-size: clamp(2.5rem, 4vw, 4.2rem); letter-spacing: -.06em; line-height: .9; }
.questionnaires-context__stats span { display: block; margin-top: 11px; color: var(--muted); font-size: .78rem; }

.questionnaire-catalog { padding-block: clamp(82px, 10vw, 144px); background: var(--white); }
.questionnaire-heading { display: grid; grid-template-columns: minmax(0, 1fr) minmax(290px, 480px); gap: 64px; align-items: end; margin-bottom: 50px; }
.questionnaire-heading h1, .questionnaire-heading h2 { max-width: 790px; margin: 11px 0 0; font-size: clamp(2.8rem, 4.6vw, 4.8rem); line-height: .96; letter-spacing: -.06em; }
.questionnaire-heading > p { margin: 0; color: var(--muted); line-height: 1.65; }

.questionnaire-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.questionnaire-grid[hidden] { display: none; }
.questionnaire-card { display: flex; min-width: 0; min-height: 370px; flex-direction: column; padding: 27px 25px 29px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.questionnaire-card:nth-child(3n + 1) { border-left: 1px solid var(--line); }
.questionnaire-card--featured { color: var(--navy); background: var(--blue); }
.questionnaire-card--featured .meta, .questionnaire-card--featured .questionnaire-card__note { color: var(--navy); }
.questionnaire-card__index { margin-bottom: auto; font-size: .75rem; font-weight: 800; letter-spacing: .12em; }
.questionnaire-card .meta { margin-top: 45px; }
.questionnaire-card h3 { margin: 10px 0 13px; font-size: clamp(1.55rem, 2.1vw, 2.35rem); line-height: 1.02; letter-spacing: -.045em; overflow-wrap: anywhere; }
.questionnaire-card__note { max-width: 34ch; margin: 0 0 24px; color: var(--muted); font-size: .84rem; line-height: 1.5; }
.questionnaire-card > a { margin-top: auto; font-size: .86rem; font-weight: 780; text-decoration: none; }
.questionnaire-card > a:hover { color: var(--navy); }
.questionnaire-card--featured > a:hover { color: var(--navy); }

.questionnaire-catalog__note { display: flex; justify-content: space-between; gap: 20px; margin: 27px 0 0; color: var(--muted); font-size: .82rem; }
.questionnaire-catalog__note a { color: var(--ink); font-weight: 750; }

.questionnaire-flow { display: grid; grid-template-columns: .75fr 1.25fr; gap: 80px; padding-block: clamp(82px, 10vw, 140px); }
.questionnaire-flow h2 { max-width: 630px; margin: 10px 0 0; font-size: clamp(3rem, 5vw, 5.5rem); line-height: .94; letter-spacing: -.06em; }
.questionnaire-flow ol { margin: 0; padding: 0; border-top: 1px solid var(--line); list-style: none; }
.questionnaire-flow li { display: grid; grid-template-columns: 46px 170px 1fr; gap: 20px; align-items: baseline; padding: 25px 0; border-bottom: 1px solid var(--line); }
.questionnaire-flow li > span { color: var(--navy); font-size: .76rem; font-weight: 800; }
.questionnaire-flow li > strong { font-size: 1.35rem; }
.questionnaire-flow li > p { margin: 0; color: var(--muted); line-height: 1.55; }
.questionnaire-gate { color: #fff; background: #101010; }
.questionnaire-gate__inner { display: grid; grid-template-columns: 1fr .65fr; gap: 90px; align-items: end; padding-block: clamp(75px, 9vw, 126px); }
.questionnaire-gate h2 { max-width: 820px; margin: 11px 0 0; font-size: clamp(3rem, 5vw, 5.6rem); line-height: .92; letter-spacing: -.06em; }
.questionnaire-gate__inner > p { margin: 0; color: rgba(255,255,255,.65); line-height: 1.72; }

/* Detalhe STOP-Bang */
.questionnaire-detail-page { background: var(--white); }
.questionnaire-breadcrumb { display: flex; min-height: 64px; gap: 10px; align-items: center; color: var(--muted); font-size: .82rem; }
.questionnaire-breadcrumb a { text-decoration: none; }
.questionnaire-detail-intro { display: grid; grid-template-columns: minmax(0, 1fr) minmax(320px, .58fr); gap: 70px; align-items: end; padding-block: clamp(62px, 8vw, 112px); }
.questionnaire-detail-intro h1 { margin: 10px 0 0; font-size: clamp(2.2rem, 3.6vw, 3.4rem); line-height: 1.02; letter-spacing: -.045em; hyphens: manual; overflow-wrap: normal; word-break: normal; text-wrap: balance; }
.questionnaire-detail-intro > div:last-child > p { max-width: 500px; margin: 0 0 23px; color: #3d3d3d; font-size: 1.08rem; line-height: 1.65; }
.questionnaire-detail-intro a { text-decoration-thickness: 1px; text-underline-offset: 3px; }
.questionnaire-detail-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.questionnaire-detail-tags span { padding: 7px 11px; border: 1px solid var(--line); font-size: .75rem; font-weight: 740; }

.stop-workspace { padding-block: clamp(55px, 7vw, 94px); background: var(--paper); }
.stop-workspace__grid { display: grid; grid-template-columns: 1fr; gap: 24px; align-items: start; }
.stop-form-panel { min-width: 0; padding: clamp(28px, 4vw, 52px); border-top: 4px solid var(--blue); background: #fff; }
.stop-panel-heading h2 { margin: 9px 0 11px; font-size: clamp(2.1rem, 3.2vw, 3.45rem); line-height: .96; letter-spacing: -.055em; }
.stop-panel-heading > p:not(.eyebrow) { max-width: 650px; margin: 0 0 30px; color: var(--muted); line-height: 1.65; }
.stop-progress { padding: 18px 0 24px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.stop-progress__track { height: 6px; overflow: hidden; background: #e7e7e7; }
.stop-progress__track span { display: block; width: 12.5%; height: 100%; background: var(--navy); transition: width 220ms ease; }
.stop-progress > div:last-child { display: flex; justify-content: space-between; gap: 20px; margin-top: 12px; color: var(--muted); font-size: .76rem; }
.stop-progress > div:last-child strong { color: var(--ink); }
.stop-question, .stop-refinement { margin: 0; padding: 34px 0 4px; border: 0; }
.stop-question[hidden], .stop-refinement[hidden] { display: none; }
.stop-question legend, .stop-refinement legend { margin-bottom: 17px; color: var(--navy); font-size: .76rem; font-weight: 800; letter-spacing: .11em; text-transform: uppercase; }
.stop-question__code { margin: 0 0 10px; color: var(--muted); font-size: .76rem; font-weight: 780; letter-spacing: .07em; text-transform: uppercase; }
.stop-question h3 { max-width: 750px; margin: 0; font-size: clamp(1.75rem, 3vw, 3rem); line-height: 1.05; letter-spacing: -.045em; }
.stop-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 28px; }
.stop-options button { min-height: 56px; border: 1px solid var(--ink); color: var(--ink); background: #fff; font-weight: 780; cursor: pointer; }
.stop-options button:hover, .stop-options button:focus-visible { color: #fff; background: var(--navy); }
.stop-options--wide { grid-template-columns: 1fr; }
.stop-options__neutral { border-color: #aaa !important; color: var(--muted) !important; }
.stop-options__neutral:hover, .stop-options__neutral:focus-visible { color: #fff !important; background: #555 !important; }
.stop-form-status { min-height: 22px; margin: 24px 0 0; color: var(--muted); font-size: .76rem; }
.stop-side-note { position: sticky; top: 95px; padding: 30px; border-top: 3px solid var(--blue); background: #fff; }
.stop-side-note h2 { margin: 8px 0 15px; font-size: clamp(2.2rem, 3.7vw, 4rem); line-height: .95; letter-spacing: -.055em; }
.stop-side-note > p:not(.eyebrow) { margin: 0 0 25px; color: var(--muted); font-size: .9rem; line-height: 1.65; }
.stop-side-note__line { padding: 17px 0; border-top: 1px solid var(--line); }
.stop-side-note__line strong { display: block; margin-bottom: 5px; font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; }
.stop-side-note__line span { color: var(--muted); font-size: .8rem; line-height: 1.5; }
.stop-side-note > a { display: inline-block; margin-top: 18px; font-size: .8rem; font-weight: 780; }

.stop-result { color: #fff; background: var(--navy); }
.stop-result__inner { display: grid; grid-template-columns: minmax(270px, .65fr) minmax(0, 1.35fr); gap: 75px; align-items: start; padding-block: clamp(70px, 9vw, 128px); }
.stop-result__inner h2 { max-width: 580px; margin: 11px 0 31px; font-size: clamp(3rem, 5vw, 5.8rem); line-height: .91; letter-spacing: -.065em; }
.stop-result__lead, .stop-result__risk { margin: 0; color: rgba(255,255,255,.72); font-size: 1rem; }
.stop-result__lead strong { display: block; margin-top: 8px; color: var(--blue); font-size: clamp(3.3rem, 6vw, 6rem); letter-spacing: -.08em; line-height: .9; }
.stop-result__risk { margin-top: 24px; }
.stop-result__risk strong { color: #fff; }
.stop-result__disclaimer { max-width: 410px; margin: 25px 0 0; color: rgba(255,255,255,.55); font-size: .78rem; line-height: 1.58; }
.stop-result__details > div { margin-bottom: 27px; padding: 25px; border: 1px solid rgba(255,255,255,.2); background: rgba(255,255,255,.05); }
.stop-result__details h3 { margin: 0 0 10px; font-size: 1.15rem; }
.stop-result__details p { margin: 0; color: rgba(255,255,255,.7); font-size: .84rem; line-height: 1.6; }
.stop-analysis[hidden] { display: none; }
.stop-analysis ul { margin: 14px 0 0; padding-left: 20px; color: rgba(255,255,255,.82); font-size: .84rem; line-height: 1.6; }
.stop-table-wrap { margin-top: 17px; overflow-x: auto; }
.stop-probability table { width: 100%; min-width: 470px; border-collapse: collapse; font-size: .78rem; }
.stop-probability th, .stop-probability td { padding: 10px 12px; border: 1px solid rgba(255,255,255,.2); text-align: left; }
.stop-probability th { color: rgba(255,255,255,.63); font-weight: 700; }
.stop-probability tr[data-current="true"] { color: var(--ink); background: var(--blue); }
.stop-result-source { border-left: 3px solid var(--blue) !important; }
.stop-result-source strong { display: block; margin-bottom: 9px; color: var(--sky); font-size: .75rem; letter-spacing: .08em; text-transform: uppercase; }
.stop-result-source p + p { margin-top: 9px; }
.stop-result-source a { color: #fff; }
.stop-result__details > button { border: 0; cursor: pointer; }

.questionnaire-detail-content { display: grid; grid-template-columns: 1fr; padding-block: clamp(78px, 10vw, 140px); }
.questionnaire-detail-content article > * { max-width: 760px; }
.questionnaire-detail-content h2 { margin: 0 0 22px; font-size: clamp(2.3rem, 3.7vw, 3.9rem); letter-spacing: -.05em; }
.questionnaire-detail-content h3 { margin: 42px 0 12px; font-size: 1.5rem; }
.questionnaire-detail-content p, .questionnaire-detail-content li { color: #414141; line-height: 1.75; }
.questionnaire-detail-content aside { padding: 28px; border-top: 3px solid var(--blue); background: var(--paper); }
.questionnaire-detail-content aside strong { display: block; margin-bottom: 12px; }
.questionnaire-detail-content aside p { margin: 0; font-size: .88rem; }

/* Bloco de autor (página de detalhe) */
.questionnaire-author { padding-block: clamp(70px, 9vw, 120px); border-top: 1px solid var(--line); background: #fff; }
.questionnaire-author__grid { display: grid; grid-template-columns: minmax(180px, 240px) minmax(0, 1fr); gap: clamp(30px, 5vw, 70px); align-items: start; }
.questionnaire-author h2 { margin: 0 0 18px; font-size: clamp(2rem, 3.4vw, 3.2rem); letter-spacing: -.05em; }
.questionnaire-author img { width: 100%; height: auto; border: 1px solid var(--line); }
.questionnaire-author__name { margin: 0; font-size: 1.3rem; font-weight: 800; }
.questionnaire-author__crm { margin: 4px 0 20px; color: var(--muted); font-size: .85rem; font-weight: 700; }
.questionnaire-author__bio p { margin: 0 0 16px; color: #414141; line-height: 1.7; }

@media (max-width: 700px) {
  .questionnaire-author__grid { grid-template-columns: 1fr; }
  .questionnaire-author img { max-width: 220px; }
}

@media (max-width: 1100px) {
  .questionnaire-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .questionnaire-card:nth-child(3n + 1) { border-left: 0; }
  .questionnaire-card:nth-child(2n + 1) { border-left: 1px solid var(--line); }
  .stop-result__inner { gap: 48px; }
}

@media (max-width: 820px) {
  .questionnaires-hero { min-height: 680px; align-items: flex-end; }
  .questionnaires-hero > img { object-position: 63% center; }
  .questionnaires-hero::before { background: linear-gradient(90deg, rgba(0, 31, 81, .94), rgba(0, 31, 81, .5)), linear-gradient(0deg, rgba(0, 31, 81, .8), transparent 70%); }
  .questionnaires-hero__copy { padding-bottom: 65px; }
  .questionnaires-context, .questionnaire-heading, .questionnaire-flow, .questionnaire-gate__inner, .questionnaire-detail-intro, .stop-workspace__grid, .stop-result__inner, .questionnaire-detail-content { grid-template-columns: minmax(0, 1fr); }
  .questionnaires-context, .questionnaire-heading, .questionnaire-flow, .questionnaire-gate__inner, .questionnaire-detail-intro, .stop-workspace__grid, .stop-result__inner, .questionnaire-detail-content { gap: 42px; }
  .stop-side-note { position: static; }
  .questionnaire-flow li { grid-template-columns: 38px 140px 1fr; }
}

@media (max-width: 560px) {
  .questionnaires-hero { min-height: 650px; }
  .questionnaires-hero h1 { max-width: 11ch; font-size: clamp(2.4rem, 10.5vw, 3.6rem); }
  .questionnaires-context__stats { grid-template-columns: 1fr; }
  .questionnaires-context__stats div, .questionnaires-context__stats div + div { padding: 17px 0; border-right: 0; border-bottom: 1px solid var(--line); }
  .questionnaires-context__stats div:last-child { border-bottom: 0; }
  .questionnaire-grid { grid-template-columns: 1fr; }
  .questionnaire-card, .questionnaire-card:nth-child(3n + 1), .questionnaire-card:nth-child(2n + 1) { min-height: 330px; border-left: 1px solid var(--line); }
  .questionnaire-catalog__note { align-items: flex-start; flex-direction: column; }
  .questionnaire-flow li { grid-template-columns: 34px 1fr; }
  .questionnaire-flow li p { grid-column: 2; }
  .questionnaire-detail-intro h1 { font-size: clamp(1.9rem, 8vw, 2.6rem); }
  .questionnaire-detail-intro > div:last-child > p { font-size: 1rem; }
  .stop-form-panel, .stop-side-note { padding: 26px 20px; }
  .stop-options { grid-template-columns: 1fr; }
  .stop-question h3 { font-size: 1.8rem; }
  .stop-result__inner { padding-block: 65px; }
  .stop-result__details > div { padding: 20px 16px; }
}

/* Renderizador nativo (questionario-app.js) — mesmo sistema do STOP-Bang */
.qx-question h3, .qx-question__label { display: block; max-width: 750px; margin: 0; font-size: clamp(1.6rem, 2.6vw, 2.5rem); font-weight: 800; line-height: 1.08; letter-spacing: -.04em; }
.qx-help { max-width: 700px; margin: 14px 0 0; color: var(--muted); font-size: .92rem; line-height: 1.6; }
.qx-options--list { grid-template-columns: 1fr; }
.qx-options--list button { min-height: 52px; padding: 12px 18px; text-align: left; }
.qx-opt-suffix { display: block; margin-top: 2px; font-size: .78rem; font-weight: 600; opacity: .68; }
.qx-opt-sub { font-weight: 400; }
.stop-options button.is-selected, .stop-options button[aria-pressed="true"] { color: #fff; background: var(--navy); border-color: var(--navy); }
.qx-input { width: 100%; min-height: 52px; padding: 12px 14px; border: 1px solid #bdbdbd; border-radius: 0; color: var(--ink); background: #fff; font: inherit; }
textarea.qx-input { min-height: 110px; resize: vertical; }
.qx-input:focus { border-color: var(--navy); outline: 2px solid var(--blue); outline-offset: 1px; }
.qx-question .qx-input, .qx-question .qx-unit, .qx-question .qx-checks { margin-top: 26px; }
.qx-unit { display: flex; align-items: stretch; }
.qx-unit span { display: grid; place-items: center; padding: 0 14px; border: 1px solid #bdbdbd; border-left: 0; color: var(--muted); font-size: .85rem; font-weight: 700; }
.qx-checks { display: grid; gap: 8px; }
.qx-check { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border: 1px solid var(--line); background: #fff; cursor: pointer; line-height: 1.45; }
.qx-check:has(input:checked) { border-color: var(--navy); background: #eef6ff; }
.qx-check input { width: 18px; height: 18px; margin: 2px 0 0; accent-color: var(--navy); flex: none; }
.qx-info { padding: 18px 20px; border-left: 3px solid var(--blue); background: var(--paper); color: #3d3d3d; font-size: .9rem; line-height: 1.6; }
.qx-info p { margin: 0 0 8px; } .qx-info p:last-child { margin: 0; }
.qx-nav { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-top: 34px; }
.qx-nav .button { border: 0; cursor: pointer; }
.qx-nav__back { padding: 0; border: 0; color: var(--ink); background: none; font: inherit; font-size: .85rem; font-weight: 780; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.qx-stepper { display: flex; gap: 6px; margin: 28px 0 0; padding: 0 0 4px; overflow-x: auto; list-style: none; }
.qx-stepper li { flex: 1 0 auto; }
.qx-stepper button { display: flex; width: 100%; gap: 8px; align-items: baseline; padding: 12px 14px; border: 1px solid var(--line); color: var(--muted); background: #fff; font: inherit; font-size: .78rem; font-weight: 780; white-space: nowrap; cursor: pointer; }
.qx-stepper button span { color: inherit; font-size: .7rem; letter-spacing: .08em; }
.qx-stepper button.is-done { color: var(--navy); border-color: var(--navy); }
.qx-stepper button[aria-current="step"] { color: #fff; background: var(--navy); border-color: var(--navy); }
.qx-step { padding-top: 34px; }
.qx-step__title { margin: 0; font-size: clamp(1.6rem, 2.4vw, 2.3rem); line-height: 1.05; letter-spacing: -.04em; }
.qx-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 26px 20px; margin-top: 28px; }
.qx-field { min-width: 0; }
.qx-field--wide { grid-column: 1 / -1; }
.qx-field__label { display: block; margin-bottom: 10px; font-size: .95rem; font-weight: 780; line-height: 1.4; }
.qx-field__label small { color: var(--muted); font-weight: 500; }
.qx-field .qx-help { margin: -4px 0 10px; font-size: .84rem; }
.qx-field .stop-options { margin-top: 0; }
.stop-result__risk strong[data-tone] { display: inline-block; margin-top: 8px; padding: 6px 12px; color: var(--ink); background: #fff; }
.stop-result__risk strong[data-tone="green"] { background: #9be3b4; }
.stop-result__risk strong[data-tone="yellow"] { background: #ffe07a; }
.stop-result__risk strong[data-tone="orange"] { background: #ffb36b; }
.stop-result__risk strong[data-tone="red"] { color: #fff; background: #c8312b; }
.qx-block ul { margin: 12px 0 0; padding-left: 20px; color: rgba(255,255,255,.82); font-size: .86rem; line-height: 1.6; }
.qx-record { max-height: 360px; margin: 12px 0 16px; padding: 16px; overflow: auto; border: 1px solid rgba(255,255,255,.2); color: #fff; background: rgba(0,0,0,.25); font-size: .78rem; line-height: 1.55; white-space: pre-wrap; }
.qx-copy { border: 0; cursor: pointer; }
.qx-article h2 { margin-top: 56px; } .qx-article h2:first-child { margin-top: 0; }
.qx-article img { max-width: 100%; height: auto; }
.qx-article table { width: 100%; border-collapse: collapse; font-size: .88rem; }
.qx-article th, .qx-article td { padding: 10px 12px; border: 1px solid var(--line); text-align: left; vertical-align: top; }
@media (max-width: 700px) {
  .qx-grid { grid-template-columns: 1fr; }
  .qx-nav { flex-direction: column-reverse; align-items: stretch; }
  .qx-nav .button { width: 100%; justify-content: center; }
}
.qx-done { padding-top: 34px; }
.qx-done h3 { margin: 0; font-size: clamp(1.6rem, 2.6vw, 2.5rem); line-height: 1.08; letter-spacing: -.04em; }
.stop-result__details > [data-qx-details] { display: contents; }
.qx-block, [data-qx-details] > .stop-result-source { margin-bottom: 20px; padding: 25px; border: 1px solid rgba(255,255,255,.2); background: rgba(255,255,255,.05); }
.qx-block h3 { margin: 0 0 10px; font-size: 1.15rem; }
.qx-block p { margin: 0; color: rgba(255,255,255,.72); font-size: .84rem; line-height: 1.6; }
.qx-block ul:first-child { margin-top: 0; }
.stop-result__inner > *, .stop-result__details, .qx-block { min-width: 0; }
.qx-record { max-width: 100%; overflow-wrap: anywhere; }
.qx-block, .stop-result-source { overflow-wrap: anywhere; }
.stop-result__inner h2 { overflow-wrap: break-word; }
@media (max-width: 520px) { .stop-result__inner h2 { font-size: clamp(2.2rem, 11vw, 3rem); hyphens: auto; } }
.stop-result__inner h2 { font-size: clamp(2.6rem, 4.2vw, 4.6rem); }
@media (max-width: 520px) { .stop-result__inner h2 { font-size: clamp(2.2rem, 11vw, 3rem); hyphens: auto; } }
.questionnaire-detail-content > * { min-width: 0; }
.qx-article table { display: block; max-width: 100%; overflow-x: auto; }
.qx-article { overflow-wrap: break-word; }

/* ---- modo pages + controles de instrumentos clínicos (questionario-app.js) ---- */
.qx-toolbar { display: flex; justify-content: flex-end; margin-top: 20px; }
.qx-btn-sm { min-height: 36px; padding: 8px 16px; font-size: .82rem; font-weight: 780; }
.qx-btn-ghost { border: 1px solid var(--line); color: var(--ink); background: #fff; cursor: pointer; }
.qx-btn-ghost:hover, .qx-btn-ghost:focus-visible { border-color: var(--navy); }
.qx-reset { text-decoration: none; }

.qx-pages { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 18px; }
.qx-pages button { display: grid; min-width: 40px; min-height: 40px; padding: 0 10px; border: 1px solid var(--line); place-items: center; color: var(--ink); background: #fff; font: inherit; font-size: .82rem; font-weight: 780; cursor: pointer; }
.qx-pages button:hover, .qx-pages button:focus-visible { border-color: var(--navy); }
.qx-pages button[aria-current="page"] { border-color: var(--navy); color: #fff; background: var(--navy); }

.qx-section { grid-column: 1 / -1; margin: 18px 0 -8px; padding: 10px 14px; color: #fff; background: var(--navy); font-size: .95rem; font-weight: 800; letter-spacing: .02em; }
.qx-section--accent { background: var(--navy); border-left: 5px solid var(--blue); }
.qx-section--alt { background: #3d3d3d; border-left: 5px solid var(--blue); }
.qx-group { grid-column: 1 / -1; margin: 6px 0 -14px; font-size: .95rem; font-weight: 780; }
.qx-info--warn { border-left-color: #b42318; }
.qx-info .qx-score__item { display: inline-block; margin-right: 18px; }
.qx-info .qx-score__item strong { color: var(--navy); font-size: 1.05rem; }

.qx-gate { padding: 16px 18px; border: 1px solid var(--line); border-left: 4px solid var(--blue); background: var(--paper); }
.qx-gate__label { margin: 0 0 4px; font-weight: 800; color: var(--navy); }
.qx-gate__prompt { margin: 0 0 12px; color: var(--muted); font-size: .88rem; }
.qx-options--inline { display: flex; flex-wrap: wrap; gap: 8px; }
.qx-options--inline button { min-height: 40px; padding: 8px 16px; border: 1px solid var(--ink); background: #fff; font: inherit; font-size: .85rem; font-weight: 780; cursor: pointer; }
.qx-options--inline button.is-selected { color: #fff; background: var(--navy); border-color: var(--navy); }

.qx-options--scale { display: grid; grid-template-columns: repeat(auto-fit, minmax(40px, 1fr)); gap: 6px; max-width: 420px; }
.qx-options--scale button { min-height: 40px; }
.qx-options--toggle { display: flex; gap: 6px; }
.qx-options--toggle button { min-height: 36px; min-width: 64px; padding: 6px 12px; }

.qx-field--inline { display: flex; }
.qx-cycle, .qx-wordbtn { min-height: 40px; padding: 8px 12px; border: 1.5px solid var(--line); color: var(--ink); background: #fff; font: inherit; font-size: .85rem; font-weight: 740; cursor: pointer; }
.qx-cycle:hover, .qx-wordbtn:hover { border-color: var(--navy); }
.qx-cycle.is-correct, .qx-wordbtn.is-selected { border-color: var(--navy); color: #fff; background: var(--navy); }
.qx-cycle.is-error { border-color: #b42318; color: #fff; background: #b42318; }

.qx-timer { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 12px 14px; border: 1px solid var(--line); background: var(--paper); }
.qx-timer__label { font-size: .88rem; font-weight: 780; }
.qx-timer__val { font-size: 1.1rem; font-weight: 800; }
.qx-timerbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 10px; padding: 12px 16px; color: #fff; background: var(--navy); font-weight: 700; }
.qx-timerbar.is-ready { background: #1e7a46; }
.qx-timerbar__val { font-size: 1.15rem; font-weight: 800; }

.qx-metro { padding: 14px 16px; border: 1px solid var(--line); background: var(--paper); }
.qx-metro__title { margin: 0 0 10px; color: var(--navy); font-weight: 800; font-size: .88rem; }
.qx-metro__controls { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.qx-metro__bpm-label { font-size: .8rem; font-weight: 800; }
.qx-metro__bpm { width: 82px; min-height: 38px; padding: 6px 10px; }
.qx-metro__beat { width: 16px; height: 16px; border-radius: 50%; background: var(--line); }
.qx-metro__beat.is-on { background: var(--navy); }

.qx-export__actions { display: flex; flex-wrap: wrap; gap: 10px; }
.qx-result-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.qx-export__out { margin-top: 18px; }
.qx-export__out[hidden] { display: none; }
.qx-export__text { max-height: 380px; margin: 12px 0; padding: 14px; overflow: auto; border: 1px solid var(--line); background: var(--paper); font-size: .8rem; line-height: 1.5; white-space: pre-wrap; }

/* Escala com extremos ancorados (ex.: NRS 0–10 com descrições nas pontas) */
.qx-scale .qx-anchors { display: flex; justify-content: space-between; gap: 12px; margin-bottom: 8px; color: var(--muted); font-size: .8rem; line-height: 1.4; }
.qx-scale .qx-anchors span:last-child { text-align: right; }
.qx-scale .qx-sel { min-height: 1.2em; margin: 8px 0 0; color: var(--muted); font-size: .8rem; line-height: 1.4; }

.qx-error { margin-top: 12px; }
.qx-error[hidden] { display: none; }
.qx-nav__back:disabled { opacity: .45; cursor: default; text-decoration: none; }

/* Chips estáticos (prévia de fluxo) */
.qx-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.qx-chip { padding: 8px 14px; border: 1px solid var(--line); border-radius: 999px; background: var(--paper); font-size: .82rem; font-weight: 740; }

/* Linha rótulo:valor (echo de dados no resultado) */
.qx-kv { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.qx-kv__label { font-weight: 780; }
.qx-kv__val { color: var(--muted); text-align: right; overflow-wrap: anywhere; }

/* Escore embutido na página (resultado inline) */
.qx-score-inline { display: flex; align-items: baseline; gap: 6px; }
.qx-score-inline__num { font-size: 2.4rem; font-weight: 800; color: var(--navy); }
.qx-score-inline__max { color: var(--muted); font-weight: 700; }

/* Barra de contagem de palavras + ocultação da lista */
.qx-wordbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: -14px; }
.qx-wordbar__count { font-size: .82rem; color: var(--muted); font-weight: 740; }
.qx-conceal { color: transparent !important; text-shadow: 0 0 10px rgba(0,0,0,.4); }

.qx-input-action { display: flex; gap: 8px; align-items: center; }
.qx-input-action .qx-input { flex: 1; min-width: 0; }
.qx-input-action .qx-btn-sm { flex: none; white-space: nowrap; }
.qx-input-action:has(textarea) .qx-btn-sm { align-self: flex-start; margin-top: 4px; }
.qx-explain { margin-top: 22px; }
.qx-explain .qx-field__label { font-size: .9rem; color: var(--muted); }
.qx-record__text { font-family: inherit; font-size: .85rem; }

.qx-block__link { display: inline-flex; margin-top: 12px; text-decoration: none; }
.qx-block__note { margin-top: 12px !important; font-size: .8rem !important; opacity: .8; }

/* Grupo de navegação à esquerda (voltar + reiniciar) no modo por etapas */
.qx-nav__group { display: flex; gap: 16px; align-items: center; }

/* Chips em grade de cartões (mini-cards de introdução da origem) */
.qx-chips--cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.qx-chips--cards .qx-chip { display: block; padding: 14px 16px; border-radius: 10px; font-size: .85rem; font-weight: 500; line-height: 1.5; }
.qx-chips--cards .qx-chip strong { display: block; font-weight: 800; color: var(--navy); }
@media (max-width: 520px) { .qx-chips--cards { grid-template-columns: 1fr; } }

/* Selo de status dentro de resumos dinâmicos (tabelas de escores) */
.qx-flag { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: .78rem; font-weight: 780; }
.qx-flag--ok { color: #146c43; background: #d8f0e2; }
.qx-flag--alerta { color: #8a5a00; background: #fbeecb; }
.qx-flag--perigo { color: #b42318; background: #fbe4e0; }

/* Tabela de resumo dinâmico dentro de notas */
.qx-table { width: 100%; border-collapse: collapse; background: #fff; font-size: .85rem; }
.qx-table th, .qx-table td { padding: 8px 10px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.qx-table th { color: var(--navy); font-weight: 800; }
.qx-resumo h4 { margin: 0 0 8px; }
.qx-resumo .qx-info { margin-top: 10px; }
.qx-detalhes { margin-top: 10px; }
.qx-detalhes summary { cursor: pointer; font-weight: 780; color: var(--navy); }
.qx-detalhes__conteudo { margin-top: 8px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.qx-detalhes__conteudo p { margin: 6px 0; }

/* ---------- widgets compostos (abas/painéis, cartões, navegação rápida) ---------- */
.qx-quicknav { margin: 0 0 12px; border: 1px solid #d5dde8; border-radius: 10px; background: #f6f8fb; padding: 10px 12px; }
.qx-quicknav__summary { cursor: pointer; font-weight: 600; font-size: 0.92rem; color: #16335c; }
.qx-quicknav__panel { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 10px; }
.qx-quicknav__panel > div { display: flex; align-items: center; gap: 8px; }
.qx-quicknav__label { font-size: 0.9rem; color: #33475f; }
.qx-quicknav__select { max-width: 280px; }
.qx-btn-sm { padding: 6px 12px; border-radius: 8px; font-size: 0.88rem; border: 1px solid #c3cedd; background: #fff; color: #16335c; cursor: pointer; }
.qx-btn-sm:hover { background: #eef2f8; }
.qx-btn-ghost { background: #fff; }
.qx-badges { display: flex; gap: 8px; margin: 2px 0 10px; }
.qx-chip { font-size: 0.78rem; font-weight: 600; letter-spacing: 0.02em; text-transform: uppercase; color: #4d5f78; background: #edf1f7; border: 1px solid #d5dde8; border-radius: 999px; padding: 3px 10px; }
.qx-smart { border: 1px solid #e4b95e; border-left-width: 5px; background: #fdf6e6; border-radius: 10px; padding: 12px 14px; margin: 0 0 14px; }
.qx-smart__title { margin: 0 0 6px; font-weight: 700; color: #7a4d00; }
.qx-smart__text { margin: 0 0 10px; }
.qx-smart__actions { display: flex; flex-wrap: wrap; gap: 8px; }
.qx-widget { display: grid; gap: 14px; margin: 10px 0 0; }
.qx-widget__head { display: grid; gap: 8px; }
.qx-widget__title { margin: 0; font-weight: 700; color: #16335c; }
.qx-widget__text { margin: 0; color: #33475f; }
.qx-tabs { display: flex; flex-wrap: wrap; gap: 6px; border-bottom: 1px solid #d5dde8; padding-bottom: 8px; }
.qx-tab { border: 1px solid #c3cedd; border-radius: 8px 8px 0 0; background: #f2f5fa; color: #33475f; padding: 7px 14px; cursor: pointer; font-size: 0.9rem; }
.qx-tab[aria-selected="true"] { background: #16335c; border-color: #16335c; color: #fff; }
.qx-widget__panel { display: grid; gap: 12px; }
.qx-widget__panel[hidden] { display: none; }
.qx-widget__toolbar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px; }
.qx-widget__score { font-weight: 700; color: #16335c; }
.qx-widget__total { font-weight: 600; color: #16335c; border-top: 1px dashed #c3cedd; padding-top: 8px; }
.qx-wordgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 8px; }
.qx-errgrid { display: grid; gap: 8px; }
.qx-errrow { display: grid; grid-template-columns: 1fr 88px; gap: 10px; align-items: center; }
.qx-errinput { text-align: right; }
.qx-cards { display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
.qx-card { text-align: left; border: 1px solid #c3cedd; border-radius: 10px; background: #fff; padding: 14px; cursor: pointer; display: grid; gap: 6px; }
.qx-card:hover { border-color: #16335c; box-shadow: 0 1px 4px rgba(22, 51, 92, 0.18); }
.qx-card strong { color: #16335c; font-size: 0.98rem; }
.qx-card span { color: #4d5f78; font-size: 0.88rem; line-height: 1.4; }
.qx-record-details summary { cursor: pointer; font-weight: 600; color: #16335c; margin-bottom: 8px; }
