/* Canonical web brand lockup — the single header/footer treatment for every
 * ALPYREN-family website and checkout.
 *
 * Source of truth: shared/brand-lockup/manifest.json (wordmark words, byline,
 * colours and the CH+ tile). `brand-lockup.js` renders the markup and sets
 * --brand-lockup-name / --brand-lockup-byline from the manifest colours.
 * Import this stylesheet last so app-specific CSS cannot re-letter the brand.
 */

.brand-lockup {
  display: inline-flex;
  align-items: center;
  gap: 0.9rem;
  min-width: 0;
  color: inherit;
  text-decoration: none;
  line-height: 1;
}

.brand-lockup-tile {
  display: block;
  flex: 0 0 64px;
  width: 64px;
  height: 64px;
  border-radius: 10px;
  object-fit: contain;
}

.brand-lockup-copy,
.brand-lockup-copy-text {
  display: grid;
  gap: 0.18rem;
  min-width: 0;
}

.brand-lockup-copy strong,
.brand-lockup-copy-text strong {
  display: block;
  font-family: 'Caveat', 'Segoe Print', cursive;
  font-style: normal;
  font-weight: 600;
  font-size: 1.75rem;
  line-height: 1;
  letter-spacing: 0;
  text-transform: none;
  color: var(--brand-lockup-name, #253344);
  white-space: nowrap;
}

.brand-lockup-copy small,
.brand-lockup-copy-text small {
  display: block;
  font-family: 'Caveat', 'Segoe Print', cursive;
  font-style: normal;
  font-weight: 500;
  font-size: 0.94rem;
  line-height: 1.15;
  letter-spacing: 0;
  text-transform: none;
  color: var(--brand-lockup-byline, #55595c);
  white-space: nowrap;
}

.brand-lockup--alpyren .brand-lockup-tile,
.brand-lockup--diploma .brand-lockup-tile {
  display: none;
}

.brand-lockup--alpyren .brand-lockup-copy strong,
.brand-lockup--alpyren .brand-lockup-copy-text strong {
  font-size: clamp(1.7rem, 2.4vw, 2.15rem);
}

.brand-lockup--alpyren .brand-lockup-copy small,
.brand-lockup--alpyren .brand-lockup-copy-text small {
  font-size: 1rem;
}

.brand-lockup--diploma .brand-lockup-copy strong,
.brand-lockup--diploma .brand-lockup-copy-text strong {
  font-size: 1.9rem;
}

.brand-lockup--diploma .brand-lockup-copy small,
.brand-lockup--diploma .brand-lockup-copy-text small {
  font-size: 0.95rem;
}

/* Dark backgrounds (web footer / dark top bars): white wordmark, approved tile. */
.brand-lockup--inverse .brand-lockup-copy strong,
.brand-lockup--inverse .brand-lockup-copy-text strong {
  color: #fff;
}

.brand-lockup--inverse .brand-lockup-copy small,
.brand-lockup--inverse .brand-lockup-copy-text small {
  color: #d8dee2;
}

/* Smaller footer/compact presentation keeps the same artwork and proportions. */
.brand-lockup--footer {
  gap: 0.7rem;
}

.brand-lockup--footer .brand-lockup-tile {
  flex-basis: 48px;
  width: 48px;
  height: 48px;
  border-radius: 8px;
}

.brand-lockup--footer .brand-lockup-copy strong,
.brand-lockup--footer .brand-lockup-copy-text strong {
  font-size: 1.55rem;
}

.brand-lockup--footer .brand-lockup-copy small,
.brand-lockup--footer .brand-lockup-copy-text small {
  font-size: 0.9rem;
}

.brand-lockup--compact {
  gap: 0.6rem;
}

.brand-lockup--compact .brand-lockup-tile {
  flex-basis: 44px;
  width: 44px;
  height: 44px;
  border-radius: 8px;
}

.brand-lockup--compact .brand-lockup-copy strong,
.brand-lockup--compact .brand-lockup-copy-text strong {
  font-size: 1.35rem;
}

.brand-lockup--compact .brand-lockup-copy small,
.brand-lockup--compact .brand-lockup-copy-text small {
  font-size: 0.82rem;
}

@media (max-width: 680px) {
  .brand-lockup-tile {
    flex-basis: 54px;
    width: 54px;
    height: 54px;
    border-radius: 9px;
  }

  .brand-lockup-copy strong,
  .brand-lockup-copy-text strong {
    font-size: 1.5rem;
  }

  .brand-lockup-copy small,
  .brand-lockup-copy-text small {
    font-size: 0.84rem;
    white-space: normal;
  }

  .brand-lockup--alpyren .brand-lockup-copy strong,
  .brand-lockup--alpyren .brand-lockup-copy-text strong {
    font-size: 1.6rem;
  }

  .brand-lockup--diploma .brand-lockup-copy strong,
  .brand-lockup--diploma .brand-lockup-copy-text strong {
    font-size: 1.6rem;
  }
}

@media (max-width: 380px) {
  .brand-lockup {
    gap: 0.65rem;
  }

  .brand-lockup-tile {
    flex-basis: 46px;
    width: 46px;
    height: 46px;
  }

  .brand-lockup-copy strong,
  .brand-lockup-copy-text strong {
    font-size: 1.35rem;
  }

  .brand-lockup-copy small,
  .brand-lockup-copy-text small {
    font-size: 0.78rem;
  }
}

/* Mobile header: localized wordmarks must never be clipped. The German,
   Spanish and French names are longer than the English one; the header brand
   may shrink so the language selector and menu always remain visible. */
@media (max-width: 680px) {
  .site-header .brand-lockup {
    flex: 1 1 auto;
    min-width: 0;
    max-width: 100%;
  }
  .site-header .brand-lockup-copy,
  .site-header .brand-lockup-copy-text {
    min-width: 0;
  }
  .site-header .brand-lockup-copy strong,
  .site-header .brand-lockup-copy-text strong {
    font-size: clamp(0.95rem, 3.9vw, 1.35rem);
    line-height: 1.05;
    white-space: nowrap;
  }
  .site-header .brand-lockup-copy small,
  .site-header .brand-lockup-copy-text small {
    font-size: clamp(0.58rem, 2.5vw, 0.78rem);
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
}
@media (max-width: 380px) {
  .site-header .brand-lockup-copy strong,
  .site-header .brand-lockup-copy-text strong {
    font-size: clamp(0.85rem, 4.6vw, 1rem);
  }
}
