taper / client /style.css
abr00kx's picture
Upload Taper: hardened ephemeral E2EE messaging protocol (Matrix hard fork)
d40e568 verified
Raw History Blame Contribute Delete
13.7 kB
:root {
--bg: #faf7f5;
--panel: #ffffff;
--text: #1b1520;
--muted: #6e6474;
--line: #ece4e6;
--accent: #d81b5c;
--accent-text: #ffffff;
--accent-soft: #fde8ef;
--danger: #b42318;
--warn-bg: #fff4e5;
--warn-text: #6b3a00;
--own: linear-gradient(135deg, #ff6a3d, #e8286a);
--own-text: #ffffff;
--other: #f1ecef;
--radius: 18px;
color-scheme: light;
}
@media (prefers-color-scheme: dark) {
:root {
--bg: #110d14;
--panel: #19141d;
--text: #f1ebf3;
--muted: #a097a7;
--line: #2b2330;
--accent: #ff5c8a;
--accent-text: #1a0610;
--accent-soft: #3a1726;
--danger: #ff8a80;
--warn-bg: #2e1f0c;
--warn-text: #ffd59a;
--own: linear-gradient(135deg, #e85a2c, #c81d5c);
--own-text: #ffffff;
--other: #241d29;
color-scheme: dark;
}
}
* { box-sizing: border-box; }
html, body { height: 100%; }
body {
margin: 0;
display: flex;
flex-direction: column;
background: var(--bg);
color: var(--text);
font: 15px/1.45 "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
-webkit-font-smoothing: antialiased;
}
[hidden] { display: none !important; }
.mono { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: 0.85em; }
.dev-banner {
background: var(--warn-bg);
color: var(--warn-text);
padding: 6px 16px;
font-size: 13px;
text-align: center;
border-bottom: 1px solid var(--line);
}
button {
font: inherit;
border: 0;
border-radius: 8px;
padding: 8px 14px;
background: var(--accent);
color: var(--accent-text);
cursor: pointer;
}
button.secondary { background: transparent; color: var(--text); border: 1px solid var(--line); }
button.link { background: none; color: var(--accent); padding: 0; border-radius: 0; }
button:disabled { opacity: 0.5; cursor: default; }
button:focus-visible, input:focus-visible, textarea:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
input, textarea, select {
font: inherit;
color: inherit;
background: var(--bg);
border: 1px solid var(--line);
border-radius: 8px;
padding: 8px 10px;
width: 100%;
}
.room-policy { padding: 6px 0; border-bottom: 1px solid var(--line); margin-bottom: 4px; }
.pw-weak { color: var(--danger); }
.pw-strong { color: #2fb36d; }
.error { color: var(--danger); min-height: 1.4em; margin: 0; }
/* Login */
.login { flex: 1; display: grid; place-items: center; padding: 16px; }
.card {
width: min(380px, 100%);
background: var(--panel);
border: 1px solid var(--line);
border-radius: 14px;
padding: 24px;
display: grid;
gap: 14px;
}
.card h1 { margin: 0; font-size: 26px; letter-spacing: -0.02em; }
.card label { display: grid; gap: 4px; font-size: 13px; color: var(--muted); }
.row { display: flex; gap: 8px; }
/* App */
.app { flex: 1; display: flex; min-height: 0; }
.sidebar {
width: 280px;
flex-shrink: 0;
background: var(--panel);
border-right: 1px solid var(--line);
padding: 14px;
overflow-y: auto;
display: grid;
grid-template-columns: minmax(0, 1fr);
align-content: start;
gap: 16px;
}
.sidebar > * { min-width: 0; }
.me { display: flex; align-items: center; gap: 8px; }
.me .mono { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.status { width: 10px; height: 10px; border-radius: 50%; background: var(--muted); flex-shrink: 0; }
.status.online { background: #2fb36d; }
.status.connecting { background: #e0a100; }
.sidebar h2 { font-size: 12px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); margin: 0 0 6px; }
.list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 2px; }
.list li button {
width: 100%;
text-align: left;
background: none;
color: var(--text);
padding: 7px 10px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.list li button[aria-current="true"] { background: var(--own); }
.list .invite { display: grid; gap: 6px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; }
.list .invite .row button { padding: 4px 10px; }
.list .none { color: var(--muted); font-size: 13px; padding: 0 10px; }
.tools summary { cursor: pointer; color: var(--muted); font-size: 13px; }
.tools form { display: grid; gap: 8px; margin-top: 8px; }
.check { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.check input { width: auto; }
.room { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.room .empty { margin: auto; color: var(--muted); }
#room-pane { display: flex; flex-direction: column; flex: 1; min-height: 0; }
.room-header {
display: flex;
align-items: center;
gap: 12px;
flex-wrap: wrap;
padding: 12px 16px;
border-bottom: 1px solid var(--line);
background: var(--panel);
}
.room-header > div { flex: 1; min-width: 0; }
.room-header h2 { margin: 0; font-size: 17px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.inline { display: flex; gap: 6px; }
.inline input { width: 200px; }
.timeline { flex: 1; overflow-y: auto; padding: 12px 16px; }
#load-older { display: block; margin: 0 auto 12px; }
#events { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.msg { padding: 6px 10px; border-radius: 10px; max-width: 72ch; position: relative; }
.msg.own { background: var(--own); justify-self: end; }
.msg .meta { display: flex; gap: 8px; align-items: baseline; font-size: 12px; color: var(--muted); }
.msg .sender { font-weight: 600; }
.msg .body { white-space: pre-wrap; overflow-wrap: anywhere; }
.msg .delete { font-size: 12px; visibility: hidden; }
.msg:hover .delete, .msg:focus-within .delete { visibility: visible; }
.msg.warn .body { color: var(--danger); font-style: italic; }
.msg.gone .body, .msg.pending .body { color: var(--muted); font-style: italic; }
.system { text-align: center; font-size: 12px; color: var(--muted); }
.composer { display: flex; gap: 8px; padding: 12px 16px; border-top: 1px solid var(--line); background: var(--panel); }
.composer textarea { resize: none; max-height: 160px; }
.toasts { position: fixed; bottom: 16px; left: 50%; transform: translateX(-50%); display: grid; gap: 8px; z-index: 10; }
.toast { background: var(--text); color: var(--bg); padding: 8px 14px; border-radius: 8px; font-size: 14px; max-width: min(480px, 90vw); }
@media (max-width: 720px) {
.app { flex-direction: column; }
.sidebar { width: auto; border-right: 0; border-bottom: 1px solid var(--line); max-height: 40vh; }
.inline input { width: 140px; }
}
/* Trust and verification */
.badge { font-size: 11px; padding: 1px 6px; border-radius: 999px; border: 1px solid var(--line); color: var(--muted); white-space: nowrap; }
.badge.verified { color: #2fb36d; border-color: #2fb36d; }
.badge.changed, .badge.violation, .badge.warning { color: var(--danger); border-color: var(--danger); }
.warnings { padding: 0 16px; }
.warnings .warning { margin: 8px 0; padding: 8px 12px; border: 1px solid var(--danger); border-radius: 8px; color: var(--danger); background: var(--panel); }
.members { padding: 6px 16px; border-bottom: 1px solid var(--line); background: var(--panel); }
.members summary { cursor: pointer; color: var(--muted); font-size: 13px; }
.members .member { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; padding: 4px 0; }
.overlay { position: fixed; inset: 0; background: rgb(0 0 0 / 50%); display: grid; place-items: center; z-index: 20; padding: 16px; }
.dialog { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 20px; width: min(520px, 100%); display: grid; gap: 12px; }
.dialog h3 { margin: 0; }
.emoji { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(64px, 1fr)); gap: 8px; text-align: center; }
.emoji .symbol { display: block; font-size: 32px; }
.emoji .label { font-size: 12px; color: var(--muted); }
.verified { color: #2fb36d; }
/* Attachments */
.attachment { display: block; max-width: min(360px, 100%); max-height: 320px; margin-top: 6px; border-radius: 8px; }
.attachment-load, .attachment-link { font-size: 13px; margin-top: 4px; display: inline-block; }
.dev-banner.blocked {
background: #7a1d1d;
color: #fff;
}
/* Settings, device lock, security keys */
.muted { color: var(--muted); font-size: 12px; }
.dialog.settings { max-height: calc(100vh - 32px); overflow-y: auto; align-content: start; }
.dialog.settings section { display: grid; gap: 8px; padding-top: 12px; border-top: 1px solid var(--line); }
.dialog.settings label { display: grid; gap: 4px; font-size: 13px; color: var(--muted); }
.dialog.settings label.check { display: flex; }
.dialog-head { display: flex; justify-content: space-between; align-items: center; }
.dialog-head h2 { margin: 0; font-size: 18px; }
.card label.check { display: flex; align-items: center; }
#device-pass-row { display: grid; gap: 4px; }
.keyrow { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; padding: 4px 0; }
.keyrow .name { flex: 1; min-width: 8ch; overflow-wrap: anywhere; }
.badge.hw { color: #2f6fb3; border-color: #2f6fb3; }
.badge.hw.unattested { color: var(--muted); border-color: var(--line); }
.me .link { font-size: 13px; }
.list li.keyrow button { width: auto; padding: 0 4px; }
/* ---- Look and feel ---------------------------------------------------- */
.dev-banner { padding: 5px 16px; font-size: 12px; }
button { border-radius: 999px; padding: 9px 18px; font-weight: 600; transition: filter .15s, background .15s; }
button:hover:not(:disabled) { filter: brightness(1.06); }
button.secondary { font-weight: 500; }
button.secondary:hover:not(:disabled) { background: var(--accent-soft); filter: none; }
input, textarea { border-radius: 12px; background: var(--panel); }
input:focus, textarea:focus { border-color: var(--accent); outline: none; }
/* Brand */
.brand { display: flex; align-items: center; gap: 10px; }
.brand .mark { width: 44px; height: 44px; flex-shrink: 0; filter: drop-shadow(0 4px 12px rgb(232 40 106 / 30%)); }
.brand h1, .brand .wordmark { margin: 0; font-size: 30px; font-weight: 800; letter-spacing: -0.04em; }
.brand.small .mark { width: 28px; height: 28px; filter: none; }
.brand.small .wordmark { font-size: 20px; }
.tagline { margin: -6px 0 4px; color: var(--muted); }
/* Login */
.login { background: radial-gradient(1200px 600px at 50% -10%, var(--accent-soft), transparent 70%); }
.card { width: min(400px, 100%); padding: 32px; gap: 16px; border-radius: 24px; box-shadow: 0 20px 60px -20px rgb(40 10 30 / 25%); }
.card .row button { flex: 1; }
.advanced summary { cursor: pointer; color: var(--muted); font-size: 13px; }
.advanced label { margin-top: 8px; }
/* Avatars */
.avatar {
width: 32px; height: 32px; border-radius: 50%; flex-shrink: 0;
display: inline-grid; place-items: center;
font-size: 14px; font-weight: 700; color: #fff;
background: #8a7f8f;
}
.hue-0 { background: #e8286a; } .hue-1 { background: #ff6a3d; } .hue-2 { background: #c28a00; }
.hue-3 { background: #1f9d6b; } .hue-4 { background: #1d8fbf; } .hue-5 { background: #5b5bd6; }
.hue-6 { background: #9b3fc9; } .hue-7 { background: #c2417a; }
/* Sidebar */
.sidebar { width: 288px; padding: 16px 12px; gap: 18px; }
.sidebar .brand { padding: 0 6px; }
.me { padding: 8px; border-radius: 14px; background: var(--bg); flex-wrap: wrap; }
.me .avatar { width: 28px; height: 28px; font-size: 13px; }
.me .mono { flex: 1 1 0; }
.sidebar h2 { padding: 0 8px; }
.list li button { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 12px; font-weight: 500; }
.list li button .name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.list li button:hover { background: var(--bg); filter: none; }
.list li button[aria-current="true"] { background: var(--accent-soft); color: var(--accent); }
.list .invite { border-radius: 14px; }
.tools { padding: 0 8px; }
/* Room */
.room-header { padding: 14px 20px; }
.room-header h2 { font-size: 18px; font-weight: 700; }
#room-id { font-size: 11px; color: var(--muted); }
.inline input { border-radius: 999px; }
.timeline { padding: 16px 20px; }
#events { gap: 2px; }
.msg {
display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 10px;
padding: 0; background: none; max-width: min(72ch, 80%); margin-top: 10px;
}
.msg > .avatar { grid-row: span 3; align-self: end; }
.msg > :not(.avatar) { grid-column: 2; }
.msg .meta { padding: 0 12px 2px; }
.msg .body { background: var(--other); padding: 8px 14px; border-radius: var(--radius); border-bottom-left-radius: 6px; justify-self: start; }
.msg.own { grid-template-columns: minmax(0, 1fr); justify-self: end; background: none; }
.msg.own > * { grid-column: 1; }
.msg.own .meta { justify-content: flex-end; }
.msg.own .body { background: var(--own); color: var(--own-text); justify-self: end; border-radius: var(--radius); border-bottom-right-radius: 6px; }
.msg.own.gone .body, .msg.own.pending .body { background: var(--other); color: var(--muted); }
.msg.cont { margin-top: 0; }
.msg.cont .meta .sender, .msg.cont .meta time, .msg.cont .meta .expiry { display: none; }
.msg.cont > .avatar { visibility: hidden; }
.msg .expiry::before { content: "🔥 "; }
.msg .attachment { border-radius: 14px; }
.system { margin: 10px 0 4px; }
.composer { align-items: flex-end; padding: 12px 20px 16px; border-top: 0; background: var(--bg); }
.composer textarea { border-radius: 22px; padding: 10px 16px; background: var(--panel); }
.composer #attach { padding: 9px 12px; }
.dialog { border-radius: 20px; padding: 24px; }
.msg.cont .meta { position: absolute; top: 50%; transform: translateY(-50%); left: 100%; padding: 0 8px; white-space: nowrap; }
.msg.own.cont .meta { left: auto; right: 100%; }