/*
 * Database-to-theme bridge.
 * Lets the existing brand_settings response drive visual content without
 * changing ordering, navigation, authentication, cart, or API behaviour.
 */

:root {
  --color-brand-primary: var(--brand-primary, #9b3527);
  --color-brand-primary-hover: var(--brand-primary-hover, #76251c);
  --si-maroon: var(--brand-primary, #9b3527);
  --si-chilli: var(--brand-primary, #9b3527);
}

/* Use the logo and name supplied by brand_settings. */
header img[alt="Logo"],
footer img[alt="Logo"] {
  width: 2.6rem !important;
  height: 2.6rem !important;
  content: normal !important;
  filter: none !important;
  animation: none !important;
}

header span.font-extrabold.text-2xl.font-display,
footer span.font-extrabold.text-2xl.font-display {
  font-size: 1.45rem !important;
}

header span.font-extrabold.text-2xl.font-display::after,
footer span.font-extrabold.text-2xl.font-display::after {
  content: none !important;
}

footer .grid > div:first-child > p {
  font-size: 0.9rem !important;
}

footer .grid > div:first-child > p::after {
  content: none !important;
}

/* Use the hero image and copy supplied by brand_settings. */
main:has(img[alt="Fried Chicken Background"]) section:first-of-type {
  background-color: #1d120d !important;
  background-image: none !important;
}

main:has(img[alt="Fried Chicken Background"]) section:first-of-type > div.absolute.inset-0.z-0 {
  display: block !important;
}

main:has(img[alt="Fried Chicken Background"]) img[alt="Fried Chicken Background"] {
  opacity: 1 !important;
  object-position: center center !important;
  filter: saturate(1.04) contrast(1.02);
}

main:has(img[alt="Fried Chicken Background"]) section:first-of-type div[class*="uppercase"][class*="tracking-widest"] {
  font-size: 0.7rem !important;
}

main:has(img[alt="Fried Chicken Background"]) section:first-of-type div[class*="uppercase"][class*="tracking-widest"]::after {
  content: none !important;
}

main:has(img[alt="Fried Chicken Background"]) section:first-of-type h1 {
  font-size: clamp(3rem, 6vw, 5.6rem) !important;
}

main:has(img[alt="Fried Chicken Background"]) section:first-of-type h1 span {
  display: inline !important;
}

main:has(img[alt="Fried Chicken Background"]) section:first-of-type h1::after {
  content: none !important;
}

main:has(img[alt="Fried Chicken Background"]) section:first-of-type h1 + p {
  font-size: clamp(1rem, 1.7vw, 1.2rem) !important;
}

main:has(img[alt="Fried Chicken Background"]) section:first-of-type h1 + p::after {
  content: none !important;
}

/* Loyalty content is also managed in brand_settings. */
main:has(img[alt="Fried Chicken Background"]) section:nth-of-type(6) h2 {
  font-size: clamp(2rem, 4vw, 2.7rem) !important;
}

main:has(img[alt="Fried Chicken Background"]) section:nth-of-type(6) h2::after,
main:has(img[alt="Fried Chicken Background"]) section:nth-of-type(6) h2 + p::after {
  content: none !important;
}

main:has(img[alt="Fried Chicken Background"]) section:nth-of-type(6) h2 + p {
  font-size: 1rem !important;
}

/* Display-only loyalty card identity on Home and Account > Rewards. */
main h4[class*="font-display"]:has(+ p[class*="tracking-widest"][class*="uppercase"]) {
  font-size: 0 !important;
  text-transform: none !important;
}

main h4[class*="font-display"]:has(+ p[class*="tracking-widest"][class*="uppercase"])::after {
  content: "Restaurent";
  color: #fff;
  font-size: 0.875rem;
  font-weight: 900;
  letter-spacing: 0.05em;
}

@media (max-width: 767px) {
  main:has(img[alt="Fried Chicken Background"]) section:first-of-type {
    background-image: none !important;
  }

  main:has(img[alt="Fried Chicken Background"]) img[alt="Fried Chicken Background"] {
    object-position: 68% center !important;
  }

  main:has(img[alt="Fried Chicken Background"]) section:first-of-type h1 {
    font-size: clamp(2.6rem, 13vw, 4rem) !important;
  }
}
