/* ================================================================== */
/*  OneCheckout — Stripe 2026 Aesthetic                                */
/*  Font: Plus Jakarta Sans | Colors: Black & White                    */
/* ================================================================== */

:root {
    --oc-font: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    --oc-black: #0a0a0a;
    --oc-white: #ffffff;
    --oc-gray-50: #fafafa;
    --oc-gray-100: #f4f4f5;
    --oc-gray-200: #e4e4e7;
    --oc-gray-300: #d4d4d8;
    --oc-gray-400: #a1a1aa;
    --oc-gray-500: #71717a;
    --oc-gray-600: #52525b;
    --oc-gray-700: #3f3f46;
    --oc-gray-900: #18181b;
    --oc-green: #10b981;
    --oc-red: #ef4444;
    --oc-radius: 12px;
    --oc-radius-sm: 8px;
    --oc-shadow: 0 20px 60px rgba(0,0,0,0.15), 0 1px 3px rgba(0,0,0,0.08);
    --oc-shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
    --oc-transition: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ---- Buy Button ---- */
.onecheckout-buy-btn-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    width: 100%;
    margin: 16px 0;
    clear: both;
}

.onecheckout-or-divider {
    font-family: var(--oc-font);
    font-size: 12px;
    font-weight: 600;
    color: var(--oc-gray-400);
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.onecheckout-buy-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    max-width: 380px;
    padding: 14px 28px;
    background: var(--oc-black);
    color: var(--oc-white);
    border: none;
    border-radius: 10px;
    font-family: var(--oc-font);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--oc-transition);
    letter-spacing: -0.01em;
}
.onecheckout-buy-btn:hover { background: var(--oc-gray-700); transform: translateY(-1px); }
.onecheckout-buy-btn:active { transform: translateY(0); }

/* ---- Overlay ---- */
.oc-overlay {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,0.5);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    padding: 16px;
    animation: ocFadeIn 0.2s ease-out;
}

@keyframes ocFadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes ocSlideUp { from { opacity: 0; transform: translateY(20px) scale(0.98); } to { opacity: 1; transform: translateY(0) scale(1); } }

/* ---- Modal ---- */
.oc-modal {
    position: relative;
    width: 100%;
    max-width: 440px;
    max-height: 94vh;
    overflow-y: auto;
    background: var(--oc-white);
    border-radius: 16px;
    box-shadow: var(--oc-shadow);
    padding: 28px;
    animation: ocSlideUp 0.3s ease-out;
}

.oc-modal::-webkit-scrollbar { width: 4px; }
.oc-modal::-webkit-scrollbar-thumb { background: var(--oc-gray-200); border-radius: 2px; }

.oc-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    background: var(--oc-gray-100);
    border-radius: 50%;
    color: var(--oc-gray-500);
    cursor: pointer;
    transition: all var(--oc-transition);
    z-index: 2;
}
.oc-close:hover { background: var(--oc-gray-200); color: var(--oc-gray-900); }

/* ---- Header ---- */
.oc-header {
    margin-bottom: 24px;
    padding-right: 40px;
}

.oc-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
    color: var(--oc-black);
    font-family: var(--oc-font);
    font-weight: 700;
    font-size: 15px;
    letter-spacing: -0.02em;
}
.oc-brand svg { opacity: 0.8; }

.oc-product-info {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px;
    background: var(--oc-gray-50);
    border: 1px solid var(--oc-gray-200);
    border-radius: var(--oc-radius-sm);
}

.oc-product-name {
    font-family: var(--oc-font);
    font-size: 14px;
    font-weight: 500;
    color: var(--oc-gray-900);
}

.oc-product-price {
    font-family: var(--oc-font);
    font-size: 16px;
    font-weight: 700;
    color: var(--oc-black);
    white-space: nowrap;
}

/* ---- Stepper ---- */
.oc-stepper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    margin-bottom: 24px;
    padding: 0 8px;
}

.oc-step {
    display: flex;
    align-items: center;
    gap: 6px;
}

.oc-step-num {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-family: var(--oc-font);
    font-size: 11px;
    font-weight: 700;
    background: var(--oc-gray-100);
    color: var(--oc-gray-400);
    transition: all var(--oc-transition);
}

.oc-step-txt {
    font-family: var(--oc-font);
    font-size: 12px;
    font-weight: 600;
    color: var(--oc-gray-400);
    transition: color var(--oc-transition);
}

.oc-step.active .oc-step-num { background: var(--oc-black); color: var(--oc-white); }
.oc-step.active .oc-step-txt { color: var(--oc-gray-900); }
.oc-step.completed .oc-step-num { background: var(--oc-green); color: var(--oc-white); }
.oc-step.completed .oc-step-txt { color: var(--oc-gray-600); }

.oc-step-line {
    flex: 1;
    height: 1px;
    background: var(--oc-gray-200);
    margin: 0 8px;
    min-width: 20px;
}

/* ---- Panels ---- */
.oc-panel { }

.oc-title {
    font-family: var(--oc-font);
    font-size: 18px;
    font-weight: 700;
    color: var(--oc-gray-900);
    margin: 0 0 4px 0;
    letter-spacing: -0.02em;
}

.oc-subtitle {
    font-family: var(--oc-font);
    font-size: 14px;
    color: var(--oc-gray-500);
    margin: 0 0 20px 0;
    line-height: 1.5;
}

.oc-text-center { text-align: center; }

/* ---- Fields ---- */
.oc-field {
    margin-bottom: 14px;
}

.oc-field label, .oc-field-label {
    display: block;
    font-family: var(--oc-font);
    font-size: 13px;
    font-weight: 600;
    color: var(--oc-gray-700);
    margin-bottom: 6px;
}

.oc-field input[type="text"],
.oc-field input[type="email"],
.oc-field input[type="tel"],
.oc-field input[type="password"] {
    width: 100%;
    padding: 11px 14px;
    background: var(--oc-white);
    border: 1px solid var(--oc-gray-200);
    border-radius: var(--oc-radius-sm);
    font-family: var(--oc-font);
    font-size: 14px;
    color: var(--oc-gray-900);
    outline: none;
    transition: border-color var(--oc-transition), box-shadow var(--oc-transition);
    -webkit-appearance: none;
}
.oc-field input:focus {
    border-color: var(--oc-black);
    box-shadow: 0 0 0 3px rgba(0,0,0,0.06);
}
.oc-field input::placeholder { color: var(--oc-gray-400); }
.oc-field input[readonly] { background: var(--oc-gray-50); color: var(--oc-gray-500); }

.oc-row { display: flex; gap: 12px; }
.oc-half { flex: 1; }

/* ---- Buttons ---- */
.oc-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 12px 24px;
    background: var(--oc-black);
    color: var(--oc-white);
    border: none;
    border-radius: var(--oc-radius-sm);
    font-family: var(--oc-font);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--oc-transition);
    letter-spacing: -0.01em;
}
.oc-btn:hover { background: var(--oc-gray-700); }
.oc-btn:active { transform: scale(0.98); }

.oc-btn-full { width: 100%; }
.oc-btn-black { background: var(--oc-black); color: var(--oc-white); }
.oc-btn-black:hover { background: var(--oc-gray-700); }

.oc-btn-back {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 10px 16px;
    background: transparent;
    color: var(--oc-gray-500);
    border: 1px solid var(--oc-gray-200);
    border-radius: var(--oc-radius-sm);
    font-family: var(--oc-font);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--oc-transition);
}
.oc-btn-back:hover { border-color: var(--oc-gray-300); color: var(--oc-gray-700); }

.oc-btn-row { display: flex; gap: 10px; margin-top: 4px; }
.oc-btn-row .oc-btn { flex: 1; }

.oc-mt-12 { margin-top: 12px; }

/* ---- PIN Digits ---- */
.oc-pin-digits {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin: 16px 0 20px;
}

.oc-pin-digit {
    width: 64px;
    height: 72px;
    text-align: center;
    font-family: var(--oc-font);
    font-size: 28px;
    font-weight: 700;
    color: var(--oc-gray-900);
    background: var(--oc-white);
    border: 2px solid var(--oc-gray-200);
    border-radius: 12px;
    outline: none;
    transition: all var(--oc-transition);
    caret-color: var(--oc-black);
    -webkit-appearance: none;
}
.oc-pin-digit:focus {
    border-color: var(--oc-black);
    box-shadow: 0 0 0 4px rgba(0,0,0,0.08);
}
.oc-pin-digit.filled {
    border-color: var(--oc-gray-300);
    background: var(--oc-gray-50);
}

/* ---- Error ---- */
.oc-error {
    font-family: var(--oc-font);
    font-size: 13px;
    color: var(--oc-red);
    text-align: center;
    margin-bottom: 12px;
    padding: 8px 12px;
    background: #fef2f2;
    border-radius: var(--oc-radius-sm);
}

/* ---- Login Prompt ---- */
.oc-login-prompt {
    text-align: center;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--oc-gray-100);
    font-family: var(--oc-font);
    font-size: 13px;
    color: var(--oc-gray-500);
}
.oc-login-prompt a {
    color: var(--oc-black);
    font-weight: 600;
    text-decoration: none;
    margin-left: 4px;
}
.oc-login-prompt a:hover { text-decoration: underline; }

/* ---- Skip Link ---- */
.oc-skip-link {
    display: block;
    text-align: center;
    margin-top: 12px;
    font-family: var(--oc-font);
    font-size: 13px;
    color: var(--oc-gray-500);
    text-decoration: none;
}
.oc-skip-link:hover { color: var(--oc-gray-700); }

/* ---- Returning User Avatar ---- */
.oc-avatar {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    margin: 0 auto 12px;
    background: var(--oc-gray-100);
    border-radius: 50%;
    color: var(--oc-gray-500);
}

/* ---- Success Icon ---- */
.oc-success-icon {
    text-align: center;
    margin-bottom: 12px;
}

/* ---- Detail Card ---- */
.oc-detail-card {
    background: var(--oc-gray-50);
    border: 1px solid var(--oc-gray-200);
    border-radius: var(--oc-radius);
    padding: 4px 16px;
    margin-bottom: 20px;
}

.oc-detail-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 12px 0;
    border-bottom: 1px solid var(--oc-gray-100);
}
.oc-detail-row:last-child { border-bottom: none; }

.oc-detail-label {
    font-family: var(--oc-font);
    font-size: 13px;
    font-weight: 500;
    color: var(--oc-gray-500);
    min-width: 60px;
}

.oc-detail-value {
    font-family: var(--oc-font);
    font-size: 13px;
    font-weight: 600;
    color: var(--oc-gray-900);
    text-align: right;
    word-break: break-word;
}

/* ---- PeachPayments Container ---- */
.oc-peach-container {
    min-height: 300px;
    margin-bottom: 12px;
    position: relative;
}
.oc-peach-container iframe {
    border: none !important;
    width: 100% !important;
    min-height: 550px !important;
}
/* Force PeachPayments Embedded Checkout inner elements taller */
.oc-peach-container > div {
    min-height: 500px;
}

.oc-peach-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    gap: 12px;
    color: var(--oc-gray-500);
    font-family: var(--oc-font);
    font-size: 13px;
}

.oc-payment-iframe {
    width: 100%;
    min-height: 700px;
    height: auto;
    border: none;
    display: block;
    border-radius: var(--oc-radius-sm);
}

/* ---- Secure Note ---- */
.oc-secure-note {
    display: flex;
    align-items: center;
    gap: 6px;
    font-family: var(--oc-font);
    font-size: 12px;
    color: var(--oc-gray-500);
    margin-bottom: 16px;
}

/* ---- Loading Spinner ---- */
.oc-loading-spinner {
    width: 24px;
    height: 24px;
    border: 2.5px solid var(--oc-gray-200);
    border-top-color: var(--oc-black);
    border-radius: 50%;
    animation: ocSpin 0.7s linear infinite;
}
@keyframes ocSpin { to { transform: rotate(360deg); } }

.oc-spinner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px 20px;
    gap: 16px;
}
.oc-spinner-lg { width: 36px; height: 36px; }
.oc-spinner-text {
    font-family: var(--oc-font);
    font-size: 14px;
    font-weight: 600;
    color: var(--oc-gray-500);
    animation: ocPulse 1.5s ease-in-out infinite;
}
@keyframes ocPulse { 0%,100% { opacity: 0.5; } 50% { opacity: 1; } }

/* ---- Result ---- */
.oc-result-icon { text-align: center; margin-bottom: 12px; }
.oc-result-msg {
    font-family: var(--oc-font);
    font-size: 15px;
    font-weight: 600;
    color: var(--oc-gray-900);
    text-align: center;
    margin-bottom: 6px;
}
.oc-result-order {
    font-family: var(--oc-font);
    font-size: 13px;
    color: var(--oc-gray-500);
    text-align: center;
    margin-bottom: 20px;
}

/* ---- Footer ---- */
.oc-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 24px;
    padding-top: 16px;
    border-top: 1px solid var(--oc-gray-100);
}
.oc-powered {
    font-family: var(--oc-font);
    font-size: 11px;
    color: var(--oc-gray-400);
    letter-spacing: 0.01em;
}
.oc-logout {
    font-family: var(--oc-font);
    font-size: 12px;
    color: var(--oc-gray-400);
    text-decoration: none;
}
.oc-logout:hover { color: var(--oc-red); }

/* ---- Mobile ---- */
@media (max-width: 480px) {
    .oc-modal { padding: 20px; border-radius: 14px; max-height: 96vh; }
    .oc-pin-digit { width: 56px; height: 64px; font-size: 24px; }
    .oc-pin-digits { gap: 8px; }
    .oc-row { flex-direction: column; gap: 0; }
    .oc-half { flex: none; }
    .oc-btn-row { flex-direction: column-reverse; gap: 8px; }
    .oc-btn-row .oc-btn-back { width: 100%; justify-content: center; }
}
