/**
 * EGP B2B Registration Frontend Styles
 * 
 * Modern, responsive CSS for the B2B registration form
 * with accessibility and mobile-first approach.
 * 
 * @package EGP_B2B_Registration
 * @since 1.0.0
 */

/* ==========================================================================
   CSS Custom Properties (Variables)
   ========================================================================== */

:root {
    /* Colors */
    --egp-primary: #6b4ddc;
    --egp-primary-hover: #135e96;
    --egp-primary-light: #f0f6fc;
    --egp-secondary: #6c757d;
    --egp-success: #28a745;
    --egp-success-light: #d4edda;
    --egp-warning: #ffc107;
    --egp-warning-light: #fff3cd;
    --egp-error: #dc3545;
    --egp-error-light: #f8d7da;
    --egp-info: #17a2b8;
    --egp-info-light: #d1ecf1;

    /* Grays */
    --egp-white: #ffffff;
    --egp-gray-50: #f8f9fa;
    --egp-gray-100: #e9ecef;
    --egp-gray-200: #dee2e6;
    --egp-gray-300: #ced4da;
    --egp-gray-400: #adb5bd;
    --egp-gray-500: #6c757d;
    --egp-gray-600: #495057;
    --egp-gray-700: #343a40;
    --egp-gray-800: #212529;
    --egp-gray-900: #000000;

    /* Typography */
    --egp-font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --egp-font-size-base: 16px;
    --egp-font-size-sm: 14px;
    --egp-font-size-lg: 18px;
    --egp-font-size-xl: 20px;
    --egp-font-size-xxl: 24px;
    --egp-line-height-base: 1.5;
    --egp-font-weight-normal: 400;
    --egp-font-weight-medium: 500;
    --egp-font-weight-semibold: 600;
    --egp-font-weight-bold: 700;

    /* Spacing */
    --egp-spacing-xs: 0.25rem;
    --egp-spacing-sm: 0.5rem;
    --egp-spacing-md: 1rem;
    --egp-spacing-lg: 1.5rem;
    --egp-spacing-xl: 2rem;
    --egp-spacing-xxl: 3rem;

    /* Border radius */
    --egp-border-radius-sm: 4px;
    --egp-border-radius: 6px;
    --egp-border-radius-lg: 8px;
    --egp-border-radius-xl: 12px;

    /* Shadows */
    --egp-shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --egp-shadow: 0 1px 3px rgba(0, 0, 0, 0.1), 0 1px 2px rgba(0, 0, 0, 0.06);
    --egp-shadow-md: 0 4px 6px rgba(0, 0, 0, 0.07), 0 2px 4px rgba(0, 0, 0, 0.06);
    --egp-shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1), 0 4px 6px rgba(0, 0, 0, 0.05);
    --egp-shadow-xl: 0 20px 25px rgba(0, 0, 0, 0.1), 0 10px 10px rgba(0, 0, 0, 0.04);

    /* Transitions */
    --egp-transition-fast: 150ms ease-in-out;
    --egp-transition-base: 250ms ease-in-out;
    --egp-transition-slow: 350ms ease-in-out;

    /* Z-index */
    --egp-z-dropdown: 1000;
    --egp-z-sticky: 1020;
    --egp-z-fixed: 1030;
    --egp-z-modal-backdrop: 1040;
    --egp-z-modal: 1050;
    --egp-z-popover: 1060;
    --egp-z-tooltip: 1070;
}

/* ==========================================================================
   Base Styles
   ========================================================================== */

.egp-b2b-registration-wrapper {
    font-family: var(--egp-font-family);
    font-size: var(--egp-font-size-base);
    line-height: var(--egp-line-height-base);
    color: var(--egp-gray-800);
    max-width: 800px;
    margin: 0 auto;
    padding: var(--egp-spacing-lg);
    background: var(--egp-white);
    border-radius: var(--egp-border-radius-lg);
    box-shadow: var(--egp-shadow-lg);
    position: relative;
}

.egp-b2b-registration-wrapper * {
    box-sizing: border-box;
}

/* ==========================================================================
   Header
   ========================================================================== */

.egp-b2b-registration-header {
    text-align: center;
    margin-bottom: var(--egp-spacing-xl);
    padding-bottom: var(--egp-spacing-lg);
    border-bottom: 2px solid var(--egp-gray-100);
}

.egp-b2b-registration-title {
    font-size: var(--egp-font-size-xxl);
    font-weight: var(--egp-font-weight-bold);
    color: var(--egp-primary);
    margin: 0 0 var(--egp-spacing-sm) 0;
}

.egp-b2b-registration-subtitle {
    color: var(--egp-gray-600);
    margin-bottom: var(--egp-spacing-md);
}

#egp-b2b-registration-wrapper {
    max-width: 670px !important;
}

.egp-b2b-required-notice {
    font-size: var(--egp-font-size-sm);
    color: var(--egp-gray-500);
    font-style: italic;
    margin: 0;
}

.required-asterisk {
    color: var(--egp-error);
    font-weight: var(--egp-font-weight-bold);
}


#vat-info-box {
    display: none !important;
}

/* ==========================================================================
   Progress Indicator
   ========================================================================== */

.egp-b2b-progress-indicator {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--egp-spacing-xl);
    padding: var(--egp-spacing-md) 0;
    position: relative;
}

.egp-b2b-progress-indicator::before {
    content: '';
    position: absolute;
    left: 60px;
    right: 60px;
    height: 2px;
    background: var(--egp-gray-200);
    z-index: 3;
    top: 40px;
    transform: translateY(-50%);
}

.progress-line-fill {
    position: absolute;
    top: 50%;
    opacity: 0;
    left: 60px;
    right: 60px;
    height: 2px;
    background: var(--egp-success);
    z-index: 2;
    width: 0%;
    transition: width var(--egp-transition-base);
    transform: translateY(-50%);
    transform-origin: left center;
}

.progress-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    z-index: 3;
    background: transparent;
    padding: 0 var(--egp-spacing-xs);
    min-width: 80px;
    flex: 1;
}

.step-number {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--egp-gray-200);
    color: var(--egp-gray-500);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: var(--egp-font-weight-semibold);
    font-size: var(--egp-font-size-sm);
    margin-bottom: var(--egp-spacing-xs);
    transition: all var(--egp-transition-base);
    position: relative;
}

.step-label {
    font-size: var(--egp-font-size-sm);
    color: var(--egp-gray-500);
    text-align: center;
    font-weight: var(--egp-font-weight-medium);
    transition: color var(--egp-transition-base);
}

.progress-step.active .step-number {
    background: var(--egp-primary);
    color: var(--egp-white);
    transform: scale(1.1);
}

.progress-step.active .step-label {
    color: var(--egp-primary);
    font-weight: var(--egp-font-weight-semibold);
}

.progress-step.completed .step-number {
    background: var(--egp-success);
    color: var(--egp-white);
    font-size: var(--egp-font-size-lg);
}

.progress-step.completed .step-number::before {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-weight: bold;
    font-size: 18px;
}

.progress-step.completed .step-number span {
    opacity: 0;
    visibility: hidden;
}

.progress-step.completed .step-label {
    color: var(--egp-success);
    font-weight: var(--egp-font-weight-semibold);
}

/* Highlight effect when scrolling to progress */
.egp-b2b-progress-highlight {
    animation: egp-progress-highlight 1s ease-out;
}

@keyframes egp-progress-highlight {
    0% {
        background-color: transparent;
        box-shadow: none;
    }

    50% {
        background-color: var(--egp-primary-light);
        box-shadow: 0 0 0 4px var(--egp-primary-light);
        border-radius: var(--egp-border-radius);
    }

    100% {
        background-color: transparent;
        box-shadow: none;
    }
}

/* ==========================================================================
   Messages
   ========================================================================== */

.egp-b2b-messages {
    margin-bottom: var(--egp-spacing-lg);
    padding: var(--egp-spacing-md);
    border-radius: var(--egp-border-radius);
    border: 1px solid;
    position: relative;
    display: flex;
    align-items: flex-start;
    gap: var(--egp-spacing-sm);
}

.egp-b2b-messages.egp-b2b-message-success {
    background: var(--egp-success-light);
    border-color: var(--egp-success);
    color: var(--egp-success);
}

.egp-b2b-messages.egp-b2b-message-error {
    background: var(--egp-error-light);
    border-color: var(--egp-error);
    color: var(--egp-error);
}

.egp-b2b-messages.egp-b2b-message-warning {
    background: var(--egp-warning-light);
    border-color: var(--egp-warning);
    color: var(--egp-warning);
}

.egp-b2b-messages.egp-b2b-message-info {
    background: var(--egp-info-light);
    border-color: var(--egp-info);
    color: var(--egp-info);
}

.message-content {
    flex: 1;
    margin: 0;
}

.message-close {
    background: none;
    border: none;
    font-size: var(--egp-font-size-lg);
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--egp-border-radius-sm);
    transition: background-color var(--egp-transition-fast);
}

.message-close:hover {
    background: rgba(0, 0, 0, 0.1);
}

/* ==========================================================================
   Form Styles
   ========================================================================== */

.egp-b2b-form {
    position: relative;
}

.egp-b2b-form-step {
    display: none;
}

.egp-b2b-form-step.active {
    display: block;
    animation: fadeInUp 0.3s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.egp-b2b-fieldset {
    border: none;
    margin: 0;
    padding: 0;
    margin-bottom: var(--egp-spacing-xl);
}

.egp-b2b-legend {
    font-size: var(--egp-font-size-xl);
    font-weight: var(--egp-font-weight-semibold);
    color: var(--egp-gray-800);
    margin-bottom: var(--egp-spacing-lg);
    padding: 0;
    display: flex;
    align-items: center;
    gap: var(--egp-spacing-sm);
}

.legend-number {
    width: 32px;
    height: 32px;
    background: var(--egp-primary);
    color: var(--egp-white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--egp-font-size-sm);
    font-weight: var(--egp-font-weight-bold);
}

/* ==========================================================================
   Form Fields
   ========================================================================== */

.egp-b2b-field {
    margin-bottom: var(--egp-spacing-lg);
    position: relative;
}

.egp-b2b-field-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--egp-spacing-md);
    margin-bottom: var(--egp-spacing-lg);
}

.egp-b2b-field-col {
    position: relative;
}

.egp-b2b-label {
    display: block;
    font-weight: var(--egp-font-weight-medium);
    color: var(--egp-gray-700);
    margin-bottom: var(--egp-spacing-xs);
    font-size: var(--egp-font-size-base);
}

.egp-b2b-input,
.egp-b2b-select {
    width: 100%;
    padding: var(--egp-spacing-sm) var(--egp-spacing-md);
    border: 2px solid var(--egp-gray-300);
    border-radius: var(--egp-border-radius);
    font-size: var(--egp-font-size-base);
    font-family: inherit;
    background: var(--egp-white);
    transition: all var(--egp-transition-base);
    appearance: none;
}

.egp-b2b-input:focus,
.egp-b2b-select:focus {
    outline: none;
    border-color: var(--egp-primary);
    box-shadow: 0 0 0 3px rgba(34, 113, 177, 0.1);
}

.egp-b2b-input:hover,
.egp-b2b-select:hover {
    border-color: var(--egp-gray-400);
}

.egp-b2b-input::placeholder {
    color: var(--egp-gray-400);
}

/* Select dropdown arrow */
.egp-b2b-select {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3e%3c/svg%3e");
    background-position: right var(--egp-spacing-sm) center;
    background-repeat: no-repeat;
    background-size: 1.5em 1.5em;
    padding-right: 2.5rem;
}

/* Field States */
.egp-b2b-input.egp-b2b-field-error-state,
.egp-b2b-select.egp-b2b-field-error-state {
    border-color: var(--egp-error);
    background-color: var(--egp-error-light);
}

.egp-b2b-input.egp-b2b-field-error-state:focus,
.egp-b2b-select.egp-b2b-field-error-state:focus {
    box-shadow: 0 0 0 3px rgba(220, 53, 69, 0.1);
}

.egp-b2b-input.egp-b2b-field-success-state,
.egp-b2b-select.egp-b2b-field-success-state {
    border-color: var(--egp-success);
    background-color: var(--egp-success-light);
}

.egp-b2b-input.egp-b2b-field-success-state:focus,
.egp-b2b-select.egp-b2b-field-success-state:focus {
    box-shadow: 0 0 0 3px rgba(40, 167, 69, 0.1);
}

/* Auto-generated field state */
.egp-b2b-input.auto-generated {
    border-color: var(--egp-info);
    background-color: var(--egp-info-light);
    position: relative;
}

.egp-b2b-input.auto-generated:focus {
    box-shadow: 0 0 0 3px rgba(23, 162, 184, 0.1);
}

/* Auto-generated field hint */
.egp-b2b-field-hint {
    display: none;
    font-size: var(--egp-font-size-sm);
    color: var(--egp-info);
    margin-top: var(--egp-spacing-xs);
    font-style: italic;
}

.egp-b2b-field-hint.show {
    display: block;
}

/* ==========================================================================
   Field Feedback
   ========================================================================== */

.egp-b2b-field-feedback {
    margin-top: var(--egp-spacing-xs);
    min-height: 20px;
    display: flex;
    align-items: center;
    gap: var(--egp-spacing-xs);
}

.egp-b2b-field-error,
.egp-b2b-field-success {
    font-size: var(--egp-font-size-sm);
    font-weight: var(--egp-font-weight-medium);
    display: none;
}

.egp-b2b-field-error {
    color: var(--egp-error);
}

.egp-b2b-field-success {
    color: var(--egp-success);
}

.egp-b2b-field-error:not(:empty),
.egp-b2b-field-success:not(:empty) {
    display: block;
}

.egp-b2b-field-loading {
    display: none;
    align-items: center;
    gap: var(--egp-spacing-xs);
    font-size: var(--egp-font-size-sm);
    color: var(--egp-gray-500);
}

.egp-b2b-field-loading.show {
    display: flex;
}

.egp-b2b-field-help {
    font-size: var(--egp-font-size-sm);
    color: var(--egp-gray-500);
    margin-top: var(--egp-spacing-xs);
    line-height: 1.4;
}

/* ==========================================================================
   Password Strength Indicator
   ========================================================================== */

.egp-b2b-password-strength {
    margin-top: var(--egp-spacing-xs);
}

.strength-bar {
    height: 4px;
    background: var(--egp-gray-200);
    border-radius: 2px;
    overflow: hidden;
    margin-bottom: var(--egp-spacing-xs);
}

.strength-fill {
    height: 100%;
    width: 0%;
    transition: all var(--egp-transition-base);
    border-radius: 2px;
}

.strength-fill.strength-1 {
    background: var(--egp-error);
}

.strength-fill.strength-2 {
    background: var(--egp-warning);
}

.strength-fill.strength-3 {
    background: var(--egp-info);
}

.strength-fill.strength-4 {
    background: var(--egp-success);
}

.strength-text {
    font-size: var(--egp-font-size-sm);
    font-weight: var(--egp-font-weight-medium);
}

.edit-entries-wrapper button {
    text-decoration: none !important;
    border: 1px solid;
    padding: 10px 24px;
    border-radius: 40px;
}

/* legend.egp-b2b-legend {
    width: 100%;
    text-align: center;
    justify-content: center;
}

div#registration-summary h4 {
    text-align: center;
} */

/* ==========================================================================
   Checkboxes
   ========================================================================== */

.egp-b2b-checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: var(--egp-spacing-sm);
    cursor: pointer;
    font-size: var(--egp-font-size-base);
    line-height: 1.4;
    margin-bottom: var(--egp-spacing-sm);
}

.egp-b2b-checkbox-label input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.egp-b2b-checkmark {
    width: 20px;
    height: 20px;
    border: 2px solid var(--egp-gray-300);
    border-radius: var(--egp-border-radius-sm);
    background: var(--egp-white);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--egp-transition-base);
    flex-shrink: 0;
    margin-top: 2px;
}

.egp-b2b-checkbox-label:hover .egp-b2b-checkmark {
    border-color: var(--egp-primary);
}

.egp-b2b-checkbox-label input[type="checkbox"]:checked+.egp-b2b-checkmark {
    background: var(--egp-primary);
    border-color: var(--egp-primary);
}

.egp-b2b-checkbox-label input[type="checkbox"]:checked+.egp-b2b-checkmark::after {
    content: '✓';
    color: var(--egp-white);
    font-size: 12px;
    font-weight: var(--egp-font-weight-bold);
}

.egp-b2b-checkbox-label input[type="checkbox"]:focus+.egp-b2b-checkmark {
    box-shadow: 0 0 0 3px rgba(34, 113, 177, 0.1);
}

.checkbox-text {
    flex: 1;
}

.checkbox-text a {
    color: var(--egp-primary);
    text-decoration: none;
}

.checkbox-text a:hover {
    text-decoration: underline;
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.egp-b2b-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--egp-spacing-xs);
    padding: var(--egp-spacing-sm) var(--egp-spacing-lg);
    border: 2px solid transparent;
    border-radius: var(--egp-border-radius);
    font-size: var(--egp-font-size-base);
    font-weight: var(--egp-font-weight-medium);
    font-family: inherit;
    text-decoration: none;
    cursor: pointer;
    transition: all var(--egp-transition-base);
    min-height: 44px;
    position: relative;
    overflow: hidden;
}

.egp-b2b-btn:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(34, 113, 177, 0.2);
}

.egp-b2b-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    pointer-events: none;
}

.egp-b2b-btn-primary {
    background: var(--egp-primary) !important;
    color: var(--egp-white);
    border-color: var(--egp-primary);
}

.egp-b2b-form-step.active[data-step="1"] .egp-b2b-step-navigation {
    justify-content: center;
    align-items: center;
}

.egp-b2b-btn-primary:hover:not(:disabled) {
    background: var(--egp-primary-hover);
    border-color: var(--egp-primary-hover);
    transform: translateY(-1px);
    box-shadow: var(--egp-shadow-md);
}

.egp-b2b-btn-secondary {
    background: var(--egp-white);
    color: var(--egp-gray-700);
    border-color: var(--egp-gray-300);
}

.egp-b2b-btn-secondary:hover:not(:disabled) {
    background: var(--egp-gray-50);
    border-color: var(--egp-gray-400);
}

.egp-b2b-btn-link {
    background: none;
    color: var(--egp-primary);
    border: none;
    padding: var(--egp-spacing-xs) 0;
    text-decoration: underline;
    min-height: auto;
}

.egp-b2b-btn-link:hover {
    color: var(--egp-primary-hover);
}

.edit-entries-wrapper {
    text-align: center;
    margin-top: 18px;
}

.btn-icon {
    font-size: var(--egp-font-size-sm);
}

/* ==========================================================================
   Step Navigation
   ========================================================================== */

.egp-b2b-step-navigation {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: var(--egp-spacing-xl);
    padding-top: var(--egp-spacing-lg);
    border-top: 1px solid var(--egp-gray-200);
}

.egp-b2b-step-navigation .egp-b2b-btn {
    min-width: 120px;
}

/* ==========================================================================
   Info Boxes
   ========================================================================== */

.egp-b2b-info-box {
    display: flex;
    align-items: flex-start;
    gap: var(--egp-spacing-sm);
    padding: var(--egp-spacing-md);
    background: var(--egp-info-light);
    border: 1px solid var(--egp-info);
    border-radius: var(--egp-border-radius);
    margin: var(--egp-spacing-md) 0;
}

.info-icon {
    width: 20px;
    height: 20px;
    background: var(--egp-info);
    color: var(--egp-white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--egp-font-size-sm);
    font-weight: var(--egp-font-weight-bold);
    flex-shrink: 0;
}

.info-content h4 {
    margin: 0 0 var(--egp-spacing-xs) 0;
    font-size: var(--egp-font-size-base);
    font-weight: var(--egp-font-weight-semibold);
    color: var(--egp-info);
}

.info-content p {
    margin: 0;
    font-size: var(--egp-font-size-sm);
    color: var(--egp-gray-700);
}

/* ==========================================================================
   Summary
   ========================================================================== */

.egp-b2b-summary {
    background: var(--egp-gray-50);
    border: 1px solid var(--egp-gray-200);
    border-radius: var(--egp-border-radius);
    padding: var(--egp-spacing-lg);
    margin-bottom: var(--egp-spacing-lg);
}

.egp-b2b-summary h4 {
    margin: 0 0 var(--egp-spacing-md) 0;
    font-size: var(--egp-font-size-lg);
    font-weight: var(--egp-font-weight-semibold);
    color: var(--egp-gray-800);
}

.summary-grid {
    display: grid;
    gap: var(--egp-spacing-sm);
}

legend.egp-b2b-legend .legend-number {
    display: none;
}

.summary-list {
    display: flex;
    flex-direction: column;
    gap: var(--egp-spacing-md);
}

.summary-item {
    display: flex;
    flex-direction: column;
    gap: var(--egp-spacing-xs);
    padding: var(--egp-spacing-sm);
    background: var(--egp-white);
    border: 1px solid var(--egp-gray-200);
    border-radius: var(--egp-border-radius);
}

.summary-item:last-child {
    border-bottom: 1px solid var(--egp-gray-200);
}

.summary-label {
    color: var(--egp-gray-600);
    font-weight: var(--egp-font-weight-medium);
    font-size: var(--egp-font-size-sm);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.summary-value {
    color: var(--egp-gray-800);
    font-weight: var(--egp-font-weight-medium);
    font-size: var(--egp-font-size-base);
}

/* Legacy support for grid layout */
.summary-item strong {
    color: var(--egp-gray-700);
    font-weight: var(--egp-font-weight-medium);
}

/* ==========================================================================
   Agreements
   ========================================================================== */

.egp-b2b-agreements {
    background: var(--egp-gray-50);
    border: 1px solid var(--egp-gray-200);
    border-radius: var(--egp-border-radius);
    padding: var(--egp-spacing-lg);
    margin-bottom: var(--egp-spacing-lg);
    padding-bottom: 0;
}

/* ==========================================================================
   Success Message
   ========================================================================== */

.egp-b2b-success-wrapper {
    text-align: center;
    padding: var(--egp-spacing-xxl) var(--egp-spacing-lg);
}

.egp-b2b-success-content {
    max-width: 500px;
    margin: 0 auto;
}

.success-icon {
    width: 80px;
    height: 80px;
    background: var(--egp-success);
    color: var(--egp-white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 40px;
    margin: 0 auto var(--egp-spacing-lg) auto;
    animation: successPulse 0.6s ease-out;
}

@keyframes successPulse {
    0% {
        transform: scale(0);
    }

    50% {
        transform: scale(1.1);
    }

    100% {
        transform: scale(1);
    }
}

.egp-b2b-message.egp-b2b-message-info {
    text-align: center !important;
}

.egp-b2b-success-content h3 {
    font-size: var(--egp-font-size-xl);
    font-weight: var(--egp-font-weight-bold);
    color: var(--egp-success);
    margin: 0 0 var(--egp-spacing-md) 0;
}

.egp-b2b-success-content p {
    color: var(--egp-gray-600);
    margin-bottom: var(--egp-spacing-lg);
}

.success-actions {
    display: flex;
    gap: var(--egp-spacing-md);
    justify-content: center;
    flex-wrap: wrap;
}

/* ==========================================================================
   Loading States
   ========================================================================== */

.egp-b2b-loading-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: var(--egp-z-modal);
    border-radius: var(--egp-border-radius-lg);
}

.loading-content {
    text-align: center;
    color: var(--egp-gray-600);
}

.loading-content p {
    margin: var(--egp-spacing-md) 0 0 0;
    font-weight: var(--egp-font-weight-medium);
}

/* Spinners */
.egp-b2b-spinner,
.egp-b2b-spinner-large {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid var(--egp-gray-300);
    border-radius: 50%;
    border-top-color: var(--egp-primary);
    animation: spin 1s ease-in-out infinite;
}

.egp-b2b-spinner-large {
    width: 40px;
    height: 40px;
    border-width: 4px;
}

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

.spinner {
    width: 16px;
    height: 16px;
    border: 2px solid var(--egp-gray-300);
    border-top: 2px solid var(--egp-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

/* ==========================================================================
   Accessibility
   ========================================================================== */

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Focus indicators */
.egp-b2b-form *:focus {
    outline: 2px solid var(--egp-primary);
    outline-offset: 2px;
}

.egp-b2b-form input:focus,
.egp-b2b-form select:focus,
.egp-b2b-form button:focus {
    outline: none;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    :root {
        --egp-primary: #0000ff;
        --egp-error: #ff0000;
        --egp-success: #008000;
        --egp-gray-300: #666666;
        --egp-gray-700: #000000;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

p.egp-b2b-required-notice {
    display: none;
}

.egp-marketing-checkbox {
    display: none;
}

/* ==========================================================================
   Responsive Design
   ========================================================================== */

/* Mobile First Approach */

@media (max-width: 633px) {
    .egp-b2b-progress-indicator .step-label {
        opacity: 0;
    }

    .egp-b2b-progress-indicator span.step-label {
        display: none;
    }
}

/* Small devices (landscape phones, 576px and up) */
@media (max-width: 575.98px) {

    .egp-b2b-progress-indicator::before {
        top: 25px !important;
    }

    .egp-b2b-registration-wrapper {
        margin: 0;
        padding: var(--egp-spacing-md);
        border-radius: 0;
        box-shadow: none;
        min-height: 100vh;
    }

    .egp-b2b-registration-title {
        font-size: var(--egp-font-size-xl);
    }

    .egp-b2b-field-row {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .egp-b2b-progress-indicator {
        flex-wrap: nowrap;
        gap: var(--egp-spacing-xs);
        padding: var(--egp-spacing-sm) 0;
    }

    .egp-b2b-progress-indicator::before {
        left: 40px;
        right: 40px;
    }

    .progress-line-fill {
        left: 40px;
    }

    .progress-step {
        min-width: 60px;
        padding: 0 var(--egp-spacing-xs);
    }

    .step-number {
        width: 32px;
        height: 32px;
        font-size: 12px;
    }

    .step-label {
        font-size: 11px;
        line-height: 1.2;
    }

    .egp-b2b-step-navigation {
        flex-direction: column;
        gap: var(--egp-spacing-md);
    }

    .egp-b2b-step-navigation .egp-b2b-btn {
        width: 100%;
        min-width: auto;
    }

    .success-actions {
        flex-direction: column;
    }

    .success-actions .egp-b2b-btn {
        width: 100%;
    }
}

/* Medium devices (tablets, 768px and up) */
@media (min-width: 576px) and (max-width: 767.98px) {
    .egp-b2b-registration-wrapper {
        padding: var(--egp-spacing-lg);
    }

    .egp-b2b-field-row {
        grid-template-columns: 1fr 1fr;
    }

    .egp-b2b-progress-indicator::before {
        left: 50px;
        right: 50px;
    }

    .progress-line-fill {
        left: 50px;
        right: 50px;
    }
}

/* Large devices (desktops, 992px and up) */
@media (min-width: 768px) {
    .egp-b2b-registration-wrapper {
        padding: var(--egp-spacing-xl);
    }

    .egp-b2b-field-row {
        grid-template-columns: 1fr 1fr;
    }

    .egp-b2b-progress-indicator::before {
        left: 60px;
        right: 60px;
    }

    .progress-line-fill {
        left: 60px;
        right: 60px;
    }

    .summary-grid {
        grid-template-columns: 1fr 1fr;
    }

    .summary-list {
        gap: var(--egp-spacing-sm);
    }

    .summary-item {
        padding: var(--egp-spacing-xs) var(--egp-spacing-sm);
    }
}

/* Extra large devices (large desktops, 1200px and up) */
@media (min-width: 992px) {
    .egp-b2b-registration-wrapper {
        max-width: 900px;
    }
}

/* ==========================================================================
   Print Styles
   ========================================================================== */

@media print {
    .egp-b2b-registration-wrapper {
        box-shadow: none;
        border: 1px solid var(--egp-gray-300);
    }

    .egp-b2b-btn,
    .egp-b2b-loading-overlay,
    .egp-b2b-progress-indicator {
        display: none !important;
    }

    .egp-b2b-form-step {
        display: block !important;
    }

    .egp-b2b-form-step:not(:last-child) {
        page-break-after: always;
    }
}

/* ==========================================================================
   Dark Mode Support (Optional)
   ========================================================================== */

@media (prefers-color-scheme: dark) {
    :root {
        --egp-white: #1a1a1a;
        --egp-gray-50: #2d2d2d;
        --egp-gray-100: #3a3a3a;
        --egp-gray-200: #4a4a4a;
        --egp-gray-300: #5a5a5a;
        --egp-gray-400: #6a6a6a;
        --egp-gray-500: #8a8a8a;
        --egp-gray-600: #a0a0a0;
        --egp-gray-700: #c0c0c0;
        --egp-gray-800: #e0e0e0;
        --egp-gray-900: #ffffff;
    }

    .egp-b2b-registration-wrapper {
        background: var(--egp-white);
        color: var(--egp-gray-800);
    }

    .egp-b2b-input,
    .egp-b2b-select {
        background: var(--egp-gray-50);
        color: var(--egp-gray-800);
    }
}