/* ===== CSS Variables ===== */
:root {
  --navy: #1a2332;
  --accent: #2563a8;
  --accent-light: #3b7dd8;
  --accent-subtle: rgba(37, 99, 168, 0.08);
  --bg: #ffffff;
  --bg-alt: #f5f7fa;
  --text: #1a1a1a;
  --text-muted: #6b7b8d;
  --text-light: #9aa5b4;
  --border: #e2e6ec;
  --white: #ffffff;
  --nav-height: 114px;
  --radius: 12px;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.04);
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --card-zoom: 1.05;
  --card-zoom-duration: 0.5s;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--nav-height);
}

body {
  font-family: 'Open Sans', 'Noto Sans Simplified Chinese', sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.7;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

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

a:hover {
  color: var(--accent);
}

/* ===== Layout ===== */
.container {
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 48px;
}

section {
  padding: 100px 0;
}

/* ===== Navigation ===== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-height);
  background: rgba(255,255,255,0.97);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  z-index: 1000;
  display: flex;
  align-items: center;
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 100%;
  margin: 0;
  padding: 0 24px;
  width: 100%;
  position: relative;
}

.nav-logo {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
  text-decoration: none;
  flex-shrink: 0;
  transition: opacity var(--transition);
}

.nav-logo:hover {
  opacity: 0.8;
}

.logo-cn {
  font-family: 'Noto Serif SC', serif;
  font-size: 1.7rem;
  font-weight: 700;
  color: var(--navy);
  letter-spacing: 0.5px;
}

.logo-en {
  font-family: 'Open Sans', sans-serif;
  font-size: 0.94rem;
  font-weight: 500;
  color: var(--text-light);
  letter-spacing: 1px;
  margin-top: 1px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 48px;
  list-style: none;
  margin-left: auto;
}

.nav-links a {
  color: var(--text-muted);
  font-size: 1.14rem;
  font-weight: 500;
  transition: color var(--transition);
  letter-spacing: 0.2px;
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: width var(--transition);
  border-radius: 1px;
}

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

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

.nav-links a.active {
  color: var(--navy);
  font-weight: 600;
}

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

.lang-switch {
  padding: 7px 18px;
  border: 1px solid var(--border);
  border-radius: 20px;
  font-size: 1rem;
  font-weight: 500;
  color: var(--text-muted);
  transition: all var(--transition);
}

.lang-switch::after {
  display: none;
}

.lang-switch:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-subtle);
}

/* ===== Hamburger (hidden on desktop) ===== */
.nav-toggle {
  display: none;
}

.nav-hamburger {
  display: none;
  cursor: pointer;
  width: 28px;
  height: 20px;
  position: relative;
  flex-shrink: 0;
  z-index: 10;
  margin: 0;
  align-self: center;
}

.nav-hamburger span,
.nav-hamburger span::before,
.nav-hamburger span::after {
  content: '';
  display: block;
  width: 100%;
  height: 2px;
  background: var(--navy);
  border-radius: 2px;
  position: absolute;
  left: 0;
  transition: all var(--transition);
}

.nav-hamburger span {
  top: 50%;
  transform: translateY(-50%);
}

.nav-hamburger span::before {
  top: -6px;
}

.nav-hamburger span::after {
  top: 6px;
}

/* ===== Hero ===== */
.hero {
  min-height: 90vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  margin-top: var(--nav-height);
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(15,25,35,0.78) 0%, rgba(15,25,35,0.32) 100%);
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 660px;
  padding: 0 48px;
}

.hero-content h1 {
  font-size: 2.8rem;
  font-weight: 700;
  line-height: 1.15;
  color: var(--white);
  margin-bottom: 20px;
  letter-spacing: -0.5px;
}

.hero-content p {
  font-size: 1.05rem;
  color: rgba(255,255,255,0.72);
  margin-bottom: 36px;
  line-height: 1.8;
  max-width: 520px;
}

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 30px;
  background: var(--accent);
  color: var(--white);
  font-size: 0.88rem;
  font-weight: 600;
  border-radius: 24px;
  border: none;
  cursor: pointer;
  transition: all var(--transition);
  letter-spacing: 0.3px;
  box-shadow: 0 2px 12px rgba(37, 99, 168, 0.2);
}

.btn:hover {
  background: var(--accent-light);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(37, 99, 168, 0.3);
}

.btn-outline {
  background: transparent;
  border: 1.5px solid rgba(255,255,255,0.35);
  color: var(--white);
  box-shadow: none;
}

/* ===== Hero Actions ===== */
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.btn-outline:hover {
  border-color: var(--white);
  background: rgba(255,255,255,0.1);
  transform: translateY(-2px);
  box-shadow: none;
}

/* ===== Section Headers ===== */
.section-header {
  margin-bottom: 56px;
}

.section-header h2 {
  font-size: 2rem;
  font-weight: 700;
  color: var(--navy);
  letter-spacing: -0.5px;
  margin-bottom: 12px;
}

.section-header p {
  font-size: 1rem;
  color: var(--text-muted);
  max-width: 560px;
  line-height: 1.7;
}

.section-header-right {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
}

.section-header-right .link-more {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.2px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all var(--transition);
}

.section-header-right .link-more:hover {
  color: var(--accent-light);
  gap: 10px;
}

/* ===== About / Split Layout ===== */
.split-section {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  min-height: 560px;
}

.split-img {
  overflow: hidden;
}

.split-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.split-section:hover .split-img img {
  transform: scale(1.03);
}

.split-content {
  padding: 80px 80px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: var(--bg-alt);
}

.split-content h2 {
  font-size: 1.9rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 20px;
  letter-spacing: -0.3px;
  line-height: 1.3;
}

.split-content p {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.9;
  max-width: 480px;
}

/* ===== Card Image Wrapper ===== */
.card-img-wrap {
  overflow: hidden;
  -webkit-transform: translateZ(0);
  transform: translateZ(0);
}

.card-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

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

.product-card {
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  position: relative;
}

.product-card:hover::after {
  transform: scaleX(1);
}

.product-card .card-img-wrap {
  border-radius: var(--radius);
  aspect-ratio: 16/10;
}

.product-card .card-img-wrap img {
  transition: transform var(--card-zoom-duration) ease;
}

.product-card:hover .card-img-wrap img {
  transform: scale(var(--card-zoom));
}

.product-card-body {
  padding: 28px 24px;
}

.product-card-body h3 {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--navy);
  margin-bottom: 8px;
}

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

/* ===== Cases / Projects ===== */
.cases-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
}

.case-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  aspect-ratio: 16/10;
}

.case-card .card-img-wrap {
  width: 100%;
  height: 100%;
  border-radius: var(--radius);
}

.case-card .card-img-wrap img {
  transition: transform 0.7s ease;
}

.case-card:hover .card-img-wrap img {
  transform: scale(1.06);
}

.case-card-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 1;
  padding: 40px 32px 32px;
  background: linear-gradient(transparent, rgba(15,25,35,0.9));
}

.case-card-overlay h3 {
  color: var(--white);
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: 6px;
}

.case-card-overlay p {
  color: rgba(255,255,255,0.65);
  font-size: 0.85rem;
}

/* ===== Partner Cards ===== */
.partner-card {
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 48px;
  box-shadow: var(--shadow-sm);
  position: relative;
}

.partner-card:hover::after {
  transform: scaleX(1);
}

.partner-card:last-child {
  margin-bottom: 0;
}

.partner-card-hero {
  width: 100%;
  aspect-ratio: 21/9;
  overflow: hidden;
  border-radius: var(--radius);
}

.partner-card-hero .card-img-wrap {
  width: 100%;
  height: 100%;
  border-radius: var(--radius);
}

.partner-card-hero .card-img-wrap img {
  transition: transform var(--card-zoom-duration) ease;
}

.partner-card:hover .partner-card-hero .card-img-wrap img {
  transform: scale(var(--card-zoom));
}

.partner-card-body {
  padding: 40px 48px;
}

.partner-card-body h3 {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 12px;
  letter-spacing: -0.3px;
}

.partner-card-body > p {
  font-size: 0.92rem;
  color: var(--text-muted);
  line-height: 1.8;
  margin-bottom: 28px;
  max-width: 640px;
}

.partner-card-photos {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.partner-card-photos img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  border-radius: 8px;
}

/* ===== Page Banner (sub pages) ===== */
.page-banner {
  background: var(--navy);
  padding: 140px 0 72px;
  margin-top: var(--nav-height);
  text-align: center;
  position: relative;
  overflow: hidden;
}

.page-banner::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 120%, rgba(37,99,168,0.15) 0%, transparent 70%);
}

.page-banner h1 {
  color: var(--white);
  font-size: 2.2rem;
  font-weight: 700;
  letter-spacing: -0.5px;
  margin-bottom: 12px;
  position: relative;
}

.page-banner p {
  color: rgba(255,255,255,0.55);
  font-size: 1.05rem;
  position: relative;
}

/* ===== Equipment Grid ===== */
.equipment-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
}

.equipment-card {
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  position: relative;
}

.equipment-card:hover::after {
  transform: scaleX(1);
}

.equipment-card .card-img-wrap {
  border-radius: var(--radius);
  aspect-ratio: 16/9;
}

.equipment-card .card-img-wrap img {
  transition: transform var(--card-zoom-duration) ease;
}

.equipment-card:hover .card-img-wrap img {
  transform: scale(var(--card-zoom));
}

.equipment-card-body {
  padding: 28px 24px;
}

.equipment-card-body h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--navy);
  margin-bottom: 8px;
}

.equipment-card-body p {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.7;
}

.equipment-specs {
  display: flex;
  gap: 24px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.equipment-specs span {
  font-size: 0.78rem;
  color: var(--text-light);
  letter-spacing: 0.3px;
  font-weight: 500;
}

/* ===== Footer ===== */
.footer {
  background: var(--bg);
  color: var(--text-muted);
  padding: 72px 0 32px;
}

.footer .container {
  max-width: 100%;
  margin: 0;
  padding: 0 24px;
  width: 100%;
}

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

.footer-brand h3 {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
  margin-bottom: 14px;
}

.footer-brand h3 .logo-cn {
  font-family: 'Noto Serif SC', serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--navy);
  letter-spacing: 0.5px;
}

.footer-brand h3 .logo-en {
  font-family: 'Open Sans', sans-serif;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-light);
  letter-spacing: 1.2px;
  margin-top: 2px;
}

.footer-brand p {
  font-size: 0.88rem;
  line-height: 1.7;
  color: var(--text-muted);
}

.footer-col h4 {
  color: var(--navy);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  margin-bottom: 20px;
}

.footer-contact-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 14px;
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.6;
}

.footer-contact-item svg {
  width: 16px;
  height: 16px;
  color: var(--accent);
  flex-shrink: 0;
  margin-top: 3px;
}

.footer-bottom {
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  font-size: 0.82rem;
  color: var(--text-light);
}

.footer-bottom a {
  color: var(--text-light);
}

.footer-bottom a:hover {
  color: var(--accent);
}

/* ===== Shared: Card Blue Line Animation ===== */
.product-card::after,
.equipment-card::after,
.partner-card::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s ease;
}

/* ===== Photo Strip ===== */
.photo-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
}

.photo-strip-item {
  overflow: hidden;
  aspect-ratio: 1/1;
}

.photo-strip-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transform: scale(1.01);
  backface-visibility: hidden;
  will-change: transform;
  transition: transform var(--card-zoom-duration) ease;
}

.photo-strip-item:hover img {
  transform: scale(var(--card-zoom));
}

/* ===== Responsive ===== */
@media (max-width: 1024px) {
  .container {
    padding: 0 32px;
  }

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

  .hero-content h1 {
    font-size: 2.4rem;
  }

  .section-header h2 {
    font-size: 1.7rem;
  }

  .page-banner h1 {
    font-size: 1.9rem;
  }

  .partner-card-body h3 {
    font-size: 1.2rem;
  }

  .split-content h2 {
    font-size: 1.6rem;
  }

  .split-content {
    padding: 60px 48px;
  }
}

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

  /* ===== Nav mobile: hamburger menu ===== */
  .navbar {
    top: 0;
    height: 72px;
  }

  .navbar .container {
    padding: 0 16px;
  }

  .nav-hamburger {
    display: block;
    order: 2;
  }

  .nav-logo {
    order: 1;
  }

  .nav-logo .logo-cn {
    font-size: 1rem;
  }

  .nav-logo .logo-en {
    font-size: 0.62rem;
    letter-spacing: 0.5px;
  }

  .nav-links {
    display: none;
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    flex-direction: column;
    background: rgba(255,255,255,0.98);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    padding: 8px 0 16px;
    gap: 0;
    margin-left: 0;
    border-bottom: 1px solid var(--border);
    box-shadow: 0 8px 24px rgba(0,0,0,0.08);
  }

  .nav-links li {
    width: 100%;
  }

  .nav-links a {
    display: block;
    padding: 14px 24px;
    font-size: 0.92rem;
    font-weight: 500;
  }

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

  .nav-links a.active {
    background: var(--accent-subtle);
    color: var(--accent);
  }

  .lang-switch {
    display: inline-block;
    margin: 8px 24px 4px;
    padding: 6px 16px;
    font-size: 0.82rem;
    width: auto;
  }

  /* Checkbox hack: show nav when toggled */
  .nav-toggle:checked ~ .nav-links {
    display: flex;
  }

  .nav-toggle:checked ~ .nav-hamburger span {
    background: transparent;
  }

  .nav-toggle:checked ~ .nav-hamburger span::before {
    top: 0;
    transform: rotate(45deg);
  }

  .nav-toggle:checked ~ .nav-hamburger span::after {
    top: 0;
    transform: rotate(-45deg);
  }

  /* ===== Hero mobile ===== */
  .hero {
    margin-top: 72px;
  }

  .hero-content {
    padding: 0 16px;
  }

  .hero-content h1 {
    font-size: 1.75rem;
  }

  .hero-content p {
    font-size: 0.92rem;
    margin-bottom: 28px;
  }

  .btn {
    padding: 11px 22px;
    font-size: 0.82rem;
  }

  /* ===== Section spacing ===== */
  section {
    padding: 56px 0;
  }

  .section-header {
    margin-bottom: 40px;
  }

  .section-header h2 {
    font-size: 1.4rem;
  }

  .section-header p {
    font-size: 0.9rem;
  }

  /* ===== Split section mobile ===== */
  .split-section {
    grid-template-columns: 1fr;
  }

  .split-content {
    padding: 48px 24px;
  }

  .split-content h2 {
    font-size: 1.4rem;
  }

  .split-content p {
    font-size: 0.9rem;
  }

  /* ===== Photo strip mobile ===== */
  .photo-strip {
    grid-template-columns: 1fr;
  }

  .photo-strip-item {
    aspect-ratio: 1/1;
  }

  /* ===== Grids ===== */
  .products-grid,
  .equipment-grid,
  .cases-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  /* ===== Product/Equipment card body ===== */
  .product-card-body,
  .equipment-card-body {
    padding: 20px 16px;
  }

  .product-card-body h3,
  .equipment-card-body h3 {
    font-size: 1rem;
  }

  .product-card-body p,
  .equipment-card-body p {
    font-size: 0.82rem;
  }

  .equipment-specs {
    gap: 16px;
  }

  /* ===== Cases overlay ===== */
  .case-card-overlay {
    padding: 28px 20px 20px;
  }

  .case-card-overlay h3 {
    font-size: 1rem;
  }

  .case-card-overlay p {
    font-size: 0.78rem;
  }

  /* ===== Partner cards ===== */
  .partner-card {
    margin-bottom: 32px;
  }

  .partner-card-body {
    padding: 24px 16px;
  }

  .partner-card-body h3 {
    font-size: 1.1rem;
  }

  .partner-card-body > p {
    font-size: 0.85rem;
  }

  .partner-card-photos {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  /* ===== Page banner ===== */
  .page-banner {
    padding: 100px 0 48px;
    margin-top: 72px;
  }

  .page-banner h1 {
    font-size: 1.5rem;
  }

  .page-banner p {
    font-size: 0.92rem;
  }

  /* ===== Footer ===== */
  .footer {
    padding: 48px 0 24px;
  }

  .footer .container {
    padding: 0 16px;
  }

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

  .footer-brand h3 .logo-cn {
    font-size: 1rem;
  }

  .footer-brand h3 .logo-en {
    font-size: 0.58rem;
  }

  .footer-brand p {
    font-size: 0.82rem;
  }

  .footer-col h4 {
    font-size: 0.78rem;
    margin-bottom: 14px;
  }

  .footer-contact-item {
    font-size: 0.82rem;
    margin-bottom: 10px;
  }

  .footer-bottom {
    font-size: 0.75rem;
    padding-top: 16px;
  }
}
