/**
 * SimplyIN Payment - Success Page & Payment Processing Styles
 * Matches WooCommerce/PrestaShop design
 */

/* ============================================
   Payment Processing Modal (Checkout Page)
   ============================================ */

.simplyin-payment-processing-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.simplyin-payment-processing-overlay.active {
    opacity: 1;
    visibility: visible;
}

.simplyin-payment-processing-modal {
    background: #fff;
    border: 2px dashed #3b82f6;
    border-radius: 12px;
    padding: 32px;
    max-width: 420px;
    width: 90%;
    text-align: center;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

/* Header with logos */
.simplyin-processing-header {
    margin-bottom: 24px;
}

.simplyin-processing-title {
    font-size: 16px;
    font-weight: 500;
    color: #374151;
    margin: 0 0 16px 0;
}

.simplyin-processing-logos {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.simplyin-processing-logos img {
    height: 28px;
    object-fit: contain;
}

.simplyin-processing-logos .simplyin-logo-separator {
    font-size: 18px;
    color: #9ca3af;
    font-weight: 300;
}

/* Payment method box */
.simplyin-processing-method {
    background: #f8fafc;
    border: 2px solid #3b82f6;
    border-radius: 8px;
    padding: 16px 20px;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.simplyin-processing-method input[type="radio"] {
    width: 18px;
    height: 18px;
    accent-color: #3b82f6;
    margin: 0;
    pointer-events: none;
}

.simplyin-processing-method-info {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
}

.simplyin-processing-method-logo {
    width: 32px;
    height: 24px;
    object-fit: contain;
}

.simplyin-processing-method-name {
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
}

.simplyin-processing-method-check {
    color: #22c55e;
    font-size: 20px;
    font-weight: bold;
}

/* Status section */
.simplyin-processing-status {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    text-align: left;
    margin-bottom: 24px;
}

.simplyin-processing-status-icon {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
}

.simplyin-processing-status-icon svg {
    width: 24px;
    height: 24px;
}

/* Clock icon for waiting */
.simplyin-processing-status-icon.waiting svg {
    fill: #f59e0b;
}

/* Check icon for success */
.simplyin-processing-status-icon.success svg {
    fill: #22c55e;
}

/* X icon for error */
.simplyin-processing-status-icon.error svg {
    fill: #ef4444;
}

.simplyin-processing-status-text {
    flex: 1;
}

.simplyin-processing-main-message {
    font-size: 16px;
    font-weight: 500;
    color: #1f2937;
    margin: 0 0 4px 0;
    line-height: 1.4;
}

.simplyin-processing-sub-message {
    font-size: 14px;
    color: #6b7280;
    margin: 0;
    line-height: 1.4;
}

/* Spinner */
.simplyin-processing-spinner {
    display: flex;
    justify-content: center;
    margin-bottom: 16px;
}

.simplyin-spinner {
    width: 36px;
    height: 36px;
    border: 3px solid #e5e7eb;
    border-top-color: #3b82f6;
    border-radius: 50%;
    animation: simplyin-spin 1s linear infinite;
}

@keyframes simplyin-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Cancel button */
.simplyin-processing-actions {
    margin-top: 20px;
}

.simplyin-processing-cancel-btn {
    background: #fff;
    border: 1px solid #d1d5db;
    color: #374151;
    padding: 10px 24px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.simplyin-processing-cancel-btn:hover {
    background: #f9fafb;
    border-color: #9ca3af;
}

/* Hidden state */
.simplyin-processing-spinner.hidden,
.simplyin-processing-actions.hidden {
    display: none;
}

/* ============================================
   Success Page Status Box
   ============================================ */

.simplyin-payment-status {
    margin-bottom: 20px;
    margin-top: 20px;
    padding: 0;
    border-radius: 12px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.simplyin-payment-status-box {
    background: #fff;
    border: 2px solid #3b82f6;
    border-radius: 12px;
    padding: 24px;
    max-width: 420px;
}

/* Status header */
.simplyin-status-header {
    text-align: center;
    margin-bottom: 20px;
}

.simplyin-status-title {
    font-size: 16px;
    font-weight: 500;
    color: #374151;
    margin: 0 0 12px 0;
}

.simplyin-status-logos {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.simplyin-status-logos img {
    height: 24px;
    object-fit: contain;
}

.simplyin-status-logos .logo-separator {
    font-size: 16px;
    color: #9ca3af;
}

/* Payment method display */
.simplyin-status-method {
    background: #f8fafc;
    border: 2px solid #3b82f6;
    border-radius: 8px;
    padding: 14px 16px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.simplyin-status-method input[type="radio"] {
    width: 18px;
    height: 18px;
    accent-color: #3b82f6;
    margin: 0;
    cursor: default;
    flex-shrink: 0;
}

.simplyin-status-method-info {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
}

.simplyin-status-method-logo {
    height: 24px;
    width: auto;
    max-width: 48px;
    object-fit: contain;
}

.simplyin-status-method-name {
    font-size: 15px;
    font-weight: 600;
    color: #1f2937;
}

.simplyin-status-method-check {
    color: #22c55e;
    font-size: 18px;
    font-weight: bold;
}

/* Status content */
.simplyin-status-content {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 20px;
}

.simplyin-status-icon-wrapper {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
}

.simplyin-status-icon-wrapper svg {
    width: 24px;
    height: 24px;
}

.simplyin-status-messages {
    flex: 1;
}

.simplyin-status-main {
    font-size: 15px;
    font-weight: 500;
    color: #1f2937;
    margin: 0 0 4px 0;
    line-height: 1.4;
}

.simplyin-status-sub {
    font-size: 13px;
    color: #6b7280;
    margin: 0;
    line-height: 1.4;
}

/* Spinner in status box */
.simplyin-status-spinner {
    display: flex;
    justify-content: center;
}

.simplyin-status-spinner .simplyin-spinner {
    width: 32px;
    height: 32px;
}

.simplyin-status-spinner.hidden {
    display: none;
}

/* Status states */
.simplyin-payment-status-box.status-processing .simplyin-status-icon-wrapper svg {
    fill: #f59e0b;
}

.simplyin-payment-status-box.status-processing .simplyin-status-icon-wrapper svg path {
    fill: #f59e0b;
}

.simplyin-payment-status-box.status-success .simplyin-status-icon-wrapper svg {
    fill: #22c55e;
}

.simplyin-payment-status-box.status-success .simplyin-status-icon-wrapper svg path {
    fill: #22c55e;
}

.simplyin-payment-status-box.status-success .simplyin-status-sub {
    color: #22c55e;
}

.simplyin-payment-status-box.status-error .simplyin-status-icon-wrapper svg {
    fill: #ef4444;
}

.simplyin-payment-status-box.status-error .simplyin-status-icon-wrapper svg path {
    fill: #ef4444;
}

.simplyin-payment-status-box.status-error .simplyin-status-icon-wrapper svg circle {
    fill: #ef4444;
}

.simplyin-payment-status-box.status-error .simplyin-status-sub {
    color: #ef4444;
}

.simplyin-payment-status-box.status-warning .simplyin-status-icon-wrapper svg {
    fill: #f59e0b;
}

.simplyin-payment-status-box.status-warning .simplyin-status-icon-wrapper svg path {
    fill: #f59e0b;
}

/* ============================================
   Legacy Status Styles (fallback)
   ============================================ */

.simplyin-status-success {
    background-color: #d1fae5;
    border: 1px solid #10b981;
    color: #065f46;
    padding: 15px;
    border-radius: 8px;
}

.simplyin-status-warning {
    background-color: #fef3c7;
    border: 1px solid #f59e0b;
    color: #92400e;
    padding: 15px;
    border-radius: 8px;
}

.simplyin-status-info {
    background-color: #dbeafe;
    border: 1px solid #3b82f6;
    color: #1e40af;
    padding: 15px;
    border-radius: 8px;
}

.simplyin-status-success .simplyin-status-icon::before {
    content: "✓";
    color: #065f46;
    font-weight: bold;
    margin-right: 8px;
}

.simplyin-status-warning .simplyin-status-icon::before {
    content: "⚠";
    color: #92400e;
    margin-right: 8px;
}

.simplyin-status-info .simplyin-status-icon::before {
    content: "ℹ";
    color: #1e40af;
    margin-right: 8px;
}

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

@media (max-width: 480px) {
    .simplyin-payment-processing-modal {
        padding: 24px 20px;
        margin: 16px;
    }
    
    .simplyin-processing-title {
        font-size: 14px;
    }
    
    .simplyin-processing-logos img {
        height: 24px;
    }
    
    .simplyin-processing-method {
        padding: 14px 16px;
    }
    
    .simplyin-processing-method-name {
        font-size: 14px;
    }
    
    .simplyin-processing-main-message {
        font-size: 14px;
    }
    
    .simplyin-processing-sub-message {
        font-size: 13px;
    }
    
    .simplyin-payment-status-box {
        padding: 20px 16px;
    }
    
    .simplyin-status-main {
        font-size: 14px;
    }
    
    .simplyin-status-sub {
        font-size: 12px;
    }
}
