:root {
    --ink: #15243a;
    --muted: #667085;
    --line: #dce5e6;
    --surface: #ffffff;
    --soft: #f4f8f7;
    --green: #047857;
    --green-2: #0f9f7b;
    --blue: #234c84;
    --gold: #d79a2b;
    --danger: #b42318;
    --shadow: 0 24px 70px rgba(21, 36, 58, .12);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--ink);
    background:
        linear-gradient(180deg, #f8fbfa 0%, #ffffff 42%, #f6faf8 100%);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    line-height: 1.5;
}

a {
    color: inherit;
    text-decoration: none;
}

.topbar {
    position: sticky;
    top: 0;
    z-index: 10;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    padding: 18px clamp(18px, 4vw, 56px);
    background: rgba(255, 255, 255, .88);
    border-bottom: 1px solid rgba(220, 229, 230, .8);
    backdrop-filter: blur(18px);
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
}

.brand-mark {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border-radius: 8px;
    color: #fff;
    background: linear-gradient(135deg, var(--green), var(--blue));
    font-weight: 900;
    font-size: 25px;
    box-shadow: 0 12px 28px rgba(4, 120, 87, .24);
}

.brand strong,
.brand small {
    display: block;
}

.brand small {
    color: var(--muted);
    font-weight: 700;
    letter-spacing: 0;
}

.nav {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav a {
    padding: 10px 12px;
    border-radius: 8px;
    color: var(--muted);
    font-weight: 800;
}

.nav a:hover {
    color: var(--green);
    background: #eef8f4;
}

main {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
}

.hero {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(320px, .85fr);
    gap: clamp(28px, 5vw, 72px);
    align-items: center;
    min-height: calc(100vh - 82px);
    padding: 48px 0 64px;
}

.eyebrow {
    display: inline-flex;
    width: fit-content;
    padding: 7px 11px;
    border: 1px solid #cfe8df;
    border-radius: 8px;
    color: var(--green);
    background: #f0faf6;
    font-size: 12px;
    font-weight: 900;
    text-transform: uppercase;
}

h1,
h2 {
    margin: 14px 0 14px;
    line-height: 1.04;
    letter-spacing: 0;
}

h1 {
    max-width: 760px;
    font-size: clamp(42px, 6vw, 76px);
}

h2 {
    font-size: clamp(30px, 4vw, 48px);
}

.hero-copy p,
.section-heading p,
.dashboard-hero p {
    max-width: 680px;
    color: var(--muted);
    font-size: 18px;
}

.hero-actions,
.form-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
    margin-top: 28px;
}

.button {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    min-height: 48px;
    padding: 0 18px;
    border: 1px solid transparent;
    border-radius: 8px;
    cursor: pointer;
    font: inherit;
    font-weight: 900;
}

.button.primary {
    color: #fff;
    background: var(--green);
    box-shadow: 0 16px 34px rgba(4, 120, 87, .22);
}

.button.primary:hover {
    background: #036c4f;
}

.button.ghost {
    color: var(--blue);
    background: #fff;
    border-color: var(--line);
}

.hero-panel {
    position: relative;
    display: grid;
    gap: 16px;
    padding: 16px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 255, 255, .78);
    box-shadow: var(--shadow);
}

.metric-card {
    min-height: 210px;
    padding: 28px;
    border-radius: 8px;
    color: #fff;
    background:
        linear-gradient(145deg, rgba(255, 255, 255, .16), rgba(255, 255, 255, 0)),
        linear-gradient(135deg, var(--blue), var(--green));
}

.metric-card span,
.metric-card small {
    display: block;
    opacity: .9;
    font-weight: 800;
}

.metric-card strong {
    display: block;
    margin: 12px 0;
    font-size: 88px;
    line-height: .9;
}

.metric-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.metric-grid div {
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.metric-grid strong,
.metric-grid span {
    display: block;
}

.metric-grid strong {
    font-size: 24px;
}

.metric-grid span {
    color: var(--muted);
    font-weight: 800;
}

.trust-band {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1px;
    overflow: hidden;
    margin-bottom: 76px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--line);
}

.trust-band div {
    padding: 24px;
    background: #fff;
}

.trust-band strong,
.trust-band span {
    display: block;
}

.trust-band span {
    margin-top: 4px;
    color: var(--muted);
}

.questionnaire-shell {
    padding: 16px 0 90px;
}

.section-heading {
    margin-bottom: 24px;
}

.survey-card {
    padding: clamp(18px, 4vw, 42px);
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    box-shadow: var(--shadow);
}

.progress-wrap {
    margin-bottom: 26px;
}

.progress-text {
    margin-bottom: 8px;
    color: var(--muted);
    font-weight: 800;
    text-align: right;
}

.progress-track,
.bar {
    overflow: hidden;
    height: 10px;
    border-radius: 999px;
    background: #edf2f2;
}

.progress-track span,
.bar span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--green), var(--gold));
    transition: width .25s ease;
}

fieldset {
    margin: 0 0 26px;
    padding: 24px;
    border: 1px solid var(--line);
    border-radius: 8px;
}

legend {
    padding: 0 10px;
    color: var(--blue);
    font-size: 18px;
    font-weight: 950;
}

label,
.question-group p,
.likert p {
    display: block;
    color: #26384f;
    font-weight: 850;
}

input,
select {
    width: 100%;
    min-height: 46px;
    margin-top: 8px;
    padding: 0 12px;
    border: 1px solid #cfdadd;
    border-radius: 8px;
    color: var(--ink);
    background: #fff;
    font: inherit;
}

input:focus,
select:focus {
    outline: 3px solid rgba(15, 159, 123, .18);
    border-color: var(--green-2);
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
    margin-top: 18px;
}

.wide {
    grid-column: 1 / -1;
}

.check-row {
    display: grid;
    grid-template-columns: 20px 1fr;
    gap: 12px;
    align-items: start;
    margin: 12px 0;
    font-weight: 750;
}

.check-row input {
    width: 18px;
    min-height: 18px;
    margin-top: 3px;
}

.question-group {
    margin-top: 20px;
    padding-top: 18px;
    border-top: 1px solid #edf2f2;
}

.likert {
    display: grid;
    grid-template-columns: 1fr repeat(3, minmax(110px, auto));
    gap: 12px;
    align-items: center;
    padding: 14px 0;
    border-bottom: 1px solid #edf2f2;
}

.likert label {
    display: inline-flex;
    gap: 8px;
    align-items: center;
    color: var(--muted);
    font-weight: 800;
}

.likert input {
    width: 16px;
    min-height: 16px;
    margin: 0;
}

.matrix {
    overflow-x: auto;
}

.matrix p {
    margin-top: 0;
    color: #26384f;
    font-weight: 850;
}

.matrix-head,
.matrix-row {
    display: grid;
    grid-template-columns: minmax(210px, 1.5fr) repeat(4, minmax(112px, 1fr));
    gap: 10px;
    align-items: center;
    min-width: 720px;
}

.matrix-head {
    padding: 0 0 10px;
    color: var(--muted);
    font-size: 13px;
    font-weight: 900;
    text-align: center;
}

.matrix-row {
    padding: 13px 0;
    border-top: 1px solid #edf2f2;
}

.matrix-row strong {
    font-size: 14px;
}

.matrix-row label {
    display: flex;
    justify-content: center;
    align-items: center;
}

.matrix-row label span {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
}

.matrix-row input {
    width: 18px;
    min-height: 18px;
    margin: 0;
}

.conditional {
    display: none;
    margin-top: 16px;
}

.conditional.is-visible {
    display: block;
}

.form-actions p {
    margin: 0;
    color: var(--muted);
}

footer {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 28px clamp(18px, 4vw, 56px);
    color: var(--muted);
    border-top: 1px solid var(--line);
}

.center-page {
    display: grid;
    min-height: 100vh;
    place-items: center;
    padding: 24px;
}

.success-card {
    width: min(560px, 100%);
    padding: 42px;
    text-align: center;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    box-shadow: var(--shadow);
}

.success-icon {
    display: inline-grid;
    place-items: center;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    color: #fff;
    background: var(--green);
    font-size: 32px;
    font-weight: 900;
}

.code-box {
    margin: 24px auto;
    padding: 14px 16px;
    border: 1px dashed var(--green);
    border-radius: 8px;
    color: var(--green);
    background: #f0faf6;
    font-size: 22px;
    font-weight: 950;
}

.dashboard {
    padding: 48px 0 90px;
}

.dashboard-hero {
    display: flex;
    justify-content: space-between;
    align-items: end;
    gap: 24px;
    margin-bottom: 28px;
}

.university-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 16px;
}

.uni-card {
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 14px 34px rgba(21, 36, 58, .08);
}

.uni-head {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
}

.uni-head span {
    color: var(--blue);
    font-weight: 950;
}

.uni-head strong {
    font-size: 34px;
}

.uni-card p {
    min-height: 48px;
    color: var(--muted);
    font-size: 14px;
}

.uni-card dl {
    display: grid;
    gap: 8px;
    margin: 16px 0 0;
}

.uni-card dl div {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    color: var(--muted);
}

.uni-card dt,
.uni-card dd {
    margin: 0;
}

.uni-card dd {
    color: var(--ink);
    font-weight: 900;
}

@media (max-width: 980px) {
    .hero,
    .trust-band,
    .university-grid {
        grid-template-columns: 1fr;
    }

    .hero {
        min-height: auto;
    }

    .dashboard-hero {
        align-items: start;
        flex-direction: column;
    }
}

@media (max-width: 680px) {
    .topbar,
    footer {
        align-items: flex-start;
        flex-direction: column;
    }

    .nav {
        width: 100%;
        overflow-x: auto;
    }

    h1 {
        font-size: 40px;
    }

    .form-grid,
    .likert {
        grid-template-columns: 1fr;
    }

    fieldset {
        padding: 18px;
    }
}
