html, body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f8fafc;
    color: #1e293b;
}

/* Page layout */
.cv-page {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Header */
.cv-header {
    background: white;
    border-bottom: 1px solid #e2e8f0;
    padding: 16px 0;
}

.cv-header-inner {
    max-width: 640px;
    margin: 0 auto;
    padding: 0 24px;
}

.cv-logo {
    height: 48px;
    width: auto;
}

/* Body */
.cv-body {
    flex: 1;
    max-width: 640px;
    width: 100%;
    margin: 0 auto;
    padding: 24px 24px 40px;
}

/* Reference number */
.cv-reference {
    text-align: center;
    color: #64748b;
    font-size: 0.875rem;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.cv-ref-icon {
    opacity: 0.6;
}

/* Deadline banner */
.cv-deadline-banner {
    background: linear-gradient(135deg, #ecfdf5, #f0fdfa);
    border: 1px solid #a7f3d0;
    border-radius: 12px;
    padding: 16px 20px;
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 24px;
}

.cv-deadline-icon {
    flex-shrink: 0;
}

.cv-deadline-title {
    font-weight: 700;
    font-size: 1rem;
    color: #0f172a;
}

.cv-deadline-sub {
    font-size: 0.85rem;
    color: #0d9488;
    margin-top: 2px;
}

/* Main card */
.cv-card {
    background: white;
    border-radius: 16px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06), 0 4px 16px rgba(0,0,0,0.04);
    padding: 32px 28px;
    margin-bottom: 24px;
}

.cv-person-icon {
    width: 48px;
    height: 48px;
    background: #0ea5e9;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

.cv-person-icon--bank {
    background: #0d9488;
}

.cv-card-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 10px;
    outline: none;
}

.cv-card-description {
    font-size: 0.95rem;
    color: #475569;
    line-height: 1.6;
    margin: 0 0 24px;
}

/* Accepted offer box */
.cv-offer-box {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 16px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 28px;
}

.cv-offer-label {
    font-size: 0.875rem;
    color: #64748b;
}

.cv-offer-status {
    font-size: 0.8rem;
    color: #0d9488;
    margin-top: 2px;
}

.cv-offer-amount {
    font-size: 1.5rem;
    font-weight: 700;
    color: #0f172a;
}

/* Section title */
.cv-section-title {
    font-size: 0.95rem;
    font-weight: 600;
    font-style: italic;
    color: #334155;
    margin: 0 0 16px;
}

/* Requirement rows */
.cv-requirement {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    background: #f8fafc;
    border-radius: 10px;
    margin-bottom: 10px;
}

.cv-requirement-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    background: #eff6ff;
}

.cv-requirement-title {
    font-weight: 600;
    font-size: 0.9rem;
    color: #0f172a;
}

.cv-requirement-sub {
    font-size: 0.8rem;
    color: #64748b;
    margin-top: 2px;
}

/* Info box */
.cv-info-box {
    background: #f0f9ff;
    border-radius: 12px;
    padding: 16px 18px;
    display: flex;
    gap: 12px;
    margin-top: 20px;
    margin-bottom: 28px;
}

.cv-info-icon {
    flex-shrink: 0;
    margin-top: 2px;
}

.cv-info-title {
    font-weight: 700;
    font-size: 0.875rem;
    color: #0f172a;
    margin-bottom: 4px;
}

.cv-info-text {
    font-size: 0.82rem;
    color: #475569;
    line-height: 1.55;
}

.cv-error-box {
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 12px;
    padding: 14px 16px;
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
    color: #dc2626;
    font-size: 0.875rem;
    font-weight: 500;
}

/* CTA button */
.cv-cta-button {
    width: 100%;
    padding: 14px 24px;
    background: linear-gradient(135deg, #0ea5e9, #0284c7);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: background 0.2s, transform 0.1s;
}

.cv-cta-button:hover {
    background: linear-gradient(135deg, #0284c7, #0369a1);
}

.cv-cta-button:active {
    transform: scale(0.99);
}

.cv-cta-button:disabled {
    background: linear-gradient(135deg, #94a3b8, #64748b);
    cursor: not-allowed;
    opacity: 0.7;
}

.cv-cta-button:disabled:hover {
    background: linear-gradient(135deg, #94a3b8, #64748b);
}

.cv-cta-button:disabled:active {
    transform: none;
}

/* Half-width CTA (for button rows) */
.cv-cta-button--half {
    flex: 1;
}

/* Back button */
.cv-back-button {
    flex: 1;
    padding: 14px 24px;
    background: white;
    color: #334155;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: background 0.2s;
}

.cv-back-button:hover {
    background: #f8fafc;
}

/* Button row */
.cv-button-row {
    display: flex;
    gap: 12px;
    margin-top: 28px;
}

/* ID type selection */
.cv-id-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 20px;
}

.cv-id-option {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 18px;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    cursor: pointer;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.cv-id-option:hover {
    border-color: #cbd5e1;
}

.cv-id-option--selected {
    border-color: #0ea5e9;
    box-shadow: 0 0 0 1px #0ea5e9;
}

.cv-id-option-icon {
    width: 40px;
    height: 40px;
    background: #f0f9ff;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.cv-id-option-text {
    flex: 1;
}

.cv-id-option-title {
    font-weight: 600;
    font-size: 0.95rem;
    color: #0f172a;
}

.cv-id-option-sub {
    font-size: 0.8rem;
    color: #64748b;
    margin-top: 2px;
}

.cv-id-option-radio {
    flex-shrink: 0;
}

.cv-radio {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: 2px solid #cbd5e1;
    transition: border-color 0.2s;
}

.cv-radio--checked {
    border-color: #0ea5e9;
    border-width: 6px;
}

/* Form elements */
.cv-form-group {
    margin-bottom: 20px;
}

.cv-label {
    display: block;
    font-weight: 600;
    font-size: 0.9rem;
    color: #0f172a;
    margin-bottom: 6px;
}

.cv-input {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    font-size: 0.95rem;
    color: #1e293b;
    background: white;
    transition: border-color 0.2s, box-shadow 0.2s;
    box-sizing: border-box;
}

.cv-input::placeholder {
    color: #94a3b8;
}

.cv-input:focus {
    outline: none;
    border-color: #0ea5e9;
    box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.1);
}

.cv-input.invalid,
.cv-input.modified.invalid {
    border-color: #ef4444;
}

.cv-input.modified.valid {
    border-color: #10b981;
}

.cv-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 36px;
}

.cv-form-hint {
    font-size: 0.8rem;
    color: #64748b;
    margin-top: 4px;
}

.cv-validation {
    color: #ef4444;
    font-size: 0.8rem;
    margin-top: 4px;
}

/* Security note */
.cv-security-note {
    text-align: center;
    color: #64748b;
    font-size: 0.82rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

/* Footer */
.cv-footer {
    background: white;
    border-top: 1px solid #e2e8f0;
    padding: 28px 24px;
    text-align: center;
    margin-top: auto;
}

.cv-footer-copyright {
    font-size: 0.82rem;
    color: #64748b;
    margin-bottom: 8px;
}

.cv-footer-links {
    font-size: 0.8rem;
}

.cv-footer-links a {
    color: #0ea5e9;
    text-decoration: none;
}

.cv-footer-links a:hover {
    text-decoration: underline;
}

.cv-footer-sep {
    color: #cbd5e1;
    margin: 0 6px;
}

/* QR code section - hidden on mobile, shown on desktop */
.cv-qr-section {
    display: none;
    margin-top: 24px;
    background: white;
    border-radius: 16px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06), 0 4px 16px rgba(0,0,0,0.04);
    padding: 24px;
    text-align: center;
}

@media (min-width: 768px) {
    .cv-qr-section {
        display: block;
    }
}

.cv-qr-card {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    text-align: left;
    margin-bottom: 20px;
}

.cv-qr-icon {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    background: #f0f9ff;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cv-qr-title {
    font-weight: 700;
    font-size: 0.95rem;
    color: #0f172a;
    margin-bottom: 4px;
}

.cv-qr-sub {
    font-size: 0.82rem;
    color: #64748b;
    line-height: 1.5;
}

.cv-qr-image img {
    width: 180px;
    height: 180px;
    border-radius: 8px;
}

/* Green CTA variant */
.cv-cta-button--green {
    background: linear-gradient(135deg, #10b981, #059669);
}

.cv-cta-button--green:hover {
    background: linear-gradient(135deg, #059669, #047857);
}

/* Review page */
.cv-review-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 24px;
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid #e2e8f0;
}

.cv-review-section-title {
    font-size: 1rem;
    font-weight: 700;
    color: #0f172a;
    margin: 0;
}

.cv-edit-button {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    background: white;
    font-size: 0.82rem;
    font-weight: 600;
    color: #334155;
    cursor: pointer;
    transition: background 0.2s;
}

.cv-edit-button:hover {
    background: #f8fafc;
}

.cv-review-rows {
    margin-bottom: 8px;
}

.cv-review-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid #f1f5f9;
}

.cv-review-row:last-child {
    border-bottom: none;
}

.cv-review-label {
    font-size: 0.85rem;
    color: #64748b;
}

.cv-review-value {
    font-size: 0.9rem;
    font-weight: 600;
    color: #0f172a;
    text-align: right;
}

/* Confirmation checkbox */
.cv-confirm-box {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 16px 18px;
    margin-top: 20px;
    margin-bottom: 20px;
}

.cv-confirm-label {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    cursor: pointer;
    font-size: 0.85rem;
    color: #334155;
    line-height: 1.5;
}

.cv-confirm-checkbox {
    margin-top: 2px;
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    accent-color: #0ea5e9;
}

/* Confirmation / All Done page */
.cv-card--centered {
    text-align: center;
}

.cv-card-title--centered {
    text-align: center;
}

.cv-card-description--centered {
    text-align: center;
}

.cv-success-icon {
    width: 56px;
    height: 56px;
    background: #ecfdf5;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
}

/* Timeline */
.cv-timeline {
    text-align: left;
    margin: 24px 0;
}

.cv-timeline-item {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 12px 0;
    border-bottom: 1px solid #f1f5f9;
}

.cv-timeline-item:last-child {
    border-bottom: none;
}

.cv-timeline-dot {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.cv-timeline-dot--done {
    background: #10b981;
}

.cv-timeline-dot--pending {
    background: #e0f2fe;
}

.cv-timeline-content {
    flex: 1;
}

.cv-timeline-title {
    font-weight: 600;
    font-size: 0.9rem;
    color: #0f172a;
}

.cv-timeline-sub {
    font-size: 0.8rem;
    color: #64748b;
    margin-top: 2px;
}

/* Info box centered variant */
.cv-info-box--centered {
    text-align: left;
}

/* Support button */
.cv-support-button {
    width: 100%;
    padding: 14px 24px;
    background: white;
    color: #334155;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: background 0.2s;
}

.cv-support-button:hover {
    background: #f8fafc;
}

/* Loading state */
.cv-loading {
    text-align: center;
    color: #64748b;
    font-size: 1rem;
    padding: 80px 24px;
}

/* Expired deadline banner variant */
.cv-deadline-banner--expired {
    background: linear-gradient(135deg, #fef2f2, #fff1f2);
    border-color: #fecaca;
}

.cv-deadline-title--expired {
    color: #dc2626;
}

.cv-deadline-sub--expired {
    color: #ef4444;
}

/* Blazor infrastructure */
.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5O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red."
    }

/* Help Modal */
.cv-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(15, 23, 42, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 16px;
    backdrop-filter: blur(4px);
}

.cv-modal {
    background: white;
    border-radius: 16px;
    max-width: 480px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.cv-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid #e2e8f0;
}

.cv-modal-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1e293b;
    margin: 0;
}

.cv-modal-close {
    background: none;
    border: none;
    padding: 8px;
    cursor: pointer;
    color: #64748b;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
}

.cv-modal-close:hover {
    background: #f1f5f9;
    color: #1e293b;
}

.cv-modal-body {
    padding: 24px;
}

.cv-modal-intro {
    color: #64748b;
    font-size: 0.9375rem;
    margin: 0 0 20px 0;
    line-height: 1.5;
}

.cv-contact-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.cv-contact-item {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 16px;
}

.cv-contact-country {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
}

.cv-contact-flag {
    font-size: 1.25rem;
}

.cv-contact-name {
    font-weight: 600;
    color: #1e293b;
    font-size: 0.9375rem;
}

.cv-contact-details {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-left: 32px;
}

.cv-contact-phone,
.cv-contact-email {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #0ea5e9;
    text-decoration: none;
    font-size: 0.875rem;
    transition: color 0.15s;
}

.cv-contact-phone:hover,
.cv-contact-email:hover {
    color: #0284c7;
}

.cv-contact-hours {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 20px;
    padding: 12px 16px;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 8px;
    color: #15803d;
    font-size: 0.875rem;
}

@media (max-width: 480px) {
    .cv-modal {
        max-height: 85vh;
        margin: 0;
    }

    .cv-contact-details {
        padding-left: 0;
    }
}

/* UK Help Modal Styles */
.cv-contact-item--uk {
    text-align: center;
    padding: 24px;
}

.cv-contact-section {
    margin-bottom: 20px;
}

.cv-contact-section:last-child {
    margin-bottom: 0;
}

.cv-contact-section-title {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-weight: 600;
    color: #1e293b;
    font-size: 0.9375rem;
    margin-bottom: 8px;
}

.cv-contact-phone--large,
.cv-contact-email--large {
    display: block;
    color: #0ea5e9;
    text-decoration: none;
    font-size: 1.25rem;
    font-weight: 600;
    transition: color 0.15s;
}

.cv-contact-phone--large:hover,
.cv-contact-email--large:hover {
    color: #0284c7;
}

/* EU Contact Table */
.cv-contact-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
    margin-bottom: 16px;
}

.cv-contact-table th {
    text-align: left;
    padding: 8px 12px;
    background: #f1f5f9;
    color: #64748b;
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.cv-contact-table td {
    padding: 10px 12px;
    border-bottom: 1px solid #e2e8f0;
    color: #1e293b;
}

.cv-contact-table tr:last-child td {
    border-bottom: none;
}

.cv-contact-table a {
    color: #0ea5e9;
    text-decoration: none;
}

.cv-contact-table a:hover {
    color: #0284c7;
    text-decoration: underline;
}
