@font-face {
  font-family: 'CN font';
  src: url(./fonts/CN-Sans/CN\ Sans.otf) format(otf),
    url(./fonts/CN-Sans/CN\ Sans.ttf) format(ttf);
  font-weight: 400;
}

@font-face {
  font-family: 'MillerDisplay';
  src: url(./fonts/Miller/Miller.otf) format(otf);
}
*,
*::after,
*::before {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  list-style: none;
  color: inherit;
  text-decoration: none;
  outline: none;
  border: none;
  line-height: inherit;
  color: inherit;
}

:root {
  font-size: 62.5%;
  --white-color: rgba(140, 139, 139, 0.2);
  --text-color: white;
  --black-color: rgb(20, 20, 20);
  --accent-color: red;
  --title-text-size: 3rem;
  --body-font-family: 'MillerDisplay', sans-serif;
  --font1: 'MillerDisplay', sans-serif;
  --font2: 'CN font', sans-serif;
  --body-font-weight: 300;
  --body-font-style: normal;

  /* nav */
  --nav-text-size: 1.2rem;
  --gap-size: 3rem;
  --padding-inline: 2rem;
}

html {
  line-height: 1.15;
  letter-spacing: 0.1em;
}

.container {
  max-width: 1300px;
  padding-inline: 2rem;
  margin: 0 auto;
}

section {
  margin: 2rem 0 2.5rem;
  padding-top: 3rem;
  padding-inline: 2rem;
}

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

/* Titre de section  */

.title {
  text-align: center;
  color: black;
  font-size: var(--title-text-size);
  text-transform: uppercase;
  line-height: 3;
  margin-bottom: 3rem;
  font-weight: 800;
  position: relative;
}

.title::after {
  display: block;
  content: '';
  position: absolute;
  background-color: var(--black-color);
  z-index: 100;
  bottom: 0;
  height: 5px;
  width: 10rem;
  left: 50%;
  transform: translateX(-50%);
}

/* Fin de titre de section */

/* les Boutons call to action */

.cta {
  background-color: rgb(3, 3, 119);
  padding: 1rem 2rem;
  border-radius: 15px;
  margin-top: 1.5rem;
  display: inline-block;
  color: white;
  font-weight: 400;
  transition: all 0.5s ease;
  border: 5px solid transparent;

  &:hover {
    background-color: white;
    color: rgb(3, 3, 119);
    border-color: rgb(3, 3, 119);
  }

  @media screen and (max-width: 768px) {
    & {
      font-size: 10px;
    }
  }
}

/* fin des boutons call to action */

body {
  background-color: var(--white-color);
  color: var(--text-color);
  font-family: var(--font1);
  font-style: normal;
  font-size: 1.7rem;
  line-height: inherit;
}

header {
  background-image: url(./images/banniere.png);
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  background-clip: border-box;

  .text__container {
    min-height: 100vh;
    height: 100vh;
    position: relative;
    background-image: linear-gradient(to bottom, transparent, 80%, black);

    nav {
      --font-size: 1.4rem;
      text-transform: uppercase;
      font-family: var(--font2);
      padding-top: 30px;
      display: flex;
      align-items: baseline;
      height: 80px;
      font-size: var(--font-size);
      position: sticky;
      top: 0;
      background-color: rgba(30, 7, 7, 0.5);
      backdrop-filter: blur(30px);
      border-radius: 10px;
      z-index: 100;

      a {
        margin-right: auto;
        letter-spacing: initial;

        img {
          vertical-align: middle;
        }
      }

      ul {
        display: flex;
        align-items: center;
        gap: 2rem;

        .close {
          display: none;
        }
      }

      .icons {
        margin-left: auto;
        display: flex;
        align-items: baseline;

        #bars {
          display: none;
        }
      }
    }

    .text {
      --font-size: 4rem;
      position: absolute;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -50%);
      font-size: var(--font-size);
      text-align: center;
      font-weight: 800;
      text-transform: uppercase;
      color: rgba(240, 222, 222, 0.809);
    }
  }
}

header.header {
  position: relative;
  background: none;

  video {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 100%;
    object-fit: cover;
  }
}

.featured__mag {
  .mag {
    display: flex;
    align-items: center;
    justify-content: space-around;
    gap: 2rem;

    .mag_img {
      flex: 1 1 50%;
    }

    .mag_img {
      flex: 1 1 50%;
      display: flex;
      justify-content: center;
      align-items: center;
      flex-direction: column;

      img {
        object-fit: cover;
      }

      .boutton {
        background-color: black;
        align-self: center;
        text-align: center;
        margin-top: 30px;
        padding: 10px 20px;
        text-transform: uppercase;
        border-radius: 10px;
      }
    }

    .mag_text {
      flex: 1 1 50%;
      align-self: flex-start;
      font-size: var(--nav-text-size);
      color: var(--black-color);
      padding-inline: 2rem;
      padding-block: 2rem;

      .mag__title {
        font-size: 5rem;
        text-align: center;
        margin-block-end: 3rem;
        font-style: italic;

        span {
          color: var(--accent-color);
        }
      }

      .mag__desc {
        line-height: 2;
        letter-spacing: 0.1em;
        word-spacing: 2px;
        font-size: 1.7rem;
        text-align: justify;
        hyphens: auto;
      }
    }
  }
}

.actualites {
  .posts__container {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2.5rem;

    .post {
      box-shadow: 0px 1px 7px -1px var(--black-color);
      border-radius: 15px;
      position: relative;
      overflow: hidden;
      min-height: 400px;
      transition: transform 0.5s ease-in;

      h4 {
        color: white;
        position: absolute;
        bottom: 10px;
        padding-inline: 1.5rem;
        display: -webkit-box;
        -webkit-line-clamp: 3;
        -webkit-box-orient: vertical;
        overflow: hidden;
      }

      h4::after {
        content: '.';
      }

      img {
        position: absolute;
        object-fit: cover;
        top: 0;
        height: 100%;
        width: 100%;
        left: 0;
        border-radius: inherit;
        z-index: -1;
      }

      .overlay {
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: linear-gradient(to bottom, transparent 50%, black);
      }

      a {
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
      }
      .badge {
        position: absolute;
        right: 10px;
        top: 10px;
        color: white;
        display: flex;
        align-items: center;
        justify-content: center;
      }
    }

    .post:hover {
      transform: translateY(-10px);
    }
  }
}

.mian__tv {
  .sub__title {
    color: black;
    font-size: 5rem;
    text-transform: capitalize;
    margin-bottom: 3rem;
    font-weight: bolder;
  }

  .description {
    color: black;
    margin-bottom: 5rem;
  }
  .videos {
    display: flex;
    gap: 1rem;

    .large {
      align-items: stretch;
      display: flex;
      justify-content: center;
      align-items: center;
      flex: 1 1 60%;
    }

    .others {
      display: flex;
      flex-direction: column;
      flex: 1 1 40%;
      gap: 20px;
      div {
        display: flex;
        align-items: center;
        justify-content: space-around;
        gap: 30px;

        img {
          cursor: pointer;
          width: 200px;
          flex: 1 1 50%;
        }

        p {
          flex: 1 1 50%;
          color: black;
          font-weight: 600;
          line-height: 2;
        }
      }
    }
  }

  .more {
    text-align: right;
    margin-top: 2rem;
    color: black;
    font-weight: 600;
  }
}

.nos_marques {
  .marques {
    display: flex;
    flex-direction: column;

    img {
      width: 400px;
    }

    .haut {
      display: flex;
      align-items: center;
      justify-content: center;

      a {
      }
    }

    .bas {
      display: flex;
      align-items: center;
      justify-content: center;

      a {
      }
    }
  }

  .description {
    text-align: center;
    color: black;
    margin-block: 1rem;
    width: fit-content(20rem);
    letter-spacing: 0.5rem;
    font-weight: 400;
  }
}

.podcast {
  .content {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    color: black;

    .img {
      border-radius: 15px;

      img {
        border-radius: inherit;
      }
    }

    .text {
      display: flex;
      align-items: center;
      justify-content: space-evenly;
      flex-direction: column;

      p {
        line-height: 2;
        font-weight: 300;
      }

      .cta {
        margin-bottom: 2rem;
      }
    }
  }
}

.publishing,
.agency {
  .content {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    align-items: center;
    gap: 2rem;
    grid-template-areas: 'logo text';
    color: black;

    .logo {
      grid-template-areas: logo;
      grid-area: logo;

      img {
        border-radius: 15px;
        box-shadow: 0px 0px 5px 0px black;
      }
    }

    &.reversed {
      grid-template-areas: 'text logo';
    }

    .text {
      grid-area: text;

      div {
        line-height: 2;
        margin-block: 1rem;
        text-align: justify;
        hyphens: auto;

        .list {
          div {
            display: flex;
            gap: 10px;
          }
        }

        p {
          line-height: inherit;
          margin-block: inherit;
          margin-block: inherit;
        }
      }
    }
  }
}

footer {
  background-color: black;
  padding-block: 2rem;
  .columns {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(30rem, 1fr));
    color: white;
    justify-items: start;

    .column {
      .column__title {
        text-transform: capitalize;
        margin: 1.5rem 0 2rem;
        text-align: left;
      }

      ul {
        li {
          margin-bottom: 1rem;
          text-transform: capitalize;
          cursor: pointer;
          border-bottom: 2px solid var(--white-color);
          padding-bottom: 2rem;
          a {
            text-transform: none;

            &:hover {
              opacity: 0.5;
            }
          }

          span {
            font-weight: 800;
          }
        }
      }

      .socials {
        display: flex;
        align-items: center;
        gap: 1rem;
        border-bottom: none;

        a {
          transition: transform 0.5s ease;
          opacity: 1;
        }
      }
    }
  }
}

.partenariat {
  .content {
    position: relative;

    img {
      border-radius: 15px;
    }

    .cta {
      position: absolute;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -100%);

      @media screen and (max-width: 425px) {
        & {
          text-align: center;
        }
      }
    }
  }
}

/* Media queries */

@media screen and (max-width: 1200px) {
  header {
    .text__container {
      nav {
        backdrop-filter: initial;

        ul {
          flex-direction: column;
          justify-content: space-around;
          position: fixed;
          background-color: black;
          left: 0;
          top: 0;
          width: 100%;
          height: 100%;
          z-index: 200;
          padding-block: 20px;
          transition: transform 0.5s ease-in;
          transform: translateY(-300%);

          &.down {
            transform: translateY(00%);
          }

          .close {
            display: block;
            position: absolute;
            top: 20px;
            right: 20px;
          }
        }

        .icons {
          #bars {
            display: block;
          }
        }
      }
    }
  }
}

@media screen and (max-width: 1024px) {
  :root {
    font-size: 60%;

    /* nav */
    --nav-text-size: 1.1rem;
    --gap-size: 1.4rem;
    --padding-inline: 2rem;
  }

  header {
    .text__container {
      .text {
        --font-size: 3rem;
      }
    }
  }
}

@media screen and (max-width: 768px) {
  :root {
    font-size: 55%;
  }

  .container {
    padding-inline: 3rem;
  }

  header {
    .text__container {
      .text {
        --font-size: 2.5rem;
        line-height: 2;
      }
    }
  }

  .featured__mag {
    .mag {
      .mag_text {
        .mag__title {
          text-align: left;
        }
      }
    }
  }
  .actualites {
    .posts__container {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
      gap: 2rem;
    }
  }

  .mian__tv {
    .sub__title {
      text-align: center;
    }
    .videos {
      flex-direction: column;
      .others {
        div {
          gap: 15px;
        }
      }
    }
  }

  .podcast {
    .content {
      grid-template-columns: 1fr;

      .text {
        text-align: center;
      }
    }
  }

  .agency,
  .publishing {
    .content {
      grid-template-areas:
        'text text'
        'logo logo';

      .text {
        text-align: center;
      }

      &.reversed {
        grid-template-areas:
          'logo logo'
          'text text';
      }

      .logo {
        display: flex;
        align-items: center;
        justify-content: center;
        img {
          width: 500px;
          height: auto;
        }
      }
    }
  }

  footer {
    .columns {
      justify-items: initial;
      padding-inline: 3rem;
    }
  }
}

@media screen and (max-width: 425px) {
  :root {
    font-size: 50%;
    --title-text-size: 1.5rem;
  }

  header {
    .text__container {
      .text {
        --font-size: 2rem;
      }
    }
  }
  .featured__mag {
    .mag {
      flex-direction: column;

      .mag_text {
        .mag__title {
          text-align: center;
        }
        .mag__desc {
          text-align: center;
        }
      }
    }
  }

  .mian__tv {
    .sub__title {
      text-align: center;
      font-size: 3rem;
      text-transform: uppercase;
    }

    .videos {
      .others {
        div {
          p {
            line-height: 1.5;
            font-size: 2rem;
            white-space: pre-wrap;
            -webkit-hyphens: auto;
            hyphens: auto;
          }
        }
      }
    }
  }

  footer {
    .columns {
      .column {
        text-align: center;

        .column__title {
          text-align: inherit;
        }

        &:last-of-type {
          text-align: left;

          .column__title {
            text-align: center;
          }
        }
      }
    }
  }
}

@media screen and (max-width: 320px) {
  header {
    .text {
      font-size: 1.7rem;
      padding-inline: 2rem;
    }
  }
  section {
    padding-inline: 1rem;
  }

  .featured__mag {
    .mag {
      .mag_text {
        .mag__title {
          font-size: 4rem;
          text-align: center;
          margin-block-end: 3rem;
          font-style: italic;
        }

        .mag__desc {
          text-align: center;
        }
      }
    }
  }

  .mian__tv {
    .videos {
      gap: 3rem;
      .others {
        div {
          flex-direction: column;
          margin-block: 1rem;
          align-items: center;
          gap: 1rem;

          p {
            text-align: left;
            margin-inline: auto;
            line-height: 1;
            white-space: wrap;
          }

          img {
            width: auto;
          }
        }
      }
    }
  }
}
