/* ============================================
   深圳美德兰电气有限公司 - 企业官网样式
   ============================================ */

/* --- CSS Variables --- */
:root {
  --primary: #CC0000;
  --primary-dark: #990000;
  --primary-light: #FF4444;
  --primary-gradient: linear-gradient(135deg, #CC0000 0%, #FF3333 100%);
  --primary-gradient-dark: linear-gradient(135deg, #990000 0%, #CC0000 100%);
  --dark: #1a1a2e;
  --dark-secondary: #2d2d44;
  --text: #333333;
  --text-light: #666666;
  --text-lighter: #999999;
  --bg: #ffffff;
  --bg-light: #f8f9fa;
  --bg-dark: #1a1a2e;
  --border: #e8e8e8;
  --shadow: 0 4px 20px rgba(0,0,0,0.08);
  --shadow-lg: 0 10px 40px rgba(0,0,0,0.12);
  --shadow-hover: 0 8px 30px rgba(204,0,0,0.15);
  --radius: 12px;
  --radius-lg: 20px;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --font-family: 'PingFang SC', 'Microsoft YaHei', 'Helvetica Neue', Arial, sans-serif;
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-family);
  color: var(--text);
  line-height: 1.7;
  overflow-x: hidden;
  background: var(--bg);
}

a { text-decoration: none; color: inherit; transition: var(--transition); }
img { max-width: 100%; height: auto; display: block; }
ul { list-style: none; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }

.section-header {
  text-align: center;
  margin-bottom: 60px;
}

.section-header .subtitle {
  display: inline-block;
  color: var(--primary);
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  margin-bottom: 12px;
  position: relative;
}

.section-header .subtitle::before,
.section-header .subtitle::after {
  content: '';
  display: inline-block;
  width: 30px;
  height: 2px;
  background: var(--primary);
  vertical-align: middle;
  margin: 0 10px;
}

.section-header h2 {
  font-size: 2.2rem;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 16px;
}

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

section {
  padding: 100px 0;
}

/* --- Navigation --- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 18px 0;
  transition: var(--transition);
}

.navbar.scrolled {
  background: rgba(255,255,255,0.97);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 2px 30px rgba(0,0,0,0.08);
  padding: 10px 0;
}

.navbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.navbar .logo {
  display: flex;
  align-items: center;
  gap: 12px;
}

.navbar .logo-icon {
  width: 42px;
  height: 42px;
  background: var(--primary-gradient);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  color: #fff;
  font-weight: 700;
}

.navbar .logo-text {
  display: flex;
  flex-direction: column;
}

.navbar .logo-text .cn {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--dark);
  line-height: 1.3;
}

.navbar .logo-text .en {
  font-size: 0.7rem;
  color: var(--text-light);
  letter-spacing: 1px;
}

.navbar .nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
}

.navbar .nav-links a {
  font-size: 0.95rem;
  color: var(--dark);
  font-weight: 500;
  position: relative;
  padding: 4px 0;
}

.navbar .nav-links a::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--primary);
  transition: var(--transition);
}

.navbar .nav-links a:hover::after,
.navbar .nav-links a.active::after {
  width: 100%;
}

.navbar .nav-links a:hover {
  color: var(--primary);
}

.navbar .nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 4px;
  z-index: 1001;
}

.navbar .nav-toggle span {
  display: block;
  width: 26px;
  height: 2.5px;
  background: var(--dark);
  border-radius: 2px;
  transition: var(--transition);
}

.navbar .nav-toggle.active span:nth-child(1) {
  transform: translateY(7.5px) rotate(45deg);
}

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

.navbar .nav-toggle.active span:nth-child(3) {
  transform: translateY(-7.5px) rotate(-45deg);
}

/* --- Hero Section --- */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  background: linear-gradient(135deg, #1a1a2e 0%, #2d2d44 50%, #1a1a2e 100%);
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 60%;
  height: 100%;
  background: radial-gradient(ellipse at center, rgba(204,0,0,0.08) 0%, transparent 70%);
  pointer-events: none;
}

.hero-particles {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  overflow: hidden;
  pointer-events: none;
}

.particle {
  position: absolute;
  width: 4px;
  height: 4px;
  background: rgba(255,255,255,0.15);
  border-radius: 50%;
  animation: float 6s infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0) translateX(0); opacity: 0.3; }
  25% { transform: translateY(-30px) translateX(10px); opacity: 0.6; }
  50% { transform: translateY(-60px) translateX(-5px); opacity: 0.8; }
  75% { transform: translateY(-30px) translateX(15px); opacity: 0.6; }
}

.hero .hero-content {
  position: relative;
  z-index: 2;
  max-width: 720px;
}

.hero .hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(204,0,0,0.15);
  border: 1px solid rgba(204,0,0,0.3);
  padding: 8px 20px;
  border-radius: 50px;
  font-size: 0.85rem;
  color: #FF6666;
  margin-bottom: 30px;
  animation: fadeInUp 0.8s ease;
}

.hero .hero-badge .dot {
  width: 8px;
  height: 8px;
  background: #FF4444;
  border-radius: 50%;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(0.8); }
}

.hero h1 {
  font-size: 3.5rem;
  font-weight: 800;
  color: #fff;
  line-height: 1.2;
  margin-bottom: 10px;
  animation: fadeInUp 0.8s ease 0.1s both;
}

.hero h1 .highlight {
  background: var(--primary-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero .hero-subtitle {
  font-size: 1.3rem;
  color: rgba(255,255,255,0.8);
  margin-bottom: 20px;
  font-weight: 300;
  animation: fadeInUp 0.8s ease 0.2s both;
}

.hero .hero-desc {
  font-size: 1.05rem;
  color: rgba(255,255,255,0.6);
  line-height: 1.8;
  margin-bottom: 40px;
  max-width: 600px;
  animation: fadeInUp 0.8s ease 0.3s both;
}

.hero .hero-buttons {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  animation: fadeInUp 0.8s ease 0.4s both;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  border-radius: 50px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  border: none;
  font-family: var(--font-family);
}

.btn-primary {
  background: var(--primary-gradient);
  color: #fff;
  box-shadow: 0 4px 20px rgba(204,0,0,0.35);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(204,0,0,0.45);
}

.btn-outline {
  background: transparent;
  color: #fff;
  border: 2px solid rgba(255,255,255,0.3);
}

.btn-outline:hover {
  border-color: var(--primary);
  background: rgba(204,0,0,0.1);
  transform: translateY(-2px);
}

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Hero Stats Bar */
.hero-stats {
  position: absolute;
  bottom: -40px;
  left: 0;
  right: 0;
  z-index: 3;
}

.hero-stats .stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  background: #fff;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 35px 20px;
}

.hero-stats .stat-item {
  text-align: center;
  padding: 0 20px;
  border-right: 1px solid var(--border);
}

.hero-stats .stat-item:last-child {
  border-right: none;
}

.hero-stats .stat-number {
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--primary);
  line-height: 1.2;
}

.hero-stats .stat-label {
  font-size: 0.9rem;
  color: var(--text-light);
  margin-top: 4px;
}

/* --- About Section --- */
.about {
  padding-top: 140px;
  background: var(--bg);
}

.about .about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.about .about-image {
  position: relative;
}

.about .about-image-placeholder {
  width: 100%;
  aspect-ratio: 4/3;
  background: var(--bg-light);
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--text-lighter);
  gap: 16px;
  font-size: 1rem;
  position: relative;
  overflow: hidden;
}

.about .about-image-placeholder .icon {
  font-size: 3rem;
  opacity: 0.5;
}

.about .about-image-placeholder::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: conic-gradient(from 0deg, transparent, rgba(204,0,0,0.05), transparent, rgba(204,0,0,0.05), transparent);
  animation: rotate 10s linear infinite;
}

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

.about .about-image-placeholder .content {
  position: relative;
  z-index: 1;
  text-align: center;
}

.about .about-text h3 {
  font-size: 1.8rem;
  color: var(--dark);
  margin-bottom: 20px;
  line-height: 1.4;
}

.about .about-text p {
  color: var(--text-light);
  margin-bottom: 16px;
  font-size: 1rem;
  line-height: 1.8;
}

.about .about-features {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 30px;
}

.about .about-features li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.95rem;
  color: var(--text);
}

.about .about-features li .check {
  color: var(--primary);
  font-weight: 700;
  font-size: 1.1rem;
}

/* --- Advantages Section --- */
.advantages {
  background: var(--bg-light);
}

.advantages .advantages-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.advantage-card {
  background: #fff;
  border-radius: var(--radius);
  padding: 40px 30px;
  text-align: center;
  box-shadow: var(--shadow);
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.advantage-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--primary-gradient);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s ease;
}

.advantage-card:hover::before {
  transform: scaleX(1);
}

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

.advantage-card .card-icon {
  width: 70px;
  height: 70px;
  margin: 0 auto 24px;
  background: linear-gradient(135deg, rgba(204,0,0,0.1), rgba(204,0,0,0.05));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  transition: var(--transition);
}

.advantage-card:hover .card-icon {
  background: var(--primary-gradient);
  color: #fff;
}

.advantage-card h3 {
  font-size: 1.2rem;
  color: var(--dark);
  margin-bottom: 14px;
}

.advantage-card p {
  color: var(--text-light);
  font-size: 0.95rem;
  line-height: 1.7;
}

/* --- Products Section --- */
.products {
  background: var(--bg);
}

.products .products-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.product-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 35px 28px;
  transition: var(--transition);
  text-align: center;
}

.product-card:hover {
  border-color: var(--primary);
  box-shadow: var(--shadow-hover);
  transform: translateY(-5px);
}

.product-card .product-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto 20px;
  background: var(--bg-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  transition: var(--transition);
}

.product-card:hover .product-icon {
  background: rgba(204,0,0,0.1);
}

.product-card h3 {
  font-size: 1.15rem;
  color: var(--dark);
  margin-bottom: 12px;
}

.product-card p {
  font-size: 0.9rem;
  color: var(--text-light);
  line-height: 1.7;
}

.product-card .product-tag {
  display: inline-block;
  margin-top: 16px;
  padding: 4px 16px;
  background: rgba(204,0,0,0.08);
  color: var(--primary);
  font-size: 0.8rem;
  border-radius: 50px;
  font-weight: 500;
}

/* --- History Timeline --- */
.history {
  background: var(--bg-light);
}

.timeline {
  position: relative;
  max-width: 800px;
  margin: 0 auto;
}

.timeline::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 3px;
  height: 100%;
  background: linear-gradient(to bottom, var(--primary), rgba(204,0,0,0.2));
  border-radius: 2px;
}

.timeline-item {
  position: relative;
  display: flex;
  justify-content: flex-start;
  padding-bottom: 60px;
}

.timeline-item:last-child {
  padding-bottom: 0;
}

.timeline-item:nth-child(even) {
  justify-content: flex-end;
}

.timeline-item .timeline-dot {
  position: absolute;
  left: 50%;
  top: 8px;
  transform: translateX(-50%);
  width: 18px;
  height: 18px;
  background: var(--primary);
  border: 4px solid #fff;
  border-radius: 50%;
  box-shadow: 0 0 0 3px var(--primary), 0 2px 10px rgba(204,0,0,0.3);
  z-index: 2;
}

.timeline-item .timeline-content {
  width: calc(50% - 45px);
  background: #fff;
  padding: 28px 30px;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  transition: var(--transition);
}

.timeline-item .timeline-content:hover {
  box-shadow: var(--shadow-hover);
  transform: translateY(-3px);
}

.timeline-item .timeline-phase {
  display: inline-block;
  padding: 4px 14px;
  background: var(--primary);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: 50px;
  margin-bottom: 10px;
  letter-spacing: 1px;
}

.timeline-item .timeline-content h3 {
  font-size: 1.1rem;
  color: var(--dark);
  margin-bottom: 10px;
}

.timeline-item .timeline-content p {
  font-size: 0.92rem;
  color: var(--text-light);
  line-height: 1.7;
}

/* --- Footer --- */
.footer {
  background: var(--dark);
  color: rgba(255,255,255,0.7);
  padding: 60px 0 0;
}

.footer .footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 40px;
}

.footer .footer-brand .logo-icon {
  width: 42px;
  height: 42px;
  background: var(--primary-gradient);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  color: #fff;
  font-weight: 700;
  margin-bottom: 16px;
}

.footer .footer-brand h3 {
  font-size: 1.1rem;
  color: #fff;
  margin-bottom: 12px;
}

.footer .footer-brand p {
  font-size: 0.9rem;
  line-height: 1.7;
  max-width: 300px;
}

.footer h4 {
  color: #fff;
  font-size: 1rem;
  margin-bottom: 20px;
  position: relative;
  padding-bottom: 10px;
}

.footer h4::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 30px;
  height: 2px;
  background: var(--primary);
}

.footer ul li {
  margin-bottom: 12px;
}

.footer ul a {
  font-size: 0.9rem;
  color: rgba(255,255,255,0.6);
  transition: var(--transition);
}

.footer ul a:hover {
  color: var(--primary);
  padding-left: 4px;
}

.footer .footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding: 20px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.85rem;
}

/* --- Scroll To Top --- */
.scroll-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 50px;
  height: 50px;
  background: var(--primary-gradient);
  color: #fff;
  border: none;
  border-radius: 50%;
  font-size: 1.2rem;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(204,0,0,0.35);
  transition: var(--transition);
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  z-index: 999;
}

.scroll-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.scroll-top:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 30px rgba(204,0,0,0.45);
}

/* --- Animations --- */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.animate-on-scroll.animated {
  opacity: 1;
  transform: translateY(0);
}

/* --- Responsive --- */
@media (max-width: 992px) {
  .hero h1 { font-size: 2.6rem; }
  .hero .hero-subtitle { font-size: 1.1rem; }
  .hero-stats .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 20px; }
  .hero-stats .stat-item { border-right: none; padding: 10px; }
  .hero-stats .stat-item:nth-child(2) { border-right: 1px solid var(--border); }
  .advantages .advantages-grid,
  .products .products-grid { grid-template-columns: repeat(2, 1fr); }
  .footer .footer-grid { grid-template-columns: 1fr 1fr; }
  .timeline::before { left: 20px; }
  .timeline-item { justify-content: flex-start !important; padding-left: 50px; }
  .timeline-item .timeline-dot { left: 20px; }
  .timeline-item .timeline-content { width: 100%; }
  .section-header h2 { font-size: 1.8rem; }
}

@media (max-width: 768px) {
  .navbar .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background: #fff;
    flex-direction: column;
    padding: 80px 30px 30px;
    gap: 20px;
    box-shadow: -5px 0 30px rgba(0,0,0,0.1);
    transition: right 0.3s ease;
    align-items: flex-start;
  }

  .navbar .nav-links.open { right: 0; }
  .navbar .nav-toggle { display: flex; }

  .hero { min-height: 90vh; }
  .hero h1 { font-size: 2rem; }
  .hero .hero-desc { font-size: 0.95rem; }
  .hero .hero-buttons { flex-direction: column; }
  .hero .hero-buttons .btn { width: 100%; justify-content: center; }

  section { padding: 60px 0; }

  .about { padding-top: 100px; }

  .about .about-features { grid-template-columns: 1fr; }

  .advantages .advantages-grid,
  .products .products-grid { grid-template-columns: 1fr; }


  .footer .footer-grid { grid-template-columns: 1fr; }
  .footer .footer-bottom { flex-direction: column; gap: 10px; text-align: center; }

  .hero-stats .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .hero-stats .stat-item { border-right: none; }
  .hero-stats .stat-number { font-size: 1.8rem; }
  .section-header { margin-bottom: 40px; }
  .section-header h2 { font-size: 1.5rem; }

}
