/* Surcouche JSHS de SOPlanning : ce fichier n'existe pas dans SOPlanning, une mise a jour ne l'ecrase pas.
   Il est charge apres styles.css par templates/www_header.tpl (ligne ajoutee par jshs-overlay/apply.py). */

/* JSHS : jauge masquee (comme la prod) */
.jauge0 {
	display: none;
}

/* JSHS : hauteur des cases larges comme la prod (ligne vide avant le titre, deux apres) */
/* JSHS : titre centre, meme marge en haut et en bas (total identique a avant : 18px) */
.cellProject .largeCode {
	text-align: center;
	margin-top: 9px;
	margin-bottom: 9px;
}

/* JSHS : fenetre "legende des codes" ouverte par le ? de "Type de vols ou tache" (clic pour fermer) */
.jshs-legende {
	position: fixed;
	inset: 0;
	z-index: 3000;
	background: rgba(0,0,0,.65);
	overflow-y: auto;
	cursor: pointer;
	text-align: center;
}
.jshs-legende img {
	width: 90%;
	max-width: 600px;
	margin: 30px auto;
	background: #fff;
	border-radius: 6px;
	box-shadow: 0 5px 25px rgba(0,0,0,.5);
}

/* JSHS : aptitude du pilote (jshs-pilote.js, regles dans qg.jshs.fr/httpdocs/aptitudePilote.php)
   Une carte compacte par pilote, sous la ligne "Personne" ; la bordure gauche donne l'etat d'un coup d'oeil.
   Trois lignes : General (medical), Helicoptere (QT et APRS du modele), Vol (ce qu'exige le type de vol). */
.jshs-aptitude {
	display: grid;
	gap: 6px;
	margin: -4px 15px 12px;
}
.jshs-pc {
	display: grid;
	gap: 4px;
	padding: 7px 12px 8px;
	background: #fff;
	border: 4px solid #90a4ae;
	border-radius: 4px;
}
.jshs-pc-ok { border-color: #43a047; }
.jshs-pc-ko { border-color: #e53935; background: #fffafa; }
.jshs-pc-nonlie { border-color: #fb8c00; background: #fffdf8; }
.jshs-pc-tete {
	display: flex;
	align-items: baseline;
	gap: 8px;
}
.jshs-pc-nom {
	font-weight: 600;
}
.jshs-pc-etat {
	font-size: 12px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: .04em;
	color: #546e7a;
}
.jshs-pc-ok .jshs-pc-etat { color: #2e7d32; }
.jshs-pc-ko .jshs-pc-etat { color: #c62828; }
.jshs-pc-nonlie .jshs-pc-etat { color: #b26a00; }
.jshs-pc-tete a { color: #78909c; }
.jshs-pc-tete a:hover { color: #37474f; }
.jshs-pc-ligne {
	display: grid;
	grid-template-columns: 9.5em 1fr;
	align-items: center;
	gap: 8px;
	padding-top: 4px;
	border-top: 1px solid #eef1f3;
}
.jshs-pc-groupe {
	font-size: 11px;
	font-weight: 700;
	letter-spacing: .05em;
	text-transform: uppercase;
	color: #607d8b;
}
.jshs-pc-puces {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 5px;
}
.jshs-chip {
	padding: 1px 8px;
	border-radius: 4px;
	font-size: 13px;
	line-height: 1.6;
	white-space: nowrap;
}
.jshs-chip-ok { background: #e8f5e9; color: #1b5e20; }
.jshs-chip-warn { background: #fff3e0; color: #a64400; }
.jshs-chip-ko { background: #ffebee; color: #b71c1c; font-weight: 600; }
.jshs-chip-info { background: #eceff1; color: #546e7a; font-style: italic; white-space: normal; }
@media (max-width: 575px) {
	.jshs-pc-ligne { grid-template-columns: 1fr; gap: 2px; }
}
/* Personne non apte ou non reliee au QG : le champ Personne est cerne de rouge */
select.jshs-non-apte,
select.jshs-non-apte + .select2-container .select2-selection {
	border-color: #e53935 !important;
	box-shadow: 0 0 0 2px rgba(229, 57, 53, .2);
}

/* JSHS : ressource FGNBP = message "interdit en zone hostile" (jshs-pilote.js, reprise de planning.jshs.fr) */
.jshs-zh {
	display: none;
	margin-top: 6px;
	padding: 4px 10px;
	background: #f44336;
	color: #fff;
	font-weight: 500;
	text-align: center;
	text-transform: uppercase;
	border-radius: 5px;
}

/* JSHS : acces a l'application mobile SOPlanning masque (reservee aux clients avec licence, non utilisee).
   L'icone "Mobile" de la barre du haut ouvre le QR code ; il n'y a pas d'autre reglage mobile dans l'interface. */
/* (20/10) Icone « Mobile » de nouveau affichee : elle ouvre le QR code de l'appli Planning Mobile JSHS (jshs-pilote.js). */

/* Planning : icone d'avertissement sur les cases de vol dont le pilote n'est pas apte (jshs-pilote.js) */
.jshs-warn {
	position: absolute;
	top: 1px;
	right: 1px;
	width: 15px;
	height: 15px;
	border-radius: 50%;
	background: #c62828;
	color: #fff;
	font: 700 11px/15px Arial, sans-serif;
	text-align: center;
	box-shadow: 0 0 0 1.5px #fff;
	pointer-events: none;
	z-index: 6;
}

/* Telephone : la carte « Application mobile » de la page de connexion remplace ces boutons (apply_mobile.py) */
@media (max-width: 800px) { .jshs-am-nav, #jshs-appmobile, .jshs-am-flottant { display: none !important; } }
