/* ROSHAN assessment (/roshan) and its report. Builds on site-v5.css.
 * The hero borrows Scale's enterprise opener: the six stages float around the
 * headline as tiles joined by one thin line, in the order they are assessed. */

.rs-page,
.rs-result-page {
    background: #fff;
}

/* ---------- Hero ---------- */

.rs-hero {
    position: relative;
    min-height: min(92vh, 860px);
    display: grid;
    place-items: center;
    padding: calc(72px + 40px) 0 72px;
    overflow: hidden;
}

.rs-hero-field {
    position: absolute;
    inset: 72px 0 0;
    pointer-events: none;
}

.rs-hero-lines {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.rs-hero-lines line {
    stroke: rgba(20, 36, 52, .2);
    stroke-width: 1;
}

.rs-tile {
    position: absolute;
    top: var(--y);
    left: var(--x);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    transform: translate(-50%, -50%);
}

.rs-tile b {
    width: clamp(72px, 7.4vw, 112px);
    aspect-ratio: 1;
    display: grid;
    place-items: center;
    border-radius: var(--q-r-md);
    background: var(--ink);
    color: #fff;
    font-size: clamp(30px, 3vw, 46px);
    font-weight: 500;
    line-height: 1;
}

.rs-tile.is-1 b { background: var(--steel); }
.rs-tile.is-2 b { background: var(--slate); }
.rs-tile.is-3 b { background: var(--q-sky); color: var(--ink); }
.rs-tile.is-4 b { background: var(--steel-light); color: var(--ink); }
.rs-tile.is-5 b { background: var(--q-panel); color: var(--ink); }

.rs-tile small {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--slate);
    font-size: 13px;
    white-space: nowrap;
}

.rs-tile small::before {
    width: 6px;
    height: 6px;
    background: var(--copper);
    content: "";
}

.rs-hero-copy {
    position: relative;
    z-index: 1;
    max-width: 720px;
    padding-inline: var(--gutter);
    text-align: center;
}

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

.rs-hero-copy .q-display {
    font-size: clamp(36px, 4.6vw, 64px);
}

.rs-hero-copy .q-lede {
    max-width: 560px;
    margin: 18px auto 0;
}

.rs-hero-actions {
    justify-content: center;
}

.rs-facts {
    margin: 16px 0 0;
    color: var(--slate);
    font-size: 14.5px;
}

/* ---------- Six stages, on the night band ---------- */

.rs-stages {
    padding-block: clamp(80px, 10vw, 140px);
    background: var(--q-night);
    color: #fff;
}

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

.rs-stage {
    display: flex;
    flex-direction: column;
    padding: clamp(22px, 2.4vw, 30px);
    border-radius: var(--q-r-md);
    background: rgba(255, 255, 255, .055);
}

.rs-stage-letter {
    display: flex;
    align-items: baseline;
    justify-content: flex-end;
    gap: 10px;
    font-size: 44px;
    font-weight: 400;
    line-height: 1;
}

.rs-stage-letter small {
    color: var(--slate-light);
    font-size: 13px;
}

.rs-stage h3 {
    margin: 26px 0 0;
    font-size: 20px;
    font-weight: 500;
}

.rs-stage p {
    margin: 8px 0 0;
    color: rgba(255, 255, 255, .62);
    font-size: 14.5px;
    line-height: 1.9;
}

.rs-stage .rs-stage-question {
    color: #fff;
    font-size: 15.5px;
}

.rs-stage-facts {
    margin: 10px 0 0;
}

.rs-stage-facts dd {
    margin: 0;
}

/* ---------- Assessment ---------- */

.rs-assessment {
    scroll-margin-top: 72px;
}

.rs-assessment-grid {
    display: grid;
    grid-template-columns: minmax(0, .72fr) minmax(0, 1.28fr);
    align-items: start;
    gap: clamp(28px, 4vw, 64px);
}

.rs-intro {
    position: sticky;
    top: 104px;
}

.rs-intro > p {
    margin: 14px 0 0;
    color: var(--slate);
    font-size: 15.5px;
}

.rs-levels {
    margin: 26px 0 0;
    border-top: 1px solid var(--line);
}

.rs-levels div {
    display: grid;
    grid-template-columns: 30px minmax(0, 1fr);
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid var(--line);
}

.rs-levels dt {
    width: 28px;
    height: 28px;
    display: grid;
    place-items: center;
    border-radius: 7px;
    background: var(--q-panel);
    font-size: 14px;
    font-weight: 500;
}

.rs-levels dd {
    margin: 0;
}

.rs-levels b {
    display: block;
    font-size: 15px;
    font-weight: 500;
    line-height: 1.7;
}

.rs-levels small {
    color: var(--slate);
    font-size: 13.5px;
    line-height: 1.8;
}

.rs-form {
    padding: clamp(16px, 2vw, 24px);
    border-radius: var(--q-r-lg);
    background: var(--q-panel);
}

.rs-form-head {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 12px;
    padding: 6px 6px 12px;
}

.rs-form-head span {
    display: block;
    color: var(--slate);
    font-size: 13.5px;
}

.rs-form-head strong {
    display: block;
    font-size: 20px;
    font-weight: 500;
}

.rs-form-head b {
    font-size: 20px;
    font-weight: 400;
}

.rs-progress {
    height: 4px;
    margin: 0 6px 16px;
    overflow: hidden;
    border-radius: 4px;
    background: rgba(20, 36, 52, .1);
}

.rs-progress i {
    display: block;
    height: 100%;
    border-radius: 4px;
    background: var(--ink);
    transition: width .5s var(--q-ease);
}

.rs-error-summary {
    display: flex;
    flex-direction: column;
    margin: 0 0 12px;
    padding: 14px 16px;
    border-radius: var(--q-r-sm);
    background: #f8e9e6;
    color: #7a2a1f;
    font-size: 14.5px;
}

.rs-step {
    margin: 0;
    padding: 0;
    border: 0;
}

.rs-step[hidden] {
    display: none;
}

.rs-step legend {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr);
    gap: 2px 16px;
    width: 100%;
    margin-bottom: 10px;
    padding: 20px;
    border-radius: var(--q-r-md);
    background: var(--ink);
    color: #fff;
}

.rs-step legend span {
    grid-row: 1 / 3;
    width: 52px;
    height: 52px;
    display: grid;
    place-items: center;
    border-radius: 10px;
    background: rgba(255, 255, 255, .1);
    font-size: 26px;
    font-weight: 500;
}

.rs-step legend b {
    font-size: 19px;
    font-weight: 500;
    line-height: 1.6;
}

.rs-step legend small {
    color: rgba(255, 255, 255, .68);
    font-size: 14.5px;
    line-height: 1.8;
}

.rs-question {
    margin-top: 8px;
    padding: clamp(18px, 2vw, 24px);
    border: 1px solid transparent;
    border-radius: var(--q-r-md);
    background: #fff;
    transition: border-color .2s;
}

.rs-question.is-invalid,
.rs-question.has-error {
    border-color: #c4553f;
}

.rs-question-copy span {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--slate);
    font-size: 13.5px;
}

.rs-question-copy em {
    padding: 1px 8px;
    border-radius: 4px;
    background: rgba(214, 145, 76, .16);
    color: #7a4a1c;
    font-size: 12.5px;
    font-style: normal;
}

.rs-question-copy h3 {
    margin: 8px 0 0;
    font-size: 17.5px;
    font-weight: 500;
    line-height: 1.75;
}

.rs-question-copy p {
    margin: 4px 0 0;
    color: var(--slate);
    font-size: 14.5px;
    line-height: 1.85;
}

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

.rs-options {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 6px;
    margin-top: 16px;
}

.rs-options label {
    position: relative;
    cursor: pointer;
}

.rs-options input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.rs-options span {
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 10px 6px;
    border: 1px solid rgba(20, 36, 52, .14);
    border-radius: var(--q-r-sm);
    text-align: center;
    transition: background-color .2s, border-color .2s, color .2s;
}

.rs-options b {
    font-size: 17px;
    font-weight: 500;
    line-height: 1.2;
}

.rs-options small {
    color: var(--slate);
    font-size: 12.5px;
    line-height: 1.5;
}

.rs-options label:hover span {
    border-color: var(--ink);
}

.rs-options input:checked + span {
    border-color: var(--ink);
    background: var(--ink);
    color: #fff;
}

.rs-options input:checked + span small {
    color: rgba(255, 255, 255, .78);
}

.rs-options input:focus-visible + span {
    outline: 2px solid var(--copper);
    outline-offset: 2px;
}

.rs-profile-step .q-field {
    padding: 0;
}

.rs-profile-grid {
    padding: 20px;
    border-radius: var(--q-r-md);
    background: #fff;
}

.rs-email-field {
    grid-column: 1 / -1;
}

.rs-consents {
    display: grid;
    gap: 8px;
    margin-top: 8px;
}

.rs-consents label {
    display: flex;
    gap: 12px;
    padding: 16px 18px;
    border: 1px solid transparent;
    border-radius: var(--q-r-md);
    background: #fff;
    cursor: pointer;
}

.rs-consents label.is-invalid {
    border-color: #c4553f;
}

.rs-consents input {
    width: 18px;
    height: 18px;
    flex: none;
    margin-top: 5px;
    accent-color: var(--ink);
}

.rs-consents b {
    display: block;
    font-size: 15px;
    font-weight: 500;
}

.rs-consents small {
    color: var(--slate);
    font-size: 13.5px;
}

.rs-privacy {
    margin: 6px 4px 0;
    color: var(--slate);
    font-size: 13.5px;
}

.rs-privacy a {
    color: var(--ink);
    text-decoration: underline;
    text-underline-offset: 3px;
}

.rs-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 16px;
}

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

.rs-back {
    margin-inline-end: auto;
}

/* ---------- Report ---------- */

.rs-report-hero {
    padding: calc(72px + clamp(36px, 5vw, 64px)) 0 clamp(24px, 3vw, 40px);
}

.rs-report-top {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(0, .6fr);
    gap: 12px;
}

.rs-report-heading {
    padding: clamp(28px, 4vw, 56px);
    border-radius: var(--q-r-lg);
    background: var(--q-panel);
}

.rs-report-heading .q-lede {
    max-width: 640px;
    margin-top: 14px;
}

.rs-report-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 18px;
    margin-top: 24px;
    color: var(--slate);
    font-size: 14px;
}

.rs-score {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: clamp(24px, 3vw, 40px);
    border-radius: var(--q-r-lg);
    background: var(--ink);
    color: #fff;
}

.rs-score span {
    color: rgba(255, 255, 255, .7);
    font-size: 14.5px;
}

.rs-score strong {
    margin-top: 24px;
    font-size: clamp(56px, 7vw, 96px);
    font-weight: 400;
    line-height: 1;
}

.rs-score small {
    color: rgba(255, 255, 255, .6);
    font-size: 14px;
}

.rs-score i {
    position: relative;
    display: block;
    height: 6px;
    margin-top: 20px;
    overflow: hidden;
    border-radius: 6px;
    background: rgba(255, 255, 255, .14);
}

.rs-score i::after {
    position: absolute;
    inset: 0 0 0 auto;
    width: var(--score);
    border-radius: 6px;
    background: #fff;
    content: "";
}

.rs-score.is-green i::after,
.rs-score.is-navy i::after { background: #9cc9ab; }
.rs-score.is-copper i::after,
.rs-score.is-warning i::after { background: var(--copper); }

.rs-verdict {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(0, .6fr);
    gap: 12px;
    margin-top: 12px;
}

.rs-verdict-copy {
    padding: clamp(24px, 3vw, 40px);
    border-radius: var(--q-r-lg);
    background: var(--q-sky);
}

.rs-verdict-copy h2 {
    margin: 10px 0 0;
    font-size: clamp(22px, 2.2vw, 30px);
    font-weight: 400;
    line-height: 1.6;
}

.rs-verdict-copy p {
    margin: 12px 0 0;
    font-size: 15.5px;
}

.rs-case {
    padding: clamp(24px, 3vw, 40px);
    border-radius: var(--q-r-lg);
    background: var(--q-panel);
}

.rs-case span {
    color: var(--slate);
    font-size: 14.5px;
}

.rs-case strong {
    display: block;
    margin-top: 16px;
    font-size: 52px;
    font-weight: 400;
    line-height: 1;
}

.rs-case strong small {
    color: var(--slate);
    font-size: 16px;
}

.rs-case p {
    margin: 14px 0 0;
    color: var(--slate);
    font-size: 14px;
}

.rs-report-stages {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}

.rs-report-stage {
    padding: 22px;
    border-radius: var(--q-r-md);
    background: var(--q-panel);
}

.rs-report-stage header {
    display: flex;
    align-items: center;
    gap: 12px;
}

.rs-report-stage header b {
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border-radius: 9px;
    background: var(--ink);
    color: #fff;
    font-size: 20px;
    font-weight: 500;
}

.rs-report-stage h3 {
    flex: 1;
    margin: 0;
    font-size: 17.5px;
    font-weight: 500;
}

.rs-report-stage header strong {
    font-size: 28px;
    font-weight: 400;
}

.rs-bar {
    height: 5px;
    margin: 16px 0 12px;
    overflow: hidden;
    border-radius: 5px;
    background: rgba(20, 36, 52, .1);
}

.rs-bar i {
    display: block;
    height: 100%;
    margin-inline-start: auto;
    border-radius: 5px;
    background: var(--ink);
}

.rs-report-stage.is-fair .rs-bar i { background: var(--copper); }
.rs-report-stage.is-poor .rs-bar i { background: #b5503b; }

.rs-report-stage p {
    margin: 0;
    color: var(--slate);
    font-size: 14.5px;
}

.rs-report-stage footer {
    display: flex;
    flex-direction: column;
    gap: 2px;
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px solid var(--line);
    font-size: 14px;
}

.rs-report-stage footer span {
    font-weight: 500;
}

.rs-report-stage footer small {
    color: var(--slate);
    font-size: 13.5px;
}

.rs-gaps {
    padding: clamp(28px, 4vw, 56px);
    border-radius: var(--q-r-lg);
    background: var(--q-night);
    color: #fff;
}

.rs-gaps ol {
    margin: clamp(20px, 3vw, 32px) 0 0;
    padding: 0;
    list-style: none;
}

.rs-gaps li {
    display: grid;
    grid-template-columns: 36px minmax(0, 1fr);
    gap: 16px;
    padding: 18px 0;
    border-top: 1px solid rgba(255, 255, 255, .12);
}

.rs-gaps li > span {
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    border-radius: 7px;
    background: var(--copper);
    color: var(--ink);
    font-size: 14px;
    font-weight: 500;
}

.rs-gaps small {
    color: var(--slate-light);
    font-size: 13.5px;
}

.rs-gaps h3 {
    margin: 2px 0 0;
    font-size: 17.5px;
    font-weight: 500;
}

.rs-gaps p {
    margin: 4px 0 0;
    color: rgba(255, 255, 255, .7);
    font-size: 15px;
}

.rs-strengths {
    padding: clamp(24px, 3vw, 36px);
    border-radius: var(--q-r-lg);
    background: var(--q-panel);
}

.rs-strengths div {
    padding: 12px 0;
    border-bottom: 1px solid var(--line);
}

.rs-strengths b {
    font-size: 14px;
    font-weight: 500;
}

.rs-strengths p {
    margin: 2px 0 0;
    color: var(--slate);
    font-size: 14.5px;
}

.rs-answers details {
    border-radius: var(--q-r-lg);
    background: var(--q-panel);
}

.rs-answers summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 22px 26px;
    font-size: 17px;
    font-weight: 500;
    cursor: pointer;
    list-style: none;
}

.rs-answers summary::-webkit-details-marker {
    display: none;
}

.rs-answers summary b {
    padding: 6px 12px;
    border-radius: var(--q-r-sm);
    background: #fff;
    font-size: 14px;
    font-weight: 500;
}

.rs-answer-stages {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    padding: 0 16px 16px;
}

.rs-answer-stages section {
    padding: 18px;
    border-radius: var(--q-r-md);
    background: #fff;
}

.rs-answer-stages header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.rs-answer-stages header b {
    width: 30px;
    height: 30px;
    display: grid;
    place-items: center;
    border-radius: 7px;
    background: var(--ink);
    color: #fff;
}

.rs-answer-stages h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 500;
}

.rs-answer-row {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr);
    gap: 10px;
    padding: 10px 0;
    border-top: 1px solid var(--line);
}

.rs-answer-row span {
    font-size: 14px;
    font-weight: 500;
}

.rs-answer-row p {
    margin: 0;
    font-size: 14.5px;
    line-height: 1.8;
}

.rs-answer-row small {
    color: var(--slate);
    font-size: 13.5px;
}

.rs-report-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-top: 26px;
}

.rs-report-actions button {
    border: 0;
    background: none;
}

/* ---------- Responsive ---------- */

@media (max-width: 1000px) {
    .rs-stage-grid,
    .rs-report-stages {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .rs-assessment-grid,
    .rs-report-top,
    .rs-verdict {
        grid-template-columns: minmax(0, 1fr);
    }

    .rs-intro {
        position: static;
    }

    .rs-levels {
        display: none;
    }
}

@media (max-width: 760px) {
    .rs-hero {
        min-height: 0;
        display: block;
        padding: calc(64px + 28px) 0 56px;
    }

    .rs-hero-field {
        position: static;
        direction: ltr;
        display: flex;
        justify-content: center;
        gap: 6px;
        margin: 0 auto 36px;
        padding-inline: 20px;
    }

    .rs-hero-lines,
    .rs-tile small {
        display: none;
    }

    .rs-tile {
        position: static;
        transform: none;
    }

    .rs-tile b {
        width: 46px;
        border-radius: 9px;
        font-size: 21px;
    }

    .rs-stage-grid,
    .rs-report-stages,
    .rs-answer-stages {
        grid-template-columns: minmax(0, 1fr);
    }

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

    .rs-options span {
        flex-direction: row;
        justify-content: flex-start;
        gap: 12px;
        padding: 10px 14px;
        text-align: right;
    }

    .rs-step legend {
        grid-template-columns: 44px minmax(0, 1fr);
        padding: 16px;
    }

    .rs-step legend span {
        width: 44px;
        height: 44px;
        font-size: 22px;
    }

    .rs-actions .q-btn {
        flex: 1;
    }
}

@media print {
    .rs-result-page .site-nav,
    .rs-result-page .site-footer,
    .rs-report-actions,
    .rs-answers {
        display: none !important;
    }

    .rs-report-hero {
        padding-top: 0;
    }
}
