
#ae-nav-progress {
    position: fixed;
    top: 0; left: 0;
    height: 3px;
    width: 0;
    background: #EE7733;
    z-index: 9999;
    animation: ae-nav-progress 8s cubic-bezier(.1,0,.2,1) forwards;
}
@keyframes ae-nav-progress {
    0%   { width: 0 }
    50%  { width: 70% }
    100% { width: 90% }
}

#ae-haut-page {
    position: fixed;
    bottom: calc(20px + env(safe-area-inset-bottom, 0px));
    right: calc(20px + env(safe-area-inset-right, 0px));
    width: 48px; height: 48px;
    display: flex; align-items: center; justify-content: center;
    padding: 0;
    border: none; border-radius: 50%;
    background: #EE7733; color: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,.3);
    cursor: pointer;
    opacity: 0; visibility: hidden;
    transform: translateY(10px);
    transition: opacity .25s ease, transform .25s ease, visibility .25s;
    z-index: 9998;
}
#ae-haut-page.is-visible {
    opacity: 1; visibility: visible;
    transform: translateY(0);
}
#ae-haut-page:hover { background: #d9631f; }
#ae-haut-page:focus { outline: 2px solid #fff; outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) {
    #ae-haut-page { transition: none; }
}

body {
	font-family: 'Open Sans', sans-serif;
}
html {
	font-size: 20px;
}
a{
	color:#000;
	margin:0;
	padding:0;
}
h1 {
	text-align:center;
	font-weight:normal;
	line-height: 1;
	font-family: Verdana,Geneva,Tahoma,Arial,Helvetica,sans-serif;
}
h4 {
	color: #558;
	font-weight: bold;
	margin: 1.5rem 0;
}
h5 {
	font-weight: bolder;
}

#langues img {
	margin:3px 15px;
	width:42px;
}


#formulaire_propose {
	border: 1px solid #eeeeee;
	padding: 5px;
	line-height: 20px;
	text-align: left;
	line-height: 1.5;
	display:none;
}

#sub_formulaire_propose {
	background-color: #f5F5F5;
	margin:1em;
	padding:1em;
}

#bloc_contact {
	font-size: smaller;
}

#message_propose_ok {
	color:#009900;
	font-weight:bold;
}
#message_propose_erreur {
	color:#BB0000;
	font-weight:bold;
}

/* PAGE VALIDATION CONTRIBUTIONS */

#liste_contribution {
	margin: 20px auto;
	min-width: 10em;
	width:20em;
}

#a_valider {
	list-style-type: none;
	padding:15px;
	display:inline;

}
#a_valider h3 {
	margin: 5px;
	padding: 0px;
	font-size:2.5em;
}

#a_valider_action {
	list-style-type: none;
}
#a_valider_action li {
	padding:10px;

}

#a_valider_action img {
	width:30px;
	height: 30px;
}

#presentation, #histoire {
	background: #f8f8f8;
}

.sousana {
	display:none;
	position:absolute;
	width:90%;
	background-color:#FFF;
	border:2px dashed #555;
	z-index:1;
}


#social {
	font-family: Helvetica, Arial, sans-serif;
	font-size: smaller;
	margin:1em;
}

#facebook {
	padding:5px;
	background-color:#3b5998;
	cursor:pointer;
	width:200px;
	margin:auto;
}

#facebook a {
	color:#fff;
}

.etoile {
	background-image: url("/style/etoile.png");
	background-repeat: no-repeat;
	background-position: center right 5px;
}

.etoile_asc {
	background-image: url("/style/etoile_asc.png");
	background-repeat: no-repeat;
	background-position: center right 5px;
}

#phrases-loading {
	padding: 12px 0;
}

#phrases-loading-texte {
	display: inline-block;
	transition: opacity 0.25s ease;
}

.phrases-loading-anim {
	display: inline-block;
	margin-right: 8px;
	vertical-align: middle;
}

.phrases-loading-anim span {
	display: inline-block;
	width: 7px;
	height: 7px;
	margin: 0 2px;
	border-radius: 50%;
	background-color: currentColor;
	opacity: 0.3;
	animation: phrases-loading-bounce 1.2s infinite ease-in-out both;
}

.phrases-loading-anim span:nth-child(1) { animation-delay: -0.32s; }
.phrases-loading-anim span:nth-child(2) { animation-delay: -0.16s; }

@keyframes phrases-loading-bounce {
	0%, 80%, 100% { opacity: 0.3; transform: translateY(0); }
	40%           { opacity: 1;   transform: translateY(-6px); }
}

#f_nb_saisie {
	padding:0;
	margin:0;
}

/* Cartes de résultat : header allégé + interlignes compacts */
.card .card-header-compact {
	background-color: transparent;
	border-bottom: none;
	padding: 0.5rem 0.5rem 0 0.5rem;
}

.card .card-body-compact {
	padding: 0 0.5rem 0.5rem 0.5rem;
}

.card .card-body-compact .card-text {
	margin-bottom: 2px;
	line-height: 1.25;
}

/* Qualifications grammaticales sur les cartes résultat */
.qualif {
	font-size: 0.65rem;
	font-style: italic;
	color: #666;
	line-height: 1.3;
}

.qualif-tag {
	display: inline-block;
	background: #f0f0f8;
	border-radius: 3px;
	padding: 1px 4px;
	font-style: italic;
	white-space: nowrap;
}

.qualif-tag + .qualif-tag {
	margin-left: 3px;
}

.qualif-lemme {
	font-style: normal;
	color: #448;
}

.categories {
	font-size: 0.65rem;
	line-height: 1.3;
}

.freq {
	font-size: 0.65rem;
	line-height: 1.3;
}

.freq-tag {
	display: inline-block;
	border-radius: 3px;
	padding: 1px 5px;
	font-weight: 600;
	white-space: nowrap;
}

.freq-courant {
	color: #1b6e3b;
	background: #e3f4e9;
}

.freq-moyen {
	color: #1f5a8a;
	background: #e4eef7;
}

.freq-rare {
	color: #8a5a00;
	background: #f7efe0;
}

.badge-theme {
	font-size: 0.6rem;
	font-weight: normal;
	padding: 2px 6px;
}

.badge-theme + .badge-theme {
	margin-left: 2px;
}

.presentation-editoriale {
	font-size: 0.85rem;
	line-height: 1.6;
	color: #444;
}


.entete-seo {
	margin: 0.5rem 0 1rem;
	padding: 0.55rem 1rem;
	background: #fff6f0;
	border: 1px solid #f3d4c2;
	border-radius: 6px;
	text-align: center;
}

.entete-theme {
	margin: 1rem 0 1.5rem;
	padding: 1rem 1.25rem;
	background: #fff6f0;
	border: 1px solid #f3d4c2;
	border-radius: 6px;
}

.entete-theme-titre {
	margin: 0 0 0.6rem;
	font-size: 1.5rem;
	font-weight: 600;
	color: #333;
}

.entete-theme-header {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	margin-bottom: 0.5rem;
}

.entete-theme-header .entete-theme-titre {
	margin-bottom: 0;
}

.entete-theme-icone {
	flex: 0 0 auto;
	width: 40px;
	height: 40px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	border-radius: 8px;
}

.entete-theme-icone svg {
	width: 22px;
	height: 22px;
}

.entete-theme-description {
	margin: 0;
	font-size: 0.95rem;
	line-height: 1.55;
	color: #444;
}

.entete-seo-ligne {
	margin: 0;
	font-size: 0.95rem;
	color: #333;
}

.entete-seo a {
	color: #EE7733;
}

.entete-seo-ligne + .entete-seo-ligne {
	margin-top: 0.3rem;
}

#ana-sentinelle {
	height: 1px;
}

/* === Pages thématiques : vue lettre =================================== */

/* Sous-index bigrammes (chips) */
.theme-bigrammes {
	display: flex;
	flex-wrap: wrap;
	gap: 0.3rem;
	padding: 0.6rem 0.75rem;
	background: #fafafa;
	border: 1px solid #eee;
	border-radius: 6px;
}

.theme-bigramme-chip {
	display: inline-flex;
	align-items: baseline;
	gap: 0.25rem;
	padding: 0.15rem 0.5rem;
	font-size: 0.8rem;
	color: #333;
	background: #fff;
	border: 1px solid #ddd;
	border-radius: 999px;
	text-decoration: none;
	transition: background 0.1s, border-color 0.1s;
}

.theme-bigramme-chip:hover {
	background: #fff6f0;
	border-color: #EE7733;
	color: #EE7733;
	text-decoration: none;
}

.theme-bigramme-label {
	font-weight: 600;
}

.theme-bigramme-n {
	font-size: 0.7rem;
	color: #888;
}

.theme-bigramme-chip:hover .theme-bigramme-n {
	color: #EE7733;
}

/* Titres de section bigramme */
.theme-bigramme-titre {
	margin-top: 1.2rem;
	margin-bottom: 0.4rem;
	font-size: 1.05rem;
	font-weight: 600;
	color: #333;
	border-bottom: 1px solid #eee;
	padding-bottom: 0.25rem;
	scroll-margin-top: 1rem;
}

/* Liste dense en colonnes typographiques */
.theme-liste-bigramme {
	list-style: none;
	padding: 0;
	margin: 0 0 0.5rem;
	column-gap: 1.2rem;
	column-count: 2;
}

.theme-liste-bigramme li {
	break-inside: avoid;
	padding: 0.1rem 0;
	font-size: 0.92rem;
	line-height: 1.45;
}

.theme-liste-bigramme a {
	text-decoration: none;
	color: #2255aa;
}

.theme-liste-bigramme a:hover {
	color: #EE7733;
	text-decoration: underline;
}

@media (min-width: 600px) {
	.theme-liste-bigramme { column-count: 3; }
}

@media (min-width: 900px) {
	.theme-liste-bigramme { column-count: 4; }
}

@media (min-width: 1400px) {
	.theme-liste-bigramme { column-count: 5; }
}

@media (max-width: 399px) {
	.theme-liste-bigramme { column-count: 1; }
}

/* --- Sous-sections de résultats par catégorie (cf. AnagrammeControler) --- */
/* Conteneur tinté englobant (background + bordure en couleur du thème, injectés inline). */
.sous-section-bloc {
	margin: 1rem 0;
	padding: 0.6rem 1rem 0.4rem;
	border-radius: 8px;
}
/* Neutralise les marges négatives de Bootstrap .row à l'intérieur du padding du bloc. */
.sous-section-bloc > .row {
	margin-left: 0;
	margin-right: 0;
}
/* En-tête transparent ; tout le visuel tinté vient du conteneur .sous-section-bloc. */
.sous-section-entete {
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 0 0 0.5rem;
	padding: 0.2rem 0;
	font-weight: 600;
	background: transparent;
}
.sous-section-icone-wrap {
	display: inline-flex;
	align-items: center;
}
.sous-section-icone {
	vertical-align: middle;
}
.sous-section-nom {
	flex: 1;
	/* couleur héritée de .sous-section-entete (inline, couleur du thème) */
}
.sous-section-compteur {
	font-weight: normal;
	color: #555; /* reset : ne pas hériter de la couleur de thème */
}
