/*
Theme Name: Le Déca Littéraire
Theme URI: 
Author: Antigravity
Description: Thème sur mesure inspiré de la chaîne YouTube Le Déca Littéraire.
Version: 1.0
*/

@import url('https://fonts.googleapis.com/css2?family=Lora:ital,wght@0,400;0,700;1,400&family=Playfair+Display:wght@400;700&display=swap');

:root {
    --bg-color: #f4f1ea;
    --text-color: #2c251d;
    --accent-color: #8b3a3a;
    --border-color: #d1c7b7;
    --header-bg: #e2d8c3;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: 'Lora', serif;
    margin: 0;
    padding: 0;
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Playfair Display', serif;
    color: var(--text-color);
}

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

/* Header & Banner */
.site-header {
    text-align: center;
    border-bottom: 2px solid var(--border-color);
}

.banner-container {
    width: 100%;
}

.banner-container img {
    width: 100%;
    height: auto;
    display: block;
}

/* Navigation */
.main-navigation {
    background-color: var(--header-bg);
    padding: 10px 0;
}

.main-navigation ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
}

.main-navigation li {
    position: relative;
    margin: 0 15px;
}

.main-navigation a {
    font-family: 'Playfair Display', serif;
    font-size: 1.1em;
    color: var(--text-color);
    text-transform: uppercase;
    font-weight: 700;
    padding: 10px 15px;
    display: block;
}

/* Dropdown */
.main-navigation ul ul {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background-color: var(--header-bg);
    border: 1px solid var(--border-color);
    min-width: 200px;
    z-index: 100;
    flex-direction: column;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.main-navigation li:hover > ul {
    display: flex;
}

.main-navigation ul ul li {
    margin: 0;
    border-bottom: 1px solid var(--border-color);
}

.main-navigation ul ul a {
    text-transform: none;
    font-size: 1em;
    font-weight: 400;
}

.main-navigation ul ul a:hover {
    background-color: var(--bg-color);
}

/* Ticker */
.ticker-wrap {
    width: 100%;
    overflow: hidden;
    background-color: var(--text-color);
    color: var(--bg-color);
    padding: 8px 0;
    border-bottom: 3px solid var(--accent-color);
}

.ticker {
    display: inline-block;
    white-space: nowrap;
    padding-left: 100%;
    animation: ticker 75s linear infinite;
    font-style: italic;
}

.ticker-item {
    margin-right: 150px;
}

@keyframes ticker {
    0% { transform: translate3d(0, 0, 0); }
    100% { transform: translate3d(-100%, 0, 0); }
}

/* Layout */
.site-content {
    display: flex;
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px;
    gap: 40px;
}

.main-column {
    flex: 1;
}

.sidebar-column {
    width: 300px;
    flex-shrink: 0;
}

/* Masonry Grid */
.masonry-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    align-items: start;
}

.grid-item {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.grid-item img {
    width: 100%;
    height: auto;
    display: block;
}

.grid-item-content {
    padding: 15px;
}

.grid-item h2 {
    font-size: 1.2em;
    margin-top: 0;
}

/* Sidebar Elements */
.widget {
    margin-bottom: 30px;
    background: #fff;
    padding: 20px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
}

.widget-title {
    font-size: 1.3em;
    border-bottom: 2px solid var(--accent-color);
    padding-bottom: 10px;
    margin-bottom: 20px;
}

/* Timeline V2 */
.timeline-container {
    position: relative;
    padding-top: 10px;
}

.timeline-container::before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: 77px; /* Center of the circle: pill width (54px) + margin (15px) + half circle (15px) - something like that. Let's precise: 54 + 15 + 15 = 84px */
    width: 2px;
    background-color: var(--text-color);
    z-index: 1;
}

.timeline-row {
    display: flex;
    align-items: center;
    margin-bottom: 25px;
    position: relative;
    z-index: 2;
}

.timeline-pill {
    background-color: var(--text-color);
    color: var(--bg-color);
    padding: 6px 12px;
    border-radius: 20px;
    font-family: 'Playfair Display', serif;
    font-weight: bold;
    font-size: 1em;
    min-width: 50px;
    text-align: center;
}

.timeline-circle {
    width: 32px;
    height: 32px;
    background-color: var(--text-color);
    border-radius: 50%;
    margin: 0 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.timeline-circle::before {
    content: "\f330"; /* dashicon-book-alt */
    font-family: dashicons;
    color: var(--bg-color);
    font-size: 18px;
}

.timeline-content {
    flex: 1;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 10px;
    font-size: 0.85em;
    text-transform: uppercase;
    font-weight: bold;
    color: var(--text-color);
    line-height: 1.4;
}

/* Mobile Sidebar Toggle */
.mobile-sidebar-toggle {
    display: none;
    width: 100%;
    padding: 15px;
    background: var(--text-color);
    color: var(--bg-color);
    text-align: center;
    font-family: 'Playfair Display', serif;
    font-size: 1.2em;
    border: none;
    cursor: pointer;
    margin-bottom: 20px;
}

/* Responsive */
@media (max-width: 900px) {
    .masonry-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .site-content {
        flex-direction: column;
    }
    
    .sidebar-column {
        width: 100%;
        display: none;
    }
    
    .sidebar-column.active {
        display: block;
    }
    
    .mobile-sidebar-toggle {
        display: block;
    }

    .masonry-grid {
        grid-template-columns: 1fr;
    }

    .main-navigation ul {
        flex-direction: column;
        align-items: center;
    }

    .main-navigation li {
        width: 100%;
        text-align: center;
    }

    .main-navigation ul ul {
        position: static;
        display: none;
    }
}
