/* ════════════════════════════════════════════
   BORDERSHOP — style-new.css  v2
   Black Minimal Design
════════════════════════════════════════════ */

:root {
  --bg:        #0d0d0d;
  --surface:   #161616;
  --surface2:  #1e1e1e;
  --border:    #2a2a2a;
  --border2:   #333333;
  --white:     #f0f0f0;
  --gray-100:  #cccccc;
  --gray-200:  #999999;
  --gray-300:  #666666;
  --red:       #e02020;
  --font-display: 'Playfair Display', serif;
  --font-body:    'DM Sans', sans-serif;
  --max-width: 1280px;
  --radius:    4px;
  --transition: 0.2s ease;
  --infobar-h: 34px;
  --header-h:  60px;
}

/* ── RESET ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--white);
  font-size: 15px;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; }
a { text-decoration: none; color: inherit; }
button { cursor: pointer; border: none; background: none; font-family: inherit; color: inherit; }

/* ════════════════════════════════════════════
   INFO BAR
════════════════════════════════════════════ */
#info-bar {
  position: sticky;
  top: 0;
  z-index: 300;
  background: #111;
  border-bottom: 1px solid var(--border);
  height: var(--infobar-h);
  display: flex;
  align-items: center;
  justify-content: center;
}

.info-bar-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
}

.info-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.7px;
  color: var(--gray-100);
  padding: 0 20px;
  white-space: nowrap;
}

.info-badge .dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--red);
  flex-shrink: 0;
}

.info-sep {
  width: 1px;
  height: 13px;
  background: var(--border2);
  flex-shrink: 0;
}

/* ════════════════════════════════════════════
   HEADER
════════════════════════════════════════════ */
#site-header {
  position: sticky;
  top: var(--infobar-h);
  z-index: 200;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  height: var(--header-h);
  display: flex;
  align-items: center;
  padding: 0 32px;
}

.header-inner {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

/*
  Logo filter strategy:
  - We use a two-layer trick via a wrapper + CSS.
  - The img itself gets no filter — your logo should already have
    white text + red pin natively in the PNG file.
  - If your PNG has BLACK text (not white), add:
      filter: invert(1);
    That will flip black→white but also flip red→cyan, so instead
    export your logo PNG with white text + red pin and no filter needed.
  - Current assumption: logo PNG already has white text + red pin.
*/
.logo-img {
  height: 52px;
  width: auto;
  object-fit: contain;
}

/* ════════════════════════════════════════════
   CATEGORY NAV
════════════════════════════════════════════ */
.cat-nav {
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: calc(var(--infobar-h) + var(--header-h));
  z-index: 150;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.cat-nav::-webkit-scrollbar { display: none; }

.cat-nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 32px;
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  min-width: max-content;
}

.cat-item {
  padding: 13px 15px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--gray-200);
  white-space: nowrap;
  letter-spacing: 0.3px;
  transition: color var(--transition);
  border-bottom: 2px solid transparent;
  background: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 5px;
}

.cat-item:hover { color: var(--white); }
.cat-item.active { color: var(--white); border-bottom-color: var(--white); }
.cat-item .arrow { font-size: 9px; opacity: 0.6; transition: transform var(--transition); }

/* ════════════════════════════════════════════
   PRODUCTS SECTION
════════════════════════════════════════════ */
.products-section {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 22px 32px 64px;
}

.products-header {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 16px;
}

.products-header h3 {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 600;
  color: var(--white);
}

.product-count { font-size: 12px; color: var(--gray-300); }

/* ── Desktop: 5 columns so ~10 cards are visible at a glance ── */
.products-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
}

/* ── Product Card ── */
.product-card {
  cursor: pointer;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: border-color var(--transition), transform var(--transition);
  animation: fadeUp 0.3s ease both;
}

.product-card:hover { border-color: var(--border2); transform: translateY(-2px); }

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

.product-img-wrap {
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: var(--surface2);
}

.product-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.32s ease;
}

.product-card:hover .product-img-wrap img { transform: scale(1.05); }

.product-badge {
  position: absolute;
  top: 7px; left: 7px;
  background: var(--white);
  color: var(--bg);
  font-size: 8.5px;
  font-weight: 700;
  letter-spacing: 1px;
  padding: 2px 6px;
  border-radius: 2px;
  text-transform: uppercase;
}
.product-badge.badge-sale { background: var(--red); color: #fff; }

.product-info { padding: 10px 10px 12px; }
.product-cat-label { font-size: 8.5px; letter-spacing: 1.5px; text-transform: uppercase; color: var(--gray-300); margin-bottom: 4px; }
.product-name { font-family: var(--font-display); font-size: 13px; font-weight: 600; color: var(--white); margin-bottom: 5px; line-height: 1.3; }
.product-price { font-size: 13px; font-weight: 600; color: var(--white); }
.product-origin { font-size: 9.5px; color: var(--gray-300); margin-top: 2px; }

.no-products {
  text-align: center; padding: 60px 20px;
  color: var(--gray-300); font-size: 14px; grid-column: 1/-1;
}

/* ════════════════════════════════════════════
   PRODUCT MODAL
   Desktop: side-by-side, right column has
   sticky action bar at bottom.
   Mobile: stacked, actions stick to bottom.
════════════════════════════════════════════ */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.78);
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease;
}
.modal-overlay.open { opacity: 1; pointer-events: all; }

.modal {
  background: var(--surface);
  border: 1px solid var(--border2);
  border-radius: var(--radius);
  max-width: 860px;
  width: 100%;
  max-height: 90vh;
  position: relative;
  transform: scale(0.97) translateY(8px);
  transition: transform 0.22s ease;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.modal-overlay.open .modal { transform: scale(1) translateY(0); }

.modal-close {
  position: absolute;
  top: 10px; right: 10px;
  width: 30px; height: 30px;
  background: var(--surface2);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; color: var(--gray-200);
  z-index: 20;
  transition: background var(--transition), color var(--transition);
}
.modal-close:hover { background: var(--white); color: var(--bg); }

/* Side-by-side on desktop */
.modal-body {
  display: grid;
  grid-template-columns: 1fr 1fr;
  flex: 1;
  overflow: hidden;
  min-height: 0;
}

.modal-images {
  padding: 20px;
  background: var(--surface2);
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow-y: auto;
}

.modal-main-image { border-radius: var(--radius); overflow: hidden; }
.modal-main-image img { width: 100%; height: auto; display: block; }

.modal-thumbs { display: flex; gap: 7px; flex-wrap: wrap; }

.modal-thumb {
  width: 54px; height: 54px;
  object-fit: cover;
  border-radius: var(--radius);
  cursor: pointer;
  border: 2px solid transparent;
  transition: border-color var(--transition);
  opacity: 0.7;
}
.modal-thumb.active, .modal-thumb:hover { border-color: var(--white); opacity: 1; }

/* Right column: scrollable content + sticky footer */
.modal-details {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-height: 0;
}

.modal-details-scroll {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 44px 22px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.modal-category { font-size: 10px; letter-spacing: 2px; text-transform: uppercase; color: var(--gray-300); }
.modal-title { font-family: var(--font-display); font-size: 22px; font-weight: 700; color: var(--white); line-height: 1.2; }
.modal-description { font-size: 13.5px; color: var(--gray-200); line-height: 1.75; }

.modal-price-block {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.modal-price { font-family: var(--font-display); font-size: 24px; font-weight: 700; color: var(--white); }
.modal-origin { font-size: 12px; color: var(--gray-300); }

/* Sticky action bar — always visible */
.modal-actions-bar {
  flex-shrink: 0;
  padding: 10px 22px 16px;
  border-top: 1px solid var(--border);
  background: var(--surface);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.modal-actions { display: flex; gap: 8px; }

.btn-order {
  display: flex; align-items: center; justify-content: center; gap: 7px;
  padding: 11px 14px;
  border-radius: var(--radius);
  font-size: 13px; font-weight: 600;
  transition: filter 0.18s ease, transform 0.18s ease;
  cursor: pointer; flex: 1;
}
.btn-order:hover { filter: brightness(0.85); transform: translateY(-1px); }
.btn-whatsapp  { background: #25D366; color: #fff; }
.btn-instagram { background: linear-gradient(135deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888); color: #fff; }

.modal-note { font-size: 11px; color: var(--gray-300); line-height: 1.5; }

/* ════════════════════════════════════════════
   HOW TO ORDER MODAL
════════════════════════════════════════════ */
/* ════════════════════════════════════════════
   HOW TO ORDER MODAL — two-panel design
════════════════════════════════════════════ */
/* ════════════════════════════════════════════
   HOW TO ORDER MODAL — bold minimal
════════════════════════════════════════════ */
/* ════════════════════════════════════════════
   HOW TO ORDER MODAL — red bold
════════════════════════════════════════════ */
/* ════════════════════════════════════════════
   HOW TO ORDER MODAL — black compact square
════════════════════════════════════════════ */
.hto-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.82);
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease;
}
.hto-overlay.open { opacity: 1; pointer-events: all; }

.hto-modal {
  background: #021b04;
  border: 1px solid #2a2a2a;
  border-radius: 14px;
  width: 100%;
  max-width: 460px;
  max-height: 560px;
  height: 560px;
  position: relative;
  transform: scale(0.97) translateY(10px);
  transition: transform 0.22s ease;
  box-shadow: 0 24px 64px rgba(0,0,0,0.7);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.hto-overlay.open .hto-modal { transform: scale(1) translateY(0); }

.hto-close {
  position: absolute;
  top: 14px; right: 14px;
  width: 28px; height: 28px;
  background: #2a2a2a;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; color: #aaa;
  z-index: 20;
  border: none; cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.hto-close:hover { background: #f0f0f0; color: #111; }

.hto-scroll {
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 32px 28px 28px;
  flex: 1;
}

.hto-eyebrow {
  font-size: 9.5px;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--red);
  font-weight: 700;
  margin-bottom: 12px;
}

.hto-headline {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: #f0f0f0;
  line-height: 1.35;
  margin-bottom: 0;
}

/* remove mixed-style spans — just style them same as headline */
.hto-hl-light,
.hto-hl-bold {
  display: inline;
  font-family: var(--font-display);
  font-style: normal;
  font-weight: 700;
  font-size: inherit;
  color: inherit;
}

.hto-divider {
  width: 36px; height: 2px;
  background: var(--red);
  border-radius: 2px;
  margin: 16px 0;
}

.hto-section-label {
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: #555;
  font-weight: 600;
  margin-bottom: 14px;
}

.hto-steps {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 13px;
}

.hto-step { display: flex; gap: 12px; align-items: flex-start; }

.hto-num {
  flex-shrink: 0;
  width: 24px; height: 24px;
  border-radius: 50%;
  background: var(--red);
  color: #fff;
  font-size: 11px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  margin-top: 1px;
}

.hto-step-body { font-size: 12.5px; color: #888; line-height: 1.55; }
.hto-step-body strong { display: block; color: #f0f0f0; font-size: 13px; margin-bottom: 2px; }

/* Mobile — centered, squarish, no scroll */
@media (max-width: 768px) {
  .hto-overlay {
    align-items: center;
    justify-content: center;
    padding: 24px;
  }
  .hto-modal {
    max-width: 100%;
    width: 100%;
    height: auto;
    max-height: 82vh;
    border-radius: 14px;
  }
  .hto-scroll { padding: 26px 20px 22px; overflow-y: auto; }
  .hto-headline { font-size: 17px; }
  .hto-steps { gap: 10px; }
  .hto-step-body { font-size: 12px; }
  .hto-step-body strong { font-size: 12.5px; }
  .hto-eyebrow { margin-bottom: 8px; }
  .hto-divider { margin: 12px 0; }
  .hto-section-label { margin-bottom: 10px; }
}

/* ════════════════════════════════════════════
   FOOTER
════════════════════════════════════════════ */
footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 36px 32px;
}
.footer-inner {
  max-width: var(--max-width); margin: 0 auto;
  display: flex; flex-direction: column; align-items: center;
  gap: 14px; text-align: center;
}
.footer-tagline { font-size: 12.5px; color: var(--gray-300); }
.footer-socials { display: flex; gap: 10px; }
.social-icon {
  width: 36px; height: 36px;
  background: var(--surface2); border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--gray-200);
  transition: background var(--transition), color var(--transition);
}
.social-icon:hover { background: var(--white); color: var(--bg); }
.footer-copy { font-size: 11.5px; color: var(--gray-300); }

/* ════════════════════════════════════════════
   HELP WIDGET (sticky bottom-right)
════════════════════════════════════════════ */
.help-widget {
  position: fixed;
  bottom: 24px; right: 24px;
  z-index: 500;
  display: flex; flex-direction: column;
  align-items: flex-end; gap: 8px;
}

/* How to Order button — dark with red accent border */
.hto-trigger-btn {
  display: flex; align-items: center; gap: 6px;
  padding: 9px 14px 9px 11px;
  background: var(--surface);
  color: var(--white);
  border: 1px solid var(--red);
  border-radius: 22px;
  font-size: 12px; font-weight: 600;
  box-shadow: 0 3px 14px rgba(0,0,0,0.5);
  transition: background var(--transition), color var(--transition), transform var(--transition);
  letter-spacing: 0.2px;
}
.hto-trigger-btn svg { flex-shrink: 0; color: var(--red); }
.hto-trigger-btn:hover { background: var(--red); color: #fff; transform: scale(1.03); }
.hto-trigger-btn:hover svg { color: #fff; }

/* Contact Us button — dark surface, white text */
.help-btn {
  display: flex; align-items: center; gap: 7px;
  padding: 11px 16px 11px 13px;
  background: var(--surface);
  color: var(--white);
  border: 1px solid var(--border2);
  border-radius: 24px;
  font-size: 12.5px; font-weight: 600;
  box-shadow: 0 4px 20px rgba(0,0,0,0.6);
  transition: background var(--transition), border-color var(--transition), transform var(--transition);
}
.help-btn:hover { background: var(--surface2); border-color: var(--white); transform: scale(1.03); }

.help-popup {
  display: flex; flex-direction: column; gap: 7px;
  opacity: 0; pointer-events: none;
  transform: translateY(8px) scale(0.96);
  transform-origin: bottom right;
  transition: opacity 0.18s ease, transform 0.18s ease;
}
.help-popup.open { opacity: 1; pointer-events: all; transform: translateY(0) scale(1); }

.help-option {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 14px; border-radius: 22px;
  font-size: 12.5px; font-weight: 500;
  white-space: nowrap; color: #fff;
  box-shadow: 0 2px 12px rgba(0,0,0,0.4);
  transition: filter var(--transition), transform var(--transition);
}
.help-option:hover { filter: brightness(0.88); transform: translateX(-2px); }
.help-wa { background: #25D366; }
.help-ig { background: linear-gradient(135deg, #f09433, #dc2743, #bc1888); }

/* ════════════════════════════════════════════
   DROPDOWN PANEL (JS-injected)
════════════════════════════════════════════ */
#js-dropdown-panel {
  background: var(--surface) !important;
  border: 1px solid var(--border2) !important;
  border-top: 2px solid var(--white) !important;
  box-shadow: 0 8px 28px rgba(0,0,0,0.5) !important;
}

/* ════════════════════════════════════════════
   RESPONSIVE — TABLET
════════════════════════════════════════════ */
@media (max-width: 1100px) {
  .products-grid { grid-template-columns: repeat(4, 1fr); }
}
@media (max-width: 860px) {
  .products-grid { grid-template-columns: repeat(3, 1fr); }
}

/* ════════════════════════════════════════════
   RESPONSIVE — MOBILE
════════════════════════════════════════════ */
@media (max-width: 768px) {
  :root {
    --infobar-h: 30px;
    --header-h:  52px;
  }

  #info-bar { height: var(--infobar-h); }
  .info-badge { font-size: 9.5px; padding: 0 10px; gap: 5px; }

  #site-header { padding: 0 16px; }
  .cat-nav-inner { padding: 0 12px; }
  .cat-item { padding: 11px 10px; font-size: 12px; }

  .products-section { padding: 16px 12px 56px; }
  .products-header h3 { font-size: 16px; }

  /* 3 columns on mobile so user sees ~6 cards */
  .products-grid { grid-template-columns: repeat(3, 1fr); gap: 8px; }

  .product-info { padding: 8px 8px 10px; }
  .product-name { font-size: 11.5px; }
  .product-price { font-size: 11.5px; }

  /* Modal: slides up from bottom */
  .modal-overlay { padding: 0; align-items: flex-end; }
  .modal {
    border-radius: 16px 16px 0 0;
    max-height: 94vh; width: 100%; max-width: 100%;
    transform: translateY(30px);
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }
  .modal-overlay.open .modal { transform: translateY(0); }

  /* Scrollable area: image + description only */
  .modal-body {
    display: flex;
    flex-direction: column;
    flex: 1;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    min-height: 0;
  }

  .modal-images { padding: 12px 12px 0; background: var(--surface2); flex-shrink: 0; }
  .modal-main-image img { height: 220px; width: 100%; object-fit: cover; border-radius: 4px; }
  .modal-thumb { width: 44px; height: 44px; }

  /* Only the description scrolls — title/price stay with it but in the scrollable zone */
  .modal-details { overflow: visible; flex-shrink: 0; }
  .modal-details-scroll { padding: 14px 16px 8px; overflow: visible; flex: none; }

  /* Hide price from scroll area on mobile — we'll show it in the sticky bar */
  .modal-price-block { display: none; }

  .modal-title  { font-size: 17px; }
  .modal-description { font-size: 13px; }

  /* Sticky bottom bar: price + order buttons always visible */
  .modal-actions-bar {
    position: sticky;
    bottom: 0;
    background: var(--surface);
    border-top: 1px solid var(--border);
    padding: 10px 16px 22px;
    z-index: 10;
    flex-shrink: 0;
  }

  /* Show price inside the sticky bar on mobile */
  .modal-actions-bar::before {
    content: attr(data-price);
    display: block;
    font-family: var(--font-display);
    font-size: 20px;
    font-weight: 700;
    color: var(--white);
    margin-bottom: 10px;
  }

  .help-widget { bottom: 16px; right: 14px; gap: 7px; }
  .help-btn { padding: 10px 13px 10px 11px; font-size: 12px; }
  .hto-trigger-btn { padding: 8px 12px 8px 10px; font-size: 11px; }

  footer { padding: 28px 16px; }


}

/* 2 columns on very small phones */
@media (max-width: 420px) {
  .info-badge { font-size: 8.5px; padding: 0 7px; gap: 4px; }
  .info-sep { height: 10px; }
}

/* Disable hover effects on touch devices */
@media (hover: none) {
  .product-card:hover { transform: none; border-color: var(--border); }
  .product-card:hover .product-img-wrap img { transform: none; }
  .btn-order:hover { filter: none; transform: none; }
  .help-btn:hover  { transform: none; background: var(--surface); border-color: var(--border2); }
  .hto-trigger-btn:hover { transform: none; background: var(--surface); color: var(--white); }
  .hto-trigger-btn:hover svg { color: var(--red); }
}