/**
 * BKN301 Checkout Styles
 *
 * @package BKN301_Paywall
 * @since 1.0.0
 */

#bkn301-iframe-container {
    margin: 20px 0;
    padding: 20px;
    background: #f9f9f9;
    border: 1px solid #ddd;
    border-radius: 4px;
}

#bkn301-payment-iframe {
    width: 100%;
    min-height: 400px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: white;
}

#bkn301-loading {
    text-align: center;
    padding: 40px;
    color: #666;
}

#bkn301-loading-overlay {
    position: fixed;
    inset: 0;
    z-index: 99998;
    background: rgba(255, 255, 255, 0.82);
    backdrop-filter: blur(2px);
}

.bkn301-overlay-content {
    position: absolute;
    top: 50%;
    left: 50%;
    width: min(420px, calc(100vw - 32px));
    transform: translate(-50%, -50%);
    padding: 32px 28px;
    background: #ffffff;
    border: 1px solid rgba(17, 24, 39, 0.08);
    border-radius: 18px;
    box-shadow: 0 24px 60px rgba(17, 24, 39, 0.14);
    text-align: center;
}

.bkn301-spinner {
    width: 56px;
    height: 56px;
    margin: 0 auto 18px;
    border: 3px solid #d7dde6;
    border-top-color: #1d4ed8;
    border-radius: 50%;
    animation: bkn301-spin 0.85s linear infinite;
}

.bkn301-overlay-title {
    margin: 0 0 8px;
    font-size: 22px;
    font-weight: 600;
    color: #111827;
}

.bkn301-overlay-message {
    margin: 0;
    font-size: 15px;
    line-height: 1.5;
    color: #4b5563;
}

#bkn301-loading-overlay[data-state="success"] .bkn301-overlay-content {
    border-color: rgba(22, 163, 74, 0.18);
}

#bkn301-loading-overlay[data-state="success"] .bkn301-spinner {
    position: relative;
    border: 0;
    animation: none;
    background: rgba(16, 185, 129, 0.12);
}

#bkn301-loading-overlay[data-state="success"] .bkn301-spinner::before {
    content: "\2713";
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    font-weight: 700;
    color: #10b981;
}

#bkn301-loading-overlay[data-state="success"] .bkn301-overlay-title {
    color: #047857;
}

#bkn301-loading-overlay[data-state="failure"] .bkn301-overlay-content {
    border-color: rgba(220, 38, 38, 0.18);
}

#bkn301-loading-overlay[data-state="failure"] .bkn301-spinner {
    position: relative;
    border: 0;
    animation: none;
    background: rgba(239, 68, 68, 0.12);
}

#bkn301-loading-overlay[data-state="failure"] .bkn301-spinner::before {
    content: "\2717";
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    font-weight: 700;
    color: #ef4444;
}

#bkn301-loading-overlay[data-state="failure"] .bkn301-overlay-title {
    color: #dc2626;
}

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

#bkn301-3ds-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
}

#bkn301-3ds-modal .modal-content {
    background: white;
    padding: 20px;
    border-radius: 8px;
    max-width: 500px;
    width: 90%;
}

.bkn301-status {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 3px;
    font-size: 12px;
    font-weight: bold;
}

.bkn301-status-pending {
    background: #ffc107;
    color: #000;
}

.bkn301-status-processed,
.bkn301-status-success {
    background: #4caf50;
    color: white;
}

.bkn301-status-failed {
    background: #f44336;
    color: white;
}

.bkn301-status-canceled {
    background: #9e9e9e;
    color: white;
}

.bkn301-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;
}
