/* ==============================
   Reset base
============================== */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Arial', sans-serif;
    background-color: #f5f5f5;
    color: #333;
    /*padding: 20px;*/
}

h1 {
    text-align: center;
    margin-bottom: 30px;
    color: #222;
}

/* ==============================
   Form principale
============================== */
form {
    max-width: 700px;
    margin: 0 auto;
    /*background: #fff;*/
    padding: 25px 30px;
    /*border-radius: 10px;*/
    /*box-shadow: 0 4px 15px rgba(0,0,0,0.1);*/
}

form label {
    display: block;
    margin-top: 15px;
    font-weight: bold;
    color: #444;
}

form input[type="text"],
form input[type="email"],
form input[type="tel"],
form select,
form textarea {
    width: 100%;
    padding: 10px 12px;
    margin-top: 5px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 14px;
    transition: 0.2s border-color;
}

form input:focus,
form select:focus,
form textarea:focus {
    border-color: #007bff;
    outline: none;
}

form textarea {
    min-height: 80px;
    resize: vertical;
}

input[required],
select[required] {
    border-left: 4px solid #dc3545;
    padding-left: 8px;
}

/* ==============================
   Sezioni fiera / studio
============================== */
#fiera_section,
#studio_esterna_section {
    display: none;
    margin-top: 15px;
    padding: 15px;
    background-color: #f9f9f9;
    border-left: 4px solid #007bff;
    border-radius: 6px;
}

#studio_esterna_section {
    position: relative;
    z-index: 0;
}

/* Flatpickr input readonly */
#data[readonly] {
    background-color: #fff;
    cursor: pointer;
    pointer-events: auto;
}

/* ==============================
   Radio buttons
============================== */
.form-group {
    margin-top: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.radio-group {
    display: flex;
    gap: 20px;
    align-items: center;
    justify-content: center;
}

.radio-group label {
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 600;
    user-select: none;
}

.radio-group input[type="radio"] {
    margin: 0;
    cursor: pointer;
    width: auto;
    height: auto;
}

/* ==============================
   Bottone submit
============================== */
button[type="submit"] {
    display: block;
    margin: 30px auto 0 auto;
    padding: 12px 30px;
    font-size: 16px;
    font-weight: 700;
    color: #fff;
    background-color: #007bff;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.25s ease;
}

button[type="submit"]:hover {
    background-color: #0056b3;
}

/* ==============================
   Responsive
============================== */
@media (max-width: 768px) {
    form {
        padding: 20px 15px;
    }

    button[type="submit"] {
        width: 100%;
    }

    .radio-group {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* ==============================
   contatti
============================== */
.form-section {
	margin-top: 7.5em;
	padding: 1em;
	border: 1px solid #ccc;
	border-radius: 6px;
	/*background: #fafafa;*/
}

.form-section legend {
	font-weight: bold;
	padding: 0 0.5em;
    color: #444;
}