/* ========================================
   智云程科技官网 - 自定义样式
   ======================================== */

:root {
  --primary: #2563eb;
  --primary-dark: #1d4ed8;
  --primary-light: #dbeafe;
  --text-dark: #1e293b;
  --text-gray: #64748b;
  --bg-light: #f8fafc;
  --bg-white: #ffffff;
  --border: #e2e8f0;
  --shadow: 0 1px 3px rgba(0,0,0,0.1), 0 1px 2px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -1px rgba(0,0,0,0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -2px rgba(0,0,0,0.05);
  --radius: 8px;
  --radius-lg: 12px;
  --transition: all 0.3s ease;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Helvetica, Arial, sans-serif;
  color: var(--text-dark);
  line-height: 1.6;
  background: var(--bg-white);
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition);
}

img {
  max-width: 100%;
  height: auto;
}

/* ---- Layout ---- */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.section {
  padding: 100px 0;
}

.section-sm {
  padding: 72px 0;
}

.section-title {
  text-align: center;
  margin-bottom: 56px;
}

.section-title h2 {
  font-size: 32px;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 12px;
}

.section-title p {
  font-size: 16px;
  color: var(--text-gray);
  max-width: 600px;
  margin: 0 auto;
}

/* ---- Header / Navigation ---- */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255,255,255,0.95);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  transition: var(--transition);
}

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

.header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 20px;
  font-weight: 700;
  color: var(--primary);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
  transition: max-height 0.4s ease, opacity 0.3s ease, padding 0.3s ease;
}

.nav-links a {
  font-size: 15px;
  color: var(--text-gray);
  font-weight: 500;
  position: relative;
  padding: 4px 0;
}

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

.nav-links a.active::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--primary);
  border-radius: 1px;
}

.nav-links a.nav-cta.active::after {
  display: none;
}

.nav-cta {
  background: var(--primary);
  color: white !important;
  padding: 8px 20px !important;
  border-radius: 6px;
  font-weight: 600 !important;
}

.nav-cta:hover {
  background: var(--primary-dark) !important;
  color: white !important;
}

/* Mobile menu */
.mobile-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.mobile-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text-dark);
  margin: 6px 0;
  transition: var(--transition);
  border-radius: 2px;
}

.mobile-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 6px);
}
.mobile-toggle.active span:nth-child(2) {
  opacity: 0;
}
.mobile-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -6px);
}

/* ---- Hero ---- */
.hero {
  padding: 160px 0 100px;
  background: linear-gradient(135deg, #eff6ff 0%, #f0f9ff 50%, #faf5ff 100%);
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(37,99,235,0.08) 0%, transparent 70%);
  border-radius: 50%;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -30%;
  left: -10%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(124,58,237,0.06) 0%, transparent 70%);
  border-radius: 50%;
}

.hero .container {
  position: relative;
  z-index: 1;
}

.hero-content {
  max-width: 700px;
}

.hero-badge {
  display: inline-block;
  background: var(--primary-light);
  color: var(--primary);
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 24px;
}

.hero h1 {
  font-size: 48px;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 20px;
  color: var(--text-dark);
}

.hero h1 .highlight {
  background: linear-gradient(135deg, var(--primary), #7c3aed);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero p {
  font-size: 18px;
  color: var(--text-gray);
  margin-bottom: 36px;
  line-height: 1.8;
}

.hero-buttons {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

/* ---- Buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  border-radius: var(--radius);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: var(--transition);
}

.btn-primary {
  background: var(--primary);
  color: white;
  box-shadow: 0 4px 14px rgba(37,99,235,0.3);
}

.btn-primary:hover {
  background: var(--primary-dark);
  box-shadow: 0 6px 20px rgba(37,99,235,0.4);
  transform: translateY(-1px);
}

.btn-outline {
  background: white;
  color: var(--text-dark);
  border: 1px solid var(--border);
}

.btn-outline:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--primary-light);
}

/* ---- Product Cards ---- */
.products-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.product-card {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

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

.product-card-icon {
  width: 56px;
  height: 56px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  font-size: 24px;
}

.product-card-icon.blue {
  background: #dbeafe;
  color: #2563eb;
}

.product-card-icon.purple {
  background: #ede9fe;
  color: #7c3aed;
}

.product-card-icon.green {
  background: #d1fae5;
  color: #059669;
}

.product-card h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--text-dark);
}

.product-card p {
  font-size: 14px;
  color: var(--text-gray);
  line-height: 1.7;
  margin-bottom: 20px;
  flex: 1;
}

.product-card .tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.product-card .tag {
  background: #e2e8f0;
  color: #334155;
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 12px;
}

.product-card .card-link {
  color: var(--primary);
  font-weight: 600;
  font-size: 14px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.product-card .card-link:hover {
  gap: 8px;
}

/* ---- Stats ---- */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.stat-item {
  text-align: center;
  padding: 32px 16px;
  background: white;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
}

.stat-number {
  font-size: 40px;
  font-weight: 800;
  color: var(--primary);
  line-height: 1;
  margin-bottom: 8px;
}

.stat-label {
  font-size: 14px;
  color: var(--text-gray);
}

/* ---- Advantages ---- */
.advantages-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.advantage-item {
  display: flex;
  gap: 16px;
  padding: 24px;
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: var(--transition);
}

.advantage-item:hover {
  box-shadow: var(--shadow);
  border-color: var(--primary);
}

.advantage-icon {
  width: 48px;
  height: 48px;
  min-width: 48px;
  border-radius: 10px;
  background: var(--primary-light);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
}

.advantage-item h4 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 6px;
}

.advantage-item p {
  font-size: 14px;
  color: var(--text-gray);
  line-height: 1.6;
}

/* ---- About Preview ---- */
.about-preview {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.about-preview-content h2 {
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 20px;
}

.about-preview-content p {
  font-size: 16px;
  color: var(--text-gray);
  line-height: 1.8;
  margin-bottom: 16px;
}

.about-preview-content .btn {
  margin-top: 12px;
}

.about-preview-visual {
  background: linear-gradient(135deg, #eff6ff, #faf5ff);
  border-radius: var(--radius-lg);
  padding: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 320px;
}

.about-preview-visual .visual-text {
  font-size: 64px;
  font-weight: 900;
  background: linear-gradient(135deg, var(--primary), #7c3aed);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-align: center;
  line-height: 1.2;
}

/* ---- Contact ---- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
}

.contact-info-list {
  list-style: none;
}

.contact-info-item {
  display: flex;
  gap: 16px;
  padding: 20px 0;
  border-bottom: 1px solid var(--border);
}

.contact-info-item:last-child {
  border-bottom: none;
}

.contact-info-icon {
  width: 44px;
  height: 44px;
  min-width: 44px;
  border-radius: 10px;
  background: var(--primary-light);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
}

.contact-info-item h4 {
  font-size: 14px;
  color: var(--text-gray);
  font-weight: 500;
  margin-bottom: 4px;
}

.contact-info-item p {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-dark);
}

.contact-form {
  background: var(--bg-light);
  padding: 36px;
  border-radius: var(--radius-lg);
}

.contact-form h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 24px;
}

.form-group {
  margin-bottom: 16px;
}

.form-group label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--text-dark);
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 14px;
  font-family: inherit;
  transition: var(--transition);
  background: white;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(37,99,235,0.1);
}

.form-group textarea {
  height: 120px;
  resize: vertical;
}

/* ---- Footer ---- */
.footer {
  background: #0f172a;
  color: #94a3b8;
  padding: 60px 0 30px;
}

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

.footer-brand .logo {
  color: white;
  margin-bottom: 16px;
}

.footer-brand p {
  font-size: 14px;
  line-height: 1.7;
  color: #94a3b8;
}

.footer-col h4 {
  color: white;
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 16px;
}

.footer-col ul {
  list-style: none;
}

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

.footer-col ul li a {
  font-size: 14px;
  color: #94a3b8;
}

.footer-col ul li a:hover {
  color: white;
}

.footer-bottom {
  border-top: 1px solid #1e293b;
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
}

/* ---- Page Header (inner pages) ---- */
.page-header {
  padding: 140px 0 60px;
  background: linear-gradient(135deg, #eff6ff 0%, #f0f9ff 50%, #faf5ff 100%);
  text-align: center;
}

.page-header h1 {
  font-size: 40px;
  font-weight: 800;
  margin-bottom: 12px;
}

.page-header p {
  font-size: 16px;
  color: var(--text-gray);
  max-width: 600px;
  margin: 0 auto;
}

/* ---- Product Detail ---- */
.product-detail-hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  padding: 40px 0;
}

.product-detail-hero-content h2 {
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 16px;
}

.product-detail-hero-content p {
  font-size: 16px;
  color: var(--text-gray);
  line-height: 1.8;
  margin-bottom: 24px;
}

.product-detail-visual {
  background: linear-gradient(135deg, #eff6ff, #f0f9ff);
  border-radius: var(--radius-lg);
  padding: 40px;
  min-height: 300px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
}

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

.feature-item {
  padding: 28px;
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: var(--transition);
}

.feature-item:hover {
  box-shadow: var(--shadow);
  border-color: var(--primary);
}

.feature-item-icon {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  background: var(--primary-light);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  font-size: 18px;
}

.feature-item h4 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 8px;
}

.feature-item p {
  font-size: 13px;
  color: var(--text-gray);
  line-height: 1.6;
}

/* ---- Timeline ---- */
.timeline {
  position: relative;
  padding-left: 40px;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 15px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--border);
}

.timeline-item {
  position: relative;
  padding-bottom: 36px;
}

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

.timeline-dot {
  position: absolute;
  left: -33px;
  top: 4px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--primary);
  border: 3px solid var(--primary-light);
}

.timeline-item h4 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 4px;
}

.timeline-item .time {
  font-size: 13px;
  color: var(--primary);
  font-weight: 600;
  margin-bottom: 8px;
}

.timeline-item p {
  font-size: 14px;
  color: var(--text-gray);
  line-height: 1.6;
}

/* ---- Placeholder / Coming Soon ---- */
.placeholder-card {
  text-align: center;
  padding: 60px 40px;
  background: var(--bg-light);
  border: 2px dashed var(--border);
  border-radius: var(--radius-lg);
}

.placeholder-card .icon {
  font-size: 48px;
  margin-bottom: 16px;
  opacity: 0.5;
}

.placeholder-card h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--text-gray);
}

.placeholder-card p {
  font-size: 14px;
  color: var(--text-gray);
}

/* ---- CTA Section ---- */
.cta-section {
  background: linear-gradient(135deg, var(--primary), #7c3aed);
  padding: 80px 0;
  text-align: center;
  color: white;
}

.cta-section h2 {
  font-size: 32px;
  font-weight: 800;
  margin-bottom: 16px;
}

.cta-section p {
  font-size: 16px;
  opacity: 0.9;
  margin-bottom: 32px;
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

.cta-section .btn-primary {
  background: white;
  color: var(--primary);
  box-shadow: 0 4px 14px rgba(0,0,0,0.15);
}

.cta-section .btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0,0,0,0.2);
}

/* ---- Animations ---- */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---- Accessibility: focus-visible ---- */
.nav-links a:focus-visible,
.btn:focus-visible,
.mobile-toggle:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

.form-group input:focus-visible,
.form-group textarea:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: -2px;
}

/* ---- Form validation states ---- */
.form-group input::placeholder,
.form-group textarea::placeholder {
  color: #94a3b8;
}

.form-group input:invalid:not(:placeholder-shown),
.form-group textarea:invalid:not(:placeholder-shown) {
  border-color: #ef4444;
}

.form-group input:valid:not(:placeholder-shown),
.form-group textarea:valid:not(:placeholder-shown) {
  border-color: #10b981;
}

/* ---- Responsive ---- */
@media (max-width: 1024px) {
  .products-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
  .feature-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .section {
    padding: 60px 0;
  }

  .section-title h2 {
    font-size: 26px;
  }

  .mobile-toggle {
    display: block;
  }

  .nav-links {
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    background: white;
    flex-direction: column;
    padding: 0 24px;
    gap: 0;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    border-bottom: none;
    box-shadow: none;
  }

  .nav-links.active {
    padding: 24px;
    max-height: 500px;
    opacity: 1;
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-lg);
  }

  .nav-links.active li {
    margin-bottom: 16px;
  }

  .nav-links.active li:last-child {
    margin-bottom: 0;
  }

  .nav-links a.active::after {
    display: none;
  }

  .nav-links .nav-cta {
    display: inline-block;
    padding: 8px 20px;
    color: white;
  }

  .hero {
    padding: 120px 0 60px;
  }

  .hero h1 {
    font-size: 32px;
  }

  .hero p {
    font-size: 16px;
  }

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

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

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

  .about-preview {
    grid-template-columns: 1fr;
    gap: 32px;
  }

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

  .product-detail-hero {
    grid-template-columns: 1fr;
  }

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

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 8px;
    text-align: center;
  }

  .page-header h1 {
    font-size: 28px;
  }

  .hero-buttons {
    flex-direction: column;
  }

  .hero-buttons .btn {
    justify-content: center;
  }
}

@media (max-width: 480px) {
  .container { padding: 0 16px; }
  .product-card { padding: 24px; }
  .contact-form { padding: 24px; }
  .stat-number { font-size: 32px; }
  .hero { padding: 110px 0 50px; }
  .hero h1 { font-size: 28px; }
  .page-header { padding: 120px 0 40px; }
  .page-header h1 { font-size: 24px; }
  .visual-text { font-size: 36px; }
}

/* ---- Product Detail Actions ---- */
.product-detail-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* ---- Product Detail Visual Content ---- */
.product-detail-visual-content {
  text-align: center;
}

.product-detail-visual img {
  width: 100%;
  border-radius: 8px;
}

.product-detail-visual-content .visual-label {
  margin-top: 16px;
  font-size: 18px;
  font-weight: 700;
}

.product-detail-visual-content .visual-sublabel {
  font-size: 13px;
  color: var(--text-gray);
  margin-top: 4px;
}

/* ---- Section Alt Background ---- */
.section-alt {
  background: var(--bg-light);
}

/* ---- Footer Brand Description ---- */
.footer-brand-desc {
  margin-top: 12px;
}

/* ---- Contact Page ---- */
.contact-heading {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 8px;
}

.contact-subtitle {
  color: var(--text-gray);
  margin-bottom: 24px;
  font-size: 15px;
}

/* ---- Button Full Width ---- */
.btn-full-width {
  width: 100%;
  justify-content: center;
}

/* ---- Product Detail Visual Inner ---- */
.product-detail-visual-inner {
  text-align: center;
}

/* ---- Visual Label Color Variants ---- */
.visual-label.purple {
  color: #7c3aed;
}

.visual-label.green {
  color: #059669;
}

/* ---- Icon Color Variants ---- */
.feature-item-icon.icon-purple,
.advantage-icon.icon-purple {
  background: #ede9fe;
  color: #7c3aed;
}

.feature-item-icon.icon-green,
.advantage-icon.icon-green {
  background: #d1fae5;
  color: #059669;
}

/* ---- Timeline Wrapper ---- */
.timeline-wrapper {
  max-width: 600px;
  margin: 0 auto;
}

/* ---- Reduced Motion ---- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .fade-in {
    opacity: 1;
    transform: none;
  }
}

/* ---- 表单反馈提示 ---- */
.form-feedback {
  margin-top: 12px;
  padding: 10px 14px;
  border-radius: var(--radius);
  font-size: 0.9rem;
  line-height: 1.5;
}
.form-feedback.success {
  background: #ecfdf5;
  color: #065f46;
  border: 1px solid #a7f3d0;
}
.form-feedback.error {
  background: #fef2f2;
  color: #991b1b;
  border: 1px solid #fecaca;
}
