/* ?????????? + ???? */
:root {
  --cg-theme: #2D7D56;
}

/* ===== ????===== */
.cg-admin { padding: 8px 4px 20px; }
.cg-admin__toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid #eee;
}
.cg-switch { font-weight: 600; margin: 0; cursor: pointer; }
.cg-list { min-height: 48px; }
.cg-row {
  display: flex;
  gap: 8px;
  margin-bottom: 8px;
}
.cg-row .form-control { flex: 1; }
.cg-empty {
  color: #999;
  font-size: 13px;
  padding: 12px;
  background: #f7f7f7;
  border-radius: 8px;
}
.cg-shop-card {
  border: 1px solid #e5e5e5;
  border-radius: 10px;
  padding: 12px;
  margin-bottom: 12px;
  background: #fafafa;
}
.cg-shop-card__head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}
.cg-shop-card__head strong { flex: 1; }
.cg-pub { margin: 0; font-weight: normal; }
.cg-shop-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.cg-shop-grid label {
  display: block;
  font-size: 12px;
  color: #666;
  margin-bottom: 4px;
}
.cg-shop-full { grid-column: 1 / -1; }
.cg-bn-preview {
  width: 100%;
  max-width: 480px;
  height: 140px;
  border: 1px dashed #cfd6e0;
  border-radius: 8px;
  background: #fff;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 8px;
}
.cg-bn-preview__img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.cg-bn-preview__empty {
  color: #999;
  font-size: 13px;
}
.cg-bn-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

/* ===== ????????????===== */
:root { --cg-theme: #2F7CF6; }
#cg_portal {
  display: none;
  position: absolute;
  inset: 0;
  z-index: 900;
  background: #f5f7fb;
  color: #1a2230;
  overflow: hidden;
  font-family: "PingFang SC", "Microsoft YaHei", sans-serif;
  flex-direction: column;
}
#cg_portal.is-open { display: flex; }
.cg-hp-top {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px 4px;
  background: #fff;
}
.cg-hp-brand {
  font-size: 16px;
  font-weight: 700;
  color: #152033;
  max-width: calc(100% - 52px);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.cg-hp-close {
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 50%;
  background: rgba(20, 28, 40, 0.06);
  color: #334;
  font-size: 22px;
  line-height: 32px;
  cursor: pointer;
}
.cg-hp-search {
  flex: 0 0 auto;
  margin: 8px 14px 6px;
  position: relative;
  background: #fff;
  border-radius: 22px;
  border: 1px solid #e4e8ef;
  box-shadow: 0 2px 8px rgba(20, 40, 80, 0.04);
}
.cg-hp-search__ico {
  position: absolute;
  left: 14px;
  top: 50%;
  width: 14px;
  height: 14px;
  margin-top: -7px;
  border: 2px solid #9aa3b2;
  border-radius: 50%;
  box-sizing: border-box;
  pointer-events: none;
}
.cg-hp-search__ico::after {
  content: '';
  position: absolute;
  right: -5px;
  bottom: -4px;
  width: 7px;
  height: 2px;
  background: #9aa3b2;
  transform: rotate(45deg);
  border-radius: 1px;
}
.cg-hp-search input {
  width: 100%;
  height: 40px;
  border: 0;
  border-radius: 22px;
  padding: 0 14px 0 38px;
  outline: none;
  background: transparent;
  font-size: 14px;
  box-sizing: border-box;
}
.cg-hp-search-results {
  flex: 0 0 auto;
  margin: 0 14px 6px;
  max-height: 180px;
  overflow: auto;
  background: #fff;
  border-radius: 12px;
  border: 1px solid #e8ecf2;
}
.cg-search-hit {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  width: 100%;
  border: 0;
  border-bottom: 1px solid #f0f2f6;
  background: #fff;
  padding: 10px 12px;
  text-align: left;
  cursor: pointer;
}
.cg-search-hit strong { font-size: 14px; color: #152033; }
.cg-search-hit span { font-size: 12px; color: #8a94a6; margin-top: 2px; }
.cg-hp-scroll {
  flex: 1 1 auto;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  padding: 4px 14px 88px;
}
.cg-sec { margin: 14px 0 6px; }
.cg-sec__title {
  margin: 0 0 10px;
  font-size: 16px;
  font-weight: 700;
  color: #152033;
}
.cg-banner {
  position: relative;
  height: 140px;
  border-radius: 14px;
  overflow: hidden;
  background: #dfe6f0;
  margin-top: 6px;
}
.cg-banner__track {
  display: flex;
  height: 100%;
  width: 100%;
  transition: transform .45s ease;
  will-change: transform;
}
.cg-banner__slide {
  flex: 0 0 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  position: relative;
  cursor: pointer;
}
.cg-banner__cap {
  position: absolute;
  left: 12px;
  bottom: 10px;
  color: #fff;
  font-size: 13px;
  text-shadow: 0 1px 4px rgba(0,0,0,.45);
}
.cg-banner__dots {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 8px;
  display: flex;
  justify-content: center;
  gap: 6px;
}
.cg-banner__dot {
  width: 6px;
  height: 6px;
  border: 0;
  border-radius: 50%;
  background: rgba(255,255,255,.45);
  padding: 0;
  cursor: pointer;
}
.cg-banner__dot.is-on { background: #fff; }
.cg-services {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 10px 6px;
}
.cg-svc {
  border: 0;
  background: transparent;
  padding: 0;
  cursor: pointer;
  text-align: center;
}
.cg-svc__ico {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  margin: 0 auto 6px;
  border-radius: 50%;
  background: linear-gradient(145deg, var(--cg-theme), #5aa2ff);
  color: #fff;
  font-style: normal;
  font-size: 16px;
  font-weight: 700;
  overflow: hidden;
}
.cg-svc__ico img { width: 100%; height: 100%; object-fit: cover; }
.cg-svc em {
  display: block;
  font-style: normal;
  font-size: 11px;
  color: #2a3548;
  line-height: 1.25;
}
.cg-popular {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}
.cg-pop {
  border: 1px solid #e6ebf2;
  border-radius: 12px;
  background: #fff;
  padding: 12px 12px 10px;
  text-align: left;
  cursor: pointer;
}
.cg-pop strong {
  display: block;
  font-size: 14px;
  color: #152033;
  margin-bottom: 4px;
}
.cg-pop span { font-size: 12px; color: #8a94a6; }

/* ??????????? */
.cg-intro-teaser__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}
.cg-intro-teaser__head .cg-sec__title { margin: 0; }
.cg-intro-more {
  flex: 0 0 auto;
  border: 0;
  background: transparent;
  color: var(--cg-theme);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  padding: 4px 2px;
}
.cg-intro-teaser__body {
  background: #fff;
  border: 1px solid #e6ebf2;
  border-radius: 10px;
  padding: 8px 12px;
  font-size: 12px;
  line-height: 1.5;
  color: #3a4558;
  box-sizing: border-box;
	height: calc(8px + 12px* 1.5* 3 + 5px); /* max-height: 72px;*/
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  overflow: hidden;
  word-break: break-word;
}

/* ???????? 20% ?? / ???? */
.cg-catalog {
  display: flex;
  align-items: stretch;
  min-height: 220px;
  max-height: 420px;
  background: #fff;
  border: 1px solid #e6ebf2;
  border-radius: 12px;
  overflow: hidden;
}
.cg-catalog--full {
  max-height: none;
  min-height: 360px;
  height: calc(100vh - 180px);
}
.cg-catalog__nav {
  flex: 0 0 20%;
  width: 20%;
  max-width: 160px;
  min-width: 72px;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  background: #f3f6fb;
  border-right: 1px solid #e6ebf2;
}
.cg-catalog__l1 {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  width: 100%;
  border: 0;
  border-bottom: 1px solid #e8ecf2;
  background: transparent;
  padding: 12px 10px;
  text-align: left;
  cursor: pointer;
  color: #4a5568;
}
.cg-catalog__l1 strong {
  font-size: 13px;
  font-weight: 700;
  line-height: 1.3;
}
.cg-catalog__l1 span {
  font-size: 11px;
  color: #9aa3b2;
  margin-top: 4px;
}
.cg-catalog__l1.is-on {
  background: #fff;
  color: var(--cg-theme);
  box-shadow: inset 3px 0 0 var(--cg-theme);
}
.cg-catalog__main {
  flex: 1 1 auto;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  padding: 10px 12px 14px;
}
.cg-catalog__floor { margin-bottom: 14px; }
.cg-catalog__floor:last-child { margin-bottom: 4px; }
.cg-catalog__floor-title {
  font-size: 13px;
  font-weight: 700;
  color: #152033;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.cg-catalog__floor-title em {
  font-style: normal;
  font-size: 11px;
  font-weight: 500;
  color: #9aa3b2;
}
.cg-catalog__points {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.cg-catalog__point {
  border: 1px solid #e0e6ef;
  background: #f8fafc;
  border-radius: 999px;
  padding: 7px 12px;
  font-size: 12px;
  color: #2a3548;
  cursor: pointer;
  line-height: 1.3;
}
.cg-catalog__point:active,
.cg-catalog__point:hover {
  border-color: var(--cg-theme);
  color: var(--cg-theme);
  background: rgba(47, 124, 246, 0.06);
}
.cg-catalog__empty {
  font-size: 12px;
  color: #9aa3b2;
}

/* ???????? */
.cg-info-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}
.cg-info-bar .cg-sec__title { margin: 0; flex: 1; }
.cg-info-back {
  flex: 0 0 auto;
  border: 0;
  background: rgba(20, 28, 40, 0.06);
  color: #334;
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}
.cg-intro {
  background: #fff;
  border: 1px solid #e6ebf2;
  border-radius: 12px;
  padding: 16px;
  font-size: 14px;
  line-height: 1.7;
  color: #3a4558;
}
.cg-intro p { margin: 0 0 10px; }
.cg-intro img { max-width: 100%; height: auto; border-radius: 8px; }

.cg-hp-actions { margin: 18px 0 8px; }
.cg-hp-go {
  width: 100%;
  height: 44px;
  border: 0;
  border-radius: 12px;
  background: var(--cg-theme);
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
}
.cg-bldg {
  background: #fff;
  border: 1px solid #e6ebf2;
  border-radius: 12px;
  margin-bottom: 10px;
  overflow: hidden;
}
.cg-bldg__head {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border: 0;
  background: #fff;
  padding: 12px 14px;
  cursor: pointer;
  text-align: left;
}
.cg-bldg__head strong { font-size: 14px; color: #152033; }
.cg-bldg__head span { font-size: 12px; color: #8a94a6; }
.cg-bldg__body { display: none; padding: 0 8px 10px; }
.cg-bldg.is-open .cg-bldg__body { display: block; }
.cg-bldg-point {
  display: flex;
  flex-direction: column;
  width: 100%;
  border: 0;
  border-top: 1px solid #f0f2f6;
  background: transparent;
  padding: 10px 8px;
  text-align: left;
  cursor: pointer;
  font-size: 13px;
  color: #2a3548;
}
.cg-bldg-point small { color: #8a94a6; margin-top: 2px; }
.cg-hint {
  text-align: center;
  color: #9aa3b2;
  font-size: 13px;
  padding: 20px 8px;
}
.cg-hp-tabs {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 56px;
  display: flex;
  background: #fff;
  border-top: 1px solid #e8ecf2;
  box-shadow: 0 -4px 16px rgba(20, 40, 80, 0.05);
  padding-bottom: env(safe-area-inset-bottom, 0);
}
.cg-tab {
  flex: 1;
  border: 0;
  background: transparent;
  color: #8a94a6;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}
.cg-tab.is-on { color: var(--cg-theme); }

/* ????????????????????????*/
@media (min-width: 768px) {
  .cg-hp-top { padding: 14px 28px 8px; }
  .cg-hp-brand { font-size: 20px; }
  .cg-hp-search { margin: 10px auto 8px; max-width: 720px; width: calc(100% - 56px); }
  .cg-hp-search-results { margin: 0 auto 8px; max-width: 720px; width: calc(100% - 56px); }
  .cg-hp-scroll {
    padding: 8px 28px 100px;
    max-width: 1100px;
    width: 100%;
    margin: 0 auto;
    box-sizing: border-box;
  }
  .cg-banner { height: 280px; border-radius: 14px; }
  .cg-services { grid-template-columns: repeat(6, 1fr); gap: 16px 12px; }
  .cg-svc__ico { width: 56px; height: 56px; font-size: 20px; }
  .cg-popular { grid-template-columns: repeat(3, 1fr); gap: 12px; }
  .cg-pop { min-height: 72px; padding: 14px 16px; font-size: 15px; }
  .cg-catalog { min-height: 320px; max-height: 520px; }
  .cg-catalog__nav { max-width: 200px; }
  .cg-catalog__l1 { padding: 14px 12px; }
  .cg-catalog__l1 strong { font-size: 14px; }
  .cg-catalog__point { font-size: 13px; padding: 8px 14px; }
  .cg-hp-go { max-width: 420px; margin-left: auto; margin-right: auto; }
  .cg-hp-tabs {
    max-width: 1100px;
    left: 50%;
    right: auto;
    width: 100%;
    transform: translateX(-50%);
  }
  #cg_shop_modal .cg-modal {
    width: min(640px, 92vw);
  }
  #cg_shop_modal .cg-modal__preview { height: 260px; }
  #cg_shop_modal .cg-modal__close {
    width: 36px;
    height: 36px;
    line-height: 34px;
    font-size: 20px;
    right: 12px;
    top: 12px;
  }
}
@media (min-width: 1200px) {
  .cg-hp-scroll { max-width: 1200px; }
  .cg-banner { height: 320px; }
  .cg-services { grid-template-columns: repeat(8, 1fr); }
  .cg-popular { grid-template-columns: repeat(4, 1fr); }
}
@media (max-width: 380px) {
  .cg-services { grid-template-columns: repeat(4, 1fr); }
  .cg-svc__ico { width: 44px; height: 44px; }
}
/* ???? */
#cg_shop_modal {
  display: none;
  position: absolute;
  inset: 0;
  z-index: 950;
  background: rgba(0,0,0,.55);
  align-items: center;
  justify-content: center;
  padding: 20px;
}
#cg_shop_modal.is-open { display: flex; }
#cg_shop_modal .cg-modal {
  width: min(520px, 96vw);
  max-height: 92vh;
  overflow: auto;
  background: #fff;
  border-radius: 14px;
  position: relative;
  box-shadow: 0 20px 50px rgba(0,0,0,.35);
}
#cg_shop_modal .cg-modal__close {
  position: absolute;
  right: 10px;
  top: 8px;
  z-index: 2;
  border: 0;
  background: rgba(0,0,0,.45);
  color: #fff;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 16px;
  line-height: 28px;
}
#cg_shop_modal .cg-modal__preview {
  height: 220px;
  background: #111 center/cover no-repeat;
  position: relative;
}
#cg_shop_modal .cg-modal__preview-empty {
  color: #aaa;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
}
#cg_shop_modal .cg-modal__body { padding: 16px 18px 18px; }
#cg_shop_modal .cg-modal__title-row {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  margin-bottom: 10px;
}
#cg_shop_modal .cg-modal__logo {
  width: 48px;
  height: 48px;
  object-fit: contain;
  border-radius: 8px;
  background: #f3f3f3;
}
#cg_shop_modal .cg-modal__title { font-size: 18px; font-weight: 700; margin: 0 0 4px; }
#cg_shop_modal .cg-tag {
  display: inline-block;
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(45,125,86,.12);
  color: var(--cg-theme);
}
#cg_shop_modal .cg-modal__meta {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  margin: 12px 0;
}
#cg_shop_modal .cg-modal__intro {
  flex: 1;
  font-size: 13px;
  color: #555;
  line-height: 1.6;
  max-height: 120px;
  overflow: auto;
}
#cg_shop_modal .cg-modal__qr {
  text-align: center;
  flex: 0 0 110px;
}
#cg_shop_modal .cg-modal__qr img {
  width: 96px;
  height: 96px;
  background: #fff;
  border: 1px solid #eee;
}
#cg_shop_modal .cg-modal__qr span {
  display: block;
  font-size: 11px;
  color: #888;
  margin-top: 4px;
}
#cg_shop_modal .cg-go {
  display: block;
  width: 100%;
  border: 0;
  border-radius: 10px;
  padding: 12px;
  background: var(--cg-theme);
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
}

@media (max-width: 720px) {
  #cg_shop_modal .cg-modal__meta { flex-direction: column; }
}
