/* =========================================================
   COMPETENCY EDIT
========================================================= */

.competency-edit-page {
    width: 100%;
    max-width: 1500px;
    margin: 0 auto;
    padding: 0 0 50px;
}


/* =========================================================
   TOP / BACK
========================================================= */

.competency-edit-top {
    margin: 0 0 16px;
}

.competency-back-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;

    min-height: 38px;
    padding: 0 14px;


    color: #2563eb;

    text-decoration: none;

    font-size: 12px;
    font-weight: 700;


    transition: .2s ease;
}

.competency-back-button:hover {
    background: #eff6ff;
    border-color: #93c5fd;
    color: #1d4ed8;
    transform: translateX(-2px);
}


/* =========================================================
   HERO
========================================================= */

.competency-edit-hero {
    position: relative;

    min-height: 190px;

    display: flex;
    align-items: center;

    padding: 35px 40px;

    margin-bottom: 20px;

    overflow: hidden;

    border-radius: 18px;

    background:
        radial-gradient(
            circle at 100% 0%,
            rgba(37, 99, 235, .35),
            transparent 35%
        ),
        linear-gradient(
            135deg,
            #020617 0%,
            #071b4d 55%,
            #0b2e73 100%
        );

    border: 1px solid rgba(37, 99, 235, .30);

    box-shadow:
        0 12px 30px rgba(15, 23, 42, .15);
}

.competency-edit-hero::after {
    content: "";

    position: absolute;

    width: 220px;
    height: 220px;

    right: -70px;
    top: -100px;

    border-radius: 50%;

    background: rgba(37, 99, 235, .18);

    pointer-events: none;
}

.competency-edit-hero-content {
    position: relative;
    z-index: 2;
}

.competency-edit-eyebrow {
    display: inline-flex;

    align-items: center;

    padding: 7px 11px;

    margin-bottom: 10px;

    border-radius: 7px;

    background: rgba(37, 99, 235, .18);

    border: 1px solid rgba(96, 165, 250, .30);

    color: #60a5fa;

    font-size: 10px;
    font-weight: 800;

    letter-spacing: 1px;
}

.competency-edit-hero h1 {
    margin: 0 0 8px;

    color: #ffffff;

    font-size: 30px;
    line-height: 1.2;

    font-weight: 800;

    letter-spacing: -.5px;
}

.competency-edit-hero p {
    max-width: 800px;

    margin: 0;

    color: #bfdbfe;

    font-size: 13px;
    line-height: 1.6;
}


/* =========================================================
   ALERT
========================================================= */

.competency-edit-alert {
    display: flex;
    align-items: flex-start;
    gap: 12px;

    margin-bottom: 18px;
    padding: 15px 18px;

    background: #fff7ed;

    border: 1px solid #fed7aa;
    border-left: 4px solid #f97316;

    border-radius: 11px;

    color: #9a3412;
}

.competency-edit-alert-icon {
    width: 25px;
    height: 25px;

    display: flex;
    align-items: center;
    justify-content: center;

    flex-shrink: 0;

    border-radius: 50%;

    background: #f97316;

    color: white;

    font-size: 13px;
    font-weight: 800;
}

.competency-edit-alert strong {
    display: block;

    margin-bottom: 3px;

    font-size: 12px;
}

.competency-edit-alert p {
    margin: 0;

    font-size: 11px;
}


/* =========================================================
   CARD
========================================================= */

.competency-edit-card {
    background: #ffffff;

    border: 1px solid #e3e9f1;

    border-radius: 17px;

    overflow: hidden;

    box-shadow:
        0 7px 24px rgba(15, 23, 42, .05);
}


/* =========================================================
   CARD HEADER
========================================================= */

.competency-edit-card-header {
    padding: 26px 30px;

    border-bottom: 1px solid #edf1f5;

    border-top: 4px solid #2563eb;
}

.competency-edit-section-label {
    margin-bottom: 7px;

    color: #60a5fa;

    font-size: 10px;
    font-weight: 800;

    letter-spacing: 1.1px;
}

.competency-edit-card-header h2 {
    margin: 0 0 5px;

    color: #172033;

    font-size: 20px;
    font-weight: 800;
}

.competency-edit-card-header p {
    margin: 0;

    color: #8a94a6;

    font-size: 12px;
}


/* =========================================================
   FORM
========================================================= */

.competency-edit-form {
    padding: 30px;
}

.competency-edit-field {
    margin-bottom: 23px;
}

.competency-edit-field label {
    display: block;

    margin-bottom: 8px;

    color: #334155;

    font-size: 12px;
    font-weight: 700;
}

.competency-edit-field label span {
    color: #2563eb;
}

.competency-edit-field input,
.competency-edit-field textarea,
.competency-edit-field select {
    width: 100%;

    box-sizing: border-box;

    border: 1px solid #dbe3ed;

    border-radius: 10px;

    background: #ffffff;

    color: #172033;

    font-family: inherit;

    font-size: 13px;

    outline: none;

    transition: .2s ease;
}

.competency-edit-field input,
.competency-edit-field select {
    height: 45px;

    padding: 0 13px;
}

.competency-edit-field textarea {
    min-height: 125px;

    padding: 13px;

    resize: vertical;

    line-height: 1.55;
}

.competency-edit-field input:focus,
.competency-edit-field textarea:focus,
.competency-edit-field select:focus {
    border-color: #3b82f6;

    box-shadow:
        0 0 0 3px rgba(37, 99, 235, .10);
}

.competency-edit-field small {
    display: block;

    margin-top: 7px;

    color: #94a3b8;

    font-size: 10px;

    line-height: 1.5;
}


/* =========================================================
   ACTION
========================================================= */

.competency-edit-actions {
    display: flex;

    align-items: center;
    justify-content: flex-end;

    gap: 10px;

    padding-top: 22px;

    margin-top: 8px;

    border-top: 1px solid #edf1f5;
}

.competency-cancel-button {
    display: inline-flex;

    align-items: center;
    justify-content: center;

    min-height: 42px;

    padding: 0 18px;

    border-radius: 9px;

    background: #ffffff;

    border: 1px solid #dbe3ed;

    color: #64748b;

    text-decoration: none;

    font-size: 12px;
    font-weight: 700;

    transition: .2s ease;
}

.competency-cancel-button:hover {
    background: #f8fafc;

    color: #334155;

    border-color: #cbd5e1;
}

.competency-save-button {
    display: inline-flex;

    align-items: center;
    justify-content: center;

    gap: 7px;

    min-height: 42px;

    padding: 0 20px;

    border: 1px solid #2563eb;

    border-radius: 9px;

    background: #2563eb;

    color: #ffffff;

    font-family: inherit;

    font-size: 12px;
    font-weight: 700;

    cursor: pointer;

    box-shadow:
        0 5px 14px rgba(37, 99, 235, .20);

    transition: .2s ease;
}

.competency-save-button:hover {
    background: #1d4ed8;

    border-color: #1d4ed8;

    transform: translateY(-1px);

    box-shadow:
        0 7px 18px rgba(37, 99, 235, .25);
}


/* =========================================================
   ERROR PAGE
========================================================= */

.competency-edit-error-page {
    padding: 70px 30px;

    text-align: center;

    background: #ffffff;

    border: 1px solid #e3e9f1;

    border-radius: 17px;

    box-shadow:
        0 7px 24px rgba(15, 23, 42, .05);
}

.competency-edit-error-icon {
    width: 48px;
    height: 48px;

    display: flex;
    align-items: center;
    justify-content: center;

    margin: 0 auto 15px;

    border-radius: 50%;

    background: #eff6ff;

    color: #2563eb;

    font-size: 20px;
    font-weight: 800;
}

.competency-edit-error-page h2 {
    margin: 0 0 7px;

    color: #172033;

    font-size: 20px;
}

.competency-edit-error-page p {
    margin: 0 0 20px;

    color: #64748b;

    font-size: 12px;
}


/* =========================================================
   RESPONSIVE
========================================================= */

@media (max-width: 700px) {

    .competency-edit-hero {
        min-height: auto;

        padding: 28px 24px;
    }

    .competency-edit-hero h1 {
        font-size: 25px;
    }

    .competency-edit-form {
        padding: 22px;
    }

    .competency-edit-card-header {
        padding: 22px;
    }

    .competency-edit-actions {
        flex-direction: column-reverse;
        align-items: stretch;
    }

    .competency-cancel-button,
    .competency-save-button {
        width: 100%;
    }
}


/* =========================================================
   DARK MODE OVERRIDES - EDIT KOMPETENSI
   ========================================================= */

html.theme-dark .competency-edit-page {
    color: #cbd5e1;
}

html.theme-dark .competency-back-button {
    color: #60a5fa !important;
}

html.theme-dark .competency-back-button:hover {
    background: #172033 !important;
    color: #93c5fd !important;
}

html.theme-dark .competency-edit-hero {
    background: linear-gradient(135deg, #070d19 0%, #0d1b38 52%, #13234e 100%) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.4) !important;
}

html.theme-dark .competency-edit-hero h1 {
    color: #ffffff !important;
}

html.theme-dark .competency-edit-hero p {
    color: #94a3b8 !important;
}

html.theme-dark .competency-edit-eyebrow {
    background: rgba(37, 99, 235, 0.25) !important;
    border: 1px solid rgba(96, 165, 250, 0.35) !important;
    color: #60a5fa !important;
    display: inline-flex !important;
    width: fit-content !important;
}

/* Form Card Container */
html.theme-dark .competency-edit-card {
    background: #0d172e !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    box-shadow: 0 8px 26px rgba(0, 0, 0, 0.3) !important;
}

html.theme-dark .competency-edit-card-header {
    background: transparent !important;
    border-top: 4px solid #3b82f6 !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
}

html.theme-dark .competency-edit-section-label {
    color: #60a5fa !important;
}

html.theme-dark .competency-edit-card-header h2 {
    color: #f8fafc !important;
}

html.theme-dark .competency-edit-card-header p {
    color: #94a3b8 !important;
}

/* Fields & Labels */
html.theme-dark .competency-edit-field label {
    color: #cbd5e1 !important;
}

html.theme-dark .competency-edit-field label span {
    color: #60a5fa !important;
}

html.theme-dark .competency-edit-field input,
html.theme-dark .competency-edit-field textarea,
html.theme-dark .competency-edit-field select {
    background: #172033 !important;
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    color: #f8fafc !important;
}

html.theme-dark .competency-edit-field input:focus,
html.theme-dark .competency-edit-field textarea:focus,
html.theme-dark .competency-edit-field select:focus {
    background: #1e293b !important;
    border-color: #3b82f6 !important;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.25) !important;
}

html.theme-dark .competency-edit-field select option {
    background: #1e293b !important;
    color: #f8fafc !important;
}

html.theme-dark .competency-edit-field small {
    color: #64748b !important;
}

/* Bottom Action Bar */
html.theme-dark .competency-edit-actions {
    border-top: 1px solid rgba(255, 255, 255, 0.08) !important;
}

html.theme-dark .competency-cancel-button {
    background: #172033 !important;
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    color: #cbd5e1 !important;
}

html.theme-dark .competency-cancel-button:hover {
    background: #1e293b !important;
    border-color: rgba(255, 255, 255, 0.2) !important;
    color: #ffffff !important;
}

html.theme-dark .competency-save-button {
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%) !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    color: #ffffff !important;
    box-shadow: 0 4px 14px rgba(37, 99, 235, 0.4) !important;
}

html.theme-dark .competency-save-button:hover {
    background: linear-gradient(135deg, #60a5fa 0%, #2563eb 100%) !important;
    color: #ffffff !important;
}