/* ===================== */
/*      VARIABLES        */
/* ===================== */
:root {
    --nav-bg: #8a0605;
    --accent: #cb4b31;
    --hover: #ffd700;
    --body-bg: #121111;
    --form-bg: rgba(0, 0, 0, 0.9);
    --text-color: #fff;
    --font-main: Arial, sans-serif;
    --nav-font: 'Inkpoint', sans-serif;
  }
  
  /* ===================== */
  /*       BASE            */
  /* ===================== */
  body {
    background-color: var(--body-bg);
    color: var(--text-color);
    margin: 0;
    padding: 50px 0;
    font-family: var(--font-main);
  }
  
  /* ===================== */
  /*       NAVBAR          */
  /* ===================== */
  nav {
    background-color: var(--nav-bg);
    padding: 10px 0;
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-bottom: 2mm solid var(--accent);
    text-align: center;
  }
  
  nav h1 {
    font-family: var(--nav-font);
    font-size: 2em;
    margin-bottom: 10px;
  }
  
  #nav-links {
    display: flex;
    flex-direction: row;
    justify-content: center;
    gap: 20px;
    width: 100%;
  }
  
  #nav-links a,
  #nav-links button,
  .nav-logout-button {
    color: var(--text-color);
    text-decoration: none;
    font-weight: bold;
    font-size: 1.2em;
    padding: 5px 10px;
    display: block;
    margin: 0 10px;
    background: transparent;
    border: none;
    cursor: pointer;
  }
  
  #nav-links a:hover,
  #nav-links button:hover {
    color: var(--hover);
  }
  
  #nav-links a.active {
    color: var(--hover);
  }
  
  /* ===================== */
  /*      CONTENUS         */
  /* ===================== */
  .stage {
    margin-top: 100px;
  }
  
  .affiche-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    position: relative;
    z-index: 10;
    margin-bottom: 200px;
  }
  
  .affiche {
    margin-top: 100px;
    width: 400px;
    height: auto;
    max-width: 100%;
  }
  
  .bordure {
    width: 5px;
    height: 250px;
    background-color: var(--accent);
  }
  
  .texte-a-droite {
    max-width: 300px;
    font-size: 1.2em;
    text-align: left;
  }
  
  /* ===================== */
  /*   BOUTONS EDIT / CANCEL */
  /* ===================== */
  .edit-button,
  .cancel-button {
    padding: 8px 12px;
    background-color: var(--accent);
    color: var(--text-color);
    font-weight: bold;
    font-size: 1em;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    text-align: center;
    margin: 5px;
    position: relative;
    z-index: 1000;
    transition: background-color 0.3s ease;
    pointer-events: auto;
  }
  
  .edit-button:hover,
  .cancel-button:hover {
    background-color: var(--hover);
  }
  
  /* ===================== */
  /*       RIDEAUX         */
  /* ===================== */
  .gauche,
  .droite {
    position: fixed;
    top: 0;
    width: clamp(10%, 20vw, 20%);
    height: 100vh;
    z-index: 1000;
    transition: transform 0.5s ease;
    pointer-events: none;
  }
  
  .gauche { left: 0; }
  .droite  { right: 0; }
  
  /* ===================== */
  /*    RESPONSIVE         */
  /* ===================== */
@media (max-width: 768px) {
  #CmdMenu { display:block; position:absolute; top:12px; left:12px; font-size:28px; cursor:pointer; }

  /* on n'utilise PAS display:none pour pouvoir animer */
  #nav-links {
    position: fixed; top:62px; left:0; right:0;
    background: var(--nav-bg);
    flex-direction: column; gap:12px; border-bottom:2px solid var(--accent);
    z-index:3000; padding:0 16px;

    display:flex; max-height:0; overflow:hidden; opacity:0;
    transition: max-height .35s ease, opacity .25s ease, padding .25s ease;
  }
  #nav-links[data-open="1"] { max-height:60vh; opacity:1; padding-top:12px; padding-bottom:12px; }
}
@media (min-width: 769px) {
  #CmdMenu { display:none; }
  #nav-links { display:flex; position:static; max-height:none; opacity:1; padding:0; gap:20px; border:0; }
}


  
  /* ===================== */
  /*  FORMULAIRES (édition)  */
  /* ===================== */
  /* Pour le formulaire d'édition (image/texte) */
  .edit-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin: 20px 0;
    padding: 15px;
    background-color: #1a1a1a;
    border: 1px solid var(--accent);
    border-radius: 5px;
  }
  
  .edit-form form label,
  .edit-form form input,
  .edit-form form textarea,
  .edit-form form button {
    display: block;
    width: 100%;
    margin-bottom: 10px;
  }
  
  .edit-form form input,
  .edit-form form textarea {
    padding: 8px;
    border: 1px solid var(--accent);
    border-radius: 4px;
    background-color: var(--body-bg);
    color: var(--text-color);
  }
  
  /* ===================== */
  /*  FORMULAIRES (modaux)   */
  /* ===================== */
  /* Style commun aux formulaires d'ajout d'acteur ou de pièce */
  .form-container {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: var(--form-bg);
    padding: 20px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    border-radius: 10px;
    max-width: 500px;
    width: 90%;
    z-index: 5000;
    backdrop-filter: blur(5px);
  }
  
  .form-container::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.6);
    z-index: -1;
  }
  
  .form-container h2 {
    text-align: center;
    font-size: 22px;
    margin-bottom: 15px;
  }
  
  .form-container label {
    font-weight: bold;
    margin-top: 10px;
    display: block;
  }
  
  .form-container input,
  .form-container textarea,
  .form-container select {
    width: 100%;
    padding: 10px;
    margin-top: 5px;
    border: 1px solid var(--accent);
    border-radius: 5px;
    font-size: 16px;
    background-color: #1a1a1a;
    color: var(--text-color);
  }
  
  .form-container button {
    width: 100%;
    padding: 10px;
    margin-top: 15px;
    font-size: 18px;
    background: var(--accent);
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: 0.3s;
    font-weight: bold;
    color: var(--text-color);
  }
  
  .form-container button:hover {
    background: var(--hover);
    color: black;
  }
  
  /* Bouton "Annuler" spécifique */
  #cancel-add-actor,
  #cancel-add-play {
    background: #8a0605;
  }
  
  #cancel-add-actor:hover,
  #cancel-add-play:hover {
    background: #b52b27;
  }
  
  @media (max-width: 600px) {
    .form-container { width: 95%; }
  }
  
  /* ===================== */
  /*   Divers                */
  /* ===================== */
  .center-btn-container {
    text-align: center;
    margin: 20px 0;
  }
  /* Aligne l'image et la bordure au centre l'une de l'autre */
.affiche { margin-top: 0 !important; }  /* on enlève le décalage de l'image */
