* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Arial, Helvetica, sans-serif;
  color: #111;
  background: #bfbfbf;
}

[hidden] {
  display: none !important;
}

button,
input,
textarea,
select {
  font: inherit;
}

.login-page {
  min-height: 100vh;
  background: #bfbfbf;
}

.login-header {
  height: 170px;
  display: grid;
  place-items: center;
  background: #7d7d7b;
  border-bottom: 1px solid #444;
}

.login-header h1 {
  margin: 0;
  color: white;
  font-size: 64px;
  font-weight: 400;
}

.login-form {
  min-height: calc(100vh - 170px);
  display: grid;
  grid-template-rows: auto auto auto auto 1fr;
  align-items: start;
  justify-items: center;
  row-gap: 46px;
  padding: 55px 9vw 80px;
}

.field-row {
  display: grid;
  grid-template-columns: 185px minmax(260px, 350px);
  align-items: center;
  column-gap: 0;
}

.field-row label {
  font-size: 34px;
  text-align: right;
  padding-right: 16px;
}

.field-row input {
  width: 100%;
  height: 47px;
  padding: 7px;
  border: 1px solid #777;
  background: #f7f7f7;
  color: #111;
  font-size: 20px;
}

.field-row input::placeholder {
  color: #b8bec4;
}

.signature {
  margin: 24px 0 0;
  font-size: 10px;
}

.message {
  min-height: 22px;
  margin: 0;
  font-size: 16px;
}

.message.error {
  color: #8b1e1e;
}

.actions {
  width: 100%;
  align-self: end;
  display: flex;
  justify-content: space-between;
  gap: 32px;
}

.actions button,
.home-page button {
  min-width: 300px;
  min-height: 74px;
  border: 1px solid #777;
  background: #efefef;
  color: #111;
  font-size: 33px;
  cursor: pointer;
}

.actions button:hover,
.home-page button:hover {
  background: #ffffff;
}

.home-page {
  min-height: 100vh;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 24px;
  padding: 40px;
  background: #bfbfbf;
}

.home-page h1 {
  margin: 0;
  font-size: 60px;
  font-weight: 400;
}

.home-page p {
  margin: 0;
  font-size: 24px;
}

.tier-page {
  min-height: 100vh;
  background: #d7d9dc;
}

.app-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  padding: 20px 28px;
  background: #40444a;
  color: white;
}

.app-header h1 {
  margin: 0;
  font-size: 36px;
  font-weight: 500;
}

.header-actions,
.form-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.header-actions button,
.form-actions button {
  min-height: 42px;
  border: 1px solid #6c7077;
  background: #f4f4f4;
  color: #111;
  cursor: pointer;
}

.header-actions button {
  min-width: 140px;
}

.workspace {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 20px;
  padding: 20px;
}

.tier-board {
  display: grid;
  gap: 12px;
  min-width: 0;
}

.tier-row {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr);
  min-height: 104px;
  border: 1px solid #777;
  background: #eceff1;
}

.tier-name {
  width: 100%;
  border: 0;
  border-right: 1px solid #777;
  background: #f3c54b;
  text-align: center;
  font-size: 32px;
  font-weight: 700;
}

.tier-name:read-only {
  cursor: default;
}

.tier-songs,
.song-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(115px, 1fr));
  gap: 10px;
  align-content: start;
  padding: 10px;
  min-height: 100px;
}

.song-pool {
  border: 1px solid #777;
  background: #f3f3f3;
  padding: 12px;
}

.song-pool h2,
.detail-panel h2,
.song-form h2 {
  margin: 0 0 12px;
  font-size: 22px;
}

.song-tile {
  display: grid;
  grid-template-rows: 68px auto;
  gap: 6px;
  min-height: 118px;
  padding: 8px;
  border: 1px solid #858585;
  background: white;
  color: #111;
  cursor: pointer;
  text-align: center;
  font-size: 14px;
}

.cover {
  display: grid;
  place-items: center;
  background: #4f6d7a;
  color: white;
  font-size: 34px;
  font-weight: 700;
}

.side-panel {
  display: grid;
  gap: 16px;
  align-content: start;
}

/* Couleurs des lignes de la tierlist */
.tier-row-color-0 {
  background: #ff4d4d; /* Rouge */
}

.tier-row-color-1 {
  background: #ffa500; /* Orange */
}

.tier-row-color-2 {
  background: #ffff4d; /* Jaune */
}

.tier-row-color-3 {
  background: #90ee90; /* Vert clair */
}

.tier-row-color-4 {
  background: #4caf50; /* Vert foncé */
}

.detail-panel,
.song-form {
  border: 1px solid #777;
  background: #f6f6f6;
  padding: 16px;
}

.song-info {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 8px 10px;
  margin: 0;
  font-size: 14px;
}

.detail-title {
  margin: 0 0 12px;
  font-size: 18px;
}

.song-info dt {
  font-weight: 700;
}

.song-info dd {
  margin: 0;
  overflow-wrap: anywhere;
}

.song-form {
  display: grid;
  gap: 10px;
}

.song-form input,
.song-form textarea {
  width: 100%;
  border: 1px solid #888;
  padding: 9px;
  background: white;
}

.song-form textarea {
  min-height: 96px;
  resize: vertical;
}

.muted {
  color: #666;
}

.message.success {
  color: #dbeedd;
}

@media (max-width: 720px) {
  .login-header {
    height: 130px;
  }

  .login-header h1 {
    font-size: 48px;
  }

  .login-form {
    min-height: calc(100vh - 130px);
    row-gap: 28px;
    padding: 36px 20px 40px;
  }

  .field-row {
    width: 100%;
    grid-template-columns: 1fr;
    row-gap: 8px;
  }

  .field-row label {
    font-size: 26px;
    text-align: left;
    padding-right: 0;
  }

  .actions {
    flex-direction: column;
  }

  .actions button,
  .home-page button {
    width: 100%;
    min-width: 0;
    font-size: 28px;
  }

  .app-header,
  .workspace {
    grid-template-columns: 1fr;
  }

  .app-header {
    display: grid;
  }

  .workspace {
    padding: 12px;
  }

  .tier-row {
    grid-template-columns: 58px minmax(0, 1fr);
  }

  .tier-name {
    font-size: 24px;
  }

  .side-panel {
    order: -1;
  }
}
