/* WDQC Styles */

.wdqc-checkout-container {
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background: #ffffff;
    border: 3px solid #8b5cf6; /* Purple border matching image */
    border-radius: 12px;
    padding: 20px;
    max-width: 500px;
    margin: 20px auto;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    color: #333;
}

.wdqc-checkout-container * {
    box-sizing: border-box;
}

.wdqc-section {
    margin-bottom: 20px;
}

.wdqc-section-title {
    font-size: 16px;
    font-weight: bold;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 8px;
    color: #000;
}

.wdqc-icon {
    color: #f59e0b; /* yellow lightning */
}

/* Upsells */
.wdqc-upsell-option {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 12px 15px;
    margin-bottom: 10px;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
}

.wdqc-upsell-option.wdqc-selected {
    border-color: #8b5cf6;
    background-color: #f5f3ff;
}

.wdqc-upsell-option input[type="radio"] {
    margin: 0 0 0 10px;
    width: 20px;
    height: 20px;
    accent-color: #8b5cf6;
}

.wdqc-upsell-details {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.wdqc-upsell-title {
    font-weight: 600;
    font-size: 15px;
}

.wdqc-upsell-badge {
    background: #fef08a;
    color: #854d0e;
    font-size: 11px;
    padding: 2px 6px;
    border-radius: 4px;
    align-self: flex-start;
    font-weight: bold;
}

.wdqc-upsell-price {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.wdqc-price-current {
    font-weight: bold;
    color: #8b5cf6;
    font-size: 16px;
}

.wdqc-price-old {
    text-decoration: line-through;
    color: #9ca3af;
    font-size: 12px;
}

/* Form Fields */
.wdqc-row {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
}

.wdqc-col {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.wdqc-col label, .wdqc-label-block {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 6px;
    color: #111;
}

.wdqc-col label .required {
    color: #ef4444;
}

.wdqc-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.wdqc-input-wrapper input,
.wdqc-input-wrapper select {
    width: 100%;
    padding: 10px 35px 10px 10px; /* space for icon on right (rtl) */
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s;
    background: #fff;
    -webkit-appearance: none;
    appearance: none;
}

.wdqc-input-wrapper input:focus,
.wdqc-input-wrapper select:focus {
    border-color: #8b5cf6;
}

.wdqc-input-icon {
    position: absolute;
    right: 10px;
    color: #9ca3af;
    pointer-events: none;
}

/* Custom Dropdown Arrow */
.wdqc-input-wrapper select {
    background-image: url('data:image/svg+xml;utf8,<svg fill="%239ca3af" height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg"><path d="M7 10l5 5 5-5z"/><path d="M0 0h24v24H0z" fill="none"/></svg>');
    background-repeat: no-repeat;
    background-position: left 8px center;
}

.wdqc-hint {
    font-size: 11px;
    color: #6b7280;
    margin-top: 4px;
}

/* Delivery Types */
.wdqc-delivery-types {
    display: flex;
    gap: 15px;
}

.wdqc-delivery-type {
    flex: 1;
    cursor: pointer;
}

.wdqc-delivery-type input {
    display: none;
}

.wdqc-delivery-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    padding: 15px;
    gap: 8px;
    transition: all 0.2s;
    color: #4b5563;
}

.wdqc-delivery-type input:checked + .wdqc-delivery-content {
    border-color: #8b5cf6;
    color: #8b5cf6;
    background-color: #f5f3ff;
}

.wdqc-delivery-icon {
    font-size: 20px;
}

/* Quantity */
.wdqc-qty-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.wdqc-quantity-selector {
    display: flex;
    align-items: center;
    gap: 10px;
}

.wdqc-qty-btn {
    width: 36px;
    height: 36px;
    border: 1px solid #d1d5db;
    background: #fff;
    border-radius: 8px;
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #374151;
}

.wdqc-quantity-selector input {
    width: 40px;
    text-align: center;
    border: none;
    font-size: 16px;
    font-weight: bold;
    outline: none;
    -moz-appearance: textfield;
}

.wdqc-quantity-selector input::-webkit-outer-spin-button,
.wdqc-quantity-selector input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Summary */
.wdqc-order-summary {
    background: #f9fafb;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 20px;
}

.wdqc-summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
    font-size: 14px;
    color: #4b5563;
}

.wdqc-summary-total {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px dashed #d1d5db;
    font-weight: bold;
    font-size: 18px;
    color: #111;
}

.wdqc-summary-total #wdqc-summary-grand-total {
    color: #8b5cf6;
}

/* Submit Button */
.wdqc-submit-btn {
    width: 100%;
    background: #8b5cf6;
    color: white;
    border: none;
    border-radius: 8px;
    padding: 15px;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    transition: background 0.2s;
    display: flex;
    justify-content: center;
    gap: 5px;
}

.wdqc-submit-btn:hover {
    background: #7c3aed;
}

.wdqc-submit-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

#wdqc-form-messages {
    margin-top: 15px;
    text-align: center;
    font-size: 14px;
}

.wdqc-msg-error {
    color: #ef4444;
}

.wdqc-msg-success {
    color: #10b981;
}

@media (max-width: 480px) {
    .wdqc-row {
        flex-direction: column;
        gap: 10px;
    }
}
