:root{color-scheme:light;--bg:#f3f5f8;--panel:#fff;--ink:#192337;--muted:#59677c;--line:#dde3ed;--accent:#2859c4;--soft:#edf2ff;--hover:#f5f7fb;--shadow:0 2px 8px #172b4d08;font-family:system-ui,-apple-system,"Segoe UI",sans-serif;font-size:14px}
[data-theme=dark]{color-scheme:dark;--bg:#10151f;--panel:#19212f;--ink:#e8eef8;--muted:#a5b1c6;--line:#303c50;--accent:#95b7ff;--soft:#243557;--hover:#202c40;--shadow:none}
*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--ink);padding:30px 28px 100px}button,input,textarea,select{font:inherit}button,select{cursor:pointer}button{color:var(--ink);background:var(--panel);border:1px solid var(--line);border-radius:9px;padding:9px 13px;line-height:1.3}button:hover{background:var(--hover);border-color:var(--muted)}button:disabled{opacity:.5;cursor:wait}a{color:var(--accent)}:focus-visible{outline:3px solid var(--accent);outline-offset:3px}[hidden]{display:none!important}.page-header,main{max-width:1680px;margin:auto}.page-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:28px}.eyebrow{letter-spacing:.16em;font-size:.68rem;font-weight:700;color:var(--muted)}h1{font-size:2.7rem;letter-spacing:-.06em;line-height:1;margin:10px 0}h1 span{color:var(--accent)}.page-header p{color:var(--muted);margin:8px 0 0}.header-tools{display:flex;align-items:center;gap:14px}#live-status{font-size:.78rem;color:var(--muted)}#live-status:before{content:"";display:inline-block;width:7px;height:7px;background:#18824c;border-radius:50%;margin-right:7px}.search-bar{display:flex;align-items:center;background:var(--panel);border:1px solid var(--line);border-radius:12px;max-width:860px;margin:0 auto 24px;padding:7px;gap:8px;box-shadow:var(--shadow)}.search-mark{font-size:1.8rem;color:var(--muted);padding-left:10px}.search-bar input{min-width:0;flex:1;padding:9px 3px;border:0;outline:none;background:transparent;color:var(--ink)}.search-bar select{max-width:130px;border:0;border-left:1px solid var(--line);padding:7px;color:var(--muted);background:transparent}.search-bar button{background:var(--soft);border:0;color:var(--accent);font-weight:650}.filter-bar{display:flex;justify-content:space-between;align-items:center;gap:10px;margin:0 0 18px}.filter-bar>div{display:flex;gap:7px}.filter-bar button{font-size:.83rem}.filter-bar p{color:var(--muted);font-size:.82rem;margin:0}button[aria-pressed=true]{background:var(--soft);color:var(--accent);border-color:var(--accent)}.groups{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,320px),1fr));gap:17px;align-items:start}.group{background:var(--panel);border:1px solid var(--line);border-radius:12px;box-shadow:var(--shadow);min-width:0;content-visibility:auto;contain-intrinsic-size:auto 360px}.group>summary{display:flex;align-items:center;gap:10px;list-style:none;cursor:pointer;padding:16px 17px;border-bottom:1px solid transparent;font-weight:700}.group[open]>summary{border-bottom-color:var(--line)}summary::-webkit-details-marker{display:none}.group>summary:before{content:"";width:4px;height:20px;border-radius:4px;background:var(--group-color,var(--accent));flex:none}.group-title{flex:1;min-width:0}.group-count{color:var(--muted);font-size:.75rem;font-weight:500}.group>summary:after,.service>summary:after{content:"⌄";color:var(--muted);font-size:1rem;font-weight:400}.group:not([open])>summary:after{content:"›"}.services{padding:5px 10px 10px}.service{border-bottom:1px solid var(--line)}.service:last-child{border-bottom:0}.service>summary{display:flex;align-items:center;list-style:none;gap:4px;padding-right:7px;cursor:pointer;min-height:59px}.service>summary:hover{background:var(--hover);border-radius:7px}.service[open]>summary:after{transform:rotate(180deg)}.service-link{display:flex;align-items:center;gap:11px;min-width:0;flex:1;padding:10px 6px;color:var(--ink);text-decoration:none}.icon{width:32px;height:32px;display:grid;place-items:center;flex:none;color:var(--accent);background:var(--soft);border-radius:8px;font-size:.65rem;font-weight:700;overflow:hidden}.icon img{width:25px;height:25px;object-fit:contain}.link-text{display:flex;flex-direction:column;gap:4px;min-width:0}.link-name{font-size:.88rem;font-weight:600;overflow-wrap:anywhere}.link-host{font-size:.71rem;color:var(--muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.star{color:#b7790a;margin-right:4px}.service-body{padding:1px 9px 14px 49px;font-size:.85rem;line-height:1.6}.description{margin:0 0 10px;white-space:pre-line;overflow-wrap:anywhere}.full-url{display:block;font-family:ui-monospace,Consolas,monospace;font-size:.72rem;overflow-wrap:anywhere;line-height:1.55}.item-actions{display:flex;flex-wrap:wrap;gap:6px;margin-top:11px}.item-actions button,.group-actions button{font-size:.76rem;padding:6px 8px}.item-actions .danger{color:#bb243d}.row-edit{font-size:.85rem;padding:5px 7px;display:none}body.editing .row-edit{display:block}.group-actions{display:flex;flex-wrap:wrap;gap:5px;padding:7px 15px 12px;display:none}body.editing .group-actions{display:flex}body.editing .service{border-radius:7px}body.editing .service[draggable=true]{cursor:grab}.drag-over{outline:2px dashed var(--accent);outline-offset:1px}.edit-bar{position:fixed;bottom:18px;left:50%;transform:translateX(-50%);display:flex;gap:8px;align-items:center;background:var(--panel);border:1px solid var(--line);border-radius:12px;padding:8px;box-shadow:var(--shadow);z-index:5;max-width:calc(100% - 24px)}#edit-actions{display:flex;gap:7px}.primary{background:var(--accent);color:var(--panel);border-color:var(--accent);font-weight:650}.primary:hover{background:var(--accent);filter:brightness(.94)}dialog{color:var(--ink);background:var(--panel);border:1px solid var(--line);border-radius:14px;width:min(95vw,580px);max-height:90vh;padding:22px}dialog::backdrop{background:#10182680}.dialog-heading{display:flex;justify-content:space-between;align-items:center;margin-bottom:18px}.dialog-heading h2{font-size:1.15rem;margin:0}.dialog-heading>button{font-size:1.3rem;padding:2px 9px}dialog label{display:block;font-size:.85rem;font-weight:600;margin:13px 0}dialog input:not([type=checkbox]),dialog textarea{display:block;width:100%;color:var(--ink);background:var(--bg);border:1px solid var(--line);border-radius:7px;padding:11px;margin-top:6px}dialog textarea{resize:vertical}dialog textarea#transfer-text{font:12px/1.6 ui-monospace,Consolas,monospace}.form-row{display:flex;gap:18px;align-items:center}.form-row>label:first-child{width:130px}.check{display:flex;gap:6px;align-items:center}.hint{font-size:.8rem;color:var(--muted);line-height:1.5}.advanced{font-size:.8rem;color:var(--muted)}.advanced>summary{cursor:pointer}.dialog-actions{display:flex;justify-content:flex-end;gap:8px;margin-top:20px}.notice{padding:13px 16px;background:var(--soft);border:1px solid var(--line);border-radius:9px;margin-bottom:17px}.empty{text-align:center;color:var(--muted);padding:50px 10px}#toast{position:fixed;left:50%;bottom:85px;transform:translateX(-50%);background:var(--ink);color:var(--panel);padding:13px 19px;border-radius:9px;max-width:90vw;z-index:20;font-size:.86rem}.sr-only{position:absolute;width:1px;height:1px;padding:0;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
@media(max-width:640px){body{padding:20px 13px 100px}.page-header{align-items:start;margin-bottom:22px}.page-header p{font-size:.8rem}h1{font-size:2.2rem}.eyebrow{font-size:.56rem}.header-tools{flex-direction:column-reverse;align-items:end;gap:9px}.header-tools button{padding:7px 10px;font-size:.8rem}.search-bar{gap:3px;flex-wrap:wrap}.search-bar input{width:calc(100% - 40px);flex-basis:calc(100% - 40px)}.search-bar select{max-width:none;flex:1;border-left:0;padding-left:11px}.search-bar button{font-size:.8rem}.filter-bar{align-items:start;flex-direction:column;gap:12px}.filter-bar button{padding:8px 10px}.groups{grid-template-columns:1fr;gap:13px}.group>summary{padding:15px}.service>summary{min-height:62px}.edit-bar{bottom:9px;flex-wrap:wrap;justify-content:center;width:max-content}#edit-actions{flex-wrap:wrap;justify-content:center}.edit-bar button{font-size:.78rem;padding:8px 10px}.form-row{flex-wrap:wrap;gap:0}.form-row>label:first-child{width:100%}.service-body{padding-left:14px}.search-mark{padding-left:9px}dialog{padding:18px}}
@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto!important}}
