*{box-sizing:border-box}html,body{background:var(--bg);color:var(--text);-webkit-font-smoothing:antialiased;margin:0;font:14px/1.45 -apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,sans-serif}a{color:var(--accent);text-decoration:none}a:hover{text-decoration:underline}h1{margin:0;font-size:22px;font-weight:700}h2{margin:0 0 var(--space-sm);font-size:16px;font-weight:600}.shell{grid-template-columns:240px 1fr;min-height:100vh;display:grid}.side{border-right:1px solid var(--separator);padding:var(--space-lg) var(--space-sm);gap:var(--space-lg);flex-direction:column;height:100vh;display:flex;position:sticky;top:0;overflow-y:auto}.side-brand{padding:0 var(--space-md);font-size:16px;font-weight:700}.side-group-title{color:var(--text-faint);text-transform:uppercase;letter-spacing:.04em;padding:0 var(--space-md) var(--space-xs);font-size:12px;font-weight:600}.side-link{justify-content:space-between;align-items:center;gap:var(--space-sm);min-height:var(--control-sm);padding:0 var(--space-md);border-radius:var(--radius-md);color:var(--text);display:flex}.side-link:hover{background:var(--card);text-decoration:none}.side-link.active{background:var(--card-nested);font-weight:600}.side-foot{gap:var(--space-sm);padding:0 var(--space-md);flex-direction:column;margin-top:auto;display:flex}.main{padding:var(--space-xxl) var(--space-xxxl);min-width:0}.page{gap:var(--space-xl);flex-direction:column;max-width:1200px;display:flex}.page-head{align-items:center;gap:var(--space-md);flex-wrap:wrap;display:flex}.page-head .grow{flex:1}@media (max-width:860px){.shell{grid-template-columns:1fr}.side{border-right:0;border-bottom:1px solid var(--separator);height:auto;position:static}.main{padding:var(--space-lg)}}.card{background:var(--card);border-radius:var(--radius-lg);padding:var(--space-lg)}.card.flush{padding:0;overflow:hidden}.stack{gap:var(--space-md);flex-direction:column;display:flex}.row{align-items:center;gap:var(--space-sm);flex-wrap:wrap;display:flex}.row.between{justify-content:space-between}.grid{gap:var(--space-md);grid-template-columns:repeat(auto-fill,minmax(220px,1fr));display:grid}.cols-2{gap:var(--space-lg);grid-template-columns:1fr 1fr;display:grid}@media (max-width:860px){.cols-2{grid-template-columns:1fr}}.muted{color:var(--text-muted)}.faint{color:var(--text-faint)}.small{font-size:12px}.strong{font-weight:600}.mono{font-family:ui-monospace,SFMono-Regular,Menlo,monospace;font-size:13px}.danger-text{color:var(--danger)}.success-text{color:var(--success)}.warning-text{color:var(--warning)}.pre{white-space:pre-wrap;word-break:break-word}.stat{gap:var(--space-xs);background:var(--card);border-radius:var(--radius-lg);padding:var(--space-lg);color:var(--text);flex-direction:column;display:flex}a.stat:hover{background:var(--card-nested);text-decoration:none}.stat-value{font-variant-numeric:tabular-nums;font-size:28px;font-weight:700}.stat-label{color:var(--text-muted)}.table-wrap{overflow-x:auto}table{border-collapse:collapse;width:100%}th,td{text-align:left;padding:var(--space-sm) var(--space-md);border-bottom:1px solid var(--separator);vertical-align:top}th{color:var(--text-muted);white-space:nowrap;font-size:12px;font-weight:600}tbody tr:last-child td{border-bottom:0}tr.clickable{cursor:pointer}tr.clickable:hover td{background:var(--card-nested)}td.num,th.num{text-align:right;font-variant-numeric:tabular-nums;white-space:nowrap}td.nowrap{white-space:nowrap}.badge{min-height:20px;padding:0 var(--space-sm);border-radius:var(--radius-sm);white-space:nowrap;background:var(--card-nested);color:var(--text-muted);align-items:center;font-size:12px;font-weight:600;display:inline-flex}.badge.danger{background:var(--danger);color:var(--on-status)}.badge.warning{background:var(--warning);color:var(--on-status)}.badge.success{background:var(--success);color:var(--on-status)}.badge.accent{background:var(--accent);color:var(--on-accent)}.count{border-radius:var(--radius-full);background:var(--danger);min-width:20px;height:20px;color:var(--on-status);justify-content:center;align-items:center;padding:0 6px;font-size:12px;font-weight:600;display:inline-flex}.field{gap:var(--space-xs);flex-direction:column;min-width:0;display:flex}.field>span{color:var(--text-muted);font-size:12px;font-weight:600}input,select,textarea{font:inherit;color:var(--text);background:var(--card-nested);border:1px solid var(--border);border-radius:var(--radius-md);min-height:var(--control-md);padding:0 var(--space-md);width:100%}textarea{padding:var(--space-sm) var(--space-md);resize:vertical;min-height:88px}input:focus,select:focus,textarea:focus{outline:2px solid var(--accent);outline-offset:-1px}input[type=checkbox],input[type=radio]{width:18px;height:18px;min-height:18px;accent-color:var(--accent)}input[type=file]{padding:var(--space-sm)}.check{align-items:center;gap:var(--space-sm);cursor:pointer;-webkit-user-select:none;user-select:none;display:inline-flex}.form-grid{gap:var(--space-md);grid-template-columns:repeat(auto-fill,minmax(200px,1fr));align-items:end;display:grid}button{font:inherit;cursor:pointer}.btn{justify-content:center;align-items:center;gap:var(--space-xs);min-height:var(--control-md);padding:0 var(--space-lg);border-radius:var(--radius-md);border:1px solid var(--border);background:var(--card-nested);color:var(--text);white-space:nowrap;font-weight:600;display:inline-flex}.btn:hover:not(:disabled){border-color:var(--list-divider)}.btn:disabled{opacity:.5;cursor:default}.btn.primary{background:var(--accent);border-color:var(--accent);color:var(--on-accent)}.btn.danger{background:var(--danger);border-color:var(--danger);color:var(--on-status)}.btn.small{min-height:var(--control-sm);padding:0 var(--space-md)}.btn.link{color:var(--accent);background:0 0;border:0;min-height:0;padding:0}.tabs{background:var(--card);border-radius:var(--radius-md);flex-wrap:wrap;gap:2px;padding:3px;display:inline-flex}.tab{color:var(--text-muted);min-height:30px;padding:0 var(--space-md);border-radius:var(--radius-sm);background:0 0;border:0;font-weight:600}.tab.active{background:var(--card-nested);color:var(--text)}.error{color:var(--danger);white-space:pre-wrap}.empty{color:var(--text-muted);padding:var(--space-xl) 0;text-align:center}.skeleton{background:var(--skeleton-bone);border-radius:var(--radius-sm);height:14px}dialog{border:1px solid var(--border);border-radius:var(--radius-lg);background:var(--card);color:var(--text);padding:var(--space-xl);width:min(480px,100vw - 32px)}dialog::backdrop{background:var(--scrim)}.photos{gap:var(--space-sm);flex-wrap:wrap;display:flex}.photo{gap:var(--space-xs);flex-direction:column;display:flex}.photo-frame{border-radius:var(--radius-md);background:var(--card-nested);width:220px;height:160px;color:var(--text-faint);justify-content:center;align-items:center;font-size:12px;display:flex;overflow:hidden}.photo-frame img,.photo-frame video{object-fit:contain;width:100%;height:100%}.photo-frame.square{width:160px;height:160px}.photo-frame.square img{object-fit:cover}.photo-frame.tall{width:135px;height:240px}.chat{gap:var(--space-sm);flex-direction:column;display:flex}.bubble{max-width:72%;padding:var(--space-sm) var(--space-md);border-radius:var(--radius-lg);background:var(--card);white-space:pre-wrap;word-break:break-word}.bubble.mine{background:var(--accent);color:var(--on-accent);align-self:flex-end}.bubble.system{color:var(--text-muted);background:0 0;align-self:center;padding:0;font-size:12px}.bubble-meta{opacity:.7;margin-top:2px;font-size:11px}.login{min-height:100vh;padding:var(--space-lg);justify-content:center;align-items:center;display:flex}.login-box{gap:var(--space-md);flex-direction:column;width:min(360px,100%);display:flex}.prefixed{background:var(--card-nested);border:1px solid var(--border);border-radius:var(--radius-md);padding-left:var(--space-md);align-items:center;display:flex}.prefixed:focus-within{outline:2px solid var(--accent);outline-offset:-1px}.prefixed input{padding-left:var(--space-sm);background:0 0;border:0}.prefixed input:focus{outline:none}.list-row{justify-content:space-between;align-items:flex-start;gap:var(--space-md);padding:var(--space-md) var(--space-lg);border-bottom:1px solid var(--separator);display:flex}.list-row:last-child{border-bottom:0}.drag{cursor:grab}.drag.over td{border-top:2px solid var(--accent)}dialog.wide{width:min(720px,100vw - 32px)}.row.end{justify-content:flex-end}.photo-frame a{width:100%;height:100%;display:block}.stack-tight{flex-direction:column;gap:2px;display:flex}.clip{text-overflow:ellipsis;white-space:nowrap;vertical-align:bottom;max-width:360px;display:inline-block;overflow:hidden}select.auto,input.auto{width:auto}.skeleton.block{border-radius:var(--radius-lg);height:160px}a.btn:hover{text-decoration:none}.alert{background:var(--danger);color:var(--on-status);border-radius:var(--radius-md);padding:var(--space-sm) var(--space-md);font-weight:600}.nested{background:var(--card-nested);border-radius:var(--radius-md);padding:var(--space-md)}.thumb{border-radius:var(--radius-md);background:var(--card-nested);width:48px;height:48px;overflow:hidden}.thumb img{object-fit:cover;width:100%;height:100%}
