/*
 * ==========================================================================
 * STOREFRONT LAYOUT STYLES
 * ==========================================================================
 * Layout-only styles for the storefront shell: header, footer, grid,
 * category bar, availability banner, and utility classes.
 *
 * Component styles have been split into:
 *   storefront-product.css  - product card & product detail
 *   storefront-cart.css     - cart page & cart toast
 *   storefront-checkout.css - checkout flow
 *   storefront-login.css    - login/account page
 *
 * Design tokens come from main.css (pyeza themes). Storefront-specific
 * tokens that have no pyeza equivalent are defined below.
 * ==========================================================================
 */

/* --- Storefront-Specific Tokens (derived from active theme) --- */
:root {
    /* Dark header/footer color */
    --sf-color-primary: var(--accent-primary);
    --sf-color-primary-hover: var(--accent-primary-dark);

    /* Brand accent */
    --sf-color-brand-gold: var(--accent-amber);

    /* Cart badge */
    --sf-color-cart-badge: var(--status-error);

    /* Layout constraint */
    --sf-max-width: 80rem;

    /* Product card image background */
    --sf-card-image-bg: var(--bg-hover);
}

/* --- Base Layout --- */
*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    height: 100%;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    margin: 0;
    font-family: var(--font-family, 'Figtree', sans-serif);
    background: var(--bg-base);
    color: var(--text-primary);
    -webkit-font-smoothing: antialiased;
}

/* --- Layout --- */
.store-main {
    max-width: var(--sf-max-width);
    margin: 0 auto;
    padding: 0 1.5rem;
    flex: 1;
    width: 100%;
}

@media (max-width: 768px) {
    .store-main {
        padding: 0 1rem;
    }
}

/* --- Store Header --- */
.store-header {
    background: var(--bg-card);
    color: var(--text-primary);
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid var(--border);
}

.store-header__inner {
    max-width: var(--sf-max-width);
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.25rem;
    padding: 0.75rem 1.5rem;
}

@media (max-width: 768px) {
    .store-header__inner {
        padding: 0.625rem 1rem;
        gap: 0.75rem;
        justify-content: space-between;
    }
}

.store-header__logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: var(--text-primary);
    flex-shrink: 0;
}

.store-header__logo:hover {
    opacity: 0.9;
}

.store-header__logo-icon svg {
    width: 1.5rem;
    height: 1.5rem;
}

.store-header__logo-text {
    font-size: 1.25rem;
    font-weight: 700;
    letter-spacing: 0.05em;
}

.store-header__logo-img {
    display: none;
    height: 2.25rem;
    width: auto;
    object-fit: contain;
}

.store-header__search {
    flex: 1;
    max-width: 37.5rem;
    min-width: 12.5rem;
}

.store-header__search-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.store-header__search-icon {
    position: absolute;
    left: 0.75rem;
    color: var(--text-muted);
    pointer-events: none;
    display: flex;
    align-items: center;
}

.store-header__search-icon svg {
    width: 1rem;
    height: 1rem;
}

.store-header__search-input.form-input {
    width: 100%;
    padding: 0.5625rem 0.75rem 0.5625rem 2.5rem;
    border: 1px solid var(--border);
    border-radius: var(--radius-full);
    background: var(--bg-base);
    color: var(--text-primary);
    font-size: 0.875rem;
    outline: none;
    transition: border-color var(--transition-fast), background var(--transition-fast), box-shadow var(--transition-fast);
}

.store-header__search-input::placeholder {
    color: var(--text-muted);
}

.store-header__search-input:focus {
    border-color: var(--sf-color-primary);
    background: var(--bg-card);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent-primary) 8%, transparent);
}

.store-header__actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 0;
}

.store-header__store-selector {
    position: relative;
}

.store-header__store-btn {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    background: var(--bg-base);
    border: 1px solid var(--border);
    border-radius: var(--radius-full);
    color: var(--text-primary);
    padding: 0.5rem 0.875rem;
    cursor: pointer;
    font-size: 0.8125rem;
    white-space: nowrap;
    transition: border-color var(--transition-fast), background var(--transition-fast);
}

.store-header__store-btn:hover {
    border-color: var(--text-muted);
    background: var(--bg-hover);
}

.store-header__store-icon svg,
.store-header__chevron svg {
    width: 0.875rem;
    height: 0.875rem;
}

.store-header__store-dropdown {
    min-width: 12.5rem;
}

.store-header__store-list {
    display: flex;
    flex-direction: column;
}

.store-header__store-option {
    display: block;
    width: 100%;
    padding: 0.625rem 1rem;
    text-align: left;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 0.875rem;
    color: var(--text-primary);
    transition: background var(--transition-fast);
}

.store-header__store-option:hover {
    background: var(--bg-base);
}

.store-header__store-option.active {
    font-weight: 600;
    background: var(--accent-primary-light);
}

.store-header__icon-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 50%;
    background: none;
    border: none;
    color: var(--text-primary);
    cursor: pointer;
    position: relative;
    text-decoration: none;
    transition: background var(--transition-fast);
}

.store-header__icon-btn:hover {
    background: var(--bg-hover);
}

.store-header__icon-btn svg {
    width: 1.25rem;
    height: 1.25rem;
}

.store-header__cart-icon {
    display: flex;
    align-items: center;
}

.store-header__cart-badge {
    position: absolute;
    top: 0;
    right: 0;
    background: var(--sf-color-cart-badge);
    color: var(--text-inverse);
    font-size: 0.625rem;
    font-weight: 700;
    min-width: 1rem;
    height: 1rem;
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 0.25rem;
}

.store-header__hamburger {
    display: none;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    color: var(--text-primary);
    cursor: pointer;
    padding: 0.25rem;
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 50%;
    transition: background var(--transition-fast);
}

.store-header__hamburger:hover {
    background: var(--bg-hover);
}

.store-header__hamburger svg {
    width: 1.25rem;
    height: 1.25rem;
}

/* Hamburger icon toggle: show menu icon, hide X by default */
.store-header__hamburger-close {
    display: none;
}

.store-header__hamburger[aria-expanded="true"] .store-header__hamburger-icon {
    display: none;
}

.store-header__hamburger[aria-expanded="true"] .store-header__hamburger-close {
    display: flex;
    align-items: center;
}

/* --- Mobile Panel (search + nav, toggled by hamburger) --- */
.store-header__mobile-panel {
    display: none;
    overflow: hidden;
    max-height: 0;
    transition: max-height 0.3s ease;
}

.store-header__mobile-panel--open {
    max-height: 30rem;
}

.store-header__mobile-search {
    padding: 0 1rem 0.75rem;
}

.store-header__mobile-nav {
    padding: 0 1rem 1rem;
    border-top: 1px solid var(--border);
}

.store-header__mobile-label {
    display: block;
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    padding: 0.75rem 0 0.375rem;
}

.store-header__mobile-store-list {
    display: flex;
    flex-direction: column;
}

.store-header__mobile-store-list .store-header__store-option {
    color: var(--text-secondary);
    padding: 0.5rem 0.75rem;
    border-radius: var(--radius-sm);
    font-size: 0.8125rem;
}

.store-header__mobile-store-list .store-header__store-option:hover {
    background: var(--bg-hover);
}

.store-header__mobile-store-list .store-header__store-option.active {
    color: var(--text-primary);
    font-weight: 600;
    background: var(--bg-hover);
}

.store-header__mobile-links {
    border-top: 1px solid var(--border);
    padding-top: 0.5rem;
    margin-top: 0.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
}

.store-header__mobile-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 0.75rem;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: var(--radius-sm);
    transition: background var(--transition-fast), color var(--transition-fast);
}

.store-header__mobile-link:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.store-header__mobile-link svg {
    width: 1.125rem;
    height: 1.125rem;
    opacity: 0.7;
}

@media (max-width: 768px) {
    .store-header__search {
        display: none;
    }
    .store-header__store-selector {
        display: none;
    }
    .store-header__mobile-panel {
        display: none !important;
    }
    .store-header__hamburger {
        display: none !important;
    }
    #cart-btn {
        display: none;
    }
    .store-header__logo-icon,
    .store-header__logo-text {
        display: none;
    }
    .store-header__logo-img {
        display: block;
    }
    body {
        padding-bottom: 3.75rem;
    }
}

@media (min-width: 769px) {
    .store-header__hamburger {
        display: none !important;
    }
    .store-header__mobile-panel {
        display: none !important;
    }
    .store-header__logo-img {
        display: none;
    }
    .bottom-nav,
    .location-sheet {
        display: none !important;
    }
}

/* --- Category Bar --- */
.category-bar {
    padding: 0.875rem 0;
    border-bottom: 1px solid var(--border-light);
}

.category-bar__inner {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding: 0 0.25rem;
}

.category-bar__inner::-webkit-scrollbar {
    display: none;
}

.category-bar__btn {
    padding: 0.4375rem 1rem;
    border: 1px solid var(--border);
    border-radius: var(--radius-full);
    background: var(--bg-card);
    color: var(--text-secondary);
    font-size: 0.8125rem;
    font-weight: 500;
    cursor: pointer;
    white-space: nowrap;
    transition: all var(--transition-fast);
    font-family: inherit;
}

.category-bar__btn:hover {
    border-color: var(--text-muted);
    color: var(--text-primary);
}

.category-bar__btn--active {
    background: var(--sf-color-primary);
    color: var(--text-inverse);
    border-color: var(--sf-color-primary);
}

.category-bar__btn--active:hover {
    background: var(--sf-color-primary-hover);
    border-color: var(--sf-color-primary-hover);
}

.category-bar__btn--toggle {
    /* inline with other filter buttons */
}

.category-bar__spacer {
    display: none;
}

@media (max-width: 768px) {
    .category-bar {
        padding: 0.75rem 0;
    }
    .category-bar__inner {
        padding: 0;
    }
}

/* --- Filter Bar (sort + price range) --- */
.filter-bar {
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--border-light);
}

.filter-bar__inner {
    display: flex;
    align-items: flex-end;
    gap: 1rem;
    flex-wrap: wrap;
}

.filter-bar__group {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.filter-bar__label {
    font-size: 0.6875rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.filter-bar__select {
    padding: 0.4375rem 2rem 0.4375rem 0.75rem;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--bg-card);
    color: var(--text-primary);
    font-size: 0.8125rem;
    font-family: inherit;
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23666' d='M3 4.5L6 7.5L9 4.5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.625rem center;
}

.filter-bar__select:hover,
.filter-bar__select:focus {
    border-color: var(--sf-color-primary);
    outline: none;
}

.filter-bar__input {
    width: 7rem;
    padding: 0.4375rem 0.75rem;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--bg-card);
    color: var(--text-primary);
    font-size: 0.8125rem;
    font-family: inherit;
}

.filter-bar__input:hover,
.filter-bar__input:focus {
    border-color: var(--sf-color-primary);
    outline: none;
}

.filter-bar__input::placeholder {
    color: var(--text-muted);
}

/* Hide number input spinners */
.filter-bar__input[type="number"]::-webkit-inner-spin-button,
.filter-bar__input[type="number"]::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}
.filter-bar__input[type="number"] {
    -moz-appearance: textfield;
}

@media (max-width: 768px) {
    .filter-bar__inner {
        gap: 0.75rem;
    }
    .filter-bar__input {
        width: 5.5rem;
    }
}

/* --- Dual-Range Price Slider --- */
.filter-bar__group--slider {
    flex: 1;
    min-width: 10rem;
    max-width: 18rem;
}

.price-slider__labels {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.25rem;
}

.price-slider__value {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-primary);
    font-variant-numeric: tabular-nums;
}

.price-slider__track-wrap {
    position: relative;
    height: 1.75rem;
}

.price-slider__track {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--border);
    border-radius: 2px;
    transform: translateY(-50%);
}

.price-slider__fill {
    position: absolute;
    height: 100%;
    background: var(--sf-color-primary);
    border-radius: 2px;
}

.price-slider__input {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    -webkit-appearance: none;
    appearance: none;
    background: transparent;
    pointer-events: none;
}

.price-slider__input::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 1.125rem;
    height: 1.125rem;
    border-radius: 50%;
    background: var(--sf-color-primary);
    border: 2px solid var(--bg-card);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
    cursor: pointer;
    pointer-events: auto;
    transition: box-shadow var(--transition-fast);
}

.price-slider__input::-webkit-slider-thumb:hover {
    box-shadow: 0 0 0 4px color-mix(in srgb, var(--sf-color-primary) 15%, transparent);
}

.price-slider__input::-moz-range-thumb {
    width: 1.125rem;
    height: 1.125rem;
    border-radius: 50%;
    background: var(--sf-color-primary);
    border: 2px solid var(--bg-card);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
    cursor: pointer;
    pointer-events: auto;
}

.price-slider__input::-webkit-slider-runnable-track {
    height: 4px;
    background: transparent;
}

.price-slider__input::-moz-range-track {
    height: 4px;
    background: transparent;
}

/* Ensure max thumb renders above min thumb */
.price-slider__input--max {
    z-index: 1;
}

@media (max-width: 768px) {
    .filter-bar__group--slider {
        flex-basis: 100%;
        max-width: none;
    }
}

/* --- Product Grid --- */
.product-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.25rem;
    padding: 1.25rem 0 2rem;
}

@media (max-width: 1024px) {
    .product-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .product-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }
}

.product-grid__empty {
    grid-column: 1 / -1;
    text-align: center;
    padding: 4rem 1rem;
}

.product-grid__empty-icon {
    display: flex;
    justify-content: center;
    margin-bottom: 1rem;
}

.product-grid__empty-icon svg {
    width: 3rem;
    height: 3rem;
    color: var(--text-muted);
}

.product-grid__empty h3 {
    margin: 0 0 0.5rem;
    font-size: 1.125rem;
}

.product-grid__empty p {
    color: var(--text-secondary);
    margin: 0 0 1.5rem;
}

/* --- Store Footer --- */
.store-footer {
    background: var(--sf-color-primary);
    color: color-mix(in srgb, var(--text-inverse) 70%, transparent);
    margin-top: auto;
    width: 100%;
}

.store-footer__inner {
    max-width: var(--sf-max-width);
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr;
    gap: 2.5rem;
    padding: 2.5rem 1.5rem;
}

@media (max-width: 640px) {
    .store-footer__inner {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        padding: 2rem 1rem;
    }
}

.store-footer__section {
    /* individual footer column */
}

.store-footer__title {
    color: var(--text-inverse);
    font-size: 0.875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin: 0 0 0.75rem;
}

.store-footer__text {
    font-size: 0.8125rem;
    margin: 0;
    line-height: 1.7;
}

.store-footer__list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.store-footer__list li {
    font-size: 0.8125rem;
    margin-bottom: 0.375rem;
    line-height: 1.5;
}

.store-footer__bottom {
    border-top: 1px solid color-mix(in srgb, var(--text-inverse) 8%, transparent);
    padding: 1.25rem 1.5rem;
    text-align: center;
}

.store-footer__bottom p {
    margin: 0;
    font-size: 0.75rem;
    color: color-mix(in srgb, var(--text-inverse) 40%, transparent);
    letter-spacing: 0.02em;
}

/* --- Store Landing --- */
.store-landing {
    padding-bottom: 2rem;
}

/* --- Availability Banner --- */
.availability-banner {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.5rem 0;
    font-size: 0.75rem;
    color: var(--text-muted);
}

.availability-banner svg {
    flex-shrink: 0;
    width: 0.875rem;
    height: 0.875rem;
    color: var(--text-muted);
    opacity: 0.7;
}

.availability-banner strong {
    color: var(--text-primary);
    font-weight: 600;
}

/* --- Popover (store selector) --- */
.popover-panel {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 0.5rem;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    z-index: 150;
    min-width: 11.25rem;
    overflow: hidden;
}

.popover-panel--open {
    display: block;
}

.popover-arrow {
    display: none;
}

/* --- Utility --- */
.btn--secondary {
    padding: 0.5rem 1rem;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    cursor: pointer;
    font-size: 0.875rem;
    font-family: inherit;
    color: var(--text-primary);
    transition: all var(--transition-fast);
}

.btn--secondary:hover {
    border-color: var(--text-primary);
}

/* --- Toast Container --- */
#toast-container {
    /* Container for HTMX-injected toast; toast itself handles position: fixed */
}

/* --- HTMX Loading Indicator --- */
.htmx-indicator {
    opacity: 0;
    transition: opacity 200ms ease-in;
}

.htmx-request .htmx-indicator,
.htmx-request.htmx-indicator {
    opacity: 1;
}

/* --- Optimistic UI: Cart loading state --- */
.cart-page__body.optimistic-loading {
    opacity: 0.5;
    pointer-events: none;
    transition: opacity 0.15s ease;
}

.cart-item.optimistic-removing {
    opacity: 0;
    transform: translateX(30px);
    transition: opacity 0.25s ease, transform 0.25s ease;
    pointer-events: none;
}

/* --- Optimistic UI: Product info loading state --- */
#product-info.optimistic-loading {
    opacity: 0.5;
    pointer-events: none;
    transition: opacity 0.15s ease;
}

/* --- Bottom Navigation (Mobile) --- */
.bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 100;
    background: var(--bg-card);
    border-top: 1px solid var(--border);
    padding: 0.625rem 1rem;
    padding-bottom: calc(0.625rem + env(safe-area-inset-bottom));
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
}

@media (max-width: 768px) {
    .bottom-nav {
        display: flex;
    }
}

.bottom-nav__item {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem 0.75rem;
    border-radius: var(--radius-full);
    color: var(--text-primary);
    font-size: 0.8125rem;
    font-weight: 500;
    font-family: inherit;
    position: relative;
    transition: background var(--transition-fast);
}

.bottom-nav__item:active {
    background: var(--bg-hover);
}

.bottom-nav__item--location {
    flex: 1;
    min-width: 0;
    background: var(--bg-base);
    border: 1px solid var(--border);
}

.bottom-nav__icon {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.bottom-nav__icon svg {
    width: 1.125rem;
    height: 1.125rem;
}

.bottom-nav__chevron {
    display: flex;
    align-items: center;
    margin-left: auto;
    color: var(--text-muted);
}

.bottom-nav__chevron svg {
    width: 0.875rem;
    height: 0.875rem;
}

.bottom-nav__label {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.bottom-nav__badge {
    position: absolute;
    top: 0;
    right: 0;
    background: var(--sf-color-cart-badge);
    color: var(--text-inverse);
    font-size: 0.625rem;
    font-weight: 700;
    min-width: 1rem;
    height: 1rem;
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 0.25rem;
}

/* --- Cart Bottom Nav Variant --- */
.bottom-nav--cart {
    gap: 0.75rem;
}

.bottom-nav__item--back,
.bottom-nav__item--checkout {
    text-decoration: none;
    font-weight: 500;
}

.bottom-nav__item--back {
    color: var(--text-secondary);
}

.bottom-nav__item--checkout {
    background: var(--sf-color-primary);
    color: var(--text-inverse);
    padding: 0.625rem 1.25rem;
}

.bottom-nav__item--checkout:active {
    background: var(--sf-color-primary-hover);
}

/* Hide footer on cart page (mobile) */
@media (max-width: 768px) {
    body[data-page="cart-drawer-content"] .store-footer {
        display: none;
    }
    /* Also hide the inline checkout button on mobile (bottom nav replaces it) */
    body[data-page="cart-drawer-content"] .cart-page__checkout-btn {
        display: none;
    }
}

/* --- Location Sheet (Mobile) --- */
.location-sheet {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 200;
}

.location-sheet--open {
    display: block;
}

.location-sheet__backdrop {
    position: absolute;
    inset: 0;
    background: var(--bg-overlay);
}

.location-sheet__content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--bg-card);
    border-radius: 1rem 1rem 0 0;
    padding-bottom: env(safe-area-inset-bottom);
    animation: sheetSlideUp 0.25s ease-out;
}

@keyframes sheetSlideUp {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
}

.location-sheet__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.125rem 1.25rem;
    border-bottom: 1px solid var(--border);
}

.location-sheet__title {
    font-size: 1rem;
    font-weight: 600;
}

.location-sheet__close {
    display: flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.375rem;
    border-radius: 50%;
    color: var(--text-secondary);
    transition: background var(--transition-fast);
}

.location-sheet__close:active {
    background: var(--bg-hover);
}

.location-sheet__close svg {
    width: 1.25rem;
    height: 1.25rem;
}

.location-sheet__list {
    padding: 0.5rem;
}

.location-sheet__option {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    width: 100%;
    padding: 0.875rem 1rem;
    background: none;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    font-size: 0.9375rem;
    color: var(--text-primary);
    font-family: inherit;
    transition: background var(--transition-fast);
}

.location-sheet__option:active {
    background: var(--bg-hover);
}

.location-sheet__option.active {
    background: var(--accent-primary-light);
    font-weight: 600;
}

.location-sheet__option-icon {
    display: flex;
    align-items: center;
    color: var(--text-muted);
}

.location-sheet__option-icon svg {
    width: 1.125rem;
    height: 1.125rem;
}

.location-sheet__option.active .location-sheet__option-icon {
    color: var(--sf-color-primary);
}

/* --- Print Styles --- */
@media print {
    .store-header,
    .store-footer,
    .cart-toast,
    #toast-container,
    .bottom-nav,
    .location-sheet {
        display: none;
    }

    .store-main {
        max-width: 100%;
        padding: 0;
    }

    .product-card:hover {
        box-shadow: none;
        transform: none;
    }
}
