/* ============================================================
   ONESTIC — Landing Page Styles
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@300;400;500;600;700&display=swap');

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

:root {
  --color-dark:        #000000;
  --color-light:       #F4F4F4;
  --color-footer:      #000000;
  --color-accent:      #e5f68d;
  --color-text-light:  #F4F4F4;
  --color-text-dark:   #1D1D1D;
  --color-text-muted:  #999999;
  --color-feature-row: #E3E3E3;
  --font-main:         'Space Grotesk', sans-serif;
  --max-width:         1280px;
  --padding-x:         32px;
}

/* Visually hidden but accessible to screen readers and search engines */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-main);
  background: var(--color-dark);
  color: var(--color-text-light);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; }
a { text-decoration: none; color: inherit; }
button { cursor: pointer; background: none; border: none; font-family: inherit; }

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--padding-x);
}

/* ============================================================
   0. TOPBAR
   ============================================================ */
.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 36px;
  background: #2A2A2A;
  z-index: 101;
  overflow: hidden;
  display: flex;
  align-items: center;
}

.topbar-track {
  display: flex;
  align-items: center;
  width: max-content;
  animation: topbar-marquee 48s linear infinite;
}

.topbar-item {
  font-family: var(--font-main);
  font-size: 12px;
  font-weight: 400;
  color: #FFFFFF;
  white-space: nowrap;
  padding: 0 10px;
  letter-spacing: 0.02em;
}

.topbar-sep {
  color: rgba(255, 255, 255, 0.4);
  font-size: 12px;
  padding: 0 5px;
}

@keyframes topbar-marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* ============================================================
   1. HEADER
   ============================================================ */
.site-header {
  position: fixed;
  top: 36px;
  left: 0;
  right: 0;
  z-index: 100;
  transition: background 0.3s ease, transform 0.35s ease;
}

.site-header.header-hidden {
  transform: translateY(calc(-100% - 36px));
}

.site-header.scrolled {
  background: var(--color-dark);
}

.header-inner {
  padding: 28px var(--padding-x) 0;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
}

.header-right {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 12px;
}

.header-inner--no-logo {
  grid-template-columns: auto 1fr;
}

.legal-page .header-inner {
  display: flex;
  grid-template-columns: unset;
  justify-content: space-between;
  align-items: center;
  gap: 0;
}

.lang-switcher {
  display: flex;
  align-items: center;
}

.lang-select {
  appearance: none;
  -webkit-appearance: none;
  background: transparent;
  border: 1px solid rgba(244, 244, 244, 0.4);
  border-radius: 50%;
  color: rgba(244, 244, 244, 0.8);
  font-family: var(--font-main);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
  cursor: pointer;
  width: 37px;
  height: 37px;
  padding: 0;
  text-align: center;
  text-align-last: center;
  transition: border-color 0.2s ease, color 0.2s ease;
}

.lang-select:hover {
  border-color: rgba(244, 244, 244, 0.8);
  color: rgba(244, 244, 244, 1);
}

.lang-select option {
  background: var(--color-dark);
  color: var(--color-text-light);
}

.header-logo {
  width: 160px;
  height: auto;
  display: block;
  opacity: 0;
  transition: opacity 0.15s ease;
}

.header-tagline-mobile {
  display: none;
  position: absolute;
  top: 140px;
  left: 0;
  right: 0;
  z-index: 2;
  padding: 0 var(--padding-x);
  font-size: 28px;
  font-weight: 400;
  line-height: 1.13;
  letter-spacing: -1.2px;
  color: var(--color-text-light);
  pointer-events: none;
}

/* Hero logo scroll animation overlay */
#hero-logo-anim {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  pointer-events: none;
  z-index: 99;
  transform-origin: center top;
  will-change: transform;
}

#hero-logo-anim > div {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
}

#hero-logo-anim img {
  width: 100%;
  height: auto;
  display: block;
}

.header-tagline {
  font-size: 16px;
  font-weight: 400;
  line-height: 1.09;
  letter-spacing: -0.48px;
  color: var(--color-text-light);
  max-width: 448px;
}

.header-divider {
  height: 0;
  border: none;
  border-top: 0.25px solid rgba(244, 244, 244, 0.3);
  margin-top: 14px;
}

.btn-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 22px;
  border: 1px solid rgba(244, 244, 244, 0.8);
  border-radius: 5px;
  font-family: var(--font-main);
  font-size: 12px;
  font-weight: 400;
  color: var(--color-text-light);
  letter-spacing: -0.24px;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
  white-space: nowrap;
  flex-shrink: 0;
  height: 37px;
  min-width: 145px;
}

.btn-cta:hover {
  background: var(--color-accent);
  border-color: var(--color-accent);
  color: var(--color-text-dark);
}

.btn-cta.btn-accent {
  background: transparent;
  color: var(--color-text-light);
  border: 1px solid var(--color-text-light);
  font-weight: 400;
  font-size: 12px;
  letter-spacing: -0.24px;
  border-radius: 5px;
  height: 37px;
  min-width: 145px;
}

.btn-cta.btn-accent:hover {
  background: var(--color-accent);
  border-color: var(--color-accent);
  color: var(--color-text-dark);
}

/* ============================================================
   2. HERO
   ============================================================ */
.hero {
  position: relative;
  height: 100vh;
  min-height: 720px;
  width: 100%;
  overflow: hidden;
}

.hero-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

.hero-logo-wrap {
  position: absolute;
  bottom: 26px;
  left: 0;
  right: 0;
  z-index: 1;
  pointer-events: none;
}

.hero-logo {
  width: 100%;
  height: auto;
  display: block;
  mix-blend-mode: difference;
}

/* ============================================================
   3. MARQUEE
   ============================================================ */
.marquee-section {
  background: var(--color-dark);
  padding: 40px 0 80px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.marquee-track {
  display: flex;
  gap: 64px;
  width: max-content;
  animation: marquee 75s linear infinite;
}

.marquee-track--reverse {
  animation-name: marquee-reverse;
  animation-duration: 70s;
}

.marquee-track:hover { animation-play-state: paused; }

@keyframes marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

@keyframes marquee-reverse {
  from { transform: translateX(-50%); }
  to   { transform: translateX(0); }
}

.marquee-item {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.marquee-item img {
  height: 28px;
  width: auto;
  max-width: 150px;
  object-fit: contain;
  opacity: 0.7;
  filter: brightness(0) invert(1);
  transition: opacity 0.2s ease;
}

.marquee-item img:hover { opacity: 1; }

/* ============================================================
   4. ABOUT
   ============================================================ */
.about-section {
  background: var(--color-dark);
  padding: 100px 0;
}

.about-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--padding-x);
  padding-top: 80px;
}

.about-label {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-text-muted);
  margin-bottom: 40px;
}

.about-heading {
  font-size: 48px;
  font-weight: 400;
  line-height: 1.13;
  letter-spacing: -2.88px;
  max-width: 880px;
  color: var(--color-text-light);
}

.about-heading em {
  font-style: normal;
  font-weight: 300;
}

/* ============================================================
   5. PRODUCTS
   ============================================================ */
.products-section {
  background: var(--color-light);
  color: var(--color-text-dark);
  padding: 100px 0 0;
}

.products-intro {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--padding-x) 80px;
}

.products-intro-text {
  font-size: 48px;
  font-weight: 400;
  line-height: 1.13;
  letter-spacing: -2.88px;
  max-width: 820px;
  color: var(--color-text-dark);
}

/* Product block */
.product-block {
  border-top: 0.5px solid rgba(29, 29, 29, 0.15);
}

.product-block-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 64px var(--padding-x);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: start;
}

.product-left { position: sticky; top: 100px; }

.product-name {
  font-size: 80px;
  font-weight: 400;
  line-height: 1.21;
  letter-spacing: -7.2px;
  color: var(--color-text-dark);
  margin-bottom: 20px;
}

.product-name-wrap {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  flex-wrap: wrap;
}

.product-name-wrap .product-name {
  margin-bottom: 0;
}

.badge-new {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 100px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: transparent;
  border: 1px solid var(--color-dark);
  color: var(--color-dark);
  margin-top: 14px;
  flex-shrink: 0;
}

.product-desc {
  font-size: 15px;
  font-weight: 400;
  line-height: 1.18;
  color: #666;
  margin-bottom: 20px;
  max-width: 380px;
}

.product-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

/* Pills — products context (dark border) */
.products-section .pill {
  display: inline-flex;
  align-items: center;
  padding: 0 8px;
  border: 0.5px solid var(--color-text-dark);
  border-radius: 4px;
  font-size: 10px;
  font-weight: 400;
  color: var(--color-text-dark);
  height: 17px;
  background: transparent;
}

/* Generic pill (used in carousel) */
.pill {
  display: inline-flex;
  align-items: center;
  padding: 0 8px;
  border: 0.5px solid currentColor;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 400;
  height: 17px;
}

/* Accordion feature list */
.feature-list {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.accordion-item {
  border-radius: 7px;
  overflow: hidden;
  background: var(--color-feature-row);
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.4s ease, transform 0.4s ease;
}
.accordion-item.visible {
  opacity: 1;
  transform: translateY(0);
}

.accordion-header {
  width: 100%;
  min-height: 32px;
  background: transparent;
  border: none;
  border-radius: 7px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 12px;
  font-size: 12px;
  font-weight: 400;
  line-height: 1.21;
  color: var(--color-text-dark);
  cursor: pointer;
  text-align: left;
  gap: 8px;
}

.accordion-icon {
  font-size: 20px;
  line-height: 1;
  flex-shrink: 0;
}

.accordion-body {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
  padding: 0 12px;
}

.accordion-item.open .accordion-body {
  max-height: 300px;
  padding: 8px 12px 12px;
}

.accordion-body p {
  font-size: 12px;
  font-weight: 400;
  line-height: 1.5;
  color: var(--color-text-dark);
  opacity: 0.75;
}

/* ============================================================
   6. CASE STUDIES CAROUSEL
   ============================================================ */
.carousel-section {
  background: var(--color-dark);
  padding: 100px 0;
  overflow: hidden;
}

.carousel-header {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--padding-x) 60px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 32px;
}

.carousel-title {
  font-size: 48px;
  font-weight: 400;
  line-height: 1.13;
  letter-spacing: -2.88px;
  max-width: 560px;
  color: var(--color-text-light);
}

.carousel-title em {
  font-style: normal;
}

.carousel-nav {
  display: flex;
  gap: 12px;
  flex-shrink: 0;
}

.carousel-btn {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 1px solid rgba(244, 244, 244, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text-light);
  font-size: 18px;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.carousel-btn:hover {
  background: rgba(244, 244, 244, 0.1);
  border-color: rgba(244, 244, 244, 0.6);
}

.carousel-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.carousel-track-wrap {
  padding-left: var(--padding-x);
  position: relative;
}

.carousel-track {
  display: flex;
  gap: 16px;
  transition: transform 0.45s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  will-change: transform;
  cursor: grab;
  user-select: none;
  touch-action: pan-y;
}

.carousel-track.dragging { cursor: grabbing; transition: none; }

/* Card — Figma: 399px wide, 598px total, image 479px */
.client-card {
  flex-shrink: 0;
  width: 399px;
  border-radius: 10px;
  overflow: hidden;
  background: #111;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}

.client-card-image-wrap {
  position: relative;
  width: 100%;
  height: 479px;
  flex-shrink: 0;
  overflow: hidden;
}

.client-card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.client-card:hover .client-card-img { transform: scale(1.04); }

.client-card-info {
  padding: 16px 20px 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
  background: #111;
}

.client-card-name {
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0.4px;
  color: rgba(244, 244, 244, 0.45);
  line-height: 1.2;
  text-transform: uppercase;
}

.client-card-tagline {
  font-size: 20px;
  font-weight: 400;
  letter-spacing: -0.4px;
  color: var(--color-text-light);
  line-height: 1.2;
}

.client-card-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.client-card-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.client-card-pills .pill {
  border: 0.5px solid rgba(244, 244, 244, 0.5);
  color: var(--color-text-light);
  background: rgba(0, 0, 0, 0.24);
  font-size: 12px;
  letter-spacing: -0.24px;
  height: 19px;
  border-radius: 4px;
  padding: 0 8px;
}


/* ============================================================
   7. FOOTER
   ============================================================ */
.site-footer {
  background: var(--color-footer);
  color: var(--color-text-light);
  padding: 80px 0 0;
  border-top: 0.5px solid rgba(244, 244, 244, 0.2);
  position: relative;
  overflow: hidden;
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--padding-x);
}

/* Footer CTA top */
.footer-cta-section {
  padding-bottom: 60px;
}

.footer-cta-heading {
  font-size: 24px;
  font-weight: 400;
  line-height: 1.25;
  letter-spacing: -0.48px;
  margin-bottom: 32px;
  max-width: 800px;
  color: var(--color-text-light);
}

.footer-cta-heading em {
  font-style: normal;
  font-weight: 300;
}

/* Footer columns */
.footer-columns-section {
  padding: 60px 0 20px;
  display: grid;
  grid-template-columns: auto repeat(4, 1fr);
  gap: 40px;
  align-items: start;
}

.footer-badge img {
  height: 52px;
  width: auto;
}

.footer-col-group {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.footer-col-title {
  font-size: 20px;
  font-weight: 400;
  letter-spacing: -0.4px;
  color: var(--color-text-light);
}

.footer-col-links {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.footer-col-links a {
  font-size: 12px;
  font-weight: 400;
  color: var(--color-text-muted);
  transition: color 0.2s ease;
  line-height: 1.4;
}

.footer-col-links a:hover { color: var(--color-text-light); }

.footer-col-text {
  font-size: 12px;
  font-weight: 400;
  color: var(--color-text-muted);
  line-height: 1.6;
}

/* Footer bottom */
.footer-bottom {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 12px var(--padding-x);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.footer-copy {
  font-size: 12px;
  font-weight: 400;
  color: var(--color-text-muted);
}

.footer-logo-bg {
  display: block;
  width: 100%;
  padding: 0;
  margin-top: 20px;
  pointer-events: none;
}

/* ============================================================
   RESPONSIVE — Tablet (768–1023px)
   ============================================================ */
@media (max-width: 1023px) {

  :root { --padding-x: 24px; }

  .header-tagline { font-size: 14px; max-width: 380px; }
  .header-tagline br { display: none; }

  .about-heading { font-size: 36px; letter-spacing: -1.8px; }

  .products-intro-text { font-size: 36px; letter-spacing: -1.8px; }

  .product-name { font-size: 60px; letter-spacing: -4px; }

  .product-block-inner {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .product-left { position: static; }

  .footer-cta-section { padding-bottom: 48px; }

  .footer-columns-section {
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
  }

  .footer-badge { grid-column: 1 / -1; }

  .carousel-header { flex-direction: column; align-items: flex-start; }

  .client-card { width: 340px; }
  .client-card-image-wrap { height: 480px; }
}

/* ============================================================
   RESPONSIVE — Mobile (< 768px)
   ============================================================ */
@media (max-width: 767px) {

  :root { --padding-x: 20px; }

  /* Header */
  .header-inner {
    padding: 20px var(--padding-x) 0;
    grid-template-columns: auto 1fr;
    gap: 0;
  }
  .header-tagline { display: none; }
  .header-logo { width: 120px; }
  .header-tagline-mobile {
    display: block;
  }
  .header-right { justify-self: end; }
  .btn-cta { padding: 8px 14px; font-size: 11px; height: 32px; min-width: auto; }
  .lang-select { width: 32px; height: 32px; font-size: 10px; }

  /* Hero */
  .hero { height: 100svh; min-height: 560px; }
  .hero-logo-wrap { bottom: 16px; left: 0; right: 0; }

  /* Marquee */
  .marquee-item img { height: 20px; }
  .marquee-track { gap: 40px; }

  /* About */
  .about-section { padding: 60px 0; }
  .about-inner { padding-top: 48px; }
  .about-heading { font-size: 28px; letter-spacing: -1.2px; }

  /* Products */
  .products-section { padding: 60px 0 0; }
  .products-intro { padding-bottom: 48px; }
  .products-intro-text { font-size: 28px; letter-spacing: -1.2px; }

  .product-name { font-size: 48px; letter-spacing: -3px; }

  .product-block-inner {
    grid-template-columns: 1fr;
    padding: 40px var(--padding-x);
    gap: 32px;
  }

  .product-left { position: static; }

  /* Carousel */
  .carousel-section { padding: 60px 0; }
  .carousel-title { font-size: 28px; letter-spacing: -1.2px; }
  .carousel-header { flex-direction: column; align-items: flex-start; }

  .client-card { width: 85vw; }
  .client-card-image-wrap { height: 468px; }

  /* Footer */
  .site-footer { padding: 60px 0 0; }

  .footer-cta-section { padding-bottom: 40px; }

  .footer-columns-section {
    grid-template-columns: 1fr 1fr;
    gap: 28px;
  }

  .footer-badge { grid-column: 1 / -1; }

  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }
}

/* ── Scroll-reveal animation ── */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.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; }
.reveal-delay-4 { transition-delay: 0.4s; }
