/**
 * Séances Hebdomadaire Widget
 * ===========================
 * Weekly calendar view for parliamentary sessions.
 * Based on Figma design specifications.
 */

/* Section Container */
.seances-hebdo {
    padding: 60px 0;
    background: #FFFFFF;
}

.seances-hebdo__container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
.seances-hebdo__header {
    text-align: center;
    margin-bottom: 40px;
}

/* Filter Bar */
.seances-hebdo__filters {
    background: #FFFFFF;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 30px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #E0E0E0;
}

.seances-hebdo__filter-row {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 15px;
}

.seances-hebdo__filter-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex: 1 1 210px;
    min-width: 210px;
}

.seances-hebdo__filter-group--date {
    flex: 2 1 340px;
    min-width: 320px;
}

.seances-hebdo__filter-label {
    font-family: 'Lato', 'Roboto', sans-serif;
    font-size: 12px;
    font-weight: 600;
    color: #666666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.seances-hebdo__date-inputs {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.seances-hebdo__date-input {
    padding: 8px 10px;
    border: 1px solid #E0E0E0;
    border-radius: 7px;
    font-family: 'Lato', 'Roboto', sans-serif;
    font-size: 13px;
    color: #333333;
    background: #FFFFFF;
    min-width: 140px;
    flex: 1 1 160px;
}

.seances-hebdo__date-separator {
    font-size: 14px;
    color: #666666;
}

.seances-hebdo__select {
    padding: 8px 34px 8px 10px;
    border: 1px solid #E0E0E0;
    border-radius: 7px;
    font-family: 'Lato', 'Roboto', sans-serif;
    font-size: 13px;
    color: #333333;
    background: #FFFFFF url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23666666'%3E%3Cpath d='M7 10l5 5 5-5z'/%3E%3C/svg%3E") no-repeat right 10px center;
    background-size: 20px;
    appearance: none;
    cursor: pointer;
    width: 100%;
}

.seances-hebdo__filter-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: #0E8040;
    color: #FFFFFF;
    border: none;
    border-radius: 8px;
    font-family: 'Lato', 'Roboto', sans-serif;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s ease;
    flex: 0 0 auto;
    white-space: nowrap;
}

.seances-hebdo__filter-btn:hover {
    background: #0a6030;
}

/* Week Selector */
.seances-hebdo__week-selector {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.seances-hebdo__week-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.seances-hebdo__week-label {
    font-family: 'Lato', 'Roboto', sans-serif;
    font-size: 14px;
    color: #666666;
}

.seances-hebdo__week-select {
    padding: 10px 35px 10px 16px;
    border: 1px solid #E0E0E0;
    border-radius: 8px;
    font-family: 'Lato', 'Roboto', sans-serif;
    font-size: 14px;
    font-weight: 600;
    color: #333333;
    background: #FFFFFF url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23666666'%3E%3Cpath d='M7 10l5 5 5-5z'/%3E%3C/svg%3E") no-repeat right 10px center;
    background-size: 20px;
    appearance: none;
    cursor: pointer;
}

.seances-hebdo__calendar-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: #333333;
    color: #FFFFFF;
    border: none;
    border-radius: 8px;
    font-family: 'Lato', 'Roboto', sans-serif;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.3s ease;
}

.seances-hebdo__calendar-btn:hover {
    background: #444444;
}

/* Calendar Grid */
.seances-hebdo__calendar {
    background: #FFFFFF;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #E0E0E0;
}

/* Day Headers */
.seances-hebdo__day-headers {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    background: #F5F5F5;
}

.seances-hebdo__day-header {
    padding: 16px 12px;
    text-align: center;
    font-family: 'Lato', 'Roboto', sans-serif;
    font-size: 14px;
    font-weight: 700;
    color: #333333;
    border-right: 1px solid #E0E0E0;
}

.seances-hebdo__day-header:last-child {
    border-right: none;
}

/* Day Columns */
.seances-hebdo__day-columns {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    min-height: 400px;
}

.seances-hebdo__day-column {
    padding: 16px;
    border-right: 1px solid #E0E0E0;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.seances-hebdo__day-column:last-child {
    border-right: none;
}

/* Session Cards */
.seances-hebdo__seance-card {
    background: #FFFFFF;
    border-radius: 12px;
    padding: 16px;
    border-left: 4px solid #0E8040;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.seances-hebdo__seance-card--pleniere {
    border-left-color: #0E8040;
}

.seances-hebdo__seance-card--commission {
    border-left-color: #ED2024;
}

.seances-hebdo__seance-time {
    margin-bottom: 12px;
}

.seances-hebdo__time-badge {
    display: inline-block;
    padding: 6px 14px;
    background: #0E8040;
    color: #FFFFFF;
    border-radius: 20px;
    font-family: 'Lato', 'Roboto', sans-serif;
    font-size: 14px;
    font-weight: 700;
}

.seances-hebdo__seance-card--commission .seances-hebdo__time-badge {
    background: #ED2024;
}

.seances-hebdo__seance-content {
    margin-bottom: 16px;
}

.seances-hebdo__seance-title {
    font-family: 'Lato', 'Roboto', sans-serif;
    font-size: 14px;
    font-weight: 700;
    color: #333333;
    margin: 0 0 8px 0;
    text-transform: uppercase;
}

.seances-hebdo__seance-location {
    font-size: 13px;
    color: #666666;
    margin: 0 0 8px 0;
}

.seances-hebdo__seance-description {
    font-size: 13px;
    color: #666666;
    margin: 0;
    line-height: 1.5;
}

.seances-hebdo__seance-commissions {
    margin: 8px 0 0 0;
    padding-left: 16px;
    font-size: 12px;
    color: #666666;
}

.seances-hebdo__seance-commissions li {
    margin-bottom: 4px;
}

/* Session Actions */
.seances-hebdo__seance-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-top: 12px;
    border-top: 1px solid #E0E0E0;
}

.seances-hebdo__seance-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border-radius: 6px;
    font-family: 'Lato', 'Roboto', sans-serif;
    font-size: 12px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
}

.seances-hebdo__seance-link--primary {
    background: #ED2024;
    color: #FFFFFF;
}

.seances-hebdo__seance-link--primary:hover {
    background: #c91a1e;
    color: #FFFFFF;
    text-decoration: none;
}

.seances-hebdo__seance-link--secondary {
    background: transparent;
    color: #0E8040;
    border: 1px solid #0E8040;
}

.seances-hebdo__seance-link--secondary:hover {
    background: #0E8040;
    color: #FFFFFF;
    text-decoration: none;
}

/* Empty Day State */
.seances-hebdo__empty-day {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    min-height: 100px;
    color: #999999;
    font-size: 14px;
}

/* Responsive Design */
@media (max-width: 1200px) {
    .seances-hebdo__filter-row {
        flex-wrap: wrap;
    }

    .seances-hebdo__filter-group {
        min-width: 200px;
    }
}

@media (min-width: 992px) {
    .seances-hebdo__filter-row {
        display: grid;
        grid-template-columns: minmax(320px, 360px) minmax(180px, 220px) minmax(180px, 220px) minmax(180px, 220px) auto;
        align-items: end;
        gap: 24px;
    }

    .seances-hebdo__filter-group,
    .seances-hebdo__filter-group--date {
        min-width: 0;
    }

    .seances-hebdo__date-inputs {
        display: grid;
        grid-template-columns: minmax(130px, 1fr) auto minmax(130px, 1fr);
        align-items: center;
        gap: 10px;
        flex-wrap: nowrap;
    }

    .seances-hebdo__date-input {
        min-width: 0;
        width: 100%;
        flex: 0 0 auto;
    }
}

@media (max-width: 992px) {

    .seances-hebdo__day-headers,
    .seances-hebdo__day-columns {
        grid-template-columns: repeat(3, 1fr);
    }

    .seances-hebdo__day-header:nth-child(4),
    .seances-hebdo__day-header:nth-child(5),
    .seances-hebdo__day-column:nth-child(4),
    .seances-hebdo__day-column:nth-child(5) {
        display: none;
    }
}

@media (max-width: 768px) {
    .seances-hebdo {
        padding: 40px 0;
    }

    .seances-hebdo__filter-row {
        flex-direction: column;
    }

    .seances-hebdo__filter-group {
        width: 100%;
    }

    .seances-hebdo__date-inputs {
        flex-wrap: wrap;
    }

    .seances-hebdo__date-input {
        min-width: 100%;
        flex: 1;
    }

    .seances-hebdo__week-selector {
        flex-direction: column;
        gap: 15px;
        align-items: flex-start;
    }

    .seances-hebdo__day-headers,
    .seances-hebdo__day-columns {
        grid-template-columns: 1fr;
    }

    .seances-hebdo__day-header,
    .seances-hebdo__day-column {
        display: block !important;
        border-right: none;
        border-bottom: 1px solid #E0E0E0;
    }

    .seances-hebdo__day-column:last-child {
        border-bottom: none;
    }
}

@media (max-width: 576px) {
    .seances-hebdo__container {
        padding: 0 15px;
    }

    .seances-hebdo__filters {
        padding: 15px;
    }

    .seances-hebdo__seance-card {
        padding: 12px;
    }

    .seances-hebdo__seance-actions {
        flex-direction: column;
    }
}
