:root {
  --tg-brand: #10a667;
  --tg-brand-deep: #087a4b;
  --tg-ink: #18212f;
  --tg-muted: #697386;
  --tg-line: #e7ebef;
  --tg-surface: #ffffff;
  --tg-canvas: #f4f7f6;
  --tg-radius: 14px;
  --tg-shadow: 0 12px 36px rgba(24, 33, 47, .07);
  --tg-wrap: 1200px;
}

html { scroll-behavior: smooth; }
body.techgg { background: var(--tg-canvas); color: var(--tg-ink); font-family: "IBM Plex Sans", "Noto Sans SC", "Microsoft YaHei", sans-serif; }
body.techgg *, body.techgg *::before, body.techgg *::after { box-sizing: border-box; }
body.techgg img { max-width: 100%; height: auto; }
body.techgg .wp, body.techgg .dz_btm_layer { width: min(var(--tg-wrap), calc(100% - 40px)); }
body.techgg .dz_layer_top { background: rgba(22, 24, 23, .97) !important; border-bottom: 1px solid rgba(255,255,255,.08); backdrop-filter: blur(18px); }
body.techgg .dz_btm_layer { min-height: 68px; }
body.techgg .dzlogo { width: 154px; height: 42px; }
body.techgg .dzlogo img { max-width: 154px; max-height: 42px; }
body.techgg .dz_layer_nav ul li a { font-size: 15px; font-weight: 650; color: rgba(255,255,255,.76); }
body.techgg .dz_layer_nav ul li.a a, body.techgg .dz_layer_nav ul li a:hover { color: #fff; }
body.techgg .header-notice .notice-icon .dzicon, body.techgg .dz_layer_dl, body.techgg .dz_layer_dl a { color: rgba(255,255,255,.82); }
body.techgg .dz_layer_nav ul li a::after { background: var(--tg-brand); }
body.techgg .dz_footc { margin-top: 56px; background: #16211c; }
body.techgg .dz_footc_bottom { padding-left: 0; padding-right: 0; }

/* Portal shell */
body.techgg .container { width: min(var(--tg-wrap), calc(100% - 40px)); margin-left: auto; margin-right: auto; }
body.techgg .portal-home-layout, body.techgg .row { min-width: 0; }
body.techgg .portal-home-layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 28px; align-items: start; }
body.techgg .portal-home-sidebar { min-width: 0; }
body.techgg .main-mid, body.techgg .main-left, body.techgg .area { min-width: 0; }
body.techgg .main-mid, body.techgg .portal-home-sidebar > * { border-radius: var(--tg-radius); }
body.techgg .tagbox { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 28px 0 10px; padding-top: 18px; border-top: 1px solid var(--tg-line); color: var(--tg-muted); }
body.techgg .tagbox a { display: inline-flex; padding: 6px 11px; border: 1px solid #d8eee4; border-radius: 999px; background: #f0faf5; color: var(--tg-brand-deep); }
body.techgg .tagbox a:hover { color: #fff; background: var(--tg-brand); border-color: var(--tg-brand); }

/* Portal article and category layouts */
body.techgg #ct.ct2.inside_box { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 28px; width: min(var(--tg-wrap), calc(100% - 40px)); }
body.techgg #ct.ct2.inside_box::before, body.techgg #ct.ct2.inside_box::after { display: none; }
body.techgg #ct.ct2.inside_box > .mn, body.techgg #ct.ct2.inside_box > .sd { float: none; width: auto; min-width: 0; margin: 0; }
body.techgg #ct.ct2.inside_box > .mn { padding: 0; background: var(--tg-surface); border-radius: var(--tg-radius); box-shadow: var(--tg-shadow); overflow: hidden; }
body.techgg #ct.ct2.inside_box > .sd { display: block; }
body.techgg .middle_info { padding: clamp(20px, 4vw, 52px); }
body.techgg .article-content { font-size: 17px; line-height: 1.9; overflow-wrap: anywhere; }
body.techgg .article-content p { margin: 1.15em 0; }
body.techgg .tg-side-card, body.techgg #ct.ct2 .sd .box-moder, body.techgg #ct.ct2 .sd > .area { margin: 0 0 18px; padding: 20px; background: #fff; border: 1px solid var(--tg-line); border-radius: var(--tg-radius); box-shadow: var(--tg-shadow); }
body.techgg .tg-side-title { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; padding-bottom: 12px; border-bottom: 1px solid var(--tg-line); font-size: 16px; font-weight: 750; }
body.techgg .tg-work-list { margin: 0; padding: 0; list-style: none; }
body.techgg .tg-work-list li + li { border-top: 1px dashed var(--tg-line); }
body.techgg .tg-work-list a { display: block; padding: 11px 0; color: var(--tg-ink); line-height: 1.55; }
body.techgg .tg-work-list a:hover { color: var(--tg-brand); }
body.techgg .tg-author-card { text-align: center; }
body.techgg .tg-author-card img { width: 76px; height: 76px; border-radius: 50%; object-fit: cover; }

/* X5 portal administration */
body.techgg.pg_portalcp #ct, body.techgg.pg_portalcp .ct2_a { width: min(1160px, calc(100% - 40px)); margin: 28px auto; }
body.techgg.pg_portalcp .mn, body.techgg.pg_portalcp .appl { border-radius: var(--tg-radius); border-color: var(--tg-line); background: #fff; box-shadow: var(--tg-shadow); }
body.techgg.pg_portalcp .tb a, body.techgg.pg_portalcp .pn { border-radius: 8px; }

/* Space/member center: retain X5 DOM, replace fragile floats. */
body.techgg[id^="nv_home"] #ct, body.techgg.pg_space #ct, body.techgg.pg_spacecp #ct { width: min(1160px, calc(100% - 40px)); margin-left: auto; margin-right: auto; }
body.techgg.pg_space .ct2_a, body.techgg.pg_spacecp .ct2_a { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 24px; }
body.techgg.pg_space .ct2_a > .appl, body.techgg.pg_space .ct2_a > .mn, body.techgg.pg_spacecp .ct2_a > .appl, body.techgg.pg_spacecp .ct2_a > .mn { float: none; width: auto; min-width: 0; margin: 0; }
body.techgg .appl, body.techgg .mn { border-color: var(--tg-line); }

@media (max-width: 900px) {
  body.techgg .wp, body.techgg .dz_btm_layer, body.techgg .container, body.techgg #ct.ct2.inside_box,
  body.techgg.pg_portalcp #ct, body.techgg.pg_portalcp .ct2_a,
  body.techgg[id^="nv_home"] #ct, body.techgg.pg_space #ct, body.techgg.pg_spacecp #ct { width: min(100% - 24px, var(--tg-wrap)); }
  body.techgg .dz_btm_layer { display: grid; grid-template-columns: auto 1fr auto; align-items: center; }
  body.techgg .dz_layer_nav { min-width: 0; overflow-x: auto; scrollbar-width: none; }
  body.techgg .dz_layer_nav::-webkit-scrollbar { display: none; }
  body.techgg .dz_layer_nav ul { display: flex; width: max-content; }
  body.techgg .portal-home-layout, body.techgg #ct.ct2.inside_box,
  body.techgg.pg_space .ct2_a, body.techgg.pg_spacecp .ct2_a { grid-template-columns: 1fr; }
  body.techgg #ct.ct2.inside_box > .sd { width: min(100%, 560px); margin: 0 auto; }
  body.techgg .portal-main-left, body.techgg .portal-main-right { float: none !important; width: 100% !important; }
}

@media (max-width: 600px) {
  body.techgg .wp, body.techgg .container, body.techgg #ct.ct2.inside_box { width: 100%; }
  body.techgg #wp { padding-left: 0; padding-right: 0; }
  body.techgg .middle_info { padding: 18px 14px; }
  body.techgg #ct.ct2.inside_box > .mn { border-radius: 0; }
  body.techgg #ct.ct2.inside_box > .sd { width: calc(100% - 24px); }
  body.techgg .article-content { font-size: 16px; line-height: 1.78; }
  body.techgg .dz_footc_bottom { width: calc(100% - 24px); }
}

/* TechGG brand footer */
body.techgg .dz_footc {
  margin-top: 56px;
  padding: 0;
  color: rgba(255, 255, 255, .62);
  background: #111a16;
  box-shadow: none;
}
body.techgg #ft.dz_footc_bottom {
  padding: 34px 0 24px;
  line-height: 1.6;
  color: inherit;
}
body.techgg .techgg-footer-top {
  display: flex;
  min-height: 76px;
  align-items: center;
  gap: 18px;
}
body.techgg .techgg-footer-logo {
  display: flex;
  width: 178px;
  height: 62px;
  padding: 7px 12px;
  flex: 0 0 178px;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 10px;
  background: #fff;
}
body.techgg .techgg-footer-logo img {
  display: block;
  width: auto;
  max-width: 100%;
  height: auto;
  max-height: 48px;
  object-fit: contain;
}
body.techgg .techgg-footer-identity { min-width: 0; }
body.techgg .techgg-footer-identity strong {
  display: block;
  color: #fff;
  font-size: 20px;
  font-weight: 750;
  letter-spacing: .04em;
}
body.techgg .techgg-footer-identity strong span {
  margin-left: 5px;
  color: #39c77f;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
}
body.techgg .techgg-footer-identity p {
  margin: 5px 0 0;
  color: rgba(255, 255, 255, .48);
  font-size: 13px;
  letter-spacing: .05em;
}
body.techgg .dz_footc_dico {
  margin-left: auto;
  padding: 0;
  float: none;
  background: transparent;
}
body.techgg .dz_footc_dico .ewmimg {
  display: flex;
  width: auto;
  margin: 0;
  float: none;
  align-items: center;
  gap: 10px;
  color: rgba(255, 255, 255, .55);
  font-size: 12px;
}
body.techgg .dz_footc_dico .ewmimg img {
  width: 64px;
  height: 64px;
  margin: 0;
  border-radius: 7px;
  object-fit: cover;
}
body.techgg .dz_footc_nav {
  display: flex;
  height: auto;
  margin: 26px 0 0;
  padding: 15px 0;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px 13px;
  line-height: 1.5;
  border-top: 1px solid rgba(255, 255, 255, .09);
  border-bottom: 1px solid rgba(255, 255, 255, .09);
}
body.techgg .dz_footc_nav a {
  margin: 0;
  float: none;
  color: rgba(255, 255, 255, .7);
  font-size: 13px;
}
body.techgg .dz_footc_nav a:hover { color: #45d58d; }
body.techgg .dz_footc_nav .pipe {
  margin: 0;
  float: none;
  color: rgba(255, 255, 255, .17);
}
body.techgg .dz_footc_copy {
  padding: 17px 0 0;
  color: rgba(255, 255, 255, .48);
  font-size: 12px;
  line-height: 1.8;
}
body.techgg .dz_footc_copy p { margin: 0; }
body.techgg .dz_footc_copy .techgg-footer-note { margin-bottom: 7px; }
body.techgg .techgg-copyright {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 3px 9px;
}
body.techgg .techgg-copyright-owner {
  color: rgba(255, 255, 255, .72);
  font-weight: 600;
}
body.techgg .techgg-copyright-owner b {
  color: #39c77f;
  font-size: 14px;
}
body.techgg .techgg-copyright-separator { color: rgba(255, 255, 255, .2); }
body.techgg .techgg-discuz-note {
  color: rgba(255, 255, 255, .6);
  letter-spacing: .03em;
}
body.techgg .dz_footc_copy a { color: rgba(255, 255, 255, .55); }
body.techgg .dz_footc_copy a:hover { color: #45d58d; }
body.techgg .dz_footc_copy .techgg-mps {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
body.techgg .dz_footc_copy .techgg-mps img {
  width: 14px;
  height: 14px;
  margin: 0;
  vertical-align: middle;
}

@media (max-width: 600px) {
  body.techgg .dz_footc { margin-top: 36px; }
  body.techgg #ft.dz_footc_bottom {
    width: 100%;
    padding: 26px 14px 20px;
  }
  body.techgg .techgg-footer-top {
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 13px;
  }
  body.techgg .techgg-footer-logo {
    width: 142px;
    height: 52px;
    flex-basis: 142px;
  }
  body.techgg .techgg-footer-logo img { max-height: 40px; }
  body.techgg .techgg-footer-identity strong { font-size: 18px; }
  body.techgg .techgg-footer-identity p { font-size: 12px; }
  body.techgg .dz_footc_dico {
    width: 100%;
    margin: 5px 0 0;
  }
  body.techgg .dz_footc_nav {
    margin-top: 20px;
    gap: 8px 11px;
  }
  body.techgg .dz_footc_nav .pipe { display: none; }
  body.techgg .techgg-copyright {
    display: block;
    line-height: 1.9;
  }
  body.techgg .techgg-copyright > span,
  body.techgg .techgg-copyright > a { margin-right: 6px; }
  body.techgg .techgg-copyright-separator { display: none; }
}
