:root { color-scheme: dark; --bg:#111614; --panel:#1a211d; --border:#303a32; --text:#edf0e9; --muted:#a7b2a8; --accent:#c4df97; font-family:system-ui,-apple-system,"Segoe UI",sans-serif; }
* { box-sizing:border-box; }
body { margin:0; background:var(--bg); color:var(--text); font-size:14px; line-height:1.5; }
button,input { font:inherit; color:inherit; }
button,a { -webkit-tap-highlight-color:transparent; }
button { cursor:pointer; }
button:disabled { cursor:default; opacity:.6; }
a { color:inherit; text-decoration:none; }
h1,h2,h3,p { margin:0; }
[hidden] { display:none!important; }
:focus-visible { outline:2px solid var(--accent); outline-offset:4px; }
.icon { width:23px; height:23px; flex-shrink:0; fill:none; stroke:currentColor; stroke-width:1.65; stroke-linecap:round; stroke-linejoin:round; }
.svg-defs { position:absolute; width:0; height:0; overflow:hidden; }
.sr-only { position:absolute; width:1px; height:1px; padding:0; margin:-1px; clip:rect(0,0,0,0); overflow:hidden; white-space:nowrap; border:0; }
.skip-link { position:fixed; top:-80px; left:15px; padding:12px; background:var(--accent); color:var(--bg); z-index:200; }
.skip-link:focus { top:10px; }
main { max-width:1180px; margin:auto; padding:0 32px 20px; }
main:focus { outline:none; }
.topbar { height:96px; display:flex; align-items:center; justify-content:space-between; gap:20px; border-bottom:1px solid var(--border); margin-bottom:28px; }
.brand { display:flex; align-items:center; gap:13px; }
.brand .icon { color:var(--accent); }
h1 { font-size:24px; letter-spacing:-.7px; font-weight:650; }
h1 span { color:var(--muted); font-size:13px; font-weight:400; letter-spacing:0; margin-left:9px; }
h2 { font-size:15px; font-weight:550; margin-bottom:13px; }
h3 { font-size:13px; font-weight:550; }
.live-state { display:flex; align-items:center; gap:8px; color:var(--accent); font-size:12px; white-space:nowrap; }
.live-dot,.status-dot { display:inline-block; width:7px; height:7px; flex:0 0 7px; border-radius:50%; background:currentColor; }
.live-state.error { color:#e9a39b; }
.live-state.pending { color:var(--muted); }
.services-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px; }
.service-card { display:flex; align-items:center; gap:15px; min-width:0; min-height:80px; padding:20px; background:var(--panel); border:1px solid var(--border); border-radius:10px; text-align:left; font-weight:550; transition:background 150ms,border-color 150ms; }
.service-card:hover { background:#263023; border-color:#657653; }
.service-card .icon { color:var(--accent); }
.files .icon { color:#e3c18a; }.gaming .icon { color:#b7bce2; }.videos .icon { color:#9dc6d4; }.torrents .icon { color:#ceabd9; }
.arrow { color:var(--muted); margin-left:auto; font-size:15px; }
.activity-section { margin-top:28px; }
.metrics-grid,.lower-grid { display:grid; grid-template-columns:1fr 1fr 1.4fr; gap:12px; }
.lower-grid { margin-top:12px; }
.metric-card,.panel { padding:20px; min-width:0; border:1px solid var(--border); border-radius:10px; background:var(--panel); }
.metric-value { font-size:28px; font-weight:550; letter-spacing:-.6px; line-height:1.3; margin-top:12px; font-variant-numeric:tabular-nums; }
.metric-detail { color:var(--muted); font-size:11px; margin:6px 0 12px; min-height:17px; }
.meter { height:4px; border-radius:5px; overflow:hidden; background:#333d32; }
.meter span { display:block; height:100%; width:0; background:var(--accent); transition:width 400ms; }
.ram { --accent:#b7bce2; }.ssd { --accent:#9fcbb7; }.hdd { --accent:#e3c18a; }
.panel-heading { display:flex; justify-content:space-between; align-items:center; gap:12px; }
.muted { color:var(--muted); font-size:11px; }
.network-values { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:16px; margin-top:22px; }
.network-values > div { min-width:0; }
.network-values > div+div { padding-left:16px; border-left:1px solid var(--border); }
.rate-label { display:block; color:var(--muted); font-size:11px; margin-bottom:7px; }
.network-values strong { display:block; font-size:18px; font-weight:550; font-variant-numeric:tabular-nums; white-space:nowrap; }
.disk { margin-top:17px; }
.disk-heading { display:flex; justify-content:space-between; align-items:center; gap:10px; margin-bottom:8px; font-size:12px; font-variant-numeric:tabular-nums; }
.disk-heading strong { font-weight:500; }
.disk .metric-detail { margin:5px 0 0; }
.status-summary { display:flex; align-items:flex-start; gap:10px; margin-top:24px; }
.status-summary strong { font-size:13px; font-weight:550; }
.status-summary .muted { display:block; margin-top:6px; }
.status-dot { color:#88948d; margin-top:7px; }
.status-dot.online,.status-dot.complete { color:#b4d98c; }.status-dot.offline { color:#d99186; }.status-dot.busy { color:#e8c061; }
.panel-link { color:var(--muted); padding:3px 8px; font-size:17px; }
.game-servers { margin-top:9px; }
.game-server { display:flex; align-items:center; gap:10px; padding:10px 0; }
.game-server .status-dot { margin-top:0; }
.game-server-main { min-width:0; flex:1; }
.game-server strong { display:block; font-size:13px; font-weight:550; overflow-wrap:anywhere; }
.game-meta { display:block; font-size:11px; color:var(--muted); margin-top:2px; }
.game-player-count { font-size:12px; font-variant-numeric:tabular-nums; white-space:nowrap; }
footer { margin-top:16px; color:var(--muted); font-size:11px; text-align:right; }
body.modal-open { overflow:hidden; }
.video-modal { position:fixed; z-index:100; inset:0; display:grid; place-items:center; padding:24px; background:#080d0bea; backdrop-filter:blur(5px); }
.video-dialog { display:flex; flex-direction:column; width:min(1160px,100%); max-height:calc(100dvh - 48px); background:var(--panel); border:1px solid #42503e; border-radius:14px; overflow:hidden; }
.video-dialog-header { display:flex; align-items:flex-start; justify-content:space-between; gap:20px; padding:25px; }
.video-dialog-header h2 { font-size:24px; margin-bottom:7px; }
.video-dialog-header p { color:var(--muted); font-size:12px; }
.dialog-close { width:40px; height:40px; flex:0 0 40px; background:#263024; border:1px solid var(--border); border-radius:7px; font-size:24px; }
.video-toolbar { display:flex; align-items:center; justify-content:space-between; gap:16px; padding:13px 25px; border-block:1px solid var(--border); }
.video-toolbar p { color:var(--muted); font-size:12px; }
.video-refresh,.convert-button { background:#2b3923; border:1px solid #4a5e38; color:#d8edb9; border-radius:6px; padding:9px 12px; min-height:38px; font-size:12px; }
.search-box { display:flex; align-items:center; gap:10px; padding:9px 12px; border:1px solid var(--border); border-radius:7px; }
.search-box input { min-width:0; width:100%; border:0; background:transparent; outline:none; }
.search-box:focus-within { border-color:var(--accent); }
.search-box .icon { width:18px; height:18px; color:var(--muted); }
.video-search { margin:15px 25px; flex-shrink:0; }
.video-table-wrap { overflow:auto; overscroll-behavior:contain; min-height:0; }
.video-table { width:100%; border-collapse:collapse; font-size:12px; }
.video-table th,.video-table td { padding:17px 20px; text-align:left; border-bottom:1px solid var(--border); vertical-align:middle; }
.video-table th { position:sticky; top:0; z-index:1; background:#252e25; font-size:11px; font-weight:550; color:var(--muted); }
.video-name { display:block; min-width:130px; max-width:340px; overflow-wrap:anywhere; font-weight:550; }
.video-path,.format-detail,.risk-detail,.job-detail { display:block; margin-top:5px; color:var(--muted); font-size:11px; overflow-wrap:anywhere; }
.compatibility-badge { display:inline-flex; padding:5px 8px; border-radius:5px; font-size:11px; }
.compatibility-badge.compatible { color:#c5dea9; background:#304025; }.compatibility-badge.risk { color:#e4ca92; background:#403727; }
.job-progress { width:125px; height:4px; margin-top:8px; overflow:hidden; background:#3b4435; border-radius:4px; }
.job-progress span { display:block; height:100%; background:var(--accent); }
.video-empty { padding:30px!important; text-align:center!important; color:var(--muted); }
@media(max-width:960px) {
  .metrics-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }.network { grid-column:1/-1; }
  .lower-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }.games-panel { grid-column:1/-1; }
  .network-values strong { font-size:22px; }.network-values { margin-top:12px; }
}
@media(max-width:600px) {
  main { padding:0 16px 20px; }.topbar { height:80px; margin-bottom:21px; }h1 { font-size:22px; }h1 span { display:none; }
  .services-grid { grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; }.service-card { padding:15px 12px; gap:10px; min-height:71px; font-size:12px; }.service-card .icon { width:20px; height:20px; }.arrow { display:none; }
  .metrics-grid,.lower-grid { gap:10px; }.metric-card,.panel { padding:16px; }.metric-detail { min-height:33px; }.metric-value { font-size:26px; }.lower-grid { grid-template-columns:1fr; }.games-panel { grid-column:auto; }
  .disk .metric-detail { min-height:auto; }.network-values strong { font-size:20px; }.network-values { gap:10px; }.network-values > div+div { padding-left:10px; }
  footer { font-size:10px; }
  .video-modal { padding:10px; }.video-dialog { max-height:calc(100dvh - 20px); }.video-dialog-header { padding:18px; gap:12px; }.video-dialog-header h2 { font-size:22px; }.video-toolbar { padding:12px 18px; }.video-search { margin:13px 18px; }.video-search input { font-size:16px; }
  .video-table thead { display:none; }.video-table,.video-table tbody,.video-table tr,.video-table td { display:block; }.video-table tr { padding:16px; border-top:1px solid var(--border); }.video-table td { padding:5px 0; border:0; }.video-table td[data-label]::before { content:attr(data-label); display:block; font-size:11px; color:var(--muted); margin-bottom:5px; }.video-name { max-width:none; }.convert-button,.video-refresh { min-height:42px; }
}
@media(prefers-reduced-motion:reduce) { *,*::before,*::after { transition:none!important; } }

/* Cloud Gaming: same palette and panels, no changes to existing widgets. */
.cloud-feedback { grid-column:1/-1; font-size:12px; color:var(--accent); }
.cloud-feedback.error { color:#e9a39b; }
.cloud-button:not(:disabled):not(.cloud-play):hover { border-color:var(--accent); background:#2b3923; }
.cloud-gaming-section { margin-top:28px; }
.cloud-section-heading { display:flex; align-items:center; justify-content:space-between; gap:12px; margin-bottom:13px; }
.cloud-section-heading h2 { margin:0; }
.cloud-readonly { font-size:11px; color:var(--muted); }
.cloud-gaming-card { display:grid; grid-template-columns:minmax(180px,1fr) auto; align-items:center; gap:18px 24px; }
.cloud-pc { display:flex; align-items:center; gap:14px; min-width:0; }
.cloud-pc-icon { display:grid; place-items:center; width:46px; height:46px; flex:0 0 46px; border:1px solid #48533f; background:#263023; border-radius:10px; color:var(--accent); }
.cloud-pc h3 { font-size:15px; }
.cloud-status { display:flex; align-items:center; gap:8px; color:var(--muted); font-size:12px; margin-top:5px; }
.cloud-status .status-dot { margin:0; }
.cloud-actions { display:flex; flex-wrap:wrap; align-items:center; gap:8px; }
.cloud-button { display:inline-flex; align-items:center; justify-content:center; gap:7px; min-height:44px; padding:10px 14px; border:1px solid var(--border); border-radius:7px; background:#222b25; color:var(--text); font-size:12px; font-weight:550; white-space:nowrap; }
.cloud-button:disabled { opacity:.65; cursor:not-allowed; color:var(--muted); }
.cloud-play { background:#c4df97; border-color:#c4df97; color:#172110; }
.cloud-play:hover { background:#d3e9b1; border-color:#d3e9b1; }
.cloud-play .icon { width:16px; height:16px; }
.cloud-access { grid-column:1/-1; display:flex; align-items:center; justify-content:space-between; gap:12px; padding-top:14px; border-top:1px solid var(--border); }
.cloud-access p { color:var(--muted); font-size:11px; }
.cloud-unlock { flex-shrink:0; border:0; background:transparent; color:var(--accent); padding:8px 0 8px 8px; min-height:40px; font-size:12px; }
.cloud-unlock:hover { text-decoration:underline; }
.cloud-login-dialog { width:min(420px,calc(100% - 32px)); padding:24px; border:1px solid #42503e; border-radius:14px; background:var(--panel); color:var(--text); }
.cloud-login-dialog::backdrop { background:#080d0be8; backdrop-filter:blur(4px); }
.cloud-login-heading { display:flex; align-items:center; justify-content:space-between; gap:12px; }
.cloud-login-heading h2 { font-size:18px; margin:0; }
.cloud-login-dialog p { font-size:12px; color:var(--muted); margin-top:14px; }
.cloud-login-dialog label { display:block; font-size:12px; margin-top:18px; }
.cloud-login-dialog input { display:block; width:100%; min-height:44px; margin-top:7px; padding:10px 12px; border:1px solid var(--border); border-radius:7px; background:var(--bg); font-size:16px; }
.cloud-login-submit { width:100%; margin-top:22px; }
.cloud-login-dialog .cloud-login-error { color:#e9a39b; }
@media(max-width:700px) {
  .cloud-gaming-card { grid-template-columns:1fr; gap:16px; }
  .cloud-actions { display:grid; grid-template-columns:1fr 1fr 1.3fr; gap:7px; }
  .cloud-button { padding:10px 8px; }
  .cloud-access { gap:8px; }
}
@media(max-width:360px) {
  .cloud-actions { grid-template-columns:1fr 1fr; }
  #cloud-sleep { grid-column:1/-1; }
  .cloud-access { align-items:flex-start; flex-direction:column; }
  .cloud-unlock { padding-left:0; }
}
