/* ============================================
   SOURCEDIRECT — China Sourcing Landing Page
   ============================================ */

/* --- CSS Variables --- */
:root {
  --bg-primary: #0a0a0a;
  --bg-secondary: #141414;
  --bg-tertiary: #1f1f1f;
  --bg-elevated: #2d2d2d;
  --text-primary: #FFFFFF;
  --text-secondary: #9CA3AF;
  --text-muted: #6B7280;
  --accent: #E63946;
  --accent-warm: #F4A261;
  --accent-glow: rgba(230, 57, 70, 0.15);
  --accent-glow-strong: rgba(230, 57, 70, 0.3);
  --border: rgba(255, 255, 255, 0.06);
  --border-hover: rgba(230, 57, 70, 0.4);
  --font-sans: 'Inter', system-ui, 'PingFang SC', 'Microsoft YaHei', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
  --radius: 4px;
  --nav-height: 72px;
}

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

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

body {
  font-family: var(--font-sans);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

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

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}

select {
  font-family: inherit;
}

/* --- Scroll Container --- */
.scroll-container {
  scroll-snap-type: y proximity;
  overflow-y: auto;
  height: 100vh;
  scroll-behavior: smooth;
}

/* --- Section Base --- */
.section {
  min-height: 100vh;
  scroll-snap-align: start;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: calc(var(--nav-height) + 40px) 5vw 60px;
}

.section__header {
  text-align: center;
  margin-bottom: 60px;
}

.section__number {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--accent);
  letter-spacing: 0.2em;
  display: block;
  margin-bottom: 16px;
}

.section__title {
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.section__desc {
  font-size: clamp(0.9rem, 1.5vw, 1.1rem);
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.7;
}

/* ============================================
   NAVIGATION
   ============================================ */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 5vw;
  z-index: 1000;
  transition: background 0.4s var(--ease-smooth), backdrop-filter 0.4s var(--ease-smooth);
}

.nav--scrolled {
  background: rgba(10, 10, 10, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
}

.nav__brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav__logo {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--accent);
  color: var(--accent);
  border-radius: var(--radius);
}

.nav__name {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav__link {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-secondary);
  transition: color 0.3s var(--ease-smooth);
  position: relative;
}

.nav__link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--accent);
  transition: width 0.3s var(--ease-out);
}

.nav__link:hover {
  color: var(--text-primary);
}

.nav__link:hover::after {
  width: 100%;
}

.nav__link--cta {
  color: var(--accent);
  border: 1px solid var(--accent);
  padding: 8px 20px;
  border-radius: var(--radius);
  transition: all 0.3s var(--ease-smooth);
}

.nav__link--cta:hover {
  background: var(--accent);
  color: var(--text-primary);
}

.nav__link--cta::after {
  display: none;
}

.nav__menu-btn {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
  z-index: 1001;
}

.nav__menu-btn span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: var(--text-primary);
  transition: all 0.3s var(--ease-out);
  transform-origin: center;
}

.nav__menu-btn--active span:nth-child(1) {
  transform: rotate(45deg) translate(4px, 5px);
}

.nav__menu-btn--active span:nth-child(2) {
  opacity: 0;
}

.nav__menu-btn--active span:nth-child(3) {
  transform: rotate(-45deg) translate(4px, -5px);
}

/* Mobile Menu */
.mobile-menu {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(10, 10, 10, 0.97);
  backdrop-filter: blur(30px);
  -webkit-backdrop-filter: blur(30px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 40px;
  z-index: 999;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s var(--ease-smooth);
}

.mobile-menu--active {
  opacity: 1;
  pointer-events: all;
}

.mobile-menu__link {
  font-size: 1.2rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-secondary);
  transition: color 0.3s;
}

.mobile-menu__link:hover {
  color: var(--accent);
}

/* ============================================
   HERO SECTION
   ============================================ */
.section--hero {
  padding: 0;
  justify-content: center;
  align-items: flex-start;
  overflow: hidden;
}

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

.hero__bg-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.05);
  animation: heroZoom 20s var(--ease-smooth) infinite alternate;
}

@keyframes heroZoom {
  0% { transform: scale(1.05); }
  100% { transform: scale(1.12); }
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg,
      rgba(10, 10, 10, 0.6) 0%,
      rgba(10, 10, 10, 0.3) 40%,
      rgba(10, 10, 10, 0.5) 70%,
      rgba(10, 10, 10, 0.95) 100%
    );
}

.hero__content {
  position: relative;
  z-index: 1;
  padding: 0 5vw;
  max-width: 900px;
}

.hero__tag {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
}

.hero__tag-line {
  width: 40px;
  height: 1px;
  background: var(--accent);
}

.hero__tag-text {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.25em;
  color: var(--accent);
  text-transform: uppercase;
}

.hero__title {
  margin-bottom: 28px;
}

.hero__title-line {
  display: block;
  font-size: clamp(2.5rem, 7vw, 5.5rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.05;
  text-transform: uppercase;
}

.hero__title-line--accent {
  color: var(--accent);
}

.hero__desc {
  font-size: clamp(0.9rem, 1.5vw, 1.1rem);
  color: var(--text-secondary);
  max-width: 540px;
  line-height: 1.7;
  margin-bottom: 36px;
}

.hero__actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 60px;
}

.hero__stats {
  display: flex;
  gap: 48px;
  flex-wrap: wrap;
}

.hero__stat {
  display: flex;
  flex-direction: column;
}

.hero__stat-num {
  font-family: var(--font-mono);
  font-size: clamp(1.8rem, 3vw, 2.5rem);
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1;
}

.hero__stat-suffix {
  font-family: var(--font-mono);
  font-size: clamp(1rem, 1.5vw, 1.2rem);
  font-weight: 500;
  color: var(--accent);
}

.hero__stat-label {
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-top: 6px;
}

.hero__scroll-hint {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  z-index: 1;
}

.hero__scroll-text {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.3em;
  color: var(--text-muted);
  text-transform: uppercase;
}

.hero__scroll-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(180deg, var(--accent), transparent);
  animation: scrollPulse 2s var(--ease-smooth) infinite;
}

@keyframes scrollPulse {
  0%, 100% { opacity: 0.3; transform: scaleY(0.6); }
  50% { opacity: 1; transform: scaleY(1); }
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 14px 32px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  transition: all 0.3s var(--ease-smooth);
  cursor: pointer;
  white-space: nowrap;
}

.btn--primary {
  background: var(--accent);
  color: var(--text-primary);
  border-color: var(--accent);
}

.btn--primary:hover {
  background: transparent;
  color: var(--accent);
  box-shadow: 0 0 20px var(--accent-glow);
}

.btn--ghost {
  border-color: rgba(255, 255, 255, 0.2);
  color: var(--text-secondary);
}

.btn--ghost:hover {
  border-color: var(--text-primary);
  color: var(--text-primary);
}

.btn--full {
  width: 100%;
}

.btn--whatsapp {
  background: #25D366;
  color: var(--text-primary);
  border-color: #25D366;
}

.btn--whatsapp:hover {
  background: transparent;
  color: #25D366;
}

/* ============================================
   CATEGORIES SECTION
   ============================================ */
.section--categories {
  background: var(--bg-primary);
}

.categories__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}

.categories__item {
  position: relative;
  overflow: hidden;
}

.categories__img-wrapper {
  position: relative;
  aspect-ratio: 3 / 2;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  transition: border-color 0.4s var(--ease-smooth);
}

.categories__img-wrapper:hover {
  border-color: var(--border-hover);
}

.categories__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s var(--ease-out);
}

.categories__img-wrapper:hover .categories__img {
  transform: scale(1.05);
}

.categories__img-overlay {
  position: absolute;
  inset: 0;
  background: rgba(230, 57, 70, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.4s var(--ease-smooth);
}

.categories__img-wrapper:hover .categories__img-overlay {
  opacity: 1;
}

.categories__img-label {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  padding: 8px 16px;
  border: 1px solid var(--accent);
  border-radius: var(--radius);
}

.categories__info {
  padding: 16px 0;
}

.categories__tag {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.2em;
  color: var(--accent-warm);
  text-transform: uppercase;
  display: block;
  margin-bottom: 6px;
}

.categories__name {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin-bottom: 6px;
}

.categories__desc {
  font-size: 0.8rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ============================================
   PROCESS SECTION
   ============================================ */
.section--process {
  background: var(--bg-secondary);
}

.process__timeline {
  position: relative;
  max-width: 700px;
  margin: 0 auto;
  padding-left: 60px;
}

.process__line {
  position: absolute;
  left: 23px;
  top: 0;
  bottom: 0;
  width: 1px;
  background: linear-gradient(180deg, var(--accent), var(--border) 30%, var(--border) 70%, transparent);
}

.process__step {
  position: relative;
  padding: 0 0 40px 0;
}

.process__step:last-child {
  padding-bottom: 0;
}

.process__marker {
  position: absolute;
  left: -60px;
  top: 0;
  width: 47px;
  height: 47px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: border-color 0.4s var(--ease-smooth), box-shadow 0.4s var(--ease-smooth);
}

.process__step:hover .process__marker {
  border-color: var(--accent);
  box-shadow: 0 0 15px var(--accent-glow);
}

.process__marker-num {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--accent);
}

.process__content {
  padding-top: 4px;
}

.process__title {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin-bottom: 8px;
}

.process__desc {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 480px;
}

/* ============================================
   CONTACT SECTION
   ============================================ */
.section--contact {
  background: var(--bg-primary);
}

.contact__wrapper {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 60px;
  max-width: 1000px;
  margin: 0 auto;
  width: 100%;
}

.contact__form {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.contact__field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.contact__label {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.contact__input {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 0.9rem;
  padding: 14px 16px;
  border-radius: var(--radius);
  outline: none;
  transition: border-color 0.3s var(--ease-smooth), box-shadow 0.3s var(--ease-smooth);
  -webkit-appearance: none;
  appearance: none;
}

.contact__input::placeholder {
  color: var(--text-muted);
}

.contact__input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent-glow);
}

.contact__select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%236B7280' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 40px;
  cursor: pointer;
}

.contact__select option {
  background: var(--bg-secondary);
  color: var(--text-primary);
}

.contact__textarea {
  resize: vertical;
  min-height: 100px;
}

.contact__side {
  display: flex;
  flex-direction: column;
  gap: 32px;
  padding-top: 8px;
}

.contact__channel {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.contact__channel-title {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  color: var(--accent);
  text-transform: uppercase;
}

.contact__channel-desc {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.contact__email-link {
  font-size: 0.85rem;
  color: var(--text-primary);
  border-bottom: 1px solid var(--border);
  padding-bottom: 2px;
  transition: border-color 0.3s;
}

.contact__email-link:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.contact__benefits {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.contact__benefits li {
  font-size: 0.8rem;
  color: var(--text-secondary);
  padding-left: 16px;
  position: relative;
}

.contact__benefits li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 8px;
  width: 6px;
  height: 6px;
  border: 1px solid var(--accent-warm);
  border-radius: 1px;
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
  background: var(--bg-primary);
  border-top: 1px solid var(--border);
  padding: 32px 5vw;
  scroll-snap-align: end;
}

.footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
}

.footer__brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.footer__name {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.15em;
}

.footer__copy {
  font-size: 0.7rem;
  color: var(--text-muted);
}

/* ============================================
   LIGHTBOX
   ============================================ */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s var(--ease-smooth);
  padding: 40px;
}

.lightbox--active {
  opacity: 1;
  pointer-events: all;
}

.lightbox__img {
  max-width: 90vw;
  max-height: 85vh;
  object-fit: contain;
  border-radius: var(--radius);
}

.lightbox__close {
  position: absolute;
  top: 24px;
  right: 24px;
  font-size: 2rem;
  color: var(--text-secondary);
  transition: color 0.3s;
  line-height: 1;
}

.lightbox__close:hover {
  color: var(--text-primary);
}

/* ============================================
   REVEAL ANIMATION
   ============================================ */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
}

.reveal--visible {
  opacity: 1;
  transform: translateY(0);
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1024px) {
  .categories__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .contact__wrapper {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .contact__side {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 24px;
  }

  .contact__channel {
    flex: 1;
    min-width: 140px;
  }
}

@media (max-width: 768px) {
  :root {
    --nav-height: 60px;
  }

  .nav__links {
    display: none;
  }

  .nav__menu-btn {
    display: flex;
  }

  .section {
    padding: calc(var(--nav-height) + 24px) 6vw 40px;
  }

  .hero__content {
    padding: 0 6vw;
  }

  .hero__title-line {
    font-size: clamp(2rem, 10vw, 3.5rem);
  }

  .hero__stats {
    gap: 24px;
  }

  .hero__actions {
    flex-direction: column;
    margin-bottom: 40px;
  }

  .hero__actions .btn {
    width: 100%;
    text-align: center;
  }

  .categories__grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .section__header {
    margin-bottom: 36px;
  }

  .process__timeline {
    padding-left: 48px;
  }

  .process__marker {
    left: -48px;
    width: 38px;
    height: 38px;
  }

  .process__line {
    left: 18px;
  }

  .contact__side {
    flex-direction: column;
  }

  .footer__inner {
    flex-direction: column;
    gap: 12px;
    text-align: center;
  }
}

@media (max-width: 480px) {
  .hero__title-line {
    font-size: clamp(1.8rem, 9vw, 2.5rem);
  }

  .hero__stat-num {
    font-size: 1.5rem;
  }

  .section__title {
    font-size: 1.5rem;
  }
}

/* ============================================
   FORM SUCCESS STATE
   ============================================ */
.contact__form--success {
  position: relative;
}

.contact__form--success::after {
  content: 'REQUEST SUBMITTED';
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-secondary);
  border: 1px solid var(--accent);
  border-radius: var(--radius);
  font-family: var(--font-mono);
  font-size: 0.85rem;
  letter-spacing: 0.15em;
  color: var(--accent);
  animation: fadeIn 0.4s var(--ease-out);
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
