/* 夸夸侠官网 - 基于 Axure 原型「首页版本（j）」 */
:root {
  --color-primary: #ff9900;
  --color-primary-dark: #e68a00;
  --color-link: #169bd5;
  --color-text: #333;
  --color-text-light: #666;
  --color-border: #e5e5e5;
  --color-bg-gray: #f2f2f2;
  --color-bg-light: #fafafa;
  --color-red: #ff0000;
  --color-search-btn: #ff9933;
  --container-width: 1286px;
  --header-height: 88px;
  --font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  font-size: 14px;
  -webkit-text-size-adjust: 100%;
  -ms-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font-family);
  color: var(--color-text);
  background: #fff;
  line-height: 1.5;
  min-width: 320px;
}

a {
  color: inherit;
  text-decoration: none;
}

a:hover {
  color: var(--color-link);
}

img {
  max-width: 100%;
  display: block;
}

ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.container {
  width: calc(100% - 32px);
  max-width: var(--container-width);
  margin: 0 auto;
}

/* 顶部工具栏（原型第一行：左 6 项 + 右 3 项，两端分布） */
.top-bar {
  background: #f2f2f2;
  font-size: 16px;
  color: #333;
}

.top-bar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  min-height: 42px;
  height: 42px;
}

.top-bar-left,
.top-bar-right {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  flex-shrink: 0;
}

/* 顶部与主头部左缘对齐（原型内容区 1286px） */
.top-bar-inner,
.header-main,
.main-nav-inner,
.trust-bar-inner {
  max-width: var(--container-width);
}

.top-bar-left {
  justify-content: flex-start;
}

.top-bar-right {
  justify-content: flex-end;
  margin-left: auto;
}

.top-bar-left a,
.top-bar-right a {
  display: inline-block;
  white-space: nowrap;
  color: #333;
  line-height: 42px;
  font-size: 16px;
  padding: 0;
}

.top-bar-left a + a {
  margin-left: 48px;
}

.top-bar-right a + a {
  margin-left: 0;
}

.top-bar-right .top-bar-sep {
  color: #999;
  line-height: 42px;
  user-select: none;
}

.top-bar-right {
  gap: 12px;
}

.top-bar a:hover {
  color: var(--color-link);
}

.city-select {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
}

.city-select img {
  width: 14px;
  height: 16px;
  object-fit: contain;
}

@media (max-width: 1100px) {
  .top-bar-left a + a {
    margin-left: 24px;
  }

  .top-bar-right a + a {
    margin-left: 28px;
  }

  .top-bar-left a,
  .top-bar-right a {
    font-size: 14px;
  }
}

@media (max-width: 900px) {
  .top-bar-inner {
    flex-direction: column;
    align-items: stretch;
    height: auto;
    min-height: 42px;
    padding: 8px 0;
  }

  .top-bar-left,
  .top-bar-right {
    flex-wrap: wrap;
    justify-content: center;
    margin-left: 0;
  }

  .top-bar-left a,
  .top-bar-right a {
    line-height: 28px;
    margin-left: 0 !important;
    margin-right: 16px;
    margin-bottom: 4px;
  }
}

/* 主头部 */
.site-header {
  background: #fff;
  border-bottom: none;
}

.header-main {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0;
  padding: 14px 0 10px;
  min-width: 0;
}

.brand-block {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 0 0 280px;
  width: 280px;
  min-width: 280px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
  width: auto;
  min-width: 0;
}

.header-divider {
  width: 1px;
  height: 29px;
  background: #797979;
  flex-shrink: 0;
}

.header-city {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  cursor: pointer;
  flex-shrink: 0;
}

.header-city-top {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--color-primary);
  font-size: 14px;
  line-height: 1.2;
}

.header-city-top img {
  width: 14px;
  height: 16px;
  object-fit: contain;
}

.header-city-switch {
  font-size: 12px;
  color: var(--color-text-light);
  line-height: 1.2;
}

.header-city:hover .header-city-switch {
  color: var(--color-link);
}

.brand-logo {
  height: 48px;
  width: auto;
  flex-shrink: 0;
  display: flex;
  align-items: center;
}

.brand-logo img {
  height: 48px;
  width: auto;
  display: block;
}

.brand-text {
  flex: 1;
  min-width: 0;
}

.brand-text p {
  margin: 4px 0 0;
  font-size: 12px;
  line-height: 1.3;
  color: var(--color-text);
  font-family: SimSun, "Songti SC", serif;
  white-space: nowrap;
}

.search-area {
  flex: 1 1 0;
  max-width: 798px;
  min-width: 0;
  margin: 0;
}

.search-tabs {
  display: flex;
  gap: 32px;
  margin-bottom: 6px;
  font-size: 16px;
  line-height: 22px;
  padding-left: 0;
}

.search-box {
  display: flex;
  width: 100%;
  height: 47px;
  border: 1px solid #797979;
  border-radius: 5px;
  overflow: hidden;
  background: #fff;
}

.search-input-wrap {
  display: flex;
  align-items: center;
  flex: 1;
  min-width: 0;
  padding-left: 12px;
  gap: 8px;
}

.search-input-icon {
  width: 17px;
  height: 20px;
  flex-shrink: 0;
  object-fit: contain;
  opacity: 0.55;
}

.search-input {
  flex: 1;
  min-width: 0;
  border: none;
  padding: 0 12px 0 0;
  height: 100%;
  font-size: 14px;
  outline: none;
  background: transparent;
}

.search-input::placeholder {
  color: #999;
}

.search-tab {
  color: var(--color-text);
}

.search-tab.active {
  color: var(--color-primary);
  font-weight: 700;
}

.search-btn {
  flex: 0 0 122px;
  width: 122px;
  border: none;
  background: var(--color-search-btn);
  color: #fff;
  font-size: 16px;
  cursor: pointer;
  transition: background 0.2s;
}

.search-btn:hover {
  background: var(--color-primary-dark);
}

.brand-text h1 {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.brand-logo-fallback {
  width: 52px;
  height: 48px;
  background: linear-gradient(135deg, #ff9900 0%, #ff6600 100%);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 700;
  font-size: 16px;
  flex-shrink: 0;
}

.header-trust {
  display: flex;
  align-items: center;
  gap: 24px;
  flex: 0 0 auto;
  margin-left: auto;
  padding-left: 24px;
}

.trust-badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  min-width: 52px;
  font-size: 12px;
  color: var(--color-text);
  text-align: center;
  line-height: 1.2;
}

.trust-badge-icon {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--color-primary);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: 600;
  line-height: 1;
  flex-shrink: 0;
}

.trust-badge-icon svg {
  width: 20px;
  height: 20px;
  fill: #fff;
}

/* 主导航（与内容区 246px + 1fr 栅格对齐） */
.main-nav {
  background: #fff;
  padding: 10px 0 14px;
}

.main-nav-inner {
  display: grid;
  grid-template-columns: 246px 1fr;
  gap: 20px;
  align-items: center;
  min-height: 52px;
  padding: 0;
}

.main-nav-doc-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 48px;
  background: var(--color-primary);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  line-height: 1;
  border-radius: 4px;
  flex-shrink: 0;
}

.main-nav-doc-btn:hover {
  color: #fff;
  opacity: 0.92;
}

.main-nav-items {
  display: flex;
  align-items: flex-end;
  gap: 40px;
  min-width: 0;
  min-height: 44px;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding-bottom: 0;
}

.main-nav-items::-webkit-scrollbar {
  display: none;
  width: 0;
  height: 0;
}

.main-nav-item {
  display: inline-block;
  flex-shrink: 0;
  white-space: nowrap;
  color: var(--color-text);
  -webkit-tap-highlight-color: transparent;
}

.main-nav-item:active,
.main-nav-item:focus {
  outline: none;
}

.main-nav-text {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  gap: 3px;
  text-align: center;
  min-height: 42px;
  line-height: 1.2;
  vertical-align: bottom;
}

.main-nav-text-no-tag {
  padding-top: 18px;
  box-sizing: border-box;
}

.main-nav-tag {
  display: inline-block;
  padding: 1px 4px;
  background: #fff;
  font-size: 12px;
  line-height: 1.2;
  font-weight: 500;
  color: #ff0000;
  white-space: nowrap;
  text-align: center;
}

.main-nav-label {
  display: block;
  font-size: 16px;
  font-weight: 400;
  line-height: 1.2;
  color: #000;
  text-align: center;
}

.main-nav-item-prominent .main-nav-label,
.main-nav-item.active.main-nav-item-prominent .main-nav-label {
  font-weight: 700;
  font-size: 18px;
  line-height: 1.2;
}

.main-nav-item-shop .main-nav-label {
  font-weight: 700;
  font-size: 16px;
}

.main-nav-item.active:not(.main-nav-item-prominent) .main-nav-label {
  font-weight: 700;
}

.main-nav-item:hover .main-nav-label {
  color: var(--color-primary);
}

.main-nav-item:hover .main-nav-tag {
  color: #ff0000;
}

/* 兼容旧结构 */
.main-nav a:not(.main-nav-item) {
  font-size: 16px;
  white-space: nowrap;
  color: var(--color-text);
}

.main-nav a:not(.main-nav-item).active {
  font-weight: 700;
  font-size: 18px;
}

.main-nav a:not(.main-nav-item):hover {
  color: var(--color-primary);
}

/* 信任标识 */
.trust-bar {
  background: #fff;
  border-bottom: 1px solid var(--color-border);
}

.trust-bar-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 48px;
  padding: 8px 0 10px;
  flex-wrap: wrap;
}

.trust-item {
  font-size: 14px;
  color: var(--color-text);
}

.trust-item a {
  color: inherit;
}

.trust-item a:hover {
  color: var(--color-link);
}

/* 主内容区 */
.main-content {
  padding: 16px 0 40px;
}

.content-layout {
  display: grid;
  grid-template-columns: 246px 1fr;
  gap: 20px;
  align-items: start;
}

/* 首页：导航 + 侧栏左列一体 */
.home-page .main-content,
.main-content.home-page {
  padding-top: 12px;
}

.home-nav-row {
  display: grid;
  grid-template-columns: 246px 1fr;
  gap: 20px;
  align-items: center;
  min-height: 46px;
  margin-bottom: 12px;
}

.home-nav-row .main-nav-doc-btn {
  justify-self: start;
}

.home-body-layout {
  display: grid;
  grid-template-columns: 246px 1fr;
  gap: 20px;
  align-items: start;
}

.home-page .category-sidebar {
  border-radius: 4px;
  overflow: hidden;
}

/* 分类侧边栏 */
.category-sidebar {
  background: #fff;
  border: 1px solid #d9d9d9;
  border-radius: 4px;
  overflow: hidden;
}

.category-sidebar-head {
  background: var(--color-primary);
  color: #fff;
  text-align: center;
  font-size: 14px;
  font-weight: 600;
  line-height: 40px;
  padding: 0 12px;
}

.category-sidebar-list {
  background: #fff;
}

.category-item {
  padding: 14px 16px 12px;
  border-bottom: 1px solid #eee;
  cursor: pointer;
  transition: background 0.2s;
}

.category-item:last-child {
  border-bottom: none;
}

.category-item:hover,
.category-item.active {
  background: #fff8ee;
}

.category-item h3 {
  margin: 0 0 6px;
  font-size: 14px;
  font-weight: 650;
  color: var(--color-text);
  line-height: 1.3;
}

.category-item p {
  margin: 0;
  font-size: 12px;
  color: #666;
  line-height: 1.5;
}

.category-sidebar-foot {
  padding: 14px 16px 16px;
  text-align: center;
  border-top: 1px solid #eee;
  background: #fff;
}

.category-sidebar-foot a {
  font-size: 14px;
  color: var(--color-text);
}

.category-sidebar-foot a:hover {
  color: var(--color-link);
}

/* 右侧内容 */
.content-main {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* 推荐横幅 */
.banner {
  border-radius: 8px;
  overflow: hidden;
}

.banner-promo {
  position: relative;
  background: var(--color-primary);
  min-height: 305px;
}

.banner-promo-link {
  display: block;
  color: inherit;
  text-decoration: none;
}

.banner-promo-link:hover {
  opacity: 0.98;
}

.banner-promo-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 18% 30%, rgba(255, 255, 255, 0.12) 0, rgba(255, 255, 255, 0) 42%),
    radial-gradient(circle at 82% 68%, rgba(255, 255, 255, 0.1) 0, rgba(255, 255, 255, 0) 38%),
    radial-gradient(circle at 70% 20%, rgba(255, 255, 255, 0.08) 0, rgba(255, 255, 255, 0) 30%);
  pointer-events: none;
}

.banner-promo-inner {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 305px;
  padding: 40px 24px 48px;
  text-align: center;
}

.banner-promo-title {
  margin: 0 0 36px;
  color: #fff;
  font-size: 28px;
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: 0.5px;
}

.banner-promo-counter {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.banner-digit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 54px;
  background: #fff;
  border-radius: 6px;
  color: var(--color-primary);
  font-size: 34px;
  font-weight: 700;
  line-height: 1;
  font-family: Arial, "Helvetica Neue", sans-serif;
}

.banner-digit-comma {
  width: auto;
  min-width: 12px;
  background: transparent;
  color: #fff;
  font-size: 34px;
  font-weight: 700;
}

.banner-link {
  display: block;
  line-height: 0;
}

.banner-link:hover {
  opacity: 0.98;
}

.banner-img {
  width: 100%;
  height: 305px;
  display: block;
  object-fit: cover;
  object-position: center;
}

/* 区块标题 */
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.section-header-centered {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
}

.section-header-spacer {
  display: block;
}

.section-title {
  margin: 0;
  font-size: 20px;
  font-weight: 650;
  text-align: center;
}

.section-more {
  font-size: 14px;
  color: var(--color-text);
  justify-self: end;
}

.section-more:hover {
  color: var(--color-link);
}

/* 老师卡片 */
.teacher-section + .teacher-section {
  margin-top: 32px;
}

.teacher-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.teacher-card {
  border: 1px solid #797979;
  border-radius: 0;
  background: #fff;
  transition: box-shadow 0.2s, transform 0.2s;
}

.teacher-card-link {
  position: relative;
  display: block;
  padding: 18px 12px 14px;
  text-align: center;
  color: inherit;
  min-height: 229px;
}

.teacher-card:hover {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
  transform: translateY(-2px);
}

.teacher-auth-badge {
  position: absolute;
  top: 0;
  right: 0;
  width: 38px;
  padding: 8px 6px;
  background: var(--color-primary);
  color: #fff;
  font-size: 12px;
  line-height: 1.15;
  border-radius: 0 0 0 5px;
  writing-mode: vertical-rl;
  text-orientation: mixed;
  letter-spacing: 1px;
}

.teacher-card-empty .teacher-card-link {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.teacher-empty-label {
  margin: 12px 0 0;
  font-size: 14px;
  color: var(--color-text);
}

.teacher-avatar {
  width: 96px;
  height: 96px;
  margin: 0 auto 10px;
  border-radius: 50%;
  background: #f5f5f5;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.teacher-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.teacher-name-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-bottom: 6px;
}

.teacher-name {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
}

.teacher-degree {
  display: inline-block;
  padding: 1px 8px;
  border-radius: 5px;
  font-size: 12px;
  line-height: 1.5;
  background: var(--color-primary);
  color: #fff;
  flex-shrink: 0;
}

.teacher-school {
  margin: 0 0 4px;
  font-size: 14px;
  color: var(--color-text);
}

.teacher-subject {
  margin: 0;
  font-size: 14px;
  color: var(--color-text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: 0 4px;
}

/* 页脚 */
.site-footer {
  background: var(--color-bg-gray);
  border-top: 1px solid var(--color-border);
  margin-top: 20px;
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(4, max-content);
  justify-content: center;
  column-gap: 100px;
  row-gap: 24px;
  padding: 32px 0;
}

.footer-col {
  text-align: left;
}

.footer-col h4 {
  margin: 0 0 12px;
  font-size: 14px;
  font-weight: 600;
}

.footer-col ul li {
  margin-bottom: 8px;
}

.footer-col a {
  font-size: 13px;
  color: var(--color-text-light);
}

.footer-col a:hover {
  color: var(--color-link);
}

.footer-bottom {
  border-top: 1px solid var(--color-border);
  padding: 16px 0;
  text-align: center;
  font-size: 12px;
  color: var(--color-text-light);
}

.footer-bottom p {
  margin: 4px 0;
}

/* 响应式 */
@media (max-width: 1280px) {
  .main-nav-items {
    gap: 32px;
  }

  .brand-block {
    flex: 0 0 240px;
    width: 240px;
    min-width: 240px;
  }

  .search-area {
    max-width: 640px;
  }

  .header-trust {
    gap: 16px;
    padding-left: 16px;
  }

  .trust-badge {
    min-width: 48px;
  }

  .trust-badge-icon {
    width: 40px;
    height: 40px;
    font-size: 16px;
  }
}

@media (max-width: 1024px) {
  .header-main {
    flex-wrap: wrap;
    gap: 16px;
  }

  .brand-block {
    flex: 1 1 100%;
    width: auto;
    min-width: 0;
  }

  .search-area {
    flex: 1 1 100%;
    width: 100%;
    max-width: none;
  }

  .header-trust {
    flex: 1 1 100%;
    margin-left: 0;
    padding-left: 0;
    justify-content: center;
    gap: 12px;
  }

  .home-nav-row,
  .home-body-layout,
  .content-layout {
    grid-template-columns: 1fr;
  }

  .category-sidebar-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
  }

  .category-item {
    border-right: 1px solid #eee;
  }

  .teacher-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer-links {
    grid-template-columns: repeat(2, max-content);
    column-gap: 64px;
  }
}

@media (max-width: 768px) {
  .header-main {
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
    text-align: center;
  }

  .brand-block {
    justify-content: center;
  }

  .brand {
    justify-content: center;
  }

  .search-area {
    max-width: none;
    margin: 0;
  }

  .header-trust {
    justify-content: center;
    padding-bottom: 0;
  }

  .main-nav-inner {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .main-nav-doc-btn {
    border-radius: 4px;
  }

  .main-nav-items {
    gap: 20px;
  }

  .category-sidebar {
    margin-top: 0;
    border-top: 1px solid #d9d9d9;
    border-radius: 4px;
  }

  .teacher-grid {
    grid-template-columns: 1fr;
  }

  .category-sidebar-list {
    grid-template-columns: 1fr;
  }

  .banner-promo-title {
    font-size: 20px;
    margin-bottom: 24px;
  }

  .banner-digit {
    width: 36px;
    height: 44px;
    font-size: 26px;
  }

  .banner-digit-comma {
    font-size: 26px;
  }

  .banner-img {
    height: 200px;
  }

  .footer-links {
    grid-template-columns: max-content;
    justify-content: center;
  }
}

/* 城市选择弹层 */
body.city-picker-open {
  overflow: hidden;
}

.city-picker-overlay {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: rgba(0, 0, 0, 0.35);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 80px 16px 24px;
  overflow-y: auto;
}

.city-picker-overlay[hidden] {
  display: none;
}

.city-picker-panel {
  position: relative;
  width: 100%;
  max-width: var(--container-width);
  background: #fff;
  border: 1px solid var(--color-border);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
  padding: 24px 28px 28px;
}

.city-picker-close {
  position: absolute;
  top: 12px;
  right: 16px;
  width: 32px;
  height: 32px;
  border: none;
  background: transparent;
  font-size: 24px;
  line-height: 1;
  color: #999;
  cursor: pointer;
}

.city-picker-close:hover {
  color: var(--color-text);
}

.city-picker-section {
  margin-bottom: 20px;
}

.city-picker-hot {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  padding-bottom: 16px;
  border-bottom: 1px solid #eee;
}

.city-picker-label-hot {
  color: #c81623;
  font-size: 14px;
  font-weight: 600;
  flex-shrink: 0;
}

.city-picker-hot-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
}

.city-picker-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
  padding: 16px 0;
  border-bottom: 1px solid #eee;
  margin-bottom: 20px;
}

.city-picker-select-group,
.city-picker-search-group {
  display: flex;
  align-items: center;
  gap: 12px;
}

.city-picker-toolbar-label {
  font-size: 14px;
  color: var(--color-text);
  white-space: nowrap;
}

.city-picker-select {
  height: 32px;
  min-width: 120px;
  padding: 0 8px;
  border: 1px solid #ccc;
  border-radius: 2px;
  font-size: 14px;
  color: #666;
  background: #fff;
}

.city-picker-search-input {
  width: 220px;
  height: 32px;
  padding: 0 10px;
  border: 1px solid #ccc;
  border-radius: 2px;
  font-size: 14px;
}

.city-picker-alpha-title {
  font-size: 14px;
  color: var(--color-text);
  margin-bottom: 16px;
}

.city-picker-alpha-list {
  max-height: 420px;
  overflow-y: auto;
}

.city-picker-letter-group {
  display: flex;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid #f0f0f0;
}

.city-picker-letter-group:last-child {
  border-bottom: none;
}

.city-picker-letter-group.is-hidden {
  display: none;
}

.city-picker-letter {
  flex: 0 0 36px;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f5f5f5;
  color: #666;
  font-size: 16px;
  font-weight: 600;
}

.city-picker-letter-content {
  flex: 1;
  min-width: 0;
}

.city-picker-province-block {
  margin-bottom: 16px;
}

.city-picker-province-block:last-child {
  margin-bottom: 0;
}

.city-picker-province-block.is-hidden {
  display: none;
}

.city-picker-province-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 10px;
}

.city-picker-city-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
}

.city-picker-city {
  border: none;
  background: transparent;
  padding: 0;
  font-size: 14px;
  color: #666;
  cursor: pointer;
  line-height: 1.6;
}

.city-picker-city:hover,
.city-picker-city.active {
  color: var(--color-primary);
}

.city-picker-city.is-hidden {
  display: none;
}

@media (max-width: 768px) {
  .city-picker-overlay {
    padding: 60px 8px 16px;
  }

  .city-picker-panel {
    padding: 20px 16px;
  }

  .city-picker-toolbar {
    flex-direction: column;
    align-items: stretch;
  }

  .city-picker-select-group,
  .city-picker-search-group {
    flex-wrap: wrap;
  }

  .city-picker-search-input {
    width: 100%;
    flex: 1;
  }

  .city-picker-letter-group {
    flex-direction: column;
    gap: 8px;
  }
}

/* 登录注册浮窗 */
body.auth-modal-open {
  overflow: hidden;
}

.auth-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 10001;
  background: rgba(0, 0, 0, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
}

.auth-modal-overlay[hidden] {
  display: none;
}

.auth-modal-wrap {
  display: flex;
  width: 100%;
  max-width: 900px;
  min-height: 420px;
  background: #d7d7d7;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.18);
}

.auth-modal-promo {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 40px 48px;
  min-width: 0;
}

.auth-modal-logo {
  width: 64px;
  height: 64px;
  margin-bottom: 20px;
  border-radius: 8px;
}

.auth-modal-welcome {
  margin: 0 0 12px;
  font-size: 22px;
  font-weight: 500;
  line-height: 1.4;
}

.auth-modal-brand {
  color: #d9001b;
  font-weight: 700;
}

.auth-modal-slogan {
  margin: 0;
  font-size: 16px;
  font-weight: 500;
  color: var(--color-text);
}

.auth-modal-panel {
  position: relative;
  width: 361px;
  flex-shrink: 0;
  background: #fff;
  border: 1px solid #797979;
  padding: 28px 24px 32px;
  display: flex;
  flex-direction: column;
}

.auth-modal-close {
  position: absolute;
  top: 8px;
  right: 12px;
  width: 32px;
  height: 32px;
  border: none;
  background: transparent;
  font-size: 24px;
  line-height: 1;
  color: #999;
  cursor: pointer;
}

.auth-modal-close:hover {
  color: var(--color-text);
}

.auth-modal-head {
  margin-bottom: 8px;
}

.auth-modal-main-tabs {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  font-size: 14px;
}

.auth-main-tab {
  border: none;
  background: none;
  padding: 0;
  font: inherit;
  color: var(--color-text-light);
  cursor: pointer;
}

.auth-main-tab.active {
  color: var(--color-text);
  font-weight: 600;
}

.auth-main-divider {
  color: #ccc;
  user-select: none;
}

.auth-modal-sub-tabs {
  display: flex;
  gap: 28px;
  margin-bottom: 4px;
}

.auth-modal-sub-tabs[hidden] {
  display: none;
}

.auth-sub-tab {
  border: none;
  background: none;
  padding: 0 0 6px;
  font: inherit;
  font-size: 18px;
  font-weight: 500;
  color: var(--color-text-light);
  cursor: pointer;
  border-bottom: 2px solid transparent;
}

.auth-sub-tab.active {
  color: var(--color-text);
  border-bottom-color: var(--color-text);
}

.auth-modal-body {
  flex: 1;
}

.auth-form-mode[hidden] {
  display: none;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.auth-register-title {
  margin: 0 0 4px;
  font-size: 18px;
  font-weight: 500;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--color-text);
  display: inline-block;
}

.auth-input {
  width: 100%;
  height: 44px;
  padding: 0 20px;
  border: 1px solid #e0e0e0;
  border-radius: 22px;
  font-size: 14px;
  font-family: inherit;
  background: #fff;
  outline: none;
  transition: border-color 0.2s;
}

.auth-input:focus {
  border-color: var(--color-primary);
}

.auth-input::placeholder {
  color: #999;
}

.auth-code-row {
  display: flex;
  gap: 10px;
  align-items: center;
}

.auth-input-code {
  flex: 1;
  min-width: 0;
}

.auth-code-btn {
  flex-shrink: 0;
  border: none;
  background: none;
  padding: 0 4px;
  font-size: 13px;
  color: var(--color-link);
  cursor: pointer;
  white-space: nowrap;
}

.auth-code-btn:hover {
  text-decoration: underline;
}

.auth-submit {
  width: 100%;
  height: 44px;
  margin-top: 6px;
  border: none;
  border-radius: 22px;
  background: #f2f2f2;
  color: #333;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s;
}

.auth-submit:hover {
  background: #e8e8e8;
}

.auth-form-foot {
  display: flex;
  justify-content: flex-end;
  margin-top: 2px;
}

.auth-form-foot-left {
  justify-content: flex-start;
}

.auth-switch-link {
  font-size: 14px;
  color: var(--color-text);
}

.auth-switch-link:hover {
  color: var(--color-link);
}

@media (max-width: 768px) {
  .auth-modal-wrap {
    flex-direction: column;
    min-height: auto;
  }

  .auth-modal-promo {
    padding: 24px 20px 16px;
  }

  .auth-modal-panel {
    width: 100%;
    border-left: none;
    border-top: 1px solid #797979;
  }
}
