:root{font-family:Noto Sans SC,PingFang SC,Microsoft YaHei,Nunito,system-ui,sans-serif;line-height:1.6;font-weight:500;color:#4a4a4a;background:linear-gradient(135deg,#fff9e6,#fffdf5);color-scheme:light;font-synthesis:none;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}@keyframes float{0%,to{transform:translateY(0)}50%{transform:translateY(-10px)}}@keyframes wiggle{0%,to{transform:rotate(-3deg)}50%{transform:rotate(3deg)}}@keyframes bounce{0%,to{transform:scale(1)}50%{transform:scale(1.05)}}@keyframes fadeIn{0%{opacity:0;transform:translateY(20px)}to{opacity:1;transform:translateY(0)}}@keyframes pulse{0%,to{box-shadow:0 4px 20px #ffb7b266}50%{box-shadow:0 4px 30px #ffb7b299}}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.spin{animation:spin 1s linear infinite}*{box-sizing:border-box}a{font-weight:600;color:#ff6b9d;text-decoration:none}a:hover{color:#ff4785;text-decoration:underline}html{background:#fff9e6!important}body{margin:0;min-width:320px;min-height:100vh;background:linear-gradient(135deg,#fff9e6,#fffdf5)!important}#root{min-height:100vh;width:100%;background:transparent}h1{font-size:1.75rem;line-height:1.3;color:#1a1a2e;font-weight:700}.btn-primary{border-radius:12px;border:none;padding:.875rem 1.5rem;font-size:.95rem;font-weight:600;font-family:inherit;background:linear-gradient(135deg,#ffd93d,#ffe566);color:#5d4037;cursor:pointer;transition:all .2s ease;box-shadow:0 4px 14px #ffd93d66}.btn-primary:hover{transform:translateY(-2px);box-shadow:0 6px 20px #ffd93d80}.btn-primary:active{transform:translateY(0)}.btn-primary:focus,.btn-primary:focus-visible{outline:2px solid #FFD93D;outline-offset:2px}.btn-primary:disabled{opacity:.6;cursor:not-allowed;transform:none}.page-center{display:flex;justify-content:center;align-items:center;min-height:100vh;padding:1.5rem}.floating-decorations{display:none}.auth-form{display:flex;flex-direction:column;gap:1.25rem;width:100%;max-width:420px;padding:2.5rem;background:#fff;border-radius:16px;box-shadow:0 25px 50px -12px #00000040;animation:fadeIn .4s ease-out}.auth-form:before{display:none}.auth-form h1{margin:0 0 .25rem;text-align:center;font-size:1.75rem;color:#1a1a2e;font-weight:700}.subtitle{text-align:center;color:#6b7280;margin:0 0 .5rem;font-size:.9rem}.input-group{position:relative;width:100%}.input-icon{position:absolute;left:1rem;top:50%;transform:translateY(-50%);color:#9ca3af;display:flex;align-items:center;pointer-events:none;z-index:1}.auth-form input{width:100%;padding:.875rem 1rem .875rem 2.75rem;border:1px solid #e5e7eb;border-radius:10px;background:#f9fafb;color:#4a4a4a;font-size:.95rem;font-family:inherit;transition:all .2s ease;box-sizing:border-box}.auth-form input:focus{outline:none;border-color:#ffd93d;background:#fff;box-shadow:0 0 0 3px #ffd93d33}.auth-form input::placeholder{color:#9ca3af}.auth-form button{padding:.875rem;font-size:1rem;margin-top:.25rem;display:flex;align-items:center;justify-content:center;gap:.5rem;border-radius:12px;border:none;font-weight:600;font-family:inherit;background:linear-gradient(135deg,#ffd93d,#ffe566);color:#5d4037;cursor:pointer;transition:all .2s ease;box-shadow:0 4px 14px #ffd93d66}.auth-form button:hover{transform:translateY(-2px);box-shadow:0 6px 20px #ffd93d80}.auth-form button:disabled{opacity:.6;cursor:not-allowed;transform:none}.link-text{text-align:center;font-size:.9rem;color:#6b7280;margin-top:.5rem}.link-text a{color:#ff6b6b;font-weight:600;text-decoration:none;transition:color .2s}.link-text a:hover{color:#ee5a5a}.demo-login-section{margin-top:.75rem;padding-top:1.25rem;border-top:1px solid #e5e7eb}.demo-title{text-align:center;color:#9ca3af;font-size:.8rem;margin:0 0 .75rem;text-transform:uppercase;letter-spacing:.05em}.demo-buttons{display:flex;gap:.75rem}.demo-btn{flex:1;padding:.75rem 1rem;font-size:.875rem;border-radius:10px;display:flex;align-items:center;justify-content:center;gap:.4rem;box-shadow:0 1px 3px #0000001a;border:none;font-weight:600;font-family:inherit;cursor:pointer;transition:all .2s ease}.demo-admin{background:linear-gradient(135deg,#c1e1c1,#d4eed4);color:#2e7d32}.demo-admin:hover{background:linear-gradient(135deg,#a8d4a8,#c1e1c1);box-shadow:0 4px 12px #c1e1c180}.demo-user{background:linear-gradient(135deg,#a0c4ff,#bfd7ff);color:#1565c0}.demo-user:hover{background:linear-gradient(135deg,#8ab4f8,#a0c4ff);box-shadow:0 4px 12px #a0c4ff80}.error{color:#dc2626;text-align:center;margin:0;padding:.75rem;background:#fef2f2;border:1px solid #fecaca;border-radius:8px;font-size:.875rem}.play-container{display:flex;flex-direction:column;height:100vh;overflow:hidden;background:#fafbfc}.play-main{flex:1;display:grid;grid-template-columns:320px 1fr 340px;gap:1.25rem;padding:1.25rem;min-height:0;overflow:hidden}.play-sidebar{min-height:0;overflow-y:auto;contain:layout style}.play-chat,.play-map{min-height:0;display:flex;overflow:hidden}.chat-empty{flex:1;display:flex;align-items:center;justify-content:center;background:#fff;border-radius:16px;box-shadow:0 4px 16px #00000014}.chat-empty-card{color:#6b7280;font-weight:600;padding:1rem 1.25rem}.play-header{display:flex;justify-content:space-between;align-items:center;padding:.75rem 1.5rem;background:#fff;color:#374151;font-weight:600;box-shadow:0 1px 3px #00000014;flex-shrink:0;z-index:100}.play-header span{display:flex;align-items:center;gap:.5rem;font-size:.95rem}.play-header .header-buttons{display:flex;gap:.5rem}.play-header button{background:linear-gradient(135deg,#a0c4ff,#bfd7ff);color:#1565c0;padding:.5rem 1rem;font-size:.875rem;box-shadow:0 2px 6px #a0c4ff66;display:flex;align-items:center;gap:.4rem;border:none;border-radius:10px;font-weight:600;font-family:inherit;cursor:pointer;transition:all .2s ease}.play-header button:hover{background:linear-gradient(135deg,#8ab4f8,#a0c4ff);box-shadow:0 4px 12px #a0c4ff80;transform:translateY(-1px)}.story-list{padding:3rem 2rem;flex:1;display:flex;flex-direction:column;align-items:center}.story-list--sidebar{padding:1rem;align-items:stretch;background:#fff;border-radius:12px;box-shadow:0 2px 8px #0000000f;height:100%;min-height:0}.sidebar-resizer{position:absolute;right:-10px;top:0;bottom:0;width:10px;cursor:col-resize;z-index:6}.sidebar-resizer:after{content:"";position:absolute;left:4px;top:20px;bottom:20px;width:2px;border-radius:999px;background:#64748b40}.sidebar-resizer:hover:after{background:#64748b8c}.story-list h2{color:#4a4a4a;text-align:center;margin-bottom:2rem;font-size:1.75rem;font-weight:700;display:flex;align-items:center;justify-content:center;gap:.75rem}.story-list--sidebar h2{margin-bottom:0;font-size:1rem;justify-content:flex-start;flex:1}.story-list ul{list-style:none;padding:0;display:grid;grid-template-columns:repeat(auto-fill,minmax(300px,1fr));gap:1.5rem;max-width:1000px;width:100%}.story-list--sidebar .ant-list-items{display:flex;flex-direction:column;gap:.75rem;max-width:none;overflow:auto;min-height:0;padding-right:.25rem}.story-list:not(.story-list--sidebar) li{background:#fff;border-radius:16px;overflow:hidden;box-shadow:0 4px 16px #00000014;transition:all .3s ease}.story-list--sidebar .ant-list-item{border-radius:12px;box-shadow:0 2px 10px #0000000f}.story-list:not(.story-list--sidebar) li:hover{box-shadow:0 8px 24px #ffd93d59;transform:translateY(-4px)}.story-list--sidebar .ant-list-item:hover{transform:translateY(-2px)}.story-list:not(.story-list--sidebar) button{width:100%;text-align:center;padding:1.5rem 1.25rem;background:linear-gradient(135deg,#fffbeb,#fff9e6);border:none;border-radius:0;color:#4a4a4a;font-size:1.1rem;font-weight:600;font-family:inherit;cursor:pointer;box-shadow:none;transition:all .2s ease}.story-list--sidebar button{text-align:left;padding:.9rem 1rem;font-size:.95rem}.story-list:not(.story-list--sidebar) button:hover{background:linear-gradient(135deg,#fff3c4,#fffbeb);transform:none;box-shadow:none}.story-list--sidebar .ant-list-item{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:nowrap}.story-list--sidebar .ant-list-item-meta{flex:1 1 auto;min-width:0}.story-list--sidebar .ant-list-item-meta-content{min-width:0}.story-list--sidebar .ant-list-item-meta-title{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.story-list--sidebar .ant-list-item-action{display:flex;align-items:center;flex:0 0 auto;white-space:nowrap;margin-inline-start:8px}.story-list--sidebar .ant-list-item-action,.story-list--sidebar .ant-list-item-action>li{margin:0;padding:0;background:transparent;box-shadow:none;border-radius:0}.story-list--sidebar .ant-list-item-action>li{display:flex;align-items:center}@media (max-width: 900px){.play-main{display:flex;flex-direction:column;gap:.75rem}.play-map{display:none}.play-sidebar{width:100%!important;max-height:240px;overflow:auto}.play-chat{flex:1;min-height:0}.play-header{gap:.75rem;flex-wrap:wrap}.play-header .header-buttons{width:100%;justify-content:flex-end;flex-wrap:wrap}}.story-list p{text-align:center;color:#6b7280}.session-list-container{margin-top:8px;overflow-y:auto;flex:1}.session-item{display:flex;align-items:center;padding:10px 12px;margin-bottom:6px;background:#f9fafb;border:1px solid #e5e7eb;border-radius:8px;cursor:pointer;transition:all .15s}.session-item:hover{background:#f3f4f6}.session-item.active{background:#eef2ff;border-color:#6366f1}.session-item-content{flex:1;min-width:0;overflow:hidden}.session-item-title{font-weight:500;font-size:14px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:#374151}.session-item-meta{font-size:11px;color:#9ca3af;white-space:nowrap}.session-item-delete{background:none;border:none;cursor:pointer;color:#9ca3af;padding:4px 8px;font-size:14px;flex-shrink:0;margin-left:8px}.session-item-delete:hover{color:#ef4444}.chat-container{flex:1;display:flex;flex-direction:column;height:100%;border-radius:12px;overflow:hidden;background:#fff;box-shadow:0 2px 8px #0000000f;position:relative}.chat-loading-overlay{position:absolute;top:0;right:0;bottom:0;left:0;background:#ffffffe6;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:1rem;z-index:10;color:#6b7280;font-size:.95rem}.chat-header{padding:.875rem 1rem;border-bottom:1px solid #f0f0f0;background:#fafafa}.chat-header h3{margin:0;font-size:1rem;color:#374151;font-weight:600}.chat-messages{flex:1;overflow-y:auto;padding:1rem;display:flex;flex-direction:column;gap:.75rem;background:#fff;contain:layout style;will-change:scroll-position;-webkit-overflow-scrolling:touch}.chat-input-area--sticky{position:sticky;bottom:0}.map-container{flex:1;display:flex;flex-direction:column;height:100%;border-radius:12px;overflow:hidden;background:#fff;box-shadow:0 2px 8px #0000000f}.map-container--empty{align-items:center;justify-content:center}.map-empty{color:#9ca3af;font-size:2rem}.map-header{display:flex;align-items:center;justify-content:space-between;padding:.875rem 1rem;border-bottom:1px solid #f0f0f0;background:#fafafa}.map-toggle{border:1px solid #cbd5e1;background:#fff;color:#1f3a8a;font-weight:600;font-size:.8rem;padding:.35rem .55rem;border-radius:10px;cursor:pointer}.map-toggle:hover{background:#f8fafc}.map-header h3{margin:0;display:flex;align-items:center;gap:.5rem;font-size:1.1rem;color:#1f3a8a}.map-loading{font-size:.85rem;color:#6b7280;display:flex;align-items:center;gap:.35rem}.map-body{flex:1;overflow:auto;padding:1rem;display:flex;flex-direction:column;gap:1rem;position:relative}.map-resizer{position:absolute;left:-10px;top:0;bottom:0;width:10px;cursor:col-resize;z-index:5}.map-resizer:after{content:"";position:absolute;left:4px;top:20px;bottom:20px;width:2px;border-radius:999px;background:#64748b40}.map-resizer:hover:after{background:#64748b8c}.play-map--collapsed,.play-sidebar--collapsed{display:flex;align-items:flex-start}.map-toggle--collapsed{margin-top:14px}.map-tree-wrap{background:linear-gradient(180deg,#fff,#f8fafc);border:1px solid #eef2f7;border-radius:12px;padding:.75rem;position:relative;overflow:auto;max-height:calc(100vh - 280px);-webkit-user-select:none;user-select:none}.map-tree-wrap.is-panning{cursor:grabbing}.map-tree{width:100%;min-width:0;height:auto;min-height:400px;display:block}.map-zoom-controls{position:absolute;top:10px;right:10px;z-index:10;display:flex;gap:4px}.map-zoom-controls button{width:28px;height:28px;border:1px solid rgba(93,64,55,.2);border-radius:8px;background:#fffffff2;color:#5d4037;font-size:16px;font-weight:700;cursor:pointer;display:flex;align-items:center;justify-content:center;transition:all .15s ease;box-shadow:0 2px 6px #5d40371a}.map-zoom-controls button:hover{background:#fef2f4;border-color:#ffb7b299;transform:scale(1.05)}.map-tooltip{position:fixed;top:0;left:0;z-index:9999;max-width:280px;padding:.6rem .8rem;border-radius:10px;background:#2d231ef2;border:1px solid rgba(255,183,178,.3);color:#fffffff5;font-size:11px;font-weight:500;line-height:1.5;box-shadow:0 8px 24px #00000040;pointer-events:none;will-change:transform;-webkit-user-select:none;user-select:none}.map-tooltip-content{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:12px}.map-tooltip-row{display:flex;gap:8px;align-items:baseline}.map-tooltip-k{color:#a5f3fcf2;font-weight:800;white-space:nowrap}.map-tooltip-v{color:#ffffffeb;font-weight:650;word-break:break-word}.map-tooltip-section{margin-top:8px;padding-top:8px;border-top:1px dashed rgba(255,255,255,.18);color:#fdfd96f2;font-weight:850}.map-tooltip-item{padding-left:12px;text-indent:-10px;color:#ffffffe6}.map-tooltip-line{color:#ffffffeb}.map-tooltip-spacer{height:6px}.tree-edge{fill:none;stroke:#94a3b859;stroke-width:1.35}.tree-edge.tree-edge--unvisited{stroke:#94a3b847}.tree-edge.tree-edge--traversed{stroke:#7dd3fce6;stroke-width:1.65}.tree-edge.tree-edge--current{stroke:#22c55ee6;stroke-width:1.9}.tree-edge-label{font-size:11px;font-weight:600;fill:#5d4037;letter-spacing:0;stroke:#fffffffa;stroke-width:4px;paint-order:stroke;pointer-events:none}.tree-edge--unvisited+.tree-edge-label{opacity:.55}.tree-node-text{font-size:12px;font-weight:700;fill:#5d4037;stroke:#ffffffe6;stroke-width:3px;paint-order:stroke}.tree-node{cursor:pointer}.tree-node .tree-node-rect,.tree-node .tree-node-text{transition:transform .15s ease,filter .15s ease,stroke .15s ease,fill .15s ease}.tree-node:hover .tree-node-rect{transform:translateY(-1px) scale(1.02);stroke:#a0c4ff;filter:drop-shadow(0 12px 22px rgba(93,64,55,.15))}.tree-node:hover .tree-node-text{fill:#0b1220}.tree-node-rect{stroke-width:2}.tree-node--reachable .tree-node-rect{fill:#fff;stroke:#94a3b84d;filter:drop-shadow(0 8px 16px rgba(15,23,42,.08))}.tree-node--visited .tree-node-rect{fill:#e0f2fee6;stroke:#7dd3fcf2;filter:drop-shadow(0 12px 22px rgba(2,132,199,.16))}.tree-node--current .tree-node-rect{fill:#dcfce7eb;stroke:#22c55ef2;filter:drop-shadow(0 16px 26px rgba(21,128,61,.18))}.tree-node--unreachable .tree-node-rect{fill:#f8fafc99;stroke:#94a3b82e;filter:none}.map-current{background:#fef2f4;border:1px solid #ffe4e6;border-radius:12px;padding:.75rem .9rem}.map-current-label{font-size:.75rem;text-transform:uppercase;letter-spacing:.06em;color:#9ca3af;margin-bottom:.25rem}.map-current-title{font-weight:700;color:#5d4037}.map-nodes{display:flex;flex-direction:column;gap:.5rem}.map-node{display:flex;align-items:center;gap:.6rem;padding:.6rem .75rem;border-radius:12px;border:1px solid #f3f4f6;background:#fafafa}.map-node-dot{width:10px;height:10px;border-radius:999px;background:#d1d5db;flex:0 0 auto}.map-node.is-visited .map-node-dot{background:#60a5fa}.map-node.is-current{background:#fff7ed;border-color:#fed7aa}.map-node.is-current .map-node-dot{background:#f97316}.map-other-nodes{margin-top:.75rem}.map-node.is-unreachable{opacity:.85}.map-node.is-unreachable .map-node-dot{background:#d1d5db}.map-node-title{font-size:1rem;color:#374151}.map-hint{color:#6b7280;font-size:.9rem;display:flex;align-items:center;gap:.5rem}.map-options{border-top:1px solid #f3f4f6;padding-top:.75rem}.map-options-title{font-size:.85rem;font-weight:700;color:#374151;margin-bottom:.5rem}.map-options-list{display:flex;flex-direction:column;gap:.5rem}.map-option-btn{width:100%;text-align:left;display:flex;gap:.6rem;align-items:baseline;padding:.65rem .75rem;border-radius:12px;border:1px solid #e5e7eb;background:#fff;cursor:pointer;transition:all .15s ease}.map-option-btn:hover:not(:disabled){background:#f9fafb;border-color:#d1d5db}.map-option-btn:disabled{opacity:.6;cursor:not-allowed}.map-option-key{font-weight:800;color:#1f3a8a;flex:0 0 auto;min-width:24px}.map-option-label{color:#374151}.chat-message{display:flex}.chat-message--user{justify-content:flex-end}.chat-message--assistant{justify-content:flex-start}.chat-bubble{max-width:70%;padding:1rem 1.25rem;border-radius:18px;line-height:1.7;word-break:break-word;font-size:1rem;white-space:pre-wrap}.chat-message--user .chat-bubble{background:#3b82f6;color:#fff;border-bottom-right-radius:4px}.chat-message--assistant .chat-bubble{background:#f3f4f6;color:#374151;border-bottom-left-radius:4px}.chat-bubble--loading{display:flex;align-items:center;gap:.5rem;color:#9ca3af;animation:pulseLoad 1.5s ease-in-out infinite}@keyframes pulseLoad{0%,to{opacity:.6}50%{opacity:1}}.typing-dots{display:flex;gap:4px}.typing-dots span{width:8px;height:8px;background:#a0c4ff;border-radius:50%;animation:bounce 1.4s infinite ease-in-out both}.typing-dots span:nth-child(1){animation-delay:-.32s}.typing-dots span:nth-child(2){animation-delay:-.16s}.typing-dots span:nth-child(3){animation-delay:0s}@keyframes bounce{0%,80%,to{transform:scale(.6);opacity:.5}40%{transform:scale(1);opacity:1}}.chat-input-area{display:flex;gap:.5rem;padding:.75rem 1rem;border-top:1px solid #f0f0f0;background:#fafafa}.chat-input-area input{flex:1;padding:.6rem .875rem;border:1px solid #e5e7eb;border-radius:8px;font-size:.9rem;color:#374151;background:#fff;-webkit-text-fill-color:#374151;outline:none;transition:border-color .2s}.chat-input-area input::placeholder{color:#6b7280;opacity:1}.chat-input-area input:focus{border-color:#ffb7b2}.chat-input-area button{padding:.6rem .875rem;background:#3b82f6;color:#fff;border:none;border-radius:12px;cursor:pointer;display:flex;align-items:center;justify-content:center;transition:background .2s}.chat-input-area button svg{stroke-width:2.25}.chat-input-area button:hover:not(:disabled){background:#ffa8a2}.chat-input-area button:disabled{opacity:.5;cursor:not-allowed}.lang-switch{background:#f3f4f6;color:#374151;border:none;border-radius:8px;padding:.5rem .75rem;font-size:.875rem;font-weight:600;cursor:pointer;transition:all .2s ease}.lang-switch:hover{background:#e5e7eb}.lang-switch-corner{position:absolute;top:1rem;right:1rem}.admin-container{padding:1.5rem;max-width:1200px;margin:0 auto;min-height:100vh;background:#f8fafc}.admin-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:1.5rem;flex-wrap:wrap;gap:1rem}.admin-header h1{margin:0;color:#1a1a2e;font-size:1.5rem;font-weight:600;display:flex;align-items:center;gap:.5rem}.admin-header button{background:#f3f4f6;color:#374151;box-shadow:none;display:flex;align-items:center;gap:.4rem;padding:.6rem .9rem;border:none;border-radius:10px;font-weight:600;font-family:inherit;cursor:pointer;transition:all .2s ease}.admin-header button:hover{background:#e5e7eb;box-shadow:none;transform:none}.admin-header button:focus,.admin-header button:focus-visible{outline:2px solid #A0C4FF;outline-offset:2px}.admin-header button:disabled{opacity:.6;cursor:not-allowed}.admin-table{width:100%;border-collapse:collapse;background:#fff;border-radius:8px;overflow:hidden;border:1px solid #e5e7eb}.admin-table th,.admin-table td{padding:.875rem 1rem;text-align:left;font-size:.875rem}.admin-table th{background:#f9fafb;color:#6b7280;font-weight:600;text-transform:uppercase;font-size:.75rem;letter-spacing:.05em;border-bottom:1px solid #e5e7eb}.admin-table tr:hover{background:#f9fafb}.admin-table td{border-bottom:1px solid #f3f4f6;color:#374151}.status-badge{display:inline-flex;align-items:center;gap:.25rem;padding:.25rem .625rem;border-radius:9999px;font-size:.75rem;font-weight:500}.status-badge.active{background:#dcfce7;color:#166534}.status-badge.ended{background:#f3f4f6;color:#6b7280}.status-badge.draft{background:#fef3c7;color:#92400e}.status-badge.published{background:#dcfce7;color:#166534}.create-story-form{display:flex;gap:.75rem;margin-bottom:1.5rem}.create-story-form input{flex:1;padding:.75rem 1rem;border:1px solid #e5e7eb;border-radius:8px;font-size:.95rem}.create-story-form input:focus{outline:none;border-color:#ffb7b2;box-shadow:0 0 0 3px #ffb7b233}.create-story-form button{padding:.75rem 1.25rem;background:linear-gradient(135deg,#ffb7b2,#ffc8c4);color:#5d4037;border:none;border-radius:8px;font-weight:600;cursor:pointer;display:flex;align-items:center;gap:.5rem;transition:all .2s}.create-story-form button:hover{transform:translateY(-1px);box-shadow:0 4px 12px #ffb7b266}.story-editor{background:#fff;border-radius:12px;padding:1.5rem;box-shadow:0 4px 20px #00000014}.editor-toolbar{margin-bottom:1.5rem;display:flex;gap:.75rem}.btn-add{padding:.625rem 1rem;background:linear-gradient(135deg,#a0c4ff,#b8d4ff);color:#1e40af;border:none;border-radius:8px;font-weight:600;cursor:pointer;display:flex;align-items:center;gap:.5rem;transition:all .2s}.btn-add:hover{transform:translateY(-1px);box-shadow:0 4px 12px #a0c4ff66}.btn-primary{background:linear-gradient(135deg,#ffd93d,#ffe566)!important;color:#5d4037!important}.btn-success{background:linear-gradient(135deg,#c1e1c1,#d4ead4)!important;color:#166534!important}.btn-translate{background:linear-gradient(135deg,#a0c4ff,#c4d9ff)!important;color:#1e40af!important}.empty-state{text-align:center;padding:3rem;color:#9ca3af}.nodes-list{display:flex;flex-direction:column;gap:1.5rem}.node-card{border:1px solid #e5e7eb;border-radius:12px;padding:1.25rem;background:#fafafa;transition:all .2s}.node-card:hover{border-color:#d1d5db;box-shadow:0 2px 8px #0000000d}.node-card.node-start{border-color:#ffd93d;background:linear-gradient(135deg,#fffbeb,#fff)}.node-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:1rem}.node-title-row{display:flex;align-items:center;gap:.5rem;flex:1}.start-icon{color:#f59e0b;font-size:1.1rem}.node-title-input{flex:1;padding:.5rem .75rem;border:1px solid #e5e7eb;border-radius:6px;font-size:1rem;font-weight:600;background:#fff}.node-title-input:focus{outline:none;border-color:#ffb7b2}.node-actions{display:flex;gap:.5rem}.btn-small{padding:.375rem .625rem;border:1px solid #e5e7eb;border-radius:6px;background:#fff;color:#6b7280;cursor:pointer;display:flex;align-items:center;gap:.25rem;font-size:.8rem;transition:all .15s}.btn-small:hover{background:#f3f4f6;color:#374151}.btn-small.btn-danger{color:#dc2626}.btn-small.btn-danger:hover{background:#fef2f2;border-color:#fecaca}.btn-small.btn-success{color:#166534!important;background:#dcfce7!important;border-color:#bbf7d0!important}.node-prompt{margin-bottom:1rem}.node-prompt label{display:block;font-weight:600;color:#374151;margin-bottom:.5rem;font-size:.9rem}.node-prompt .help-text{display:block;font-weight:400;color:#9ca3af;font-size:.8rem;margin-top:.25rem}.node-prompt textarea{width:100%;padding:.75rem;border:1px solid #e5e7eb;border-radius:8px;font-size:.9rem;resize:vertical;min-height:100px;font-family:inherit;line-height:1.5}.node-prompt textarea:focus{outline:none;border-color:#ffb7b2;box-shadow:0 0 0 3px #ffb7b226}.node-edges{border-top:1px solid #e5e7eb;padding-top:1rem}.edges-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:.75rem;font-size:.9rem;color:#6b7280}.edge-row{display:flex;gap:.5rem;margin-bottom:.5rem;align-items:center}.edge-key{width:60px;padding:.5rem;border:1px solid #e5e7eb;border-radius:6px;text-align:center;font-weight:600}.edge-label{flex:1;padding:.5rem .75rem;border:1px solid #e5e7eb;border-radius:6px}.edge-target{width:180px;padding:.5rem .75rem;border:1px solid #e5e7eb;border-radius:6px;background:#fff}.edge-key:focus,.edge-label:focus,.edge-target:focus{outline:none;border-color:#a0c4ff}.node-graph-editor{display:flex;flex-direction:column;height:calc(100vh - 280px);min-height:500px;background:linear-gradient(135deg,#fefefe,#f8fafc);border-radius:16px;overflow:hidden;border:2px solid rgba(160,196,255,.3);box-shadow:0 8px 32px #a0c4ff26}.graph-toolbar{display:flex;align-items:center;gap:1rem;padding:.75rem 1rem;background:#fff;border-bottom:1px solid #e5e7eb}.btn-add-node{display:flex;align-items:center;gap:.4rem;padding:.5rem 1rem;background:linear-gradient(135deg,#c1e1c1,#d4ead4);color:#166534;border:none;border-radius:8px;font-weight:600;cursor:pointer;transition:all .2s}.btn-add-node:hover{transform:translateY(-1px);box-shadow:0 4px 12px #c1e1c180}.graph-hint{color:#9ca3af;font-size:.8rem}.graph-canvas{flex:1;background:#fefefe}.graph-node .node-rect{fill:#fff;stroke:#e5e7eb;stroke-width:2;filter:drop-shadow(0 4px 8px rgba(0,0,0,.08));transition:all .2s ease-out}.graph-node:hover .node-rect{stroke:#a0c4ff;stroke-width:3;filter:drop-shadow(0 8px 20px rgba(160,196,255,.4));transform:scale(1.02)}.graph-node.is-start .node-rect{fill:#fffbeb;stroke:#ffd93d}.graph-node.is-dragging .node-rect{stroke:#ffb7b2;filter:drop-shadow(0 8px 20px rgba(255,183,178,.4))}.graph-node .node-title{font-size:13px;font-weight:700;fill:#5d4037}.graph-node .node-actions{opacity:0;transition:opacity .2s}.graph-node:hover .node-actions{opacity:1}.graph-node .node-connector{fill:#a0c4ff;stroke:#fff;stroke-width:2;transition:all .15s}.graph-node .node-connector:hover{fill:#ffb7b2;r:10}.graph-edge .edge-label{font-size:11px;font-weight:600;fill:#6b7280}.graph-edge:hover .edge-action{opacity:1!important}.graph-edge .edge-delete-icon{font-size:14px;font-weight:700;fill:#ef4444}.edge-edit-modal{position:fixed;top:0;right:0;bottom:0;left:0;background:#0006;display:flex;align-items:center;justify-content:center;z-index:1000;animation:fadeIn .2s ease-out}@keyframes fadeIn{0%{opacity:0}to{opacity:1}}@keyframes slideUp{0%{opacity:0;transform:translateY(20px) scale(.95)}to{opacity:1;transform:translateY(0) scale(1)}}.edge-edit-content{background:#fff;border-radius:16px;padding:1.5rem;min-width:320px;box-shadow:0 20px 60px #00000026;animation:slideUp .25s ease-out;border:2px solid #FFB7B2}.edge-edit-content h4{margin:0 0 1rem;color:#5d4037;font-size:1.1rem}.edge-edit-field{margin-bottom:1rem}.edge-edit-field label{display:block;font-size:.85rem;color:#6b7280;margin-bottom:.4rem}.edge-edit-field input{width:100%;padding:.6rem .8rem;border:1px solid #e5e7eb;border-radius:8px;font-size:.95rem;color:#333;background:#fff;transition:border-color .2s}.edge-edit-field input:focus{outline:none;border-color:#a0c4ff}.edge-edit-actions{display:flex;align-items:stretch;gap:.5rem;margin-top:1.25rem}.edge-edit-actions button{flex:1;height:40px;display:flex;align-items:center;justify-content:center;border:none;border-radius:8px;font-weight:600;font-size:.9rem;cursor:pointer;transition:background .15s}.edge-edit-actions .btn-close{background:#f3f4f6;color:#666}.edge-edit-actions .btn-close:hover{background:#e5e7eb}.edge-edit-actions .btn-save{background:#ffb7b2;color:#5d4037}.edge-edit-actions .btn-save:hover{background:#ffa8a2}.edge-edit-actions .btn-delete{background:#fee2e2;color:#dc2626}.edge-edit-actions .btn-delete:hover{background:#fecaca}.node-options-list{display:flex;flex-direction:column;gap:.75rem}.node-option-item{display:flex;align-items:stretch;gap:.5rem;padding:.5rem;background:#fff;border-radius:10px;border:1px solid #e5e7eb}.node-option-item .option-key-input{background:#5d4037;color:#fff;font-weight:700;height:36px;width:60px;display:flex;align-items:center;justify-content:center;border-radius:6px;font-size:.85rem;text-align:center;border:none;flex-shrink:0}.node-option-item .option-key-input:focus{outline:none;box-shadow:0 0 0 2px #5d40374d}.node-option-item .option-key-input::placeholder{color:#fff9}.node-option-item .option-label-input{flex:1;min-width:0;height:36px;padding:0 .75rem;border:1px solid #e5e7eb;border-radius:6px;font-size:.9rem;background:#fafafa}.node-option-item .option-label-input:focus{outline:none;border-color:#a0c4ff;background:#fff}.node-option-item .option-target-btn{background:#c1e1c1;border:none;color:#2e5a2e;font-size:.8rem;font-weight:500;height:36px;padding:0 .75rem;display:flex;align-items:center;border-radius:6px;cursor:pointer;white-space:nowrap;max-width:120px;overflow:hidden;text-overflow:ellipsis;transition:all .15s;flex-shrink:0}.node-option-item .option-target-btn:hover{background:#a8d4a8}.no-options{color:#9ca3af;font-size:.85rem;font-style:italic;padding:.5rem}.node-edit-modal{position:fixed;top:0;right:0;bottom:0;left:0;background:#0006;display:flex;align-items:center;justify-content:center;z-index:1000}.node-edit-grid{display:grid;grid-template-columns:1fr 1fr;gap:1rem}.node-edit-content{background:#fff;border-radius:16px;padding:1.5rem;width:90%;max-width:640px;max-height:85vh;overflow-y:auto;box-shadow:0 20px 50px #0003;animation:modalPop .25s ease-out}.node-nav-bar{display:flex;align-items:center;justify-content:space-between;gap:1rem;padding:.75rem;margin:-1.5rem -1.5rem 1rem;background:#f8f8f8;border-radius:20px 20px 0 0;border-bottom:1px solid #eee}.node-nav-bar .nav-btn{padding:.5rem 1rem;border:none;border-radius:8px;font-size:.85rem;font-weight:600;cursor:pointer;transition:all .15s}.node-nav-bar .nav-btn.prev{background:#c1e1c1;color:#166534}.node-nav-bar .nav-btn.next{background:#a0c4ff;color:#1e3a5f}.node-nav-bar .nav-btn:disabled{background:#e5e5e5;color:#aaa;cursor:not-allowed}.node-nav-bar .nav-btn:not(:disabled):hover{transform:translateY(-1px)}.node-nav-bar .nav-title{flex:1;text-align:center;font-weight:600;color:#5d4037;font-size:.9rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.node-edit-content.macaron{background:#fff;border:2px solid #FFB7B2;box-shadow:0 20px 60px #5d40371f;border-radius:20px}.node-edit-content.macaron .node-edit-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:1.5rem;padding-bottom:1rem;border-bottom:2px solid #f5f5f5}.node-edit-content.macaron h3{color:#5d4037;font-weight:700;font-size:1.15rem;margin:0}.node-edit-content.macaron .node-id{font-family:monospace;font-size:.75rem;color:#888;background:#f5f5f5;padding:.3rem .6rem;border-radius:6px}.node-edit-content.macaron .node-parents{background:#f0fdf4;border:1px solid #C1E1C1;border-radius:12px;padding:1rem;margin-bottom:1.25rem}.node-edit-content.macaron .node-parents label{color:#166534;font-size:.8rem;font-weight:600;margin-bottom:.5rem;display:block}.node-edit-content.macaron .parent-list{display:flex;flex-wrap:wrap;gap:.5rem}.node-edit-content.macaron .parent-tag{background:#c1e1c1;color:#166534;padding:.4rem .75rem;border-radius:8px;font-size:.85rem;font-weight:600;cursor:pointer;transition:all .15s;border:none}.node-edit-content.macaron .parent-tag:hover{background:#a8d4a8}.node-edit-content.macaron .parent-tag .edge-key{opacity:.7}.node-edit-content.macaron label{color:#5d4037;font-weight:600;font-size:.85rem}.node-edit-content.macaron input,.node-edit-content.macaron textarea{background:#fafafa;border:1px solid #e5e5e5;color:#5d4037;border-radius:10px}.node-edit-content.macaron input:focus,.node-edit-content.macaron textarea:focus{border-color:#a0c4ff;background:#fff;outline:none}.node-edit-content.macaron .btn-ai-generate{background:#a0c4ff;color:#1e3a5f;border:none}.node-edit-content.macaron .btn-ai-generate:hover{background:#8ab8ff}.node-edit-content.macaron .node-options-list{background:#fffbeb;border-radius:12px;padding:.75rem;border:1px solid #fde68a}.node-edit-content.macaron .btn-cancel{background:#f5f5f5;color:#666;border:1px solid #e5e5e5;border-radius:10px;transition:all .15s}.node-edit-content.macaron .btn-cancel:hover{background:#eee;transform:translateY(-1px)}.node-edit-content.macaron .btn-save{background:#ffb7b2;color:#5d4037;border:none;border-radius:10px;transition:all .15s}.node-edit-content.macaron .btn-save:hover{background:#ffa8a2;transform:translateY(-1px);box-shadow:0 4px 12px #ffb7b24d}.node-edit-content.futuristic{background:linear-gradient(145deg,#fff,#f8fafc);border:none;box-shadow:0 25px 80px #0000001f,0 0 0 1px #0000000d;border-radius:20px}.node-edit-content.futuristic .node-edit-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:1.5rem;padding-bottom:1rem;border-bottom:1px solid #e5e7eb}.node-edit-content.futuristic h3{color:#1f2937;font-weight:700;font-size:1.25rem;margin:0}.node-edit-content.futuristic .node-id{font-family:SF Mono,Monaco,monospace;font-size:.7rem;color:#6366f1;background:#eef2ff;padding:.25rem .6rem;border-radius:20px;font-weight:500}.node-edit-content.futuristic .node-parents{background:linear-gradient(135deg,#faf5ff,#f3e8ff);border:1px solid #e9d5ff;border-radius:12px;padding:1rem;margin-bottom:1.25rem}.node-edit-content.futuristic .node-parents label{color:#7c3aed;font-size:.75rem;font-weight:600;margin-bottom:.6rem;text-transform:uppercase;letter-spacing:.5px}.node-edit-content.futuristic .parent-list{display:flex;flex-wrap:wrap;gap:.5rem}.node-edit-content.futuristic .parent-tag{background:#fff;color:#7c3aed;padding:.4rem .85rem;border-radius:20px;font-size:.85rem;font-weight:500;cursor:pointer;transition:all .2s;box-shadow:0 2px 8px #7c3aed26;border:1px solid #e9d5ff}.node-edit-content.futuristic .parent-tag:hover{background:#7c3aed;color:#fff;transform:translateY(-1px)}.node-edit-content.futuristic .parent-tag .edge-key{opacity:.7;font-size:.75rem}.node-edit-content.futuristic label{color:#374151;font-weight:500;font-size:.85rem}.node-edit-content.futuristic input,.node-edit-content.futuristic textarea{background:#f9fafb;border:1.5px solid #e5e7eb;color:#1f2937;border-radius:10px;transition:all .2s}.node-edit-content.futuristic input:focus,.node-edit-content.futuristic textarea:focus{border-color:#a78bfa;box-shadow:0 0 0 3px #a78bfa26;outline:none;background:#fff}.node-edit-content.futuristic input::placeholder,.node-edit-content.futuristic textarea::placeholder{color:#9ca3af}.node-edit-content.futuristic .btn-ai-generate{background:linear-gradient(135deg,#8b5cf6,#7c3aed);color:#fff;box-shadow:0 4px 12px #8b5cf64d}.node-edit-content.futuristic .node-options-list{background:#f9fafb;border-radius:12px;padding:.75rem;border:1px solid #e5e7eb}.node-edit-content.futuristic .node-option-item{background:#fff;border:1px solid #e5e7eb;border-radius:10px;box-shadow:0 2px 4px #0000000a}.node-edit-content.futuristic .option-key-input{background:linear-gradient(135deg,#6366f1,#4f46e5);color:#fff;font-weight:600;border:none}.node-edit-content.futuristic .option-target{color:#6b7280;font-weight:500}.node-edit-content.futuristic .no-options{color:#9ca3af}.node-edit-content.futuristic .btn-cancel{background:#f3f4f6;color:#4b5563;border:1px solid #e5e7eb}.node-edit-content.futuristic .btn-cancel:hover{background:#e5e7eb}.node-edit-content.futuristic .btn-save{background:linear-gradient(135deg,#10b981,#059669);color:#fff;box-shadow:0 4px 15px #10b9814d}.node-edit-content.futuristic .btn-save:hover{transform:translateY(-1px);box-shadow:0 6px 20px #10b98166}@keyframes modalPop{0%{opacity:0;transform:scale(.9) translateY(20px)}to{opacity:1;transform:scale(1) translateY(0)}}.node-edit-content .field-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:.3rem}.btn-ai-generate{display:flex;align-items:center;gap:.3rem;padding:.35rem .75rem;background:linear-gradient(135deg,#a0c4ff,#c4d9ff);border:none;border-radius:8px;font-size:.75rem;font-weight:600;color:#1e40af;cursor:pointer;transition:all .2s}.btn-ai-generate:hover:not(:disabled){transform:translateY(-1px);box-shadow:0 4px 12px #a0c4ff80}.btn-ai-generate:disabled{opacity:.7;cursor:not-allowed}.node-edit-content h3{margin:0 0 1rem;color:#5d4037}.node-edit-content .field{margin-bottom:1rem}.node-edit-content label{display:block;font-weight:600;color:#374151;margin-bottom:.4rem;font-size:.9rem}.node-edit-content input,.node-edit-content textarea{width:100%;padding:.6rem .8rem;border:1px solid #e5e7eb;border-radius:8px;font-size:.95rem;font-family:inherit}.node-edit-content textarea{min-height:120px;resize:vertical}.node-edit-content input:focus,.node-edit-content textarea:focus{outline:none;border-color:#ffb7b2}.node-edit-buttons{display:flex;align-items:stretch;gap:.5rem;justify-content:flex-end;margin-top:1.25rem}.node-edit-buttons button{height:40px;padding:0 1.25rem;display:flex;align-items:center;justify-content:center;border-radius:8px;font-weight:600;font-size:.9rem;cursor:pointer;border:none;transition:background .15s}.node-edit-buttons .btn-cancel{background:#f3f4f6;color:#666}.node-edit-buttons .btn-cancel:hover{background:#e5e7eb}.node-edit-buttons .btn-save{background:#ffb7b2;color:#5d4037}.node-edit-buttons .btn-save:hover{background:#ffa8a2}.view-toggle{display:flex;gap:0;border:1px solid #e5e7eb;border-radius:8px;overflow:hidden}.btn-toggle{display:flex;align-items:center;gap:.4rem;padding:.5rem .9rem;background:#fff;border:none;color:#6b7280;font-weight:500;font-size:.85rem;cursor:pointer;transition:all .15s}.btn-toggle:not(:last-child){border-right:1px solid #e5e7eb}.btn-toggle:hover{background:#f9fafb}.btn-toggle.active{background:linear-gradient(135deg,#ffb7b2,#ffc8c4);color:#5d4037;font-weight:600}.admin-layout{display:flex;min-height:100vh;background:linear-gradient(135deg,#fef2f4,#fff9e6,#f0fdf4)}.admin-layout-loading{display:flex;align-items:center;justify-content:center;min-height:100vh;background:#f8f9fa}.loading-spinner{width:40px;height:40px;border:3px solid #e5e7eb;border-top-color:#ffb7b2;border-radius:50%;animation:spin .8s linear infinite}.admin-sidebar{width:220px;background:linear-gradient(180deg,#fff,#fef2f4);border-right:2px solid rgba(255,183,178,.3);display:flex;flex-direction:column;transition:width .2s ease;flex-shrink:0;box-shadow:4px 0 20px #ffb7b21a}.admin-sidebar.closed{width:60px}.sidebar-header{display:flex;align-items:center;justify-content:space-between;padding:.75rem;border-bottom:2px dashed rgba(255,183,178,.4)}.sidebar-logo{display:flex;align-items:center;gap:.75rem}.logo-icon{font-size:1.25rem;width:36px;height:36px;background:linear-gradient(135deg,#ffb7b2,#ffc8c4);border-radius:10px;display:flex;align-items:center;justify-content:center;color:#5d4037}.logo-text{font-weight:700;font-size:1rem;color:#5d4037}.sidebar-toggle{background:none;border:none;padding:.4rem;cursor:pointer;color:#6b7280;border-radius:6px;transition:all .15s}.sidebar-toggle:hover{background:#f3f4f6;color:#374151}.sidebar-nav{flex:1;padding:.5rem;display:flex;flex-direction:column;gap:.2rem}.nav-item{display:flex;align-items:center;gap:.6rem;padding:.6rem .75rem;border:none;background:transparent;border-radius:12px;cursor:pointer;color:#6b7280;font-size:.85rem;font-weight:500;transition:all .15s;text-align:left;width:100%}.nav-item:hover{background:#f9fafb;color:#374151}.nav-item.active{background:linear-gradient(135deg,#ffb7b2,#ffc8c4);color:#5d4037;font-weight:600;box-shadow:0 2px 8px #ffb7b266}.nav-item.active .nav-icon{color:#5d4037}.nav-icon{font-size:1.1rem;flex-shrink:0}.sidebar-footer{padding:.75rem;border-top:1px solid #f3f4f6}.nav-item.logout:hover{background:#fef2f2;color:#dc2626}.admin-main{flex:1;display:flex;flex-direction:column;min-width:0}.admin-topbar{display:flex;align-items:center;justify-content:space-between;padding:.75rem 1.25rem;background:#fffc;-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px);border-bottom:2px dashed rgba(255,183,178,.3)}.page-title{margin:0;font-size:1.1rem;font-weight:700;color:#5d4037}.topbar-right{display:flex;align-items:center;gap:1rem}.user-info{display:flex;align-items:center;gap:.5rem;padding:.4rem .75rem;background:#f9fafb;border-radius:20px}.user-avatar{font-size:1rem}.user-name{font-size:.9rem;font-weight:500;color:#374151}.admin-content{flex:1;padding:1rem 1.25rem;overflow-y:auto;animation:fadeSlideIn .3s ease-out}@keyframes fadeSlideIn{0%{opacity:0;transform:translateY(10px)}to{opacity:1;transform:translateY(0)}}.dashboard{max-width:1200px}.stats-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:.75rem;margin-bottom:1.5rem}.stat-card{background:#fff;border-radius:16px;padding:1rem;display:flex;align-items:center;gap:.75rem;border:2px solid rgba(255,183,178,.2);box-shadow:0 4px 12px #ffb7b21a;cursor:pointer;transition:all .2s ease-out;position:relative;animation:cardPop .4s ease-out backwards}.stat-card:nth-child(1){animation-delay:.05s}.stat-card:nth-child(2){animation-delay:.1s}.stat-card:nth-child(3){animation-delay:.15s}.stat-card:nth-child(4){animation-delay:.2s}@keyframes cardPop{0%{opacity:0;transform:scale(.9) translateY(10px)}to{opacity:1;transform:scale(1) translateY(0)}}.stat-card:hover{transform:translateY(-2px);box-shadow:0 8px 20px #00000014}.stat-icon{width:44px;height:44px;border-radius:14px;display:flex;align-items:center;justify-content:center;font-size:1.1rem}.stat-icon.stories{background:linear-gradient(135deg,#ffb7b2,#ffc8c4);color:#5d4037}.stat-icon.sessions{background:linear-gradient(135deg,#a0c4ff,#b8d4ff);color:#1e40af}.stat-icon.users{background:linear-gradient(135deg,#c1e1c1,#d4ead4);color:#166534}.stat-icon.growth{background:linear-gradient(135deg,#fdfd96,#fefe9a);color:#92400e}.stat-info{flex:1}.stat-value{font-size:1.5rem;font-weight:700;color:#5d4037}.stat-label{font-size:.85rem;color:#9ca3af}.stat-badge{position:absolute;top:.75rem;right:.75rem;font-size:.7rem;padding:.2rem .5rem;background:#dcfce7;color:#166534;border-radius:10px;font-weight:600}.dashboard-section{margin-bottom:1.25rem}.section-title{font-size:.9rem;font-weight:600;color:#5d4037;margin:0 0 .75rem;display:flex;align-items:center;gap:.5rem}.section-title:before{content:"✦";color:#ffb7b2}.quick-actions{display:flex;gap:.5rem;flex-wrap:wrap}.action-btn{display:flex;align-items:center;gap:.4rem;padding:.5rem 1rem;background:#fff;border:2px solid rgba(160,196,255,.4);border-radius:12px;font-weight:500;font-size:.85rem;cursor:pointer;transition:all .15s;color:#5d4037}.action-btn:hover{border-color:#d1d5db;background:#f9fafb}.action-btn.primary{background:linear-gradient(135deg,#ffb7b2,#ffc8c4);border-color:transparent;color:#5d4037}.action-btn.primary:hover{transform:translateY(-1px);box-shadow:0 4px 12px #ffb7b266}.recent-list{background:#fff;border-radius:16px;overflow:hidden;box-shadow:0 4px 12px #ffb7b21f;border:2px solid rgba(255,183,178,.2)}.recent-item{display:flex;align-items:center;gap:.75rem;padding:.75rem 1rem;border-bottom:1px dashed rgba(255,183,178,.3)}.recent-item:last-child{border-bottom:none}.recent-avatar{width:36px;height:36px;background:linear-gradient(135deg,#a0c4ff,#c8dcff);border-radius:50%;display:flex;align-items:center;justify-content:center;font-size:.9rem;color:#1e40af}.recent-info{flex:1}.recent-name{font-weight:600;color:#374151;font-size:.95rem}.recent-detail{font-size:.8rem;color:#9ca3af;margin-top:.15rem}.recent-status{font-size:.75rem;padding:.25rem .6rem;border-radius:10px;font-weight:500}.recent-status.active{background:#dcfce7;color:#166534}.recent-status.ended{background:#f3f4f6;color:#6b7280}.loading-text,.empty-text{text-align:center;padding:2rem;color:#9ca3af}.story-edit-header{display:flex;align-items:center;justify-content:space-between;margin-bottom:1.5rem;padding-bottom:1rem;border-bottom:1px solid #e5e7eb}.edit-title-row{display:flex;align-items:center;gap:1rem}.edit-actions{display:flex;gap:.5rem}.edit-actions button{display:flex;align-items:center;gap:.4rem;padding:.6rem 1rem;border:none;border-radius:8px;font-weight:600;cursor:pointer;transition:all .15s}.btn-back{background:#f3f4f6;color:#6b7280}.btn-back:hover{background:#e5e7eb}.ai-config{max-width:900px}.config-section{background:#fff;border-radius:16px;padding:1rem 1.25rem;margin-bottom:1rem;border:2px solid rgba(255,183,178,.2);box-shadow:0 4px 12px #ffb7b21a;animation:cardPop .4s ease-out backwards}.config-section:nth-child(1){animation-delay:.05s}.config-section:nth-child(2){animation-delay:.1s}.config-section:nth-child(3){animation-delay:.15s}.config-section:nth-child(4){animation-delay:.2s}.config-section:nth-child(5){animation-delay:.25s}.config-section-title{font-size:.9rem;font-weight:600;color:#5d4037;margin:0 0 .75rem;display:flex;align-items:center;gap:.5rem}.config-section-title:before{content:"✦";color:#ffb7b2}.provider-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:.5rem}.provider-card{padding:.75rem;border:2px solid #e5e7eb;border-radius:12px;cursor:pointer;transition:all .15s}.provider-card:hover{border-color:#a0c4ff}.provider-card.selected{border-color:#ffb7b2;background:linear-gradient(135deg,#fef2f4,#fff)}.provider-name{font-weight:600;font-size:.85rem;color:#374151}.provider-desc{font-size:.7rem;color:#9ca3af;margin-top:.25rem}.config-grid{display:grid;grid-template-columns:1fr 1fr;gap:.75rem}.config-field label{display:block;font-size:.8rem;font-weight:500;color:#6b7280;margin-bottom:.3rem}.config-field input{width:100%;padding:.5rem .75rem;border:2px solid #e5e7eb;border-radius:10px;font-size:.85rem;transition:border-color .15s}.config-field input:focus{outline:none;border-color:#ffb7b2}.model-selector{background:#f9fafb;border-radius:12px;padding:.75rem}.model-header{display:flex;gap:.5rem;margin-bottom:.75rem}.model-search{flex:1;display:flex;align-items:center;gap:.5rem;padding:.4rem .75rem;background:#fff;border:2px solid #e5e7eb;border-radius:10px}.model-search input{flex:1;border:none;outline:none;font-size:.85rem}.btn-fetch{display:flex;align-items:center;gap:.4rem;padding:.5rem .75rem;background:linear-gradient(135deg,#a0c4ff,#b8d4ff);border:none;border-radius:10px;font-size:.8rem;font-weight:500;color:#1e40af;cursor:pointer;transition:all .15s}.btn-fetch:hover:not(:disabled){transform:translateY(-1px);box-shadow:0 4px 12px #a0c4ff66}.btn-fetch:disabled{opacity:.6;cursor:not-allowed}.model-list{display:flex;flex-wrap:wrap;gap:.4rem;max-height:200px;overflow-y:auto}.model-item{display:flex;align-items:center;gap:.3rem;padding:.4rem .75rem;background:#fff;border:2px solid #e5e7eb;border-radius:8px;font-size:.8rem;cursor:pointer;transition:all .15s}.model-item:hover{border-color:#a0c4ff}.model-item.selected{border-color:#ffb7b2;background:linear-gradient(135deg,#fef2f4,#fff)}.model-item .check-icon{color:#22c55e}.model-hint{font-size:.8rem;color:#6b7280}.model-input{display:block;width:100%;margin-top:.5rem;padding:.5rem .75rem;border:2px solid #e5e7eb;border-radius:10px;font-size:.85rem}.model-input:focus{outline:none;border-color:#ffb7b2}.model-empty{padding:1rem;text-align:center;color:#9ca3af;font-size:.85rem}.params-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:.75rem}.param-field label{display:block;font-size:.75rem;font-weight:500;color:#6b7280;margin-bottom:.25rem}.param-field input{width:100%;padding:.4rem .6rem;border:2px solid #e5e7eb;border-radius:8px;font-size:.85rem}.param-field input:focus{outline:none;border-color:#ffb7b2}.rate-limit-row{display:flex;align-items:flex-end;gap:.5rem}.rate-limit-row .param-field{flex:1}.rate-separator{padding-bottom:.5rem;color:#6b7280;font-size:.85rem}.config-actions{display:flex;align-items:center;gap:.75rem;margin-top:1rem}.btn-test,.btn-save{display:flex;align-items:center;gap:.4rem;padding:.6rem 1.25rem;border:none;border-radius:12px;font-size:.85rem;font-weight:600;cursor:pointer;transition:all .15s}.btn-test{background:#fff;border:2px solid #e5e7eb;color:#374151}.btn-test:hover{border-color:#a0c4ff}.btn-save{background:linear-gradient(135deg,#ffb7b2,#ffc8c4);color:#5d4037}.btn-save:hover:not(:disabled){transform:translateY(-1px);box-shadow:0 4px 12px #ffb7b266}.btn-save:disabled{opacity:.6;cursor:not-allowed}.save-msg{font-size:.85rem;font-weight:500}.save-msg.success{color:#22c55e}.save-msg.error{color:#ef4444}
