/* ========================================
   Xtone - Dafang Stone Group
   Style matches Apexstone design system
   ======================================== */

/* Reset & Base */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --charcoal: #1a1a2e;
  --accent: #c9a96e;
  --accent-hover: #b8944f;
  --white: #ffffff;
  --light-gray: #f5f5f5;
  --text: #222222;
  --text-muted: #666666;
  --border: #e0e0e0;
  --shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  --shadow-hover: 0 4px 16px rgba(0, 0, 0, 0.12);
}

html { scroll-behavior: smooth; }
section[id] { scroll-margin-top: 80px; }

body {
  font-family: -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Microsoft YaHei', 'Segoe UI', Roboto, sans-serif;
  color: var(--text);
  background: var(--white);
  line-height: 1.6;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; }

.container { max-width: 1280px; margin: 0 auto; padding: 0 24px; }
.section-padding { padding: 80px 0; }

/* ========================================
   Header
   ======================================== */
.header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  background: var(--charcoal);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 72px;
}
.logo {
  font-size: 1.5rem; font-weight: 700; color: var(--white);
  letter-spacing: 2px;
}
.logo span { color: var(--accent); }
.logo img { height: 40px; width: auto; display: block; }
.nav { display: flex; align-items: center; gap: 32px; }
.nav a {
  color: rgba(255,255,255,0.8); font-size: 0.9rem; font-weight: 500;
  transition: color 0.2s;
}
.nav a:hover { color: var(--accent); }
.lang-switch {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 16px; border: 1px solid rgba(255,255,255,0.3);
  border-radius: 4px; color: var(--white); font-size: 0.85rem;
  transition: all 0.2s;
}
.lang-switch:hover { border-color: var(--accent); color: var(--accent); }

/* ========================================
   Hero Section (matches Apexstone about)
   ======================================== */
.hero {
  position: relative; height: 520px; background: var(--charcoal);
  overflow: hidden; display: flex; align-items: center;
}
.hero-slides {
  position: absolute; inset: 0;
}
.hero-slide {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
  opacity: 0; transition: opacity 1.2s ease-in-out;
}
.hero-slide.active { opacity: 1; }
.hero::before {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(26,26,46,0.40) 0%, rgba(45,45,68,0.25) 100%);
  z-index: 1;
}
.hero-dots {
  position: absolute; bottom: 24px; left: 50%; transform: translateX(-50%);
  z-index: 3; display: flex; gap: 10px;
}
.hero-dot {
  width: 10px; height: 10px; border-radius: 50%;
  background: rgba(255,255,255,0.4); border: none; cursor: pointer;
  padding: 0; transition: background 0.3s;
}
.hero-dot.active { background: var(--accent); }
.hero-arrow {
  position: absolute; top: 50%; transform: translateY(-50%);
  z-index: 3; width: 44px; height: 44px; border-radius: 50%;
  background: rgba(0,0,0,0.3); border: none; color: #fff;
  font-size: 20px; cursor: pointer; display: flex;
  align-items: center; justify-content: center;
  transition: background 0.3s;
}
.hero-arrow:hover { background: rgba(0,0,0,0.6); }
.hero-arrow.prev { left: 20px; }
.hero-arrow.next { right: 20px; }
.hero-content {
  position: relative; z-index: 1;
  max-width: 720px;
}
.hero h1 {
  font-size: 2.75rem; font-weight: 700; color: var(--white);
  margin-bottom: 16px; line-height: 1.2;
}
.hero .subtitle {
  font-size: 1.25rem; color: var(--accent); font-weight: 600;
  margin-bottom: 8px;
}
.hero .desc {
  font-size: 1rem; color: rgba(255,255,255,0.7);
  max-width: 560px;
}

/* ========================================
   Company Intro Section
   ======================================== */
.intro-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 48px;
  align-items: center;
}
.intro-text h2 {
  font-size: 1.875rem; font-weight: 700; color: var(--charcoal);
  margin-bottom: 24px;
}
.intro-text p {
  font-size: 1rem; color: var(--text-muted); line-height: 1.8;
  margin-bottom: 24px;
}
.intro-badges {
  display: grid; grid-template-columns: 1fr 1fr; gap: 12px;
}
.badge-item {
  display: flex; align-items: center; gap: 10px;
}
.badge-item svg { width: 20px; height: 20px; color: var(--accent); flex-shrink: 0; }
.badge-item span { font-size: 0.875rem; color: var(--text); }
.intro-image {
  aspect-ratio: 4/3; background: linear-gradient(135deg, #e8e8e8, #d4d4d4);
  border-radius: 8px; position: relative; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
}
.intro-image img { width: 100%; height: 100%; object-fit: cover; }
.intro-image .label {
  position: absolute; bottom: 16px; left: 16px;
  background: var(--charcoal); color: var(--white);
  padding: 8px 16px; border-radius: 4px; font-size: 0.8rem; font-weight: 600;
}

/* ========================================
   Stats Section (Factory Capabilities style)
   ======================================== */
.stats-section { background: var(--light-gray); }
.stats-header { text-align: center; margin-bottom: 48px; }
.stats-header h2 {
  font-size: 1.875rem; font-weight: 700; color: var(--charcoal);
  margin-bottom: 12px;
}
.stats-header p { color: var(--text-muted); }
.stats-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px;
}
.stat-card {
  background: var(--white); border-radius: 8px; padding: 32px 24px;
  text-align: center; box-shadow: var(--shadow);
  transition: all 0.3s ease;
}
.stat-card:hover {
  transform: translateY(-4px); box-shadow: var(--shadow-hover);
}
.stat-icon {
  width: 64px; height: 64px; margin: 0 auto 16px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%; background: rgba(201, 169, 110, 0.1);
}
.stat-icon svg { width: 32px; height: 32px; color: var(--accent); }
.stat-number {
  font-size: 1.5rem; font-weight: 700; color: var(--charcoal);
  margin-bottom: 8px;
}
.stat-label { font-size: 0.875rem; color: var(--text-muted); }

/* ========================================
   Business Section (Three Brands)
   ======================================== */
.business-header { text-align: center; margin-bottom: 48px; }
.business-header h2 {
  font-size: 1.875rem; font-weight: 700; color: var(--charcoal);
  margin-bottom: 12px;
}
.business-header p { color: var(--text-muted); max-width: 600px; margin: 0 auto; }
.business-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px;
}
.business-card {
  background: var(--white); border-radius: 12px; overflow: hidden;
  box-shadow: var(--shadow); transition: all 0.3s ease;
  border: 1px solid var(--border);
}
.business-card:hover {
  transform: translateY(-6px); box-shadow: var(--shadow-hover);
}
.card-image {
  height: 200px; background: linear-gradient(135deg, #e8e8e8, #d4d4d4);
  display: flex; align-items: center; justify-content: center;
  position: relative; overflow: hidden;
}
.card-image img { width: 100%; height: 100%; object-fit: cover; }
.card-image .brand-tag {
  position: absolute; top: 16px; left: 16px;
  background: var(--accent); color: var(--white);
  padding: 4px 12px; border-radius: 4px; font-size: 0.75rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: 1px;
}
.card-content { padding: 24px; }
.card-brand-logo { height: 48px; width: auto; max-width: 160px; object-fit: contain; margin-bottom: 12px; display: block; }
.card-content h3 {
  font-size: 1.25rem; font-weight: 700; color: var(--charcoal);
  margin-bottom: 8px;
}
.card-content .card-subtitle {
  font-size: 0.875rem; color: var(--accent); font-weight: 600;
  margin-bottom: 12px;
}
.card-content p {
  font-size: 0.9rem; color: var(--text-muted); line-height: 1.6;
  margin-bottom: 20px;
}
.card-link {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 0.875rem; font-weight: 600; color: var(--accent);
  transition: gap 0.2s;
}
.card-link:hover { gap: 10px; }
.card-link svg { width: 16px; height: 16px; }

/* ========================================
   Global Presence Section
   ======================================== */
.presence-section { background: var(--light-gray); }
.presence-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 48px;
  align-items: center;
}
.presence-text h2 {
  font-size: 1.875rem; font-weight: 700; color: var(--charcoal);
  margin-bottom: 24px;
}
.presence-text p {
  font-size: 1rem; color: var(--text-muted); line-height: 1.8;
  margin-bottom: 24px;
}
.region-list { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.region-item {
  background: var(--white); padding: 12px 16px; border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}
.region-item .region-name { font-size: 0.85rem; color: var(--text-muted); }
.region-item .region-count { font-size: 1.1rem; font-weight: 700; color: var(--charcoal); }
.presence-image {
  aspect-ratio: 4/3; background: linear-gradient(135deg, #e8e8e8, #d4d4d4);
  border-radius: 8px; position: relative; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
}
.presence-image img { width: 100%; height: 100%; object-fit: cover; }
.presence-image .label {
  position: absolute; bottom: 16px; left: 16px;
  background: var(--charcoal); color: var(--white);
  padding: 8px 16px; border-radius: 4px; font-size: 0.8rem; font-weight: 600;
}

/* ========================================
   Footer
   ======================================== */
.footer { background: var(--charcoal); color: rgba(255,255,255,0.8); padding: 64px 0 0; }
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 48px;
  padding-bottom: 48px; border-bottom: 1px solid rgba(255,255,255,0.1);
}
.footer-brand .logo { margin-bottom: 16px; display: block; }
.footer-brand .logo img { height: 36px; width: auto; }
.footer-brand p { font-size: 0.875rem; line-height: 1.7; color: rgba(255,255,255,0.6); }
.footer-col h4 {
  font-size: 0.9rem; font-weight: 600; color: var(--white);
  margin-bottom: 16px; text-transform: uppercase; letter-spacing: 1px;
}
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 10px; }
.footer-col a {
  font-size: 0.875rem; color: rgba(255,255,255,0.6);
  transition: color 0.2s;
}
.footer-col a:hover { color: var(--accent); }
.footer-bottom {
  padding: 24px 0; text-align: center;
  font-size: 0.8rem; color: rgba(255,255,255,0.4);
}
.footer-bottom a { color: rgba(255,255,255,0.5); transition: color 0.2s; }
.footer-bottom a:hover { color: var(--accent); }

/* ========================================
   Responsive
   ======================================== */
@media (max-width: 1024px) {
  .intro-grid, .presence-grid { grid-template-columns: 1fr; }
  .intro-image, .presence-image { max-height: 300px; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .business-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
  .hero { height: 380px; }  .hero-arrow { display: none; }
  .hero h1 { font-size: 2rem; }
  .section-padding { padding: 48px 0; }
  .nav { display: none; }
  .stats-grid { grid-template-columns: 1fr 1fr; gap: 16px; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
}
