/* ========================================
   Components
   ======================================== */

/* ---------- Header ---------- */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  background: var(--color-white);
  z-index: 1000;
  transition: box-shadow var(--transition-base);
}

.header.scrolled {
  box-shadow: var(--shadow-md);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.logo {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.logo-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--color-gold), var(--color-gold-dark));
  border-radius: 4px;
}

.logo-icon svg {
  width: 32px;
  height: 32px;
  fill: var(--color-white);
}

.logo-text {
  font-family: var(--font-heading-cn);
  font-size: 1.25rem;
  color: var(--color-text);
  line-height: 1.2;
}

.logo-text span {
  display: block;
  font-size: 0.7rem;
  color: var(--color-gold);
  letter-spacing: 2px;
  text-transform: uppercase;
}

.nav {
  display: flex;
  gap: var(--space-xl);
}

.nav-link {
  position: relative;
  font-size: 0.95rem;
  color: var(--color-text);
  padding: var(--space-sm) 0;
  transition: color var(--transition-fast);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--color-gold);
  transition: width var(--transition-base);
}

.nav-link:hover,
.nav-link.active {
  color: var(--color-gold);
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

/* Mobile Menu Toggle */
.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: var(--space-sm);
}

.menu-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-text);
  transition: all var(--transition-fast);
}

.menu-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.menu-toggle.active span:nth-child(2) {
  opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #F8F6F1 0%, #EDE8DC 50%, #F5F0E5 100%);
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M30 0L30 60M0 30L60 30' stroke='%23C9A962' stroke-width='0.5' opacity='0.1'/%3E%3C/svg%3E");
  opacity: 0.5;
}

.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 800px;
  padding: var(--space-lg);
  animation: fadeInUp 1s ease-out;
}

.hero-subtitle {
  font-family: var(--font-heading-en);
  font-size: 1rem;
  color: var(--color-gold);
  letter-spacing: 4px;
  text-transform: uppercase;
  margin-bottom: var(--space-lg);
}

.hero-title {
  font-family: var(--font-heading-cn);
  font-size: clamp(2.5rem, 6vw, 4rem);
  color: var(--color-text);
  margin-bottom: var(--space-lg);
  line-height: 1.2;
}

.hero-desc {
  font-size: 1.125rem;
  color: var(--color-text-light);
  margin-bottom: var(--space-2xl);
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.hero-decoration {
  position: absolute;
  width: 300px;
  height: 300px;
  border: 1px solid var(--color-gold-light);
  border-radius: 50%;
  opacity: 0.3;
}

.hero-decoration-1 {
  top: 10%;
  right: -100px;
  animation: scaleIn 2s ease-out;
}

.hero-decoration-2 {
  bottom: 10%;
  left: -150px;
  width: 400px;
  height: 400px;
  animation: scaleIn 2.5s ease-out 0.3s both;
}

/* Page Hero (smaller) */
.hero-page {
  min-height: 50vh;
  padding-top: var(--header-height);
}

.hero-page .hero-title {
  font-size: clamp(2rem, 5vw, 3rem);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  padding: var(--space-md) var(--space-xl);
  font-size: 0.95rem;
  font-weight: 500;
  border-radius: 4px;
  transition: all var(--transition-base);
  cursor: pointer;
}

.btn-primary {
  background: linear-gradient(135deg, var(--color-gold), var(--color-gold-dark));
  color: var(--color-white);
  box-shadow: 0 4px 15px rgba(201, 169, 98, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(201, 169, 98, 0.4);
}

.btn-secondary {
  background: transparent;
  color: var(--color-gold);
  border: 1px solid var(--color-gold);
}

.btn-secondary:hover {
  background: var(--color-gold);
  color: var(--color-white);
}

.btn-text {
  padding: var(--space-sm) 0;
  color: var(--color-gold);
}

.btn-text:hover {
  color: var(--color-gold-dark);
}

.btn-text::after {
  content: '→';
  margin-left: var(--space-sm);
  transition: transform var(--transition-fast);
}

.btn-text:hover::after {
  transform: translateX(5px);
}

/* ---------- Section Header ---------- */
.section-header {
  text-align: center;
  margin-bottom: var(--space-3xl);
}

.section-label {
  font-family: var(--font-heading-en);
  font-size: 0.875rem;
  color: var(--color-gold);
  letter-spacing: 3px;
  text-transform: uppercase;
  margin-bottom: var(--space-md);
}

.section-title {
  font-family: var(--font-heading-cn);
  color: var(--color-text);
  margin-bottom: var(--space-md);
}

.section-desc {
  font-size: 1rem;
  color: var(--color-text-light);
  max-width: 600px;
  margin: 0 auto;
}

.section-divider {
  width: 60px;
  height: 2px;
  background: linear-gradient(90deg, var(--color-gold), var(--color-gold-light));
  margin: var(--space-lg) auto 0;
}

/* ---------- Cards ---------- */
.card {
  background: var(--color-white);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-base);
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.card-image {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4/3;
}

.card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.card:hover .card-image img {
  transform: scale(1.05);
}

.card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.4), transparent);
  opacity: 0;
  transition: opacity var(--transition-base);
}

.card:hover .card-overlay {
  opacity: 1;
}

.card-content {
  padding: var(--space-lg);
}

.card-title {
  font-family: var(--font-heading-cn);
  font-size: 1.125rem;
  margin-bottom: var(--space-sm);
}

.card-desc {
  font-size: 0.875rem;
  color: var(--color-text-light);
  line-height: 1.6;
}

.card-meta {
  font-size: 0.75rem;
  color: var(--color-text-light);
  margin-top: var(--space-md);
}

/* Product Card */
.product-card .card-image {
  aspect-ratio: 1/1;
}

.product-card .card-tag {
  position: absolute;
  top: var(--space-md);
  left: var(--space-md);
  padding: var(--space-xs) var(--space-sm);
  background: var(--color-gold);
  color: var(--color-white);
  font-size: 0.75rem;
  border-radius: 2px;
}

/* News Card */
.news-card .card-date {
  display: inline-block;
  padding: var(--space-xs) var(--space-sm);
  background: var(--color-bg-dark);
  color: var(--color-gold);
  font-size: 0.75rem;
  border-radius: 2px;
  margin-bottom: var(--space-sm);
}

/* Feature Card */
.feature-card {
  text-align: center;
  padding: var(--space-2xl);
  background: var(--color-white);
  border-radius: 8px;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-base);
}

.feature-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
}

.feature-icon {
  width: 72px;
  height: 72px;
  margin: 0 auto var(--space-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--color-gold-pale), var(--color-bg));
  border-radius: 50%;
  transition: all var(--transition-base);
}

.feature-card:hover .feature-icon {
  background: linear-gradient(135deg, var(--color-gold), var(--color-gold-dark));
}

.feature-icon svg {
  width: 32px;
  height: 32px;
  stroke: var(--color-gold);
  stroke-width: 1.5;
  fill: none;
  transition: stroke var(--transition-base);
}

.feature-card:hover .feature-icon svg {
  stroke: var(--color-white);
}

.feature-title {
  font-family: var(--font-heading-cn);
  font-size: 1.25rem;
  margin-bottom: var(--space-md);
}

.feature-desc {
  font-size: 0.9rem;
  color: var(--color-text-light);
  line-height: 1.7;
}

/* Category Card */
.category-card {
  position: relative;
  height: 300px;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
}

.category-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent 40%, rgba(0,0,0,0.7));
  z-index: 1;
  transition: background var(--transition-base);
}

.category-card:hover::before {
  background: linear-gradient(to bottom, rgba(201,169,98,0.3) 0%, rgba(0,0,0,0.8) 100%);
}

.category-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.category-card:hover img {
  transform: scale(1.1);
}

.category-content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: var(--space-xl);
  z-index: 2;
  color: var(--color-white);
}

.category-title {
  font-family: var(--font-heading-cn);
  font-size: 1.5rem;
  margin-bottom: var(--space-sm);
}

.category-desc {
  font-size: 0.875rem;
  opacity: 0.8;
}

/* ---------- Stats ---------- */
.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-xl);
  padding: var(--space-3xl) 0;
  background: linear-gradient(135deg, var(--color-text) 0%, #1a1a1a 100%);
}

.stat-item {
  text-align: center;
  color: var(--color-white);
}

.stat-number {
  font-family: var(--font-heading-en);
  font-size: clamp(2.5rem, 5vw, 3.5rem);
  color: var(--color-gold);
  margin-bottom: var(--space-sm);
}

.stat-label {
  font-size: 0.9rem;
  opacity: 0.8;
}

/* ---------- Partners ---------- */
.partners {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-2xl);
  opacity: 0.6;
}

.partner-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-md) var(--space-xl);
  font-family: var(--font-heading-en);
  font-size: 1.25rem;
  color: var(--color-text);
  border: 1px solid var(--color-border);
  border-radius: 4px;
  transition: all var(--transition-base);
}

.partner-logo:hover {
  border-color: var(--color-gold);
  color: var(--color-gold);
}

/* ---------- Timeline ---------- */
.timeline {
  position: relative;
  padding-left: var(--space-2xl);
}

.timeline::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--color-gold), var(--color-gold-light));
}

.timeline-item {
  position: relative;
  padding-bottom: var(--space-2xl);
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: calc(-1 * var(--space-2xl) - 5px);
  top: 0;
  width: 12px;
  height: 12px;
  background: var(--color-gold);
  border-radius: 50%;
  border: 3px solid var(--color-bg);
}

.timeline-year {
  font-family: var(--font-heading-en);
  font-size: 1.25rem;
  color: var(--color-gold);
  margin-bottom: var(--space-sm);
}

.timeline-title {
  font-family: var(--font-heading-cn);
  font-size: 1.125rem;
  margin-bottom: var(--space-sm);
}

.timeline-desc {
  font-size: 0.9rem;
  color: var(--color-text-light);
}

/* ---------- Gallery ---------- */
.gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-md);
}

.gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: 8px;
  cursor: pointer;
}

.gallery-item img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.gallery-item:hover img {
  transform: scale(1.1);
}

.gallery-item::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(201, 169, 98, 0);
  transition: background var(--transition-base);
}

.gallery-item:hover::after {
  background: rgba(201, 169, 98, 0.2);
}

/* ---------- Tags ---------- */
.tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
}

.tag {
  display: inline-block;
  padding: var(--space-xs) var(--space-md);
  font-size: 0.8rem;
  background: var(--color-bg-dark);
  color: var(--color-text-light);
  border-radius: 20px;
  transition: all var(--transition-fast);
  cursor: pointer;
}

.tag:hover,
.tag.active {
  background: var(--color-gold);
  color: var(--color-white);
}

/* ---------- Form Elements ---------- */
.form-group {
  margin-bottom: var(--space-lg);
}

.form-label {
  display: block;
  font-size: 0.9rem;
  color: var(--color-text);
  margin-bottom: var(--space-sm);
}

.form-input,
.form-textarea,
.form-select {
  width: 100%;
  padding: var(--space-md);
  font-size: 1rem;
  color: var(--color-text);
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: 4px;
  transition: all var(--transition-fast);
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
  outline: none;
  border-color: var(--color-gold);
  box-shadow: 0 0 0 3px rgba(201, 169, 98, 0.1);
}

.form-textarea {
  min-height: 150px;
  resize: vertical;
}

.form-input::placeholder,
.form-textarea::placeholder {
  color: #aaa;
}

/* ---------- Pagination ---------- */
.pagination {
  display: flex;
  justify-content: center;
  gap: var(--space-sm);
  margin-top: var(--space-2xl);
}

.pagination-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  font-size: 0.9rem;
  color: var(--color-text);
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: 4px;
  transition: all var(--transition-fast);
}

.pagination-btn:hover,
.pagination-btn.active {
  background: var(--color-gold);
  border-color: var(--color-gold);
  color: var(--color-white);
}

/* ---------- Back to Top ---------- */
.back-to-top {
  position: fixed;
  bottom: var(--space-xl);
  right: var(--space-xl);
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-gold);
  color: var(--color-white);
  border-radius: 50%;
  box-shadow: var(--shadow-md);
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-base);
  cursor: pointer;
  z-index: 999;
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
}

.back-to-top:hover {
  background: var(--color-gold-dark);
  transform: translateY(-3px);
}

.back-to-top svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
}

/* ---------- CTA Section ---------- */
.cta-section {
  position: relative;
  padding: var(--space-4xl) 0;
  background: linear-gradient(135deg, var(--color-text) 0%, #1a1a1a 100%);
  text-align: center;
  overflow: hidden;
}

.cta-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Ccircle cx='50' cy='50' r='40' stroke='%23C9A962' stroke-width='0.5' fill='none' opacity='0.1'/%3E%3C/svg%3E");
  opacity: 0.5;
}

.cta-content {
  position: relative;
  z-index: 1;
}

.cta-title {
  font-family: var(--font-heading-cn);
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  color: var(--color-white);
  margin-bottom: var(--space-lg);
}

.cta-desc {
  font-size: 1rem;
  color: rgba(255,255,255,0.7);
  margin-bottom: var(--space-xl);
}

/* ---------- Loading ---------- */
.loading {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 2px solid var(--color-gold-light);
  border-top-color: var(--color-gold);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ---------- Responsive ---------- */
@media (max-width: 992px) {
  .nav {
    position: fixed;
    top: var(--header-height);
    left: 0;
    right: 0;
    background: var(--color-white);
    flex-direction: column;
    padding: var(--space-xl);
    gap: var(--space-md);
    box-shadow: var(--shadow-md);
    transform: translateY(-100%);
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-base);
  }

  .nav.active {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }

  .menu-toggle {
    display: flex;
  }

  .stats {
    grid-template-columns: repeat(2, 1fr);
  }

  .gallery {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .hero {
    min-height: 80vh;
  }

  .stats {
    grid-template-columns: 1fr 1fr;
    gap: var(--space-lg);
    padding: var(--space-2xl) var(--space-lg);
  }

  .gallery {
    grid-template-columns: 1fr 1fr;
  }

  .section-header {
    margin-bottom: var(--space-2xl);
  }
}

@media (max-width: 480px) {
  .logo-text {
    font-size: 1rem;
  }

  .logo-text span {
    display: none;
  }

  .hero-content {
    padding: var(--space-md);
  }

  .stats {
    grid-template-columns: 1fr;
  }

  .gallery {
    grid-template-columns: 1fr;
  }

  .back-to-top {
    right: var(--space-md);
    bottom: var(--space-md);
    width: 40px;
    height: 40px;
  }
}
