:root {
  --cream: #faf3ea;
  --card: #fffdf8;
  --terracotta: #c1440e;
  --terracotta-dark: #9a360b;
  --ocre: #d9a441;
  --anthracite: #1c1917;
  --text-soft: #6b5b4c;
  --border: #e8dcc9;
  --font-display: "Montserrat", sans-serif;
  --font-body: "Inter", -apple-system, sans-serif;
}

* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  * {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--anthracite);
  background: var(--cream);
  line-height: 1.6;
}

h1,
h2,
h3 {
  font-family: var(--font-display);
  font-weight: 600;
  margin: 0;
}
p {
  margin: 0;
}
a {
  color: inherit;
  text-decoration: none;
}

.wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  border: none;
  transition:
    transform 0.15s ease,
    box-shadow 0.15s ease,
    background 0.15s ease;
}
.btn-primary {
  background: var(--terracotta);
  color: var(--cream);
}
.btn-primary:hover {
  background: var(--terracotta-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(193, 68, 14, 0.25);
}
.btn-small {
  padding: 10px 20px;
  font-size: 14px;
}
.btn-outline {
  background: transparent;
  color: var(--terracotta);
  border: 2px solid var(--terracotta);
}
.btn-outline:hover {
  background: color-mix(in srgb, var(--terracotta) 8%, transparent);
  transform: translateY(-2px);
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(250, 243, 234, 0.9);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 14px;
  padding-bottom: 14px;
  gap: 24px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
}
.brand-logo {
  width: 52px;
  height: 52px;
  border-radius: 50%;
}
.brand-name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 19px;
}
.nav {
  display: flex;
  gap: 32px;
}
.nav a {
  font-size: 15px;
  font-weight: 500;
  transition: color 0.15s ease;
}
.nav a:hover {
  color: var(--terracotta);
}
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}
.nav-toggle span {
  width: 22px;
  height: 2px;
  background: var(--anthracite);
  border-radius: 2px;
}

/* Hero */
.hero {
  padding: 90px 0 70px;
  overflow: hidden;
}
.hero-inner {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: center;
  gap: 48px;
}
.hero h1 {
  font-size: 44px;
  line-height: 1.15;
  letter-spacing: -0.5px;
}
.hero-sub {
  margin-top: 22px;
  font-size: 18px;
  color: var(--text-soft);
  max-width: 520px;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 32px;
}

.hero-art {
  position: relative;
  height: 320px;
}
.pegboard {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(var(--ocre) 1.5px, transparent 1.5px);
  background-size: 24px 24px;
  opacity: 0.35;
  border-radius: 24px;
}
.ae-mark {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(220px, 70%);
  aspect-ratio: 1 / 1;
}

/* Traits du A et du E : se dessinent comme un tracé */
.ae-stroke {
  stroke-dasharray: 90;
  stroke-dashoffset: 90;
  animation: aeDraw 0.7s ease-out forwards;
}
.ae-a-left {
  animation-delay: 0.1s;
}
.ae-a-right {
  animation-delay: 0.28s;
}
.ae-e-1 {
  animation-delay: 0.85s;
  animation-duration: 0.4s;
}
.ae-e-2 {
  animation-delay: 1s;
  animation-duration: 0.4s;
}
.ae-e-3 {
  animation-delay: 1.15s;
  animation-duration: 0.4s;
}

@keyframes aeDraw {
  to {
    stroke-dashoffset: 0;
  }
}

/* Points : apparaissent en léger rebond */
.ae-dot {
  opacity: 0;
  transform-box: fill-box;
  transform-origin: center;
  animation: aeDot 0.4s ease-out forwards;
}
.ae-dot-1 {
  animation-delay: 1.45s;
}
.ae-dot-2 {
  animation-delay: 1.6s;
}
.ae-dot-3 {
  animation-delay: 1.75s;
}

@keyframes aeDot {
  0% {
    opacity: 0;
    transform: scale(0);
  }
  70% {
    opacity: 1;
    transform: scale(1.35);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

/* Respiration douce une fois le tracé terminé */
.ae-breathe {
  transform-box: fill-box;
  transform-origin: center;
  animation: aeBreathe 4.5s ease-in-out 2.3s infinite;
}

@keyframes aeBreathe {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.03);
  }
}

/* Stitch divider */
.stitch {
  height: 1px;
  background-image: repeating-linear-gradient(
    90deg,
    var(--ocre) 0 10px,
    transparent 10px 20px
  );
  opacity: 0.5;
}

/* Sections */
section {
  padding: 80px 0;
}
section h2 {
  font-size: 30px;
  text-align: center;
  margin-bottom: 40px;
}
.services {
  background: var(--cream);
}
.about {
  background: var(--card);
}
.about-text {
  max-width: 760px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 18px;
  font-size: 16.5px;
  color: var(--anthracite);
}
.realisations {
  background: var(--cream);
}

/* Cards grid */
.cards {
  display: grid;
  gap: 22px;
}
.cards-3 {
  grid-template-columns: repeat(3, 1fr);
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 26px;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    border-color 0.2s ease;
}
.service-card {
  cursor: pointer;
  font-family: var(--font-body);
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 30px rgba(28, 25, 23, 0.08);
  border-color: var(--ocre);
}

.card-head {
  display: flex;
  align-items: center;
  gap: 8px;
}
.card-head h3 {
  font-size: 19px;
}
.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}
.dot-terracotta {
  background: var(--terracotta);
}
.dot-ocre {
  background: var(--ocre);
}
.dot-anthracite {
  background: var(--anthracite);
}
.slogan {
  color: var(--terracotta);
  font-weight: 600;
  font-size: 14.5px;
}
.desc {
  color: var(--text-soft);
  font-size: 14.5px;
}
.card-divider {
  height: 1px;
  background: var(--border);
  margin: 4px 0;
}
.price {
  color: var(--terracotta);
  font-weight: 700;
  font-size: 16px;
  font-family: var(--font-display);
}
.card-more {
  font-size: 13px;
  color: var(--text-soft);
  margin-top: auto;
}

/* Realisation cards */
.preview {
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--border);
  margin-bottom: 14px;
}
.preview-body {
  background: #f1e7d8;
  height: 110px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.preview-body-img {
  height: auto;
  padding: 0;
}
.preview-body-img img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  object-position: top;
  display: block;
}

.tag {
  display: inline-block;
  align-self: flex-start;
  font-size: 12px;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 999px;
  color: var(--cream);
}
.tag-terracotta {
  background: var(--terracotta);
}
.tag-ocre {
  background: var(--ocre);
  color: var(--anthracite);
}
.tag-dark {
  background: var(--anthracite);
}
.project-card h3 {
  font-size: 17px;
}
.project-card p {
  color: var(--text-soft);
  font-size: 14px;
}
/* Contact */
.contact {
  background: var(--anthracite);
  color: var(--cream);
  text-align: center;
}
.contact h2 {
  color: var(--cream);
}
.contact-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}
.contact-lead {
  color: var(--cream);
  opacity: 0.85;
  font-size: 15px;
  margin-bottom: 12px;
}

.contact-form {
  width: 100%;
  max-width: 480px;
  background: var(--card);
  border-radius: 16px;
  padding: 28px;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 16px;
  color: var(--anthracite);
}
.form-row {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.form-row label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-soft);
}
.form-row input,
.form-row select,
.form-row textarea {
  font-family: var(--font-body);
  font-size: 15px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--cream);
  color: var(--anthracite);
  resize: vertical;
}
.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus {
  outline: none;
  border-color: var(--terracotta);
  box-shadow: 0 0 0 3px rgba(193, 68, 14, 0.15);
}
.form-submit {
  margin-top: 4px;
}
.form-status {
  font-size: 14px;
  margin: 0;
  min-height: 20px;
}
.form-status.success {
  color: var(--terracotta);
  font-weight: 600;
}
.form-status.error {
  color: #b3261e;
  font-weight: 600;
}

/* Footer */
.site-footer {
  background: var(--cream);
  border-top: 1px solid var(--border);
  padding: 24px 0;
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  color: var(--text-soft);
}
.footer-social {
  display: flex;
  gap: 18px;
}
.footer-social a:hover {
  color: var(--terracotta);
}

/* Scroll reveal */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition:
    opacity 0.6s ease,
    transform 0.6s ease;
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Modal */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(28, 25, 23, 0.55);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 100;
  padding: 24px;
}
.modal-backdrop.is-open {
  display: flex;
}
.modal {
  display: none;
  background: var(--card);
  border-radius: 16px;
  padding: 36px;
  max-width: 460px;
  width: 100%;
  position: relative;
  max-height: 85vh;
  overflow-y: auto;
  animation: modalIn 0.25s ease;
}
.modal.is-active {
  display: block;
}
@keyframes modalIn {
  from {
    opacity: 0;
    transform: scale(0.96);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}
.modal h3 {
  font-size: 22px;
  margin-bottom: 10px;
}
.modal-sub {
  color: var(--text-soft);
  font-size: 14px;
  margin-bottom: 16px;
}
.modal-preview {
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--border);
  margin-bottom: 18px;
}
.modal-preview img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  object-position: top;
  display: block;
}
.modal-block + .modal-block {
  margin-top: 18px;
}
.modal-block h4 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 14px;
  color: var(--terracotta);
  margin: 0 0 6px;
}
.modal-block p {
  font-size: 14.5px;
  line-height: 1.55;
}
.modal-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 20px;
}
.modal-actions .btn {
  width: 100%;
}
.modal-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.modal-list li {
  position: relative;
  padding-left: 18px;
  font-size: 14.5px;
}
.modal-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 8px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--terracotta);
}
.modal-divider {
  height: 1px;
  background: var(--border);
  margin: 20px 0 14px;
}
.modal-price {
  color: var(--terracotta);
  font-weight: 700;
  font-size: 18px;
  font-family: var(--font-display);
}
.modal-note {
  color: var(--text-soft);
  font-size: 12.5px;
  margin-top: 10px;
}
.modal-cta {
  width: 100%;
  margin-top: 20px;
}
.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--cream);
  font-size: 18px;
  cursor: pointer;
  line-height: 1;
  transition: background 0.15s ease;
}
.modal-close:hover {
  background: var(--border);
}

/* Responsive */
@media (max-width: 900px) {
  .hero-inner {
    grid-template-columns: 1fr;
  }
  .hero-art {
    height: 220px;
  }
  .cards-3 {
    grid-template-columns: 1fr;
  }
  .nav {
    position: fixed;
    top: 68px;
    left: 0;
    right: 0;
    background: var(--cream);
    flex-direction: column;
    padding: 20px 24px;
    gap: 18px;
    visibility: hidden;
    transform: translateY(-120%);
    transition:
      transform 0.35s ease-out,
      visibility 0s linear 0.35s;
  }
  .nav.is-open {
    visibility: visible;
    border-bottom: 1px solid var(--border);
    transform: translateY(0);
    transition: transform 0.35s ease-out;
  }
  .nav-toggle {
    display: flex;
  }
}
@media (max-width: 768px) {
  .header-cta {
    display: none;
  }
}
@media (max-width: 480px) {
  .header-inner {
    gap: 12px;
  }
}
@media (max-width: 600px) {
  .hero h1 {
    font-size: 32px;
  }
  .hero-art {
    height: 150px;
  }
  .ae-mark {
    width: min(150px, 55%);
  }
  .footer-inner {
    flex-direction: column;
    gap: 10px;
    text-align: center;
  }
}
