/* === Page header === */
.fv5 .asso-head { background: var(--ex-surface); border: 1px solid var(--ex-stone-200); border-radius: 14px; padding: 2rem 2.5rem; margin-bottom: 2rem; box-shadow: var(--ex-shadow-md); display: flex; justify-content: space-between; align-items: start; flex-wrap: wrap; gap: 1.5rem; position: relative; overflow: hidden; }
.fv5 .asso-head::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px; background: linear-gradient(90deg, var(--ex-green-400), var(--ex-accent), var(--ex-green-400)); }
.fv5 .asso-head h1 { font-size: 1.8rem; font-weight: 800; letter-spacing: -0.02em; margin: 0 0 0.4rem; line-height: 1.2; }
.fv5 .asso-head .sub { color: var(--ex-stone-500); font-size: 0.95rem; margin-bottom: 0.75rem; }

/* === Badges === */
.fv5 .badges { display: flex; gap: 0.45rem; flex-wrap: wrap; }
.fv5 .badge { padding: 0.25rem 0.65rem; border-radius: 5px; font-size: 0.72rem; font-weight: 600; display: inline-flex; align-items: center; }
.fv5 .b-active { background: #d1fae5; color: #065f46; }
.fv5 .b-dissolved { background: #fee2e2; color: #991b1b; }
.fv5 .b-cessation { background: var(--ex-green-100); color: var(--ex-green-800); }
.fv5 .b-rup { background: var(--ex-green-100); color: var(--ex-green-800); }
.fv5 .b-loc { background: #e0e7ff; color: #3730a3; }
.fv5 .b-date { background: var(--ex-stone-100); color: var(--ex-stone-600); font-family: var(--ex-mono); font-size: 0.7rem; font-weight: 400; }
.fv5 .b-group { background: #ede9fe; color: #5b21b6; }
.fv5 .b-assoce { background: #fef3c7; color: #92400e; }

/* === Grid layout === */
.fv5 .grid { display: grid; grid-template-columns: 2fr 1fr; gap: 2rem; padding-left: 0; }
@media (max-width: 968px) { .fv5 .grid { grid-template-columns: 1fr; } .fv5 .sidebar { position: relative !important; top: 0 !important; } }

/* === Cards === */
.fv5 .crd { background: var(--ex-surface); border: 1px solid var(--ex-stone-200); border-radius: 12px; margin-bottom: 1.25rem; box-shadow: var(--ex-shadow-sm); overflow: hidden; transition: box-shadow 0.2s var(--ex-ease); padding-left: 0; }
.fv5 .crd:hover { box-shadow: var(--ex-shadow-md); }
.fv5 .crd-h { display: flex; align-items: center; gap: 0.6rem; padding: 0.8rem 1.25rem; background: var(--ex-stone-50); border-bottom: 1px solid var(--ex-stone-200); }
.fv5 .crd-ico { width: 28px; height: 28px; background: linear-gradient(135deg, var(--ex-green-300), var(--ex-green-500)); border-radius: 7px; display: flex; align-items: center; justify-content: center; font-size: 0.7rem; font-weight: 700; color: var(--ex-green-900); flex-shrink: 0; box-shadow: 0 2px 6px rgba(255,187,9,0.2); text-align: center; line-height: 1; padding-left: 1px; }
.fv5 .crd-t { font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; color: var(--ex-green-700); margin: 0; }
.fv5 .crd-body { padding: 1.25rem; }
.fv5 .crd-body p, .fv5 .crd-body li, .fv5 .crd-body address { margin: 0.35rem 0; line-height: 1.75; color: var(--ex-stone-700); font-size: 0.9rem; font-style: normal; }
.fv5 .crd-body .hl { color: var(--ex-stone-800); }
.fv5 .crd-body li span.cap { display: inline-block; }
.fv5 .crd-body li span.cap::first-letter { text-transform: uppercase; }
.fv5 .crd-body h3 { font-size: 0.7rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; color: var(--ex-stone-500); margin: 1.1rem 0 0.5rem; }
.fv5 .crd-body ul { list-style: none; margin: 0; padding-left: 2em; }
.fv5 .crd-body li { padding: 0.3rem 0; padding-left: 1rem; position: relative; }
.fv5 .crd-body li::before { content: '\2013'; position: absolute; left: 0; color: var(--ex-stone-400); }

/* === Sidebar === */
.fv5 .sidebar { position: sticky; top: 2rem; height: fit-content; }
.fv5 .side-card { background: var(--ex-surface); border: 1px solid var(--ex-stone-200); border-radius: 12px; margin-bottom: 1.25rem; box-shadow: var(--ex-shadow-sm); overflow: hidden; padding-left: 0; }
.fv5 .sc-head { font-size: 0.68rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; color: var(--ex-green-700); padding: 0.75rem 1.25rem; background: var(--ex-stone-50); border-bottom: 1px solid var(--ex-stone-200); }
.fv5 .sc-body { padding: 1rem 1.25rem; }

/* === Quick actions === */
.fv5 .qa-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.5rem; }
.fv5 a.qa-btn, .fv5 .qa-btn { padding: 0.55rem 0.5rem; border: 1px solid var(--ex-stone-200); background: var(--ex-stone-50); border-radius: 8px; text-align: center; cursor: pointer; transition: all 0.15s var(--ex-ease); text-decoration: none; color: var(--ex-stone-600); font-size: 0.8rem; font-weight: 500; display: block; font-family: var(--ex-font); }
.fv5 .qa-btn:hover { border-color: var(--ex-green-300); background: var(--ex-green-50); color: var(--ex-green-800); transform: translateY(-1px); }
.fv5 a.qa-btn.qa-btn-green, .fv5 .qa-btn.qa-btn-green { background: #f6ffef; border-color: #d6febf; color: #2dd81d; }
.fv5 a.qa-btn.qa-btn-green:hover, .fv5 .qa-btn.qa-btn-green:hover { background: #ecfedb; border-color: #9cfd93; color: #2faf1e; transform: translateY(-1px); }
.fv5 a.qa-btn.qa-btn-blue, .fv5 .qa-btn.qa-btn-blue { background: #eff6ff; border-color: #bfdbfe; color: #1d4ed8; }
.fv5 a.qa-btn.qa-btn-blue:hover, .fv5 .qa-btn.qa-btn-blue:hover { background: #dbeafe; border-color: #93c5fd; color: #1e40af; transform: translateY(-1px); }

/* === Sector items === */
.fv5 a.sector-item, .fv5 .sector-item { display: flex; align-items: center; gap: 0.5rem; padding: 0.5rem 0.75rem; font-size: 0.86rem; color: var(--ex-link); text-decoration: none; transition: background 0.12s, color 0.12s; border-radius: 6px; margin-bottom: 0.15rem; }
.fv5 .sector-item span { display: inline-block; font-weight: normal;}
.fv5 .sector-item span::first-letter { text-transform: uppercase; }
.fv5 .sector-item::before { content: '\27A4'; font-size: 0.7rem; color: var(--ex-stone-400); transition: color 0.15s; flex-shrink: 0; }
.fv5 .sector-item:hover { background: var(--ex-green-50); color: var(--ex-green-900); }
.fv5 .sector-item:hover::before { color: var(--ex-green-600); }

/* === Offres partenaires === */
.fv5 #offres-partenaires ul { list-style: none; padding: 0; margin: 0; }
.fv5 #offres-partenaires li { padding: 0.55rem 0.75rem; background: var(--ex-stone-50); border-radius: 8px; margin-bottom: 0.4rem; border: 1px solid transparent; transition: all 0.15s; font-size: 0.88rem; }
.fv5 #offres-partenaires li:hover { background: var(--ex-surface); border-color: var(--ex-green-300); transform: translateX(3px); }

/* === Mission text === */
.fv5 .crd-body p.mission-text { padding: 0.75rem 1rem; border-left: 3px solid var(--ex-green-400); background: var(--ex-stone-50); border-radius: 0 8px 8px 0; font-size: 0.92rem; line-height: 1.8; color: var(--ex-stone-800); font-style: italic; }

/* === Identifiers grid === */
.fv5 .igrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 0.5rem; }
.fv5 .ibox { padding: 0.65rem 0.75rem; background: var(--ex-stone-50); border: 1px solid var(--ex-stone-100); border-radius: 8px; transition: border-color 0.15s; position: relative; cursor: pointer; }
.fv5 .ibox:hover { border-color: var(--ex-green-300); }
.fv5 .ibox .lbl { font-size: 0.62rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; color: var(--ex-stone-400); }
.fv5 .ibox .val { font-family: var(--ex-mono); font-size: 0.84rem; font-weight: 500; color: var(--ex-stone-800); word-break: break-all; }
.fv5 .ibox .copy-msg { display: none; font-size: 0.65rem; color: var(--ex-green-700); font-family: var(--ex-font); font-weight: 600; margin-top: 0.2rem; }
.fv5 .ibox.copied .copy-msg { display: block; }
.fv5 .ibox.copied { border-color: var(--ex-green-400); background: var(--ex-green-50); }
.fv5 .ibox details { margin-top: 0; }
.fv5 .ibox details summary { position: absolute; top: 0.4rem; right: 0.4rem; width: 18px; height: 18px; border-radius: 50%; background: var(--ex-stone-100); color: transparent; font-size: 0; display: flex; align-items: center; justify-content: center; cursor: pointer; list-style: none; padding: 0; transition: all 0.15s; line-height: 1; }
.fv5 .ibox details summary::after { content: '?'; font-size: 0.65rem; font-weight: 700; color: var(--ex-stone-400); }
.fv5 .ibox details summary::-webkit-details-marker { display: none; }
.fv5 .ibox details summary::before { content: none; }
.fv5 .ibox details summary:hover { background: var(--ex-green-100); }
.fv5 .ibox details summary:hover::after { color: var(--ex-green-700); }
.fv5 .ibox details[open] summary { background: var(--ex-green-400); }
.fv5 .ibox details[open] summary::after { content: '\d7'; color: var(--ex-green-900); }
.fv5 .ibox details .info { margin-top: 0.5rem; font-size: 0.78rem; line-height: 1.5; color: var(--ex-stone-500); border-top: 1px solid var(--ex-stone-100); padding-top: 0.4rem; }

/* === History / Timeline === */
.fv5 .histo-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 640px) { .fv5 .histo-grid { grid-template-columns: 1fr; } }
.fv5 ul.tl { position: relative; margin: 0; margin-left: 9px; padding-left: 20px; border-left: 2px solid var(--ex-stone-200); }
.fv5 .tl li { position: relative; padding: 0.45rem 0; border-bottom: 1px solid var(--ex-stone-100); line-height: 1.5; }
.fv5 .tl li:last-child { border-bottom: none; }
.fv5 .tl li::before { content: ''; position: absolute; left: -26px; top: 50%; transform: translateY(-50%); width: 10px; height: 10px; border-radius: 50%; background: var(--ex-surface); border: 2.5px solid var(--ex-green-400); }
.fv5 .tl time { font-family: var(--ex-mono); font-size: 0.78rem; color: var(--ex-stone-500); font-weight: 500; }

/* === JOAFE === */
.fv5 .joafe-box { background: var(--ex-stone-50); border: 1px solid var(--ex-stone-100); border-radius: 8px; padding: 1rem; }
.fv5 .joafe-header { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 0.75rem; }
.fv5 .joafe-type { font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; padding: 0.2rem 0.6rem; border-radius: 4px; background: var(--ex-green-100); color: var(--ex-green-800); }
.fv5 .joafe-date { font-family: var(--ex-mono); font-size: 0.8rem; color: var(--ex-stone-500); }
.fv5 .joafe-links { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.fv5 .joafe-links a { display: inline-flex; align-items: center; gap: 0.3rem; padding: 0.35rem 0.7rem; border: 1px solid var(--ex-stone-200); border-radius: 6px; font-size: 0.82rem; font-weight: 500; text-decoration: none; color: var(--ex-link); background: var(--ex-surface); transition: all 0.15s; }
.fv5 .joafe-links a:hover { border-color: var(--ex-link); background: var(--ex-stone-50); }

/* === Admin grid === */
.fv5 .admin-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 640px) { .fv5 .admin-grid { grid-template-columns: 1fr; } }
.fv5 .admin-detail { background: var(--ex-stone-50); border-radius: 8px; padding: 1rem; border: 1px solid var(--ex-stone-100); }
.fv5 .admin-detail summary { margin: 0; padding: 0; }
.fv5 .admin-detail[open] { border-color: var(--ex-green-300); }
.fv5 .admin-detail > p, .fv5 .admin-detail > ul { border-left: none; padding-left: 0; margin-left: 0; }

/* === Contact mairie widget === */
.fv5 .contactMairieWidget { background: var(--ex-surface); border: 1px solid var(--ex-stone-200); border-radius: 10px; padding: 1.25rem; margin-top: 0.75rem; box-shadow: var(--ex-shadow-sm); }
.fv5 .contactMairieWidget h4 { font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; color: var(--ex-green-700); margin: 0 0 1rem; padding-bottom: 0.6rem; border-bottom: 1px solid var(--ex-stone-100); display: flex; align-items: center; gap: 0.5rem; }
.fv5 .contactMairieWidget h4::before { content: '\1F3E2'; font-size: 0.9rem; }
.fv5 .contactMairieWidget address { font-style: normal; display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; }
@media (max-width: 640px) { .fv5 .contactMairieWidget address { grid-template-columns: 1fr; } }
.fv5 .contactMairieWidget address p { margin: 0; font-size: 0.85rem; color: var(--ex-stone-700); padding: 0.5rem 0.65rem; background: var(--ex-stone-50); border-radius: 6px; border-left: 3px solid transparent; padding-left: 0.65rem; }
.fv5 .contactMairieWidget address p:first-child { border-left-color: var(--ex-green-400); }
.fv5 .contactMairieWidget address p:nth-child(2) { border-left-color: var(--ex-green-300); }
.fv5 .contactMairieWidget address p:nth-child(3) { border-left-color: var(--ex-green-200); }
.fv5 .contactMairieWidget address a { color: var(--ex-link); text-decoration: none; font-weight: 500; }
.fv5 .contactMairieWidget address a:hover { text-decoration: underline; }
.fv5 .contactMairieWidget address ul { list-style: none; padding: 0; margin: 0.15rem 0; }
.fv5 .contactMairieWidget address li { padding: 0.1rem 0; font-size: 0.83rem; color: var(--ex-stone-600); }
.fv5 .contactMairieWidget address li::before { content: none; padding-left: 0; }
.fv5 .contactMairieWidget .mairie-source { grid-column: 1 / -1; font-size: 0.75rem; color: var(--ex-stone-400); margin-top: 0.25rem; background: none; padding: 0; border-left: none; }
.fv5 .contactMairieWidget .mairie-source a { color: var(--ex-stone-400); font-weight: 400; text-decoration: underline; }
.fv5 .contactMairieWidget button { margin-top: 0.75rem; padding: 0.4rem 0.9rem; background: var(--ex-stone-50); border: 1px solid var(--ex-stone-200); border-radius: 8px; cursor: pointer; font-family: var(--ex-font); font-size: 0.82rem; color: var(--ex-stone-600); transition: all 0.15s; display: block; width: 100%; text-align: center; }
.fv5 .contactMairieWidget button:hover { background: var(--ex-stone-100); border-color: var(--ex-stone-300); color: var(--ex-stone-800); }
