/* ============================================
   上海聚瑶科技有限公司 | Apple Style Website
   ============================================ */

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

:root {
  --black: #1d1d1f;
  --gray: #86868b;
  --light-gray: #f5f5f7;
  --white: #ffffff;
  --blue: #0071e3;
  --blue-hover: #0077ED;
  --border: #d2d2d7;
  --font: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Helvetica Neue', Arial, sans-serif;
  --max-w: 1024px;
  --section-py: 80px;
}

html { scroll-behavior: smooth; font-size: 16px; }
body {
  font-family: var(--font);
  color: var(--black);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  line-height: 1.5;
}
a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }
ul { list-style: none; }

/* --- Navigation --- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  background: rgba(255,255,255,0.8);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid rgba(0,0,0,0.06);
  transition: all .3s;
}
.nav-inner {
  max-width: var(--max-w); margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  height: 48px; padding: 0 24px;
}
.nav-logo {
  display: flex; align-items: center; gap: 8px;
  font-size: 17px; font-weight: 600; letter-spacing: -0.3px;
  color: var(--black);
}
.nav-logo-img { height: 26px; width: auto; display: block; }
.nav-logo-text { color: var(--black); }
.nav-logo-text span { color: var(--blue); }
.nav-links { display: flex; gap: 4px; align-items: center; }
.nav-links > a {
  font-size: 13px; color: var(--black);
  opacity: 0.8; transition: opacity .2s;
  padding: 0 12px; height: 48px; display: flex; align-items: center;
}
.nav-links > a:hover { opacity: 1; }
.nav-item { position: static; display: flex; align-items: center; height: 48px; }
.nav-item > a {
  font-size: 13px; color: var(--black);
  opacity: 0.8; transition: opacity .2s;
  padding: 0 12px; height: 48px; display: flex; align-items: center;
}
.nav-item:hover > a { opacity: 1; }
.caret { font-size: 9px; opacity: .55; margin-left: 3px; transform: translateY(1px); }

/* Dropdown (Apple-style full-width panel) */
.dropdown {
  position: absolute; top: 48px; left: 0; right: 0;
  background: rgba(255,255,255,0.92);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid rgba(0,0,0,0.06);
  box-shadow: 0 18px 40px rgba(0,0,0,0.08);
  opacity: 0; visibility: hidden;
  transform: translateY(-6px);
  transition: opacity .25s ease, transform .25s ease, visibility .25s;
  z-index: 999;
}
.has-dropdown:hover .dropdown {
  opacity: 1; visibility: visible; transform: translateY(0);
}
.dropdown-inner {
  max-width: var(--max-w); margin: 0 auto;
  padding: 28px 24px 32px;
  display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 4px 28px;
}
.dropdown-inner a {
  font-size: 15px; color: var(--black);
  padding: 10px 14px; border-radius: 10px;
  opacity: 0.9; transition: background .2s, opacity .2s;
}
.dropdown-inner a:hover { background: var(--light-gray); opacity: 1; }
.nav-phone {
  font-size: 13px; color: var(--blue); font-weight: 500;
  margin-left: 8px;
}

/* Mobile nav */
.nav-toggle { display: none; cursor: pointer; }
@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-toggle { display: block; font-size: 22px; }
  .nav-phone { display: none; }
}

/* --- Hero Section --- */
.hero {
  min-height: 100vh;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  text-align: center;
  padding: 120px 24px 80px;
  background: var(--light-gray);
  position: relative; overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at 50% 0%, rgba(0,113,227,0.06) 0%, transparent 70%);
  pointer-events: none;
}
.hero-eyebrow {
  font-size: 14px; font-weight: 500; color: var(--blue);
  letter-spacing: 1px; text-transform: uppercase;
  margin-bottom: 16px; opacity: 0;
  transform: translateY(20px);
  transition: all .8s cubic-bezier(.16,1,.3,1);
}
.hero h1 {
  font-size: clamp(36px, 7vw, 72px);
  font-weight: 700; line-height: 1.05;
  letter-spacing: -2px;
  margin-bottom: 20px; max-width: 800px;
  opacity: 0; transform: translateY(30px);
  transition: all .9s cubic-bezier(.16,1,.3,1) .1s;
}
.hero p {
  font-size: clamp(16px, 2.2vw, 22px);
  color: var(--gray); max-width: 560px;
  margin-bottom: 40px; line-height: 1.6;
  opacity: 0; transform: translateY(30px);
  transition: all .9s cubic-bezier(.16,1,.3,1) .2s;
}
.hero-btns {
  display: flex; gap: 16px; flex-wrap: wrap; justify-content: center;
  opacity: 0; transform: translateY(30px);
  transition: all .9s cubic-bezier(.16,1,.3,1) .3s;
}
.hero-eyebrow.visible, .hero h1.visible, .hero p.visible, .hero-btns.visible { opacity: 1; transform: none; }

.btn-primary {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--blue); color: #fff;
  padding: 14px 32px; border-radius: 980px;
  font-size: 15px; font-weight: 500;
  transition: background .2s, transform .2s;
  cursor: pointer; border: none;
}
.btn-primary:hover { background: var(--blue-hover); transform: scale(1.02); }
.btn-secondary {
  display: inline-flex; align-items: center; gap: 6px;
  background: transparent; color: var(--blue);
  padding: 14px 32px; border-radius: 980px;
  font-size: 15px; font-weight: 500;
  border: 1.5px solid var(--blue);
  transition: all .2s; cursor: pointer;
}
.btn-secondary:hover { background: rgba(0,113,227,0.06); }

.hero-scroll {
  position: absolute; bottom: 40px;
  font-size: 12px; color: var(--gray); letter-spacing: 1px;
  text-transform: uppercase;
  animation: bounce 2s infinite;
}
@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(6px); }
}

/* --- Section Common --- */
.section { padding: var(--section-py) 24px; }
.section-light { background: var(--light-gray); }
.section-dark { background: var(--black); color: var(--white); }
.section-dark h2, .section-dark p { color: var(--white); }

.container { max-width: var(--max-w); margin: 0 auto; }

.section-eyebrow {
  font-size: 13px; font-weight: 600; color: var(--blue);
  letter-spacing: 2px; text-transform: uppercase;
  margin-bottom: 12px;
}
.section-title {
  font-size: clamp(28px, 4vw, 48px);
  font-weight: 700; line-height: 1.1;
  letter-spacing: -1px; margin-bottom: 16px;
}
.section-subtitle {
  font-size: 18px; color: var(--gray); line-height: 1.6;
  max-width: 600px;
}
.section-header { text-align: center; margin-bottom: 64px; }
.section-header .section-subtitle { margin: 0 auto; }

/* Scroll animation */
.reveal { opacity: 0; transform: translateY(40px); transition: all .8s cubic-bezier(.16,1,.3,1); }
.reveal.visible { opacity: 1; transform: none; }
.reveal-delay-1 { transition-delay: .1s; }
.reveal-delay-2 { transition-delay: .2s; }
.reveal-delay-3 { transition-delay: .3s; }
.reveal-delay-4 { transition-delay: .4s; }

/* --- Products Grid --- */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
}
.product-card {
  background: var(--white); border-radius: 20px;
  padding: 48px 32px 40px; text-align: center;
  border: 1px solid rgba(0,0,0,0.06);
  transition: transform .3s, box-shadow .3s;
  cursor: default;
}
.product-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0,0,0,0.1);
}
.product-icon {
  font-size: 56px; margin-bottom: 20px;
  display: flex; justify-content: center; align-items: center;
}
.product-card h3 {
  font-size: 20px; font-weight: 600;
  margin-bottom: 10px; letter-spacing: -0.3px;
}
.product-card p {
  font-size: 14px; color: var(--gray); line-height: 1.7;
}

/* --- Tech Features --- */
.tech-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1px; background: var(--border);
  border: 1px solid var(--border); border-radius: 20px; overflow: hidden;
}
.tech-item {
  background: var(--white); padding: 40px 32px;
  transition: background .2s;
}
.tech-item:hover { background: var(--light-gray); }
.tech-item .num {
  font-size: 48px; font-weight: 700; color: var(--blue);
  line-height: 1; margin-bottom: 8px; opacity: 0.3;
}
.tech-item h3 {
  font-size: 17px; font-weight: 600; margin-bottom: 8px;
}
.tech-item p { font-size: 14px; color: var(--gray); line-height: 1.6; }

/* --- About Section --- */
.about-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 64px; align-items: center;
}
.about-img {
  border-radius: 20px; overflow: hidden;
  aspect-ratio: 4/3;
  background: linear-gradient(135deg, #e8f0fe 0%, #d0e4ff 100%);
  display: flex; align-items: center; justify-content: center;
  font-size: 80px;
}
.about-text h2 { font-size: clamp(28px, 3.5vw, 42px); font-weight: 700; margin-bottom: 20px; letter-spacing: -1px; }
.about-text p { font-size: 16px; color: var(--gray); line-height: 1.8; margin-bottom: 16px; }
.about-tags { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.about-tag {
  padding: 6px 16px; background: var(--light-gray);
  border-radius: 980px; font-size: 13px; font-weight: 500;
  color: var(--black);
}
@media (max-width: 768px) { .about-grid { grid-template-columns: 1fr; gap: 40px; } }

/* --- Service Detail --- */
.service-item {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 64px; align-items: center;
  padding: 64px 0; border-bottom: 1px solid var(--border);
}
.service-item:last-child { border-bottom: none; }
.service-item:nth-child(even) .service-visual { order: -1; }
.service-visual {
  border-radius: 20px; overflow: hidden;
  aspect-ratio: 4/3;
  display: flex; align-items: center; justify-content: center;
  font-size: 80px;
}
.service-visual-bg-1 { background: linear-gradient(135deg, #e3f2fd, #90caf9); }
.service-visual-bg-2 { background: linear-gradient(135deg, #fff3e0, #ffcc80); }
.service-visual-bg-3 { background: linear-gradient(135deg, #f3e5f5, #ce93d8); }
.service-visual-bg-4 { background: linear-gradient(135deg, #e8f5e9, #a5d6a7); }
.service-visual-bg-5 { background: linear-gradient(135deg, #fce4ec, #f48fb1); }
.service-visual-bg-6 { background: linear-gradient(135deg, #e0f7fa, #80deea); }

.service-content h3 { font-size: 26px; font-weight: 700; margin-bottom: 12px; letter-spacing: -0.5px; }
.service-content p { font-size: 15px; color: var(--gray); line-height: 1.8; margin-bottom: 20px; }
.service-list { display: flex; flex-direction: column; gap: 10px; }
.service-list li {
  font-size: 14px; color: var(--black);
  padding-left: 20px; position: relative; line-height: 1.5;
}
.service-list li::before {
  content: '✓'; position: absolute; left: 0;
  color: var(--blue); font-weight: 700;
}
@media (max-width: 768px) {
  .service-item, .service-item:nth-child(even) .service-visual { grid-template-columns: 1fr; order: 0; }
}

/* --- Stats --- */
.stats-grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 1px; background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 20px; overflow: hidden;
}
.stat-item { padding: 48px 24px; text-align: center; background: var(--black); }
.stat-num { font-size: 52px; font-weight: 700; color: var(--white); line-height: 1; margin-bottom: 8px; }
.stat-label { font-size: 14px; color: rgba(255,255,255,0.6); }
@media (max-width: 768px) { .stats-grid { grid-template-columns: repeat(2, 1fr); } }

/* --- Contact --- */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: start; }
.contact-info h3 { font-size: 24px; font-weight: 700; margin-bottom: 24px; letter-spacing: -0.5px; }
.contact-list { display: flex; flex-direction: column; gap: 20px; }
.contact-item { display: flex; gap: 16px; align-items: flex-start; }
.contact-icon {
  width: 40px; height: 40px; border-radius: 10px;
  background: rgba(0,113,227,0.08); display: flex;
  align-items: center; justify-content: center; font-size: 18px; flex-shrink: 0;
}
.contact-item h4 { font-size: 14px; font-weight: 600; margin-bottom: 2px; }
.contact-item p { font-size: 14px; color: var(--gray); }

.contact-form { background: var(--white); border-radius: 20px; padding: 40px; border: 1px solid rgba(0,0,0,0.06); }
.form-title { font-size: 20px; font-weight: 600; margin-bottom: 24px; }
.form-group { margin-bottom: 16px; }
.form-group label { display: block; font-size: 13px; font-weight: 500; margin-bottom: 6px; color: var(--black); }
.form-group input, .form-group textarea, .form-group select {
  width: 100%; padding: 12px 16px; border: 1.5px solid var(--border);
  border-radius: 10px; font-size: 15px; font-family: var(--font);
  outline: none; transition: border-color .2s;
  background: var(--white); color: var(--black);
}
.form-group input:focus, .form-group textarea:focus, .form-group select:focus { border-color: var(--blue); }
.form-group textarea { resize: vertical; min-height: 100px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-submit {
  width: 100%; padding: 14px; background: var(--blue);
  color: #fff; border: none; border-radius: 980px;
  font-size: 15px; font-weight: 500; cursor: pointer;
  transition: background .2s, transform .2s;
  margin-top: 8px;
}
.form-submit:hover { background: var(--blue-hover); transform: scale(1.01); }
@media (max-width: 768px) { .contact-grid { grid-template-columns: 1fr; } .form-row { grid-template-columns: 1fr; } }

/* --- Footer --- */
.footer {
  background: var(--black); color: rgba(255,255,255,0.7);
  padding: 60px 24px 40px;
}
.footer-inner { max-width: var(--max-w); margin: 0 auto; }
.footer-top {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px; padding-bottom: 40px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}
.footer-brand h3 { font-size: 18px; font-weight: 700; color: #fff; margin-bottom: 12px; }
.footer-brand p { font-size: 13px; line-height: 1.7; }
.footer-col h4 { font-size: 13px; font-weight: 600; color: #fff; margin-bottom: 16px; text-transform: uppercase; letter-spacing: 1px; }
.footer-col ul { display: flex; flex-direction: column; gap: 10px; }
.footer-col ul li a { font-size: 13px; opacity: 0.7; transition: opacity .2s; }
.footer-col ul li a:hover { opacity: 1; }
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center;
  padding-top: 32px; flex-wrap: wrap; gap: 12px;
}
.footer-bottom p { font-size: 12px; }
.footer-bottom a { font-size: 12px; color: var(--blue); }
@media (max-width: 768px) {
  .footer-top { grid-template-columns: 1fr 1fr; gap: 32px; }
  .footer-bottom { flex-direction: column; text-align: center; }
}

/* --- Mobile nav overlay --- */
.mobile-nav {
  display: none; position: fixed; inset: 0; z-index: 999;
  background: rgba(0,0,0,0.5);
}
.mobile-nav.active { display: block; }
.mobile-nav-menu {
  position: absolute; top: 0; right: 0; bottom: 0;
  width: 280px; background: #fff;
  padding: 24px; display: flex; flex-direction: column; gap: 4px;
}
.m-group { display: flex; flex-direction: column; gap: 2px; margin-top: 8px; }
.m-group-title {
  font-size: 12px; font-weight: 600; color: var(--gray);
  text-transform: uppercase; letter-spacing: 1px;
  padding: 8px 16px 4px;
}
.mobile-nav-menu a {
  padding: 12px 16px; font-size: 15px;
  border-radius: 10px; transition: background .2s;
}
.mobile-nav-menu a:hover { background: var(--light-gray); }

/* --- About list --- */
.about-list { list-style: none; }
.about-list li { padding: 4px 0; }

/* --- FAQ (details / summary) --- */
.faq-list { max-width: 760px; margin: 0 auto; display: flex; flex-direction: column; gap: 12px; }
.faq-item {
  background: var(--white);
  border: 1px solid rgba(0,0,0,0.06);
  border-radius: 14px;
  padding: 0 22px;
  transition: box-shadow .2s;
}
.faq-item[open] { box-shadow: 0 8px 24px rgba(0,0,0,0.06); }
.faq-item summary {
  list-style: none; cursor: pointer;
  font-size: 16px; font-weight: 500; color: var(--black);
  padding: 20px 0; display: flex; justify-content: space-between; align-items: center;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: '+'; font-size: 22px; font-weight: 400; color: var(--blue);
  margin-left: 16px; transition: transform .2s;
}
.faq-item[open] summary::after { content: '\2212'; }
.faq-item p { font-size: 15px; color: var(--gray); line-height: 1.8; padding: 0 0 20px; }
