/* =========================================================
   EMPLOYEE ASSESSMENT UI — Premium Light Enterprise Design
   ========================================================= */

/* Reset base styles from ui-kit are already applied */

/* ---------- Utility Classes ---------- */
.hidden {
    display: none !important;
}

/* ---------- Page Background ---------- */

body {
    background: #FFFCEF;
}

/* ---------- Header / Navbar ---------- */

.topbar {
    min-height: 72px;
    border-bottom: 1px solid #E8E4C4;
    background: rgba(255,252,239,.94);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 0 32px;
    position: sticky;
    top: 0;
    z-index: 20;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

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

.brand-mark {
    width: 54px;
    height: 54px;
    flex: 0 0 54px;
    border-radius: var(--radius-lg);
    background: var(--lavender-soft);
    color: var(--cta);
    font-size: var(--text-title);
    font-weight: 700;
    display: grid;
    place-items: center;
    box-shadow: 0 4px 12px rgba(43,27,61,.15);
}

.brand-copy {
    display: flex;
    flex-direction: column;
}

.brand-copy strong {
    font-size: var(--text-lg);
    color: #2B1B3D;
    font-weight: 700;
}

.brand-copy small {
    font-size: var(--text-sm);
    color: #5E5470;
    margin-top: 2px;
}

.topbar-status {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #5E5470;
    font-size: var(--text-base);
}

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #6D5FD5;
    box-shadow: 0 0 0 2px rgba(109,95,213,.40);
}

/* ---------- Page Container ---------- */

.page-shell {
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 32px;
}

/* ---------- Intro Section ---------- */

.intro-section {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 40px;
    margin-bottom: 36px;
}

.intro-copy {
    max-width: 680px;
}

.eyebrow {
    margin: 0 0 1px;
    color: #6D5FD5;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.intro-copy h1 {
    margin: 0;
    color: #2B1B3D;
    font-size: clamp(36px, 6vw, 58px);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.02em;
}

.intro-copy h1 span {
    display: block;
    color: #6D5FD5;
}

.intro-text {
    margin: 10px 0 0;
    color: #5E5470;
    font-size: 17px;
    font-weight: 400;
    line-height: 1.6;
    max-width: 560px;
}

/* ---------- Progress Card ---------- */

.progress-card {
    width: 280px;
    flex: 0 0 280px;
    padding: 20px;
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    background: var(--surface-card);
    box-shadow: var(--shadow-md);
    transition: all .25s var(--ease-standard);
}

.progress-card.submitted {
    border-color: #E8CF7A;
    background: #FFF3CF;
}

.progress-card.submitted .progress-topline {
    color: #6B5300;
}

.progress-card.submitted .progress-topline strong {
    color: #6B5300;
}

.progress-card.submitted p {
    color: #6B5300;
}

@media (hover: hover) {
    .progress-card:hover {
        transform: translateY(-2px);
        border-color: #D5D28F;
        box-shadow: 0 10px 28px rgba(109,95,213,.12);
    }
}

.progress-topline {
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: var(--text-primary);
    font-size: var(--text-base);
    margin-bottom: 12px;
}

.progress-topline strong {
    font-weight: 600;
}

.progress-track {
    height: 8px;
    margin: 12px 0 10px;
    overflow: hidden;
    border-radius: 999px;
    background: #EFEBD0;
}

.progress-track span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: #6D5FD5;
    transition: width .35s cubic-bezier(.22,1,.36,1);
}

.progress-card.submitted .progress-topline strong,
.progress-card.submitted ~ * p {
    color: #6B5300;
}

.progress-card p {
    margin: 0;
    color: var(--text-secondary);
    font-size: var(--text-sm);
    text-align: center;
}

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

.assessment-card {
    padding: 28px;
    border: 1px solid var(--border);
    border-radius: var(--radius-2xl);
    background: var(--surface-card);
    box-shadow: var(--shadow-sm);
    transition: all .25s var(--ease-standard);
    margin-bottom: 24px;
}

@media (hover: hover) {
    .assessment-card:hover {
        transform: translateY(-2px);
        border-color: #D5D28F;
        box-shadow: 0 10px 28px rgba(109,95,213,.12);
    }
}

.identity-card {
    margin-bottom: 20px;
}

.skill-assessment-card {
    position: relative;
    overflow: visible;
    margin-bottom: 20px;
}

.section-heading {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 24px;
}

.section-number {
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
    border-radius: var(--radius-md);
    background: var(--lavender-soft);
    color: var(--cta);
    font-size: var(--text-sm);
    font-weight: 800;
}

.section-heading .eyebrow {
    margin-bottom: 4px;
}

.section-heading h2 {
    margin: 0;
    color: var(--text-primary);
    font-size: clamp(24px, 3vw, 32px);
    letter-spacing: -0.03em;
    font-weight: 700;
}

/* ---------- Form Fields ---------- */

.employee-picker label,
.manager-block label,
.field-group label,
.other-skill-box label {
    display: block;
    margin-bottom: 6px;
    color: var(--text-primary);
    font-size: var(--text-base);
    font-weight: 600;
}

.search-field,
.skill-combobox {
    position: relative;
}

.skill-combobox + .helper-text {
    display: block;
    margin-top: 6px;
    margin-left: 0;
    color: #8C839C;
    font-size: 12px;
    font-weight: 400;
}

.search-field input,
.skill-combobox input,
.login-form input,
select,
.other-skill-box input {
    width: 100%;
    height: 48px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--surface-input);
    color: var(--text-primary);
    font-size: var(--text-base);
    transition:
        border-color .2s var(--ease-standard),
        box-shadow .2s var(--ease-standard);
}

.search-field input,
.skill-combobox input,
.other-skill-box input {
    padding: 0 44px 0 16px;
}

select {
    padding: 0 40px 0 14px;
    appearance: none;
    background-image:
        linear-gradient(
            45deg,
            transparent 50%,
            var(--select-arrow) 50%
        ),
        linear-gradient(
            135deg,
            var(--select-arrow) 50%,
            transparent 50%
        );
    background-position:
        calc(100% - 18px) 16px,
        calc(100% - 12px) 16px;
    background-size: 6px 6px, 6px 6px;
    background-repeat: no-repeat;
}

.select-arrow {
    color: var(--text-tertiary);
}

.search-field input:focus,
.skill-combobox input:focus,
select:focus,
select:focus-visible,
.other-skill-box input:focus {
    border-color: #6D5FD5;
    box-shadow: 0 0 0 4px rgba(109,95,213,.18);
}

.search-icon {
    position: absolute;
    top: 50%;
    right: 16px;
    transform: translateY(-50%);
    color: var(--text-tertiary);
    pointer-events: none;
    width: 18px;
    height: 18px;
}

.search-icon .icon {
    width: 18px;
    height: 18px;
    stroke-width: 1.9;
}

/* ---------- Results Dropdown ---------- */

.picker-results,
.skill-dropdown {
    position: absolute;
    z-index: 50;
    width: 100%;
    margin-top: 8px;
    padding: 8px;
    border: 1px solid #E8E4C4;
    border-radius: 12px;
    background: #FFFFFF;
    box-shadow: 0 12px 32px rgba(43,27,61,.08);
    max-height: 280px;
    overflow-y: auto;
    animation: dropdown-in 180ms ease both;
}

.picker-results {
    position: relative;
}

.employee-result,
.skill-option {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 7px 12px;
    background: transparent;
    color: #2B1B3D;
    text-align: left;
    transition: all .2s ease;
    margin-bottom: 6px;
}

.skill-option:last-child {
    margin-bottom: 0;
}

.employee-result:last-child {
    border-bottom: none;
}

@media (hover: hover) {
    .employee-result:hover,
    .skill-option:hover {
        background: #FDFBD4;
        border-left: 3px solid #6D5FD5;
        padding-left: 15px;
    }
}

.employee-result span,
.employee-result small,
.skill-option small {
    display: block;
}

.employee-result strong {
    display: block;
    margin-bottom: 2px;
    font-weight: 600;
}

.employee-result small,
.skill-option small {
    color: #8C839C;
    font-size: var(--text-2xs);
}

.employee-profile {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 12px;
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: var(--surface-card);
    animation: profile-in 280ms ease both;
}

.profile-avatar {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    flex: 0 0 44px;
    border-radius: var(--radius-md);
    background: var(--lavender-soft);
    color: var(--cta);
    font-size: var(--text-base);
    font-weight: 700;
}

.profile-main {
    min-width: 0;
    flex: 1;
}

.profile-experience {
    display: flex;
    align-items: flex-start;
    margin-left: auto;
    padding-left: 24px;
    color: #3D2A6E;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.35;
    white-space: nowrap;
}

.profile-experience-career {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
}

.profile-experience-title {
    margin: 0;
    color: inherit;
    font-size: inherit;
    font-weight: inherit;
    line-height: inherit;
}

.profile-experience strong {
    color: inherit;
    font-size: inherit;
    font-weight: 700;
    letter-spacing: 0;
    line-height: inherit;
}

.profile-experience-dot {
    margin: 0 8px;
}

.profile-experience small {
    display: block;
    margin: 0;
    color: #6A5888;
    font-size: 12px;
    font-weight: 500;
    line-height: 1.3;
    text-align: left;
    white-space: nowrap;
}

.profile-main strong,
.profile-main span,
.profile-main small {
    display: block;
}

.profile-main strong {
    font-size: var(--text-body);
    font-weight: 600;
}

.profile-main span {
    margin-top: 2px;
    color: var(--text-secondary);
    font-size: var(--text-sm);
}

.profile-main small {
    margin-top: 1px;
    color: var(--text-tertiary);
    font-size: var(--text-xs);
}

.text-button {
    border: 0;
    background: transparent;
    color: var(--cta);
    font-size: var(--text-sm);
    font-weight: 600;
    padding: 0;
    transition: color .2s var(--ease-standard);
}

@media (hover: hover) {
    .text-button:hover {
        color: var(--cta-hover);
        text-decoration: underline;
    }
}

/* ---------- Employee Details ---------- */

.employee-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1px;
    margin-top: 16px;
    overflow: hidden;
    border: 1px solid #E8E4C4;
    border-radius: var(--radius-lg);
    background: #E8E4C4;
}

.detail-field {
    padding: 16px;
    background: #FFFEF9;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.detail-field + .detail-field {
    border-left: 0;
}

.detail-field span,
.detail-field strong {
    display: block;
}

.detail-field span {
    margin-bottom: 0;
    color: #8C839C;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.detail-field strong {
    overflow: hidden;
    color: #2B1B3D;
    font-size: 16px;
    font-weight: 600;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.detail-field strong.placeholder {
    color: #A9A3B5;
}

/* ---------- Skill Top Grid ---------- */

.manager-block {
    margin-top: 16px;
}

.skill-top-grid {
    display: grid;
    grid-template-columns:
        minmax(200px, 0.8fr)
        minmax(260px, 1.2fr);
    gap: 16px;
}

.skill-dropdown-field {
    position: relative;
}

.skill-combobox {
    display: flex;
}

.skill-combobox input {
    padding-right: 48px;
}

.dropdown-arrow {
    position: absolute;
    top: 50%;
    right: 4px;
    width: 40px;
    height: 40px;
    transform: translateY(-50%);
    border: 0;
    border-radius: var(--radius-md);
    background: transparent;
    color: #8C839C;
    display: grid;
    place-items: center;
}

.dropdown-arrow svg {
    width: 16px;
    height: 16px;
    transition: transform .2s var(--ease-standard);
}

@media (hover: hover) {
    .dropdown-arrow:hover:not(:disabled) {
        background: #FDFBD4;
    }
}

.dropdown-arrow.open svg {
    transform: rotate(180deg);
}

.skill-dropdown {
    max-height: 300px;
    overflow-y: auto;
}

.skill-option {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 10px 12px;
    border-radius: var(--radius-sm);
    background: transparent;
    color: var(--text-primary);
    text-align: left;
    transition: all .2s var(--ease-standard);
}

@media (hover: hover) {
    .skill-option:hover {
        background: var(--lavender-soft);
        transform: translateX(2px);
    }
}

.skill-option small {
    color: var(--text-tertiary);
    font-size: var(--text-2xs);
}

.dropdown-empty {
    padding: 18px 14px;
    color: #8C839C;
    font-size: var(--text-sm);
    text-align: center;
}

/* ---------- Selected Skills ---------- */

.selected-skills-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 20px;
    margin-bottom: 12px;
    color: var(--text-primary);
    font-size: var(--text-base);
}

.selected-skills-header > div {
    display: flex;
    align-items: center;
    gap: 10px;
}

.selected-skills-header strong {
    display: grid;
    place-items: center;
    min-width: 24px;
    height: 24px;
    padding: 0 6px;
    border-radius: var(--radius-pill);
    background: var(--lavender-soft);
    color: var(--cta);
    font-size: var(--text-xs);
    font-weight: 700;
    transition:
        transform .2s var(--ease-standard),
        background .2s var(--ease-standard);
}

@media (hover: hover) {
    .selected-skills-header strong:hover {
        transform: scale(1.05);
        background: var(--lavender);
    }
}

#clearSelectedSkills {
    color: #5E5470;
    font-size: var(--text-sm);
    font-weight: 600;
    padding: 0;
    transition: color .2s var(--ease-standard);
}

@media (hover: hover) {
    #clearSelectedSkills:hover {
        color: #E0606F;
    }
}

.selected-skills-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 12px;
}

.rating-key {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 18px;
    margin: 0 0 22px;
    color: #5E5470;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.4;
}

.rating-key strong {
    margin-right: 4px;
    color: #6D5FD5;
    font-weight: 700;
}

/* 3-section layout containers */
.skill-section {
    margin-bottom: 24px;
}

#mandatorySkillsSection {
    margin-bottom: 32px;
}

.pick-skills-section {
    margin: 8px 0 20px;
    padding-top: 4px;
}

.pick-skills-section .skill-section-header {
    margin-bottom: 14px;
}

.pick-skills-section .skill-top-grid {
    margin-top: 4px;
}

.pick-skills-section .selected-skills-header {
    margin-top: 16px;
}

#secondarySkillsSection {
    margin-top: 4px;
    margin-bottom: 8px;
}

.skill-section-header {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid #E8E4C4;
}

.skill-section-header h3 {
    color: #2B1B3D;
    font-size: var(--text-section);
    font-weight: 700;
    margin: 0;
}

.skill-section-header p {
    color: #5E5470;
    font-size: var(--text-body);
    margin: 0;
}

/* Mandatory section gets slightly more prominence */
#mandatorySkillsSection .skill-section-header {
    border-color: #6D5FD5;
}

#mandatorySkillsSection .skill-section-header h3 {
    color: #6D5FD5;
}

.selected-skills-empty {
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--surface-input);
    color: var(--text-tertiary);
    font-size: var(--text-sm);
    text-align: center;
}

.skill-card-group {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.zero-experience-reason {
    margin: -1px 8px 0;
    padding: 8px 12px 10px;
    border: 1px solid #E8D9A8;
    border-top: 0;
    border-radius: 0 0 12px 12px;
    background: #FFF8E7;
}

.zero-experience-reason-label {
    display: block;
    color: #4E3D66;
    font-size: 13px;
    font-weight: 700;
}

.zero-experience-reason-helper {
    margin: 2px 0 5px;
    color: #6B5C75;
    font-size: 12px;
    line-height: 1.4;
}

.zero-experience-reason-input {
    display: block;
    width: 100%;
    min-height: 46px;
    padding: 7px 9px;
    border: 1px solid #E8E4C4;
    border-radius: var(--radius-md);
    background: #FFFEF9;
    color: #2B1B3D;
    font: inherit;
    font-size: 13px;
    resize: vertical;
    box-sizing: border-box;
}

.zero-experience-reason-input:focus {
    outline: 2px solid #6D5FD5;
    border-color: transparent;
    box-shadow: 0 0 0 4px rgba(109,95,213,.18);
}

.zero-experience-reason-input.is-invalid {
    border-color: #E0606F;
    box-shadow: 0 0 0 2px rgba(224,96,111,.20);
}

/* ---------- Soft Skills Section ---------- */

.soft-skills-section {
    margin-top: 20px;
    padding: 18px 0 0;
    border: 0;
    border-top: 1px solid #E8E4C4;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}

.soft-skills-eyebrow {
    margin: 0 0 5px;
    color: #5E5470;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.soft-skills-heading {
    margin: 0 0 14px;
    color: #2B1B3D;
    font-size: var(--text-section);
    font-weight: 700;
    line-height: 1.3;
    letter-spacing: 0;
}

.soft-skills-section .selected-skills-list {
    gap: 8px;
}

/* ---------- Skill Cards ---------- */

.multi-skill-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto 28px;
    align-items: center;
    gap: 14px;
    padding: 12px 16px;
    min-height: 88px;
    background: #FFFEF9;
    border: 1px solid #E8E4C4;
    border-radius: 14px;

    box-shadow: 0 2px 8px rgba(43,27,61,.03);

    transition:
        transform var(--dur-fast) ease,
        box-shadow var(--dur-fast) ease,
        border-color var(--dur-fast) ease;
}

.multi-skill-row:hover {
    transform: translateY(-1px);

    box-shadow: 0 4px 12px rgba(43,27,61,.06);
    border-color: #6D5FD5;
}

.multi-skill-info {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.multi-skill-name {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #2B1B3D;
    font-size: 18px;
    font-weight: 700;
}

.multi-skill-category {
    display: block;
    margin-top: 0;
    color: #5E5470;
    font-size: 13px;
    font-weight: 400;
}

.skill-rating-area {
    display: grid;
    grid-template-columns: 184px 6.75rem;
    align-items: center;
    column-gap: 8px;
}

/* ---------- Stars ---------- */

.star-rating {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 4px;
    width: 100%;
}

.star-button {
    width: 32px;
    height: 32px;
    padding: 0;
    border: 0;
    border-radius: var(--radius-sm);
    background: transparent;
    color: #E6E2C2;
    font-size: var(--text-section);
    line-height: 1;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition:
        transform 180ms ease,
        filter 180ms ease,
        color 180ms ease;
}

.star-button .icon {
    width: 27px;
    height: 27px;
    fill: currentColor;
    stroke: none;
}

.star-button:focus {
    outline: none;
}

.star-button:focus-visible {
    outline: 2px solid #6D5FD5;
    outline-offset: 2px;
}

@media (hover: hover) {
    .star-button:hover {
        filter: drop-shadow(0 0 9px rgba(217,154,32,.55));
        color: #D99A20;
    }
}

.star-button.active {
    color: #A87305;
    filter: drop-shadow(0 0 5px rgba(168,115,5,.28));
}

.star-button.preview {
    color: color-mix(in srgb, #D99A20 70%, transparent);
    filter: drop-shadow(0 0 4px rgba(217,154,32,.2));
}

.star-button.active.preview {
    color: #A87305;
    filter: drop-shadow(0 0 5px rgba(168,115,5,.28));
}

.star-rating.star-pop .star-button.active {
    animation: star-pop 180ms ease both;
}

.star-rating.star-pop .star-button.active:nth-child(2) {
    animation-delay: 20ms;
}

.star-rating.star-pop .star-button.active:nth-child(3) {
    animation-delay: 40ms;
}

.star-rating.star-pop .star-button.active:nth-child(4) {
    animation-delay: 60ms;
}

.star-rating.star-pop .star-button.active:nth-child(5) {
    animation-delay: 80ms;
}

/* ---------- Skill Feedback ---------- */

.skill-feedback {
    width: 6.75rem;
    min-height: 1.2em;
    color: #5E5470;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.2;
    white-space: nowrap;
}

.skill-rating-copy {
    width: 100%;
    min-height: 48px;
}

.skill-status {
    display: flex;
    align-items: center;
    min-height: 28px;
    margin-top: 4px;
}

.skill-status .skill-tick,
.skill-status .skill-gap {
    width: 26px;
    height: 26px;
    stroke-width: 2.2;
}

.skill-status .skill-tick {
    color: #1F8A4C;
}

.skill-status .skill-gap {
    color: #C44747;
}

.skill-card-group.is-complete .multi-skill-row {
    border-color: rgba(31, 138, 76, .5);
}

.skill-card-group.is-missing .multi-skill-row {
    border-color: #E7A3A3;
    background: #FFF8F6;
}

.missing-notice {
    position: fixed;
    inset: 0;
    z-index: 40;
    display: grid;
    place-items: center;
    padding: 24px;
    background: rgba(43, 27, 61, .28);
}

.missing-notice-card {
    width: min(420px, 100%);
    padding: 22px 22px 18px;
    border: 1px solid #E8E4C4;
    border-radius: 16px;
    background: #FFFEF9;
    box-shadow: 0 16px 40px rgba(43, 27, 61, .16);
}

.missing-notice-card h2 {
    margin: 4px 0 12px;
    color: #2B1B3D;
    font-size: 22px;
    line-height: 1.3;
}

.missing-notice-card ul {
    margin: 0 0 16px;
    padding-left: 18px;
    color: #5E5470;
    font-size: 14px;
    line-height: 1.5;
}

.missing-notice-card li + li {
    margin-top: 6px;
}

.missing-notice-card .submit-button {
    min-width: 0;
}

.confirm-note {
    margin: 0 0 12px;
    color: #5E5470;
    font-size: 14px;
    line-height: 1.45;
}

.missing-notice-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.skill-feedback.feedback-pop {
    animation: feedback-pop 280ms ease both;
}

/* ---------- Experience Field ---------- */

.skill-exp-field {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.skill-exp-label {
    font-size: 12px;
    color: #8C839C;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-weight: 600;
}

.skill-exp-input {
    padding: 8px 10px;
    border: 1px solid #E8E4C4;
    border-radius: var(--radius-md);
    font-size: 14px;
    color: #2B1B3D;
    background: #FFFFFF;
    width: min(140px, 100%);
    box-sizing: border-box;
    transition:
        border-color .2s ease,
        box-shadow .2s ease;
}

@media (hover: hover) {
    .skill-exp-input:hover {
        border-color: #D5D28F;
    }
}

.skill-exp-input:focus {
    outline: 2px solid #6D5FD5;
    border-color: transparent;
    box-shadow: 0 0 0 4px rgba(109,95,213,.18);
}

.skill-exp-input::-webkit-outer-spin-button,
.skill-exp-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.skill-exp-input[type=number] {
    -moz-appearance: textfield;
}

.skill-exp-input-invalid {
    border-color: #E0606F !important;
    box-shadow: 0 0 0 2px rgba(224,96,111,.20) !important;
}

.skill-exp-warning {
    font-size: 12px;
    color: #E0606F;
    margin-top: 4px;
    min-height: 18px;
    line-height: 1.35;
}

/* ---------- Remove Skill ---------- */

.multi-skill-remove {
    grid-column: 3;
    grid-row: 1;
    display: grid;
    place-items: center;
    width: 24px;
    height: 24px;
    border: 0;
    border-radius: var(--radius-xs);
    background: transparent;
    color: #5E5470;
    font-size: var(--text-lg);
    transition:
        background .2s ease,
        color .2s ease,
        transform .2s ease;
}

@media (hover: hover) {
    .multi-skill-remove:hover {
        background: #FFF3CF;
        color: #E0606F;
        transform: rotate(6deg);
    }
}

/* ---------- Other Skill ---------- */

.other-skill-row {
    margin-top: 16px;
}

.other-skill-button {
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--cta);
    font-size: var(--text-sm);
    font-weight: 700;
}

@media (hover: hover) {
    .other-skill-button:hover {
        color: var(--cta-hover);
        text-decoration: underline;
    }
}

.other-skill-box {
    display: grid;
    grid-template-columns: 1fr 180px;
    gap: 12px;
    margin-top: 12px;
    animation: profile-in 280ms ease both;
}

.other-skill-rating {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.other-skill-rating label {
    font-size: var(--text-sm);
    font-weight: 600;
}

.other-skill-rating select {
    width: 100%;
    height: 42px;
    padding: 0 10px;
    border: 1px solid var(--border);
    border-radius: var(--radius-xs);
    background: var(--surface-strong);
    color: var(--text-primary);
}

/* ---------- Submit Section ---------- */

.submit-section {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 28px;
    padding: 28px 32px;
    border: 1px solid #E8E4C4;
    border-radius: var(--radius-2xl);
    background: #FBF9EA;
    box-shadow: 0 4px 12px rgba(109,95,213,.15);
    transition: all .25s var(--ease-standard);
}

@media (hover: hover) {
    .submit-section:hover {
        transform: translateY(-2px);
        border-color: #D5D28F;
        box-shadow: 0 10px 28px rgba(109,95,213,.35);
    }
}

.submit-section h2 {
    margin: 0;
    color: #2B1B3D;
    font-size: var(--text-display);
    letter-spacing: -0.03em;
    font-weight: 700;
    font-family: "Inter", sans-serif;
}

.submit-section .approval-info {
    color: #6B5300;
    font-size: var(--text-sm);
    font-weight: 600;
}

.submit-section p:last-child {
    margin: 6px 0 0;
    color: #5E5470;
    font-size: var(--text-base);
}

/* ---------- Buttons ---------- */

.submit-button,
.secondary-button {
    border: 0;
    border-radius: var(--radius-md);
    padding: 14px 24px;
    font-weight: 700;
    transition:
        transform .2s var(--ease-standard),
        box-shadow .2s var(--ease-standard);
}

.submit-button {
    background: #6D5FD5;
    color: #FFFFFF;
    min-width: 220px;
    white-space: nowrap;
    box-shadow: 0 4px 12px rgba(109,95,213,.25);
}

@media (hover: hover) {
    .submit-button:hover:not(:disabled) {
        background: #5E50C9;
        transform: translateY(-2px);
        box-shadow: 0 10px 28px rgba(109,95,213,.35);
    }
    
    .secondary-button:hover {
        background: #EEEBFF;
        transform: translateY(-2px);
        box-shadow: 0 10px 28px rgba(109,95,213,.15);
    }
}

.submit-button:active:not(:disabled),
.secondary-button:active {
    transform: translateY(0);
}

.submit-button:disabled {
    background: #EFEBD0;
    color: #A59FB3;
    box-shadow: none;
    cursor: not-allowed;
}

/* ---------- Button Spinner ---------- */

.button-spinner {
    display: inline-block;
    width: 14px;
    height: 14px;
    margin-right: 8px;
    border: 2px solid rgba(255,255,255,.35);
    border-top-color: var(--surface-strong);
    border-radius: 50%;
    animation: spin 700ms linear infinite;
}

/* ---------- Success State ---------- */

.success-state {
    padding: 40px 28px;
    border: 1px solid #E8E4C4;
    border-radius: var(--radius-2xl);
    background: #FFFEF9;
    box-shadow: 0 4px 16px rgba(109,95,213,.12);
    text-align: center;
    animation: card-in 550ms ease both;
    min-height: 220px;
}

.success-mark {
    display: grid;
    place-items: center;
    width: 52px;
    height: 52px;
    margin: 0 auto 12px;
    border-radius: 50%;
    background: #F1EFC8;
    color: #6B6820;
    font-size: var(--text-display);
    font-weight: 800;
    animation: success-pop 600ms cubic-bezier(.22,1,.36,1) both;
}

.success-state h2 {
    margin: 0;
    color: #2B1B3D;
    font-size: var(--text-hero-lg);
    letter-spacing: -0.04em;
    font-weight: 700;
}

.success-state p:not(.eyebrow) {
    max-width: 480px;
    margin: 8px auto 20px;
    color: #5E5470;
    line-height: 1.6;
}

.secondary-button {
    background: transparent;
    border: 1px solid #6D5FD5;
    color: #6D5FD5;
    box-shadow: none;
    cursor: pointer;
    font-family: "Inter", sans-serif;
}

.secondary-button svg {
    display: inline-block;
    width: 16px;
    height: 16px;
    margin-left: 8px;
}

/* ---------- Approval Banner ---------- */

.approval-banner {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0 0 24px;
    padding: 14px 16px;
    border: 1px solid #E8CF7A;
    border-radius: var(--radius-xl);
    background: #FFF3CF;
    box-shadow: 0 2px 8px rgba(189,185,106,.20);
    animation: approval-banner-in 520ms cubic-bezier(.22,1,.36,1) both;
}

.approval-banner-icon {
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #FBF9EA;
    color: #6B5300;
    font-size: var(--text-section);
}

.approval-banner p {
    margin: 0;
    color: #6B5300;
    font-size: var(--text-sm);
    font-weight: 700;
    line-height: 1.5;
}

/* ---------- Review Section ---------- */

#assessmentForm.review-mode > :not(#reviewSection) {
    display: none !important;
}

#assessmentWorkspace:has(#assessmentForm.review-mode:not(.hidden)) .intro-section {
    display: none;
}

#assessmentWorkspace:has(#successState:not(.hidden)) .intro-section {
    display: none !important;
}

#assessmentForm.review-mode #reviewSection {
    margin-top: 0;
}

.submit-section.review-section {
    background:
        linear-gradient(
            100deg,
            var(--lavender-soft),
            var(--surface-card)
        );
}

.review-actions {
    display: flex;
    gap: 16px;
    margin-top: 20px;
}

.final-submission-warning {
    margin: 12px 0;
    color: #4E3D66;
    font-weight: 700;
    line-height: 1.5;
}

.assessment-review-list {
    display: grid;
    gap: 8px;
    margin: 16px 0;
    padding: 0;
    list-style: none;
}

.assessment-review-list li {
    display: flex;
    flex-direction: column;
    gap: 3px;
    padding: 10px 12px;
    border: 1px solid #E8E4C4;
    border-radius: 10px;
    background: #FFFEF9;
}

.assessment-review-list li span,
.review-payload-note {
    color: #5E5470;
    font-size: 13px;
    line-height: 1.45;
}

.review-payload-note {
    margin: 12px 0 0;
}

/* ---------- Footer ---------- */

footer {
    display: flex;
    justify-content: space-between;
    padding: 22px 0 30px;
    color: var(--text-tertiary);
    font-size: var(--text-xs);
}

/* ---------- Final enterprise polish ---------- */

.topbar {
    min-height: 60px;
    padding-inline: 24px;
    border-color: rgba(232, 228, 196, .72);
    background: rgba(255, 252, 239, .96);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
}

.brand {
    gap: 10px;
}

.brand-mark {
    width: 42px;
    height: 42px;
    flex-basis: 42px;
    border-radius: 12px;
    box-shadow: none;
    font-size: 16px;
}

.brand-copy strong {
    font-size: 15px;
}

.brand-copy small {
    margin-top: 0;
    font-size: 11px;
}

.topbar-status {
    gap: 8px;
    font-size: 12px;
}

.status-dot {
    width: 7px;
    height: 7px;
    box-shadow: none;
}

.intro-section {
    align-items: center;
    gap: 32px;
    margin-bottom: 28px;
}

.intro-copy h1 {
    font-size: clamp(36px, 4.4vw, 46px);
    line-height: 1.08;
}

.intro-text {
    margin-top: 8px;
    font-size: 15px;
    line-height: 1.55;
}

.progress-card {
    padding: 16px;
    border-radius: 16px;
    box-shadow: var(--shadow-sm);
}

.assessment-card {
    padding: 24px;
    border-radius: 18px;
    box-shadow: var(--shadow-sm);
    transition: border-color var(--dur-fast) var(--ease-standard);
}

@media (hover: hover) {
    .assessment-card:hover {
        transform: none;
        border-color: var(--border-hover);
        box-shadow: var(--shadow-sm);
    }
}

.section-heading {
    gap: 14px;
    margin-bottom: 20px;
}

.section-heading h2 {
    font-size: clamp(24px, 2.6vw, 30px);
}

.employee-details {
    border-color: rgba(232, 228, 196, .7);
    background: rgba(232, 228, 196, .7);
}

.detail-field {
    padding: 12px 14px;
}

.detail-field span {
    font-size: 10px;
    letter-spacing: .055em;
}

.detail-field strong {
    font-size: 14px;
}

.skill-section-header {
    gap: 6px;
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-color: var(--border);
}

#mandatorySkillsSection .skill-section-header {
    border-color: rgba(109, 95, 213, .3);
}

#mandatorySkillsSection .skill-section-header h3 {
    color: var(--text-primary);
}

.skill-section-header h3 {
    font-size: 20px;
    letter-spacing: -.015em;
}

.skill-section-header p {
    font-size: 13px;
}

.skill-section {
    margin-bottom: 22px;
}

#mandatorySkillsSection {
    margin-bottom: 28px;
}

.pick-skills-section {
    margin-bottom: 18px;
}

#secondarySkillsSection {
    margin-bottom: 6px;
}

.selected-skills-list {
    gap: 8px;
}

.multi-skill-row {
    min-height: 72px;
    padding: 10px 14px;
    border-color: var(--border);
    border-radius: 12px;
    box-shadow: none;
}

.multi-skill-row:not(:has(.multi-skill-remove)) {
    grid-template-columns: minmax(0, 1fr) auto;
}

.multi-skill-name {
    font-size: 17px;
    line-height: 1.3;
    white-space: normal;
    overflow-wrap: anywhere;
}

.multi-skill-category {
    font-size: 12px;
}

.skill-exp-label {
    font-size: 10px;
    letter-spacing: .045em;
}

.skill-exp-input {
    min-height: 38px;
    padding: 7px 10px;
}

.star-button.active,
.star-button.active.preview {
    color: #D99A20;
    filter: drop-shadow(0 0 4px rgba(217, 154, 32, .24));
}

.star-button.preview {
    color: color-mix(in srgb, #D99A20 58%, #E6E2C2);
    filter: none;
}

.soft-skills-section {
    margin-top: 18px;
    padding-top: 16px;
    border-top-color: rgba(232, 228, 196, .8);
}

.soft-skills-eyebrow {
    margin-bottom: 4px;
    color: var(--text-secondary);
    font-size: 11px;
    letter-spacing: .065em;
}

.soft-skills-heading {
    margin: 0 0 14px;
    font-size: 22px;
}

.soft-skills-selector {
    margin-top: 16px;
}

.soft-skills-selector > label {
    display: block;
    margin-bottom: 6px;
    color: var(--text-primary);
    font-size: 13px;
    font-weight: 600;
}

.soft-skills-section .selected-skills-empty {
    padding: 10px 12px;
    border-color: transparent;
    background: var(--surface-cream);
}

.zero-experience-reason {
    margin-inline: 8px;
    border-color: rgba(232, 217, 168, .8);
    background: #FFFAEF;
}

.zero-experience-reason-helper {
    font-size: 12px;
}

.pre-review-cta {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr) auto;
    align-items: center;
    gap: 24px;
    padding: 22px 24px;
    border-color: var(--border);
    border-radius: 16px;
    background: var(--surface-cream);
    box-shadow: none;
}

.pre-review-cta .eyebrow {
    margin-bottom: 5px;
    font-size: 11px;
}

.pre-review-cta h2 {
    font-size: 22px;
    line-height: 1.25;
}

.pre-review-cta p:not(.eyebrow) {
    margin: 6px 0 0;
    color: var(--text-secondary);
    font-size: 13px;
    line-height: 1.5;
}

.cta-action {
    display: flex;
    justify-content: flex-end;
}

@media (hover: hover) {
    .pre-review-cta:hover,
    .submit-section.review-section:hover {
        transform: none;
        border-color: var(--border);
        box-shadow: none;
    }
}

.submit-button,
.secondary-button {
    min-height: 46px;
    padding: 11px 18px;
    border-radius: 11px;
    font-family: var(--font-sans);
    font-size: 13px;
    line-height: 1.25;
}

.submit-button {
    min-width: 210px;
    box-shadow: 0 2px 6px rgba(109, 95, 213, .18);
}

.secondary-button {
    border-color: var(--border-hover);
    background: var(--surface-card);
    color: var(--text-secondary);
}

.submit-section.review-section {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    align-items: start;
    gap: 8px;
    padding: 24px;
    border-color: var(--border);
    border-radius: 18px;
    background: var(--surface-card);
    box-shadow: var(--shadow-sm);
}

.review-section h2 {
    max-width: 720px;
    font-size: 25px;
    line-height: 1.3;
}

.review-section .final-submission-warning {
    margin: 8px 0 0;
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
}

.assessment-review-list {
    width: 100%;
    min-width: 0;
    margin: 12px 0 0;
    display: grid;
    gap: 0;
}

.assessment-review-header,
.assessment-review-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(100px, .28fr) minmax(140px, .36fr);
    align-items: center;
    gap: 16px;
    min-width: 0;
}

.assessment-review-header {
    padding: 0 14px 8px;
    color: var(--text-tertiary);
    font-size: 11px;
    font-weight: 600;
}

.assessment-review-row {
    padding: 12px 14px;
    border-top: 1px solid rgba(232, 228, 196, .75);
}

.review-skill-name {
    min-width: 0;
    color: var(--text-primary);
    font-size: 14px;
    font-weight: 600;
    overflow-wrap: anywhere;
}

.review-metric {
    display: flex;
    flex-direction: column;
    gap: 2px;
    color: var(--text-primary);
    font-size: 13px;
}

.review-metric > span {
    color: var(--text-tertiary);
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.review-metric > strong {
    font-weight: 500;
}

.review-reason {
    grid-column: 1 / -1;
    margin: 0;
    color: var(--text-secondary);
    font-size: 12px;
    line-height: 1.45;
}

.review-reason strong {
    color: var(--text-primary);
}

.review-payload-note {
    margin: 8px 14px 0;
    color: var(--text-tertiary);
    font-size: 11px;
}

.review-actions {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 10px;
    width: 100%;
    margin-top: 12px;
}

footer {
    gap: 12px;
    padding: 20px 0 24px;
    font-size: 11px;
}

@media (max-width: 900px) {
    .pre-review-cta {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .cta-action {
        grid-column: 1 / -1;
    }
}

@media (max-width: 640px) {
    .topbar {
        padding-inline: 12px;
    }

    .intro-copy h1 {
        font-size: 36px;
    }

    .intro-section {
        gap: 18px;
        margin-bottom: 22px;
    }

    .intro-text {
        font-size: 14px;
    }

    .assessment-card {
        padding: 18px 16px;
        border-radius: 16px;
    }

    .section-heading {
        gap: 12px;
        margin-bottom: 18px;
    }

    .section-heading h2 {
        font-size: 24px;
    }

    .section-number {
        width: 32px;
        height: 32px;
        flex-basis: 32px;
    }

    .detail-field {
        padding: 9px 12px;
    }

    .detail-field strong {
        font-size: 13px;
        white-space: normal;
        overflow-wrap: anywhere;
    }

    .detail-field span {
        font-size: 11px;
    }

    .multi-skill-row {
        min-height: 0;
        padding: 11px 12px;
    }

    .multi-skill-name {
        font-size: 16px;
    }

    .skill-rating-area {
        gap: 3px;
    }

    .star-rating {
        gap: 2px;
    }

    .star-button {
        width: 26px;
        height: 26px;
    }

    .pre-review-cta {
        grid-template-columns: minmax(0, 1fr);
        gap: 14px;
        padding: 18px 16px;
    }

    .cta-action {
        grid-column: auto;
    }

    .cta-action .submit-button,
    .review-actions .submit-button,
    .review-actions .secondary-button {
        width: 100%;
        min-width: 0;
    }

    .submit-section.review-section {
        padding: 18px 16px;
    }

    .review-section h2 {
        font-size: 22px;
    }

    .assessment-review-header {
        display: none;
    }

    .assessment-review-row {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        gap: 8px 12px;
        padding: 12px 4px;
    }

    .review-skill-name {
        grid-column: 1 / -1;
    }

    .review-reason {
        grid-column: 1 / -1;
    }

    .review-actions {
        flex-direction: column-reverse;
        align-items: stretch;
    }

    footer {
        align-items: flex-start;
        gap: 4px;
        padding: 18px 0 22px;
    }
}

/* ---------- Animations ---------- */

@keyframes card-in {
    from {
        opacity: 0;
        transform: translateY(12px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes dropdown-in {
    from {
        opacity: 0;
        transform: translateY(-4px) scale(0.99);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes profile-in {
    from {
        opacity: 0;
        transform: translateY(6px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes multi-skill-in {
    from {
        opacity: 0;
        transform: translateY(-6px) scale(0.985);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes star-pop {
    0% {
        transform: scale(0.8);
    }
    50% {
        transform: scale(1.15) rotate(-3deg);
    }
    100% {
        transform: scale(1);
    }
}

@keyframes feedback-pop {
    0% {
        opacity: 0;
        transform: translateX(4px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes success-pop {
    0% {
        opacity: 0;
        transform: scale(0.5);
    }
    65% {
        transform: scale(1.1);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes approval-banner-in {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

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

@media (max-width: 1000px) {
    .multi-skill-row {
        grid-template-columns: minmax(0, 1fr) auto 28px;
        gap: 8px 12px;
    }
    
    .skill-feedback {
        width: 6.75rem;
    }
    
    .skill-exp-input {
        width: 120px;
    }
}

@media (max-width: 900px) {
    .intro-section,
    .submit-section {
        align-items: stretch;
        flex-direction: column;
    }
    
    .progress-card {
        width: 100%;
        flex-basis: auto;
    }
    
    .skill-top-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 760px) {
    .multi-skill-row {
        grid-template-columns: minmax(0, 1fr) auto 28px;
        gap: 8px;
        padding: 10px 12px;
    }
    
    .skill-feedback {
        width: 6.5rem;
    }
    
    .star-button {
        width: 22px;
        height: 22px;
        font-size: var(--text-title);
    }
    
    .skill-exp-input {
        width: min(120px, 100%);
    }
    
    .other-skill-box {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .page-shell {
        width: min(100% - 20px, 1260px);
    }
    
    main {
        padding-top: 42px;
    }
    
    .topbar {
        min-height: 62px;
    }
    
    .topbar-status {
        display: none;
    }
    
    .intro-copy h1 {
        font-size: var(--text-hero-xl);
    }
    
    .assessment-card,
    .submit-section {
        padding: 20px;
        border-radius: var(--radius-xl);
    }
    
    .employee-details {
        grid-template-columns: 1fr;
    }
    
    .detail-field + .detail-field {
        border-top: 1px solid var(--border);
        border-left: 0;
    }
    
    .multi-skill-row {
        grid-template-areas:
            "info remove"
            "rating remove";
        grid-template-columns: minmax(0, 1fr) 28px;
        gap: 10px 8px;
        padding: 12px;
        min-height: 0;
    }

    .multi-skill-info {
        grid-area: info;
    }

    .skill-rating-area {
        grid-area: rating;
        grid-template-columns: 152px 6.5rem;
        align-items: center;
        column-gap: 6px;
    }

    .multi-skill-remove {
        grid-area: remove;
        align-self: start;
    }
    
    .star-button {
        width: 24px;
        height: 24px;
        font-size: var(--text-title);
    }
    
    .skill-feedback {
        width: 6.5rem;
    }
    
    .skill-exp-input {
        width: min(140px, 100%);
    }

    .multi-skill-name {
        white-space: normal;
        overflow: visible;
        text-overflow: clip;
        overflow-wrap: anywhere;
    }
    
    .other-skill-box {
        grid-template-columns: 1fr;
    }
    
    footer {
        gap: 10px;
        flex-direction: column;
    }
}

/* Keep the final overrides last so legacy breakpoint rules cannot undo them. */
@media (max-width: 900px) {
    .pre-review-cta {
        display: grid;
        flex-direction: initial;
    }
}

@media (max-width: 640px) {
    .intro-copy h1 {
        font-size: 36px;
    }

    .pre-review-cta {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        flex-direction: initial;
    }
}

@media (max-width: 640px) {
    .employee-details {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .employee-details .detail-field {
        min-width: 0;
        padding: 9px 10px;
    }

    .employee-details .detail-field span,
    .employee-details .detail-field strong {
        line-height: 1.35;
        overflow-wrap: anywhere;
    }
}

html:has(#loginScreen:not(.hidden)),
body:has(#loginScreen:not(.hidden)) {
    height: 100%;
    overflow: hidden;
}

body:has(#loginScreen:not(.hidden)) .page-shell {
    height: 100vh;
    max-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

body:has(#loginScreen:not(.hidden)) .topbar {
    flex: 0 0 auto;
}

body:has(#loginScreen:not(.hidden)) main {
    flex: 1 1 auto;
    min-height: 0;
    padding: 0;
    display: grid;
    place-items: center;
    overflow: hidden;
}

body:has(#loginScreen:not(.hidden)) footer {
    display: none;
}

.login-stage {
    width: 100%;
    height: 100%;
    min-height: 0;
    display: grid;
    place-items: center;
    padding: 0;
}

.login-stage.hidden {
    display: none;
}

.login-card {
    width: min(820px, 100%);
    display: grid;
    grid-template-columns: 248px minmax(0, 1fr);
    margin: 0;
    padding: 0;
    overflow: hidden;
}

.login-card:hover {
    transform: none;
    border-color: var(--border);
    box-shadow: var(--shadow-sm);
}

.portal-rail {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 22px;
    min-height: 100%;
    padding: 28px 22px;
    color: #FFFFFF;
    background:
        radial-gradient(circle at 18% 8%, rgba(255, 255, 255, .28), transparent 42%),
        linear-gradient(165deg, #8B7FE8 0%, #6D5FD5 52%, #433A86 100%);
}

.portal-kicker {
    margin: 0;
    color: rgba(255, 255, 255, .82);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
}

.portal-role {
    display: block;
    margin-top: 8px;
    font-size: 36px;
    line-height: .95;
    letter-spacing: -0.03em;
}

.portal-purpose {
    margin: 12px 0 0;
    color: rgba(255, 255, 255, .92);
    font-size: 13px;
    font-weight: 500;
    line-height: 1.5;
}

.portal-steps {
    display: grid;
    gap: 8px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.portal-steps li {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 600;
}

.portal-steps span {
    display: grid;
    width: 22px;
    height: 22px;
    place-items: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, .2);
    font-size: 11px;
    font-weight: 700;
}

.login-main {
    min-width: 0;
    padding: 32px 28px 28px;
}

.topbar-status {
    padding: 7px 12px;
    border-radius: 999px;
    background: #F3F0FF;
    color: #433A86;
    font-weight: 700;
}

@media (max-width: 900px) {
    .topbar-status {
        display: flex;
    }
}

.login-stage.is-loading .login-panel {
    display: none;
}

.login-stage:not(.is-loading) .login-loader {
    display: none;
}

.login-loader {
    display: grid;
    justify-items: center;
    gap: 6px;
    min-height: 240px;
    align-content: center;
    text-align: center;
}

.login-loader strong {
    color: #2B1B3D;
    font-size: 20px;
    font-weight: 700;
}

.login-orbit {
    position: relative;
    width: 108px;
    height: 108px;
    margin-bottom: 10px;
    border: 1px solid #E8E4C4;
    border-radius: 50%;
}

.login-orbit::after {
    content: "";
    position: absolute;
    inset: 10px;
    border: 2px solid transparent;
    border-top-color: #6D5FD5;
    border-radius: 50%;
    animation: spin 1.1s linear infinite;
}

.login-orbit i {
    position: absolute;
    inset: 0;
    transform: rotate(calc(var(--i) * 72deg));
}

.login-orbit i::before {
    content: "";
    position: absolute;
    left: 50%;
    top: 8px;
    width: 14px;
    height: 14px;
    margin-left: -7px;
    background: #E6E2C2;
    clip-path: polygon(50% 0%, 62% 34%, 98% 35%, 69% 56%, 79% 92%, 50% 72%, 21% 92%, 31% 56%, 2% 35%, 38% 34%);
    animation: login-star 1.4s ease-in-out infinite;
    animation-delay: calc(var(--i) * 0.16s);
}

@keyframes login-star {
    0%, 70%, 100% {
        background: #E6E2C2;
        transform: scale(1);
    }
    35% {
        background: #D99A20;
        transform: scale(1.28);
    }
}

.login-panel .section-heading {
    margin-bottom: 8px;
}

.login-lead {
    margin: 6px 0 0;
    color: #5E5470;
    font-size: 14px;
    line-height: 1.5;
}

.login-form {
    display: grid;
    gap: 8px;
    max-width: none;
}

.login-form label {
    margin-top: 8px;
    color: var(--text-primary);
    font-size: var(--text-base);
    font-weight: 700;
}

.login-form input {
    width: 100%;
    height: 48px;
    padding: 0 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--surface-input);
    color: var(--text-primary);
    font: inherit;
    font-size: var(--text-base);
}

.login-form input:focus {
    outline: none;
    border-color: var(--cta);
    box-shadow: 0 0 0 3px rgba(109, 95, 213, .15);
}

.login-form .submit-button {
    width: 100%;
    min-width: 0;
    margin-top: 16px;
    justify-content: center;
}

.login-status {
    display: grid;
    grid-template-columns: 78px minmax(0, 1fr);
    gap: 8px 14px;
    align-items: center;
    margin-top: 16px;
    padding: 16px;
    border: 2px solid #E8CF7A;
    border-radius: var(--radius-lg);
    background: #FBF3D0;
    color: #8C6A1E;
}

.login-status-copy {
    min-width: 0;
}

.login-status-orbit {
    position: relative;
    width: 72px;
    height: 72px;
    border: 1px solid #E4C56A;
    border-radius: 50%;
    background: #FFF8DE;
}

.login-status-orbit::after {
    content: "";
    position: absolute;
    inset: 8px;
    border: 2px solid transparent;
    border-top-color: #A87305;
    border-radius: 50%;
    animation: spin 1.1s linear infinite;
}

.login-status-orbit i {
    position: absolute;
    inset: 0;
    transform: rotate(calc(var(--i) * 72deg));
}

.login-status-orbit i::before {
    content: "";
    position: absolute;
    left: 50%;
    top: 5px;
    width: 11px;
    height: 11px;
    margin-left: -5.5px;
    background: #E8D48A;
    clip-path: polygon(50% 0%, 62% 34%, 98% 35%, 69% 56%, 79% 92%, 50% 72%, 21% 92%, 31% 56%, 2% 35%, 38% 34%);
    animation: login-status-star 1.4s ease-in-out infinite;
    animation-delay: calc(var(--i) * 0.16s);
}

@keyframes login-status-star {
    0%, 70%, 100% {
        background: #E8D48A;
        transform: scale(1);
    }
    35% {
        background: #A87305;
        transform: scale(1.25);
    }
}

.login-status-copy .eyebrow {
    margin: 0;
    color: #8C6A1E;
}

.login-status strong {
    display: block;
    margin-top: 4px;
    color: #8C6A1E;
    font-size: var(--text-body);
    line-height: 1.5;
}

.login-status p {
    margin: 6px 0 0;
    color: #8C6A1E;
    font-size: var(--text-sm);
    font-weight: 600;
    line-height: 1.6;
}

.login-status small {
    display: block;
    margin-top: 8px;
    color: var(--amber-text-2);
    font-size: var(--text-xs);
    font-weight: 700;
}

.login-status .secondary-button {
    grid-column: 2;
    justify-self: start;
    padding: 8px 14px;
    font-size: var(--text-xs);
}

.login-status-rejected {
    grid-template-columns: minmax(0, 1fr);
    border-color: #E8D2D6;
    background: #FBE3E6;
    color: #79534E;
}

.login-status-rejected .eyebrow,
.login-status-rejected strong,
.login-status-rejected p {
    color: #79534E;
}

.login-status-rejected .secondary-button {
    align-self: center;
}

.login-form.is-waiting label,
.login-form.is-waiting input,
.login-form.is-waiting .submit-button,
.login-form.is-rejected label,
.login-form.is-rejected input,
.login-form.is-rejected .submit-button {
    display: none;
}

.login-panel:has(.login-form.is-waiting) .login-lead,
.login-panel:has(.login-form.is-rejected) .login-lead {
    display: none;
}

@media (max-width: 720px) {
    .login-card {
        grid-template-columns: minmax(0, 1fr);
    }

    .portal-rail {
        gap: 16px;
        padding: 20px 18px;
    }

    .portal-role {
        font-size: 30px;
    }
}

.topbar {
    min-height: 96px;
}

.brand {
    align-items: center;
    gap: 18px;
    margin-left: -22px;
}

.brand-copy {
    display: flex;
    align-items: center;
    margin: 0;
    padding-left: 18px;
    border-left: 1.5px solid #E4D7A4;
    color: #2B1B3D;
    font-size: 22px;
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 1;
    text-align: left;
    white-space: nowrap;
    transform: translateY(-6px);
}

.brand-logo {
    display: flex;
    align-items: center;
    height: auto;
    padding: 0;
    background: transparent;
    border: 0;
    box-shadow: none;
}

.brand-logo img {
    display: block;
    height: 74px;
    width: auto;
    max-width: min(360px, 58vw);
    object-fit: contain;
}

.section-mark {
    display: grid;
    place-items: center;
    width: 56px;
    height: 56px;
    flex: 0 0 56px;
}

.section-mark img {
    display: block;
    width: 56px;
    height: 56px;
    object-fit: contain;
}

.login-frame {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: min(820px, calc(100% - 32px));
    max-height: 100%;
}

.login-frame .login-card {
    width: 100%;
}

@media (max-width: 640px) {
    .brand-logo img {
        height: 52px;
    }

    .brand-copy {
        display: none;
    }
}

@media (max-width: 860px) {
    .employee-profile {
        flex-wrap: wrap;
    }

    .profile-experience {
        width: 100%;
        margin-left: 0;
        padding-left: 0;
    }

    .profile-experience,
    .profile-experience small {
        white-space: normal;
    }
}
