/* ===== Solitaire Lite - 主题样式 ===== */
:root {
  /* 牌桌色调 - 经典绿色毛毡 */
  --felt-green: #1a5f3a;
  --felt-green-light: #228b4a;
  --felt-green-dark: #0d3d24;
  --felt-pattern: #165832;
  
  /* 纸牌配色 */
  --card-white: #faf8f5;
  --card-red: #c41e3a;
  --card-black: #1a1a1a;
  --card-back: linear-gradient(135deg, #2c5282 0%, #1a365d 100%);
  --card-shadow: rgba(0, 0, 0, 0.35);
  
  /* 金色点缀 */
  --gold: #d4af37;
  --gold-light: #f4e4a6;
  
  /* Typography */
  --font-display: 'Cormorant Garamond', Georgia, serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  
  /* 间距 */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background: var(--felt-green);
  color: var(--card-white);
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
}

/* 毛毡纹理背景 */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background: 
    radial-gradient(ellipse at 20% 30%, var(--felt-green-light) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 70%, var(--felt-pattern) 0%, transparent 50%),
    repeating-linear-gradient(
      90deg,
      transparent,
      transparent 2px,
      rgba(0, 0, 0, 0.03) 2px,
      rgba(0, 0, 0, 0.03) 4px
    );
  pointer-events: none;
  z-index: 0;
}

.felt-overlay {
  position: fixed;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 1;
}

/* ===== 导航栏 ===== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: var(--space-md) var(--space-xl);
  background: rgba(13, 61, 36, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(212, 175, 55, 0.2);
}

.nav {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  text-decoration: none;
  color: var(--card-white);
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
}

.logo-icon {
  font-size: 1.75rem;
  color: var(--gold);
}

.logo-icon-img {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  object-fit: contain;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: var(--space-xl);
}

.nav-links a {
  color: rgba(250, 248, 245, 0.9);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s;
}

.nav-links a:hover {
  color: var(--gold-light);
}

/* ===== 主内容区 ===== */
.main {
  position: relative;
  z-index: 2;
  padding-top: 80px;
}

/* ===== Hero 区域 ===== */
.hero {
  min-height: calc(100vh - 80px);
  max-width: 1200px;
  margin: 0 auto;
  padding: var(--space-2xl);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-2xl);
  align-items: center;
}

@media (max-width: 900px) {
  .hero {
    grid-template-columns: 1fr;
    text-align: center;
  }
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: var(--space-lg);
}

.title-line {
  display: block;
}

.title-line.accent {
  color: var(--gold-light);
  text-shadow: 0 0 30px rgba(212, 175, 55, 0.3);
}

.hero-subtitle {
  font-size: 1.125rem;
  line-height: 1.7;
  color: rgba(250, 248, 245, 0.9);
  margin-bottom: var(--space-xl);
  max-width: 420px;
}

@media (max-width: 900px) {
  .hero-subtitle {
    max-width: none;
    margin-left: auto;
    margin-right: auto;
  }
}

.hero-actions {
  display: flex;
  gap: var(--space-md);
  flex-wrap: wrap;
}

@media (max-width: 900px) {
  .hero-actions {
    justify-content: center;
  }
}

/* 按钮样式 */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-md) var(--space-xl);
  border-radius: 12px;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.25s ease;
  border: none;
  font-family: inherit;
}

.btn-primary {
  background: linear-gradient(135deg, var(--gold) 0%, #b8962e 100%);
  color: var(--felt-green-dark);
  box-shadow: 0 4px 20px rgba(212, 175, 55, 0.4);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 28px rgba(212, 175, 55, 0.5);
}

.btn-icon {
  width: 20px;
  height: 20px;
}

.btn-secondary {
  background: rgba(250, 248, 245, 0.15);
  color: var(--card-white);
  border: 2px solid rgba(212, 175, 55, 0.5);
}

.btn-secondary:hover {
  background: rgba(212, 175, 55, 0.2);
  border-color: var(--gold);
}

/* Hero 视觉 - 纸牌堆叠 */
.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 320px;
}

.card-stack {
  position: relative;
  width: 140px;
  height: 200px;
}

.card {
  position: absolute;
  width: 120px;
  height: 168px;
  border-radius: 10px;
  box-shadow: 0 4px 15px var(--card-shadow);
  left: calc(var(--offset, 0) * 12px);
  top: calc(var(--offset, 0) * 8px);
  transition: transform 0.3s ease;
}

.card-back {
  background: var(--card-back);
  border: 2px solid rgba(255, 255, 255, 0.2);
}

.card-back::before {
  content: '';
  position: absolute;
  inset: 8px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 6px;
}

.card-face {
  background: var(--card-white);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
}

.card-heart {
  color: var(--card-red);
}

.card-heart .card-suit {
  font-size: 2.5rem;
}

.hero-app-link {
  display: block;
  text-decoration: none;
}

.hero-app-icon {
  width: 160px;
  height: 160px;
  border-radius: 28px;
  object-fit: contain;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
  transition: transform 0.3s ease;
}

.hero-app-icon:hover {
  transform: scale(1.05);
}

.floating-cards {
  position: absolute;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.mini-card {
  position: absolute;
  width: 60px;
  height: 84px;
  background: var(--card-white);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  font-weight: 700;
  box-shadow: 0 2px 10px var(--card-shadow);
  animation: float 4s ease-in-out infinite;
}

.mini-card-1 { left: 15%; top: 20%; color: var(--card-black); animation-delay: 0s; }
.mini-card-2 { right: 20%; top: 30%; color: var(--card-red); animation-delay: 1.3s; }
.mini-card-3 { left: 50%; bottom: 15%; color: var(--card-black); animation-delay: 2.6s; }

@keyframes float {
  0%, 100% { transform: translateY(0) rotate(-2deg); }
  50% { transform: translateY(-10px) rotate(2deg); }
}

/* ===== 特色功能区 ===== */
.features {
  padding: var(--space-2xl) var(--space-xl);
  max-width: 1200px;
  margin: 0 auto;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  text-align: center;
  margin-bottom: var(--space-2xl);
  color: var(--gold-light);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: var(--space-lg);
}

.feature-card {
  background: rgba(13, 61, 36, 0.6);
  border: 1px solid rgba(212, 175, 55, 0.2);
  border-radius: 16px;
  padding: var(--space-xl);
  text-align: center;
  transition: all 0.3s ease;
}

.feature-card:hover {
  transform: translateY(-4px);
  border-color: rgba(212, 175, 55, 0.4);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
}

.feature-icon {
  font-size: 2.5rem;
  margin-bottom: var(--space-md);
}

.feature-card h3 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  margin-bottom: var(--space-sm);
  color: var(--card-white);
}

.feature-card p {
  font-size: 0.9rem;
  line-height: 1.6;
  color: rgba(250, 248, 245, 0.85);
}

/* ===== 游戏预览区 ===== */
.game-preview {
  padding: var(--space-2xl) var(--space-xl);
  max-width: 1200px;
  margin: 0 auto;
}

.preview-intro {
  text-align: center;
  color: rgba(250, 248, 245, 0.9);
  margin-bottom: var(--space-xl);
}

.screenshot-gallery {
  flex: 1;
  min-width: 300px;
  max-width: 1000px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: var(--space-md);
}

.screenshot-img {
  width: 100%;
  height: auto;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
  object-fit: cover;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.screenshot-img:hover {
  transform: scale(1.03);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
}

.app-store-link-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-xl);
  background: rgba(13, 61, 36, 0.6);
  border-radius: 16px;
  border: 1px solid rgba(212, 175, 55, 0.2);
  text-decoration: none;
  color: var(--gold-light);
  transition: all 0.3s ease;
}

.app-store-link-card:hover {
  border-color: var(--gold);
  transform: translateY(-4px);
}

.app-icon-large {
  width: 120px;
  height: 120px;
  border-radius: 22px;
  object-fit: contain;
}

.view-on-app-store {
  font-weight: 600;
}

.preview-container {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: var(--space-2xl);
  flex-wrap: wrap;
}

.preview-frame {
  flex: 1;
  min-width: 280px;
  max-width: 360px;
}

.preview-mockup {
  background: linear-gradient(145deg, #2d2d2d 0%, #1a1a1a 100%);
  border-radius: 40px;
  padding: 12px;
  box-shadow: 
    0 25px 50px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.phone-frame {
  background: #000;
  border-radius: 32px;
  overflow: hidden;
}

.phone-screen {
  aspect-ratio: 9/19;
  background: var(--felt-green);
  padding: 8px;
}

/* 简化版 Solitaire 棋盘 */
.solitaire-board {
  height: 100%;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.board-foundation {
  display: flex;
  gap: 6px;
  justify-content: flex-end;
}

.foundation-slot {
  width: 28px;
  height: 40px;
  border: 2px dashed rgba(212, 175, 55, 0.4);
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.1);
}

.board-tableau {
  flex: 1;
  display: flex;
  gap: 6px;
}

.tableau-column {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
  align-items: center;
}

.preview-card {
  width: 32px;
  height: 44px;
  border-radius: 4px;
  font-size: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
}

.preview-card.face-down,
.preview-card.back {
  background: linear-gradient(135deg, #2c5282, #1a365d);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.preview-card.face-up {
  background: var(--card-white);
}

.preview-card.red {
  color: var(--card-red);
}

.preview-card.black {
  color: var(--card-black);
}

.board-stock {
  display: flex;
  justify-content: flex-start;
}

.stock-pile {
  margin-left: 0;
}

.app-screenshot {
  max-width: 280px;
  border-radius: 12px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
}

/* ===== 下载区 ===== */
.download {
  padding: var(--space-2xl) var(--space-xl);
  text-align: center;
}

.download-content {
  max-width: 500px;
  margin: 0 auto;
  background: rgba(13, 61, 36, 0.6);
  border: 1px solid rgba(212, 175, 55, 0.3);
  border-radius: 24px;
  padding: var(--space-2xl);
}

.download-content h2 {
  font-family: var(--font-display);
  font-size: 1.75rem;
  margin-bottom: var(--space-sm);
}

.download-content p {
  color: rgba(250, 248, 245, 0.9);
  margin-bottom: var(--space-lg);
}

.btn-download {
  display: inline-block;
  padding: 0;
  background: none;
  border: none;
}

.app-store-badge,
.play-store-badge {
  height: 50px;
  width: auto;
  transition: transform 0.2s;
}

.play-store-badge {
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.3));
}

.app-store-badge {
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.3));
}

.app-store-badge:hover,
.play-store-badge:hover {
  transform: scale(1.05);
}

.app-store-badge:hover {
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.4));
}

.play-store-badge:hover {
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.4));
}

.download-note {
  font-size: 0.85rem;
  color: rgba(250, 248, 245, 0.7);
  margin-top: var(--space-md);
}

/* ===== 页脚 ===== */
.footer {
  padding: var(--space-xl);
  text-align: center;
  border-top: 1px solid rgba(212, 175, 55, 0.2);
}

.footer p {
  color: rgba(250, 248, 245, 0.7);
  font-size: 0.9rem;
}

.footer-links {
  margin-top: var(--space-sm);
}

.footer-links a {
  color: var(--gold);
  text-decoration: none;
  margin: 0 var(--space-md);
}

.footer-links a:hover {
  text-decoration: underline;
}
