/* Digital & AI Assessment: the public page (/assessment), the code entry and
 * closed pages, and the company's form. Uses the site-v5.css tokens; the report
 * has its own stylesheet (assessment-report.css). */

/* ---------- Public page ---------- */

.as-hero {
    padding: calc(72px + clamp(40px, 6vw, 88px)) 0 clamp(40px, 5vw, 72px);
}

.as-hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
    gap: clamp(32px, 6vw, 96px);
    align-items: end;
}

.as-hero-copy .q-label {
    margin-bottom: 18px;
}

.as-hero-copy .q-display {
    font-size: clamp(34px, 4.4vw, 60px);
}

.as-hero-copy .q-lede {
    max-width: 640px;
    margin-top: 20px;
}

.as-hero-facts {
    display: grid;
    gap: 10px;
    margin: 0;
}

.as-hero-facts div {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 2px 18px;
    align-items: baseline;
    padding: 20px 22px;
    border-radius: var(--q-r-md);
    background: var(--q-panel);
}

.as-hero-facts dt {
    grid-column: 1 / -1;
    color: var(--slate);
    font-size: 13.5px;
}

.as-hero-facts dd {
    margin: 0;
    font-size: clamp(30px, 3vw, 40px);
    font-weight: 400;
    line-height: 1.3;
}

.as-hero-facts small {
    color: var(--slate);
    font-size: 14px;
    line-height: 1.8;
}

.as-steps {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.as-steps li {
    padding: clamp(22px, 2.4vw, 30px);
    border-radius: var(--q-r-md);
    background: var(--q-panel);
}

.as-steps span {
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 8px;
    background: var(--ink);
    color: #fff;
    font-size: 14px;
}

.as-steps h3 {
    margin: 22px 0 0;
    font-size: 18.5px;
    font-weight: 500;
    line-height: 1.6;
}

.as-steps p {
    margin: 8px 0 0;
    color: var(--slate);
    font-size: 15px;
    line-height: 1.9;
}

.as-area-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 28px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.as-area-list li {
    display: flex;
    gap: 16px;
    align-items: baseline;
    padding: 16px 0;
    border-bottom: 1px solid var(--line);
    font-size: 16px;
    line-height: 1.8;
}

.as-area-list b {
    flex: none;
    width: 28px;
    color: var(--copper);
    font-size: 13px;
    font-weight: 500;
}

.as-report-preview {
    margin: 0 12px;
    border-radius: var(--q-r-lg);
    background: var(--ink);
    color: #fff;
}

.as-report-list {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.as-report-list li {
    padding: 24px;
    border-radius: var(--q-r-md);
    background: rgba(255, 255, 255, .06);
}

.as-report-list h3 {
    margin: 0;
    font-size: 17.5px;
    font-weight: 500;
    line-height: 1.6;
}

.as-report-list p {
    margin: 8px 0 0;
    color: rgba(255, 255, 255, .66);
    font-size: 14.5px;
    line-height: 1.9;
}

.as-request-grid {
    display: grid;
    grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
    gap: clamp(32px, 6vw, 96px);
    align-items: start;
}

.as-request-copy .q-lede {
    margin-top: 16px;
}

.as-request-aside {
    margin-top: 16px;
    padding: 22px 24px;
}

.as-request-copy .as-request-aside:first-of-type {
    margin-top: 32px;
}

.as-request-aside h3 {
    margin: 0;
    font-size: 17px;
    font-weight: 500;
}

.as-request-aside p {
    margin: 6px 0 10px;
    color: var(--slate);
    font-size: 15px;
    line-height: 1.9;
}

.as-request-form-wrap .ct-message {
    margin-bottom: 16px;
}

.as-request-form textarea {
    min-height: 120px;
}

/* ---------- Code entry and closed link ---------- */

.as-gate {
    min-height: calc(100vh - 72px);
    display: grid;
    place-items: center;
    padding: calc(72px + 48px) 16px 72px;
}

.as-gate-card {
    width: min(480px, 100%);
    padding: clamp(28px, 5vw, 44px);
    border-radius: var(--q-r-lg);
    background: var(--q-panel);
}

.as-gate-card .q-h3 {
    margin-top: 14px;
}

.as-gate-lede {
    margin: 10px 0 24px;
    color: var(--slate);
    font-size: 15.5px;
    line-height: 1.95;
}

.as-gate-card .ct-message {
    margin-bottom: 16px;
}

.as-gate-form {
    display: grid;
    gap: 16px;
}

.as-gate-form input {
    font-size: 24px;
    letter-spacing: .4em;
    text-align: center;
}

.as-gate-form .q-btn {
    justify-self: start;
}

.as-gate-help {
    margin: 22px 0 0;
    color: var(--slate);
    font-size: 14px;
}

.as-gate-help a {
    color: var(--ink);
    text-decoration: underline;
    text-underline-offset: 3px;
}

/* ---------- The form ---------- */

.as-form-page {
    background: var(--paper-2);
}

.as-form-shell {
    display: grid;
    grid-template-columns: 300px minmax(0, 1fr);
    gap: clamp(20px, 3vw, 40px);
    align-items: start;
    padding: calc(72px + 28px) 0 96px;
}

.as-side {
    position: sticky;
    top: 92px;
    max-height: calc(100vh - 108px);
    display: flex;
    flex-direction: column;
    gap: 10px;
    overflow: auto;
    scrollbar-width: thin;
}

.as-side-card {
    padding: 20px;
    border-radius: var(--q-r-md);
    background: #fff;
}

.as-company {
    margin: 10px 0 0;
    font-size: 19px;
    font-weight: 500;
    line-height: 1.6;
}

.as-overall {
    margin-top: 14px;
}

.as-overall-row {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 4px 10px;
    font-size: 13.5px;
}

.as-overall-row > span:first-child {
    font-weight: 500;
}

.as-save {
    color: var(--slate);
}

.as-save[data-tone="ok"] {
    color: #2f7a5b;
}

.as-save[data-tone="error"] {
    color: #a63d2f;
}

.as-bar {
    height: 6px;
    margin-top: 8px;
    overflow: hidden;
    border-radius: 99px;
    background: var(--q-panel);
}

.as-bar i {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: var(--steel);
    transition: width .35s var(--q-ease);
}

.as-nav {
    padding: 8px;
    border-radius: var(--q-r-md);
    background: #fff;
}

.as-nav ol {
    margin: 0;
    padding: 0;
    list-style: none;
}

.as-nav li[hidden] {
    display: none;
}

.as-nav a {
    display: grid;
    grid-template-columns: 26px minmax(0, 1fr) auto;
    gap: 10px;
    align-items: center;
    padding: 7px 8px;
    border-radius: 7px;
    color: var(--ink);
    font-size: 14px;
    line-height: 1.6;
}

.as-nav a:hover {
    background: var(--paper-2);
}

.as-nav b {
    width: 24px;
    height: 24px;
    display: grid;
    place-items: center;
    border-radius: 6px;
    background: var(--q-panel);
    font-size: 12px;
    font-weight: 500;
}

.as-nav small {
    color: var(--slate);
    font-size: 12px;
}

.as-nav li.is-done b {
    background: var(--steel);
    color: #fff;
}

.as-nav a[aria-current] {
    background: var(--ink);
    color: #fff;
}

.as-nav a[aria-current] b {
    background: rgba(255, 255, 255, .16);
    color: #fff;
}

.as-nav a[aria-current] small {
    color: rgba(255, 255, 255, .7);
}

.as-side-foot {
    display: grid;
    gap: 10px;
    padding: 16px 20px;
    border-radius: var(--q-r-md);
    background: #fff;
    color: var(--slate);
    font-size: 13.5px;
    line-height: 1.85;
}

.as-side-foot p {
    margin: 0;
}

.as-side-foot .q-link {
    font-size: 14px;
}

.as-signout {
    padding: 0;
    border: 0;
    background: none;
    color: var(--slate);
    font-size: 13.5px;
    text-decoration: underline;
    text-underline-offset: 3px;
    cursor: pointer;
}

.as-main {
    min-width: 0;
    outline: none;
}

.as-main > .ct-message {
    margin-bottom: 14px;
}

.as-main .ct-message a {
    color: inherit;
    font-weight: 500;
    text-decoration: underline;
}

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

.as-sec[hidden],
.as-q[hidden] {
    display: none;
}

/* Clear the fixed site navigation when a section or question is scrolled to. */
.as-sec,
.as-q {
    scroll-margin-top: 96px;
}

.as-sec-head {
    padding: clamp(22px, 3vw, 32px);
    border-radius: var(--q-r-md);
    background: var(--ink);
    color: #fff;
}

.as-eyebrow {
    margin: 0;
    color: rgba(255, 255, 255, .62);
    font-size: 13.5px;
}

.as-sec-head .q-h3 {
    margin-top: 6px;
}

.as-sec-intro {
    margin: 8px 0 0;
    color: rgba(255, 255, 255, .72);
    font-size: 15px;
    line-height: 1.9;
}

.as-owner {
    display: grid;
    gap: 6px;
    margin-top: 20px;
    font-size: 13.5px;
}

.as-owner label {
    color: rgba(255, 255, 255, .8);
}

.as-owner input {
    width: 100%;
    min-height: 44px;
    padding: 8px 14px;
    border: 1px dashed rgba(255, 255, 255, .3);
    border-radius: 8px;
    background: rgba(255, 255, 255, .06);
    color: #fff;
    font-size: 14.5px;
}

.as-owner input::placeholder {
    color: rgba(255, 255, 255, .5);
}

.as-owner input:focus {
    border-style: solid;
    border-color: rgba(255, 255, 255, .7);
    outline: none;
}

.as-questions {
    display: grid;
    gap: 10px;
    margin-top: 10px;
}

.as-q {
    min-width: 0;
    margin: 0;
    padding: clamp(18px, 2.4vw, 26px);
    border: 1px solid transparent;
    border-radius: var(--q-r-md);
    background: #fff;
    transition: border-color .2s;
}

.as-q.is-answered {
    border-inline-start: 3px solid var(--steel);
}

/* A legend that behaves like a heading inside the card's padding. */
.as-q > legend {
    float: inline-start;
    width: 100%;
    padding: 0;
}

.as-q > legend + * {
    clear: both;
}

.as-q-title {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 6px 12px;
    margin: 0 0 14px;
    font-size: 16.5px;
    font-weight: 500;
    line-height: 1.75;
}

.as-q-title small {
    color: var(--slate);
    font-size: 13px;
    font-weight: 400;
}

.as-q-no {
    flex: none;
    min-width: 34px;
    padding: 1px 7px;
    border-radius: 5px;
    background: var(--q-panel);
    color: var(--slate);
    font-size: 12.5px;
    font-weight: 500;
    text-align: center;
}

.as-q-help,
.as-q-note {
    clear: both;
    margin: -6px 0 14px;
    color: var(--slate);
    font-size: 14px;
    line-height: 1.85;
}

.as-q-note {
    margin: 10px 0 0;
}

/* Options: native inputs, hidden but focusable, drawn by the box after them. */
.as-opt,
.as-level,
.as-mx-cell {
    position: relative;
    display: block;
    cursor: pointer;
}

.as-opt input,
.as-level input,
.as-mx-cell input {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    opacity: 0;
    cursor: pointer;
}

.as-opts {
    display: grid;
    gap: 8px;
    clear: both;
}

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

.as-opts.cols-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.as-opt-box {
    height: 100%;
    display: flex;
    gap: 12px;
    align-items: center;
    padding: 10px 14px;
    border: 1px solid rgba(20, 36, 52, .14);
    border-radius: 8px;
    font-size: 15px;
    line-height: 1.75;
    transition: border-color .15s, background-color .15s;
}

.as-opt:hover .as-opt-box,
.as-level:hover .as-opt-box {
    border-color: var(--slate-light);
}

.as-mark {
    flex: none;
    width: 18px;
    height: 18px;
    display: grid;
    place-items: center;
    border: 1.5px solid var(--slate-light);
    border-radius: 50%;
    background: #fff;
}

.is-multi .as-mark {
    border-radius: 4px;
}

input:checked + .as-opt-box {
    border-color: var(--steel);
    background: #eef3f8;
}

input:checked + .as-opt-box .as-mark {
    border-color: var(--steel);
    background: var(--steel);
    box-shadow: inset 0 0 0 3px #fff;
}

.is-multi input:checked + .as-opt-box .as-mark {
    box-shadow: none;
    background: var(--steel) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7'/%3E%3C/svg%3E") center / 13px no-repeat;
}

input:focus-visible + .as-opt-box,
input:focus-visible + .as-mx-box .as-mx-dot {
    outline: 2px solid var(--copper);
    outline-offset: 2px;
}

input:disabled + .as-opt-box {
    opacity: .45;
    cursor: not-allowed;
}

.as-levels {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 8px;
    clear: both;
}

.as-level .as-opt-box {
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
    padding: 12px;
}

.as-level-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    color: var(--slate);
    font-size: 12.5px;
}

.as-level-head b {
    font-weight: 500;
}

.as-level-bars {
    display: inline-flex;
    gap: 2px;
}

.as-level-bars i {
    width: 4px;
    height: 12px;
    border-radius: 1px;
    background: var(--q-panel);
}

.as-level-bars i.on {
    background: var(--slate-light);
}

.as-level-text {
    font-size: 14px;
    line-height: 1.75;
}

.as-level input:checked + .as-opt-box {
    border-color: var(--ink);
    background: var(--ink);
    color: #fff;
}

.as-level input:checked + .as-opt-box .as-level-head {
    color: rgba(255, 255, 255, .7);
}

.as-level input:checked + .as-opt-box .as-level-bars i {
    background: rgba(255, 255, 255, .2);
}

.as-level input:checked + .as-opt-box .as-level-bars i.on {
    background: var(--copper);
}

/* Grids: a row per item, a column per answer. */
.as-matrix {
    clear: both;
    overflow: clip;
    border: 1px solid rgba(20, 36, 52, .12);
    border-radius: 10px;
}

.as-mx-head,
.as-mx-row {
    display: grid;
    grid-template-columns: minmax(180px, 1fr) repeat(var(--as-cols), minmax(64px, 88px));
    align-items: center;
}

.as-mx-cells {
    display: contents;
}

.as-mx-head {
    position: sticky;
    top: 72px;
    z-index: 1;
    background: var(--paper-2);
    color: var(--slate);
    font-size: 12px;
    line-height: 1.5;
    text-align: center;
}

.as-mx-head span {
    padding: 10px 4px;
}

.as-mx-row {
    border-top: 1px solid rgba(20, 36, 52, .08);
}

.as-mx-row:hover {
    background: #f9fafb;
}

.as-mx-label {
    padding: 10px 14px;
    font-size: 14.5px;
    line-height: 1.75;
}

.as-mx-cell {
    align-self: stretch;
}

.as-mx-box {
    height: 100%;
    min-height: 44px;
    display: grid;
    place-items: center;
}

.as-mx-dot {
    width: 20px;
    height: 20px;
    border: 1.5px solid var(--slate-light);
    border-radius: 50%;
    background: #fff;
}

.as-mx-text {
    display: none;
}

.as-mx-cell input:checked + .as-mx-box .as-mx-dot {
    border-color: var(--steel);
    background: var(--steel);
    box-shadow: inset 0 0 0 4px #fff;
}

.is-pain .as-mx-cell:last-child input:checked + .as-mx-box .as-mx-dot {
    border-color: var(--copper);
    background: var(--copper);
}

.as-input {
    width: 100%;
    min-height: 48px;
    padding: 10px 14px;
    border: 1px solid rgba(20, 36, 52, .18);
    border-radius: 8px;
    background: #fff;
    color: var(--ink);
    font-size: 15px;
    line-height: 1.9;
    transition: border-color .2s, box-shadow .2s;
}

textarea.as-input {
    resize: vertical;
}

.as-input:focus {
    border-color: var(--steel);
    outline: none;
    box-shadow: 0 0 0 3px rgba(43, 73, 108, .15);
}

.as-input[aria-invalid] {
    border-color: #a63d2f;
}

.as-q-error {
    display: block;
    margin-top: 6px;
    color: #a63d2f;
    font-size: 13.5px;
}

.as-q-error[hidden] {
    display: none;
}

.as-sec-foot {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 14px;
}

.as-sec-foot [hidden] {
    display: none;
}

.as-sec-meta {
    color: var(--slate);
    font-size: 14px;
}

.as-sec-foot [data-as-next] {
    margin-inline-start: auto;
}

.as-finish {
    margin-top: 18px;
    padding: clamp(22px, 3vw, 32px);
    border-radius: var(--q-r-md);
    background: var(--q-sky);
}

.as-finish h3 {
    margin: 0;
    font-size: 20px;
    font-weight: 500;
}

.as-finish > p {
    margin: 6px 0 16px;
    font-size: 15px;
    line-height: 1.9;
}

.as-finish [data-as-first-missing] {
    margin-bottom: 12px;
}

.as-finish .q-btn:disabled {
    opacity: .5;
    cursor: not-allowed;
}

.as-confirm {
    margin-top: 4px;
    padding: 18px 20px;
    border-radius: 10px;
    background: #fff;
}

.as-confirm p {
    margin: 0;
    font-size: 15px;
    line-height: 1.9;
}

.as-confirm .q-actions {
    margin-top: 14px;
}

/* ---------- Blank questionnaire for printing ---------- */

.as-sheet {
    max-width: 900px;
    padding: calc(72px + 32px) 0 72px;
    font-size: 14px;
}

.as-sheet-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 28px;
    padding: 16px 20px;
    border-radius: var(--q-r-md);
    background: var(--q-panel);
}

.as-sheet-bar p {
    margin: 0;
    color: var(--slate);
}

.as-sheet-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--ink);
}

.as-sheet-head h1 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    text-align: end;
}

.as-sheet-head p {
    margin: 0;
    color: var(--slate);
    font-size: 12.5px;
    text-align: end;
}

.as-sheet-info {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px 24px;
    margin: 16px 0 10px;
}

.as-sheet-info span {
    padding-bottom: 14px;
    border-bottom: 1px dotted var(--slate-light);
    color: var(--slate);
}

.as-sheet-note {
    margin: 0 0 18px;
    color: var(--slate);
    font-size: 12.5px;
}

.as-sheet-sec h2 {
    margin: 22px 0 8px;
    padding: 6px 12px;
    border-radius: 6px;
    background: var(--ink);
    color: #fff;
    font-size: 15px;
    font-weight: 600;
}

.as-sheet-sec h2 small,
.as-sheet-title small {
    font-weight: 400;
    opacity: .75;
}

.as-sheet-owner {
    margin: 0 0 8px;
    padding-bottom: 10px;
    border-bottom: 1px dotted var(--slate-light);
    color: var(--slate);
    font-size: 12.5px;
}

.as-sheet-q {
    padding: 8px 0;
    border-bottom: 1px solid var(--line);
    break-inside: avoid;
}

.as-sheet-q.is-matrix {
    break-inside: auto;
}

.as-sheet-title {
    margin: 0 0 6px;
    font-weight: 600;
}

.as-sheet-opts {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 18px;
}

.as-sheet-levels {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 6px;
    font-size: 12px;
}

.as-sheet-levels span {
    padding: 6px;
    border: 1px solid var(--line);
    border-radius: 5px;
}

.as-sheet-levels b {
    display: block;
    font-weight: 600;
}

.as-sheet table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
}

.as-sheet th,
.as-sheet td {
    padding: 4px 6px;
    border: 1px solid var(--line);
    text-align: start;
}

.as-sheet th {
    background: var(--paper-2);
    font-weight: 500;
}

.as-sheet td.is-cell {
    text-align: center;
}

.as-sheet-line {
    height: 22px;
    border-bottom: 1px dotted var(--slate-light);
}

.as-sheet-lines {
    height: 66px;
    background: repeating-linear-gradient(to bottom, transparent 0 21px, var(--slate-light) 21px 22px);
}

@media print {
    .as-print-page .site-nav,
    .as-print-page .site-announcement,
    .as-print-page .site-footer,
    .as-print-page .skip-link,
    .as-sheet-bar {
        display: none !important;
    }

    .as-print-page main,
    .as-print-page.has-site-announcement main {
        padding: 0 !important;
    }

    .as-sheet {
        width: auto;
        max-width: none;
        padding: 0;
        font-size: 11.5px;
    }

    .as-sheet-sec h2 {
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }
}

/* ---------- Narrow screens ---------- */

@media (max-width: 1100px) {
    .as-levels {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

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

@media (max-width: 960px) {
    .as-hero-grid,
    .as-request-grid {
        grid-template-columns: minmax(0, 1fr);
    }

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

    .as-form-shell {
        grid-template-columns: minmax(0, 1fr);
        padding-top: calc(64px + 16px);
    }

    .as-side {
        position: static;
        max-height: none;
        overflow: visible;
    }

    .as-nav {
        display: none;
    }

    .as-side-foot {
        order: 3;
    }

    .as-mobile-nav {
        position: sticky;
        top: 64px;
        z-index: 3;
        display: flex;
        align-items: center;
        gap: 10px;
        margin: 0 0 10px;
        padding: 10px 12px;
        border-radius: var(--q-r-md);
        background: #fff;
        box-shadow: 0 6px 18px rgba(20, 36, 52, .08);
        font-size: 14px;
    }

    .as-mobile-nav select {
        flex: 1;
        min-height: 42px;
        padding: 6px 10px;
        border: 1px solid rgba(20, 36, 52, .18);
        border-radius: 8px;
        background: #fff;
        font-size: 15px;
    }

    .as-mx-head {
        top: 128px;
    }

    .as-sec,
    .as-q {
        scroll-margin-top: 140px;
    }
}

@media (max-width: 720px) {
    .as-area-list,
    .as-report-list,
    .as-steps,
    .as-sheet-info,
    .as-sheet-levels,
    .as-opts.cols-2,
    .as-opts.cols-3 {
        grid-template-columns: minmax(0, 1fr);
    }

    .as-levels {
        grid-template-columns: minmax(0, 1fr);
    }

    .as-level .as-opt-box {
        display: grid;
        grid-template-columns: auto minmax(0, 1fr);
        align-items: center;
        gap: 12px;
    }

    .as-level-head {
        flex-direction: column;
        align-items: flex-start;
        gap: 2px;
    }

    /* Grids become one card per row, with the answers as chips. */
    .as-matrix {
        border: 0;
        border-radius: 0;
    }

    .as-mx-head {
        display: none;
    }

    .as-mx-row {
        display: block;
        padding: 12px 0;
    }

    .as-mx-row:hover {
        background: none;
    }

    .as-mx-label {
        display: block;
        padding: 0 0 8px;
        font-weight: 500;
    }

    .as-mx-cells {
        display: flex;
        flex-wrap: wrap;
        gap: 6px;
    }

    .as-mx-box {
        min-height: 36px;
        display: flex;
        gap: 6px;
        padding: 5px 12px 5px 10px;
        border: 1px solid rgba(20, 36, 52, .14);
        border-radius: 99px;
    }

    .as-mx-dot {
        width: 14px;
        height: 14px;
    }

    .as-mx-text {
        display: inline;
        font-size: 13.5px;
    }

    .as-mx-cell input:checked + .as-mx-box {
        border-color: var(--steel);
        background: #eef3f8;
    }

    .as-sec-foot .q-btn {
        flex: 1;
    }

    .as-sec-meta {
        order: -1;
        width: 100%;
    }

    .as-report-preview {
        margin: 0;
        border-radius: 0;
    }
}

@media (prefers-reduced-motion: reduce) {
    .as-bar i,
    .as-q,
    .as-opt-box {
        transition: none;
    }
}
