/* ============================================
   惠州医时科技有限公司 — 企业官网样式
   Visual thesis: calm precision — 深夜蓝底 + 青绿渐变
   ============================================ */

:root {
  --bg: #0a1020;
  --bg-soft: #0e1730;
  --bg-dark: #070c18;
  --surface: rgba(255, 255, 255, 0.04);
  --surface-strong: rgba(255, 255, 255, 0.07);
  --line: rgba(255, 255, 255, 0.09);
  --line-strong: rgba(255, 255, 255, 0.16);
  --text: #eef2f8;
  --text-soft: #a8b4c8;
  --text-dim: #7c8aa3;
  --accent: #3ee6c4;
  --accent-2: #4aa8ff;
  --gradient: linear-gradient(120deg, #3ee6c4 0%, #4aa8ff 100%);
  --radius: 20px;
  --maxw: 1180px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --font: "Inter", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, -apple-system, sans-serif;
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
ul { list-style: none; }
img, svg { display: block; max-width: 100%; }

.container {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 28px;
}

/* ---------- Header ---------- */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 18px 0;
  transition: padding 0.4s var(--ease), background 0.4s var(--ease), border-color 0.4s var(--ease);
  border-bottom: 1px solid transparent;
}
.site-header.scrolled {
  padding: 12px 0;
  background: rgba(8, 13, 26, 0.78);
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  border-bottom-color: var(--line);
}
.nav {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
  letter-spacing: 0.02em;
}
.logo-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px; height: 40px;
  border-radius: 12px;
  background: var(--gradient);
  color: #06121a;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0;
  box-shadow: 0 6px 22px rgba(62, 230, 196, 0.25);
}
.logo-name { font-size: 17px; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 38px;
}
.nav-links a {
  position: relative;
  font-size: 15px;
  color: var(--text-soft);
  font-weight: 500;
  transition: color 0.3s var(--ease);
  padding: 4px 0;
}
.nav-links a::after {
  content: "";
  position: absolute;
  left: 0; bottom: -2px;
  width: 100%; height: 2px;
  background: var(--gradient);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.35s var(--ease);
  border-radius: 2px;
}
.nav-links a:hover { color: var(--text); }
.nav-links a:hover::after { transform: scaleX(1); transform-origin: left; }

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px; height: 44px;
  padding: 10px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  height: 2px;
  width: 100%;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.3s var(--ease), opacity 0.3s var(--ease);
}
.nav-toggle.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.active span:nth-child(2) { opacity: 0; }
.nav-toggle.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 30px;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.01em;
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease), background 0.3s var(--ease), border-color 0.3s var(--ease);
  will-change: transform;
}
.btn-primary {
  background: var(--gradient);
  color: #06121a;
  box-shadow: 0 10px 30px rgba(62, 230, 196, 0.28);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 40px rgba(62, 230, 196, 0.4);
}
.btn-ghost {
  border: 1px solid var(--line-strong);
  color: var(--text);
  background: rgba(255, 255, 255, 0.02);
}
.btn-ghost:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-2px);
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding: 140px 0 80px;
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}
.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(900px 600px at 78% 30%, rgba(74, 168, 255, 0.12), transparent 60%),
    radial-gradient(700px 500px at 20% 80%, rgba(62, 230, 196, 0.1), transparent 60%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-soft) 55%, var(--bg) 100%);
}
.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  opacity: 0.5;
  animation: float 16s ease-in-out infinite;
}
.orb-1 {
  width: 460px; height: 460px;
  background: radial-gradient(circle, rgba(62, 230, 196, 0.5), transparent 70%);
  top: -80px; right: -60px;
}
.orb-2 {
  width: 520px; height: 520px;
  background: radial-gradient(circle, rgba(74, 168, 255, 0.42), transparent 70%);
  bottom: -160px; left: -140px;
  animation-delay: -8s;
}
@keyframes float {
  0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(-28px, 24px, 0) scale(1.08); }
}
.grid-overlay {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.028) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.028) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 80% 70% at 50% 45%, #000 30%, transparent 78%);
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 45%, #000 30%, transparent 78%);
}
.hero-net {
  position: absolute;
  top: 50%; right: -4%;
  width: 640px; height: 640px;
  transform: translateY(-50%);
  opacity: 0.9;
  z-index: 1;
}

.hero-inner {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 28px;
}
.hero-eyebrow {
  display: inline-block;
  font-size: 13px;
  letter-spacing: 0.28em;
  font-weight: 600;
  color: var(--accent);
  padding: 8px 16px;
  border: 1px solid rgba(62, 230, 196, 0.28);
  border-radius: 999px;
  background: rgba(62, 230, 196, 0.06);
  margin-bottom: 30px;
  animation: fadeUp 0.8s var(--ease) both;
}
.hero h1 {
  font-size: clamp(3rem, 7.2vw, 5.6rem);
  line-height: 1.06;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 26px;
  animation: fadeUp 0.9s var(--ease) 0.08s both;
}
.grad-text {
  background: var(--gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}
.hero-sub {
  font-size: clamp(1rem, 1.6vw, 1.2rem);
  color: var(--text-soft);
  max-width: 620px;
  margin-bottom: 40px;
  animation: fadeUp 0.9s var(--ease) 0.16s both;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 64px;
  animation: fadeUp 0.9s var(--ease) 0.24s both;
}
.hero-metrics {
  display: flex;
  gap: 56px;
  flex-wrap: wrap;
  padding-top: 34px;
  border-top: 1px solid var(--line);
  animation: fadeUp 0.9s var(--ease) 0.32s both;
}
.metric { display: flex; align-items: baseline; gap: 2px; flex-wrap: wrap; }
.metric-num {
  font-size: clamp(2rem, 3.4vw, 2.8rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  background: var(--gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  font-variant-numeric: tabular-nums;
}
.metric-plus {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--accent);
  margin-right: 8px;
}
.metric-label {
  display: block;
  width: 100%;
  font-size: 13.5px;
  color: var(--text-dim);
  letter-spacing: 0.04em;
}

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

/* ---------- Sections ---------- */
.section {
  position: relative;
  padding: clamp(80px, 11vw, 140px) 0;
}
.section-dark {
  background: var(--bg-dark);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.section-head {
  max-width: 720px;
  margin-bottom: clamp(48px, 6vw, 76px);
}
.section-tag {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.16em;
  color: var(--accent);
  margin-bottom: 18px;
}
.section-tag::before {
  content: "";
  width: 28px; height: 2px;
  background: var(--gradient);
  border-radius: 2px;
}
.section-title {
  font-size: clamp(1.9rem, 3.6vw, 2.9rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.18;
}
.section-desc {
  margin-top: 18px;
  font-size: 1.05rem;
  color: var(--text-soft);
  max-width: 620px;
}

/* ---------- About ---------- */
.about-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: clamp(40px, 6vw, 88px);
  align-items: center;
}
.about-text p {
  color: var(--text-soft);
  margin-bottom: 20px;
  font-size: 1.02rem;
}
.about-text .lead {
  font-size: clamp(1.25rem, 2vw, 1.5rem);
  line-height: 1.55;
  color: var(--text);
  font-weight: 500;
  margin-bottom: 26px;
}
.about-text strong { color: var(--accent); font-weight: 700; }

.about-visual { position: relative; }
.about-panel {
  position: relative;
  padding: 8px 0;
  border-radius: var(--radius);
  background: linear-gradient(160deg, rgba(255,255,255,0.06), rgba(255,255,255,0.015));
  border: 1px solid var(--line);
  overflow: hidden;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.35);
}
.about-panel::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: var(--gradient);
  opacity: 0.8;
}
.panel-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 22px 30px;
  border-bottom: 1px solid var(--line);
  transition: background 0.3s var(--ease);
}
.panel-row:last-child { border-bottom: none; }
.panel-row:hover { background: rgba(62, 230, 196, 0.04); }
.panel-key {
  font-size: 13.5px;
  color: var(--text-dim);
  letter-spacing: 0.06em;
  white-space: nowrap;
}
.panel-val {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  text-align: right;
}

/* ---------- Services ---------- */
.services-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}
.service-card {
  position: relative;
  padding: clamp(30px, 4vw, 46px);
  border-radius: var(--radius);
  background: linear-gradient(165deg, rgba(255,255,255,0.055), rgba(255,255,255,0.012));
  border: 1px solid var(--line);
  overflow: hidden;
  transition: transform 0.4s var(--ease), border-color 0.4s var(--ease), box-shadow 0.4s var(--ease);
}
.service-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(520px 320px at 100% 0%, rgba(62, 230, 196, 0.12), transparent 62%);
  opacity: 0;
  transition: opacity 0.45s var(--ease);
  pointer-events: none;
}
.service-card:hover {
  transform: translateY(-6px);
  border-color: rgba(62, 230, 196, 0.32);
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.45);
}
.service-card:hover::before { opacity: 1; }

.service-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
}
.service-icon {
  width: 68px; height: 68px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 18px;
  background: linear-gradient(150deg, rgba(62, 230, 196, 0.16), rgba(74, 168, 255, 0.1));
  border: 1px solid rgba(62, 230, 196, 0.22);
  color: var(--accent);
}
.service-icon svg { width: 38px; height: 38px; }
.service-index {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--text-dim);
}
.service-card h3 {
  font-size: 1.6rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin-bottom: 14px;
}
.service-card > p {
  color: var(--text-soft);
  margin-bottom: 26px;
  font-size: 15.5px;
}
.service-list { display: grid; gap: 12px; }
.service-list li {
  position: relative;
  padding-left: 26px;
  font-size: 15px;
  color: var(--text-soft);
}
.service-list li::before {
  content: "";
  position: absolute;
  left: 0; top: 9px;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--gradient);
  box-shadow: 0 0 10px rgba(62, 230, 196, 0.5);
}

/* ---------- Advantages ---------- */
.advantages-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}
.advantage-item {
  display: flex;
  gap: 22px;
  padding: clamp(26px, 3vw, 36px);
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--surface);
  transition: border-color 0.35s var(--ease), background 0.35s var(--ease), transform 0.35s var(--ease);
}
.advantage-item:hover {
  border-color: rgba(74, 168, 255, 0.32);
  background: var(--surface-strong);
  transform: translateY(-4px);
}
.advantage-icon {
  flex-shrink: 0;
  width: 52px; height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  color: var(--accent-2);
  background: rgba(74, 168, 255, 0.1);
  border: 1px solid rgba(74, 168, 255, 0.2);
}
.advantage-icon svg { width: 30px; height: 30px; }
.advantage-item h4 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 8px;
}
.advantage-item p {
  font-size: 14.5px;
  color: var(--text-soft);
}

/* ---------- Closing ---------- */
.closing {
  position: relative;
  padding: clamp(90px, 13vw, 160px) 0;
  text-align: center;
  overflow: hidden;
  background:
    radial-gradient(800px 460px at 50% 40%, rgba(62, 230, 196, 0.1), transparent 65%),
    radial-gradient(700px 420px at 50% 60%, rgba(74, 168, 255, 0.1), transparent 65%);
  border-top: 1px solid var(--line);
}
.closing-inner h2 {
  font-size: clamp(2.2rem, 5vw, 4rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  background: linear-gradient(120deg, #ffffff 20%, #9fe9da 55%, #7cc2ff 90%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  margin-bottom: 18px;
}
.closing-inner p {
  font-size: clamp(1rem, 1.6vw, 1.15rem);
  letter-spacing: 0.32em;
  color: var(--text-dim);
  text-transform: uppercase;
}

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--line);
  background: var(--bg-dark);
  padding: 34px 0;
}
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}
.footer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 600;
  font-size: 15px;
}
.footer-brand .logo-mark { width: 34px; height: 34px; font-size: 12px; border-radius: 10px; }
.footer-copy { font-size: 13.5px; color: var(--text-dim); }
.footer-meta {
  display: flex;
  align-items: center;
  gap: 8px 18px;
  flex-wrap: wrap;
}
.footer-icp {
  font-size: 13.5px;
  color: var(--text-dim);
  transition: color 0.3s var(--ease);
}
.footer-icp:hover { color: var(--accent); }

/* ---------- Reveal animation ---------- */
.reveal {
  opacity: 0;
  transform: translateY(34px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
  will-change: opacity, transform;
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }
.services-grid .service-card:nth-child(2) { transition-delay: 0.1s; }
.advantages-grid .advantage-item:nth-child(2) { transition-delay: 0.08s; }
.advantages-grid .advantage-item:nth-child(3) { transition-delay: 0.16s; }
.advantages-grid .advantage-item:nth-child(4) { transition-delay: 0.24s; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .about-grid { grid-template-columns: 1fr; }
  .services-grid { grid-template-columns: 1fr; }
  .advantages-grid { grid-template-columns: 1fr; }
  .hero-net { opacity: 0.4; right: -30%; width: 520px; height: 520px; }
  .br-pc { display: none; }
}

@media (max-width: 780px) {
  .nav-toggle { display: flex; }
  .nav-links {
    position: absolute;
    top: calc(100% + 10px);
    right: 28px;
    left: 28px;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    padding: 12px;
    border-radius: 18px;
    background: rgba(10, 16, 32, 0.97);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--line);
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: opacity 0.3s var(--ease), transform 0.3s var(--ease), visibility 0.3s;
  }
  .nav-links.open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }
  .nav-links a {
    display: block;
    padding: 13px 16px;
    border-radius: 12px;
    font-size: 16px;
  }
  .nav-links a:hover { background: var(--surface); }
  .nav-links a::after { display: none; }

  .hero { min-height: auto; padding: 128px 0 72px; }
  .hero-metrics { gap: 28px 40px; }
  .hero-actions { margin-bottom: 52px; }
}

@media (max-width: 520px) {
  .container { padding: 0 20px; }
  .nav { padding: 0 20px; }
  .nav-links { right: 20px; left: 20px; }
  .hero-inner { padding: 0 20px; }
  .hero-actions { flex-direction: column; align-items: stretch; }
  .btn { width: 100%; }
  .logo-name { display: none; }
  .hero-metrics { gap: 22px; }
  .metric { min-width: calc(50% - 22px); }
  .about-panel { border-radius: 16px; }
  .panel-row { padding: 18px 22px; }
  .service-card { padding: 26px 22px; }
  .advantage-item { flex-direction: column; gap: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  .reveal { opacity: 1; transform: none; }
}
