:root {
    --color1: #14df6cd5;
    --color2: #F4F4f4;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: 'Times New Roman', Times, serif;
    line-height: 1.5;
    overflow-x: hidden;
}

img { max-width: 100%; height: auto; }

div.cover {
    background: url(cover_overlay.png) no-repeat center/100% 100%,
                url(cover.png) no-repeat center/cover;
    height: 640px;
    position: relative;
}

div.cover-text {
    position: absolute;
    top: 50%;
    width: 100%;
    text-align: center;
}

h1 {
    color: black;
    text-align: center;
    font-size: 60px;
    margin-bottom: 10px;
}

div.cover p {
    color: black;
    text-align: center;
    font-size: 30px;
    margin-top: 0;
}

div.cover-contact {
    /* background-color : #FF000080; */
    position: absolute;
    top: 80%;
    left: 10px;
    font-size: 15px;
    border-left: 4px solid var(--color1);
    padding-left: 8px;
}

div.cover-contact p {
    text-align: left;
    margin: 0px;
}

div.cover-contact p:first-child {
    margin-top: -10px;
}

div.cover-contact a {
    color: white;
    font-size: 14px;
}

a.contact-button {
    color: var(--color1);
    border: 3px solid var(--color1);
    padding: 2px 25px;
    text-decoration: none;
    background-color: #00000040;
    display: inline-block;
    margin-top: 20px;
    font-size: 14px;
}

a.contact-button:hover {
    color: white;
    border: 3px solid white;
}

.section {
    padding-left: 40px;
    padding-right: 40px;
    padding-top: 30px;
    padding-bottom: 30px;
}

div.section-grise1 {
    background: url(triangle2white.svg) no-repeat center bottom/100%;
    background-color: var(--color2);
    height: 420px;
    padding-bottom: 60px;
    color: #656565;
}

div.section-grise2 {
    background: url(triangle1white.svg) no-repeat center top/100%;
    background-color: var(--color2);
    height: auto;
    min-height: 230px;
    padding-top: 80px;
    justify-content: center;
}

h2 {
    text-align: center;
    font-size: 34px;
}

div.separateur {
    background-color: #979797;
    height: 2px;
    width: 150px;
    position: relative;
    left: 50%;
    margin-left: -75px;
}

div.section-grise1 p {
    font-size: 22px;
    color: #656565;
}

div.section p {
    font-size: 22px;
    color: #656565;
}

/* Concerne le texte "brut" dans index.html (entre les <p>) */
.section-grise1 {
    font-size: 20px; /* +1 ou +2 px par rapport aux <p> */
}

.lien-galerie {
    color: var(--color1);
    text-decoration: none;
}

.lien-galerie:hover {
    text-decoration: underline;
}

div.frame {
    margin: 50px 50px;
    padding: 20px 30px;
    background-color: white;
    box-shadow: 0px 0px 8px rgba(0, 0, 0, 0.1);
}

div.section p.frame-title {
    font-size: 34px;
    font-weight: bold;
    margin-bottom: 20px;
    color: black;
    margin-top: 5px;
    text-align: center;
}

div.texte-avec-ligne-verticale p {
    margin-top: 0;
}

div.texte-avec-ligne-verticale {
    border-left: 4px solid var(--color1);
    padding-left: 8px;
    height: 30px;
    display: inline-block;
}

div.barre-verticale {
    height: 50px;
    width: 4px;
    background-color: var(--color1);
}

/* PORTFOLIO */
.portfolio-header {
    height: 150px;
    background: url(Header.png) no-repeat center/cover;
    position: relative;
}

div.section-grise1-portfolio p {
    text-align: center;
}

.portfolio-header .portfolio-header-title {
    font-size: 26px;
    font-weight: bold;
    color: white;
    padding-top: 4px;
    padding-left: 8px;
}

h1.portfolio {
    font-size: 46px;
    color: black;
    line-height: 1;
    margin-top: 10px;
}

h2.portfolio {
    font-size: 26px;
    color: black;
    font-weight: normal;
    margin-bottom: 0;
}

a.portfolio-back {
    color: var(--color1);
    margin-left: -10px;
}

.galerie {
    display: flex;
    justify-content: center;
    gap: 70px;
    margin-top: 30px;
    flex-wrap: wrap;
}

.galerie img {
    width: 330px;
    height: 225px;
    object-fit: cover;
    border-radius: 6px;
    cursor: pointer;
    box-shadow: 0 0 8px rgba(0,0,0,0.15);
    transition: transform 0.15s ease;
}

/* LIGHTBOX */
.lightbox {
    display: none;
    position: fixed;
    z-index: 9999;
    inset: 0;
    background: rgba(0,0,0,0.85);
    justify-content: center;
    align-items: center;
    padding: 30px;
}

.lightbox:target {
    display: flex;
}

.lightbox img {
    max-width: 95vw;
    max-height: 90vh;
    border-radius: 8px;
    box-shadow: 0 0 20px rgba(0,0,0,0.4);
}

.lightbox .close {
    position: absolute;
    top: 18px;
    right: 22px;
    color: white;
    font-size: 42px;
    text-decoration: none;
    line-height: 1;
}

/* FOOTER */
.site-footer {
    text-align: center;
    font-size: 12px;
    font-family: "Times New Roman", Times, serif;
    color: #777;
    padding: 12px 20px;
    background-color: #f8f8f8;
    border-top: 1px solid #e0e0e0;
}

.site-footer p {
    margin: 0;
    line-height: 1.3;
}

/* =========================
   RESPONSIVE (mobile)
   ========================= */

@media screen and (max-width: 768px) {

  /* =========================================================
     COVER (SMARTPHONE)
     Objectif: ne pas toucher la vue PC
     - cover-text redevient "statique" (sinon top/transform casse bottom)
     - bouton + coordonnées ancrés au bas de l'image
  ========================================================= */

  div.cover {
    height: 520px;
    background-position: center;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  /* IMPORTANT: neutralise le positionnement desktop */
  div.cover-text {
    position: static !important;
    top: auto !important;
    transform: none !important;
    padding: 0 16px;
    text-align: center;
    width: 100%;
    z-index: 2;
  }

  /* Texte lisible sur photo */
  div.cover h1,
  div.cover p {
    color: #fff !important;
    text-shadow: 0 2px 10px rgba(0,0,0,0.75);
  }

  div.cover h1 {
    font-size: 34px;
    line-height: 1.1;
    margin: 0 0 8px 0;
  }

  div.cover p {
    font-size: 18px;
    margin: 0;
  }

  /* Bouton: ancré au bas de l'image */
  div.cover a.contact-button {
    position: absolute !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    bottom: 71px !important;       /* ajuste 44-70 si besoin */
    margin: 0 !important;
    z-index: 3;

    padding: 12px 22px;
    font-size: 14px;

    background-color: rgba(0,0,0,0.35);
    color: #fff !important;
    border-color: #fff !important;
  }

  /* Coordonnées: tout en bas, transparent */
  div.cover-contact {
    position: absolute !important;
    top: auto !important;
    bottom: 10px !important;       /* ajuste 6-14 si besoin */
    left: 16px !important;
    right: 16px !important;
    z-index: 3;

    background: transparent !important;
    border-left: 4px solid #fff !important;
    padding-left: 10px !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    border-radius: 0 !important;
  }

  div.cover-contact p:first-child {
    margin-top: 0 !important;
  }

  div.cover-contact a {
    color: #fff !important;
    font-size: 14px;
    text-shadow: 0 2px 10px rgba(0,0,0,0.75) !important;
  }

  /* =========================================================
     SECTIONS
  ========================================================= */

  .section {
    padding-left: 16px;
    padding-right: 16px;
    padding-top: 22px;
    padding-bottom: 22px;
  }

  h2 {
    font-size: 26px;
    margin-top: 0;
  }

  div.section p,
  div.section-grise1 p {
    font-size: 18px;
    line-height: 1.6;
  }

  .section-grise1 {
    font-size: 18px;
    line-height: 1.6;
  }

  div.section-grise1 {
    height: auto;
    padding-bottom: 60px;
  }

  div.section-grise2 {
    height: auto;
    padding-top: 60px;
    padding-bottom: 30px;
  }

  /* =========================================================
     FRAME
  ========================================================= */

  div.frame {
    margin: 18px 0;
    padding: 16px;
  }

  div.section p.frame-title {
    font-size: 26px;
  }

  /* =========================================================
     TABLE EN COLONNE
  ========================================================= */

  table {
    width: 100%;
    border-collapse: collapse;
  }

  table tr,
  table td {
    display: block;
    width: 100%;
  }

  table td {
    text-align: center;
  }

  table td img {
    width: 92px !important;
    margin-bottom: 10px;
  }

  div.texte-avec-ligne-verticale {
    height: auto;
    display: block;
    padding-left: 12px;
    margin-left: 0 !important;
    text-align: left;
  }

  /* =========================================================
     GALERIE
  ========================================================= */

  .galerie {
    gap: 14px;
    margin-top: 18px;
  }

  .galerie img {
    width: 100%;
    max-width: 420px;
    height: auto;
  }

  /* =========================================================
     HEADER GALERIE
  ========================================================= */

  .portfolio-header {
    height: 140px;
  }

  .portfolio-header .portfolio-header-title {
    font-size: 20px;
  }

  /* Bouton de la page portfolio: pas absolu sur mobile */
  .portfolio-header .contact-button {
    position: static !important;
    display: inline-block;
    margin: 12px 16px 0 16px;
    transform: none !important;
    left: auto !important;
    bottom: auto !important;
  }

  h1.portfolio {
    font-size: 34px;
  }

  h2.portfolio {
    font-size: 20px;
  }

  /* =========================================================
     LIGHTBOX
  ========================================================= */

  .lightbox {
    padding: 14px;
  }

  .lightbox .close {
    font-size: 38px;
    top: 10px;
    right: 14px;
  }

  /* =========================================================
     FOOTER
  ========================================================= */

  .site-footer {
    font-size: 11px;
    padding: 10px 14px;
  }
}
