/*
 * UNSA Territoriaux 21 · accueil public simplifié (08/10/2026).
 * Une colonne, une action principale, trois accès, les dernières actualités.
 * Chargé uniquement par index.php (et actualites.php pour le pied de page) ;
 * les autres pages publiques gardent public-2026.css seul.
 * Charte : bleu #009ee0, marine #004289, Sora / Inter, jamais d'orange,
 * texte blanc sur fond bleu, bordures neutres, cibles 44 px, champs 16 px.
 */
@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Sora:wght@600;700;800&display=swap");

.ut21-redesign {
    --hm-blue: #009ee0;
    --hm-blue-600: #0287c2;
    --hm-blue-ui: #0077b3;
    --hm-blue-ui-h: #036d9e;
    --hm-navy: #004289;
    --hm-ink: #0f172a;
    --hm-text: #334155;
    --hm-muted: #64748b;
    --hm-line: #e2e8f0;
    --hm-soft: #f6f8fb;
    --hm-blue-50: #f0f9ff;
    --hm-r: 14px;
    font-family: "Inter", -apple-system, "Segoe UI", sans-serif;
    color: var(--hm-text);
}
.ut21-redesign h1, .ut21-redesign h2, .ut21-redesign h3 { font-family: "Sora", "Inter", sans-serif; color: var(--hm-ink); }

/* Boutons */
.hm-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    min-height: 48px; padding: 0 22px; border-radius: 12px;
    font-weight: 700; font-size: 16px; text-decoration: none; cursor: pointer;
    transition: background-color .2s ease, box-shadow .2s ease;
}
.hm-btn svg { width: 20px; height: 20px; flex-shrink: 0; }
.hm-btn-primary { background: var(--hm-blue-ui); color: #fff !important; border: 0; }
.hm-btn-primary:hover { background: var(--hm-blue-ui-h); }
.hm-btn-ghost { background: #fff; color: var(--hm-ink) !important; border: 1px solid var(--hm-line); }
.hm-btn-ghost:hover { background: var(--hm-soft); }
.hm-btn-white { background: #fff; color: var(--hm-navy) !important; border: 0; }
.hm-btn-white:hover { background: var(--hm-blue-50); }
.hm-link { color: var(--hm-navy); font-weight: 600; text-underline-offset: 4px; }
.ut21-redesign .hm-btn:focus-visible, .ut21-redesign .hm-link:focus-visible, .hm-search input:focus-visible {
    outline: 3px solid var(--hm-ink); outline-offset: 3px;
}

/* 1. Accueil : message, action, recherche */
.hm-hero { max-width: 780px; margin: 0 auto; padding: 48px 0 28px; text-align: center; }
.hm-eyebrow {
    display: inline-flex; align-items: center; gap: 8px; margin: 0 0 18px; padding: 6px 14px;
    border-radius: 999px; background: var(--hm-blue-50); color: #036d9e; font-size: 13px; font-weight: 600;
}
.hm-hero h1 { font-size: clamp(2.1rem, 1.4rem + 3vw, 3.5rem); line-height: 1.08; letter-spacing: -0.03em; margin: 0 0 18px; font-weight: 800; }
.hm-hero h1 span { color: var(--hm-blue); }
.hm-lead { font-size: clamp(1.05rem, 1rem + .3vw, 1.2rem); line-height: 1.6; color: var(--hm-muted); margin: 0 auto 28px; max-width: 60ch; }
.hm-cta { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin-bottom: 30px; }
.hm-search { max-width: 620px; margin: 0 auto 44px; text-align: left; }
.hm-search label { display: block; font-size: 14px; font-weight: 600; color: var(--hm-ink); margin-bottom: 8px; text-align: center; }
.hm-search div { display: flex; gap: 8px; padding: 6px; background: #fff; border: 1px solid var(--hm-line); border-radius: 14px; box-shadow: 0 4px 16px rgba(15, 23, 42, .05); }
.hm-search input { flex: 1 1 auto; min-width: 0; min-height: 44px; border: 0; padding: 0 12px; font: inherit; font-size: 16px; color: var(--hm-ink); background: transparent; }
.hm-search input::placeholder { color: #94a3b8; }
.hm-search button { min-height: 44px; padding: 0 18px; font-size: 15px; }
.hm-proof { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 22px; margin: 26px 0 0; padding: 0; list-style: none; font-size: 14px; color: var(--hm-muted); }
.hm-proof strong { color: var(--hm-ink); font-variant-numeric: tabular-nums; }


/* 1 bis. Les trois tâches des visiteurs (données de fréquentation : connexion, contact, adhésion) */
.hm-tasks { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin: 0 0 36px; }
.hm-task { display: flex; flex-direction: column; gap: 10px; padding: 24px; background: #fff; border: 1px solid var(--hm-line); border-radius: 18px; box-shadow: 0 6px 20px rgba(15, 23, 42, .05); min-width: 0; }
.hm-task-icon { width: 52px; height: 52px; border-radius: 14px; background: var(--hm-blue-ui); color: #fff; display: flex; align-items: center; justify-content: center; }
.hm-task-icon svg { width: 26px; height: 26px; }
.hm-task h2 { font-size: 21px; margin: 4px 0 0; }
.hm-task p { margin: 0; color: var(--hm-muted); line-height: 1.55; }
.hm-task p strong { color: var(--hm-ink); }
.hm-task-actions { margin-top: auto; padding-top: 8px; display: flex; flex-direction: column; gap: 10px; align-items: stretch; text-align: center; }
.hm-task-actions .hm-btn { width: 100%; }
.hm-task-actions .hm-link { font-size: 15px; min-height: 32px; display: inline-flex; align-items: center; justify-content: center; }

/* 2. Bandeau élections */
.hm-elections {
    display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 20px 32px; align-items: center;
    margin: 8px 0 48px; padding: 28px 32px; border-radius: 20px; background: var(--hm-navy); color: #fff;
}
.hm-elections p { margin: 0; color: rgba(255, 255, 255, .9); }
.hm-elections .hm-kicker { font-size: 13px; font-weight: 600; letter-spacing: .02em; color: #fff; opacity: .85; margin-bottom: 6px; }
.hm-elections h2 { color: #fff; font-size: clamp(1.35rem, 1.1rem + 1vw, 1.75rem); margin: 0 0 8px; }
.hm-elections strong { color: #fff; }
.hm-elections-actions { display: flex; flex-direction: column; gap: 10px; align-items: stretch; }
.hm-elections-actions a:not(.hm-btn) { color: #fff; font-size: 14px; font-weight: 600; text-align: center; text-underline-offset: 3px; }

/* 3. Trois accès */
.hm-section { margin: 0 0 48px; }
.hm-section-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 18px; }
.hm-section-head h2 { font-size: clamp(1.35rem, 1.15rem + .8vw, 1.7rem); margin: 0; }
.hm-access { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.hm-card {
    display: flex; flex-direction: column; gap: 10px; padding: 22px; min-width: 0;
    background: #fff; border: 1px solid var(--hm-line); border-radius: var(--hm-r);
    text-decoration: none; color: inherit; transition: box-shadow .2s ease;
}
.hm-card:hover { box-shadow: 0 8px 24px rgba(15, 23, 42, .07); }
.hm-card:focus-visible { outline: 3px solid var(--hm-ink); outline-offset: 3px; }
.hm-card-icon { width: 44px; height: 44px; border-radius: 12px; display: flex; align-items: center; justify-content: center; background: var(--hm-blue-50); color: #036d9e; }
.hm-card-icon svg { width: 22px; height: 22px; }
.hm-card h3 { font-size: 17px; margin: 4px 0 0; }
.hm-card p { margin: 0; font-size: 14px; line-height: 1.55; color: var(--hm-muted); }
.hm-card span { margin-top: auto; padding-top: 6px; font-size: 14px; font-weight: 700; color: var(--hm-navy); }

/* 4. Dernières actualités */
.hm-news { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.hm-news-item { display: flex; flex-direction: column; min-width: 0; background: #fff; border: 1px solid var(--hm-line); border-radius: var(--hm-r); overflow: hidden; text-decoration: none; color: inherit; transition: box-shadow .2s ease; }
.hm-news-item:hover { box-shadow: 0 8px 24px rgba(15, 23, 42, .07); }
.hm-news-item img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; display: block; background: var(--hm-soft); }
.hm-news-body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 6px; }
.hm-news-meta { font-size: 12px; font-weight: 600; color: var(--hm-muted); }
.hm-news-item h3 { font-size: 16px; line-height: 1.35; margin: 0; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

/* 5. Pied de page */
.hm-footer { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 24px; margin-top: 16px; padding: 32px 0 40px; border-top: 1px solid var(--hm-line); font-size: 14px; color: var(--hm-muted); }
.hm-footer strong { display: block; color: var(--hm-ink); font-family: "Sora", "Inter", sans-serif; font-size: 15px; margin-bottom: 6px; }
.hm-footer address { font-style: normal; line-height: 1.7; }
.hm-footer a { color: var(--hm-navy); }
.hm-footer ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 18px; align-content: start; }
.hm-footer li a { display: inline-flex; min-height: 32px; align-items: center; font-weight: 600; text-underline-offset: 3px; }

/* Mobile */
@media (max-width: 860px) {
    .hm-access, .hm-news, .hm-tasks { grid-template-columns: 1fr; }
    .hm-news-item { flex-direction: row; }
    .hm-news-item img { width: 112px; aspect-ratio: 1; flex-shrink: 0; }
    .hm-news-body { padding: 12px 14px; }
    .hm-news-item h3 { font-size: 15px; }
    .hm-elections { grid-template-columns: 1fr; padding: 24px 20px; }
    .hm-footer { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
    .hm-hero { padding: 32px 0 28px; }
    .hm-cta { flex-direction: column; }
    .hm-cta .hm-btn { width: 100%; }
    .hm-search div { flex-direction: column; }
    .hm-search button { width: 100%; }
    .hm-proof { flex-direction: column; align-items: center; gap: 4px; }
    .ut21-redesign .rd-nav { gap: 6px 18px; overflow-x: auto; flex-wrap: nowrap; padding-block: 12px; }
    .ut21-redesign .rd-nav a { white-space: nowrap; min-height: 32px; display: inline-flex; align-items: center; }
}
@media (prefers-reduced-motion: reduce) {
    .hm-btn, .hm-card, .hm-news-item { transition: none; }
}
