

/* ── Modal backdrop ── */
.oval-qm-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: rgba(0,0,0,.65);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    overflow-y: auto;
    padding: 24px 16px 40px;
    align-items: flex-start;
    justify-content: center;
}
.oval-qm-backdrop.is-open {
    display: flex;
}
body.oval-qm-open {
    overflow: hidden;
}

/* ── Dialog box ── */
.oval-qm-dialog {
    position: relative;
    background: #fff;
    border-radius: 14px;
    width: 100%;
    max-width: 720px;
    box-shadow: 0 32px 80px -20px rgba(0,0,0,.45), 0 0 0 1px rgba(0,0,0,.08);
    animation: oval-qm-in .22s cubic-bezier(.22,1,.36,1);
}
@keyframes oval-qm-in {
    from { opacity:0; transform: translateY(24px) scale(.98); }
    to   { opacity:1; transform: translateY(0)   scale(1);    }
}

/* ── Close button ── */
.oval-qm-close {
    position: absolute;
    top: 16px; right: 18px;
    background: rgba(0,0,0,.06);
    border: none;
    border-radius: 50%;
    width: 34px; height: 34px;
    font-size: 15px;
    cursor: pointer;
    color: #374151;
    display: flex; align-items: center; justify-content: center;
    z-index: 2;
    transition: background .15s, color .15s;
}
.oval-qm-close:hover { background: #700020; color: #fff; }

/* ── Scrollable body ── */
.oval-qm-body {
    padding: 36px 36px 32px;
}
@media (max-width: 600px) {
    .oval-qm-body { padding: 28px 20px 24px; }
    .oval-qm-dialog { border-radius: 10px; }
}

/* ════════════════════════════════════════════
   FORM STYLES  (.oval-qf-*)
   Used by both modal + standalone shortcode
════════════════════════════════════════════ */

/* Header */
.oval-qf-header {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 24px;
    padding-bottom: 20px;
    border-bottom: 1px solid #f3f4f6;
}
.oval-qf-icon {
    flex-shrink: 0;
    margin-top: 2px;
}
.oval-qf-header-text { flex: 1; }
.oval-qf-header h2 {
    font-size: clamp(18px, 3.5vw, 22px);
    font-weight: 700;
    color: #111827;
    margin: 0 0 5px;
    font-family: inherit;
    padding-right: 36px;
    line-height: 1.2;
}
.oval-qf-header p {
    font-size: 14px;
    color: #6b7280;
    margin: 0;
    line-height: 1.55;
}

/* Error banner */
.oval-qf-error {
    background: #fef2f2;
    border: 1px solid #fca5a5;
    border-left: 4px solid #ef4444;
    border-radius: 6px;
    padding: 12px 16px;
    font-size: 14px;
    color: #991b1b;
    margin-bottom: 20px;
}

/* Row (2-col grid) */
.oval-qf-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}
@media (max-width: 540px) {
    .oval-qf-row { grid-template-columns: 1fr; }
}

/* Field */
.oval-qf-field {
    margin-bottom: 18px;
}
.oval-qf-field label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 6px;
    letter-spacing: .01em;
}
.oval-qf-opt {
    font-weight: 400;
    color: #9ca3af;
    font-size: 12px;
}
.oval-qf-required label::after {
    content: ' *';
    color: #700020;
    font-weight: 700;
}

/* Inputs & textareas */
.oval-qf-form input[type="text"],
.oval-qf-form input[type="email"],
.oval-qf-form input[type="tel"],
.oval-qf-form textarea {
    width: 100% !important;
    box-sizing: border-box !important;
    border: 1.5px solid #d1d5db !important;
    border-radius: 8px !important;
    padding: 10px 14px !important;
    font-size: 14.5px !important;
    color: #111827 !important;
    background: #fff !important;
    background-color: #fff !important;
    transition: border-color .15s, box-shadow .15s !important;
    font-family: inherit !important;
    outline: none !important;
    resize: vertical !important;
    box-shadow: none !important;
    appearance: none !important;
    -webkit-appearance: none !important;
}
.oval-qf-form input[type="text"]:focus,
.oval-qf-form input[type="email"]:focus,
.oval-qf-form input[type="tel"]:focus,
.oval-qf-form textarea:focus {
    border-color: #700020 !important;
    box-shadow: 0 0 0 3px rgba(112,0,32,.1) !important;
    outline: none !important;
}
.oval-qf-form input.is-invalid,
.oval-qf-form textarea.is-invalid {
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 3px rgba(239,68,68,.1) !important;
}
.oval-qf-form textarea { min-height: 80px !important; }

/* Pill groups */
.oval-qf-pills {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 8px !important;
    margin-top: 4px !important;
}
.oval-qf-pills .oval-qf-pill,
.oval-qf-form .oval-qf-pill {
    display: inline-block !important;
    padding: 7px 16px !important;
    border-radius: 999px !important;
    border: 1.5px solid #d1d5db !important;
    background: #fff !important;
    background-color: #fff !important;
    font-size: 13px !important;
    font-family: inherit !important;
    color: #374151 !important;
    cursor: pointer !important;
    transition: all .15s !important;
    line-height: 1 !important;
    box-shadow: none !important;
    text-shadow: none !important;
    letter-spacing: 0 !important;
    text-transform: none !important;
    font-weight: 500 !important;
    margin: 0 !important;
    width: auto !important;
}
.oval-qf-pills .oval-qf-pill:hover,
.oval-qf-form .oval-qf-pill:hover {
    border-color: #700020 !important;
    color: #700020 !important;
    background: #fff !important;
    background-color: #fff !important;
}
.oval-qf-pills .oval-qf-pill.is-active,
.oval-qf-form .oval-qf-pill.is-active {
    background: #700020 !important;
    background-color: #700020 !important;
    border-color: #700020 !important;
    color: #fff !important;
    font-weight: 600 !important;
}

/* GDPR */
.oval-qf-gdpr { margin-top: 4px; }
.oval-qf-check-label {
    display: flex !important;
    align-items: flex-start;
    gap: 10px;
    cursor: pointer;
    font-weight: 400 !important;
    color: #6b7280 !important;
    font-size: 13px;
    line-height: 1.5;
}
.oval-qf-check-label input[type="checkbox"] {
    flex-shrink: 0;
    margin-top: 2px;
    width: 16px; height: 16px;
    accent-color: #700020;
    cursor: pointer;
}
.oval-qf-check-label a { color: #700020; text-decoration: underline; }
.oval-qf-req-star { color: #700020; font-weight: 700; }

/* Submit row */
.oval-qf-actions {
    display: flex !important;
    align-items: center !important;
    gap: 20px !important;
    margin-top: 24px !important;
    flex-wrap: wrap !important;
}
.oval-qf-form .oval-qf-submit,
.oval-qf-standalone .oval-qf-submit {
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
    background: #700020 !important;
    background-color: #700020 !important;
    color: #fff !important;
    border: none !important;
    border-radius: 8px !important;
    padding: 13px 32px !important;
    font-size: 15px !important;
    font-weight: 600 !important;
    font-family: inherit !important;
    cursor: pointer !important;
    transition: background .18s, transform .1s !important;
    white-space: nowrap !important;
    box-shadow: none !important;
    text-shadow: none !important;
    text-transform: none !important;
    letter-spacing: 0 !important;
    line-height: 1.4 !important;
    width: auto !important;
}
.oval-qf-form .oval-qf-submit:hover,
.oval-qf-standalone .oval-qf-submit:hover {
    background: #8f0028 !important;
    background-color: #8f0028 !important;
    color: #fff !important;
}
.oval-qf-form .oval-qf-submit:active,
.oval-qf-standalone .oval-qf-submit:active { transform: scale(.98) !important; }
.oval-qf-form .oval-qf-submit:disabled,
.oval-qf-standalone .oval-qf-submit:disabled { background: #9ca3af !important; cursor: not-allowed !important; }
.oval-qf-submit-spinner svg {
    animation: oval-spin 1s linear infinite;
}
@keyframes oval-spin { to { transform: rotate(360deg); } }
.oval-qf-note {
    font-size: 12px;
    color: #9ca3af;
    margin: 0;
    line-height: 1.5;
}

/* ── Success state ── */
.oval-qf-success {
    text-align: center;
    padding: 16px 0 8px;
}
.oval-qf-success-icon { margin-bottom: 20px; }
.oval-qf-success-icon svg { display: inline-block; }
.oval-qf-success-title {
    font-size: 22px;
    font-weight: 700;
    color: #111827;
    margin: 0 0 10px;
}
.oval-qf-success-body {
    font-size: 15px;
    color: #374151;
    margin: 0 0 8px;
}
.oval-qf-success-sub {
    font-size: 13.5px;
    color: #6b7280;
    margin: 0;
}


/* ── Standalone shortcode overrides ── */
.oval-qf-standalone { max-width: 760px; margin: 40px auto; padding: 0 20px; }
.oval-qf-standalone .oval-qf-header { display: block !important; padding: 0 0 20px; border-bottom: 1px solid #e5e7eb; margin-bottom: 28px; }
.oval-qf-standalone .oval-qf-header h2 { font-size: clamp(22px,4vw,30px) !important; margin: 0 0 8px !important; color: #111827 !important; padding-right: 0 !important; }
.oval-qf-standalone .oval-qf-header p  { margin: 0 !important; color: #6b7280 !important; font-size: 15px !important; }
