/* Variables de thème */
:root {
  --beige: #f5efe6;
  --gold: #c7a45d;
  --black: #222222;
  --sand: #d9d2c4;
  --text: #222222;
  --muted: #6b6256;
  --white: #ffffff;
  --radius: 10px;
  --shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  --container: 1152px;
}

/* Reset léger */
* {
  box-sizing: border-box;
}
html,
body {
  height: 100%;
  overflow-x: hidden;
}
html {
  scroll-behavior: smooth;
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
body {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Arial,
    sans-serif;
  color: var(--text);
  background: var(--beige);
  line-height: 1.6;
}
img {
  max-width: 100%;
  display: block;
  height: auto;
}
a {
  color: inherit;
  text-decoration: none;
}

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}
main,
.section,
.hero,
.site-header {
  width: 100%;
  max-width: 100vw;
}
main {
  overflow-x: hidden;
}

/* En-tête */
.site-header {
  position: sticky;
  top: 0;
  background: var(--beige);
  border-bottom: none;
  z-index: 50;
}
.header-inner {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 12px;
  padding: 18px 0;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.brand-logo {
  height: 200px;
  width: 200px;
  display: block;
  object-fit: contain;
}
.brand-title {
  font-family: "Playfair Display", Georgia, "Times New Roman", serif;
  font-weight: 700;
  letter-spacing: 0.4px;
}
.site-nav {
  display: flex;
  gap: 16px;
  align-items: center;
}
.site-nav.left {
  justify-self: start;
}
.site-nav.right {
  justify-self: end;
}
.site-nav .btn {
  margin-left: 8px;
}
.site-nav .tel {
  color: var(--muted);
}

/* Sections */
.section {
  padding: 72px 0;
  scroll-margin-top: 80px;
}
.section-title {
  font-family: "Playfair Display", Georgia, "Times New Roman", serif;
  font-weight: 700;
  font-size: 32px;
  margin: 0 0 24px;
}

/* Hero */
.hero {
  position: relative;
  height: 100vh;
  margin: 0;
  padding: 0;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: url("img/homepagepm.png");
  background-image: image-set(
    url("img/homepagepm.webp") type("image/webp"),
    url("img/homepagepm.png") type("image/png")
  );
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  filter: contrast(0.75) brightness(0.85);
  z-index: 0;
}

.hero::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(rgba(0, 0, 0, 0.35), rgba(0, 0, 0, 0.35));
  z-index: 1;
}
.hero-inner {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 64px 0 72px;
  transform: translate(0, -1%);
}
.hero-logo {
  max-width: 620px;
  width: auto;
  height: auto;
  margin: 0 auto 12px;
  display: block;
  position: relative;
  z-index: 1;
}
.hero-title {
  font-family: "Playfair Display", Georgia, "Times New Roman", serif;
  font-size: 40px;
  margin: 0 0 12px;
}
.hero-subtitle {
  color: #ffffff;
  margin: -24px auto 28px;
  font-size: 21px;
  font-family: "Playfair Display", Georgia, "Times New Roman", serif;
  font-weight: 600;
  letter-spacing: 0.3px;
  position: relative;
  z-index: 2;
}
.hero-cta {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  position: relative;
  z-index: 2;
  margin-top: 8px;
}
.hero .btn-outline {
  color: #ffffff;
  border-color: #ffffff;
}
.hero .btn-outline:hover {
  background: rgba(255, 255, 255, 0.12);
}

/* Boutons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 18px;
  border-radius: 999px;
  border: 1px solid var(--gold);
  box-shadow: var(--shadow);
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease;
}
.btn-primary {
  background: var(--gold);
  color: var(--black);
}
.btn-primary:hover {
  transform: translateY(-1px);
}
.btn-outline {
  background: transparent;
  color: var(--black);
}
.btn-outline:hover {
  background: var(--sand);
}

/* Services */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 320px));
  gap: 16px;
  justify-content: center;
}
.service-card {
  background: var(--white);
  border: 1px solid var(--sand);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.service-media {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: linear-gradient(135deg, #f6f1e6, #ede2cf);
}
.service-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}
.service-card:hover .service-media img {
  transform: scale(1.05);
}
.service-content {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.service-title {
  font-family: "Playfair Display", Georgia, "Times New Roman", serif;
  margin: 0 0 6px;
}

/* Réalisations */
.works-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(420px, 1fr));
  gap: 2px;
}
.work-item {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  isolation: isolate;
}
.work-item img {
  width: 100%;
  height: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  display: block;
}

/* À propos */
.about-inner {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 24px;
  align-items: center;
}
.about-media {
  justify-self: center;
}
.about-media img {
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  max-width: 420px;
  width: 100%;
}

/* Formulaire */
.quote-form {
  background: var(--white);
  border: 1px solid var(--sand);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow);
}
.form-row {
  display: grid;
  gap: 8px;
  margin-bottom: 14px;
}
.comfort-options {
  display: inline-flex;
  gap: 16px;
  align-items: center;
  flex-wrap: wrap;
}
.comfort-choice {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  line-height: 1.1;
  min-height: 24px;
}
.comfort-choice input {
  accent-color: var(--gold);
  width: 20px;
  height: 20px;
  margin: 0;
  flex-shrink: 0;
}
.comfort-choice span {
  display: inline-block;
}
.comfort-note {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}
.photos-note {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}
.photos-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 10px;
}
.photo-placeholder {
  position: relative;
  border: 1px dashed var(--sand);
  border-radius: var(--radius);
  background: linear-gradient(135deg, #f4f2ee, #e7e2da);
  color: var(--muted);
  min-height: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-weight: 600;
  padding: 12px;
  cursor: pointer;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  overflow: hidden;
}
.photo-placeholder:hover {
  border-color: var(--gold);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.08);
}
.photo-placeholder input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  z-index: 1;
}
.photo-placeholder .photo-preview {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}
.photo-placeholder span {
  position: relative;
  z-index: 1;
}
.photo-placeholder.has-preview {
  border-style: solid;
}
.photo-placeholder.has-preview span {
  display: none;
}
.photo-remove {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 2;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: none;
  background: rgba(0, 0, 0, 0.68);
  color: #fff;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  display: none;
}
.photo-placeholder.has-preview .photo-remove {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
label {
  font-weight: 600;
}
input,
select,
textarea {
  width: 100%;
  padding: 12px;
  border-radius: 10px;
  border: 1px solid var(--sand);
  background: #fff;
  font: inherit;
}
.form-actions {
  margin-top: 12px;
}
.form-message {
  margin-top: 12px;
  color: var(--black);
}
.form-message.success {
  color: #236e2e;
}
.form-message.error {
  color: #8a1f11;
}

/* Pied de page */
.site-footer {
  border-top: 1px solid var(--sand);
  background: #f7f2e9;
}
.footer-inner {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  padding: 24px 0;
  max-width: 100%;
  overflow: hidden;
  justify-items: center;
}
.footer-col {
  text-align: center;
}
.footer-title {
  font-family: "Playfair Display", Georgia, "Times New Roman", serif;
  margin: 0 0 6px;
}
.footer-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 6px;
}
.copyright {
  color: var(--muted);
}

/* Utilitaires */
.grid {
  display: grid;
}

/* Responsive */
@media (max-width: 1024px) {
  .footer-inner {
    grid-template-columns: repeat(2, 1fr);
  }
  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .works-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .about-inner {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .footer-inner {
    grid-template-columns: 1fr;
  }
  .container {
    padding: 0 16px;
  }
  .services-grid,
  .works-grid {
    grid-template-columns: 1fr;
  }
  .hero-title {
    font-size: 32px;
  }
  .hero-logo {
    max-width: 350px;
    margin-bottom: -20px;
  }
  .hero-subtitle {
    font-size: 18px;
    margin: 50px auto 16px;
    font-weight: 600;
  }
  .hero-cta {
    margin-top: 0;
  }
  .hero-inner {
    max-width: 520px;
    margin: 0 auto;
    padding: 0 16px;
  }
  .section {
  padding: 56px 0;
}
@media (max-width: 640px) {
  .section {
    scroll-margin-top: 68px;
  }
}
  .brand-logo {
    height: 140px;
    width: 140px;
  }
  .header-inner {
    grid-template-columns: 1fr auto 1fr;
  }
}
