/*
Theme Name: Astra Child
Template: astra
Version: 1.0.0
*/

/* ============================================================
   AIMEIBAIBIAN · 全球高端企业工厂品牌视觉升级
   设计师：资深前端设计总监
   改动范围：纯外观 — 不修改任何功能/按钮逻辑/页面结构
   ============================================================ */

/* ---- Google Fonts (通过 @import) ---- */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Playfair+Display:wght@400;500;600;700&family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&display=swap');

/* ---- CSS 自定义属性 (Design Tokens) ---- */
:root {
  --p-color-deep-navy: #0A1628;
  --p-color-navy: #0F1F3A;
  --p-color-dark-blue: #132C4B;
  --p-color-midnight: #1A2F4E;
  --p-color-gold: #C9A84C;
  --p-color-gold-light: #E0C568;
  --p-color-gold-dark: #A88930;
  --p-color-silver: #D4D9E2;
  --p-color-soft-white: #F0F2F6;
  --p-color-smoke: #E8EBF0;
  --p-color-charcoal: #2D3748;
  --p-color-steel: #4A5568;
  --p-gradient-navy: linear-gradient(135deg, #0A1628 0%, #0F1F3A 40%, #132C4B 100%);
  --p-gradient-gold: linear-gradient(135deg, #C9A84C 0%, #E0C568 50%, #C9A84C 100%);
  --p-gradient-hero: linear-gradient(135deg, #0A1628 0%, #0F1F3A 30%, #132C4B 60%, #1A2F4E 100%);
  --p-font-primary: 'Plus Jakarta Sans', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --p-font-heading: 'Playfair Display', 'Georgia', serif;
  --p-font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --p-transition-smooth: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --p-transition-glass: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  --p-glass-bg: rgba(255, 255, 255, 0.06);
  --p-glass-border: rgba(255, 255, 255, 0.10);
  --p-glass-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  --p-radius-sm: 6px;
  --p-radius-md: 12px;
  --p-radius-lg: 20px;
  --p-radius-xl: 28px;
  --p-shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.06);
  --p-shadow-md: 0 8px 30px rgba(0, 0, 0, 0.12);
  --p-shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.15);
  --p-shadow-gold: 0 4px 20px rgba(201, 168, 76, 0.3);
}

/* ==============================================================
   1. 全局基础
   ============================================================== */
html {
  scroll-behavior: smooth !important;
}
body {
  font-family: var(--p-font-body) !important;
  color: var(--p-color-charcoal) !important;
  background: var(--p-color-soft-white) !important;
  line-height: 1.7 !important;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
::selection {
  background: var(--p-color-gold);
  color: var(--p-color-deep-navy);
}
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: var(--p-color-deep-navy); }
::-webkit-scrollbar-thumb { background: var(--p-color-gold); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--p-color-gold-light); }

/* ==============================================================
   2. 标题排版
   ============================================================== */
h1, h2, h3, h4, h5, h6,
.entry-title,
.entry-content h1, .entry-content h2, .entry-content h3,
.entry-content h4, .entry-content h5, .entry-content h6,
.page-title, .widget-title,
.woocommerce-loop-product__title,
.woocommerce div.product .product_title {
  font-family: var(--p-font-heading) !important;
  font-weight: 700 !important;
  letter-spacing: -0.02em !important;
  color: var(--p-color-deep-navy) !important;
}
h1, .entry-content h1, .page-title {
  font-size: clamp(2.2rem, 5vw, 3.8rem) !important;
  line-height: 1.15 !important;
  letter-spacing: -0.03em !important;
}
h2, .entry-content h2 {
  font-size: clamp(1.6rem, 3.5vw, 2.8rem) !important;
  line-height: 1.2 !important;
}
h3, .entry-content h3 {
  font-size: clamp(1.3rem, 2.5vw, 2.0rem) !important;
}
.entry-content h2::after,
.related.products > h2::after,
.upsells.products > h2::after {
  content: '' !important;
  display: block !important;
  margin-top: 12px !important;
  width: 60px !important;
  height: 3px !important;
  background: var(--p-gradient-gold) !important;
  border-radius: 2px !important;
}

/* =========================================================
   3. 背景 — 深色质感
   ============================================================== */
.ast-separate-container,
.ast-plain-container,
.ast-page-builder-template,
.site-content, #primary, #secondary {
  background: transparent !important;
}
.ast-separate-container {
  background: var(--p-color-soft-white) !important;
}
.ast-separate-container .ast-article-single,
.ast-separate-container .ast-article-inner,
.ast-separate-container .woocommerce {
  background: #ffffff !important;
  border-radius: var(--p-radius-lg) !important;
  box-shadow: var(--p-shadow-md) !important;
  position: relative !important;
  overflow: hidden !important;
}
.ast-article-post,
.ast-article-single,
.hentry {
  background: #ffffff !important;
  border-radius: var(--p-radius-lg) !important;
  box-shadow: var(--p-shadow-sm) !important;
  transition: var(--p-transition-smooth) !important;
  overflow: hidden !important;
  position: relative !important;
}
.ast-article-post:hover,
.hentry:hover {
  transform: translateY(-4px) !important;
  box-shadow: var(--p-shadow-lg) !important;
}
.ast-article-post::before,
.ast-article-single::before {
  content: '' !important;
  position: absolute !important;
  top: 0; left: 0; right: 0;
  height: 3px !important;
  background: var(--p-gradient-gold) !important;
  opacity: 0 !important;
  transition: opacity 0.4s ease !important;
  z-index: 1 !important;
}
.ast-article-post:hover::before,
.ast-article-single:hover::before {
  opacity: 1 !important;
}

/* ==============================================================
   4. 链接
   ============================================================== */
a, .entry-meta a {
  color: var(--p-color-dark-blue) !important;
  text-decoration: none !important;
  transition: var(--p-transition-smooth) !important;
}
a:hover, .entry-meta a:hover {
  color: var(--p-color-gold) !important;
}

/* =============================================================
   5. 按钮系统 — 只改视觉，不改功能
   ============================================================== */
button, .button, .wp-block-button__link,
.wc-block-components-button,
.woocommerce a.button, .woocommerce button.button,
.woocommerce a.add_to_cart_button,
.woocommerce .button.single_add_to_cart_button,
.single_add_to_cart_button,
a.ast-button, .ast-custom-button,
input[type="submit"], input[type="button"],
.wp-block-search .wp-block-search__button,
.wp-block-file .wp-block-file__button {
  font-family: var(--p-font-primary) !important;
  font-weight: 600 !important;
  font-size: 14px !important;
  letter-spacing: 0.02em !important;
  border: none !important;
  border-radius: 50px !important;
  padding: 14px 32px !important;
  color: #ffffff !important;
  background: var(--p-gradient-navy) !important;
  box-shadow: 0 4px 15px rgba(10, 22, 40, 0.3) !important;
  transition: var(--p-transition-smooth) !important;
  cursor: pointer !important;
  position: relative !important;
  overflow: hidden !important;
  text-transform: none !important;
}
button::before, .button::before, .wp-block-button__link::before {
  content: '' !important;
  position: absolute !important;
  top: 0; left: -100%;
  width: 100%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.15), transparent) !important;
  transition: left 0.6s ease !important;
}
button:hover::before, .button:hover::before, .wp-block-button__link:hover::before {
  left: 100% !important;
}
button:hover, .button:hover, .wp-block-button__link:hover,
.woocommerce a.button:hover, .woocommerce button.button:hover,
.woocommerce a.add_to_cart_button:hover,
.single_add_to_cart_button:hover {
  transform: translateY(-2px) !important;
  box-shadow: 0 8px 25px rgba(10, 22, 40, 0.4) !important;
  background: linear-gradient(135deg, #132C4B 0%, #0F1F3A 50%, #0A1628 100%) !important;
  color: var(--p-color-gold-light) !important;
}
button:active, .button:active {
  transform: translateY(0) !important;
}
/* ==============================================================
   6. HEADER — 玻璃质感导航
   ================================= */
.ast-primary-header-bar, #masthead {
  background: rgba(10, 22, 40, 0.92) !important;
  backdrop-filter: blur(20px) !important;
  -webkit-backdrop-filter: blur(20px) !important;
  border-bottom: 1px solid rgba(201, 168, 76, 0.15) !important;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3) !important;
  transition: var(--p-transition-glass) !important;
}
.site-logo-img img, .custom-logo {
  transition: var(--p-transition-smooth) !important;
  filter: drop-shadow(0 2px 8px rgba(201, 168, 76, 0.2)) !important;
}
.site-logo-img img:hover, .custom-logo:hover {
  transform: scale(1.03) !important;
  filter: drop-shadow(0 4px 16px rgba(201, 168, 76, 0.4)) !important;
}
.site-title, .site-title a {
  font-family: var(--p-font-primary) !important;
  font-weight: 700 !important;
  font-size: 1.2rem !important;
  color: var(--p-color-gold-light) !important;
  letter-spacing: 0.05em !important;
  text-transform: uppercase !important;
}
.main-header-menu .menu-link,
.ast-builder-menu-1 .menu-item > .menu-link {
  font-family: var(--p-font-primary) !important;
  font-weight: 500 !important;
  font-size: 14px !important;
  letter-spacing: 0.03em !important;
  color: var(--p-color-silver) !important;
  transition: var(--p-transition-smooth) !important;
  position: relative !important;
  padding: 10px 16px !important;
}
.main-header-menu .menu-link::after {
  content: '' !important;
  position: absolute !important;
  bottom: 4px; left: 16px; right: 16px;
  height: 2px !important;
  background: var(--p-gradient-gold) !important;
  transform: scaleX(0) !important;
  transform-origin: center !important;
  transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94) !important;
  border-radius: 1px !important;
}
.main-header-menu .menu-link:hover,
.ast-builder-menu-1 .menu-item:hover > .menu-link,
.main-header-menu .menu-item.current-menu-item > .menu-link {
  color: var(--p-color-gold-light) !important;
}
.main-header-menu .menu-link:hover::after,
.main-header-menu .menu-item.current-menu-item > .menu-link::after {
  transform: scaleX(1) !important;
}
.main-header-menu .sub-menu,
.ast-builder-menu-1 .sub-menu {
  background: rgba(10, 22, 40, 0.95) !important;
  backdrop-filter: blur(20px) !important;
  -webkit-backdrop-filter: blur(20px) !important;
  border: 1px solid rgba(201, 168, 76, 0.15) !important;
  border-radius: var(--p-radius-md) !important;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5) !important;
  overflow: hidden !important;
}
.main-header-menu .sub-menu .menu-link {
  color: var(--p-color-silver) !important;
  padding: 12px 20px !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
  transition: var(--p-transition-smooth) !important;
}
.main-header-menu .sub-menu .menu-link:hover {
  background: rgba(201, 168, 76, 0.08) !important;
  color: var(--p-color-gold-light) !important;
  padding-left: 28px !important;
}
.main-header-menu .sub-menu .menu-link::after {
  display: none !important;
}

/* =========================================================
   7. 移动端导航
   ============================================================== */
.ast-mobile-header-content {
  background: rgba(10, 22, 40, 0.98) !important;
  backdrop-filter: blur(20px) !important;
  -webkit-backdrop-filter: blur(20px) !important;
}
.ast-mobile-popup-inner {
  background: var(--p-color-deep-navy) !important;
}
.ast-mobile-header-content .menu-link,
.ast-mobile-popup-content .menu-link {
  color: var(--p-color-silver) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06) !important;
}
.ast-mobile-menu-trigger-minimal {
  color: var(--p-color-gold) !important;
}
.ast-mobile-menu-trigger-minimal .ast-mobile-svg {
  fill: var(--p-color-gold) !important;
}

/* =============================================================
   8. 背景装饰粒子
   ============================================================== */
#page::before {
  content: '' !important;
  position: fixed !important;
  top: 0; left: 0;
  width: 100%; height: 100%;
  pointer-events: none !important;
  z-index: -1 !important;
  background:
    radial-gradient(ellipse at 20% 50%, rgba(201, 168, 76, 0.03) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 20%, rgba(201, 168, 76, 0.02) 0%, transparent 50%),
    radial-gradient(ellipse at 50% 80%, rgba(10, 22, 40, 0.02) 0%, transparent 50%) !important;
}

/* ==============================================================
   9. Footer — 深色精致
   ============================================================= */
.site-footer, .ast-footer-overlay,
.site-above-footer-wrap, .site-below-footer-wrap,
.site-primary-footer-wrap {
  background: var(--p-gradient-navy) !important;
  position: relative !important;
  overflow: hidden !important;
}
.site-footer::before {
  content: '' !important;
  position: absolute !important;
  top: 0; left: 0; right: 0;
  height: 3px !important;
  background: var(--p-gradient-gold) !important;
  z-index: 1 !important;
}
.site-footer .widget-title,
.footer-widget-area .widget-title {
  font-family: var(--p-font-primary) !important;
  color: var(--p-color-gold-light) !important;
  font-size: 1rem !important;
  text-transform: uppercase !important;
  letter-spacing: 0.08em !important;
  margin-bottom: 20px !important;
  position: relative !important;
  padding-bottom: 12px !important;
}
.site-footer .widget-title::after {
  content: '' !important;
  position: absolute !important;
  bottom: 0; left: 0;
  width: 36px !important;
  height: 2px !important;
  background: var(--p-gradient-gold) !important;
}
.site-footer .widget, .footer-widget-area .widget {
  color: var(--p-color-silver) !important;
  font-size: 14px !important;
}
.site-footer a, .footer-widget-area a {
  color: var(--p-color-silver) !important;
  transition: var(--p-transition-smooth) !important;
}
.site-footer a:hover, .footer-widget-area a:hover {
  color: var(--p-color-gold-light) !important;
  padding-left: 4px !important;
}
.site-below-footer-wrap, .site-above-footer-wrap {
  border: none !important;
  border-top: 1px solid rgba(201, 168, 76, 0.1) !important;
}
.ast-footer-copyright {
  color: var(--p-color-steel) !important;
  font-size: 13px !important;
  letter-spacing: 0.03em !important;
}
.site-footer .footer-widget-area ul li {
  border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
  padding: 8px 0 !important;
}

/* ==============================================================
   10. WooCommerce 优化
   ========================================================= */
.woocommerce ul.products li.product,
.products .product {
  background: #ffffff !important;
  border-radius: var(--p-radius-lg) !important;
  box-shadow: var(--p-shadow-sm) !important;
  overflow: hidden !important;
  transition: var(--p-transition-smooth) !important;
  position: relative !important;
}
.woocommerce ul.products li.product:hover,
.products .product:hover {
  transform: translateY(-6px) !important;
  box-shadow: var(--p-shadow-lg) !important;
}
.woocommerce ul.products li.product .woocommerce-loop-product__title {
  font-family: var(--p-font-primary) !important;
  font-weight: 600 !important;
  font-size: 16px !important;
  color: var(--p-color-deep-navy) !important;
  padding: 0 16px !important;
}
.woocommerce ul.products li.product .price {
  color: var(--p-color-gold-dark) !important;
  font-weight: 700 !important;
  font-size: 18px !important;
  padding: 0 16px 16px !important;
}
.woocommerce ul.products li.product .button {
  margin: 0 16px 16px !important;
  width: calc(100% - 32px) !important;
  text-align: center !important;
}
.woocommerce ul.products li.product a img,
.woocommerce div.product div.images img {
  border-radius: var(--p-radius-md) !important;
  transition: var(--p-transition-smooth) !important;
}
.woocommerce ul.products li.product a img:hover {
  transform: scale(1.03) !important;
}
.woocommerce div.product {
  background: #ffffff !important;
  border-radius: var(--p-radius-lg) !important;
  box-shadow: var(--p-shadow-sm) !important;
  padding: 30px !important;
}
.woocommerce div.product .product_title {
  font-size: 2rem !important;
  color: var(--p-color-deep-navy) !important;
}
.woocommerce div.product .price {
  color: var(--p-color-gold-dark) !important;
  font-size: 1.5rem !important;
  font-weight: 700 !important;
}
.ast-site-header-cart .ast-cart-menu-wrap .count {
  font-family: var(--p-font-primary) !important;
  background: var(--p-gradient-gold) !important;
  color: var(--p-color-deep-navy) !important;
  font-weight: 700 !important;
}
.ast-site-header-cart .ast-addon-cart-wrap {
  color: var(--p-color-gold) !important;
}
/* ==============================================================
   11. 首页轮播 — 核心布局
   ============================================================= */
.hero-carousel {
  position: relative;
  overflow: hidden;
  width: 100%;
  max-width: 1200px;
  margin: 30px auto;
  border-radius: 12px;
  box-shadow: 0 20px 60px rgba(0,0,0.15);
  min-height: 400px;
  background: #0A1628;
}

.carousel-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.6s ease, visibility 0.6s ease;
  z-index: 1;
}

.carousel-slide.active {
  opacity: 1;
  visibility: visible;
  z-index: 2;
}

.carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* 左右箭头 */
.carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  background: rgba(10,22,40,0.5);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #E0C568;
  border: 1px solid rgba(201,168,76,0.2);
  width: 48px;
  height: 48px;
  font-size: 28px;
  cursor: pointer;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  padding: 0;
  transition: all 0.3s;
}
.carousel-arrow-left  { left: 16px; }
.carousel-arrow-right { right: 16px; }
.carousel-arrow:hover {
  background: rgba(10,22,40,0.8);
  border-color: #C9A84C;
  transform: translateY(-50%) scale(1.1);
}

/* 底部圆点 */
.carousel-dots {
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  display: flex;
  gap: 10px;
}
.carousel-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(255,255,0.3);
  border: 2px solid rgba(255,255,0.5);
  cursor: pointer;
  transition: all 0.3s;
}
.carousel-dot.active {
  background: #C9A84C;
  border-color: #C9A84C;
  transform: scale(1.2);
}
/* ==============================================================
   12. 搜索框样式
   ============================================================= */
.ast-search-menu-icon .search-form {
  border: 1px solid rgba(201, 168, 76, 0.2) !important;
  border-radius: 50px !important;
  overflow: hidden !important;
  background: rgba(255, 255, 255, 0.08) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
}
.ast-search-menu-icon .search-field {
  color: var(--p-color-silver) !important;
  background: transparent !important;
  border: none !important;
  font-family: var(--p-font-primary) !important;
}
.ast-search-menu-icon .search-field::placeholder {
  color: rgba(212, 217, 226, 0.5) !important;
}
.ast-search-menu-icon .search-submit {
  color: var(--p-color-gold) !important;
}

/* ==============================================================
   13. 语言切换器适配
   ============================================================== */
.trp-floater-ls-names {
  background: rgba(10, 22, 40, 0.95) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border: 1px solid rgba(201, 168, 76, 0.15) !important;
  border-radius: var(--p-radius-md) !important;
}
.trp-floater-ls-names a {
  color: var(--p-color-silver) !important;
}
.trp-floater-ls-names a:hover {
  color: var(--p-color-gold-light) !important;
}

/* ==============================================================
   14. 面包屑
   ============================================================== */
.ast-breadcrumbs {
  font-family: var(--p-font-primary) !important;
  font-size: 13px !important;
  color: var(--p-color-steel) !important;
}
.ast-breadcrumbs a {
  color: var(--p-color-dark-blue) !important;
}
.ast-breadcrumbs a:hover {
  color: var(--p-color-gold) !important;
}

/* =========================================================
   15. 响应式
   ============================================================== */
@media (max-width: 768px) {
  .woocommerce ul.products[class*="columns-"] li.product {
    float: none !important;
    width: 100% !important;
  }
  .woocommerce div.product {
    padding: 16px !important;
  }
  .ast-article-post {
    margin-bottom: 20px !important;
  }
  .ast-primary-header-bar {
    padding: 0 12px !important;
  }
}
@media (max-width: 544px) {
  .site-title, .site-title a { font-size: 0.9rem !important; }
  h1, .entry-content h1 { font-size: 1.8rem !important; }
  .ast-separate-container .ast-article-single,
  .ast-separate-container .ast-article-inner {
    border-radius: var(--p-radius-md) !important;
  }
  button, .button, .wp-block-button__link {
    padding: 12px 24px !important;
  }
}
@media (max-width: 544px) {
  .site-below-footer-wrap .ast-builder-grid-row,
  .site-above-footer-wrap .ast-builder-grid-row {
    grid-template-columns: 1fr !important;
    text-align: center !important;
  }
  .footer-widget-area .widget-title::after {
    left: 50% !important;
    transform: translateX(-50%) !important;
  }
}