/* ===== RESET ET BASE ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f4f4f4;
    padding: 20px;
}

main {
    max-width: 1100px;
    margin: 20px auto;
    background: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
}

h1, h2, h3 {
    margin-bottom: 20px;
    color: #2c3e50;
}

h1 {
    border-bottom: 3px solid #3498db;
    padding-bottom: 10px;
}

h2 {
    color: #2980b9;
    margin-top: 30px;
}

/* ===== NAVIGATION ===== */
header {
    background: #2c3e50;
    color: white;
    padding: 15px 0;
    border-radius: 5px;
}

nav ul {
    list-style: none;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
}

nav ul li {
    margin: 0 15px;
}

nav ul li a {
    color: #ecf0f1;
    text-decoration: none;
    font-weight: bold;
    padding: 5px 10px;
}

nav ul li a:hover {
    color: #3498db;
    background: rgba(255,255,255,0.1);
    border-radius: 3px;
}

/* ===== FOOTER ===== */
footer {
    text-align: center;
    margin-top: 20px;
    padding: 20px;
    background: #34495e;
    color: #ecf0f1;
    border-radius: 5px;
}

footer a {
    color: #3498db;
    text-decoration: none;
}

footer a:hover {
    text-decoration: underline;
}

/* ===== SECTIONS ===== */
.section {
    margin-bottom: 40px;
    padding-bottom: 20px;
    border-bottom: 2px solid #bdc3c7;
}

.section:last-child {
    border-bottom: none;
}

/* ===== BOUTONS ===== */
.btn {
    display: inline-block;
    padding: 10px 20px;
    background: #3498db;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    border: none;
    font-size: 16px;
    cursor: pointer;
}

.btn:hover {
    background: #2980b9;
}

.btn-effacer {
    background: #95a5a6;
}

.btn-effacer:hover {
    background: #7f8c8d;
}

/* ===== FORMULAIRES ===== */
form {
    max-width: 800px;
    margin: 0 auto;
}

fieldset {
    border: 2px solid #bdc3c7;
    padding: 20px;
    margin-bottom: 25px;
    border-radius: 5px;
}

legend {
    font-weight: bold;
    color: #2c3e50;
    padding: 0 10px;
    font-size: 1.2em;
}

.form-group {
    margin-bottom: 20px;
}

label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

input:not([type="radio"]):not([type="checkbox"]):not([type="file"]),
select,
textarea {
    width: 100%;
    padding: 10px;
    border: 2px solid #bdc3c7;
    border-radius: 4px;
    font-size: 16px;
}

input:focus,
select:focus,
textarea:focus {
    border-color: #3498db;
    outline: none;
}

.radio-group,
.checkbox-group {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.radio-group label,
.checkbox-group label {
    font-weight: normal;
    display: flex;
    align-items: center;
    gap: 5px;
}

.radio-group input,
.checkbox-group input {
    width: auto;
}

small {
    display: block;
    color: #7f8c8d;
    font-size: 0.85em;
    margin-top: 5px;
}

/* ===== TABLEAUX ===== */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
}

th, td {
    border: 2px solid #bdc3c7;
    padding: 12px;
    text-align: left;
}

th {
    background: #ecf0f1;
    font-weight: bold;
}

/* ===== GRILLE ===== */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
}

.card {
    background: #ecf0f1;
    padding: 20px;
    border-radius: 5px;
    text-align: center;
}

.card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 5px;
    margin-bottom: 15px;
}