
.tk-brand-collection {
  --block-default-padding-block: 0;
  --block-default-padding-inline: 0;
}

.tk-brand-grid {
  display: grid;
  grid-template-columns: repeat(var(--bc-columns, 6), minmax(0, 1fr));
  gap: var(--bc-gap, 20px);
}

.tk-brand-card {
  display: block;
  color: inherit;
  text-decoration: none;
  transition: all var(--tk-dur-base) ease;
}

.tk-brand-card-media {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: var(--bc-logo-bg, color-mix(in srgb, var(--tk-color-primary) 8%, var(--tk-color-muted)));
}

.tk-brand-card-media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--tk-dur-slow) var(--tk-ease-snap);
}

.tk-brand-card:hover .tk-brand-card-media img {
  transform: scale(1.05);
}

/* Contain: the whole logo, centred, with room around it on its background. */
.tk-brand-collection--logo-contain .tk-brand-card-media {
  box-sizing: border-box;
  padding: 14%;
}

.tk-brand-collection--logo-contain .tk-brand-card-media img {
  object-fit: contain;
}

.tk-brand-card-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  color: color-mix(in srgb, var(--tk-color-primary) 70%, #33333a);
  font-family: var(--tk-font-heading);
  font-weight: 800;
  font-size: clamp(18px, 2.5vw, 32px);
  background: var(
    --bc-logo-bg,
    linear-gradient(135deg, rgb(255 255 255 / 0.34), transparent),
    color-mix(in srgb, var(--tk-color-primary) 12%, var(--tk-color-muted))
  );
}

.tk-brand-name {
  display: -webkit-box;
  overflow: hidden;
  margin: 0;
  font-family: var(--bc-name-font, inherit);
  font-weight: var(--bc-name-weight, 700);
  line-height: var(--bc-name-line-height, 1.35);
  letter-spacing: var(--bc-name-letter-spacing, normal);
  text-transform: var(--bc-name-transform, none);
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 1;
}

.tk-brand-count {
  display: block;
  margin: 2px 0 0;
  font-size: 12px;
}

/* ─────────────────────────── Circle ─────────────────────────── */
.tk-brand-collection--circle .tk-brand-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  text-align: center;
}

.tk-brand-collection--circle .tk-brand-card-media {
  width: clamp(72px, 9vw, 128px);
  aspect-ratio: 1 / 1;
  border-radius: 999px;
  border: 2px solid color-mix(in srgb, var(--tk-color-primary) 20%, transparent);
  background: var(--bc-logo-bg, var(--tk-color-surface));
  transition: transform var(--tk-dur-base) var(--tk-ease-spring), box-shadow var(--tk-dur-slow) ease;
}

.tk-brand-collection--circle .tk-brand-card:hover .tk-brand-card-media {
  transform: scale(1.05);
  box-shadow: 0 8px 30px rgb(23 23 28 / 0.12);
}

.tk-brand-collection--circle .tk-brand-card-overlay {
  display: none;
}

.tk-brand-collection--circle .tk-brand-name {
  color: var(--bc-name-color, var(--tk-color-heading));
  font-size: var(--bc-name-size, 14px);
  transition: color var(--tk-dur-fast) ease;
}

.tk-brand-collection--circle .tk-brand-card:hover .tk-brand-name {
  color: var(--bc-name-color, var(--tk-color-primary));
}

.tk-brand-collection--circle .tk-brand-count {
  color: var(--tk-color-muted-foreground);
}

/* ──────────────────────────── Tile ──────────────────────────── */
.tk-brand-collection--tile .tk-brand-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  text-align: center;
}

.tk-brand-collection--tile .tk-brand-card-media {
  width: 100%;
  aspect-ratio: var(--bc-ratio, 1 / 1);
  border: 2px solid transparent;
  box-shadow: 0 1px 2px rgb(23 23 28 / 0.06);
  transition: border-color var(--tk-dur-base) ease;
  border-start-start-radius: var(--bc-card-radius-ts, var(--tk-card-radius, 16px));
  border-start-end-radius: var(--bc-card-radius-te, var(--tk-card-radius, 16px));
  border-end-end-radius: var(--bc-card-radius-be, var(--tk-card-radius, 16px));
  border-end-start-radius: var(--bc-card-radius-bs, var(--tk-card-radius, 16px));
}

.tk-brand-collection--tile .tk-brand-card:hover .tk-brand-card-media {
  border-color: var(--tk-color-primary);
}

.tk-brand-collection--tile .tk-brand-card-overlay {
  display: none;
}

.tk-brand-collection--tile .tk-brand-name {
  color: var(--bc-name-color, var(--tk-color-heading));
  font-size: var(--bc-name-size, 14px);
  transition: color var(--tk-dur-fast) ease;
}

.tk-brand-collection--tile .tk-brand-card:hover .tk-brand-name {
  color: var(--bc-name-color, var(--tk-color-primary));
}

.tk-brand-collection--tile .tk-brand-count {
  color: var(--tk-color-muted-foreground);
}

/* ─────────────────────────── Minimal ─────────────────────────── */
.tk-brand-collection--minimal .tk-brand-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  text-align: center;
  padding: 12px;
  border-radius: var(--bc-card-radius-ts, var(--tk-card-radius, 12px));
}

.tk-brand-collection--minimal .tk-brand-card-media {
  width: 100%;
  max-width: 96px;
  aspect-ratio: 1 / 1;
  background: var(--bc-logo-bg, transparent);
  border-radius: var(--tk-control-radius, 12px);
  transition: transform var(--tk-dur-base) var(--tk-ease-spring);
}

.tk-brand-collection--minimal .tk-brand-card:hover .tk-brand-card-media {
  transform: scale(1.1);
}

.tk-brand-collection--minimal .tk-brand-card-overlay {
  display: none;
}

.tk-brand-collection--minimal .tk-brand-name {
  color: var(--bc-name-color, var(--tk-color-heading));
  font-size: var(--bc-name-size, 13px);
  font-weight: 600;
  transition: color var(--tk-dur-fast) ease;
}

.tk-brand-collection--minimal .tk-brand-card:hover .tk-brand-name {
  color: var(--bc-name-color, var(--tk-color-primary));
}

.tk-brand-collection--minimal .tk-brand-count {
  color: var(--tk-color-muted-foreground);
  font-size: 11px;
}

/* ─────────────────────────── Badge ─────────────────────────── */
.tk-brand-collection--badge .tk-brand-card {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 12px;
  padding: 8px 14px;
  background: var(--tk-color-surface);
  border: 1px solid var(--tk-color-border);
  border-radius: var(--bc-card-radius-ts, var(--tk-card-radius, 999px));
  box-shadow: 0 1px 3px rgb(0 0 0 / 0.04);
}

.tk-brand-collection--badge .tk-brand-card:hover {
  border-color: var(--tk-color-primary);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgb(0 0 0 / 0.08);
}

.tk-brand-collection--badge .tk-brand-card-media {
  width: 42px;
  height: 42px;
  min-width: 42px;
  border-radius: 999px;
  background: var(--bc-logo-bg, color-mix(in srgb, var(--tk-color-primary) 8%, var(--tk-color-muted)));
}

.tk-brand-collection--badge .tk-brand-card-overlay {
  display: none;
}

.tk-brand-collection--badge .tk-brand-card-body {
  display: flex;
  flex-direction: column;
  text-align: start;
  min-width: 0;
}

.tk-brand-collection--badge .tk-brand-name {
  font-size: var(--bc-name-size, 13px);
  color: var(--bc-name-color, var(--tk-color-heading));
}

.tk-brand-collection--badge .tk-brand-count {
  color: var(--tk-color-muted-foreground);
  font-size: 11px;
}

/* ─────────────────────────── Elevated ─────────────────────────── */
.tk-brand-collection--elevated .tk-brand-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  text-align: center;
  padding: 20px 16px;
  background: var(--tk-color-surface);
  border: 1px solid var(--tk-color-border);
  border-start-start-radius: var(--bc-card-radius-ts, var(--tk-card-radius, 18px));
  border-start-end-radius: var(--bc-card-radius-te, var(--tk-card-radius, 18px));
  border-end-end-radius: var(--bc-card-radius-be, var(--tk-card-radius, 18px));
  border-end-start-radius: var(--bc-card-radius-bs, var(--tk-card-radius, 18px));
  box-shadow: 0 10px 25px -5px rgb(0 0 0 / 0.06), 0 8px 10px -6px rgb(0 0 0 / 0.04);
}

.tk-brand-collection--elevated .tk-brand-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 30px -10px color-mix(in srgb, var(--tk-color-primary) 16%, rgb(0 0 0 / 0.08));
  border-color: color-mix(in srgb, var(--tk-color-primary) 40%, transparent);
}

.tk-brand-collection--elevated .tk-brand-card-media {
  width: 72px;
  height: 72px;
  aspect-ratio: 1 / 1;
  border-radius: var(--tk-control-radius, 14px);
  background: var(--bc-logo-bg, color-mix(in srgb, var(--tk-color-primary) 6%, var(--tk-color-muted)));
}

.tk-brand-collection--elevated .tk-brand-card-overlay {
  display: none;
}

.tk-brand-collection--elevated .tk-brand-name {
  font-size: var(--bc-name-size, 15px);
  color: var(--bc-name-color, var(--tk-color-heading));
}

.tk-brand-collection--elevated .tk-brand-count {
  color: var(--tk-color-muted-foreground);
}

/* ─────────────────────────── Overlay ─────────────────────────── */
.tk-brand-collection--overlay .tk-brand-card {
  position: relative;
  overflow: hidden;
  aspect-ratio: var(--bc-ratio, 1 / 1);
  border-start-start-radius: var(--bc-card-radius-ts, var(--tk-card-radius, 14px));
  border-start-end-radius: var(--bc-card-radius-te, var(--tk-card-radius, 14px));
  border-end-end-radius: var(--bc-card-radius-be, var(--tk-card-radius, 14px));
  border-end-start-radius: var(--bc-card-radius-bs, var(--tk-card-radius, 14px));
}

.tk-brand-collection--overlay .tk-brand-card-media {
  position: absolute;
  inset: 0;
}

.tk-brand-collection--overlay .tk-brand-card-overlay {
  position: absolute;
  inset: 0;
  transition: opacity var(--tk-dur-base) ease;
}

.tk-brand-collection--overlay .tk-brand-card-body {
  position: absolute;
  inset-block-end: 0;
  inset-inline-start: 0;
  width: 100%;
  padding: 14px 16px;
  z-index: 1;
}

.tk-brand-collection--overlay .tk-brand-name {
  font-size: var(--bc-name-size, clamp(14px, 1.4vw, 18px));
}

/* Overlay tones */
.tk-brand-collection--tone-dark .tk-brand-card-overlay {
  background: linear-gradient(to top, rgb(0 0 0 / 0.72), rgb(0 0 0 / 0.2) 42%, transparent);
}

.tk-brand-collection--tone-primary .tk-brand-card-overlay {
  background: linear-gradient(
    to top,
    color-mix(in srgb, var(--tk-color-primary) 90%, transparent),
    color-mix(in srgb, var(--tk-color-primary) 40%, transparent) 42%,
    transparent
  );
}

.tk-brand-collection--tone-surface .tk-brand-card-overlay {
  background: linear-gradient(
    to top,
    var(--tk-color-surface),
    color-mix(in srgb, var(--tk-color-surface) 35%, transparent) 45%,
    transparent
  );
}

.tk-brand-collection--tone-dark .tk-brand-name,
.tk-brand-collection--tone-primary .tk-brand-name {
  color: var(--bc-name-color, #ffffff);
}

.tk-brand-collection--tone-dark .tk-brand-count,
.tk-brand-collection--tone-primary .tk-brand-count {
  color: rgb(255 255 255 / 0.75);
}

.tk-brand-collection--tone-surface .tk-brand-name {
  color: var(--bc-name-color, var(--tk-color-heading));
}

.tk-brand-collection--tone-surface .tk-brand-count {
  color: var(--tk-color-muted-foreground);
}

.tk-brand-collection-empty {
  margin: 0;
  border: 1px dashed var(--tk-color-border);
  border-radius: var(--tk-control-radius, 8px);
  padding: 28px;
  color: var(--tk-color-muted-foreground);
  text-align: center;
}

@media (max-width: 1023px) {
  .tk-brand-grid {
    grid-template-columns: repeat(var(--bc-columns-tablet, var(--bc-columns, 4)), minmax(0, 1fr));
    gap: var(--bc-gap-tablet, var(--bc-gap, 20px));
  }

  .tk-brand-collection--overlay .tk-brand-name {
    font-size: var(--bc-name-size-tablet, var(--bc-name-size, clamp(14px, 1.4vw, 18px)));
  }

  .tk-brand-collection--tile .tk-brand-name,
  .tk-brand-collection--circle .tk-brand-name,
  .tk-brand-collection--minimal .tk-brand-name,
  .tk-brand-collection--badge .tk-brand-name,
  .tk-brand-collection--elevated .tk-brand-name {
    font-size: var(--bc-name-size-tablet, var(--bc-name-size, 14px));
  }
}

@media (max-width: 767px) {
  .tk-brand-grid {
    grid-template-columns: repeat(var(--bc-columns-mobile, var(--bc-columns-tablet, var(--bc-columns, 3))), minmax(0, 1fr));
    gap: var(--bc-gap-mobile, var(--bc-gap-tablet, var(--bc-gap, 20px)));
  }

  .tk-brand-collection--overlay .tk-brand-name {
    font-size: var(--bc-name-size-mobile, var(--bc-name-size-tablet, var(--bc-name-size, clamp(14px, 1.4vw, 18px))));
  }

  .tk-brand-collection--tile .tk-brand-name,
  .tk-brand-collection--circle .tk-brand-name,
  .tk-brand-collection--minimal .tk-brand-name,
  .tk-brand-collection--badge .tk-brand-name,
  .tk-brand-collection--elevated .tk-brand-name {
    font-size: var(--bc-name-size-mobile, var(--bc-name-size-tablet, var(--bc-name-size, 14px)));
  }
}


.tk-heading {
  color: var(--hd-color, var(--tk-color-heading));
  font-family: var(--hd-font, var(--tk-font-heading));
  font-weight: var(--hd-weight, 700);
  font-style: var(--hd-style, normal);
  line-height: var(--hd-line-height, 1.25);
  letter-spacing: var(--hd-letter-spacing, normal);
  text-transform: var(--hd-transform, none);
  text-wrap: balance;
  max-width: var(--hd-max-width, none);
}

/* Narrowed by its max width, the column sits on the side its text is aligned
   to (centred only when the text is centred). */

.tk-heading--constrained {
  margin-inline-start: var(--hd-ms, 0);
  margin-inline-end: var(--hd-me, auto);
}

@media (max-width: 1023px) {
  .tk-heading--constrained {
    margin-inline-start: var(--hd-ms-tablet, var(--hd-ms, 0));
    margin-inline-end: var(--hd-me-tablet, var(--hd-me, auto));
  }
}

@media (max-width: 767px) {
  .tk-heading--constrained {
    margin-inline-start: var(--hd-ms-mobile, var(--hd-ms-tablet, var(--hd-ms, 0)));
    margin-inline-end: var(--hd-me-mobile, var(--hd-me-tablet, var(--hd-me, auto)));
  }
}

/* The text is painted by a gradient from the heading colour to the second one,
   across the words only (each line on its own) and from where they start. */
.tk-heading--gradient .tk-heading__text {
  background-image: linear-gradient(
    to right,
    var(--hd-color, var(--tk-color-heading)),
    var(--hd-gradient-to)
  );
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
[dir="rtl"] .tk-heading--gradient .tk-heading__text {
  background-image: linear-gradient(
    to left,
    var(--hd-color, var(--tk-color-heading)),
    var(--hd-gradient-to)
  );
}
/* The backdrop word sits behind the heading, centred on it and aligned as its
   text is, never widening the page (overflow-x: clip) nor moving the layout. */
.tk-heading--backdrop {
  isolation: isolate;
  overflow-x: clip;
}

.tk-heading > .tk-heading__backdrop {
  position: absolute;
  z-index: -1;
  inset-inline: 0;
  top: 50%;
  font-size: 2.6em;
  line-height: 1;
  pointer-events: none;
  transform: translateY(-50%);
  white-space: nowrap;
  user-select: none;
}

.tk-heading--backdrop-outline > .tk-heading__backdrop {
  color: transparent;
  -webkit-text-stroke: 1.5px
    color-mix(in srgb, var(--hd-color, var(--tk-color-heading)) 22%, transparent);
}

.tk-heading--backdrop-faint > .tk-heading__backdrop {
  color: color-mix(in srgb, var(--hd-color, var(--tk-color-heading)) 8%, transparent);
}


.tk-heading {
  font-size: var(--hd-size, var(--hd-size-default, inherit));
  text-align: var(--hd-align, start);
}

@media (max-width: 1023px) {
  .tk-heading {
    font-size: var(--hd-size-tablet, var(--hd-size, var(--hd-size-default, inherit)));
    text-align: var(--hd-align-tablet, var(--hd-align, start));
  }
}

@media (max-width: 767px) {
  .tk-heading {
    font-size: var(--hd-size-mobile, var(--hd-size-tablet, var(--hd-size, var(--hd-size-default, inherit))));
    text-align: var(--hd-align-mobile, var(--hd-align-tablet, var(--hd-align, start)));
  }
}


.tk-section {
  display: flex;
  flex-direction: column;
  justify-content: var(--sc-justify, center);
  --block-default-padding-block: var(--tk-section-padding-y);
}

/* The content sits in the container (shared styles). A Section is as tall as
   its content: the editor sizes an empty Section's drop zone itself. */

/*
 * Auto-collapse: hide the section when its inner slot produces no visible block.
 * :empty matches a .tk-section-inner with no child nodes at all (storefront SSR case).
 * :has(> :empty:only-child) catches the Puck render where one empty wrapper div is injected.
 */
.tk-section:has(> .tk-section-inner:empty),
.tk-section:has(> .tk-section-inner > :empty:only-child) {
  display: none;
}


.tk-section {
  min-height: var(--sc-min-height, auto);
}

@media (max-width: 1023px) {
  .tk-section {
    min-height: var(--sc-min-height-tablet, var(--sc-min-height, auto));
  }
}

@media (max-width: 767px) {
  .tk-section {
    min-height: var(--sc-min-height-mobile, var(--sc-min-height-tablet, var(--sc-min-height, auto)));
  }
}


/* Edges reach past the band into its neighbour, so the band is lifted above
   the Sections beside it. Each edge is painted with the band's own background
   (or its own colour, below)
   and cut to its shape by a mask. */
.tk-section--edged {
  z-index: 1;
}

.tk-section > .tk-section-edge {
  position: absolute;
  inset-inline: 0;
  background-color: var(--block-container-background, transparent);
  background-image: var(--block-container-background-image, none);
  background-size: cover;
  pointer-events: none;
  -webkit-mask: var(--sc-edge-mask) no-repeat 0 0 / 100% 100%;
  mask: var(--sc-edge-mask) no-repeat 0 0 / 100% 100%;
}

.tk-section > .tk-section-edge--top {
  inset-block-end: 100%;
}

.tk-section > .tk-section-edge--bottom {
  inset-block-start: 100%;
  transform: scaleY(-1);
}

/* An edge in a colour of its own, for a band coloured by a block inside it. */
.tk-section--edge-colored > .tk-section-edge {
  background: var(--sc-edge-color);
}

/* Arches repeat along the edge, each twice as wide as the edge is tall. */
.tk-section > .tk-section-edge--arches {
  -webkit-mask-repeat: repeat-x;
  mask-repeat: repeat-x;
  -webkit-mask-size: calc(var(--sc-edge-block-size) * 2) 100%;
  mask-size: calc(var(--sc-edge-block-size) * 2) 100%;
}


.tk-section > .tk-section-edge {
  block-size: var(--sc-edge-height, 48px);
  --sc-edge-block-size: var(--sc-edge-height, 48px);
}

@media (max-width: 1023px) {
  .tk-section > .tk-section-edge {
    block-size: var(--sc-edge-height-tablet, var(--sc-edge-height, 48px));
    --sc-edge-block-size: var(--sc-edge-height-tablet, var(--sc-edge-height, 48px));
  }
}

@media (max-width: 767px) {
  .tk-section > .tk-section-edge {
    block-size: var(--sc-edge-height-mobile, var(--sc-edge-height-tablet, var(--sc-edge-height, 48px)));
    --sc-edge-block-size: var(--sc-edge-height-mobile, var(--sc-edge-height-tablet, var(--sc-edge-height, 48px)));
  }
}

/* Parallax: the band stops painting its background image, and a layer behind
   its content paints it instead - taller than the band, so it has room to
   move. The layer clips itself, so the band's edges still reach outside it.
   --sc-parallax runs from -1 (the band coming in at the bottom of the screen)
   to 1 (leaving at the top), written by the layer itself; it slides
   the image from 15% of the band's height up to 15% down, so the image moves
   slower than the page. Unset - no script, reduced motion - it sits centred. */
.tk-block.tk-section--parallax {
  isolation: isolate;
  background-image: none;
}

.tk-section > .tk-section-parallax {
  position: absolute;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  border-radius: inherit;
  pointer-events: none;
}

.tk-section-parallax::before {
  content: "";
  position: absolute;
  inset-block: -15%;
  inset-inline: 0;
  background-image: var(--block-container-background-image, none);
  background-size: var(--block-container-background-fit, cover);
  background-position: var(--block-container-background-position, center);
  background-repeat: no-repeat;
  /* The layer is 130% of the band, so 15% of the band is 15 / 1.3 of it. */
  transform: translate3d(0, calc(var(--sc-parallax, 0) * 15% / 1.3), 0);
  will-change: transform;
}

@media (max-width: 767px) {
  .tk-section-parallax::before {
    background-image: var(--block-container-background-image-mobile, var(--block-container-background-image, none));
  }
}
/* Video: behind the content and its overlay, over the background image,
   which shows until the video plays and then fades under it. */
.tk-section--video {
  isolation: isolate;
}

.tk-section > .tk-section-video {
  position: absolute;
  inset: 0;
  z-index: -1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: inherit;
  pointer-events: none;
  opacity: 0;
  transition: opacity var(--tk-dur-slow) ease;
}

.tk-section > .tk-section-video.is-playing {
  opacity: 1;
}
/* Anchored: a same-page link stops the Section just under the sticky header
   (its bottom edge, published by the header), and the jump scrolls smoothly
   unless the shopper asks for reduced motion. */
.tk-section[id] {
  scroll-margin-top: var(--tk-sticky-top, 0px);
}

@media (prefers-reduced-motion: no-preference) {
  html:has(.tk-section[id]) {
    scroll-behavior: smooth;
  }
}
