Per-card opt-in push to the relay for distraction-free mobile reading.
Not tag-based: a real cards.read_push column so the reading state
stays independent of whatever tags the user organises by.
hyprcrd
- cards.read_push column (0/1, default 0) via Database migration.
- POST /api/cards + PATCH /api/cards/{id} accept read_push; save hook
posts the card (title+body, encrypted) and referenced images
to the relay's /api/read endpoint. First inline image is flagged
as the hero. Toggle-off / DELETE wipes the remote copy.
- Detail-bar toggle button ("Read" → "On relay") with filled book
icon + inverted accent background when active; outline book icon
in the bottom meta row of the board card when read_push=1.
relay
- read_items + read_attachments tables, encrypted under the
inter-tenant key like messages (dual-format envelope).
- Client API: POST /api/read, DELETE /api/read/{uid}, POST
/api/read-attachments. Session API: GET /api/read (list),
GET /api/read/{uid} (single decrypted), GET /api/read-attachments/
{uid}/{filename} (serves decrypted image bytes).
- Payload size caps raised to 15MB (attachments) / 2MB (items).
- New nav tab + view: list with thumbnails, click opens a zen reader
overlay. Reader caps article width at 680px, bumps type to 17px/1.7,
renders a minimal markdown subset (headings, lists, code fences,
blockquotes, links, inline images), rewrites uploads/ references
to the session-authed image endpoint. Escape closes the reader.
- Mobile-first: wider touch targets, tighter padding at ≤640px.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1049 lines
40 KiB
CSS
1049 lines
40 KiB
CSS
@font-face { font-family:'Silkscreen'; font-weight:400; src:url('../fonts/silkscreen-400.ttf') format('truetype'); }
|
|
@font-face { font-family:'Silkscreen'; font-weight:700; src:url('../fonts/silkscreen-700.ttf') format('truetype'); }
|
|
@font-face { font-family:'JetBrains Mono'; font-weight:400; src:url('../fonts/jetbrains-mono-400.ttf') format('truetype'); }
|
|
|
|
:root {
|
|
--bg:#1e293b; --surface:#273349; --raised:#2e3d56; --border:#384a64;
|
|
--dim:#64748b; --muted:#94a3b8; --text:#cbd5e1; --bright:#f1f5f9;
|
|
--accent:#38bdf8; --accent2:#818cf8; --danger:#fb7185; --ok:#4ade80;
|
|
--pixel:'Silkscreen', cursive;
|
|
--mono:'JetBrains Mono', monospace;
|
|
--radius:3px;
|
|
--radius-lg:6px;
|
|
--shadow-card:0 1px 2px rgba(0,0,0,0.3), 0 8px 24px -8px rgba(0,0,0,0.4);
|
|
--shadow-popover:0 8px 24px rgba(0,0,0,0.4);
|
|
--shadow-button:0 4px 12px -4px rgba(56,189,248,0.4);
|
|
--focus-ring:0 0 0 3px color-mix(in srgb, var(--accent) 22%, transparent);
|
|
}
|
|
* { margin:0; padding:0; box-sizing:border-box; }
|
|
body {
|
|
font-family:var(--mono);
|
|
background:var(--bg); color:var(--text);
|
|
min-height:100dvh; display:flex; flex-direction:column;
|
|
-webkit-font-smoothing:antialiased;
|
|
}
|
|
.pixel { font-family:var(--pixel); }
|
|
.hidden { display:none !important; }
|
|
.shrink { flex-shrink:0; }
|
|
.spacer { flex:1; }
|
|
|
|
/* ─────────────────────────────────────────────────────────────────
|
|
Header
|
|
───────────────────────────────────────────────────────────────── */
|
|
|
|
header {
|
|
padding:12px 20px; border-bottom:1px solid var(--border);
|
|
display:flex; align-items:center; gap:12px; flex-shrink:0;
|
|
background:var(--surface);
|
|
position:relative;
|
|
}
|
|
header .brand-icon {
|
|
color:var(--accent); font-size:18px; line-height:1;
|
|
filter: drop-shadow(0 0 8px color-mix(in srgb, var(--accent) 35%, transparent));
|
|
}
|
|
header h1 {
|
|
font-family:var(--pixel); font-size:14px; color:var(--accent);
|
|
letter-spacing:0.05em;
|
|
}
|
|
.header-status {
|
|
background:none; border:none; padding:4px 8px; cursor:pointer;
|
|
font-family:var(--pixel); font-size:9px; color:var(--dim);
|
|
display:inline-flex; align-items:center; gap:6px;
|
|
border-radius:var(--radius);
|
|
transition: color .15s, background .15s;
|
|
}
|
|
.header-status .ph { font-size:12px; }
|
|
.header-status:hover {
|
|
color: var(--accent);
|
|
background: color-mix(in srgb, var(--accent) 10%, transparent);
|
|
}
|
|
.header-status.has-unread {
|
|
color: var(--accent);
|
|
position: relative;
|
|
}
|
|
.header-status.has-unread::after {
|
|
content:''; position:absolute; top:2px; right:2px;
|
|
width:6px; height:6px; border-radius:50%;
|
|
background:var(--danger);
|
|
box-shadow: 0 0 6px color-mix(in srgb, var(--danger) 60%, transparent);
|
|
}
|
|
.header-status:focus-visible { outline:none; box-shadow: var(--focus-ring); }
|
|
header .dot {
|
|
width:8px; height:8px; border-radius:50%;
|
|
background:var(--accent); animation:pulse 2s ease-in-out infinite;
|
|
box-shadow: 0 0 8px color-mix(in srgb, var(--accent) 60%, transparent);
|
|
}
|
|
@keyframes pulse {
|
|
0%,100% { opacity:1; transform:scale(1); }
|
|
50% { opacity:0.4; transform:scale(0.85); }
|
|
}
|
|
header .user {
|
|
font-family:var(--pixel); font-size:10px; color:var(--muted);
|
|
display:flex; align-items:center; gap:6px;
|
|
}
|
|
header .user .badge {
|
|
background:var(--accent); color:var(--bg);
|
|
padding:5px 10px; font-size:9px;
|
|
border:1px solid var(--accent); border-radius:var(--radius);
|
|
line-height:1; font-family:var(--pixel);
|
|
}
|
|
header .nav-btn {
|
|
background:none; border:1px solid var(--border); color:var(--muted);
|
|
cursor:pointer; padding:5px 10px;
|
|
font-family:var(--pixel); font-size:9px; border-radius:var(--radius);
|
|
transition:all .15s;
|
|
}
|
|
header .nav-btn:hover {
|
|
color:var(--accent); border-color:var(--accent);
|
|
background: color-mix(in srgb, var(--accent) 8%, transparent);
|
|
}
|
|
header .nav-btn:focus-visible {
|
|
outline:none; box-shadow: var(--focus-ring);
|
|
}
|
|
header .nav-btn.active {
|
|
background:var(--accent); color:var(--bg); border-color:var(--accent);
|
|
box-shadow: 0 0 12px -2px color-mix(in srgb, var(--accent) 50%, transparent);
|
|
}
|
|
header .nav-btn.danger:hover {
|
|
color:var(--danger); border-color:var(--danger);
|
|
background: color-mix(in srgb, var(--danger) 8%, transparent);
|
|
}
|
|
|
|
/* ─────────────────────────────────────────────────────────────────
|
|
Layout shell
|
|
───────────────────────────────────────────────────────────────── */
|
|
|
|
main {
|
|
flex:1; display:flex; flex-direction:column;
|
|
padding:20px; gap:16px; max-width:920px; width:100%;
|
|
margin:0 auto;
|
|
}
|
|
@media (max-width: 600px) { main { padding:12px; gap:12px; } }
|
|
|
|
/* ─────────────────────────────────────────────────────────────────
|
|
Form primitives — used by every view (auth, compose, account, admin)
|
|
───────────────────────────────────────────────────────────────── */
|
|
|
|
.field { display:flex; flex-direction:column; gap:5px; width:100%; }
|
|
.field-label,
|
|
.field > label {
|
|
font-family:var(--pixel); font-size:9px; color:var(--dim);
|
|
text-transform:uppercase; letter-spacing:0.05em;
|
|
}
|
|
.input,
|
|
.field input[type="text"],
|
|
.field input[type="password"],
|
|
.field input[type="email"],
|
|
.field select,
|
|
.field textarea {
|
|
background:var(--bg); border:1px solid var(--border);
|
|
color:var(--bright); padding:9px 12px; font-size:13px;
|
|
font-family:var(--mono); border-radius:var(--radius);
|
|
transition:border-color .15s, box-shadow .15s, background .15s;
|
|
width:100%;
|
|
}
|
|
.input:focus,
|
|
.field input:focus,
|
|
.field select:focus,
|
|
.field textarea:focus {
|
|
border-color:var(--accent); outline:none;
|
|
box-shadow: var(--focus-ring);
|
|
background: color-mix(in srgb, var(--bg) 96%, var(--accent) 4%);
|
|
}
|
|
.input::placeholder,
|
|
.field input::placeholder,
|
|
.field textarea::placeholder { color:var(--dim); }
|
|
.field textarea { min-height:140px; resize:vertical; line-height:1.55; }
|
|
.field-hint {
|
|
font-size:9px; color:var(--dim); line-height:1.4;
|
|
font-family:var(--mono);
|
|
}
|
|
|
|
/* Inline label-on-checkbox style */
|
|
label.checkbox {
|
|
font-family:var(--pixel); font-size:9px; color:var(--dim);
|
|
text-transform:uppercase;
|
|
display:flex; align-items:center; gap:6px; cursor:pointer;
|
|
}
|
|
label.checkbox input[type="checkbox"] { accent-color:var(--accent); cursor:pointer; }
|
|
|
|
/* ─────────────────────────────────────────────────────────────────
|
|
Buttons
|
|
───────────────────────────────────────────────────────────────── */
|
|
|
|
.btn {
|
|
padding:10px 18px; border:1px solid transparent; border-radius:var(--radius);
|
|
font-family:var(--pixel); font-size:11px; cursor:pointer;
|
|
transition:all .15s;
|
|
display:inline-flex; align-items:center; gap:6px;
|
|
justify-content:center;
|
|
}
|
|
.btn:active { transform: translateY(1px); }
|
|
.btn:focus-visible { outline:none; box-shadow: var(--focus-ring); }
|
|
|
|
.btn-primary { background:var(--accent); color:var(--bg); border-color:var(--accent); }
|
|
.btn-primary:hover {
|
|
filter:brightness(1.12);
|
|
transform: translateY(-1px);
|
|
box-shadow: var(--shadow-button);
|
|
}
|
|
.btn-secondary {
|
|
background:transparent; border-color:var(--border); color:var(--muted);
|
|
}
|
|
.btn-secondary:hover {
|
|
color:var(--accent); border-color:var(--accent);
|
|
background: color-mix(in srgb, var(--accent) 8%, transparent);
|
|
transform: translateY(-1px);
|
|
}
|
|
.btn-danger {
|
|
background:transparent; border-color:var(--danger); color:var(--danger);
|
|
}
|
|
.btn-danger:hover {
|
|
background:var(--danger); color:var(--bg);
|
|
transform: translateY(-1px);
|
|
}
|
|
|
|
/* ─────────────────────────────────────────────────────────────────
|
|
Cards (compose, sections)
|
|
───────────────────────────────────────────────────────────────── */
|
|
|
|
.compose-card,
|
|
.section {
|
|
background:var(--surface); border:1px solid var(--border);
|
|
border-radius:var(--radius-lg); padding:18px;
|
|
display:flex; flex-direction:column; gap:12px;
|
|
}
|
|
.compose-card h2,
|
|
.section h2 {
|
|
font-family:var(--pixel); font-size:11px; color:var(--accent);
|
|
text-transform:uppercase; letter-spacing:0.05em;
|
|
display:flex; align-items:center; gap:8px;
|
|
}
|
|
.section h2 .count {
|
|
background:var(--bg); padding:3px 7px; border-radius:var(--radius);
|
|
font-size:9px; color:var(--muted);
|
|
border:1px solid var(--border);
|
|
}
|
|
|
|
/* ─────────────────────────────────────────────────────────────────
|
|
Compose
|
|
───────────────────────────────────────────────────────────────── */
|
|
|
|
#view-compose:not(.hidden) {
|
|
display: flex; flex-direction: column; gap: 16px;
|
|
}
|
|
#view-inbox:not(.hidden) {
|
|
display: flex; flex-direction: column; gap: 16px;
|
|
}
|
|
.compose-attachments {
|
|
display: flex; flex-wrap: wrap; gap: 6px; min-height: 0;
|
|
}
|
|
.compose-attachments:empty { display: none; }
|
|
.compose-att {
|
|
display: flex; align-items: center; gap: 5px;
|
|
padding: 4px 10px; border-radius: var(--radius);
|
|
background: var(--raised); border: 1px solid var(--border);
|
|
font-family: var(--pixel); font-size: 9px; color: var(--text);
|
|
}
|
|
.compose-att .att-remove {
|
|
background: none; border: none; color: var(--muted); cursor: pointer;
|
|
padding: 0; font-size: 11px; line-height: 1;
|
|
transition: color 0.15s;
|
|
}
|
|
.compose-att .att-remove:hover { color: var(--danger); }
|
|
.compose-att .att-icon { font-size: 12px; color: var(--dim); }
|
|
.compose-att .att-size { color: var(--dim); }
|
|
.compose-card .actions {
|
|
display:flex; gap:8px; align-items:center;
|
|
}
|
|
.compose-card .actions .spacer { flex:1; }
|
|
|
|
/* Shopping view — phone-friendly checklist. Large tap targets,
|
|
unchecked items only, tap to flip. */
|
|
.shopping-wrap { max-width: 520px; margin: 0 auto; display: flex; flex-direction: column; gap: 12px; }
|
|
.shopping-top { display: flex; align-items: center; gap: 10px; padding: 6px 2px; }
|
|
.shopping-items { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
|
|
.shopping-items .empty { list-style: none; text-align: center; padding: 40px 16px; color: var(--dim); background: transparent; border: none; cursor: default; }
|
|
.shopping-items .empty:active { transform: none; }
|
|
|
|
/* Multi-list stacked boxes — no own border/background so items
|
|
don't look doubled. The header provides section separation. */
|
|
.shopping-list-box {
|
|
list-style: none;
|
|
display: flex;
|
|
flex-direction: column;
|
|
gap: 6px;
|
|
}
|
|
.shopping-list-header {
|
|
font-weight: 600;
|
|
font-size: 13px;
|
|
color: var(--bright);
|
|
padding: 4px 6px 8px;
|
|
border-bottom: 1px solid var(--border);
|
|
}
|
|
.shopping-list-done {
|
|
text-align: center;
|
|
padding: 16px 8px;
|
|
color: var(--dim);
|
|
font-size: 14px;
|
|
}
|
|
.shopping-item {
|
|
background: var(--raised, var(--surface));
|
|
border: 1px solid var(--border);
|
|
border-radius: var(--radius-lg);
|
|
padding: 12px 14px;
|
|
font-size: 15px;
|
|
cursor: pointer;
|
|
user-select: none;
|
|
-webkit-tap-highlight-color: transparent;
|
|
transition: transform 0.12s, opacity 0.3s, background 0.12s;
|
|
}
|
|
.shopping-item:active { transform: scale(0.98); }
|
|
.shopping-item.checked { opacity: 0.35; text-decoration: line-through; }
|
|
|
|
/* Section headings between items — "# Obst", "## Backwaren", etc.
|
|
Adds breathing room above so grouped items feel like sections. */
|
|
.shopping-heading {
|
|
padding: 14px 6px 2px;
|
|
cursor: default;
|
|
font-weight: 600;
|
|
letter-spacing: 0.02em;
|
|
}
|
|
.shopping-heading:first-child { padding-top: 2px; }
|
|
.shopping-heading.h1 { font-size: 17px; color: var(--bright); }
|
|
.shopping-heading.h2 { font-size: 14px; color: var(--accent); }
|
|
.shopping-heading.h3,
|
|
.shopping-heading.h4,
|
|
.shopping-heading.h5,
|
|
.shopping-heading.h6 { font-size: 12px; color: var(--muted); }
|
|
.shopping-err { background: var(--danger-bg, #7f1d1d); color: var(--danger-fg, #fecaca); padding: 8px 12px; border-radius: 6px; font-size: 13px; }
|
|
.shopping-err.hidden { display: none; }
|
|
|
|
/* Chat view */
|
|
.chat-layout { display: flex; height: calc(100vh - 200px); min-height: 300px; border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; }
|
|
.chat-sidebar { width: 200px; border-right: 1px solid var(--border); display: flex; flex-direction: column; background: var(--surface); }
|
|
.chat-sidebar-header { padding: 12px; border-bottom: 1px solid var(--border); }
|
|
#chat-thread-list { flex: 1; overflow-y: auto; }
|
|
.chat-thread {
|
|
display: flex; align-items: center; gap: 8px; padding: 10px 12px;
|
|
cursor: pointer; border-bottom: 1px solid var(--border); transition: background 0.1s;
|
|
}
|
|
.chat-thread:hover { background: var(--raised); }
|
|
.chat-thread.active { background: var(--raised); border-left: 3px solid var(--accent); }
|
|
.chat-thread .peer-name { font-family: var(--pixel); font-size: 10px; color: var(--bright); flex: 1; }
|
|
.chat-thread .unread-badge {
|
|
font-family: var(--pixel); font-size: 8px; background: var(--accent);
|
|
color: var(--bg); padding: 1px 6px; border-radius: 8px; min-width: 16px; text-align: center;
|
|
}
|
|
.chat-thread .thread-time { font-family: var(--pixel); font-size: 8px; color: var(--dim); }
|
|
.chat-main { flex: 1; display: flex; flex-direction: column; min-height: 0; }
|
|
.chat-header { padding: 12px 16px; border-bottom: 1px solid var(--border); }
|
|
.chat-messages { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 6px; }
|
|
.chat-msg {
|
|
max-width: 75%; padding: 8px 12px; border-radius: var(--radius-lg);
|
|
font-size: 12px; line-height: 1.6; word-break: break-word;
|
|
}
|
|
.chat-msg.mine { align-self: flex-end; background: var(--accent); color: var(--bg); border-bottom-right-radius: 2px; }
|
|
.chat-msg.theirs { align-self: flex-start; background: var(--raised); color: var(--text); border: 1px solid var(--border); border-bottom-left-radius: 2px; }
|
|
.chat-msg .msg-time { font-family: var(--pixel); font-size: 8px; opacity: 0.6; margin-top: 4px; }
|
|
.chat-msg.mine .msg-time { text-align: right; }
|
|
.chat-input-bar { display: flex; gap: 8px; padding: 12px 16px; border-top: 1px solid var(--border); }
|
|
.chat-input-bar input {
|
|
flex: 1; background: var(--bg); border: 1px solid var(--border); color: var(--bright);
|
|
padding: 8px 12px; font-size: 12px; font-family: var(--mono);
|
|
border-radius: var(--radius); outline: none;
|
|
}
|
|
.chat-input-bar input:focus { border-color: var(--accent); }
|
|
.chat-empty {
|
|
flex: 1; display: flex; flex-direction: column; align-items: center;
|
|
justify-content: center; gap: 8px; color: var(--dim);
|
|
font-family: var(--pixel); font-size: 10px;
|
|
}
|
|
|
|
.compose-status-bar {
|
|
font-family: var(--pixel); font-size: 10px; color: var(--muted);
|
|
min-height: 0; overflow: hidden;
|
|
transition: opacity 0.3s ease, max-height 0.3s ease;
|
|
max-height: 0; opacity: 0;
|
|
}
|
|
.compose-status-bar.visible { max-height: 32px; opacity: 1; padding-top: 8px; }
|
|
.compose-status-bar.ok { color: var(--accent); }
|
|
.compose-status-bar.err { color: var(--danger); }
|
|
|
|
/* Status text (used in compose, account, create-user) */
|
|
.status { font-family:var(--pixel); font-size:9px; color:var(--dim); }
|
|
.status.ok { color:var(--ok); }
|
|
.status.err { color:var(--danger); }
|
|
|
|
/* ─────────────────────────────────────────────────────────────────
|
|
Auth forms (setup, login, change-password)
|
|
───────────────────────────────────────────────────────────────── */
|
|
|
|
.auth-form {
|
|
display:flex; flex-direction:column; align-items:center;
|
|
padding:40px 28px; gap:14px; max-width:400px; margin:48px auto 0;
|
|
background:var(--surface); border:1px solid var(--border);
|
|
border-radius:var(--radius-lg);
|
|
box-shadow: var(--shadow-card);
|
|
}
|
|
.auth-form .auth-icon {
|
|
font-size:36px; color:var(--accent); margin-bottom:4px;
|
|
filter: drop-shadow(0 0 16px color-mix(in srgb, var(--accent) 40%, transparent));
|
|
}
|
|
.auth-form h2 {
|
|
font-family:var(--pixel); font-size:14px; color:var(--accent);
|
|
margin-bottom:4px; letter-spacing:0.05em;
|
|
}
|
|
.auth-form p {
|
|
font-size:11px; color:var(--muted); text-align:center; line-height:1.55;
|
|
margin: 0 0 4px;
|
|
}
|
|
.auth-form .field { width:100%; }
|
|
.auth-form .btn { width:100%; }
|
|
.auth-form .err {
|
|
font-family:var(--pixel); font-size:9px; color:var(--danger);
|
|
min-height:11px; text-align:center;
|
|
}
|
|
|
|
/* Flash-highlight: a brief accent pulse on a card after the user
|
|
tapped the header inbox link and we just scrolled it into view. */
|
|
@keyframes flash-highlight {
|
|
0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 60%, transparent); }
|
|
50% { box-shadow: 0 0 0 6px color-mix(in srgb, var(--accent) 30%, transparent),
|
|
0 0 24px 4px color-mix(in srgb, var(--accent) 50%, transparent); }
|
|
100% { box-shadow: 0 0 0 0 transparent; }
|
|
}
|
|
.flash-highlight {
|
|
animation: flash-highlight 1.6s ease-out;
|
|
}
|
|
|
|
/* ─────────────────────────────────────────────────────────────────
|
|
Inbox + lists
|
|
───────────────────────────────────────────────────────────────── */
|
|
|
|
.inbox-item {
|
|
display:flex; align-items:flex-start; gap:10px;
|
|
padding:12px 10px; margin: 0 -10px;
|
|
border-bottom:1px solid var(--border);
|
|
transition: background .12s;
|
|
border-radius:var(--radius);
|
|
}
|
|
.inbox-item:hover {
|
|
background: color-mix(in srgb, var(--raised) 70%, transparent);
|
|
}
|
|
.inbox-item:last-child { border-bottom:none; }
|
|
.inbox-item .meta {
|
|
font-family:var(--pixel); font-size:9px; color:var(--dim);
|
|
white-space:nowrap; flex-shrink:0;
|
|
}
|
|
.inbox-item .content { flex:1; min-width:0; }
|
|
.inbox-item .content .title {
|
|
font-size:12px; color:var(--bright); font-weight:bold;
|
|
margin-bottom:2px; word-break:break-word;
|
|
}
|
|
.inbox-item .content .body {
|
|
font-size:11px; color:var(--text); white-space:pre-wrap;
|
|
word-break:break-word; max-height:120px; overflow:auto;
|
|
}
|
|
.inbox-item .from {
|
|
font-family:var(--pixel); font-size:9px; color:var(--accent2);
|
|
display:inline-flex; align-items:center; gap:6px;
|
|
margin-bottom:4px;
|
|
}
|
|
.inbox-item .from .ph { font-size:11px; }
|
|
.badge-new {
|
|
display:inline-block;
|
|
background:var(--accent); color:var(--bg);
|
|
padding:1px 6px; border-radius:var(--radius);
|
|
font-family:var(--pixel); font-size:8px;
|
|
text-transform:uppercase; letter-spacing:0.05em;
|
|
margin-left:4px;
|
|
}
|
|
.badge-synced {
|
|
display:inline-flex; align-items:center; gap:3px;
|
|
color:var(--ok, #4ade80);
|
|
padding:1px 6px; border-radius:var(--radius);
|
|
border:1px solid color-mix(in srgb, var(--ok, #4ade80) 40%, var(--border));
|
|
font-family:var(--pixel); font-size:8px;
|
|
text-transform:uppercase; letter-spacing:0.05em;
|
|
margin-left:4px;
|
|
}
|
|
.badge-synced .ph { font-size:9px; }
|
|
.inbox-item .del {
|
|
background:none; border:none; color:var(--dim); cursor:pointer;
|
|
padding:6px; font-size:14px; flex-shrink:0;
|
|
border-radius:var(--radius);
|
|
transition: color .15s, background .15s;
|
|
}
|
|
.inbox-item .del:hover {
|
|
color:var(--danger);
|
|
background: color-mix(in srgb, var(--danger) 10%, transparent);
|
|
}
|
|
|
|
/* User row (admin) */
|
|
.user-row {
|
|
display:flex; align-items:center; gap:12px;
|
|
padding:12px 10px; margin: 0 -10px;
|
|
border-bottom:1px solid var(--border);
|
|
border-radius:var(--radius);
|
|
transition: background .12s;
|
|
}
|
|
.user-row:hover {
|
|
background: color-mix(in srgb, var(--raised) 70%, transparent);
|
|
}
|
|
.user-row:last-child { border-bottom:none; }
|
|
.user-row .info { flex:1; }
|
|
.user-row .name {
|
|
font-family:var(--pixel); font-size:11px; color:var(--bright);
|
|
display:flex; align-items:center; gap:6px;
|
|
}
|
|
.user-row .meta { font-size:10px; color:var(--muted); margin-top:3px; }
|
|
.user-row .badge {
|
|
background:var(--accent); color:var(--bg);
|
|
padding:2px 7px; font-family:var(--pixel); font-size:8px;
|
|
text-transform:uppercase; border-radius:var(--radius);
|
|
}
|
|
.user-row .actions { display:flex; gap:6px; }
|
|
.user-row .actions .btn { padding:5px 10px; font-size:9px; }
|
|
|
|
/* User-row icon */
|
|
.user-row .user-icon { font-size:20px; color:var(--accent); flex-shrink:0; }
|
|
|
|
/* ─────────────────────────────────────────────────────────────────
|
|
Empty state — used by inbox, users list, etc.
|
|
───────────────────────────────────────────────────────────────── */
|
|
|
|
.empty-state {
|
|
display:flex; flex-direction:column; align-items:center;
|
|
justify-content:center; padding:36px 12px; gap:8px;
|
|
color:var(--dim); text-align:center;
|
|
}
|
|
.empty-state .icon {
|
|
font-size:38px; color:var(--dim); opacity:0.6;
|
|
}
|
|
.empty-state .label {
|
|
font-family:var(--pixel); font-size:10px; color:var(--muted);
|
|
text-transform:uppercase; letter-spacing:0.05em;
|
|
}
|
|
.empty-state .hint {
|
|
font-size:11px; color:var(--dim); line-height:1.5;
|
|
max-width:280px;
|
|
}
|
|
.empty {
|
|
font-size:11px; color:var(--dim); font-style:italic; padding:8px 0;
|
|
}
|
|
|
|
/* ─────────────────────────────────────────────────────────────────
|
|
Loading skeleton (used by inbox / users list while fetching)
|
|
───────────────────────────────────────────────────────────────── */
|
|
|
|
.skeleton-row {
|
|
display:flex; align-items:center; gap:10px; padding:12px 10px;
|
|
border-bottom:1px solid var(--border);
|
|
}
|
|
.skeleton-row:last-child { border-bottom:none; }
|
|
.skel {
|
|
background: linear-gradient(90deg,
|
|
color-mix(in srgb, var(--raised) 60%, transparent) 0%,
|
|
color-mix(in srgb, var(--raised) 90%, transparent) 50%,
|
|
color-mix(in srgb, var(--raised) 60%, transparent) 100%);
|
|
background-size: 200% 100%;
|
|
animation: skeleton 1.4s ease-in-out infinite;
|
|
border-radius:2px; height:10px; width:60%;
|
|
}
|
|
.skel.short { width:30%; }
|
|
.skel.tall { height:14px; }
|
|
@keyframes skeleton {
|
|
0% { background-position:200% 0; }
|
|
100% { background-position:-200% 0; }
|
|
}
|
|
|
|
/* ─────────────────────────────────────────────────────────────────
|
|
Account view — secret display + input row
|
|
───────────────────────────────────────────────────────────────── */
|
|
|
|
.account-secret-row {
|
|
display:flex; gap:8px; align-items:stretch;
|
|
}
|
|
.account-secret-row .input { flex:1; }
|
|
.account-secret-block { margin-bottom:14px; }
|
|
.account-divider {
|
|
text-align:center; color:var(--dim);
|
|
font-family:var(--pixel); font-size:9px;
|
|
text-transform:uppercase; letter-spacing:0.05em;
|
|
margin: 4px 0;
|
|
}
|
|
.account-secret-grid {
|
|
display:grid; grid-template-columns:1fr; gap:14px;
|
|
}
|
|
.account-secret-actions {
|
|
margin-top:24px; padding-top:14px; border-top:1px solid var(--border);
|
|
}
|
|
|
|
/* ─────────────────────────────────────────────────────────────────
|
|
Create user form (admin)
|
|
───────────────────────────────────────────────────────────────── */
|
|
|
|
.create-user-form {
|
|
display:flex; flex-direction:column; gap:12px;
|
|
padding-top:14px; border-top:1px solid var(--border); margin-top:14px;
|
|
}
|
|
.create-user-form .actions {
|
|
display:flex; gap:8px; align-items:center; margin-top:4px;
|
|
}
|
|
|
|
/* ─────────────────────────────────────────────────────────────────
|
|
Toast — single + stack support
|
|
───────────────────────────────────────────────────────────────── */
|
|
|
|
#toast-stack {
|
|
position:fixed; top:20px; right:20px;
|
|
display:flex; flex-direction:column; gap:8px;
|
|
z-index:200; pointer-events:none;
|
|
}
|
|
.toast {
|
|
background:var(--surface); color:var(--bright);
|
|
padding:10px 14px; border-radius:var(--radius-lg);
|
|
font-family:var(--pixel); font-size:10px;
|
|
display:flex; align-items:center; gap:8px;
|
|
border:1px solid var(--border);
|
|
box-shadow: var(--shadow-popover);
|
|
pointer-events:auto;
|
|
transform: translateX(120%);
|
|
transition: transform .25s cubic-bezier(0.16, 1, 0.3, 1), opacity .25s;
|
|
opacity:0;
|
|
min-width:180px; max-width:320px;
|
|
}
|
|
.toast.show { transform: translateX(0); opacity:1; }
|
|
.toast.fade-out { opacity:0; transform: translateX(20%); }
|
|
.toast .toast-icon { font-size:14px; flex-shrink:0; }
|
|
.toast .toast-msg { line-height:1.3; word-break:break-word; }
|
|
.toast.info { border-color: color-mix(in srgb, var(--accent) 60%, var(--border)); }
|
|
.toast.info .toast-icon { color: var(--accent); }
|
|
.toast.ok { border-color: color-mix(in srgb, var(--ok) 60%, var(--border)); }
|
|
.toast.ok .toast-icon { color: var(--ok); }
|
|
.toast.err { border-color: color-mix(in srgb, var(--danger) 60%, var(--border)); }
|
|
.toast.err .toast-icon { color: var(--danger); }
|
|
|
|
/* ─────────────────────────────────────────────────────────────────
|
|
Notices
|
|
───────────────────────────────────────────────────────────────── */
|
|
|
|
.notice {
|
|
padding:10px 14px; border-radius:var(--radius); font-size:11px;
|
|
margin-bottom:12px;
|
|
display:flex; align-items:flex-start; gap:8px;
|
|
line-height:1.5;
|
|
}
|
|
.notice .ph { font-size:14px; flex-shrink:0; margin-top:1px; }
|
|
.notice.info { background:rgba(56,189,248,0.08); border:1px solid color-mix(in srgb, var(--accent) 60%, var(--border)); color:var(--accent); }
|
|
.notice.warn { background:rgba(251,113,133,0.08); border:1px solid color-mix(in srgb, var(--danger) 60%, var(--border)); color:var(--danger); }
|
|
|
|
/* ─────────────────────────────────────────────────────────────────
|
|
Phosphor icon defaults
|
|
───────────────────────────────────────────────────────────────── */
|
|
|
|
.ph { display:inline-block; vertical-align:-2px; }
|
|
header .nav-btn .ph { font-size:11px; vertical-align:-1px; margin-right:2px; }
|
|
.btn .ph { font-size:12px; vertical-align:-2px; }
|
|
.section h2 .ph, .compose-card h2 .ph { font-size:13px; vertical-align:-2px; }
|
|
|
|
/* ─────────────────────────────────────────────────────────────────
|
|
Default nav layout (desktop)
|
|
───────────────────────────────────────────────────────────────── */
|
|
|
|
#nav-buttons:not(.hidden) {
|
|
display:flex; gap:6px; align-items:center;
|
|
}
|
|
#nav-burger {
|
|
display:none;
|
|
padding:5px 10px; font-size:11px;
|
|
}
|
|
|
|
/* ─────────────────────────────────────────────────────────────────
|
|
Mobile: collapse nav into a burger menu
|
|
───────────────────────────────────────────────────────────────── */
|
|
|
|
@media (max-width: 700px) {
|
|
#nav-user { display:none !important; }
|
|
#nav-burger { display:inline-flex !important; align-items:center; }
|
|
#nav-buttons:not(.hidden) { display:none; }
|
|
#nav-buttons.menu-open {
|
|
display:flex !important;
|
|
flex-direction:column;
|
|
align-items:stretch;
|
|
position:fixed;
|
|
top: 48px;
|
|
left: 0;
|
|
right: 0;
|
|
bottom: 0;
|
|
margin: 0;
|
|
background:var(--surface);
|
|
border-top:1px solid var(--border);
|
|
border-radius: 0;
|
|
padding: 12px 16px;
|
|
gap: 6px;
|
|
z-index:100;
|
|
}
|
|
#nav-buttons.menu-open .nav-btn {
|
|
text-align:left;
|
|
width:100%;
|
|
padding: 14px 16px;
|
|
font-size: 15px;
|
|
}
|
|
#nav-buttons.menu-open .nav-btn .ph {
|
|
font-size: 16px;
|
|
margin-right: 8px;
|
|
}
|
|
|
|
#view-admin .section {
|
|
display:block !important;
|
|
padding:14px 12px;
|
|
}
|
|
#view-admin .section h2 { margin-bottom:10px; }
|
|
#view-admin .section .create-user-form { margin-top:14px; }
|
|
|
|
.chat-layout { flex-direction: column; height: calc(100vh - 160px); }
|
|
.chat-sidebar { width: 100%; border-right: none; border-bottom: 1px solid var(--border); max-height: none; }
|
|
#chat-thread-list {
|
|
display: flex; overflow-x: auto; overflow-y: hidden; gap: 0;
|
|
scrollbar-width: none; -ms-overflow-style: none;
|
|
}
|
|
#chat-thread-list::-webkit-scrollbar { display: none; }
|
|
.chat-thread {
|
|
flex-shrink: 0; flex-direction: column; align-items: center;
|
|
gap: 2px; padding: 8px 14px; border-bottom: none; border-right: 1px solid var(--border);
|
|
min-width: 70px; text-align: center;
|
|
}
|
|
.chat-thread.active { border-left: none; border-bottom: 3px solid var(--accent); }
|
|
.chat-thread .thread-time { display: none; }
|
|
.chat-sidebar-header { display: none; }
|
|
}
|
|
|
|
/* ─────────────────────────────────────────────────────────────────
|
|
Desktop layout (≥ 901px)
|
|
───────────────────────────────────────────────────────────────── */
|
|
|
|
@media (min-width: 901px) {
|
|
|
|
body {
|
|
background:
|
|
radial-gradient(ellipse at top left, rgba(56,189,248,0.05), transparent 50%),
|
|
radial-gradient(ellipse at bottom right, rgba(129,140,248,0.05), transparent 50%),
|
|
var(--bg);
|
|
}
|
|
|
|
main {
|
|
max-width: 1200px;
|
|
padding: 32px 32px 48px;
|
|
gap: 24px;
|
|
}
|
|
|
|
header {
|
|
padding: 14px 32px;
|
|
}
|
|
header h1 {
|
|
font-size: 16px;
|
|
letter-spacing: 0.08em;
|
|
}
|
|
header .brand-icon { font-size:20px; }
|
|
header .nav-btn {
|
|
padding: 7px 12px;
|
|
}
|
|
header .user {
|
|
padding: 4px 10px;
|
|
background: var(--bg);
|
|
border: 1px solid var(--border);
|
|
border-radius: var(--radius);
|
|
}
|
|
|
|
/* Compose view: single column, centered. Inbox/shared/sent are in
|
|
their own view now — no sidebar to fill the right-hand space. */
|
|
#view-compose:not(.hidden) {
|
|
max-width: 720px;
|
|
margin: 0 auto;
|
|
}
|
|
|
|
/* Cards: depth via shadow + larger padding */
|
|
.compose-card,
|
|
.section {
|
|
padding: 22px 24px;
|
|
box-shadow: var(--shadow-card);
|
|
border-color: color-mix(in srgb, var(--border) 70%, var(--accent) 12%);
|
|
}
|
|
.compose-card h2,
|
|
.section h2 {
|
|
font-size: 12px;
|
|
margin-bottom: 6px;
|
|
padding-bottom: 12px;
|
|
border-bottom: 1px solid var(--border);
|
|
}
|
|
|
|
.compose-card .field textarea {
|
|
min-height: 320px;
|
|
font-size: 14px;
|
|
padding: 12px 14px;
|
|
}
|
|
.compose-card .field input,
|
|
.compose-card .field select {
|
|
padding: 9px 12px;
|
|
font-size: 14px;
|
|
}
|
|
.compose-card .field > label {
|
|
font-size: 10px;
|
|
margin-bottom: 6px;
|
|
}
|
|
.compose-card .actions {
|
|
margin-top: 6px;
|
|
padding-top: 12px;
|
|
border-top: 1px solid var(--border);
|
|
}
|
|
.compose-card .actions .btn {
|
|
padding: 11px 22px;
|
|
font-size: 12px;
|
|
}
|
|
|
|
|
|
/* Admin: 2-column grid */
|
|
#view-admin:not(.hidden) .section {
|
|
display: grid;
|
|
grid-template-columns: minmax(0, 1fr) 360px;
|
|
grid-template-areas:
|
|
"header header"
|
|
"list form";
|
|
gap: 28px;
|
|
align-items: start;
|
|
}
|
|
#view-admin .section h2 { grid-area: header; }
|
|
#view-admin .section #users-list { grid-area: list; }
|
|
#view-admin .section .create-user-form {
|
|
grid-area: form;
|
|
margin-top: 0;
|
|
padding-top: 0;
|
|
border-top: none;
|
|
padding-left: 24px;
|
|
border-left: 1px solid var(--border);
|
|
}
|
|
|
|
.user-row {
|
|
padding: 14px 12px;
|
|
}
|
|
.user-row .name { font-size: 12px; }
|
|
|
|
/* Auth-forms: full vertical centering, larger icon */
|
|
.auth-form {
|
|
margin-top: 88px;
|
|
padding: 44px 36px;
|
|
max-width: 440px;
|
|
}
|
|
.auth-form h2 { font-size: 16px; margin-bottom: 8px; }
|
|
.auth-form .auth-icon { font-size: 44px; }
|
|
}
|
|
|
|
/* ─────────────────────────────────────────────────────────────────
|
|
* Read view — list + distraction-free zen reader. Mobile-first; the
|
|
* article width is capped tight for comfortable line-lengths and the
|
|
* type scale is larger than anywhere else in the UI because this is
|
|
* meant for actual reading, not scanning.
|
|
* ───────────────────────────────────────────────────────────────── */
|
|
|
|
.read-wrap {
|
|
max-width: 720px;
|
|
margin: 0 auto;
|
|
padding: 24px 16px 48px;
|
|
}
|
|
|
|
.read-empty {
|
|
text-align: center;
|
|
padding: 64px 24px;
|
|
color: var(--dim);
|
|
font-size: 13px;
|
|
line-height: 1.6;
|
|
}
|
|
.read-empty-icon { font-size: 48px; display: block; margin: 0 auto 16px; color: var(--muted); }
|
|
|
|
.read-items {
|
|
list-style: none;
|
|
display: flex;
|
|
flex-direction: column;
|
|
gap: 10px;
|
|
}
|
|
.read-item {
|
|
background: var(--surface);
|
|
border: 1px solid var(--border);
|
|
border-radius: var(--radius-lg);
|
|
padding: 14px 16px;
|
|
cursor: pointer;
|
|
transition: border-color 0.15s, background 0.15s;
|
|
display: flex;
|
|
gap: 14px;
|
|
align-items: center;
|
|
}
|
|
.read-item:hover { border-color: var(--accent); background: var(--raised); }
|
|
.read-item-thumb {
|
|
width: 64px; height: 64px; flex-shrink: 0;
|
|
border-radius: var(--radius);
|
|
background: var(--bg) center/cover no-repeat;
|
|
border: 1px solid var(--border);
|
|
}
|
|
.read-item-thumb-placeholder {
|
|
display: flex; align-items: center; justify-content: center;
|
|
color: var(--dim);
|
|
font-size: 24px;
|
|
}
|
|
.read-item-body { flex: 1; min-width: 0; }
|
|
.read-item-title {
|
|
color: var(--bright);
|
|
font-size: 14px;
|
|
font-weight: 500;
|
|
line-height: 1.4;
|
|
margin-bottom: 4px;
|
|
white-space: nowrap;
|
|
overflow: hidden;
|
|
text-overflow: ellipsis;
|
|
}
|
|
.read-item-meta {
|
|
font-family: var(--pixel);
|
|
font-size: 9px;
|
|
color: var(--dim);
|
|
text-transform: uppercase;
|
|
letter-spacing: 0.5px;
|
|
}
|
|
|
|
/* Reader overlay: covers the main content area; header stays visible
|
|
* so the user can navigate back via the burger / nav buttons. */
|
|
.read-reader {
|
|
position: fixed;
|
|
inset: 56px 0 0 0;
|
|
background: var(--bg);
|
|
z-index: 80;
|
|
overflow-y: auto;
|
|
display: flex;
|
|
flex-direction: column;
|
|
}
|
|
.read-reader-bar {
|
|
position: sticky;
|
|
top: 0;
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 8px;
|
|
padding: 10px 14px;
|
|
background: color-mix(in srgb, var(--bg) 92%, transparent);
|
|
backdrop-filter: blur(8px);
|
|
-webkit-backdrop-filter: blur(8px);
|
|
border-bottom: 1px solid var(--border);
|
|
z-index: 2;
|
|
}
|
|
.read-reader-btn {
|
|
background: transparent;
|
|
border: 1px solid var(--border);
|
|
color: var(--text);
|
|
width: 36px; height: 36px;
|
|
border-radius: var(--radius);
|
|
cursor: pointer;
|
|
display: flex; align-items: center; justify-content: center;
|
|
font-size: 16px;
|
|
transition: border-color 0.15s, color 0.15s;
|
|
}
|
|
.read-reader-btn:hover { border-color: var(--accent); color: var(--accent); }
|
|
.read-reader-btn-danger:hover { border-color: var(--danger); color: var(--danger); }
|
|
|
|
.read-article {
|
|
max-width: 680px;
|
|
width: 100%;
|
|
margin: 0 auto;
|
|
padding: 24px 20px 96px;
|
|
font-size: 17px;
|
|
line-height: 1.7;
|
|
color: var(--text);
|
|
}
|
|
.read-article .read-hero {
|
|
display: block;
|
|
width: 100%;
|
|
max-height: 360px;
|
|
object-fit: cover;
|
|
border-radius: var(--radius-lg);
|
|
margin-bottom: 24px;
|
|
background: var(--surface);
|
|
}
|
|
.read-article h1.read-title {
|
|
font-family: var(--mono);
|
|
font-size: 26px;
|
|
line-height: 1.25;
|
|
font-weight: 700;
|
|
color: var(--bright);
|
|
margin-bottom: 6px;
|
|
}
|
|
.read-article .read-date {
|
|
font-family: var(--pixel);
|
|
font-size: 10px;
|
|
color: var(--dim);
|
|
text-transform: uppercase;
|
|
letter-spacing: 0.5px;
|
|
margin-bottom: 28px;
|
|
}
|
|
.read-article h1, .read-article h2, .read-article h3 {
|
|
color: var(--bright);
|
|
line-height: 1.3;
|
|
margin-top: 28px;
|
|
margin-bottom: 12px;
|
|
}
|
|
.read-article h2 { font-size: 20px; }
|
|
.read-article h3 { font-size: 17px; }
|
|
.read-article p { margin: 0 0 16px; }
|
|
.read-article a { color: var(--accent); text-decoration: underline; }
|
|
.read-article ul, .read-article ol { padding-left: 24px; margin: 0 0 16px; }
|
|
.read-article li { margin-bottom: 6px; }
|
|
.read-article code {
|
|
font-family: var(--mono);
|
|
font-size: 0.9em;
|
|
background: var(--surface);
|
|
padding: 1px 5px;
|
|
border-radius: 3px;
|
|
}
|
|
.read-article pre {
|
|
background: var(--surface);
|
|
border: 1px solid var(--border);
|
|
border-radius: var(--radius-lg);
|
|
padding: 14px 16px;
|
|
overflow-x: auto;
|
|
margin: 0 0 16px;
|
|
}
|
|
.read-article pre code { background: none; padding: 0; }
|
|
.read-article blockquote {
|
|
border-left: 3px solid var(--accent);
|
|
padding-left: 14px;
|
|
color: var(--muted);
|
|
margin: 0 0 16px;
|
|
}
|
|
.read-article img {
|
|
max-width: 100%;
|
|
height: auto;
|
|
border-radius: var(--radius);
|
|
margin: 12px 0;
|
|
}
|
|
.read-article hr {
|
|
border: none;
|
|
border-top: 1px solid var(--border);
|
|
margin: 28px 0;
|
|
}
|
|
.read-article table {
|
|
border-collapse: collapse;
|
|
margin: 0 0 16px;
|
|
width: 100%;
|
|
}
|
|
.read-article th, .read-article td {
|
|
border: 1px solid var(--border);
|
|
padding: 8px 10px;
|
|
text-align: left;
|
|
}
|
|
|
|
/* Mobile: pad tighter, bump touch targets */
|
|
@media (max-width: 640px) {
|
|
.read-article { font-size: 16px; padding: 20px 16px 96px; }
|
|
.read-article h1.read-title { font-size: 22px; }
|
|
.read-reader { inset: 52px 0 0 0; }
|
|
.read-reader-btn { width: 40px; height: 40px; font-size: 18px; }
|
|
.read-item-thumb { width: 52px; height: 52px; }
|
|
}
|