/* CRM walkthrough (public/tour.js). Uses the CRM's own palette and type. */
.tour-root{position:fixed;inset:0;z-index:100;pointer-events:auto;--t-card:var(--paper,#FCFCFA);--t-ink:var(--ink,#1A1F17);--t-ink2:var(--ink-2,#4C5548);--t-ink3:var(--ink-3,#77806F);--t-line:var(--stone-200,#D3D5CB);--t-forest:#2C4A32;--t-gold:#C9A44C;--t-wash:#FBF5E4}
:root[data-theme="dark"] .tour-root{--t-forest:#9fc79f;--t-wash:#2e2819}
@media (prefers-color-scheme:dark){:root[data-theme="system"] .tour-root{--t-forest:#9fc79f;--t-wash:#2e2819}}
.tour-veil{position:absolute;inset:0;background:rgba(14,22,16,.52);transition:opacity .2s ease}
.tour-root:not(.no-target) .tour-veil{background:transparent}
.tour-spot{position:absolute;left:0;top:0;border-radius:14px;box-shadow:0 0 0 9999px rgba(14,22,16,.52),0 0 0 3px var(--t-gold),0 0 0 9px rgba(201,164,76,.22);transition:transform .32s cubic-bezier(.2,.7,.2,1),width .32s cubic-bezier(.2,.7,.2,1),height .32s cubic-bezier(.2,.7,.2,1),opacity .2s ease;pointer-events:none}
.tour-card{position:absolute;left:0;top:0;width:min(380px,calc(100vw - 32px));background:var(--t-card);color:var(--t-ink);border:1px solid var(--t-line);border-radius:18px;box-shadow:0 24px 60px rgba(14,22,16,.28),0 4px 14px rgba(14,22,16,.12);padding:18px 20px 16px;font:400 14.5px/1.55 "Libre Franklin",ui-sans-serif,system-ui,-apple-system,sans-serif;transition:transform .32s cubic-bezier(.2,.7,.2,1),opacity .18s ease}
.tour-card.tour-out{opacity:0}
.tour-card[data-pos="center"]{left:50%;top:50%;transform:translate(-50%,-50%);width:min(440px,calc(100vw - 32px))}
.tour-card[data-pos="sheet"]{left:12px;right:12px;top:auto;bottom:calc(84px + env(safe-area-inset-bottom,0px));width:auto;transform:none;max-height:58vh;overflow:auto}
.tour-top{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:6px}
.tour-count{font:700 10.5px/1 "Libre Franklin",sans-serif;letter-spacing:.14em;text-transform:uppercase;color:#8A6614}
:root[data-theme="dark"] .tour-count{color:#dfbe70}
.tour-x{border:0;background:transparent;color:var(--t-ink3);font-size:22px;line-height:1;width:32px;height:32px;border-radius:999px;cursor:pointer;display:grid;place-items:center}
.tour-x:hover{background:var(--stone-50,#F3F3EE);color:var(--t-ink)}
.tour-card h2{font:600 23px/1.2 "EB Garamond",Georgia,serif;margin:0 0 8px;color:var(--t-ink);text-wrap:balance}
.tour-body p{margin:0 0 10px;color:var(--t-ink2)}
.tour-body b{color:var(--t-ink);font-weight:600}
.tour-list{margin:2px 0 10px;padding:0;list-style:none;display:grid;gap:7px}
.tour-list li{position:relative;padding-left:20px;color:var(--t-ink2)}
.tour-list li::before{content:"";position:absolute;left:3px;top:.62em;width:7px;height:7px;border-radius:50%;background:var(--t-gold)}
.tour-checks{list-style:none;margin:4px 0 10px;padding:0;display:grid;gap:8px}
.tour-check{display:grid;grid-template-columns:26px 1fr auto;gap:10px;align-items:center;padding:10px 12px;border:1px solid var(--t-line);border-radius:12px;background:var(--stone-50,#F3F3EE)}
.tour-check.done{background:var(--t-wash);border-color:rgba(201,164,76,.55)}
.tour-tick{width:24px;height:24px;border-radius:50%;border:2px solid var(--t-line);display:grid;place-items:center;font-weight:700;font-size:13px;color:#fff}
.tour-check.done .tour-tick{background:var(--t-forest);border-color:var(--t-forest)}
:root[data-theme="dark"] .tour-check.done .tour-tick{color:#152018}
.tour-check-text{min-width:0;display:grid;gap:1px}
.tour-check-text b{font-size:14px}
.tour-check-text small{font-size:12px;color:var(--t-ink3)}
.tour-state{font:700 11px/1 "Libre Franklin",sans-serif;letter-spacing:.1em;text-transform:uppercase;color:var(--t-forest)}
.tour-foot{font-size:12.5px;color:var(--t-ink3);margin:0}
.tour-nav{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:12px;padding-top:12px;border-top:1px solid var(--t-line)}
.tour-dots{display:flex;gap:5px;flex-wrap:wrap}
.tour-dot{width:7px;height:7px;border-radius:999px;background:var(--t-line);transition:width .25s ease,background .25s ease}
.tour-dot.past{background:rgba(201,164,76,.6)}
.tour-dot.on{width:20px;background:var(--t-gold)}
.tour-actions{display:flex;gap:8px;flex:none}
.tour-btn{font:600 13px/1 "Libre Franklin",sans-serif;border-radius:999px;padding:11px 18px;border:1px solid #2C4A32;background:#2C4A32;color:#EDF1E9;cursor:pointer;text-decoration:none;display:inline-flex;align-items:center;justify-content:center;white-space:nowrap;transition:filter .15s ease,transform .1s ease}
.tour-btn:hover{filter:brightness(1.08)}
.tour-btn:active{transform:scale(.97)}
.tour-btn.ghost{background:transparent;color:var(--t-ink);border-color:var(--t-line)}
.tour-btn.ghost:hover{background:var(--stone-50,#F3F3EE);filter:none}
.tour-btn.sm{padding:8px 13px;font-size:12px}
.tour-btn:focus-visible,.tour-x:focus-visible{outline:2px solid var(--t-gold);outline-offset:2px}
.tour-root.tour-leave{opacity:0;transition:opacity .2s ease}
@media (max-width:820px){.tour-card h2{font-size:21px}.tour-nav{flex-direction:column;align-items:stretch}.tour-dots{justify-content:center}.tour-actions{justify-content:stretch}.tour-actions .tour-btn{flex:1;min-height:44px}}
@media (prefers-reduced-motion:reduce){.tour-spot,.tour-card,.tour-dot{transition:none}}
/* On a phone, give the page room to scroll the lit item above the walkthrough card. */
@media (max-width:820px){body.tour-on .view{padding-bottom:62vh!important}}
/* Setup checklist: next item, in-place controls */
.tour-check.next{border-color:var(--t-gold);background:var(--t-card);box-shadow:0 0 0 3px rgba(201,164,76,.18)}
.tour-check-text .tour-steps{display:grid;gap:4px;margin-top:8px;font-size:12.5px;color:var(--t-ink2)}
.tour-check-text .tour-warn{display:block;margin-top:8px;font-size:12.5px;color:#8C3A2B}
:root[data-theme="dark"] .tour-check-text .tour-warn{color:#efaa99}
.tour-sig{display:grid;gap:8px;margin-top:8px}
.tour-sig textarea{width:100%;font:inherit;font-size:13px;line-height:1.45;border:1px solid var(--t-line);border-radius:10px;padding:8px 10px;background:var(--t-card);color:var(--t-ink);resize:vertical}
.tour-sig .tour-btn{justify-self:start}
.tour-note{font-size:13px;color:var(--t-ink);background:var(--t-wash);border-left:3px solid var(--t-gold);border-radius:8px;padding:8px 10px}
.tour-allset{font-size:15px;color:var(--t-ink)}
.tour-btn:disabled{opacity:.6;cursor:default}
.tour-card[data-pos="center"]{max-height:calc(100dvh - 32px);overflow:auto}
.tour-check-text .tour-wait{display:block;margin-top:8px;font-size:12.5px;color:var(--t-ink)}
.tour-check-text .tour-warn b,.tour-check-text .tour-wait b{font-weight:700}

/* Phone or computer set to dark mode with the CRM on "System": same dark fixes as the Dark setting. */
@media (prefers-color-scheme:dark){
 :root[data-theme="system"] .tour-count{color:#dfbe70}
 :root[data-theme="system"] .tour-check.done .tour-tick{color:#152018}
 :root[data-theme="system"] .tour-check-text .tour-warn{color:#efaa99}
}
