/* ==========================================================================
   Wyszukiwarka — arkusz pełnoekranowy (dialog #dw-search-dialog)
   ========================================================================== */
.dw-search-dialog.has-ss {
    width: 100%; max-width: none; height: 100%; max-height: none; margin: 0; padding: 0;
    border: 0; background: #fff; color: var(--dw-ink, #272727);
}
.dw-search-dialog.has-ss::backdrop { background: rgba(39, 39, 39, .35); }
.dw-search-dialog.has-ss > :not(.dw-ss) { display: none !important; }
html.dw-ss-open, html.dw-ss-open body { overflow: hidden; }

.dw-ss { display: flex; flex-direction: column; height: 100%; }

.dw-ss__bar {
    display: flex; align-items: center; gap: 12px;
    padding: calc(12px + env(safe-area-inset-top)) 16px 12px 20px;
    border-bottom: 1px solid var(--dw-line, #ece6dc);
}
.dw-ss__field {
    flex: 1; display: flex; align-items: center; gap: 10px; min-width: 0;
    height: 48px; padding: 0 6px 0 16px;
    border: 1px solid transparent; border-radius: 100px; background: var(--dw-cream, #f8f5ef);
    transition: border-color .2s, background-color .2s;
}
.dw-ss__field:focus-within { border-color: #b39365; background: #fff; }
.dw-ss__icon { display: grid; color: var(--dw-ink-2, #4a545e); }
.dw-ss__input {
    flex: 1; min-width: 0; height: 100%; padding: 0; border: 0; outline: none; background: none;
    font: inherit; font-size: 16px; /* ≥16 px — iOS nie powiększa strony przy fokusie */
    color: var(--dw-ink, #272727); -webkit-appearance: none; appearance: none;
}
.dw-ss__input::placeholder { color: #8a8f94; }
.dw-ss__input::-webkit-search-cancel-button { display: none; }
.dw-ss__clear {
    display: grid; place-items: center; flex: 0 0 36px; height: 36px; padding: 0;
    border: 0; border-radius: 50%; background: #e9e1d3; color: var(--dw-ink, #272727); cursor: pointer;
}
.dw-ss__clear[hidden] { display: none; }
.dw-ss__cancel {
    min-height: 44px; padding: 0 4px; border: 0; background: none; cursor: pointer;
    font: inherit; font-size: 15px; color: var(--dw-ink, #272727);
}

.dw-ss__body { flex: 1; overflow-y: auto; overscroll-behavior: contain; padding: 20px 20px calc(28px + env(safe-area-inset-bottom)); }
.dw-ss__h {
    margin: 0 0 12px; font-size: 13px; letter-spacing: .08em; text-transform: uppercase; color: var(--dw-gold-text, #7f6440);
}
.dw-ss__h span { margin-left: 6px; color: #8a8f94; letter-spacing: 0; }

.dw-ss__chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 28px; }
.dw-ss__chip {
    min-height: 44px; padding: 0 16px; border: 1px solid var(--dw-line, #ece6dc); border-radius: 100px;
    background: #fff; cursor: pointer; font: inherit; font-size: 15px; color: var(--dw-ink, #272727);
}
.dw-ss__chip:active { background: var(--dw-cream, #f8f5ef); border-color: #b39365; }

.dw-ss__help {
    padding: 20px; border-radius: 20px; background: var(--dw-cream, #f8f5ef);
    box-shadow: inset 10px 14px 54px rgba(179, 147, 101, .16);
}
.dw-ss__help p { margin: 0; font-size: 15px; line-height: 1.5; color: var(--dw-ink-2, #4a545e); }
.dw-ss__help-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.dw-ss__btn {
    display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 20px;
    border: 1px solid #b39365; border-radius: 100px; text-decoration: none;
    font-size: 13px; letter-spacing: .05em; text-transform: uppercase; color: var(--dw-gold-text, #7f6440);
}
.dw-ss__btn--dark { background: var(--dw-ink, #272727); border-color: var(--dw-ink, #272727); color: #fff; }

.dw-ss__group + .dw-ss__group { margin-top: 24px; }
.dw-ss__item {
    position: relative;
    display: flex; align-items: center; gap: 12px; min-height: 60px; padding: 10px 12px; margin: 0 -12px;
    border-radius: 12px; color: var(--dw-ink, #272727); text-decoration: none;
}
.dw-ss__item + .dw-ss__item::before {
    content: ""; position: absolute; top: 0; left: 12px; right: 12px; height: 1px; background: #f0ebe2;
}
.dw-ss__item:active, .dw-ss__item.is-active { background: var(--dw-cream, #f8f5ef); }
.dw-ss__item:active::before, .dw-ss__item.is-active::before,
.dw-ss__item:active + .dw-ss__item::before, .dw-ss__item.is-active + .dw-ss__item::before { display: none; }
.dw-ss__item-main { display: flex; flex-direction: column; gap: 3px; flex: 1; min-width: 0; }
.dw-ss__item-title { font-size: 16px; line-height: 1.3; }
.dw-ss__item-title mark { background: none; color: inherit; font-weight: 600; text-decoration: underline; text-decoration-color: #b39365; text-underline-offset: 3px; }
.dw-ss__item-meta { font-size: 13px; color: #6b7178; }
.dw-ss__item-price { font-size: 14px; white-space: nowrap; color: var(--dw-gold-text, #7f6440); }
.dw-ss__item-chev { display: grid; color: #b0a491; }
.dw-ss__more {
    min-height: 44px; margin-top: 4px; padding: 0; border: 0; background: none; cursor: pointer;
    font: inherit; font-size: 14px; color: var(--dw-gold-text, #7f6440); text-decoration: underline; text-underline-offset: 4px;
}
.dw-ss__all {
    display: flex; align-items: center; justify-content: space-between; min-height: 48px; margin-top: 28px; padding: 0 22px;
    border: 1px solid #b39365; border-radius: 100px; text-decoration: none;
    font-size: 14px; letter-spacing: .05em; text-transform: uppercase; color: var(--dw-gold-text, #7f6440);
}
.dw-ss__none-title { margin: 8px 0 6px; font-size: 20px; color: var(--dw-ink, #272727); }
.dw-ss__none-text { margin: 0; font-size: 15px; line-height: 1.5; color: var(--dw-ink-2, #4a545e); }

.dw-ss a:focus-visible, .dw-ss button:focus-visible { outline: 2px solid var(--dw-gold-text, #7f6440); outline-offset: 2px; }

@media (min-width: 768px) {
    /* tablet/desktop: arkusz jako wycentrowane okno */
    .dw-search-dialog.has-ss { width: min(680px, 100% - 48px); height: min(720px, 100% - 96px); margin: 48px auto auto; border-radius: 24px; }
}
