/* Mobile logo fix — keep the white badge + image inside the viewport */
header a[href="/"] {
  max-width: min(42vw, 150px) !important;
  flex-shrink: 1 !important;
  overflow: hidden !important;
  box-sizing: border-box !important;
}

header a[href="/"][class*="rounded-b"] {
  padding-left: 0.625rem !important;
  padding-right: 0.625rem !important;
  padding-top: 0.35rem !important;
  padding-bottom: 0.5rem !important;
}

header a[href="/"] img[alt="Everywhere Digest"],
header img[alt="Everywhere Digest"] {
  height: 16px !important;
  width: auto !important;
  max-width: 100% !important;
  max-height: 16px !important;
  object-fit: contain !important;
  display: block !important;
}

@media (min-width: 640px) {
  header a[href="/"] {
    max-width: 180px !important;
  }

  header a[href="/"] img[alt="Everywhere Digest"],
  header img[alt="Everywhere Digest"] {
    height: 20px !important;
    max-height: 20px !important;
  }
}

@media (min-width: 1024px) {
  header a[href="/"] {
    max-width: none !important;
  }

  header a[href="/"] img[alt="Everywhere Digest"],
  header img[alt="Everywhere Digest"] {
    height: 24px !important;
    max-height: 24px !important;
  }
}
