/* ============================================================
   同趣见 · 公共样式表
   ============================================================ */

/* ---------- 全局重置 & 变量 ---------- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --brand-primary: #7550bd;
  --brand-primary-dark: #5e3fa0;
  --brand-secondary: #ff8c42;
  --brand-gradient: linear-gradient(135deg, #ff8c42 0%, #7550bd 100%);
  --brand-accent: #f3ebfd;
  --neutral-50: #f8fafc;
  --neutral-100: #f1f5f9;
  --neutral-200: #e2e8f0;
  --neutral-600: #475569;
  --neutral-800: #1e293b;
  --neutral-900: #0f172a;
  --radius-md: 16px;
  --radius-sm: 10px;
  --shadow-sm: 0 4px 12px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 12px 32px rgba(0, 0, 0, 0.06);
  --font-sans: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;
  --content-max: 1280px;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  background-color: #ffffff;
  color: var(--neutral-800);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, svg {
  max-width: 100%;
  height: auto;
}

/* <picture> 不生成盒子，替换 WebP 后布局与原 <img> 完全一致 */
picture {
  display: contents;
}

/* ---------- 全屏宽度布局 ---------- */
.full-width {
  width: 100%;
}

.container {
  width: 100%;
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 0 24px;
}

@media (min-width: 768px) {
  .container {
    padding: 0 40px;
  }
}

@media (min-width: 1440px) {
  .container {
    max-width: 1400px;
    padding: 0 48px;
  }
}

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 9px 18px;
  border-radius: 100px;
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
  transition: all 0.2s ease;
  white-space: nowrap;
  border: 1px solid transparent;
  cursor: pointer;
}

@media (min-width: 768px) {
  .btn {
    padding: 10px 22px;
    font-size: 0.95rem;
  }
}

.btn-outline {
  border-color: var(--neutral-200);
  background: transparent;
  color: var(--neutral-800);
}

.btn-outline:hover {
  border-color: var(--brand-primary);
  color: var(--brand-primary);
}

.btn-primary {
  background: var(--brand-gradient);
  color: white;
  box-shadow: 0 6px 16px rgba(117, 80, 189, 0.3);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #e87d33 0%, var(--brand-primary-dark) 100%);
}

.btn-lg {
  padding: 12px 28px;
  font-size: 1rem;
}

@media (min-width: 768px) {
  .btn-lg {
    padding: 14px 36px;
    font-size: 1.05rem;
  }
}

/* ---------- 导航栏 ---------- */
.navbar-wrapper {
  width: 100%;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--neutral-200);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 0;
  gap: 12px;
  position: relative;
}

@media (min-width: 768px) {
  .navbar {
    padding: 16px 0;
    gap: 24px;
  }
}

/* Logo 图片 */
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  text-decoration: none;
  z-index: 1001;
}

.logo img {
  height: 32px;
  width: auto;
  display: block;
}

@media (min-width: 768px) {
  .logo img {
    height: 38px;
  }
}

.logo-text {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--neutral-900);
}

@media (min-width: 768px) {
  .logo-text {
    font-size: 1.45rem;
  }
}

/* 桌面端导航链接 */
.nav-links {
  display: none;
  gap: 28px;
  align-items: center;
  flex-wrap: wrap;
}

@media (min-width: 900px) {
  .nav-links {
    display: flex;
  }
}

.nav-links a {
  text-decoration: none;
  color: var(--neutral-600);
  font-weight: 500;
  font-size: 0.95rem;
  transition: color 0.2s ease;
  white-space: nowrap;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--brand-primary);
}

/* 右侧操作区 */
.nav-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-shrink: 0;
}

.nav-actions .btn-outline {
  display: none;
}

@media (min-width: 480px) {
  .nav-actions .btn-outline {
    display: inline-flex;
  }
}

/* ---------- 汉堡菜单按钮 ---------- */
.hamburger {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: transparent;
  border: 1px solid var(--neutral-200);
  border-radius: 10px;
  cursor: pointer;
  padding: 0;
  flex-shrink: 0;
  transition: border-color 0.2s;
  z-index: 1001;
}

.hamburger:hover {
  border-color: var(--brand-primary);
}

.hamburger span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--neutral-800);
  border-radius: 2px;
  transition: all 0.3s ease;
}

/* 展开状态：变成 X */
.hamburger.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.hamburger.open span:nth-child(2) {
  opacity: 0;
}

.hamburger.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

@media (min-width: 900px) {
  .hamburger {
    display: none;
  }
}

/* ---------- 移动端抽屉菜单 ---------- */
.mobile-menu {
  position: fixed;
  top: 0;
  right: 0;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transform: translateX(100%);
  transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 999;
  display: flex;
  flex-direction: column;
  padding: 80px 32px 40px;
  overflow-y: auto;
}

.mobile-menu.open {
  transform: translateX(0);
}

@media (min-width: 900px) {
  .mobile-menu {
    display: none;
  }
}

.mobile-menu-links {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.mobile-menu-links a {
  text-decoration: none;
  color: var(--neutral-800);
  font-size: 1.2rem;
  font-weight: 600;
  padding: 14px 0;
  border-bottom: 1px solid var(--neutral-100);
  transition: color 0.2s;
}

.mobile-menu-links a:hover,
.mobile-menu-links a.active {
  color: var(--brand-primary);
}

.mobile-menu-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 32px;
}

.mobile-menu-actions .btn {
  width: 100%;
  padding: 14px 20px;
  font-size: 1rem;
}

/* 菜单遮罩层 */
.menu-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.4);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s, visibility 0.3s;
  z-index: 998;
}

.menu-overlay.open {
  opacity: 1;
  visibility: visible;
}

@media (min-width: 900px) {
  .menu-overlay {
    display: none;
  }
}

/* ---------- 通用区块 ---------- */
.section-wrapper {
  width: 100%;
  padding: 56px 0;
}

@media (min-width: 768px) {
  .section-wrapper {
    padding: 80px 0;
  }
}

.section-wrapper.alt-bg {
  background: var(--neutral-50);
}

.section-title {
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--neutral-900);
  margin-bottom: 8px;
}

@media (min-width: 768px) {
  .section-title {
    font-size: 2rem;
    margin-bottom: 12px;
  }
}

.section-sub {
  font-size: 0.95rem;
  color: var(--neutral-600);
  max-width: 640px;
  margin-bottom: 28px;
}

@media (min-width: 768px) {
  .section-sub {
    font-size: 1.1rem;
    margin-bottom: 48px;
  }
}

/* ---------- CTA 区块 ---------- */
.cta-wrapper {
  width: 100%;
  background: linear-gradient(135deg, var(--neutral-900) 0%, #1e2a3a 100%);
  padding: 56px 0;
}

@media (min-width: 768px) {
  .cta-wrapper {
    padding: 80px 0;
  }
}

.cta-section {
  text-align: center;
  color: white;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

@media (min-width: 768px) {
  .cta-section {
    gap: 24px;
  }
}

.cta-section h2 {
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  max-width: 700px;
}

@media (min-width: 768px) {
  .cta-section h2 {
    font-size: 2.2rem;
  }
}

.cta-section p {
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.95rem;
  max-width: 600px;
}

@media (min-width: 768px) {
  .cta-section p {
    font-size: 1.1rem;
  }
}

.cta-section .btn-primary {
  background: white;
  color: var(--neutral-900);
  box-shadow: none;
}

.cta-section .btn-primary:hover {
  background: var(--neutral-100);
}

/* 深色 CTA 底上的描边按钮 */
.cta-section .btn-outline {
  border-color: rgba(255, 255, 255, 0.32);
  color: #fff;
}

.cta-section .btn-outline:hover {
  border-color: #fff;
  color: #fff;
  background: rgba(255, 255, 255, 0.06);
}

/* ---------- 页脚 ---------- */
.footer-wrapper {
  width: 100%;
  background: #ffffff;
  border-top: 1px solid var(--neutral-200);
  padding: 32px 0 28px;
}

@media (min-width: 768px) {
  .footer-wrapper {
    padding: 48px 0 32px;
  }
}

.footer {
  display: flex;
  flex-direction: column;
  gap: 20px;
  color: var(--neutral-600);
  font-size: 0.85rem;
}

@media (min-width: 768px) {
  .footer {
    flex-direction: row;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 40px;
    font-size: 0.95rem;
  }
}

.footer-links {
  display: flex;
  gap: 16px 24px;
  flex-wrap: wrap;
}

.footer-links a {
  text-decoration: none;
  color: var(--neutral-600);
  transition: color 0.2s ease;
}

.footer-links a:hover {
  color: var(--brand-primary);
}

/* 页脚当前页高亮（由 js/layout.js 自动标记） */
.footer-links a.is-current {
  color: var(--brand-primary);
  font-weight: 600;
}

/* 页脚备案号 */
.footer-icp {
  width: 100%;
  font-size: 0.78rem;
  color: var(--neutral-600);
  opacity: 0.8;
}

@media (min-width: 768px) {
  .footer-icp {
    font-size: 0.82rem;
  }
}

/* ---------- 品牌渐变背景 ---------- */
.brand-gradient-bg {
  background: var(--brand-gradient);
}

/* ---------- 手机截图展示（产品预览） ---------- */
.phone-frame {
  background: #fff;
  border: 5px solid var(--neutral-900);
  border-radius: 26px;
  overflow: hidden;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.16);
  line-height: 0;
  flex-shrink: 0;
}

.phone-frame img {
  width: 100%;
  height: auto;
  display: block;
}

/* 横向滑动的截图列表（所有屏幕均可左右滑动，不换行） */
.shots-scroller {
  position: relative;
}

.shots-row {
  display: flex;
  gap: 18px;
  overflow-x: auto;
  overflow-y: hidden;
  padding: 28px 4px 16px;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}

.shots-row .phone-frame {
  width: 190px;
  scroll-snap-align: center;
}

@media (min-width: 540px) {
  .shots-row { gap: 22px; }
  .shots-row .phone-frame { width: 220px; }
}

@media (min-width: 900px) {
  .shots-row { padding: 28px 0 16px; gap: 26px; }
  .shots-row .phone-frame { width: 246px; transition: transform 0.25s ease; }
  .shots-row .phone-frame:hover { transform: translateY(-6px); }
}

.shots-row::-webkit-scrollbar {
  height: 6px;
}

.shots-row::-webkit-scrollbar-track {
  background: transparent;
}

.shots-row::-webkit-scrollbar-thumb {
  background: var(--neutral-200);
  border-radius: 3px;
}

.shots-row::-webkit-scrollbar-thumb:hover {
  background: #cfc4e6;
}

/* 左右滑动按钮 */
.shots-nav {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin-top: 2px;
}

@media (min-width: 900px) {
  .shots-nav { justify-content: flex-end; }
}

.shots-nav button {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid var(--neutral-200);
  background: #fff;
  color: var(--neutral-800);
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  -webkit-tap-highlight-color: transparent;
}

.shots-nav button:hover:not(:disabled) {
  border-color: var(--brand-primary);
  color: var(--brand-primary);
  box-shadow: var(--shadow-sm);
}

.shots-nav button:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

/* ---------- 小程序码卡片 ---------- */
.qr-card {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  background: #fff;
  border: 1px solid var(--neutral-200);
  border-radius: var(--radius-md);
  padding: 20px 22px;
  box-shadow: var(--shadow-sm);
  text-align: center;
}

.qr-card img {
  width: 132px;
  height: 132px;
  object-fit: contain;
  border-radius: 8px;
}

@media (min-width: 768px) {
  .qr-card img {
    width: 160px;
    height: 160px;
  }
}

.qr-card .qr-title {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--neutral-900);
}

.qr-card .qr-desc {
  font-size: 0.8rem;
  color: var(--neutral-600);
}

/* ---------- 页面级 Hero（内页通用） ---------- */
.page-hero {
  width: 100%;
  padding: 56px 0 48px;
}

@media (min-width: 768px) {
  .page-hero {
    padding: 80px 0 64px;
  }
}

.page-hero h1 {
  font-size: clamp(1.8rem, 6vw, 2.8rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--neutral-900);
  margin-bottom: 12px;
}

.page-hero p {
  font-size: 1rem;
  color: var(--neutral-600);
  max-width: 720px;
}

@media (min-width: 768px) {
  .page-hero p {
    font-size: 1.15rem;
  }
}

.page-hero.dark {
  background: linear-gradient(135deg, #0f172a 0%, #1e2a3a 100%);
  color: #fff;
}

.page-hero.dark h1,
.page-hero.dark p {
  color: #fff;
}

.page-hero.dark p {
  color: rgba(255, 255, 255, 0.8);
}

.page-hero.dark .btn-primary {
  background: #fff;
  color: var(--neutral-900);
  box-shadow: none;
}

.page-hero.dark .btn-primary:hover {
  background: var(--neutral-100);
}

.page-hero.dark .btn-outline {
  border-color: rgba(255, 255, 255, 0.3);
  color: #fff;
}

.page-hero.dark .btn-outline:hover {
  border-color: #fff;
  color: #fff;
}

.page-hero.blue {
  background: linear-gradient(135deg, #f6f0fc 0%, #fdeee2 100%);
}

/* ============================================================
   通用表单控件（申请表单 / 留言表单等，任意页面可直接复用）
   用法见 apply.html：.form-card > form > .form-grid > .form-item
   ============================================================ */
.form-card {
  background: #fff;
  border: 1px solid var(--neutral-200);
  border-radius: var(--radius-md);
  padding: 22px 18px;
  box-shadow: var(--shadow-sm);
}

@media (min-width: 768px) {
  .form-card { padding: 36px 34px; }
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
}

@media (min-width: 640px) {
  .form-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px 22px;
  }
}

.form-item { min-width: 0; }
.form-item.full { grid-column: 1 / -1; }

.form-label {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--neutral-800);
  margin-bottom: 8px;
}

.form-label .req {
  color: #e2574c;
  margin-left: 3px;
}

.form-label .opt {
  font-weight: 400;
  font-size: 0.78rem;
  color: var(--neutral-600);
  margin-left: 6px;
}

.form-control {
  width: 100%;
  padding: 12px 14px;
  font-size: 1rem;
  font-family: inherit;
  line-height: 1.5;
  color: var(--neutral-900);
  background: #fff;
  border: 1px solid var(--neutral-200);
  border-radius: var(--radius-sm);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  -webkit-appearance: none;
  appearance: none;
}

@media (min-width: 768px) {
  .form-control { font-size: 0.95rem; }
}

.form-control::placeholder { color: #9aa7b8; }

.form-control:focus {
  outline: none;
  border-color: var(--brand-primary);
  box-shadow: 0 0 0 3px rgba(117, 80, 189, 0.12);
}

.form-control:disabled {
  background: var(--neutral-50);
  cursor: not-allowed;
}

textarea.form-control {
  min-height: 116px;
  resize: vertical;
  line-height: 1.65;
}

select.form-control {
  padding-right: 40px;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9'%3E%3Cpath fill='none' stroke='%23475569' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round' d='M1 1.5 7 7.5 13 1.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  cursor: pointer;
}

select.form-control::-ms-expand { display: none; }

.form-tip {
  font-size: 0.78rem;
  color: var(--neutral-600);
  line-height: 1.55;
  margin-top: 6px;
}

.form-error {
  display: none;
  font-size: 0.78rem;
  color: #e2574c;
  line-height: 1.5;
  margin-top: 6px;
}

.form-item.has-error .form-control { border-color: #e2574c; }
.form-item.has-error .form-error { display: block; }

/* 勾选行 */
.form-check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.85rem;
  color: var(--neutral-600);
  line-height: 1.6;
  cursor: pointer;
}

.form-check input {
  width: 18px;
  height: 18px;
  margin-top: 2px;
  flex-shrink: 0;
  accent-color: var(--brand-primary);
  cursor: pointer;
}

.form-check a {
  color: var(--brand-primary);
  text-decoration: none;
}

.form-check a:hover { text-decoration: underline; }

/* 提交区 */
.form-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 26px;
}

.form-actions .btn { min-width: 170px; }

.form-actions .btn[disabled] {
  opacity: 0.6;
  cursor: not-allowed;
  box-shadow: none;
}

.form-hint {
  font-size: 0.8rem;
  color: var(--neutral-600);
  line-height: 1.55;
}

/* 提交结果提示条 */
.form-alert {
  display: none;
  border-radius: var(--radius-sm);
  padding: 14px 18px;
  font-size: 0.88rem;
  line-height: 1.65;
  margin-bottom: 22px;
}

.form-alert.show { display: block; }
.form-alert.ok { background: #f0fbf4; border: 1px solid #b7e4c7; color: #1a6f3e; }
.form-alert.err { background: #fff6f5; border: 1px solid #f5c2be; color: #b3382e; }
.form-alert.warn { background: #fffaf0; border: 1px solid #f2ddb0; color: #8a6116; }
.form-alert strong { font-weight: 700; }

/* 申请类型选择卡（label 包 input[type=radio]） */
.type-picker {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

@media (min-width: 900px) {
  .type-picker { grid-template-columns: repeat(4, 1fr); gap: 16px; }
}

.type-option {
  position: relative;
  display: block;
  padding: 16px 14px;
  background: #fff;
  border: 1px solid var(--neutral-200);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.2s ease;
}

@media (min-width: 900px) {
  .type-option { padding: 18px 16px; }
}

.type-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.type-option:hover { border-color: #cfc4e6; }

.type-option .t-icon {
  font-size: 1.35rem;
  line-height: 1;
  display: block;
  margin-bottom: 8px;
}

.type-option .t-name {
  display: block;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--neutral-900);
}

.type-option .t-desc {
  display: block;
  font-size: 0.78rem;
  color: var(--neutral-600);
  line-height: 1.5;
  margin-top: 4px;
}

.type-option.is-active,
.type-option:has(input:checked) {
  border-color: var(--brand-primary);
  background: #fdfbff;
  box-shadow: 0 0 0 3px rgba(117, 80, 189, 0.1);
}

.type-option.is-active .t-name { color: var(--brand-primary); }

/* 提交成功面板 */
.form-success {
  display: none;
  text-align: center;
  padding: 12px 4px 4px;
}

.form-success.show { display: block; }

.form-success .fs-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 18px;
  border-radius: 50%;
  background: linear-gradient(135deg, #ff8c42 0%, #7550bd 100%);
  color: #fff;
  font-size: 1.8rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.form-success h3 {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--neutral-900);
  margin-bottom: 10px;
}

.form-success p {
  font-size: 0.92rem;
  color: var(--neutral-600);
  line-height: 1.7;
  max-width: 480px;
  margin: 0 auto 8px;
}

.form-success .fs-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  margin-top: 22px;
}

/* 侧边信息小卡 */
.side-card {
  background: #fff;
  border: 1px solid var(--neutral-200);
  border-radius: var(--radius-md);
  padding: 22px 20px;
  box-shadow: var(--shadow-sm);
}

@media (min-width: 768px) {
  .side-card { padding: 26px 24px; }
}

.side-card h3 {
  font-size: 1.02rem;
  font-weight: 700;
  color: var(--neutral-900);
  margin-bottom: 14px;
}

.side-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.side-list li {
  display: flex;
  gap: 10px;
  font-size: 0.88rem;
  color: var(--neutral-600);
  line-height: 1.6;
}

.side-list li .sl-ico { flex-shrink: 0; }

.side-list li strong { color: var(--neutral-800); font-weight: 600; }