/*
	User Submitted Posts : CSS : USP Form (version relookée)
	Palette : accent #f9b872 | extra 1 #fae7a5 | extra 2 #d4efdf
	Liste complète des sélecteurs @ https://m0n.co/e
*/

div#user-submitted-posts {
	--usp-accent: #f9b872;
	--usp-accent-dark: #f0a152;
	--usp-extra1: #fae7a5;
	--usp-extra2: #d4efdf;
	--usp-text: #2f2a24;
	--usp-muted: #7a7266;
	--usp-border: #e7e1d6;
	--usp-bg-field: #fffdf9;
	--usp-error: #c0392b;
	--usp-radius: 10px;

	width: 100%;
	max-width: 760px;
	margin: 0 auto;
	color: var(--usp-text);
	overflow: visible;
}

/* ---------- Carte du formulaire ---------- */
div#user-submitted-posts form {
	position: relative;
	box-sizing: border-box;
	margin: 10px 0;
	padding: 40px 36px 32px;
	background: #fff;
	border: 1px solid var(--usp-border);
	border-radius: 16px;
	box-shadow: 0 10px 40px rgba(60, 40, 10, .08);
	overflow: hidden;
}
/* Bandeau de couleurs en haut de la carte */
div#user-submitted-posts form::before {
	content: "";
	position: absolute;
	top: 0; left: 0; right: 0;
	height: 6px;
	background: linear-gradient(90deg, var(--usp-accent) 0%, var(--usp-extra1) 50%, var(--usp-extra2) 100%);
}

div#user-submitted-posts fieldset { box-sizing: border-box; margin: 0 0 22px 0; padding: 0; border: 0; }

/* ---------- Libellés ---------- */
div#user-submitted-posts fieldset label {
	box-sizing: border-box;
	display: block;
	float: none;
	clear: both;
	width: 100%;
	margin: 0 0 8px 0;
	padding: 0;
	border: 0;
	font-size: 14px;
	font-weight: 600;
	line-height: 1.4;
	color: var(--usp-text);
}
div#user-submitted-posts .usp-req { color: #e08a2e; font-weight: 700; }
div#user-submitted-posts p.usp-legend { margin: 0 0 18px 0; font-size: 13px; color: var(--usp-muted); }

/* ---------- Champs ---------- */
div#user-submitted-posts fieldset input.usp-input,
div#user-submitted-posts textarea.usp-textarea,
div#user-submitted-posts select {
	box-sizing: border-box;
	display: block;
	float: none;
	clear: both;
	width: 100%;
	margin: 0;
	padding: 13px 16px;
	font-family: inherit;
	font-size: 16px;
	line-height: 1.4;
	color: var(--usp-text);
	background: var(--usp-bg-field);
	border: 1.5px solid var(--usp-border);
	border-radius: var(--usp-radius);
	box-shadow: none;
	transition: border-color .2s ease, box-shadow .2s ease, background-color .2s ease;
	-webkit-appearance: none;
	appearance: none;
}
div#user-submitted-posts textarea.usp-textarea { min-height: 160px; resize: vertical; }

div#user-submitted-posts ::placeholder { color: #b3aa9b; opacity: 1; }

div#user-submitted-posts fieldset input.usp-input:hover,
div#user-submitted-posts textarea.usp-textarea:hover,
div#user-submitted-posts select:hover { border-color: #d9cfbd; }

div#user-submitted-posts fieldset input.usp-input:focus,
div#user-submitted-posts textarea.usp-textarea:focus,
div#user-submitted-posts select:focus {
	outline: none;
	background: #fff;
	border-color: var(--usp-accent);
	box-shadow: 0 0 0 4px rgba(249, 184, 114, .30);
}

/* Listes déroulantes : petite flèche */
div#user-submitted-posts select {
	padding-right: 44px;
	cursor: pointer;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9'%3E%3Cpath d='M1 1l6 6 6-6' fill='none' stroke='%237a7266' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 16px center;
}
div#user-submitted-posts select.usp-multiple { width: 100%; background-image: none; padding-right: 16px; }

/* Catégories hiérarchiques */
div#user-submitted-posts .usp-cat-child { text-indent: 20px; }
div#user-submitted-posts .usp-cat-grand { text-indent: 40px; }
div#user-submitted-posts .usp-cat-great { text-indent: 60px; }
div#user-submitted-posts .usp-cat-great-great { text-indent: 80px; }

/* ---------- Éditeur de texte enrichi ---------- */
div#user-submitted-posts div.usp_text-editor { margin: 0; }
div#user-submitted-posts div.wp-editor-container {
	border: 1.5px solid var(--usp-border);
	border-radius: var(--usp-radius);
	overflow: hidden;
}
div#user-submitted-posts div.wp-editor-container:focus-within { border-color: var(--usp-accent); box-shadow: 0 0 0 4px rgba(249, 184, 114, .30); }
div#user-submitted-posts .wp-editor-tools { margin-bottom: 6px; }

/* ---------- Images ---------- */
div#user-submitted-posts fieldset.usp-images { margin: 0 0 22px 0; }
div#user-submitted-posts div#usp-upload-message { margin: 0 0 10px 0; font-size: 13px; color: var(--usp-muted); }
div#user-submitted-posts fieldset input.usp-input.usp-clone {
	margin: 0 0 10px 0;
	padding: 14px 16px;
	font-size: 14px;
	background: rgba(250, 231, 165, .25);
	border: 1.5px dashed var(--usp-accent);
	cursor: pointer;
}
div#user-submitted-posts fieldset input.usp-input.usp-clone:hover { background: rgba(250, 231, 165, .5); }
div#user-submitted-posts input[type="file"]::file-selector-button {
	margin-right: 14px;
	padding: 8px 16px;
	font-family: inherit;
	font-size: 13px;
	font-weight: 600;
	color: var(--usp-text);
	background: var(--usp-accent);
	border: 0;
	border-radius: 999px;
	cursor: pointer;
	transition: background-color .2s ease;
}
div#user-submitted-posts input[type="file"]::file-selector-button:hover { background: var(--usp-accent-dark); }

div#user-submitted-posts a#usp_add-another {
	display: inline-block;
	clear: both;
	margin: 4px 0 0 0;
	padding: 7px 16px;
	font-size: 13px;
	font-weight: 600;
	text-decoration: none;
	color: var(--usp-text);
	background: var(--usp-extra2);
	border-radius: 999px;
	transition: filter .2s ease;
}
div#user-submitted-posts a#usp_add-another:hover { filter: brightness(.95); }

/* ---------- Bouton d'envoi ---------- */
div#user-submitted-posts div#usp-submit { margin: 30px 0 0 0; }
div#user-submitted-posts input.usp-submit,
div#user-submitted-posts input#user-submitted-post {
	display: inline-block;
	width: auto;
	min-width: 220px;
	margin: 0;
	padding: 15px 34px;
	font-family: inherit;
	font-size: 16px;
	font-weight: 700;
	line-height: 1.2;
	letter-spacing: .01em;
	color: #3a2a14;
	background: var(--usp-accent);
	border: 0;
	border-radius: 999px;
	box-shadow: 0 6px 18px rgba(249, 184, 114, .55);
	cursor: pointer;
	-webkit-appearance: none;
	appearance: none;
	transition: background-color .2s ease, transform .15s ease, box-shadow .2s ease;
}
div#user-submitted-posts input.usp-submit:hover,
div#user-submitted-posts input#user-submitted-post:hover {
	background: var(--usp-accent-dark);
	transform: translateY(-1px);
	box-shadow: 0 8px 22px rgba(240, 161, 82, .6);
}
div#user-submitted-posts input.usp-submit:active { transform: translateY(0); }
div#user-submitted-posts input.usp-submit:focus-visible {
	outline: 3px solid #3a2a14;
	outline-offset: 3px;
}

/* ---------- Messages ---------- */
div#user-submitted-posts div.usp-error,
div#user-submitted-posts div#usp-error-message,
div#user-submitted-posts div#usp-error-message.usp-callout-failure {
	margin: 0 0 24px 0;
	padding: 14px 18px;
	font-size: 14px;
	color: var(--usp-error);
	background: #fdf0ee;
	border-left: 4px solid var(--usp-error);
	border-radius: 8px;
}
div#user-submitted-posts div#usp-success-message {
	margin: 0;
	padding: 22px 24px;
	font-size: 16px;
	font-weight: 600;
	color: #1f5a3c;
	background: var(--usp-extra2);
	border-left: 4px solid #5fb88a;
	border-radius: 8px;
}

/* ---------- Case à cocher ---------- */
div#user-submitted-posts fieldset.usp-checkbox { padding: 4px 0; }
div#user-submitted-posts fieldset.usp-checkbox input { display: inline-block; vertical-align: middle; position: relative; top: -1px; width: 18px; height: 18px; margin: 0 8px 0 0; accent-color: var(--usp-accent-dark); }
div#user-submitted-posts fieldset.usp-checkbox label { display: inline-block; width: auto; vertical-align: middle; font-weight: 400; }

.usp-hidden, .usp-no-js { display: none; }
.usp-js { display: block; }

/* ---------- Parsley (validation) ---------- */
div#user-submitted-posts ul.parsley-errors-list { display: none; list-style-type: none; }
div#user-submitted-posts ul.parsley-errors-list.filled { display: block; float: none; clear: both; margin: 6px 0 0 0; padding: 0; font-size: 13px; line-height: 18px; }
div#user-submitted-posts ul.parsley-errors-list.filled li.parsley-required,
div#user-submitted-posts ul.parsley-errors-list.filled li.parsley-type {
	display: inline-block;
	margin: 0;
	padding: 4px 12px;
	color: var(--usp-error);
	background: #fdf0ee;
	border-radius: 6px;
}
div#user-submitted-posts input.parsley-error,
div#user-submitted-posts textarea.parsley-error,
div#user-submitted-posts select.parsley-error { border-color: var(--usp-error); }
div#user-submitted-posts input.parsley-success,
div#user-submitted-posts textarea.parsley-success { border-color: #5fb88a; }

/* ---------- Chosen (listes de tags / catégories) ---------- */
div#user-submitted-posts .chosen-container[style] { box-sizing: border-box; display: block; float: none; clear: both; width: 100% !important; margin: 0; font-size: 15px; }
div#user-submitted-posts .chosen-container-multi .chosen-choices,
div#user-submitted-posts .chosen-container-single .chosen-single {
	min-height: 48px;
	padding: 6px 10px;
	background: var(--usp-bg-field);
	border: 1.5px solid var(--usp-border);
	border-radius: var(--usp-radius);
	box-shadow: none;
}
div#user-submitted-posts .chosen-container-single .chosen-single { padding: 11px 14px; line-height: 24px; height: auto; background-image: none; }
div#user-submitted-posts .chosen-container-active .chosen-choices,
div#user-submitted-posts .chosen-container-active .chosen-single {
	border-color: var(--usp-accent);
	box-shadow: 0 0 0 4px rgba(249, 184, 114, .30);
}
div#user-submitted-posts .chosen-container-multi .chosen-choices li.search-choice {
	padding: 6px 24px 6px 10px;
	line-height: 1.2;
	color: var(--usp-text);
	background: var(--usp-extra1);
	border: 0;
	border-radius: 999px;
	box-shadow: none;
}
div#user-submitted-posts .chosen-container .chosen-drop { border: 1.5px solid var(--usp-border); border-radius: 0 0 var(--usp-radius) var(--usp-radius); box-shadow: 0 10px 24px rgba(60, 40, 10, .1); }
div#user-submitted-posts .chosen-container .chosen-results li.highlighted { background: var(--usp-accent); background-image: none; color: #3a2a14; }
div#user-submitted-posts .chosen-container-multi .chosen-choices li.search-choice .search-choice-close { text-decoration: none; border: none; padding: 0; box-shadow: none; top: 7px; }

/* ---------- Mobile ---------- */
@media (max-width: 600px) {
	div#user-submitted-posts form { padding: 32px 20px 24px; border-radius: 12px; }
	div#user-submitted-posts input.usp-submit,
	div#user-submitted-posts input#user-submitted-post { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
	div#user-submitted-posts * { transition: none !important; }
}

/* Chosen v1.8.7 https://github.com/harvesthq/chosen by Patrick Filler - MIT License */
.chosen-container{position:relative;display:inline-block;vertical-align:middle;font-size:13px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.chosen-container *{-webkit-box-sizing:border-box;box-sizing:border-box}.chosen-container .chosen-drop{position:absolute;top:100%;z-index:1010;width:100%;border:1px solid #aaa;border-top:0;background:#fff;-webkit-box-shadow:0 4px 5px rgba(0,0,0,.15);box-shadow:0 4px 5px rgba(0,0,0,.15);clip:rect(0,0,0,0);-webkit-clip-path:inset(100% 100%);clip-path:inset(100% 100%)}.chosen-container.chosen-with-drop .chosen-drop{clip:auto;-webkit-clip-path:none;clip-path:none}.chosen-container a{cursor:pointer}.chosen-container .chosen-single .group-name,.chosen-container .search-choice .group-name{margin-right:4px;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;font-weight:400;color:#999}.chosen-container .chosen-single .group-name:after,.chosen-container .search-choice .group-name:after{content:":";padding-left:2px;vertical-align:top}.chosen-container-single .chosen-single{position:relative;display:block;overflow:hidden;padding:0 0 0 8px;height:25px;border:1px solid #aaa;border-radius:5px;background-color:#fff;background:-webkit-gradient(linear,left top,left bottom,color-stop(20%,#fff),color-stop(50%,#f6f6f6),color-stop(52%,#eee),to(#f4f4f4));background:linear-gradient(#fff 20%,#f6f6f6 50%,#eee 52%,#f4f4f4 100%);background-clip:padding-box;-webkit-box-shadow:0 0 3px #fff inset,0 1px 1px rgba(0,0,0,.1);box-shadow:0 0 3px #fff inset,0 1px 1px rgba(0,0,0,.1);color:#444;text-decoration:none;white-space:nowrap;line-height:24px}.chosen-container-single .chosen-default{color:#999}.chosen-container-single .chosen-single span{display:block;overflow:hidden;margin-right:26px;text-overflow:ellipsis;white-space:nowrap}.chosen-container-single .chosen-single-with-deselect span{margin-right:38px}.chosen-container-single .chosen-single abbr{position:absolute;top:6px;right:26px;display:block;width:12px;height:12px;background:url(chosen-sprite.png) -42px 1px no-repeat;font-size:1px}.chosen-container-single .chosen-single abbr:hover{background-position:-42px -10px}.chosen-container-single.chosen-disabled .chosen-single abbr:hover{background-position:-42px -10px}.chosen-container-single .chosen-single div{position:absolute;top:0;right:0;display:block;width:18px;height:100%}.chosen-container-single .chosen-single div b{display:block;width:100%;height:100%;background:url(chosen-sprite.png) no-repeat 0 2px}.chosen-container-single .chosen-search{position:relative;z-index:1010;margin:0;padding:3px 4px;white-space:nowrap}.chosen-container-single .chosen-search input[type=text]{margin:1px 0;padding:4px 20px 4px 5px;width:100%;height:auto;outline:0;border:1px solid #aaa;background:url(chosen-sprite.png) no-repeat 100% -20px;font-size:1em;font-family:sans-serif;line-height:normal;border-radius:0}.chosen-container-single .chosen-drop{margin-top:-1px;border-radius:0 0 4px 4px;background-clip:padding-box}.chosen-container-single.chosen-container-single-nosearch .chosen-search{position:absolute;clip:rect(0,0,0,0);-webkit-clip-path:inset(100% 100%);clip-path:inset(100% 100%)}.chosen-container .chosen-results{color:#444;position:relative;overflow-x:hidden;overflow-y:auto;margin:0 4px 4px 0;padding:0 0 0 4px;max-height:240px;-webkit-overflow-scrolling:touch}.chosen-container .chosen-results li{display:none;margin:0;padding:5px 6px;list-style:none;line-height:15px;word-wrap:break-word;-webkit-touch-callout:none}.chosen-container .chosen-results li.active-result{display:list-item;cursor:pointer}.chosen-container .chosen-results li.disabled-result{display:list-item;color:#ccc;cursor:default}.chosen-container .chosen-results li.highlighted{background-color:#3875d7;background-image:-webkit-gradient(linear,left top,left bottom,color-stop(20%,#3875d7),color-stop(90%,#2a62bc));background-image:linear-gradient(#3875d7 20%,#2a62bc 90%);color:#fff}.chosen-container .chosen-results li.no-results{color:#777;display:list-item;background:#f4f4f4}.chosen-container .chosen-results li.group-result{display:list-item;font-weight:700;cursor:default}.chosen-container .chosen-results li.group-option{padding-left:15px}.chosen-container .chosen-results li em{font-style:normal;text-decoration:underline}.chosen-container-multi .chosen-choices{position:relative;overflow:hidden;margin:0;padding:0 5px;width:100%;height:auto;border:1px solid #aaa;background-color:#fff;background-image:-webkit-gradient(linear,left top,left bottom,color-stop(1%,#eee),color-stop(15%,#fff));background-image:linear-gradient(#eee 1%,#fff 15%);cursor:text}.chosen-container-multi .chosen-choices li{float:left;list-style:none}.chosen-container-multi .chosen-choices li.search-field{margin:0;padding:0;white-space:nowrap}.chosen-container-multi .chosen-choices li.search-field input[type=text]{margin:1px 0;padding:0;height:25px;outline:0;border:0!important;background:0 0!important;-webkit-box-shadow:none;box-shadow:none;color:#999;font-size:100%;font-family:sans-serif;line-height:normal;border-radius:0;width:25px}.chosen-container-multi .chosen-choices li.search-choice{position:relative;margin:3px 5px 3px 0;padding:3px 20px 3px 5px;border:1px solid #aaa;max-width:100%;border-radius:3px;background-color:#eee;background-image:-webkit-gradient(linear,left top,left bottom,color-stop(20%,#f4f4f4),color-stop(50%,#f0f0f0),color-stop(52%,#e8e8e8),to(#eee));background-image:linear-gradient(#f4f4f4 20%,#f0f0f0 50%,#e8e8e8 52%,#eee 100%);background-size:100% 19px;background-repeat:repeat-x;background-clip:padding-box;-webkit-box-shadow:0 0 2px #fff inset,0 1px 0 rgba(0,0,0,.05);box-shadow:0 0 2px #fff inset,0 1px 0 rgba(0,0,0,.05);color:#333;line-height:13px;cursor:default}.chosen-container-multi .chosen-choices li.search-choice span{word-wrap:break-word}.chosen-container-multi .chosen-choices li.search-choice .search-choice-close{position:absolute;top:4px;right:3px;display:block;width:12px;height:12px;background:url(chosen-sprite.png) -42px 1px no-repeat;font-size:1px}.chosen-container-multi .chosen-choices li.search-choice .search-choice-close:hover{background-position:-42px -10px}.chosen-container-multi .chosen-choices li.search-choice-disabled{padding-right:5px;border:1px solid #ccc;background-color:#e4e4e4;background-image:-webkit-gradient(linear,left top,left bottom,color-stop(20%,#f4f4f4),color-stop(50%,#f0f0f0),color-stop(52%,#e8e8e8),to(#eee));background-image:linear-gradient(#f4f4f4 20%,#f0f0f0 50%,#e8e8e8 52%,#eee 100%);color:#666}.chosen-container-multi .chosen-choices li.search-choice-focus{background:#d4d4d4}.chosen-container-multi .chosen-choices li.search-choice-focus .search-choice-close{background-position:-42px -10px}.chosen-container-multi .chosen-results{margin:0;padding:0}.chosen-container-multi .chosen-drop .result-selected{display:list-item;color:#ccc;cursor:default}.chosen-container-active .chosen-single{border:1px solid #5897fb;-webkit-box-shadow:0 0 5px rgba(0,0,0,.3);box-shadow:0 0 5px rgba(0,0,0,.3)}.chosen-container-active.chosen-with-drop .chosen-single{border:1px solid #aaa;border-bottom-right-radius:0;border-bottom-left-radius:0;background-image:-webkit-gradient(linear,left top,left bottom,color-stop(20%,#eee),color-stop(80%,#fff));background-image:linear-gradient(#eee 20%,#fff 80%);-webkit-box-shadow:0 1px 0 #fff inset;box-shadow:0 1px 0 #fff inset}.chosen-container-active.chosen-with-drop .chosen-single div{border-left:none;background:0 0}.chosen-container-active.chosen-with-drop .chosen-single div b{background-position:-18px 2px}.chosen-container-active .chosen-choices{border:1px solid #5897fb;-webkit-box-shadow:0 0 5px rgba(0,0,0,.3);box-shadow:0 0 5px rgba(0,0,0,.3)}.chosen-container-active .chosen-choices li.search-field input[type=text]{color:#222!important}.chosen-disabled{opacity:.5!important;cursor:default}.chosen-disabled .chosen-single{cursor:default}.chosen-disabled .chosen-choices .search-choice .search-choice-close{cursor:default}.chosen-rtl{text-align:right}.chosen-rtl .chosen-single{overflow:visible;padding:0 8px 0 0}.chosen-rtl .chosen-single span{margin-right:0;margin-left:26px;direction:rtl}.chosen-rtl .chosen-single-with-deselect span{margin-left:38px}.chosen-rtl .chosen-single div{right:auto;left:3px}.chosen-rtl .chosen-single abbr{right:auto;left:26px}.chosen-rtl .chosen-choices li{float:right}.chosen-rtl .chosen-choices li.search-field input[type=text]{direction:rtl}.chosen-rtl .chosen-choices li.search-choice{margin:3px 5px 3px 0;padding:3px 5px 3px 19px}.chosen-rtl .chosen-choices li.search-choice .search-choice-close{right:auto;left:4px}.chosen-rtl.chosen-container-single .chosen-results{margin:0 0 4px 4px;padding:0 4px 0 0}.chosen-rtl .chosen-results li.group-option{padding-right:15px;padding-left:0}.chosen-rtl.chosen-container-active.chosen-with-drop .chosen-single div{border-right:none}.chosen-rtl .chosen-search input[type=text]{padding:4px 5px 4px 20px;background:url(chosen-sprite.png) no-repeat -30px -20px;direction:rtl}.chosen-rtl.chosen-container-single .chosen-single div b{background-position:6px 2px}.chosen-rtl.chosen-container-single.chosen-with-drop .chosen-single div b{background-position:-12px 2px}@media only screen and (-webkit-min-device-pixel-ratio:1.5),only screen and (min-resolution:144dpi),only screen and (min-resolution:1.5dppx){.chosen-container .chosen-results-scroll-down span,.chosen-container .chosen-results-scroll-up span,.chosen-container-multi .chosen-choices .search-choice .search-choice-close,.chosen-container-single .chosen-search input[type=text],.chosen-container-single .chosen-single abbr,.chosen-container-single .chosen-single div b,.chosen-rtl .chosen-search input[type=text]{background-image:url(chosen-sprite@2x.png)!important;background-size:52px 37px!important;background-repeat:no-repeat!important}}