@charset "UTF-8";
/* ==========================================================
   IPM TOOLS-DESIGN | atelier.css
   Les outils de la rédaction : un formulaire à gauche,
   l'aperçu à droite, un bouton pour récupérer le résultat.
   ========================================================== */

.atelier { max-width: var(--maxw); margin: 0 auto; padding: 0 var(--pad-x) clamp(60px, 9vh, 110px); display: grid; grid-template-columns: minmax(300px, 420px) minmax(0, 1fr); gap: clamp(24px, 4vw, 56px); align-items: start; }
@media (max-width: 900px) { .atelier { grid-template-columns: 1fr; } }

.atelier__form { display: flex; flex-direction: column; gap: 22px; min-width: 0; }
.atelier__group { border: 0; margin: 0; padding: 0 0 22px; border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.atelier__group:last-child { border-bottom: 0; }
.atelier__legend { font-family: var(--f-mono); font-size: 11px; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); padding: 0; margin: 0 0 4px; }

.fld { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.fld__label { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; font-family: var(--f-body); font-size: 14px; font-weight: 600; color: var(--ink); }
.fld__hint { font-size: 12.5px; line-height: 1.5; color: var(--muted); margin: 0; }
.fld__hint code { font-family: var(--f-mono); font-size: 12px; color: var(--ink-soft); background: var(--bg-2); padding: 1px 5px; border-radius: 3px; }
.fld input[type="text"], .fld input[type="url"], .fld input[type="number"], .fld input[type="datetime-local"], .fld select, .fld textarea {
  width: 100%; font: inherit; font-size: 15px; line-height: 1.45; color: var(--ink); background: var(--surface);
  border: 1px solid var(--line-strong); border-radius: 6px; padding: 10px 12px; transition: border-color var(--t-fast), box-shadow var(--t-fast);
}
.fld textarea { min-height: 110px; resize: vertical; font-size: 14px; }
.fld textarea.is-code { font-family: var(--f-mono); font-size: 13px; min-height: 160px; }
.fld input:focus-visible, .fld select:focus-visible, .fld textarea:focus-visible { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.fld input[type="file"] { font-size: 13px; color: var(--ink-soft); }
.fld input[type="color"] { width: 46px; height: 34px; padding: 2px; border: 1px solid var(--line-strong); border-radius: 6px; background: var(--surface); }
.fld-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.fld-check { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--ink-soft); cursor: pointer; }
.fld-check input { width: 18px; height: 18px; accent-color: var(--accent); }

/* Boutons segmentés (radios) */
.seg { display: flex; flex-wrap: wrap; gap: 6px; }
.seg label { position: relative; cursor: pointer; }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg span { display: inline-block; font-family: var(--f-mono); font-size: 12px; letter-spacing: .04em; padding: 8px 12px; border: 1px solid var(--line-strong); border-radius: 9999px; color: var(--ink-soft); transition: background var(--t-fast), color var(--t-fast), border-color var(--t-fast); }
.seg input:checked + span { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.seg input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }

/* Boutons */
.btn-row { display: flex; flex-wrap: wrap; gap: 10px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; font-family: var(--f-mono); font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; padding: 13px 20px; border-radius: 6px; border: 1px solid var(--ink); background: var(--ink); color: var(--bg); cursor: pointer; transition: transform var(--t-fast), background var(--t-fast), color var(--t-fast); }
.btn:hover { transform: translateY(-1px); }
.btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--line-strong); }
.btn--ghost:hover { border-color: var(--ink); }
.btn--small { padding: 8px 12px; font-size: 11px; }
.btn[disabled] { opacity: .45; cursor: not-allowed; transform: none; }

/* Aperçu */
.atelier__preview { position: sticky; top: 90px; display: flex; flex-direction: column; gap: 14px; min-width: 0; }
@media (max-width: 900px) { .atelier__preview { position: static; } }
.atelier__stage { background: var(--bg-2); border: 1px solid var(--line); border-radius: 10px; padding: clamp(14px, 3vw, 30px); display: grid; place-items: center; min-height: 320px; overflow: hidden; }
.atelier__stage canvas { display: block; max-width: 100%; height: auto; max-height: 72vh; box-shadow: 0 20px 40px -24px rgba(0,0,0,.45); }
.atelier__stage--checker { background-color: var(--bg-2); background-image: linear-gradient(45deg, var(--line) 25%, transparent 25%), linear-gradient(-45deg, var(--line) 25%, transparent 25%), linear-gradient(45deg, transparent 75%, var(--line) 75%), linear-gradient(-45deg, transparent 75%, var(--line) 75%); background-size: 20px 20px; background-position: 0 0, 0 10px, 10px -10px, -10px 0; }
.atelier__note { font-size: 13px; line-height: 1.55; color: var(--muted); margin: 0; }
.atelier__note strong { color: var(--ink-soft); }

/* Code à copier */
.code-out { position: relative; }
.code-out pre { margin: 0; max-height: 220px; overflow: auto; white-space: pre-wrap; word-break: break-all; font-family: var(--f-mono); font-size: 12px; line-height: 1.55; color: var(--ink-soft); background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 14px 16px; }
.code-out .btn { position: absolute; top: 8px; right: 8px; }

/* Compteurs (titre, description) */
.count { font-family: var(--f-mono); font-size: 12px; font-weight: 600; color: var(--muted); white-space: nowrap; }
.count.is-ok { color: #1f7a4d; }
.count.is-warn { color: #a86400; }
.count.is-bad { color: #b0283a; }
[data-theme="dark"] .count.is-ok { color: #6fd3a0; }
[data-theme="dark"] .count.is-warn { color: #f2c46d; }
[data-theme="dark"] .count.is-bad { color: #ff8a98; }

/* Onglets de type (atelier d'embeds) */
.type-tabs { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.type-tabs label { cursor: pointer; position: relative; }
.type-tabs input { position: absolute; opacity: 0; pointer-events: none; }
.type-tabs span { display: flex; flex-direction: column; gap: 3px; height: 100%; padding: 12px 14px; border: 1px solid var(--line-strong); border-radius: 8px; background: var(--surface); transition: border-color var(--t-fast), box-shadow var(--t-fast); }
.type-tabs b { font-size: 14px; }
.type-tabs small { font-size: 12px; line-height: 1.4; color: var(--muted); }
.type-tabs input:checked + span { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.type-tabs input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
[hidden] { display: none !important; }

.embed-frame { width: 100%; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.embed-frame iframe { display: block; width: 100%; border: 0; min-height: 200px; transition: height .2s ease; }
.embed-frame.is-mobile { max-width: 390px; margin: 0 auto; }

/* Index : « J'ai besoin de... » */
.need-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 10px; }
.need { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 16px 18px; border: 1px solid var(--line); background: var(--surface); border-radius: 8px; font-size: 15px; line-height: 1.35; color: var(--ink); transition: border-color var(--t-fast), transform var(--t-fast); }
.need:hover { border-color: var(--ink); transform: translateY(-2px); }
.need small { display: block; font-family: var(--f-mono); font-size: 11px; letter-spacing: .06em; color: var(--muted); margin-top: 4px; }
.need .arrow { color: var(--accent); transition: transform var(--t-base); }
.need:hover .arrow { transform: translateX(4px); }
.need:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* Carte : liste des pays mis en avant, points */
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; padding: 5px 6px 5px 10px; border-radius: 9999px; background: var(--bg-2); border: 1px solid var(--line); }
.chip button { width: 22px; height: 22px; border-radius: 50%; border: 0; background: transparent; color: var(--muted); cursor: pointer; font-size: 15px; line-height: 1; }
.chip button:hover { color: var(--ink); background: var(--line); }
.suggest { position: relative; }
.suggest__list { position: absolute; z-index: 20; left: 0; right: 0; top: 100%; margin: 4px 0 0; padding: 4px; list-style: none; background: var(--surface); border: 1px solid var(--line-strong); border-radius: 8px; box-shadow: var(--shadow); max-height: 240px; overflow: auto; }
.suggest__list li { padding: 8px 10px; border-radius: 5px; font-size: 14px; cursor: pointer; }
.suggest__list li[aria-selected="true"], .suggest__list li:hover { background: var(--bg-2); }
.atelier__stage--map { cursor: crosshair; }

/* Aperçu de partage */
.share-grid { display: grid; gap: 22px; }
.share-block h3 { font-family: var(--f-mono); font-size: 11px; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); margin: 0 0 10px; }
.sp-google { background: #fff; color: #202124; border: 1px solid #dadce0; border-radius: 12px; padding: 18px 20px; font-family: Arial, Helvetica, sans-serif; max-width: 652px; }
.sp-google__site { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.sp-google__fav { width: 26px; height: 26px; border-radius: 50%; background: #f1f3f4; display: grid; place-items: center; font-size: 12px; font-weight: 700; color: #fff; }
.sp-google__name { font-size: 14px; line-height: 1.3; color: #202124; }
.sp-google__url { font-size: 12px; color: #4d5156; }
.sp-google__title { font-size: 20px; line-height: 1.3; color: #1a0dab; margin: 0 0 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 600px; }
.sp-google__desc { font-size: 14px; line-height: 1.58; color: #4d5156; margin: 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.sp-fb { background: #fff; color: #050505; border: 1px solid #dadde1; border-radius: 8px; overflow: hidden; max-width: 500px; font-family: Helvetica, Arial, sans-serif; }
.sp-img { position: relative; aspect-ratio: 1.91 / 1; background: #e4e6eb center / cover no-repeat; display: grid; place-items: center; color: #8a8d91; font-size: 13px; }
.sp-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.sp-fb__body { padding: 10px 12px 12px; background: #f0f2f5; }
.sp-fb__dom { font-size: 12px; text-transform: uppercase; color: #65676b; letter-spacing: .02em; }
.sp-fb__title { font-size: 16px; font-weight: 600; line-height: 1.3; margin: 3px 0 2px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.sp-fb__desc { font-size: 14px; color: #65676b; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }
.sp-x { max-width: 500px; font-family: -apple-system, "Helvetica Neue", Arial, sans-serif; }
.sp-x__card { position: relative; border: 1px solid #cfd9de; border-radius: 16px; overflow: hidden; }
.sp-x__title { position: absolute; left: 12px; bottom: 12px; max-width: calc(100% - 24px); background: rgba(0,0,0,.77); color: #fff; font-size: 13px; line-height: 1.3; padding: 2px 6px; border-radius: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sp-x__from { font-size: 13px; color: #536471; margin-top: 4px; }
.sp-wa { background: #efeae2; padding: 16px; border-radius: 10px; max-width: 420px; }
.sp-wa__bubble { margin-left: auto; max-width: 330px; background: #d9fdd3; border-radius: 8px; padding: 4px; box-shadow: 0 1px 1px rgba(0,0,0,.12); font-family: -apple-system, "Helvetica Neue", Arial, sans-serif; color: #111b21; }
.sp-wa__card { display: flex; flex-direction: column; background: #d1f4cc; border-radius: 6px; overflow: hidden; }
.sp-wa__card .sp-img { aspect-ratio: 1.91 / 1; }
.sp-wa__txt { padding: 8px 10px; }
.sp-wa__title { font-size: 14px; font-weight: 600; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.sp-wa__desc { font-size: 12.5px; color: #54656f; line-height: 1.35; margin-top: 2px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.sp-wa__dom { font-size: 12px; color: #667781; margin-top: 2px; }
.sp-wa__link { font-size: 14px; color: #027eb5; padding: 6px 6px 2px; word-break: break-all; }
.sp-wa__time { text-align: right; font-size: 11px; color: #667781; padding: 0 6px 2px; }
.share-tips { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.share-tips li { display: flex; gap: 10px; font-size: 14px; line-height: 1.5; color: var(--ink-soft); }
.share-tips li::before { content: ""; flex: 0 0 8px; height: 8px; margin-top: 7px; border-radius: 50%; background: var(--muted); }
.share-tips li.is-ok::before { background: #2fae6b; }
.share-tips li.is-warn::before { background: #e3a21a; }
.share-tips li.is-bad::before { background: #d6334a; }

/* Checklist */
.check-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 8px; }
.check-progress { flex: 1; min-width: 200px; display: flex; align-items: center; gap: 14px; }
.check-progress__bar { flex: 1; height: 8px; background: var(--bg-2); border: 1px solid var(--line); border-radius: 99px; overflow: hidden; }
.check-progress__bar i { display: block; height: 100%; width: 0; background: var(--accent); transition: width var(--t-base); }
.check-progress b { font-family: var(--f-mono); font-size: 14px; }
.check-groups { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 18px; }
.check-group { border: 1px solid var(--line); background: var(--surface); border-radius: 10px; padding: 20px 22px; }
.check-group h3 { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; font-family: var(--f-display); font-size: 22px; line-height: 1.1; margin: 0 0 12px; }
.check-group h3 small { font-family: var(--f-mono); font-size: 12px; color: var(--muted); }
.check-group ul { list-style: none; margin: 0; padding: 0; }
.check-group li { border-top: 1px solid var(--line); }
.check-group label { display: flex; gap: 12px; padding: 11px 0; font-size: 14.5px; line-height: 1.5; color: var(--ink); cursor: pointer; }
.check-group input { flex: 0 0 18px; width: 18px; height: 18px; margin-top: 2px; accent-color: var(--accent); }
.check-group label small { display: block; font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.check-group input:checked ~ span { color: var(--muted); text-decoration: line-through; text-decoration-color: var(--line-strong); }
.check-group a { color: var(--accent); border-bottom: 1px solid currentColor; }

/* Nouveautés */
.news { max-width: 900px; margin: 0 auto; padding: 0 var(--pad-x) clamp(60px, 9vh, 110px); }
.news__day { font-family: var(--f-mono); font-size: 12px; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; color: var(--accent); margin: 40px 0 6px; }
.news__list { list-style: none; margin: 0; padding: 0; }
.news__list li { display: grid; grid-template-columns: 110px 1fr; gap: 18px; padding: 16px 0; border-top: 1px solid var(--line); }
.news__tag { font-family: var(--f-mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); padding-top: 3px; }
.news__list b { display: block; font-size: 16px; margin-bottom: 2px; }
.news__list p { margin: 0; font-size: 15px; line-height: 1.6; color: var(--ink-soft); }
.news__list a { color: var(--accent); border-bottom: 1px solid currentColor; }
@media (max-width: 560px) { .news__list li { grid-template-columns: 1fr; gap: 4px; } }

/* Index : marques à venir */
.brand-soon { margin-top: 28px; padding-top: 22px; border-top: 1px dashed var(--line-strong); display: flex; flex-wrap: wrap; align-items: center; gap: 14px 28px; }
.brand-soon__label { margin: 0; font-family: var(--f-mono); font-size: 11px; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); }
.brand-soon__list { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.brand-soon__item { display: inline-flex; align-items: center; gap: 10px; padding: 8px 14px; border: 1px solid var(--line); border-radius: 99px; font-family: var(--f-mono); font-size: 13px; color: var(--ink-soft); background: var(--surface); }
.brand-soon__item img { height: 16px; width: auto; filter: grayscale(1); opacity: .7; }
[data-theme="dark"] .brand-soon__item img { filter: brightness(0) invert(1); opacity: .6; }

/* Index : outils de la rédaction, deux grands puis trois */
.tpl-grid.tpl-grid--tools { grid-template-columns: repeat(6, 1fr); }
.tpl-grid--tools > * { grid-column: span 2; }
.tpl-grid--tools > :nth-child(-n+4) { grid-column: span 3; }
@media (max-width: 980px) { .tpl-grid.tpl-grid--tools { grid-template-columns: repeat(2, 1fr); } .tpl-grid--tools > *, .tpl-grid--tools > :nth-child(-n+4) { grid-column: auto; } }
@media (max-width: 540px) { .tpl-grid.tpl-grid--tools { grid-template-columns: 1fr; } }
.tb-footer a { color: inherit; border-bottom: 1px solid currentColor; }
.outil-hero--atelier h1 { font-size: clamp(34px, 8.6vw, 100px); }
.share-grid { grid-template-columns: minmax(0, 1fr); }
.share-block { min-width: 0; }

/* Index : couleur de chaque carte marque (ex-style inline) */
.brand-card--dh { --brand: #E1001A; }
.brand-card--lalibre { --brand: #AC115D; }
.brand-card--parismatch { --brand: #D7262C; }
.brand-card--lavenir { --brand: #00E25D; }
.brand-card--moustique { --brand: #E30613; }
.tpl-card--atelier { border-top: 3px solid var(--accent); background: linear-gradient(180deg, var(--accent-soft), transparent 60%), var(--surface); }
.tpl-card--atelier .tpl-card__title { font-size: 32px; }

/* Index : carte du socle commun, pleine largeur */
.tpl-card--socle { margin-bottom: 22px; border-left: 4px solid var(--accent); }
.tpl-card--socle .tpl-card__title { font-size: 32px; }
.tpl-card--socle .tpl-card__desc { max-width: 70ch; }
