:root {
    --cvp-primary: #D12333;
    --cvp-secondary: #086AD8;
    --cvp-primary-soft: rgba(209,35,51,.18);
    --cvp-button-start: var(--cvp-primary);
    --cvp-button-end: var(--cvp-secondary);
    --cvp-focus-color: var(--cvp-primary);
}

.cvp-shell {
    padding: 40px 24px;
    background: linear-gradient(135deg, var(--cvp-secondary) 0%, var(--cvp-primary) 100%);
    border-radius: 28px;
    color: #fff;
    box-shadow: 0 24px 80px rgba(15, 23, 42, 0.35);
    overflow: hidden;
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* Keep form controls isolated from theme/browser typography. Elementor
 * typography controls can override these inherited values per widget. */
.cvp-shell input,
.cvp-shell select,
.cvp-shell button,
.cvp-shell textarea {
    font-family: inherit;
}

.cvp-shell button,
.cvp-shell input,
.cvp-shell select,
.cvp-shell textarea {
    box-sizing: border-box;
}

.cvp-hero-card {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
    align-items: start;
}

@media (max-width: 868px) {
    .cvp-hero-card {
        grid-template-columns: 1fr;
    }
}

.cvp-hero-copy h2 {
    font-size: 2.2rem;
    margin: 0 0 14px;
    font-weight: 800;
    line-height: 1.25;
    color: #ffffff;
}

.cvp-hero-copy p {
    color: rgba(255, 255, 255, 0.75);
    font-size: 1.05rem;
    line-height: 1.6;
}

.cvp-badge {
    display: inline-block;
    margin-bottom: 14px;
    padding: 6px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    color: #a5b4fc;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.cvp-form-panel {
    background: rgba(255, 255, 255, 0.07);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 24px;
    padding: 28px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
}

.cvp-field {
    margin-bottom: 18px;
}

.cvp-field label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.9);
}

.cvp-field input,
.cvp-field select {
    width: 100%;
    padding: 13px 16px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    background: rgba(255, 255, 255, 0.95);
    color: #0f172a;
    font-size: 1rem;
    font-weight: 500;
    transition: all 0.2s ease;
    box-sizing: border-box;
}

.cvp-field input:focus,
.cvp-field select:focus {
    outline: none;
    border-color: var(--cvp-focus-color);
    box-shadow: 0 0 0 4px var(--cvp-primary-soft);
}

.cvp-submit-btn {
    width: 100%;
    padding: 15px 20px;
    border: none;
    border-radius: 14px;
    font-size: 1.05rem;
    font-weight: 700;
    color: #fff;
    background: linear-gradient(135deg, var(--cvp-button-start), var(--cvp-button-end));
    cursor: pointer;
    transition: all 0.25s ease;
    box-shadow: 0 10px 25px var(--cvp-primary-soft);
}

.cvp-submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 30px var(--cvp-primary-soft);
}

.cvp-loading {
    display: none;
}

.cvp-submit-btn.is-loading .cvp-btn-text {
    display: none;
}

.cvp-submit-btn.is-loading .cvp-loading {
    display: inline-block;
}

.cvp-result-card {
    margin-top: 24px;
    display: none;
}

.cvp-honeypot {
    position: absolute;
    left: -9999px;
}

/* Glassmorphism Cards Styling */
.cvp-glass-card {
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(28px);
    -webkit-backdrop-filter: blur(28px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 24px;
    padding: 28px;
    color: #ffffff;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    position: relative;
    overflow: hidden;
}

.cvp-success-card {
    border-left: 5px solid #22c55e;
}

.cvp-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 12px;
}

.cvp-verified-badge {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(34, 197, 94, 0.15);
    border: 1px solid rgba(34, 197, 94, 0.3);
    padding: 8px 14px;
    border-radius: 999px;
    color: #4ade80;
    font-size: 0.82rem;
    font-weight: 800;
    letter-spacing: 0.5px;
}

.cvp-checkmark-svg {
    width: 22px;
    height: 22px;
}

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

.cvp-card-logo-img {
    max-height: 42px;
    border-radius: 6px;
    object-fit: contain;
}

.cvp-company-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #ffffff;
}

.cvp-candidate-hero {
    margin-bottom: 24px;
}

.cvp-label {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: rgba(255, 255, 255, 0.6);
    font-weight: 600;
}

.cvp-candidate-fullname {
    font-size: 1.8rem;
    font-weight: 800;
    margin: 4px 0 10px;
    color: #ffffff;
}

.cvp-status-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(34, 197, 94, 0.2);
    color: #86efac;
    padding: 6px 14px;
    border-radius: 999px;
    font-weight: 700;
    font-size: 0.88rem;
}

.cvp-dot {
    width: 8px;
    height: 8px;
    background: #22c55e;
    border-radius: 50%;
    box-shadow: 0 0 10px #22c55e;
}

.cvp-card-details-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    background: rgba(0, 0, 0, 0.2);
    padding: 20px;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

@media (max-width: 580px) {
    .cvp-card-details-grid {
        grid-template-columns: 1fr;
    }
}

.cvp-detail-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.cvp-detail-label {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.55);
    font-weight: 500;
}

.cvp-detail-val {
    font-size: 0.98rem;
    font-weight: 600;
    color: #ffffff;
    word-break: break-word;
}

.cvp-highlight {
    color: #a5b4fc;
    font-family: monospace;
    font-size: 1.05rem;
}

.cvp-type-badge {
    display: inline-block;
    background: var(--type-color, var(--cvp-primary));
    color: #fff;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 700;
}

/* Failed Verification Card */
.cvp-failed-card {
    border-left: 5px solid #ef4444;
    background: rgba(239, 68, 68, 0.08);
    text-align: center;
    padding: 36px 24px;
}

.cvp-failed-icon-wrap {
    width: 60px;
    height: 60px;
    margin: 0 auto 16px;
    background: rgba(239, 68, 68, 0.18);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(239, 68, 68, 0.35);
}

.cvp-cross-svg {
    width: 32px;
    height: 32px;
}

.cvp-failed-title {
    font-size: 1.6rem;
    font-weight: 800;
    color: #fca5a5;
    margin: 0 0 8px;
}

.cvp-failed-desc {
    font-size: 1.05rem;
    font-weight: 600;
    color: #ffffff;
    margin: 0 0 12px;
}

.cvp-failed-note {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 20px;
}

.cvp-retry-btn {
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: #fff;
    padding: 10px 22px;
    border-radius: 999px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
}

.cvp-retry-btn:hover {
    background: rgba(255, 255, 255, 0.25);
}


.cvp-shell :focus-visible { outline: 3px solid var(--cvp-primary); outline-offset: 3px; }
@media (prefers-reduced-motion: reduce) { .cvp-shell *, .cvp-shell *::before, .cvp-shell *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; } }


/* =====================================================================
 * Verification UI — centered, responsive presentation + result modal
 * ===================================================================== */
.cvp-shell,
.cvp-shell * {
    box-sizing: border-box;
}

.cvp-shell {
    width: 100%;
    max-width: 1180px;
    margin: 32px auto;
    padding: clamp(32px, 5vw, 64px) clamp(18px, 4vw, 48px);
    border-radius: clamp(20px, 3vw, 32px);
}

.cvp-verification-wrap {
    width: min(100%, 780px);
    margin: 0 auto;
}

.cvp-hero-card {
    display: block;
}

.cvp-hero-copy {
    width: 100%;
    max-width: 760px;
    margin: 0 auto 34px;
    text-align: center;
}

.cvp-hero-copy .cvp-badge {
    margin-bottom: 16px;
}

.cvp-hero-copy h2 {
    margin: 0 auto 14px;
    font-size: clamp(2rem, 5vw, 3.35rem);
    line-height: 1.08;
    letter-spacing: -0.035em;
    text-wrap: balance;
}

.cvp-hero-copy p {
    max-width: 660px;
    margin: 0 auto;
    font-size: clamp(.98rem, 1.7vw, 1.08rem);
    line-height: 1.7;
    color: rgba(255,255,255,.78);
}

.cvp-form-panel {
    width: 100%;
    max-width: 700px;
    margin: 0 auto;
    padding: clamp(22px, 4vw, 34px);
    border-radius: 26px;
}

.cvp-verification-form {
    width: 100%;
}

.cvp-field input,
.cvp-field select {
    min-height: 52px;
}

.cvp-submit-btn {
    min-height: 54px;
}

/* Result modal */
.cvp-verification-modal {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
    transition: opacity .22s ease, visibility .22s ease;
}

.cvp-verification-modal.is-open {
    visibility: visible;
    opacity: 1;
    pointer-events: auto;
}

.cvp-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(6, 10, 24, .72);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.cvp-modal-dialog {
    position: relative;
    z-index: 1;
    width: min(100%, 620px);
    max-height: min(90vh, 820px);
    overflow: auto;
    padding: 12px;
    border: 1px solid rgba(255,255,255,.2);
    border-radius: 30px;
    background: linear-gradient(145deg, rgba(255,255,255,.16), rgba(255,255,255,.08));
    box-shadow: 0 35px 100px rgba(0,0,0,.42);
    transform: translateY(18px) scale(.97);
    transition: transform .28s cubic-bezier(.16,1,.3,1);
}

.cvp-verification-modal.is-open .cvp-modal-dialog {
    transform: translateY(0) scale(1);
}

.cvp-modal-content {
    width: 100%;
}

.cvp-modal-content .cvp-glass-card {
    margin: 0;
    border-radius: 22px;
    box-shadow: none;
}

.cvp-modal-content .cvp-success-card {
    border-left: 0;
    border-top: 4px solid #22c55e;
}

.cvp-modal-content .cvp-failed-card {
    border-left: 0;
    border-top: 4px solid #ef4444;
}

.cvp-modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 3;
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    padding: 0;
    border: 1px solid rgba(255,255,255,.2);
    border-radius: 50%;
    background: rgba(10,15,30,.28);
    color: #fff;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    transition: transform .2s ease, background .2s ease, border-color .2s ease;
}

.cvp-modal-close:hover {
    transform: rotate(90deg);
    background: rgba(255,255,255,.14);
    border-color: rgba(255,255,255,.4);
}

.cvp-modal-close:focus-visible {
    outline: 3px solid #fff;
    outline-offset: 3px;
}

.cvp-modal-content .cvp-card-header {
    padding-right: 42px;
}

.cvp-modal-content .cvp-failed-title {
    padding-right: 36px;
}

.cvp-modal-content .cvp-retry-btn {
    min-width: 190px;
    min-height: 46px;
}

body.cvp-modal-open {
    overflow: hidden;
}

/* Keep the old inline result available to scripts/accessibility without
   allowing it to stretch the layout below the form. */
.cvp-result-card {
    display: none !important;
}

@media (max-width: 680px) {
    .cvp-shell {
        margin: 20px auto;
        padding: 30px 14px;
        border-radius: 20px;
    }

    .cvp-hero-copy {
        margin-bottom: 24px;
    }

    .cvp-hero-copy h2 {
        font-size: clamp(1.9rem, 10vw, 2.55rem);
    }

    .cvp-hero-copy p {
        font-size: .95rem;
        line-height: 1.6;
    }

    .cvp-form-panel {
        padding: 20px 16px;
        border-radius: 20px;
    }

    .cvp-verification-modal {
        padding: 12px;
    }

    .cvp-modal-dialog {
        max-height: 94vh;
        padding: 8px;
        border-radius: 24px;
    }

    .cvp-modal-close {
        top: 14px;
        right: 14px;
        width: 36px;
        height: 36px;
        font-size: 24px;
    }

    .cvp-modal-content .cvp-glass-card {
        padding: 24px 18px;
    }

    .cvp-modal-content .cvp-card-header {
        align-items: flex-start;
        padding-right: 34px;
    }

    .cvp-modal-content .cvp-company-brand {
        width: 100%;
    }

    .cvp-modal-content .cvp-company-title {
        max-width: 100%;
        overflow-wrap: anywhere;
    }
}

@media (prefers-reduced-motion: reduce) {
    .cvp-verification-modal,
    .cvp-modal-dialog,
    .cvp-modal-close {
        transition: none !important;
    }
}


/* Submit button loading treatment */
.cvp-submit-btn .cvp-loading {
    align-items: center;
    justify-content: center;
    gap: 9px;
}

.cvp-submit-btn.is-loading .cvp-loading {
    display: inline-flex;
}

.cvp-submit-btn.is-loading .cvp-loading::before {
    content: "";
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255,255,255,.4);
    border-top-color: #fff;
    border-radius: 50%;
    animation: cvpButtonSpin .7s linear infinite;
}

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

.cvp-result-actions {
    display: flex;
    justify-content: center;
    margin-top: 24px;
}

.cvp-success-close-btn {
    min-width: 210px;
}

.cvp-card-logo-fallback {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    flex: 0 0 42px;
    border-radius: 10px;
    background: rgba(255,255,255,.12);
    color: rgba(255,255,255,.9);
}
