/* =========================================================
   XBYTE — Home page (clean, isolated build from mockup)
   All classes are prefixed .xb-home / .xb-* and scoped so they
   never collide with the legacy stylesheet.css rules.
   ========================================================= */

.xb-home {
  --xb-gold: #c8952f;
  --xb-gold-dark: #a97c24;
  --xb-gold-tint: #faf3e2;
  --xb-ink: #1a1a1a;
  --xb-muted: #6b6f76;
  --xb-line: #e7e7e4;
  --xb-surface: #ffffff;
  --xb-surface-alt: #f6f6f4;
  --xb-radius: 10px;
  color: var(--xb-ink);
}

.xb-home__section { padding: 2.75rem 0; }
.xb-home__section--alt { background: var(--xb-surface-alt); }

/* ---- Section heading ---- */
.xb-section-head {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.75rem;
}
.xb-section-head__title {
  margin: 0;
  font-family: "Montserrat", "Open Sans", sans-serif;
  font-weight: 800;
  font-size: clamp(1.35rem, 2.2vw, 1.9rem);
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--xb-ink);
  text-align: center;
}
.xb-section-head--center { grid-template-columns: 1fr; }
.xb-section-head__link {
  justify-self: end;
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  font-weight: 700;
  font-size: .9rem;
  color: var(--xb-ink) !important;
  white-space: nowrap;
}
.xb-section-head__link:hover,
.xb-section-head__link:focus { color: var(--xb-gold-dark) !important; }
.xb-section-head__link i { color: var(--xb-gold-dark); font-size: .85rem; }

/* =========================================================
   HERO
   ========================================================= */
.xb-hero {
  background: var(--xb-surface);
  padding: 2rem 0 2.25rem;
  overflow: hidden;
}
.xb-hero__grid {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  align-items: center;
  gap: 2rem;
}
.xb-hero__content { max-width: 500px; }
.xb-hero__title {
  margin: 0 0 0.95rem;
  font-family: "Montserrat", "Open Sans", sans-serif;
  font-weight: 800;
  font-size: clamp(1.7rem, 3.2vw, 2.5rem);
  line-height: 1.08;
  letter-spacing: -0.01em;
  text-transform: uppercase;
  color: var(--xb-ink);
}
.xb-hero__title-accent { color: var(--xb-gold); }
.xb-hero__text {
  margin: 0 0 1.5rem;
  font-size: 0.98rem;
  line-height: 1.6;
  color: var(--xb-muted);
  max-width: 44ch;
}
.xb-hero__cta {
  display: inline-flex;
  align-items: center;
  gap: .55rem;
  padding: .8rem 1.5rem;
  background: var(--xb-gold);
  color: #fff !important;
  font-weight: 800;
  font-size: .85rem;
  letter-spacing: .04em;
  text-transform: uppercase;
  border: 0;
  border-radius: 0;
}
.xb-hero__cta:hover,
.xb-hero__cta:focus { background: var(--xb-gold-dark); color: #fff !important; }
.xb-hero__cta i { font-size: .8rem; }

/* Media: product image over a gold "X" motif. Drop a transparent PNG at
   catalog/view/theme/xbyte/image/hero-products.png and it appears automatically. */
.xb-hero__media {
  position: relative;
  min-height: 280px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.xb-hero__media::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(135deg, transparent 46%, rgba(200, 149, 47, .22) 46%, rgba(200, 149, 47, .22) 54%, transparent 54%),
    linear-gradient(45deg, transparent 46%, rgba(200, 149, 47, .16) 46%, rgba(200, 149, 47, .16) 54%, transparent 54%);
  background-repeat: no-repeat;
  background-position: center;
  background-size: 92% 92%;
  z-index: 0;
}
.xb-hero__img {
  position: relative;
  z-index: 1;
  display: block;
  max-width: 100%;
  height: auto;
  max-height: 420px;
  object-fit: contain;
}

/* =========================================================
   TRUST BAR
   ========================================================= */
/* Full-width black band (shared look for trust + B2B bars) */
.xb-trust,
.xb-b2b {
  padding: 2rem 0;
  background: var(--xb-ink);
}
.xb-trust__grid,
.xb-b2b__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: .75rem;
}
.xb-trust__item,
.xb-b2b__item {
  display: flex;
  align-items: center;
  gap: .95rem;
  padding: .5rem 1rem;
}
.xb-trust__icon,
.xb-b2b__icon {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 0;
  color: var(--xb-gold);
  background: rgba(200, 149, 47, 0.14);
  font-size: 1.5rem;
}
.xb-trust__text,
.xb-b2b__text { min-width: 0; line-height: 1.3; }
.xb-trust__title,
.xb-b2b__title {
  display: block;
  font-weight: 800;
  font-size: .82rem;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: #ffffff;
}
.xb-trust__sub,
.xb-b2b__sub {
  display: block;
  font-size: .82rem;
  color: rgba(255, 255, 255, 0.6);
  margin-top: .2rem;
}

/* =========================================================
   UNSERE KATEGORIEN
   ========================================================= */
.xb-cats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(215px, 1fr));
  gap: 1.25rem;
}
.xb-cat {
  --xb-cat-foot: 3.6rem;
  position: relative;
  display: block;
  padding: 6px 6px var(--xb-cat-foot);
  background: var(--xb-surface-alt);
  border: 0;
  border-radius: 0;
  overflow: hidden;
}
.xb-cat__media {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
}
.xb-cat__media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.xb-cat__icon {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3.5rem;
  color: #c8c8c2;
}

/* Sliding panel: in the resting state only the title shows in the bottom strip.
   On hover the whole panel slides up (the name rises) while a translucent white
   layer fades in, and the child sections are revealed below the name. */
.xb-cat__panel {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  padding: 0 1.35rem;
  background: rgba(255, 255, 255, 0);
  pointer-events: none;
  overflow: hidden;
  transform: translateY(calc(100% - var(--xb-cat-foot)));
  transition: transform .42s cubic-bezier(.22, .61, .36, 1), background-color .32s ease;
}
.xb-cat:hover .xb-cat__panel,
.xb-cat:focus-within .xb-cat__panel {
  transform: translateY(0);
  background: rgba(255, 255, 255, .93);
}
.xb-cat__title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .5rem;
  height: var(--xb-cat-foot);
  flex: 0 0 auto;
  pointer-events: auto;
  text-decoration: none;
}
.xb-cat__name {
  font-weight: 700;
  font-size: .9rem;
  line-height: 1.25;
  text-transform: uppercase;
  letter-spacing: .03em;
  color: var(--xb-ink);
}
.xb-cat__arrow {
  flex: 0 0 auto;
  color: var(--xb-gold-dark);
  font-size: 1rem;
  transition: opacity .25s ease;
}
.xb-cat:hover .xb-cat__arrow,
.xb-cat:focus-within .xb-cat__arrow { opacity: 0; }
.xb-cat__children {
  list-style: none;
  margin: 0;
  padding: 0 0 1rem;
  overflow: auto;
}
.xb-cat__children li {
  opacity: 0;
  transform: translateY(8px);
  transition: opacity .3s ease, transform .3s ease;
}
.xb-cat:hover .xb-cat__children li,
.xb-cat:focus-within .xb-cat__children li {
  opacity: 1;
  transform: translateY(0);
}
.xb-cat:hover .xb-cat__children li:nth-child(1) { transition-delay: .14s; }
.xb-cat:hover .xb-cat__children li:nth-child(2) { transition-delay: .18s; }
.xb-cat:hover .xb-cat__children li:nth-child(3) { transition-delay: .22s; }
.xb-cat:hover .xb-cat__children li:nth-child(4) { transition-delay: .26s; }
.xb-cat:hover .xb-cat__children li:nth-child(5) { transition-delay: .30s; }
.xb-cat:hover .xb-cat__children li:nth-child(6) { transition-delay: .34s; }
.xb-cat:hover .xb-cat__children li:nth-child(7) { transition-delay: .38s; }
.xb-cat:hover .xb-cat__children li:nth-child(8) { transition-delay: .42s; }
.xb-cat__children a {
  display: block;
  padding: .3rem 0;
  font-size: .82rem;
  font-weight: 600;
  color: #5a5a55;
  text-decoration: none;
  border-bottom: 1px solid rgba(0, 0, 0, .07);
  pointer-events: auto;
  transition: color .2s ease;
}
.xb-cat__children a:hover { color: var(--xb-gold-dark); }

/* =========================================================
   B2B FEATURE BAR
   ========================================================= */
/* B2B feature bar shares the full-width black-band styles defined above. */

/* =========================================================
   TOP ANGEBOTE (product cards)
   ========================================================= */
/* Horizontal slider: cards scroll sideways with snap; nav arrows sit on the sides */
.xb-slider {
  position: relative;
}
.xb-products {
  display: flex;
  gap: 1.25rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding: 4px 2px 6px;
  scrollbar-width: none;               /* Firefox */
  -ms-overflow-style: none;            /* IE/Edge */
}
.xb-products::-webkit-scrollbar { display: none; }   /* Chrome/Safari */
.xb-product {
  flex: 0 0 clamp(240px, 22vw, 288px);
  scroll-snap-align: start;
}
/* Arrow navigation */
.xb-slider__nav {
  position: absolute;
  top: 42%;
  transform: translateY(-50%);
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--xb-line);
  border-radius: 50%;
  background: #fff;
  color: var(--xb-ink);
  font-size: 1.15rem;
  cursor: pointer;
  box-shadow: 0 6px 18px rgba(0, 0, 0, .12);
}
.xb-slider__nav:hover {
  background: var(--xb-ink);
  color: #fff;
  border-color: var(--xb-ink);
}
.xb-slider__nav--prev { left: -14px; }
.xb-slider__nav--next { right: -14px; }
.xb-slider__nav[hidden] { display: none; }
/* Flat gray card — same language as the category cards: no border, no radius,
   no shadow, light-gray surface with a small breathing margin around the image. */
.xb-product {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 6px 6px 0;
  background: var(--xb-surface-alt);
  border: 0;
  border-radius: 0;
  overflow: hidden;
}
.xb-product__badge {
  position: absolute;
  top: 6px;
  left: 6px;
  z-index: 2;
  padding: .2rem .45rem;
  background: var(--xb-ink);
  color: #fff;
  font-weight: 700;
  font-size: .7rem;
  line-height: 1;
  border-radius: 0;
}
/* Square, center-cropped image that fills the media box (cover) */
.xb-product__media {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: #fff;
}
.xb-product__media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.xb-product__body {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: .35rem;
  padding: .85rem .8rem 1.05rem;
  flex: 1 1 auto;
}
.xb-product__code {
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .05em;
  text-transform: uppercase;
  color: var(--xb-gold-dark);
}
.xb-product__name {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 2.5em;
  font-size: .84rem;
  font-weight: 600;
  line-height: 1.35;
  color: var(--xb-ink) !important;
  text-decoration: none;
}
.xb-product__name:hover { color: var(--xb-gold-dark) !important; }

/* Footer area pinned to the bottom so every card lines up regardless of state */
.xb-product__foot {
  width: 100%;
  margin-top: auto;
  padding-top: .55rem;
}
.xb-product__prices {
  display: flex;
  align-items: baseline;
  justify-content: center;
  flex-wrap: wrap;
  gap: .45rem;
  margin-bottom: .6rem;
}
.xb-product__price {
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--xb-ink);
}
.xb-product__price--special { color: var(--xb-gold-dark); }
.xb-product__price--old {
  font-weight: 600;
  font-size: .82rem;
  color: var(--xb-muted);
  text-decoration: line-through;
}
.xb-product__order {
  width: 100%;
  padding: .6rem .75rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .45rem;
  border: 1px solid var(--xb-ink);
  border-radius: 0;
  background: var(--xb-ink);
  color: #fff;
  font-weight: 700;
  font-size: .8rem;
  cursor: pointer;
}
.xb-product__order:hover { background: var(--xb-gold-dark); border-color: var(--xb-gold-dark); }

/* Guest / locked state — clean, reassuring, no fake prices */
.xb-product__foot--locked {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .4rem;
  padding: .85rem .35rem .3rem;
  border-top: 1px solid var(--xb-line);
}
.xb-product__note {
  margin: 0;
  font-size: .8rem;
  font-weight: 600;
  line-height: 1.45;
  color: var(--xb-muted);
}
.xb-product__note a {
  color: var(--xb-gold-dark) !important;
  font-weight: 700;
  text-decoration: none;
}
.xb-product__note a:hover { text-decoration: underline; }

/* =========================================================
   TOP MARKEN
   ========================================================= */
.xb-brands {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 1.5rem 2.5rem;
}
.xb-brand {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 46px;
  text-decoration: none;
  filter: grayscale(1);
  opacity: .7;
  transition: filter .18s ease, opacity .18s ease;
}
.xb-brand:hover { filter: grayscale(0); opacity: 1; }
.xb-brand img { max-height: 46px; max-width: 130px; object-fit: contain; }
.xb-brand__name {
  font-family: "Montserrat", "Open Sans", sans-serif;
  font-weight: 800;
  font-size: 1.05rem;
  letter-spacing: .02em;
  text-transform: uppercase;
  color: var(--xb-ink);
}

.xb-modules:empty { display: none; }

/* =========================================================
   RESPONSIVE
   ========================================================= */
@media (max-width: 1199.98px) {
  .xb-slider__nav--prev { left: 4px; }
  .xb-slider__nav--next { right: 4px; }
}

@media (max-width: 991.98px) {
  /* Hero: X mark sits behind the text as a subtle watermark */
  .xb-hero { position: relative; padding: 2.25rem 0; }
  .xb-hero__grid { display: block; }
  .xb-hero__content { position: relative; z-index: 1; max-width: none; }
  .xb-hero__text { max-width: none; }
  .xb-hero__media {
    position: absolute;
    inset: 0;
    order: 0;
    z-index: 0;
    min-height: 0;
    opacity: 0.55;
    pointer-events: none;
  }
  .xb-hero__media::before { background-size: 260px 260px; background-position: center; }
  .xb-trust__grid { grid-template-columns: repeat(2, 1fr); row-gap: 1.25rem; }

  .xb-b2b__grid { grid-template-columns: repeat(2, 1fr); row-gap: 1.25rem; }
  .xb-section-head { grid-template-columns: 1fr; text-align: center; }
  .xb-section-head__spacer { display: none; }
  .xb-section-head__link { justify-self: center; }
}

@media (max-width: 767.98px) {
  .xb-cats { grid-template-columns: repeat(2, 1fr); }
  /* Slider: two cards visible + a peek of the next so users know to swipe */
  .xb-products { gap: 0.75rem; padding: 4px 0 6px; }
  .xb-product { flex-basis: clamp(150px, 43vw, 200px); }
  /* Keep the nav arrows on mobile (smaller, sitting on the media row) */
  .xb-slider__nav { width: 38px; height: 38px; font-size: 1rem; top: 34%; }
  .xb-slider__nav--prev { left: 6px; }
  .xb-slider__nav--next { right: 6px; }
}

@media (max-width: 575.98px) {
  /* Hero: phone sizing */
  .xb-hero { padding: 1.4rem 0 1.6rem; }
  .xb-hero__grid { gap: 1rem; }
  .xb-hero__title { font-size: 1.6rem; margin-bottom: 0.7rem; }
  .xb-hero__text { font-size: 0.92rem; margin-bottom: 1.1rem; }
  .xb-hero__cta { padding: 0.72rem 1.25rem; font-size: 0.8rem; }
  .xb-hero__media::before { background-size: 220px 220px; }

  .xb-home__section { padding: 2.25rem 0; }

  /* Trust + B2B bars: two per row on phones (not one) */
  .xb-trust__grid,
  .xb-b2b__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem 0.6rem; }
  .xb-trust__item,
  .xb-b2b__item { padding: 0.35rem 0.35rem; gap: 0.55rem; }
  .xb-trust__icon,
  .xb-b2b__icon { width: 38px; height: 38px; font-size: 1.15rem; border-radius: 0; }
  .xb-trust__title,
  .xb-b2b__title,
  .xb-trust__sub,
  .xb-b2b__sub { font-size: 0.7rem; overflow-wrap: break-word; hyphens: auto; }
  .xb-brands { gap: 1.25rem 1.75rem; }
  .xb-brand { height: 36px; }
  .xb-brand img { max-height: 36px; max-width: 100px; }

  /* Compact product cards on phones */
  .xb-product__body { padding: 0.7rem 0.55rem 0.85rem; gap: 0.25rem; }
  .xb-product__code { font-size: 0.68rem; }
  .xb-product__name { font-size: 0.8rem; min-height: 2.3em; }
  .xb-product__price { font-size: 1rem; }
  .xb-product__note { font-size: 0.75rem; }
  .xb-product__order { padding: 0.55rem; font-size: 0.76rem; }
  .xb-product__foot--locked { padding: 0.7rem 0.3rem 0.25rem; }
}
