/* ============================================
   ATOMIC — Design System
   Inspiré de atomicdigital.design
   Palette: Noir pur + Blanc + Orange vif
   Typo: Space Grotesk + Inter
============================================ */

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

:root {
  --black:       #080808;
  --off-black:   #0f0f0f;
  --dark:        #151515;
  --card:        #111111;
  --white:       #ffffff;
  --off-white:   #f0f0f0;
  --muted:       rgba(255,255,255,0.42);
  --muted-light: rgba(255,255,255,0.65);
  --border:      rgba(255,255,255,0.07);
  --border-m:    rgba(255,255,255,0.11);
  --accent:      #FF4D00;
  --accent-h:    #e64300;

  --f-display: 'Space Grotesk', sans-serif;
  --f-body:    'Inter', sans-serif;

  --w: 1160px;
  --nav-h: 68px;
  --ease: cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }
body { background: var(--black); color: var(--white); font-family: var(--f-body); line-height: 1.6; overflow-x: hidden; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
img { display: block; max-width: 100%; }

/* Container */
.container { width: 100%; max-width: var(--w); margin: 0 auto; padding: 0 40px; }

/* Labels */
.section-label {
  font-size: 11px; font-weight: 600; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--muted); margin-bottom: 18px;
}

/* Titles */
.section-title {
  font-family: var(--f-display);
  font-size: clamp(2.2rem, 5vw, 3.8rem);
  font-weight: 700; line-height: 1.05; letter-spacing: -0.03em;
  margin-bottom: 56px;
}

/* Buttons */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--f-body); font-size: 13px; font-weight: 500;
  letter-spacing: 0.01em; padding: 13px 24px; border-radius: 100px;
  border: 1.5px solid transparent; cursor: pointer; white-space: nowrap;
  transition: all 0.22s var(--ease);
}
.btn:hover { transform: translateY(-1px); }
.btn--primary { background: var(--white); color: var(--black); border-color: var(--white); }
.btn--primary:hover { background: var(--off-white); }
.btn--outline { background: transparent; color: var(--white); border-color: var(--border-m); }
.btn--outline:hover { border-color: rgba(255,255,255,0.4); background: rgba(255,255,255,0.04); }
.btn--ghost { background: transparent; color: var(--muted-light); border-color: transparent; padding-left: 0; }
.btn--ghost:hover { color: var(--white); }

/* ============================================
   PRELOADER
============================================ */
.preloader {
  position: fixed; inset: 0; z-index: 9999;
  background: var(--black);
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: 24px;
  transition: opacity 0.6s var(--ease), visibility 0.6s var(--ease);
}
.preloader.hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.preloader__text {
  font-family: var(--f-display); font-size: clamp(2.5rem, 6vw, 5rem);
  font-weight: 700; letter-spacing: -0.04em; color: var(--white);
}
.preloader__bar {
  width: 200px; height: 1px;
  background: var(--border-m); position: relative; overflow: hidden;
}
.preloader__bar::after {
  content: ''; position: absolute; left: -100%; top: 0;
  width: 100%; height: 100%; background: var(--white);
  animation: barSlide 1.2s var(--ease) forwards;
}
@keyframes barSlide { to { left: 0; } }

/* ============================================
   NAVIGATION
============================================ */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  height: var(--nav-h);
  border-bottom: 1px solid transparent;
  transition: background 0.4s, backdrop-filter 0.4s, border-color 0.4s;
}
.nav.scrolled {
  background: rgba(8,8,8,0.9);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  border-color: var(--border);
}
.nav__inner {
  display: flex; align-items: center; justify-content: space-between;
  height: var(--nav-h); max-width: var(--w); margin: 0 auto; padding: 0 40px;
}
.nav__logo {
  font-family: var(--f-display); font-size: 20px; font-weight: 700;
  letter-spacing: -0.04em; color: var(--white); transition: opacity 0.2s;
}
.nav__logo:hover { opacity: 0.7; }
.nav__links { display: flex; align-items: center; gap: 36px; }
.nav__links a {
  font-size: 13px; font-weight: 400; color: var(--muted);
  transition: color 0.2s; letter-spacing: 0.01em;
}
.nav__links a:hover { color: var(--white); }
.nav__cta {
  color: var(--white) !important;
  padding-bottom: 1px;
  border-bottom: 1px solid rgba(255,255,255,0.3);
}

.nav__burger {
  display: none; flex-direction: column; justify-content: center; gap: 5px;
  background: none; border: none; cursor: pointer; padding: 4px;
  width: 32px; height: 32px;
}
.nav__burger span {
  display: block; width: 20px; height: 1px; background: var(--white);
  transition: transform 0.25s var(--ease), opacity 0.2s;
  transform-origin: center;
}
.nav__burger.open span:first-child { transform: translateY(3px) rotate(45deg); }
.nav__burger.open span:last-child  { transform: translateY(-3px) rotate(-45deg); }

.nav__mobile {
  display: none; flex-direction: column; padding: 16px 40px 28px;
  background: rgba(8,8,8,0.96); backdrop-filter: blur(20px);
  border-top: 1px solid var(--border);
  opacity: 0; transform: translateY(-8px); pointer-events: none;
  transition: opacity 0.25s var(--ease), transform 0.25s var(--ease);
}
.nav__mobile.open { opacity: 1; transform: translateY(0); pointer-events: all; }
.nav__mobile-link {
  font-size: 15px; color: var(--muted); padding: 14px 0;
  border-bottom: 1px solid var(--border); transition: color 0.2s;
}
.nav__mobile-link:hover { color: var(--white); }
.nav__mobile-cta { color: var(--white) !important; border-bottom: none; margin-top: 8px; }

/* ============================================
   HERO
============================================ */
.hero {
  position: relative; min-height: 100svh;
  display: flex; align-items: center;
  padding-top: var(--nav-h); overflow: hidden;
}

/* Grid background */
.hero__bg-grid {
  position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
  background-size: 80px 80px;
  mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 40%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 40%, transparent 100%);
}

/* Orange glow */
.hero::before {
  content: '';
  position: absolute; top: -10%; right: -5%; width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(255,77,0,0.10) 0%, transparent 70%);
  pointer-events: none;
}

.hero > .container {
  position: relative; z-index: 1;
  padding-top: 80px; padding-bottom: 120px;
}

.hero__eyebrow {
  font-size: 11px; font-weight: 500; letter-spacing: 0.15em;
  text-transform: uppercase; color: var(--muted); margin-bottom: 36px;
}

.hero__title {
  font-family: var(--f-display);
  font-size: clamp(3.5rem, 8.5vw, 7rem);
  font-weight: 700; line-height: 0.98;
  letter-spacing: -0.04em; margin-bottom: 32px;
}
.hero__title em { font-style: normal; color: transparent;
  -webkit-text-stroke: 1px rgba(255,255,255,0.4); }

.hero__sub {
  font-size: clamp(0.95rem, 1.5vw, 1.1rem); font-weight: 300;
  color: var(--muted-light); max-width: 520px;
  margin-bottom: 48px; line-height: 1.75;
}

.hero__actions { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }

.hero__scroll-cue {
  position: absolute; bottom: 40px; left: 50%;
  transform: translateX(-50%); display: flex;
  flex-direction: column; align-items: center;
}
.hero__scroll-line {
  width: 1px; height: 56px;
  background: linear-gradient(to bottom, rgba(255,255,255,0.35), transparent);
  animation: scrollPulse 2s ease-in-out infinite;
}
@keyframes scrollPulse {
  0%,100% { opacity: 0.35; transform: scaleY(0.8); transform-origin: top; }
  50%     { opacity: 0.9; transform: scaleY(1); }
}

/* ============================================
   TICKER — logo défilant
============================================ */
.ticker {
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  overflow: hidden; padding: 24px 0;
}
.ticker__inner { position: relative; overflow: hidden; }
.ticker__track {
  display: flex; align-items: center; gap: 64px;
  animation: tickerMove 30s linear infinite;
  width: max-content;
}
.ticker__track:hover { animation-play-state: paused; }
.ticker__item {
  flex-shrink: 0; display: flex; align-items: center;
  opacity: 0.35; transition: opacity 0.2s;
  filter: brightness(0) invert(1);
}
.ticker__item:hover { opacity: 0.7; }
.ticker__item img { height: 22px; width: auto; max-width: 100px; object-fit: contain; }

@keyframes tickerMove {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* ============================================
   PORTFOLIO
============================================ */
.portfolio { padding: 120px 0; border-top: 1px solid var(--border); }
.portfolio__header { margin-bottom: 56px; }

.portfolio__grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  grid-template-rows: auto auto;
  gap: 2px;
}

.portfolio__item { grid-column: span 6; }
.portfolio__item--large { grid-column: span 6; grid-row: span 2; }
.portfolio__item--wide { grid-column: span 12; }

.portfolio__link { display: block; }

.portfolio__img-wrap {
  position: relative; overflow: hidden;
  background: var(--card);
  aspect-ratio: 16/10;
}
.portfolio__item--large .portfolio__img-wrap { aspect-ratio: unset; height: 100%; min-height: 480px; }
.portfolio__item--wide .portfolio__img-wrap { aspect-ratio: 21/8; }

.portfolio__img-wrap img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.7s var(--ease), filter 0.4s;
  filter: brightness(0.85);
}
.portfolio__link:hover .portfolio__img-wrap img {
  transform: scale(1.04); filter: brightness(1);
}

.portfolio__overlay {
  position: absolute; inset: 0;
  display: flex; align-items: flex-end; justify-content: flex-end;
  padding: 20px;
  opacity: 0; transition: opacity 0.3s;
}
.portfolio__link:hover .portfolio__overlay { opacity: 1; }

.portfolio__arrow {
  width: 44px; height: 44px; border-radius: 50%;
  background: var(--white); color: var(--black);
  display: flex; align-items: center; justify-content: center;
  transform: translateY(8px) rotate(-45deg);
  transition: transform 0.3s var(--ease);
}
.portfolio__link:hover .portfolio__arrow { transform: translateY(0) rotate(0deg); }

.portfolio__meta {
  padding: 16px 0 24px;
  border-bottom: 1px solid var(--border);
}
.portfolio__tag {
  font-size: 10px; font-weight: 600; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--muted);
  display: block; margin-bottom: 8px;
}
.portfolio__title {
  font-family: var(--f-display); font-size: 1.2rem;
  font-weight: 600; letter-spacing: -0.02em; margin-bottom: 4px;
}
.portfolio__desc { font-size: 13px; color: var(--muted); }

.portfolio__more { margin-top: 48px; }

/* ============================================
   PAIN POINTS
============================================ */
.pain {
  padding: 100px 0;
  border-top: 1px solid var(--border);
}
.pain__headline {
  font-family: var(--f-display);
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  font-weight: 600; letter-spacing: -0.025em; line-height: 1.12;
  max-width: 680px; margin-bottom: 16px;
}
.pain__sub {
  font-size: 15px; color: var(--muted); max-width: 500px;
  margin-bottom: 72px; line-height: 1.75;
}
.pain__grid {
  display: grid; grid-template-columns: repeat(3,1fr);
  gap: 1px; background: var(--border);
  border: 1px solid var(--border);
}
.pain__card {
  background: var(--black); padding: 40px 36px;
  transition: background 0.25s var(--ease);
}
.pain__card:hover { background: var(--card); }
.pain__num {
  font-size: 10px; font-weight: 700; letter-spacing: 0.12em;
  color: var(--accent); margin-bottom: 20px;
}
.pain__card h3 {
  font-family: var(--f-display); font-size: 1.15rem;
  font-weight: 600; letter-spacing: -0.01em; margin-bottom: 12px;
}
.pain__card p { font-size: 13.5px; color: var(--muted); line-height: 1.75; }

/* ============================================
   SERVICES
============================================ */
.services { padding: 120px 0; border-top: 1px solid var(--border); background: var(--off-black); }

.services__layout { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: start; }
.services__intro { font-size: 15px; color: var(--muted); line-height: 1.75; max-width: 320px; }

.services__tabs { display: flex; flex-direction: column; gap: 0; }
.services__tab {
  border-bottom: 1px solid var(--border);
  cursor: pointer; padding: 28px 0;
  transition: padding 0.2s var(--ease);
}
.services__tab:first-child { border-top: 1px solid var(--border); }
.services__tab-head h3 {
  font-family: var(--f-display); font-size: 1.1rem; font-weight: 600;
  letter-spacing: -0.01em; margin-bottom: 6px; color: var(--muted-light);
  transition: color 0.2s;
}
.services__tab-head p { font-size: 13px; color: var(--muted); line-height: 1.6; }
.services__tab.active .services__tab-head h3 { color: var(--white); }
.services__tab:hover .services__tab-head h3 { color: var(--white); }

/* ============================================
   ABOUT
============================================ */
.about {
  padding: 120px 0;
  border-top: 1px solid var(--border);
}
.about__inner { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: start; }
.about__left .section-title { margin-bottom: 32px; }
.about__left p {
  font-size: 15px; color: var(--muted); line-height: 1.8; margin-bottom: 16px;
}
.about__list { margin-top: 36px; display: flex; flex-direction: column; gap: 14px; }
.about__list li {
  font-size: 14px; color: var(--muted-light);
  padding-left: 18px; position: relative; line-height: 1.5;
}
.about__list li::before {
  content: ''; position: absolute; left: 0; top: 7px;
  width: 5px; height: 5px; border-radius: 50%; background: var(--accent);
}
.about__stats {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 1px; background: var(--border); border: 1px solid var(--border);
}
.about__stat {
  background: var(--dark); padding: 36px 32px;
  display: flex; flex-direction: column; gap: 8px;
}
.about__stat-n {
  font-family: var(--f-display); font-size: 3.2rem; font-weight: 700;
  letter-spacing: -0.04em; color: var(--white); line-height: 1;
}
.about__stat-l { font-size: 12px; color: var(--muted); letter-spacing: 0.02em; }

/* ============================================
   PROCESS
============================================ */
.process { padding: 120px 0; border-top: 1px solid var(--border); background: var(--off-black); }
.process .section-title { margin-bottom: 0; }
.process__list { margin-top: 64px; }
.process__item {
  display: grid; grid-template-columns: 100px 1fr; gap: 40px;
  padding: 32px 0; border-bottom: 1px solid var(--border); align-items: start;
  transition: padding-left 0.2s var(--ease), background 0.2s;
}
.process__item:first-child { border-top: 1px solid var(--border); }
.process__item:hover { padding-left: 12px; background: rgba(255,255,255,0.015); }
.process__n {
  font-size: 10px; font-weight: 700; letter-spacing: 0.12em;
  color: var(--accent); padding-top: 4px;
}
.process__content h3 {
  font-family: var(--f-display); font-size: 1.2rem; font-weight: 600;
  letter-spacing: -0.01em; margin-bottom: 10px;
}
.process__content p { font-size: 14px; color: var(--muted); line-height: 1.75; max-width: 480px; }

/* ============================================
   CAREERS
============================================ */
.careers {
  position: relative; padding: 0;
  border-top: 1px solid var(--border);
  overflow: hidden;
}
.careers__images {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 2px; height: 500px;
}
.careers__img { overflow: hidden; }
.careers__img img {
  width: 100%; height: 100%; object-fit: cover;
  filter: brightness(0.55) saturate(0.8);
  transition: filter 0.5s;
}
.careers__img:hover img { filter: brightness(0.75) saturate(1); }

.careers .container { position: relative; z-index: 1; padding-top: 80px; padding-bottom: 80px; }
.careers__title {
  font-family: var(--f-display); font-size: clamp(3rem, 7vw, 6rem);
  font-weight: 700; line-height: 0.96; letter-spacing: -0.04em;
  margin: 16px 0 32px; text-transform: lowercase;
}
.careers__text {
  font-size: 15px; color: var(--muted); max-width: 560px;
  line-height: 1.8; margin-bottom: 12px;
}
.careers__equality {
  font-size: 12px; color: var(--muted); margin-bottom: 36px;
  letter-spacing: 0.04em;
}

/* ============================================
   CTA FINAL
============================================ */
.cta-final {
  padding: 160px 0;
  border-top: 1px solid var(--border);
  position: relative; overflow: hidden;
}
.cta-final::before {
  content: ''; position: absolute;
  bottom: -30%; left: 50%; transform: translateX(-50%);
  width: 900px; height: 500px;
  background: radial-gradient(ellipse, rgba(255,77,0,0.06) 0%, transparent 65%);
  pointer-events: none;
}
.cta-final .section-label { margin-bottom: 16px; }
.cta-final__title {
  font-family: var(--f-display);
  font-size: clamp(3rem, 8vw, 7rem);
  font-weight: 700; line-height: 0.96;
  letter-spacing: -0.04em; margin-bottom: 48px;
}
.cta-final__title em {
  font-style: normal; color: transparent;
  -webkit-text-stroke: 1px rgba(255,255,255,0.35);
}
.cta-final__link {
  display: inline-flex; align-items: center; gap: 14px;
  font-family: var(--f-display); font-size: clamp(1.1rem, 2.5vw, 1.8rem);
  font-weight: 500; letter-spacing: -0.01em; color: var(--white);
  border-bottom: 1px solid rgba(255,255,255,0.2); padding-bottom: 6px;
  transition: color 0.2s, border-color 0.2s, gap 0.2s var(--ease);
}
.cta-final__link:hover { color: var(--off-white); border-color: rgba(255,255,255,0.5); gap: 20px; }

/* ============================================
   FOOTER
============================================ */
.footer {
  padding: 64px 0 40px;
  border-top: 1px solid var(--border);
  background: var(--off-black);
}
.footer__top {
  display: flex; gap: 80px; align-items: flex-start;
  margin-bottom: 64px;
}
.footer__logo {
  font-family: var(--f-display); font-size: 22px; font-weight: 700;
  letter-spacing: -0.04em; flex-shrink: 0;
}
.footer__cols { display: flex; gap: 64px; flex-wrap: wrap; }
.footer__col { display: flex; flex-direction: column; gap: 12px; }
.footer__col-title {
  font-size: 12px; font-weight: 600; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--muted); margin-bottom: 4px;
}
.footer__col a {
  font-size: 13px; color: var(--muted); transition: color 0.2s; line-height: 1.5;
}
.footer__col a:hover { color: var(--white); }
.footer__bottom {
  display: flex; justify-content: space-between; align-items: center;
  padding-top: 24px; border-top: 1px solid var(--border);
  font-size: 12px; color: var(--muted);
}
.footer__bottom a { color: var(--muted); transition: color 0.2s; }
.footer__bottom a:hover { color: var(--white); }

/* ============================================
   REVEAL ANIMATIONS
============================================ */
.reveal {
  opacity: 0; transform: translateY(24px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}
.reveal.visible { opacity: 1; transform: translateY(0); }
.reveal-d1 { transition-delay: 0.1s; }
.reveal-d2 { transition-delay: 0.2s; }
.reveal-d3 { transition-delay: 0.3s; }

/* ============================================
   RESPONSIVE
============================================ */
@media (max-width: 1024px) {
  .portfolio__item--large { grid-column: span 12; }
  .portfolio__item         { grid-column: span 6; }
  .portfolio__item--wide   { grid-column: span 12; }
  .portfolio__item--large .portfolio__img-wrap { height: 420px; }
  .services__layout { grid-template-columns: 1fr; gap: 48px; }
  .about__inner     { grid-template-columns: 1fr; gap: 56px; }
  .pain__grid       { grid-template-columns: 1fr; }
  .footer__top      { flex-direction: column; gap: 48px; }
}

@media (max-width: 768px) {
  :root { --nav-h: 60px; }
  .container { padding: 0 24px; }
  .nav__inner { padding: 0 24px; }
  .nav__links { display: none; }
  .nav__burger { display: flex; }
  .nav__mobile { display: flex; }

  .hero > .container { padding-top: 48px; padding-bottom: 80px; }

  .portfolio__grid { grid-template-columns: 1fr; display: flex; flex-direction: column; }
  .portfolio__item,
  .portfolio__item--large,
  .portfolio__item--wide { width: 100%; }
  .portfolio__item--large .portfolio__img-wrap { height: 280px; }
  .portfolio__item--wide .portfolio__img-wrap { aspect-ratio: 16/10; }

  .careers__images { grid-template-columns: 1fr; height: 320px; }
  .careers__img--2, .careers__img--3 { display: none; }

  .portfolio, .pain, .services, .about, .process, .cta-final { padding: 80px 0; }
  .careers .container { padding-top: 48px; padding-bottom: 60px; }

  .footer__cols { flex-direction: column; gap: 32px; }
  .footer__bottom { flex-direction: column; gap: 8px; text-align: center; }

  .about__stats { grid-template-columns: 1fr 1fr; }
  .about__stat-n { font-size: 2.4rem; }

  .process__item { grid-template-columns: 60px 1fr; gap: 16px; }
}

@media (max-width: 480px) {
  .hero__actions { flex-direction: column; align-items: flex-start; }
  .ticker__item img { height: 18px; }
  .section-title { margin-bottom: 36px; }
}

/* Prevent body scroll when mobile menu open */
body.nav-open { overflow: hidden; }
