:root { color-scheme: light; --ink: #17221b; --muted: #68736c; --cream: #f5f1e8; --card: #fffefa; --green: #24543b; --accent: #e77d4e; }
* { box-sizing: border-box; }
body { margin: 0; background: var(--cream); color: var(--ink); font: 16px/1.5 Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
button, input, select { font: inherit; }
.store-header { display: flex; align-items: center; gap: .75rem; padding: .5rem max(1rem, calc((100vw - 1180px) / 2)); background: rgba(255,254,250,.94); border-bottom: 1px solid #ded8cc; position: sticky; top: 0; z-index: 5; backdrop-filter: blur(12px); }
.brand { display: inline-flex; flex: 0 1 auto; align-items: center; min-width: 0; gap: .45rem; color: var(--ink); font-family: Inter, system-ui, -apple-system, sans-serif; font-size: 1.18rem; font-weight: 900; line-height: 1; text-decoration: none; letter-spacing: -.6px; text-transform: uppercase; white-space: nowrap; }
.brand-logo { display: block; flex: 0 0 auto; width: 2.25rem; height: 2.25rem; object-fit: contain; }
.brand-name { overflow: hidden; text-overflow: ellipsis; }
.header-search { flex: 1 1 12rem; min-width: 0; }
.header-search input { width: 100%; min-height: 2.65rem; padding: .6rem .8rem; color: var(--ink); background: #f1eee7; border: 1px solid transparent; border-radius: 999px; }
.header-search input:focus { background: white; border-color: var(--green); outline: 2px solid #24543b22; }
.admin-link { padding: .4rem .65rem; color: var(--green); border: 1px solid #b8c9bc; border-radius: 999px; font-size: .78rem; font-weight: 750; text-decoration: none; white-space: nowrap; }
.admin-link:hover, .admin-link:focus-visible { color: white; background: var(--green); outline: none; }
main { width: min(1180px, calc(100% - 2rem)); margin: 0 auto; padding-bottom: 8rem; }
.store-footer { padding: 1.5rem 1rem 7rem; color: var(--muted); font-size: .72rem; text-align: center; }
.filters { padding: .35rem 0 0; }
.quick-filters { display: flex; align-items: center; gap: .5rem; min-width: 0; }
.filters label, .filter-group { display: grid; min-width: 0; gap: .35rem; color: var(--muted); font-size: .78rem; font-weight: 700; }
.price-order-filter { width: min(100%, 14rem); }
.filters input, .filters select { width: 100%; min-height: 2.8rem; padding: .65rem .8rem; color: var(--ink); background: white; border: 1px solid #cfc9bd; border-radius: .65rem; }
.filter-chips { display: flex; gap: 8px; padding: .05rem 0 .2rem; overflow-x: auto; overscroll-behavior-inline: contain; white-space: nowrap; scrollbar-width: none; }
.filter-chips::-webkit-scrollbar { display: none; }
.quick-filters .filter-chips { flex: 1; }
.filter-chips-wrap { flex-wrap: wrap; overflow: visible; white-space: normal; }
.filter-chip { flex: 0 0 auto; min-height: 2.35rem; padding: .45rem .75rem; color: var(--green); background: white; border: 1px solid #bfc9c1; border-radius: 999px; font-size: .76rem; font-weight: 800; white-space: nowrap; cursor: pointer; }
.filter-chip:hover { border-color: var(--green); background: #eef5f0; }
.filter-chip.is-active { color: white; background: var(--green); border-color: var(--green); box-shadow: 0 4px 12px #24543b33; }
.more-filters, .apply-filters { flex: 0 0 auto; min-height: 2.35rem; padding: .45rem .7rem; color: var(--green); background: white; border: 1px solid #bfc9c1; border-radius: 999px; font-size: .76rem; font-weight: 800; white-space: nowrap; cursor: pointer; }
.more-filters:hover, .more-filters:focus-visible { border-color: var(--green); background: #eef5f0; outline: none; }
.filters-dialog { width: min(100%, 31rem); max-width: 31rem; margin: auto 0 0; padding: 0; color: var(--ink); background: var(--card); border: 0; border-radius: 1.15rem 1.15rem 0 0; box-shadow: 0 -12px 45px #17221b44; }
.filters-dialog::backdrop { background: #111a15a6; backdrop-filter: blur(2px); }
.filters-drawer { display: grid; gap: 1rem; padding: 1.1rem; }
.filters-drawer-heading { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.filters-drawer-heading h2 { margin: 0; font-size: 1.15rem; }
.filters-close { width: 2.3rem; height: 2.3rem; padding: 0; color: var(--ink); background: #eee9df; border: 0; border-radius: 50%; font-size: 1.35rem; cursor: pointer; }
.filters-drawer .filter-group { gap: .45rem; }
.filters-drawer .price-order-filter { width: 100%; }
.apply-filters { width: 100%; color: white; background: var(--green); border-color: var(--green); border-radius: .65rem; }
.status { margin: .75rem 0 .65rem; color: var(--muted); font-size: .78rem; }
.product-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem; }
.product-card { overflow: hidden; background: var(--card); border: 1px solid #e0dacd; border-radius: .9rem; box-shadow: 0 8px 25px rgba(36,49,41,.05); cursor: pointer; }
.product-card:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.product-media { position: relative; aspect-ratio: 4 / 5; overflow: hidden; background: #e8e4dc; }
.gallery-badge { position: absolute; right: .55rem; bottom: .55rem; padding: .3rem .5rem; color: white; background: #17221bd9; border-radius: 999px; font-size: .68rem; font-weight: 800; }
.product-media img { width: 100%; height: 100%; display: block; object-fit: cover; transition: opacity .2s ease; }
.is-loading { background: linear-gradient(100deg, #e7e2d9 30%, #f7f4ed 50%, #e7e2d9 70%); background-size: 240% 100%; animation: skeleton 1.4s ease-in-out infinite; }
.is-loading > img { opacity: 0; }
.product-media.image-missing img { visibility: hidden; }
.card-thumbnails { display: flex; gap: .4rem; padding: .45rem .55rem 0; overflow-x: auto; background: var(--card); }
.card-thumbnails[hidden] { display: none; }
.card-thumbnails button { flex: 0 0 2.75rem; width: 2.75rem; height: 2.75rem; padding: 0; overflow: hidden; background: #e8e4dc; border: 2px solid transparent; border-radius: .4rem; cursor: pointer; }
.card-thumbnails button.is-active { border-color: var(--accent); }
.card-thumbnails img { width: 100%; height: 100%; display: block; object-fit: cover; }
.product-body { display: flex; flex-direction: column; align-items: flex-start; justify-content: space-between; gap: .35rem; padding: .8rem; }
.category { color: var(--green); font-size: .68rem; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; }
.product-body h2 { margin: .35rem 0 .55rem; font-size: .98rem; line-height: 1.2; }
.price { margin-top: auto; font-size: 1.05rem; }
.select-button { width: 100%; margin-top: .75rem; padding: .62rem .35rem; color: var(--green); background: transparent; border: 1px solid var(--green); border-radius: .55rem; font-size: .78rem; font-weight: 800; cursor: pointer; }
.select-button.is-selected { color: white; background: var(--green); }
.order-bar { position: fixed; z-index: 10; right: .75rem; bottom: .75rem; left: .75rem; display: flex; align-items: center; justify-content: space-between; gap: .7rem; padding: .7rem; padding-bottom: calc(0.7rem + env(safe-area-inset-bottom)); color: white; background: #17221bf2; border-radius: 1rem; box-shadow: 0 16px 40px #17221b55; }
.order-bar.hidden { display: none; }
.order-bar.is-empty { left: auto; width: 9.5rem; opacity: .72; transform: scale(.92); transform-origin: right bottom; }
.order-bar.is-empty .cart-summary > span > span, .order-bar.is-empty .cart-action { display: none; }
.order-bar.has-items { box-shadow: 0 16px 42px #17221b77, 0 0 0 2px #25d36655; }
.cart-summary { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .2rem; color: white; background: transparent; border: 0; text-align: left; cursor: pointer; }
.cart-summary > span { display: grid; min-width: 5.2rem; font-size: .78rem; }
.cart-summary > span strong { color: white; }
.cart-summary:disabled { opacity: .55; cursor: default; }
.order-bar span { color: #ced9d1; }
.cart-action { display: inline-flex; align-items: center; gap: .45rem; }
.cart-badge { display: inline-grid; min-width: 1.45rem; height: 1.45rem; padding: 0 .35rem; place-items: center; color: #102018; background: #25d366; border-radius: 999px; font-size: .7rem; font-weight: 900; }
.cart-badge[hidden] { display: none; }
.order-button, #complete-order { padding: .75rem .85rem; color: #ffffff; background: #25D366; border: 0; border-radius: .65rem; font-size: .76rem; font-weight: 800; text-align: center; cursor: pointer; }
.order-button.is-disabled { opacity: .5; pointer-events: none; }
.cart-dialog { width: min(92vw, 36rem); max-height: 82dvh; padding: 0; overflow: auto; color: var(--ink); background: var(--card); border: 0; border-radius: 1rem; box-shadow: 0 25px 80px #17221b66; }
.cart-dialog::backdrop { background: #111a15a6; backdrop-filter: blur(2px); }
.cart-shell { padding: 1rem; }
.cart-heading { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: .5rem; }
.cart-heading h2 { margin: 0; font-size: 1.2rem; }
.cart-close { width: 2.4rem; height: 2.4rem; color: var(--ink); background: #eee9df; border: 0; border-radius: 50%; font-size: 1.1rem; cursor: pointer; }
.cart-item { display: grid; grid-template-columns: minmax(0, 1fr) minmax(8rem, .7fr) 4.5rem; gap: .5rem; align-items: center; padding: .5rem 0; border-bottom: 1px solid #e5dfd5; font-size: .78rem; }
.cart-specifications { display: grid; grid-column: 1 / -1; gap: .35rem; }
.cart-item select, .cart-item input { width: 100%; min-height: 2.2rem; padding: .35rem; border: 1px solid #cfc9bd; border-radius: .45rem; }
.cart-item select.is-invalid { border: 2px solid #c73e32; outline: 2px solid #c73e3222; }
.order-notes, .modal-size-field { display: grid; width: 100%; gap: .35rem; margin-top: .8rem; color: var(--muted); font-size: .78rem; font-weight: 800; }
.modal-size-field[hidden], [hidden] { display: none !important; }
.order-notes textarea, .modal-size-field select { width: 100%; padding: .65rem; color: var(--ink); background: white; border: 1px solid #cfc9bd; border-radius: .55rem; font: inherit; }
.order-notes textarea { min-height: 5.5rem; resize: vertical; font-weight: 500; }
.stock-notice { margin: .8rem 0 .2rem; color: var(--muted); font-size: .76rem; font-style: italic; }
.cart-notice { margin: .35rem 0 0; color: #9c372d; font-size: .75rem; font-weight: 700; }
.cart-shell > .order-button { width: 100%; min-height: 3rem; margin-top: .8rem; }
.load-more-sentinel { height: 2px; margin-top: 2rem; }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

.product-dialog { width: min(92vw, 860px); max-height: 92dvh; padding: 0; overflow: auto; color: var(--ink); background: var(--card); border: 0; border-radius: 1.1rem; box-shadow: 0 25px 80px #17221b66; }
.product-dialog::backdrop { background: #111a15b8; backdrop-filter: blur(3px); }
.modal-shell { position: relative; display: grid; }
.modal-close { position: absolute; z-index: 3; top: .7rem; right: .7rem; width: 2.65rem; height: 2.65rem; color: white; background: #17221bcc; border: 0; border-radius: 50%; font-size: 1.7rem; line-height: 1; cursor: pointer; }
.modal-media { position: relative; aspect-ratio: 4 / 5; overflow: hidden; background-color: #e8e4dc; }
.modal-media > img { width: 100%; height: 100%; display: block; object-fit: contain; transition: opacity .2s ease; }
.modal-media.image-missing > img { visibility: hidden; }
.gallery-control { position: absolute; top: 50%; width: 2.6rem; height: 2.6rem; transform: translateY(-50%); color: white; background: #17221bbd; border: 0; border-radius: 50%; font-size: 1.8rem; cursor: pointer; }
.gallery-previous { left: .7rem; }
.gallery-next { right: .7rem; }
.modal-thumbnails { display: flex; gap: .55rem; padding: .7rem; overflow-x: auto; background: #f1eee7; }
.modal-thumbnails button { flex: 0 0 4rem; width: 4rem; height: 4rem; padding: 0; overflow: hidden; background: #ddd7cc; border: 2px solid transparent; border-radius: .55rem; cursor: pointer; }
.modal-thumbnails button.is-active { border-color: var(--accent); }
.modal-thumbnails img { width: 100%; height: 100%; display: block; object-fit: cover; }
.modal-details { display: flex; flex-direction: column; align-items: flex-start; padding: 1.25rem; }
.modal-details h2 { margin: .4rem 0 .65rem; font-family: Georgia, serif; font-size: clamp(1.65rem, 7vw, 2.5rem); line-height: 1.05; }
.modal-price { font-size: 1.35rem; }
.modal-add { margin-top: 1.25rem; min-height: 3rem; }
.modal-confirmation { min-height: 1.5rem; margin: .65rem 0 0; color: var(--green); font-size: .85rem; font-weight: 700; }

@keyframes skeleton { to { background-position-x: -240%; } }
@media (max-width: 420px) { .store-header { gap: .5rem; padding-right: .75rem; padding-left: .75rem; } .brand { flex: 0 1 auto; gap: .3rem; font-size: .9rem; } .brand-logo { width: 2rem; height: 2rem; } .header-search input { min-height: 2.35rem; padding: .5rem .65rem; } }
@media (max-width: 768px) { #product-dialog .modal-media { max-height: 38vh; width: 100%; aspect-ratio: auto; } #product-dialog .modal-media > img { max-height: 38vh; width: 100%; object-fit: contain; } }
@media (min-width: 680px) { .store-header { gap: 1.5rem; } .header-search { max-width: 34rem; margin-left: auto; } .product-grid { grid-template-columns: repeat(3, 1fr); gap: 1rem; } .product-body { padding: 1rem; } .modal-shell { grid-template-columns: minmax(0, 1.2fr) minmax(17rem, .8fr); } .modal-media { grid-row: span 2; aspect-ratio: auto; min-height: 34rem; } .modal-thumbnails { grid-column: 1; } .modal-details { grid-column: 2; grid-row: 1 / span 2; justify-content: center; } }
@media (min-width: 980px) { .product-grid { grid-template-columns: repeat(4, 1fr); gap: 1.25rem; } .order-bar { right: 2rem; bottom: 2rem; left: auto; width: min(24rem, calc(100% - 4rem)); } }
@media (prefers-reduced-motion: no-preference) { .product-card { transition: transform .18s ease, box-shadow .18s ease; } .product-card:hover { transform: translateY(-3px); box-shadow: 0 15px 32px rgba(36,49,41,.1); } }
@media (prefers-reduced-motion: reduce) { .is-loading { animation: none; } }
