.xq-drawer,
.xq-request-page {
    --xq-heading: #132a4f;
    --xq-ink: #18365d;
    --xq-muted: #767676;
    --xq-line: #e4e8ef;
    --xq-panel: #eef4f8;
    --xq-field: #ffffff;
    --xq-accent: #2f63bf;
    --xq-accent-hover: #1d4f9f;
    --xq-link: #2b5fad;
    --xq-focus: #2f63bf;
}

.xq-overlay {
    position: fixed;
    inset: 0;
    z-index: 9998;
    background: rgba(17, 21, 24, 0.56);
    opacity: 0;
    pointer-events: none;
    transition: opacity 180ms ease;
}

.xq-overlay--open {
    opacity: 1;
    pointer-events: auto;
}

.xq-drawer {
    --xq-heading: #111518;
    --xq-ink: #1f3a5f;
    --xq-muted: #5a6577;
    --xq-line: #e8ebf0;
    --xq-panel: #ffffff;
    --xq-accent: #2c3e50;
    --xq-accent-hover: #1f3a5f;
    --xq-link: #2c4a6e;
    --xq-focus: #7c4dff;

    position: fixed;
    inset: 0 0 0 auto;
    z-index: 9999;
    display: flex;
    width: min(430px, 100vw);
    height: 100vh;
    height: var(--xq-viewport-height, 100dvh);
    max-height: var(--xq-viewport-height, 100dvh);
    flex-direction: column;
    background: var(--xq-panel);
    color: var(--xq-ink);
    box-shadow: -12px 0 30px rgba(17, 21, 24, 0.16);
    transform: translateX(100%);
    transition: transform 220ms ease;
}

.xq-drawer--open {
    transform: translateX(0);
}

.xq-drawer__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 64px;
    padding: 18px 24px;
    border-bottom: 1px solid var(--xq-line);
    background: var(--xq-panel);
}

.xq-drawer__header h2 {
    margin: 0;
    color: var(--xq-heading);
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 0;
}

.xq-drawer__close {
    width: 34px;
    height: 34px;
    border: 0;
    background: transparent;
    color: var(--xq-heading);
    cursor: pointer;
    font-size: 28px;
    line-height: 1;
}

.xq-drawer__body,
.xq-drawer__content {
    display: flex;
    min-height: 0;
    flex: 1;
    flex-direction: column;
}

.xq-loading {
    padding: 26px 24px;
    color: var(--xq-muted);
}

.xq-drawer-list {
    flex: 1;
    overflow-y: auto;
    padding: 20px 24px;
}

.xq-drawer-item {
    display: grid;
    grid-template-columns: 72px minmax(0, 1fr);
    gap: 14px;
    padding-bottom: 20px;
}

.xq-item-thumb,
.xq-request-item__thumb {
    display: block;
    overflow: hidden;
    border: 1px solid var(--xq-line);
    border-radius: 4px;
    background: #ffffff;
}

.xq-item-thumb {
    width: 72px;
    height: 72px;
}

.xq-item-thumb img,
.xq-request-item__thumb img {
    width: 100% !important;
    height: 100% !important;
    object-fit: contain;
    padding: 6px;
}

.xq-item-main {
    min-width: 0;
}

.xq-item-title,
.xq-request-item__title {
    color: var(--xq-ink);
    text-decoration: none;
    font-weight: 600;
    line-height: 1.35;
}

.xq-item-title {
    display: block;
    margin-bottom: 6px;
    font-size: 15px;
    font-weight: 700;
}

.xq-item-sku,
.xq-request-item__sku,
.xq-item-price {
    display: block;
    color: var(--xq-muted);
    font-size: 13px;
}

.xq-drawer .xq-item-sku,
.xq-drawer .xq-item-price {
    display: block;
}

.xq-item-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 12px;
}

.xq-qty {
    position: relative;
    display: inline-block;
    overflow: visible;
    width: 130px;
    min-width: 130px;
    height: 55px;
    border: 0;
    border-radius: 0;
    background: transparent;
}

.xq-qty__btn,
.xq-qty__input {
    height: inherit !important;
    min-width: 0 !important;
    min-height: 0 !important;
    padding: 0 !important;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: var(--xq-muted) !important;
    text-align: center;
    font-weight: 500 !important;
    line-height: 1;
    box-shadow: none !important;
    box-sizing: border-box;
    appearance: none;
    -webkit-appearance: none;
}

.xq-qty__btn {
    position: absolute;
    top: calc(50% - 55px / 3.6);
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: calc(55px / 1.8);
    height: calc(55px / 1.8) !important;
    min-height: 0 !important;
    padding: 0 !important;
    cursor: pointer;
    font-size: 18px;
    line-height: 1;
    color: var(--xq-muted);
    background: transparent !important;
    transition: color 0.12s ease;
}

.xq-qty__minus {
    left: 9%;
}

.xq-qty__plus {
    right: 9%;
}

.xq-qty__btn:hover {
    color: var(--xq-ink);
    background: transparent !important;
}

.xq-qty__input {
    position: absolute;
    inset: 0;
    width: 100% !important;
    max-width: none;
    padding: 0 calc(55px / 1.8 + 9%) !important;
    border: 1px solid var(--xq-line) !important;
    background: transparent;
    font-size: 0.9em;
    -moz-appearance: textfield;
}

.xq-qty__btn:focus,
.xq-qty__btn:focus-visible,
.xq-qty__input:focus,
.xq-qty__input:focus-visible {
    border-color: var(--xq-line) !important;
    box-shadow: none !important;
    outline: none !important;
}

.xq-qty__input::-webkit-inner-spin-button,
.xq-qty__input::-webkit-outer-spin-button {
    margin: 0;
    -webkit-appearance: none;
}

.xq-drawer .xq-qty {
    width: 130px;
    min-width: 130px;
    height: 55px;
}

.xq-drawer .xq-qty__btn,
.xq-drawer .xq-qty__input {
    color: #31465f !important;
    font-weight: 500 !important;
}

.xq-drawer .xq-qty__input {
    border: 1px solid var(--xq-line) !important;
    font-size: 0.9em;
}

.xq-remove {
    border: 0;
    background: transparent;
    color: var(--xq-link);
    cursor: pointer;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.2;
    box-sizing: border-box;
    min-width: 0;
    min-height: 0;
    padding: 4px 0;
    appearance: none;
    -webkit-appearance: none;
}

.xq-drawer .xq-remove {
    flex: 0 0 auto;
}

.xq-drawer-footer {
    flex: 0 0 auto;
    padding: 18px 24px max(26px, calc(18px + env(safe-area-inset-bottom)));
    border-top: 1px solid var(--xq-line);
    background: var(--xq-panel);
}

.xq-total-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
    color: var(--xq-ink);
    font-size: 18px;
}

.xq-primary-cta,
.xq-submit,
.xq-keep-shopping {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    border-radius: 4px;
    text-decoration: none;
    text-transform: uppercase;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.01em;
}

.xq-primary-cta,
.xq-submit {
    width: 100%;
    border: 0;
    background: var(--xq-accent);
    color: #ffffff !important;
    cursor: pointer;
}

.xq-primary-cta:hover,
.xq-submit:hover {
    background: var(--xq-accent-hover);
}

.xq-drawer__close:focus-visible,
.xq-remove:focus-visible,
.xq-primary-cta:focus-visible,
.xq-submit:focus-visible,
.xq-keep-shopping:focus-visible,
.xq-notes textarea:focus-visible,
.xq-field input:focus-visible,
.xq-field select:focus-visible,
.xq-field textarea:focus-visible {
    outline: 2px solid var(--xq-focus);
    outline-offset: 2px;
}

.xq-empty {
    display: flex;
    flex: 1;
    flex-direction: column;
    justify-content: center;
    padding: 48px 24px;
    color: var(--xq-muted);
    text-align: center;
}

.xq-empty p {
    margin: 0 0 8px;
    color: var(--xq-ink);
    font-weight: 700;
}

.xq-empty--page {
    align-items: center;
    min-height: 360px;
    padding: 86px 32px;
    border: 1px solid var(--xq-line);
    border-radius: 8px;
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
}

.xq-empty--page p {
    margin-bottom: 12px;
    color: #3f4d5f;
    font-size: clamp(24px, 1.45vw, 28px);
    font-weight: 600;
    line-height: 1.25;
}

.xq-empty--page small {
    color: var(--xq-muted);
    font-size: 16px;
    line-height: 1.45;
}

body.xq-drawer-open {
    overflow: hidden;
}

.xq-request-page {
    max-width: min(1652px, calc(100vw - 92px));
    margin: 0 auto;
    padding: 30px 0 64px;
    color: var(--xq-ink);
}

.xq-request-page__top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 42px;
}

.xq-request-page h1 {
    margin: 0;
    color: var(--xq-heading);
    font-size: clamp(34px, 2.35vw, 44px);
    font-weight: 700;
    line-height: 1.12;
    letter-spacing: 0;
}

.xq-keep-shopping {
    min-width: 222px;
    padding: 0 24px;
    border: 1px solid #d8dee7;
    border-radius: 6px;
    background: #ffffff;
    color: #2c3e50;
}

.xq-keep-shopping:hover {
    border-color: #2c3e50;
    background: #2c3e50;
    color: #ffffff;
}

.xq-request-page__layout {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(320px, 1fr);
    gap: 40px;
    align-items: start;
}

.xq-request-cart {
    display: grid;
    gap: 28px;
    min-width: 0;
}

.xq-request-items {
    margin-top: 7px;
}

.xq-request-items__head,
.xq-request-item {
    display: grid;
    grid-template-columns: 92px minmax(0, 1fr) 150px 130px;
    column-gap: 22px;
    align-items: center;
}

.xq-request-items__head {
    padding: 0 0 18px;
    border-bottom: 2px solid var(--theme-table-border-color, var(--theme-border-color, #e5e7eb));
    color: var(--theme-headings-color, var(--xq-heading));
    font-size: 15px;
    font-weight: 600;
}

.xq-request-items__head span:last-child {
    text-align: right;
}

.xq-request-item {
    position: relative;
    padding: 18px 0;
    border-bottom: 1px dashed var(--theme-table-border-color, var(--theme-border-color, #e5e7eb));
}

.xq-request-item__thumb {
    width: 76px;
    height: 76px;
    border-radius: 4px;
}

.xq-request-item__title {
    display: block;
    margin-bottom: 8px;
    color: var(--xq-ink);
    font-size: 15px;
    font-weight: 500;
    line-height: 1.4;
}

.xq-request-item .xq-qty {
    width: 130px;
    min-width: 130px;
}

.xq-request-item__quantity {
    justify-self: start;
}

.xq-request-item__amount {
    color: var(--xq-ink);
    font-size: 15px;
    font-weight: 600;
    text-align: right;
}

.xq-request-item__remove {
    margin-top: 8px;
    color: var(--xq-link);
    font-size: 13px;
}

.xq-summary {
    margin: 0;
    padding: 0;
}

.xq-summary div {
    display: flex;
    justify-content: space-between;
    gap: 24px;
    padding: 16px 0;
    border-bottom: 1px dashed var(--theme-table-border-color, var(--theme-border-color, #e5e7eb));
    color: var(--xq-muted);
    font-size: 15px;
}

.xq-summary dt,
.xq-summary dd {
    margin: 0;
}

.xq-summary__total {
    color: var(--xq-ink) !important;
    font-size: 16px !important;
    font-weight: 700;
}

.xq-request-sidebar {
    position: sticky;
    top: calc(50px + var(--admin-bar, 0px) + var(--header-sticky-height, 0px) * (var(--sticky-shrink, 100) / 100));
}

.xq-request-totals,
.xq-request-form {
    padding: var(--cart-totals-padding, 35px);
    border: var(--cart-totals-border, 1px solid var(--theme-border-color, #e5e7eb));
    border-radius: var(--cart-totals-border-radius, 6px);
    background: #ffffff;
}

.xq-request-totals h2,
.xq-request-form h2 {
    margin: 0 0 18px;
    color: var(--theme-headings-color, var(--xq-heading));
    font-size: 15px;
    font-weight: 700;
    line-height: 1.3;
    letter-spacing: 0;
}

.xq-request-totals:empty {
    display: none;
}

.xq-notes span,
.xq-field span {
    display: block;
    margin-bottom: 8px;
    color: #77777d;
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0;
    line-height: 1.25;
    text-transform: none;
}

.xq-field span em {
    margin-left: 1px;
    color: #77777d;
    font-style: normal;
}

.xq-notes {
    display: block;
    max-width: none;
}

.xq-notes textarea,
.xq-field input,
.xq-field textarea,
.xq-field select {
    width: 100%;
    border: 1px solid #d2d2d7;
    border-radius: 8px;
    background: #ffffff;
    color: #1d1d1f;
    font-size: 15px;
    box-shadow: none;
    outline: none !important;
    transition: border-color 0.2s ease, background 0.2s ease;
}

.xq-notes textarea:focus,
.xq-notes textarea:focus-visible,
.xq-field input:focus,
.xq-field input:focus-visible,
.xq-field textarea:focus,
.xq-field textarea:focus-visible,
.xq-field select:focus,
.xq-field select:focus-visible {
    border-color: #1d1d1f !important;
    background: #ffffff !important;
    box-shadow: none !important;
    outline: none !important;
}

.xq-request-form .xq-field input,
.xq-request-form .xq-field textarea {
    border: 1px solid #d2d2d7 !important;
    border-radius: 8px !important;
    background-color: #ffffff !important;
    color: #1d1d1f !important;
    font-size: 15px !important;
    box-shadow: none !important;
}

.xq-field input::placeholder,
.xq-field textarea::placeholder {
    color: #86868b;
    opacity: 1;
}

.xq-field select {
    min-height: 51px;
    padding: 0 42px 0 20px;
    appearance: none;
    background-image: linear-gradient(45deg, transparent 50%, #132a4f 50%), linear-gradient(135deg, #132a4f 50%, transparent 50%);
    background-position: calc(100% - 24px) 50%, calc(100% - 18px) 50%;
    background-repeat: no-repeat;
    background-size: 6px 6px, 6px 6px;
}

.xq-notes textarea {
    min-height: 50px;
}

.xq-request-form {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 18px;
}

.xq-request-sidebar .xq-request-form {
    grid-template-columns: 1fr;
}

.xq-field--full,
.xq-form-message,
.xq-request-form h2 {
    grid-column: 1 / -1;
}

.xq-field {
    grid-column: span 3;
}

.xq-request-sidebar .xq-field,
.xq-field--email,
.xq-field--address,
.xq-request-form .xq-field--full {
    grid-column: 1 / -1;
}

.xq-field--email {
    order: initial;
}

.xq-field--third {
    grid-column: span 2;
}

.xq-form-divider {
    grid-column: 1 / -1;
    height: 1px;
    margin: 10px 0 16px;
    background: #d8d8d8;
}

.xq-field input {
    min-height: 52.5px !important;
    padding: 14px 16px !important;
}

.xq-field textarea {
    min-height: 126px !important;
    padding: 14px 16px !important;
}

.xq-request-form .xq-submit {
    grid-column: 1 / -1;
    justify-self: stretch;
    width: 100%;
    min-height: 50px;
    margin-top: 2px;
    border: 0;
    background-color: #8c97aa !important;
    color: #ffffff !important;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 800;
    text-transform: uppercase;
    opacity: 1;
    box-shadow: none;
    text-shadow: none;
}

.xq-request-form .xq-submit:not(:disabled) {
    background-color: #2c3e50 !important;
    cursor: pointer;
}

.xq-request-form .xq-submit:disabled {
    cursor: not-allowed;
}

.xq-request-form .xq-submit:not(:disabled):hover,
.xq-request-form .xq-submit:not(:disabled):focus-visible {
    background-color: #2c3e50 !important;
    color: #ffffff !important;
}

.xq-request-form .xq-submit:focus-visible {
    outline: 2px solid #17191c;
    outline-offset: 2px;
}

.xq-form-message {
    min-height: 24px;
    color: var(--xq-muted);
}

.xq-form-message--error {
    color: #b42318;
}

.xq-form-message--success {
    color: #147d52;
}

.xq-is-submitting {
    opacity: 0.72;
    pointer-events: none;
}

@media (max-width: 1000px) {
    .xq-request-page__layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .xq-request-sidebar {
        position: static;
    }
}

@media (max-width: 900px) {
    .xq-request-page__top {
        display: block;
    }

    .xq-request-page__top .xq-back-button {
        display: none;
    }

    .xq-keep-shopping {
        margin-top: 18px;
    }
}

body:has(.xq-request-page) .entry-header,
body:has(.xq-request-page) .hero-section {
    display: none;
}

@media (max-width: 640px) {
    .xq-drawer__header,
    .xq-drawer-list,
    .xq-drawer-footer {
        padding-right: 18px;
        padding-left: 18px;
    }

    .xq-request-page {
        max-width: calc(100vw - 32px);
        padding-top: 26px;
    }

    .xq-request-page h1 {
        font-size: 34px;
    }

    .xq-request-page__top {
        margin-bottom: 34px;
    }

    .xq-request-item {
        grid-template-columns: 82px 1fr;
        gap: 16px;
        align-items: start;
    }

    .xq-request-items__head {
        display: none;
    }

    .xq-request-item__thumb {
        width: 82px;
        height: 82px;
    }

    .xq-request-item__title {
        font-size: 16px;
        line-height: 1.28;
    }

    .xq-request-item__quantity,
    .xq-request-item__amount {
        grid-column: 2;
        justify-self: start;
        text-align: left;
    }

    .xq-request-item__amount {
        font-size: 16px;
    }

    .xq-request-item .xq-qty {
        margin-top: 18px;
    }

    .xq-summary div {
        font-size: 17px;
    }

    .xq-summary__total {
        font-size: 23px !important;
    }

    .xq-request-form {
        grid-template-columns: 1fr;
    }

    .xq-request-totals,
    .xq-request-form {
        padding: 24px 18px;
    }

    .xq-field,
    .xq-field--third,
    .xq-request-form .xq-submit {
        grid-column: 1 / -1;
    }

    .xq-notes {
        max-width: none;
    }
}
