html.dr-catalog-locked { overflow: hidden; }
.dr-catalog-dialog, .dr-catalog-toast {
    box-sizing: border-box;
    background: #fff;
    color: #173f61;
    border: 1px solid #dce8ef;
    border-radius: 20px;
    box-shadow: 0 16px 48px rgb(12 46 73 / 20%);
    font: 15px/1.5 Inter, Arial, sans-serif;
}
.dr-catalog-dialog {
    width: min(460px, calc(100% - 28px));
    max-height: calc(100dvh - 28px);
    padding: 0;
    overscroll-behavior: contain;
}
.dr-catalog-dialog::backdrop { background: rgb(11 36 61 / 45%); }
.dr-catalog-dialog form { position: relative; padding: clamp(18px, 4vw, 30px); }
.dr-catalog-dialog h2 { margin: 0 40px 4px 0; font: 500 clamp(23px, 5vw, 29px)/1.2 Georgia, serif; color: #11385a; }
.dr-catalog-model { margin: 8px 0 18px; font-weight: 650; }
.dr-catalog-dialog button, .dr-catalog-toast button { cursor: pointer; }
.dr-catalog-dialog button:disabled { cursor: default; opacity: .55; }
.dr-catalog-close, .dr-catalog-amount button {
    border: 1px solid #cfdfeb;
    border-radius: 10px;
    background: #f4f9fd;
    color: #175581;
    min-width: 44px;
    min-height: 44px;
    font-size: 20px;
}
.dr-catalog-close { position: absolute; inset: 10px 10px auto auto; }
.dr-catalog-option { padding: 12px; background: #eef7fd; border-radius: 12px; }
.dr-catalog-option label { display: flex; gap: 8px; align-items: center; min-height: 32px; font-weight: 650; cursor: pointer; }
.dr-catalog-option input { margin: 0; accent-color: #075c9e; }
.dr-catalog-option small { display: block; margin-inline-start: 22px; }
.dr-catalog-amount { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 16px; margin-block: 16px; }
.dr-catalog-amount div { display: flex; gap: 5px; }
.dr-catalog-amount input { box-sizing: border-box; width: 62px; text-align: center; border: 1px solid #cfdfeb; border-radius: 10px; color: inherit; padding: 0 3px; }
.dr-catalog-total { display: flex; justify-content: space-between; gap: 6px; margin: 10px 0; font-weight: 700; }
.dr-catalog-total output { color: #10345c; font-size: 21px; }
.dr-catalog-error { color: #992e2b; }
.dr-catalog-error:empty { display: none; }
.dr-catalog-dialog [type=submit] { width: 100%; margin-top: 10px; border: 0; }
/* Confirmation after a successful add-to-cart, shared by catalog and product pages. */
.dr-catalog-toast {
    position: fixed;
    z-index: 10000;
    inset: auto 16px 16px auto;
    width: min(376px, calc(100% - 32px));
    padding: 16px;
}
.dr-catalog-toast p {
    margin: 0 0 12px;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.35;
    text-align: center;
}
.dr-catalog-toast div {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    align-items: stretch;
}
.dr-catalog-toast :is(a, button) {
    box-sizing: border-box;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    min-height: 44px;
    margin: 0;
    padding: 9px 6px;
    border: 1px solid #cfdfeb;
    border-radius: 12px;
    background: #f4f9fd;
    color: #075c9e;
    font: 600 14px/1.3 Inter, Arial, sans-serif;
    text-decoration: none;
    text-align: center;
    white-space: normal;
    cursor: pointer;
    transition: background-color .16s ease, border-color .16s ease;
}
.dr-catalog-toast a {
    background: #075c9e;
    border-color: #075c9e;
    color: #fff;
}
.dr-catalog-toast button:hover { background: #e9f3fb; border-color: #a7c7df; }
.dr-catalog-toast a:hover { background: #064c83; border-color: #064c83; color: #fff; }
.dr-catalog-toast :is(a, button):focus-visible { outline: 2px solid #075c9e; outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) {
    .dr-catalog-toast :is(a, button) { transition: none; }
}

@media (max-width: 720px) {
    .dr-catalog-toast {
        inset: auto 16px calc(16px + env(safe-area-inset-bottom, 0px)) 16px;
        width: auto;
        max-width: none;
        margin: 0;
    }
    .dr-catalog-toast p { text-align: center; }
    .dr-catalog-toast div { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; }
    .dr-catalog-toast a, .dr-catalog-toast button {
        box-sizing: border-box;
        width: 100%;
        min-height: 44px;
        justify-content: center;
        padding: 10px 12px;
        border: 1px solid #cfdfeb;
        border-radius: 12px;
        text-align: center;
        text-decoration: none;
    }
    .dr-catalog-toast button { background: #f4f9fd; color: #075c9e; }
    .dr-catalog-toast a { background: #075c9e; border-color: #075c9e; color: #fff; }
    .dr-catalog-toast :is(a, button):focus-visible { outline: 2px solid #075c9e; outline-offset: 2px; }
}
