:root{--bg-primary: #1e1e1e;--bg-secondary: #2a2a2a;--bg-tertiary: #333;--color-primary: #fff;--color-accent: #4caf50;--color-accent-hover: #66bb6a;--border-color: #444;--sidebar-width: 280px;--sidebar-collapsed: 44px;--btn-min-size: 44px;--transition-speed: .25s;--z-sidebar: 100;--z-asa: 110;--z-modal: 10000}*{box-sizing:border-box}body{margin:0;padding:0;background:var(--bg-primary);color:var(--color-primary);font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,sans-serif;height:100vh;overflow:hidden}#app{display:grid;grid-template-columns:var(--sidebar-width) 1fr var(--sidebar-width);grid-template-rows:1fr auto;grid-template-areas:"acciones canvas paleta" "acciones consola paleta";height:100vh;width:100vw;transition:grid-template-columns var(--transition-speed) ease}#app.sidebar-left-collapsed{grid-template-columns:var(--sidebar-collapsed) 1fr var(--sidebar-width)}#app.sidebar-right-collapsed{grid-template-columns:var(--sidebar-width) 1fr var(--sidebar-collapsed)}#app.sidebar-left-collapsed.sidebar-right-collapsed{grid-template-columns:var(--sidebar-collapsed) 1fr var(--sidebar-collapsed)}#canvas-container{grid-area:canvas;display:flex;justify-content:center;align-items:center;padding:20px;overflow:hidden;background:var(--bg-primary);position:relative;min-height:0;transform:none!important;zoom:1!important}#canvas-container canvas{width:auto;height:auto;flex-shrink:0}#miCanvas{border:2px solid var(--color-accent);background:#fff;border-radius:6px;box-shadow:0 8px 32px #0006;transform:none!important;display:block;width:1280px!important;height:720px!important}#panel-acciones{grid-area:acciones;background:var(--bg-secondary);border-right:1px solid var(--border-color);overflow:hidden;box-shadow:4px 0 12px #0003;height:100vh;position:relative;transition:all var(--transition-speed) ease;z-index:var(--z-sidebar);width:100%}#panel-acciones .contenido-panel{padding:24px 20px;height:100%;overflow-y:auto;overflow-x:hidden;opacity:1;transition:opacity var(--transition-speed) ease;min-height:100%;box-sizing:border-box;margin:0}#panel-acciones.collapsed .contenido-panel{opacity:0;pointer-events:none}#panel-acciones .asa-panel{position:absolute;top:50%;right:-2px;transform:translateY(-50%);min-width:20px;max-width:32px;width:max(20px,2vw);min-height:80px;max-height:120px;height:max(80px,8vh);background:var(--color-accent);border:2px solid var(--color-accent);border-left:none;border-radius:0 12px 12px 0;cursor:pointer;display:flex;align-items:center;justify-content:center;z-index:1050;transition:all var(--transition-speed) ease;color:#000;user-select:none;box-shadow:2px 0 8px #0003;transform-origin:left center;font-size:clamp(14px,1.5vw,18px);font-weight:900;line-height:1}#panel-acciones .asa-panel:hover{background:var(--color-accent-hover);border-color:var(--color-accent-hover);transform:translateY(-50%) translate(3px);box-shadow:3px 0 12px #4caf5066;font-size:clamp(16px,1.7vw,20px)}#panel-acciones .asa-panel:focus-visible{outline:2px solid var(--color-accent);outline-offset:2px}#paleta-comandos{grid-area:paleta;background:var(--bg-secondary);border-left:1px solid var(--border-color);overflow:hidden;box-shadow:-4px 0 12px #0003;height:100vh;position:relative;transition:all var(--transition-speed) ease;z-index:var(--z-sidebar);width:100%}#paleta-comandos .contenido-panel{padding:24px 20px;height:100%;overflow-y:auto;overflow-x:hidden;opacity:1;transition:opacity var(--transition-speed) ease;min-height:100%;box-sizing:border-box;margin:0}#paleta-comandos.collapsed .contenido-panel{opacity:0;pointer-events:none}#paleta-comandos .asa-panel{position:absolute;top:50%;left:-2px;transform:translateY(-50%);min-width:20px;max-width:32px;width:max(20px,2vw);min-height:80px;max-height:120px;height:max(80px,8vh);background:var(--color-accent);border:2px solid var(--color-accent);border-right:none;border-radius:12px 0 0 12px;cursor:pointer;display:flex;align-items:center;justify-content:center;z-index:1050;transition:all var(--transition-speed) ease;color:#000;user-select:none;box-shadow:-2px 0 8px #0003;transform-origin:right center;font-size:clamp(14px,1.5vw,18px);font-weight:900;line-height:1}#paleta-comandos .asa-panel:hover{background:var(--color-accent-hover);border-color:var(--color-accent-hover);transform:translateY(-50%) translate(-3px);box-shadow:-3px 0 12px #4caf5066;font-size:clamp(16px,1.7vw,20px)}#paleta-comandos .asa-panel:focus-visible{outline:2px solid var(--color-accent);outline-offset:2px}.seccion{margin-bottom:28px;padding:0 4px}.seccion:last-child{margin-bottom:0}.seccion h3{margin:0 0 16px;color:var(--color-accent);font-size:13px;font-weight:700;text-transform:uppercase;letter-spacing:1px;border-bottom:2px solid var(--border-color);padding-bottom:8px;padding-left:2px;padding-right:2px}.botones-grupo{display:flex;flex-wrap:wrap;gap:12px;align-items:center;padding:2px 0}.botones-grupo button{min-width:var(--btn-min-size);min-height:var(--btn-min-size);padding:12px 16px;background:var(--bg-tertiary);color:var(--color-primary);border:2px solid var(--border-color);border-radius:8px;cursor:pointer;font-size:13px;font-weight:600;font-family:inherit;transition:all var(--transition-speed) ease;display:flex;align-items:center;justify-content:center;gap:6px;text-align:center;user-select:none;position:relative;text-decoration:none;line-height:1.2}.botones-grupo button:hover{background:var(--border-color);border-color:var(--color-accent);transform:translateY(-2px);box-shadow:0 4px 12px #00000040}.botones-grupo button:active{background:var(--color-accent);border-color:var(--color-accent);transform:translateY(0);color:#000}.botones-grupo button:disabled{background:#222;color:#666;cursor:not-allowed;transform:none;border-color:#333;box-shadow:none}.botones-grupo button:focus-visible{outline:3px solid var(--color-accent);outline-offset:2px}.colores{justify-content:center}.colores button{width:var(--btn-min-size);height:var(--btn-min-size);padding:0;border:3px solid var(--border-color);border-radius:50%;cursor:pointer;transition:all var(--transition-speed) ease;position:relative;min-width:var(--btn-min-size);min-height:var(--btn-min-size)}.colores button:hover{transform:scale(1.1);border-color:var(--color-accent);box-shadow:0 4px 16px #0000004d}.colores button.activo{border-color:var(--color-accent);border-width:4px;box-shadow:0 0 16px #4caf5099;transform:scale(1.05)}.colores button.activo:after{content:"\2713";position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);color:#fff;font-size:16px;font-weight:700;text-shadow:0 0 4px rgba(0,0,0,.8)}.btn-stroke{min-width:70px;min-height:var(--btn-min-size);padding:12px 16px;background:var(--bg-tertiary);color:var(--color-primary);border:2px solid var(--border-color);border-radius:8px;cursor:pointer;font-size:14px;font-family:monospace;font-weight:600;transition:all var(--transition-speed) ease;text-align:center;display:flex;align-items:center;justify-content:center}.btn-stroke:hover{background:var(--border-color);border-color:var(--color-accent);transform:translateY(-2px)}.btn-stroke.activo{background:var(--color-accent);border-color:var(--color-accent);color:#000;box-shadow:0 0 16px #4caf5099}.btn-stroke:active{background:var(--border-color);transform:translateY(0)}.herramientas{justify-content:center}.herramientas button{width:var(--btn-min-size);height:var(--btn-min-size);min-width:var(--btn-min-size);min-height:var(--btn-min-size);font-weight:700;font-size:16px;display:flex;align-items:center;justify-content:center;border:2px solid var(--border-color);background:var(--bg-tertiary);color:var(--color-primary);border-radius:8px;transition:all var(--transition-speed) ease;cursor:pointer;padding:0}.herramientas button:hover{background:var(--border-color);border-color:var(--color-accent);transform:translateY(-2px);box-shadow:0 4px 16px #00000040}.herramientas button.activo{background:var(--color-accent);border-color:var(--color-accent);color:#000;box-shadow:0 0 16px #4caf5099}#estado-objeto{padding:12px;background:var(--bg-tertiary);border:2px solid var(--border-color);border-radius:8px;font-size:12px;color:#ccc;text-align:center;font-style:italic;min-height:24px;display:flex;align-items:center;justify-content:center;transition:all var(--transition-speed) ease}#zoom-indicator{font-size:11px;color:#888;margin-top:6px;text-align:center}#consola-fija{grid-area:consola;height:160px;min-height:100px;max-height:50vh;background:#1a1a1a;color:#fff;font-family:Consolas,Monaco,Lucida Console,monospace;font-size:14px;padding:0;box-sizing:border-box;border-top:3px solid var(--color-accent);overflow:hidden;resize:none;position:relative}#consola-fija-resizer{position:absolute;top:0;left:0;width:100%;height:8px;cursor:ns-resize;z-index:12;background:var(--color-accent);border-top:3px solid var(--color-accent);transition:all var(--transition-speed) ease}#consola-fija-resizer:hover{background:var(--color-accent-hover);height:10px}.contenido{white-space:pre-line;padding:20px 20px 12px;height:calc(100% - 8px);overflow-y:auto;line-height:1.4}.contenido::-webkit-scrollbar,#paleta-comandos .contenido-panel::-webkit-scrollbar,#panel-acciones .contenido-panel::-webkit-scrollbar{width:8px}.contenido::-webkit-scrollbar-track,#paleta-comandos .contenido-panel::-webkit-scrollbar-track,#panel-acciones .contenido-panel::-webkit-scrollbar-track{background:var(--bg-tertiary);border-radius:4px}.contenido::-webkit-scrollbar-thumb,#paleta-comandos .contenido-panel::-webkit-scrollbar-thumb,#panel-acciones .contenido-panel::-webkit-scrollbar-thumb{background:var(--color-accent);border-radius:4px}.contenido::-webkit-scrollbar-thumb:hover,#paleta-comandos .contenido-panel::-webkit-scrollbar-thumb:hover,#panel-acciones .contenido-panel::-webkit-scrollbar-thumb:hover{background:var(--color-accent-hover)}.sticker-menu{position:fixed;background:var(--bg-secondary);border:2px solid var(--color-accent);border-radius:8px;padding:8px;z-index:1000;color:var(--color-primary);font-family:inherit;box-shadow:0 8px 24px #0006}.sticker-menu div{padding:8px 12px;cursor:pointer;border-radius:4px;transition:background-color var(--transition-speed) ease;font-size:14px}.sticker-menu div:hover{background:var(--bg-tertiary)}.modal-overlay{position:fixed;top:0;left:0;width:100vw;height:100vh;background:#000000d9;display:flex;justify-content:center;align-items:center;z-index:var(--z-modal);backdrop-filter:blur(4px)}.modal-content{background:var(--bg-secondary);border:3px solid var(--color-accent);border-radius:16px;padding:0;max-width:90vw;max-height:90vh;overflow:hidden;box-shadow:0 16px 64px #0009;animation:modalFadeIn var(--transition-speed) ease}@keyframes modalFadeIn{0%{opacity:0;transform:scale(.9) translateY(-20px)}to{opacity:1;transform:scale(1) translateY(0)}}.modal-header{background:var(--bg-tertiary);padding:20px 24px;border-bottom:2px solid var(--border-color);display:flex;justify-content:space-between;align-items:center}.modal-header h2{margin:0;color:var(--color-accent);font-size:24px;font-weight:700}.btn-cerrar{background:none;border:2px solid transparent;color:#fff;font-size:24px;cursor:pointer;padding:8px;width:40px;height:40px;display:flex;align-items:center;justify-content:center;border-radius:6px;transition:all var(--transition-speed) ease}.btn-cerrar:hover{background:#f44;border-color:#f44;transform:scale(1.1)}.modal-body{padding:24px;overflow-y:auto;max-height:calc(90vh - 100px)}.atajos-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(280px,1fr));gap:20px}.categoria-atajos{background:var(--bg-primary);border:2px solid var(--border-color);border-radius:12px;padding:16px}.categoria-atajos h3{margin:0 0 16px;color:var(--color-accent);font-size:16px;font-weight:700;border-bottom:2px solid var(--border-color);padding-bottom:8px}.atajo-item{display:flex;align-items:center;padding:10px 0;border-bottom:1px solid var(--bg-tertiary);font-size:14px}.atajo-item:last-child{border-bottom:none}.atajo-item kbd{background:var(--color-accent);color:#000;padding:4px 8px;border-radius:6px;font-size:12px;font-weight:700;margin-right:10px;min-width:24px;text-align:center;display:inline-block;font-family:inherit}.atajo-item kbd+kbd{margin-left:2px;margin-right:10px}.onboarding-overlay{position:fixed;top:0;left:0;width:100vw;height:100vh;background:#000000e6;display:flex;justify-content:center;align-items:center;z-index:calc(var(--z-modal) + 1);backdrop-filter:blur(2px)}.onboarding-content{background:var(--bg-secondary);border:3px solid var(--color-accent);border-radius:20px;padding:32px;max-width:500px;text-align:center;box-shadow:0 20px 80px #000000b3;animation:onboardingPulse 2.5s ease-in-out}@keyframes onboardingPulse{0%,to{transform:scale(1);box-shadow:0 20px 80px #000000b3}50%{transform:scale(1.02);box-shadow:0 25px 100px #4caf504d}}.onboarding-content h2{color:var(--color-accent);font-size:28px;margin:0 0 16px;font-weight:700}.onboarding-content p{color:#ccc;font-size:16px;line-height:1.5;margin:0 0 24px}.onboarding-tips{background:var(--bg-primary);border:2px solid var(--border-color);border-radius:12px;padding:16px;margin:20px 0;text-align:left}.onboarding-tips h4{color:var(--color-accent);font-size:14px;margin:0 0 12px;text-transform:uppercase;letter-spacing:1px}.onboarding-tips ul{margin:0;padding-left:20px;color:#ddd}.onboarding-tips li{margin-bottom:8px;font-size:14px}.btn-comenzar{background:var(--color-accent);color:#000;border:none;padding:16px 32px;border-radius:8px;font-size:16px;font-weight:700;cursor:pointer;transition:all var(--transition-speed) ease;text-transform:uppercase;letter-spacing:1px}.btn-comenzar:hover{background:var(--color-accent-hover);transform:translateY(-2px);box-shadow:0 8px 24px #4caf5066}@media (max-width: 1200px){:root{--sidebar-width: 260px;--btn-min-size: 40px}.colores button,.herramientas button{width:40px;height:40px}}@media (max-width: 768px){:root{--sidebar-width: 100%;--sidebar-collapsed: 40px;--btn-min-size: 48px}#app{grid-template-columns:1fr;grid-template-rows:1fr auto auto;grid-template-areas:"canvas" "consola" "paleta"}#panel-acciones{position:fixed;top:0;left:0;width:var(--sidebar-width);z-index:200;transform:translate(-100%);transition:transform var(--transition-speed) ease}#panel-acciones.mobile-open{transform:translate(0)}#paleta-comandos{width:100%;height:auto;max-height:50vh;border-left:none;border-top:2px solid var(--border-color);box-shadow:0 -8px 24px #0000004d}#consola-fija{height:140px;max-height:30vh}#canvas-container{padding:10px}#canvas-container{overflow:auto;padding:5px}#miCanvas{min-width:320px;min-height:180px}#panel-acciones .asa-panel{right:-30px;width:30px;height:60px;border-radius:0 20px 20px 0}.atajos-grid{grid-template-columns:1fr}.modal-content{max-width:95vw;max-height:95vh}.onboarding-content{max-width:90vw;padding:24px}}@media (max-width: 480px){#canvas-container{padding:5px;overflow:auto}#miCanvas{min-width:280px;min-height:157px}.botones-grupo{gap:8px}.botones-grupo button{padding:10px 12px;font-size:12px}}@keyframes fadeIn{0%{opacity:0;transform:translateY(-10px)}to{opacity:1;transform:translateY(0)}}@keyframes slideInRight{0%{opacity:0;transform:translate(20px)}to{opacity:1;transform:translate(0)}}@keyframes slideInLeft{0%{opacity:0;transform:translate(-20px)}to{opacity:1;transform:translate(0)}}.seccion{animation:fadeIn .4s ease-out}#paleta-comandos .seccion:nth-child(odd){animation:slideInRight .5s ease-out}#panel-acciones .seccion:nth-child(2n){animation:slideInLeft .5s ease-out}.hidden{display:none!important}.visually-hidden{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;white-space:nowrap!important;border:0!important}.loading{opacity:.6;pointer-events:none}*:focus-visible{outline:2px solid var(--color-accent);outline-offset:2px}@media (max-width: 768px){#panel-acciones .asa-panel,#paleta-comandos .asa-panel{width:18px;height:60px;min-width:18px;min-height:60px;font-size:12px}#panel-acciones .asa-panel:hover,#paleta-comandos .asa-panel:hover{font-size:14px}}@media (max-width: 480px){#panel-acciones .asa-panel,#paleta-comandos .asa-panel{width:16px;height:50px;min-width:16px;min-height:50px;font-size:10px}#panel-acciones .asa-panel:hover,#paleta-comandos .asa-panel:hover{font-size:12px}}@media (min-width: 1400px){#panel-acciones .asa-panel,#paleta-comandos .asa-panel{width:28px;height:100px;max-width:28px;max-height:100px;font-size:20px}#panel-acciones .asa-panel:hover,#paleta-comandos .asa-panel:hover{font-size:22px}}
