/*
Theme Name: VogoViet Travel Child
Description: 中越双向旅游服务平台子主题 - 基于Astra主题的专业旅游网站解决方案，支持中越双语，移动端优化，联盟营销系统
Author: VogoViet Development Team
Version: 1.0.0
Template: astra
Text Domain: vogoviet-travel-child
Domain Path: /languages
License: GPL v2.0
License URI: https://www.gnu.org/licenses/gpl-2.0.html

VogoViet Travel Child Theme, Copyright 2024 VogoViet Development Team
VogoViet Travel Child Theme is distributed under the terms of the GNU GPL v2.0
*/

/* ==========================================================================
   导入父主题样式 | Import Parent Theme Styles
   ========================================================================== */
@import url("../astra/style.css");

/* ==========================================================================
   1. CSS变量定义 - 严格遵循设计规范
   ========================================================================== */

:root {
  /* 主色调系统 */
  --primary-color: #2C3E50;        /* 深森林绿 - 导航栏/标题/按钮背景 */
  --secondary-color: #F3D250;      /* 暖沙色 - CTA按钮/强调文本/价格标签 */
  --cultural-red: #C91F37;         /* 中国红 - 中国方向产品标签 */
  --cultural-gold: #FFD700;        /* 越南金 - 越南方向产品标签 */
  
  /* 中性色系统 */
  --bg-light: #F8F7F4;            /* 米白 - 页面背景 */
  --bg-white: #FFFFFF;             /* 纯白 - 产品卡片/表单背景 */
  --text-dark: #1A1A1A;           /* 炭黑 - 正文文本 */
  --text-gray: #666666;           /* 灰色 - 辅助文本 */
  
  /* 交互状态色 */
  --primary-hover: #1E4057;       /* 主色调悬停状态 */
  --secondary-hover: #E6C547;     /* 辅助色悬停状态 */
  
  /* 间距系统 */
  --spacing-xs: 8px;
  --spacing-sm: 12px;
  --spacing-md: 16px;
  --spacing-lg: 24px;
  --spacing-xl: 32px;
  
  /* 圆角系统 */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  
  /* 阴影系统 */
  --shadow-light: 0 2px 8px rgba(44, 62, 80, 0.1);
  --shadow-medium: 0 4px 16px rgba(44, 62, 80, 0.15);
  --shadow-heavy: 0 8px 32px rgba(44, 62, 80, 0.2);
}

/* ==========================================================================
   2. 基础样式重置
   ========================================================================== */

* {
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  background-color: var(--bg-light);
  color: var(--text-dark);
  line-height: 1.6;
  margin: 0;
  padding: 0;
}

img {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius-sm);
}

a {
  text-decoration: none;
  color: inherit;
  transition: all 0.3s ease;
}

/* ==========================================================================
   3. 导航栏样式
   ========================================================================== */

.site-header {
  background: var(--primary-color);
  padding: var(--spacing-md) 0;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: var(--shadow-medium);
}

.header-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--spacing-md);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.site-logo {
  color: var(--bg-white);
  font-size: 24px;
  font-weight: 700;
}

.search-box {
  flex: 1;
  max-width: 400px;
  margin: 0 var(--spacing-lg);
  position: relative;
}

.search-input {
  width: 100%;
  padding: var(--spacing-sm) var(--spacing-md);
  border: none;
  border-radius: var(--radius-md);
  font-size: 16px;
  background: var(--bg-white);
}

.user-menu {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
}

.language-switcher {
  display: flex;
  gap: var(--spacing-xs);
}

.lang-btn {
  padding: var(--spacing-xs) var(--spacing-sm);
  background: rgba(255, 255, 255, 0.1);
  color: var(--bg-white);
  border-radius: var(--radius-sm);
  font-size: 14px;
  transition: background 0.3s ease;
}

.lang-btn:hover,
.lang-btn.active {
  background: var(--secondary-color);
  color: var(--primary-color);
}

/* ==========================================================================
   4. 首页轮播Banner
   ========================================================================== */

.hero-banner {
  position: relative;
  height: 60vh;
  min-height: 400px;
  overflow: hidden;
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
}

.banner-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 1s ease-in-out;
}

.banner-slide.active {
  opacity: 1;
}

.banner-content {
  text-align: center;
  color: var(--bg-white);
  max-width: 600px;
  padding: var(--spacing-lg);
}

.banner-title {
  font-size: 3rem;
  font-weight: 700;
  margin-bottom: var(--spacing-md);
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.banner-subtitle {
  font-size: 1.2rem;
  margin-bottom: var(--spacing-xl);
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

.cta-button {
  display: inline-block;
  padding: var(--spacing-md) var(--spacing-xl);
  background: linear-gradient(135deg, var(--secondary-color), var(--secondary-hover));
  color: var(--primary-color);
  font-weight: 600;
  border-radius: var(--radius-sm);
  font-size: 18px;
  box-shadow: var(--shadow-medium);
  transition: all 0.3s ease;
}

.cta-button:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-heavy);
}

/* ==========================================================================
   5. 分类导航（横向滚动）
   ========================================================================== */

.category-nav {
  padding: var(--spacing-lg) 0;
  background: var(--bg-white);
  margin: var(--spacing-lg) 0;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-light);
}

.category-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--spacing-md);
}

.category-scroll {
  display: flex;
  overflow-x: auto;
  gap: var(--spacing-lg);
  padding: var(--spacing-sm) 0;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.category-scroll::-webkit-scrollbar {
  display: none;
}

.category-item {
  flex: 0 0 auto;
  text-align: center;
  min-width: 80px;
}

.category-icon {
  width: 60px;
  height: 60px;
  background: var(--primary-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto var(--spacing-sm);
  color: var(--bg-white);
  font-size: 24px;
  transition: all 0.3s ease;
}

.category-item:hover .category-icon {
  background: var(--secondary-color);
  color: var(--primary-color);
  transform: scale(1.1);
}

.category-label {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-dark);
}

/* ==========================================================================
   6. 联盟推广横幅（仅移动端）
   ========================================================================== */

.affiliate-banner {
  display: none; /* 默认隐藏，移动端显示 */
  align-items: center;
  background: var(--primary-color);
  height: 80px;
  padding: 0 var(--spacing-md);
  border-radius: var(--radius-md);
  margin: var(--spacing-lg) 0;
  box-shadow: var(--shadow-medium);
  transition: background 0.3s ease;
}

.affiliate-banner:active {
  background: var(--primary-hover);
}

.affiliate-icon {
  color: var(--secondary-color);
  font-size: 24px;
  margin-right: var(--spacing-md);
}

.affiliate-text {
  color: var(--bg-white);
  flex: 1;
  font-size: 14px;
  line-height: 1.4;
}

.affiliate-btn {
  background: var(--secondary-color);
  color: var(--primary-color);
  padding: var(--spacing-sm) var(--spacing-md);
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 14px;
  transition: all 0.3s ease;
}

.affiliate-btn:active {
  transform: scale(1.05);
}

/* ==========================================================================
   7. 产品网格系统
   ========================================================================== */

.products-section {
  max-width: 1200px;
  margin: 0 auto;
  padding: var(--spacing-xl) var(--spacing-md);
}

.section-title {
  font-size: 2rem;
  font-weight: 700;
  color: var(--primary-color);
  margin-bottom: var(--spacing-lg);
  text-align: center;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--spacing-lg);
  margin-bottom: var(--spacing-xl);
}

.product-card {
  background: var(--bg-white);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-light);
  transition: all 0.3s ease;
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-heavy);
}

.product-image {
  position: relative;
  aspect-ratio: 1.2;
  overflow: hidden;
}

.product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 0;
}

.local-badge {
  position: absolute;
  top: var(--spacing-sm);
  left: var(--spacing-sm);
  background: var(--secondary-color);
  color: var(--primary-color);
  padding: 4px var(--spacing-sm);
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 600;
}

.promo-tag {
  position: absolute;
  top: var(--spacing-sm);
  right: var(--spacing-sm);
  background: var(--cultural-red);
  color: var(--bg-white);
  padding: 4px var(--spacing-sm);
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 600;
}

.product-content {
  padding: var(--spacing-md);
}

.product-title {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: var(--spacing-sm);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-meta {
  display: flex;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-md);
  font-size: 14px;
  color: var(--text-gray);
}

.product-meta i {
  margin-right: 4px;
  color: var(--primary-color);
}

.product-price {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--secondary-color);
  margin-bottom: var(--spacing-md);
}

.product-price small {
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--text-gray);
}

.product-btn {
  display: block;
  width: 100%;
  padding: var(--spacing-sm) 0;
  background: var(--primary-color);
  color: var(--bg-white);
  text-align: center;
  border-radius: var(--radius-sm);
  font-weight: 600;
  transition: all 0.3s ease;
}

.product-btn:hover {
  background: var(--primary-hover);
}

/* ==========================================================================
   8. 底部固定导航栏（移动端）
   ========================================================================== */

.mobile-nav {
  display: none; /* 默认隐藏，移动端显示 */
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--bg-white);
  border-top: 1px solid #E5E5E5;
  padding: var(--spacing-sm) 0;
  z-index: 1000;
}

.mobile-nav-container {
  display: flex;
  justify-content: space-around;
  align-items: center;
}

.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: var(--spacing-xs);
  color: var(--text-gray);
  font-size: 12px;
  transition: color 0.3s ease;
}

.nav-item.active {
  color: var(--secondary-color);
}

.nav-item i {
  font-size: 20px;
  margin-bottom: 4px;
}

/* ==========================================================================
   9. 表单样式
   ========================================================================== */

.form-container {
  max-width: 600px;
  margin: 0 auto;
  padding: var(--spacing-xl);
  background: var(--bg-white);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-medium);
}

.form-group {
  margin-bottom: var(--spacing-lg);
}

.form-label {
  display: block;
  margin-bottom: var(--spacing-sm);
  font-weight: 600;
  color: var(--text-dark);
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: var(--spacing-sm) var(--spacing-md);
  border: 2px solid #E5E5E5;
  border-radius: var(--radius-sm);
  font-size: 16px;
  transition: border-color 0.3s ease;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--secondary-color);
}

.form-submit {
  width: 100%;
  height: 50px;
  background: var(--secondary-color);
  color: var(--primary-color);
  border: none;
  border-radius: var(--radius-sm);
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.form-submit:hover {
  background: var(--secondary-hover);
  transform: translateY(-1px);
}

/* ==========================================================================
   10. 响应式媒体查询
   ========================================================================== */

/* 移动端 (≤767px) */
@media (max-width: 767px) {
  .product-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-md);
  }
  
  .desktop-nav {
    display: none;
  }
  
  .mobile-nav {
    display: block;
  }
  
  .affiliate-banner {
    display: flex;
  }
  
  .banner-title {
    font-size: 2rem;
  }
  
  .banner-subtitle {
    font-size: 1rem;
  }
  
  .search-box {
    display: none;
  }
  
  .category-item {
    min-width: 70px;
  }
  
  .category-icon {
    width: 50px;
    height: 50px;
    font-size: 20px;
  }
  
  .product-title {
    font-size: 1rem;
  }
  
  .section-title {
    font-size: 1.5rem;
  }
  
  /* 触摸反馈 */
  .product-card:active,
  .cta-button:active,
  .product-btn:active {
    transform: scale(0.98);
  }
  
  /* 为移动端底部导航留出空间 */
  body {
    padding-bottom: 80px;
  }
}

/* 平板 (768px - 1199px) */
@media (min-width: 768px) and (max-width: 1199px) {
  .product-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  
  .mobile-nav {
    display: none;
  }
  
  .affiliate-banner {
    display: none;
  }
  
  .banner-title {
    font-size: 2.5rem;
  }
}

/* 桌面端 (≥1200px) */
@media (min-width: 1200px) {
  .product-grid {
    grid-template-columns: repeat(4, 1fr);
  }
  
  .mobile-nav {
    display: none;
  }
  
  .affiliate-banner {
    display: none;
  }
}

/* ==========================================================================
   11. 动画和过渡效果
   ========================================================================== */

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in-up {
  animation: fadeInUp 0.6s ease-out;
}

@keyframes pulse {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
}

.pulse {
  animation: pulse 2s infinite;
}

/* ==========================================================================
   12. 工具类
   ========================================================================== */

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mb-sm { margin-bottom: var(--spacing-sm); }
.mb-md { margin-bottom: var(--spacing-md); }
.mb-lg { margin-bottom: var(--spacing-lg); }
.mb-xl { margin-bottom: var(--spacing-xl); }

.mt-sm { margin-top: var(--spacing-sm); }
.mt-md { margin-top: var(--spacing-md); }
.mt-lg { margin-top: var(--spacing-lg); }
.mt-xl { margin-top: var(--spacing-xl); }

.hidden { display: none; }
.visible { display: block; }

/* 无障碍访问 */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* 打印样式 */
@media print {
  .mobile-nav,
  .affiliate-banner,
  .cta-button {
    display: none;
  }
  
  .product-card {
    break-inside: avoid;
  }
}