/**
 * Styles CSS pour la partie publique du plugin AutopostWP
 */

/* Si besoin d'ajouter des styles spécifiques pour les articles créés via AutopostWP */
.autopost-article {
    font-family: var(--wp--preset--font-family--body, inherit);
    color: var(--wp--preset--color--contrast, inherit);
}

/* Styles pour les blocs de template communs */
.autopost-article blockquote {
    border-left: 4px solid #e2e4e7;
    padding-left: 1em;
    margin-left: 0;
    font-style: italic;
}

.autopost-article .template-highlight {
    background-color: #f8f9fa;
    border: 1px solid #e2e4e7;
    padding: 15px;
    margin-bottom: 20px;
}

.autopost-article .template-note {
    background-color: #e8f5e9;
    border-left: 4px solid #4caf50;
    padding: 15px;
    margin-bottom: 20px;
}

.autopost-article .template-warning {
    background-color: #fff3cd;
    border-left: 4px solid #ffc107;
    padding: 15px;
    margin-bottom: 20px;
}

.autopost-article .template-steps {
    counter-reset: step-counter;
    list-style: none;
    padding-left: 0;
}

.autopost-article .template-steps li {
    position: relative;
    padding-left: 3em;
    padding-bottom: 1.5em;
    margin-bottom: 1em;
}

.autopost-article .template-steps li::before {
    content: counter(step-counter);
    counter-increment: step-counter;
    position: absolute;
    left: 0;
    top: 0;
    width: 2em;
    height: 2em;
    border-radius: 50%;
    background-color: #2271b1;
    color: white;
    text-align: center;
    line-height: 2em;
    font-weight: bold;
}

/* Styles responsifs */
@media screen and (max-width: 782px) {
    .autopost-article .template-steps li {
        padding-left: 2.5em;
    }
}

/* Styles généraux pour les blocs AutopostWP */
.autopost-block {
    margin: 2rem 0;
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.autopost-block:hover {
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
    transform: translateY(-3px);
}

/* Témoignages */
.testimonial-block {
    background-color: #f8f9fa;
    border-left: 4px solid #6c63ff;
    padding: 1.5rem;
}

.testimonial-content {
    font-style: italic;
    font-size: 1.1rem;
    color: #555;
    position: relative;
    padding: 0 1rem;
}

.testimonial-content::before {
    content: '"';
    font-size: 3rem;
    color: #ddd;
    position: absolute;
    left: -10px;
    top: -20px;
    line-height: 1;
    font-family: Georgia, serif;
}

.testimonial-author {
    display: flex;
    align-items: center;
    margin-top: 1rem;
}

.testimonial-author-photo {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
    margin-right: 1rem;
    border: 2px solid #fff;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.testimonial-author-info {
    line-height: 1.4;
}

.testimonial-author-name {
    font-weight: bold;
    font-size: 1rem;
    margin: 0;
}

.testimonial-author-position {
    font-size: 0.85rem;
    color: #777;
    margin: 0;
}

/* Carrousel de témoignages */
.testimonial-carousel {
    position: relative;
    padding: 2rem 0;
}

.testimonial-carousel .testimonial-item {
    display: none;
}

.testimonial-carousel .testimonial-item.active {
    display: block;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.testimonial-carousel-nav {
    display: flex;
    justify-content: center;
    margin-top: 1rem;
}

.testimonial-carousel-nav button {
    background: #6c63ff;
    color: white;
    border: none;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    margin: 0 0.25rem;
    cursor: pointer;
    transition: background 0.3s ease;
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.testimonial-carousel-nav button:hover {
    background: #5a52d5;
}

/* FAQ Accordéon */
.faq-accordion {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
}

.faq-item {
    border-bottom: 1px solid #eee;
}

.faq-question {
    padding: 1rem 1.5rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.faq-question:hover {
    background-color: #f9f9f9;
}

.faq-question::after {
    content: '+';
    font-size: 1.2rem;
    transition: transform 0.3s ease;
}

.faq-item.active .faq-question::after {
    transform: rotate(45deg);
    content: '+';
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease;
}

.faq-item.active .faq-answer {
    max-height: 500px;
}

.faq-answer-inner {
    padding: 0 1.5rem 1.5rem;
    color: #666;
}

/* Tableaux comparatifs */
.comparison-table {
    width: 100%;
    border-collapse: collapse;
    margin: 2rem 0;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    overflow: hidden;
}

.comparison-table thead {
    background: #6c63ff;
    color: #fff;
}

.comparison-table th {
    padding: 1.2rem 1rem;
    text-align: left;
}

.comparison-table th:first-child {
    border-top-left-radius: 8px;
}

.comparison-table th:last-child {
    border-top-right-radius: 8px;
}

.comparison-table tr:nth-child(even) {
    background-color: #f8f9fa;
}

.comparison-table td {
    padding: 1rem;
    border-top: 1px solid #eee;
}

.comparison-table td.feature-name {
    font-weight: 600;
}

.comparison-table .best-value {
    background-color: rgba(108, 99, 255, 0.1);
    position: relative;
}

.comparison-table .best-value::after {
    content: 'RECOMMANDÉ';
    position: absolute;
    top: 0;
    right: 0;
    background: #6c63ff;
    color: white;
    font-size: 0.7rem;
    padding: 3px 8px;
    transform: translateY(-50%);
    border-radius: 2px;
}

/* Tableaux enrichis alignés sur la charte globale */
.autopost-article .dk-table {
    --dk-font-family: var(--wp--preset--font-family--body, var(--global-font-family, "Inter", "Segoe UI", -apple-system, BlinkMacSystemFont, system-ui, sans-serif));
    --dk-head-font: var(--wp--preset--font-family--heading, var(--dk-font-family));
    --dk-text: var(--wp--preset--color--contrast, #1f1f1f);
    --dk-muted: var(--wp--preset--color--neutral, #5f6368);
    --dk-surface: var(--wp--preset--color--base, #ffffff);
    --dk-accent: var(--wp--preset--color--primary, #6c63ff);
    --dk-border: var(--wp--preset--color--border, rgba(15, 23, 42, 0.12));
    --dk-alt: var(--wp--preset--color--secondary, #f5f6fb);
    --dk-row-alt: rgba(245, 246, 251, 0.45);
    --dk-row-alt: color-mix(in srgb, var(--dk-alt) 70%, transparent);
    margin: 2.5rem auto;
    padding: 1.5rem;
    border-radius: 24px;
    border: 1px solid var(--dk-border);
    background: var(--dk-surface);
    box-shadow: 0 25px 60px rgba(15, 23, 42, 0.08);
    color: var(--dk-text);
    font-family: var(--dk-font-family);
    max-width: min(1200px, 100%);
}

.autopost-article .dk-table__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.autopost-article .dk-table__title {
    font-family: var(--dk-head-font);
    font-size: clamp(1.1rem, 2vw, 1.5rem);
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--dk-text);
    margin: 0;
}

.autopost-article .dk-table__badge {
    background: var(--dk-accent);
    color: #fff;
    font-size: 0.78rem;
    font-weight: 600;
    padding: 0.35rem 0.9rem;
    border-radius: 999px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.autopost-article .dk-table__scroll {
    overflow-x: auto;
    margin: 0 -0.5rem;
    padding: 0 0.5rem 0.5rem;
}

.autopost-article .dk-table table {
    width: 100%;
    min-width: 720px;
    border-collapse: collapse;
    font-size: 0.95rem;
}

.autopost-article .dk-table th,
.autopost-article .dk-table td {
    padding: 1rem 1.25rem;
    text-align: left;
    vertical-align: top;
    border-bottom: 1px solid var(--dk-border);
}

.autopost-article .dk-table th {
    font-family: var(--dk-head-font);
    font-size: 0.78rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--dk-muted);
    background: var(--dk-alt);
    position: sticky;
    top: 0;
    z-index: 1;
}

.autopost-article .dk-table tr:last-child th,
.autopost-article .dk-table tr:last-child td {
    border-bottom: none;
}

.autopost-article .dk-table tbody tr:nth-child(odd) td {
    background: rgba(245, 246, 251, 0.35);
    background: var(--dk-row-alt);
}

.autopost-article .dk-table td strong {
    color: var(--dk-text);
    display: block;
    font-size: 1rem;
}

.autopost-article .dk-table td em {
    color: var(--dk-muted);
    font-style: normal;
    font-size: 0.9rem;
}

.autopost-article .dk-table .dk-table__rank {
    font-weight: 700;
    color: var(--dk-accent);
    font-size: 1.05rem;
}

.autopost-article .dk-table .dk-table__tag {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid var(--dk-border);
    border-radius: 999px;
    padding: 0.2rem 0.8rem;
    font-size: 0.8rem;
    color: var(--dk-muted);
}

.autopost-article .dk-table--compact table {
    min-width: auto;
}

@media (max-width: 782px) {
    .autopost-article .dk-table {
        padding: 1.1rem;
        border-radius: 18px;
    }

    .autopost-article .dk-table th,
    .autopost-article .dk-table td {
        padding: 0.85rem 0.9rem;
        font-size: 0.9rem;
    }
}

/* Avantages / Inconvénients */
.pros-cons {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
}

.pros-block, .cons-block {
    flex: 1;
    min-width: 250px;
    padding: 1.5rem;
    border-radius: 8px;
}

.pros-block {
    background-color: rgba(40, 167, 69, 0.1);
    border-left: 4px solid #28a745;
}

.cons-block {
    background-color: rgba(220, 53, 69, 0.1);
    border-left: 4px solid #dc3545;
}

.pros-cons h3 {
    margin-top: 0;
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.pros-block h3 {
    color: #28a745;
}

.cons-block h3 {
    color: #dc3545;
}

.pros-cons ul {
    margin: 0;
    padding-left: 1.5rem;
}

.pros-cons li {
    margin-bottom: 0.5rem;
    position: relative;
}

.pros-block li::marker {
    color: #28a745;
}

.cons-block li::marker {
    color: #dc3545;
}

/* Images avec texte (gauche/droite) */
.image-text-block {
    display: flex;
    align-items: center;
    margin: 2rem 0;
    gap: 2rem;
}

.image-text-left .image-container {
    order: 1;
}

.image-text-right .image-container {
    order: 2;
}

.image-text-left .text-container {
    order: 2;
}

.image-text-right .text-container {
    order: 1;
}

.image-container {
    flex: 0 0 40%;
}

.image-container img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
}

.image-container img:hover {
    transform: scale(1.02);
}

.text-container {
    flex: 1;
}

/* Statistiques */
.stats-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-around;
    text-align: center;
    margin: 2rem 0;
    gap: 1.5rem;
}

.stat-item {
    flex: 1;
    min-width: 150px;
    padding: 1.5rem;
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.stat-item:hover {
    transform: translateY(-5px);
}

.stat-value {
    font-size: 2.5rem;
    font-weight: 700;
    color: #6c63ff;
    line-height: 1;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.9rem;
    color: #666;
}

/* Timeline */
.timeline {
    position: relative;
    margin: 3rem 0;
    padding-left: 2rem;
}

.timeline::before {
    content: '';
    position: absolute;
    width: 2px;
    background-color: #ddd;
    top: 0;
    bottom: 0;
    left: 8px;
}

.timeline-item {
    margin-bottom: 2rem;
    position: relative;
}

.timeline-item::before {
    content: '';
    position: absolute;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background-color: #6c63ff;
    left: -2.3rem;
    top: 0;
    z-index: 1;
}

.timeline-item:last-child {
    margin-bottom: 0;
}

.timeline-date {
    font-weight: 600;
    color: #6c63ff;
    margin-bottom: 0.5rem;
}

.timeline-title {
    font-size: 1.1rem;
    margin-top: 0;
    margin-bottom: 0.5rem;
}

.timeline-description {
    color: #666;
}

/* Vidéo responsive */
.video-container {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 ratio */
    height: 0;
    overflow: hidden;
    max-width: 100%;
    margin: 2rem 0;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

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

.video-caption {
    margin-top: 1rem;
    font-size: 0.9rem;
    color: #666;
    text-align: center;
}

/* Section d'instructions par étapes */
.steps-container {
    counter-reset: step-counter;
    margin: 2rem 0;
}

.step-item {
    display: flex;
    margin-bottom: 2rem;
    position: relative;
}

.step-number {
    flex: 0 0 60px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: #6c63ff;
    color: white;
    font-size: 1.5rem;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 1.5rem;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    z-index: 1;
}

.step-content {
    flex: 1;
}

.step-item:not(:last-child)::after {
    content: '';
    position: absolute;
    left: 30px;
    top: 60px;
    bottom: -30px;
    width: 2px;
    background-color: #eee;
    transform: translateX(-50%);
    z-index: 0;
}

.step-title {
    margin-top: 0;
    margin-bottom: 0.75rem;
    font-size: 1.2rem;
    color: #333;
}

.step-description {
    color: #666;
    margin-bottom: 1rem;
}

.step-image {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin-top: 1rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Boîtes d'avertissement et d'info */
.notice-box {
    padding: 1.5rem;
    margin: 1.5rem 0;
    border-radius: 6px;
    position: relative;
    padding-left: 4rem;
}

.notice-box::before {
    font-family: dashicons;
    position: absolute;
    left: 1.25rem;
    top: 1.4rem;
    font-size: 1.5rem;
}

.warning-box {
    background-color: rgba(255, 193, 7, 0.15);
    border-left: 4px solid #ffc107;
}

.warning-box::before {
    content: "\f534";
    color: #ffc107;
}

.info-box {
    background-color: rgba(23, 162, 184, 0.15);
    border-left: 4px solid #17a2b8;
}

.info-box::before {
    content: "\f348";
    color: #17a2b8;
}

.success-box {
    background-color: rgba(40, 167, 69, 0.15);
    border-left: 4px solid #28a745;
}

.success-box::before {
    content: "\f147";
    color: #28a745;
}

.error-box {
    background-color: rgba(220, 53, 69, 0.15);
    border-left: 4px solid #dc3545;
}

.error-box::before {
    content: "\f153";
    color: #dc3545;
}

.notice-title {
    margin-top: 0;
    margin-bottom: 0.75rem;
    font-size: 1.2rem;
}

/* CTA (Call to Action) */
.cta-block {
    background: linear-gradient(135deg, #6c63ff 0%, #5a52d5 100%);
    color: white;
    padding: 3rem 2rem;
    text-align: center;
    border-radius: 8px;
    margin: 3rem 0;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.cta-title {
    font-size: 1.8rem;
    margin-top: 0;
    margin-bottom: 1rem;
}

.cta-description {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.cta-button {
    display: inline-block;
    padding: 0.75rem 2rem;
    background-color: white;
    color: #6c63ff;
    border-radius: 50px;
    font-weight: bold;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.15);
    background: #f8f9fa;
}

/* Bloc newsletter */
.newsletter-block {
    background-color: #f8f9fa;
    padding: 2rem;
    border-radius: 8px;
    text-align: center;
    margin: 2rem 0;
}

.newsletter-title {
    font-size: 1.5rem;
    margin-top: 0;
    margin-bottom: 1rem;
}

.newsletter-description {
    color: #666;
    margin-bottom: 1.5rem;
}

.newsletter-form {
    max-width: 500px;
    margin: 0 auto;
    display: flex;
    gap: 0.5rem;
}

.newsletter-input {
    flex: 1;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 0.95rem;
}

.newsletter-button {
    padding: 0.75rem 1.5rem;
    background: #6c63ff;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.3s ease;
    font-weight: 500;
}

.newsletter-button:hover {
    background: #5a52d5;
}

.newsletter-notice {
    font-size: 0.8rem;
    color: #888;
    margin-top: 1rem;
}

/* Galerie d'images */
.gallery-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1rem;
    margin: 2rem 0;
}

.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.gallery-item:hover {
    transform: translateY(-5px);
}

.gallery-item img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.gallery-item:hover img {
    transform: scale(1.05);
}

.gallery-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 0.75rem;
    transform: translateY(100%);
    transition: transform 0.3s ease;
    font-size: 0.9rem;
}

.gallery-item:hover .gallery-caption {
    transform: translateY(0);
}

/* Bloc de tarification */
.pricing-block {
    background: white;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    padding: 2rem;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin: 2rem 0;
    max-width: 350px;
    display: inline-block;
}

.pricing-block:hover {
    transform: translateY(-10px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.pricing-title {
    font-size: 1.5rem;
    margin-top: 0;
    margin-bottom: 1.5rem;
    color: #333;
}

.pricing-price {
    font-size: 3rem;
    font-weight: 700;
    color: #6c63ff;
    margin-bottom: 0.5rem;
}

.pricing-currency {
    font-size: 1.5rem;
    vertical-align: super;
    margin-right: 5px;
}

.pricing-period {
    display: block;
    font-size: 0.9rem;
    color: #888;
    margin-bottom: 1.5rem;
}

.pricing-features {
    list-style: none;
    padding: 0;
    margin: 0 0 2rem;
    text-align: left;
}

.pricing-features li {
    padding: 0.75rem 0;
    border-bottom: 1px solid #f0f0f0;
    color: #666;
}

.pricing-features li::before {
    content: "✓";
    color: #6c63ff;
    margin-right: 0.75rem;
    font-weight: bold;
}

.pricing-button {
    display: inline-block;
    padding: 0.75rem 2rem;
    background-color: #6c63ff;
    color: white;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: background 0.3s ease;
}

.pricing-button:hover {
    background-color: #5a52d5;
}

/* Responsive Design */
@media (max-width: 768px) {
    .image-text-block {
        flex-direction: column;
    }
    
    .image-text-left .image-container,
    .image-text-right .image-container,
    .image-text-left .text-container,
    .image-text-right .text-container {
        order: unset;
    }
    
    .image-container {
        margin-bottom: 1.5rem;
    }
    
    .pros-cons {
        flex-direction: column;
    }
    
    .newsletter-form {
        flex-direction: column;
    }
    
    .newsletter-button {
        margin-top: 0.5rem;
    }
}

/* Scripts pour les éléments interactifs */
.js-accordion .faq-question {
    cursor: pointer;
}

.js-carousel .testimonial-carousel-nav {
    display: flex;
    justify-content: center;
    margin-top: 15px;
}

.js-carousel .carousel-dots {
    display: flex;
}

.js-carousel .carousel-dots .dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #ddd;
    margin: 0 5px;
    cursor: pointer;
}

.js-carousel .carousel-dots .dot.active {
    background: #6c63ff;
} 