/* ============================================
   INQUIRY DRAWER + FLOATING ACTION BUTTON
   ============================================ */

/* ---------- FAB ---------- */
.iq-fab {
    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 9990;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 18px 12px 16px;
    background: var(--color-accent, #0067FF);
    color: #fff;
    border: none;
    border-radius: 999px;
    font-family: inherit;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 10px 28px rgba(0, 103, 255, 0.32);
    transition: transform 200ms ease, box-shadow 200ms ease, background 200ms ease;
}
.iq-fab:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 14px 36px rgba(0, 103, 255, 0.42);
    background: #0052cc;
    color: #fff;
}
.iq-fab-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 22px;
    height: 22px;
    padding: 0 6px;
    background: #fff;
    color: var(--color-accent, #0067FF);
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    line-height: 1;
}
.iq-fab[data-empty="1"] .iq-fab-count { display: none; }

@media (max-width: 600px) {
    .iq-fab { right: 16px; bottom: 16px; padding: 12px 14px 12px 12px; }
    .iq-fab-label { display: none; }
}

/* "Added!" pulse */
.iq-fab.is-pulsing {
    animation: iq-pulse 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}
@keyframes iq-pulse {
    0% { transform: scale(1); }
    40% { transform: scale(1.18); }
    100% { transform: scale(1); }
}

/* ---------- BACKDROP ---------- */
.iq-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.5);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    z-index: 9991;
    opacity: 0;
    transition: opacity 250ms ease;
}
.iq-backdrop.is-open { opacity: 1; }

/* ---------- DRAWER ---------- */
.iq-drawer {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 440px;
    max-width: 100vw;
    z-index: 9992;
    background: #fff;
    box-shadow: -10px 0 40px rgba(15, 23, 42, 0.18);
    display: flex;
    flex-direction: column;
    transform: translateX(100%);
    transition: transform 320ms cubic-bezier(0.4, 0, 0.2, 1);
    font-family: var(--font-body, 'Inter', sans-serif);
    color: var(--color-body, #364151);
}
.iq-drawer.is-open { transform: translateX(0); }

@media (max-width: 480px) {
    .iq-drawer { width: 100vw; }
}

.iq-drawer-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    padding: 22px 24px;
    border-bottom: 1px solid var(--color-border, #E5E7EB);
}
.iq-title {
    margin: 0;
    font-size: 20px;
    font-weight: 800;
    color: var(--color-heading, #0F172A);
    letter-spacing: -0.01em;
}
.iq-subtitle {
    margin: 2px 0 0;
    font-size: 12px;
    color: #6b7280;
}
.iq-close {
    background: none;
    border: none;
    cursor: pointer;
    color: #6b7280;
    padding: 4px;
    border-radius: 6px;
    transition: background 0.15s ease, color 0.15s ease;
}
.iq-close:hover { background: #f3f4f6; color: var(--color-heading); }

/* ---------- EMPTY ---------- */
.iq-empty {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 40px 24px;
    gap: 16px;
}
.iq-empty[hidden] { display: none; }
.iq-empty-icon { color: #cbd5e1; }
.iq-empty h3 { margin: 0; font-size: 18px; font-weight: 700; color: var(--color-heading); }
.iq-empty p { margin: 0; font-size: 14px; line-height: 1.55; max-width: 280px; }

/* ---------- ITEMS LIST ---------- */
.iq-items {
    flex: 1;
    overflow-y: auto;
    padding: 12px 16px;
    scrollbar-width: thin;
}
.iq-items[hidden] { display: none; }

.iq-items::-webkit-scrollbar { width: 6px; }
.iq-items::-webkit-scrollbar-thumb { background: #d1d5db; border-radius: 3px; }

.iq-item {
    display: grid;
    grid-template-columns: 60px 1fr auto;
    gap: 12px;
    align-items: center;
    padding: 12px;
    border: 1px solid var(--color-border);
    border-radius: 10px;
    margin-bottom: 8px;
    background: #fff;
    transition: border-color 0.15s ease;
}
.iq-item:hover { border-color: var(--color-accent); }

.iq-item-img {
    width: 60px;
    height: 60px;
    background: #f8fafc;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6px;
}
.iq-item-img img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    mix-blend-mode: multiply;
}

.iq-item-info { min-width: 0; }
.iq-item-name {
    font-size: 13px;
    font-weight: 600;
    color: var(--color-heading);
    line-height: 1.3;
    margin: 0 0 6px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.iq-qty {
    display: inline-flex;
    align-items: center;
    border: 1px solid var(--color-border);
    border-radius: 6px;
    overflow: hidden;
}
.iq-qty button {
    width: 26px;
    height: 26px;
    background: #fff;
    border: none;
    color: var(--color-heading);
    cursor: pointer;
    font-size: 14px;
    line-height: 1;
    transition: background 0.1s ease;
}
.iq-qty button:hover { background: var(--color-bg-soft, #F2F0FE); }
.iq-qty span {
    min-width: 28px;
    text-align: center;
    font-size: 13px;
    font-weight: 600;
    color: var(--color-heading);
}

.iq-item-remove {
    background: none;
    border: none;
    color: #94a3b8;
    cursor: pointer;
    padding: 6px;
    border-radius: 6px;
    transition: background 0.15s ease, color 0.15s ease;
}
.iq-item-remove:hover { background: #fee2e2; color: #dc2626; }

/* ---------- FORM ---------- */
.iq-form {
    border-top: 1px solid var(--color-border);
    padding: 20px 24px;
    background: var(--color-bg-muted, #F8FAFC);
}
.iq-form[hidden] { display: none; }

.iq-form-title {
    margin: 0 0 14px;
    font-size: 14px;
    font-weight: 700;
    color: var(--color-heading);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.iq-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.iq-field { display: block; }
.iq-field-full { grid-column: 1 / -1; }

.iq-field span {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: var(--color-heading);
    margin-bottom: 4px;
}
.iq-field em {
    color: #dc2626;
    font-style: normal;
}

.iq-field input,
.iq-field textarea {
    width: 100%;
    padding: 9px 12px;
    background: #fff;
    border: 1px solid var(--color-border);
    border-radius: 6px;
    font-family: inherit;
    font-size: 13px;
    color: var(--color-heading);
    box-sizing: border-box;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.iq-field input:focus,
.iq-field textarea:focus {
    outline: none;
    border-color: var(--color-accent);
    box-shadow: 0 0 0 3px rgba(0, 103, 255, 0.12);
}

.iq-form-actions {
    margin-top: 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.iq-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 22px;
    border-radius: 10px;
    font-family: inherit;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    border: none;
    transition: background 0.2s ease, transform 0.15s ease;
}
.iq-btn-primary {
    background: var(--color-accent);
    color: #fff;
}
.iq-btn-primary:hover { background: #0052cc; color: #fff; transform: translateY(-2px); }
.iq-btn-success {
    background: var(--color-success, #16A34A);
    color: #fff;
    box-shadow: 0 6px 16px rgba(22, 163, 74, 0.22);
}
.iq-btn-success:hover { background: #15803D; color: #fff; transform: translateY(-2px); }

.iq-btn-spinner {
    display: none;
    animation: iq-spin 0.8s linear infinite;
}
.iq-btn.is-loading .iq-btn-text { display: none; }
.iq-btn.is-loading .iq-btn-spinner { display: inline-block; }
.iq-btn:disabled { opacity: 0.7; cursor: not-allowed; }
@keyframes iq-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.iq-privacy {
    margin: 0;
    font-size: 11px;
    color: #6b7280;
    line-height: 1.45;
    text-align: center;
}

.iq-status {
    margin-top: 14px;
    padding: 12px 14px;
    border-radius: 8px;
    font-size: 13px;
    line-height: 1.5;
}
.iq-status.is-success {
    background: #D1FAE5;
    color: #065F46;
    border-left: 3px solid #16A34A;
}
.iq-status.is-error {
    background: #FEE2E2;
    color: #991B1B;
    border-left: 3px solid #DC2626;
}

/* ---------- ADD-TO-INQUIRY BUTTON (used on cards + product page) ---------- */
.iq-add-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8px 14px;
    background: #fff;
    color: var(--color-heading);
    border: 1.5px solid var(--color-border);
    border-radius: 8px;
    font-family: inherit;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
    text-decoration: none;
}
.iq-add-btn:hover {
    background: var(--color-accent);
    color: #fff;
    border-color: var(--color-accent);
}
.iq-add-btn svg { transition: transform 0.15s ease; }
.iq-add-btn.is-added {
    background: var(--color-success, #16A34A);
    color: #fff;
    border-color: var(--color-success, #16A34A);
}
/* In list → the "+" becomes an "×" to signal it now removes */
.iq-add-btn.is-added svg { transform: rotate(45deg); }
.iq-add-btn.is-added:hover {
    background: #DC2626;
    border-color: #DC2626;
    color: #fff;
}

/* Big version for product page hero */
.iq-add-btn.iq-add-btn-lg {
    padding: 14px 24px;
    border-radius: 12px;
    font-size: 15px;
}

/* ---------- REQUEST QUOTE button (green) ---------- */
.iq-quote-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8px 14px;
    background: var(--color-success, #16A34A);
    color: #fff;
    border: 1.5px solid var(--color-success, #16A34A);
    border-radius: 8px;
    font-family: inherit;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}
.iq-quote-btn:hover {
    background: #15803D;
    border-color: #15803D;
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(22, 163, 74, 0.28);
}
.iq-quote-btn-lg {
    padding: 14px 24px;
    border-radius: 12px;
    font-size: 15px;
}

/* ---------- WHATSAPP button ---------- */
.iq-wa-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 38px;
    height: 38px;
    background: #25D366;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-family: inherit;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    flex-shrink: 0;
    transition: background 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}
.iq-wa-btn:hover {
    background: #1FAF54;
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.32);
}
.iq-wa-btn-lg {
    width: auto;
    padding: 14px 24px;
    border-radius: 12px;
    font-size: 15px;
}

/* ---------- Quick action row inside cards ---------- */
.ps-card-quick {
    display: flex;
    gap: 6px;
    margin-top: 8px;
}
