:root{color-scheme:dark;--bg:#0b0e14;--panel:#131923;--panel2:#18212e;--line:#273344;--text:#edf2fa;--muted:#9aa8ba;--gold:#e4bf68;--green:#7bd89c;--red:#f17878;--blue:#87aefc;font-family:Inter,system-ui,-apple-system,"Segoe UI",sans-serif}
*{box-sizing:border-box}
body{margin:0;background:radial-gradient(ellipse at top,#172232 0,#0b0e14 48rem);color:var(--text);min-height:100vh}
button,input,textarea{font:inherit}
button,a{-webkit-tap-highlight-color:transparent}
.topbar{height:72px;display:flex;align-items:center;justify-content:space-between;padding:0 clamp(16px,4vw,52px);border-bottom:1px solid rgba(255,255,255,.07);background:rgba(10,13,19,.8);position:sticky;top:0;z-index:4;backdrop-filter:blur(14px)}
.brand{display:flex;align-items:center;gap:12px;color:var(--text);text-decoration:none}.brand-mark{width:38px;height:38px;border-radius:12px;display:grid;place-items:center;background:linear-gradient(145deg,#edcc75,#a77e30);color:#17130a;font-weight:900;font-size:1.2rem}.brand b,.brand small{display:block}.brand b{font-size:.83rem;letter-spacing:.12em}.brand small{font-size:.72rem;color:var(--muted);margin-top:3px}
.top-actions{display:flex;align-items:center;gap:16px}.quiet-link{font-size:.8rem;color:var(--muted);text-decoration:none}.quiet-link:hover{color:var(--text)}.whoami{font-size:.72rem;color:var(--muted)}
.shell{width:min(1180px,calc(100% - 32px));margin:34px auto 64px}
.hero{display:flex;align-items:flex-end;justify-content:space-between;gap:24px;margin-bottom:20px}.hero h1{font-size:clamp(1.8rem,4vw,3rem);line-height:1.04;letter-spacing:-.04em;margin:7px 0 10px}.hero p:not(.eyebrow){color:var(--muted);margin:0;max-width:600px}.hero-actions{display:flex;gap:9px;flex-wrap:wrap;justify-content:flex-end}
.eyebrow{font-size:.66rem;font-weight:800;letter-spacing:.16em;color:var(--gold);margin:0 0 7px}.section-heading{display:flex;align-items:flex-end;justify-content:space-between;gap:18px;margin:34px 0 14px}.section-heading h2,.panel h2{font-size:1.2rem;margin:0 0 5px}.section-heading p:not(.eyebrow){color:var(--muted);font-size:.84rem;margin:5px 0 0}
.button{border:1px solid transparent;border-radius:10px;padding:10px 14px;min-height:40px;font-size:.8rem;font-weight:750;cursor:pointer;transition:filter .15s,transform .15s;background:none;color:var(--text)}.button:hover{filter:brightness(1.12);transform:translateY(-1px)}.button:disabled{opacity:.5;cursor:not-allowed;transform:none}.primary{background:linear-gradient(135deg,#e9cc7a,#c09a43);color:#17130a}.secondary{background:#202b3b;border-color:#34455b}.danger{background:#4a2529;border-color:#73373e;color:#ffcdcd}
.notice{padding:12px 15px;margin:14px 0 20px;background:#172536;border:1px solid #294665;border-radius:12px;color:#cfe0f8;font-size:.84rem}.notice.error{background:#391f24;border-color:#67353d;color:#ffd2d2}.notice.success{background:#173126;border-color:#2f654a;color:#ccf5dd}
.bot-grid,.template-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:15px}.bot-card,.template-card,.panel{background:linear-gradient(150deg,rgba(24,33,46,.98),rgba(17,23,33,.98));border:1px solid var(--line);border-radius:16px;box-shadow:0 12px 32px rgba(0,0,0,.14)}
.bot-card{padding:17px}.bot-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px}.bot-title{display:flex;align-items:center;gap:11px}.bot-mark{width:42px;height:42px;display:grid;place-items:center;border-radius:13px;background:#202c3b;border:1px solid #34465d;color:var(--gold);font-weight:900}.bot-title h3{font-size:1rem;margin:0 0 4px}.bot-title p{font-size:.72rem;color:var(--muted);margin:0}.status-pill,.count-pill{border-radius:999px;padding:6px 9px;font-size:.67rem;font-weight:800;white-space:nowrap;background:#1d3328;color:#a5edbf;border:1px solid #315d42}.status-pill.off{background:#3b2528;color:#ffbcbc;border-color:#63393e}.status-pill.pending{background:#302b20;color:#f2d98c;border-color:#67562c}
.bot-meta{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin:15px 0}.meta-item{border:1px solid rgba(255,255,255,.06);background:rgba(4,8,13,.22);border-radius:10px;padding:9px 10px;min-width:0}.meta-item small{display:block;color:var(--muted);font-size:.64rem;margin-bottom:4px}.meta-item b{font-size:.76rem;overflow-wrap:anywhere}.bot-actions{display:flex;align-items:center;justify-content:space-between;gap:9px;border-top:1px solid rgba(255,255,255,.07);padding-top:13px}
.switch-line{display:flex;align-items:center;gap:9px;font-size:.78rem;font-weight:750;cursor:pointer}.switch-line input{appearance:none;width:38px;height:22px;border-radius:999px;background:#445064;position:relative;cursor:pointer;transition:background .2s;margin:0}.switch-line input:before{content:"";position:absolute;inset:3px auto 3px 3px;width:16px;border-radius:50%;background:#fff;transition:transform .2s}.switch-line input:checked{background:#48a978}.switch-line input:checked:before{transform:translateX(16px)}
.features{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px;margin-top:14px}.feature{display:flex;align-items:center;gap:8px;border:1px solid rgba(255,255,255,.06);background:rgba(3,7,12,.18);border-radius:9px;padding:8px;font-size:.72rem;color:#d4dce7}.feature input{accent-color:#64c68e}.feature .feature-save{margin-left:auto;color:var(--green);font-size:.62rem;display:none}.feature.saving .feature-save{display:block}
.template-card{padding:0;overflow:hidden}.template-swatch{height:82px;padding:12px 15px;display:flex;align-items:flex-start;justify-content:space-between;background:linear-gradient(115deg,var(--template-primary),var(--template-accent) 52%,var(--template-bg))}.template-swatch span{font-size:.65rem;font-weight:800;color:#111;background:rgba(255,255,255,.65);padding:6px 9px;border-radius:999px}.template-body{padding:15px}.template-body h3{margin:0 0 5px;font-size:1rem}.template-body>p{margin:0 0 13px;color:var(--muted);font-size:.73rem}.template-form{display:grid;grid-template-columns:1fr 1fr;gap:9px}.template-form label,.credentials-form label{display:flex;flex-direction:column;gap:6px;font-size:.72rem;color:#c7d1dd}.template-form label.wide{grid-column:1/-1}.template-form input,.template-form textarea,.credentials-form input,.credentials-form textarea{border:1px solid #344357;background:#0d131b;color:var(--text);border-radius:8px;padding:9px 10px;outline:none;width:100%;font-size:.78rem}.template-form textarea,.credentials-form textarea{resize:vertical}.template-form input:focus,.template-form textarea:focus,.credentials-form input:focus,.credentials-form textarea:focus{border-color:#b6964e;box-shadow:0 0 0 2px rgba(226,191,104,.12)}.template-actions{display:flex;justify-content:flex-end;margin-top:10px}
.panel{padding:17px;margin-top:18px}.panel p{color:var(--muted);font-size:.8rem;margin:6px 0 0}.help{max-width:680px;margin:30px auto;text-align:center;padding:30px}.count-pill{background:#21283a;color:#d4c39a;border-color:#484236}
.global-controls{display:flex;align-items:center;justify-content:space-between;gap:18px}.global-control-actions{display:flex;align-items:flex-end;gap:8px;flex-wrap:wrap}.global-control-actions label{display:grid;gap:6px;color:var(--muted);font-size:.68rem}.global-control-actions select{min-width:180px;border:1px solid #344357;background:#0d131b;color:var(--text);border-radius:8px;padding:10px;font:inherit}.activation-fields,.activation-identity{grid-column:1/-1;color:#e2c572!important;font-size:.68rem!important;margin:7px 0 0!important}.template-switch{margin-right:auto}.audit-list{display:grid;margin-top:13px}.audit-row{display:flex;justify-content:space-between;align-items:center;gap:14px;border-top:1px solid rgba(255,255,255,.07);padding:11px 0}.audit-detail b,.audit-detail small{display:block}.audit-detail b{font-size:.76rem}.audit-detail small,.audit-row time,.audit-empty{color:var(--muted);font-size:.68rem}.audit-row time{text-align:right;white-space:nowrap}.audit-empty{margin:8px 0 0}
.credential-dialog{width:min(600px,calc(100% - 26px));max-height:90vh;overflow:auto;border:1px solid #3b4b61;border-radius:17px;background:#131a25;color:var(--text);padding:0;box-shadow:0 24px 80px rgba(0,0,0,.65)}.credential-dialog::backdrop{background:rgba(0,0,0,.72);backdrop-filter:blur(5px)}.dialog-head{display:flex;align-items:center;justify-content:space-between;padding:18px 20px;border-bottom:1px solid var(--line)}.dialog-head h2{margin:0;font-size:1.12rem}.icon-button{border:0;background:#253144;color:white;width:34px;height:34px;border-radius:9px;font-size:1.25rem;cursor:pointer}.credentials-form{padding:18px 20px;display:grid;gap:13px}.credentials-form label{font-size:.75rem}.field-hint{font-weight:400;color:var(--muted);font-size:.67rem}.lock-label{color:#f3d787;font-size:.65rem}.dialog-warning{font-size:.73rem;line-height:1.5;color:#f0d99c;background:#302a1d;border:1px solid #67552b;border-radius:9px;padding:10px;margin:0}.dialog-actions{display:flex;justify-content:flex-end;gap:8px}.audit-panel{margin-top:26px}.templates-heading{margin-top:40px}
@media(max-width:760px){.hero{align-items:flex-start;flex-direction:column}.hero-actions{justify-content:flex-start}.bot-grid,.template-grid{grid-template-columns:1fr}.shell{margin-top:24px}.topbar{height:64px}.top-actions{gap:8px}.quiet-link{font-size:.72rem}.whoami{display:none}}
@media(max-width:760px){.global-controls{align-items:flex-start;flex-direction:column}.global-control-actions{width:100%}.global-control-actions select{min-width:0}}
@media(max-width:440px){.bot-meta{grid-template-columns:1fr 1fr}.features{grid-template-columns:1fr}.template-form{grid-template-columns:1fr}.template-form label.wide{grid-column:auto}.hero-actions{width:100%}.hero-actions .button{flex:1}.bot-actions{align-items:flex-start;flex-direction:column}.bot-actions .button{width:100%}}
.template-heading-actions{display:flex;align-items:center;gap:9px;flex-wrap:wrap;justify-content:flex-end}.private-dir{display:block;margin:0 0 12px;color:#aab8ca;font-size:.65rem;overflow-wrap:anywhere}.credentials-form select{border:1px solid #344357;background:#0d131b;color:var(--text);border-radius:8px;padding:10px;outline:none;width:100%;font:inherit;font-size:.78rem}.credentials-form select:focus{border-color:#b6964e;box-shadow:0 0 0 2px rgba(226,191,104,.12)}
@media(max-width:760px){.template-heading-actions{width:100%;justify-content:flex-start}}
.monitor-panel{display:grid;grid-template-columns:1fr minmax(260px,.8fr);align-items:center;gap:22px}.monitor-status{margin-top:12px!important;color:#cbd9ed!important}.monitor-owner-form{display:grid;gap:8px}.monitor-owner-form>label{font-size:.72rem;color:#c7d1dd}.monitor-owner-form>div{display:flex;gap:8px}.monitor-owner-form input{min-width:0;flex:1;border:1px solid #344357;background:#0d131b;color:var(--text);border-radius:8px;padding:10px;font:inherit}.monitor-owner-form small{font-size:.66rem;line-height:1.45;color:var(--muted)}
.product-tools{display:grid;gap:10px;margin-top:14px;padding-top:13px;border-top:1px solid rgba(255,255,255,.07)}.product-tools-title b,.product-tools-title small{display:block}.product-tools-title b{font-size:.78rem}.product-tools-title small{margin-top:4px;color:var(--muted);font-size:.65rem}.product-tools-title .private-dir{margin:5px 0 0}.product-tools-actions{display:flex;align-items:center;gap:7px;flex-wrap:wrap}.product-tools-actions .button{min-height:36px;padding:8px 10px;font-size:.7rem}.product-import{position:relative;overflow:hidden}.product-import input{position:absolute;inset:0;width:100%;height:100%;opacity:0;cursor:pointer}.product-import.disabled{opacity:.5;pointer-events:none}.template-actions{flex-wrap:wrap;gap:7px}.template-actions .switch-line{flex:1 0 auto}.template-actions .button{font-size:.7rem;padding:8px 10px;min-height:36px}
@media(max-width:760px){.monitor-panel{grid-template-columns:1fr}.monitor-owner-form>div{flex-wrap:wrap}.monitor-owner-form .button{width:100%}}
