/* ==========================================================================
   Ampelogos — feuille de style principale
   Palette : RAL 3005 #5B1220 (marque), RAL 4007 #47243C (fonds sombres, boutons),
             gris-brun #6B5D55, gris fonce #1A1A1A, creme #F3EBDD, fond #FDFBF7
   Typo : Lora (titres) + Calibri/equivalent (texte courant)
   Echelle : tout le texte hors titres suit --scale (via la taille de html) ;
             les titres h1-h3 sont recalcules pour garder leur taille d'origine.
   Logo : --logo-h donne a "Prestations sommelieres" la taille du texte courant.
   ========================================================================== */

/* ---------- Police Lora hebergee en local (licence SIL OFL, voir assets/fonts) ---------- */
@font-face {
  font-family: 'Lora';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('../fonts/lora-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'Lora';
  font-style: italic;
  font-weight: 400 700;
  font-display: swap;
  src: url('../fonts/lora-latin-italic.woff2') format('woff2');
}

:root {
  --violet: #47243C;
  --bordeaux: #5B1220;
  --gris-brun: #6B5D55;
  --gris-fonce: #1A1A1A;
  --creme: #F3EBDD;
  --fond: #FDFBF7;
  --blanc: #FFFFFF;
  --border-soft: #E4D9C8;

  --font-titre: 'Lora', Georgia, 'Times New Roman', serif;
  --font-texte: Calibri, Candara, 'Segoe UI', Optima, Arial, sans-serif;

  --container-width: 1240px;
  --scale: 1.12;
  --logo-h: 76px;
}

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

html {
  scroll-behavior: smooth;
  font-size: calc(16px * var(--scale));
}

body {
  margin: 0;
  font-family: var(--font-texte);
  color: var(--gris-fonce);
  background: var(--fond);
  line-height: 1.6;
  font-size: 1.0625rem;
}

img { max-width: 100%; display: block; }

h1, h2, h3, h4 {
  font-family: var(--font-titre);
  color: var(--bordeaux);
  font-weight: 600;
  line-height: 1.25;
  margin: 0 0 0.45em;
}

h1 { font-size: calc(2.6rem / var(--scale)); }
h2 { font-size: calc(1.9rem / var(--scale)); }
h3 { font-size: calc(1.3rem / var(--scale)); }

p { margin: 0 0 0.8em; }

a { color: var(--bordeaux); text-decoration: none; }
a:hover { text-decoration: underline; }

.eyebrow {
  font-family: var(--font-titre);
  font-style: italic;
  color: var(--gris-brun);
  letter-spacing: 0.02em;
  margin: 0 0 0.3em;
  font-size: 1.05rem;
}

.container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 24px;
}

.section {
  padding: 44px 0;
}
.section .container > h2:not(:first-child) { margin-top: 30px; }

.section--creme {
  background: var(--creme);
}

.section--violet {
  background: var(--violet);
  color: var(--creme);
}
.section--violet h2, .section--violet h3 { color: var(--blanc); }

.section-head {
  max-width: 680px;
  margin: 0 0 24px;
}
.section-head.center {
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

/* ---------- Boutons ---------- */
.btn {
  display: inline-block;
  font-family: var(--font-texte);
  font-weight: bold;
  letter-spacing: 0.02em;
  padding: 12px 30px;
  border: 1.5px solid var(--violet);
  color: var(--violet);
  background: transparent;
  border-radius: 2px;
  transition: background 0.2s ease, color 0.2s ease;
}
.btn:hover {
  background: var(--violet);
  color: var(--blanc);
  text-decoration: none;
}
.btn-primary {
  background: var(--violet);
  color: var(--blanc);
}
.btn-primary:hover {
  filter: brightness(0.88);
  color: var(--blanc);
}
.section--violet .btn { border-color: var(--creme); color: var(--creme); }
.section--violet .btn:hover { background: var(--creme); color: var(--violet); }

/* ---------- Header ---------- */
.site-header {
  position: relative;
  z-index: 100;
  background: var(--fond);
  border-bottom: 1px solid var(--border-soft);
}
.site-header .container {
  max-width: 1560px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 16px;
  padding-bottom: 16px;
}
.site-logo img { height: var(--logo-h); width: auto; }
.site-logo { display: flex; align-items: center; flex-shrink: 0; }

.main-nav {
  flex: 1 1 0;
  min-width: 0;
  margin-left: 32px;
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
  column-gap: 24px;
  row-gap: 8px;
}
.main-nav a {
  font-family: var(--font-texte);
  font-size: 1em;
  color: var(--gris-fonce);
  letter-spacing: 0.01em;
  white-space: nowrap;
}
.main-nav a:hover { color: var(--bordeaux); text-decoration: none; }
.main-nav a.active { color: var(--bordeaux); border-bottom: 2px solid var(--bordeaux); padding-bottom: 4px; }

.lang-switch {
  display: flex;
  gap: 6px;
  font-family: var(--font-texte);
  font-size: 0.85rem;
  color: var(--gris-brun);
  margin-left: 4px;
}
.lang-switch a { color: var(--gris-brun); font-size: inherit; }
.lang-switch a.active { color: var(--bordeaux); font-weight: bold; border-bottom: 0; padding-bottom: 0; }
.lang-switch span { color: var(--border-soft); }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}
.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--violet);
  margin: 5px 0;
}

/* ---------- Hero ---------- */
.hero {
  padding: 44px 0 52px;
}
.hero .container {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 40px;
  align-items: center;
}
.hero h1 { margin-bottom: 0.35em; }
.hero .lede {
  font-size: 1.15rem;
  color: var(--gris-brun);
  max-width: 52ch;
}
.hero-actions { margin-top: 20px; display: flex; gap: 14px; flex-wrap: wrap; }

.hero-list {
  margin: 0 0 14px;
  padding: 0;
  list-style: none;
  max-width: 56ch;
}
.hero-list li {
  position: relative;
  padding-left: 1.4em;
  margin-bottom: 6px;
  color: var(--gris-fonce);
  font-size: 1.1rem;
  line-height: 1.45;
}
.hero-list li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 0.55em;
  width: 7px;
  height: 7px;
  background: var(--bordeaux);
  border-radius: 50%;
}

.page-hero {
  padding: 36px 0 40px;
  border-bottom: 1px solid var(--border-soft);
}
.page-hero h1 { margin-bottom: 0.3em; }
.page-hero .lede { color: var(--gris-brun); font-size: 1.1rem; max-width: 70ch; }

/* ---------- Photos : meme cadre noir tres fin partout ---------- */
.photo-frame {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid #000;
}
.page-hero--photo .container {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 40px;
  align-items: center;
}

.about-grid {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 40px;
  align-items: start;
}

/* ---------- Cartes offres ---------- */
.offer-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}
.offer-card {
  background: var(--blanc);
  border: 1px solid var(--border-soft);
  padding: 24px 26px;
  border-radius: 2px;
}
.offer-card h3 { margin-bottom: 0.4em; }
.offer-card a.more { font-weight: bold; }

/* ---------- Tables tarifs ---------- */
.price-table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0 6px;
  font-size: 0.98rem;
}
.price-table caption {
  text-align: left;
  font-family: var(--font-titre);
  font-size: 1.15rem;
  color: var(--bordeaux);
  margin-bottom: 10px;
}
.price-table th {
  text-align: left;
  background: var(--violet);
  color: var(--blanc);
  padding: 9px 14px;
  font-weight: normal;
  font-family: var(--font-titre);
}
.price-table td {
  padding: 9px 14px;
  border-bottom: 1px solid var(--border-soft);
  vertical-align: top;
}
.price-table tr:nth-child(even) td { background: var(--creme); }
.price-table .amount { white-space: nowrap; font-weight: bold; color: var(--bordeaux); vertical-align: middle; text-align: center; font-size: 1.3rem; }
.price-table th:last-child { width: 250px; text-align: center; white-space: nowrap; }
@media (max-width: 560px) {
  .price-table th:last-child { width: auto; white-space: normal; }
  .price-table th, .price-table td { padding: 9px 10px; }
  .price-table td:first-child strong, .price-table .amount { font-size: 1.1rem; }
}
.table-scroll { overflow-x: auto; max-width: 760px; margin: 0 auto; }
.price-table td:first-child strong { font-family: var(--font-titre); font-size: 1.3rem; line-height: 1.3; color: var(--bordeaux); }
.price-table .desc { display: inline-block; margin-top: 2px; color: var(--gris-brun); font-size: 0.95rem; line-height: 1.4; }

.note {
  color: var(--gris-brun);
  font-size: 0.92rem;
  font-style: italic;
}

/* ---------- Liste de prestations (sans prix) ---------- */
.feature-list {
  list-style: none;
  padding: 0;
  margin: 12px 0 4px;
}
.feature-list li {
  padding: 12px 0;
  border-bottom: 1px solid var(--border-soft);
}
.feature-list li:first-child { padding-top: 0; }
.feature-list h3 { margin: 0 0 4px; }
.feature-list p { margin: 0; }

/* ---------- Domaines list ---------- */
.domaine-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  column-gap: 36px;
  list-style: none;
  padding: 0;
  margin: 14px 0;
}
.domaine-list li {
  padding: 8px 0;
}
.domaine-list .nom { font-family: var(--font-titre); color: var(--bordeaux); font-size: 1.3rem; line-height: 1.3; }
.domaine-list .nom a { border-bottom: 1px solid var(--border-soft); }
.domaine-list .nom a:hover { border-bottom-color: var(--bordeaux); text-decoration: none; }
.domaine-list .region { color: var(--gris-brun); font-size: 1.08rem; }

/* ---------- Qui sommes-nous : parcours ---------- */
.timeline {
  border-left: 2px solid var(--border-soft);
  padding-left: 24px;
  margin: 14px 0;
}
.timeline-item { margin-bottom: 16px; }
.timeline-item .role { font-family: var(--font-titre); color: var(--bordeaux); font-size: 1.1rem; }
.timeline-item .meta { color: var(--gris-brun); font-size: 0.92rem; margin-bottom: 4px; display: block; }

/* ---------- Contact ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 40px;
}
.contact-info dt {
  font-family: var(--font-titre);
  color: var(--bordeaux);
  margin-top: 16px;
}
.contact-info dt:first-child { margin-top: 0; }
.contact-info dd { margin: 4px 0 0; color: var(--gris-fonce); }

.form-field { margin-bottom: 14px; }
.form-field label {
  display: block;
  font-weight: bold;
  margin-bottom: 5px;
  font-size: 0.95rem;
}
.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border-soft);
  background: var(--blanc);
  font-family: var(--font-texte);
  font-size: 1rem;
  color: var(--gris-fonce);
  border-radius: 2px;
}
.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  outline: none;
  border-color: var(--bordeaux);
}
.form-field.checkbox {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}
.form-field.checkbox input { width: auto; margin-top: 4px; }
.form-field.checkbox label { font-weight: normal; font-size: 0.9rem; }
.honeypot { position: absolute; left: -9999px; top: -9999px; }

.form-msg {
  padding: 12px 16px;
  margin-bottom: 18px;
  border-left: 3px solid var(--bordeaux);
  background: var(--creme);
  display: none;
}
.form-msg.show { display: block; }
.form-msg.error { border-left-color: #8a1c1c; }

/* ---------- CTA band ---------- */
.cta-band {
  text-align: center;
}
.cta-band h2 { color: inherit; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--violet);
  color: var(--creme);
  padding: 40px 0 22px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 32px;
  margin-bottom: 28px;
}
.footer-grid h4 {
  color: var(--blanc);
  font-size: 1rem;
  margin-bottom: 10px;
}
.site-footer a { color: var(--creme); }
/* sur le fond violet : logo positif sur fond blanc (pas de version negatif) */
.site-footer .logo-footer img { box-sizing: content-box; height: var(--logo-h); width: auto; margin-bottom: 10px; padding: 12px 16px; background: var(--blanc); border-radius: 2px; }
.footer-nav { list-style: none; padding: 0; margin: 0; }
.footer-nav li { margin-bottom: 6px; }
.footer-bottom {
  border-top: 1px solid rgba(243,235,221,0.25);
  padding-top: 16px;
  font-size: 0.85rem;
  color: rgba(243,235,221,0.75);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}
.footer-bottom a { color: rgba(243,235,221,0.85); }
.footer-bottom .alcool { color: rgba(243,235,221,0.85); }

/* ---------- Legal pages ---------- */
.legal-content h2 { margin-top: 1.4em; }
.legal-content { max-width: 820px; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  :root { --logo-h: 68px; }
  .main-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-left: 0;
    background: var(--fond);
    border-bottom: 1px solid var(--border-soft);
    flex-direction: column;
    flex-wrap: nowrap;
    justify-content: flex-start;
    align-items: flex-start;
    gap: 0;
    padding: 6px 24px 16px;
    display: none;
  }
  .main-nav.open { display: flex; }
  .main-nav a { padding: 9px 0; width: 100%; }
  .lang-switch { margin: 8px 0 0; }
  .nav-toggle { display: block; }
}

@media (max-width: 880px) {
  h1 { font-size: calc(2.1rem / var(--scale)); }
  .hero .container { grid-template-columns: 1fr; }
  .hero-image { order: -1; max-width: 360px; margin: 0 auto; }
  .page-hero--photo .container { grid-template-columns: 1fr; gap: 24px; }
  .about-grid { grid-template-columns: 1fr; gap: 24px; }
  .about-photo { max-width: 360px; height: auto; }
  .offer-grid { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 22px; }
  .domaine-list { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  :root { --logo-h: 60px; }
  body { font-size: 1rem; }
  .section { padding: 32px 0; }
  .hero { padding: 28px 0 36px; }
  .page-hero { padding: 28px 0 30px; }
  h1 { font-size: calc(1.8rem / var(--scale)); }
}

/* ---------- Ajouts : Qui sommes-nous, lien croisé, parcours ---------- */
.about-grid { align-items: stretch; }
.about-photo { height: 100%; object-fit: cover; object-position: 25% 30%; }
.about-name { margin-top: 24px; }
.about-name h2 { font-size: calc(1.5rem / var(--scale)); }
.about-name p:last-child { margin-bottom: 0; }
.timeline-item .role a { border-bottom: 1px solid var(--border-soft); }
.timeline-item .role a:hover { border-bottom-color: var(--bordeaux); text-decoration: none; }
.cross-link { margin-top: 48px; font-size: 1.25em; }

@media (max-width: 1239px) {
  .about-grid { align-items: start; }
  .about-photo { height: auto; }
}

/* ---------- Bandeau compact : reste visible sur une ligne au defilement ---------- */
html { scroll-padding-top: 76px; }
.site-header.is-compact {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  animation: header-in 0.25s ease;
}
.site-header.is-compact .container { padding-top: 6px; padding-bottom: 6px; }
/* barre reduite : le sceau remplace le logo complet */
.site-logo .logo-seal { display: none; }
.site-header.is-compact .site-logo .logo-full { display: none; }
.site-header.is-compact .site-logo .logo-seal { display: block; width: 56px; height: 56px; }
@keyframes header-in {
  from { transform: translateY(-100%); }
  to { transform: translateY(0); }
}
@media (min-width: 1101px) {
  .site-header.is-compact .main-nav {
    flex-wrap: nowrap;
    column-gap: 18px;
    margin-left: 24px;
  }
  .site-header.is-compact .main-nav a { font-size: 0.84em; }
  .site-header.is-compact .main-nav a.active { padding-bottom: 2px; }
}
@media (max-width: 1100px) {
  .site-header.is-compact .main-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-left: 0;
    background: var(--fond);
    border-bottom: 1px solid var(--border-soft);
    flex-direction: column;
    flex-wrap: nowrap;
    justify-content: flex-start;
    align-items: flex-start;
    gap: 0;
    padding: 6px 24px 16px;
    display: none;
  }
  .site-header.is-compact .main-nav.open { display: flex; }
  .site-header.is-compact .main-nav a { padding: 9px 0; width: 100%; }
  .site-header.is-compact .lang-switch { margin: 8px 0 0; }
  .site-header.is-compact .nav-toggle { display: block; }
}
@media (prefers-reduced-motion: reduce) {
  .site-header.is-compact { animation: none; }
}

/* ---------- Contact : photo sous les coordonnees ---------- */
.contact-grid { grid-template-rows: auto 1fr; align-items: start; }
.contact-grid .contact-info { grid-column: 1; grid-row: 1; }
.contact-grid .contact-form-col { grid-column: 2; grid-row: 1 / span 2; }
.contact-grid .contact-photo {
  grid-column: 1;
  grid-row: 2;
  margin-top: 8px;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  object-position: 50% 27%;
}
@media (max-width: 880px) {
  .contact-grid { grid-template-rows: none; }
  .contact-grid .contact-info, .contact-grid .contact-form-col, .contact-grid .contact-photo { grid-column: auto; grid-row: auto; }
  .contact-grid .contact-photo { max-width: 520px; margin-top: 16px; }
}

/* ---------- Formulaire : mention RGPD ---------- */
.form-legal { margin: 16px 0 0; color: var(--gris-brun); font-size: 0.92rem; line-height: 1.5; }
.form-legal a { text-decoration: underline; }

/* ---------- Mention sous le bouton des bandeaux d'appel a l'action ---------- */
.cta-band .cta-note { margin: 18px auto 0; max-width: 62ch; font-size: 0.92rem; line-height: 1.5; color: rgba(243,235,221,0.85); }

/* ---------- Pied de page : credits photo ; mise en page sans photo ---------- */
.photo-credit { display: block; margin-top: 6px; font-size: 0.82rem; line-height: 1.4; color: var(--gris-brun); }
.page-hero--photo .container.no-photo,
.hero .container.no-photo,
.about-grid.no-photo { grid-template-columns: 1fr; }

/* ---------- Credit photo : image + legende dans une figure (genere par finaliser.ps1) ---------- */
.photo-fig { margin: 0; }
.about-grid > .photo-fig { display: flex; flex-direction: column; height: 100%; }
.about-grid > .photo-fig .about-photo { flex: 1 1 auto; min-height: 0; height: auto; }
.contact-grid > .photo-fig { grid-column: 1; grid-row: 2; margin-top: 8px; }
@media (max-width: 1239px) {
  .about-grid > .photo-fig { height: auto; }
}
@media (max-width: 880px) {
  .contact-grid > .photo-fig { grid-column: auto; grid-row: auto; margin-top: 16px; max-width: 520px; }
}

/* Ligne d'identite legale du pied de page */
.footer-legal { margin: 12px 0 0; font-size: 0.85rem; line-height: 1.5; color: rgba(243,235,221,0.85); }

