/* ============================================================
   A1tox — 联系销售页（/contact-sales/）
   复刻 openai.com/contact-sales 的版式：极淡薰衣草渐变首屏 +
   12 栏网格左文右卡（左 1–5、右 6–11）+ 单行页脚。基础层沿用 dna-tokens / dna-components，
   本文件只写本页组件（cs- 前缀），不改动全站样式。
   ============================================================ */

/* ---------- 0. 页底与渐变底 ---------- */
.cs-page {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100svh;
  background: #fff;
}

/* 首屏渐变：水平方向冷蓝 → 暖粉 → 淡紫（取目标页顶行实测色），
   垂直方向 320px 内淡出到纯白 */
.cs-page::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  z-index: 0;
  height: 320px;
  pointer-events: none;
  background: linear-gradient(
    90deg,
    #ccd4f1 0%,
    #cdceeb 21%,
    #dccee2 42%,
    #ead2d7 53%,
    #ebd4d8 62%,
    #e3dce8 83%,
    #dadaeb 100%
  );
  -webkit-mask-image: linear-gradient(180deg, #000 0%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 0%, transparent 100%);
}

/* ---------- 1. 顶栏：只留品牌位（对齐目标页的极简头部） ---------- */
.cs-header {
  position: relative;
  z-index: 1;
  padding-block: 18px;
}
.cs-header__inner {
  display: flex;
  align-items: center;
  gap: 16px;
}

/* ---------- 2. 主分栏：12 栏网格，左 1–5、右 6–11 ---------- */
.cs-main {
  position: relative;
  z-index: 1;
  flex: 1 0 auto;
  padding-top: clamp(48px, 6.4vw, 91px);
  padding-bottom: clamp(72px, 8vw, 120px);
}
.cs-layout {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 24px;
  align-items: start;
}
.cs-pitch { grid-column: 1 / 6; }
.cs-form-col { grid-column: 6 / 12; }

/* ---------- 3. 左栏 ---------- */
.cs-title {
  font-size: clamp(2.25rem, 4.45vw, 4rem);
  line-height: 1.04;
  letter-spacing: -0.022em;
  font-weight: 500;
  text-wrap: balance;
}
.cs-sub {
  margin-top: clamp(16px, 1.6vw, 20px);
  max-width: 24rem;
  font-size: clamp(1.0625rem, 1.35vw, 1.1875rem);
  line-height: 1.6;
  letter-spacing: -0.01em;
  color: var(--fg);
}

.cs-features { margin-top: clamp(36px, 3.8vw, 56px); }
.cs-label {
  font-size: 0.875rem;
  line-height: 1.5;
  color: var(--fg-44);
}
.cs-list {
  margin-top: 10px;
  display: grid;
  gap: 8px;
}
.cs-list li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 1rem;
  line-height: 1.5;
  letter-spacing: -0.01em;
}
.cs-list svg {
  flex: none;
  width: 20px;
  height: 20px;
  margin-top: 1px;
  color: var(--fg);
}

.cs-trust { margin-top: clamp(32px, 3.2vw, 46px); }
/* 信任标识：复用全站 logo-swap 翻牌组件（同 /fde/ 页），本页固定 3 个一排 */
.logo-swap--3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 44px;
}

/* ---------- 4. 表单卡：全站少数带明显阴影的浮层 ---------- */
.cs-card {
  position: relative;
  min-height: 284px;
  padding: 28px;
  border-radius: 16px;
  background: #fff;
  box-shadow:
    0 24px 60px rgba(17, 17, 17, 0.12),
    0 2px 8px rgba(17, 17, 17, 0.04);
}

.cs-form__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
}
.cs-form__title {
  font-size: clamp(1.375rem, 1.8vw, 1.625rem);
  line-height: 1.2;
  letter-spacing: -0.02em;
  font-weight: 500;
}
.cs-form__step {
  flex: none;
  font-size: 0.875rem;
  color: var(--fg);
}
.cs-form__step[hidden] { display: none; }

.cs-step[hidden] { display: none; }
.cs-step,
.cs-success { animation: cs-step-in 0.28s var(--ease-primary) both; }

@keyframes cs-step-in {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: none; }
}

.cs-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 18px;
}
.cs-field:last-of-type { margin-bottom: 0; }
.cs-label {
  font-size: 0.875rem;
  line-height: 1.4;
}
.cs-field > .cs-label { color: var(--fg-60); }
.cs-req { color: var(--fg-44); }

.cs-input,
.cs-select,
.cs-textarea {
  width: 100%;
  padding: 9px 12px;
  border: 1px solid rgba(0, 0, 0, 0.15);
  border-radius: 8px;
  background: #fff;
  color: var(--fg);
  font: inherit;
  font-size: 1rem;
  line-height: 1.45;
  transition:
    border-color var(--dur-short) var(--ease-primary),
    box-shadow var(--dur-short) var(--ease-primary);
}
.cs-input { height: 42px; }
.cs-select {
  height: 42px;
  padding-right: 36px;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none'%3E%3Cpath d='M2.5 4.5 6 8l3.5-3.5' stroke='%23111' stroke-width='1.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 13px center;
  background-size: 12px;
}
.cs-select:invalid { color: var(--fg-60); }
.cs-textarea {
  min-height: 100px;
  resize: vertical;
}
.cs-input::placeholder,
.cs-textarea::placeholder { color: var(--fg-60); }
.cs-input:focus,
.cs-select:focus,
.cs-textarea:focus {
  outline: none;
  border-color: var(--fg);
  box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.06);
}
.cs-input[aria-invalid="true"],
.cs-select[aria-invalid="true"] {
  border-color: var(--error);
}

.cs-error {
  margin: 0;
  font-size: 0.8125rem;
  line-height: 1.4;
  color: var(--error);
}
.cs-error[hidden] { display: none; }

.cs-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 26px;
}
.cs-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 40px;
  padding: 0 20px;
  border: 0;
  border-radius: var(--radius-full);
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: -0.005em;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color var(--dur-short) var(--ease-primary);
}
.cs-btn--primary { background: var(--fg); color: #fff; }
.cs-btn--primary:hover:not(:disabled) { background: #1f1f1f; }
.cs-btn--primary:disabled {
  background: #f1f1f1;
  color: rgba(0, 0, 0, 0.5);
  cursor: not-allowed;
}
.cs-btn:active:not(:disabled) { transform: translateY(1px); }

.cs-back {
  height: 40px;
  margin-right: auto;
  padding: 0 4px;
  border: 0;
  background: none;
  font-family: inherit;
  font-size: 0.875rem;
  color: var(--fg-60);
  cursor: pointer;
}
.cs-back:hover { color: var(--fg); text-decoration: underline; text-underline-offset: 3px; }

/* ---------- 5. 提交成功态 ---------- */
.cs-success {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding-block: 6px;
}
.cs-success[hidden] { display: none; }
.cs-success:focus,
.cs-success:focus-visible { outline: none; }
.cs-success__icon {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #f1f1f1;
}
.cs-success__text {
  font-size: 1.0625rem;
  line-height: 1.6;
  letter-spacing: -0.01em;
  text-wrap: pretty;
}

/* ---------- 6. 卡下辅助说明 ---------- */
.cs-help {
  margin-top: 50px;
  text-align: center;
  font-size: 0.875rem;
  line-height: 1.6;
  color: var(--fg-60);
}
.cs-noscript {
  margin-top: 18px;
  font-size: 0.875rem;
  line-height: 1.6;
  color: var(--fg-60);
}
.cs-noscript a { color: var(--fg); text-decoration: underline; text-underline-offset: 3px; }
.cs-help a {
  color: var(--fg);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.cs-help a:hover { color: var(--fg); }

/* ---------- 7. 单行页脚 ---------- */
.cs-footer {
  position: relative;
  z-index: 1;
  padding-block: 24px 36px;
}
.cs-footer__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 32px;
  font-size: 0.875rem;
  color: var(--fg-60);
}
.cs-footer__links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  margin-inline: auto;
}
.cs-footer__links a { color: var(--fg-60); }
.cs-footer__links a:hover { color: var(--fg); text-decoration: underline; text-underline-offset: 3px; }

/* ---------- 8. 响应式 ---------- */
@media (max-width: 1120px) {
  .logo-swap--3 { gap: 14px 20px; }
}

@media (max-width: 900px) {
  .cs-layout { grid-template-columns: minmax(0, 1fr); gap: 40px; }
  .cs-pitch,
  .cs-form-col { grid-column: 1 / -1; }
  .cs-title__br { display: none; }
  .cs-sub { max-width: 34rem; }
  .cs-form-col { max-width: 640px; }
  .cs-help { text-align: left; }
}

@media (max-width: 768px) {
  .cs-page::before { height: 520px; }
  .cs-header { padding-block: 14px; }
  .cs-main { padding-top: 36px; }
  .cs-card { padding: 22px; min-height: 0; }
  .logo-swap--3 { gap: 12px 14px; }
  .cs-actions { margin-top: 22px; }
  .cs-footer__links { margin-inline: 0; }
  .cs-footer__inner { gap: 14px 20px; }
}

@media (prefers-reduced-motion: reduce) {
  .cs-step,
  .cs-success { animation: none !important; }
}
