/**
 * override and customize some control panel special cases for Publications
 */

 .statut {
  box-sizing: border-box;
  display: inline-block;
  margin-left: 1ch;
  margin-right: 1ch;
  line-height: 20px;

  width:  8px;
  height: 8px;
  border-radius: 100%;
  border: 1px solid transparent;
}
.statut--nouveau   { background-color: #CCC; }
.statut--edite     { background-color: #FABB00; }
.statut--revise    { background-color: #2EAAB8; }
.statut--approuve  { background-color: #73B62F; }
.statut--rejete    { background-color: red; }

.tableview .statut {
  margin-left: 0;
  margin-right: .25em;
}

/* Statut global : rendu natif des radio-group de Craft 5.10 (liste verticale,
   pastille de couleur par option). L'ancien hack float/marge datait du DOM de
   Craft 3 et créait un faux décalage parent/enfant en 5.10.
   Seul ajout : un peu d'air entre les instructions et les options. */
#fields-statutGlobal-field .instructions {
 margin-bottom: 10px;
}

/* cp layout hack */
#tab-flux-éditorial > .field:nth-child(n+2):nth-child(-n+7) {
  float: left;
  margin-top: 0;
  margin-right: 12px;
  min-width: 72px;
  width: auto;
}

#tab-flux-éditorial > :not([id^="fields-statut"]) {
  clear: both;
}

#tab-flux-éditorial .select:not(.selectize) select {
  width: 7ch;
}

#fields-typesPublication-field {
  padding-top: 24px;
  border-top: 1px solid rgba(0, 0, 20, 0.1);
}

.superTableAddRow.disabled {
  display: none;
}

/* publications tableview overrides */
.tableview [data-title] {
  z-index: 1;
}

.tableview [data-title]:empty:after {
  opacity: .2;
}

.tableview [data-title="FLA"]:after,
.tableview [data-title="WEB"]:after,
.tableview [data-title="GE"]:after,
.tableview [data-title="PRT"]:after,
.tableview [data-title="TV"]:after,
.tableview [data-title="FB"]:after {
  display: block;
  padding: 0 0 0 14px;
  position: absolute;
  z-index: -1;
  top: 50%;
  left: 0;
  right: 0;
  transform: translateY(-50%);
  font-size: 10px;
  line-height: 1;
  opacity: 0;
}

.tableview [data-title="FLA"]:after {
  content: "FLA";
}
.tableview [data-title="WEB"]:after {
  content: "WEB";
}
.tableview [data-title="GE"]:after {
  content: "GE";
}
.tableview [data-title="PRT"]:after {
  content: "PRT";
}
.tableview [data-title="TV"]:after {
  content: "TV";
}
.tableview [data-title="FB"]:after {
  content: "FB";
}
/* end tableview overrides */

/* hide buttons on user submitted assets */
#fields-photosRecues-field .add,
#fields-photosRecues-field .delete {
  display: none !important;
}

/* overrides entry instructions defaults */
[data-type*="entryinstructions"] .instructions {
  min-height: 0 !important;
}

#fields-flashNouvelleALaUnePlage1Debut-field,
#fields-flashNouvelleEnVedettePlage1Debut-field,
#fields-flashActiviteASurveillerPlage1Debut-field,
#fields-noteInterne-field
{
  padding-top: 24px;
  border-top: 1px solid rgba(0, 0, 20, 0.1);
}

#content #fields-flashNouvelleALaUnePlage1Debut-field,
#content #fields-flashNouvelleALaUnePlage2Debut-field,
#content #fields-flashNouvelleEnVedettePlage1Debut-field,
#content #fields-flashNouvelleEnVedettePlage2Debut-field,
#content #fields-flashActiviteASurveillerPlage1Debut-field,
#content #fields-flashActiviteASurveillerPlage2Debut-field
{
  margin-bottom: .25rem !important;
}
#fields-flashNouvelleALaUnePlage1Fin-field > .heading,
#fields-flashNouvelleALaUnePlage2Fin-field > .heading,
#fields-flashNouvelleEnVedettePlage1Fin-field > .heading,
#fields-flashNouvelleEnVedettePlage2Fin-field > .heading,
#fields-flashActiviteASurveillerPlage1Fin-field > .heading,
#fields-flashActiviteASurveillerPlage2Fin-field > .heading
{
  display: none;
}
#fields-flashNouvelleALaUnePlage1Debut-field .input::before,
#fields-flashNouvelleALaUnePlage2Debut-field .input::before,
#fields-flashNouvelleEnVedettePlage1Debut-field .input::before,
#fields-flashNouvelleEnVedettePlage2Debut-field .input::before,
#fields-flashActiviteASurveillerPlage1Debut-field .input::before,
#fields-flashActiviteASurveillerPlage2Debut-field .input::before
{
  content: 'Du';
  display: inline-block;
  width: 1.75rem;
}
#fields-flashNouvelleALaUnePlage1Fin-field .input::before,
#fields-flashNouvelleALaUnePlage2Fin-field .input::before,
#fields-flashNouvelleEnVedettePlage1Fin-field .input::before,
#fields-flashNouvelleEnVedettePlage2Fin-field .input::before,
#fields-flashActiviteASurveillerPlage1Fin-field .input::before,
#fields-flashActiviteASurveillerPlage2Fin-field .input::before
{
  content: 'Au';
  display: inline-block;
  width: 1.75rem;
}

[id*="fields-nouvelle1Publication-field"],
[id*="fields-nouvelle2Publication-field"],
[id*="fields-nouvelle1Titre-field"],
[id*="fields-nouvelle2Titre-field"] {
  padding-top: 15px;
  border-top: 3px double rgba(0, 0, 20, 0.1);
}
