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

body {
    font-family: system-ui, sans-serif;
    color: #1a2b34;
    background-color: #f2ede1;
}

header {
    text-align: center;
    background-color: #f2ede1;
}

.logo img {
    width: 100%;
    max-width: 1100px;
    height: auto;
    display: block;
    margin: 0 auto;
}

nav {
    text-align: center;
    padding: 1rem 0 1.5rem;
    background-color: #f2ede1;
    border-top: 1px solid rgba(26, 43, 52, 0.1);
}

nav a {
    position: relative;
    margin: 0 1.8rem;
    text-decoration: none;
    color: #1a2b34;
    font-weight: 600;
    font-size: 0.95rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    padding-bottom: 6px;
    transition: color 0.2s ease;
}


nav a:hover {
    color: #d94f70;
}

/* Barre dégradée pour les liens simples (sans sous-menu) */
nav > a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #d94f70, #e8944a, #2f9e6f);
    transition: width 0.25s ease;
}

nav > a:hover::after {
    width: 100%;
}

/* Triangle pour les catégories avec sous-menu */
.nav-item > a::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: -2px;
    transform: translateX(-50%) scaleY(0);
    transform-origin: top;
    width: 0;
    height: 0;
    border-left: 7px solid transparent;
    border-right: 7px solid transparent;
    border-top: 8px solid #e8944a;
    transition: transform 0.2s ease;
}

.nav-item:hover > a::after {
    transform: translateX(-50%) scaleY(1);
}
main {
    padding: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

footer {
    text-align: center;
    padding: 1rem;
    color: #888;
}

.nav-item {
    position: relative;
    display: inline-block;
	padding-bottom: 20px;
    margin-bottom: -20px;
}

.sous-menu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    padding-top: 0.8rem;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    background-color: #f2ede1;
    z-index: 100;
    transition: opacity 0.2s ease;
}

.nav-item:hover .sous-menu {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.sous-lien {
    position: relative;
    margin: 0 !important;
    font-size: 0.85rem !important;
    white-space: nowrap;
    text-decoration: none;
    color: #1a2b34;
    padding-bottom: 4px;
}

.sous-lien::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #d94f70, #e8944a, #2f9e6f);
    transition: width 0.25s ease;
}

.nav-item:hover .sous-lien::after {
    width: 100%;
}

.article {
    max-width: 760px;
    margin: 0 auto;
}

.article-header {
	margin-bottom: 2.5rem;
    padding-bottom: 1.5rem;
    border-bottom: none;
    position: relative;
}

.article-header::after {
    content: "";
    display: block;
    width: 60px;
    height: 4px;
    background: linear-gradient(90deg, #d94f70, #e8944a, #2f9e6f);
    margin-top: 1rem;
    border-radius: 2px;
}

.article-header h1 {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 2.1rem;
    line-height: 1.3;
}
.article-date {
    color: #888;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.article p {
    line-height: 1.7;
    margin-bottom: 1.2rem;
    font-size: 1.05rem;
}

.article h2 {
    font-family: Georgia, "Times New Roman", serif;
    margin-top: 2.5rem;
    margin-bottom: 1rem;
    font-size: 1.5rem;
    color: #1a2b34;
    border-left: 4px solid #2f9e6f;
    padding-left: 0.8rem;
}

.article p:first-of-type {
    font-size: 1.15rem;
    color: #1a2b34;
}
.article code {
    background-color: rgba(26, 43, 52, 0.08);
    padding: 0.15rem 0.4rem;
    border-radius: 3px;
    font-size: 0.9em;
}

.article pre {
    background-color: #1a2b34;
    color: #e8e3d5;
    padding: 1.2rem;
    border-radius: 6px;
    overflow-x: auto;
    margin-bottom: 1.5rem;
}

.article pre code {
    background: none;
    padding: 0;
    color: inherit;
}

.form-admin {
    display: flex;
    flex-direction: column;
    max-width: 700px;
    gap: 0.3rem;
}

.form-admin label {
    margin-top: 1rem;
    font-weight: 600;
}

.form-admin input,
.form-admin textarea {
    padding: 0.6rem;
    border: 1px solid rgba(26, 43, 52, 0.2);
    border-radius: 4px;
    font-family: inherit;
    font-size: 1rem;
}

.form-admin button[type="submit"] {
    margin-top: 1.5rem;
    padding: 0.7rem;
    background-color: #2f9e6f;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 600;
}

.barre-outils {
    display: flex;
    gap: 0.4rem;
    margin-top: 0.5rem;
}

.barre-outils button {
    padding: 0.4rem 0.8rem;
    border: 1px solid rgba(26, 43, 52, 0.2);
    background-color: #f2ede1;
    border-radius: 4px;
    cursor: pointer;
}

.table-admin {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1.5rem;
}

.table-admin th, .table-admin td {
    text-align: left;
    padding: 0.6rem;
    border-bottom: 1px solid rgba(26, 43, 52, 0.1);
}

.erreur {
    color: #d94f70;
    font-weight: 600;
}

.article-img {
    max-width: 100%;
    height: auto;
    border-radius: 6px;
    margin: 1.5rem 0;
    display: block;
}

.video-wrapper {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%;
    margin: 1.5rem 0;
}

.video-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 6px;
}

.article a {
    color: #2f9e6f;
    text-decoration: underline;
}

.grille-categories {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
    margin-top: 2rem;
}

@media (max-width: 768px) {
    .grille-categories {
        grid-template-columns: 1fr;
    }
}

.bloc-sous-categorie h2 {
    border-left: 4px solid #2f9e6f;
    padding-left: 0.8rem;
    margin-bottom: 1.2rem;
}

.fil-articles {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.carte-article {
    background-color: #fdfbf6;
    border-radius: 12px;
    border: 0.5px solid rgba(26, 43, 52, 0.08);
    overflow: hidden;
    margin-bottom: 0;
    padding-bottom: 0;
}

.carte-article-bande {
    height: 5px;
    background: linear-gradient(90deg, #d94f70, #e8944a, #2f9e6f);
}

.carte-article-corps {
    padding: 1.2rem 1.4rem;
}

.carte-article-badge {
    font-size: 0.7rem;
    letter-spacing: 0.08em;
    color: #2f9e6f;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
    display: block;
}

.carte-article h3 {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 1.15rem;
    line-height: 1.35;
    margin-bottom: 0.5rem;
}

.carte-article h3 a {
    color: #1a2b34;
    text-decoration: none;
}

.carte-article h3 a:hover {
    color: #d94f70;
}

.carte-article p {
    font-size: 0.9rem;
    color: #5f5e5a;
    line-height: 1.6;
}

.carte-article .meta {
    margin-top: 0.8rem;
    font-size: 0.75rem;
    color: #888780;
}

.page-article {
    display: grid;
    grid-template-columns: 1fr 280px;
    gap: 3rem;
    max-width: 1200px;
    margin: 0 auto;
}

.page-article .article {
    max-width: none;
}

.menu-lateral {
    border-left: 1px solid rgba(26, 43, 52, 0.1);
    padding-left: 1.5rem;
}

.menu-lateral h3 {
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 1rem;
    color: #2f9e6f;
}

.menu-lateral ul {
    list-style: none;
}

.menu-lateral li {
    margin-bottom: 0.8rem;
}

.menu-lateral a {
    color: #1a2b34;
    text-decoration: none;
    font-size: 0.9rem;
    line-height: 1.4;
}

.menu-lateral a:hover {
    color: #d94f70;
}

@media (max-width: 900px) {
    .page-article {
        grid-template-columns: 1fr;
    }
    .menu-lateral {
        border-left: none;
        border-top: 1px solid rgba(26, 43, 52, 0.1);
        padding-left: 0;
        padding-top: 1.5rem;
    }
}

.btn-supprimer {
    background-color: #d94f70;
    color: white;
    border: none;
    padding: 0.3rem 0.7rem;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.85rem;
}
