/*
 * Ecrans publics MaGestion : connexion et inscription, d'apres la maquette.
 * Feuille autonome : ces pages ne chargent pas les styles de l'application.
 */
:root {
    --mg-orange: #F5883A;
    --mg-orange-dark: #E27322;
    --mg-orange-soft: #FEF1E4;
    --mg-green: #34B76A;
    --mg-green-dark: #259553;
    --mg-green-soft: #E5F6EC;
    --mg-red: #D93025;
    --mg-red-soft: #FDECEC;
    --mg-ink: #1B1D28;
    --mg-muted: #6B7280;
    --mg-line: #E6E8EC;
    --mg-bg: #FAFBFA;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body.mg-public {
    margin: 0;
    min-height: 100vh;
    font-family: 'Outfit', 'Segoe UI', system-ui, -apple-system, Roboto, Arial, sans-serif;
    font-size: 15px;
    line-height: 1.45;
    color: var(--mg-ink);
    background:
        radial-gradient(900px 420px at 50% 100%, rgba(52, 183, 106, .16), transparent 70%),
        var(--mg-bg);
    position: relative;
    overflow-x: hidden;
}
a { color: inherit; }
.mg-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Elements communs ---------- */
.mg-logo { display: inline-flex; align-items: center; gap: 10px; font-size: 24px; font-weight: 600; letter-spacing: -0.01em; text-decoration: none; color: var(--mg-ink); }
/* Logo MaGestion : l'image contient deja le nom, le texte reste pour les lecteurs d'ecran. */
.mg-logo-bars { width: 182px; height: 44px; flex: 0 0 auto; background: url(mg-logo.png) left center / contain no-repeat; }
.mg-logo > .mg-logo-bars + span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.mgh-top .mg-logo-bars { width: 150px; height: 36px; }
.mgh-shot-bar .mg-logo-bars { width: 24px; height: 24px; background-image: url(mg-symbole.png); background-position: center; }
@media (max-width: 480px) { .mg-logo-bars { width: 150px; height: 36px; } .mgh-top .mg-logo-bars { width: 128px; height: 31px; } }
.mg-link { color: var(--mg-orange-dark); font-weight: 500; text-decoration: none; }
.mg-link:hover { text-decoration: underline; }

.mg-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    min-height: 44px; padding: 0 20px; border-radius: 10px; border: 1px solid transparent;
    font: inherit; font-weight: 600; font-size: 15px; text-decoration: none; cursor: pointer;
    transition: background-color .15s, border-color .15s;
}
.mg-btn-primary { background: var(--mg-orange); color: #fff; }
.mg-btn-primary:hover { background: var(--mg-orange-dark); }
.mg-btn-soft { background: #F1F2F4; color: var(--mg-ink); }
.mg-btn-soft:hover { background: #E6E8EC; }
.mg-btn-block { width: 100%; }
.mg-btn-sm { min-height: 38px; padding: 0 16px; font-size: 14px; }
.mg-btn:focus-visible, .mg-link:focus-visible, .mg-eye:focus-visible { outline: 2px solid var(--mg-orange); outline-offset: 2px; }

.mg-f { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; min-width: 0; }
.mg-f label { font-size: 13.5px; font-weight: 500; color: var(--mg-ink); }
.mg-f label em { color: var(--mg-orange-dark); font-style: normal; }
.mg-f-row { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.mg-f-row .mg-link { font-size: 13px; }
.mg-f input[type=text], .mg-f input[type=email], .mg-f input[type=tel], .mg-f input[type=password], .mg-f select {
    width: 100%; min-height: 46px; padding: 10px 14px;
    border: 1px solid var(--mg-line); border-radius: 10px; background: #fff;
    font: inherit; color: var(--mg-ink);
}
.mg-f input[type=file] { font: inherit; font-size: 14px; }
.mg-f input::placeholder { color: #A3A8B3; }
.mg-f input:focus, .mg-f select:focus { outline: none; border-color: var(--mg-orange); box-shadow: 0 0 0 3px var(--mg-orange-soft); }
.mg-bad input, .mg-bad select { border-color: var(--mg-red); }
.mg-err { color: var(--mg-red); font-size: 13px; }
.mg-hint { color: var(--mg-muted); font-size: 12.5px; }
.mg-pass { position: relative; }
.mg-pass input { padding-right: 46px !important; }
.mg-eye {
    position: absolute; top: 50%; right: 6px; transform: translateY(-50%);
    width: 36px; height: 36px; border: 0; border-radius: 8px; background: none; color: var(--mg-ink);
    display: flex; align-items: center; justify-content: center; cursor: pointer;
}
.mg-eye svg { width: 20px; height: 20px; }
.mg-eye[aria-pressed="true"] { color: var(--mg-orange-dark); }
.mg-check { display: flex; align-items: center; gap: 8px; font-size: 14px; margin: 2px 0 16px; cursor: pointer; }
.mg-check input { width: 18px; height: 18px; accent-color: var(--mg-orange); flex: 0 0 auto; }

.mg-alert { border-radius: 10px; padding: 10px 14px; margin-bottom: 14px; font-size: 14px; }
.mg-alert ul { margin: 6px 0 0; padding-left: 18px; }
.mg-alert-ok { background: var(--mg-green-soft); color: var(--mg-green-dark); }
.mg-alert-ko { background: var(--mg-red-soft); color: var(--mg-red); }

/* ---------- Connexion ---------- */
.mgl {
    position: relative; z-index: 1;
    max-width: 1120px; margin: 0 auto; padding: 72px 24px 260px;
    display: grid; grid-template-columns: minmax(0, 1fr) 420px; gap: 56px; align-items: start;
}
.mgl-pitch { padding-top: 8px; }
.mgl-pitch h1 { margin: 22px 0 16px; font-size: 32px; line-height: 1.2; font-weight: 500; letter-spacing: -0.015em; max-width: 440px; }
.mgl-pitch p { margin: 0; font-size: 20px; color: #2E3140; max-width: 400px; }
.mgl-card { background: #fff; border-radius: 22px; padding: 36px 36px 28px; box-shadow: 0 24px 60px rgba(27, 29, 40, .10); }
.mgl-card h2 { margin: 0 0 8px; font-size: 22px; font-weight: 500; text-align: center; }
.mgl-sub { margin: 0 auto 22px; text-align: center; color: #2E3140; max-width: 280px; }
.mgl-foot { margin-top: 22px; display: flex; flex-direction: column; align-items: center; gap: 10px; font-size: 15px; }
.mgl-lang { margin-top: 18px; display: flex; align-items: center; justify-content: center; gap: 8px; font-size: 13px; color: var(--mg-muted); }
.mgl-lang select { border: 1px solid var(--mg-line); border-radius: 8px; padding: 5px 8px; font: inherit; background: #fff; color: var(--mg-ink); }

/* Apercu decoratif en bas de la connexion */
.mgp-preview {
    position: absolute; left: 0; right: 0; bottom: 0; height: 240px; z-index: 0;
    display: flex; gap: 16px; justify-content: center; align-items: flex-start; padding: 0 16px;
    pointer-events: none; overflow: hidden;
    -webkit-mask-image: linear-gradient(to bottom, #000 30%, transparent 96%);
    mask-image: linear-gradient(to bottom, #000 30%, transparent 96%);
}
.mgp-card { flex: 0 0 230px; height: 190px; background: #fff; border-radius: 16px; padding: 16px; box-shadow: 0 6px 24px rgba(27, 29, 40, .05); display: flex; flex-direction: column; gap: 8px; }
.mgp-card.mgp-wide { flex-basis: 340px; }
.mgp-card.mgp-green { background: var(--mg-green-soft); }
.mgp-cap { font-size: 12px; color: var(--mg-muted); }
.mgp-card b { font-size: 22px; font-weight: 500; }
.mgp-card b small { font-size: 10px; color: var(--mg-muted); vertical-align: top; }
.mgp-card svg { width: 100%; flex: 1; min-height: 0; }
.mgp-bars, .mgp-lines { display: flex; flex-direction: column; gap: 12px; margin-top: 8px; }
.mgp-bars i, .mgp-lines i { display: block; height: 8px; border-radius: 8px; background: #8FDDB0; }
.mgp-bars i.mgp-o { background: #F9B98A; }
.mgp-cols { flex: 1; display: flex; align-items: flex-end; gap: 12px; padding-top: 10px; }
.mgp-cols i { flex: 1; border-radius: 8px 8px 0 0; background: #F9B98A; }
.mgp-cols i:nth-child(even) { background: #FBD3B4; }

/* ---------- Inscription ---------- */
body.mg-register { background: #fff; }
.mgr-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 32px; border-bottom: 1px solid var(--mg-line); }
.mgr-nav { display: flex; align-items: center; gap: 20px; font-size: 15px; }
.mgr-nav > a:not(.mg-btn) { color: #3F4354; text-decoration: none; }
.mgr-nav > a:not(.mg-btn):hover { color: var(--mg-orange-dark); }
.mgr { max-width: 1180px; margin: 0 auto; padding: 28px 32px 64px; display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 48px; align-items: start; }
.mgr-progress { height: 4px; border-radius: 4px; background: var(--mg-green-soft); overflow: hidden; max-width: 720px; }
.mgr-progress span { display: block; height: 100%; background: var(--mg-green); border-radius: 4px; transition: width .25s; }
.mgr-step { margin: 8px 0 14px; font-size: 13.5px; color: var(--mg-muted); }
.mgr-step b { color: var(--mg-green-dark); font-weight: 500; }
.mgr h1 { margin: 0 0 14px; font-size: 30px; line-height: 1.2; font-weight: 500; letter-spacing: -0.015em; }
.mgr-have { margin: 0 0 24px; font-size: 16px; }
.mgr-pane { border: 0; padding: 0; margin: 0; min-width: 0; max-width: 720px; }
.mgr-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 20px; }
.mgr-grid .mg-full { grid-column: 1 / -1; }
.mgr-actions { display: flex; justify-content: flex-end; gap: 12px; margin-top: 12px; }
.mgr-tc { border: 1px solid var(--mg-line); border-radius: 10px; padding: 12px 14px; max-height: 220px; overflow: auto; font-size: 13.5px; margin-bottom: 14px; }

.mgr-side { background: #fff; border-radius: 20px; padding: 22px; box-shadow: 0 16px 48px rgba(27, 29, 40, .09); border: 1px solid #F1F2F4; }
.mgr-side h2 { margin: 0 0 12px; font-size: 19px; font-weight: 500; }
.mgr-offer { margin: 0 0 12px; font-size: 14.5px; color: #2E3140; }
.mgr-note { background: #F7F7F8; border-radius: 12px; padding: 12px 14px 12px 40px; font-size: 13.5px; margin-bottom: 10px; position: relative; }
.mgr-note::before { content: "i"; position: absolute; left: 12px; top: 12px; width: 18px; height: 18px; border-radius: 50%; border: 1.5px solid var(--mg-orange); color: var(--mg-orange-dark); font-size: 11px; font-weight: 700; display: flex; align-items: center; justify-content: center; }
.mgr-limits { list-style: none; margin: 14px 0 0; padding: 14px 16px; background: var(--mg-green-soft); border-radius: 14px; }
.mgr-limits li { display: flex; justify-content: space-between; gap: 12px; padding: 5px 0; font-size: 14px; }
.mgr-side .mg-btn { margin-top: 8px; }

/* ---------- Telephone et tablette ---------- */
@media (max-width: 900px) {
    .mgl { grid-template-columns: 1fr; gap: 28px; padding: 32px 16px 200px; }
    .mgl-pitch h1 { font-size: 26px; }
    .mgl-pitch p { font-size: 17px; }
    .mgl-card { padding: 26px 20px 22px; }
    .mgr { grid-template-columns: 1fr; gap: 24px; padding: 20px 16px 48px; }
    .mgr-top { padding: 12px 16px; }
    .mgr h1 { font-size: 24px; }
    /* Sur telephone, le formulaire d'abord ; le recapitulatif vient ensuite. */
}
@media (max-width: 560px) {
    .mgr-grid { grid-template-columns: 1fr; }
    .mgr-actions { flex-direction: column-reverse; }
    .mgr-actions .mg-btn { width: 100%; }
    .mg-logo { font-size: 20px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* ================= Page d'accueil (site vitrine) ================= */
body.mg-home { background: #fff; }
.mg-home main { overflow: hidden; }
.mg-home h2 { font-size: 30px; font-weight: 500; letter-spacing: -0.015em; line-height: 1.2; margin: 0 0 12px; text-align: center; }
.mg-home section { padding: 64px 24px; }

.mgh-top { position: sticky; top: 0; z-index: 20; background: rgba(255, 255, 255, .92); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); border-bottom: 1px solid var(--mg-line); display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 12px 32px; }
.mgh-nav { display: flex; gap: 28px; font-size: 15px; }
.mgh-nav a { color: #3F4354; text-decoration: none; }
.mgh-nav a:hover { color: var(--mg-orange-dark); }
.mgh-cta { display: flex; gap: 10px; }

.mgh-hero { text-align: center; background: radial-gradient(1000px 520px at 50% 62%, rgba(245, 136, 58, .16), transparent 70%); padding-top: 72px !important; padding-bottom: 0 !important; position: relative; }
.mgh-hero h1 { margin: 0 auto 18px; font-size: 46px; line-height: 1.15; font-weight: 500; letter-spacing: -0.02em; max-width: 760px; }
.mgh-lead { margin: 0 auto 24px; font-size: 21px; color: #2E3140; max-width: 640px; }
.mgh-price { display: inline-block; margin: 0 0 18px; padding: 4px 16px; border: 1.5px solid var(--mg-green); border-radius: 50%; color: var(--mg-green-dark); font-weight: 600; transform: rotate(-4deg); }
.mgh-actions { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }

.mgh-shot { max-width: 980px; margin: 44px auto 0; background: #fff; border-radius: 20px 20px 0 0; box-shadow: 0 -8px 60px rgba(27, 29, 40, .10); border: 1px solid var(--mg-line); border-bottom: 0; text-align: left; overflow: hidden; -webkit-mask-image: linear-gradient(to bottom, #000 62%, transparent); mask-image: linear-gradient(to bottom, #000 62%, transparent); }
.mgh-shot-bar { display: flex; align-items: center; gap: 8px; padding: 12px 18px; border-bottom: 1px solid var(--mg-line); font-size: 15px; }
.mgh-shot-bar .mg-logo-bars { transform: scale(.7); transform-origin: left center; margin-right: -6px; }
.mgh-shot-body { display: flex; }
.mgh-shot-rail { flex: 0 0 64px; border-right: 1px solid var(--mg-line); padding: 14px 0; display: flex; flex-direction: column; align-items: center; gap: 14px; }
.mgh-shot-rail i { width: 34px; height: 34px; border-radius: 10px; border: 1px solid var(--mg-line); }
.mgh-shot-rail i.on { background: var(--mg-orange); border-color: var(--mg-orange); }
.mgh-shot-main { flex: 1; min-width: 0; padding: 16px 18px 0; background: #FAFAFB; }
.mgh-shot-hello { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.mgh-shot-hello > i { width: 36px; height: 36px; border-radius: 50%; background: var(--mg-green); flex: 0 0 auto; }
.mgh-shot-hello b { display: block; font-size: 15px; font-weight: 500; }
.mgh-shot-hello span { font-size: 12px; color: var(--mg-muted); }
.mgh-shot-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.mgh-shot-grid .mgp-card { flex: none; height: 200px; box-shadow: none; border: 1px solid var(--mg-line); }
.mgh-red { color: #E5484D; }
.mgh-pie { width: 84px; height: 84px; border-radius: 50%; margin: 6px auto 0; background: conic-gradient(#8FDDB0 0 68%, #F9A8A0 68% 100%); }

.mgh-ps { text-align: center; background: radial-gradient(700px 300px at 50% 100%, rgba(52, 183, 106, .10), transparent 70%); }
.mgh-switch { display: inline-flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.mgh-switch button { border: 0; background: none; font: inherit; font-size: 18px; color: #A3A8B3; cursor: pointer; padding: 6px 4px; }
.mgh-switch button.on { color: #E5484D; }
.mgh-switch.is-solutions button.on { color: var(--mg-green-dark); }
.mgh-switch button:focus-visible { outline: 2px solid var(--mg-orange); outline-offset: 2px; border-radius: 6px; }
.mgh-switch-knob { width: 40px; height: 22px; border-radius: 22px; background: #E1E4EA; position: relative; cursor: pointer; transition: background-color .2s; }
.mgh-switch-knob::after { content: ""; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .2); transition: transform .2s; }
.mgh-switch.is-solutions .mgh-switch-knob { background: var(--mg-green); }
.mgh-switch.is-solutions .mgh-switch-knob::after { transform: translateX(18px); }
.mgh-list { list-style: none; margin: 20px auto 0; padding: 0; display: inline-flex; flex-direction: column; gap: 14px; text-align: left; font-size: 19px; }
.mgh-list li { display: flex; align-items: center; gap: 14px; }
.mgh-list li::before { content: ""; flex: 0 0 22px; height: 3px; border-radius: 3px; background: #F0655B; }
.mgh-list-good li::before { background: var(--mg-green); }

.mgh-modules { background: radial-gradient(900px 480px at 50% 50%, rgba(52, 183, 106, .12), transparent 70%); }
.mgh-mod-grid { max-width: 920px; margin: 24px auto 0; background: #fff; border-radius: 20px; box-shadow: 0 16px 48px rgba(27, 29, 40, .07); display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); overflow: hidden; }
.mgh-mod { padding: 22px 24px; border-right: 1px solid var(--mg-line); border-bottom: 1px solid var(--mg-line); }
.mgh-mod:nth-child(3n) { border-right: 0; }
.mgh-mod:nth-last-child(-n+3) { border-bottom: 0; }
.mgh-mod-head { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.mgh-mod-ico { width: 40px; height: 40px; border-radius: 12px; background: #F4F5F7; display: flex; align-items: center; justify-content: center; flex: 0 0 auto; }
.mgh-mod-ico svg { width: 20px; height: 20px; }
.mgh-mod h3 { margin: 0; font-size: 15px; font-weight: 500; }
.mgh-mod p { margin: 0; font-size: 14.5px; color: #4B5563; }

.mgh-steps { text-align: center; }
.mgh-sub { margin: 0 auto 26px; font-size: 16px; color: #2E3140; }
.mgh-step-grid { list-style: none; margin: 0 auto 28px; padding: 0; max-width: 980px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; text-align: left; }
.mgh-step-grid li { border-radius: 16px; padding: 18px 20px; background: #F4F5F7; }
.mgh-step-grid li.s1 { background: #FDE6D2; }
.mgh-step-grid li.s3 { background: #DDF3E5; }
.mgh-step-grid span { font-size: 12.5px; color: #4B5563; }
.mgh-step-grid p { margin: 8px 0 0; font-size: 17px; line-height: 1.35; }

.mgh-local { max-width: 1000px; margin: 0 auto; }
.mgh-local-head { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; align-items: start; margin-bottom: 28px; }
.mgh-local-head h2 { text-align: left; margin: 0; }
.mgh-local-head p { margin: 0; font-size: 16px; color: #2E3140; }
.mgh-local-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 16px; }
.mgh-tile { background: #F7F7F8; border-radius: 16px; padding: 22px 24px; min-height: 150px; }
.mgh-tile.t1 { grid-column: span 5; }
.mgh-tile.t2 { grid-column: span 7; }
.mgh-tile.t3 { grid-column: span 7; }
.mgh-tile.t4 { grid-column: span 5; }
.mgh-tile h3 { margin: 0 0 6px; font-size: 20px; font-weight: 500; color: var(--mg-green-dark); line-height: 1.25; }
.mgh-tile p { margin: 0; font-size: 15px; }
.mgh-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.mgh-chips span { background: #fff; border: 1px solid var(--mg-line); border-radius: 999px; padding: 6px 12px; font-size: 13px; font-weight: 500; }

.mgh-final { text-align: center; background: radial-gradient(800px 360px at 50% 40%, rgba(245, 136, 58, .16), transparent 70%); padding-bottom: 88px !important; }
.mgh-final h2 { font-size: 40px; margin-bottom: 16px; }
.mgh-final p { margin: 0 auto 26px; font-size: 19px; max-width: 600px; color: #2E3140; }

.mgh-foot { border-top: 1px solid var(--mg-line); padding: 24px 32px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.mgh-foot nav { display: flex; flex-wrap: wrap; gap: 24px; font-size: 15px; }
.mgh-foot nav a { color: #3F4354; text-decoration: none; }
.mgh-foot nav a:hover { color: var(--mg-orange-dark); }
.mgh-copy { font-size: 13px; color: var(--mg-muted); }

@media (max-width: 900px) {
    .mgh-top { padding: 10px 16px; }
    .mgh-nav { display: none; }
    .mg-home section { padding: 44px 16px; }
    .mgh-hero h1 { font-size: 30px; }
    .mgh-hero h1 br, .mgh-final h2 br { display: none; }
    .mgh-lead { font-size: 17px; }
    .mg-home h2 { font-size: 24px; }
    .mgh-final h2 { font-size: 28px; }
    .mgh-shot-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .mgh-shot-rail { display: none; }
    .mgh-mod-grid { grid-template-columns: 1fr; }
    .mgh-mod { border-right: 0 !important; border-bottom: 1px solid var(--mg-line) !important; }
    .mgh-mod:last-child { border-bottom: 0 !important; }
    .mgh-step-grid { grid-template-columns: 1fr; }
    .mgh-local-head { grid-template-columns: 1fr; gap: 12px; }
    .mgh-tile { grid-column: 1 / -1 !important; min-height: 0; }
    .mgh-list { font-size: 16px; }
    .mgh-foot { padding: 20px 16px; flex-direction: column; align-items: flex-start; }
}
@media (max-width: 480px) {
    /* Connexion et Essai gratuit restent tous les deux visibles, en plus compact. */
    .mgh-top { gap: 8px; padding: 10px 12px; }
    .mgh-top .mg-logo { font-size: 19px; gap: 7px; min-width: 0; }
    .mgh-cta { gap: 6px; flex: 0 0 auto; }
    .mgh-cta .mg-btn { padding: 8px 11px; font-size: 13.5px; white-space: nowrap; }
    .mgh-actions .mg-btn { width: 100%; }
}

.mg-home section[id] { scroll-margin-top: 72px; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

/* ================= Page des tarifs ================= */
.mgh-nav a.on { color: var(--mg-orange-dark); font-weight: 600; }
.mgt-hero { text-align: center; padding-top: 64px !important; padding-bottom: 20px !important; background: radial-gradient(900px 380px at 50% 100%, rgba(245, 136, 58, .12), transparent 70%); }
.mgt-hero h1 { margin: 0 auto 14px; font-size: 40px; font-weight: 500; letter-spacing: -0.02em; line-height: 1.15; }
.mgt-list { padding-top: 28px !important; }
.mgt-none { text-align: center; color: var(--mg-muted); font-size: 17px; }
.mgt-grid { max-width: 1080px; margin: 0 auto; display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 20px; align-items: stretch; }
.mgt-card { position: relative; background: #fff; border: 1px solid var(--mg-line); border-radius: 20px; padding: 26px 24px 24px; display: flex; flex-direction: column; }
.mgt-card.is-popular { border-color: var(--mg-orange); box-shadow: 0 18px 48px rgba(245, 136, 58, .16); }
.mgt-badge { position: absolute; top: -12px; left: 24px; background: var(--mg-orange); color: #fff; border-radius: 999px; padding: 4px 12px; font-size: 12.5px; font-weight: 600; }
.mgt-card h2 { margin: 0 0 6px !important; font-size: 21px !important; text-align: left !important; font-weight: 600 !important; }
.mgt-desc { margin: 0 0 14px; color: #4B5563; font-size: 14.5px; }
.mgt-price { margin: 6px 0 4px; display: flex; align-items: baseline; flex-wrap: wrap; gap: 6px; }
.mgt-price b { font-size: 36px; font-weight: 600; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.mgt-price span { color: var(--mg-muted); font-size: 15px; }
.mgt-trial { margin: 0 0 6px; color: var(--mg-green-dark); font-weight: 500; font-size: 14.5px; }
.mgt-feats { list-style: none; margin: 16px 0 22px; padding: 16px 0 0; border-top: 1px solid var(--mg-line); display: flex; flex-direction: column; gap: 10px; font-size: 14.5px; flex: 1; }
.mgt-feats li { position: relative; padding-left: 26px; }
.mgt-feats li::before { content: ""; position: absolute; left: 0; top: 3px; width: 16px; height: 16px; border-radius: 50%; background: var(--mg-green-soft); }
.mgt-feats li::after { content: ""; position: absolute; left: 5px; top: 6px; width: 6px; height: 9px; border: solid var(--mg-green-dark); border-width: 0 2px 2px 0; transform: rotate(40deg) scale(.7); }
@media (max-width: 900px) { .mgt-hero h1 { font-size: 28px; } }
.mgt-toggle { display: inline-flex; gap: 4px; margin-top: 22px; padding: 4px; border-radius: 999px; background: #fff; border: 1px solid var(--mg-line); box-shadow: 0 4px 14px rgba(27, 29, 40, .06); }
.mgt-toggle button { border: 0; background: none; font: inherit; font-size: 15.5px; font-weight: 500; color: #3F4354; padding: 9px 22px; border-radius: 999px; cursor: pointer; min-height: 42px; }
.mgt-toggle button.on { background: var(--mg-ink); color: #fff; }
.mgt-toggle button:focus-visible { outline: 2px solid var(--mg-orange); outline-offset: 2px; }
.mgt-card[hidden] { display: none; }
.mgt-desc { margin: 12px 0 0 !important; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; line-height: 1.5; }
.mgt-desc.is-open { display: block; }
.mgt-more { align-self: flex-start; margin-top: 4px; padding: 4px 0; border: 0; background: none; font: inherit; font-size: 13.5px; font-weight: 500; color: var(--mg-orange-dark); cursor: pointer; }
.mgt-grid { grid-template-columns: repeat(auto-fit, minmax(250px, 340px)) !important; justify-content: center; }
.mgt-free { max-width: 1080px; margin: 22px auto 0; background: #F7F7F8; border: 1px dashed #D5D9E0; border-radius: 20px; padding: 20px 24px; display: flex; align-items: center; gap: 18px 28px; flex-wrap: wrap; }
.mgt-free-main { flex: 1 1 300px; min-width: 0; }
.mgt-free-tag { display: inline-block; font-size: 12.5px; font-weight: 600; color: var(--mg-green-dark); background: var(--mg-green-soft); border-radius: 999px; padding: 3px 11px; margin-bottom: 6px; }
.mgt-free h2 { margin: 0 !important; font-size: 19px !important; font-weight: 600 !important; text-align: left !important; }
.mgt-free h2 b { font-weight: 600; color: var(--mg-green-dark); }
.mgt-free p { margin: 4px 0 0; font-size: 14.5px; color: #4B5563; }
.mgt-free-feats { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; flex: 1 1 280px; }
.mgt-free-feats li { background: #fff; border: 1px solid var(--mg-line); border-radius: 999px; padding: 6px 13px; font-size: 13.5px; font-weight: 500; }
.mgt-free .mg-btn { flex: 0 0 auto; }
@media (max-width: 640px) { .mgt-free { padding: 18px; } .mgt-free .mg-btn { width: 100%; } }

.mg-check small { display: block; font-size: 12.5px; font-weight: 400; color: var(--mg-muted); }

/* ---- Menu du haut des pages publiques : jamais sur deux lignes ; sur tablette et telephone, il se replie ---- */
.mgh-nav a, .mgh-cta .mg-btn { white-space: nowrap; }
.mgh-cta { align-items: center; flex: 0 0 auto; }
.mgh-top .mg-logo { flex: 0 0 auto; }
.mgh-burger, .mgh-nav-cnx { display: none; }
.mgh-burger .mgh-b2 { display: none; }
@media (max-width: 1280px) and (min-width: 1101px) { .mgh-nav { gap: 20px; font-size: 14.5px; } .mgh-top { padding: 12px 24px; gap: 16px; } }
@media (max-width: 1100px) {
    .mgh-top { padding: 10px 20px; }
    .mgh-burger { display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto; width: 42px; height: 42px; padding: 0; border: 1px solid var(--mg-line); border-radius: 12px; background: #fff; color: var(--mg-ink); cursor: pointer; }
    .mgh-burger svg { width: 22px; height: 22px; }
    .mgh-burger:focus-visible { outline: 2px solid var(--mg-orange); outline-offset: 2px; }
    .mgh-top.ouvert .mgh-burger .mgh-b1 { display: none; } .mgh-top.ouvert .mgh-burger .mgh-b2 { display: inline; }
    .mgh-top.ouvert .mgh-burger { border-color: var(--mg-orange); color: var(--mg-orange-dark); }
    .mgh-nav { display: none; }
    .mgh-top.ouvert .mgh-nav { display: flex; flex-direction: column; gap: 0; position: absolute; top: 100%; left: 0; right: 0; padding: 6px 20px 14px; background: #fff; border-bottom: 1px solid var(--mg-line); box-shadow: 0 18px 40px rgba(27, 29, 40, .12); max-height: calc(100vh - 70px); overflow-y: auto; font-size: 16px; animation: mgh-menu .16s ease-out; }
    .mgh-top.ouvert .mgh-nav a { display: block; padding: 14px 6px; border-bottom: 1px solid #F1F2F5; font-weight: 500; }
    .mgh-top.ouvert .mgh-nav a:last-child { border-bottom: 0; }
}
@keyframes mgh-menu { from { opacity: 0; transform: translateY(-6px); } }
@media (max-width: 520px) {
    .mgh-top { padding: 10px 12px; }
    .mgh-cta .mgh-cnx { display: none; }
    .mgh-top.ouvert .mgh-nav .mgh-nav-cnx { display: block; color: var(--mg-orange-dark); font-weight: 600; }
    .mgh-top.ouvert .mgh-nav { padding: 6px 12px 14px; }
}
@media (min-width: 521px) { .mgh-top.ouvert .mgh-nav a.mgh-nav-cnx { display: none; } .mgh-top.ouvert .mgh-nav a:nth-last-child(2) { border-bottom: 0; } }
