/*
 * Reference-only visual alignment for AVLOG header + homepage cards.
 * Isolated overrides: does not replace templates or touch other page modules.
 */

/* ===== Header: match reference template ===== */
html body.body .header.site-header,
html body.body .site-header {
  background: rgba(8,14,11,.94) !important;
  border-bottom: 1px solid rgba(105,164,125,.18) !important;
  box-shadow: 0 10px 34px rgba(0,0,0,.34) !important;
  backdrop-filter: blur(18px) saturate(135%) !important;
  -webkit-backdrop-filter: blur(18px) saturate(135%) !important;
}
html body.body .site-header:after {
  height: 1px !important;
  opacity: .9 !important;
  background: linear-gradient(90deg,transparent,rgba(57,185,120,.18),rgba(117,214,160,.72),rgba(57,185,120,.18),transparent) !important;
}
html body.body .site-header .site-header-inner {
  display: grid !important;
  grid-template-columns: minmax(145px,220px) minmax(250px,1fr) minmax(220px,330px) !important;
  align-items: center !important;
  gap: clamp(12px,2vw,28px) !important;
  width: min(1360px,calc(100% - 42px)) !important;
  max-width: 1360px !important;
  min-height: 76px !important;
  margin: 0 auto !important;
  padding: 11px 0 !important;
  box-sizing: border-box !important;
}
html body.body .site-header .site-brand { grid-column: 1; grid-row: 1; min-width: 0 !important; margin: 0 !important; }
html body.body .site-header .site-brand a {
  display: inline-flex !important;
  align-items: center !important;
  gap: 11px !important;
  color: #f1f7f2 !important;
  font-size: 20px !important;
  font-weight: 800 !important;
  letter-spacing: .02em !important;
  text-decoration: none !important;
}
html body.body .site-header .site-brand img {
  width: 42px !important;
  height: 42px !important;
  padding: 5px !important;
  object-fit: contain !important;
  border-radius: 13px !important;
  background: linear-gradient(145deg,#1a2a20,#101913) !important;
  border: 1px solid rgba(117,214,160,.22) !important;
  box-shadow: 0 5px 18px rgba(0,0,0,.2) !important;
}
html body.body .site-header .site-brand .name {
  max-width: 190px !important;
  color: #f1f7f2 !important;
  font-size: 20px !important;
  font-weight: 800 !important;
  letter-spacing: .02em !important;
}
html body.body .site-main-nav {
  grid-column: 2 !important;
  grid-row: 1 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 5px !important;
  min-width: 0 !important;
  white-space: nowrap !important;
}
html body.body .site-main-nav .site-nav-link {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 7px !important;
  padding: 11px 15px !important;
  border: 1px solid transparent !important;
  border-radius: 11px !important;
  color: #b2c0b6 !important;
  font-size: 14px !important;
  font-weight: 650 !important;
  text-decoration: none !important;
  transition: background .2s,border-color .2s,color .2s,transform .2s !important;
}
html body.body .site-main-nav .site-nav-link i {
  margin: 0 !important;
  color: #80a38d !important;
  font-size: 17px !important;
}
html body.body .site-main-nav .site-nav-link:first-child {
  color: #dff6e8 !important;
  background: rgba(57,185,120,.12) !important;
  border-color: rgba(57,185,120,.24) !important;
  box-shadow: none !important;
}
html body.body .site-main-nav .site-nav-link:first-child i { color: #75d6a0 !important; }
html body.body .site-main-nav .site-nav-link:hover {
  color: #fff !important;
  background: rgba(57,185,120,.12) !important;
  border-color: rgba(117,214,160,.25) !important;
  transform: translateY(-1px) !important;
}
html body.body .site-search-wrap {
  grid-column: 3 !important;
  grid-row: 1 !important;
  display: block !important;
  width: 100% !important;
  max-width: none !important;
  min-width: 0 !important;
  margin: 0 !important;
}
html body.body .site-header .site-search-form {
  display: flex !important;
  align-items: center !important;
  gap: 11px !important;
  width: 100% !important;
  max-width: none !important;
  min-width: 0 !important;
  height: 46px !important;
  margin: 0 !important;
  padding: 4px 5px 4px 14px !important;
  border: 1px solid #2a3b30 !important;
  border-radius: 12px !important;
  background: #111a15 !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.025) !important;
}
html body.body .site-header .site-search-form:focus-within {
  border-color: rgba(87,198,137,.72) !important;
  background: #142019 !important;
  box-shadow: none !important;
}
html body.body .site-header .site-search-leading {
  flex: 0 0 auto !important;
  color: #75d6a0 !important;
}
html body.body .site-header .site-search-input {
  display: block !important;
  flex: 1 1 0% !important;
  width: 1% !important;
  min-width: 0 !important;
  max-width: 100% !important;
  height: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  outline: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  color: #f5fff7 !important;
  caret-color: #75d6a0 !important;
  font-size: 14px !important;
}
html body.body .site-header .site-search-input::placeholder { color: #84958a !important; opacity: 1 !important; }
html body.body .site-header .site-search-submit {
  display: flex !important;
  flex: 0 0 74px !important;
  align-items: center !important;
  justify-content: center !important;
  width: 74px !important;
  min-width: 74px !important;
  max-width: 74px !important;
  height: 36px !important;
  margin: 0 !important;
  padding: 0 12px !important;
  border: 0 !important;
  border-radius: 9px !important;
  background: linear-gradient(135deg,#4bc486,#279a60) !important;
  color: #06130b !important;
  font-size: 13px !important;
  font-weight: 800 !important;
  box-shadow: 0 4px 12px rgba(38,156,94,.18) !important;
}
html body.body .site-header .site-search-submit:hover { background: linear-gradient(135deg,#75d6a0,#39b978) !important; }
html body.body .site-header .site-search-submit i { display: none !important; }
html body.body .site-hot-search-dropdown {
  background: #111a15 !important;
  border: 1px solid rgba(91,190,132,.30) !important;
  border-radius: 13px !important;
  box-shadow: 0 18px 45px rgba(0,0,0,.42) !important;
  color: #e8eee9 !important;
}
html body.body .site-hot-search-item {
  background: #18231c !important;
  border: 1px solid rgba(160,190,170,.12) !important;
  color: #dbe9df !important;
  border-radius: 8px !important;
}
html body.body .site-hot-search-item:hover {
  background: rgba(57,185,120,.14) !important;
  border-color: rgba(57,185,120,.35) !important;
  color: #fff !important;
}

/* ===== Homepage shortcut cards: reference template treatment ===== */
html body.body .main > .hub-wrap > .hub-shortcuts {
  display: grid !important;
  grid-template-columns: repeat(4,minmax(0,1fr)) !important;
  gap: 14px !important;
  margin: 0 0 30px !important;
}
html body.body .main > .hub-wrap > .hub-shortcuts > .hub-shortcut {
  display: flex !important;
  align-items: center !important;
  gap: 12px !important;
  min-height: 0 !important;
  padding: 18px 16px 18px 13px !important;
  border: 1px solid transparent !important;
  border-left: 4px solid #16a34a !important;
  border-radius: 16px !important;
  background: transparent !important;
  box-shadow: none !important;
  text-decoration: none !important;
  transition: transform .2s ease,border-color .2s ease,box-shadow .2s ease !important;
}
html body.body .main > .hub-wrap > .hub-shortcuts > .hub-shortcut:hover {
  transform: translateY(-3px) !important;
  border: 1px solid rgba(74,222,128,.45) !important;
  border-left: 4px solid #16a34a !important;
  box-shadow: 0 10px 28px rgba(0,0,0,.22) !important;
}
html body.body .main > .hub-wrap > .hub-shortcuts > .hub-shortcut-random { border-left-color: #a855f7 !important; }
html body.body .main > .hub-wrap > .hub-shortcuts > .hub-shortcut-random:hover {
  border: 1px solid rgba(168,85,247,.55) !important;
  border-left: 4px solid #a855f7 !important;
  box-shadow: 0 10px 28px rgba(168,85,247,.12) !important;
}
html body.body .main > .hub-wrap > .hub-shortcuts .hub-icon {
  display: flex !important;
  flex: 0 0 48px !important;
  align-items: center !important;
  justify-content: center !important;
  width: 48px !important;
  height: 48px !important;
  border-radius: 14px !important;
  background: #16a34a !important;
  color: #fff !important;
  font-size: 25px !important;
}
html body.body .main > .hub-wrap > .hub-shortcuts .hub-shortcut-random .hub-icon {
  background: #a855f7 !important;
  color: #fff !important;
  box-shadow: none !important;
}
html body.body .main > .hub-wrap > .hub-shortcuts .hub-shortcut h2 {
  margin: 0 0 5px !important;
  color: #fff !important;
  font-size: 18px !important;
}
html body.body .main > .hub-wrap > .hub-shortcuts .hub-shortcut p {
  margin: 0 !important;
  color: #b9b9c4 !important;
  font-size: 13px !important;
}

/* ===== Homepage latest-video cards: reference template skin ===== */
html body.body #videos .category-con .a-con {
  display: grid !important;
  grid-template-columns: repeat(6,minmax(0,1fr)) !important;
  gap: 16px 12px !important;
  width: 100% !important;
  max-width: none !important;
  margin: 0 !important;
  padding: 0 !important;
  float: none !important;
  box-sizing: border-box !important;
}
html body.body #videos .category-con .a-con-inner {
  display: flex !important;
  flex-direction: column !important;
  min-width: 0 !important;
  width: auto !important;
  max-width: none !important;
  margin: 0 !important;
  padding: 8px !important;
  border: 1px solid rgba(255,255,255,.105) !important;
  border-radius: 12px !important;
  background: rgba(255,255,255,.035) !important;
  box-shadow: none !important;
  overflow: hidden !important;
}
html body.body #videos .category-con .pic {
  position: relative !important;
  display: block !important;
  width: 100% !important;
  aspect-ratio: 3 / 4 !important;
  overflow: hidden !important;
  border: 1px solid rgba(160,190,170,.13) !important;
  border-radius: 9px !important;
  background: rgba(255,255,255,.035) !important;
}
html body.body #videos .category-con .pic > a:first-child {
  display: block !important;
  width: 100% !important;
  height: 100% !important;
}
html body.body #videos .category-con .pic img {
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  border-radius: inherit !important;
  transition: transform .35s ease,filter .35s ease !important;
}
html body.body #videos .category-con .a-con-inner:hover .pic img {
  transform: scale(1.035) !important;
  filter: brightness(.78) !important;
}
html body.body #videos .category-con .pic .bofang {
  background: rgba(7,16,10,.82) !important;
  color: #8ce0ad !important;
  border: 1px solid rgba(117,214,160,.52) !important;
  box-shadow: 0 5px 22px rgba(0,0,0,.35) !important;
  backdrop-filter: blur(8px) !important;
}
html body.body #videos .category-con .a-con-inner .s1 {
  display: -webkit-box !important;
  overflow: hidden !important;
  margin: 8px 0 0 !important;
  -webkit-box-orient: vertical !important;
  -webkit-line-clamp: 1 !important;
  font-size: 13px !important;
  line-height: 1.5 !important;
  font-weight: 600 !important;
}
html body.body #videos .category-con .a-con-inner .s1 a {
  overflow: hidden !important;
  color: #e8eee9 !important;
  text-decoration: none !important;
  text-overflow: ellipsis !important;
}
html body.body #videos .category-con .a-con-inner .s1 a:hover { color: #75d6a0 !important; }
html body.body #videos .category-con .a-con-inner .vod-time {
  display: block !important;
  margin-top: 4px !important;
  color: #94a399 !important;
  font-size: 11px !important;
}
html body.body #videos .category-con .a-con-inner .s2 { margin-top: 5px !important; }
html body.body #videos .category-con .a-con-inner .s2 a {
  display: inline-block !important;
  padding: 2px 7px !important;
  border: 1px solid rgba(91,190,132,.30) !important;
  border-radius: 4px !important;
  background: transparent !important;
  color: #75d6a0 !important;
  font-size: 11px !important;
  text-decoration: none !important;
}
html body.body #videos .category-con .a-con-inner * { min-width: 0; box-sizing: border-box; }

@media (max-width: 1050px) {
  html body.body .site-header .site-header-inner {
    grid-template-columns: minmax(0,1fr) auto !important;
    width: calc(100% - 30px) !important;
    gap: 10px 14px !important;
    padding: 10px 0 !important;
  }
  html body.body .site-header .site-brand { grid-column: 1 !important; grid-row: 1 !important; }
  html body.body .site-main-nav { grid-column: 2 !important; grid-row: 1 !important; justify-content: flex-end !important; }
  html body.body .site-search-wrap { grid-column: 1 / -1 !important; grid-row: 2 !important; }
}
@media (max-width: 767px) {
  html body.body .site-header .site-header-inner { width: calc(100% - 22px) !important; gap: 8px !important; }
  html body.body .site-header .site-brand img { width: 35px !important; height: 35px !important; }
  html body.body .site-header .site-brand .name { max-width: 130px !important; font-size: 17px !important; }
  html body.body .site-main-nav { gap: 2px !important; }
  html body.body .site-main-nav .site-nav-link { padding: 8px 7px !important; font-size: 12px !important; border-radius: 9px !important; }
  html body.body .site-main-nav .site-nav-link i { font-size: 14px !important; }
  html body.body .site-header .site-search-form { height: 42px !important; }
  html body.body .site-header .site-search-submit { flex-basis: 58px !important; width: 58px !important; min-width: 58px !important; max-width: 58px !important; }
  html body.body .main > .hub-wrap > .hub-shortcuts { gap: 10px !important; }
  html body.body .main > .hub-wrap > .hub-shortcuts > .hub-shortcut { padding: 14px 12px 14px 10px !important; gap: 9px !important; }
  html body.body .main > .hub-wrap > .hub-shortcuts .hub-icon { flex-basis: 40px !important; width: 40px !important; height: 40px !important; font-size: 20px !important; }
  html body.body .main > .hub-wrap > .hub-shortcuts .hub-shortcut h2 { font-size: 14px !important; }
  html body.body .main > .hub-wrap > .hub-shortcuts .hub-shortcut p { font-size: 11px !important; }
  html body.body #videos .category-con .a-con { grid-template-columns: repeat(3,minmax(0,1fr)) !important; gap: 10px 7px !important; }
  html body.body #videos .category-con .a-con-inner { padding: 5px !important; border-radius: 8px !important; }
}
@media (max-width: 420px) {
  html body.body .site-header .site-brand .name { max-width: 105px !important; }
  html body.body .site-main-nav .site-nav-link { padding: 8px 6px !important; }
}
