/* ==============================================
   黄威皓 — 医药销售个人网站
   Design: Glassmorphism + Modern Science
   ============================================== */

/* --- CSS Variables --- */
:root {
  --color-bg: #faf8f5;
  --color-bg-alt: #f3f0ed;
  --color-surface: rgba(255, 255, 255, 0.65);
  --color-surface-hover: rgba(255, 255, 255, 0.85);
  --color-glass-border: rgba(255, 255, 255, 0.5);
  --color-glass-shadow: rgba(102, 126, 234, 0.08);
  --color-text: #2c2433;
  --color-text-muted: #6b6376;
  --color-accent-1: #667eea;
  --color-accent-2: #764ba2;
  --color-accent-3: #c471ed;
  --color-gradient: linear-gradient(120deg, #667eea 0%, #764ba2 50%, #c471ed 100%);
  --color-gradient-subtle: linear-gradient(120deg, rgba(102, 126, 234, 0.08) 0%, rgba(118, 75, 162, 0.06) 100%);
  --font-display: 'Playfair Display', 'Noto Serif SC', 'STSong', 'SimSun', serif;
  --font-body: 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', 'Hiragino Sans GB', sans-serif;
  --radius-sm: 12px;
  --radius-md: 20px;
  --radius-lg: 28px;
  --blur-glass: 18px;
  --blur-nav: 14px;
  --max-width: 1080px;
  --nav-height: 64px;
  --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-out-back: cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.75;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
img { max-width: 100%; display: block; }

/* --- Glass Card --- */
.glass-card {
  background: var(--color-surface);
  backdrop-filter: blur(var(--blur-glass));
  -webkit-backdrop-filter: blur(var(--blur-glass));
  border: 1px solid var(--color-glass-border);
  border-radius: var(--radius-md);
  padding: 32px;
  box-shadow: 0 4px 24px var(--color-glass-shadow), 0 1px 2px rgba(0,0,0,0.04);
  transition: transform 0.35s var(--ease-out-expo), box-shadow 0.35s var(--ease-out-expo), background 0.35s var(--ease-out-expo);
}
.glass-card:hover {
  transform: translateY(-3px);
  background: var(--color-surface-hover);
  box-shadow: 0 12px 40px rgba(102, 126, 234, 0.12), 0 2px 4px rgba(0,0,0,0.04);
}

/* --- Navigation --- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-height);
  z-index: 1000;
  transition: background 0.4s var(--ease-out-expo), box-shadow 0.4s var(--ease-out-expo), backdrop-filter 0.4s var(--ease-out-expo);
}
.nav.scrolled {
  background: rgba(250, 248, 245, 0.7);
  backdrop-filter: blur(var(--blur-nav));
  -webkit-backdrop-filter: blur(var(--blur-nav));
  box-shadow: 0 1px 0 rgba(0,0,0,0.05), 0 4px 20px rgba(0,0,0,0.04);
}
.nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nav-logo {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 2px;
  background: var(--color-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.nav-links { display: flex; gap: 36px; }
.nav-link {
  font-size: 14px;
  font-weight: 500;
  color: var(--color-text-muted);
  position: relative;
  transition: color 0.3s;
}
.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px; left: 0; right: 0;
  height: 2px;
  background: var(--color-gradient);
  border-radius: 1px;
  transform: scaleX(0);
  transition: transform 0.3s var(--ease-out-expo);
}
.nav-link:hover, .nav-link:focus-visible { color: var(--color-text); }
.nav-link:hover::after, .nav-link:focus-visible::after { transform: scaleX(1); }

/* Hamburger */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none; border: none;
  cursor: pointer;
  padding: 4px;
  z-index: 1001;
}
.nav-toggle span {
  display: block;
  width: 22px; height: 2px;
  background: var(--color-text);
  border-radius: 1px;
  transition: transform 0.3s var(--ease-out-expo), opacity 0.3s;
}
.nav-toggle.active span:nth-child(1) { transform: rotate(45deg) translate(4px, 5px); }
.nav-toggle.active span:nth-child(2) { opacity: 0; }
.nav-toggle.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -6px); }

/* --- Hero --- */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  padding: 100px 24px 60px;
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.hero-bg svg { width: 100%; height: 100%; color: var(--color-accent-1); }
.hero-content { position: relative; z-index: 1; width: 100%; max-width: 680px; }
.hero-card {
  background: var(--color-surface);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--color-glass-border);
  border-radius: var(--radius-lg);
  padding: 56px 48px;
  text-align: center;
  box-shadow: 0 8px 48px rgba(102, 126, 234, 0.08);
}
.hero-greeting {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 18px;
  color: var(--color-text-muted);
  margin-bottom: 8px;
}
.hero-name {
  font-family: var(--font-display);
  font-size: clamp(44px, 8vw, 72px);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: 2px;
  background: var(--color-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero-divider {
  width: 60px; height: 3px;
  background: var(--color-gradient);
  border-radius: 2px;
  margin: 20px auto;
}
.hero-title {
  font-size: 18px;
  font-weight: 500;
  color: var(--color-text);
  margin-bottom: 12px;
}
.hero-sub {
  font-size: 15px;
  color: var(--color-text-muted);
  max-width: 420px;
  margin: 0 auto 36px;
  line-height: 1.6;
}
.hero-actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

/* Buttons */
.btn-primary, .btn-secondary {
  display: inline-flex;
  align-items: center;
  padding: 14px 32px;
  font-size: 15px;
  font-weight: 600;
  border-radius: 100px;
  transition: transform 0.3s var(--ease-out-expo), box-shadow 0.3s var(--ease-out-expo);
  cursor: pointer;
}
.btn-primary {
  background: var(--color-gradient);
  color: #fff;
  box-shadow: 0 4px 20px rgba(102, 126, 234, 0.3);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 32px rgba(102, 126, 234, 0.4); }
.btn-secondary {
  background: rgba(255,255,255,0.6);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(102, 126, 234, 0.2);
  color: var(--color-accent-2);
}
.btn-secondary:hover { transform: translateY(-2px); background: rgba(255,255,255,0.85); }

/* Scroll indicator */
.hero-scroll {
  position: absolute;
  bottom: 32px; left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--color-text-muted);
  animation: float 2s ease-in-out infinite;
}
@keyframes float {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(6px); }
}

/* --- Sections --- */
.section {
  position: relative;
  padding: 100px 24px;
}
.section-alt {
  background: var(--color-bg-alt);
}
.section-bg {
  position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 0;
}
.section-bg svg { position: absolute; width: 100%; height: 100%; }
.container { position: relative; z-index: 1; max-width: var(--max-width); margin: 0 auto; }

.section-label {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 14px;
  color: var(--color-accent-1);
  letter-spacing: 3px;
  text-transform: uppercase;
  margin-bottom: 8px;
}
.section-title {
  font-family: var(--font-display);
  font-size: clamp(32px, 5vw, 44px);
  font-weight: 700;
  letter-spacing: 1px;
  margin-bottom: 48px;
  color: var(--color-text);
}

/* --- About --- */
.about-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 24px;
}
.about-intro p { color: var(--color-text); margin-bottom: 16px; }
.about-intro p:last-child { margin-bottom: 0; }
.about-info { display: flex; flex-direction: column; gap: 20px; }
.info-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  font-size: 15px;
  color: var(--color-text-muted);
  line-height: 1.6;
}
.info-item strong { color: var(--color-text); display: block; margin-bottom: 2px; }
.info-icon { color: var(--color-accent-1); font-size: 10px; margin-top: 7px; flex-shrink: 0; }

/* --- Timeline --- */
.timeline { position: relative; padding-left: 40px; }
.timeline-line {
  position: absolute;
  left: 15px; top: 0; bottom: 0;
  width: 2px;
  background: linear-gradient(180deg, var(--color-accent-1), var(--color-accent-2), transparent);
  border-radius: 1px;
}
.timeline-item { position: relative; margin-bottom: 32px; }
.timeline-item:last-child { margin-bottom: 0; }
.timeline-dot {
  position: absolute;
  left: -34px; top: 28px;
  width: 12px; height: 12px;
  border-radius: 50%;
  background: var(--color-gradient);
  box-shadow: 0 0 0 6px var(--color-bg-alt), 0 0 16px rgba(102,126,234,0.3);
  z-index: 2;
}
.timeline-card { position: relative; }
.timeline-date {
  font-size: 13px;
  font-weight: 600;
  color: var(--color-accent-1);
  letter-spacing: 1px;
}
.timeline-card h3 {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  margin: 6px 0;
}
.timeline-company {
  font-size: 14px;
  color: var(--color-text-muted);
  margin-bottom: 12px;
}
.timeline-card p { color: var(--color-text-muted); font-size: 15px; }
.timeline-card p strong { color: var(--color-text); }

/* --- Insights --- */
.insights-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.insight-card { cursor: default; }
.insight-tag {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--color-accent-1);
  background: rgba(102, 126, 234, 0.08);
  padding: 4px 12px;
  border-radius: 100px;
  margin-bottom: 14px;
}
.insight-card h3 {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 10px;
  line-height: 1.35;
}
.insight-card p { color: var(--color-text-muted); font-size: 14px; margin-bottom: 16px; }
.insight-date { font-size: 12px; color: var(--color-accent-3); font-style: italic; }

/* --- Contact --- */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
  max-width: 560px;
}
.contact-card { text-align: center; padding: 40px 32px; }
.contact-icon { font-size: 32px; margin-bottom: 12px; }
.contact-card h3 { font-family: var(--font-display); font-size: 20px; margin-bottom: 8px; }
.contact-card a {
  font-size: 15px;
  color: var(--color-accent-1);
  font-weight: 500;
  transition: color 0.3s;
}
.contact-card a:hover { color: var(--color-accent-2); }

/* --- Footer --- */
.footer {
  text-align: center;
  padding: 32px 24px;
  font-size: 13px;
  color: var(--color-text-muted);
  border-top: 1px solid rgba(0,0,0,0.05);
}
.footer-url {
  margin-top: 4px;
  font-size: 12px;
  color: var(--color-accent-1);
}

/* --- Animations --- */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s var(--ease-out-expo), transform 0.7s var(--ease-out-expo);
}
.reveal.visible { opacity: 1; transform: translateY(0); }
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }

/* --- Responsive --- */
@media (max-width: 1024px) {
  .insights-grid { grid-template-columns: 1fr; max-width: 560px; margin: 0 auto; }
}

@media (max-width: 768px) {
  .hero-card { padding: 40px 28px; }
  .about-grid { grid-template-columns: 1fr; }
  .timeline { padding-left: 32px; }
  .timeline-dot { left: -26px; }
  .insights-grid { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; max-width: 100%; }
  .section { padding: 72px 20px; }

  .nav-links {
    position: fixed;
    top: 0; right: -100%;
    width: 260px; height: 100vh;
    flex-direction: column;
    gap: 0;
    background: rgba(250,248,245,0.95);
    backdrop-filter: blur(var(--blur-nav));
    -webkit-backdrop-filter: blur(var(--blur-nav));
    padding: 100px 32px 32px;
    transition: right 0.4s var(--ease-out-expo);
    box-shadow: -4px 0 40px rgba(0,0,0,0.08);
  }
  .nav-links.open { right: 0; }
  .nav-link {
    font-size: 20px;
    padding: 16px 0;
    border-bottom: 1px solid rgba(0,0,0,0.05);
  }
  .nav-toggle { display: flex; }
}

@media (max-width: 480px) {
  .hero-card { padding: 32px 20px; }
  .hero-actions { flex-direction: column; align-items: center; }
  .btn-primary, .btn-secondary { width: 100%; justify-content: center; }
}
