/* ============================================================
   WELLSPRING TEXTILE THEME
   Shared stylesheet for index.php and catalogues.php
   ============================================================ */

/* Hero swiper */
.main-swiper,
.main-swiper .swiper-slide,
.main-swiper .image-holder { width: 100%; height: 100vh; }
.main-swiper .image-holder img {
  width: 100%; height: 100%;
  object-fit: cover; display: block;
}

/* ============================================================
   LIGHTBOX
   ============================================================ */
.lightbox-overlay {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0,0,0,0.85);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}
.lightbox-content {
  position: relative;
  width: min(1280px, 95%);
  max-width: 95%;
  max-height: 95vh;
  overflow: hidden;
  background: #111;
  padding: 0;
  border-radius: 10px;
  text-align: center;
  display: flex;
  flex-direction: column;
}
.lightbox-body {
  display: flex;
  width: 100%;
  flex: 1 1 auto;
  min-height: 0;
}
.lightbox-left {
  flex: 0 0 60%;
  max-width: 60%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 10px 10px 8px;
  background: #0e0e0e;
  min-width: 0;
}
.lightbox-left .lightbox-highlight {
  flex: 1 1 auto;
  width: 100%;
  min-height: 0;
}
.lightbox-left .lightbox-label { margin: 8px 0 0; flex-shrink: 0; }
.lightbox-right {
  flex: 0 0 40%;
  max-width: 40%;
  display: flex;
  flex-direction: column;
  background: #181210;
  border-left: 1px solid rgba(201,169,110,0.18);
  padding: 22px 18px;
  min-height: 0;
}
.lightbox-right-header {
  border-bottom: 1px solid rgba(201,169,110,0.18);
  padding-bottom: 1rem;
  margin-bottom: 1rem;
  text-align: left;
}
.lightbox-right-header .lr-eyebrow {
  display: block;
  font-family: var(--heading-font);
  color: #C9A96E;
  font-size: 0.7rem;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  margin-bottom: 0.4rem;
}
.lightbox-right-header .lr-title {
  font-family: var(--heading-font);
  color: #fff;
  font-weight: 400;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: 1.15rem;
  margin: 0 0 0.35rem;
}
.lightbox-right-header .lr-count {
  font-size: 0.75rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #8B6F4E;
}
.lightbox-right .lightbox-images {
  flex: 1 1 auto;
  overflow-y: auto;
  align-content: start;
  padding-right: 4px;
}
.lightbox-right .lightbox-images::-webkit-scrollbar { width: 6px; }
.lightbox-right .lightbox-images::-webkit-scrollbar-thumb {
  background: rgba(201,169,110,0.4);
  border-radius: 3px;
}
@media (max-width: 900px) {
  .lightbox-body { flex-direction: column; }
  .lightbox-left,
  .lightbox-right { flex: 1 1 auto; max-width: 100%; border-left: none; }
  .lightbox-right { border-top: 1px solid rgba(201,169,110,0.18); max-height: 38vh; }
}
.lightbox-close {
  position: absolute;
  top: 6px;
  right: 10px;
  color: white;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  z-index: 30;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.45);
  transition: background 0.2s ease, transform 0.2s ease;
}
.lightbox-close:hover {
  background: rgba(0, 0, 0, 0.85);
  transform: scale(1.08);
}
.lightbox-highlight {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}
.lightbox-highlight img {
  max-width: 100%;
  max-height: 70vh;
  border-radius: 10px;
  object-fit: contain;
  transition: opacity 0.3s ease;
}
.nav-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0,0,0,0.6);
  border: none;
  color: white;
  font-size: 32px;
  padding: 8px 14px;
  cursor: pointer;
  border-radius: 6px;
  z-index: 10;
}
.nav-arrow.left { left: 10px; }
.nav-arrow.right { right: 10px; }
.nav-arrow:hover { background: rgba(255,255,255,0.2); }
.lightbox-label {
  color: #ccc;
  font-size: 14px;
  margin: 10px 0 20px;
  font-family: monospace;
}
/* Thumbnails — grid keeps natural aspect ratio AND allows vertical scrolling */
.lightbox-images {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  align-content: start;
}
.lightbox-images img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 4px;
  cursor: pointer;
  opacity: 0.7;
  transition: transform 0.2s, opacity 0.2s, border-color 0.2s;
  background: #222;
  border: 2px solid transparent;
  align-self: start;
}
.lightbox-images img:hover { transform: scale(1.04); opacity: 1; }
.lightbox-images img.active { border-color: #C9A96E; opacity: 1; }

/* ============================================================
   NAVBAR
   ============================================================ */
/* Only the navbar itself stays transparent; the offcanvas panel keeps its own bg */
#header-nav,
#header-nav.navbar,
#header-nav.bg-light,
#header-nav .container-fluid {
  background: transparent !important;
  box-shadow: none !important;
}
#header-nav {
  background: rgba(255, 255, 255, 0.20) !important;
  backdrop-filter: blur(16px) saturate(180%) !important;
  -webkit-backdrop-filter: blur(16px) saturate(180%) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.25);
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 999;
  transition: background 0.3s ease;
}
#header-nav .nav-link {
  color: #ffffff !important;
  font-weight: 500;
  letter-spacing: 0.5px;
  transition: color 0.2s ease;
  text-shadow: 0 1px 2px rgba(0,0,0,0.4);
}
#header-nav .nav-link:hover,
#header-nav .nav-link.active { color: #C9A96E !important; }
#header-nav .logo {
  filter: drop-shadow(0 0 4px rgba(0, 0, 0, 0.3));
  height: 45px;
}
/* Offcanvas styling lives in the mobile @media block further down */
#header-nav.scrolled { background: rgba(245, 239, 230, 0.92) !important; }
#header-nav.scrolled .nav-link { color: #2C1810 !important; text-shadow: none; }

/* For inner pages (no full hero), the navbar always has the solid look */
body.inner-page #header-nav {
  background: rgba(245, 239, 230, 0.92) !important;
  border-bottom: 1px solid rgba(201,169,110,0.18);
}
body.inner-page #header-nav .nav-link { color: #2C1810 !important; text-shadow: none; }

/* ============================================================
   THEME TOKENS
   ============================================================ */
:root {
  --primary-color: #8B4513 !important;
  --bs-primary-rgb: 139, 69, 19 !important;
  --light-blue-color: #F5EFE6 !important;
  --dark-color: #2C1810 !important;
  --accent-color: #C9A96E !important;
}
body { background: #FAF7F2; color: #2C1810; }
a:hover { color: #C9A96E; }

/* ============================================================
   SECTION HEADINGS
   ============================================================ */
.section-heading { text-align: center; margin-bottom: 3rem; }
.section-heading .eyebrow {
  font-size: 0.75rem; letter-spacing: 0.35em;
  text-transform: uppercase; color: #C9A96E;
  display: block; margin-bottom: 0.7rem;
}
.section-heading h2 {
  font-family: var(--heading-font); font-weight: 300;
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  color: #2C1810 !important; letter-spacing: 0.04em;
  margin: 0;
}
.section-heading h2::after {
  content: ""; display: block;
  width: 56px; height: 1px; background: #C9A96E;
  margin: 1rem auto 0;
}

/* ============================================================
   SERVICES
   ============================================================ */
#company-services {
  background: #FAF7F2;
  border-top: 1px solid rgba(201, 169, 110, 0.2);
  border-bottom: 1px solid rgba(201, 169, 110, 0.2);
  padding-top: 4em; padding-bottom: 4em;
}
#company-services .icon-box {
  background: #fff; padding: 1.6em 1.4em;
  border: 1px solid rgba(44, 24, 16, 0.06);
  height: 100%; transition: 0.25s ease;
}
#company-services .icon-box:hover {
  border-color: #C9A96E; transform: translateY(-3px);
  box-shadow: 0 12px 30px rgba(44,24,16,0.06);
}
#company-services .icon-box-icon svg { fill: #8B4513; width: 32px; height: 32px; }

/* ============================================================
   PRODUCT CARD (Fabric Library)
   ============================================================ */
.product-card { background: #fff; border: 1px solid rgba(44,24,16,0.06); padding-bottom: 0.4rem; transition: 0.25s; }
.product-card:hover { border-color: #C9A96E; }
.product-card .image-holder {
  background: #F5EFE6;
  padding: 0;
  position: relative;
  overflow: hidden;
  aspect-ratio: 1 / 1;
}
.product-card .image-holder img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.product-card:hover .image-holder img { transform: scale(1.06); }
.product-store .product-card .cart-concern {
  position: absolute;
  inset: 0;
  top: 0; right: 0; bottom: 0; left: 0;
  width: auto;
  background: rgba(44,24,16,0.65);
  display: flex !important;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.9rem;
  padding: 1rem;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.product-store .product-card:hover .cart-concern { bottom: 0; opacity: 1; }
.product-card .overlay-name {
  color: #C9A96E;
  font-family: var(--heading-font);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-size: 0.95rem;
  text-align: center;
  line-height: 1.3;
}
.product-card .card-title a {
  color: #2C1810; font-family: var(--heading-font);
  letter-spacing: 0.08em; font-size: 0.95rem;
}
.product-card .card-title a:hover { color: #8B4513; }
.inspect-btn { background: #2C1810 !important; border: none; letter-spacing: 0.12em; }
.inspect-btn:hover { background: #8B4513 !important; }

/* PRODUCT-SWIPER NAVIGATION */
#mobile-products .product-swiper { position: relative; padding-bottom: 2.5rem; }
#mobile-products .product-swiper-pagination {
  position: absolute;
  bottom: 0; left: 50%;
  transform: translateX(-50%);
  text-align: center;
}
#mobile-products .product-swiper-pagination .swiper-pagination-bullet {
  background: #2C1810;
  opacity: 0.25;
  width: 8px; height: 8px;
  margin: 0 4px;
  transition: opacity 0.2s, background 0.2s;
}
#mobile-products .product-swiper-pagination .swiper-pagination-bullet-active {
  opacity: 1;
  background: #C9A96E;
}
.product-swiper-nav {
  display: flex;
  justify-content: center;
  gap: 14px;
  margin-top: 1.6rem;
}
.ps-arrow {
  width: 44px; height: 44px;
  border-radius: 50%;
  border: 1px solid rgba(44,24,16,0.2);
  background: #fff;
  color: #2C1810;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: 0.2s ease;
}
.ps-arrow svg { width: 14px; height: 14px; }
.ps-arrow:hover {
  background: #C9A96E;
  color: #2C1810;
  border-color: #C9A96E;
}
.ps-arrow.swiper-button-disabled {
  opacity: 0.35;
  cursor: not-allowed;
}
.ps-arrow.swiper-button-disabled:hover {
  background: #fff;
  color: #2C1810;
  border-color: rgba(44,24,16,0.2);
}

#productSearch {
  border: 1px solid rgba(44,24,16,0.18);
  border-radius: 0; padding: 0.55em 1em;
  background: #fff; min-width: 240px;
}
#productSearch:focus { outline: none; border-color: #C9A96E; box-shadow: 0 0 0 3px rgba(201,169,110,0.18); }

/* ============================================================
   FEATURED COLLECTIONS
   ============================================================ */
.collection-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
@media (max-width: 900px) { .collection-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 540px) { .collection-grid { grid-template-columns: 1fr; } }
.collection-card {
  position: relative; overflow: hidden;
  aspect-ratio: 4 / 5; cursor: pointer;
  background: #2C1810;
}
.collection-card img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.6s ease; display: block;
}
.collection-card:hover img { transform: scale(1.06); }
.collection-card .label {
  position: absolute; inset: 0;
  background: rgba(44,24,16,0.65);
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  text-align: center; padding: 1rem;
  color: #fff;
  opacity: 0; transition: opacity 0.3s ease;
}
.collection-card:hover .label { opacity: 1; }
.collection-card .label small {
  display: block; color: #C9A96E;
  font-size: 0.7rem; letter-spacing: 0.32em;
  text-transform: uppercase; margin-bottom: 0.6rem;
}
.collection-card .label .ttl {
  font-family: var(--heading-font); font-weight: 400;
  letter-spacing: 0.18em; text-transform: uppercase;
  font-size: 1.1rem; color: #fff;
}

/* ============================================================
   YEARLY / WHOLESALE BANNER (matrix collage)
   ============================================================ */
#yearly-sale {
  position: relative;
  background-color: #2C1810 !important;
  background-image: none !important;
  overflow: hidden;
  isolation: isolate;
}
#yearly-sale .fabric-collage {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  grid-auto-rows: 1fr;
  gap: 0;
  z-index: 0;
}
#yearly-sale .fabric-collage img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: opacity 0.45s ease, transform 0.45s ease;
}
#yearly-sale .fabric-collage img.swap-out {
  opacity: 0;
  transform: scale(1.06);
  will-change: opacity, transform;
}
#yearly-sale .yearly-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, rgba(44,24,16,0.92) 0%, rgba(44,24,16,0.65) 55%, rgba(139,69,19,0.55) 100%);
  z-index: 1;
}
#yearly-sale .container { position: relative; z-index: 2; }
@media (max-width: 900px) {
  #yearly-sale .fabric-collage { grid-template-columns: repeat(6, 1fr); }
}
@media (max-width: 540px) {
  #yearly-sale .fabric-collage { grid-template-columns: repeat(4, 1fr); }
}
#yearly-sale .text-content h3 {
  color: #C9A96E !important; letter-spacing: 0.3em;
  text-transform: uppercase; font-size: 0.85rem; font-weight: 500;
}
#yearly-sale .text-content h2 { color: #fff !important; font-weight: 300; }
#yearly-sale .btn {
  background: #C9A96E !important; color: #2C1810 !important;
  border: none !important; letter-spacing: 0.18em;
}
#yearly-sale .btn:hover { background: #fff !important; }

/* ============================================================
   TESTIMONIALS
   ============================================================ */
#testimonials { background: #F5EFE6; padding: 5em 0; }
#testimonials blockquote {
  font-family: var(--heading-font); font-weight: 300;
  font-size: 1.4rem; line-height: 1.6;
  color: #2C1810; font-style: italic;
}
#testimonials .quote svg { fill: #C9A96E; }
#testimonials .star.star-fill { fill: #C9A96E; }

/* ============================================================
   FABRIC MOSAIC (masonry)
   ============================================================ */
.fabric-mosaic { column-count: 4; column-gap: 8px; }
.fabric-mosaic .tile {
  position: relative;
  overflow: hidden;
  cursor: pointer;
  margin: 0 0 8px;
  break-inside: avoid;
  -webkit-column-break-inside: avoid;
  page-break-inside: avoid;
  display: block;
}
.fabric-mosaic .tile img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.5s ease;
}
.fabric-mosaic .tile:hover img { transform: scale(1.06); }
.fabric-mosaic .tile::after {
  content: attr(data-name);
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  background: rgba(44,24,16,0.65); color: #C9A96E;
  font-family: var(--heading-font); letter-spacing: 0.18em;
  text-transform: uppercase; font-size: 0.75rem;
  opacity: 0; transition: 0.3s;
  padding: 0.5rem; text-align: center;
}
.fabric-mosaic .tile:hover::after { opacity: 1; }
@media (max-width: 1100px) { .fabric-mosaic { column-count: 3; } }
@media (max-width: 700px)  { .fabric-mosaic { column-count: 2; } }
@media (max-width: 420px)  { .fabric-mosaic { column-count: 1; } }

/* ============================================================
   CONTACT FORM
   ============================================================ */
#contact { background: #FAF7F2; }
#contact .contact-content {
  background: #fff;
  border: 1px solid rgba(44,24,16,0.08);
  border-top: 4px solid #C9A96E;
  padding: 3em clamp(1.5em, 4vw, 4em);
  max-width: 920px;
  margin: 0 auto;
}
#contact .section-heading { margin-bottom: 2.2rem; }
#contact .form-label {
  font-family: var(--heading-font);
  font-size: 0.75rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: #2C1810;
  margin-bottom: 0.4rem;
}
#contact .form-control {
  border: 1px solid rgba(44,24,16,0.18);
  background: #FAF7F2;
  padding: 0.7em 1em;
  font-size: 0.95rem;
  color: #2C1810;
  transition: 0.2s;
}
#contact .form-control:focus {
  outline: none;
  border-color: #C9A96E;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(201,169,110,0.18);
}
#contact textarea.form-control { resize: vertical; min-height: 140px; }
#contact .btn-primary {
  background: #2C1810 !important;
  border-color: #2C1810 !important;
  color: #fff !important;
  letter-spacing: 0.22em;
  padding: 0.85em 2.6em;
  transition: 0.25s;
}
#contact .btn-primary:hover {
  background: #C9A96E !important;
  border-color: #C9A96E !important;
  color: #2C1810 !important;
}

/* ============================================================
   FOOTER
   ============================================================ */
#footer { background: #2C1810; color: #cdbba6; padding-top: 4em; }
#footer p, #footer a { color: #cdbba6; }
#footer a:hover { color: #C9A96E; }
#footer .widget-title { color: #C9A96E; letter-spacing: 0.18em; font-weight: 500; }
#footer .social-links svg { fill: #C9A96E; transition: 0.2s; }
#footer .social-links a:hover svg { fill: #fff; }
#footer hr { border-color: rgba(201,169,110,0.18); }
#footer .contact-list { margin: 0; padding: 0; }
#footer .contact-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.8rem;
  padding: 0.55rem 0;
  border-bottom: 1px solid rgba(201,169,110,0.12);
  font-size: 0.9rem;
  line-height: 1.45;
}
#footer .contact-list li:last-child { border-bottom: none; }
#footer .ci-icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  color: #C9A96E;
  margin-top: 2px;
}
#footer .ci-body { color: #cdbba6; word-break: break-word; }
#footer .ci-label {
  display: block;
  font-family: var(--heading-font);
  font-size: 0.65rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: #8B6F4E;
  margin-bottom: 0.15rem;
}
#footer-bottom { background: #1a0e08; color: #8a7864; padding: 1.2em 0; }
#footer-bottom p { color: #8a7864; margin: 0; }

/* ============================================================
   MISC
   ============================================================ */
.padding-large { padding-top: 5em; padding-bottom: 5em; }

/* ============================================================
   FIND US — MAP SECTION
   ============================================================ */
#find-us { background: #F5EFE6; }
#find-us .map-card {
  background: #fff;
  border: 1px solid rgba(44,24,16,0.08);
  border-top: 4px solid #C9A96E;
  max-width: 1080px;
  margin: 0 auto;
  overflow: hidden;
}
#find-us .map-card > a { display: block; position: relative; cursor: pointer; }
#find-us .map-card > a::after {
  content: "Click map to open directions";
  position: absolute;
  bottom: 14px; left: 50%;
  transform: translateX(-50%);
  background: rgba(44,24,16,0.85);
  color: #C9A96E;
  padding: 0.45em 0.95em;
  font-size: 0.7rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-family: var(--heading-font);
  border-radius: 3px;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.25s ease;
}
#find-us .map-card > a:hover::after { opacity: 1; }
#find-us .map-embed {
  width: 100%;
  height: 420px;
  border: 0;
  display: block;
  pointer-events: none;
  filter: saturate(0.9) contrast(1.02);
}
#find-us .map-info {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.4rem;
  padding: 1.6em clamp(1.2em, 3vw, 2.4em);
  border-top: 1px solid rgba(44,24,16,0.08);
}
#find-us .map-info h4 {
  font-family: var(--heading-font);
  font-weight: 400;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #2C1810;
  margin: 0 0 0.4rem;
  font-size: 1.05rem;
}
#find-us .map-info p {
  margin: 0;
  color: #5a4737;
  font-size: 0.95rem;
  line-height: 1.5;
}
#find-us .directions-btn {
  background: #2C1810 !important;
  border: none !important;
  color: #fff !important;
  letter-spacing: 0.22em;
  padding: 0.85em 2.2em;
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  transition: 0.25s ease;
  text-decoration: none;
}
#find-us .directions-btn svg { width: 18px; height: 18px; }
#find-us .directions-btn:hover {
  background: #C9A96E !important;
  color: #2C1810 !important;
}
#find-us .directions-btn:hover svg path { fill: #2C1810; }

/* ============================================================
   SPEED DIAL (Messenger / WhatsApp / Viber)
   ============================================================ */
.speed-dial {
  position: fixed;
  right: 24px;
  bottom: 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  z-index: 9000;
}
.sd-btn {
  position: relative;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 22px rgba(0,0,0,0.25), 0 2px 6px rgba(0,0,0,0.15);
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  text-decoration: none;
  color: #fff;
}
.sd-btn:hover { transform: scale(1.08) translateY(-2px); color: #fff; }
.sd-btn:active { transform: scale(0.96); }
.sd-btn svg { width: 30px; height: 30px; display: block; }
.sd-btn .sd-tooltip {
  position: absolute;
  right: calc(100% + 14px);
  top: 50%;
  transform: translateY(-50%) translateX(8px);
  background: #2C1810;
  color: #fff;
  padding: 0.55em 0.95em;
  border-radius: 4px;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-family: var(--heading-font);
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: 0.25s ease;
}
.sd-btn .sd-tooltip::after {
  content: "";
  position: absolute;
  top: 50%; left: 100%;
  transform: translateY(-50%);
  border: 6px solid transparent;
  border-left-color: #2C1810;
}
.sd-btn:hover .sd-tooltip {
  opacity: 1;
  transform: translateY(-50%) translateX(0);
}
.sd-fb { background: linear-gradient(135deg, #00B2FF 0%, #006AFF 100%); }
.sd-wa { background: linear-gradient(135deg, #25D366 0%, #128C7E 100%); }
.sd-vb { background: #7360F2; overflow: hidden; padding: 0; }
.sd-vb .sd-icon-img {
  width: 100%; height: 100%;
  object-fit: cover;
  border-radius: 50%;
  display: block;
}
.sd-vb .sd-icon-fallback { width: 30px; height: 30px; }
.sd-call { background: linear-gradient(135deg, #C9A96E 0%, #8B4513 100%); }

/* Toggle FAB — only used on mobile */
.sd-toggle {
  display: none;
  border: none;
  padding: 0;
  background: linear-gradient(135deg, #2C1810 0%, #5C2C0E 100%);
}
.sd-toggle svg { transition: transform 0.3s ease; }
.speed-dial.open .sd-toggle svg { transform: rotate(45deg); }

.sd-fb::before {
  content: "";
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  background: rgba(0, 106, 255, 0.35);
  z-index: -1;
  animation: sdPulse 2.2s ease-out infinite;
}
@keyframes sdPulse {
  0%   { transform: scale(0.85); opacity: 0.7; }
  70%  { transform: scale(1.35); opacity: 0; }
  100% { transform: scale(1.35); opacity: 0; }
}

/* MOBILE: collapsible — only the toggle shows; tap to fan out */
@media (max-width: 768px) {
  .speed-dial { right: 16px; bottom: 16px; gap: 10px; }
  .sd-btn { width: 50px; height: 50px; }
  .sd-btn svg { width: 26px; height: 26px; }
  .sd-btn .sd-tooltip { display: none; }
  .sd-toggle { display: flex; }
  .speed-dial .sd-btn:not(.sd-toggle) {
    opacity: 0;
    transform: translateY(20px) scale(0.6);
    pointer-events: none;
    transition: opacity 0.25s ease, transform 0.25s ease;
  }
  .speed-dial.open .sd-btn:not(.sd-toggle) {
    opacity: 1;
    transform: none;
    pointer-events: auto;
  }
  .speed-dial.open .sd-fb   { transition-delay: 0.05s; }
  .speed-dial.open .sd-vb   { transition-delay: 0.10s; }
  .speed-dial.open .sd-wa   { transition-delay: 0.15s; }
  .speed-dial.open .sd-call { transition-delay: 0.20s; }
}

/* ============================================================
   LIGHTBOX MAGNIFIER ZOOM
   ============================================================ */
.zoom-frame {
  position: relative;
  display: inline-block;
  line-height: 0;
  max-width: 100%;
  max-height: 100%;
  cursor: zoom-in;
}
.zoom-frame img {
  display: block;
  max-width: 100%;
  width: auto;
  height: auto;
  max-height: 88vh;
  border-radius: 8px;
  object-fit: contain;
  transition: opacity 0.3s ease;
}
.lightbox-left .zoom-frame img { max-height: 84vh; }
@media (max-width: 900px) {
  .lightbox-left .zoom-frame img { max-height: 55vh; }
}
.zoom-lens {
  position: absolute;
  display: none;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.85);
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.4),
    0 6px 18px rgba(0, 0, 0, 0.55);
  background-repeat: no-repeat;
  background-color: #111;
  pointer-events: none;
  z-index: 5;
}
@media (hover: none) {
  .zoom-lens { display: none !important; }
  .lightbox-highlight { cursor: default; }
}

/* ============================================================
   CATALOGUES PAGE
   ============================================================ */
.page-hero {
  padding: 9em 0 4em;
  background-color: #2C1810;
  background-image:
    linear-gradient(135deg, rgba(44,24,16,0.78) 0%, rgba(139,69,19,0.55) 100%),
    url('../textile/EUROPEAN/Maroon.png');
  background-size: cover, cover;
  background-position: center, center;
  background-repeat: no-repeat, no-repeat;
  text-align: center;
  color: #fff;
}
.page-hero .eyebrow {
  display: inline-block;
  font-size: 0.75rem;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: #C9A96E;
  margin-bottom: 1rem;
}
.page-hero h1 {
  font-family: var(--heading-font);
  font-weight: 300;
  font-size: clamp(2rem, 5vw, 3.4rem);
  letter-spacing: 0.06em;
  margin: 0 0 0.5em;
  text-shadow: 0 2px 14px rgba(0,0,0,0.35);
}
.page-hero p {
  color: #e6d8be;
  max-width: 640px;
  margin: 0 auto;
  font-size: 1rem;
}

#catalogues { padding: 4em 0; }

.catalogue-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 2.5rem;
}
.catalogue-toolbar .count {
  font-family: var(--heading-font);
  font-size: 0.8rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: #8B6F4E;
}
.catalogue-toolbar .count strong { color: #2C1810; font-weight: 500; }

.catalogue-controls {
  display: flex;
  gap: 10px;
  align-items: stretch;
  flex-wrap: wrap;
}
#catalogueSearch,
#catalogueFilter {
  border: 1px solid rgba(44,24,16,0.18);
  border-radius: 0;
  padding: 0.65em 1em;
  background: #fff;
  min-width: 220px;
  font-size: 0.9rem;
  color: #2C1810;
  font-family: inherit;
  transition: border-color 0.2s, box-shadow 0.2s;
}
#catalogueSearch:focus,
#catalogueFilter:focus {
  outline: none;
  border-color: #C9A96E;
  box-shadow: 0 0 0 3px rgba(201,169,110,0.18);
}
#catalogueFilter {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  padding-right: 2.4em;
  cursor: pointer;
  font-family: var(--heading-font);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: 0.78rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8' fill='%232C1810'%3E%3Cpath d='M6 8 0 0h12z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.95em center;
  background-size: 10px;
}
#catalogueFilter::-ms-expand { display: none; }
#catalogueFilter option {
  font-family: var(--body-font);
  letter-spacing: 0;
  text-transform: none;
  font-size: 0.95rem;
}

/* Folder-segregated browse */
.collection-block { margin-bottom: 4rem; }
.collection-block:last-child { margin-bottom: 0; }
.collection-block .collection-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  border-bottom: 1px solid rgba(201,169,110,0.4);
  padding-bottom: 0.9rem;
  margin-bottom: 1.4rem;
  flex-wrap: wrap;
}
.collection-block .collection-header h2 {
  font-family: var(--heading-font);
  font-weight: 400;
  font-size: clamp(1.2rem, 2vw, 1.5rem);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #2C1810;
  margin: 0;
}
.collection-block .collection-count {
  font-size: 0.72rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: #8B6F4E;
  font-family: var(--heading-font);
}
.collection-swatches {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 12px;
}
.swatch {
  display: block;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: #F5EFE6;
  cursor: pointer;
  position: relative;
  border: 1px solid rgba(44,24,16,0.06);
  transition: border-color 0.25s ease, transform 0.25s ease;
}
.swatch:hover {
  border-color: #C9A96E;
  transform: translateY(-2px);
}
.swatch img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
  display: block;
}
.swatch:hover img { transform: scale(1.06); }
.swatch::after {
  content: attr(data-label);
  position: absolute;
  bottom: 0; left: 0; right: 0;
  background: linear-gradient(0deg, rgba(0,0,0,0.78), rgba(0,0,0,0));
  color: #C9A96E;
  padding: 1.6em 0.7em 0.55em;
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  opacity: 0;
  transition: opacity 0.3s;
  font-family: var(--heading-font);
}
.swatch:hover::after { opacity: 1; }
@media (max-width: 540px) {
  .collection-swatches { grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 8px; }
}

.catalogue-toolbar .count {
  font-family: var(--heading-font);
  font-size: 0.78rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: #8B6F4E;
}
.catalogue-toolbar .count strong { color: #2C1810; font-weight: 500; }
.catalogue-empty {
  text-align: center;
  padding: 4em 1em;
  color: #8B6F4E;
  font-family: var(--heading-font);
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

/* ============================================================
   MINIMAL MOBILE NAV / BURGER
   ============================================================ */
@media (max-width: 991.98px) {
  /* Push everything below the fixed nav so the hero doesn't sit under it */
  body { padding-top: 48px; }

  /* Slim top nav bar on mobile */
  #header-nav {
    padding: 0.2rem 0.6rem !important;
    margin-bottom: 0 !important;
  }
  #header-nav .container-fluid { padding: 0 !important; min-height: 0 !important; }
  #header-nav .navbar-brand { padding: 0 !important; margin: 0 !important; }
  #header-nav .logo { height: 26px; }

  .navbar-toggler {
    border: none !important;
    padding: 0.25rem 0.4rem !important;
    background: transparent !important;
    line-height: 1 !important;
  }
  .navbar-toggler:focus { box-shadow: none !important; outline: none !important; }
  .navbar-toggler .navbar-icon {
    width: 22px; height: 22px;
    fill: #fff;
    filter: drop-shadow(0 1px 2px rgba(0,0,0,0.45));
  }
  #header-nav.scrolled .navbar-toggler .navbar-icon { fill: #2C1810; filter: none; }
  body.inner-page .navbar-toggler .navbar-icon { fill: #2C1810; filter: none; }

  /* Offcanvas — full-height, narrow panel from the right */
  .offcanvas.offcanvas-end {
    position: fixed !important;
    top: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    height: 100vh !important;
    width: 220px !important;
    max-width: 75vw !important;
    z-index: 1045 !important;
    display: flex !important;
    flex-direction: column !important;
    background: #2C1810 !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    border-left: 1px solid rgba(201,169,110,0.18) !important;
  }
  .offcanvas .offcanvas-header {
    flex: 0 0 auto !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    padding: 1.2rem 1.4rem !important;
    border-bottom: 1px solid rgba(201,169,110,0.18) !important;
  }
  .offcanvas .offcanvas-brand {
    color: #C9A96E !important;
    font-family: var(--heading-font);
    letter-spacing: 0.28em;
    text-transform: uppercase;
    font-size: 1rem;
    font-weight: 400;
    text-decoration: none;
  }
  .offcanvas .btn-close {
    background: none !important;
    color: #C9A96E !important;
    opacity: 1 !important;
    width: 32px !important;
    height: 32px !important;
    padding: 0 !important;
    margin: 0 !important;
    line-height: 1 !important;
    border: none !important;
    cursor: pointer;
    display: flex !important;
    align-items: center;
    justify-content: center;
  }
  .offcanvas .btn-close::before {
    content: "×";
    color: #C9A96E;
    font-family: var(--heading-font);
    font-weight: 300;
    font-size: 2rem;
    line-height: 1;
  }
  .offcanvas .offcanvas-body {
    flex: 1 1 auto !important;
    display: block !important;
    padding: 0 !important;
    overflow-y: auto !important;
  }
  .offcanvas #navbar,
  .offcanvas .navbar-nav {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    padding: 0 !important;
    margin: 0 !important;
    width: 100% !important;
    list-style: none;
  }
  .offcanvas #navbar .nav-item {
    display: block !important;
    width: 100% !important;
    border-bottom: 1px solid rgba(201,169,110,0.1);
  }
  .offcanvas #navbar .nav-link {
    display: block !important;
    color: #fff !important;
    text-shadow: none !important;
    padding: 0.9rem 1.1rem !important;
    margin: 0 !important;
    font-size: 0.8rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    font-family: var(--heading-font);
    font-weight: 400;
    text-decoration: none;
    transition: background 0.2s ease, color 0.2s ease, padding-left 0.2s ease;
  }
  .offcanvas #navbar .nav-link:hover,
  .offcanvas #navbar .nav-link.active {
    background: rgba(201,169,110,0.08);
    color: #C9A96E !important;
    padding-left: 1.4rem !important;
  }
  .offcanvas .offcanvas-header { padding: 1rem 1.1rem !important; }
  .offcanvas .offcanvas-brand { font-size: 0.9rem; letter-spacing: 0.22em; }
}

/* ============================================================
   MOBILE TUNING — general
   ============================================================ */
@media (max-width: 768px) {
  .padding-large  { padding-top: 3em;  padding-bottom: 3em; }
  .padding-xlarge { padding-top: 4em;  padding-bottom: 4em; }
  .padding-medium { padding-top: 2em;  padding-bottom: 2em; }

  .section-heading { margin-bottom: 1.8rem; }
  .section-heading .eyebrow { letter-spacing: 0.25em; font-size: 0.7rem; }

  /* HERO on mobile = static LOGO-1 image, taller container with center-zoom crop */
  #billboard {
    display: block !important;
    width: 100% !important;
    max-width: 100vw !important;
    height: 65vh !important;
    min-height: 500px !important;
    overflow: hidden;
    background: #F5EFE6;
    position: relative;
  }
  #billboard .main-swiper { display: none !important; }
  .hero-static-mobile {
    display: block;
    width: 100%;
    height: 100%;
    max-width: none;
    object-fit: cover;
    object-position: center center;
    transform: scale(1.25);
    transform-origin: center center;
  }

  /* Page hero (catalogues etc.) */
  .page-hero { padding: 6em 0 2em; }
  .page-hero h1 { font-size: 1.7rem; }
  .page-hero p { font-size: 0.9rem; }

  /* Wholesale collage section */
  #yearly-sale .text-content { padding: 1.5em 0 !important; }
  #yearly-sale .text-content h3 { font-size: 0.72rem !important; letter-spacing: 0.25em; }
  #yearly-sale .text-content h2 { font-size: 1.7rem !important; line-height: 1.2; }
  #yearly-sale .text-content p  { font-size: 0.95rem; }

  /* Find Us map */
  #find-us .map-embed { height: 280px; }
  #find-us .map-info {
    flex-direction: column;
    align-items: stretch;
    text-align: center;
    gap: 1rem;
  }
  #find-us .directions-btn { width: 100%; justify-content: center; }

  /* Catalogue toolbar stacks */
  .catalogue-toolbar {
    flex-direction: column;
    align-items: stretch;
    gap: 0.8rem;
  }
  #catalogueSearch { min-width: 0; width: 100%; }

  /* Tighter swatch grid on phones */
  .collection-swatches {
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
    gap: 8px;
  }
  .collection-block { margin-bottom: 2.5rem; }
  .collection-block .collection-header h2 { font-size: 1.1rem; letter-spacing: 0.18em; }
  .collection-block .collection-count { font-size: 0.66rem; letter-spacing: 0.22em; }

  /* Featured collections — already 2 cols */

  /* Contact form spacing */
  #contact .contact-content { padding: 2em 1.2em; }

  /* Footer */
  #footer { padding-top: 3em; }
  #footer .contact-list li { font-size: 0.85rem; }
  #footer-bottom .copyright,
  #footer-bottom { text-align: center; }
}

@media (max-width: 540px) {
  .padding-large  { padding-top: 2.5em; padding-bottom: 2.5em; }
  .padding-xlarge { padding-top: 3em;   padding-bottom: 3em; }

  /* Slightly shorter hero on small phones */
  #billboard,
  #billboard .main-swiper,
  #billboard .main-swiper .swiper-wrapper,
  #billboard .main-swiper .swiper-slide,
  #billboard .main-swiper .image-holder {
    height: 360px !important;
    min-height: 360px !important;
  }

  /* Wholesale even tighter */
  #yearly-sale .text-content h2 { font-size: 1.45rem !important; }
}

/* ============================================================
   MOBILE GALLERIES → swipe carousels (CSS scroll-snap)
   ============================================================ */
@media (max-width: 768px) {
  /* Featured Collections */
  .collection-grid {
    display: flex !important;
    grid-template-columns: none !important;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    gap: 12px;
    padding: 0 1rem 0.5rem;
    margin: 0 -1rem;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .collection-grid::-webkit-scrollbar { display: none; }
  .collection-grid > .collection-card {
    flex: 0 0 78%;
    scroll-snap-align: center;
    aspect-ratio: 4 / 5;
  }

  /* From The Bolt mosaic */
  .fabric-mosaic {
    column-count: initial !important;
    column-gap: 0 !important;
    display: flex !important;
    flex-wrap: nowrap;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    gap: 8px;
    padding: 0 1rem 0.5rem;
    margin: 0 -1rem;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .fabric-mosaic::-webkit-scrollbar { display: none; }
  .fabric-mosaic .tile {
    flex: 0 0 60%;
    scroll-snap-align: center;
    aspect-ratio: 1 / 1;
    margin: 0 !important;
    height: auto !important;
  }
  .fabric-mosaic .tile img {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  /* Catalogues page swatches per folder — horizontal swipe */
  .collection-swatches {
    display: flex !important;
    grid-template-columns: none !important;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    gap: 10px;
    padding: 0 1rem 0.5rem;
    margin: 0 -1rem;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .collection-swatches::-webkit-scrollbar { display: none; }
  .collection-swatches > .swatch {
    flex: 0 0 42%;
    scroll-snap-align: start;
    aspect-ratio: 1 / 1;
  }

  /* Affordance: show a subtle hint that content scrolls */
  .collection-grid,
  .fabric-mosaic,
  .collection-swatches {
    scroll-padding-left: 1rem;
  }
}

/* ============================================================
   LIGHTBOX — mobile redesign (full-bleed + horizontal thumb strip)
   ============================================================ */
@media (max-width: 768px) {
  .lightbox-overlay { padding: 0; }
  .lightbox-content {
    width: 100%;
    height: 100%;
    max-width: 100%;
    max-height: 100%;
    border-radius: 0;
  }
  .lightbox-body {
    flex-direction: column;
    height: 100%;
  }
  .lightbox-left {
    flex: 1 1 auto;
    max-width: 100%;
    min-height: 0;
    padding: 6px;
  }
  .lightbox-left .zoom-frame {
    display: flex;
    width: 100%;
    height: 100%;
    align-items: center;
    justify-content: center;
  }
  .lightbox-left .zoom-frame img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    border-radius: 4px;
  }
  .lightbox-label {
    font-size: 12px;
    margin: 6px 0 0;
    padding: 0 8px;
  }
  /* Picker becomes a horizontal scrollable strip at the bottom */
  .lightbox-right {
    flex: 0 0 auto;
    max-width: 100%;
    max-height: none;
    border-left: none;
    border-top: 1px solid rgba(201,169,110,0.18);
    padding: 10px 8px 12px;
  }
  .lightbox-right-header {
    padding-bottom: 0.5rem;
    margin-bottom: 0.6rem;
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.8rem;
  }
  .lightbox-right-header .lr-eyebrow { display: none; }
  .lightbox-right-header .lr-title { font-size: 0.95rem; margin: 0; }
  .lightbox-right-header .lr-count { font-size: 0.7rem; }

  /* Horizontal thumbnail strip */
  .lightbox-right .lightbox-images {
    column-count: initial !important;
    column-gap: 0;
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    overflow-y: hidden;
    gap: 6px;
    padding: 2px 0 6px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
  }
  .lightbox-right .lightbox-images img {
    flex: 0 0 64px;
    width: 64px !important;
    height: 64px !important;
    margin: 0 !important;
    object-fit: cover;
    aspect-ratio: 1 / 1;
  }

  /* Bigger close + simpler nav arrows for touch */
  .lightbox-close {
    width: 44px; height: 44px;
    font-size: 30px;
    top: 8px; right: 10px;
  }
  .nav-arrow {
    font-size: 22px;
    padding: 6px 10px;
  }
  .zoom-frame { cursor: default; }
}
