:root {
  --primary: #165dff;
  --secondary: #36bffa;
  --accent: #722ed1;
  --dark: #1d2129;
  --muted: #5f6675;
  --light: #f2f3f5;
  --line: #e5e7ef;
  --surface: #fff;
  --shadow: 0 20px 28px rgba(15, 23, 42, 0.1);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--dark);
  background: #fff;
  font-family: Inter, "Microsoft YaHei", Arial, sans-serif;
  line-height: 1.6;
}

body.locked {
  overflow: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

img {
  display: block;
  max-width: 100%;
}

.container {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.navbar {
  position: fixed;
  z-index: 40;
  top: 0;
  left: 0;
  width: 100%;
  padding: 16px 0;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(12px);
  transition: padding 0.25s ease, box-shadow 0.25s ease;
}

.navbar.compact {
  padding: 8px 0;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.brand img {
  width: 40px;
  height: 40px;
  object-fit: contain;
}

.brand strong,
.footer-brand strong {
  font-size: 20px;
}

.brand-icon {
  width: 40px;
  height: 40px;
  display: inline-grid;
  place-items: center;
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  border-radius: 10px;
  flex: 0 0 auto;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 34px;
  font-weight: 700;
}

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

.nav-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.nav-cta,
.btn,
.view-product {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 24px;
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 800;
}

.nav-cta,
.btn.primary,
.view-product {
  color: #fff;
  background: var(--primary);
}

.btn.ghost {
  color: var(--dark);
  background: #fff;
  border: 1px solid #d1d5db;
}

.menu-toggle {
  display: none;
  padding: 6px;
  background: transparent;
  border: 0;
  font-size: 24px;
}

.hero-section {
  padding: 128px 0 88px;
}

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

.hero-copy h1 {
  margin: 0;
  font-size: clamp(42px, 5vw, 64px);
  line-height: 1.15;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
}

.hero-copy h1 span {
  color: var(--primary);
}

.hero-copy p {
  max-width: 560px;
  margin: 24px 0 0;
  color: var(--muted);
  font-size: 18px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 32px;
}

.rating-strip {
  display: flex;
  align-items: center;
  gap: 22px;
  margin-top: 48px;
}

.avatar-stack {
  display: flex;
}

.avatar-stack img {
  width: 40px;
  height: 40px;
  margin-left: -8px;
  border: 2px solid #fff;
  border-radius: 50%;
  object-fit: cover;
}

.avatar-stack img:first-child {
  margin-left: 0;
}

.stars {
  color: #fbbf24;
}

.stars b {
  margin-left: 8px;
  color: var(--dark);
}

.rating-strip p {
  margin: 2px 0 0;
  color: var(--muted);
  font-size: 14px;
}

.hero-media {
  position: relative;
}

.hero-media img {
  position: relative;
  z-index: 2;
  width: 100%;
  border-radius: 24px;
  box-shadow: var(--shadow);
}

.media-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(32px);
}

.media-glow.one {
  top: -24px;
  left: -24px;
  width: 160px;
  height: 160px;
  background: rgba(114, 46, 209, 0.12);
}

.media-glow.two {
  right: -32px;
  bottom: -40px;
  width: 240px;
  height: 240px;
  background: rgba(22, 93, 255, 0.12);
}

.partners {
  margin-top: 92px;
  text-align: center;
}

.partners p {
  margin: 0 0 24px;
  color: var(--muted);
}

.partners div {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 34px 64px;
}

.partners strong {
  color: #9ca3af;
  font-size: 24px;
}

.section {
  padding: 84px 0;
}

.section.light {
  background: var(--light);
}

.section-head {
  max-width: 760px;
  margin: 0 auto 54px;
  text-align: center;
}

.section-head h2,
.cta-panel h2 {
  margin: 0;
  font-size: clamp(30px, 3vw, 42px);
  line-height: 1.2;
}

.section-head p {
  margin: 14px 0 0;
  color: var(--muted);
}

.product-grid,
.feature-grid,
.testimonial-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px;
}

.product-card,
.feature-card,
.testimonial-card {
  background: var(--surface);
  border-radius: 22px;
  box-shadow: 0 12px 24px rgba(15, 23, 42, 0.08);
}

.product-card {
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

.product-image {
  height: 240px;
  background: #e6eaf2;
  overflow: hidden;
}

.product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product-body {
  padding: 24px;
}

.product-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.product-title-row h3 {
  margin: 0;
  font-size: 21px;
}

.product-title-row span,
.detail-badge {
  padding: 4px 12px;
  color: var(--primary);
  background: rgba(22, 93, 255, 0.1);
  border-radius: 999px;
  white-space: nowrap;
  font-size: 14px;
  font-weight: 800;
}

.product-body p {
  min-height: 56px;
  margin: 12px 0 22px;
  color: var(--muted);
}

.view-product {
  min-height: 38px;
  padding: 0 18px;
  border-radius: 8px;
}

.feature-card,
.testimonial-card {
  padding: 30px;
}

.feature-card {
  transition: transform 0.25s ease;
}

.feature-card:hover {
  transform: scale(1.03);
}

.feature-card > span {
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  color: var(--primary);
  background: rgba(22, 93, 255, 0.1);
  border-radius: 14px;
  font-size: 24px;
}

.feature-card h3,
.testimonial-card strong {
  margin: 22px 0 10px;
  font-size: 20px;
}

.feature-card p,
.testimonial-card p {
  color: var(--muted);
}

.person {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 22px;
}

.person img {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
}

.person strong {
  display: block;
  margin: 0;
}

.person span {
  color: var(--muted);
  font-size: 14px;
}

.cta-section {
  padding: 84px 0;
}

.cta-panel {
  display: grid;
  grid-template-columns: 1fr 360px;
  align-items: center;
  gap: 40px;
  padding: 58px;
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  border-radius: 28px;
}

.cta-panel p {
  color: rgba(255, 255, 255, 0.82);
  font-size: 18px;
}

.cta-panel img {
  border-radius: 16px;
  box-shadow: var(--shadow);
}

.footer {
  padding: 54px 0 28px;
  color: #fff;
  background: var(--dark);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1.2fr;
  gap: 34px;
}

.footer p,
.footer a {
  color: #aeb7c7;
}

.footer-grid a {
  display: block;
  margin-top: 10px;
}

.socials {
  display: flex;
  gap: 12px;
  margin-top: 22px;
}

.socials a {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  margin: 0;
  background: #2b3342;
  border-radius: 50%;
}

.subscribe {
  display: flex;
  margin-top: 14px;
}

.subscribe input {
  min-width: 0;
  width: 100%;
  padding: 12px 14px;
  color: #fff;
  background: #2b3342;
  border: 0;
  border-radius: 8px 0 0 8px;
}

.subscribe button {
  padding: 0 16px;
  color: #fff;
  background: var(--primary);
  border: 0;
  border-radius: 0 8px 8px 0;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-top: 42px;
  padding-top: 24px;
  border-top: 1px solid #303746;
}

.footer-bottom p {
  margin: 0;
}

.footer-bottom div {
  display: flex;
  gap: 22px;
}

.product-page {
  position: fixed;
  z-index: 60;
  inset: 0;
  overflow-y: auto;
  background: #fff;
  transform: translateX(100%);
  transition: transform 0.3s ease;
}

.product-page.open {
  transform: translateX(0);
}

.product-page-inner {
  padding: 72px 0;
}

.detail-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 40px;
}

.detail-top button,
.back-button {
  color: var(--primary);
  background: transparent;
  border: 0;
  cursor: pointer;
  font-weight: 800;
}

.back-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.detail-top > div {
  display: flex;
  gap: 18px;
  font-size: 20px;
}

.detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 54px;
}

.detail-image {
  overflow: hidden;
  border-radius: 20px;
  box-shadow: var(--shadow);
}

.detail-image img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.detail-thumbs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-top: 14px;
}

.detail-thumbs button {
  overflow: hidden;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 10px;
  cursor: pointer;
}

.detail-thumbs button.active {
  border-color: var(--primary);
}

.detail-thumbs img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
}

.detail-info h1 {
  margin: 14px 0 12px;
  font-size: clamp(30px, 3vw, 42px);
  line-height: 1.2;
}

.detail-rating {
  display: flex;
  gap: 10px;
  color: var(--muted);
}

.detail-info > p {
  margin-top: 24px;
  color: var(--muted);
}

.detail-info h3 {
  margin: 30px 0 12px;
}

.check-list {
  display: grid;
  gap: 9px;
  padding: 0;
  list-style: none;
}

.check-list li::before {
  content: "\f00c";
  margin-right: 10px;
  color: #16a34a;
  font-family: FontAwesome;
}

.color-swatches {
  display: flex;
  gap: 14px;
}

.color-swatches button {
  width: 40px;
  height: 40px;
  border: 2px solid #d1d5db;
  border-radius: 50%;
  cursor: pointer;
}

.color-swatches .black {
  background: #111827;
}

.color-swatches .white {
  background: #fff;
}

.color-swatches .blue {
  background: var(--primary);
}

.service-note {
  margin-top: 30px;
  padding-top: 22px;
  color: var(--muted);
  border-top: 1px solid var(--line);
}

.service-note p {
  margin: 8px 0;
}

.detail-tabs {
  margin-top: 70px;
}

.tab-list {
  display: flex;
  flex-wrap: wrap;
  border-bottom: 1px solid var(--line);
}

.tab-list button {
  padding: 16px 20px;
  color: var(--muted);
  background: transparent;
  border: 0;
  border-bottom: 2px solid transparent;
  cursor: pointer;
  font-weight: 800;
}

.tab-list button.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}

.tab-panel {
  padding: 30px 0;
}

.tab-panel.hidden,
.hidden {
  display: none;
}

.spec-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px 46px;
}

.spec-grid div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.spec-grid span {
  color: var(--muted);
}

.review-summary {
  margin-bottom: 28px;
  padding: 24px;
  background: var(--light);
  border-radius: 16px;
}

.review-summary strong {
  display: block;
  font-size: 40px;
}

.detail-review-list {
  display: grid;
  gap: 18px;
}

.detail-review-list article {
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.fade-in {
  animation: fadeIn 0.8s ease both;
}

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

@media (max-width: 900px) {
  .nav-links {
    position: absolute;
    top: 68px;
    left: 16px;
    right: 16px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 12px;
    background: #fff;
    border-radius: 14px;
    box-shadow: var(--shadow);
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links a {
    padding: 12px;
  }

  .nav-cta {
    display: none;
  }

  .menu-toggle {
    display: block;
  }

  .hero-grid,
  .detail-grid,
  .cta-panel {
    grid-template-columns: 1fr;
  }

  .product-grid,
  .feature-grid,
  .testimonial-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .cta-panel {
    padding: 34px;
  }

  .footer-bottom {
    flex-direction: column;
  }

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

@media (max-width: 560px) {
  .brand strong {
    max-width: 170px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .hero-section {
    padding-top: 108px;
  }

  .hero-actions,
  .rating-strip {
    align-items: flex-start;
    flex-direction: column;
  }

  .partners strong {
    font-size: 20px;
  }

  .section {
    padding: 64px 0;
  }

  .footer-bottom div {
    flex-wrap: wrap;
  }
}
