:root {
  --zoneyung-logo-background: #14785e;
}

img[src="https://center.zoneyung.net/center-server/static/images/zy-logo.png"] {
  background: var(--zoneyung-logo-background);
  object-position: left center;
}

/* The authentication layout ships with a square, object-cover logo slot. */
a:has(> h1) > div:has(> img[src="https://center.zoneyung.net/center-server/static/images/zy-logo.png"]) {
  width: 148px !important;
  height: 42px !important;
  flex: 0 0 148px;
}

a:has(> h1) > div > img[src="https://center.zoneyung.net/center-server/static/images/zy-logo.png"] {
  width: 148px !important;
  height: 42px !important;
  padding: 6px 10px !important;
  border-radius: 6px !important;
  object-fit: contain !important;
  object-position: center !important;
}

/* Public navigation has enough room for the full company mark. */
header a:has(img[src="https://center.zoneyung.net/center-server/static/images/zy-logo.png"]) > div:has(> img) {
  width: 104px !important;
  height: 32px !important;
}

header img[src="https://center.zoneyung.net/center-server/static/images/zy-logo.png"] {
  width: 104px !important;
  height: 32px !important;
  padding: 5px 8px !important;
  border-radius: 6px !important;
  object-fit: contain !important;
  object-position: center !important;
}

/* Dashboard logo slots remain square and show the identifiable leading mark. */
aside img[src="https://center.zoneyung.net/center-server/static/images/zy-logo.png"] {
  object-fit: cover !important;
  object-position: left center !important;
}

@media (max-width: 480px) {
  header a:has(img[src="https://center.zoneyung.net/center-server/static/images/zy-logo.png"]) > span {
    display: none;
  }
}

@media (max-width: 360px) {
  a:has(> h1) > div:has(> img[src="https://center.zoneyung.net/center-server/static/images/zy-logo.png"]) {
    width: 120px !important;
    height: 36px !important;
    flex-basis: 120px;
  }

  a:has(> h1) > div > img[src="https://center.zoneyung.net/center-server/static/images/zy-logo.png"] {
    width: 120px !important;
    height: 36px !important;
    padding: 5px 8px !important;
  }

  a:has(> h1) > h1 {
    font-size: 18px !important;
  }
}
