/* Checkout Modal and Quantity Selector Styles */

/* Quantity Selector */
.quantity-control {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin: 15px 0;
    background: #f0f0f0;
    padding: 10px;
    border-radius: 8px;
    border: 1px solid #ccc;
}

.qty-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: none;
    background: #000;
    color: white;
    font-size: 20px;
    font-weight: bold;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.qty-btn:hover {
    transform: scale(1.1);
    background: #333;
}

.qty-btn:active {
    transform: scale(0.95);
}

.qty-value {
    font-size: 1.2rem;
    font-weight: 600;
    min-width: 30px;
    text-align: center;
    color: #000;
}

/* Modal Overlay */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Modal Container */
.modal-container {
    background: #1a1a1a;
    width: 90%;
    max-width: 500px;
    border-radius: 20px;
    padding: 30px;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    transform: translateY(20px);
    transition: all 0.3s ease;
}

.modal-overlay.active .modal-container {
    transform: translateY(0);
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: none;
    border: none;
    color: #999;
    font-size: 24px;
    cursor: pointer;
    transition: color 0.2s;
}

.modal-close:hover {
    color: white;
}

.modal-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 20px;
    color: white;
    text-align: center;
}

/* Checkout Form */
.checkout-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.form-group label {
    font-size: 0.9rem;
    color: #ccc;
    font-weight: 500;
}

.form-group input,
.form-group select {
    background: #2a2a2a;
    border: 1px solid #444;
    padding: 12px;
    border-radius: 8px;
    color: white;
    font-family: inherit;
    transition: border-color 0.2s;
}

.form-group input:focus {
    outline: none;
    border-color: var(--primary);
}

/* Payment Selection */
.payment-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin: 5px 0;
}

.payment-option {
    position: relative;
}

.payment-option input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.payment-label {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 12px;
    border: 1px solid #444;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    background: #2a2a2a;
    min-height: 65px;
}

.payment-label img {
    max-height: 20px;
    margin-bottom: 8px;
}

.payment-label span {
    font-size: 0.8rem;
    font-weight: 600;
    text-align: center;
}

/* Step Transitions */
.checkout-step {
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.checkout-step.hidden {
    display: none;
    opacity: 0;
    transform: translateX(20px);
}

.checkout-step.active {
    display: block;
    opacity: 1;
    transform: translateX(0);
}

/* Bank Info Box */
.bank-info-box {
    background: #1a1a1a;
    border: 1px solid #333;
    border-radius: 12px;
    padding: 15px;
    margin-top: 15px;
    font-size: 0.9rem;
}

.bank-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid #2a2a2a;
}

.bank-row:last-child {
    border-bottom: none;
}

.bank-label {
    color: #888;
    font-size: 0.8rem;
}

.bank-value {
    color: #fff;
    font-weight: 600;
    font-family: 'Inter', monospace;
}

.copy-btn {
    background: #333;
    border: none;
    color: var(--primary);
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.7rem;
    cursor: pointer;
    margin-left: 10px;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 4px;
}

.copy-btn:hover {
    background: #444;
}

.copy-btn.copied {
    background: #10b981;
    color: white;
}

.btn-back {
    background: transparent;
    border: 1px solid #444;
    color: #888;
    width: 100%;
    padding: 10px;
    border-radius: 8px;
    margin-top: 10px;
    cursor: pointer;
    font-weight: 600;
}

.btn-next {
    background: var(--primary);
    color: white;
    width: 100%;
    padding: 14px;
    border-radius: 8px;
    border: none;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    margin-top: 20px;
}

.bank-title {
    color: var(--primary);
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* QR Visual Crop - Adjusted to show full image */
.qr-crop-container {
    width: 100%;
    max-width: 60px;
    height: auto;
    overflow: hidden;
    margin: 0 auto 5px;
    border: 1px solid var(--primary);
    border-radius: 6px;
    background: white;
    padding: 2px;
    /* The QR itself needs white background to be scannable */
}

.qr-crop-container img {
    border: none;
    max-width: 100% !important;
    width: 100%;
    height: auto;
    margin: 0;
    display: block;
}

/* Summary Box */
.order-summary {
    background: rgba(255, 255, 255, 0.05);
    padding: 15px;
    border-radius: 12px;
    margin-top: 10px;
    border: 1px dashed #444;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 5px;
    font-size: 0.95rem;
}

.summary-total {
    border-top: 1px solid #444;
    margin-top: 10px;
    padding-top: 10px;
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--primary-light);
}

.btn-confirm {
    background: var(--primary);
    color: white;
    border: none;
    padding: 15px;
    border-radius: 10px;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    margin-top: 10px;
    transition: all 0.2s;
}

.btn-confirm:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(15, 76, 129, 0.4);
}

/* Fullscreen QR Overlay */
.qr-fullscreen-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 3000;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
}

.qr-fullscreen-overlay.active {
    opacity: 1;
    visibility: visible;
}

.qr-fullscreen-content {
    background: white;
    padding: 20px;
    border-radius: 20px;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.5);
    max-width: 90%;
    max-height: 80%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.qr-fullscreen-content img {
    max-width: 100%;
    max-height: 70vh;
    object-fit: contain;
}

.qr-fullscreen-close {
    margin-top: 20px;
    background: white;
    color: #333;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}