*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --bg:       #f7f5f2;
    --surface:  #ffffff;
    --border:   #e2ddd8;
    --text:     #2c2825;
    --muted:    #8a8480;
    --accent:   #c0392b;
    --radius:   6px;
    --shadow:   0 1px 4px rgba(0,0,0,0.08);
}

body {
    background: var(--bg);
    color: var(--text);
    font-family: Georgia, 'Times New Roman', serif;
    font-size: 1.0625rem;
    line-height: 1.7;
}

a {
    color: var(--accent);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

.container {
    max-width: 720px;
    margin: 0 auto;
    padding: 0 1.25rem;
}

/* -- Header -- */
header {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    padding: 1rem 0;
    margin-bottom: 2.5rem;
}

header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

header h1 {
    font-size: 1.25rem;
    font-weight: normal;
    letter-spacing: 0.02em;
}

header h1 a {
    color: var(--text);
}

/* -- Bouton -- */
.btn {
    display: inline-block;
    padding: 0.4rem 1rem;
    background: var(--accent);
    color: #fff;
    border: none;
    border-radius: var(--radius);
    font-family: inherit;
    font-size: 0.9rem;
    cursor: pointer;
    transition: opacity 0.15s;
}

.btn:hover {
    opacity: 0.85;
    text-decoration: none;
}

/* -- Liste des articles -- */
.post-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.post-card a {
    display: block;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.25rem 1.5rem;
    box-shadow: var(--shadow);
    transition: border-color 0.15s;
    color: var(--text);
}

.post-card a:hover {
    border-color: var(--accent);
    text-decoration: none;
}

.post-card h2 {
    font-size: 1.15rem;
    font-weight: normal;
    margin-bottom: 0.3rem;
}

.post-card time {
    font-size: 0.85rem;
    color: var(--muted);
    font-style: italic;
    font-family: sans-serif;
}

.empty {
    color: var(--muted);
    font-style: italic;
}

/* -- Article -- */
article h2 {
    font-size: 1.6rem;
    font-weight: normal;
    margin-bottom: 0.4rem;
}

article time {
    display: block;
    font-size: 0.85rem;
    color: var(--muted);
    font-style: italic;
    font-family: sans-serif;
    margin-bottom: 1.5rem;
}

.content {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.5rem;
    box-shadow: var(--shadow);
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

.back {
    font-size: 0.9rem;
    font-family: sans-serif;
}

/* -- Formulaire -- */
.post-form {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

.post-form h2 {
    font-size: 1.4rem;
    font-weight: normal;
}

label {
    font-size: 0.9rem;
    font-family: sans-serif;
    color: var(--muted);
}

input[type="text"],
textarea {
    width: 100%;
    padding: 0.6rem 0.75rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-family: inherit;
    font-size: 1rem;
    background: var(--surface);
    color: var(--text);
    transition: border-color 0.15s;
}

input[type="text"]:focus,
textarea:focus {
    outline: none;
    border-color: var(--accent);
}

textarea {
    resize: vertical;
}

main h2 {
    font-size: 1.4rem;
    font-weight: normal;
    margin-bottom: 1rem;
}

/* -- Erreurs -- */
.errors {
    list-style: none;
    background: #fdf0ef;
    border: 1px solid #f5c6c2;
    border-radius: var(--radius);
    padding: 0.75rem 1rem;
    margin-bottom: 1rem;
    font-family: sans-serif;
    font-size: 0.9rem;
    color: var(--accent);
}
