/*
 * SkedAC démo — chrome de la démo (barre, tag Pro, tour guidé, modales, chat simulé).
 * Complète ../style.css sans le modifier. Identité : dégradé Sked (#f93b53 → #bb228b).
 */

/* ── Barre démo ─────────────────────────────────────────────────────────── */
.demo-body { padding-top: 46px; transition: opacity .2s ease; }
/* Continuité de page en page pendant le tour (posé par footer.php quand ?tour= est présent) :
   la page démarre invisible, déjà entièrement mise en page (tooltip « ancrée » incluse),
   puis apparaît d'un coup une fois prête — pas de flash du mauvais écran avant que le tour
   ne s'installe. Pages hors tour : aucune classe posée, affichage instantané comme avant. */
.demo-body.is-entering { opacity: 0; }
.demo-body.is-entering.is-ready { opacity: 1; }
.demo-body.is-leaving { opacity: 0; }
.demo-bar {
    position: fixed; top: 0; left: 0; right: 0; z-index: 10050;
    height: 46px; display: flex; align-items: center; gap: 18px; padding: 0 18px;
    background: #14141e; border-bottom: 1px solid rgba(249,59,83,.35);
    box-shadow: 0 6px 24px rgba(0,0,0,.45); font-size: 13px; color: #d6d6de;
}
.demo-bar__left { display: flex; align-items: center; gap: 10px; min-width: 0; }
.demo-bar__badge {
    display: inline-flex; align-items: center; gap: 7px; padding: 4px 10px; border-radius: 999px;
    background: linear-gradient(90deg, #f93b53, #dc2f6e 75%, #bb228b); color: #fff; font-weight: 700;
    font-size: 11px; letter-spacing: .6px; text-transform: uppercase; white-space: nowrap;
}
.demo-bar__dot { width: 7px; height: 7px; border-radius: 50%; background: #fff; animation: demo-pulse 1.8s ease-in-out infinite; }
@keyframes demo-pulse { 0%,100% { box-shadow: 0 0 0 0 rgba(255,255,255,.55); } 50% { box-shadow: 0 0 0 5px rgba(255,255,255,0); } }
.demo-bar__desc { color: #8c8c9a; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.demo-bar__nav { display: flex; align-items: center; gap: 2px; margin-left: auto; }
.demo-bar__nav a { color: #b8b8c4; text-decoration: none; padding: 6px 10px; border-radius: 6px; white-space: nowrap; font-weight: 500; }
.demo-bar__nav a:hover { background: rgba(255,255,255,.06); color: #fff; text-decoration: none; }
.demo-bar__nav a.is-active { color: #fff; background: rgba(249,59,83,.16); }
.demo-bar__right { display: flex; align-items: center; gap: 8px; }
.demo-bar__restart { color: #b8b8c4; text-decoration: none; padding: 6px 10px; border-radius: 6px; white-space: nowrap; }
.demo-bar__restart:hover { color: #fff; background: rgba(255,255,255,.06); text-decoration: none; }
.demo-bar__cta {
    color: #fff; text-decoration: none; padding: 7px 14px; border-radius: 8px; white-space: nowrap; font-weight: 700;
    background: linear-gradient(90deg, #f93b53, #dc2f6e 75%, #bb228b); box-shadow: 0 4px 14px rgba(249,59,83,.35);
}
.demo-bar__cta:hover { color: #fff; text-decoration: none; transform: translateY(-1px); }
.demo-bar__toggle { display: none; }

@media (max-width: 1100px) { .demo-bar__desc { display: none; } }
@media (max-width: 860px) {
    .demo-body { padding-top: 46px; }
    .demo-bar { flex-wrap: wrap; height: auto; min-height: 46px; padding: 0 12px; }
    .demo-bar__nav, .demo-bar__right { display: none; width: 100%; flex-direction: column; align-items: stretch; gap: 0; padding: 6px 0 10px; }
    .demo-bar.is-open .demo-bar__nav, .demo-bar.is-open .demo-bar__right { display: flex; }
    .demo-bar__nav a, .demo-bar__restart { padding: 11px 6px; border-bottom: 1px solid rgba(255,255,255,.06); }
    .demo-bar__cta { text-align: center; margin-top: 8px; }
    .demo-bar__toggle {
        display: flex; flex-direction: column; justify-content: center; gap: 4px; margin-left: auto;
        width: 40px; height: 46px; background: none; border: 0; cursor: pointer; padding: 0 8px;
    }
    .demo-bar__toggle span { display: block; height: 2px; background: #fff; border-radius: 2px; }
}

/* ── Tag Pro ────────────────────────────────────────────────────────────── */
.demo-pro-tag {
    display: inline-block; vertical-align: middle; margin-left: 6px; padding: 1px 7px; border-radius: 999px;
    font-size: 9px; font-weight: 800; letter-spacing: .8px; line-height: 1.6;
    color: #fff; background: linear-gradient(135deg, #9C27B0, #673AB7); border: 1px solid rgba(255,255,255,.18);
    text-transform: uppercase; cursor: help;
}

/* ── Éléments désactivés (réservés aux vrais comptes) ───────────────────── */
[data-demo-action] { cursor: pointer; }
.demo-disabled-input { opacity: .55; cursor: not-allowed !important; }
.demo-chat-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 6px 0 14px; }
.demo-chat-chip {
    background: rgba(156,39,176,.12); border: 1px solid rgba(156,39,176,.45); color: #e2c8ff;
    border-radius: 999px; padding: 7px 13px; font-size: 12px; cursor: pointer; transition: all .2s; font-family: inherit;
}
.demo-chat-chip:hover { background: rgba(156,39,176,.28); color: #fff; transform: translateY(-1px); }
.demo-chat-chip[disabled] { opacity: .45; cursor: default; transform: none; }
.demo-chat-notice {
    margin-bottom: 12px; padding: 10px 14px; border-radius: 8px; font-size: 12px; line-height: 1.5;
    background: rgba(156,39,176,.08); border: 1px solid rgba(156,39,176,.3); color: var(--text-secondary);
}
.demo-chat-notice strong { color: #e2c8ff; }
.demo-typing { display: inline-block; width: 8px; height: 14px; margin-left: 2px; background: #BB86FC; vertical-align: text-bottom; animation: demo-caret 1s steps(2) infinite; }
@keyframes demo-caret { 50% { opacity: 0; } }

/* ── Tour guidé ─────────────────────────────────────────────────────────── */
/* Masqué par défaut : sans position réelle, le « trou » de la spotlight serait
   n'importe où dans le document — l'ombre 9999px assombrirait alors tout l'écran
   sans rien découper dessus. On ne l'affiche qu'une fois positionTour() passé. */
.demo-tour-spot {
    position: absolute; z-index: 10010; border-radius: 14px; pointer-events: none;
    box-shadow: 0 0 0 9999px rgba(6,6,10,.45), 0 0 0 3px rgba(249,59,83,.9), 0 0 32px rgba(249,59,83,.55);
    opacity: 0;
    transition: opacity .25s ease, top .35s ease, left .35s ease, width .35s ease, height .35s ease;
}
.demo-tour-spot.is-visible { opacity: 1; }
/* État par défaut « ancrée » : centrée en haut du viewport, visible tout de suite (avant
   même que la cible réelle soit résolue) — jamais invisible ni mal placée pendant le
   chargement d'une page. Une fois la cible trouvée, .is-positioned bascule en position
   absolue à côté d'elle (positionTour()). */
.demo-tour-tip {
    position: fixed; z-index: 10020; top: 64px; left: 50%; transform: translateX(-50%);
    width: 380px; max-width: calc(100vw - 24px);
    background: #16161f; border: 1px solid rgba(249,59,83,.45); border-radius: 14px;
    box-shadow: 0 24px 60px rgba(0,0,0,.65), 0 0 0 1px rgba(255,255,255,.04);
    color: #f2f2f6; font-family: inherit; animation: demo-tip-in .3s ease;
}
.demo-tour-tip.is-positioned { position: absolute; transform: none; }
@keyframes demo-tip-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.demo-tour-tip__head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 16px 0; }
.demo-tour-tip__chapter { font-size: 10px; letter-spacing: 1px; text-transform: uppercase; font-weight: 800;
    background: linear-gradient(90deg, #f93b53, #dc2f6e 75%, #bb228b); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.demo-tour-tip__count { font-size: 11px; color: #8c8c9a; white-space: nowrap; }
.demo-tour-tip__progress { display: flex; gap: 4px; padding: 10px 16px 0; }
.demo-tour-tip__progress span { flex: 1; height: 3px; border-radius: 3px; background: rgba(255,255,255,.1); }
.demo-tour-tip__progress span.is-done { background: linear-gradient(90deg, #f93b53, #dc2f6e); }
.demo-tour-tip__progress span.is-current { background: #f93b53; box-shadow: 0 0 10px rgba(249,59,83,.8); }
.demo-tour-tip__title { font-size: 16px; font-weight: 800; padding: 12px 16px 4px; line-height: 1.3; }
.demo-tour-tip__text { font-size: 13px; line-height: 1.6; color: #c9c9d3; padding: 0 16px 14px; }
.demo-tour-tip__foot { display: flex; align-items: center; gap: 8px; padding: 0 16px 14px; }
.demo-tour-tip__skip { margin-right: auto; background: none; border: 0; color: #8c8c9a; font-size: 12px; cursor: pointer; padding: 6px 2px; font-family: inherit; }
.demo-tour-tip__skip:hover { color: #fff; }
.demo-tour-btn {
    border: 1px solid rgba(255,255,255,.14); background: rgba(255,255,255,.06); color: #fff; border-radius: 8px;
    padding: 8px 14px; font-size: 13px; font-weight: 600; cursor: pointer; font-family: inherit; transition: all .2s;
}
.demo-tour-btn:hover { background: rgba(255,255,255,.12); }
.demo-tour-btn--primary { border: 0; background: linear-gradient(90deg, #f93b53, #dc2f6e 75%, #bb228b); box-shadow: 0 4px 14px rgba(249,59,83,.35); }
.demo-tour-btn--primary:hover { transform: translateY(-1px); box-shadow: 0 6px 20px rgba(249,59,83,.45); }
.demo-tour-tip__arrow { position: absolute; width: 14px; height: 14px; background: #16161f; border-left: 1px solid rgba(249,59,83,.45); border-top: 1px solid rgba(249,59,83,.45); transform: rotate(45deg); }
.demo-tour-tip--below .demo-tour-tip__arrow { top: -8px; }
.demo-tour-tip--above .demo-tour-tip__arrow { bottom: -8px; transform: rotate(225deg); }
@media (max-width: 640px) {
    .demo-tour-tip { width: calc(100vw - 24px); }
    .demo-tour-tip.is-positioned { left: 12px !important; transform: none; }
    .demo-tour-tip__arrow { display: none; }
}

/* ── Modales (action réservée / fin de visite) ──────────────────────────── */
.demo-modal { position: fixed; inset: 0; z-index: 10060; display: flex; align-items: center; justify-content: center; padding: 20px;
    background: rgba(6,6,10,.78); backdrop-filter: blur(4px); animation: demo-tip-in .25s ease; }
.demo-modal__box { width: 100%; max-width: 480px; background: #16161f; border: 1px solid rgba(249,59,83,.45); border-radius: 18px;
    box-shadow: 0 30px 80px rgba(0,0,0,.7); padding: 30px 28px 24px; text-align: center; color: #f2f2f6; }
.demo-modal__icon { font-size: 40px; line-height: 1; margin-bottom: 12px; }
.demo-modal__title { font-size: 21px; font-weight: 800; margin-bottom: 10px; line-height: 1.25; }
.demo-modal__text { font-size: 14px; line-height: 1.6; color: #c9c9d3; margin-bottom: 22px; }
.demo-modal__actions { display: flex; flex-direction: column; gap: 10px; }
.demo-modal__cta { display: block; padding: 13px 18px; border-radius: 10px; color: #fff; text-decoration: none; font-weight: 800; font-size: 15px;
    background: linear-gradient(90deg, #f93b53, #dc2f6e 75%, #bb228b); box-shadow: 0 6px 20px rgba(249,59,83,.4); }
.demo-modal__cta:hover { color: #fff; text-decoration: none; transform: translateY(-1px); }
.demo-modal__secondary { background: none; border: 1px solid rgba(255,255,255,.14); color: #d6d6de; border-radius: 10px; padding: 11px 18px; cursor: pointer; font-family: inherit; font-size: 13px; font-weight: 600; }
.demo-modal__secondary:hover { background: rgba(255,255,255,.06); color: #fff; }
.demo-modal--end .demo-modal__box { max-width: 560px; border-color: rgba(46,204,113,.5); }
.demo-modal--end .demo-modal__icon { animation: demo-pop .5s ease; }
@keyframes demo-pop { 0% { transform: scale(.4); opacity: 0; } 70% { transform: scale(1.15); } 100% { transform: scale(1); opacity: 1; } }
