/* FOCUSDESIGN — AI 工具门户选择页（一屏无滚动） */
:root,
html[data-theme="dark"] {
  --at-bg: #060608;
  --at-bg-elevated: #0e0e12;
  --at-border: rgba(212, 168, 83, 0.22);
  --at-border-hover: rgba(212, 168, 83, 0.65);
  --at-accent: #d4a853;
  --at-accent-soft: #e8c97a;
  --at-text: #f2f0eb;
  --at-text2: rgba(242, 240, 235, 0.58);
  --at-header-bg: rgba(6, 6, 8, 0.82);
  --at-card-bg: rgba(14, 14, 18, 0.72);
  --at-shade: linear-gradient(180deg, rgba(6,6,8,0.08) 0%, rgba(6,6,8,0.45) 50%, rgba(6,6,8,0.94) 100%);
}

html[data-theme="light"] {
  --at-bg: #f7f5f0;
  --at-bg-elevated: #ffffff;
  --at-border: rgba(160, 120, 40, 0.25);
  --at-border-hover: rgba(160, 120, 40, 0.55);
  --at-accent: #a87828;
  --at-accent-soft: #c49a3a;
  --at-text: #141210;
  --at-text2: rgba(20, 18, 16, 0.58);
  --at-header-bg: rgba(247, 245, 240, 0.92);
  --at-card-bg: rgba(255, 255, 255, 0.88);
  --at-shade: linear-gradient(180deg, rgba(255,255,255,0) 0%, rgba(247,245,240,0.45) 50%, rgba(247,245,240,0.96) 100%);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html {
  height: 100%;
  overflow: hidden;
}

body.ai-tools-page {
  height: 100%;
  height: 100dvh;
  max-height: 100dvh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background: var(--at-bg);
  color: var(--at-text);
  font-family: 'Inter', -apple-system, 'PingFang SC', 'Microsoft YaHei', sans-serif;
  font-weight: 300;
  font-size: 14px;
  line-height: 1.5;
}

/* 背景氛围 */
.at-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}
.at-bg-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.35;
}
.at-bg-glow-1 {
  width: 50vw;
  height: 50vw;
  max-width: 560px;
  max-height: 560px;
  top: -20%;
  left: -8%;
  background: radial-gradient(circle, rgba(212, 168, 83, 0.35) 0%, transparent 70%);
}
.at-bg-glow-2 {
  width: 40vw;
  height: 40vw;
  max-width: 420px;
  max-height: 420px;
  bottom: -15%;
  right: -6%;
  background: radial-gradient(circle, rgba(20, 184, 166, 0.12) 0%, transparent 70%);
}
.at-bg-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(212, 168, 83, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(212, 168, 83, 0.04) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 80% 70% at 50% 40%, black 20%, transparent 75%);
}

/* 顶栏 */
.at-header {
  position: relative;
  z-index: 10;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px clamp(16px, 3vw, 36px);
  border-bottom: 1px solid var(--at-border);
  background: var(--at-header-bg);
  backdrop-filter: blur(12px);
}
.at-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--at-text);
}
.at-brand img { height: 24px; }
.at-brand-text {
  font-size: 0.88rem;
  letter-spacing: 0.12em;
  font-weight: 400;
}
.at-brand-text span { color: var(--at-accent); }
.at-nav {
  display: flex;
  align-items: center;
  gap: 20px;
}
.at-nav-link {
  color: var(--at-text2);
  text-decoration: none;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  transition: color 0.2s;
}
.at-nav-link:hover { color: var(--at-accent); }

/* 主内容 — 占满剩余高度 */
.at-main {
  position: relative;
  z-index: 1;
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: clamp(8px, 1.5vh, 16px) clamp(16px, 3vw, 40px);
  max-width: 1440px;
  width: 100%;
  margin: 0 auto;
  overflow: hidden;
}

.at-hero {
  flex-shrink: 0;
  text-align: center;
  margin-bottom: clamp(10px, 1.8vh, 18px);
  max-width: 680px;
}
.at-eyebrow {
  font-size: 0.65rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--at-accent);
  margin-bottom: 6px;
  font-weight: 400;
}
.at-title {
  font-family: 'Cormorant Garamond', 'Songti SC', 'SimSun', serif;
  font-size: clamp(1.75rem, 3.2vw, 2.5rem);
  font-weight: 400;
  letter-spacing: 0.08em;
  margin-bottom: 6px;
  background: linear-gradient(135deg, var(--at-text) 0%, var(--at-accent-soft) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.at-lead {
  color: var(--at-text2);
  font-size: clamp(0.78rem, 1.1vw, 0.88rem);
  line-height: 1.45;
  font-weight: 300;
}

/* 三卡入口 — 弹性占满主区域 */
.at-cards {
  flex: 1;
  min-height: 0;
  width: 100%;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(10px, 1.5vw, 18px);
  align-items: stretch;
}
.at-card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 0;
  height: 100%;
  border-radius: 12px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  background: var(--at-card-bg);
  border: 1px solid var(--at-border);
  backdrop-filter: blur(8px);
  transition: border-color 0.35s, box-shadow 0.35s;
}
.at-card:hover {
  border-color: var(--at-border-hover);
  box-shadow:
    0 16px 36px rgba(0, 0, 0, 0.3),
    0 0 0 1px rgba(212, 168, 83, 0.12);
}
.at-card-media {
  position: relative;
  flex: 1;
  min-height: 0;
  overflow: hidden;
}
.at-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}
.at-card:hover .at-card-media img {
  transform: scale(1.04);
}
.at-card-shade {
  position: absolute;
  inset: 0;
  background: var(--at-shade);
  pointer-events: none;
}
.at-card-content {
  flex-shrink: 0;
  padding: clamp(12px, 1.6vh, 16px) clamp(14px, 1.8vw, 20px);
  border-top: 1px solid var(--at-border);
}
.at-card-index {
  display: block;
  font-size: 0.62rem;
  letter-spacing: 0.18em;
  color: var(--at-accent);
  margin-bottom: 6px;
  font-weight: 500;
}
.at-card-title {
  font-family: 'Cormorant Garamond', 'Songti SC', serif;
  font-size: clamp(1.45rem, 2.8vw, 2rem);
  font-weight: 600;
  letter-spacing: 0.05em;
  margin-bottom: 6px;
  color: var(--at-text);
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.at-card-desc {
  font-size: clamp(0.68rem, 0.95vw, 0.76rem);
  color: var(--at-text2);
  line-height: 1.4;
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.at-card-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  color: var(--at-accent);
  opacity: 0.85;
  transition: opacity 0.2s, gap 0.25s;
}
.at-card:hover .at-card-cta {
  opacity: 1;
  gap: 10px;
}

/* 页脚 */
.at-footer {
  position: relative;
  z-index: 1;
  flex-shrink: 0;
  padding: 8px clamp(16px, 3vw, 32px) 10px;
  text-align: center;
  font-size: 0.68rem;
  color: var(--at-text2);
  letter-spacing: 0.05em;
  border-top: 1px solid var(--at-border);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.at-footer-sep { margin: 0 8px; opacity: 0.4; }

/* 小屏：保持三列一屏，进一步压缩文案 */
@media (max-width: 768px) {
  .at-header { padding: 8px 14px; }
  .at-brand-text { display: none; }
  .at-nav { gap: 12px; }
  .at-hero { margin-bottom: 8px; }
  .at-eyebrow { margin-bottom: 4px; font-size: 0.6rem; }
  .at-title { margin-bottom: 4px; }
  .at-card-desc { -webkit-line-clamp: 1; margin-bottom: 6px; }
  .at-footer span:last-child,
  .at-footer-sep { display: none; }
}

@media (max-height: 700px) {
  .at-eyebrow { display: none; }
  .at-lead { font-size: 0.75rem; }
  .at-card-content { padding: 8px 12px; }
  .at-card-cta { display: none; }
}

/* 入场动画 */
@keyframes at-fade-up {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}
.at-hero {
  animation: at-fade-up 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
}
.at-card {
  animation: at-fade-up 0.75s cubic-bezier(0.22, 1, 0.36, 1) both;
}
.at-card:nth-child(1) { animation-delay: 0.1s; }
.at-card:nth-child(2) { animation-delay: 0.18s; }
.at-card:nth-child(3) { animation-delay: 0.26s; }

@media (prefers-reduced-motion: reduce) {
  .at-hero, .at-card { animation: none; }
  .at-card:hover .at-card-media img { transform: none; }
}
