/* ============ Calculator ============ */
.calc{display:flex;flex-direction:column;flex:1;min-height:0;background:var(--card)}
.calc-head{display:flex;align-items:center;gap:8px;padding:8px 10px;border-bottom:1px solid var(--border)}
.calc-mode{
  width:32px;height:32px;border-radius:50%;display:flex;align-items:center;justify-content:center;
  color:var(--text-2);font-size:16px;flex:none;
}
.calc-mode:hover{background:var(--row-hover)}
.calc-display{
  flex:1;text-align:right;font-size:30px;font-weight:300;padding:4px 8px;
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-variant-numeric:tabular-nums;
}
.calc-keys{flex:1;display:flex;flex-direction:column;padding:8px;gap:6px;min-height:0}
.calc-adv-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:6px}
.calc-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:6px;flex:1}
.calc-key{
  border-radius:10px;font-size:17px;display:flex;align-items:center;justify-content:center;
  background:var(--card-alt);color:var(--text);transition:background .1s;
}
.calc-key:hover{background:var(--row-hover)}
.calc-key:active{background:var(--sel-strong)}
.calc-key.d{font-weight:500}
.calc-key.eq{background:var(--accent);color:#fff;font-weight:700}
.calc-key.eq:hover{background:var(--accent-hover)}
.calc-key.div,.calc-key.mul,.calc-key.sub,.calc-key.add{color:var(--accent);font-weight:700}
.calc-key.adv{font-size:13.5px;color:var(--text-2)}
.calc-key.ce,.calc-key.c,.calc-key.bs,.calc-key.pct{color:var(--muted)}

/* ============ Browser ============ */
.browser{display:flex;flex-direction:column;flex:1;min-height:0;background:var(--card)}
.br-tabstrip{
  display:flex;align-items:flex-end;gap:0;padding:6px 8px 0;background:var(--hb-focus);
  min-height:38px;overflow-x:auto;
}
.win:not(.focused) .br-tabstrip{background:var(--hb-inactive)}
.win.private .br-tabstrip{background:#2b1e3f}
.br-tab{
  display:flex;align-items:center;gap:7px;padding:7px 10px;border-radius:9px 9px 0 0;
  font-size:13px;max-width:190px;min-width:0;cursor:default;color:var(--text-2);
  border:1px solid transparent;border-bottom:none;position:relative;
}
.br-tab:hover{background:var(--row-hover)}
.br-tab.active{background:var(--card);color:var(--text);border-color:var(--border)}
.br-tab-ic{width:14px;height:14px;flex:none;color:var(--muted)}
.br-tab-ic svg{width:14px;height:14px}
.br-tab-spinner{width:13px;height:13px;flex:none;color:var(--accent);display:flex}
.br-tab-spinner svg{width:13px;height:13px;animation:spin 1s linear infinite}
.br-tab-title{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.br-tab-x{
  width:18px;height:18px;border-radius:50%;display:flex;align-items:center;justify-content:center;
  color:var(--muted);flex:none;opacity:0;
}
.br-tab:hover .br-tab-x,.br-tab.active .br-tab-x{opacity:1}
.br-tab-x:hover{background:var(--row-hover)}
.br-tab-x svg{width:11px;height:11px}
.br-tab-plus{
  width:30px;height:30px;border-radius:50%;display:flex;align-items:center;justify-content:center;
  color:var(--muted);flex:none;margin:0 4px 4px;
}
.br-tab-plus:hover{background:var(--row-hover)}
.br-tab-plus svg{width:14px;height:14px}
.br-toolbar{
  display:flex;align-items:center;gap:4px;padding:5px 8px;background:var(--hb-focus);
  border-top:1px solid var(--border);
}
.win:not(.focused) .br-toolbar{background:var(--hb-inactive)}
.win.private .br-toolbar{background:#2b1e3f}
.br-urlbar{
  flex:1;display:flex;align-items:center;gap:8px;background:var(--input-bg);
  border:1px solid var(--input-border);border-radius:18px;height:32px;padding:0 12px;margin:0 6px;
}
.br-urlbar:focus-within{border-color:var(--accent);box-shadow:0 0 0 2px color-mix(in srgb, var(--accent) 40%, transparent)}
.br-lock{width:14px;height:14px;color:var(--muted);flex:none}
.br-lock svg{width:14px;height:14px}
.br-url{flex:1;background:transparent;border:none;outline:none;color:var(--text);font-size:13.5px;padding:0}
.br-star.off{opacity:.45}
.br-content{flex:1;min-height:0;overflow:auto;background:var(--bg)}
.br-page{min-height:100%}

/* start page */
.start-page{display:flex;flex-direction:column;align-items:center;padding:70px 40px 40px;gap:44px}
.sp-hero{display:flex;flex-direction:column;align-items:center;gap:18px}
.sp-art{width:84px;height:84px;opacity:.95}
.sp-art svg{width:84px;height:84px}
.sp-title{font-size:21px;font-weight:300;color:var(--text)}
.sp-search{
  width:520px;max-width:80vw;height:46px;border-radius:23px;background:var(--card);
  border:1px solid var(--border);box-shadow:0 2px 10px rgba(0,0,0,.12);
  display:flex;align-items:center;padding:0 18px;
}
.sp-input{flex:1;background:transparent;border:none;outline:none;color:var(--text);font-size:15px}
.sp-tiles{display:flex;gap:28px;flex-wrap:wrap;justify-content:center}
.sp-tile{display:flex;flex-direction:column;align-items:center;gap:8px;width:88px;cursor:default;border-radius:10px;padding:10px 4px}
.sp-tile:hover{background:var(--row-hover)}
.sp-tile-ic{width:38px;height:38px}
.sp-tile-ic svg{width:38px;height:38px}
.sp-tile-name{font-size:12.5px;color:var(--text-2);text-align:center;max-width:84px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}

/* search results page */
.srch-page{padding:26px 40px 40px;max-width:720px}
.srch-head{display:flex;align-items:baseline;gap:18px;margin-bottom:22px}
.srch-logo{font-size:20px;font-weight:700;color:var(--accent)}
.srch-count{font-size:13px;color:var(--muted)}
.srch-res{margin-bottom:24px;cursor:default;border-radius:8px;padding:4px 8px;margin-left:-8px}
.srch-res:hover{background:var(--row-hover)}
.srch-res-url{font-size:12.5px;color:var(--success)}
.srch-res-title{font-size:18px;color:#1a5fb4;font-weight:500;margin:2px 0}
#desktop.theme-dark .srch-res-title{color:#78aeed}
.srch-res-desc{font-size:13.5px;color:var(--text-2);line-height:1.45}

/* error / offline */
.err-page{padding:90px 40px;text-align:center;max-width:640px;margin:0 auto}
.err-big{font-size:20px;font-weight:700;margin-bottom:14px}
.err-mid{font-size:15px;color:var(--text-2);margin-bottom:20px}
.err-small{font-size:13.5px;color:var(--text-2);margin-bottom:6px}
.err-list{list-style:disc;text-align:left;font-size:13.5px;color:var(--text-2);margin:0 auto 24px;max-width:420px;padding-left:22px}
.err-list li{margin:4px 0}
.err-page .btn{margin-top:6px}

/* ubuntu page */
.ubu-page{min-height:100%}
.ubu-nav{display:flex;align-items:center;gap:22px;background:#2c001e;color:#fff;padding:12px 30px}
.ubu-logo{width:24px;height:24px}
.ubu-logo svg{width:24px;height:24px}
.ubu-logo-t{font-size:16px;font-weight:700}
.ubu-link{font-size:14px;color:#ddd;cursor:default;text-decoration:none;padding:4px 2px}
.ubu-link:hover{color:#fff;text-decoration:underline}
.ubu-hero{
  background:linear-gradient(120deg,#2c001e 0%,#5e2750 60%,#772953 100%);color:#fff;
  padding:70px 50px 80px;
}
.ubu-hero-title{font-size:40px;font-weight:300;margin-bottom:10px}
.ubu-hero-sub{font-size:17px;opacity:.9;max-width:560px;margin-bottom:26px}
.ubu-cards{display:flex;gap:20px;padding:36px 50px;flex-wrap:wrap}
.ubu-card{flex:1;min-width:200px;background:var(--card);border:1px solid var(--border);border-radius:12px;padding:22px}
.ubu-card-t{font-size:18px;font-weight:500;margin-bottom:6px}
.ubu-card-d{font-size:14px;color:var(--text-2)}

/* wiki */
.wiki-page{padding:40px 56px;max-width:760px}
.wiki-title{font-size:28px;font-weight:400;border-bottom:1px solid var(--border);padding-bottom:6px;margin-bottom:4px}
.wiki-meta{font-size:13px;color:var(--muted);margin-bottom:20px}
.wiki-page p{font-size:14.5px;line-height:1.6;margin-bottom:14px}

/* example */
.example-page{padding:60px 40px;max-width:620px;margin:0 auto;text-align:center}
.example-page h1{font-size:26px;font-weight:500;margin-bottom:16px}
.example-page p{font-size:14.5px;line-height:1.6;color:var(--text-2);margin-bottom:12px}
.example-more{color:var(--info)!important;cursor:default}

/* vfs plain text */
.br-plain{padding:20px;font-family:var(--font-mono);font-size:13.5px;white-space:pre-wrap;background:var(--card)}

/* ============ Store ============ */
.store{display:flex;flex-direction:column;flex:1;min-height:0;overflow-y:auto;padding:16px 22px 30px}
.store-hb{display:flex;align-items:center;gap:4px;flex:1;margin-left:8px;min-width:0}
.store-search{
  display:flex;align-items:center;gap:8px;background:var(--input-bg);border:1px solid var(--input-border);
  border-radius:16px;height:30px;padding:0 10px;width:200px;
}
.store-search:focus-within{border-color:var(--accent)}
.ss-ic{width:14px;height:14px;color:var(--muted);flex:none}
.ss-ic svg{width:14px;height:14px}
.ss-input{flex:1;background:transparent;border:none;outline:none;font-size:13px;color:var(--text);min-width:0}
.store-updates.has{color:var(--accent);position:relative}
.store-updates.has::after{content:"";position:absolute;top:5px;right:5px;width:7px;height:7px;border-radius:50%;background:var(--accent)}
.store-offline{display:flex;flex-direction:column;align-items:center;gap:12px;padding:70px 20px;text-align:center}
.store-off-ic{width:54px;height:54px;color:var(--muted)}
.store-off-ic svg{width:54px;height:54px}
.store-off-t{font-size:20px;font-weight:700}
.store-off-s{font-size:14px;color:var(--muted)}
.store-chips{display:flex;gap:8px;margin-bottom:16px;flex-wrap:wrap}
.store-chip{
  padding:5px 14px;border-radius:16px;font-size:13.5px;background:var(--card-alt);
  border:1px solid var(--border);
}
.store-chip:hover{background:var(--row-hover)}
.store-chip.sel{background:var(--sel-strong);border-color:var(--accent);font-weight:500}
.store-feat{
  display:flex;align-items:center;gap:22px;border-radius:16px;padding:24px 28px;margin-bottom:22px;
  background:linear-gradient(120deg,#2c001e,#5e2750 70%,#772953);color:#fff;
}
.store-feat-ic{width:84px;height:84px;flex:none;filter:drop-shadow(0 4px 10px rgba(0,0,0,.4))}
.store-feat-ic svg{width:84px;height:84px}
.store-feat-t{flex:1;min-width:0}
.store-feat-kicker{font-size:12px;text-transform:uppercase;letter-spacing:.06em;opacity:.75;margin-bottom:4px}
.store-feat-name{font-size:26px;font-weight:700;margin-bottom:6px}
.store-feat-d{font-size:14px;opacity:.9;max-width:520px;margin-bottom:14px}
.store-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(190px,1fr));gap:14px}
.store-card{
  background:var(--card);border:1px solid var(--border);border-radius:14px;padding:16px 14px;
  display:flex;flex-direction:column;gap:6px;cursor:default;
}
.store-card:hover{box-shadow:0 3px 12px rgba(0,0,0,.14)}
.store-card-ic{width:56px;height:56px}
.store-card-ic svg{width:56px;height:56px}
.store-card-name{font-size:15px;font-weight:700;margin-top:4px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.store-card-pub{font-size:12.5px;color:var(--muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.store-stars{display:flex;gap:2px}
.ss-star{width:13px;height:13px;color:var(--faint)}
.ss-star svg{width:13px;height:13px}
.ss-star.on{color:#f5a623}
.store-card-size{font-size:12px;color:var(--muted)}
.store-btn{margin-top:6px}
.store-app-top{display:flex;align-items:center;gap:14px;margin-bottom:12px}
.store-app-ic{width:72px;height:72px}
.store-app-ic svg{width:72px;height:72px}
.store-app-title{font-size:24px;font-weight:700}
.store-app-pub{font-size:13.5px;color:var(--muted);margin-bottom:16px}
.store-app-desc{font-size:14.5px;line-height:1.55;max-width:640px;margin-bottom:22px}
.store-upd-list{margin:10px 0 16px;max-width:640px}
.store-upd-row{
  display:flex;align-items:center;gap:14px;padding:12px 14px;background:var(--card);
  border:1px solid var(--border);border-radius:12px;margin-bottom:8px;
}
.store-upd-row.done{opacity:.65}
.store-upd-main{flex:1;min-width:0}
.store-upd-name{font-size:14.5px;font-weight:500}
.store-upd-sub{font-size:12.5px;color:var(--muted)}
.store-upd-all{margin-top:6px}
.store-empty{padding:50px;text-align:center}
.store-empty-t{font-size:18px;font-weight:700;margin-bottom:6px}
.store-empty-s{font-size:14px;color:var(--muted)}

/* ============ Clocks ============ */
.clocks{display:flex;flex-direction:column;flex:1;min-height:0}
.cl-tabs{display:flex;gap:4px;padding:8px 12px;border-bottom:1px solid var(--border);flex:none}
.cl-tab{
  display:flex;align-items:center;gap:7px;padding:7px 14px;border-radius:8px;font-size:14px;color:var(--text-2);
}
.cl-tab:hover{background:var(--row-hover)}
.cl-tab.sel{background:var(--sel-strong);color:var(--text);font-weight:500}
.cl-tab-ic{width:15px;height:15px}
.cl-tab-ic svg{width:15px;height:15px}
.cl-content{flex:1;overflow-y:auto;padding:18px 24px}
.cl-hero{text-align:center;padding:26px 0 10px}
.cl-big{font-size:64px;font-weight:300;letter-spacing:1px;font-variant-numeric:tabular-nums}
.cl-date{font-size:16px;color:var(--muted);margin-top:2px}
.cl-city-list{margin:22px auto 0;max-width:480px}
.cl-city{display:flex;align-items:center;justify-content:space-between;padding:12px 16px;border-bottom:1px solid var(--border)}
.cl-city-name{font-size:15px}
.cl-city-sub{font-size:12.5px;color:var(--muted)}
.cl-city-time{font-size:22px;font-weight:300;font-variant-numeric:tabular-nums}
.cl-timer{display:flex;flex-direction:column;align-items:center;gap:24px;padding-top:16px}
.cl-timer-face{position:relative;width:220px;height:220px}
.cl-ring{width:220px;height:220px}
.cl-ring-bg{fill:none;stroke:var(--track);stroke-width:10}
.cl-ring-fg{fill:none;stroke:var(--accent);stroke-width:10;stroke-linecap:round;transform:rotate(-90deg);transform-origin:center;transition:stroke-dashoffset .3s linear}
.cl-timer-time{
  position:absolute;inset:0;display:flex;align-items:center;justify-content:center;
  font-size:38px;font-weight:300;font-variant-numeric:tabular-nums;
}
.cl-sw-time{font-size:34px}
.cl-set{display:flex;gap:8px;flex-wrap:wrap;justify-content:center}
.cl-controls{display:flex;gap:8px}
.cl-laps{width:300px;margin-top:4px}
.cl-lap{display:flex;justify-content:space-between;padding:8px 12px;border-bottom:1px solid var(--border);font-size:14px}
.cl-alarms{max-width:560px;margin:0 auto}
.cl-alarm{
  display:flex;align-items:center;gap:14px;padding:12px 16px;background:var(--card);
  border:1px solid var(--border);border-radius:12px;margin-bottom:8px;
}
.cl-alarm.off .cl-alarm-time,.cl-alarm.off .cl-alarm-sub{opacity:.4}
.cl-alarm-time{font-size:30px;font-weight:300;flex:1}
.cl-alarm-sub{font-size:13px;color:var(--muted)}
.cl-add-row{margin-top:14px;text-align:center}
.cl-empty{padding:50px;text-align:center}
.cl-empty-t{font-size:18px;font-weight:700}
.cl-empty-s{font-size:14px;color:var(--muted)}
.cl-alarm-form{display:flex;gap:14px;min-width:280px}
.cl-alarm-form label{display:flex;flex-direction:column;gap:6px;font-size:13px;color:var(--muted);flex:1}
.cl-alarm-form input{width:100%}

/* ============ Image Viewer ============ */
.viewer{display:flex;flex-direction:column;flex:1;min-height:0}
.vw-hb{display:flex;align-items:center;flex:1;margin-left:6px}
.vw-stage{
  flex:1;min-height:0;display:flex;align-items:center;justify-content:center;
  background:
    repeating-conic-gradient(rgba(128,128,128,.08) 0% 25%, transparent 0% 50%) 0 0/24px 24px,
    var(--bg-deep);
  overflow:hidden;position:relative;
}
.vw-img-wrap{max-width:94%;max-height:94%;transition:transform .15s ease;transform-origin:center}
.vw-img{pointer-events:none}
.vw-img svg{width:auto;height:auto;max-width:92vw;max-height:78vh}
.vw-status{border-top:1px solid var(--border);padding:4px 12px;font-size:12.5px;color:var(--muted)}
.vw-empty{padding:60px;color:var(--muted)}
.vw-info{display:flex;flex-direction:column;gap:4px;font-size:14px;min-width:280px}

/* ============ System Monitor ============ */
.monitor{display:flex;flex-direction:column;flex:1;min-height:0}
.mn-tabs{display:flex;gap:2px;padding:6px 10px;border-bottom:1px solid var(--border);flex:none}
.mn-tab{padding:6px 14px;border-radius:8px;font-size:13.5px;color:var(--text-2)}
.mn-tab:hover{background:var(--row-hover)}
.mn-tab.sel{background:var(--sel-strong);color:var(--text);font-weight:500}
.mn-content{flex:1;overflow-y:auto;padding:12px 16px}
.mn-table{max-width:900px}
.mn-row{display:flex;align-items:center;border-radius:6px;min-height:32px;padding:0 10px;cursor:default}
.mn-row:not(.mn-head):hover{background:var(--row-hover)}
.mn-row.sel{background:var(--sel)}
.mn-head .mn-cell{font-size:12px;color:var(--faint);font-weight:500;padding:4px 10px;border-radius:4px}
.mn-cell{font-size:13.5px;padding:2px 10px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;flex:0 0 110px}
.mn-name{font-weight:500}
.mn-cpu{color:var(--text-2)}
.mn-foot{display:flex;justify-content:flex-end;margin-top:12px;max-width:900px}
.mn-res{display:grid;grid-template-columns:repeat(auto-fit,minmax(320px,1fr));gap:14px}
.mn-card{background:var(--card);border:1px solid var(--border);border-radius:12px;padding:12px}
.mn-card-t{font-size:13px;font-weight:700;margin-bottom:8px}
.mn-graph{width:100%;height:150px;display:block}
.mn-res-info{display:flex;gap:26px;margin-top:16px;font-size:13.5px;color:var(--text-2);flex-wrap:wrap}

/* ============ Help ============ */
.help{display:flex;flex:1;min-height:0}
.hp-hb{display:flex;align-items:center;flex:1;margin-left:6px}
.hp-sidebar{
  width:200px;flex:none;background:var(--sidebar-bg);border-right:1px solid var(--border);
  padding:8px 6px;overflow-y:auto;
}
.hp-nav{padding:7px 12px;border-radius:7px;font-size:13.5px;cursor:default}
.hp-nav:hover{background:var(--row-hover)}
.hp-nav.sel{background:var(--sel-strong);font-weight:500}
.hp-content{flex:1;overflow-y:auto;padding:26px 34px 50px;max-width:720px}
.hp-content h1{font-size:24px;font-weight:700;margin:0 0 14px}
.hp-content h2{font-size:17px;font-weight:700;margin:24px 0 8px}
.hp-content p{font-size:14px;line-height:1.6;margin-bottom:10px}
.hp-content ul{margin:4px 0 12px;padding-left:22px}
.hp-content li{font-size:14px;line-height:1.55;margin:4px 0}
.hp-content ul.mono li{font-family:var(--font-mono);font-size:13.5px}
.hp-kbd{
  display:inline-block;padding:1px 7px;border-radius:5px;border:1px solid var(--border-strong);
  background:var(--card-alt);font-size:12.5px;font-family:var(--font-ui);box-shadow:0 1px 0 var(--border-strong);
}
