.shop { --paper: #fffaf3; }
.shop main { max-width: 76rem; }
.shop h1 { text-align: left; font-size: clamp(2.3rem, 5vw, 4rem); margin: .4em 0; }
.shop h2 { margin: .2em 0; }
.shop h3 { margin: .2em 0; line-height: 1.3; }
.shop button, .shop input, .shop select { font: inherit; }
.shop button { font-weight: 650; }
.shop button:disabled { opacity: .55; cursor: not-allowed; }
.shop :focus-visible { outline: 3px solid #287a86; outline-offset: 4px; }
.shop [hidden] { display: none !important; }
.shop-hero { display: grid; grid-template-columns: 1.4fr 1fr; gap: 2rem; align-items: center; padding: 2rem 3rem; border-radius: 24px; background: #f5e3cc; margin: 1rem 0 3rem; }
.shop-hero p { max-width: 34rem; }
.shop-hero figure { margin: 0; text-align: center; }
.shop-hero img { height: 310px; width: 100%; object-fit: contain; }
.shop-hero figcaption { font-size: .85rem; color: var(--text-muted); }
.eyebrow { text-transform: uppercase; letter-spacing: .13em; font-size: .75rem; font-weight: 750; color: var(--accent); }
.muted { color: var(--text-muted); font-size: .875rem; }
.shop-link { display: inline-block; color: var(--accent); font-weight: 700; padding: .6rem 0; }
.section-heading { display: flex; justify-content: space-between; gap: 1rem; align-items: center; margin-bottom: 1.5rem; }
.filters { display: flex; gap: .85rem; align-items: end; flex-wrap: wrap; border: 1px solid #e5d5c2; border-radius: 18px; background: #f7eee3; padding: 1.1rem; }
.shop label { display: grid; gap: .4rem; font-size: .875rem; }
.filters .search { flex: 1 1 15rem; }
.shop .check { display: flex; align-items: center; gap: .5rem; min-height: 44px; }
.shop input[type="checkbox"] { width: 1.15rem; height: 1.15rem; }
.shop .secondary { background: transparent; color: var(--accent); border: 1px solid #bca286; }
.shop .secondary:hover { background: #f2dfc9; }
/* Поля и переключатели фильтра сохраняют нативное управление с клавиатуры. */
.filters > label:not(.check) { color: #715744; font-size: .75rem; font-weight: 650; gap: .5rem; }
.filters input[type="search"], .filters select { height: 46px; border: 1px solid #d7c4ae; border-radius: 11px; background-color: #fffdf9; color: var(--text); font-size: .875rem; font-weight: 400; box-shadow: 0 2px 3px #593b2010; }
.filters input[type="search"] { width: 100%; padding-left: 2.6rem; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' fill='none' stroke='%238b6c52' stroke-width='1.7' stroke-linecap='round'%3E%3Ccircle cx='8.5' cy='8.5' r='5.5'/%3E%3Cpath d='m13 13 4 4'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: .85rem center; }
.filters select { appearance: none; padding: 0 2.4rem 0 .85rem; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%238b6c52' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m4 6 4 4 4-4'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right .8rem center; }
.filters input[type="search"]::placeholder { color: #8a7767; }
.filters .check { position: relative; height: 46px; padding: 0 .85rem; gap: .55rem; border: 1px solid #d7c4ae; border-radius: 11px; background: #fffdf9; color: #715744; cursor: pointer; font-size: .8125rem; white-space: nowrap; }
.filters .check:hover { border-color: #a57a52; }
.filters .check:has(:checked) { background: #efe0cd; border-color: #a57a52; color: #713c18; }
.filters .check input { appearance: none; flex-shrink: 0; width: 18px; height: 18px; margin: 0; border: 1.5px solid #b39b81; border-radius: 5px; background: white; }
.filters .check input:checked { border-color: var(--accent); background: var(--accent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 18 18' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m4 9 3 3 7-7'/%3E%3C/svg%3E") center / 16px; }
.filters button[type="reset"] { min-height: 46px; padding: .5rem .65rem; border-color: transparent; border-radius: 10px; font-size: .8125rem; font-weight: 600; color: #715744; }
@media (forced-colors: active) { .filters .check input { appearance: auto; } .filters select { appearance: auto; } }
.products { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.4rem; }
.product { border-radius: 16px; background: var(--paper); overflow: hidden; border: 1px solid #e2d2c0; display: flex; flex-direction: column; }
.product-art { position: relative; background: #efe2cf; }
.product:nth-child(3n + 2) .product-art { background: #e5e8dc; }
.product:nth-child(3n) .product-art { background: #efe0d8; }
.product-art img { width: 100%; height: 220px; object-fit: contain; padding: 1rem; display: block; }
.product .favorite { position: absolute; top: .8rem; right: .8rem; width: 44px; height: 44px; padding: 0; background: var(--paper); font-size: 1.4rem; }
.product-body { padding: 1.2rem; display: flex; flex: 1; flex-direction: column; }
.product-body p { margin: .3rem 0 .7rem; }
.product-description { font-size: .9rem; }
.product h3 a { color: inherit; text-decoration: none; }
.product h3 a:hover { text-decoration: underline; text-underline-offset: .2em; }
#product-page > a { color: var(--accent); text-underline-offset: .25em; }
.product-detail { display: grid; grid-template-columns: 1.1fr 1fr; gap: 2.5rem; align-items: start; margin-top: 2rem; }
.detail-gallery { min-width: 0; }
.shop .gallery-zoom { display: block; width: 100%; padding: 1.5rem; border-radius: 20px; background: #efe2cf; cursor: zoom-in; }
.gallery-zoom img { display: block; width: 100%; height: auto; }
.detail-price { font-size: 2rem; font-weight: 750; }
.detail-actions { display: flex; flex-wrap: wrap; gap: .75rem; }
.detail-gallery dialog img { display: block; width: 100%; }
@media (max-width: 650px) { .product-detail { grid-template-columns: 1fr; gap: 1rem; } }
.product-bottom { display: flex; gap: .5rem; justify-content: space-between; align-items: center; margin-top: auto; }
.price { white-space: nowrap; font-size: 1.15rem; }
.product-bottom button { padding: .5rem .9rem; font-size: .85rem; }
.shop-note { margin-top: 3rem; padding: 2rem; border-block: 1px solid #d9c5af; }
.shop-note p { max-width: 45rem; }
.shop dialog { width: min(40rem, calc(100% - 1.5rem)); max-height: 90dvh; padding: 1.5rem; border: 1px solid #d9c5af; border-radius: 20px; background: var(--paper); color: var(--text); }
.shop dialog::backdrop { background: rgb(43 33 27 / 55%); }
.shop:has(dialog[open]) { overflow: hidden; }
.cart-row { display: grid; grid-template-columns: 1fr auto; gap: .5rem; padding: 1rem 0; border-bottom: 1px solid #d9c5af; }
.quantity { display: flex; gap: .6rem; align-items: center; }
.quantity button { min-width: 44px; min-height: 44px; padding: .3rem; }
.cart-row .remove { font-size: .8rem; padding: .4rem .7rem; }
.promo { display: flex; gap: .75rem; align-items: end; margin-top: 1.5rem; }
.promo label { min-width: 0; flex: 1; }
.totals div { display: flex; justify-content: space-between; gap: 1rem; margin: .5rem 0; }
.totals dd { margin: 0; }
.grand-total { font-weight: 750; font-size: 1.3rem; border-top: 1px solid #d9c5af; padding-top: .6rem; }
#order-form { display: grid; gap: .8rem; border-top: 1px solid #d9c5af; padding-top: 1rem; }
#order-form p { margin: 0; }
#clear-cart { margin-top: 1rem; }
.error { color: #a02222; }
.notice:not(:empty), .storage-warning:not(:empty) { position: fixed; bottom: 1rem; left: 50%; transform: translateX(-50%); z-index: 20; margin: 0; padding: .8rem 1.2rem; width: max-content; max-width: 90%; background: #2b211b; color: white; border-radius: 12px; box-shadow: 0 4px 20px #0002; }
.storage-warning:not(:empty) { bottom: 5rem; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 1rem; top: 1rem; z-index: 30; background: white; padding: 1rem; }
@media (max-width: 850px) { .products { grid-template-columns: repeat(2, minmax(0, 1fr)); } .shop-hero { padding: 1.5rem; gap: 1rem; } }
@media (max-width: 540px) { .shop-hero { grid-template-columns: 1fr; } .shop-hero img { height: 220px; } .products { grid-template-columns: 1fr; } .filters > label { flex: 1 1 100%; } .section-heading { flex-wrap: wrap; } .cart-row { grid-template-columns: 1fr; } .shop dialog { padding: 1rem; } }
