/* Bravalua Store Finder. Every rule is scoped under .bv-root so the WordPress theme is untouched. */
.bv-root {
  --bv-yellow: #E9DC09;
  --bv-logo: #FCE81E;
  --bv-brown: #43291A;
  --bv-brown-2: #3A2315;
  --bv-brown-3: #5A3E2B;
  --bv-muted: #6B4E3A;
  --bv-cream: #FFFBD6;
  --bv-line: #F0E3CC;
  --bv-blue: #3BA7DF;
  --bv-green: #95BF22;
  --bv-head: 'Josefin Sans', system-ui, sans-serif;
  --bv-body: 'DM Sans', system-ui, sans-serif;
  font-family: var(--bv-body);
  color: var(--bv-brown);
  line-height: 1.5;
  -webkit-text-size-adjust: 100%;
}
.bv-root *, .bv-root *::before, .bv-root *::after { box-sizing: border-box; }
.bv-root h2, .bv-root h3, .bv-root p, .bv-root ol, .bv-root ul { margin: 0; padding: 0; }
.bv-root button { font: inherit; color: inherit; }
.bv-root a { color: inherit; }
.bv-root :focus-visible { outline: 3px solid var(--bv-blue); outline-offset: 2px; }
.bv-wrap { max-width: 1280px; margin: 0 auto; padding-left: 20px; padding-right: 20px; }
.bv-sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Language switch */
.bv-langs { display: flex; gap: 4px; }
.bv-lang {
  font-family: var(--bv-head); font-weight: 700; font-size: 14px; letter-spacing: .08em;
  min-width: 44px; min-height: 44px; border: 2px solid var(--bv-brown); border-radius: 8px;
  background: transparent; cursor: pointer; padding: 0 6px;
}
.bv-lang[aria-pressed="true"] { background: #fff; }
/* Header variant (as in the design): light borders, active language in logo yellow. */
.bv-langs--head .bv-lang { border-color: var(--bv-line); background: #fff; }
.bv-langs--head .bv-lang[aria-pressed="true"] { border-color: var(--bv-brown); background: var(--bv-logo); }

/* Hero / search */
.bv-hero { background: var(--bv-yellow); }
.bv-hero .bv-wrap { padding-top: clamp(28px, 6vw, 56px); padding-bottom: clamp(24px, 5vw, 48px); display: flex; flex-direction: column; gap: 16px; }
.bv-hero-top { display: flex; justify-content: flex-end; }
.bv-title {
  font-family: var(--bv-head); font-weight: 700; text-transform: uppercase; letter-spacing: .02em;
  font-size: clamp(30px, 7vw, 52px); line-height: 1.05; max-width: 820px; color: var(--bv-brown);
}
.bv-sub { font-size: 19px; max-width: 640px; color: var(--bv-brown-2); text-wrap: pretty; }
.bv-form { display: flex; flex-wrap: wrap; gap: 12px; max-width: 760px; margin-top: 6px; }
.bv-field { position: relative; flex: 3 1 280px; min-width: 0; }
.bv-input {
  width: 100%; min-height: 56px; padding: 0 20px; font-family: var(--bv-body); font-size: 18px; color: var(--bv-brown);
  background: #fff; border: 3px solid var(--bv-brown); border-radius: 14px; -webkit-appearance: none; appearance: none;
}
.bv-input::-webkit-search-cancel-button { cursor: pointer; }
.bv-btn-search {
  flex: 1 0 150px; min-height: 56px; padding: 0 28px; display: flex; align-items: center; justify-content: center; gap: 10px;
  font-family: var(--bv-head); font-weight: 700; font-size: 18px; letter-spacing: .08em; text-transform: uppercase;
  background: var(--bv-brown); color: #fff !important; border: 0; border-radius: 14px; cursor: pointer;
}
.bv-btn-search:hover { background: #2C1A10; }
.bv-locate {
  align-self: flex-start; display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 4px;
  background: transparent; border: 0; cursor: pointer; font-weight: 700; font-size: 16px; text-decoration: underline; text-underline-offset: 3px;
}
.bv-locate[disabled] { opacity: .6; cursor: progress; }
.bv-msg { font-size: 16px; font-weight: 500; background: var(--bv-cream); border-radius: 10px; padding: 12px 16px; max-width: 760px; }
.bv-msg:empty { display: none; }
/* Errors: red text on white so they stand out from the yellow band and the cream success message. */
.bv-msg.is-error { --bv-red: #B42318; display: flex; gap: 12px; align-items: flex-start; background: #fff; color: var(--bv-red); border: 2px solid var(--bv-red); padding: 14px 16px; border-radius: 14px; }
.bv-msg-icon { flex: 0 0 auto; color: var(--bv-red); margin-top: 1px; }
.bv-msg-body { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.bv-msg-body strong { font-family: var(--bv-head); font-size: 18px; letter-spacing: .03em; text-transform: uppercase; line-height: 1.2; }
.bv-msg-body span { font-weight: 400; text-wrap: pretty; }
.bv-try { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.bv-try button {
  color: var(--bv-brown);
  min-height: 40px; padding: 0 14px; display: inline-flex; align-items: center; gap: 6px; cursor: pointer;
  background: var(--bv-cream); border: 2px solid var(--bv-brown); border-radius: 999px; font-weight: 700; font-size: 15px;
}
.bv-try button:hover { background: var(--bv-logo); }

/* Autocomplete */
.bv-suggest {
  position: absolute; z-index: 30; left: 0; right: 0; top: calc(100% + 6px); list-style: none;
  background: #fff; border: 3px solid var(--bv-brown); border-radius: 14px; overflow: hidden; box-shadow: 0 10px 24px rgba(67, 41, 26, .18);
}
.bv-suggest[hidden] { display: none; }
.bv-suggest li { padding: 12px 18px; cursor: pointer; font-size: 16px; border-top: 1px solid var(--bv-line); }
.bv-suggest li:first-child { border-top: 0; }
.bv-suggest li[aria-selected="true"], .bv-suggest li:hover { background: var(--bv-cream); }
.bv-suggest b { font-weight: 700; }
.bv-suggest .bv-powered { padding: 6px 18px; font-size: 11px; color: var(--bv-muted); text-align: right; cursor: default; background: #fff !important; }

/* Results layout */
.bv-results { display: flex; flex-wrap: wrap; gap: 24px; align-items: flex-start; padding-top: clamp(20px, 4vw, 40px); padding-bottom: clamp(32px, 5vw, 56px); scroll-margin-top: 12px; }
.bv-mapcol { flex: 999 1 560px; min-width: 0; display: flex; flex-direction: column; gap: 12px; }
.bv-listcol { flex: 1 1 360px; min-width: 0; display: flex; flex-direction: column; gap: 12px; }

/* Map */
.bv-map { position: relative; width: 100%; aspect-ratio: 1180 / 1000; background: #FFF8EA; border: 3px solid var(--bv-brown); border-radius: 20px; overflow: hidden; }
.bv-map-canvas, .bv-schematic { position: absolute; inset: 0; }
.bv-schematic svg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.bv-schematic[hidden], .bv-map-canvas[hidden] { display: none; }
.bv-spin { position: absolute; transform: translate(-50%, -100%); background: transparent; border: 0; padding: 0; cursor: pointer; display: flex; flex-direction: column; align-items: center; }
.bv-you { position: absolute; transform: translate(-50%, -50%); }

.bv-pin { display: flex; flex-direction: column; align-items: center; cursor: pointer; }
.bv-pin svg { width: 30px; height: 38px; display: block; transition: width .15s, height .15s; filter: drop-shadow(0 2px 2px rgba(67, 41, 26, .25)); }
.bv-pin path { fill: var(--bv-logo); }
.bv-pin-label { display: none; white-space: nowrap; background: var(--bv-brown); color: #fff; font-family: var(--bv-head); font-weight: 700; font-size: 14px; letter-spacing: .04em; padding: 6px 10px; border-radius: 8px; margin-bottom: 4px; }
.bv-pin.is-sel svg { width: 40px; height: 52px; }
.bv-pin.is-sel path { fill: var(--bv-blue); }
.bv-pin.is-sel .bv-pin-label { display: block; }
.bv-dot { width: 26px; height: 26px; border-radius: 50%; background: var(--bv-green); border: 4px solid var(--bv-brown); box-shadow: 0 0 0 8px rgba(149, 191, 34, .3); }

.bv-gate {
  position: absolute; inset: auto 16px 16px 16px; z-index: 40; background: #fff; border: 2px solid var(--bv-brown); border-radius: 16px;
  padding: 16px 18px; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; box-shadow: 0 8px 20px rgba(67, 41, 26, .15);
}
.bv-gate[hidden] { display: none; }
.bv-gate-text { flex: 1 1 240px; font-size: 14px; }
.bv-gate-text strong { display: block; font-family: var(--bv-head); font-size: 17px; letter-spacing: .03em; text-transform: uppercase; }
.bv-gate-text a { color: var(--bv-brown); }

.bv-legend { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 14px; color: var(--bv-muted); }
.bv-legend span { display: inline-flex; align-items: center; gap: 6px; }
.bv-legend i { width: 12px; height: 12px; border-radius: 50%; background: var(--bv-green); border: 2px solid var(--bv-brown); display: inline-block; }

/* Selected store sheet (mobile, over the map) */
.bv-sheet {
  position: absolute; left: 10px; right: 10px; bottom: 10px; z-index: 40; display: none;
  background: #fff; border: 2px solid var(--bv-brown); border-radius: 16px; padding: 12px 14px; box-shadow: 0 8px 20px rgba(67, 41, 26, .2);
}
.bv-sheet-top { display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; }
.bv-sheet-close { flex: 0 0 auto; width: 36px; height: 36px; margin: -6px -6px 0 0; border: 0; background: transparent; cursor: pointer; font-size: 22px; line-height: 1; }
.bv-sheet .bv-actions { margin-top: 10px; }

/* List */
.bv-list-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.bv-list-head h2 { font-family: var(--bv-head); font-weight: 700; font-size: 26px; letter-spacing: .04em; text-transform: uppercase; }
.bv-list-head span { font-size: 14px; color: var(--bv-muted); }
.bv-empty { background: #fff; border: 2px dashed #C9B49A; border-radius: 16px; padding: 28px 24px; display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.bv-empty svg { width: 36px; height: 46px; }
.bv-empty h2 { font-family: var(--bv-head); font-weight: 700; font-size: 22px; letter-spacing: .04em; text-transform: uppercase; }
.bv-empty p { font-size: 16px; color: var(--bv-brown-3); }
.bv-list { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.bv-card { background: #fff; border: 2px solid var(--bv-line); border-radius: 16px; padding: 16px 18px; display: flex; flex-direction: column; gap: 10px; scroll-margin: 8px; cursor: pointer; transition: border-color .15s, background-color .15s; }
.bv-card:hover { border-color: #C9B49A; }
.bv-card.is-sel { background: var(--bv-cream); border-color: var(--bv-brown); }
.bv-card-top { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; }
.bv-store-name { font-family: var(--bv-head); font-weight: 700; font-size: 19px; letter-spacing: .03em; display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; }
.bv-badge { font-family: var(--bv-body); font-size: 12px; font-weight: 700; letter-spacing: .02em; background: var(--bv-green); color: var(--bv-brown); border-radius: 999px; padding: 2px 8px; }
.bv-addr { font-size: 15px; line-height: 1.4; color: var(--bv-brown-3); }
.bv-dist { flex: 0 0 auto; font-weight: 700; font-size: 15px; background: var(--bv-cream); border-radius: 999px; padding: 4px 10px; white-space: nowrap; }
.bv-card.is-sel .bv-dist { background: #fff; }
.bv-actions { display: flex; flex-wrap: wrap; gap: 8px; }
/* Store name is the keyboard entry point for "show on map" (the card itself handles mouse/touch). */
.bv-card-name { background: none; border: 0; padding: 0; margin: 0; font: inherit; letter-spacing: inherit; color: inherit; text-align: left; cursor: pointer; border-radius: 4px; }
.bv-btn-route {
  min-height: 44px; padding: 0 14px; border-radius: 10px; background: var(--bv-brown); color: #fff !important; text-decoration: none;
  font-weight: 700; font-size: 14px; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
}
.bv-btn-route:hover { background: #2C1A10; }

@media (min-width: 900px) {
  /* Desktop: the list scrolls next to the map instead of making the page long. */
  .bv-list { max-height: 640px; overflow-y: auto; padding-right: 4px; overscroll-behavior: contain; }
}

@media (max-width: 899px) {
  .bv-sub { font-size: 17px; }
  .bv-results { gap: 18px; }
  .bv-map { aspect-ratio: auto; height: min(56vh, 460px); min-height: 300px; border-radius: 16px; }
  /* The schematic drawing only lines up with its pins at its own proportions. */
  .bv-map.is-schematic { height: auto; min-height: 0; aspect-ratio: 1180 / 1000; }
  .bv-map.is-schematic .bv-sheet { display: none; } /* too small to overlay: the card below shows the store */
  .bv-sheet.is-open { display: block; }
  .bv-sheet .bv-btn-route { flex: 1 1 auto; }
  .bv-gate { inset: auto 10px 10px 10px; }
  .bv-card .bv-btn-route { flex: 1 1 auto; }
}

@media (max-width: 520px) {
  .bv-wrap { padding-left: 16px; padding-right: 16px; }
  .bv-hero .bv-wrap { gap: 12px; }
  .bv-title { font-size: clamp(28px, 8.4vw, 36px); }
  .bv-sub { font-size: 16px; }
  .bv-input { font-size: 17px; padding: 0 16px; }
  .bv-btn-search { flex-basis: 100%; }
  .bv-card { padding: 14px; }
}

/* Products */
.bv-products { background: var(--bv-yellow); }
.bv-products .bv-wrap { padding-top: clamp(36px, 6vw, 56px); padding-bottom: 44px; display: flex; flex-direction: column; gap: 24px; }
.bv-products-head h2 { font-family: var(--bv-head); font-weight: 700; font-size: clamp(28px, 5vw, 40px); letter-spacing: .04em; text-transform: uppercase; }
.bv-products-head p { font-size: 18px; max-width: 720px; margin-top: 6px; }
.bv-track { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr)); gap: 20px; list-style: none; }
.bv-product { background: #fff; border-radius: 22px; padding: 14px 14px 22px; display: flex; flex-direction: column; gap: 14px; box-shadow: 0 6px 0 #D6C200; }
.bv-product img { width: 100%; height: auto; aspect-ratio: 546 / 378; object-fit: cover; border-radius: 14px; display: block; }
.bv-product-body { padding: 0 8px; display: flex; flex-direction: column; gap: 8px; }
.bv-product h3 { font-family: var(--bv-head); font-weight: 700; font-size: 24px; letter-spacing: .03em; text-transform: uppercase; line-height: 1.1; }
.bv-product-alt { font-size: 15px; font-weight: 700; color: var(--bv-muted); }
.bv-product p { font-size: 16px; line-height: 1.55; color: var(--bv-brown-2); }
.bv-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; list-style: none; }
.bv-tags li { font-size: 13px; font-weight: 700; background: var(--bv-cream); border: 1px solid #F0D9AE; border-radius: 999px; padding: 5px 11px; }
.bv-carousel-nav { display: none; }

@media (max-width: 899px) {
  /* Mobile/tablet: one swipeable row instead of six stacked cards. */
  .bv-products .bv-wrap { padding-left: 0; padding-right: 0; gap: 18px; }
  .bv-products-head { padding: 0 20px; }
  .bv-products-head p { font-size: 16px; }
  .bv-track {
    display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding: 0 20px;
    padding: 0 20px 10px; scrollbar-width: none; -webkit-overflow-scrolling: touch; overscroll-behavior-x: contain;
  }
  .bv-track::-webkit-scrollbar { display: none; }
  .bv-product { flex: 0 0 min(80%, 340px); scroll-snap-align: start; padding: 10px 10px 18px; gap: 12px; }
  .bv-product h3 { font-size: 21px; }
  .bv-product p { font-size: 15px; }
  .bv-carousel-nav { display: flex; align-items: center; justify-content: center; gap: 14px; padding: 0 20px; }
  .bv-dots { display: flex; gap: 2px; }
  .bv-dots button { width: 24px; height: 44px; border: 0; background: transparent; cursor: pointer; padding: 0; display: flex; align-items: center; justify-content: center; }
  .bv-dots button::after { content: ''; width: 10px; height: 10px; border-radius: 50%; background: rgba(67, 41, 26, .3); transition: width .2s; }
  .bv-dots button[aria-current="true"]::after { background: var(--bv-brown); width: 22px; border-radius: 6px; }
  .bv-arrow { width: 44px; height: 44px; border-radius: 50%; border: 2px solid var(--bv-brown); background: #fff; cursor: pointer; display: flex; align-items: center; justify-content: center; }
  .bv-arrow[disabled] { opacity: .35; cursor: default; }
}
@media (max-width: 520px) {
  .bv-products-head { padding: 0 16px; }
  .bv-track { padding: 0 16px 10px; scroll-padding: 0 16px; }
}
@media (prefers-reduced-motion: reduce) {
  .bv-root * { transition: none !important; scroll-behavior: auto !important; }
}
