/* ==========================================================================
   L'Artisan Logiciel — Style
   Ambiance : atelier numérique, flat design, coloré, contemporain
   ========================================================================== */

/* --- TOKENS --- */
:root {
  /* Palette "atelier numérique" */
  --copper:       #C47B3B;
  --copper-light: #D9983D;
  --copper-glow:  rgba(196, 123, 59, 0.15);
  --amber:        #F5A623;
  --amber-light:  #FFC857;
  --teal:         #2A9D8F;
  --teal-dark:    #1E7A6E;
  --teal-light:   #7ECEC3;
  --navy:         #1D2B3A;
  --navy-light:   #2C3E50;
  --slate:        #3D4F5F;
  --cream:        #FAF7F2;
  --warm-white:   #FFF9F0;
  --warm-gray:    #E8E0D6;
  --grid-line:    rgba(196, 123, 59, 0.08);
  --text:         #1D2B3A;
  --text-muted:   #5A6978;
  --text-light:   #8A9AAA;
  --white:        #FFFFFF;
  --shadow-sm:    0 2px 8px rgba(29, 43, 58, 0.08);
  --shadow-md:    0 4px 20px rgba(29, 43, 58, 0.12);
  --shadow-lg:    0 8px 40px rgba(29, 43, 58, 0.16);
  --radius:       12px;
  --radius-sm:    8px;
  --radius-lg:    20px;
  --transition:   0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--text);
  background: var(--cream);
  line-height: 1.7;
  overflow-x: hidden;
}

/* Blueprint grid background — subtil, partout */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
  z-index: 0;
}

body > * { position: relative; z-index: 1; }

.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

h1, h2, h3 {
  font-family: 'Merriweather', Georgia, serif;
  color: var(--navy);
  line-height: 1.3;
}

a { color: var(--teal-dark); text-decoration: none; }
img { max-width: 100%; display: block; }

/* --- BUTTONS --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: var(--radius-sm);
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all var(--transition);
  border: 2px solid transparent;
  text-decoration: none;
}

.btn svg {
  flex-shrink: 0;
}

.btn--primary {
  background: var(--copper);
  color: var(--white);
  border-color: var(--copper);
}
.btn--primary:hover {
  background: var(--copper-light);
  border-color: var(--copper-light);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(196, 123, 59, 0.35);
}

.btn--secondary {
  background: var(--teal);
  color: var(--white);
  border-color: var(--teal);
}
.btn--secondary:hover {
  background: var(--teal-dark);
  border-color: var(--teal-dark);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(42, 157, 143, 0.35);
}

.btn--ghost {
  background: transparent;
  color: var(--navy);
  border-color: var(--navy);
}
.btn--ghost:hover {
  background: var(--navy);
  color: var(--white);
  transform: translateY(-2px);
}

.btn--outline-light {
  background: transparent;
  color: var(--warm-white);
  border-color: rgba(255, 255, 255, 0.4);
}
.btn--outline-light:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--warm-white);
  color: var(--white);
  transform: translateY(-2px);
}

.btn--small {
  padding: 10px 20px;
  font-size: 0.85rem;
}

.btn--large {
  padding: 18px 36px;
  font-size: 1.05rem;
}

/* --- NAVIGATION --- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(250, 247, 242, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--warm-gray);
  transition: all var(--transition);
}

.nav--scrolled {
  box-shadow: var(--shadow-sm);
}

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.nav__logo {
  display: flex;
  align-items: baseline;
  gap: 6px;
  text-decoration: none;
}

.nav__logo-artisan {
  font-family: 'Merriweather', serif;
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--navy);
}

.nav__logo-logiciel {
  font-family: 'Inter', sans-serif;
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--copper);
  letter-spacing: 0.02em;
}

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

.nav__links a {
  font-weight: 500;
  font-size: 0.9rem;
  color: var(--slate);
  transition: color var(--transition);
  position: relative;
}

.nav__links a:not(.btn)::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--copper);
  transition: width var(--transition);
}

.nav__links a:not(.btn):hover { color: var(--navy); }
.nav__links a:not(.btn):hover::after { width: 100%; }

.nav__toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.nav__toggle span {
  width: 24px;
  height: 2px;
  background: var(--navy);
  transition: all var(--transition);
}

/* --- HERO --- */
.hero {
  padding: 160px 0 100px;
  background:
    radial-gradient(ellipse at 80% 20%, var(--copper-glow) 0%, transparent 60%),
    radial-gradient(ellipse at 20% 80%, rgba(42, 157, 143, 0.08) 0%, transparent 50%),
    var(--cream);
  position: relative;
  overflow: hidden;
}

/* Decorative workshop elements */
.hero::before {
  content: '';
  position: absolute;
  top: 80px;
  right: -40px;
  width: 400px;
  height: 400px;
  border: 3px solid var(--copper-glow);
  border-radius: 50%;
  opacity: 0.6;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -60px;
  right: 120px;
  width: 200px;
  height: 200px;
  background: var(--copper-glow);
  transform: rotate(45deg);
  border-radius: var(--radius);
}

.hero__inner { max-width: 720px; }

.hero__title {
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  margin-bottom: 24px;
  letter-spacing: -0.02em;
}

.hero__accent {
  color: var(--copper);
  position: relative;
}

.hero__accent::after {
  content: '';
  position: absolute;
  bottom: 4px;
  left: 0;
  right: 0;
  height: 12px;
  background: var(--amber-light);
  opacity: 0.3;
  z-index: -1;
  border-radius: 2px;
}

.hero__subtitle {
  font-size: 1.15rem;
  color: var(--text-muted);
  margin-bottom: 36px;
  max-width: 600px;
}

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

.hero__trust {
  font-size: 0.85rem;
  color: var(--text-light);
  display: flex;
  align-items: center;
  gap: 8px;
}

.hero__trust::before {
  content: '📍';
}

/* --- SECTIONS --- */
.section {
  padding: 100px 0;
}

.section__title {
  font-size: clamp(1.8rem, 3.5vw, 2.4rem);
  text-align: center;
  margin-bottom: 12px;
}

.section__subtitle {
  text-align: center;
  color: var(--text-muted);
  font-size: 1.05rem;
  margin-bottom: 56px;
}

/* --- PROBLEM SECTION --- */
.problem {
  background: var(--navy);
  position: relative;
}

.problem::before {
  content: '';
  position: absolute;
  inset: 0;
  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: 40px 40px;
  pointer-events: none;
}

.problem .section__title {
  color: var(--warm-white);
}

.problem__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 24px;
}

.problem__card {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius);
  padding: 32px 28px;
  transition: all var(--transition);
}

.problem__card:hover {
  background: rgba(255, 255, 255, 0.1);
  transform: translateY(-4px);
}

.problem__icon {
  margin-bottom: 16px;
  color: var(--copper-light);
}

.problem__icon svg {
  width: 36px;
  height: 36px;
}

.problem__card p {
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* --- SERVICES --- */
.services {
  background: var(--warm-white);
}

.services__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
}

.service__card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 36px 32px;
  border: 1px solid var(--warm-gray);
  transition: all var(--transition);
  position: relative;
  overflow: hidden;
}

/* Decorative corner — comme un onglet d'atelier */
.service__card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 0;
  background: var(--copper);
  transition: height var(--transition);
  border-radius: 0 0 2px 0;
}

.service__card:hover {
  border-color: var(--copper-glow);
  box-shadow: var(--shadow-md);
  transform: translateY(-4px);
}

.service__card:hover::before {
  height: 100%;
}

.service__icon {
  width: 56px;
  height: 56px;
  background: var(--copper-glow);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  color: var(--copper);
}

.service__icon svg {
  width: 28px;
  height: 28px;
}

.service__card h3 {
  font-size: 1.15rem;
  margin-bottom: 12px;
}

.service__card p {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 16px;
}

.service__meta {
  font-family: 'Inter', sans-serif;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--teal);
  background: rgba(42, 157, 143, 0.08);
  padding: 6px 12px;
  border-radius: 20px;
  display: inline-block;
}

/* --- METHOD --- */
.method {
  background: var(--cream);
  position: relative;
}

.method__steps {
  display: flex;
  align-items: flex-start;
  gap: 0;
  max-width: 900px;
  margin: 0 auto;
}

.method__step {
  flex: 1;
  text-align: center;
  padding: 0 20px;
  position: relative;
}

.method__number {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--copper);
  color: var(--white);
  font-family: 'Merriweather', serif;
  font-weight: 700;
  font-size: 1.3rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
  position: relative;
  z-index: 2;
  box-shadow: 0 4px 12px rgba(196, 123, 59, 0.3);
}

.method__connector {
  flex: 0 0 auto;
  width: 40px;
  height: 2px;
  background: var(--warm-gray);
  margin-top: 28px;
  position: relative;
}

.method__connector::after {
  content: '';
  position: absolute;
  right: -3px;
  top: -3px;
  width: 8px;
  height: 8px;
  border: 2px solid var(--warm-gray);
  border-left: 0;
  border-bottom: 0;
  transform: rotate(45deg);
}

.method__step h3 {
  font-size: 1rem;
  margin-bottom: 8px;
  color: var(--navy);
}

.method__step p {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* --- WHY US --- */
.why {
  background: var(--warm-white);
}

.why__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
}

.why__card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 32px 28px;
  border: 1px solid var(--warm-gray);
  transition: all var(--transition);
  position: relative;
}

.why__card::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 20px;
  right: 20px;
  height: 3px;
  background: linear-gradient(90deg, var(--copper), var(--amber));
  border-radius: 3px 3px 0 0;
  transform: scaleX(0);
  transition: transform var(--transition);
}

.why__card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-4px);
}

.why__card:hover::after {
  transform: scaleX(1);
}

.why__card h3 {
  font-size: 1.05rem;
  margin-bottom: 10px;
  color: var(--navy);
}

.why__card p {
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* --- ABOUT / QUI SUIS-JE --- */
.about {
  background: var(--warm-white);
}

.about__inner {
  display: flex;
  align-items: center;
  gap: 56px;
  max-width: 800px;
  margin: 0 auto;
}

.about__photo {
  flex-shrink: 0;
}

.about__photo-placeholder {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  background: var(--warm-gray);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 500;
  border: 4px solid var(--copper-glow);
}

.about__photo img {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid var(--copper-glow);
}

.about__title {
  font-size: 1.6rem;
  margin-bottom: 4px;
  text-align: left;
}

.about__role {
  font-size: 0.9rem;
  color: var(--copper);
  font-weight: 600;
  margin-bottom: 20px;
}

.about__text p {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 14px;
  line-height: 1.7;
}

.about__cta {
  margin-top: 8px;
  font-weight: 600;
  color: var(--text) !important;
}

.about__cta a {
  color: var(--copper);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.about__cta a:hover {
  color: var(--copper-light);
}

/* --- REFERENCE --- */
.reference {
  background: var(--white);
}

.reference__inner {
  display: flex;
  align-items: center;
  gap: 48px;
  max-width: 800px;
  margin: 0 auto;
  padding: 32px;
  background: var(--cream);
  border-radius: var(--radius-lg);
  border: 1px solid var(--warm-gray);
}

.reference__logo {
  flex-shrink: 0;
  transition: var(--transition);
}

.reference__logo:hover {
  opacity: 0.8;
}

.reference__logo img {
  height: 60px;
  width: auto;
}

.reference__text {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.7;
}

.reference__text strong {
  color: var(--text);
}

@media (max-width: 768px) {
  .reference__inner {
    flex-direction: column;
    text-align: center;
    gap: 24px;
  }
}

/* --- SECTORS --- */
.sectors {
  background: var(--cream);
}

.sectors__tags {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}

.sector__tag {
  background: var(--white);
  border: 1px solid var(--warm-gray);
  padding: 10px 22px;
  border-radius: 40px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--slate);
  transition: all var(--transition);
}

.sector__tag:hover {
  background: var(--navy);
  color: var(--white);
  border-color: var(--navy);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

/* --- CTA --- */
.cta {
  background:
    radial-gradient(ellipse at 30% 50%, var(--copper-glow) 0%, transparent 50%),
    radial-gradient(ellipse at 70% 50%, rgba(42, 157, 143, 0.08) 0%, transparent 50%),
    var(--navy);
  padding: 100px 0;
  position: relative;
  overflow: hidden;
}

.cta::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.02) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
}

.cta__inner {
  text-align: center;
  max-width: 600px;
}

.cta__title {
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  color: var(--warm-white);
  margin-bottom: 16px;
}

.cta__text {
  color: rgba(255, 255, 255, 0.75);
  font-size: 1.05rem;
  margin-bottom: 40px;
}

.cta__methods {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

.cta__zone {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.45);
}

/* --- FOOTER --- */
.footer {
  background: var(--navy-light);
  padding: 48px 0 32px;
  border-top: 3px solid var(--copper);
}

.footer__inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 32px;
}

.footer__brand .nav__logo-artisan,
.footer__brand .nav__logo-logiciel {
  color: var(--warm-white);
}

.footer__brand .nav__logo-logiciel {
  color: var(--copper-light);
}

.footer__tagline {
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.85rem;
  margin-top: 8px;
}

.footer__links {
  display: flex;
  gap: 24px;
}

.footer__links a {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.9rem;
  transition: color var(--transition);
}

.footer__links a:hover {
  color: var(--warm-white);
}

.footer__legal {
  text-align: right;
}

.footer__legal p {
  color: rgba(255, 255, 255, 0.35);
  font-size: 0.8rem;
  line-height: 1.6;
}

/* --- ANIMATIONS ON SCROLL --- */
.fade-up {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

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

/* --- RESPONSIVE --- */
@media (max-width: 768px) {
  .nav__links {
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    background: rgba(250, 247, 242, 0.98);
    backdrop-filter: blur(12px);
    flex-direction: column;
    padding: 24px;
    gap: 16px;
    transform: translateY(-120%);
    transition: transform var(--transition);
    border-bottom: 1px solid var(--warm-gray);
  }

  .nav__links.open {
    transform: translateY(0);
  }

  .nav__toggle {
    display: flex;
  }

  .nav__toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }
  .nav__toggle.active span:nth-child(2) {
    opacity: 0;
  }
  .nav__toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
  }

  .hero { padding: 130px 0 80px; }
  .hero__actions { flex-direction: column; }
  .hero__actions .btn { text-align: center; justify-content: center; }

  .section { padding: 72px 0; }

  .about__inner {
    flex-direction: column;
    text-align: center;
    gap: 32px;
  }

  .about__title {
    text-align: center;
  }

  .about__photo-placeholder {
    width: 160px;
    height: 160px;
  }

  .method__steps {
    flex-direction: column;
    align-items: center;
  }

  .method__connector {
    width: 2px;
    height: 32px;
    margin: 0;
  }

  .method__connector::after {
    right: -3px;
    top: auto;
    bottom: -3px;
    transform: rotate(135deg);
  }

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

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

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

  .footer__links {
    justify-content: center;
  }

  .footer__legal {
    text-align: center;
  }

  .cta__methods {
    flex-direction: column;
    align-items: center;
  }
}

@media (max-width: 480px) {
  .hero__title { font-size: 2rem; }
  .problem__grid { grid-template-columns: 1fr; }
}
