:root {
  --font-round: "Baloo 2", "Space Grotesk", sans-serif;
  --bg: #fff9e9;
  --bg-soft: #fffdf5;
  --ink: #121117;
  --ink-soft: #565062;
  --line: rgba(18, 17, 23, 0.14);
  --brand: #f8c813;
  --brand-2: #31c9d2;
  --brand-3: #ef7582;
  --brand-4: #f47a11;
  --shadow: 0 16px 34px rgba(45, 34, 14, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Space Grotesk", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 12% 20%, rgba(248, 200, 19, 0.28), transparent 35%),
    radial-gradient(circle at 88% 16%, rgba(49, 201, 210, 0.2), transparent 28%),
    linear-gradient(145deg, #fff9e9 0%, #fff4dd 100%);
  transition: background 500ms ease;
}

body.connected {
  --bg: #1a1410;
  --bg-soft: rgba(30, 23, 18, 0.84);
  --ink: #fff5d5;
  --ink-soft: #f4dca0;
  --line: rgba(255, 230, 171, 0.2);
  --brand: #f8c813;
  --brand-2: #31c9d2;
  --brand-3: #ef7582;
  --brand-4: #f47a11;
  --shadow: 0 24px 44px rgba(0, 0, 0, 0.35);
  background:
    radial-gradient(circle at 12% 20%, rgba(248, 200, 19, 0.32), transparent 34%),
    radial-gradient(circle at 84% 12%, rgba(49, 201, 210, 0.23), transparent 30%),
    radial-gradient(circle at 76% 80%, rgba(239, 117, 130, 0.22), transparent 32%),
    linear-gradient(152deg, #1a1410 0%, #2b1c14 100%);
}

.loading-overlay {
  position: fixed;
  inset: 0;
  z-index: 20;
  background: rgba(12, 9, 7, 0.88);
  display: grid;
  place-items: center;
  gap: 12px;
  text-align: center;
  color: #fff7df;
}

.loading-overlay.hidden {
  display: none;
}

.loading-logo {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid rgba(248, 200, 19, 0.9);
  box-shadow: 0 0 0 10px rgba(49, 201, 210, 0.15);
  animation: spin 1.15s linear infinite;
}

.bg-shape {
  position: fixed;
  z-index: -1;
  filter: blur(68px);
  opacity: 0.26;
  transition: opacity 350ms ease;
}

body.connected .bg-shape {
  opacity: 0.58;
}

.shape-1 {
  width: 270px;
  height: 270px;
  top: -40px;
  left: -70px;
  border-radius: 50%;
  background: rgba(248, 200, 19, 0.52);
}

.shape-2 {
  width: 320px;
  height: 320px;
  right: -90px;
  bottom: -70px;
  border-radius: 41% 59% 52% 48% / 55% 45% 55% 45%;
  background: rgba(49, 201, 210, 0.35);
}

.topbar {
  width: min(1200px, 94vw);
  margin: 0 auto;
  padding: 16px 0 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

.title-wrap h1 {
  grid-column: 2;
  align-self: center;
  margin: 0;
  font-family: var(--font-round);
  font-weight: 700;
  font-size: clamp(1.45rem, 2.9vw, 2.45rem);
  letter-spacing: 0.03em;
  text-align: center;
}

.title-wrap {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  grid-template-areas:
    "logo title"
    "subtitle subtitle";
  column-gap: 10px;
  row-gap: 4px;
  column-gap: 24px;
  row-gap: 6px;
  max-width: 760px;
}

.brand-logo {
  grid-area: logo;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  object-fit: cover;
  margin-right: 6px;
  border: 3px solid rgba(248, 200, 19, 0.9);
  box-shadow: 0 10px 22px rgba(244, 122, 17, 0.28);
  transition: box-shadow 220ms ease, border-color 220ms ease;
}

body.connected .brand-logo {
  border-color: rgba(49, 201, 210, 0.9);
  box-shadow: 0 12px 28px rgba(49, 201, 210, 0.22);
}

body.shop-open .brand-logo {
  border-color: rgba(47, 224, 125, 0.9);
  box-shadow:
    0 0 0 8px rgba(47, 224, 125, 0.16),
    0 10px 26px rgba(47, 224, 125, 0.34);
  animation: haloPulseOpen 1.8s ease-in-out infinite;
}

body.shop-closed .brand-logo {
  border-color: rgba(255, 141, 82, 0.9);
  box-shadow:
    0 0 0 8px rgba(255, 141, 82, 0.14),
    0 10px 26px rgba(255, 141, 82, 0.28);
  animation: haloPulseClosed 1.9s ease-in-out infinite;
}

.title-wrap p {
  grid-area: subtitle;
  margin: 2px 0 0;
  color: var(--ink-soft);
  font-size: 0.9rem;
  line-height: 1.35;
  text-align: center;
}

/* ── PEDIDOS Y ENVIOS ─────────────────── */
.info-tab-hero {
  margin-top: 14px;
}

.info-tab-hero h2 {
  margin: 0 0 10px;
  font-family: var(--font-round);
  font-size: clamp(1.25rem, 2.5vw, 2rem);
  line-height: 1.1;
}

.orders-layout {
  margin-top: 14px;
  display: grid;
  gap: 14px;
}

.order-lead {
  margin: 0;
  max-width: 72ch;
  color: var(--ink-soft);
  line-height: 1.7;
}

.order-card {
  display: grid;
  gap: 12px;
}

.order-card-head {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.order-icon {
  flex: 0 0 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  min-width: 28px;
  max-width: 28px;
  height: 28px;
  min-height: 28px;
  max-height: 28px;
  border-radius: 9px;
  background: linear-gradient(180deg, rgba(248, 200, 19, 0.24), rgba(244, 122, 17, 0.18));
  border: 1px solid rgba(248, 200, 19, 0.42);
  color: #24180f;
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  line-height: 0;
}

.order-icon svg {
  width: 12px;
  min-width: 12px;
  max-width: 12px;
  height: 12px;
  min-height: 12px;
  max-height: 12px;
  display: block;
  flex: 0 0 12px;
}

.order-kicker {
  margin: 4px 0 0;
  color: #4a382a;
  font-size: 0.9rem;
  line-height: 1.45;
}

.order-card h3,
.order-card h4 {
  margin: 0;
  font-family: var(--font-round);
  color: var(--ink);
}

.order-card h3 {
  font-size: 1.2rem;
  line-height: 1.15;
}

.order-card h4 {
  font-size: 1rem;
  color: #2e241a;
  padding-top: 2px;
}

.order-card p,
.order-card li {
  color: var(--ink-soft);
  line-height: 1.7;
}

.order-card p {
  margin: 0;
}

.order-card p:last-child {
  margin-bottom: 0;
}

.order-intro {
  font-weight: 500;
  color: #2f241b;
}

.order-note {
  border-left: 3px solid rgba(248, 200, 19, 0.65);
  padding-left: 12px;
  color: #2f241b;
  font-weight: 600;
  background: rgba(248, 200, 19, 0.08);
  border-radius: 0 12px 12px 0;
  padding-top: 10px;
  padding-bottom: 10px;
}

.order-highlight {
  font-weight: 700;
}

.order-highlight-whatsapp {
  color: #1f9d57;
}

.order-highlight-instagram {
  color: #d14d72;
}

.order-highlight-bizum {
  color: #c2187a;
}

.order-highlight-transfer {
  color: #6a4fd8;
}

.order-highlight-correos {
  color: #1d5fd1;
}

.order-highlight-mail {
  color: #2d7df6;
}

.order-alert {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid rgba(244, 122, 17, 0.2);
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(244, 122, 17, 0.08), rgba(248, 200, 19, 0.06));
  color: #2f241b;
}

.order-alert-icon {
  flex: 0 0 22px;
  width: 22px;
  height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(244, 122, 17, 0.16);
  color: #d35f12;
  font-family: var(--font-round);
  font-size: 0.82rem;
  font-weight: 700;
  line-height: 1;
}

.order-list {
  margin: 0;
  padding-left: 20px;
  display: grid;
  gap: 8px;
}

.actions {
  display: flex;
  gap: 10px;
}

.container {
  width: min(1200px, 94vw);
  margin: 0 auto 32px;
}

/* ── WHATSAPP FAB ─────────────────────── */
.whatsapp-fab {
  position: fixed;
  bottom: 28px;
  right: 28px;
  z-index: 100;
  display: flex;
  align-items: center;
  gap: 10px;
  background: #25d366;
  color: #fff;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.88rem;
  padding: 13px 20px 13px 16px;
  border-radius: 999px;
  box-shadow: 0 6px 24px rgba(37, 211, 102, 0.45), 0 2px 8px rgba(0,0,0,0.18);
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.whatsapp-fab:hover {
  transform: translateY(-3px) scale(1.03);
  box-shadow: 0 10px 32px rgba(37, 211, 102, 0.55), 0 4px 12px rgba(0,0,0,0.2);
}

.whatsapp-fab:active {
  transform: translateY(0) scale(0.98);
}

.hidden {
  display: none !important;
}

/* ── TABS ─────────────────────────────── */
.tabs-nav {
  display: flex;
  gap: 8px;
  margin-bottom: 18px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 0;
}

.tab-btn {
  background: none;
  border: none;
  border-bottom: 3px solid transparent;
  color: #3d3127;
  font-family: var(--font-round);
  font-weight: 700;
  font-size: 1rem;
  padding: 10px 18px;
  cursor: pointer;
  margin-bottom: -1px;
  border-radius: 10px 10px 0 0;
  transition: color 160ms ease, border-color 160ms ease, background 160ms ease;
}

.tab-btn:hover {
  color: #17110b;
  background: rgba(248, 200, 19, 0.16);
}

.tab-btn.active {
  color: var(--brand);
  border-bottom-color: var(--brand);
  background: rgba(248, 200, 19, 0.1);
}

body.connected .tab-btn {
  color: #ffe9c7;
}

body.connected .tab-btn:hover {
  color: #fff9eb;
  background: rgba(248, 200, 19, 0.18);
}

/* ── HISTORIA ─────────────────────────── */
.historia-hero {
  position: relative;
  border-radius: 22px;
  overflow: hidden;
  height: 380px;
  margin-bottom: 40px;
}

.historia-hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.historia-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(7,7,10,0.82) 0%, rgba(7,7,10,0.28) 60%, transparent 100%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 36px 40px;
  color: #fff;
}

.historia-hero-overlay .eyebrow {
  color: var(--brand);
  margin-bottom: 6px;
}

.historia-hero-overlay h2 {
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  margin: 0 0 10px;
  line-height: 1.15;
  text-shadow: 0 2px 12px rgba(0,0,0,0.5);
}

.historia-hero-overlay p {
  font-size: 1rem;
  opacity: 0.82;
  margin: 0;
  max-width: 520px;
}

.historia-body {
  display: grid;
  grid-template-columns: 1fr 1.6fr;
  gap: 48px;
  align-items: start;
  padding-bottom: 40px;
}

.historia-info {
  position: sticky;
  top: 16px;
  display: grid;
  gap: 12px;
}

.contact-card,
.location-card {
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 12px;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0.07));
  box-shadow: var(--shadow);
}

.hours-card {
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 12px;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.08));
  box-shadow: var(--shadow);
}

.hours-title {
  margin: 0 0 9px;
  font-family: var(--font-round);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #1e1712;
  font-weight: 700;
}

.historia-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
}

.historia-pills span {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  color: #2c1e07;
  border: 1px solid rgba(248, 200, 19, 0.4);
  border-radius: 999px;
  padding: 5px 12px;
  background: rgba(248, 200, 19, 0.16);
}

.historia-address {
  font-size: 0.88rem;
  color: #2b2420;
  margin: 0;
  line-height: 1.5;
}

.historia-block-title {
  margin: 2px 0 8px;
  font-family: var(--font-round);
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #302620;
  font-weight: 700;
}

.shop-open-status {
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.86rem;
  line-height: 1.35;
  color: #201812;
  font-weight: 700;
}

.shop-open-status::before {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
  background: #8a8a8a;
  box-shadow: 0 0 0 5px rgba(138, 138, 138, 0.2);
}

.shop-open-status.open::before {
  background: #2fe07d;
  box-shadow: 0 0 0 5px rgba(47, 224, 125, 0.22);
}

.shop-open-status.closed::before {
  background: #ff8d52;
  box-shadow: 0 0 0 5px rgba(255, 141, 82, 0.2);
}

.shop-open-detail {
  display: none;
}

body.connected .historia-pills span {
  color: #ffeec5;
  background: rgba(248, 200, 19, 0.2);
}

body.connected .hours-title {
  color: #fff0d4;
}

body.connected .shop-open-status {
  color: #fff6ea;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.5);
}

body.connected .historia-address {
  color: #ffe3cb;
}

body.connected .historia-block-title {
  color: #ffe6c9;
}

.historia-map {
  margin-top: 8px;
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  justify-self: stretch;
}

.historia-map iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

.historia-text {
  border-left: 2px solid var(--line);
  padding-left: 36px;
}

.historia-text .eyebrow {
  margin-bottom: 6px;
}

.historia-text h3 {
  font-family: var(--font-round);
  font-size: 1.5rem;
  margin: 0 0 20px;
}

.historia-text p {
  font-size: 1.02rem;
  line-height: 1.8;
  color: var(--ink-soft);
  margin: 0 0 20px;
}

.historia-text p:last-child {
  margin-bottom: 0;
}

/* ── BRAND HERO ───────────────────────── */
.brand-hero {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 14px;
  margin-bottom: 14px;
}

.panel-lite {
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(8px);
  padding: 16px;
}

.eyebrow {
  margin: 0 0 8px;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--brand-4);
}

.brand-bio h2 {
  margin: 0;
  font-size: clamp(1.2rem, 2vw, 1.9rem);
  line-height: 1.2;
}

.brand-bio p {
  color: var(--ink-soft);
}

.info-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.info-pills span {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 0.85rem;
  color: var(--ink-soft);
  background: rgba(255, 255, 255, 0.25);
}

.brand-links h3 {
  margin: 0;
}

.brand-links p {
  margin: 8px 0 10px;
  color: var(--ink-soft);
  font-size: 0.93rem;
}

.quick-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.historia-info .quick-links {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.quick-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
  color: var(--ink-soft);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 0.84rem;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.22);
  transition: 160ms ease, box-shadow 160ms ease;
}

.historia-info .quick-link:first-child {
  color: #0f5f3b;
  border-color: rgba(37, 211, 102, 0.45);
  background: linear-gradient(120deg, rgba(37, 211, 102, 0.25), rgba(37, 211, 102, 0.1));
}

.historia-info .quick-link:last-child {
  color: #611c7d;
  border-color: rgba(188, 42, 141, 0.45);
  background: linear-gradient(120deg, rgba(188, 42, 141, 0.22), rgba(251, 173, 80, 0.13));
}

.historia-info .quick-link svg {
  width: 16px;
  height: 16px;
}

.quick-link:hover {
  transform: translateY(-2px);
  color: var(--ink);
  border-color: rgba(248, 200, 19, 0.7);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.14);
}

body.connected .historia-info .quick-links {
  background: transparent;
}

body.connected .historia-info .quick-link:first-child {
  color: #c6ffd9;
}

body.connected .historia-info .quick-link:last-child {
  color: #ffd4ee;
}

.panel,
.catalog-shell {
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(8px);
}

.panel {
  padding: 18px;
}

.panel p,
.panel li {
  color: var(--ink-soft);
}

.catalog-shell {
  margin-top: 14px;
  padding: 16px;
  display: block;
}

.toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.catalog-title {
  margin: 0;
  font-size: 1.1rem;
}

.status {
  font-weight: 500;
  color: var(--ink-soft);
}

/* ── BUSCADOR ─────────────────────────── */
.filters-row {
  margin-top: 12px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
}

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

.search-icon {
  position: absolute;
  left: 14px;
  width: 16px;
  height: 16px;
  color: var(--ink-soft);
  pointer-events: none;
  flex-shrink: 0;
}

.search-input {
  width: 100%;
  padding: 10px 40px 10px 40px;
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-radius: 999px;
  font: inherit;
  font-size: 0.92rem;
  color: var(--ink);
  outline: none;
  transition: border-color 160ms ease, box-shadow 160ms ease;
  -webkit-appearance: none;
}

.search-input::placeholder {
  color: var(--ink-soft);
  opacity: 0.7;
}

.search-input:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(248, 200, 19, 0.18);
}

.search-input::-webkit-search-cancel-button {
  display: none;
}

.search-clear {
  position: absolute;
  right: 12px;
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-soft);
  padding: 4px;
  border-radius: 50%;
  transition: color 120ms ease, background 120ms ease;
}

.search-clear:hover {
  color: var(--ink);
  background: var(--line);
}

.sort-wrap {
  display: grid;
  gap: 3px;
}

.sort-label {
  font-size: 0.72rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

.sort-select {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.12);
  color: var(--ink);
  font: inherit;
  font-size: 0.86rem;
  padding: 9px 11px;
  cursor: pointer;
  min-width: 225px;
}

.sort-select:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(248, 200, 19, 0.18);
}

.category-section {
  margin-top: 12px;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 12px;
  background: linear-gradient(150deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.01));
}

.menu-label {
  margin: 0 0 8px;
  font-size: 0.74rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-soft);
  font-weight: 700;
}

.menu-label.sub {
  margin-top: 10px;
}

.category-menu {
  margin-top: 0;
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 2px 1px 6px;
}

.subcategory-menu {
  border-top: 1px dashed rgba(255, 255, 255, 0.14);
  padding-top: 12px;
}

.category-menu::-webkit-scrollbar {
  height: 8px;
}

.category-menu::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.16);
  border-radius: 999px;
}

.category-chip {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 15px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--ink-soft);
  font: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
  transition: 180ms ease, box-shadow 180ms ease;
}

.category-chip:hover {
  transform: translateY(-1px);
  border-color: rgba(255, 255, 255, 0.35);
}

.category-chip.active {
  border-color: transparent;
  color: #14100b;
  background: linear-gradient(120deg, var(--brand), var(--brand-4));
  box-shadow: 0 8px 20px rgba(244, 122, 17, 0.26);
}

.category-chip.offer-chip {
  border-color: transparent;
  color: #fff;
  background: linear-gradient(120deg, #ef7582, #f47a11);
  box-shadow: 0 0 0 2px rgba(248, 200, 19, 0.35), 0 10px 24px rgba(239, 117, 130, 0.35);
}

.category-chip.anniversary-chip {
  border-color: transparent;
  color: #fff9df;
  background: linear-gradient(120deg, #0fa3b1, #31c9d2);
  box-shadow: 0 0 0 2px rgba(49, 201, 210, 0.3), 0 10px 24px rgba(49, 201, 210, 0.28);
}

.category-chip.soft-active {
  border-color: rgba(255, 255, 255, 0.24);
  color: var(--ink);
  background: rgba(255, 255, 255, 0.2);
}

body.connected .category-chip.soft-active {
  color: #fff6df;
}

.gallery-grid {
  margin-top: 16px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 14px;
}

body.lightbox-open {
  overflow: hidden;
}

.image-card {
  position: relative;
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid var(--line);
  min-height: 240px;
  box-shadow: var(--shadow);
  opacity: 0;
  transform: translateY(16px);
  animation: rise 420ms ease forwards;
}

.image-card.offer-item {
  border-color: rgba(248, 200, 19, 0.8);
  box-shadow: 0 0 0 1px rgba(248, 200, 19, 0.6), 0 18px 30px rgba(244, 122, 17, 0.28);
}

.image-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.image-card.out-of-stock img {
  filter: blur(2.4px) brightness(0.72) saturate(0.85);
  transform: scale(1.02);
}

.stock-overlay {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 2;
  pointer-events: none;
  padding: 7px 14px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.45);
  background: rgba(10, 10, 12, 0.7);
  color: #fff;
  font-size: 0.86rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.38);
}

.image-caption {
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 10px;
  padding: 10px 12px;
  border-radius: 12px;
  background: linear-gradient(180deg, rgba(7, 7, 10, 0.35) 0%, rgba(7, 7, 10, 0.88) 100%);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  color: #fff;
  display: flex;
  gap: 10px;
  align-items: center;
}

.image-caption h3 {
  margin: 0;
  flex: 1;
  min-width: 0;
  font-size: 0.92rem;
  line-height: 1.2;
  white-space: normal;
  overflow-wrap: anywhere;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.8);
}

.image-meta {
  grid-area: meta;
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  min-width: 0;
}

.image-tag {
  width: fit-content;
  font-size: 0.72rem;
  letter-spacing: 0.03em;
  color: #ffeebf;
  border: 1px solid rgba(248, 200, 19, 0.46);
  border-radius: 999px;
  padding: 3px 8px;
}

.offer-badge {
  width: fit-content;
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  font-weight: 700;
  color: #1b1308;
  border-radius: 999px;
  padding: 3px 8px;
  background: linear-gradient(120deg, #f8c813, #f47a11);
}

.image-price-tag {
  margin-left: auto;
  align-self: center;
  flex-shrink: 0;
  color: #111;
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.01em;
  border-radius: 999px;
  padding: 5px 10px;
  background: linear-gradient(120deg, #ffffff, #ffe9ad);
  border: 1px solid rgba(255, 255, 255, 0.7);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.28);
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 210;
  background: rgba(6, 6, 10, 0.9);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 18px;
}

.lightbox-image {
  max-width: min(94vw, 1100px);
  max-height: 78vh;
  width: auto;
  height: auto;
  border-radius: 14px;
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.48);
}

.lightbox-caption {
  margin: 12px 0 0;
  color: #fff;
  font-weight: 600;
  text-align: center;
}

.lightbox-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 42px;
  height: 42px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.36);
  background: rgba(0, 0, 0, 0.38);
  color: #fff;
  font-size: 1.18rem;
  line-height: 1;
  cursor: pointer;
}


.btn {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.12);
  color: var(--ink);
  font: inherit;
  border-radius: 999px;
  padding: 9px 14px;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: 180ms ease;
}

body.connected .btn {
  color: #fff;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn:disabled {
  opacity: 0.56;
  cursor: not-allowed;
}

.btn.primary {
  border: 0;
  color: #15110b;
  background: linear-gradient(120deg, var(--brand), var(--brand-4));
}

.empty-state {
  grid-column: 1 / -1;
  border: 1px dashed var(--line);
  border-radius: 14px;
  padding: 16px;
  color: var(--ink-soft);
  background: rgba(255, 255, 255, 0.05);
}

.error {
  color: #f17777;
}

@keyframes rise {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes haloPulseOpen {
  0%,
  100% {
    box-shadow:
      0 0 0 7px rgba(47, 224, 125, 0.14),
      0 10px 24px rgba(47, 224, 125, 0.32);
  }
  50% {
    box-shadow:
      0 0 0 12px rgba(47, 224, 125, 0.24),
      0 12px 28px rgba(47, 224, 125, 0.44);
  }
}

@keyframes haloPulseClosed {
  0%,
  100% {
    box-shadow:
      0 0 0 7px rgba(255, 141, 82, 0.12),
      0 10px 24px rgba(255, 141, 82, 0.28);
  }
  50% {
    box-shadow:
      0 0 0 12px rgba(255, 141, 82, 0.2),
      0 12px 28px rgba(255, 141, 82, 0.36);
  }
}

@media (max-width: 700px) {
  .brand-hero {
    grid-template-columns: 1fr;
  }

  .topbar {
    padding-top: 12px;
  }

  .brand-logo {
    width: 52px;
    height: 52px;
  }

  .title-wrap h1 {
    font-size: 1.28rem;
  }

  .title-wrap p {
    display: none;
  }

  .historia-map {
    width: 100%;
    max-width: none;
  }

  .historia-hero {
    height: 260px;
  }

  .historia-hero-overlay {
    padding: 24px 20px;
  }

  .historia-body {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .historia-info {
    position: static;
  }

  .historia-text {
    border-left: none;
    padding-left: 0;
    border-top: 2px solid var(--line);
    padding-top: 28px;
  }

  .filters-row {
    grid-template-columns: 1fr;
  }

  .sort-select {
    min-width: 0;
    width: 100%;
  }

  .category-section {
    padding: 10px;
  }

  .gallery-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .image-card {
    min-height: 180px;
  }

  .image-caption {
    left: 8px;
    right: 8px;
    bottom: 8px;
    padding: 8px 10px;
  }

  .image-caption h3 {
    font-size: 0.84rem;
  }

  .image-tag,
  .offer-badge {
    font-size: 0.66rem;
  }

  .image-price-tag {
    right: 9px;
    bottom: 9px;
    font-size: 0.72rem;
    padding: 4px 8px;
  }

  .orders-layout {
    gap: 12px;
  }

  .order-card-head {
    gap: 8px;
  }

  .order-icon {
    flex-basis: 24px;
    width: 24px;
    min-width: 24px;
    max-width: 24px;
    height: 24px;
    min-height: 24px;
    max-height: 24px;
    border-radius: 8px;
  }

  .order-icon svg {
    width: 10px;
    min-width: 10px;
    max-width: 10px;
    height: 10px;
    min-height: 10px;
    max-height: 10px;
    flex-basis: 10px;
  }
}
