/* ---------------------------------------------------------------------
   0. Global box-sizing pour tout le chat ----------------------------- */
#ajaxchat *, 
#ajaxchat *::before, 
#ajaxchat *::after {
    box-sizing: border-box;
}

/* ---------------------------------------------------------------------
   1. Indicateurs d'activité (icônes animées) -------------------------- */
#act_indicator {  /* GIF animé affiché durant une action Ajax */
	visibility:hidden;
	vertical-align:text-bottom;
	margin-left: -18px;
	cursor: wait; /* curseur "sablier" */
}

#check_indicator{  /* GIF statique indiquant la version */
	vertical-align:text-bottom;
	margin-right: -2px;
	margin-bottom: 2px;
	cursor: help;  /* curseur "?" pour l’info-bulle */
}

/* ---------------------------------------------------------------------
   2. Palette de couleurs & sélecteur "BBCodes" ----------------------- */
.select_color { /* C’est un conteneur du nuancier. */
	margin: 0 auto;
}

#bbpalette { /* conteneur du nuancier rapide */
	display: inline;
}

#fc { /* petit carré couleur courante */
	margin: 0 auto;
	height: 20px;
	width: 20px;
	border-style:solid;
	border-width:1px; /* cadre fin autour du carré */
}

#chat_colour_palette { /* tableau complet des teintes */
	text-align: center;
	padding-bottom: 5px;
}

#chat_colour_palette table {
	margin: 0 auto;
}

/* ---------------------------------------------------------------------
   3.  Zones d’entête / règles / barre nav ----------------------------- */
/* Les blocs « Règles » et le petit titre du chat. */
.chat_rules {
	padding: 2px 6px 4px;
	font-size: 1.1em;
}

.chat-rules-center {
	width: 100%;
	margin-left: -5px;
	text-align: center;
}

.span_chat_rule {
	font-weight: bold;
	font-size: 1.1em;
	color: #AA0000;
}

.chat-header-link {
	text-align: center;
}

#ajaxchat .navbar.chatrules { /* barre contenant les règles du chat */
	margin: 0 5px 3px 5px;
	border-radius: 0 0 7px 7px;
}

#ajaxchat .navbar.chatrules ul {
	list-style-type: none !important;
}

#ajaxchat .navbar.chatrules ol, ul { /* listes à puces à l’intérieur */
	margin-left: 5px;
	list-style-position: inside;
}

/* ---------------------------------------------------------------------
   4.  Conteneurs principaux ------------------------------------------- */
.main { /* Wrapper vertical des messages (scroll). */
	height: 400px;
	overflow: auto;
}

#ajaxchat .forabg { /* boîtier bleu (hérite du style forum) */
	margin-bottom: 0;
}

#chat {  /* wrapper des messages et de l’entête */
	width: 100%;
}

#chat-header {
	width: 100%;
}

/* ---------------------------------------------------------------------
   5.  Section "Qui est en train de chatter" --------------------------- */
#whois_online {  /* liste des connectés */
	text-align: left;
	margin-left: 10px;
}

.whois {
    float: right;              /* plaque le volet à droite */
    width: 15.5%;              /* ajusté pour 100% total */
    /* height: 250px; */             /* même hauteur que les messages */
    /* overflow-y: auto;    */      
    /* overflow-x: hidden; */
    /* box-sizing: border-box; */
    text-align: center;
}

.whois_online {  /* liste interne */
	display: block;
	width: 90%;
	text-align: left;
	margin: 6px auto;
}

.whois h3 { /* titre "Qui est…" */
	margin: 2px 0;
}

.whois_online_off { /* masqué si option désactivée */
	visibility: hidden;
	position: fixed; /* retire du flux pour éviter le blanc */
}

/* ---------------------------------------------------------------------
   6.  Fenêtre de messages (shouts) ------------------------------------ */
.shout-body,
.shouts {
    float: left;               /* plaque la zone à gauche */
    width: 83%;                /* largeur un peu augmentée */
    /* height: 250px;  */           /* hauteur fixe pour forcer le scroll */
    /* overflow-y: auto !important; */
    /* overflow-x: hidden !important; */
    /* box-sizing: border-box; */

    /* Décalage vertical léger sous la barre de saisie */
    margin-top: 3px;
    /* Garde 0.5% d’air sur les côtés pour la scrollbar et whois */
    margin-left: 0.5%;
    margin-right: 0.5%;

    /* Espace interne pour ne pas coller les lignes à la scrollbar */
    padding-right: 2px;
}

.chat_online_off { /* même que .shouts quand offline */
	float: none;      /* enlève le float */
    width: 100%;      /* prend toute la largeur disponible */
    margin: 3px 0 0 0;/* même décalage vertical que .shout-body */
    padding-right: 2px;
}

.archive {  /* mode « Archive » pleine largeur */
	float: left;
	width: 100%;
	overflow: auto !important;
	/* overflow-x: hidden !important; */
}

/* ---------------------------------------------------------------------
   7.Post (ligne de chat) ------------------------------------------- */
.chatpost { /* wrapper graphique d’un message */
	padding: 0 0 2px 5px;
	margin-bottom: 0;
	background-repeat: no-repeat;
	background-position: 100% 0;
	position: relative;
	border-radius: 4px;
	/*border-right: #CCCCCC 1px solid;
	border-bottom: #CCCCCC 1px solid;
	border-left: #CCCCCC 1px solid; */
	border:1px solid #CCC; /* contour 3 côtés */
}

.message { /* paragraphe texte du message */
	line-height: 1.4em;
	font-size: 1.2em;
	padding-top: 2px;
	overflow: auto;
}

.chat-time { /* horodatage après le pseudo */
	font-size: 0.9em;
}
  
.chat-usernames {
	padding-top: 5px;
}

/* Tout ce qui affecte la zone message elle-même (texte, icônes, citations, édition). */
.chat-postbody {
	padding: 0;
	line-height: 1em;
	width: 100%;
	clear: both;
	min-height: 20px;
}

.chat dd {
	border: none !important;
}

.chat-postbody .content {
	font-size: 1.3em;
}

.chat-postbody ul.profile-icons {
	float: right;
	width: auto;
	padding: 0;
}

.chat-postbody ul.profile-icons li {
	margin: 0 3px;
}

.chat-postbody .message blockquote, .chat-postbody .codebox {
	margin-right: 30px;
	margin-bottom: 4px;
	width: 80%;
}

.chat_edit textarea.inputbox {
	width: 99%;
}

/* 	Colonne profil + icône statut. */
.chat-postprofile {
	margin-right: 32px;
	display: inline-block;
	float: left;
	white-space: nowrap;
}

.chat-postprofile-no-avatar {
	margin-right: 4px;
	display: inline-block;
	float: left;
	white-space: nowrap;
}

.status_img {
	vertical-align: middle;
}

/*BBCodes*/
#ajaxchat .message ul, #ajaxchat .message ol {
	margin: 0.8em 0 0.9em 3em;
}

.chat-postbody .message blockquote {
	width: calc(100% - 65px);
}

/* ---------------------------------------------------------------------
   8.  Avatars ---------------------------------------------------------- */
.chat-avatars { /* petit avatar à gauche du message */
	float: left;
	max-width: 20px;
	position: relative;
	margin-right: 10px;
	outline: none;
	z-index: 0;
	padding: 1px 0px 1px 0px;
}

.chat-avatars > img { /* img réelle limitée */
	width: auto !important;
	height: auto !important;
	max-width: 25px;
	max-height: 20px;
}
/* tooltip avatar XL quand hover */
div.chat-avatars:hover span {
	position:absolute;
	display:block;
	top: -4px;
	left: 40px;
	padding: 2px 2px 0;
	background: transparent;
	width: 300px;
}

div.chat-avatars:hover {
	background-color: transparent;
	z-index: 50;
}

.chat-avatars span {
	position: absolute;
	left: 0px;
	display: none;
	text-decoration: none;
}

.chat-avatars span img {
	border-width: 0;
	height: auto;
}

/* ---------------------------------------------------------------------
   9.  Zone d’entrée + barre d’outils ---------------------------------- */
.chatform { /* ligne boutons + infos */
	width: 100% !important;
	text-align: center;
	padding: 2px;
}

.chatinput { /* champ texte principal */
	width: 60% !important;
	margin-bottom: 4px;
}

.chatnavbar { /* barre de navigation sous les msgs */
	margin: 6px 0 4px 0;
	padding: 5px 10px 8px 10px;
	text-align: center;
}

.input_message {
	padding: 10px;
}

/* ---------------------------------------------------------------------
   10. Boutons / icônes ------------------------------------------------- */
.chat-icon { /* icône "bulle" avant le titre */
	background-position: 0 50%;
	background-repeat: no-repeat;
	background-image: url("./images/icon_chat.png");
	padding: 6px 0 6px 21px;
}

.chat-icon-link { /* petit bouton lien */
	background-image: url("./images/icon_chat.png");
	padding-left: 4px;
}

.chat .button {
	padding: 0 8px;
	height: auto;
	margin-bottom: 3px;
}

.chat a:hover {
	text-decoration: none !important;
}

.font_cookie_delete {
	margin: 2px auto 0 auto !important;
	width: 90px;
}

.details {
	color: #AA0000;
}

/* ---------------------------------------------------------------------
   11. Effets divers ---------------------------------------------------- */
.chat li.row:hover { /* neutralise le survol forum */
	background-color: transparent !important;
}

.chat_sound { /* balise audio cachée */
	visibility: hidden;
	position: absolute;
}

/* ---------------------------------------------------------------------
   12. Compatibilité avec ABBC3 (extension BBCode) ---------------------- */
/* ABBC3 Compatibility */

#ajaxchat .abbc3_buttons_row {
	width: inherit !important;
}

#ajaxchat #abbc3_buttons {
	margin-top: 0 !important;
}

#ajaxchat #color_palette_placeholder {
	width: 100%;
	margin: 0 auto;
}

#ajaxchat #color_palette_placeholder table {
	width: 100%;
	margin: 0 auto;
}

#chat_bbcodes #bbcode_wizard {
	position: inherit;
}

#chat ul.topiclist dt {
	width: auto;
}

/* ---------------------------------------------------------------------
   13.Modes / thèmes spécifiques (Bootlike, Subway, Black, etc.) ------ */
.bordernav {
	border: 1px solid #E7E7E7;
}

.chat .btnbl {
	padding: 2px 10px;
}

.smfont {
	font-size: inherit;
}

.chat.panel {
	margin-bottom: 3px;
}

.chat-messages-down {
	-webkit-transform: scaleY(-1);
	transform: scaleY(-1);
}

/* Subway additions */
#chat .subway .post-buttons .icon-button:before {
	top: 5px;
}

#chat .subway .post-buttons .button {
	height: 24px;
	width: 24px;
}

.subway .chatpost {
	margin-bottom: 5px;
	padding: 5px;
}

/* Black additions */
.fachaticon {
	width: 30px;
	margin-left: -5px;
}

.fachaticon .nav-link {
	width: 30px;
}

.fachaticon .navbar .nav-tabs .responsive-menu .nav-link:after, .navbar .nav-tabs .account .nav-link:after, .navbar .nav-tabs .pm .nav-link:after, .navbar .nav-tabs .notifications .nav-link:after, .navbar .nav-tabs .mcp .nav-link:after, .navbar .nav-tabs .acp .nav-link:after, .navbar .nav-tabs .faq .nav-link:after, .navbar .nav-tabs .logout .nav-link:after, .navbar .nav-tabs .login .nav-link:after, .navbar .nav-tabs .register .nav-link:after, .navbar .nav-tabs .rightside .boardrules .nav-link:after, .navbar .nav-tabs .rightside .pages .nav-link:after, .navbar .nav-tabs .members .nav-link:after, .navbar .nav-tabs .forums .nav-link:after, .navbar .nav-tabs .leftside .boardrules .nav-link:after, .navbar .nav-tabs .leftside .pages .nav-link:after {
	font-size: 16px;
}

/* Aqua-Marine additions */
#ajaxchat .forabg.aqua-marine {
	padding-bottom: 0;
}

#ajaxchat .navbar.chatrules.aqua-marine {
	margin-top: -4px;
}

/* ComBoot additions */
.message-comboot {
	line-height: 1.4em;
	padding-top: 2px;
	overflow: auto;
}

.whois-comboot h3 {
	margin: 2px 0;
	font-size: inherit;
}

#ajaxchat .btn-toolbar .btn, .btn-toolbar .btn-group, .btn-toolbar .input-group {
	float: none !important;
}

#ajaxchat .btn {
	padding: 0px 10px;
}

/*!
 *  14 Font Awesome 4.6.1 by @davegandy - http://fontawesome.io - @fontawesome
 *  License - http://fontawesome.io/license (Font: SIL OFL 1.1, CSS: MIT License)
 */
/* FONT PATH
 * -------------------------- */
@font-face {
  font-family: 'FontAwesome';
  src: url('font-awesome/fontawesome-webfont.eot?v=4.5.0');
  src: url('font-awesome/fontawesome-webfont.eot?#iefix&v=4.5.0') format('embedded-opentype'), url('font-awesome/fontawesome-webfont.woff2?v=4.5.0') format('woff2'), url('font-awesome/fontawesome-webfont.woff?v=4.5.0') format('woff'), url('font-awesome/fontawesome-webfont.ttf?v=4.5.0') format('truetype'), url('font-awesome/fontawesome-webfont.svg?v=4.5.0#fontawesomeregular') format('svg');
  font-weight: normal;
  font-style: normal;
}
@font-face {
  font-family: 'FontAwesome';
  src: url('font-awesome/fontawesome-webfont.eot?v=4.6.1');
  src: url('font-awesome/fontawesome-webfont.eot?#iefix&v=4.6.1') format('embedded-opentype'), url('font-awesome/fontawesome-webfont.woff2?v=4.6.1') format('woff2'), url('font-awesome/fontawesome-webfont.woff?v=4.6.1') format('woff'), url('font-awesome/fontawesome-webfont.ttf?v=4.6.1') format('truetype'), url('font-awesome/fontawesome-webfont.svg?v=4.6.1#fontawesomeregular') format('svg');
  font-weight: normal;
  font-style: normal;
}

.shout-body .fa {
  display: inline-block;
  font: normal normal normal 14px/1 FontAwesome;
  font-size: 1.125em;
  text-rendering: auto;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.fa-fw {
  width: 1.28571429em;
  text-align: center;
}

.fa-quote-left:before {
  content: "\f10d";
}

.fa-pencil-square-o:before {
  content: "\f044";
}

.fa-trash-o:before {
  content: "\f014";
}

.fa-comments:before {
  content: "\f086";
}

/* ---------------------------------------------------------------------
   15. Media queries (responsivité) ------------------------------------ */
@media (max-width: 900px) {
    .shout-body,
    .shouts,
    .whois {
        width: 100% !important;
        float: none !important;
        margin: 3px 0 0 0;    /* garde un petit espacement vertical */
    }
}
 
@media only screen and (max-width: 900px) {
	/* adaptations : liste whois & container messages plus petits */
	.whois {
		width: 100%;
		height: auto;
		text-align: left;
		padding: 6px 0 0;
	}
	.whois_chatting {
		display: inline;
		border: none;
		margin: 0;
	}
	.whois_online {
		display: inline;
		margin: 0 4px;
	}
	.shouts {
		width: 100%;
		height:150px;
	}
	#whois_online {
	/* Ancien : display:-webkit-flex; -> changez en -webkit-inline-flex */
    display: -webkit-inline-flex; /* Safari pré-flexbox */  
    display: inline-flex;         /* Spécification standard */
    
    /* flex-wrap */
    -webkit-flex-wrap: wrap;      /* Safari 6.1+ */
    flex-wrap: wrap;              /* Standard */
	}
	.chatpost {
		padding: 0 0 2px 10px !important;
	}
}

@media only screen and (max-width: 700px) {
	/* avatars à gauche, message rebascule après */
	.chatpost {
		padding: 0 0 2px 10px !important;
	}
	.chat-postprofile {
		float: left;
	}
	.message {
		clear: left;
	}
	.shout-body .fa {
		font-size: 1em;
	}
}

@media only screen and (max-width: 550px) {
    /* —————— vos règles existantes —————— */
    .chat-avatars { display: none; }
    .chat-postprofile {
        margin-right: 4px;
        min-width: 80px;
        display: inline;
    }
    .chatnavbar { padding: 2px; }
    #bbpalette { display: none; }
    #whois_online {
        display: -webkit-inline-flex;
        display: inline-flex;
        -webkit-flex-wrap: wrap;
        flex-wrap: wrap;
    }
    .chatpost {
        padding: 0 0 2px 10px !important;
    }

    /* —————— Adaptations responsive chat —————— */
    .shout-body,
    .shouts,
    .chat_online_off,
    .whois {
        float: none !important;        /* plus de colonnes côte-à-côte */
        width: 100% !important;        /* plein écran */
        height: auto !important;       /* la boîte s’agrandit au contenu */
        max-height: none !important;   /* pas de limitation */
        margin-bottom: 10px;            /* espace avant la section suivante */
    }

    /* Ajuste légèrement la largeur du champ de saisie */
    .chatinput {
        width: 90% !important;
    }
}

/* ---------------------------------------------------------------------
   16. Aides divers ----------------------------------------------------- */
.original { /* citation originale */
	padding: 8px 10px;
	margin-bottom: 4px;
}

.nomargin { /* utilitaire reset */
	margin-top: 0 !important;
	margin-bottom: 0 !important;
	margin-left: 0 !important;
	margin-right: 0 !important;
}

#ajaxchat .forabg ul.topiclist li.header dt, .forumbg ul.topiclist li.header dt {
	width: 100%; /* titre 100% */
}

.top-pad {
	padding-top: 2px;
}

.nobg {
	background: none !important;
	border: none !important;
}

.pull-right {
  float: right;
}

.pull-left {
  float: left;
}

/* ---------------------------------------------------------------------
   17.Fonction collapse perso ----------------------------------------- */
#ajaxchat { position: relative; }

#ajaxchat-toggle {
    position: absolute;
    top: 0.3rem;
    right: 0.2rem;
}

/* état déplié */
#ajaxchat .shout-body,
#ajaxchat .whois,
#ajaxchat .chatnavbar,
#ajaxchat .chat_rules,
#ajaxchat .navbar.chatrules,
#ajaxchat .inner > form,
#ajaxchat .inner > div.chatform {
    transition: max-height .25s ease, opacity .2s ease;
    overflow: hidden;
    max-height: 2000px;
    opacity: 1;
}

/* état replié */
#ajaxchat.collapsed .shout-body,
#ajaxchat.collapsed .whois,
#ajaxchat.collapsed .chatnavbar,
#ajaxchat.collapsed .chat_rules,
#ajaxchat.collapsed .navbar.chatrules,
#ajaxchat.collapsed .inner > form,
#ajaxchat.collapsed .inner > div.chatform {
    max-height: 0;
    opacity: 0;
}

/* ---------------------------------------------------------------------
   Forcer le footer AJAX Chat (chatnavbar) à passer sous les floats ----- */
#ajaxchat .chatnavbar {
    clear: both !important;
    /* (vous pouvez aussi ajuster un margin-top ici si vous voulez un petit espacement) */
    margin-top: 3px;
}

.shout-body,
.shouts,
.chat_online_off,
.whois {
	padding-bottom: 0;              /* supprime l’ancien padding */
    margin-bottom: 5px;            /* espace sous la boîte */
    height: 250px;                /* hauteur fixe */
    overflow-y: auto !important;  /* scroll vertical */  
    overflow-x: hidden !important;/* pas de scroll horizontal */
}