/*
 * Copy this file into your theme to customize it.
 * https://www.phpboost.com/wiki/structure-d-un-theme#paragraph-le-repertoire-theme
 *
 * Specific dashboard styles for form elements
*/

/* --- Buttons --- */
button[id*="menu_element"] {
	width: 100%;
	margin-bottom: 0.618em;
}

@media (min-width: 769px) {
	button[id*="menu_element"] { width: auto; }
}

/* --- Fieldset --- */
#AdminLoggedErrorsControllerList_fbuttons,
#AdminErrorsController404List_fbuttons{ padding: 0 0.309em; }

@media (min-width: 769px) {
	#AdminErrorsController404List_fbuttons,
	#AdminLoggedErrorsControllerList_fbuttons { padding: 0 1.309em; }
}

fieldset[id*="advises"] .form-element {
	padding: 0.618em;
	width: 100%;
	border-width: 0;
}

@media (min-width: 1367px) {
	fieldset[id*="advises"] .form-element { width: calc(100% / 2); }
}

/* --- Inputs --- */
[type="text"],
[type="email"],
[type="url"],
[type="number"],
[type="tel"],
[type="search"],
[type="password"],
[type="file"],
textarea,
select {
	width: 100%;
	padding: 0.618em;
}

[type="number"] { padding-right: 0; }

[type="color"] { width: 100%; }

@media (min-width:769px){
	p[id*="filter"] select,
	p[id*="filter"] input{ width: 200px; }
}

/* --- possible values --- */
@media (min-width: 769px) {
	[id*="_possible_values_"] .form-field-radio [type="radio"]:not(:checked) + label::before,
	[id*="_possible_values_"] .form-field-radio [type="radio"]:checked + label::before { top: -0.809em; }

	[id*="_possible_values_"] .form-field-radio [type="radio"]:not(:checked) + label::after,
	[id*="_possible_values_"] .form-field-radio [type="radio"]:checked + label::after { top: -0.618em; }

}

/* --- Form elements --- */
.fieldset-content .fieldset-inset,
.form-element {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
	width: 100%;
}

.no-flex .fieldset-inset { display: inline-block; }

.form-element.form-element-textarea { width: 100%; }

.form-element {
    flex-direction: column;
    justify-content: space-between;
    align-items: space-between;
	border-width: 0 0 1px 0;
	border-style: solid;
	border-color: transparent;
}

.form-element.top-field { justify-content: flex-start; }

.form-element.full-field,
.form-element.half-field,
.form-element.third-field { width: 100%; }

@media (min-width: 769px) {
	.fieldset-content .modal .content-panel.fieldset-inset { width: 80%; }

	.form-element { width: calc(100% / 2); }

	.form-element.form-subtitle { padding: 1.618em 1.618em 0.618em 0; }

	.form-element.half-field,
	.form-element.third-field { width: calc(100% / 2); }
}

@media (min-width: 1025px) {
	.form-element.half-field  { width: calc(100% / 2); }
	.form-element.third-field { width: calc(100% / 3); }
}

@media (min-width: 1281px) {
	.form-element { width: calc(100% / 4); }
}

.form-element > label {
	margin-bottom: 0.228em;
	display: block;
	font-weight: 600;
	width: 100%;
}

.form-field,
.form-field-map,
.form-element-auth .form-field,
.form-field-textarea { width: 100%; }

.form-field-free-large {
	width: 100%;
	max-width: none;
}

.form-field-action-link { text-align: center; }

.form-field-action-link ul {
	margin: 0.309em;
	list-style-type: none;
}

.form-field-action-link ul li {
	display: inline-table;
	margin: 2px 0.618em;
}

.form-field-action-link ul li a { text-decoration: none; }

/* --- Textarea --- */

.form-element-textarea .form-field-textarea { display: block; }

.form-element-preview, .form-element-reset {
	margin-top: 0.309em;
	text-align: center;
}

@media (min-width: 769px) {
	.form-element-preview, .form-element-reset { display: inline-block; }
}

/* --- Authorizations --- */
.auth-setter,
.form-element-auth { width: 100%; }

@media (min-width: 769px) {
	.form-element-auth { width: 50%; }
}
