/* =====================================================================
   EPH Employee Survey — design system
   ===================================================================== */
:root {
    --brand-900: #0a2149;
    --brand-800: #0c2b59;
    --brand-700: #12407e;
    --brand-600: #1a4f96;
    --brand-100: #e6edf8;
    --brand-50:  #f2f6fc;

    --green-600: #1e8a4c;
    --green-50:  #e8f6ee;
    --red-600:   #c0392b;
    --red-50:    #fdeeee;
    --amber-50:  #fff7e6;

    --ink:      #142033;
    --ink-2:    #3b475b;
    --muted:    #6b7689;
    --line:     #e3e8f0;
    --line-2:   #d3dbe7;
    --surface:  #ffffff;
    --bg:       #f4f6fa;

    --r-sm: 8px;
    --r-md: 12px;
    --r-lg: 18px;
    --shadow-sm: 0 1px 2px rgba(10, 33, 73, .05);
    --shadow-md: 0 1px 3px rgba(10, 33, 73, .06), 0 10px 30px -12px rgba(10, 33, 73, .14);
    --shadow-lg: 0 24px 60px -20px rgba(10, 33, 73, .35);

    --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    --font-head: "Poppins", var(--font-body);
    --header-h: 64px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
    margin: 0;
    font-family: var(--font-body);
    font-size: 15px;
    line-height: 1.6;
    color: var(--ink);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}
img { max-width: 100%; }
a { color: var(--brand-700); }
h1, h2, h3 { font-family: var(--font-head); line-height: 1.25; color: var(--brand-900); margin: 0; }
:focus-visible { outline: 3px solid rgba(26, 79, 150, .35); outline-offset: 2px; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Top bar ---------- */
.topbar {
    position: sticky; top: 0; z-index: 30;
    height: var(--header-h);
    background: rgba(255, 255, 255, .92);
    backdrop-filter: saturate(160%) blur(10px);
    border-bottom: 1px solid var(--line);
}
.topbar .inner {
    max-width: 1200px; height: 100%; margin: 0 auto; padding: 0 20px;
    display: flex; align-items: center; gap: 14px;
}
.topbar .logo { height: 34px; width: auto; display: block; }
.topbar .divider { width: 1px; height: 28px; background: var(--line-2); }
.topbar .title { font-size: 13px; color: var(--muted); line-height: 1.3; }
.topbar .title strong { display: block; color: var(--ink); font-weight: 600; font-size: 14px; }
.topbar .spacer { flex: 1; }

.chip {
    display: inline-flex; align-items: center; gap: 6px;
    font-size: 12px; font-weight: 600; letter-spacing: .02em;
    padding: 6px 12px; border-radius: 999px;
    background: var(--brand-50); color: var(--brand-700); border: 1px solid var(--brand-100);
    white-space: nowrap;
}
.chip svg { width: 14px; height: 14px; }
.chip-green { background: var(--green-50); color: var(--green-600); border-color: #c9ead7; }

.page { flex: 1; width: 100%; max-width: 1200px; margin: 0 auto; padding: 32px 20px 48px; }
.site-footer {
    text-align: center; color: var(--muted); font-size: 12px;
    padding: 20px 16px 28px; border-top: 1px solid var(--line); background: var(--surface);
}

/* ---------- Generic card ---------- */
.card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    box-shadow: var(--shadow-md);
    padding: 28px;
}
.card + .card { margin-top: 20px; }
.card-head { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 18px; }
.card-head h2 { font-size: 17px; }
.card-head .sub { font-size: 13px; color: var(--muted); margin-top: 2px; }
.card-head .count {
    margin-left: auto; flex: none;
    font-size: 12px; font-weight: 600; color: var(--muted);
    background: var(--bg); border: 1px solid var(--line); border-radius: 999px; padding: 3px 10px;
}
.card-head .count.done { color: var(--green-600); background: var(--green-50); border-color: #c9ead7; }
.badge-num {
    flex: none; width: 34px; height: 34px; border-radius: 10px;
    display: grid; place-items: center;
    font-family: var(--font-head); font-weight: 600; font-size: 14px;
    background: var(--brand-100); color: var(--brand-700);
}

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    font: 600 14px/1 var(--font-body);
    padding: 13px 20px; min-height: 46px;
    border-radius: var(--r-md); border: 1px solid transparent;
    cursor: pointer; text-decoration: none; white-space: nowrap;
    transition: background .15s, border-color .15s, box-shadow .15s, transform .05s;
}
.btn:active { transform: translateY(1px); }
.btn svg { width: 18px; height: 18px; flex: none; }
.btn-primary { background: var(--brand-700); color: #fff; box-shadow: 0 6px 16px -8px rgba(18, 64, 126, .7); }
.btn-primary:hover { background: var(--brand-800); }
.btn-success { background: var(--green-600); color: #fff; box-shadow: 0 6px 16px -8px rgba(30, 138, 76, .7); }
.btn-success:hover { background: #18723f; }
.btn-ghost { background: var(--surface); color: var(--ink-2); border-color: var(--line-2); }
.btn-ghost:hover { border-color: var(--brand-600); color: var(--brand-700); }
.btn-block { width: 100%; }

/* ---------- Alerts ---------- */
.alert {
    display: flex; gap: 10px; align-items: flex-start;
    border-radius: var(--r-md); padding: 12px 14px; margin-bottom: 20px;
    font-size: 14px; border: 1px solid;
}
.alert svg { width: 18px; height: 18px; flex: none; margin-top: 2px; }
.alert-success { background: var(--green-50); color: #155c34; border-color: #c9ead7; }
.alert-error   { background: var(--red-50); color: #8a1d21; border-color: #f3caca; }
.alert-info    { background: var(--brand-50); color: var(--brand-800); border-color: var(--brand-100); }
.error-text { color: var(--red-600); font-size: 13px; margin-top: 8px; }

/* =====================================================================
   Start page
   ===================================================================== */
.welcome {
    display: grid; grid-template-columns: 1.05fr 1fr;
    background: var(--surface); border: 1px solid var(--line);
    border-radius: 24px; overflow: hidden; box-shadow: var(--shadow-lg);
    max-width: 1040px; margin: 0 auto;
}
.welcome-aside {
    position: relative; overflow: hidden;
    color: #fff; padding: 44px 40px;
    background:
        radial-gradient(120% 80% at 100% 0%, rgba(255, 255, 255, .14), transparent 55%),
        radial-gradient(90% 60% at 0% 100%, rgba(30, 138, 76, .25), transparent 60%),
        linear-gradient(150deg, var(--brand-700), var(--brand-900));
}
.welcome-aside::after {
    content: ""; position: absolute; right: -80px; bottom: -80px;
    width: 280px; height: 280px; border-radius: 50%;
    border: 40px solid rgba(255, 255, 255, .05);
}
.welcome-aside .emblem {
    width: 64px; height: 64px; border-radius: 50%; background: #fff; padding: 3px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, .25);
}
.welcome-aside .eyebrow {
    margin-top: 24px; font-size: 12px; font-weight: 600; letter-spacing: .16em;
    text-transform: uppercase; color: rgba(255, 255, 255, .7);
}
.welcome-aside h1 { color: #fff; font-size: 30px; margin-top: 8px; }
.welcome-aside .tagline { color: rgba(255, 255, 255, .8); margin: 10px 0 28px; }
.facts { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; position: relative; z-index: 1; }
.facts li { display: flex; gap: 12px; font-size: 14px; color: rgba(255, 255, 255, .9); }
.facts .ic {
    flex: none; width: 34px; height: 34px; border-radius: 10px;
    display: grid; place-items: center; background: rgba(255, 255, 255, .12);
}
.facts .ic svg { width: 18px; height: 18px; }
.facts strong { color: #fff; display: block; font-weight: 600; }

.welcome-main { padding: 44px 40px; display: flex; flex-direction: column; justify-content: center; }
.welcome-main .logo { width: 220px; height: auto; margin-bottom: 28px; }
.welcome-main h2 { font-size: 22px; }
.welcome-main .lead { color: var(--muted); margin: 6px 0 24px; font-size: 14px; }

.field-label { display: block; font-weight: 600; font-size: 13px; color: var(--ink-2); margin-bottom: 8px; }
.input-wrap { position: relative; }
.input-wrap svg {
    position: absolute; left: 14px; top: 50%; transform: translateY(-50%);
    width: 20px; height: 20px; color: var(--muted); pointer-events: none;
}
.input {
    width: 100%; font: 500 16px/1.3 var(--font-body); color: var(--ink);
    padding: 14px 14px 14px 46px; min-height: 52px;
    border: 1.5px solid var(--line-2); border-radius: var(--r-md); background: #fff;
    letter-spacing: .04em; text-transform: uppercase;
    transition: border-color .15s, box-shadow .15s;
}
.input::placeholder { text-transform: none; letter-spacing: 0; color: #a3acbb; font-weight: 400; }
.input:focus { outline: none; border-color: var(--brand-600); box-shadow: 0 0 0 4px rgba(26, 79, 150, .12); }
.input.is-invalid { border-color: var(--red-600); }
.form-foot { margin-top: 16px; font-size: 12px; color: var(--muted); display: flex; gap: 8px; align-items: flex-start; }
.form-foot svg { width: 16px; height: 16px; flex: none; margin-top: 1px; color: var(--green-600); }
.deadline {
    margin-top: 24px; padding: 12px 14px; border-radius: var(--r-md);
    background: var(--amber-50); border: 1px solid #f5e1b5; color: #7a5a12; font-size: 13px;
}

/* =====================================================================
   Survey wizard
   ===================================================================== */
.survey-shell { display: grid; grid-template-columns: 290px minmax(0, 1fr); gap: 28px; align-items: start; }

/* Sidebar stepper (desktop) */
.stepper {
    position: sticky; top: calc(var(--header-h) + 24px);
    background: var(--surface); border: 1px solid var(--line);
    border-radius: var(--r-lg); box-shadow: var(--shadow-md); padding: 20px;
}
.overall { margin-bottom: 18px; }
.overall-top { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 8px; }
.overall-top span { font-size: 13px; color: var(--muted); }
.overall-top strong { font-family: var(--font-head); font-size: 22px; color: var(--brand-800); }
.bar { height: 8px; background: var(--brand-50); border-radius: 999px; overflow: hidden; }
.bar > span {
    display: block; height: 100%; border-radius: inherit;
    background: linear-gradient(90deg, var(--brand-600), var(--green-600));
    transition: width .4s ease;
}
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.steps button {
    width: 100%; display: flex; align-items: center; gap: 12px; text-align: left;
    padding: 10px; border-radius: var(--r-md); border: 1px solid transparent;
    background: none; font: inherit; color: inherit; cursor: pointer;
    transition: background .12s, border-color .12s;
}
.steps button:hover { background: var(--bg); }
.steps .is-current button { background: var(--brand-50); border-color: var(--brand-100); }
.step-dot {
    flex: none; width: 30px; height: 30px; border-radius: 50%;
    display: grid; place-items: center;
    font-size: 12px; font-weight: 700; color: var(--muted);
    background: var(--surface); border: 1.5px solid var(--line-2);
}
.step-dot svg { width: 15px; height: 15px; }
.is-current .step-dot { background: var(--brand-700); border-color: var(--brand-700); color: #fff; }
.is-done .step-dot { background: var(--green-600); border-color: var(--green-600); color: #fff; }
.step-text { min-width: 0; flex: 1; }
.step-text small { display: block; font-size: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.step-text span { display: block; font-size: 13px; font-weight: 500; color: var(--ink); line-height: 1.35; }
.step-count { font-size: 11px; color: var(--muted); font-variant-numeric: tabular-nums; }
.stepper .save-note {
    margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--line);
    font-size: 12px; color: var(--muted); display: flex; gap: 8px;
}
.stepper .save-note svg { width: 16px; height: 16px; flex: none; color: var(--green-600); margin-top: 1px; }

/* Mobile step strip */
.mobile-steps { display: none; }

/* Content */
.step-head { margin-bottom: 22px; }
.step-head .eyebrow {
    font-size: 12px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--brand-600);
}
.step-head h1 { font-size: 26px; margin-top: 4px; }
.step-head p { color: var(--muted); margin: 8px 0 0; max-width: 62ch; }

.legend {
    display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px;
    margin-bottom: 20px; padding: 12px; border-radius: var(--r-md);
    background: var(--surface); border: 1px dashed var(--line-2);
    font-size: 11px; color: var(--muted); text-align: center; line-height: 1.3;
}
.legend b { display: block; font-family: var(--font-head); font-size: 15px; color: var(--brand-800); }

/* Rating item */
.item { padding: 18px 0; border-top: 1px solid var(--line); }
.item:first-of-type { border-top: 0; padding-top: 0; }
.item:last-child { padding-bottom: 0; }
.item-q { display: flex; gap: 10px; font-size: 15px; color: var(--ink); margin: 0 0 12px; font-weight: 500; }
.item-q .num {
    flex: none; min-width: 38px; font-weight: 600; color: var(--brand-600);
    font-variant-numeric: tabular-nums;
}
.item-q .tick {
    flex: none; margin-left: auto; width: 20px; height: 20px; color: var(--green-600);
    opacity: 0; transform: scale(.6); transition: opacity .15s, transform .15s;
}
.item.is-answered .item-q .tick { opacity: 1; transform: none; }

fieldset.item { border: 0; margin: 0; min-width: 0; }
fieldset.item legend { padding: 0; width: 100%; }

.scale { display: grid; grid-template-columns: repeat(5, 1fr) 1.1fr; gap: 8px; }
.opt { position: relative; }
.opt input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; }
.opt span {
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    min-height: 54px; padding: 6px 4px; text-align: center;
    border: 1.5px solid var(--line-2); border-radius: var(--r-md); background: var(--surface);
    font-family: var(--font-head); font-weight: 600; font-size: 16px; color: var(--ink-2);
    transition: background .12s, border-color .12s, color .12s, box-shadow .12s;
    pointer-events: none;
}
.opt span small {
    font-family: var(--font-body); font-weight: 500; font-size: 10.5px; line-height: 1.2;
    color: var(--muted); margin-top: 2px;
}
.opt:hover span { border-color: var(--brand-600); }
.opt input:focus-visible + span { box-shadow: 0 0 0 4px rgba(26, 79, 150, .2); }
.opt input:checked + span {
    background: var(--brand-700); border-color: var(--brand-700); color: #fff;
    box-shadow: 0 6px 14px -8px rgba(18, 64, 126, .8);
}
.opt input:checked + span small { color: rgba(255, 255, 255, .85); }
.opt.na span { font-family: var(--font-body); font-size: 13px; background: var(--bg); }
.opt.na input:checked + span { background: #5c6577; border-color: #5c6577; box-shadow: none; }
.scale-ends { display: none; }

/* Choice pills (Part A / D) */
.question + .question { margin-top: 26px; padding-top: 22px; border-top: 1px solid var(--line); }
.q-label { display: block; font-weight: 600; font-size: 15px; color: var(--ink); margin-bottom: 12px; }
.q-hint { font-weight: 400; color: var(--muted); font-size: 13px; }
.pills { display: flex; flex-wrap: wrap; gap: 8px; }
.pill { position: relative; }
.pill input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; }
.pill span {
    display: inline-flex; align-items: center; gap: 8px;
    min-height: 44px; padding: 10px 16px;
    border: 1.5px solid var(--line-2); border-radius: 999px; background: var(--surface);
    font-size: 14px; font-weight: 500; color: var(--ink-2);
    transition: background .12s, border-color .12s, color .12s;
    pointer-events: none;
}
.pill span::before {
    content: ""; width: 16px; height: 16px; border-radius: 50%; flex: none;
    border: 1.5px solid var(--line-2); background: #fff; transition: inherit;
}
.pill input[type=checkbox] + span::before { border-radius: 5px; }
.pill:hover span { border-color: var(--brand-600); }
.pill input:focus-visible + span { box-shadow: 0 0 0 4px rgba(26, 79, 150, .2); }
.pill input:checked + span { background: var(--brand-50); border-color: var(--brand-700); color: var(--brand-800); }
.pill input:checked + span::before {
    border-color: var(--brand-700);
    background: var(--brand-700) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='white' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 8.5l2.5 2.5L12 5.5'/%3E%3C/svg%3E") center/12px no-repeat;
}
.pill input:disabled + span { opacity: .45; cursor: not-allowed; }
.clear-link {
    margin-top: 10px; background: none; border: 0; padding: 4px 0;
    font: 500 12px var(--font-body); color: var(--muted); text-decoration: underline; cursor: pointer;
}
.clear-link:hover { color: var(--brand-700); }

/* Textareas (Part E) */
.textarea {
    width: 100%; min-height: 110px; resize: vertical;
    font: 400 15px/1.55 var(--font-body); color: var(--ink);
    padding: 12px 14px; border: 1.5px solid var(--line-2); border-radius: var(--r-md); background: #fff;
    transition: border-color .15s, box-shadow .15s;
}
.textarea:focus { outline: none; border-color: var(--brand-600); box-shadow: 0 0 0 4px rgba(26, 79, 150, .12); }
.char-count { text-align: right; font-size: 11px; color: var(--muted); margin-top: 4px; font-variant-numeric: tabular-nums; }

/* Required / missing answers */
.req { color: var(--red-600); font-weight: 700; }
.item.is-missing, .question.is-missing {
    position: relative;
    background: var(--red-50);
    border-radius: var(--r-md);
    margin-left: -12px; margin-right: -12px;
    padding-left: 12px; padding-right: 12px;
    box-shadow: inset 3px 0 0 var(--red-600);
}
.item.is-missing { padding-top: 14px; padding-bottom: 14px; }
.question.is-missing { padding-top: 14px; padding-bottom: 14px; }
.question + .question.is-missing { margin-top: 26px; }
.is-missing .opt span, .is-missing .pill span, .is-missing .textarea { border-color: #e9a9a4; }
.missing-banner { margin: 20px 0 0; }

.steps button:disabled, .strip button:disabled { opacity: .45; cursor: not-allowed; }
.steps button:disabled:hover { background: none; }

/* Action bar */
.actions {
    position: sticky; bottom: 16px; z-index: 20;
    display: flex; gap: 10px; align-items: center;
    margin-top: 24px; padding: 12px;
    background: rgba(255, 255, 255, .94); backdrop-filter: blur(10px);
    border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-lg);
}
.actions .spacer { flex: 1; }

/* Result pages */
.result { max-width: 560px; margin: 24px auto; text-align: center; padding: 48px 32px; }
.result .icon {
    width: 72px; height: 72px; margin: 0 auto 20px; border-radius: 50%;
    display: grid; place-items: center;
}
.result .icon svg { width: 34px; height: 34px; }
.result .icon.green { background: var(--green-50); color: var(--green-600); }
.result .icon.blue { background: var(--brand-50); color: var(--brand-700); }
.result h1 { font-size: 24px; }
.result p { color: var(--muted); margin: 10px 0 0; }
.result .btn { margin-top: 26px; }

/* =====================================================================
   Admin — employee progress grid
   ===================================================================== */
.chip-btn { cursor: pointer; font-family: var(--font-body); }
.chip-btn:hover { background: var(--brand-100); }

.admin-head { display: flex; align-items: flex-end; gap: 20px; margin-bottom: 22px; }
.admin-head .eyebrow { font-size: 12px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--brand-600); }
.admin-head h1 { font-size: 26px; margin-top: 4px; }
.admin-head p { color: var(--muted); margin: 6px 0 0; }
.participation {
    margin-left: auto; flex: none; text-align: right;
    padding: 12px 18px; border-radius: var(--r-lg);
    background: linear-gradient(150deg, var(--brand-700), var(--brand-900)); color: #fff;
    box-shadow: var(--shadow-md);
}
.participation strong { display: block; font-family: var(--font-head); font-size: 28px; line-height: 1.1; }
.participation span { font-size: 12px; opacity: .8; letter-spacing: .04em; }

.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 22px; }
.stat {
    background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg);
    padding: 16px 18px; box-shadow: var(--shadow-sm); border-top: 3px solid var(--brand-700);
}
.stat span { display: block; font-size: 12px; color: var(--muted); font-weight: 500; }
.stat strong { font-family: var(--font-head); font-size: 26px; color: var(--brand-900); }
.stat-green { border-top-color: var(--green-600); }
.stat-blue { border-top-color: var(--brand-600); }
.stat-grey { border-top-color: #9aa3b2; }

.toolbar { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; margin-bottom: 20px; }
.toolbar .search { flex: 1 1 280px; }
.toolbar .search .input { text-transform: none; letter-spacing: 0; min-height: 46px; font-size: 15px; }
.filters { display: flex; gap: 6px; flex-wrap: wrap; }
.filter {
    display: inline-flex; align-items: center; gap: 8px;
    height: 40px; padding: 0 14px; border-radius: 999px;
    font: 600 13px var(--font-body); color: var(--ink-2);
    background: var(--surface); border: 1px solid var(--line-2); cursor: pointer;
    white-space: nowrap;
}
.filter b { font-weight: 600; font-size: 11px; padding: 2px 7px; border-radius: 999px; background: var(--bg); color: var(--muted); }
.filter:hover { border-color: var(--brand-600); }
.filter.is-active { background: var(--brand-700); border-color: var(--brand-700); color: #fff; }
.filter.is-active b { background: rgba(255, 255, 255, .18); color: #fff; }

.emp-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 16px; }
.emp-card {
    display: flex; flex-direction: column; align-items: center; text-align: center;
    background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg);
    padding: 22px 18px 18px; box-shadow: var(--shadow-sm);
    transition: box-shadow .15s, transform .15s;
}
.emp-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }

.emp-avatar {
    width: 76px; height: 76px; border-radius: 50%;
    display: grid; place-items: center;
    background: var(--brand-50); color: var(--brand-600);
    border: 3px solid #fff; box-shadow: 0 0 0 2px var(--brand-100);
    margin-bottom: 14px;
}
.emp-avatar svg { width: 38px; height: 38px; }
.status-submitted .emp-avatar { background: var(--green-50); color: var(--green-600); box-shadow: 0 0 0 2px #c9ead7; }
.status-not_started .emp-avatar { background: var(--bg); color: #9aa3b2; box-shadow: 0 0 0 2px var(--line); }

.emp-name {
    font-family: var(--font-head); font-weight: 600; font-size: 15px; color: var(--brand-900); line-height: 1.3;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
    min-height: 2.6em; word-break: break-word;
}
.emp-id { font-size: 11.5px; color: var(--muted); letter-spacing: .03em; margin-top: 2px; font-variant-numeric: tabular-nums; }

.emp-progress { width: 100%; margin-top: auto; padding-top: 16px; border-top: 1px solid var(--line); margin-top: 16px; text-align: left; }
.emp-progress-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.emp-progress-top strong { font-family: var(--font-head); font-size: 15px; color: var(--brand-800); font-variant-numeric: tabular-nums; }
.status-pill {
    font-size: 11px; font-weight: 600; padding: 3px 9px; border-radius: 999px;
    background: var(--brand-50); color: var(--brand-700);
}
.status-submitted .status-pill { background: var(--green-50); color: var(--green-600); }
.status-submitted .emp-progress-top strong { color: var(--green-600); }
.status-not_started .status-pill { background: var(--bg); color: var(--muted); }
.status-not_started .emp-progress-top strong { color: #9aa3b2; }
.emp-card .bar { background: var(--line); height: 7px; }
.status-submitted .bar > span { background: var(--green-600); }
.status-in_progress .bar > span { background: linear-gradient(90deg, var(--brand-600), var(--brand-700)); }
.emp-detail { margin-top: 8px; font-size: 12px; color: var(--muted); line-height: 1.4; }

.empty { text-align: center; color: var(--muted); padding: 48px 16px; }
.empty svg { width: 40px; height: 40px; color: #a3acbb; }

/* =====================================================================
   Responsive
   ===================================================================== */
@media (max-width: 1080px) {
    .survey-shell { grid-template-columns: 250px minmax(0, 1fr); gap: 20px; }
}

@media (max-width: 900px) {
    .welcome { grid-template-columns: 1fr; border-radius: 20px; }
    .welcome-aside, .welcome-main { padding: 32px 28px; }
    .welcome-aside h1 { font-size: 26px; }
    .welcome-main { order: -1; }
    .welcome-main .logo { width: 180px; margin-bottom: 20px; }

    .survey-shell { grid-template-columns: 1fr; }
    .stepper { display: none; }
    .mobile-steps {
        display: block; position: sticky; top: var(--header-h); z-index: 15;
        margin: -32px -20px 20px; padding: 12px 20px 10px;
        background: rgba(244, 246, 250, .96); backdrop-filter: blur(10px);
        border-bottom: 1px solid var(--line);
    }
    .mobile-steps .top { display: flex; justify-content: space-between; font-size: 12px; color: var(--muted); margin-bottom: 8px; }
    .mobile-steps .top strong { color: var(--brand-800); }
    .mobile-steps .bar { background: var(--line); height: 6px; }
    .strip {
        overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch;
        margin: 12px -20px 0; padding: 2px 20px 4px;
        scroll-snap-type: x proximity; scroll-padding: 0 20px;
        /* fade edges to hint that the row scrolls */
        -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 16px, #000 calc(100% - 28px), transparent 100%);
                mask-image: linear-gradient(90deg, transparent 0, #000 16px, #000 calc(100% - 28px), transparent 100%);
    }
    .strip::-webkit-scrollbar { display: none; }
    .strip ol {
        display: flex; gap: 8px; margin: 0; padding: 0; list-style: none;
        width: max-content;
    }
    .strip li { flex: none; scroll-snap-align: center; }
    .strip button {
        display: inline-flex; align-items: center; gap: 8px;
        height: 38px; padding: 0 14px 0 5px;
        font: 600 13px/1 var(--font-body); color: var(--ink-2);
        white-space: nowrap;
        border-radius: 999px; border: 1px solid var(--line-2);
        background: var(--surface); box-shadow: var(--shadow-sm);
        cursor: pointer; transition: background .15s, border-color .15s, color .15s;
    }
    .chip-dot {
        width: 28px; height: 28px; border-radius: 50%; flex: none;
        display: grid; place-items: center;
        font-size: 12px; font-weight: 700;
        background: var(--bg); color: var(--muted); border: 1px solid var(--line-2);
    }
    .chip-dot svg { width: 14px; height: 14px; }
    .strip .is-done button { border-color: #c9ead7; color: #155c34; background: var(--green-50); }
    .strip .is-done .chip-dot { background: var(--green-600); border-color: var(--green-600); color: #fff; }
    .strip .is-current button {
        background: var(--brand-700); border-color: var(--brand-700); color: #fff;
        box-shadow: 0 6px 14px -8px rgba(18, 64, 126, .8);
    }
    .strip .is-current .chip-dot { background: #fff; border-color: #fff; color: var(--brand-700); }
    .strip button:disabled { opacity: 1; color: #a3acbb; background: var(--bg); box-shadow: none; border-style: dashed; }
    .strip button:disabled .chip-dot { color: #b6bec9; background: #fff; }
}

@media (max-width: 640px) {
    body { font-size: 14.5px; }
    :root { --header-h: 58px; }
    .page { padding: 20px 16px 32px; }
    .topbar .inner { padding: 0 16px; gap: 10px; }
    .topbar .logo { height: 28px; }
    .topbar .divider, .topbar .title { display: none; }
    .mobile-steps { margin: -20px -16px 18px; padding: 10px 16px 8px; }
    .strip { margin: 10px -16px 0; padding: 2px 16px 4px; scroll-padding: 0 16px; }

    .welcome-aside, .welcome-main { padding: 26px 20px; }
    .welcome-aside h1 { font-size: 22px; }
    .welcome-aside .tagline { margin-bottom: 20px; }

    .card { padding: 20px 16px; border-radius: 16px; }
    .card + .card { margin-top: 14px; }
    .step-head h1 { font-size: 21px; }
    .legend { display: none; }

    .scale { grid-template-columns: repeat(5, 1fr); gap: 6px; }
    .opt span { min-height: 48px; font-size: 16px; }
    .opt span small { display: none; }
    .opt.na { grid-column: 1 / -1; }
    .opt.na span { min-height: 40px; }
    .scale-ends {
        display: flex; justify-content: space-between;
        font-size: 11px; color: var(--muted); margin: 6px 2px 8px;
    }

    .pill span { padding: 9px 14px; font-size: 13.5px; }

    .actions {
        position: fixed; left: 0; right: 0; bottom: 0; margin: 0;
        border-radius: 16px 16px 0 0; border-width: 1px 0 0;
        padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
        display: grid; grid-template-columns: auto 1fr; gap: 8px;
    }
    .actions .spacer { display: none; }
    .actions .btn { padding: 12px 14px; }
    .actions .btn-later { grid-column: 1 / -1; order: 3; min-height: 40px; border: 0; background: none; box-shadow: none; padding: 6px; }
    .actions:not(.has-back) { grid-template-columns: 1fr; }
    .page.with-actions { padding-bottom: 150px; }
    .result { padding: 36px 20px; margin: 8px auto; }
}

@media (max-width: 900px) {
    .stats { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
    .admin-head { flex-direction: column; align-items: stretch; gap: 14px; }
    .admin-head h1 { font-size: 21px; }
    .participation { margin-left: 0; display: flex; align-items: baseline; justify-content: space-between; text-align: left; }
    .stats { gap: 10px; }
    .stat { padding: 12px 14px; }
    .stat strong { font-size: 22px; }
    .filters { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin: 0 -16px; padding: 0 16px; width: calc(100% + 32px); }
    .filters::-webkit-scrollbar { display: none; }
    .emp-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
    .emp-card { padding: 16px 12px 14px; }
    .emp-avatar { width: 60px; height: 60px; margin-bottom: 10px; }
    .emp-avatar svg { width: 30px; height: 30px; }
    .emp-name { font-size: 13.5px; }
    .emp-id { font-size: 10.5px; }
    .emp-progress { padding-top: 12px; margin-top: 12px; }
    .status-pill { font-size: 10px; padding: 2px 7px; }
    .emp-detail { font-size: 11px; }
}

@media (max-width: 360px) {
    .emp-grid { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
}
