/* ============ RESET ============ */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

/* ============ BODY ============ */
body {
  font-family: Arial, sans-serif;
  background-color: #000;
  color: #ddd;
  line-height: 1.6;
  overflow-x: hidden; /* empêche les débordements sur mobile */
}

/* ============ NAVBAR ============ */
header {
  background: #111;
  color: white;
  position: sticky;
  top: 0;
  z-index: 100;
}

.menu {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1100px;
  margin: 0 auto;
  padding: 15px 20px;
}

.menu-logo {
  font-size: 1.5em;
  font-weight: bold;
  color: #fff;
}

.menu-links {
  list-style: none;
  display: flex;
  gap: 20px;
}

.menu-links a {
  text-decoration: none;
  color: #fff;
  font-weight: 500;
  transition: color 0.3s;
}

.menu-links a:hover {
  text-decoration: underline;
}

.menu-toggle {
  display: none;
  font-size: 1.8em;
  background: none;
  border: none;
  color: white;
  cursor: pointer;
}

/* ============ IMAGE DE FOND ============ */
.image-1 {
  background: 
    linear-gradient(to bottom, rgba(0,0,0,0) 60%, #000 100%),
    url('1.jpg') no-repeat top center / cover;
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  z-index: -1;
  opacity: 0.6;
}

/* ============ SECTIONS ============ */
.section {
  max-width: 1100px;
  margin: 60px auto;
  padding: 0 20px;
  text-align: left;
}

.section h1,
.section h2 {
  margin-bottom: 15px;
  color: #fff;
}

.section p {
  font-size: 1.1em;
  color: #ccc;
}

/* ============ BOUTON ============ */
.button1 {
  padding: 12.5px 30px;
  border: 0;
  border-radius: 100px;
  background-color: #fff;
  color: #000;
  font-weight: bold;
  transition: all 0.5s;
  display: inline-block;
  margin-top: 20px;
  margin-left: 0;
  cursor: pointer;
}

.button1:hover {
  box-shadow: 0 0 20px #6fc5ff50;
  transform: scale(1.1);
}

.button1:active {
  box-shadow: none;
  transform: scale(0.98);
  transition: all 0.25s;
}

/* ============ BLOC CODE ============ */
pre {
  background-color: #2d2d2d;
  color: #f8f8f2;
  font-family: 'Courier New', monospace;
  padding: 10px 15px;
  border-radius: 10px;
  border: 1px solid #444;
  white-space: pre;          
  display: inline-block;     /* s'adapte au contenu */
  box-shadow: 0 4px 15px rgba(0,0,0,0.4);
  width: fit-content;        /* s'adapte vraiment au texte */
  max-width: 100%;           /* mais ne dépasse pas l'écran */
  overflow-x: auto;          /* permet de scroller si c’est trop long */
}

code {
  font-size: 0.95em;
}

/* ============ FOOTER ============ */
footer {
  background: #111;
  color: #888;
  text-align: center;
  padding: 20px 0;
  margin-top: 40px;
  font-size: 0.9em;
  border-top: 1px solid #333;
}

/* ============ RESPONSIVE ============ */
@media (max-width: 768px) {
  .menu-links {
    display: none;
    flex-direction: column;
    background: #222;
    position: absolute;
    top: 65px;
    right: 20px;
    width: 200px;
    padding: 15px;
    border-radius: 5px;
    transition: all 0.3s ease;
  }

  .menu-links.active {
    display: flex;
  }

  .menu-toggle {
    display: block;
  }

  .section {
    margin: 40px auto;
    padding: 0 15px;
  }

  .section h1 {
    font-size: 1.6em;
  }

  .section p {
    font-size: 1em;
  }

  .button1 {
    width: 100%;
    text-align: center;
  }

  pre {
    font-size: 0.9em;
    padding: 8px 10px;
  }
}
