:root{--bg:#f5f6f8;--surface:#fff;--border:#dfe3e8;--text:#20242a;--muted:#68717d;--accent:#486bd8;--accent-soft:#e9efff;--danger:#b43a3a;--completed:#5c8f65;--missed:#b86647;--shadow:0 10px 30px rgba(30,40,60,.09);font-family:Inter,system-ui,sans-serif;color:var(--text);background:var(--bg)}*{box-sizing:border-box}body{margin:0;color:var(--text);background:var(--bg)}
body[data-theme="cute"]{--bg:#fff4fb;--surface:#fffafd;--border:#edcfe3;--accent:#cc6ba9;--accent-soft:#fbe3f2}body[data-theme="cozy"]{--bg:#f3eee4;--surface:#fffaf0;--border:#d8cbb7;--accent:#7b6b45;--accent-soft:#ebe2ce}body[data-theme="halloween"]{--bg:#1b1720;--surface:#29222f;--border:#584160;--text:#f7ead8;--muted:#c1adbd;--accent:#ee8b2d;--accent-soft:#4d3021}body[data-theme="winter"]{--bg:#edf7fb;--surface:#fff;--border:#bdd8e5;--accent:#3682a8;--accent-soft:#d8eff8}body[data-theme="valentine"]{--bg:#fff0f2;--surface:#fffafb;--border:#efc6ce;--accent:#c74462;--accent-soft:#fde0e7}body[data-theme="spring"]{--bg:#f2f8ed;--surface:#fcfff9;--border:#cfe0bf;--accent:#62964d;--accent-soft:#e2f0d8}body[data-theme="chicago95"]{--bg:#008080;--surface:#c0c0c0;--border:#808080;--text:#000;--muted:#333;--accent:#000080;--accent-soft:#d8d8ef;font-family:"MS Sans Serif",Tahoma,sans-serif}
.corehub-top{height:58px;background:var(--surface);border-bottom:1px solid var(--border);display:flex;align-items:center;justify-content:space-between;padding:0 24px;position:sticky;top:0;z-index:1000;color:var(--text)}.corehub-brand{font-weight:800;text-decoration:none;color:var(--text);font-size:20px}.corehub-wrap{max-width:1050px;margin:35px auto;padding:0 20px}.corehub-menu details{position:relative}.corehub-menu summary{cursor:pointer;list-style:none}.corehub-dropdown{position:absolute;right:0;top:30px;width:200px;background:var(--surface);border:1px solid var(--border);border-radius:11px;padding:7px;box-shadow:var(--shadow);z-index:1001}.corehub-dropdown a,.corehub-dropdown button{display:block;width:100%;padding:9px 10px;border:0;background:none;text-align:left;text-decoration:none;color:var(--text);border-radius:7px}.corehub-dropdown a:hover,.corehub-dropdown button:hover{background:var(--accent-soft)}
.corehub-hero{margin-bottom:22px}.corehub-hero h1{margin-bottom:5px}.corehub-hero p,.corehub-card p{color:var(--muted)}.corehub-appgrid{display:grid;grid-template-columns:repeat(auto-fill,minmax(250px,1fr));gap:18px}.corehub-appcard,.corehub-card{background:var(--surface);border:1px solid var(--border);border-radius:16px;box-shadow:var(--shadow)}.corehub-appcard{padding:20px;display:flex;gap:17px;align-items:center;text-decoration:none;color:inherit;transition:.15s}.corehub-appcard:hover{transform:translateY(-2px)}.corehub-appcard h2{margin:0 0 6px}.corehub-appcard p{margin:0;color:var(--muted)}.corehub-appicon{width:54px;height:54px;border-radius:15px;background:var(--accent-soft);color:var(--accent);display:grid;place-items:center;font-size:26px;font-weight:800}.corehub-card{padding:24px;margin-bottom:20px}.corehub-inline{display:flex;gap:9px;flex-wrap:wrap;align-items:end}.corehub-table{display:grid}.corehub-row{display:flex;gap:12px;align-items:center;padding:12px 0;border-top:1px solid var(--border)}.corehub-row:first-child{border-top:0}.corehub-row>div:first-child{flex:1}.corehub-row small{display:block;color:var(--muted);margin-top:3px}.corehub-pill{font-size:12px;border-radius:20px;padding:5px 9px;background:#e6f4ea;color:#205b34}.corehub-pill.off{background:var(--accent-soft);color:var(--muted)}.corehub-flash{padding:12px 15px;border-radius:10px;margin-bottom:15px;background:var(--accent-soft)}.corehub-flash.error{background:#fce8e6;color:#8d2929}.corehub-flash.success{background:#e6f4ea;color:#205b34}
input,button,select,textarea{font:inherit;border:1px solid var(--border);border-radius:9px;padding:10px 12px;background:var(--surface);color:var(--text)}button{cursor:pointer}.corehub-primary,.primary{background:var(--accent)!important;color:#fff!important;border-color:var(--accent)!important;font-weight:700}label{display:grid;gap:6px;font-weight:650}dt{font-weight:700;margin-top:12px}dd{margin-left:0;color:var(--muted)}code{background:var(--accent-soft);padding:2px 5px;border-radius:4px}
/* Compatibility aliases for v0.1 templates */.top{height:58px;background:var(--surface);border-bottom:1px solid var(--border);display:flex;align-items:center;justify-content:space-between;padding:0 24px}.wrap{max-width:1050px;margin:35px auto;padding:0 20px}.card{background:var(--surface);border:1px solid var(--border);border-radius:16px;padding:24px;margin-bottom:20px}.table{display:grid}.row{display:flex;gap:12px;align-items:center;padding:12px 0;border-top:1px solid var(--border)}.row>div:first-child{flex:1}.row small{display:block;color:var(--muted)}.pill{font-size:12px;border-radius:20px;padding:5px 9px;background:#e6f4ea}.pill.off{background:#eee}.inline{display:flex;gap:9px;flex-wrap:wrap}.auth{max-width:430px;margin:70px auto}.auth form{display:grid;gap:15px}
body[data-theme="chicago95"] .corehub-card,body[data-theme="chicago95"] .corehub-appcard,body[data-theme="chicago95"] button,body[data-theme="chicago95"] input,body[data-theme="chicago95"] select,body[data-theme="chicago95"] textarea{border-radius:0;box-shadow:inset -1px -1px #000,inset 1px 1px #fff}
.corehub-appbar{height:46px;background:var(--surface);border-bottom:1px solid var(--border);display:flex;align-items:center;justify-content:space-between;padding:0 14px;position:sticky;top:0;z-index:999;color:var(--text)}.corehub-appbar a{color:var(--text);text-decoration:none}.corehub-appbar .corehub-home{font-weight:800}.corehub-actions{position:relative}.corehub-actions summary{cursor:pointer;list-style:none;font-weight:700}.corehub-actions .corehub-dropdown{top:28px}
.corehub-kebab{width:36px;height:36px;display:grid;place-items:center;border:0;background:transparent;font-size:22px;padding:0}.corehub-action-menu{position:relative;display:inline-block}.corehub-action-menu>details>summary{list-style:none;cursor:pointer}.corehub-action-menu>details>summary::-webkit-details-marker{display:none}.corehub-action-list{position:absolute;right:0;top:34px;min-width:160px;background:var(--surface);border:1px solid var(--border);box-shadow:var(--shadow);padding:6px;z-index:50}.corehub-action-list button,.corehub-action-list a{display:block;width:100%;text-align:left;border:0;background:transparent;color:var(--text);padding:8px;text-decoration:none}.corehub-action-list button:hover,.corehub-action-list a:hover{background:var(--accent-soft)}
@media(max-width:650px){.corehub-wrap,.wrap{margin-top:20px}.corehub-top{padding:0 15px}.corehub-row,.row{align-items:flex-start;flex-wrap:wrap}.corehub-appgrid{grid-template-columns:1fr}}

/* CoreHub v0.3 social home */
.corehub-top-actions{display:flex;align-items:center;gap:12px}.corehub-notification-menu{position:relative}.corehub-icon-button{width:38px;height:38px;display:grid;place-items:center;cursor:pointer;list-style:none;border-radius:10px;position:relative;font-size:18px}.corehub-icon-button:hover{background:var(--accent-soft)}.corehub-icon-button::-webkit-details-marker{display:none}.corehub-badge{position:absolute;right:-4px;top:-4px;min-width:18px;height:18px;border-radius:999px;background:var(--danger);color:white;font-size:10px;font-weight:800;display:grid;place-items:center;padding:0 4px;border:2px solid var(--surface)}.corehub-notification-dropdown{width:min(390px,calc(100vw - 24px));top:45px;max-height:70vh;overflow:auto}.corehub-dropdown-title{display:flex;align-items:center;justify-content:space-between;padding:7px 9px;border-bottom:1px solid var(--border)}.corehub-dropdown-title form{margin:0}.corehub-linkbutton{padding:5px 7px!important;color:var(--accent)!important;font-size:12px}.corehub-notification{display:grid!important;gap:3px;border-bottom:1px solid var(--border);padding:10px!important;border-radius:8px!important}.corehub-notification:last-child{border-bottom:0}.corehub-notification.unread{background:var(--accent-soft)!important}.corehub-notification span,.corehub-notification small{color:var(--muted);font-size:12px}.corehub-notification strong{font-size:13px}.corehub-empty-mini{padding:18px;color:var(--muted);text-align:center}
.corehub-home-widgets{display:grid;grid-template-columns:minmax(0,.9fr) minmax(0,1.1fr);gap:18px;margin-top:24px}.corehub-widget{margin-bottom:0;min-height:360px;display:flex;flex-direction:column}.corehub-widget-head{display:flex;justify-content:space-between;gap:12px;align-items:flex-start;margin-bottom:12px}.corehub-widget-head h2{margin:0 0 4px}.corehub-widget-head p{margin:0;font-size:13px}.corehub-live-dot{width:9px;height:9px;border-radius:50%;background:var(--completed);box-shadow:0 0 0 3px color-mix(in srgb,var(--completed) 20%,transparent);margin-top:7px}
.corehub-chat-log{height:265px;overflow:auto;border:1px solid var(--border);background:color-mix(in srgb,var(--surface) 92%,var(--bg));border-radius:12px;padding:10px;display:flex;flex-direction:column;gap:8px}.corehub-chat-message{padding:7px 9px;background:var(--surface);border:1px solid var(--border);border-radius:10px}.corehub-chat-message>div{display:flex;justify-content:space-between;gap:10px;align-items:baseline}.corehub-chat-message strong{font-size:13px}.corehub-chat-message time{color:var(--muted);font-size:10px;white-space:nowrap}.corehub-chat-message p{margin:3px 0 0!important;color:var(--text)!important;font-size:13px;white-space:pre-wrap;overflow-wrap:anywhere}.corehub-chat-form{display:grid;grid-template-columns:1fr auto;gap:8px;margin-top:10px}.corehub-chat-form input{min-width:0}
.corehub-tabs{display:flex;gap:4px;padding:4px;background:var(--bg);border-radius:10px;margin-bottom:10px}.corehub-tabs a{flex:1;text-align:center;text-decoration:none;color:var(--muted);font-size:12px;font-weight:750;padding:8px 6px;border-radius:8px}.corehub-tabs a.active{background:var(--surface);color:var(--accent);box-shadow:0 1px 4px rgba(0,0,0,.08)}.corehub-privacy-toggle{display:flex;align-items:center;justify-content:space-between;gap:12px;border-bottom:1px solid var(--border);padding:2px 0 10px;margin-bottom:5px}.corehub-privacy-toggle span:first-of-type{display:grid;gap:2px}.corehub-privacy-toggle strong{font-size:12px}.corehub-privacy-toggle small{color:var(--muted);font-size:10px}.corehub-toggle{width:42px;height:24px;padding:2px;border:0;border-radius:999px;background:var(--border);flex:none}.corehub-toggle span{display:block;width:20px;height:20px;background:var(--surface);border-radius:50%;transition:.15s;box-shadow:0 1px 4px rgba(0,0,0,.2)}.corehub-toggle.on{background:var(--accent)}.corehub-toggle.on span{transform:translateX(18px)}.corehub-feed{height:260px;overflow:auto;padding-right:3px}.corehub-feed-item{padding:10px 4px;border-bottom:1px solid var(--border)}.corehub-feed-item:last-child{border-bottom:0}.corehub-feed-meta{display:flex;justify-content:space-between;gap:10px}.corehub-feed-meta strong{font-size:12px}.corehub-feed-meta time,.corehub-feed-item small{font-size:10px;color:var(--muted);white-space:nowrap}.corehub-feed-item p{margin:4px 0!important;color:var(--text)!important;font-size:13px;white-space:pre-wrap}.corehub-muted{color:var(--muted);font-size:11px}.corehub-news-compose{margin:7px 0;border:1px solid var(--border);border-radius:9px;padding:8px}.corehub-news-compose summary{cursor:pointer;color:var(--accent);font-size:12px;font-weight:750}.corehub-news-compose form{display:grid;gap:8px;margin-top:8px}.corehub-news-compose label{font-size:11px}.corehub-news-compose input,.corehub-news-compose textarea{padding:8px;font-size:12px}
body[data-theme="chicago95"] .corehub-icon-button,body[data-theme="chicago95"] .corehub-chat-log,body[data-theme="chicago95"] .corehub-chat-message,body[data-theme="chicago95"] .corehub-tabs,body[data-theme="chicago95"] .corehub-news-compose{border-radius:0}body[data-theme="chicago95"] .corehub-toggle{border-radius:0}
@media(max-width:780px){.corehub-home-widgets{grid-template-columns:1fr}.corehub-notification-dropdown{position:fixed;right:12px;top:54px}.corehub-widget{min-height:330px}.corehub-feed,.corehub-chat-log{height:230px}}

/* CoreHub v0.4 dashboard, widgets and day view */
html,body{min-height:100%;background:var(--bg)}body{min-height:100vh}.corehub-wrap{min-height:calc(100vh - 93px)}
.corehub-home-nav{display:flex;gap:6px;margin:-10px 0 24px}.corehub-home-nav a{padding:8px 13px;border-radius:999px;text-decoration:none;color:var(--muted);font-weight:750}.corehub-home-nav a.active{background:var(--accent);color:#fff}
.corehub-appgrid-v4{align-items:start}.corehub-appcard-v4{position:relative;background:var(--surface);border:1px solid var(--border);border-radius:16px;box-shadow:var(--shadow);min-height:132px;overflow:hidden}.corehub-appcard-v4.dragging{opacity:.45}.corehub-appcard-tools{height:34px;display:flex;align-items:center;justify-content:space-between;padding:5px 9px;border-bottom:1px solid var(--border);background:color-mix(in srgb,var(--surface) 88%,var(--bg))}.corehub-drag{border:0;background:transparent;padding:2px 7px;color:var(--muted);cursor:grab;font-size:18px}.corehub-appcard-main{display:flex;gap:14px;align-items:center;padding:16px;text-decoration:none;color:inherit}.corehub-appcard-main:hover{background:color-mix(in srgb,var(--accent-soft) 28%,transparent)}.corehub-appcard-copy{min-width:0}.corehub-appcard-copy h2{margin:0 0 4px;font-size:19px}.corehub-appcard-copy p{margin:0;color:var(--text);font-size:14px;font-weight:700}.corehub-appcard-copy small{display:block;color:var(--muted);margin-top:4px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.corehub-widget-switch{display:flex;grid-template-columns:none;align-items:center;gap:7px;font-size:11px;color:var(--muted);font-weight:750}.corehub-widget-switch input{position:absolute;opacity:0;pointer-events:none}.corehub-widget-switch i{width:31px;height:18px;border-radius:999px;background:var(--border);position:relative}.corehub-widget-switch i:after{content:"";position:absolute;width:14px;height:14px;left:2px;top:2px;border-radius:50%;background:var(--surface);box-shadow:0 1px 3px rgba(0,0,0,.2);transition:.15s}.corehub-widget-switch input:checked+i{background:var(--accent)}.corehub-widget-switch input:checked+i:after{transform:translateX(13px)}.corehub-appcard-v4.is-widget{grid-column:span 2}.corehub-app-widget{border-top:1px solid var(--border);height:280px;background:var(--bg)}.corehub-app-widget iframe{display:block;width:100%;height:100%;border:0;background:transparent}
.corehub-day-head{display:flex;justify-content:space-between;gap:20px;align-items:flex-end;margin-bottom:22px}.corehub-day-head h1{margin:0 0 5px}.corehub-day-head p{margin:0;color:var(--muted)}.corehub-day-controls{display:flex;gap:7px;align-items:center}.corehub-day-controls form{display:flex;gap:7px}.corehub-day-step{display:grid;place-items:center;width:39px;height:39px;border:1px solid var(--border);border-radius:9px;text-decoration:none;color:var(--text);background:var(--surface)}.corehub-day-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(330px,1fr));gap:18px}.corehub-day-group{margin:0}.corehub-day-apphead{display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid var(--border);padding-bottom:10px;margin-bottom:3px}.corehub-day-apphead h2{margin:0}.corehub-day-apphead a{font-size:12px;color:var(--accent);text-decoration:none}.corehub-day-event{display:grid;grid-template-columns:76px 1fr;gap:12px;padding:12px 0;border-bottom:1px solid var(--border)}.corehub-day-event:last-child{border-bottom:0}.corehub-day-event p{margin:4px 0!important;color:var(--muted)!important;font-size:13px}.corehub-day-event small{color:var(--muted)}.corehub-day-kind{text-transform:uppercase;font-size:10px;letter-spacing:.06em;font-weight:800;color:var(--accent);padding-top:3px}
body[data-theme="chicago95"] .corehub-appcard-v4,body[data-theme="chicago95"] .corehub-home-nav a,body[data-theme="chicago95"] .corehub-day-step{border-radius:0}
@media(max-width:780px){.corehub-appcard-v4.is-widget{grid-column:span 1}.corehub-day-head{align-items:stretch;flex-direction:column}.corehub-day-controls{flex-wrap:wrap}.corehub-day-controls form{flex:1}.corehub-day-controls input{min-width:0;flex:1}.corehub-day-grid{grid-template-columns:1fr}}
/* CoreHub v0.5 chat, profiles and dense dashboard */
.corehub-appgrid-v4{grid-auto-flow:dense}.corehub-account-summary{display:flex!important;align-items:center;gap:7px}.corehub-avatar{width:40px;height:40px;border-radius:50%;object-fit:cover;display:inline-grid;place-items:center;flex:none;border:1px solid var(--border);background:var(--accent-soft)}.corehub-avatar.tiny{width:24px;height:24px;font-size:11px}.corehub-avatar.profile{width:86px;height:86px;font-size:28px}.corehub-avatar.fallback{font-weight:850;color:var(--accent)}.corehub-profile-photo-row{display:flex;gap:16px;align-items:center;flex-wrap:wrap;margin-bottom:18px}.corehub-profile-photo-row form{display:flex;gap:8px;align-items:end;flex-wrap:wrap}.corehub-profile-photo-row label{display:grid;gap:5px}
.corehub-chat-room{display:grid;grid-template-columns:240px minmax(0,1fr);gap:18px;min-height:calc(100vh - 160px)}.corehub-chat-sidebar,.corehub-chat-main{margin:0}.corehub-chat-sidebar h2{margin-top:0}.corehub-chat-sidebar h3{font-size:12px;text-transform:uppercase;letter-spacing:.06em;color:var(--muted);margin:18px 7px 7px}.corehub-chat-nav{display:flex;align-items:center;gap:7px;padding:8px 9px;border-radius:9px;text-decoration:none;color:var(--text);margin:2px 0}.corehub-chat-nav:hover,.corehub-chat-nav.active{background:var(--accent-soft);color:var(--accent)}.corehub-stack{display:grid;gap:7px;margin-top:8px}.corehub-chat-main{display:flex;flex-direction:column;min-width:0;padding:0;overflow:hidden}.corehub-chat-room-head{padding:16px 20px;border-bottom:1px solid var(--border)}.corehub-chat-room-head h1{font-size:20px;margin:0}.corehub-chat-room-head p{margin:3px 0 0;color:var(--muted);font-size:12px}.corehub-chat-thread{flex:1;overflow:auto;min-height:360px;max-height:65vh;padding:12px 18px}.corehub-chat-rich-message{display:grid;grid-template-columns:42px 1fr;gap:10px;padding:8px 4px}.corehub-chat-rich-message:hover{background:color-mix(in srgb,var(--accent-soft) 25%,transparent)}.corehub-chat-meta{display:flex;gap:7px;align-items:baseline;flex-wrap:wrap}.corehub-chat-meta span,.corehub-chat-meta time{color:var(--muted);font-size:10px}.corehub-chat-text{white-space:pre-wrap;overflow-wrap:anywhere;line-height:1.45}.corehub-chat-image{display:block;max-width:min(520px,100%);max-height:360px;border-radius:12px;margin-top:7px;border:1px solid var(--border)}.corehub-chat-composer{padding:12px;border-top:1px solid var(--border);display:grid;gap:8px}.corehub-chat-composer textarea{resize:vertical;min-height:54px}.corehub-chat-compose-tools{display:flex;gap:8px;align-items:center;justify-content:flex-end}.corehub-file-button{margin-right:auto;cursor:pointer;padding:7px 10px;border:1px solid var(--border);border-radius:8px}.corehub-file-button input{display:none}.corehub-emoji-picker{position:relative}.corehub-emoji-picker summary{cursor:pointer;padding:7px 10px}.corehub-emoji-picker>div{position:absolute;right:0;bottom:36px;display:flex;flex-wrap:wrap;width:230px;padding:8px;background:var(--surface);border:1px solid var(--border);border-radius:10px;box-shadow:var(--shadow);z-index:10}.corehub-emoji-picker button{width:38px;height:38px;padding:4px;border:0;background:transparent;font-size:20px}.corehub-emoji-picker img,.corehub-inline-emoji{width:22px;height:22px;object-fit:contain;vertical-align:middle}.corehub-emoji-admin{display:flex;gap:10px;flex-wrap:wrap;margin-top:14px}.corehub-emoji-admin>div{display:flex;align-items:center;gap:8px;border:1px solid var(--border);padding:8px;border-radius:10px}.corehub-emoji-admin img{width:32px;height:32px;object-fit:contain}.corehub-inline-badge{background:var(--danger);color:white;border-radius:999px;padding:1px 6px;font-size:10px}
@media(max-width:760px){.corehub-chat-room{grid-template-columns:1fr}.corehub-chat-sidebar{max-height:230px;overflow:auto}.corehub-chat-thread{max-height:58vh}}
.corehub-chat-header-link{color:inherit;text-decoration:none}.corehub-chat-header-link:hover{color:var(--accent)}.corehub-chat-mini-bell{font-size:14px;text-decoration:none;vertical-align:middle}.corehub-chat-widget-tools{display:flex;gap:8px;align-items:center}.corehub-chat-widget-tools select{font-size:11px;padding:5px 7px;width:auto;max-width:150px}
