﻿/* QK Cashier - 前端样式 */
.qk-cashier-wrap {
    max-width: 480px;
    margin: 40px auto;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* 卡片 */
.qk-cashier-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 32px;
    box-shadow: 0 2px 12px rgba(0,0,0,.06);
}

.qk-cashier-title {
    font-size: 20px;
    font-weight: 700;
    color: #111827;
    margin: 0 0 28px;
    padding-bottom: 16px;
    border-bottom: 1px solid #f3f4f6;
}

/* 字段 */
.qk-field {
    margin-bottom: 24px;
}

.qk-label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 8px;
    letter-spacing: .3px;
}

/* 金额输入 */
.qk-amount-wrap {
    display: flex;
    align-items: center;
    border: 1.5px solid #d1d5db;
    border-radius: 8px;
    overflow: hidden;
    transition: border-color .2s;
}
.qk-amount-wrap:focus-within {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59,130,246,.12);
}

.qk-currency-unit {
    padding: 0 14px;
    font-size: 13px;
    font-weight: 700;
    color: #6b7280;
    background: #f9fafb;
    border-left: 1px solid #e5e7eb;
    line-height: 50px;
    white-space: nowrap;
}

.qk-input--amount {
    flex: 1;
    border: none;
    outline: none;
    font-size: 22px;
    font-weight: 700;
    color: #111827;
    padding: 0 12px;
    height: 50px;
    background: transparent;
    /* 隐藏 number 箭头 */
    -moz-appearance: textfield;
}
.qk-input--amount::-webkit-inner-spin-button,
.qk-input--amount::-webkit-outer-spin-button {
    -webkit-appearance: none;
}

.qk-hint {
    font-size: 12px;
    color: #ef4444;
    margin: 6px 0 0;
    min-height: 16px;
}

/* 支付方式列表 */
.qk-gateways {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.qk-gateway-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border: 1.5px solid #e5e7eb;
    border-radius: 8px;
    padding: 14px 16px;
    cursor: pointer;
    transition: border-color .18s, background .18s;
    user-select: none;
}
.qk-gateway-item:hover {
    border-color: #93c5fd;
    background: #f8faff;
}
.qk-gateway-item.is-selected {
    border-color: #3b82f6;
    background: #eff6ff;
}

.qk-gateway-radio {
    display: none;
}

.qk-gateway-inner {
    display: flex;
    align-items: center;
    gap: 10px;
}

.qk-gateway-logo {
    height: 24px;
    width: auto;
    object-fit: contain;
}

.qk-gateway-name {
    font-size: 14px;
    font-weight: 600;
    color: #374151;
}

.qk-gateway-check {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: 2px solid #d1d5db;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    color: transparent;
    transition: all .18s;
    flex-shrink: 0;
}
.qk-gateway-item.is-selected .qk-gateway-check {
    background: #3b82f6;
    border-color: #3b82f6;
    color: #fff;
}

/* 按钮 */
.qk-btn {
    display: block;
    width: 100%;
    padding: 14px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: opacity .2s, transform .1s;
    text-align: center;
}
.qk-btn:active { transform: scale(.98); }

.qk-btn--pay {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: #fff;
    margin-top: 8px;
}
.qk-btn--pay:disabled {
    background: #d1d5db;
    cursor: not-allowed;
    transform: none;
}
.qk-btn--pay:not(:disabled):hover { opacity: .92; }

.qk-btn--ghost {
    background: transparent;
    border: 1.5px solid #d1d5db;
    color: #374151;
    margin-top: 12px;
}
.qk-btn--ghost:hover { background: #f9fafb; }

/* 错误提示 */
.qk-error {
    margin-top: 12px;
    padding: 10px 14px;
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 6px;
    font-size: 13px;
    color: #dc2626;
    text-align: center;
}

.qk-notice {
    font-size: 13px;
    color: #9ca3af;
    padding: 12px;
    background: #f9fafb;
    border-radius: 6px;
    text-align: center;
}

/* 子支付方式（如 키움페이 的 CARD/BANK/VACCT） */
.qk-gateway-fields {
    margin: -4px 0 6px 0;
    padding: 12px 16px;
    background: #f8faff;
    border: 1px solid #bfdbfe;
    border-top: none;
    border-radius: 0 0 8px 8px;
}

.qk-sub-methods {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.qk-sub-method-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border: 1.5px solid #d1d5db;
    border-radius: 20px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    transition: all .15s;
    user-select: none;
}
.qk-sub-method-item input { display: none; }
.qk-sub-method-item:hover { border-color: #93c5fd; background: #eff6ff; }
.qk-sub-method-item.is-active { border-color: #3b82f6; background: #eff6ff; color: #2563eb; }

/* 结果页 */
.qk-result {
    text-align: center;
    padding: 48px 32px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0,0,0,.06);
}

.qk-result__icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    font-size: 28px;
    line-height: 64px;
    margin: 0 auto 20px;
}

.qk-result--success .qk-result__icon {
    background: #d1fae5;
    color: #059669;
}
.qk-result--fail .qk-result__icon {
    background: #fee2e2;
    color: #dc2626;
}

.qk-result h2 {
    font-size: 22px;
    font-weight: 700;
    color: #111827;
    margin: 0 0 8px;
}

.qk-result__amount {
    font-size: 28px;
    font-weight: 800;
    color: #111827;
    margin: 12px 0 8px;
}

.qk-result__order {
    font-size: 13px;
    color: #9ca3af;
    margin-bottom: 24px;
}
