/* ==========================================================================
   WooCommerce Offerte Aanvraag - Frontend styling
   ========================================================================== */

.woa-form-wrapper {
    max-width: 760px;
    margin: 0 auto;
    font-family: inherit;
    color: #1f2937;
    box-sizing: border-box;
}

.woa-form-wrapper *,
.woa-form-wrapper *::before,
.woa-form-wrapper *::after {
    box-sizing: border-box;
}

/* --- Notices ------------------------------------------------------------ */
.woa-notice {
    padding: 14px 18px;
    border-radius: 8px;
    margin-bottom: 24px;
    font-size: 15px;
    line-height: 1.5;
    border-left: 4px solid transparent;
    background: #f9fafb;
}
.woa-notice-success {
    background: #ecfdf5;
    border-left-color: #10b981;
    color: #065f46;
}
.woa-notice-error {
    background: #fef2f2;
    border-left-color: #ef4444;
    color: #991b1b;
}

/* --- Product summary card ---------------------------------------------- */
.woa-product-summary {
    display: flex;
    gap: 24px;
    align-items: flex-start;
    padding: 20px;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    margin-bottom: 28px;
    background: #ffffff;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}
.woa-product-image {
    flex: 0 0 140px;
}
.woa-product-image img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    display: block;
}
.woa-product-info {
    flex: 1;
    min-width: 0;
}
.woa-product-name {
    margin: 0 0 8px;
    font-size: 1.35em;
    font-weight: 600;
    line-height: 1.3;
    color: #111827;
}
.woa-product-sku {
    margin: 4px 0;
    font-size: 13px;
    color: #6b7280;
}
.woa-product-price {
    margin: 8px 0;
    font-size: 1.15em;
    font-weight: 600;
    color: #111827;
}
.woa-product-price .amount,
.woa-product-price ins {
    text-decoration: none;
}
.woa-product-desc {
    margin-top: 10px;
    font-size: 14px;
    color: #4b5563;
    line-height: 1.5;
}
.woa-product-desc p:last-child { margin-bottom: 0; }

/* --- Form card --------------------------------------------------------- */
.woa-quote-form {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 28px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px 20px;
}

.woa-quote-form .woa-field {
    display: flex;
    flex-direction: column;
    margin: 0;
}

/* Volledige breedte velden */
.woa-quote-form .woa-field-full,
.woa-quote-form .woa-submit,
.woa-quote-form .woa-feedback {
    grid-column: 1 / -1;
}

.woa-quote-form label {
    font-weight: 600;
    margin-bottom: 6px;
    font-size: 14px;
    color: #374151;
}
.woa-quote-form .required {
    color: #dc2626;
    margin-left: 2px;
}

.woa-quote-form input[type="text"],
.woa-quote-form input[type="email"],
.woa-quote-form input[type="tel"],
.woa-quote-form input[type="number"],
.woa-quote-form textarea {
    width: 100%;
    padding: 11px 14px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 15px;
    line-height: 1.4;
    color: #111827;
    background: #ffffff;
    transition: border-color .15s ease, box-shadow .15s ease, background-color .15s ease;
    -webkit-appearance: none;
    appearance: none;
    font-family: inherit;
}

.woa-quote-form input:focus,
.woa-quote-form textarea:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
    background: #ffffff;
}

.woa-quote-form input::placeholder,
.woa-quote-form textarea::placeholder {
    color: #9ca3af;
}

.woa-quote-form textarea {
    resize: vertical;
    min-height: 120px;
}

/* --- Honeypot (verborgen) ---------------------------------------------- */
.woa-field-hp {
    position: absolute !important;
    left: -5000px !important;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

/* --- Submit knop ------------------------------------------------------- */
.woa-quote-form .woa-submit {
    margin-top: 6px;
}
.woa-submit-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 13px 28px;
    background: #292323;
    color: #ffffff;
    border: 0;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
    text-decoration: none;
    transition: background-color .15s ease, transform .05s ease, box-shadow .15s ease;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    font-family: inherit;
}
.woa-submit-btn:hover,
.woa-submit-btn:focus {
    background: #292323;
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
}
.woa-submit-btn:active {
    transform: translateY(1px);
}
.woa-submit-btn:disabled {
    opacity: .6;
    cursor: not-allowed;
}

/* --- Loading state ----------------------------------------------------- */
.woa-quote-form.is-loading {
    opacity: .7;
    pointer-events: none;
}
.woa-quote-form.is-loading .woa-submit-btn::after {
    content: "";
    width: 14px;
    height: 14px;
    border: 2px solid rgba(255, 255, 255, 0.4);
    border-top-color: #ffffff;
    border-radius: 50%;
    animation: woa-spin .7s linear infinite;
}

@keyframes woa-spin {
    to { transform: rotate(360deg); }
}

/* --- Inline feedback (AJAX) ------------------------------------------- */
.woa-feedback {
    margin: 0;
    padding: 0;
    font-size: 14px;
    line-height: 1.5;
}
.woa-feedback:not(:empty) {
    padding: 12px 16px;
    border-radius: 8px;
    margin-top: 4px;
}
.woa-feedback.is-success {
    background: #ecfdf5;
    color: #065f46;
    border-left: 4px solid #10b981;
}
.woa-feedback.is-error {
    background: #fef2f2;
    color: #991b1b;
    border-left: 4px solid #ef4444;
}

/* --- Front-end offerte knop (op product/shop) ------------------------- */
.woa-quote-button {
    display: inline-block;
    padding: 12px 24px;
    background: #292323;
    color: #ffffff !important;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    transition: background-color .15s ease, box-shadow .15s ease;
}
.woa-quote-button:hover,
.woa-quote-button:focus {
    background: #292323;
    color: #ffffff !important;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
}

/* --- Responsive -------------------------------------------------------- */
@media (max-width: 600px) {
    .woa-product-summary {
        flex-direction: column;
        padding: 16px;
    }
    .woa-product-image {
        flex-basis: auto;
        max-width: 180px;
    }
    .woa-quote-form {
        grid-template-columns: 1fr;
        padding: 20px;
    }
    .woa-submit-btn {
        width: 100%;
    }
}
