:root {
    --primary-color: #2C3E50;
    --secondary-color: #3498DB;
    --accent-color: #E74C3C;
    --text-color: #333;
    --light-bg: #F8F9FA;
    --border-radius: 8px;
    --spacing: 1rem;
}

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

body {
    padding-top: 80px; /* Ajustez cette valeur si nécessaire */
    font-family: 'Segoe UI', system-ui, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing);
}

/* Header */
.site-header {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 2rem 0;
}

.main-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

.nav-links {
    display: flex;
    gap: 1rem;
}

.hero-section {
    text-align: center;
    padding: 4rem 0;
}

.hero-section h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.8rem 1.5rem;
    border-radius: var(--border-radius);
    text-decoration: none;
    transition: all 0.3s ease;
    font-weight: 500;
}

.btn-primary {
    background-color: var(--accent-color);
    color: white;
}

.btn-login {
    border: 2px solid white;
    color: white;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

/* Styles pour les publicités dans le feed */
.ad-banner {
    border-left: 4px solid #007bff !important;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.ad-banner:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,123,255,0.15) !important;
}

.ad-banner .card-body {
    position: relative;
}

.ad-banner::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 0;
    height: 0;
    border-left: 20px solid transparent;
    border-top: 20px solid #007bff;
}

.ad-banner .btn-primary {
    background: linear-gradient(45deg, #007bff, #0056b3);
    border: none;
    transition: all 0.3s ease;
}

.ad-banner .btn-primary:hover {
    background: linear-gradient(45deg, #0056b3, #004085);
    transform: translateY(-1px);
}


/* Fix pour éviter le chevauchement avec la navbar fixe */
.main-content {
    padding-top: 120px !important;
}

/* Styles pour le contenu des publications */
.publication-content {
    line-height: 1.6;
    word-wrap: break-word;
}

.publication-content p {
    margin-bottom: 10px;
}

.publication-content p:last-child {
    margin-bottom: 0;
}

.publication-content img, .publication-content video {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    margin: 10px 0;
}

.publication-content .editor-media-container {
    margin: 15px 0;
    display: block;
}

.publication-content .align-left {
    float: left;
    margin-right: 15px;
    margin-bottom: 10px;
    max-width: 50%;
}

.publication-content .align-right {
    float: right;
    margin-left: 15px;
    margin-bottom: 10px;
    max-width: 50%;
}

.publication-content .align-center {
    display: block;
    margin: 15px auto;
    text-align: center;
}

.publication-content strong {
    font-weight: 600;
}

.publication-content em {
    font-style: italic;
}

.publication-content u {
    text-decoration: underline;
}

/* Masquer les contrôles d'édition dans l'affichage final */
.publication-content .media-controls {
    display: none !important;
}

/* Styles pour les boutons de l'éditeur */
.btn-group .btn {
    border-radius: 6px !important;
    margin-right: 2px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.btn-group .btn:last-child {
    margin-right: 0;
}

.btn-group .btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.btn-outline-primary {
    border-color: #007bff;
    color: #007bff;
}

.btn-outline-primary:hover {
    background-color: #007bff;
    border-color: #007bff;
    color: white;
}

.btn-primary {
    background-color: #007bff;
    border-color: #007bff;
    color: white;
}

.btn-primary:hover {
    background-color: #0056b3;
    border-color: #0056b3;
}

/* Animation pour le bouton de sauvegarde */
.btn.btn-success {
    background-color: #28a745 !important;
    border-color: #28a745 !important;
    color: white !important;
}

/* Responsive pour les boutons */
@media (max-width: 768px) {
    .btn-group {
        display: flex;
        flex-wrap: wrap;
        gap: 5px;
    }
    
    .btn-group .btn {
        flex: 1;
        margin-right: 0;
        font-size: 12px;
        padding: 6px 8px;
    }
}

/* Service Sections */
.service-section {
    padding: 4rem 0;
}

.service-section:nth-child(even) {
    background-color: var(--light-bg);
}

.service-section h2 {
    text-align: center;
    margin-bottom: 3rem;
    color: var(--primary-color);
}

.service-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.service-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 2rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.service-card:hover {
    transform: translateY(-5px);
}

.service-card h3 {
    color: var(--secondary-color);
    margin-bottom: 1rem;
}

.service-card ul {
    list-style: none;
    margin-bottom: 1.5rem;
}

.service-card ul li {
    margin-bottom: 0.5rem;
    padding-left: 1.5rem;
    position: relative;
}

.service-card ul li::before {
    content: "→";
    position: absolute;
    left: 0;
    color: var(--accent-color);
}

/* Footer */
.site-footer {
    background-color: var(--primary-color);
    color: white;
    padding: 3rem 0;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
}

.footer-col h4 {
    margin-bottom: 1rem;
}

.footer-col ul {
    list-style: none;
}

.footer-col ul li {
    margin-bottom: 0.5rem;
}

.footer-col a {
    color: white;
    text-decoration: none;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.footer-col a:hover {
    opacity: 1;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-section h1 {
        font-size: 2rem;
    }
    
    .service-grid {
        grid-template-columns: 1fr;
    }
    
    .main-nav {
        flex-direction: column;
        gap: 1rem;
    }
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.service-card {
    animation: fadeIn 0.5s ease-out forwards;
}

.service-section:nth-child(1) .service-card { animation-delay: 0.1s; }
.service-section:nth-child(2) .service-card { animation-delay: 0.2s; }
.service-section:nth-child(3) .service-card { animation-delay: 0.3s; }
.service-section:nth-child(4) .service-card { animation-delay: 0.4s; }
