/* ========================================
   HAULIV — High-Precision Fulfillment
   Dark theme | Cyan accents | Mobile-first
   ======================================== */

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

:root {
  --bg-primary: #0a1628;
  --bg-secondary: #0d1f35;
  --bg-card: #111d30;
  --bg-card-hover: #152640;
  --accent: #00e5ff;
  --accent-dim: rgba(0, 229, 255, 0.15);
  --accent-glow: rgba(0, 229, 255, 0.3);
  --text-primary: #e8edf3;
  --text-secondary: #8a9bb5;
  --text-muted: #5a6f8a;
  --white: #ffffff;
  --red-muted: #ff6b6b;
  --green-accent: #00e5a0;
  --border: rgba(255, 255, 255, 0.08);

  --ff: 'Inter', system-ui, -apple-system, sans-serif;
  --fs-base: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
  --fs-sm: clamp(0.875rem, 0.85rem + 0.15vw, 0.9375rem);
  --fs-lg: clamp(1.125rem, 1rem + 0.5vw, 1.375rem);
  --fs-xl: clamp(1.5rem, 1.2rem + 1.5vw, 2.25rem);
  --fs-2xl: clamp(2rem, 1.5rem + 2.5vw, 3.5rem);
  --fs-stat: clamp(1.75rem, 1.5rem + 1.5vw, 2.5rem);

  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 1.5rem;
  --space-lg: 2.5rem;
  --space-xl: 4rem;
  --space-2xl: 6rem;

  --radius: 8px;
  --radius-lg: 16px;
  --shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.4);
  --transition: 0.3s ease;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
  -webkit-text-size-adjust: 100%;
}

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

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

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

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-md);
}

.section {
  padding: var(--space-xl) 0;
}

/* --- Section Headers --- */
.section__header {
  text-align: center;
  max-width: 700px;
  margin: 0 auto var(--space-xl);
}

.section__tag {
  display: inline-block;
  font-size: var(--fs-sm);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: var(--space-sm);
}

.section__title {
  font-size: var(--fs-xl);
  font-weight: 800;
  line-height: 1.15;
  color: var(--white);
  letter-spacing: -0.02em;
  margin-bottom: var(--space-sm);
}
.section__title--light { color: var(--white); }

.section__lead {
  font-size: var(--fs-base);
  color: var(--text-secondary);
  line-height: 1.7;
}

/* --- Buttons --- */
.btn {
  display: inline-block;
  padding: 0.875rem 2rem;
  font-family: var(--ff);
  font-size: var(--fs-base);
  font-weight: 600;
  border-radius: var(--radius);
  border: 2px solid transparent;
  cursor: pointer;
  text-align: center;
  transition: transform var(--transition), box-shadow var(--transition), background var(--transition);
  min-height: 44px;
}

.btn--primary {
  background: var(--accent);
  color: var(--bg-primary);
  border-color: var(--accent);
}
.btn--primary:hover {
  background: #00c4db;
  transform: translateY(-2px);
  box-shadow: 0 8px 30px var(--accent-glow);
}

.btn--outline {
  background: transparent;
  color: var(--accent);
  border-color: rgba(0, 229, 255, 0.3);
}
.btn--outline:hover {
  border-color: var(--accent);
  background: var(--accent-dim);
  transform: translateY(-2px);
}

.btn--lg {
  padding: 1.125rem 2.5rem;
  font-size: var(--fs-lg);
}

/* ========================================
   NAVIGATION
   ======================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(10, 22, 40, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 70px;
}

.nav__logo {
  display: flex;
  align-items: center;
  z-index: 10;
}

.nav__toggle {
  display: flex;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  min-height: 44px;
  min-width: 44px;
  align-items: center;
  justify-content: center;
  z-index: 10;
}
.nav__toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--white);
  border-radius: 2px;
  transition: transform var(--transition), opacity var(--transition);
}
.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); }

.nav__menu {
  list-style: none;
  position: fixed;
  top: 70px;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--bg-primary);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding-top: var(--space-lg);
  gap: var(--space-md);
  visibility: hidden;
  opacity: 0;
  transition: opacity var(--transition), visibility var(--transition);
  z-index: 999;
}
.nav__menu--open { visibility: visible; opacity: 1; }

.nav__link {
  color: var(--text-secondary);
  font-size: var(--fs-lg);
  font-weight: 500;
  padding: var(--space-xs) var(--space-sm);
  transition: color var(--transition);
}
.nav__link:hover { color: var(--accent); }

.nav__cta {
  background: var(--accent);
  color: var(--bg-primary) !important;
  border-radius: var(--radius);
  padding: 0.625rem 1.5rem;
  font-weight: 600;
}
.nav__cta:hover { background: #00c4db; }

@media (min-width: 769px) {
  .nav__toggle { display: none; }
  .nav__menu {
    position: static;
    flex-direction: row;
    visibility: visible;
    opacity: 1;
    padding: 0;
    gap: var(--space-sm);
    background: none;
  }
  .nav__link { font-size: var(--fs-sm); }
}

/* ========================================
   HERO
   ======================================== */
.hero {
  position: relative;
  min-height: 85vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.hero__bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
}
.hero__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  max-width: none;
}

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

.hero__content {
  position: relative;
  z-index: 1;
  padding-top: var(--space-xl);
  padding-bottom: var(--space-xl);
  text-align: center;
  max-width: 820px;
  margin: 0 auto;
}

.hero__tag {
  font-size: var(--fs-sm);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: var(--space-sm);
}

.hero__title {
  font-size: var(--fs-2xl);
  font-weight: 900;
  line-height: 1.1;
  color: var(--white);
  margin-bottom: var(--space-md);
  letter-spacing: -0.03em;
}

.hero__sub {
  font-size: var(--fs-lg);
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: var(--space-lg);
  max-width: 650px;
  margin-left: auto;
  margin-right: auto;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  justify-content: center;
  margin-bottom: var(--space-xl);
}

.hero__stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-sm);
  max-width: 600px;
  margin: 0 auto;
}

.hero__stat {
  text-align: center;
  padding: var(--space-sm);
  background: rgba(0, 229, 255, 0.06);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.hero__stat-value {
  display: block;
  font-size: var(--fs-stat);
  font-weight: 800;
  color: var(--accent);
  line-height: 1.2;
}

.hero__stat-label {
  font-size: var(--fs-sm);
  color: var(--text-muted);
  font-weight: 500;
}

/* ========================================
   METHODOLOGY — Features
   ======================================== */
.methodology {
  background: var(--bg-secondary);
}

.features {
  display: flex;
  flex-direction: column;
  gap: var(--space-xl);
}

.feature {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-lg);
  align-items: center;
}

.feature__image {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
}
.feature__image img {
  width: 100%;
  height: auto;
  display: block;
}

.feature__content {
  position: relative;
}

.feature__number {
  display: block;
  font-size: var(--fs-stat);
  font-weight: 900;
  color: var(--accent);
  opacity: 0.3;
  margin-bottom: var(--space-xs);
  line-height: 1;
}

.feature__title {
  font-size: var(--fs-xl);
  font-weight: 800;
  color: var(--white);
  margin-bottom: var(--space-sm);
}

.feature__text {
  font-size: var(--fs-base);
  color: var(--text-secondary);
  line-height: 1.8;
}

/* ========================================
   ABOUT — Glass Box
   ======================================== */
.about {
  position: relative;
  overflow: hidden;
  padding: 0;
}

.about__bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
}
.about__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  max-width: none;
}

.about__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(10, 22, 40, 0.92) 0%, rgba(10, 22, 40, 0.75) 100%);
}

.about__inner {
  position: relative;
  z-index: 1;
  padding-top: var(--space-xl);
  padding-bottom: var(--space-xl);
}

.about__content {
  max-width: 680px;
}

.about__content p {
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: var(--space-md);
}

.about__highlight {
  font-size: var(--fs-lg);
  font-weight: 700;
  color: var(--accent) !important;
  padding: var(--space-md);
  background: var(--accent-dim);
  border-left: 3px solid var(--accent);
  border-radius: 0 var(--radius) var(--radius) 0;
}

/* ========================================
   COMPARISON TABLE
   ======================================== */
.compare {
  background: var(--bg-primary);
}

.table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--bg-card);
}

.compare-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 600px;
}

.compare-table th,
.compare-table td {
  padding: var(--space-md);
  text-align: left;
  border-bottom: 1px solid var(--border);
  font-size: var(--fs-sm);
}

.compare-table thead th {
  background: var(--bg-secondary);
  font-weight: 700;
  font-size: var(--fs-base);
  color: var(--white);
  position: sticky;
  top: 0;
}

.compare-table tbody td:first-child {
  font-weight: 600;
  color: var(--white);
}

.compare-table__old {
  color: var(--text-muted);
}

.compare-table__new {
  color: var(--accent);
}

.compare-table tbody tr:last-child td {
  border-bottom: none;
}

.compare-table tbody tr:hover {
  background: rgba(0, 229, 255, 0.03);
}

.table-note {
  display: block;
  font-size: 0.75rem;
  color: var(--red-muted);
  margin-top: 0.25rem;
  font-style: italic;
}

.table-accent {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  background: var(--accent-dim);
  color: var(--accent);
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
  margin-left: 0.375rem;
}

/* ========================================
   STORY
   ======================================== */
.story {
  background: var(--bg-secondary);
}

.story__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-md);
}

.story__card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  transition: border-color var(--transition), box-shadow var(--transition);
}
.story__card:hover {
  border-color: rgba(0, 229, 255, 0.2);
  box-shadow: 0 0 30px rgba(0, 229, 255, 0.05);
}

.story__card-tag {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: var(--space-sm);
}

.story__card h3 {
  font-size: var(--fs-lg);
  font-weight: 800;
  color: var(--white);
  margin-bottom: var(--space-sm);
}

.story__card p {
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: var(--space-sm);
}
.story__card p:last-child { margin-bottom: 0; }

.story__card--manifesto {
  border-color: rgba(0, 229, 255, 0.15);
  background: linear-gradient(135deg, var(--bg-card) 0%, rgba(0, 229, 255, 0.04) 100%);
}

.story__list {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.story__list li {
  padding-left: var(--space-md);
  border-left: 2px solid var(--accent);
}

.story__list li strong {
  display: block;
  color: var(--white);
  font-weight: 700;
  margin-bottom: 0.25rem;
}

.story__list li span {
  color: var(--text-secondary);
  font-size: var(--fs-sm);
  line-height: 1.7;
}

/* ========================================
   FOOTER
   ======================================== */
.footer {
  background: var(--bg-primary);
  border-top: 1px solid var(--border);
}

.footer__cta {
  text-align: center;
  padding-top: var(--space-xl);
  padding-bottom: var(--space-xl);
  border-bottom: 1px solid var(--border);
}

.footer__title {
  font-size: var(--fs-xl);
  font-weight: 800;
  color: var(--white);
  margin-bottom: var(--space-sm);
}

.footer__sub {
  color: var(--text-secondary);
  margin-bottom: var(--space-lg);
  font-size: var(--fs-base);
  max-width: 650px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.7;
}

.footer__integrations {
  padding: var(--space-lg) 0;
  text-align: center;
  border-bottom: 1px solid var(--border);
}

.footer__integrations-label {
  font-size: var(--fs-sm);
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 600;
  margin-bottom: var(--space-sm);
}

.footer__logos {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-md);
}

.footer__logos span {
  font-weight: 600;
  font-size: var(--fs-sm);
  color: var(--text-secondary);
  padding: var(--space-xs) var(--space-md);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-card);
}

.footer__hubs {
  padding: var(--space-lg) 0;
  text-align: center;
  border-bottom: 1px solid var(--border);
}

.footer__hubs-label {
  font-size: var(--fs-sm);
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 600;
  margin-bottom: var(--space-sm);
}

.footer__hub-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-sm);
}

.footer__hub {
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--text-muted);
  padding: var(--space-xs) var(--space-sm);
  border-radius: 50px;
  border: 1px solid var(--border);
}

.footer__hub--active {
  color: var(--accent);
  border-color: var(--accent);
  background: var(--accent-dim);
}

.footer__bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-sm);
  padding: var(--space-md) 0;
}

.footer__info {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  color: var(--text-muted);
  font-size: var(--fs-sm);
}

.footer__copy {
  color: var(--text-muted);
  font-size: var(--fs-sm);
}

/* ========================================
   SCROLL REVEAL
   ======================================== */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s cubic-bezier(0.4, 0, 0.2, 1), transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
}
.reveal--visible {
  opacity: 1;
  transform: translateY(0);
}

.features .feature:nth-child(2).reveal { transition-delay: 0.05s; }
.features .feature:nth-child(3).reveal { transition-delay: 0.1s; }
.features .feature:nth-child(4).reveal { transition-delay: 0.15s; }

.story__grid .story__card:nth-child(2).reveal { transition-delay: 0.1s; }
.story__grid .story__card:nth-child(3).reveal { transition-delay: 0.2s; }

/* ========================================
   FOCUS
   ======================================== */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

/* ========================================
   RESPONSIVE — Tablet (768px+)
   ======================================== */
@media (min-width: 768px) {
  .feature {
    grid-template-columns: 1fr 1fr;
  }

  .feature--reverse .feature__image {
    order: 2;
  }

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

  .story__card--manifesto {
    grid-column: 1 / -1;
  }
}

/* ========================================
   RESPONSIVE — Desktop (1024px+)
   ======================================== */
@media (min-width: 1024px) {
  .section {
    padding: var(--space-2xl) 0;
  }

  .hero {
    min-height: 90vh;
  }

  .about__inner {
    padding-top: var(--space-2xl);
    padding-bottom: var(--space-2xl);
  }

  .footer__cta {
    padding-top: var(--space-2xl);
    padding-bottom: var(--space-2xl);
  }
}

/* ========================================
   PRINT
   ======================================== */
@media print {
  .site-header, .hero__bg, .about__bg { display: none; }
  .hero__overlay, .about__overlay { background: none; }
  body { color: #000; background: #fff; }
  .section__title, .hero__title, .footer__title { color: #000; }
}
