/* ==========================================================================
   PAEEJ TECHNOPOLE â€” DETAIL-PROGRAMME.CSS (relookÃ© Lot 9)
   ========================================================================== */

body { background: #f6f8fb; }

/* ====== HERO DÃ‰TAIL ====== */
.detail-hero {
    background: linear-gradient(180deg, #054c7a 0%, #043a5e 100%);
    color: #fff;
    padding: 32px 0 50px;
    position: relative;
}
.detail-hero::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 80px;
    background: linear-gradient(180deg, transparent 0%, #f6f8fb 100%);
    pointer-events: none;
}
.detail-hero .container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 40px;
    position: relative;
    z-index: 2;
}
.detail-breadcrumb {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.detail-breadcrumb a {
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
}
.detail-breadcrumb a:hover {
    color: #f5d68f;
}
.detail-breadcrumb .sep {
    color: rgba(255, 255, 255, 0.4);
}
.detail-breadcrumb .current {
    color: #f5d68f;
    font-weight: 500;
}

.detail-cat-tag {
    display: inline-block;
    background: rgba(196, 147, 44, 0.25);
    color: #f5d68f;
    padding: 5px 14px;
    border-radius: 14px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.5px;
    margin-bottom: 14px;
    text-transform: uppercase;
}
.detail-hero h1 {
    font-family: 'League Spartan', sans-serif;
    font-size: 38px;
    font-weight: 600;
    line-height: 1.15;
    margin: 0 0 18px;
    color: #fff;
    max-width: 800px;
}
.detail-hero-tags {
    display: flex;
    gap: 24px;
    flex-wrap: wrap;
    margin-top: 16px;
}
.detail-hero-tag {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.9);
}
.detail-hero-tag i {
    color: #f5d68f;
    font-size: 16px;
}

/* ====== CORPS ====== */
.detail-body {
    max-width: 1280px;
    margin: -20px auto 0;
    padding: 0 40px 60px;
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 32px;
    position: relative;
    z-index: 3;
}
.detail-main { display: flex; flex-direction: column; gap: 24px; }

.detail-image-wrap {
    background: #fff;
    border-radius: 16px;
    padding: 8px;
    box-shadow: 0 4px 20px rgba(5, 76, 122, 0.06);
}
.detail-image-wrap img {
    width: 100%;
    border-radius: 12px;
    display: block;
}

.detail-section {
    background: #fff;
    border-radius: 16px;
    padding: 28px 32px;
    box-shadow: 0 2px 12px rgba(5, 76, 122, 0.04);
}
.detail-section h2.section-title {
    font-family: 'League Spartan', sans-serif;
    font-size: 22px;
    font-weight: 600;
    color: #054c7a;
    margin: 0 0 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    padding-bottom: 14px;
    border-bottom: 1px solid #eef1f5;
}
.detail-section h2.section-title i {
    color: #c4932c;
    font-size: 20px;
}
.detail-section .section-content {
    font-size: 14px;
    color: #5e5e5e;
    line-height: 1.7;
}
.detail-section .section-content * {
    color: inherit;
}
.detail-section .section-content p {
    margin-bottom: 12px;
}

.tags-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    list-style: none;
    padding: 0;
    margin: 0;
}
.tags-list li {
    background: #f6f8fb;
    border: 1px solid #eef1f5;
    color: #054c7a;
    padding: 6px 14px;
    border-radius: 14px;
    font-size: 12px;
    font-weight: 500;
    display: inline-block;
}
.tags-list li::before {
    display: none;
}

/* ====== SECTION LOCALITÃ‰S - PIÃˆCE MAÃŽTRESSE ====== */
.section-localites {
    background: linear-gradient(135deg, #fff8e8 0%, #faf3ec 100%);
    border-radius: 16px;
    padding: 28px 32px;
    border-left: 4px solid #c4932c;
    position: relative;
    overflow: hidden;
}
.section-localites::before {
    content: '';
    position: absolute;
    top: -50px;
    right: -50px;
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(196, 147, 44, 0.08) 0%, transparent 70%);
    border-radius: 50%;
}
.section-localites .section-title {
    border-bottom-color: rgba(196, 147, 44, 0.2);
    position: relative;
}
.localites-intro {
    font-size: 13px;
    color: #5e5e5e;
    margin-bottom: 20px;
    position: relative;
}
.localites-intro strong {
    color: #054c7a;
}
.localites-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
    position: relative;
}
.localite-card {
    background: #fff;
    border-radius: 12px;
    padding: 16px 18px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    border: 1px solid #eef1f5;
    transition: all 0.2s;
}
.localite-card.dispo { border-left: 4px solid #15803d; }
.localite-card.urgent { border-left: 4px solid #c4932c; }
.localite-card.pleine { border-left: 4px solid #b91c1c; opacity: 0.7; }
.localite-card.fermee { border-left: 4px solid #94a3b8; opacity: 0.55; }
.localite-card:hover {
    transform: translateX(2px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05);
}
.localite-info { flex: 1; }
.localite-info strong {
    display: block;
    font-size: 15px;
    color: #054c7a;
    font-weight: 600;
    margin-bottom: 2px;
}
.localite-info span.localite-prov {
    font-size: 12px;
    color: #5e5e5e;
}
.localite-stats {
    text-align: right;
    min-width: 130px;
}
.localite-stats .nb {
    font-family: 'League Spartan', sans-serif;
    font-size: 22px;
    font-weight: 700;
    color: #054c7a;
    line-height: 1;
}
.localite-stats .lbl {
    font-size: 11px;
    color: #5e5e5e;
    margin-top: 4px;
}
.localite-stats .lbl.urgent {
    color: #c4932c;
    font-weight: 600;
}
.localite-stats .lbl.danger {
    color: #b91c1c;
    font-weight: 600;
}
.progress-bar {
    background: #e7eaf0;
    height: 5px;
    border-radius: 3px;
    margin-top: 8px;
    overflow: hidden;
}
.progress-fill {
    height: 100%;
    border-radius: 3px;
    transition: width 0.5s;
}
.progress-fill.green {
    background: linear-gradient(90deg, #15803d, #22c55e);
}
.progress-fill.amber {
    background: linear-gradient(90deg, #c4932c, #f59e0b);
}
.progress-fill.red {
    background: linear-gradient(90deg, #b91c1c, #ef4444);
}
.progress-fill.gray {
    background: #94a3b8;
}
.localites-legend {
    display: flex;
    gap: 20px;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px dashed rgba(196, 147, 44, 0.3);
    font-size: 11px;
    color: #5e5e5e;
    flex-wrap: wrap;
}
.legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
}
.legend-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

/* ====== SIDEBAR ====== */
.detail-sidebar {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.apply-card {
    background: linear-gradient(135deg, #054c7a 0%, #043a5e 100%);
    color: #fff;
    border-radius: 16px;
    padding: 24px;
    position: sticky;
    top: 20px;
    box-shadow: 0 8px 30px rgba(5, 76, 122, 0.25);
}
.apply-card h3 {
    font-family: 'League Spartan', sans-serif;
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 16px;
    color: #fff;
}
.deadline-card-side {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(245, 214, 143, 0.3);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 18px;
    text-align: center;
}
.deadline-card-side .lbl {
    font-size: 10px;
    color: rgba(255, 255, 255, 0.7);
    text-transform: uppercase;
    letter-spacing: 0.8px;
    margin-bottom: 6px;
}
.deadline-card-side .val {
    font-family: 'League Spartan', sans-serif;
    font-size: 22px;
    font-weight: 700;
    color: #f5d68f;
}
.deadline-card-side .countdown {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.85);
    margin-top: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}
.deadline-card-side .countdown i {
    color: #f5d68f;
}

.btn-apply-main {
    background: linear-gradient(135deg, #c4932c 0%, #d4a23c 100%);
    color: #fff !important;
    padding: 16px;
    border-radius: 12px;
    text-align: center;
    font-size: 14px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-bottom: 10px;
    box-shadow: 0 4px 14px rgba(196, 147, 44, 0.3);
    transition: transform 0.15s;
    text-decoration: none;
    border: none;
    cursor: pointer;
    width: 100%;
    font-family: 'Poppins', sans-serif;
}
.btn-apply-main:hover {
    transform: translateY(-1px);
    color: #fff;
}
.btn-apply-main.disabled {
    background: #94a3b8;
    cursor: not-allowed;
    opacity: 0.7;
    box-shadow: none;
}
.btn-apply-main.disabled:hover {
    transform: none;
}

.apply-stats {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.15);
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    text-align: center;
}
.apply-stat .num {
    font-family: 'League Spartan', sans-serif;
    font-size: 18px;
    font-weight: 700;
    color: #f5d68f;
    line-height: 1;
}
.apply-stat .lbl {
    font-size: 10px;
    color: rgba(255, 255, 255, 0.75);
    margin-top: 4px;
}

/* ====== TIMELINE ====== */
.timeline-card {
    background: #fff;
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 2px 12px rgba(5, 76, 122, 0.04);
}
.timeline-card h3 {
    font-family: 'League Spartan', sans-serif;
    font-size: 16px;
    font-weight: 600;
    color: #054c7a;
    margin: 0 0 18px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.timeline-card h3 i {
    color: #c4932c;
}
.tl-item {
    display: flex;
    gap: 14px;
    padding: 12px 0;
    border-bottom: 1px solid #eef1f5;
}
.tl-item:last-child { border-bottom: none; }
.tl-date {
    background: #054c7a;
    color: #fff;
    min-width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    flex-shrink: 0;
}
.tl-date.alt {
    background: linear-gradient(135deg, #c4932c 0%, #d4a23c 100%);
}
.tl-date strong {
    font-family: 'League Spartan', sans-serif;
    font-size: 16px;
    font-weight: 700;
    line-height: 1;
}
.tl-info { flex: 1; padding-top: 4px; }
.tl-info .ev {
    font-size: 13px;
    color: #054c7a;
    font-weight: 600;
}
.tl-info .day {
    font-size: 11px;
    color: #5e5e5e;
    margin-top: 2px;
}

/* ====== CONTACT ====== */
.contact-card {
    background: #fff;
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 2px 12px rgba(5, 76, 122, 0.04);
}
.contact-card h3 {
    font-family: 'League Spartan', sans-serif;
    font-size: 16px;
    font-weight: 600;
    color: #054c7a;
    margin: 0 0 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.contact-card h3 i { color: #c4932c; }
.contact-line {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    font-size: 13px;
    color: #5e5e5e;
}
.contact-line i {
    color: #c4932c;
    background: rgba(196, 147, 44, 0.1);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    flex-shrink: 0;
}

/* ====== PARTAGE ====== */
.share-buttons {
    display: flex;
    gap: 10px;
    margin-top: 12px;
}
.share-btn {
    width: 40px;
    height: 40px;
    background: #f6f8fb;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #054c7a;
    font-size: 16px;
    transition: all 0.15s;
    cursor: pointer;
}
.share-btn:hover {
    background: #054c7a;
    color: #fff;
    transform: translateY(-2px);
}

/* ====== FICHIERS JOINTS ====== */
.section-fichiers .files-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-top: 12px;
}
.file-item {
    background: #f6f8fb;
    border: 1px solid #eef1f5;
    border-radius: 12px;
    padding: 14px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.15s;
    text-decoration: none;
    color: inherit;
}
.file-item:hover {
    border-color: #c4932c;
    background: #fff;
    box-shadow: 0 4px 12px rgba(196, 147, 44, 0.1);
}
.file-item .file-icon {
    background: #c4932c;
    color: #fff;
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
}
.file-item .file-info { flex: 1; min-width: 0; }
.file-item .file-name {
    font-size: 13px;
    color: #054c7a;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.file-item .file-meta {
    font-size: 11px;
    color: #5e5e5e;
    margin-top: 2px;
}
.file-item .file-dl {
    color: #c4932c;
    font-size: 14px;
}

/* ====== STICKY CTA EN BAS ====== */
.sticky-cta {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #054c7a;
    color: #fff;
    padding: 14px 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
    border-top: 3px solid #c4932c;
    z-index: 100;
    transform: translateY(100%);
    transition: transform 0.3s;
}
.sticky-cta.visible {
    transform: translateY(0);
}
.sticky-info { font-size: 13px; }
.sticky-info strong {
    color: #f5d68f;
    font-family: 'League Spartan', sans-serif;
    font-size: 16px;
}
.sticky-btn {
    background: linear-gradient(135deg, #c4932c 0%, #d4a23c 100%);
    padding: 10px 24px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    color: #fff !important;
    text-decoration: none;
}
.sticky-btn:hover {
    color: #fff;
}

/* ====== SOCIAL FLOTTANT (cÃ´tÃ© gauche) ====== */
.social-media-detail {
    position: fixed;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 4;
}
ul.social-icons li {
    display: flex;
    align-items: center;
    justify-content: center;
}

ul.social-icons li:last-child a {
    margin-bottom: 0px;
}
.social-media-detail .social-icons {
    display: flex;
    flex-direction: column;
    gap: 8px;
    list-style: none;
    padding: 10px 0;
    margin: 0;
}
.social-media-detail .social-icons a {
    width: 40px;
    height: 40px;
    background: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #054c7a;
    font-size: 16px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    transition: all 0.15s;
    text-decoration: none;
}
.social-media-detail .social-icons a:hover {
    background: #c4932c;
    color: #fff;
    transform: translateX(4px);
}

/* ====== RESPONSIVE ====== */
@media (max-width: 1100px) {
    .social-media-detail { display: none; }
}
@media (max-width: 1024px) {
    .detail-body {
        grid-template-columns: 1fr;
        padding: 0 20px 40px;
    }
    .localites-grid { grid-template-columns: 1fr; }
    .apply-card { position: static; }
    .detail-hero h1 { font-size: 28px; }
    .detail-hero .container { padding: 0 20px; }
    .detail-hero { padding: 24px 0 40px; }
    .sticky-cta { padding: 12px 20px; flex-wrap: wrap; gap: 10px; }
    .sticky-info { font-size: 12px; flex: 1; min-width: 200px; }
    .section-fichiers .files-list { grid-template-columns: 1fr; }
}
