/* Preferencia visual compartida; todos los estilos quedan dentro de .mst-tools. */
.mst-tools .mst-theme-switch{position:relative;display:inline-grid;grid-template-columns:1fr 1fr;align-items:center;justify-items:center;flex:none;width:84px;height:44px;padding:4px;border:1px solid #4e485d;border-radius:999px;background:#211e2e;color:#a49ab5;cursor:pointer;isolation:isolate}
.mst-tools .mst-theme-switch::before{content:'';position:absolute;z-index:-1;left:4px;top:4px;width:34px;height:34px;background:#d9fbe5;border-radius:50%;transition:transform .2s ease}
.mst-tools[data-theme=dark] .mst-theme-switch::before{transform:translateX(40px)}
.mst-tools .mst-theme-switch svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.mst-tools[data-theme=light] .mst-theme-sun,.mst-tools[data-theme=dark] .mst-theme-moon{color:#173d25}
.mst-tools .mst-theme-switch:hover{border-color:#77c58f}

.mst-tools[data-theme=light]{--mst-ink:#202330;--mst-muted:#606776;--mst-green:#1d5822;--mst-neon:#1d5822;--mst-border:#d7dce3;--mst-paper:#f5f6f8;color-scheme:light}
.mst-tools[data-theme=light] :focus-visible{outline-color:#0575e6}
.mst-tools[data-theme=light] .mst-header{background:#fff;border-color:#dce0e7}
.mst-tools[data-theme=light] .mst-brand img{filter:brightness(0)}
.mst-tools[data-theme=light] .mst-header-divider{background:#d1d6de}
.mst-tools[data-theme=light] .mst-header-label,.mst-tools[data-theme=light] nav a{color:#555d6c}
.mst-tools[data-theme=light] nav a:hover{color:#17251a}
.mst-tools[data-theme=light] .mst-theme-switch{background:#e7ebef;border-color:#c5cdd4;color:#6d7582}
.mst-tools[data-theme=light] .mst-theme-switch::before{background:#fff;box-shadow:0 1px 5px #182b2c21}
.mst-tools[data-theme=light] .mst-eyebrow{color:#525a66}
.mst-tools[data-theme=light] .mst-category-icon{background:#e4f2e6;border-color:#bfd6c5;color:#1d5822}
.mst-tools[data-theme=light] .mst-tag{background:#e4f2e6;border-color:#bad6c0;color:#24582f}
.mst-tools[data-theme=light] .mst-tool-card{background:linear-gradient(140deg,#fff,#eff4ef);border-color:#cbd5cf}
.mst-tools[data-theme=light] .mst-tool-card:hover{border-color:#448d56}
.mst-tools[data-theme=light] .mst-tool-card::before{border-color:#c4d5c8}
.mst-tools[data-theme=light] .mst-tool-card h2{color:#202330}
.mst-tools[data-theme=light] .mst-tool-card p{color:#606776}
.mst-tools[data-theme=light] .mst-card-action{border-color:#d4ddd6}
.mst-tools[data-theme=light] .mst-footer{border-color:#dce0e7;color:#626a78}
.mst-tools[data-theme=light] .mst-heading-detail{color:#616978}
.mst-tools[data-theme=light] .mst-heading-detail .mst-svg{border-color:#ccd5ce;color:#1d5822}
.mst-tools[data-theme=light] .mst-editor{background:#fff;border-color:#d7dce3;box-shadow:0 12px 40px #18232e05}
.mst-tools[data-theme=light] .mst-text-button{color:#5b6271}
.mst-tools[data-theme=light] .mst-text-button:hover{color:#1d5822}
.mst-tools[data-theme=light] .mst-field label{color:#343b47}
.mst-tools[data-theme=light] .mst-field input,.mst-tools[data-theme=light] .mst-field select,.mst-tools[data-theme=light] .mst-field textarea,.mst-tools[data-theme=light] .mst-link-output{background:#f7f8fa;color:#202330;border-color:#c4cbd5}
.mst-tools[data-theme=light] .mst-field input:hover,.mst-tools[data-theme=light] .mst-field select:hover,.mst-tools[data-theme=light] .mst-field textarea:hover{border-color:#86998b}
.mst-tools[data-theme=light] .mst-field input:focus,.mst-tools[data-theme=light] .mst-field select:focus,.mst-tools[data-theme=light] .mst-field textarea:focus{border-color:#1d5822;outline-color:#1d582233}
.mst-tools[data-theme=light] .mst-field input::placeholder,.mst-tools[data-theme=light] .mst-field textarea::placeholder,.mst-tools[data-theme=light] .mst-link-output::placeholder{color:#68717f}
.mst-tools[data-theme=light] .mst-help,.mst-tools[data-theme=light] .mst-counter,.mst-tools[data-theme=light] .mst-optional,.mst-tools[data-theme=light] .mst-mobile-preview-label{color:#606776}
.mst-tools[data-theme=light] .mst-error{color:#a62c37}
.mst-tools[data-theme=light] .mst-field [aria-invalid=true]{border-color:#a62c37}
.mst-tools[data-theme=light] .mst-share{border-color:#dce0e7}
.mst-tools[data-theme=light] .mst-output-label .mst-svg{color:#606776}
.mst-tools[data-theme=light] .mst-readiness{color:#626a78}
.mst-tools[data-theme=light] .mst-share[data-ready=true] .mst-readiness{color:#1d5822}
.mst-tools[data-theme=light] .mst-share[data-ready=true] .mst-readiness::before{background:#1d5822}
.mst-tools[data-theme=light] .mst-primary{background:#1d5822;color:#fff}
.mst-tools[data-theme=light] .mst-primary:hover:enabled{background:#286f30}
.mst-tools[data-theme=light] .mst-primary:disabled{background:#e6eaee;border-color:#cbd1d9;color:#69717e}
.mst-tools[data-theme=light] .mst-secondary{border-color:#bbc7bf;background:#fff;color:#273c2d}
.mst-tools[data-theme=light] .mst-secondary:hover:enabled{border-color:#438b52;background:#eff6f0}
.mst-tools[data-theme=light] .mst-secondary:disabled{background:#f1f3f4;border-color:#d0d5da;color:#68717b}
.mst-tools[data-theme=light] .mst-status{color:#1d5822}
.mst-tools[data-theme=light] .mst-preview-heading h2,.mst-tools[data-theme=light] .mst-live{color:#606776}
.mst-tools[data-theme=light] .mst-live>span{background:#27843e;box-shadow:0 0 0 3px #27843e15}
.mst-tools[data-theme=light] .mst-chat-window{box-shadow:0 12px 40px #20232e0a;border-color:#afc7bc}
.mst-tools[data-theme=light] .mst-qr-dock{background:#fff;border-color:#d7dce3}
.mst-tools[data-theme=light] .mst-qr-info .mst-overline,.mst-tools[data-theme=light] .mst-qr-info>p:not(.mst-overline){color:#606776}

/* El chat acompaña el tema; el QR conserva siempre negro sobre blanco. */
.mst-tools[data-theme=dark] .mst-chat-window{background:#111b20;border-color:#3b5050;color-scheme:dark}
.mst-tools[data-theme=dark] .mst-chat-header{background:#202e33}
.mst-tools[data-theme=dark] .mst-avatar{background:#354b44;color:#b6e4c7}
.mst-tools[data-theme=dark] .mst-chat-contact>span:last-child{color:#b4c4be}
.mst-tools[data-theme=dark] .mst-chat-body{background-color:#0e191d;background-image:radial-gradient(ellipse at center,#b2cdbb0d 1px,transparent 1.6px),radial-gradient(ellipse at center,transparent 10px,#b2cdbb06 11px,transparent 12px);scrollbar-color:#3d5550 transparent}
.mst-tools[data-theme=dark] .mst-chat-date{background:#263936;color:#c6d3cd}
.mst-tools[data-theme=dark] .mst-chat-bubble{background:#075d4c}
.mst-tools[data-theme=dark] .mst-chat-bubble::after{border-top-color:#075d4c}
.mst-tools[data-theme=dark] #mst-chat-message{color:#eff9f2}
.mst-tools[data-theme=dark] #mst-chat-message.mst-chat-placeholder{color:#c1dbcc}
.mst-tools[data-theme=dark] .mst-chat-meta{color:#b5ccc2}
.mst-tools[data-theme=dark] .mst-chat-meta svg{stroke:#b5ccc2}
.mst-tools[data-theme=dark] .mst-chat-composer{background:#202e33;color:#b4c4be;border-color:#31423f}
.mst-tools[data-theme=dark] .mst-chat-composer>span:first-of-type{background:#2c3c40;color:#bbc9c2}

@media(max-width:800px){.mst-tools .mst-header-divider,.mst-tools .mst-header-label{display:none}.mst-tools .mst-header-inner{gap:20px}}
@media(max-width:600px){.mst-tools .mst-header-inner{display:grid;grid-template-columns:1fr auto;column-gap:12px;row-gap:0;padding-block:12px}.mst-tools .mst-header-inner .mst-brand{grid-area:1/1}.mst-tools .mst-header-inner .mst-theme-switch{grid-area:1/2}.mst-tools .mst-header-inner nav{grid-area:2/1/3/3;margin-left:0}.mst-tools .mst-header-inner nav a{padding:8px 0 0}}
@media(prefers-reduced-motion:reduce){.mst-tools .mst-theme-switch::before{transition:none}}
