/* Final launch fixes shared by the existing homepage and subpages. */
.fe-age-gate { z-index: 2000; }
.fe-age-gate-btn { box-sizing: border-box; text-decoration: none; }

#main .fe-purchase-actions,
#main .fe-wtb-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.75rem;
  margin: 1.75rem 0 2.5rem;
}
#main .fe-purchase-stockists {
  color: var(--ink);
  text-underline-offset: 5px;
  line-height: 1.6;
}
#main .fe-wtb-list a,
#main .fe-wtb-branches a {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  min-height: 2.75rem;
  color: inherit;
  text-decoration: none;
}
#main .fe-wtb-list a:hover,
#main .fe-wtb-branches a:hover {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 4px;
}
#main .fe-wtb-map-mark { flex: none; color: var(--ink-soft); }
#main .fe-wtb-map-hint { color: var(--ink-soft); font-size: 0.875rem; }
#main .fe-wtb-list a:focus-visible,
#main .fe-wtb-branches a:focus-visible,
#main .fe-purchase-stockists:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 4px;
}
#main .fe-contact-invite { display: inline-block; white-space: nowrap; }
#main .fe-contact-v2 .fe-subpage-hero-heading {
  font-size: clamp(2.2rem, 4.4vw, 4.25rem);
  line-height: 1.22;
}

/* Contain the animated artwork without hiding unrelated page overflow. */
@media (max-width: 860px) {
  #main.fe-contact { padding-left: 0; padding-right: 0; }
  #main .fe-wtb-art,
  #main .fe-oem-hero-art { overflow: clip; }
  #main .fe-oem-graffiti {
    left: 4%;
    top: 48%;
    max-width: 90%;
    font-size: clamp(2rem, 7vw, 3.2rem);
  }
  #main .fe-oem-stamp { left: 2%; }
  #main .fe-oem-sky { left: -6%; width: 112%; }
  #main .fe-oem-cloud { right: 0; }
  #main .fe-oem-statue { max-width: 96%; object-fit: contain; }
  #main .fe-wtb-cloud--2 { right: 0; }
}
@media (max-width: 480px) {
  #main .fe-contact-v2-list > div { grid-template-columns: 1fr; gap: 0.25rem; }
  #main .fe-contact-v2-list dd { overflow-wrap: anywhere; }
  #main .fe-purchase-actions { align-items: stretch; flex-direction: column; }
  #main .fe-purchase-actions a { text-align: center; }
  #main .fe-purchase-stockists { padding: 0.65rem 0; }
  #main .fe-contact-v2 .fe-subpage-hero-heading { font-size: 2.2rem; }
}

/* Mobile header and menu refinements. */
@media (max-width: 860px) {
  #main .fe-oem-statue {
    left: 65%;
    transform: translateX(-50%);
    translate: 0 0;
  }
}
@media (max-width: 767px) {
  .fe-navbar { padding-left: 12px; padding-right: 12px; }
  .fe-navbar .fe-container {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    width: 100%;
    max-width: none;
    margin: 0;
    gap: 8px;
  }
  .fe-navbar .fe-nav-button { flex: 0 0 40px; width: 40px; height: 44px; margin: 0; }
  .fe-navbar .fe-nav-brand { flex: none; margin: 0; }
  .fe-navbar .fe-brand-img { width: 96px; height: auto; max-height: 36px; }
  .fe-nav > .fe-container > .fe-lang-switcher {
    display: inline-flex !important;
    flex: none;
    margin: 0 0 0 auto;
    gap: 2px;
    font-size: 0.8125rem;
  }
  .fe-navbar .fe-lang-btn { min-height: 44px; padding: 0 6px; opacity: 1; }
  .fe-mobile-menu { padding: 12px 20px 24px; }
  .fe-mobile-menu-head { flex: none; margin-bottom: 12px; gap: 12px; }
  .fe-mobile-menu-head-actions { display: flex; align-items: center; gap: 12px; margin-left: auto; }
  .fe-mobile-menu-head .fe-mobile-menu-eyebrow { margin: 0; }
  .fe-mobile-menu .fe-lang-switcher { display: inline-flex; margin: 0; gap: 3px; }
  .fe-mobile-menu .fe-lang-btn,
  .fe-mobile-menu .fe-lang-btn:hover,
  .fe-mobile-menu .fe-lang-btn.fe-lang-active,
  .fe-mobile-menu .fe-lang-divider { color: #fff; opacity: 1; }
  .fe-mobile-menu .fe-lang-btn { min-width: 32px; min-height: 44px; padding: 0 4px; }
  .fe-mobile-menu-nav { flex: none; justify-content: flex-start; gap: 8px; }
  .fe-mobile-menu-group { gap: 0; }
  .fe-mobile-menu-link {
    box-sizing: border-box;
    display: flex;
    align-items: center;
    min-height: 44px;
    padding: 6px 8px;
    line-height: 1.35;
    font-size: 1rem;
  }
  .fe-mobile-menu-label { font-size: 1rem; line-height: 1.35; }
  .fe-mobile-menu-num { display: none; }
  .fe-mobile-menu-sub { gap: 0; padding: 0 0 4px 8px; margin-left: 12px; }
  .fe-mobile-menu-sub-link {
    box-sizing: border-box;
    display: flex;
    align-items: center;
    min-height: 42px;
    padding: 6px 8px;
    font-size: 0.9375rem;
    line-height: 1.35;
  }
  .fe-mobile-menu-sub-label { font-size: 0.9375rem; line-height: 1.35; }
}

/* Solid brand ink avoids platform-dependent colour-filter output. */
@supports ((mask-image: url("")) or (-webkit-mask-image: url(""))) {
  .fe-navbar .fe-nav-brand { position: relative; }
  .fe-navbar .fe-brand-img { filter: none; opacity: 0; }
  .fe-navbar .fe-nav-brand::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background-color: var(--ink);
    -webkit-mask: url("../img/logo/logo-hr-498x173-TM.png") center / contain no-repeat;
    mask: url("../img/logo/logo-hr-498x173-TM.png") center / contain no-repeat;
  }
}

/* Keep the browser's root/toolbar surface on the page's paper colour.
   The product colour belongs to an inner paint layer, rather than to
   the sticky surface that WebKit can use for browser chrome tinting. */
html { background-color: var(--paper); color-scheme: light; }
body { background-color: var(--paper); }
.fe-ps-stage {
  isolation: isolate;
  background-color: var(--paper);
  transition: none;
}
.fe-ps-stage::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-color: var(--bg);
  transition: background-color 0.9s cubic-bezier(.4,0,.2,1);
}

/* The catalogue heading contains both names; legacy CSS hid its
   Chinese-named wrapper when English was selected. */
#main .brews-grid .brew-card-zh { display: block; }

/* The RED social link uses its readable name instead of an icon. */
.fe-sitefoot-icon.fe-sitefoot-icon--text {
  width: auto;
  align-items: center;
  font-family: var(--f-mono);
  font-size: 0.8rem;
  font-weight: 700;
  line-height: 22px;
  letter-spacing: 0.02em;
  text-decoration: none;
}

/* Preserve the complete portrait QR in the footer and enlarged view. */
.fe-sitefoot-qr img { height: 132px; object-fit: contain; }
.fe-modal[data-fe-modal-image="true"] .fe-modal-dialog {
  width: min(92vw, 560px);
  max-width: 560px;
  max-height: calc(100dvh - 32px);
  background: #fff;
  border: 0;
  overflow: visible;
}
.fe-modal[data-fe-modal-image="true"] .fe-modal-header { display: none; }
.fe-modal[data-fe-modal-image="true"] .fe-modal-body { padding: 16px; overflow: visible; }
.fe-modal[data-fe-modal-image="true"] .fe-modal-block { display: flex; justify-content: center; }
.fe-modal[data-fe-modal-image="true"] .fe-modal-image {
  display: block;
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: calc(100dvh - 96px);
  object-fit: contain;
}
.fe-modal[data-fe-modal-image="true"] .fe-modal-close {
  top: 8px;
  right: 8px;
  z-index: 2;
  color: #fff;
  background: rgba(0, 0, 0, .65);
}

/* CSS-only QR crop: (35,180)-(599,744) in the unchanged 634x866
   source. Keep four modules of quiet zone; never redraw the code. */
.fe-sitefoot-qr { width: 120px; }
.fe-sitefoot-qr .fe-wechat-preview {
  position: relative;
  display: block;
  width: 120px;
  height: 120px;
  overflow: hidden;
  opacity: 1;
}
.fe-sitefoot-qr .fe-wechat-preview img {
  position: absolute;
  display: block;
  width: 112.41135%;
  max-width: none;
  height: auto;
  left: -6.20568%;
  top: -31.9149%;
  padding: 0;
  outline: 0;
  background: transparent;
  filter: invert(1);
  mix-blend-mode: screen;
}
/* Enlarge as black on white for broad scanner compatibility. */
.fe-modal[data-fe-modal-image="true"] .fe-modal-body:has(.fe-wechat-qr-image) {
  display: flex;
  justify-content: center;
}
.fe-modal[data-fe-modal-image="true"] .fe-modal-block:has(.fe-wechat-qr-image) {
  position: relative;
  display: block;
  width: 100%;
  max-width: calc(100dvh - 96px);
  flex: 0 1 auto;
  aspect-ratio: 1;
  overflow: hidden;
}
.fe-modal[data-fe-modal-image="true"] .fe-modal-body .fe-wechat-qr-image {
  position: absolute;
  width: 112.41135%;
  height: auto;
  max-width: none;
  max-height: none;
  left: -6.20568%;
  top: -31.9149%;
}

/* Keep the founder inset inside the photo, clear of its caption and quote. */
#main .fe-founder-photo-stack {
  position: relative;
}
#main .fe-founder-photo-stack .fe-founder-portrait {
  right: 2%;
  bottom: 4%;
  width: 32% !important;
}

.fe-brand-facts { font-weight: 500; }
#main .fe-brand-aliases, #main .fe-stockist-note {
  max-width: 80rem;
  margin: 0 auto 2rem;
  padding: 0 clamp(1rem, 5vw, 5rem);
  box-sizing: border-box;
  font-size: 0.9rem;
  line-height: 1.8;
  color: var(--ink-soft);
}

html[lang="en"] #main.brew-detail .brew-card-en.is-name { display: none !important; }
html[lang="en"] #main.brew-detail .brew-hero-title { font-family: var(--f-serif); }
