/* Location controls and store cards; WooCommerce product geometry belongs to WoodMart. */
.acwt-woodmart-near [hidden] { display: none !important; }
.acwt-woodmart-near .acwt-wn-controls, .acwt-woodmart-near [data-role="location-form"] { display: flex; flex-wrap: wrap; align-items: end; gap: .75rem; }
.acwt-woodmart-near .acwt-wn-controls { margin-bottom: .75rem; }
.acwt-woodmart-near .acwt-wn-controls label { display: flex; flex-direction: column; gap: .25rem; margin: 0; }
.acwt-woodmart-near [data-role="location-form"] input { min-width: min(260px, 100%); }
.acwt-woodmart-near [data-role="radius"] { max-width: 110px; }
.acwt-woodmart-near .acwt-wn-help { font-size: .85em; opacity: .8; }
.acwt-woodmart-near [data-role="places"] { display: grid; gap: .5rem; }
.acwt-woodmart-near [data-role="places"] button { text-align: start; white-space: normal; }
.acwt-woodmart-near [data-role="pages"] { display: flex; justify-content: center; flex-wrap: wrap; gap: .5rem; margin-top: 1rem; }
.acwt-woodmart-near [data-role="recovery"] { margin-bottom: 1rem; }
.acwt-woodmart-near [aria-busy="true"] { opacity: .6; }
.acwt-woodmart-near button:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; }
.acwt-wn-heading { display: flex; align-items: center; gap: .5rem; margin-bottom: 1rem; }
.acwt-wn-heading h3 { margin: 0; }
.acwt-wn-gear { display: inline-flex; align-items: center; justify-content: center; min-width: 36px; height: 36px; padding: 0; margin-inline-start: .5rem; vertical-align: middle; font-family: sans-serif; line-height: 1; color: var(--wd-text-color, #333); background-color: var(--btn-bgcolor, #FFFFFF); border: 1px solid currentColor; border-radius: 50%; cursor: pointer; -webkit-text-fill-color: currentColor; }
.acwt-wn-gear[aria-expanded="true"] { color: #d00; }
.acwt-wn-gear:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; }
.acwt-wn-panel { margin-bottom: 1rem; }

.acwt-wn-gear, .acwt-woodmart-near [data-action="locate"] { font-size: var(--btn-font-size, 25px); background-color: var(--btn-bgcolor, #FFFFFF); }

/* Set the local variable too: a fallback does not override WoodMart's inherited 13px value. */
button.acwt-wn-gear[data-action="settings"] { --btn-font-size: 25px; --btn-bgcolor: #FFFFFF; font-size: 25px; background-color: #FFFFFF; }
button.acwt-wn-gear[data-action="settings"] > span { font-size: inherit; }

/* Image-only store cards intentionally use native Brands geometry and image sizing. */
.acwt-stores .acwt-store-card.acwt-store-has-text { flex-direction: column; gap: .5rem; }
.acwt-stores .acwt-store-text { max-width: 100%; overflow-wrap: break-word; }
.acwt-stores.text-left .acwt-store-has-text { align-items: flex-start; }
.acwt-stores.text-right .acwt-store-has-text { align-items: flex-end; }
.acwt-stores .acwt-store-card a:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; }

/* Display copy can be hidden independently of the interactive location panel. */
.acwt-woodmart-near.acwt-hide-display-text > [data-role="catalog-status"],
.acwt-woodmart-near.acwt-hide-display-text > noscript { display: none !important; }
.acwt-store-product-cards .wd-col, .acwt-store-product-cards .wd-carousel-item { height: auto; min-width: 0; }
.acwt-store-product-card { display: flex; flex-direction: column; height: 100%; overflow: hidden; border: 1px solid var(--brdcolor-gray-300, #e5e5e5); border-radius: var(--wd-brd-radius, 20px); background: var(--wd-main-bgcolor, #fff); }
.acwt-store-product-image { display: flex; align-items: center; justify-content: center; aspect-ratio: 1 / 1; min-width: 0; padding: 24px; overflow: hidden; }
.acwt-store-product-image img { width: 100%; height: 100%; object-fit: contain; }
.acwt-store-product-details { padding: 16px 18px; text-align: inherit; overflow-wrap: break-word; }
.acwt-store-product-details .acwt-store-text { font-weight: 600; color: var(--wd-title-color, #333); }
.acwt-store-product-footer { margin-top: auto; padding: 12px 18px; border-top: 1px solid var(--brdcolor-gray-300, #e5e5e5); }
.acwt-store-visit { display: flex; align-items: center; justify-content: space-between; gap: 12px; color: var(--wd-primary-color, #333); }
.acwt-store-product-card a:focus-visible { outline: 2px solid currentColor; outline-offset: -3px; }

/* Distance stays independent of the optional caption and does not replace the store link. */
.acwt-store-distance { display: inline-flex; align-items: center; justify-content: center; gap: .35em; font-size: .9em; white-space: nowrap; }
.acwt-store-distance svg { flex-shrink: 0; }
.acwt-store-product-footer { display: flex; align-items: center; flex-wrap: wrap; gap: .75rem; }
.acwt-store-product-footer .acwt-store-visit { flex: 1 1 auto; min-width: 0; }
.acwt-store-distance-details { padding: 0 18px 16px; }
.acwt-store-card .acwt-store-distance { max-width: 100%; }

/* Independently mapped WCFM fields in the category/name/price/icon positions. */
.acwt-store-custom-card .acwt-store-product-details { text-align: start; display: grid; gap: 6px; }
.acwt-store-custom-card .acwt-store-slot-secondary { color: var(--wd-alternative-color, #999); font-size: .95em; }
.acwt-store-custom-card .acwt-store-slot-title { color: var(--wd-title-color, #333); font-weight: 600; }
.acwt-store-custom-card .acwt-store-slot-secondary a,
.acwt-store-custom-card .acwt-store-slot-title a { color: inherit; }
.acwt-store-custom-card .acwt-store-slot-footer { flex: 1 1 0; min-width: 0; text-align: start; overflow-wrap: anywhere; color: var(--wd-primary-color, #333); }
.acwt-store-custom-card .acwt-store-slot-footer a { color: inherit; }
.acwt-store-custom-card .acwt-store-action-icon { display: inline-flex; align-items: center; justify-content: center; flex: 0 0 32px; width: 32px; min-height: 32px; margin-inline-start: auto; font-size: 20px; color: var(--wd-title-color, #333); }
.acwt-store-custom-card .acwt-store-action-icon svg,
.acwt-store-custom-card .acwt-store-action-icon img { width: 20px; height: 20px; object-fit: contain; }
.acwt-store-custom-card .acwt-store-distance { white-space: normal; text-align: start; }

/* Opt-in foreground logo placement. Absolute inner bounds keep large padding inside small cards. */
.acwt-stores .acwt-logo-adjusted { position: relative; padding: 0; overflow: hidden; min-width: 0; }
.acwt-stores .acwt-store-logo-area { width: 100%; flex: 0 0 auto; }
.acwt-stores .acwt-logo-placement { position: absolute; top: min(var(--acwt-logo-top), 45%); right: min(var(--acwt-logo-right), 45%); bottom: min(var(--acwt-logo-bottom), 45%); left: min(var(--acwt-logo-left), 45%); display: flex; align-items: var(--acwt-logo-y); justify-content: var(--acwt-logo-x); }
.acwt-stores .acwt-logo-placement img { display: block; width: min(var(--acwt-logo-width), 100%); height: min(var(--acwt-logo-height), 100%); max-width: 100%; max-height: 100%; margin: 0; object-fit: contain; object-position: var(--acwt-logo-object); }
