/* ============================================================ tokens * Every color has a light and dark value; contrast figures are against the tile. * text #1d1d1f / #f5f5f7 16.8:1 / 15.6:1 * text-2 #6e6e73 / #a1a1a6 5.1:1 / 6.6:1 * accent #0066cc / #0a84ff (white label 5.6:1 / 3.7:1, semibold) * lit #ffedc7 / #ffe2a8 (lit-text 6.2:1+ for secondary, 10.7:1 primary) */ :root { --canvas: #f2f2f7; --surface: #ffffff; --tile: #ffffff; --text: #1d1d1f; --text-2: #6e6e73; --separator: rgba(60, 60, 67, 0.16); --fill: rgba(120, 120, 128, 0.14); --fill-strong: rgba(120, 120, 128, 0.24); --accent: #0066cc; --on-accent: #ffffff; --lit: #ffedc7; --lit-text: #3d2c0a; --lit-text-2: #6b5426; --warn: #c93400; --crit: #d70015; --ok: #248a3d; --glass: rgba(255, 255, 255, 0.72); --glass-edge: rgba(255, 255, 255, 0.6); --shadow: 0 1px 2px rgba(0, 0, 0, 0.04), 0 4px 16px rgba(0, 0, 0, 0.06); --focus: 0 0 0 3px color-mix(in srgb, var(--accent) 45%, transparent); --font: -apple-system, BlinkMacSystemFont, system-ui, "Segoe UI", Roboto, "Helvetica Neue", sans-serif; --font-num: ui-rounded, "SF Pro Rounded", -apple-system, BlinkMacSystemFont, system-ui, sans-serif; color-scheme: light dark; } @media (prefers-color-scheme: dark) { :root { --canvas: #0f0f11; --surface: #1c1c1e; --tile: #1c1c1e; --text: #f5f5f7; --text-2: #a1a1a6; --separator: rgba(84, 84, 88, 0.55); --fill: rgba(118, 118, 128, 0.24); --fill-strong: rgba(118, 118, 128, 0.36); --accent: #0a84ff; --lit: #ffe2a8; --warn: #ff9f0a; --crit: #ff453a; --ok: #30d158; --glass: rgba(30, 30, 32, 0.68); --glass-edge: rgba(255, 255, 255, 0.08); --shadow: none; } } @media (prefers-contrast: more) { :root { --text-2: var(--text); --separator: color-mix(in srgb, var(--text) 45%, transparent); --glass: var(--surface); } .w { border-color: var(--d-separator) !important; } } @media (prefers-reduced-transparency: reduce) { :root { --glass: var(--surface); } } /* ============================================================ base */ * { box-sizing: border-box; } html, body { margin: 0; height: 100%; } body { font: 14px/1.4 var(--font); background: var(--canvas); color: var(--text); overflow: hidden; -webkit-font-smoothing: antialiased; } button, input, select, textarea { font: inherit; color: inherit; } h2, h3 { margin: 0; } .muted { color: var(--text-2); } .small { font-size: 13px; } .num { font-family: var(--font-num); font-variant-numeric: tabular-nums; } .i { width: 1em; height: 1em; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; } .i.f { fill: currentColor; stroke: none; } .i.inline { vertical-align: -2px; margin-right: 3px; } :focus { outline: none; } :focus-visible { box-shadow: var(--focus); border-radius: 8px; } .sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; } /* ============================================================ chrome */ #app { position: relative; height: 100vh; } /* Floating toolbar: the one glass surface, part of the functional layer. */ #topbar { position: absolute; top: 10px; left: 10px; right: 10px; z-index: 30; height: 52px; padding: 0 8px 0 10px; display: flex; align-items: center; justify-content: space-between; gap: 8px; background: var(--glass); backdrop-filter: blur(24px) saturate(1.4); -webkit-backdrop-filter: blur(24px) saturate(1.4); border: 1px solid var(--glass-edge); border-radius: 18px; box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12); } .tb-group { display: flex; align-items: center; gap: 4px; min-width: 0; } .btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 36px; min-width: 36px; padding: 0 14px; border: 0; border-radius: 10px; background: var(--fill); cursor: pointer; font-weight: 500; white-space: nowrap; } .btn:hover { background: var(--fill-strong); } .btn .i { font-size: 18px; } .btn.icon { padding: 0; width: 36px; background: transparent; } .btn.icon:hover { background: var(--fill); } .btn.primary { background: var(--accent); color: var(--on-accent); font-weight: 600; } .btn.primary:hover { filter: brightness(1.08); } .btn.danger { color: var(--crit); } .btn.danger-fill { background: var(--crit); color: #fff; font-weight: 600; } .btn:disabled { opacity: 0.35; cursor: default; } .picker { position: relative; display: flex; align-items: center; } .picker select { appearance: none; -webkit-appearance: none; border: 0; background: transparent; cursor: pointer; font-size: 17px; font-weight: 650; padding: 6px 28px 6px 8px; border-radius: 10px; max-width: 46vw; text-overflow: ellipsis; } .picker select:hover { background: var(--fill); } .picker .i { position: absolute; right: 8px; pointer-events: none; font-size: 14px; color: var(--text-2); } .conn { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--crit); padding: 0 6px; } .conn::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; } .conn.ok { display: none; } .save-status { font-size: 13px; color: var(--text-2); padding: 0 6px; white-space: nowrap; } .menu { position: absolute; right: 8px; top: calc(100% + 6px); z-index: 50; background: var(--glass); backdrop-filter: blur(30px) saturate(1.4); -webkit-backdrop-filter: blur(30px) saturate(1.4); border: 1px solid var(--glass-edge); border-radius: 14px; box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2); padding: 6px; display: flex; flex-direction: column; min-width: 220px; } .menu[hidden] { display: none; } .menu button { display: flex; align-items: center; gap: 10px; border: 0; background: transparent; text-align: left; padding: 9px 10px; border-radius: 8px; cursor: pointer; min-height: 36px; } .menu button .i { font-size: 17px; color: var(--text-2); } .menu button:hover { background: var(--fill); } .menu .danger, .menu .danger .i { color: var(--crit); } .menu hr { border: 0; border-top: 1px solid var(--separator); margin: 4px 6px; } #workspace { position: absolute; inset: 0; display: flex; } #palette, #inspector { flex: none; overflow-y: auto; background: var(--surface); padding: 76px 14px 20px; } #palette { width: 232px; border-right: 1px solid var(--separator); } #inspector { width: 300px; border-left: 1px solid var(--separator); } .panel-title { font-size: 17px; font-weight: 650; margin: 2px 2px 12px; display: flex; align-items: center; gap: 8px; } .panel-title .i { font-size: 20px; color: var(--text-2); } .hint { margin: 16px 2px 0; font-size: 13px; color: var(--text-2); } #palette-list { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; } .pal-item { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; min-height: 72px; padding: 10px 4px; border-radius: 12px; border: 0; background: var(--fill); font-size: 13px; text-align: center; cursor: pointer; } .pal-item:hover { background: var(--fill-strong); } .pal-item .i { font-size: 22px; } .pal-item span { hyphens: auto; -webkit-hyphens: auto; overflow-wrap: anywhere; line-height: 1.2; } body:not(.editing) .edit-only { display: none !important; } body.editing .view-only { display: none !important; } #stage { flex: 1; overflow: auto; min-width: 0; position: relative; padding-top: 72px; display: flex; align-items: flex-start; } #canvas { flex: 1; min-width: 0; align-self: stretch; } #grid { position: relative; margin: 0 auto; } /* inspector form: grouped like a settings list */ .field { margin-bottom: 12px; } .field > label, .field-label { display: block; font-size: 13px; color: var(--text-2); margin: 0 2px 4px; } .field.check > label { display: flex; align-items: center; gap: 10px; color: var(--text); font-size: 14px; min-height: 28px; cursor: pointer; } .field.check input { width: 18px; height: 18px; accent-color: var(--accent); margin: 0; } .section { border-top: 1px solid var(--separator); margin-top: 16px; padding-top: 14px; } .section-title { font-size: 13px; font-weight: 600; color: var(--text-2); margin: 0 2px 10px; } .row { display: flex; gap: 8px; align-items: flex-end; } .row > * { flex: 1; min-width: 0; } select.input, input.input, textarea.input { width: 100%; min-width: 0; min-height: 34px; padding: 6px 10px; background: var(--fill); border: 1px solid transparent; border-radius: 9px; } input.input:focus, select.input:focus, textarea.input:focus { border-color: var(--accent); box-shadow: var(--focus); background: var(--surface); } textarea.input { resize: vertical; min-height: 76px; font-family: ui-monospace, Menlo, monospace; font-size: 13px; } .input.invalid { border-color: var(--crit); } .seg { display: flex; background: var(--fill); border-radius: 9px; padding: 2px; gap: 2px; } .seg button { flex: 1; border: 0; background: transparent; border-radius: 7px; min-height: 30px; padding: 0 6px; cursor: pointer; font-size: 13px; white-space: nowrap; } .seg button[aria-pressed="true"] { background: var(--surface); box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12); font-weight: 600; } .color-row { display: flex; gap: 6px; } .color-row input[type=color] { width: 34px; height: 34px; padding: 0; border: 1px solid var(--separator); border-radius: 9px; background: none; flex: none; cursor: pointer; } .icon-row { display: flex; gap: 6px; align-items: center; } .icon-row .icon-prev { width: 34px; height: 34px; border-radius: 9px; background: var(--fill); display: grid; place-items: center; flex: none; font-size: 18px; } .ent-item { display: flex; gap: 6px; margin-bottom: 6px; } .ent-item .btn { flex: none; } .ent-hint { font-size: 13px; color: var(--text-2); margin: 4px 2px 0; } .insp-actions { display: flex; gap: 8px; margin-top: 18px; } .insp-actions .btn { flex: 1; } .presets { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; } .preset { height: 52px; border-radius: 10px; border: 2px solid transparent; padding: 0; position: relative; overflow: hidden; cursor: pointer; } .preset span { position: absolute; left: 7px; bottom: 5px; font-size: 12px; font-weight: 600; } .preset i { position: absolute; right: 7px; top: 7px; width: 16px; height: 16px; border-radius: 5px; } .preset[aria-pressed="true"] { border-color: var(--accent); } /* sheets, alerts, toasts */ .modal { position: fixed; inset: 0; background: rgba(0, 0, 0, 0.4); display: flex; align-items: center; justify-content: center; z-index: 100; padding: 16px; } .modal[hidden] { display: none; } .modal-card { background: var(--surface); border-radius: 18px; padding: 20px; width: 420px; max-width: 100%; max-height: 85vh; overflow: auto; box-shadow: 0 24px 80px rgba(0, 0, 0, 0.35); } .modal-card h3 { font-size: 20px; font-weight: 700; margin-bottom: 4px; } .modal-card p { margin: 6px 0 0; color: var(--text-2); } .modal-actions { display: flex; gap: 8px; justify-content: flex-end; margin-top: 18px; } .modal-actions .btn { min-width: 96px; } .attr-table { width: 100%; border-collapse: collapse; font-size: 13px; margin-top: 14px; } .attr-table td { border-top: 1px solid var(--separator); padding: 7px 4px; vertical-align: top; word-break: break-word; } .attr-table td:first-child { color: var(--text-2); width: 40%; } #toasts { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); z-index: 200; display: flex; flex-direction: column; gap: 8px; align-items: center; } .toast { background: var(--glass); backdrop-filter: blur(24px); -webkit-backdrop-filter: blur(24px); border: 1px solid var(--glass-edge); color: var(--text); padding: 10px 16px; border-radius: 14px; font-size: 14px; box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2); } .toast.err { color: var(--crit); font-weight: 500; } /* ============================================================ dashboard canvas * Themed via --d-* on #stage. "System" leaves them on the adaptive tokens. */ #stage { --d-bg: var(--canvas); --d-tile: var(--tile); --d-text: var(--text); --d-text-2: var(--text-2); --d-accent: var(--accent); --d-separator: var(--separator); --d-fill: var(--fill); --d-lit: var(--lit); --d-shadow: var(--shadow); background: var(--d-bg); background-size: cover; background-position: center; background-attachment: local; color: var(--d-text); } .w { position: absolute; border-radius: var(--d-radius, 20px); background: var(--w-bg, var(--d-tile)); color: var(--w-color, var(--d-text)); --accent-w: var(--w-accent, var(--d-accent)); box-shadow: var(--d-shadow); border: 1px solid transparent; backdrop-filter: blur(var(--d-blur, 0px)); -webkit-backdrop-filter: blur(var(--d-blur, 0px)); overflow: hidden; transition: left .2s, top .2s, width .2s, height .2s, background-color .25s; user-select: none; container-type: size; } .w.transparent, .surface-plain .w { background: transparent; box-shadow: none; border-color: transparent; backdrop-filter: none; -webkit-backdrop-filter: none; } .surface-outline .w:not(.transparent) { background: transparent; box-shadow: none; border-color: var(--d-separator); backdrop-filter: none; } .w-body { position: absolute; inset: 0; padding: 16px; display: flex; flex-direction: column; min-height: 0; } .w-body.flush { padding: 0; } .w.transparent .w-body, .surface-plain .w .w-body { padding: 6px 4px; } .pad { padding: 16px; height: 100%; display: flex; } /* Lit: a light that is on turns its tile into lamplight — the signature moment. */ .w.lit-lamp:not(.transparent) { background: var(--w-bg, color-mix(in srgb, var(--lamp, var(--d-lit)) 32%, var(--d-lit))); color: var(--lit-text); --d-text-2: var(--lit-text-2); --d-fill: rgba(61, 44, 10, 0.12); } .w.lit-lamp .badge { background: rgba(255, 255, 255, 0.55); color: var(--lit-text); } .surface-plain .w.lit-lamp, .surface-outline .w.lit-lamp { background: transparent; color: var(--w-color, var(--d-text)); --d-text-2: var(--text-2); --d-fill: var(--fill); } .surface-plain .w.lit-lamp .badge, .surface-outline .w.lit-lamp .badge { background: color-mix(in srgb, var(--lamp, var(--d-lit)) 45%, var(--d-lit)); color: var(--lit-text); } .w.lit-on .badge { background: var(--accent-w); color: #fff; } /* edit mode */ body.editing #grid { background-image: var(--cell-bg); background-repeat: repeat; min-height: calc(100% - 16px); } body.editing .w { cursor: grab; } body.editing .w-body { pointer-events: none; } body.editing .surface-plain .w, body.editing .w.transparent { outline: 1px dashed var(--d-separator); outline-offset: -1px; } body.editing .w.selected { outline: 2px solid var(--accent); outline-offset: 2px; z-index: 5; } .w.dragging { transition: none; z-index: 20; cursor: grabbing; box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3); } .w-resize { position: absolute; right: 2px; bottom: 2px; width: 24px; height: 24px; cursor: nwse-resize; z-index: 3; opacity: 0; transition: opacity .1s; color: var(--accent); } .w-resize::after { content: ""; position: absolute; right: 5px; bottom: 5px; width: 10px; height: 10px; border-right: 3px solid currentColor; border-bottom: 3px solid currentColor; border-bottom-right-radius: 4px; } .w-tools { position: absolute; top: 8px; right: 8px; z-index: 3; display: none; gap: 4px; } .w-tools button { width: 30px; height: 30px; border-radius: 9px; border: 0; display: grid; place-items: center; background: var(--surface); color: var(--text); box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2); cursor: pointer; font-size: 16px; } .w-tools button.del { color: var(--crit); } body.editing .w.selected .w-tools { display: flex; } body.editing .w:hover .w-resize, body.editing .w.selected .w-resize { opacity: 1; } .placeholder { position: absolute; border-radius: var(--d-radius, 20px); background: color-mix(in srgb, var(--accent) 16%, transparent); border: 2px dashed var(--accent); pointer-events: none; z-index: 1; } /* ============================================================ widget content */ .wbtn { all: unset; box-sizing: border-box; cursor: pointer; -webkit-tap-highlight-color: transparent; } .wbtn:focus-visible { box-shadow: var(--focus); border-radius: 12px; } .wt { font-size: 14px; color: var(--d-text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .wt.wrap { white-space: normal; } .empty { margin: auto; text-align: center; color: var(--d-text-2); font-size: 14px; line-height: 1.45; } .name { font-size: 15px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .glyph { font-size: 20px; line-height: 1; } .badge { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--d-fill); font-size: 22px; flex: none; transition: background-color .25s, color .25s; } .level { align-self: flex-start; font-size: 12px; font-weight: 700; padding: 2px 8px; border-radius: 99px; color: var(--warn); background: color-mix(in srgb, currentColor 16%, transparent); } .heading { display: flex; flex-direction: column; justify-content: center; height: 100%; gap: 2px; } .heading .h-main { font-weight: 700; letter-spacing: -0.02em; line-height: 1.1; } .tile { display: flex; flex-direction: column; justify-content: space-between; height: 100%; width: 100%; gap: 8px; } .tile-text { display: flex; flex-direction: column; min-width: 0; } .state { font-size: 14px; color: var(--d-text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } @container (max-height: 110px) { .tile { flex-direction: row; align-items: center; justify-content: flex-start; } } .value { display: flex; flex-direction: column; justify-content: space-between; height: 100%; width: 100%; gap: 4px; } .value-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; } .value-ico { font-size: 20px; color: var(--d-text-2); display: flex; } .big { font-size: clamp(26px, min(30cqh, 24cqw), 56px); font-weight: 700; letter-spacing: -0.02em; line-height: 1; } .unit { font-size: 0.42em; font-weight: 600; color: var(--d-text-2); margin-left: 3px; letter-spacing: 0; } .value.warn .big { color: var(--warn); } .value.crit .big { color: var(--crit); } .value.warn .level { color: var(--warn); } .value.crit .level { color: var(--crit); } .car .level { color: var(--crit); align-self: center; } .gauge { display: flex; flex-direction: column; align-items: center; height: 100%; width: 100%; } .gauge svg { flex: 1; width: 100%; min-height: 0; } .light { display: flex; flex-direction: column; height: 100%; gap: 10px; justify-content: space-between; } .tile-row { display: flex; align-items: center; gap: 12px; min-width: 0; } /* Brightness: a wide pill slider like Control Center, filled with the lamp's color. */ .slider { -webkit-appearance: none; appearance: none; width: 100%; height: 44px; margin: 0; border-radius: 14px; cursor: pointer; background: linear-gradient(to right, var(--slider-fill, var(--d-text)) var(--pct, 0%), var(--d-fill) var(--pct, 0%)); outline: none; } .w.lit-lamp .slider { --slider-fill: color-mix(in srgb, var(--lamp, #f0a83a) 65%, #f0a83a); } .surface-plain .w.lit-lamp .slider, .surface-outline .w.lit-lamp .slider { --slider-fill: color-mix(in srgb, var(--lamp, #f5b942) 60%, #f5b942); } .slider::-webkit-slider-thumb { -webkit-appearance: none; width: 6px; height: 26px; border-radius: 3px; background: transparent; } .slider::-moz-range-thumb { width: 6px; height: 26px; border: 0; background: transparent; } .slider:focus-visible { box-shadow: var(--focus); } .slider.thin { height: 28px; border-radius: 10px; flex: 1; min-width: 60px; } .climate { display: flex; flex-direction: column; height: 100%; gap: 8px; } .climate .temps { display: flex; align-items: center; justify-content: space-between; flex: 1; gap: 8px; } .climate .target { font-size: clamp(28px, min(22cqh, 18cqw), 56px); font-weight: 700; } .round { width: 44px; height: 44px; border-radius: 50%; background: var(--d-fill); display: grid; place-items: center; font-size: 20px; flex: none; } .round:hover { background: color-mix(in srgb, var(--d-text) 16%, transparent); } .round.primary { background: var(--d-text); color: var(--d-tile); } .chips { display: flex; gap: 6px; flex-wrap: wrap; } .chip { border-radius: 99px; padding: 0 14px; min-height: 32px; display: inline-flex; align-items: center; font-size: 13px; font-weight: 500; background: var(--d-fill); } .chip[aria-pressed="true"] { background: var(--d-text); color: var(--d-tile); font-weight: 600; } .graph { display: flex; flex-direction: column; height: 100%; gap: 6px; } .graph .legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 13px; color: var(--d-text-2); } .graph .legend span { display: inline-flex; align-items: center; gap: 6px; } .graph .legend svg { flex: none; } .graph .legend b { font-size: 15px; color: var(--d-text); } .graph .plot { flex: 1; min-height: 0; position: relative; } .graph .plot svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; } .graph .axis { font-size: 11px; fill: var(--d-text-2); } .clock { display: flex; flex-direction: column; justify-content: center; align-items: center; height: 100%; text-align: center; } .clock .time { font-size: clamp(30px, min(38cqh, 22cqw), 96px); font-weight: 700; letter-spacing: -0.03em; line-height: 1; } .clock .date { color: var(--d-text-2); margin-top: 6px; font-size: 15px; } .cam-btn { position: absolute; inset: 0; } .cam { width: 100%; height: 100%; object-fit: cover; display: block; background: #000; } .cam-label { position: absolute; left: 12px; bottom: 10px; font-size: 13px; font-weight: 600; color: #fff; text-shadow: 0 1px 4px rgba(0, 0, 0, 0.8); pointer-events: none; } .media { display: flex; flex-direction: column; height: 100%; gap: 6px; justify-content: space-between; } .media .title { font-weight: 650; font-size: 17px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .media .ctrls { display: flex; gap: 8px; align-items: center; } .weather { display: flex; align-items: center; gap: 16px; height: 100%; width: 100%; } .wx-ico { font-size: clamp(36px, min(45cqh, 20cqw), 72px); display: flex; color: var(--d-text-2); } .wx-text { display: flex; flex-direction: column; min-width: 0; } .wx-temp { font-size: clamp(26px, min(26cqh, 16cqw), 48px); font-weight: 700; line-height: 1.05; } .list { display: flex; flex-direction: column; overflow-y: auto; min-height: 0; margin: 4px -6px 0; } .list-row { display: flex; align-items: center; gap: 12px; min-height: 44px; padding: 0 6px; border-radius: 10px; } .list-row + .list-row { box-shadow: inset 0 1px 0 var(--d-separator); } .list-row:hover { background: var(--d-fill); } .row-ico { font-size: 20px; display: flex; color: var(--d-text-2); } .list-row .grow { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 15px; } .list-row .st { color: var(--d-text-2); font-size: 14px; white-space: nowrap; } .switch { width: 46px; height: 28px; border-radius: 14px; background: var(--d-fill); position: relative; flex: none; transition: background-color .2s; } .switch::after { content: ""; position: absolute; top: 2px; left: 2px; width: 24px; height: 24px; border-radius: 50%; background: #fff; transition: transform .2s; box-shadow: 0 2px 4px rgba(0, 0, 0, 0.25); } [aria-checked="true"] > .switch { background: var(--ok); } [aria-checked="true"] > .switch::after { transform: translateX(18px); } .btn-widget { display: flex; flex-direction: column; align-items: flex-start; justify-content: space-between; height: 100%; width: 100%; gap: 8px; } .btn-widget:active .badge { background: var(--accent-w); color: #fff; } .text-w { white-space: pre-wrap; overflow: auto; height: 100%; line-height: 1.45; } .frame { width: 100%; height: 100%; border: 0; display: block; } .img-w { width: 100%; height: 100%; display: block; } /* tab menu: a sidebar on wide screens, a rail on tablets, a tab bar on phones */ #tabnav { position: sticky; top: 4px; flex: none; z-index: 10; width: 220px; margin: 8px 0 16px 16px; padding: 8px; display: flex; flex-direction: column; gap: 2px; max-height: calc(100vh - 92px); overflow-y: auto; background: color-mix(in srgb, var(--d-tile) 82%, transparent); backdrop-filter: blur(24px) saturate(1.3); -webkit-backdrop-filter: blur(24px) saturate(1.3); border: 1px solid var(--d-separator); border-radius: var(--d-radius, 20px); color: var(--d-text); } #tabnav[hidden] { display: none; } .tabnav-item { display: flex; align-items: center; gap: 12px; min-height: 44px; padding: 0 12px; border: 0; border-radius: 12px; background: transparent; color: inherit; cursor: pointer; font-size: 15px; font-weight: 500; text-align: left; } .tabnav-item:hover { background: var(--d-fill); } .tabnav-item[aria-current="page"] { background: color-mix(in srgb, var(--d-accent) 18%, transparent); font-weight: 650; } .tabnav-ico { font-size: 20px; display: flex; color: var(--d-text-2); flex: none; } .tabnav-item[aria-current="page"] .tabnav-ico { color: var(--d-accent); } .tabnav-label { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .tabnav-item.add { color: var(--d-text-2); margin-top: 4px; } .tabnav-item.add .i { font-size: 20px; } body.kiosk #tabnav { top: 6px; max-height: calc(100vh - 20px); } .surface-plain #tabnav { background: transparent; border-color: transparent; backdrop-filter: none; -webkit-backdrop-filter: none; } .i.flip { transform: rotate(180deg); } .tab-list { display: flex; flex-direction: column; gap: 6px; margin-bottom: 4px; } .tab-item { display: flex; gap: 4px; align-items: center; } .tab-item .input { min-width: 0; } .tab-item .tab-icon { width: 76px; flex: none; } .tab-item .icon-prev { width: 30px; height: 30px; font-size: 16px; } .tab-item .btn.icon { width: 30px; min-width: 30px; flex: none; } /* waste */ .bin { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: var(--bin); color: #fff; font-size: 19px; flex: none; } .w-body > .wt { flex: none; } .waste-next { flex: none; display: flex; align-items: center; gap: 14px; padding: 8px 0 12px; } .waste-next + .waste-list { border-top: 1px solid var(--d-separator); padding-top: 4px; } .waste-bins { display: flex; } .waste-bins .bin { width: 52px; height: 52px; border-radius: 14px; font-size: 28px; } .waste-bins .bin + .bin { margin-left: -12px; box-shadow: 0 0 0 3px var(--d-tile); } .waste-next-text { display: flex; flex-direction: column; min-width: 0; gap: 1px; } .waste-when { font-size: 24px; font-weight: 700; line-height: 1.15; } .waste-next.soon .waste-when { color: var(--d-accent); } .waste-types { font-size: 15px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .waste-next .level { color: var(--d-accent); margin-top: 4px; } .waste-row .bin { width: 28px; height: 28px; border-radius: 8px; font-size: 16px; } .waste-day { font-size: 14px; font-weight: 600; white-space: nowrap; } .waste-day.soon { color: var(--d-accent); } @container (max-width: 300px) { .waste-row .st { display: none; } } /* photos */ .photos { position: absolute; inset: 0; background: #000; overflow: hidden; } .ph-layer { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: var(--fit, cover); opacity: 0; transition: opacity 1.2s ease; } .ph-layer.on { opacity: 1; } .ph-msg { position: absolute; inset: 0; display: flex; padding: 16px; color: #fff; --d-text-2: rgba(255, 255, 255, 0.75); } .ph-msg:empty { display: none; } .ph-date { position: absolute; left: 14px; bottom: 12px; font-size: 13px; font-weight: 600; color: #fff; text-shadow: 0 1px 4px rgba(0, 0, 0, 0.8); } .albums { display: flex; flex-direction: column; gap: 2px; background: var(--fill); border-radius: 9px; padding: 4px; max-height: 220px; overflow-y: auto; } .album { display: flex; align-items: center; gap: 10px; min-height: 36px; padding: 0 8px; border-radius: 7px; cursor: pointer; } .album:hover { background: var(--fill); } .album input { width: 18px; height: 18px; accent-color: var(--accent); margin: 0; } .album .grow { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } /* calendar */ .cal { flex: 1; min-height: 0; overflow-y: auto; margin: 4px -4px 0; padding: 0 4px; } .cal-day { font-size: 13px; font-weight: 650; color: var(--d-text-2); margin: 12px 0 4px; } .cal-day:first-child { margin-top: 4px; } .cal-ev { display: flex; align-items: flex-start; gap: 10px; padding: 6px 0; } .cal-bar { width: 4px; align-self: stretch; min-height: 20px; border-radius: 2px; flex: none; } .cal-when { width: 92px; flex: none; font-size: 14px; color: var(--d-text-2); padding-top: 1px; } .cal-what { display: flex; flex-direction: column; min-width: 0; flex: 1; } .cal-sum { font-size: 15px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .cal-sub { font-size: 13px; color: var(--d-text-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .cal-now { font-size: 12px; font-weight: 700; padding: 2px 8px; border-radius: 99px; color: var(--d-accent); background: color-mix(in srgb, currentColor 16%, transparent); align-self: center; } @container (max-width: 260px) { .cal-ev { flex-wrap: wrap; } .cal-when { width: auto; order: 2; flex-basis: 100%; padding-left: 14px; } } /* car */ .car { position: relative; display: flex; flex-direction: column; height: 100%; gap: 8px; } .car-img { position: absolute; right: -4px; top: -6px; width: 46%; height: 58%; object-fit: contain; object-position: right top; pointer-events: none; } .car.has-img .car-head, .car.has-img .car-main { max-width: 56%; } .car-head { display: flex; flex-direction: column; min-width: 0; } .car-head .name { font-size: 17px; } .car-main { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-top: auto; } .car-range { font-size: 17px; font-weight: 600; } .car-range .wt { font-size: 14px; font-weight: 400; } .car-bar { position: relative; height: 12px; border-radius: 6px; background: var(--d-fill); overflow: visible; flex: none; } .car-fill { position: absolute; inset: 0 auto 0 0; border-radius: 6px; background: var(--d-text); transition: width .4s; } .car-bar.charging .car-fill { background: var(--ok); background-image: linear-gradient(110deg, transparent 40%, rgba(255, 255, 255, 0.45) 50%, transparent 60%); background-size: 200% 100%; animation: charge 2.4s linear infinite; } .car-bar.low .car-fill { background: var(--crit); } .car-limit { position: absolute; top: -3px; bottom: -3px; width: 2px; margin-left: -1px; border-radius: 1px; background: var(--d-text-2); } @keyframes charge { from { background-position: 100% 0; } to { background-position: -100% 0; } } .car-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; } .car-act { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 14px; border-radius: 12px; background: var(--d-fill); font-size: 14px; font-weight: 500; } .car-act .i { font-size: 18px; } .car-act[aria-pressed="true"] { background: var(--d-text); color: var(--d-tile); } .car-odo { margin-left: auto; } @container (max-width: 340px) { .car-img { display: none; } .car.has-img .car-head, .car.has-img .car-main { max-width: none; } .car-odo { display: none; } } @container (max-height: 200px) { .car-actions { display: none; } } /* ============================================================ kiosk */ body.kiosk #topbar, body.kiosk #palette, body.kiosk #inspector { display: none !important; } body.kiosk #stage { padding-top: 6px; } body.kiosk.idle, body.kiosk.idle * { cursor: none !important; } #saver { position: fixed; inset: 0; z-index: 80; background: #000; color: #8e8e93; display: flex; flex-direction: column; align-items: center; justify-content: center; cursor: none; } #saver[hidden] { display: none; } #saver .time { font-size: min(22vw, 220px); font-weight: 600; letter-spacing: -0.03em; line-height: 1; } #saver .date { font-size: 22px; margin-top: 12px; color: #636366; } /* ============================================================ motion + sizes */ @media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; animation: none !important; } } /* While editing (and on tablets) the menu becomes a compact rail to leave room for the grid. */ @media (min-width: 641px) { body.editing #tabnav { width: 84px; padding: 6px; margin-left: 10px; } body.editing .tabnav-item { flex-direction: column; justify-content: center; gap: 3px; padding: 8px 4px; min-height: 60px; text-align: center; } body.editing .tabnav-label { font-size: 11px; font-weight: 600; max-width: 100%; } } @media (max-width: 900px) { #tabnav { width: 84px; padding: 6px; margin-left: 10px; } .tabnav-item { flex-direction: column; justify-content: center; gap: 3px; padding: 8px 4px; min-height: 60px; text-align: center; } .tabnav-label { font-size: 11px; font-weight: 600; max-width: 100%; } #palette { width: 180px; } #inspector { width: 260px; } #palette-list { grid-template-columns: 1fr; } .save-status { display: none; } } @media (max-width: 640px) { body:not(.editing) #tabnav { position: fixed; top: auto; left: 10px; right: 10px; bottom: calc(10px + env(safe-area-inset-bottom)); width: auto; margin: 0; flex-direction: row; max-height: none; overflow-x: auto; padding: 6px; border-radius: 22px; background: var(--glass); border-color: var(--glass-edge); box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2); } body:not(.editing) #tabnav .tabnav-item { flex: 1; min-width: 64px; } body.has-tabs:not(.editing) #canvas { padding-bottom: 96px; } body.editing #tabnav { position: static; width: auto; flex-direction: row; overflow-x: auto; max-height: none; margin: 4px 10px; } body.editing #stage { flex-direction: column; align-items: stretch; } #workspace { flex-direction: column; } body.editing #stage { order: 1; flex: 1; } body.editing #palette { order: 2; width: auto; max-height: 120px; padding: 10px; border: 0; border-top: 1px solid var(--separator); } body.editing #palette .panel-title, body.editing #palette .hint { display: none; } body.editing #palette-list { grid-template-columns: repeat(4, 1fr); } body.editing #inspector { order: 3; width: auto; max-height: 40vh; padding: 14px; border: 0; border-top: 1px solid var(--separator); } .btn.label-wide span { display: none; } }