/* WP Order Form — all colors hardcoded, overridden by wp_add_inline_style */

.wpof-wrapper {
    display: flex;
    justify-content: center;
    padding: 20px;
    font-family: 'Segoe UI', Arial, sans-serif;
}

.wpof-card {
    width: 100%;
    max-width: 460px;
    background: #fff;
    border-radius: 12px;
    border: 2px solid #3b8d39 !important;
    box-shadow: 0 4px 20px rgba(0,0,0,.1);
    overflow: hidden;
}

.wpof-card .wpof-header {
    padding: 24px 24px 8px;
    text-align: center;
    border-bottom: 1px solid #f0f0f0;
}
.wpof-card .wpof-icon { font-size: 28px; display: block; margin-bottom: 6px; }
.wpof-card .wpof-title { margin: 0 !important; font-size: 16px !important; font-weight: 500 !important; color: #3b8d39 !important; }

.wpof-card .wpof-success,
.wpof-card .wpof-error {
    margin: 12px 24px;
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
}
.wpof-card .wpof-success { background: #ecfdf5; color: #065f46; border: 1px solid #6ee7b7; }
.wpof-card .wpof-error   { background: #fef2f2; color: #991b1b; border: 1px solid #fca5a5; }

.wpof-card #wpof-order-form {
    padding: 20px 24px !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 14px !important;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
}

.wpof-card .wpof-field {
    position: relative !important;
    display: block !important;
}

.wpof-card .wpof-field-icon {
    position: absolute !important;
    left: 12px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    font-size: 15px !important;
    line-height: 1 !important;
    z-index: 2 !important;
    pointer-events: none !important;
    display: inline-block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

.wpof-card .wpof-field input,
.wpof-card .wpof-field select {
    display: block !important;
    width: 100% !important;
    padding: 12px 14px 12px 40px !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 8px !important;
    font-size: 14px !important;
    color: #374151 !important;
    background: #fff !important;
    box-sizing: border-box !important;
    appearance: none !important;
    -webkit-appearance: none !important;
    box-shadow: none !important;
    outline: none !important;
    transition: border-color .2s, box-shadow .2s !important;
    min-height: unset !important;
    height: auto !important;
    margin: 0 !important;
    background-image: none !important;
}

.wpof-card .wpof-field input:focus,
.wpof-card .wpof-field select:focus {
    border-color: #3b8d39 !important;
    box-shadow: 0 0 0 3px rgba(59,141,57,.2) !important;
    outline: none !important;
}

.wpof-card .wpof-field input::placeholder { color: #9ca3af !important; }

.wpof-card .wpof-field input.wpof-field-error,
.wpof-card .wpof-field select.wpof-field-error {
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 3px rgba(239,68,68,.15) !important;
}

.wpof-card .wpof-controls-row {
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
    margin-top: 4px !important;
}

.wpof-card .wpof-quantity {
    display: flex !important;
    align-items: center !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 8px !important;
    overflow: hidden !important;
    background: #f9fafb !important;
    flex-shrink: 0 !important;
}
.wpof-card .wpof-quantity button {
    background: none !important;
    border: none !important;
    cursor: pointer !important;
    padding: 10px 14px !important;
    font-size: 18px !important;
    color: #6b7280 !important;
    line-height: 1 !important;
    box-shadow: none !important;
    border-radius: 0 !important;
}
.wpof-card .wpof-quantity button:hover { background: #e5e7eb !important; }
.wpof-card #wpof-qty-value {
    min-width: 32px !important;
    text-align: center !important;
    font-weight: 600 !important;
    font-size: 15px !important;
    color: #374151 !important;
}

/* Commander button */
.wpof-card .wpof-btn-submit {
    flex: 1 !important;
    background: #3b8d39 !important;
    color: #ffffff !important;
    border: none !important;
    border-radius: 8px !important;
    padding: 12px 20px !important;
    font-size: 15px !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    box-shadow: 0 2px 6px rgba(0,0,0,.2) !important;
    transition: transform .15s, opacity .15s !important;
    width: auto !important;
    display: block !important;
}
.wpof-card .wpof-btn-submit:hover { transform: translateY(-1px) !important; opacity: .9 !important; }
.wpof-card .wpof-btn-submit:disabled { opacity: .6 !important; cursor: not-allowed !important; transform: none !important; }

.wpof-card .wpof-summary {
    margin: 0 24px 24px !important;
    border: 1px solid #e5e7eb !important;
    border-radius: 8px !important;
    overflow: hidden !important;
}
.wpof-card .wpof-summary-toggle {
    width: 100% !important;
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    padding: 14px 16px !important;
    background: #f9fafb !important;
    border: none !important;
    cursor: pointer !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    color: #374151 !important;
    box-shadow: none !important;
}
.wpof-card .wpof-chevron { font-size: 12px; transition: transform .2s; }
.wpof-card .wpof-chevron.open { transform: rotate(180deg); }

.wpof-card .wpof-summary-body {
    padding: 14px 16px;
    border-top: 1px solid #e5e7eb;
    display: flex;
    flex-direction: column;
    gap: 10px;
    font-size: 14px;
}
.wpof-card .wpof-summary-line {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #6b7280;
}
.wpof-card .wpof-summary-line span:last-child { margin-left: auto; font-weight: 500; color: #1f2937; }
.wpof-card .wpof-badge {
    background: #dcfce7; color: #166534;
    border-radius: 4px; padding: 2px 8px;
    font-size: 12px; font-weight: 600;
}
.wpof-card .wpof-summary-total {
    display: flex; justify-content: space-between; align-items: center;
    padding-top: 10px; border-top: 1px dashed #e5e7eb; color: #1f2937;
}
/* Total price color */
.wpof-card .wpof-summary-total strong:last-child { color: #3b8d39 !important; font-size: 18px; }

/* Hide WooCommerce Add to Cart */
.wpof-hide-cart .cart,
.wpof-hide-cart form.cart,
.wpof-hide-cart .single_add_to_cart_button,
.wpof-hide-cart .woocommerce-variation-add-to-cart,
.wpof-hide-cart .quantity {
    display: none !important;
}

@media (max-width: 480px) {
    .wpof-wrapper { padding: 10px; }
    .wpof-card .wpof-controls-row { flex-direction: column; }
    .wpof-card .wpof-btn-submit { width: 100% !important; }
}
