/**
 * 询价车样式
 *
 * 全部类名以 .hmq 开头，避免与模板（多为 Tailwind 生成）冲突。
 * 主色取站点品牌色变量 --brand，取不到时回落 #0047ba。
 */

.hmq-fab,
.hmq-drawer,
.hmq-mask,
.hmq-toast,
.hmq-inline {
    box-sizing: border-box;
    font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
}

.hmq-fab *,
.hmq-drawer *,
.hmq-toast *,
.hmq-inline * {
    box-sizing: border-box;
}

/* ---------------------------------------------------------------- 悬浮按钮 */

.hmq-fab {
    position: fixed;
    left: 20px;
    bottom: 20px;
    z-index: 9000;
    display: none;
    align-items: center;
    gap: 8px;
    height: 46px;
    padding: 0 18px 0 14px;
    border: 0;
    border-radius: 999px;
    background: var(--brand, #0047ba);
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
    box-shadow: 0 6px 20px rgba(0, 71, 186, .28);
    transition: transform .16s ease, box-shadow .16s ease;
}

.hmq-fab:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 26px rgba(0, 71, 186, .34);
}

.hmq-fab svg {
    width: 18px;
    height: 18px;
    flex: 0 0 auto;
}

.hmq-fab__n {
    min-width: 20px;
    height: 20px;
    padding: 0 5px;
    border-radius: 999px;
    background: #ff6a00;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    line-height: 20px;
    text-align: center;
}

/* ---------------------------------------------------------------- 内容页按钮 */

.hmq-inline {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin: 12px 0 4px;
    padding: 0 16px;
    height: 38px;
    border: 1px solid var(--brand, #0047ba);
    border-radius: 6px;
    background: #fff;
    color: var(--brand, #0047ba);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background .15s ease, color .15s ease;
}

.hmq-inline:hover {
    background: var(--brand, #0047ba);
    color: #fff;
}

.hmq-inline[disabled] {
    border-color: #d7dbe3;
    color: #9aa3b0;
    background: #f7f8fa;
    cursor: default;
}

.hmq-inline svg {
    width: 16px;
    height: 16px;
}

/* ---------------------------------------------------------------- 抽屉 */

.hmq-mask {
    position: fixed;
    inset: 0;
    z-index: 9100;
    background: rgba(17, 24, 39, .45);
    opacity: 0;
    visibility: hidden;
    transition: opacity .22s ease, visibility .22s;
}

.hmq-mask.is-on {
    opacity: 1;
    visibility: visible;
}

.hmq-drawer {
    position: fixed;
    top: 0;
    right: 0;
    z-index: 9200;
    display: flex;
    flex-direction: column;
    width: 420px;
    max-width: 100%;
    height: 100%;
    background: #fff;
    box-shadow: -8px 0 32px rgba(17, 24, 39, .14);
    transform: translateX(100%);
    visibility: hidden;
    transition: transform .26s cubic-bezier(.32, .72, 0, 1), visibility .26s;
}

.hmq-drawer.is-on {
    transform: none;
    visibility: visible;
}

.hmq-head {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 16px 18px;
    border-bottom: 1px solid #eef0f4;
}

.hmq-head h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 700;
    color: #1a1f2b;
}

.hmq-head small {
    color: #99a1ae;
    font-size: 12px;
}

.hmq-x {
    margin-left: auto;
    width: 30px;
    height: 30px;
    border: 0;
    border-radius: 6px;
    background: #f4f5f7;
    color: #616b7a;
    font-size: 18px;
    line-height: 1;
    cursor: pointer;
}

.hmq-x:hover {
    background: #e9ebef;
}

.hmq-body {
    flex: 1 1 auto;
    overflow-y: auto;
    padding: 14px 18px;
}

.hmq-empty {
    padding: 48px 10px;
    text-align: center;
    color: #99a1ae;
    font-size: 13.5px;
    line-height: 1.9;
}

.hmq-empty svg {
    width: 42px;
    height: 42px;
    margin-bottom: 10px;
    opacity: .35;
}

.hmq-item {
    position: relative;
    padding: 12px 0;
    border-bottom: 1px dashed #eceff3;
}

.hmq-item a {
    display: block;
    padding-right: 26px;
    color: #1a1f2b;
    font-size: 13.5px;
    font-weight: 600;
    line-height: 1.5;
    text-decoration: none;
    overflow: hidden;
    text-overflow: ellipsis;
    display: block;
}

.hmq-item a:hover {
    color: var(--brand, #0047ba);
}

.hmq-item__meta {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 8px;
}

.hmq-qty {
    display: inline-flex;
    align-items: center;
    border: 1px solid #dfe3ea;
    border-radius: 5px;
    overflow: hidden;
}

.hmq-qty button {
    width: 26px;
    height: 26px;
    border: 0;
    background: #f7f8fa;
    color: #4b5563;
    font-size: 15px;
    line-height: 1;
    cursor: pointer;
}

.hmq-qty button:hover {
    background: #eceff4;
}

.hmq-qty span {
    min-width: 34px;
    text-align: center;
    font-size: 13px;
    color: #1a1f2b;
}

.hmq-note {
    flex: 1 1 auto;
    height: 28px;
    padding: 0 8px;
    border: 1px solid #dfe3ea;
    border-radius: 5px;
    font-size: 12.5px;
    color: #1a1f2b;
    min-width: 0;
}

.hmq-note:focus {
    outline: none;
    border-color: var(--brand, #0047ba);
}

.hmq-del {
    position: absolute;
    top: 10px;
    right: 0;
    width: 22px;
    height: 22px;
    border: 0;
    background: none;
    color: #b6bcc7;
    font-size: 16px;
    line-height: 1;
    cursor: pointer;
}

.hmq-del:hover {
    color: #e5484d;
}

/* ---------------------------------------------------------------- 表单 */

.hmq-form {
    padding: 14px 18px 18px;
    border-top: 1px solid #eef0f4;
    background: #fbfcfd;
}

.hmq-row {
    margin-bottom: 9px;
}

.hmq-row input,
.hmq-row textarea {
    width: 100%;
    padding: 9px 11px;
    border: 1px solid #dfe3ea;
    border-radius: 6px;
    background: #fff;
    font-size: 13.5px;
    color: #1a1f2b;
    font-family: inherit;
}

.hmq-row input:focus,
.hmq-row textarea:focus {
    outline: none;
    border-color: var(--brand, #0047ba);
    box-shadow: 0 0 0 3px rgba(0, 71, 186, .08);
}

.hmq-row textarea {
    resize: vertical;
    min-height: 54px;
}

.hmq-row--half {
    display: flex;
    gap: 9px;
}

.hmq-row--half > * {
    flex: 1 1 0;
    min-width: 0;
}

.hmq-submit {
    width: 100%;
    height: 42px;
    margin-top: 4px;
    border: 0;
    border-radius: 6px;
    background: var(--brand, #0047ba);
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
}

.hmq-submit:hover {
    filter: brightness(1.06);
}

.hmq-submit[disabled] {
    opacity: .6;
    cursor: default;
}

.hmq-tip {
    margin-top: 8px;
    color: #99a1ae;
    font-size: 11.5px;
    line-height: 1.6;
    text-align: center;
}

.hmq-hp {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    opacity: 0;
}

/* ---------------------------------------------------------------- 提示 */

.hmq-toast {
    position: fixed;
    left: 50%;
    bottom: 88px;
    z-index: 9300;
    max-width: 78vw;
    padding: 10px 18px;
    border-radius: 8px;
    background: rgba(24, 29, 38, .92);
    color: #fff;
    font-size: 13.5px;
    line-height: 1.5;
    transform: translate(-50%, 12px);
    opacity: 0;
    visibility: hidden;
    transition: opacity .2s ease, transform .2s ease, visibility .2s;
}

.hmq-toast.is-on {
    opacity: 1;
    transform: translate(-50%, 0);
    visibility: visible;
}

.hmq-toast.is-err {
    background: #d13b3f;
}

@media (max-width: 640px) {
    .hmq-fab {
        left: 12px;
        bottom: 12px;
        height: 42px;
        padding: 0 15px 0 12px;
        font-size: 13px;
    }

    .hmq-drawer {
        width: 100%;
    }
}
