Files
MaalFlows/public/admin.css
T

1594 lines
35 KiB
CSS

:root {
color-scheme: light;
font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
--line: #dfe6e2;
--ink: #17211d;
--muted: #627067;
--brand: #0f8f6f;
--bg: #f5f7f4;
--panel: #ffffff;
--topbar-height: 58px;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); overflow: hidden; }
button, input, textarea, select { font: inherit; }
button {
border: 0;
background: var(--brand);
color: white;
border-radius: 6px;
padding: 10px 14px;
cursor: pointer;
}
button:hover { filter: brightness(0.96); }
input, textarea, select {
width: 100%;
border: 1px solid var(--line);
border-radius: 6px;
padding: 9px 10px;
background: white;
color: var(--ink);
}
input[type="color"] {
width: 100%;
height: 44px;
padding: 4px;
cursor: pointer;
}
input[type="color"]::-webkit-color-swatch-wrapper { padding: 0; }
input[type="color"]::-webkit-color-swatch {
border: 0;
border-radius: 4px;
}
label { display: grid; gap: 6px; color: var(--muted); font-size: 13px; }
.hidden { display: none !important; }
.shell { min-height: 100vh; }
.login { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.panel {
width: min(360px, 100%);
display: grid;
gap: 14px;
background: white;
border: 1px solid var(--line);
border-radius: 8px;
padding: 24px;
}
.panel h1 { margin: 0 0 6px; }
.error { min-height: 20px; color: #b42318; margin: 0; }
.app {
height: 100vh;
min-height: 0;
display: grid;
grid-template-columns: 330px minmax(0, 1fr) 320px;
overflow: hidden;
}
.sidebar {
border-right: 1px solid var(--line);
background: var(--panel);
display: grid;
grid-template-rows: auto auto minmax(0, 1fr);
min-height: 0;
overflow: hidden;
}
.brand {
height: var(--topbar-height);
display: flex;
align-items: center;
justify-content: space-between;
gap: 6px;
padding: 10px;
border-bottom: 1px solid var(--line);
}
.brand h1 { margin: 0; font-size: 18px; }
.brand-actions {
display: inline-flex;
align-items: center;
gap: 5px;
flex: 0 0 auto;
}
.brand button { background: #edf3ef; color: var(--ink); }
.icon-button {
width: 32px;
height: 32px;
padding: 0;
display: grid;
place-items: center;
}
.icon-button svg {
width: 18px;
height: 18px;
fill: currentColor;
}
.admin-sound-control {
height: 32px;
display: inline-flex;
align-items: center;
gap: 6px;
padding: 0 5px 0 0;
border-radius: 6px;
background: #edf3ef;
}
.admin-sound-control .sound-off { display: none; }
.admin-sound-control .muted .sound-on { display: none; }
.admin-sound-control .muted .sound-off { display: block; }
.admin-sound-control input[type="range"] {
width: 42px;
height: 4px;
padding: 0;
border: 0;
accent-color: var(--brand);
cursor: pointer;
}
.logout-compact {
height: 32px;
padding: 0;
}
.online-dot-toggle {
width: 28px;
height: 32px;
display: grid;
place-items: center;
cursor: pointer;
}
.online-dot-toggle input {
position: absolute;
opacity: 0;
pointer-events: none;
}
.online-dot-toggle span {
width: 11px;
height: 11px;
border-radius: 50%;
background: #c9d4ce;
box-shadow: 0 0 0 4px rgb(201 212 206 / 25%);
}
.online-dot-toggle input:checked + span {
background: #2f9e44;
box-shadow: 0 0 0 4px rgb(47 158 68 / 16%);
}
.switch { display: flex; align-items: center; gap: 8px; }
.switch input { width: auto; }
.setting-switch {
display: flex;
align-items: center;
gap: 10px;
justify-content: space-between;
flex-direction: row-reverse;
border: 1px solid var(--line);
border-radius: 8px;
padding: 10px 12px;
background: #f8fbf9;
color: var(--ink);
}
.setting-switch input {
appearance: none;
width: 42px;
min-width: 42px;
max-width: 42px;
flex: 0 0 42px;
height: 24px;
border: 0;
border-radius: 999px;
padding: 0;
background: #cbd6d0;
position: relative;
cursor: pointer;
}
.setting-switch input:before {
position: absolute;
top: 3px;
left: 3px;
width: 18px;
height: 18px;
border-radius: 50%;
background: white;
content: "";
transition: transform .16s ease;
}
.setting-switch input:checked { background: var(--brand); }
.setting-switch input:checked:before { transform: translateX(18px); }
.color-field input { margin-top: 2px; }
.color-row {
display: grid;
grid-template-columns: 58px minmax(0, 1fr);
gap: 8px;
align-items: center;
}
.color-row input[type="color"] {
width: 58px;
}
.hex-input {
font-family: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace;
text-transform: lowercase;
}
.effect-settings {
margin: 0;
padding: 10px 12px;
display: grid;
grid-template-columns: repeat(2, minmax(0, 1fr));
gap: 8px 10px;
border: 1px solid var(--line);
border-radius: 8px;
background: #f8fbf9;
}
.effect-settings legend {
padding: 0 4px;
color: var(--muted);
font-size: 13px;
}
.effect-settings label {
display: flex;
align-items: center;
gap: 7px;
min-width: 0;
color: var(--ink);
font-size: 12px;
}
.effect-settings input {
width: auto;
margin: 0;
}
.launcher-preview-stage {
grid-column: 1 / -1;
min-height: 112px;
display: grid;
place-items: center;
border: 1px solid var(--line);
border-radius: 8px;
background:
linear-gradient(90deg, rgb(15 143 111 / 5%) 1px, transparent 1px),
linear-gradient(rgb(15 143 111 / 5%) 1px, transparent 1px),
#ffffff;
background-size: 18px 18px;
}
.launcher-preview {
--preview-brand: var(--brand);
--preview-text: #ffffff;
position: relative;
width: 58px;
height: 58px;
display: grid;
place-items: center;
border: 0;
border-radius: 50%;
background: var(--preview-brand);
color: var(--preview-text);
box-shadow: 0 12px 30px rgb(0 0 0 / 22%);
cursor: default;
overflow: visible;
}
.launcher-preview.effect-breathe {
animation: launcherPreviewBreathe 2.8s ease-in-out infinite;
}
.launcher-preview.effect-ring::before {
position: absolute;
inset: -5px;
border: 2px solid var(--preview-brand);
border-radius: 50%;
opacity: .62;
content: "";
animation: launcherPreviewRing 2.2s ease-out infinite;
}
.launcher-preview.notify-pulse::after {
position: absolute;
inset: 0;
border-radius: 50%;
pointer-events: none;
content: "";
animation: launcherPreviewPulse 1.15s ease-out infinite;
}
.launcher-preview.notify-wiggle .launcher-preview-icon {
animation: launcherPreviewWiggle .62s ease-in-out infinite;
}
.launcher-preview-status {
position: absolute;
top: -3px;
left: -3px;
width: 14px;
height: 14px;
border: 2px solid #ffffff;
border-radius: 50%;
background: #c9d4ce;
box-shadow: 0 0 0 4px rgb(201 212 206 / 24%);
}
.launcher-preview.online .launcher-preview-status {
background: #2f9e44;
box-shadow: 0 0 0 4px rgb(47 158 68 / 16%);
}
.launcher-preview-badge {
position: absolute;
top: -5px;
right: -5px;
min-width: 22px;
height: 22px;
display: none;
place-items: center;
border: 2px solid #ffffff;
border-radius: 999px;
background: #ff3b30;
color: #ffffff;
font-size: 12px;
font-weight: 800;
line-height: 1;
box-shadow: 0 8px 18px rgb(0 0 0 / 18%);
}
.launcher-preview.show-badge .launcher-preview-badge {
display: grid;
}
.launcher-preview-label {
position: absolute;
right: 68px;
top: 50%;
max-width: 150px;
padding: 7px 10px;
border-radius: 999px;
background: var(--ink);
color: #ffffff;
font-size: 12px;
white-space: nowrap;
box-shadow: 0 10px 24px rgb(0 0 0 / 18%);
opacity: 0;
transform: translateY(-50%) translateX(8px);
transition: opacity .18s ease, transform .18s ease;
}
.launcher-preview.show-label .launcher-preview-label {
opacity: 1;
transform: translateY(-50%) translateX(0);
}
.launcher-preview-icon,
.launcher-preview-icon::before,
.launcher-preview-icon::after {
display: block;
content: "";
}
.launcher-preview-icon {
position: relative;
margin: 0 auto;
color: var(--preview-text);
}
.preview-shape-circle .launcher-preview-icon,
.preview-shape-circle .launcher-preview-icon::before,
.preview-shape-circle .launcher-preview-icon::after {
height: 3px;
border-radius: 4px;
background: var(--preview-text);
}
.preview-shape-circle .launcher-preview-icon {
width: 26px;
}
.preview-shape-circle .launcher-preview-icon::before {
transform: translateY(-8px);
}
.preview-shape-circle .launcher-preview-icon::after {
width: 18px;
transform: translateY(5px);
}
.preview-shape-bubble .launcher-preview-icon {
width: 30px;
height: 23px;
border: 3px solid var(--preview-text);
border-radius: 13px;
background: transparent;
}
.preview-shape-bubble .launcher-preview-icon::before {
position: absolute;
left: 5px;
top: 7px;
width: 4px;
height: 4px;
border-radius: 50%;
background: var(--preview-text);
box-shadow: 8px 0 0 var(--preview-text), 16px 0 0 var(--preview-text);
}
.preview-shape-bubble .launcher-preview-icon::after {
position: absolute;
right: 2px;
bottom: -8px;
width: 10px;
height: 10px;
border-left: 3px solid var(--preview-text);
border-bottom: 3px solid var(--preview-text);
border-bottom-left-radius: 8px;
background: transparent;
transform: rotate(-18deg);
}
.preview-shape-messenger .launcher-preview-icon {
width: 32px;
height: 32px;
border-radius: 50%;
background: var(--preview-text);
}
.preview-shape-messenger .launcher-preview-icon::before {
position: absolute;
left: 8px;
top: 8px;
width: 16px;
height: 16px;
background: var(--preview-brand);
clip-path: polygon(0 56%, 42% 56%, 58% 22%, 100% 22%, 58% 78%, 42% 78%);
}
.preview-shape-messenger .launcher-preview-icon::after {
position: absolute;
right: 5px;
bottom: 1px;
width: 8px;
height: 8px;
border-radius: 0 0 8px 0;
background: var(--preview-text);
transform: rotate(25deg);
}
.preview-shape-whatsapp .launcher-preview-icon {
width: 32px;
height: 32px;
border: 3px solid var(--preview-text);
border-radius: 50%;
background: transparent;
}
.preview-shape-whatsapp .launcher-preview-icon::before {
position: absolute;
left: 8px;
top: 7px;
width: 12px;
height: 15px;
border: 3px solid var(--preview-text);
border-left-color: transparent;
border-top-color: transparent;
border-radius: 0 0 12px 0;
transform: rotate(-35deg);
}
.preview-shape-whatsapp .launcher-preview-icon::after {
position: absolute;
left: 1px;
bottom: -4px;
width: 10px;
height: 10px;
border-left: 3px solid var(--preview-text);
border-bottom: 3px solid var(--preview-text);
background: transparent;
transform: rotate(12deg);
}
@keyframes launcherPreviewBreathe {
0%, 100% { transform: scale(1); box-shadow: 0 12px 30px rgb(0 0 0 / 22%); }
50% { transform: scale(1.035); box-shadow: 0 16px 36px rgb(0 0 0 / 20%), 0 0 0 8px rgb(15 143 111 / 10%); }
}
@keyframes launcherPreviewRing {
0% { transform: scale(.92); opacity: .58; }
70% { transform: scale(1.22); opacity: 0; }
100% { transform: scale(.92); opacity: 0; }
}
@keyframes launcherPreviewPulse {
0% { box-shadow: 0 0 0 0 rgb(255 59 48 / 46%); opacity: .9; transform: scale(1); }
70% { box-shadow: 0 0 0 18px rgb(255 59 48 / 0%); opacity: 0; transform: scale(1.08); }
100% { box-shadow: 0 0 0 0 rgb(255 59 48 / 0%); opacity: 0; transform: scale(1); }
}
@keyframes launcherPreviewWiggle {
0%, 100% { transform: translateY(0) rotate(0deg); }
22% { transform: translateY(-3px) rotate(-4deg); }
48% { transform: translateY(2px) rotate(3deg); }
72% { transform: translateY(-1px) rotate(-2deg); }
}
.widget-language-settings {
grid-template-columns: 112px minmax(230px, 1fr);
}
.effect-settings .full-row,
.effect-settings .ai-help,
.widget-language-settings small {
grid-column: 1 / -1;
}
.widget-copy-settings label {
grid-column: 1 / -1;
display: grid;
align-items: stretch;
}
.widget-copy-settings input,
.widget-copy-settings textarea,
.widget-language-settings select {
width: 100%;
}
.language-select {
position: relative;
display: block;
}
.native-language-select {
position: absolute;
width: 1px;
height: 1px;
opacity: 0;
pointer-events: none;
}
.language-picker {
position: relative;
width: 100%;
height: 38px;
padding: 0 30px 0 11px;
display: flex;
align-items: center;
gap: 8px;
border: 1px solid var(--line);
border-radius: 7px;
background: white;
color: var(--ink);
font-size: 13px;
text-align: left;
}
.language-picker::after {
content: "";
position: absolute;
right: 11px;
top: 50%;
width: 7px;
height: 7px;
border-right: 1px solid var(--muted);
border-bottom: 1px solid var(--muted);
transform: translateY(-50%);
rotate: 45deg;
}
.language-picker span:last-child {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.language-menu {
position: absolute;
z-index: 20;
top: calc(100% + 5px);
left: 0;
right: auto;
width: max(100%, 280px);
max-height: 230px;
overflow: auto;
padding: 5px;
border: 1px solid var(--line);
border-radius: 8px;
background: white;
box-shadow: 0 14px 30px rgb(23 33 29 / 14%);
}
.language-option {
width: 100%;
min-height: 32px;
padding: 6px 8px;
display: flex;
align-items: center;
gap: 8px;
border: 0;
border-radius: 6px;
background: transparent;
color: var(--ink);
font-size: 13px;
text-align: left;
}
.language-option:hover,
.language-option.active {
background: #eaf6f1;
color: var(--brand);
}
.language-option span:last-child {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.language-picker .flag-image,
.language-option .flag-image {
flex: 0 0 auto;
}
.effect-settings .full-row {
display: grid;
align-items: stretch;
}
.effect-settings .setting-switch.full-row {
display: flex;
align-items: center;
}
.telegram-settings input:not([type="checkbox"]) {
width: 100%;
}
.sound-settings input[type="range"] {
width: 100%;
padding: 0;
accent-color: var(--brand);
}
.settings-top-row {
grid-column: 1 / -1;
display: grid;
grid-template-columns: 1fr;
gap: 8px;
}
.settings-top-row .setting-switch {
min-height: 39px;
padding: 8px 10px;
}
.settings-top-row label:not(.setting-switch) {
display: grid;
gap: 6px;
}
.settings-top-row select,
.settings-top-row input:not([type="checkbox"]) {
width: 100%;
}
.settings-actions {
display: flex;
align-items: center;
gap: 10px;
grid-column: 1 / -1;
}
.settings-save-status {
min-height: 18px;
color: var(--muted);
font-size: 12px;
font-weight: 700;
}
.settings-save-status.saving::before,
.settings-save-status.translating::before {
content: "";
display: inline-block;
width: 10px;
height: 10px;
margin-right: 6px;
border: 2px solid rgba(15, 143, 111, .25);
border-top-color: var(--brand);
border-radius: 50%;
vertical-align: -2px;
animation: mfSpin .8s linear infinite;
}
.settings-save-status.saved { color: var(--brand); }
.settings-save-status.warning { color: #b7791f; }
.settings-save-status.error { color: #b42318; }
@keyframes mfSpin {
to { transform: rotate(360deg); }
}
.ai-help {
margin: 0;
color: var(--muted);
font-size: 12px;
line-height: 1.4;
}
.ai-help a {
color: var(--brand);
font-weight: 700;
}
.effect-settings input[type="password"],
.effect-settings select {
width: 100%;
}
.effect-settings small {
color: var(--muted);
font-size: 11px;
}
.model-row {
display: grid;
grid-template-columns: minmax(0, 1fr) auto;
gap: 8px;
align-items: center;
}
.model-row button {
height: 38px;
padding: 0 10px;
}
.ai-actions {
grid-column: 1 / -1;
display: grid;
grid-template-columns: repeat(2, minmax(0, 1fr));
gap: 8px;
}
.ai-actions button {
padding: 10px 12px;
}
.ai-actions button:last-child {
background: #edf3ef;
color: var(--ink);
}
.admin-users-settings {
margin-top: 14px;
}
.admin-user-form {
grid-column: 1 / -1;
display: grid;
grid-template-columns: 1fr;
gap: 9px;
padding: 10px;
border: 1px solid var(--line);
border-radius: 8px;
background: #fbfdfb;
}
.admin-user-form label {
display: grid;
grid-template-columns: 86px minmax(0, 1fr);
align-items: center;
gap: 10px;
min-width: 0;
}
.admin-user-form label span {
color: var(--ink);
font-size: 13px;
}
.admin-user-form input {
width: 100%;
min-width: 0;
}
.admin-user-form button {
grid-column: 1 / -1;
}
.admin-user-form button {
padding: 10px 12px;
}
.admin-users-list {
grid-column: 1 / -1;
display: grid;
gap: 8px;
}
.admin-user-item {
display: grid;
grid-template-columns: minmax(0, 1fr);
align-items: center;
gap: 8px;
padding: 10px;
border: 1px solid var(--line);
border-radius: 8px;
background: #fff;
}
.admin-user-item div {
display: grid;
gap: 2px;
min-width: 0;
}
.admin-user-item span {
color: var(--muted);
font-size: 12px;
}
.admin-user-item .admin-user-actions {
display: flex;
flex-wrap: wrap;
align-items: center;
gap: 6px;
}
.admin-user-item button {
padding: 6px 8px;
border-radius: 6px;
font-size: 12px;
}
.password-mask {
display: inline-flex;
align-items: center;
min-height: 30px;
padding: 0 4px 0 0;
font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
letter-spacing: 1px;
color: var(--muted);
}
.admin-user-item button:disabled {
opacity: .45;
cursor: not-allowed;
}
#adminUsersStatus {
grid-column: 1 / -1;
}
@media (max-width: 720px) {
.admin-user-form label {
grid-template-columns: 1fr;
gap: 5px;
}
}
.list-tools {
padding: 10px 14px;
border-bottom: 1px solid var(--line);
background: #fbfdfb;
}
.list-tools label { color: var(--muted); }
.conversation-list { overflow: auto; min-height: 0; }
.conversation-item {
border: 0;
border-bottom: 1px solid var(--line);
border-left: 3px solid transparent;
background: white;
color: var(--ink);
border-radius: 0;
padding: 10px 10px 10px 7px;
display: grid;
grid-template-columns: minmax(0, 1fr) auto;
gap: 8px;
align-items: start;
}
.conversation-item.active {
background: #edf8f3;
border-left-color: var(--brand);
}
.conversation-item.fresh { animation: pulse 1.2s ease-in-out 4; }
.conversation-item.unread { background: #fffdf4; }
.conversation-item.unread.active { background: #edf8f3; }
.conversation-open {
min-width: 0;
text-align: left;
display: grid;
gap: 5px;
border: 0;
background: transparent;
color: var(--ink);
border-radius: 6px;
padding: 2px;
}
.conversation-open:hover { filter: none; background: #f3f7f4; }
.row { display: flex; justify-content: space-between; gap: 10px; align-items: center; }
.visitor-row { min-width: 0; }
.visitor-name-wrap {
min-width: 0;
display: inline-flex;
align-items: center;
gap: 7px;
}
.visitor-name-wrap strong {
min-width: 0;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.visitor-name-wrap .presence-dot {
flex: 0 0 auto;
}
.unread-dot {
width: 9px;
height: 9px;
flex: 0 0 auto;
border-radius: 50%;
background: #c9d4ce;
}
.conversation-item.unread .unread-dot {
background: #ff3b30;
box-shadow: 0 0 0 0 rgb(255 59 48 / 55%);
animation: unreadPulse 1.25s ease-out infinite;
}
.status {
font-size: 12px;
color: white;
background: #456257;
border-radius: 999px;
padding: 2px 8px;
}
.photo-count {
flex: 0 0 auto;
color: var(--brand);
font-size: 12px;
}
.snippet, .preview, .meta { color: var(--muted); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.visitor-facts {
display: flex;
flex-wrap: wrap;
gap: 4px;
color: var(--muted);
font-size: 11px;
}
.visitor-facts > span {
max-width: 96px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
border: 1px solid #e4ebe6;
border-radius: 999px;
padding: 2px 6px;
background: #f8fbf9;
}
.conversation-actions {
grid-column: 1 / -1;
display: grid;
grid-template-columns: repeat(3, minmax(0, 1fr)) 34px;
gap: 6px;
}
.status-button {
height: 34px;
padding: 0 6px;
font-size: 11px;
background: #f4f7f5;
color: var(--muted);
border: 1px solid var(--line);
white-space: nowrap;
}
.status-button.active {
color: white;
border-color: transparent;
}
.status-button.new.active { background: #2f9e44; }
.status-button.open.active { background: #2f80ed; }
.status-button.resolved.active { background: #68736c; }
.delete-chat {
width: 34px;
height: 34px;
padding: 0;
display: grid;
place-items: center;
background: #fff1f0;
color: #b42318;
}
.delete-chat svg { width: 18px; height: 18px; fill: currentColor; }
.empty-list {
margin: 0;
padding: 18px 14px;
color: var(--muted);
font-size: 13px;
}
.conversation { display: grid; grid-template-rows: auto minmax(0, 1fr) auto auto; min-width: 0; min-height: 0; overflow: hidden; }
.conversation-header {
height: var(--topbar-height);
overflow: visible;
padding: 12px 20px;
background: white;
border-bottom: 1px solid var(--line);
display: flex;
align-items: center;
justify-content: space-between;
gap: 20px;
}
.conversation-header h2 { margin: 0; font-size: 20px; }
.conversation-header p { margin: 0; color: var(--muted); font-size: 13px; }
.conversation-header select { width: 150px; align-self: start; }
.visitor-head { width: 100%; min-width: 0; display: grid; gap: 7px; }
.visitor-summary-row .operator-presence {
max-width: 240px;
border-color: #dfe9e4;
color: var(--muted);
overflow: hidden;
text-overflow: ellipsis;
}
.visitor-summary-row .operator-presence.hidden { display: none; }
.visitor-summary-row .operator-presence.typing {
border-color: #f7d8a8;
background: #fff8ed;
color: #8a5a00;
}
.visitor-summary-row {
display: flex;
align-items: center;
flex-wrap: nowrap;
gap: 7px;
min-width: 0;
color: var(--muted);
font-size: 12px;
}
.visitor-name-edit {
min-width: 0;
margin: 0 4px 0 0;
padding: 0;
display: inline-flex;
align-items: center;
gap: 7px;
border: 0;
background: transparent;
color: var(--ink);
font-size: 20px;
font-weight: 800;
line-height: 1.2;
}
.visitor-name-edit:hover {
background: transparent;
color: var(--brand);
filter: none;
}
.visitor-name-edit span {
min-width: 0;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.visitor-name-edit svg {
width: 15px;
height: 15px;
flex: 0 0 auto;
fill: currentColor;
opacity: .64;
}
.visitor-summary-row > span {
border: 1px solid #e4ebe6;
border-radius: 999px;
padding: 2px 7px;
background: #f8fbf9;
white-space: nowrap;
}
.visitor-summary-row .country-pill {
display: inline-flex;
align-items: center;
gap: 5px;
border-color: #d9e6df;
background: #fbfdfb;
}
.country-badge {
display: inline-flex;
align-items: center;
gap: 5px;
min-width: 0;
}
.flag-image {
width: 18px;
height: 13px;
flex: 0 0 auto;
border-radius: 2px;
background-color: #e4ebe6;
background-position: center;
background-size: cover;
box-shadow: 0 0 0 1px rgb(0 0 0 / 8%);
}
.country-badge.unknown .flag-image {
width: auto;
height: auto;
background: transparent;
box-shadow: none;
}
.country-badge strong {
color: var(--muted);
font-size: 11px;
line-height: 1;
}
.visitor-summary-row .presence-dot {
border: 0;
padding: 0;
background: #c9d4ce;
}
.visitor-summary-row .presence-dot.active { background: #2f9e44; }
.visitor-summary-row .presence-dot.idle { background: #f59f00; }
.visitor-summary-row .presence-dot.offline { background: #c9d4ce; }
.visitor-details {
max-width: 980px;
color: var(--muted);
font-size: 12px;
}
.visitor-summary-row .visitor-details {
position: relative;
max-width: none;
}
.visitor-summary-row .visitor-details[open] {
flex-basis: auto;
}
.visitor-details summary {
width: fit-content;
display: inline-flex;
align-items: center;
cursor: pointer;
user-select: none;
color: var(--ink);
}
.visitor-details summary::-webkit-details-marker { display: none; }
.visitor-details summary span {
width: 20px;
height: 20px;
display: grid;
place-items: center;
border-radius: 50%;
background: var(--brand);
color: white;
font-size: 12px;
font-weight: 700;
}
.visitor-detail-popover {
position: absolute;
z-index: 20;
top: calc(100% + 10px);
right: -8px;
width: min(520px, 64vw);
max-width: calc(100vw - 380px);
max-height: calc(100vh - 118px);
overflow: auto;
padding: 12px;
border: 1px solid var(--line);
border-radius: 8px;
background: white;
box-shadow: 0 14px 32px rgb(0 0 0 / 13%);
}
.visitor-detail-popover:before {
position: absolute;
top: -6px;
right: 12px;
width: 10px;
height: 10px;
transform: rotate(45deg);
border-left: 1px solid var(--line);
border-top: 1px solid var(--line);
background: white;
content: "";
}
.visitor-detail-grid {
display: grid;
grid-template-columns: 76px minmax(0, 1fr);
gap: 5px 10px;
margin-top: 0;
}
.visitor-detail-grid span { color: var(--muted); }
.visitor-detail-grid a,
.history-list a {
min-width: 0;
color: var(--brand);
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.visitor-detail-grid em {
min-width: 0;
color: var(--muted);
font-style: normal;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.history-list {
margin: 10px 0 0;
padding-left: 20px;
display: grid;
gap: 4px;
}
.history-list li {
min-width: 0;
display: grid;
grid-template-columns: minmax(0, 1fr) auto;
gap: 10px;
}
.history-list small { color: var(--muted); }
.messages {
overflow: auto;
min-height: 0;
padding: 20px;
display: flex;
flex-direction: column;
gap: 12px;
}
.visitor-panel {
min-height: 0;
overflow: hidden;
display: grid;
grid-template-rows: auto minmax(0, 1fr);
border-left: 1px solid var(--line);
background: var(--panel);
}
.visitor-panel header {
height: var(--topbar-height);
padding: 14px;
border-bottom: 1px solid var(--line);
display: grid;
grid-template-columns: minmax(0, 1fr) auto;
gap: 10px;
align-items: center;
}
.visitor-panel h2 { margin: 0; font-size: 18px; }
.visitor-panel header span { color: var(--muted); font-size: 12px; }
.visitor-list {
min-height: 0;
overflow: auto;
}
.visitor-card {
padding: 10px 12px 10px 9px;
border-bottom: 1px solid var(--line);
border-left: 3px solid transparent;
background: white;
}
.visitor-card.bot { opacity: .68; }
.visitor-card.clickable { cursor: pointer; }
.visitor-card.clickable:hover { background: #f8fbf9; }
.visitor-card.active {
background: #edf8f3;
border-left-color: var(--brand);
}
.visitor-card-head {
display: grid;
grid-template-columns: 34px minmax(0, 1fr) 10px;
gap: 9px;
align-items: center;
margin-bottom: 7px;
}
.visitor-card-head strong,
.visitor-card-head small {
display: block;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.visitor-card-head small { color: var(--muted); font-size: 12px; margin-top: 2px; }
.visitor-avatar {
width: 34px;
height: 34px;
display: grid;
place-items: center;
border-radius: 8px;
background: #eaf6f1;
color: var(--brand);
font-weight: 800;
font-size: 13px;
}
.presence-dot {
width: 9px;
height: 9px;
flex: 0 0 auto;
border-radius: 50%;
}
.presence-dot.active {
background: #2f9e44;
box-shadow: 0 0 0 4px rgb(47 158 68 / 14%);
}
.presence-dot.idle {
background: #f59f00;
box-shadow: 0 0 0 4px rgb(245 159 0 / 16%);
}
.presence-dot.offline {
background: #c9d4ce;
}
.visitor-compact-meta {
display: flex;
align-items: center;
gap: 7px;
min-width: 0;
color: var(--muted);
font-size: 12px;
}
.visitor-compact-meta > span {
flex: 0 0 auto;
max-width: 72px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.visitor-page,
.visitor-referrer {
display: block;
min-width: 0;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
font-size: 12px;
}
.visitor-page { margin-top: 6px; }
.visitor-referrer {
margin-top: 3px;
color: var(--muted);
}
.visitor-card a { color: var(--ink); text-decoration: none; }
.visitor-card a:hover { color: var(--brand); text-decoration: underline; }
.message {
max-width: min(680px, 86%);
padding: 10px 12px;
border-radius: 8px;
border: 1px solid var(--line);
background: white;
}
.message.admin { align-self: flex-end; background: #ecf8f3; border-color: #c7e8dc; }
.message .by { font-size: 12px; color: var(--muted); margin-bottom: 4px; }
.translation-meta {
display: inline-flex;
align-items: center;
margin-left: 4px;
padding: 1px 6px;
border-radius: 999px;
border: 1px solid #d8e5df;
background: #f6faf8;
color: #416256;
font-size: 11px;
font-weight: 700;
white-space: nowrap;
}
.translation-meta.translated { border-color: #b9dfca; background: #eef8f2; color: #1e7a47; }
.translation-meta.failed,
.translation-meta.invalid_key,
.translation-meta.bad_model { border-color: #f0b9b9; background: #fff1f1; color: #b42318; }
.translation-meta.missing_key,
.translation-meta.quota_exceeded,
.translation-meta.rate_limited,
.translation-meta.empty { border-color: #f1d29b; background: #fff7e8; color: #9a5b00; }
.translation-meta.disabled,
.translation-meta.skipped,
.translation-meta.pending,
.translation-meta.same_language { border-color: #d7dde2; background: #f5f7f8; color: #667085; }
.message p { margin: 0; white-space: pre-wrap; }
.message a { color: var(--brand); display: inline-block; margin-top: 6px; }
.translation {
margin-top: 7px;
padding: 8px 9px;
border-left: 3px solid var(--brand);
border-radius: 6px;
background: #f4faf7;
}
.translation span {
display: block;
margin-bottom: 4px;
color: var(--muted);
font-size: 11px;
font-weight: 700;
}
.read-receipt {
align-self: flex-end;
margin-top: -4px;
font-size: 12px;
color: var(--muted);
}
.read-receipt.seen { color: var(--brand); }
.attachments {
display: flex;
flex-wrap: wrap;
gap: 8px;
margin-top: 8px;
}
.photo-preview {
width: min(340px, 100%);
display: grid;
gap: 0;
padding: 0;
border: 1px solid var(--line);
border-radius: 8px;
background: white;
color: var(--ink);
overflow: hidden;
text-align: left;
margin: 0;
}
.photo-open {
width: 100%;
min-height: 80px;
max-height: 360px;
display: grid;
place-items: center;
padding: 0;
border: 0;
border-radius: 0;
background: #edf3ef;
color: var(--ink);
}
.photo-open img {
max-width: 100%;
height: auto;
max-height: 360px;
width: auto;
object-fit: contain;
display: block;
background: #edf3ef;
}
.photo-preview figcaption {
display: grid;
grid-template-columns: minmax(0, 1fr) 30px;
gap: 6px;
align-items: center;
padding: 6px 7px;
}
.photo-preview figcaption span {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
color: var(--muted);
font-size: 12px;
}
.photo-delete {
width: 30px;
height: 30px;
padding: 0;
display: grid;
place-items: center;
background: #fff1f0;
color: #b42318;
}
.photo-delete svg { width: 16px; height: 16px; fill: currentColor; }
.photo-modal {
position: fixed;
inset: 0;
z-index: 20;
display: grid;
place-items: center;
padding: 24px;
}
.photo-backdrop {
position: absolute;
inset: 0;
border: 0;
border-radius: 0;
background: rgb(0 0 0 / 72%);
}
.photo-modal figure {
position: relative;
z-index: 1;
margin: 0;
max-width: min(1100px, 94vw);
max-height: 90vh;
display: grid;
gap: 8px;
}
.photo-modal img {
max-width: 100%;
max-height: 82vh;
object-fit: contain;
border-radius: 8px;
background: white;
}
.photo-modal figcaption {
color: white;
text-align: center;
font-size: 13px;
}
.photo-close {
position: absolute;
top: 10px;
right: 10px;
width: 34px;
height: 34px;
padding: 0;
border-radius: 50%;
background: rgb(0 0 0 / 54%);
}
.typing { padding: 0 20px 10px; color: var(--brand); font-size: 13px; }
.reply {
display: grid;
gap: 8px;
padding: 14px;
background: white;
border-top: 1px solid var(--line);
}
.reply.dragging {
box-shadow: inset 0 0 0 2px var(--brand);
background: #edf8f3;
}
.reply-operator-presence {
width: fit-content;
max-width: 100%;
border: 1px solid #dfe9e4;
border-radius: 999px;
padding: 4px 9px;
background: #f8fbf9;
color: var(--muted);
font-size: 12px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.reply-operator-presence.hidden { display: none; }
.reply-operator-presence.typing {
border-color: #f7d8a8;
background: #fff8ed;
color: #8a5a00;
}
.reply-composer {
display: grid;
grid-template-columns: minmax(0, 1fr) 44px 88px;
gap: 8px;
align-items: stretch;
}
.reply-composer textarea { min-height: 72px; resize: vertical; }
.reply-icon-button {
min-height: 72px;
width: 100%;
display: grid;
place-items: center;
border-radius: 6px;
padding: 0;
cursor: pointer;
}
.reply-icon-button svg {
width: 21px;
height: 21px;
fill: currentColor;
}
.attach-button {
border: 1px solid var(--line);
background: #f8fbf9;
color: var(--muted);
}
.attach-button:hover { background: #edf3ef; color: var(--ink); }
.attach-button input { display: none; }
.send-button {
border: 0;
background: var(--brand);
color: white;
}
.send-button svg {
width: 26px;
height: 26px;
transform: translateX(1px);
}
.reply-attachments {
display: flex;
flex-wrap: wrap;
gap: 6px;
}
.reply-chip {
max-width: 100%;
display: inline-flex;
align-items: center;
gap: 6px;
border: 1px solid var(--line);
border-radius: 999px;
background: #f8fbf9;
padding: 5px 5px 5px 9px;
font-size: 12px;
}
.reply-chip span {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
max-width: 240px;
}
.reply-chip button {
width: 22px;
height: 22px;
border-radius: 50%;
padding: 0;
background: #e8eee9;
color: var(--ink);
}
.settings {
position: fixed;
inset: 0 0 0 auto;
width: min(430px, 100%);
overflow: auto;
background: white;
border-left: 1px solid var(--line);
padding: 16px;
box-shadow: -12px 0 30px rgb(0 0 0 / 12%);
}
.settings-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.settings h2 { margin: 0 0 12px; }
.settings h3 { margin: 20px 0 8px; }
.settings form { display: grid; gap: 12px; }
.settings-tabs {
display: grid;
grid-template-columns: repeat(2, minmax(0, 1fr));
gap: 6px;
margin: 0 0 14px;
padding: 4px;
border: 1px solid var(--line);
border-radius: 8px;
background: #f7faf8;
}
.settings-tabs button {
padding: 9px 10px;
background: transparent;
color: var(--muted);
}
.settings-tabs button.active {
background: var(--brand);
color: white;
}
.settings-tab-panel { display: none; }
.settings-tab-panel.active { display: block; }
.admin-preferences {
display: grid;
gap: 14px;
}
.admin-preferences label:not(.setting-switch) {
gap: 8px;
}
.admin-preferences input[type="range"] {
padding: 0;
accent-color: var(--brand);
}
.seconds-field {
display: grid;
grid-template-columns: minmax(0, 1fr) auto;
gap: 7px;
align-items: center;
}
.seconds-field span {
color: var(--muted);
font-size: 12px;
}
pre {
white-space: pre-wrap;
overflow: auto;
padding: 12px;
border: 1px solid var(--line);
border-radius: 8px;
background: #f7faf8;
}
@keyframes pulse {
0%, 100% { background: white; }
50% { background: #dff7eb; }
}
@keyframes unreadPulse {
0% { box-shadow: 0 0 0 0 rgb(255 59 48 / 55%); }
70% { box-shadow: 0 0 0 8px rgb(255 59 48 / 0%); }
100% { box-shadow: 0 0 0 0 rgb(255 59 48 / 0%); }
}
@media (max-width: 820px) {
body { overflow: auto; }
.app { height: auto; min-height: 100vh; grid-template-columns: 1fr; overflow: visible; }
.sidebar { height: 42vh; border-right: 0; border-bottom: 1px solid var(--line); }
.conversation { height: 58vh; }
.visitor-panel { display: none; }
}