/**
 * ======= sanxio store-advanced · 旗舰店档案 / introduce start ===========
 * 对齐 mall 的 unified-list 蓝条组头 + Antigravity 间距 Token
 */

/* ---------- 页壳 ---------- */
body.sx-store-advanced--profile .sca-channel-top--profile {
  margin: 0 0 var(--sanxio-gap-sm, 8px);
  padding: 0;
}

body.sx-store-advanced--profile .sca-profile-page {
  display: flex;
  flex-direction: column;
  /* 卡片间距只走 gap，避免再叠 margin 变双倍（对齐 contact） */
  gap: var(--sanxio-content-gap, 12px);
}

/* ---------- unified 区块（自含模块壳，不依赖 home-content） ---------- */
body.sx-store-advanced--profile .sca-profile-block.sanxio-home-section-card--unified-list {
  position: relative;
  margin: 0;
  padding: 0;
  background: var(--md3-color-surface-container-low, #f3f5f9);
  border: none;
  border-radius: var(--md3-shape-md, 12px) !important;
  overflow: hidden;
  box-sizing: border-box;
  --sx-home-head-rail-width: 4px;
  --sx-home-rail-inset: var(--sanxio-gap-sm, 8px);
  --sca-profile-pad-start: var(--sanxio-gap-md, 12px);
  --sca-profile-pad-end: var(--sx-home-rail-inset);
  --sx-home-rail-start: 0;
  --sx-home-rail-end: 0;
}

/* 详情单卡（不在 .sca-profile-page 内）仍保留块间距 */
body.sx-store-advanced--profile .sca-channel-top--profile + .sca-profile-block.sanxio-home-section-card--unified-list {
  margin: 0 0 var(--sanxio-content-gap, 12px);
}

body.sx-store-advanced--profile.sanxio-home-premium-page .sca-profile-block.sanxio-home-section-card--unified-list .sca-profile-block__head.sanxio-home-section__head,
body.sx-store-advanced--profile .sca-profile-block__head.sanxio-home-section__head {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: wrap;
  align-items: center !important;
  justify-content: space-between;
  gap: var(--sanxio-gap-sm, 8px);
  min-height: 0 !important;
  margin: 0 0 var(--sanxio-gap-sm, 8px) !important;
  padding: 10px var(--sca-profile-pad-end) 10px var(--sca-profile-pad-start) !important;
  border-radius: var(--md3-shape-md, 12px) var(--md3-shape-md, 12px) 0 0 !important;
  border-style: solid !important;
  border-color: var(--md3-color-primary, #005fb8) !important;
  border-width: 1px var(--sx-home-head-rail-width, 4px) 0 !important;
  background-color: var(--md3-color-surface, #fff) !important;
  background-image: none !important;
  box-shadow: none !important;
  box-sizing: border-box;
}

body.sx-store-advanced--profile .sca-profile-block__title {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.3;
  color: var(--md3-color-on-surface);
}

body.sx-store-advanced--profile .sca-profile-block__more {
  margin-left: auto;
  font-size: 13px;
  font-weight: 600;
  color: var(--md3-color-primary);
  text-decoration: none;
  white-space: nowrap;
}

/* 内容卡贴齐组头外缘；底边用 gap-sm，避免卡内再垫出过大空白（对齐 contact） */
body.sx-store-advanced--profile.sanxio-home-premium-page .sca-profile-block.sanxio-home-section-card--unified-list .sca-profile-block__body,
body.sx-store-advanced--profile .sca-profile-block__body {
  padding: 0 0 var(--sanxio-gap-sm, 8px) !important;
  box-sizing: border-box;
}

/* ---------- 公司概况 ---------- */
body.sx-store-advanced--profile .sca-profile {
  display: flex;
  flex-direction: column;
  gap: var(--sanxio-gap-md, 12px);
}

body.sx-store-advanced--profile .sca-profile__hero {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  gap: var(--sanxio-gap-md, 12px);
  padding: var(--sanxio-card-py, 12px) var(--sanxio-card-px, 12px);
  background: var(--md3-color-surface);
  border: 1px solid var(--md3-color-outline-variant);
  border-radius: var(--md3-shape-md, 12px);
  box-sizing: border-box;
}

body.sx-store-advanced--profile .sca-profile__visual {
  flex: 0 0 auto;
  width: 72px;
  height: 72px;
  border-radius: var(--md3-shape-md, 12px);
  overflow: hidden;
  border: 1px solid var(--md3-color-outline-variant);
  background: var(--md3-color-surface-container);
  display: flex;
  align-items: center;
  justify-content: center;
}

body.sx-store-advanced--profile .sca-profile__visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

body.sx-store-advanced--profile .sca-profile__visual .material-symbols-outlined {
  font-size: 36px;
  color: var(--md3-color-on-surface-variant);
  opacity: 0.65;
}

body.sx-store-advanced--profile .sca-profile__lead {
  flex: 1 1 auto;
  min-width: 0;
}

body.sx-store-advanced--profile .sca-profile__title {
  margin: 0 0 4px;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.3;
  color: var(--md3-color-on-surface);
  word-break: break-word;
}

body.sx-store-advanced--profile .sca-profile__tagline {
  margin: 0 0 8px;
  font-size: 13px;
  line-height: 1.45;
  color: var(--md3-color-on-surface-variant);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

body.sx-store-advanced--profile .sca-profile__badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 8px;
}

body.sx-store-advanced--profile .sca-profile__badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  border-radius: var(--md3-shape-full, 999px);
  font-size: 11px;
  font-weight: 600;
  line-height: 1.2;
  background: var(--md3-color-surface-container-high);
  color: var(--md3-color-on-surface);
  border: 1px solid var(--md3-color-outline-variant);
}

body.sx-store-advanced--profile .sca-profile__badge .material-symbols-outlined {
  font-size: 14px;
}

body.sx-store-advanced--profile .sca-profile__badge--ok {
  background: color-mix(in srgb, var(--md3-color-primary) 12%, transparent);
  color: var(--md3-color-primary);
  border-color: color-mix(in srgb, var(--md3-color-primary) 35%, transparent);
}

body.sx-store-advanced--profile .sca-profile__badge--warn {
  background: color-mix(in srgb, var(--md3-color-error) 10%, transparent);
  color: var(--md3-color-error);
}

body.sx-store-advanced--profile .sca-profile__meta {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin: 0;
  font-size: 12px;
  color: var(--md3-color-on-surface-variant);
}

body.sx-store-advanced--profile .sca-profile__meta .material-symbols-outlined {
  font-size: 16px;
}

/* ---------- 指标 ---------- */
body.sx-store-advanced--profile .sca-stat-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--sanxio-gap-sm, 8px);
}

body.sx-store-advanced--profile .sca-stat-card {
  padding: var(--sanxio-gap-sm, 8px) var(--sanxio-card-px, 12px);
  border-radius: var(--md3-shape-sm, 8px);
  background: var(--md3-color-surface);
  border: 1px solid var(--md3-color-outline-variant);
  box-sizing: border-box;
  min-width: 0;
}

body.sx-store-advanced--profile .sca-stat-card__label {
  display: block;
  font-size: 11px;
  color: var(--md3-color-on-surface-variant);
  margin-bottom: 4px;
}

body.sx-store-advanced--profile .sca-stat-card__value {
  display: block;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.3;
  color: var(--md3-color-on-surface);
  word-break: break-word;
}

body.sx-store-advanced--profile .sca-stat-card__hint {
  display: block;
  margin-top: 2px;
  font-size: 11px;
  color: var(--md3-color-on-surface-variant);
}

/* ---------- 认证 / 业务 ---------- */
body.sx-store-advanced--profile .sca-profile__section-title {
  margin: 0 0 var(--sanxio-gap-sm, 8px);
  font-size: 13px;
  font-weight: 700;
  color: var(--md3-color-on-surface);
}

body.sx-store-advanced--profile .sca-verify-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

body.sx-store-advanced--profile .sca-verify-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 10px;
  border-radius: var(--md3-shape-sm, 8px);
  font-size: 12px;
  font-weight: 500;
  background: var(--md3-color-surface);
  border: 1px solid var(--md3-color-outline-variant);
}

body.sx-store-advanced--profile .sca-verify-chip .material-symbols-outlined {
  font-size: 16px;
  color: var(--md3-color-primary);
}

body.sx-store-advanced--profile .sca-info-cards {
  display: grid;
  gap: var(--sanxio-gap-sm, 8px);
}

body.sx-store-advanced--profile .sca-info-card {
  padding: var(--sanxio-card-py, 12px) var(--sanxio-card-px, 12px);
  border-radius: var(--md3-shape-sm, 8px);
  background: var(--md3-color-surface);
  border: 1px solid var(--md3-color-outline-variant);
  box-sizing: border-box;
}

body.sx-store-advanced--profile .sca-info-card__title {
  margin: 0 0 6px;
  font-size: 13px;
  font-weight: 700;
  color: var(--md3-color-on-surface);
}

body.sx-store-advanced--profile .sca-info-card p {
  margin: 0;
  font-size: 13px;
  line-height: 1.55;
  color: var(--md3-color-on-surface-variant);
  word-break: break-word;
}

/* 行业分类等 cat_pos 链接：纯文本样式，无下划线、不变色 */
body.sx-store-advanced--profile .sca-info-card a,
body.sx-store-advanced--profile .sca-info-card a:link,
body.sx-store-advanced--profile .sca-info-card a:visited,
body.sx-store-advanced--profile .sca-info-card a:hover,
body.sx-store-advanced--profile .sca-info-card a:active,
body.sx-store-advanced--profile .sca-info-card a:focus {
  color: inherit !important;
  text-decoration: none !important;
}

body.sx-store-advanced--profile .sca-profile__cta {
  margin: 0;
  text-align: center;
}

/* ---------- 正文 / 空态 ---------- */
body.sx-store-advanced--profile .sca-channel__content--prose {
  font-size: 14px;
  line-height: 1.7;
  color: var(--md3-color-on-surface);
}

body.sx-store-advanced--profile .sca-channel__content--prose img {
  max-width: 100%;
  height: auto;
  border-radius: var(--md3-shape-sm, 8px);
}

body.sx-store-advanced--profile .sca-empty--profile {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--sanxio-gap-sm, 8px);
  margin: 0;
  padding: 28px var(--sanxio-card-px, 12px);
  text-align: center;
  color: var(--md3-color-on-surface-variant);
  background: var(--md3-color-surface);
  border: 1px dashed var(--md3-color-outline-variant);
  border-radius: var(--md3-shape-md, 12px);
}

body.sx-store-advanced--profile .sca-empty--profile .material-symbols-outlined {
  font-size: 40px;
  opacity: 0.5;
}

body.sx-store-advanced--profile .sca-empty--profile p {
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
}

body.sx-store-advanced--profile .sca-video--rounded {
  border-radius: var(--md3-shape-md, 12px);
  overflow: hidden;
  background: var(--md3-color-surface);
}

body.sx-store-advanced--profile .sca-channel__tools {
  margin-top: var(--sanxio-gap-md, 12px);
}

/* ---------- 桌面 ---------- */
@media (min-width: 768px) {
  body.sx-store-advanced--profile .sca-profile__hero {
    gap: var(--sanxio-content-gap, 20px);
    padding: var(--sanxio-card-py, 20px) var(--sanxio-card-px, 20px);
  }

  body.sx-store-advanced--profile .sca-profile__visual {
    width: 96px;
    height: 96px;
  }

  body.sx-store-advanced--profile .sca-profile__title {
    font-size: 20px;
  }

  body.sx-store-advanced--profile .sca-profile__tagline {
    font-size: 14px;
    -webkit-line-clamp: 3;
  }

  body.sx-store-advanced--profile .sca-stat-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: var(--sanxio-gap-md, 16px);
  }

  body.sx-store-advanced--profile .sca-stat-card__value {
    font-size: 16px;
  }

  body.sx-store-advanced--profile .sca-info-cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--sanxio-gap-md, 16px);
  }

  body.sx-store-advanced--profile .sca-profile-block__title {
    font-size: 16px;
  }

  body.sx-store-advanced--profile .sca-channel__content--prose {
    font-size: 15px;
  }
}

@media (max-width: 767px) {
  body.sx-store-advanced--profile .sca-profile-block.sanxio-home-section-card--unified-list {
    --sca-profile-pad-start: calc(var(--sx-home-head-rail-width, 4px) + 12px);
    --sca-profile-pad-end: calc(var(--sx-home-head-rail-width, 4px) + 12px);
  }

  body.sx-store-advanced--profile .sca-profile-block__title {
    font-size: 14px;
  }
}
/**
 * ======= sanxio store-advanced · profile end ===========
 */
