/*
Theme Name: TractPart Modern Landing
Theme URI: https://tractparts.io
Author: Codex
Description: Theme WordPress moderne pour tractparts.io, vente et sourcing de pieces de rechange pour engins.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.6
Requires PHP: 8.0
Text Domain: tractpart-modern
*/

:root {
  --bg: #080d12;
  --bg-soft: #101820;
  --panel: #f7f8f4;
  --panel-2: #ffffff;
  --ink: #111827;
  --muted: #667085;
  --line: #d9e0e7;
  --yellow: #ffbf1b;
  --yellow-2: #f59e0b;
  --cyan: #32d5c8;
  --green: #0f8f75;
  --white: #ffffff;
  --shadow: 0 28px 90px rgba(0, 0, 0, 0.26);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--panel);
  font-family: Manrope, Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.55;
}

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

button,
input,
textarea {
  font: inherit;
}

.wrap {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
}

.topbar {
  position: fixed;
  z-index: 50;
  top: 18px;
  right: 0;
  left: 0;
  pointer-events: none;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  padding: 0 16px;
  pointer-events: auto;
  background: rgba(8, 13, 18, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  backdrop-filter: blur(18px);
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.2);
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--white);
  font-weight: 900;
  letter-spacing: 0;
}

.logo-mark {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  color: var(--bg);
  background: var(--yellow);
  border-radius: 8px;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.logo:hover .logo-mark {
  transform: translateY(-2px) rotate(-5deg);
  box-shadow: 0 12px 30px rgba(255, 191, 27, 0.36);
}

.logo span:last-child {
  display: grid;
  line-height: 1.08;
}

.logo small {
  color: rgba(255, 255, 255, 0.58);
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
}

.menu {
  display: flex;
  align-items: center;
  gap: 24px;
  color: rgba(255, 255, 255, 0.76);
  font-size: 0.92rem;
  font-weight: 800;
}

.menu a {
  position: relative;
  padding: 10px 0;
}

.menu a::after {
  position: absolute;
  right: 0;
  bottom: 4px;
  left: 0;
  height: 2px;
  content: "";
  background: var(--cyan);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.24s ease;
}

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

.menu a:hover::after {
  transform: scaleX(1);
  transform-origin: left;
}

.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 18px;
  overflow: hidden;
  border: 0;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 900;
  line-height: 1;
  transition: transform 0.22s ease, box-shadow 0.22s ease, background 0.22s ease;
}

.btn::before {
  position: absolute;
  top: 0;
  bottom: 0;
  left: -90%;
  width: 72%;
  content: "";
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.48), transparent);
  transform: skewX(-18deg);
  transition: left 0.42s ease;
}

.btn:hover {
  transform: translateY(-3px);
}

.btn:hover::before {
  left: 120%;
}

.btn-primary {
  color: var(--bg);
  background: var(--yellow);
  box-shadow: 0 16px 36px rgba(255, 191, 27, 0.26);
}

.btn-primary:hover {
  background: #ffd150;
  box-shadow: 0 22px 48px rgba(255, 191, 27, 0.36);
}

.btn-dark {
  color: var(--white);
  background: var(--bg);
}

.btn-dark:hover {
  background: #17212b;
}

.hero {
  position: relative;
  min-height: 850px;
  padding: 152px 0 84px;
  color: var(--white);
  background:
    linear-gradient(100deg, rgba(8, 13, 18, 0.96) 0%, rgba(8, 13, 18, 0.82) 44%, rgba(8, 13, 18, 0.24) 100%),
    url("https://images.unsplash.com/photo-1581094480465-4e6c25fb4a52?auto=format&fit=crop&w=1900&q=84") center / cover;
}

.hero::before {
  position: absolute;
  inset: 0;
  content: "";
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.85), transparent 86%);
}

.hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.06fr) minmax(360px, 0.7fr);
  gap: 54px;
  align-items: end;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 36px;
  padding: 0 13px;
  color: #dffdfa;
  background: rgba(50, 213, 200, 0.12);
  border: 1px solid rgba(50, 213, 200, 0.34);
  border-radius: 8px;
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.chip::before {
  width: 8px;
  height: 8px;
  content: "";
  background: var(--cyan);
  border-radius: 50%;
  box-shadow: 0 0 0 6px rgba(50, 213, 200, 0.12);
}

.hero h1 {
  max-width: 810px;
  margin: 24px 0 0;
  font-size: clamp(2.9rem, 6.4vw, 6.3rem);
  line-height: 0.91;
  letter-spacing: 0;
}

.hero h1 strong {
  color: var(--yellow);
}

.lead {
  max-width: 670px;
  margin: 26px 0 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: clamp(1.04rem, 1.8vw, 1.24rem);
  font-weight: 650;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 34px;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  max-width: 680px;
  margin-top: 50px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(14px);
}

.metric {
  padding: 22px;
  border-right: 1px solid rgba(255, 255, 255, 0.12);
  transition: background 0.24s ease, transform 0.24s ease;
}

.metric:last-child {
  border-right: 0;
}

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

.metric strong {
  display: block;
  color: var(--yellow);
  font-size: 1.7rem;
  line-height: 1;
}

.metric span {
  display: block;
  margin-top: 8px;
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.85rem;
  font-weight: 850;
}

.rfq {
  position: relative;
  overflow: hidden;
  color: var(--ink);
  background: rgba(247, 248, 244, 0.94);
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 8px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.rfq::before {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 5px;
  content: "";
  background: linear-gradient(90deg, var(--yellow), var(--cyan));
}

.rfq:hover {
  transform: translateY(-8px);
  box-shadow: 0 38px 105px rgba(0, 0, 0, 0.34);
}

.rfq-head,
.rfq-form {
  padding: 28px;
}

.rfq-head {
  padding-bottom: 0;
}

.rfq h2 {
  margin: 0;
  font-size: 1.48rem;
  line-height: 1.18;
}

.rfq p {
  margin: 10px 0 0;
  color: var(--muted);
  font-weight: 650;
}

.rfq-form {
  display: grid;
  gap: 13px;
}

.field {
  display: grid;
  gap: 7px;
}

.field label {
  color: #344054;
  font-size: 0.78rem;
  font-weight: 900;
}

.field input,
.field textarea {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  color: var(--ink);
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.field textarea {
  min-height: 104px;
  resize: vertical;
}

.field input:hover,
.field textarea:hover {
  transform: translateY(-1px);
  border-color: #aab7c6;
}

.field input:focus,
.field textarea:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 4px rgba(15, 143, 117, 0.14);
}

.section {
  padding: 96px 0;
}

.section-dark {
  color: var(--white);
  background: var(--bg);
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 34px;
  margin-bottom: 34px;
}

.kicker {
  margin: 0 0 10px;
  color: var(--green);
  font-size: 0.78rem;
  font-weight: 950;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.section-dark .kicker {
  color: var(--cyan);
}

.title {
  max-width: 760px;
  margin: 0;
  font-size: clamp(2rem, 4vw, 3.6rem);
  line-height: 1.02;
  letter-spacing: 0;
}

.copy {
  max-width: 430px;
  margin: 0;
  color: var(--muted);
  font-weight: 700;
}

.section-dark .copy {
  color: rgba(255, 255, 255, 0.68);
}

.parts-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.part-card {
  position: relative;
  min-height: 230px;
  padding: 24px;
  overflow: hidden;
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-radius: 8px;
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.part-card::after {
  position: absolute;
  right: -64px;
  bottom: -64px;
  width: 150px;
  height: 150px;
  content: "";
  background: radial-gradient(circle, rgba(50, 213, 200, 0.28), transparent 68%);
  opacity: 0;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.part-card:hover {
  transform: translateY(-7px);
  border-color: rgba(15, 143, 117, 0.45);
  box-shadow: 0 24px 56px rgba(17, 24, 39, 0.12);
}

.part-card:hover::after {
  opacity: 1;
  transform: translate(-18px, -18px);
}

.part-icon {
  display: grid;
  width: 50px;
  height: 50px;
  margin-bottom: 30px;
  place-items: center;
  color: var(--bg);
  background: #fff1bd;
  border-radius: 8px;
  transition: transform 0.25s ease, background 0.25s ease;
}

.part-card:hover .part-icon {
  background: var(--yellow);
  transform: rotate(-6deg) scale(1.08);
}

.part-card h3 {
  margin: 0;
  font-size: 1.08rem;
}

.part-card p {
  margin: 10px 0 0;
  color: var(--muted);
}

.feature-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 48px;
  align-items: center;
}

.visual {
  min-height: 560px;
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(8, 13, 18, 0), rgba(8, 13, 18, 0.28)),
    url("https://images.unsplash.com/photo-1504917595217-d4dc5ebe6122?auto=format&fit=crop&w=1300&q=84") center / cover;
  box-shadow: var(--shadow);
  transition: transform 0.35s ease, filter 0.35s ease, box-shadow 0.35s ease;
}

.visual:hover {
  transform: scale(1.018);
  filter: saturate(1.12) contrast(1.04);
  box-shadow: 0 34px 94px rgba(0, 0, 0, 0.3);
}

.checks {
  display: grid;
  gap: 16px;
  margin: 28px 0 0;
  padding: 0;
  list-style: none;
}

.checks li {
  display: grid;
  grid-template-columns: 32px 1fr;
  gap: 13px;
  align-items: start;
  color: #344054;
  font-weight: 800;
}

.checks li::before {
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  color: var(--bg);
  background: var(--yellow);
  border-radius: 8px;
  content: "\2713";
  font-weight: 950;
}

.steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  counter-reset: steps;
}

.step {
  min-height: 220px;
  padding: 24px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  transition: transform 0.25s ease, background 0.25s ease, border-color 0.25s ease;
}

.step:hover {
  transform: translateY(-7px);
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(50, 213, 200, 0.38);
}

.step::before {
  display: inline-grid;
  width: 42px;
  height: 42px;
  margin-bottom: 28px;
  place-items: center;
  color: var(--bg);
  background: var(--cyan);
  border-radius: 8px;
  counter-increment: steps;
  content: counter(steps, decimal-leading-zero);
  font-size: 0.78rem;
  font-weight: 950;
}

.step h3 {
  margin: 0;
  color: var(--white);
}

.step p {
  margin: 10px 0 0;
  color: rgba(255, 255, 255, 0.64);
}

.cta {
  padding: 74px 0;
  color: var(--bg);
  background: linear-gradient(90deg, var(--yellow), #ffe39a);
}

.cta-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 30px;
  align-items: center;
}

.cta h2 {
  max-width: 760px;
  margin: 0;
  font-size: clamp(2rem, 4vw, 3.2rem);
  line-height: 1.04;
}

.cta p {
  max-width: 650px;
  margin: 14px 0 0;
  color: rgba(8, 13, 18, 0.72);
  font-weight: 800;
}

.footer {
  padding: 66px 0 28px;
  color: rgba(255, 255, 255, 0.68);
  background: #070b10;
}

.footer-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(240px, 0.72fr) minmax(280px, 0.95fr);
  gap: 34px;
}

.footer .logo {
  margin-bottom: 20px;
}

.footer h2 {
  margin: 0 0 14px;
  color: var(--white);
  font-size: 1rem;
}

.footer p {
  max-width: 430px;
  margin: 0;
}

.footer address {
  font-style: normal;
}

.footer a:hover {
  color: var(--yellow);
}

.map {
  overflow: hidden;
  min-height: 230px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  background: var(--bg-soft);
}

.map iframe {
  width: 100%;
  height: 230px;
  border: 0;
  filter: grayscale(0.25) contrast(1.08);
}

.copyright {
  display: flex;
  grid-column: 1 / -1;
  justify-content: space-between;
  gap: 18px;
  padding-top: 26px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 0.9rem;
}

@media (max-width: 1000px) {
  .menu {
    display: none;
  }

  .hero-grid,
  .feature-grid,
  .cta-inner,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .parts-grid,
  .steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .wrap {
    width: min(100% - 28px, 1180px);
  }

  .topbar {
    top: 10px;
  }

  .logo small {
    display: none;
  }

  .nav {
    min-height: 64px;
  }

  .nav .btn {
    min-height: 42px;
    padding: 0 12px;
    font-size: 0.82rem;
  }

  .hero {
    min-height: auto;
    padding: 118px 0 58px;
  }

  .metrics,
  .parts-grid,
  .steps {
    grid-template-columns: 1fr;
  }

  .metric {
    border-right: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  }

  .metric:last-child {
    border-bottom: 0;
  }

  .section {
    padding: 64px 0;
  }

  .section-head {
    display: block;
  }

  .copy {
    margin-top: 16px;
  }

  .visual {
    min-height: 360px;
  }

  .copyright {
    display: grid;
  }
}
