noteJS-react/src/styles/style.css

4922 lines
102 KiB
CSS
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

:root {
--accent-color: #007bff;
--accent-color-rgb: 0, 123, 255;
/* Светлая тема (по умолчанию) */
--bg-primary: #f5f5f5;
--bg-secondary: #ffffff;
--bg-tertiary: #f8f9fa;
--bg-quaternary: #e9ecef;
--bg-hover: #e7f3ff;
--text-primary: #333333;
--text-secondary: #666666;
--text-muted: #999999;
--text-light: #757575;
--border-primary: #e0e0e0;
--border-secondary: #dddddd;
--border-focus: var(--accent-color);
--shadow-light: rgba(0, 0, 0, 0.1);
--shadow-medium: rgba(0, 0, 0, 0.15);
/* Цвета иконок */
--icon-search: #2196f3;
--icon-tags: #4caf50;
--icon-notes: #ff9800;
--icon-user: #9c27b0;
--icon-danger: #dc3545;
}
/* Темная тема */
[data-theme="dark"] {
--bg-primary: #1a1a1a;
--bg-secondary: #2d2d2d;
--bg-tertiary: #3a3a3a;
--bg-quaternary: #4a4a4a;
--bg-hover: #2a4a6b;
--text-primary: #ffffff;
--text-secondary: #cccccc;
--text-muted: #999999;
--text-light: #aaaaaa;
--border-primary: #404040;
--border-secondary: #555555;
--border-focus: var(--accent-color);
--shadow-light: rgba(0, 0, 0, 0.3);
--shadow-medium: rgba(0, 0, 0, 0.4);
/* Цвета иконок в темной теме */
--icon-search: #64b5f6;
--icon-tags: #81c784;
--icon-notes: #ffb74d;
--icon-user: #ba68c8;
--icon-danger: #f44336;
}
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
body {
font-family: "Open Sans", sans-serif;
padding: 0;
margin: 0;
background: var(--bg-primary);
color: var(--text-primary);
display: flex;
flex-direction: row;
justify-content: center;
align-items: flex-start;
gap: 30px;
padding: 0 15px;
transition: background-color 0.3s ease, color 0.3s ease;
}
#root {
display: contents;
}
.notification-stack {
position: fixed;
top: 0;
left: 0;
right: 0;
z-index: 10000;
pointer-events: none;
}
.notification-stack .notification {
pointer-events: all;
}
/*
ОБНОВЛЕНИЕ: Добавлены свойства переноса текста для всех элементов заметок
- word-wrap: break-word
- overflow-wrap: break-word
- word-break: break-word
Это устраняет проблему, когда длинный текст без пробелов выходил за границы блока.
Теперь длинные слова и текст корректно переносятся на следующую строку.
*/
/* Стили для Iconify иконок */
.iconify {
font-size: 16px;
vertical-align: middle;
display: inline-block;
width: 1em;
height: 1em;
}
/* Убираем выделение при нажатии на кнопки на мобильных устройствах */
button {
-webkit-tap-highlight-color: transparent;
-moz-tap-highlight-color: transparent;
tap-highlight-color: transparent;
outline: none;
box-shadow: none;
}
button:focus,
button:active {
outline: none;
box-shadow: none;
}
/* Применяем к другим интерактивным элементам */
input[type="button"],
input[type="submit"],
input[type="reset"],
a,
div[role="button"] {
-webkit-tap-highlight-color: transparent;
-moz-tap-highlight-color: transparent;
tap-highlight-color: transparent;
outline: none;
box-shadow: none;
}
input[type="button"]:focus,
input[type="submit"]:focus,
input[type="reset"]:focus,
a:focus,
div[role="button"]:focus,
input[type="button"]:active,
input[type="submit"]:active,
input[type="reset"]:active,
a:active,
div[role="button"]:active {
outline: none;
box-shadow: none;
}
iconify-icon {
font-size: 16px;
vertical-align: middle;
display: inline-block;
width: 1em;
height: 1em;
}
/* Стили для иконок в заголовках */
header .iconify {
font-size: 20px;
margin-right: 8px;
}
/* Стили для иконок в кнопках удалены, так как теперь кнопки имеют свои стили */
/* Стили для иконок в секциях */
.search-title .iconify,
.tags-title .iconify {
font-size: 14px;
margin-right: 6px;
}
/* Цветные иконки */
/* Иконка поиска - синий */
.search-title .iconify[data-icon="mdi:magnify"] {
color: var(--icon-search);
}
/* Иконка тегов - зеленый */
.tags-title .iconify[data-icon="mdi:tag"] {
color: var(--icon-tags);
}
/* Иконка заметок - оранжевый */
header .iconify[data-icon="mdi:note-text"] {
color: var(--icon-notes);
}
/* Иконка пользователя - фиолетовый */
header .iconify[data-icon="mdi:account"],
.username-clickable .iconify[data-icon="mdi:account"] {
color: var(--icon-user);
}
/* Переключатель темы */
.theme-toggle-btn {
width: 40px;
height: 40px;
border-radius: 50%;
border: none;
background: var(--bg-secondary);
color: var(--text-secondary);
cursor: pointer;
font-size: 18px;
transition: all 0.3s ease;
display: flex;
align-items: center;
justify-content: center;
flex-shrink: 0;
}
.theme-toggle-btn:hover {
background-color: var(--accent-color, #007bff);
color: white;
transform: scale(1.1);
}
.theme-toggle-btn .iconify {
font-size: 18px;
color: var(--text-secondary);
transition: color 0.3s ease;
margin: 0;
}
.theme-toggle-btn:hover .iconify {
color: white;
}
/* Иконка входа - синий */
header .iconify[data-icon="mdi:login"] {
color: #2196f3;
}
/* Иконка регистрации - зеленый */
header .iconify[data-icon="mdi:account-plus"] {
color: #4caf50;
}
/* Markdown кнопки - разные цвета */
.btnMarkdown .iconify[data-icon="mdi:format-bold"] {
color: #d32f2f;
}
.btnMarkdown .iconify[data-icon="mdi:format-italic"] {
color: #f57c00;
}
.btnMarkdown .iconify[data-icon="mdi:palette"] {
color: #e91e63;
}
.btnMarkdown .iconify[data-icon="mdi:format-header-1"] {
color: #1976d2;
}
.btnMarkdown .iconify[data-icon="mdi:format-header-pound"] {
color: #1976d2;
}
.btnMarkdown .iconify[data-icon="mdi:format-list-bulleted"] {
color: #388e3c;
}
.btnMarkdown .iconify[data-icon="mdi:format-quote-close"] {
color: #f57c00;
}
.btnMarkdown .iconify[data-icon="mdi:code-tags"] {
color: #7b1fa2;
}
.btnMarkdown .iconify[data-icon="mdi:link"] {
color: #0288d1;
}
.btnMarkdown .iconify[data-icon="mdi:format-strikethrough"] {
color: #ff6f00;
}
.btnMarkdown .iconify[data-icon="mdi:format-list-numbered"] {
color: #4caf50;
}
.btnMarkdown .iconify[data-icon="mdi:checkbox-marked-outline"] {
color: #ff9800;
}
.btnMarkdown .iconify[data-icon="mdi:image-plus"] {
color: #2196f3;
}
.btnMarkdown .iconify[data-icon="mdi:eye"] {
color: #607d8b;
}
.btnMarkdown .iconify[data-icon="mdi:file-plus"] {
color: #9c27b0;
}
.btnMarkdown .iconify[data-icon="mdi:eye-off"] {
color: #e91e63;
}
.btnMarkdown .iconify[data-icon="mdi:robot"] {
color: #ff6f00;
}
.btnMarkdown .iconify[data-icon="mdi:menu-down"] {
color: #1976d2;
}
.notesHeaderBtn .iconify[data-icon="mdi:pencil"] {
color: #2196f3;
}
.notesHeaderBtn .iconify[data-icon="mdi:delete"] {
color: #dc3545;
}
header {
font-size: 20px;
font-weight: bold;
}
.notes-header {
display: flex;
justify-content: space-between;
align-items: flex-start;
width: 100%;
box-sizing: border-box;
}
.notes-header-left {
display: flex;
flex-direction: column;
align-items: flex-start;
flex: 1;
min-width: 0;
}
/* Стили для секции поиска в левой панели */
.search-section {
margin-top: 15px;
padding-top: 15px;
border-top: 1px solid var(--border-primary);
}
.search-header {
margin-bottom: 10px;
}
.search-title {
font-size: 12px;
font-weight: bold;
color: var(--text-primary);
}
.search-container {
position: relative;
width: 100%;
}
.search-input {
width: 100%;
padding: 6px 30px 6px 10px;
border: 1px solid var(--border-secondary);
border-radius: 15px;
font-size: 12px;
background-color: var(--bg-tertiary);
color: var(--text-primary);
transition: all 0.3s ease;
box-sizing: border-box;
}
.search-input:focus {
outline: none;
border-color: var(--border-focus);
background-color: var(--bg-secondary);
box-shadow: 0 0 0 2px rgba(var(--accent-color-rgb), 0.25);
}
.clear-search-btn {
position: absolute;
right: 6px;
top: 50%;
transform: translateY(-50%);
background: none;
border: none;
color: #999;
cursor: pointer;
font-size: 14px;
padding: 2px 4px;
border-radius: 50%;
transition: all 0.2s ease;
}
.clear-search-btn:hover {
background-color: var(--bg-quaternary);
color: var(--text-secondary);
}
.filter-indicator {
display: inline-flex;
align-items: center;
margin-top: 15px;
padding: 4px 10px;
background-color: rgba(var(--accent-color-rgb), 0.1);
border: 1px solid rgba(var(--accent-color-rgb), 0.3);
border-radius: 15px;
font-size: 12px;
color: var(--accent-color);
font-weight: 500;
max-width: min(300px, 100%);
box-sizing: border-box;
}
.filter-indicator-text {
flex: 1;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
min-width: 0;
}
.filter-indicator button {
background: none;
border: none;
color: var(--icon-danger);
cursor: pointer;
margin-left: 8px;
font-weight: bold;
padding: 2px 4px;
font-size: 14px;
border-radius: 3px;
min-width: 20px;
min-height: 20px;
display: flex;
align-items: center;
justify-content: center;
transition: all 0.2s ease;
}
.filter-indicator button:hover {
color: #ff6b6b;
background-color: rgba(255, 107, 107, 0.1);
}
.user-info {
display: flex;
align-items: center;
gap: 15px;
flex-shrink: 0;
}
.user-info span {
font-size: 14px;
color: #666;
font-weight: 500;
}
/* Мини-аватарка в хедере */
.user-avatar-mini {
width: 40px;
height: 40px;
border-radius: 50%;
overflow: hidden;
cursor: pointer;
transition: all 0.3s ease;
border: 2px solid var(--accent-color, #007bff);
flex-shrink: 0;
}
.user-avatar-mini:hover {
transform: scale(1.05);
box-shadow: 0 0 0 3px rgba(var(--accent-color-rgb), 0.2);
}
.user-avatar-mini img {
width: 100%;
height: 100%;
object-fit: cover;
}
.user-avatar-placeholder-mini {
display: flex;
align-items: center;
justify-content: center;
background: #e0e0e0;
color: #999;
font-size: 24px;
}
.user-avatar-placeholder-mini .iconify {
margin: 0;
padding: 0;
line-height: 1;
vertical-align: baseline;
}
/* Иконка настроек */
.settings-icon-btn {
width: 40px;
height: 40px;
border-radius: 50%;
border: none;
background: var(--bg-secondary);
color: var(--text-secondary);
cursor: pointer;
font-size: 18px;
transition: all 0.3s ease;
display: flex;
align-items: center;
justify-content: center;
flex-shrink: 0;
}
.settings-icon-btn:hover {
background-color: var(--accent-color, #007bff);
color: white;
transform: scale(1.1);
}
.settings-icon-btn .iconify {
font-size: 18px;
color: var(--text-secondary);
transition: color 0.3s ease;
margin: 0;
}
.settings-icon-btn:hover .iconify {
color: white;
}
.logout-btn {
width: 40px;
height: 40px;
border-radius: 50%;
border: none;
background: var(--bg-secondary);
color: var(--text-secondary);
cursor: pointer;
display: flex;
align-items: center;
justify-content: center;
transition: all 0.3s ease;
flex-shrink: 0;
}
.logout-btn:hover {
background-color: #dc3545;
}
.logout-btn .iconify {
font-size: 20px;
color: #dc3545;
transition: color 0.3s ease;
margin: 0;
padding: 0;
line-height: 1;
vertical-align: baseline;
}
.logout-btn:hover .iconify {
color: white;
}
/* Стили для кнопок навигации в профиле и настройках */
.notes-btn {
width: 40px;
height: 40px;
border-radius: 50%;
border: none;
background: var(--bg-secondary);
color: var(--text-secondary);
cursor: pointer;
display: flex;
align-items: center;
justify-content: center;
transition: all 0.3s ease;
flex-shrink: 0;
}
.notes-btn:hover {
background-color: var(--accent-color, #007bff);
}
.notes-btn .iconify {
font-size: 20px;
color: #666;
transition: color 0.3s ease;
margin: 0;
padding: 0;
line-height: 1;
vertical-align: baseline;
}
.notes-btn:hover .iconify {
color: white;
}
.settings-btn {
width: 40px;
height: 40px;
border-radius: 50%;
border: none;
background: var(--bg-secondary);
color: var(--text-secondary);
cursor: pointer;
display: flex;
align-items: center;
justify-content: center;
transition: all 0.3s ease;
flex-shrink: 0;
}
.settings-btn:hover {
background-color: var(--accent-color, #007bff);
}
.settings-btn .iconify {
font-size: 20px;
color: #666;
transition: color 0.3s ease;
margin: 0;
padding: 0;
line-height: 1;
vertical-align: baseline;
}
.settings-btn:hover .iconify {
color: white;
}
.profile-btn {
width: 40px;
height: 40px;
border-radius: 50%;
border: none;
background: var(--bg-secondary);
color: var(--text-secondary);
cursor: pointer;
display: flex;
align-items: center;
justify-content: center;
transition: all 0.3s ease;
flex-shrink: 0;
}
.profile-btn:hover {
background-color: var(--accent-color, #007bff);
}
.profile-btn .iconify {
font-size: 20px;
color: #666;
transition: color 0.3s ease;
margin: 0;
padding: 0;
line-height: 1;
vertical-align: baseline;
}
.profile-btn:hover .iconify {
color: white;
}
.auth-link {
text-align: center;
margin-top: 15px;
font-size: 14px;
}
.auth-link a {
color: var(--accent-color, #007bff);
text-decoration: none;
font-weight: 500;
}
.auth-link a:hover {
text-decoration: underline;
}
.container {
width: 90%;
max-width: 600px;
box-shadow: 0 0 10px var(--shadow-light);
border-radius: 8px;
padding: 15px;
margin-top: 20px;
background: var(--bg-secondary);
color: var(--text-primary);
box-sizing: border-box;
word-wrap: break-word;
overflow-wrap: break-word;
overflow: visible;
transition: background-color 0.3s ease, color 0.3s ease, box-shadow 0.3s ease;
}
/* Убираем margin-top у заметок, так как gap уже обеспечивает отступы */
.notes-container .container {
margin-top: 0;
}
/* Добавляем отступ сверху для контейнера заметок, чтобы расстояние между блоком "Мои заметки" и первой заметкой было таким же, как между заметками */
.notes-container {
margin-top: 8px;
}
.empty-message {
text-align: center;
color: #999;
margin-top: 50px;
word-break: break-word;
overflow-wrap: break-word;
max-width: 100%;
padding: 0 20px;
box-sizing: border-box;
}
.login-form {
margin-top: 20px;
}
.form-group {
margin-bottom: 15px;
}
.form-group label {
display: block;
margin-bottom: 5px;
font-weight: bold;
color: var(--text-primary);
}
.form-group input {
width: 100%;
padding: 10px;
border: 1px solid var(--border-secondary);
border-radius: 5px;
font-size: 16px;
background-color: var(--bg-tertiary);
color: var(--text-primary);
box-sizing: border-box;
transition: all 0.3s ease;
}
.form-group input:focus {
outline: none;
border-color: var(--border-focus);
background-color: var(--bg-secondary);
box-shadow: 0 0 0 2px rgba(var(--accent-color-rgb), 0.25);
}
/* Toggle Switch Styles */
.ai-toggle-group {
margin-bottom: 20px;
}
.ai-toggle-label {
display: flex;
align-items: center;
justify-content: space-between;
cursor: pointer;
user-select: none;
font-weight: normal !important;
margin-bottom: 0 !important;
padding: 16px 20px;
background-color: var(--bg-tertiary);
border: 1px solid var(--border-secondary);
border-radius: 8px;
transition: all 0.3s ease;
}
.ai-toggle-label:hover {
background-color: var(--bg-secondary);
border-color: var(--accent-color);
}
.ai-toggle-label.disabled {
opacity: 0.6;
cursor: not-allowed;
background-color: var(--bg-secondary);
}
.ai-toggle-label.disabled:hover {
background-color: var(--bg-secondary);
border-color: var(--border-secondary);
}
.ai-toggle-label.disabled .toggle-text-main {
color: var(--text-secondary);
}
.ai-toggle-label.disabled .toggle-text-desc {
color: #e67e22;
font-weight: 500;
}
.ai-toggle-label.disabled .toggle-slider {
background-color: #999;
cursor: not-allowed;
}
.ai-toggle-label.disabled .toggle-slider::before {
background-color: #ddd;
}
.toggle-label-content {
display: flex;
flex-direction: column;
gap: 4px;
flex: 1;
min-width: 0;
}
.toggle-text-main {
color: var(--text-primary);
font-size: 15px;
font-weight: 500;
}
.toggle-text-desc {
color: var(--text-secondary);
font-size: 12px;
line-height: 1.4;
}
.toggle-switch-wrapper {
flex-shrink: 0;
margin-left: 20px;
position: relative;
}
.toggle-checkbox {
display: none;
}
.toggle-slider {
position: relative;
display: block;
width: 50px;
height: 26px;
background-color: #ccc;
border-radius: 26px;
transition: background-color 0.3s ease;
box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.2);
}
.toggle-slider::before {
content: "";
position: absolute;
width: 22px;
height: 22px;
border-radius: 50%;
background-color: white;
top: 2px;
left: 2px;
transition: transform 0.3s ease;
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}
.toggle-checkbox:checked + .toggle-slider {
background-color: var(--accent-color, #007bff);
box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.3);
}
.toggle-checkbox:checked + .toggle-slider::before {
transform: translateX(24px);
}
.error-message {
color: var(--icon-danger);
margin-top: 10px;
padding: 10px;
background-color: rgba(220, 53, 69, 0.1);
border: 1px solid rgba(220, 53, 69, 0.3);
border-radius: 5px;
}
textarea {
width: 100%;
min-height: 50px;
resize: none;
border: none;
background: var(--bg-secondary);
color: var(--text-primary);
margin-bottom: 5px;
overflow-y: hidden;
transition: background-color 0.3s ease, color 0.3s ease;
/* Разрешаем выделение текста */
-webkit-user-select: text;
-moz-user-select: text;
-ms-user-select: text;
user-select: text;
}
textarea:focus {
outline: none;
}
.save-button-container {
display: flex;
flex-direction: column;
gap: 10px;
}
.action-buttons {
display: flex;
align-items: center;
gap: 10px;
}
.btnAI {
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
color: white;
display: flex;
align-items: center;
gap: 6px;
}
.btnAI:hover {
background: linear-gradient(135deg, #5568d3 0%, #5a3f7d 100%);
transform: translateY(-2px);
}
.btnAI:active {
transform: translateY(0);
}
.btnAI .iconify {
font-size: 18px;
}
.save-hint {
font-size: 12px;
color: #999;
font-style: italic;
}
.btnSave {
padding: 10px 20px;
cursor: pointer;
border-width: 1px;
background: var(--bg-secondary);
color: var(--text-primary);
border: 1px solid var(--border-secondary);
border-radius: 5px;
font-family: "Open Sans", sans-serif;
transition: all 0.3s ease;
font-size: 16px;
}
.btnSave:hover {
background-color: var(--accent-color, #007bff);
color: white;
border-color: var(--accent-color, #007bff);
}
.date {
font-size: 11px;
color: grey;
display: flex;
align-items: center;
justify-content: space-between;
gap: 10px;
flex-wrap: wrap;
}
.date .date-text {
flex: 1;
overflow: hidden;
text-overflow: ellipsis;
display: flex;
align-items: center;
gap: 4px;
flex-wrap: wrap;
}
.date-separator {
color: #999;
font-weight: normal;
margin: 0 2px;
}
.note-actions {
display: flex;
align-items: center;
gap: 4px;
flex-wrap: wrap;
}
.notesHeaderBtn {
display: inline-flex;
align-items: center;
justify-content: center;
gap: 4px;
cursor: pointer;
color: var(--text-primary);
font-weight: bold;
white-space: nowrap;
padding: 2px 4px;
border-radius: 4px;
transition: all 0.2s ease;
font-size: 10px;
}
.notesHeaderBtn:hover {
background: var(--bg-quaternary);
}
#pinBtn:hover {
background: rgba(255, 193, 7, 0.2);
color: #ffc107;
}
#archiveBtn:hover {
background: var(--bg-quaternary);
color: var(--text-primary);
}
#editBtn:hover {
background: rgba(13, 202, 240, 0.2);
color: #0dcaf0;
}
#deleteBtn:hover {
background: rgba(220, 53, 69, 0.2);
color: var(--icon-danger);
}
.textNote {
margin-top: 10px;
white-space: pre-wrap;
position: relative;
transition: max-height 0.3s ease;
word-wrap: break-word;
overflow-wrap: break-word;
word-break: break-word;
}
.textNote.collapsed {
max-height: 300px;
overflow: hidden;
}
.textNote.collapsed::after {
content: "";
position: absolute;
bottom: 0;
left: 0;
right: 0;
height: 80px;
background: linear-gradient(to bottom, transparent, var(--bg-secondary));
pointer-events: none;
}
.show-more-btn {
display: flex;
align-items: center;
justify-content: center;
width: 100%;
margin-top: 10px;
padding: 8px;
background-color: var(--bg-tertiary);
border: 1px solid var(--border-secondary);
border-radius: 5px;
color: var(--accent-color, #007bff);
font-size: 14px;
cursor: pointer;
transition: all 0.3s ease;
text-align: center;
gap: 5px;
}
.show-more-btn:hover {
background-color: var(--accent-color, #007bff);
color: white;
border-color: var(--accent-color, #007bff);
}
/* Убираем стандартные отступы для абзацев */
.textNote p {
margin: 0;
padding: 0;
word-wrap: break-word;
overflow-wrap: break-word;
}
/* Убираем маргины у заголовков */
.textNote h1,
.textNote h2,
.textNote h3,
.textNote h4,
.textNote h5,
.textNote h6 {
margin: 0;
padding: 0;
word-wrap: break-word;
overflow-wrap: break-word;
word-break: break-word;
}
/* Убираем отступы у списков */
.textNote ul,
.textNote ol {
margin: 0;
padding-left: 20px;
word-wrap: break-word;
overflow-wrap: break-word;
line-height: 0.5;
}
/* Убираем маргины у элементов списка */
.textNote li {
margin: 0;
padding: 0;
line-height: 1;
word-wrap: break-word;
overflow-wrap: break-word;
}
/* Стили для ссылок */
.textNote a {
color: var(--accent-color, #007bff);
text-decoration: none;
word-wrap: break-word;
overflow-wrap: break-word;
}
/* Стили для внешних ссылок */
.textNote a.external-link {
position: relative;
padding-right: 16px;
}
.textNote a.external-link::after {
content: "↗";
position: absolute;
right: 0;
top: 0;
font-size: 0.8em;
opacity: 0.7;
transition: opacity 0.3s ease;
}
.textNote a.external-link:hover::after {
opacity: 1;
}
.textNote a:hover {
text-decoration: underline;
}
/* Стили для цитат */
.textNote blockquote {
border-left: 4px solid var(--accent-color, #007bff);
padding-left: 16px;
margin: 10px 0;
color: var(--text-secondary);
font-style: italic;
background-color: var(--bg-tertiary);
padding: 10px 16px;
border-radius: 0 4px 4px 0;
word-wrap: break-word;
overflow-wrap: break-word;
}
.textNote blockquote p {
margin: 0;
}
/* Стили для кода */
.textNote pre {
background-color: var(--bg-tertiary);
color: var(--text-primary);
padding: 10px;
border-radius: 5px;
font-size: 14px;
overflow-x: auto;
word-wrap: break-word;
overflow-wrap: break-word;
white-space: pre-wrap;
}
.textNote code {
background-color: var(--bg-tertiary);
color: var(--text-primary);
padding: 2px 4px;
border-radius: 5px;
font-size: 14px;
word-wrap: break-word;
overflow-wrap: break-word;
word-break: break-word;
}
/* Стили для чекбоксов (to-do списков) */
.textNote input[type="checkbox"] {
cursor: pointer;
margin-right: 8px;
width: 18px;
height: 18px;
accent-color: var(--accent-color, #007bff);
vertical-align: middle;
position: relative;
top: -1px;
}
/* Стили для элементов списка с чекбоксами (task-list-item создается marked.js) */
.textNote .task-list-item {
list-style-type: none;
margin-left: -20px;
padding: 0;
line-height: 1.5;
transition: all 0.3s ease;
}
/* Перечеркивание текста для выполненных задач */
.textNote .task-list-item:has(input[type="checkbox"]:checked) {
opacity: 0.65;
text-decoration: line-through;
color: #999;
}
.textNote .task-list-item input[type="checkbox"]:checked ~ * {
text-decoration: line-through;
color: #999;
}
.textNote .task-list-item:has(input[type="checkbox"]:checked) * {
text-decoration: line-through;
color: #999;
}
/* Альтернативный вариант для перечеркивания всего текста в элементе */
.textNote input[type="checkbox"]:checked {
text-decoration: none;
}
.textNote input[type="checkbox"]:checked + * {
text-decoration: line-through;
color: #999;
}
/* Hover эффект для чекбоксов */
.textNote .task-list-item:hover {
background-color: rgba(var(--accent-color-rgb), 0.05);
border-radius: 4px;
padding-left: 4px;
margin-left: -24px;
}
/* Если marked.js не добавляет класс task-list-item, используем :has селектор */
.textNote li:has(input[type="checkbox"]) {
list-style-type: none;
margin-left: -20px;
padding: 0;
line-height: 1.5;
transition: all 0.3s ease;
}
.textNote li:has(input[type="checkbox"]:checked) {
opacity: 0.65;
text-decoration: line-through;
color: #999;
}
.textNote li:has(input[type="checkbox"]) input[type="checkbox"]:checked {
text-decoration: none;
}
.textNote li:has(input[type="checkbox"]:checked) label,
.textNote li:has(input[type="checkbox"]:checked) span,
.textNote li:has(input[type="checkbox"]:checked) p {
text-decoration: line-through;
color: #999;
}
.textNote li:has(input[type="checkbox"]:checked) * {
text-decoration: line-through;
color: #999;
}
.textNote li:has(input[type="checkbox"]):hover {
background-color: rgba(var(--accent-color-rgb), 0.05);
border-radius: 4px;
padding-left: 4px;
margin-left: -24px;
}
.notes-container {
width: 100%;
display: flex;
flex-direction: column;
align-items: center;
padding-bottom: 60px; /* Отступ снизу для footer */
margin-top: 16px; /* Отступ сверху для одинакового расстояния между блоком "Мои заметки" и первой заметкой */
gap: 16px; /* Отступ между заметками */
word-wrap: break-word;
overflow-wrap: break-word;
}
#notesList {
width: 100%;
display: flex;
flex-direction: column;
align-items: center;
}
.markdown-buttons {
margin-top: 10px;
margin-bottom: 10px;
overflow-x: auto;
overflow-y: hidden;
position: relative;
display: flex;
flex-wrap: nowrap;
gap: 8px;
align-items: center;
scrollbar-width: none;
}
.markdown-buttons::-webkit-scrollbar {
display: none;
}
/* Кнопки markdown в редакторе редактирования: те же отступы и поведение */
.markdown-buttons.markdown-buttons--edit {
display: flex;
flex-wrap: nowrap;
gap: 8px;
overflow-x: auto;
overflow-y: hidden;
scrollbar-width: none;
}
.markdown-buttons.markdown-buttons--edit::-webkit-scrollbar {
display: none;
}
.markdown-buttons.markdown-buttons--edit .btnMarkdown {
padding: 5px 10px;
margin-right: 0;
border: none;
background-color: transparent;
color: var(--text-primary);
border-radius: 4px;
font-size: 14px;
touch-action: manipulation;
-webkit-tap-highlight-color: transparent;
user-select: none;
-webkit-user-select: none;
min-height: 44px;
display: inline-flex;
align-items: center;
justify-content: center;
transition: all 0.3s ease;
}
.markdown-buttons.markdown-buttons--edit .btnMarkdown:hover {
background-color: var(--bg-quaternary);
}
@media (max-width: 768px) {
.markdown-buttons.markdown-buttons--edit .btnMarkdown {
min-height: 48px;
padding: 8px 12px;
margin: 0;
}
}
.markdown-buttons .btnMarkdown {
padding: 5px 10px;
margin-right: 0;
cursor: pointer;
border: none;
background-color: transparent;
color: var(--text-primary);
border-radius: 4px;
font-size: 14px;
/* Улучшения для мобильных устройств */
touch-action: manipulation;
-webkit-tap-highlight-color: transparent;
user-select: none;
-webkit-user-select: none;
min-height: 44px; /* Минимальная высота для touch */
display: inline-flex;
align-items: center;
justify-content: center;
transition: all 0.3s ease;
}
.markdown-buttons .btnMarkdown:hover {
background-color: var(--bg-quaternary);
}
.btnMarkdown.active {
background-color: var(--accent-color);
color: white;
}
.btnMarkdown.active .iconify {
color: white !important;
}
/* Выпадающее меню заголовков */
.header-dropdown {
position: relative;
display: inline-block;
overflow: visible;
z-index: 1;
}
.header-dropdown-menu {
display: block;
position: fixed;
background: var(--bg-secondary);
border: 1px solid var(--border-secondary);
border-radius: 5px;
box-shadow: 0 2px 8px var(--shadow-medium);
z-index: 1001;
min-width: 60px;
max-width: 120px;
}
.header-dropdown-menu button {
display: block;
width: 100%;
padding: 8px 16px;
border: none;
background: none;
text-align: left;
cursor: pointer;
font-size: 14px;
font-weight: 500;
color: var(--text-primary);
transition: background 0.2s ease;
}
.header-dropdown-menu button:hover {
background: var(--bg-quaternary);
}
.header-dropdown-menu button:first-child {
border-radius: 5px 5px 0 0;
}
.header-dropdown-menu button:last-child {
border-radius: 0 0 5px 5px;
}
/* Плавающая панель форматирования */
.floating-toolbar-wrapper {
overflow-x: auto;
overflow-y: hidden;
/* Скрываем скроллбар */
scrollbar-width: none;
/* Плавная прокрутка */
scroll-behavior: smooth;
/* Максимальная ширина с учетом отступов */
max-width: calc(100vw - 20px);
}
.floating-toolbar-wrapper::-webkit-scrollbar {
display: none;
}
.floating-toolbar {
display: flex;
gap: 4px;
background-color: var(--bg-secondary);
border: 1px solid var(--border-secondary);
border-radius: 8px;
padding: 6px;
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
animation: fadeIn 0.2s ease-out;
align-items: center;
/* Предотвращаем сжатие кнопок */
flex-shrink: 0;
min-width: fit-content;
width: max-content;
}
@keyframes fadeIn {
from {
opacity: 0;
transform: translateY(-5px);
}
to {
opacity: 1;
transform: translateY(0);
}
}
.floating-toolbar-btn {
padding: 6px 10px;
border: none;
background-color: transparent;
color: var(--text-primary);
border-radius: 4px;
cursor: pointer;
font-size: 16px;
display: flex;
align-items: center;
justify-content: center;
transition: all 0.2s ease;
min-width: 32px;
min-height: 32px;
}
.floating-toolbar-btn:hover {
background-color: var(--bg-quaternary);
}
.floating-toolbar-btn:active {
transform: scale(0.95);
}
.floating-toolbar-btn:disabled {
opacity: 0.5;
cursor: not-allowed;
pointer-events: none;
}
.floating-toolbar-btn .iconify {
font-size: 18px;
}
.floating-toolbar-btn .iconify[data-icon="mdi:format-bold"] {
color: #1976d2;
}
.floating-toolbar-btn .iconify[data-icon="mdi:format-italic"] {
color: #7b1fa2;
}
.floating-toolbar-btn .iconify[data-icon="mdi:format-strikethrough"] {
color: #ff6f00;
}
.floating-toolbar-btn.active {
background-color: var(--bg-quaternary);
box-shadow: 0 0 0 2px var(--border-focus);
}
.floating-toolbar-btn.active .iconify {
opacity: 1;
filter: brightness(1.2);
}
.floating-toolbar-separator {
width: 1px;
height: 20px;
background-color: var(--border-secondary);
margin: 0 4px;
}
/* Адаптивность для выпадающего меню заголовков */
@media (max-width: 768px) {
.header-dropdown-menu {
min-width: 50px;
right: -10px; /* Смещаем чуть левее для лучшего позиционирования на мобильных */
}
}
.footer {
text-align: center;
font-size: 12px;
color: #999;
position: fixed;
bottom: 0;
width: 100%;
padding: 10px 0;
}
.footer span {
font-weight: bold;
}
/* Стили для личного кабинета */
.profile-container {
margin-top: 20px;
}
.avatar-section {
text-align: center;
padding: 20px;
border-bottom: 1px solid #e0e0e0;
margin-bottom: 20px;
}
.avatar-wrapper {
margin-bottom: 15px;
display: flex;
justify-content: center;
align-items: center;
}
.avatar-preview {
width: 150px;
height: 150px;
border-radius: 50%;
object-fit: cover;
border: 3px solid var(--accent-color, #007bff);
}
.avatar-placeholder {
width: 150px;
height: 150px;
border-radius: 50%;
background-color: #e0e0e0;
display: inline-flex;
align-items: center;
justify-content: center;
font-size: 64px;
color: #999;
}
.avatar-buttons {
display: flex;
justify-content: center;
gap: 10px;
margin-top: 15px;
}
.btn-upload,
.btn-delete {
padding: 8px 16px;
cursor: pointer;
border: 1px solid var(--border-secondary);
background-color: var(--bg-tertiary);
color: var(--text-primary);
border-radius: 5px;
font-size: 14px;
transition: all 0.3s ease;
display: inline-block;
}
.btn-upload:hover {
background-color: var(--accent-color, #007bff);
color: white;
border-color: var(--accent-color, #007bff);
}
.btn-delete {
color: #dc3545;
}
.btn-delete:hover {
background-color: #dc3545;
color: white;
border-color: #dc3545;
}
.avatar-hint {
font-size: 12px;
color: #999;
margin-top: 10px;
}
.profile-form {
padding: 0 10px;
margin-bottom: 80px; /* Отступ снизу для последнего элемента */
}
.profile-form h3 {
margin-bottom: 15px;
color: var(--text-primary);
}
.separator {
margin: 30px 0;
border: none;
border-top: 1px solid var(--border-primary);
}
/* Стили для уведомлений */
.notification {
position: fixed;
top: 20px;
left: 50%;
transform: translateX(-50%) translateY(-100%);
padding: 12px 20px;
border-radius: 8px;
color: white;
font-weight: 500;
z-index: 10000;
max-width: 350px;
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
transition: transform 0.3s ease, top 0.3s ease;
font-size: 14px;
line-height: 1.4;
word-wrap: break-word;
}
.notification-success {
background-color: #28a745;
}
.notification-error {
background-color: #dc3545;
}
.notification-warning {
background-color: #ffc107;
color: #000;
}
.notification-info {
background-color: var(--accent-color, #007bff);
}
/* Состояние видимости уведомления */
.notification.visible {
transform: translateX(-50%) translateY(0);
}
/* Адаптивность для мобильных устройств */
@media (max-width: 768px) {
.notification {
left: 10px;
right: 10px;
max-width: none;
transform: translateY(-100%);
}
.notification.visible {
transform: translateY(0);
}
}
.back-btn {
padding: 8px 16px;
border: 1px solid var(--border-secondary);
background-color: var(--bg-tertiary);
border-radius: 5px;
font-size: 14px;
color: var(--border-focus);
text-decoration: none;
transition: all 0.3s ease;
display: inline-block;
}
.back-btn:hover {
background-color: var(--accent-color, #007bff);
color: white;
border-color: var(--accent-color, #007bff);
}
.username-clickable {
cursor: pointer;
transition: color 0.3s ease;
}
.username-clickable:hover {
color: var(--accent-color, #007bff);
text-decoration: underline;
}
.center {
display: flex;
justify-content: center;
align-items: center;
flex-direction: column;
width: 600px;
height: 100%;
}
.container-leftside {
width: 220px;
height: auto;
max-width: 220px;
box-shadow: 0 0 10px var(--shadow-light);
border-radius: 8px;
padding: 12px;
margin-top: 20px;
background: var(--bg-secondary);
color: var(--text-primary);
transition: background-color 0.3s ease, color 0.3s ease, box-shadow 0.3s ease;
}
/* Мини-календарь - базовые стили для всех устройств */
.mini-calendar {
width: 100%;
}
.calendar-header {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 10px;
}
.calendar-month-year {
font-size: 13px;
font-weight: bold;
color: var(--text-primary);
text-align: center;
flex: 1;
}
.calendar-nav {
background: none;
border: none;
font-size: 18px;
cursor: pointer;
color: var(--text-secondary);
padding: 0 3px;
transition: color 0.3s ease;
}
.calendar-nav:hover {
color: var(--accent-color);
}
.calendar-weekdays {
display: grid;
grid-template-columns: repeat(7, 1fr);
gap: 1px;
margin-bottom: 3px;
}
.calendar-weekday {
text-align: center;
font-size: 9px;
font-weight: bold;
color: var(--text-secondary);
padding: 3px 0;
}
.calendar-days {
display: grid;
grid-template-columns: repeat(7, 1fr);
gap: 1px;
}
.calendar-day {
aspect-ratio: 1;
display: flex;
align-items: center;
justify-content: center;
font-size: 11px;
cursor: pointer;
border-radius: 3px;
transition: all 0.2s ease;
color: var(--text-primary);
padding: 2px;
font-weight: 500;
position: relative;
background-color: transparent;
border: 1px solid transparent;
}
.calendar-day:hover {
background-color: transparent;
border-color: var(--accent-color, #007bff);
}
.calendar-day.today {
background-color: transparent;
color: var(--text-primary);
font-weight: bold;
border: 1px solid var(--accent-color, #007bff);
}
.calendar-day.today:hover {
background-color: transparent;
border-color: var(--accent-color, #007bff);
}
.calendar-day.other-month {
color: var(--text-muted);
background-color: transparent;
border: 1px solid transparent;
}
.calendar-day.other-month:hover {
border-color: var(--accent-color, #007bff);
}
.calendar-day.selected {
background-color: var(--accent-color, #007bff);
color: white;
font-weight: bold;
opacity: 1;
border: 1px solid var(--accent-color, #007bff);
}
.calendar-day.selected:hover {
background-color: var(--accent-color, #007bff);
border-color: var(--accent-color, #007bff);
}
/* Стили календаря для PC версии (темный стиль как на изображении) */
@media (min-width: 769px) {
.mini-calendar,
.container-leftside .mini-calendar {
background-color: transparent;
}
.calendar-month-year {
font-size: 14px;
font-weight: 600;
color: var(--text-primary);
}
.calendar-nav {
font-size: 20px;
color: var(--text-secondary);
font-weight: 400;
}
.calendar-nav:hover {
color: var(--accent-color);
}
.calendar-weekdays {
margin-bottom: 5px;
}
.calendar-weekday {
font-size: 10px;
font-weight: 400;
color: #999999;
text-transform: none;
}
.calendar-day {
font-size: 12px;
border-radius: 4px;
color: #ffffff;
font-weight: 400;
background-color: transparent;
border: 1px solid transparent;
}
.calendar-day:hover {
background-color: transparent;
border-color: var(--accent-color, #007bff);
}
.calendar-day.other-month {
color: #999999;
background-color: transparent;
border: 1px solid transparent;
}
.calendar-day.other-month:hover {
border-color: var(--accent-color, #007bff);
}
.calendar-day.selected {
background-color: var(--accent-color, #007bff);
color: white;
font-weight: 500;
opacity: 1;
border-radius: 4px;
border: 1px solid var(--accent-color, #007bff);
}
.calendar-day.selected:hover {
background-color: var(--accent-color, #007bff);
border-color: var(--accent-color, #007bff);
}
.calendar-day.today {
background-color: transparent;
color: #ffffff;
font-weight: 500;
border: 1px solid var(--accent-color, #007bff);
}
.calendar-day.today:hover {
background-color: transparent;
border-color: var(--accent-color, #007bff);
}
}
/* Индикатор для дней с заметками (зеленый кружок) */
.calendar-day.has-notes::after {
content: "";
position: absolute;
bottom: 2px;
left: 50%;
transform: translateX(-50%);
width: 4px;
height: 4px;
background-color: #28a745;
border-radius: 50%;
}
/* Индикатор для дней с отредактированными заметками (желтый кружок) */
.calendar-day.has-edited-notes::before {
content: "";
position: absolute;
bottom: 2px;
left: 50%;
transform: translateX(-50%);
width: 4px;
height: 4px;
background-color: #ffc107;
border-radius: 50%;
}
/* Когда есть оба типа заметок - сдвигаем кружки в стороны */
.calendar-day.has-notes.has-edited-notes::before {
transform: translateX(-150%);
}
.calendar-day.has-notes.has-edited-notes::after {
transform: translateX(50%);
}
/* Индикатор для выбранного дня с заметками */
.calendar-day.selected.has-notes::after {
background-color: #28a745;
border: 1px solid #fff;
box-shadow: 0 0 3px rgba(0, 0, 0, 0.5);
}
/* Индикатор для выбранного дня с отредактированными заметками */
.calendar-day.selected.has-edited-notes::before {
background-color: #ffc107;
border: 1px solid #fff;
box-shadow: 0 0 3px rgba(0, 0, 0, 0.5);
}
/* Индикатор для сегодняшнего дня с заметками */
.calendar-day.today.has-notes::after {
background-color: #28a745;
border: 1px solid #fff;
box-shadow: 0 0 3px rgba(0, 0, 0, 0.5);
}
/* Индикатор для сегодняшнего дня с отредактированными заметками */
.calendar-day.today.has-edited-notes::before {
background-color: #ffc107;
border: 1px solid #fff;
box-shadow: 0 0 3px rgba(0, 0, 0, 0.5);
}
/* Для дней с обоими типами заметок в выбранном состоянии */
.calendar-day.selected.has-notes.has-edited-notes::before,
.calendar-day.selected.has-notes.has-edited-notes::after {
border: 1px solid #fff;
box-shadow: 0 0 3px rgba(0, 0, 0, 0.5);
}
/* Для дней с обоими типами заметок в сегодняшнем состоянии */
.calendar-day.today.has-notes.has-edited-notes::before,
.calendar-day.today.has-notes.has-edited-notes::after {
border: 1px solid #fff;
box-shadow: 0 0 3px rgba(0, 0, 0, 0.5);
}
/* Темная тема для календаря (PC версия) */
@media (min-width: 769px) {
[data-theme="dark"] .mini-calendar,
[data-theme="dark"] .container-leftside .mini-calendar {
background-color: transparent;
}
[data-theme="dark"] .calendar-day {
background-color: transparent;
color: #ffffff;
border: 1px solid transparent;
}
[data-theme="dark"] .calendar-day:hover {
background-color: transparent;
border-color: var(--accent-color, #007bff);
}
[data-theme="dark"] .calendar-day.other-month {
background-color: transparent;
color: #999999;
border: 1px solid transparent;
}
[data-theme="dark"] .calendar-day.other-month:hover {
border-color: var(--accent-color, #007bff);
}
[data-theme="dark"] .calendar-day.today {
background-color: transparent;
color: #ffffff;
border: 1px solid var(--accent-color, #007bff);
}
[data-theme="dark"] .calendar-day.today:hover {
background-color: transparent;
border-color: var(--accent-color, #007bff);
}
[data-theme="dark"] .calendar-day.selected {
background-color: var(--accent-color, #007bff);
color: white;
opacity: 1;
border: 1px solid var(--accent-color, #007bff);
}
[data-theme="dark"] .calendar-day.selected:hover {
background-color: var(--accent-color, #007bff);
border-color: var(--accent-color, #007bff);
}
[data-theme="dark"] .calendar-nav {
color: #ffffff;
}
[data-theme="dark"] .calendar-nav:hover {
opacity: 0.8;
}
[data-theme="dark"] .calendar-weekday {
color: #999999;
}
[data-theme="dark"] .calendar-month-year {
color: #ffffff;
}
[data-theme="dark"] .calendar-day.has-notes::after {
background-color: #28a745;
}
[data-theme="dark"] .calendar-day.has-edited-notes::before {
background-color: #ffc107;
}
}
/* Индикаторы заметок в темной теме */
[data-theme="dark"] .calendar-day.has-notes::after {
background-color: #28a745;
box-shadow: 0 0 2px rgba(40, 167, 69, 0.6);
}
[data-theme="dark"] .calendar-day.has-edited-notes::before {
background-color: #ffc107;
box-shadow: 0 0 2px rgba(255, 193, 7, 0.6);
}
/* Стили для секции тегов */
.tags-section {
margin-top: 15px;
padding-top: 15px;
border-top: 1px solid var(--border-primary);
}
.tags-header {
margin-bottom: 10px;
}
.tags-title {
font-size: 12px;
font-weight: bold;
color: var(--text-primary);
}
.tags-container {
display: flex;
flex-wrap: wrap;
gap: 5px;
}
.tag {
display: inline-block;
padding: 4px 8px;
background-color: rgba(var(--accent-color-rgb), 0.1);
color: var(--accent-color);
border: 1px solid rgba(var(--accent-color-rgb), 0.3);
border-radius: 12px;
font-size: 10px;
font-weight: 500;
cursor: pointer;
transition: all 0.2s ease;
user-select: none;
max-width: 100%;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
word-break: break-word;
}
.tag:hover {
background-color: var(--accent-color, #007bff);
color: white;
}
.tag.active {
background-color: var(--accent-color, #007bff);
color: white;
font-weight: bold;
}
.tag-count {
margin-left: 4px;
font-size: 9px;
opacity: 0.8;
}
/* Стили для тегов в заметках */
.textNote .tag-in-note {
display: inline-block;
padding: 2px 6px;
background-color: rgba(var(--accent-color-rgb), 0.1);
color: var(--accent-color);
border: 1px solid rgba(var(--accent-color-rgb), 0.3);
border-radius: 8px;
font-size: 12px;
font-weight: 500;
cursor: pointer;
transition: all 0.2s ease;
text-decoration: none;
margin: 0 2px;
word-wrap: break-word;
overflow-wrap: break-word;
}
.textNote .tag-in-note:hover {
background-color: var(--accent-color, #007bff);
color: white;
transform: translateY(-1px);
box-shadow: 0 2px 4px rgba(var(--accent-color-rgb), 0.3);
}
/* Стили для подсветки результатов поиска */
.search-highlight {
background-color: #fff3cd;
padding: 1px 2px;
border-radius: 2px;
font-weight: 500;
}
.search-highlight.current {
background-color: #ffc107;
color: #000;
}
/* Стили для мобильного меню и слайдера */
.mobile-menu-btn {
display: none;
position: fixed;
top: 15px;
left: 15px;
z-index: 999;
background: var(--bg-secondary);
border: 1px solid var(--border-secondary);
border-radius: 8px;
padding: 10px 12px;
cursor: pointer;
box-shadow: 0 2px 8px var(--shadow-light);
transition: all 0.3s ease;
}
.mobile-menu-btn:hover {
background: var(--bg-quaternary);
box-shadow: 0 4px 12px var(--shadow-medium);
}
.mobile-menu-btn .iconify {
font-size: 24px;
color: var(--text-primary);
}
/* Мобильный слайдер */
.mobile-sidebar {
display: flex;
position: fixed;
top: 0;
left: -85vw;
width: 85vw;
max-width: 320px;
height: 100vh;
background: var(--bg-secondary);
color: var(--text-primary);
box-shadow: 2px 0 10px var(--shadow-light);
z-index: 1000;
overflow-y: auto;
transition: left 0.3s ease;
flex-direction: column;
padding: 0;
}
.mobile-sidebar.open {
left: 0;
}
.sidebar-close-btn {
display: flex;
align-items: center;
justify-content: center;
width: 40px;
height: 40px;
padding: 0;
margin: 10px 10px 10px auto;
background: var(--bg-tertiary);
border: 1px solid var(--border-secondary);
border-radius: 8px;
cursor: pointer;
transition: all 0.2s ease;
flex-shrink: 0;
}
.sidebar-close-btn:hover {
background: var(--bg-quaternary);
}
.sidebar-close-btn .iconify {
font-size: 20px;
color: var(--text-primary);
}
.sidebar-content {
padding: 10px 12px;
overflow-y: auto;
flex: 1;
}
/* Правильные стили для календаря в слайдере */
.mobile-sidebar .mini-calendar {
width: 100%;
margin-bottom: 15px;
}
.mobile-sidebar .calendar-header {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 8px;
gap: 4px;
}
.mobile-sidebar .calendar-month-year {
font-size: 12px;
font-weight: bold;
color: var(--text-primary);
text-align: center;
flex: 1;
}
.mobile-sidebar .calendar-nav {
background: none;
border: none;
font-size: 16px;
cursor: pointer;
color: var(--text-secondary);
padding: 0 3px;
transition: color 0.3s ease;
}
.mobile-sidebar .calendar-nav:hover {
color: var(--accent-color);
}
/* Календарь дней в слайдере */
.mobile-sidebar .calendar-days {
display: grid;
grid-template-columns: repeat(7, 1fr);
gap: 1px;
margin-bottom: 15px;
}
.mobile-sidebar .calendar-day {
aspect-ratio: 1;
display: flex;
align-items: center;
justify-content: center;
font-size: 9px;
cursor: pointer;
border-radius: 3px;
transition: all 0.2s ease;
color: var(--text-primary);
padding: 1px;
font-weight: 500;
position: relative;
background-color: transparent;
border: 1px solid transparent;
}
.mobile-sidebar .calendar-day:hover {
background-color: transparent;
border-color: var(--accent-color, #007bff);
}
.mobile-sidebar .calendar-day.today {
background-color: transparent;
color: var(--text-primary);
font-weight: bold;
border: 1px solid var(--accent-color, #007bff);
}
.mobile-sidebar .calendar-day.today:hover {
background-color: transparent;
border-color: var(--accent-color, #007bff);
}
.mobile-sidebar .calendar-day.selected {
background-color: var(--accent-color, #007bff);
color: white;
font-weight: bold;
opacity: 1;
border: 1px solid var(--accent-color, #007bff);
}
.mobile-sidebar .calendar-day.selected:hover {
background-color: var(--accent-color, #007bff);
border-color: var(--accent-color, #007bff);
}
.mobile-sidebar .calendar-day.other-month {
color: var(--text-muted);
background-color: transparent;
border: 1px solid transparent;
}
.mobile-sidebar .calendar-day.other-month:hover {
border-color: var(--accent-color, #007bff);
}
/* Темная тема для календаря в мобильном сайдбаре */
[data-theme="dark"] .mobile-sidebar .calendar-day {
background-color: transparent;
color: var(--text-primary);
border: 1px solid transparent;
}
[data-theme="dark"] .mobile-sidebar .calendar-day:hover {
background-color: transparent;
border-color: var(--accent-color, #007bff);
}
[data-theme="dark"] .mobile-sidebar .calendar-day.other-month {
background-color: transparent;
color: var(--text-muted);
border: 1px solid transparent;
}
[data-theme="dark"] .mobile-sidebar .calendar-day.other-month:hover {
border-color: var(--accent-color, #007bff);
}
[data-theme="dark"] .mobile-sidebar .calendar-day.today {
background-color: transparent;
color: var(--text-primary);
border: 1px solid var(--accent-color, #007bff);
}
[data-theme="dark"] .mobile-sidebar .calendar-day.today:hover {
background-color: transparent;
border-color: var(--accent-color, #007bff);
}
[data-theme="dark"] .mobile-sidebar .calendar-day.selected {
background-color: var(--accent-color, #007bff);
color: white;
opacity: 1;
border: 1px solid var(--accent-color, #007bff);
}
[data-theme="dark"] .mobile-sidebar .calendar-day.selected:hover {
background-color: var(--accent-color, #007bff);
border-color: var(--accent-color, #007bff);
}
[data-theme="dark"] .mobile-sidebar .calendar-nav:hover {
color: var(--border-focus);
}
[data-theme="dark"] .mobile-sidebar .calendar-weekday {
color: var(--text-secondary);
}
/* Индикаторы заметок в темной теме для мобильного календаря */
[data-theme="dark"] .mobile-sidebar .calendar-day.has-notes::after {
background-color: #28a745;
box-shadow: 0 0 2px rgba(40, 167, 69, 0.6);
}
[data-theme="dark"] .mobile-sidebar .calendar-day.has-edited-notes::before {
background-color: #ffc107;
box-shadow: 0 0 2px rgba(255, 193, 7, 0.6);
}
/* Поиск в слайдере */
.mobile-sidebar .search-section {
margin-bottom: 15px;
padding-bottom: 15px;
border-bottom: 1px solid var(--border-primary);
}
.mobile-sidebar .search-title {
font-size: 11px;
font-weight: bold;
color: var(--text-primary);
display: block;
margin-bottom: 8px;
}
.mobile-sidebar .search-input {
width: 100%;
padding: 6px 10px;
border: 1px solid var(--border-secondary);
border-radius: 15px;
font-size: 11px;
background-color: var(--bg-tertiary);
color: var(--text-primary);
transition: all 0.3s ease;
box-sizing: border-box;
}
.mobile-sidebar .search-input:focus {
outline: none;
border-color: var(--accent-color, #007bff);
background-color: var(--bg-secondary);
box-shadow: 0 0 0 2px rgba(var(--accent-color-rgb), 0.25);
}
/* Теги в слайдере */
.mobile-sidebar .tags-section {
margin-top: 0;
padding-top: 0;
border-top: none;
}
.mobile-sidebar .tags-title {
font-size: 11px;
font-weight: bold;
color: var(--text-primary);
display: block;
margin-bottom: 8px;
}
.mobile-sidebar .tags-container {
display: flex;
flex-wrap: wrap;
gap: 5px;
}
.mobile-sidebar .tag {
display: inline-block;
padding: 4px 8px;
background-color: rgba(var(--accent-color-rgb), 0.1);
color: var(--accent-color);
border: 1px solid rgba(var(--accent-color-rgb), 0.3);
border-radius: 12px;
font-size: 9px;
font-weight: 500;
cursor: pointer;
transition: all 0.2s ease;
user-select: none;
max-width: 100%;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
word-break: break-word;
touch-action: manipulation;
-webkit-tap-highlight-color: transparent;
}
.mobile-sidebar .tag:not(.active) {
background-color: rgba(var(--accent-color-rgb), 0.1) !important;
color: var(--accent-color) !important;
}
.mobile-sidebar .tag:not(.active):hover {
background-color: var(--accent-color, #007bff);
color: white;
}
/* Отключаем hover эффекты на touch-устройствах для предотвращения "залипания" */
@media (hover: none) and (pointer: coarse) {
.mobile-sidebar .tag:not(.active):hover {
background-color: rgba(var(--accent-color-rgb), 0.1) !important;
color: var(--accent-color) !important;
}
}
.mobile-sidebar .tag:not(.active):active,
.mobile-sidebar .tag:not(.active):focus,
.mobile-sidebar .tag:not(.active):focus:active {
background-color: rgba(var(--accent-color-rgb), 0.1) !important;
color: var(--accent-color) !important;
outline: none;
}
.mobile-sidebar .tag.active {
background-color: var(--accent-color, #007bff);
color: white;
font-weight: bold;
}
.mobile-sidebar .tag.active:active,
.mobile-sidebar .tag.active:focus {
background-color: var(--accent-color, #007bff);
color: white;
outline: none;
}
.mobile-sidebar .tag-count {
margin-left: 3px;
font-size: 8px;
opacity: 0.8;
}
/* Оверлей для закрытия слайдера */
.mobile-sidebar-overlay {
display: none;
position: fixed;
top: 0;
left: 0;
right: 0;
bottom: 0;
background: rgba(0, 0, 0, 0.5);
z-index: 999;
opacity: 0;
transition: opacity 0.3s ease;
}
.mobile-sidebar-overlay.open {
display: block;
opacity: 1;
}
/* Мобильная адаптация */
@media (max-width: 768px) {
/* Адаптация переключателя AI */
.ai-toggle-label {
padding: 12px 16px;
}
.toggle-text-main {
font-size: 14px;
}
.toggle-text-desc {
font-size: 11px;
}
.toggle-switch-wrapper {
margin-left: 12px;
}
.toggle-slider {
width: 44px;
height: 24px;
}
.toggle-slider::before {
width: 20px;
height: 20px;
}
.toggle-checkbox:checked + .toggle-slider::before {
transform: translateX(20px);
}
/* Показываем мобильное меню */
.mobile-menu-btn {
display: flex;
align-items: center;
justify-content: center;
}
/* Скрываем левый блок с календарем, поиском и тегами */
.container-leftside {
display: none !important;
}
/* На мобильных устройствах меняем направление flex и центрируем */
body {
flex-direction: column;
gap: 0;
padding: 0 10px;
justify-content: flex-start;
align-items: center;
}
/* Центральный контейнер занимает всю ширину, но центрируется */
.center {
width: 100%;
max-width: 600px;
margin: 0 auto;
margin-top: 60px;
}
/* Адаптируем контейнер заметок */
.container {
width: 100%;
max-width: none;
margin-top: 5px;
padding: 10px;
box-sizing: border-box;
}
/* Уменьшаем отступ сверху для первого блока "Мои заметки" на мобильных */
.center > .container:first-child {
margin-top: 3px;
}
/* Убираем margin-top у заметок на мобильных, так как gap уже обеспечивает отступы */
.notes-container .container {
margin-top: 0;
}
/* Добавляем отступ сверху для контейнера заметок на мобильных */
.notes-container {
margin-top: 5px;
}
/* Адаптируем заголовок заметок */
.notes-header {
flex-direction: row;
align-items: center;
gap: 10px;
width: 100%;
}
.notes-header-left {
flex: 1;
min-width: 0;
}
.user-info {
flex-shrink: 0;
flex-wrap: wrap;
gap: 8px;
}
.user-info .back-btn {
font-size: 12px;
padding: 6px 8px;
white-space: nowrap;
}
.user-info .theme-toggle-btn {
flex-shrink: 0;
}
/* Дополнительная адаптация для очень маленьких экранов */
@media (max-width: 480px) {
.user-info {
flex-shrink: 0;
gap: 4px;
}
.user-info .back-btn {
font-size: 11px;
padding: 4px 6px;
}
.user-info .theme-toggle-btn {
width: 32px;
height: 32px;
padding: 6px;
}
.user-info .theme-toggle-btn .iconify {
font-size: 16px;
}
.settings-icon-btn {
width: 32px;
height: 32px;
padding: 6px;
}
.settings-icon-btn .iconify {
font-size: 16px;
}
}
/* Адаптируем кнопки markdown */
.markdown-buttons {
display: flex;
flex-wrap: nowrap;
gap: 8px;
width: 100%;
justify-content: flex-start;
overflow-x: auto;
overflow-y: hidden;
scrollbar-width: none;
}
.markdown-buttons::-webkit-scrollbar {
display: none;
}
.markdown-buttons .btnMarkdown {
flex: 0 1 auto;
min-width: auto;
margin-right: 0;
padding: 8px 12px;
font-size: 14px;
border: none;
background-color: transparent;
}
/* Адаптируем textarea */
textarea {
min-height: 100px;
}
/* Адаптируем кнопку сохранения */
.save-button-container {
width: 100%;
flex-direction: column;
}
.action-buttons {
width: 100%;
flex-direction: column;
}
.btnSave,
.btnAI,
.btn-secondary {
width: 100%;
text-align: center;
justify-content: center;
}
/* Адаптируем footer */
.footer {
position: relative;
margin-top: 20px;
}
}
/* Стили для загрузки изображений */
.image-preview-container {
margin: 15px 0;
padding: 15px;
background: #f8f9fa;
border: 2px dashed #dee2e6;
border-radius: 8px;
/* Улучшения для мобильных устройств */
touch-action: manipulation;
-webkit-tap-highlight-color: transparent;
}
.image-preview-header {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 10px;
font-weight: 600;
color: #495057;
}
/* Стили для контейнера предпросмотра заметки */
.note-preview-container {
margin: 15px 0;
padding: 15px;
background: var(--bg-tertiary);
border: 2px solid var(--accent-color, #007bff);
border-radius: 8px;
min-height: 200px;
max-height: 600px;
overflow-y: auto;
transition: background-color 0.3s ease, border-color 0.3s ease;
}
.note-preview-header {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 15px;
padding-bottom: 10px;
border-bottom: 2px solid var(--border-primary);
font-weight: 600;
color: var(--accent-color, #007bff);
font-size: 16px;
transition: color 0.3s ease, border-color 0.3s ease;
}
.note-preview-content {
background: var(--bg-secondary);
color: var(--text-primary);
padding: 15px;
border-radius: 6px;
min-height: 150px;
transition: background-color 0.3s ease, color 0.3s ease;
}
/* Выравниваем размер контейнеров в режиме редактирования под размер контейнеров создания */
.textNote .markdown-buttons--edit,
.textNote .note-preview-container,
.textNote .image-preview-container,
.textNote .file-preview-container,
.textNote .textInput,
.textNote textarea.textInput {
width: 100%;
box-sizing: border-box;
}
/* Стили для файлов в режиме редактирования - делаем такими же сжатыми как в создании */
.textNote .file-preview-container .file-preview-item {
padding: 6px 10px;
min-height: 40px;
}
.textNote .file-preview-container .file-preview-item .file-icon {
font-size: 24px;
}
.textNote .file-preview-container .file-preview-item .file-name {
font-size: 14px;
line-height: 1.2;
}
.textNote .file-preview-container .file-preview-item .file-size {
font-size: 11px;
margin-top: 1px;
line-height: 1.2;
}
.textNote .file-preview-container .file-preview-item .remove-file-btn {
width: 24px;
height: 24px;
font-size: 14px;
}
.note-preview-content h1,
.note-preview-content h2,
.note-preview-content h3,
.note-preview-content h4,
.note-preview-content h5,
.note-preview-content h6 {
margin-top: 0.5em;
margin-bottom: 0.5em;
color: var(--text-primary);
transition: color 0.3s ease;
}
.note-preview-content p {
margin: 0.5em 0;
color: var(--text-primary);
transition: color 0.3s ease;
}
.note-preview-content ul,
.note-preview-content ol {
margin: 0.5em 0;
padding-left: 2em;
color: var(--text-primary);
transition: color 0.3s ease;
}
.note-preview-content li {
color: var(--text-primary);
transition: color 0.3s ease;
}
.note-preview-content a {
color: var(--accent-color, #007bff);
text-decoration: none;
transition: color 0.3s ease;
}
.note-preview-content a:hover {
text-decoration: underline;
}
.note-preview-content code {
background: var(--bg-quaternary);
color: var(--text-primary);
padding: 2px 6px;
border-radius: 4px;
font-family: "Courier New", monospace;
transition: background-color 0.3s ease, color 0.3s ease;
}
.note-preview-content pre {
background: var(--bg-quaternary);
color: var(--text-primary);
padding: 10px;
border-radius: 6px;
overflow-x: auto;
border: 1px solid var(--border-primary);
transition: background-color 0.3s ease, color 0.3s ease,
border-color 0.3s ease;
}
.note-preview-content pre code {
background: transparent;
padding: 0;
border-radius: 0;
}
.note-preview-content blockquote {
border-left: 4px solid var(--accent-color, #007bff);
padding-left: 15px;
margin: 10px 0;
color: var(--text-secondary);
background-color: var(--bg-tertiary);
padding: 8px 15px;
border-radius: 0 4px 4px 0;
transition: color 0.3s ease, background-color 0.3s ease,
border-color 0.3s ease;
}
.note-preview-content blockquote p {
color: var(--text-secondary);
margin: 0;
}
.note-preview-content img {
max-width: 100%;
height: auto;
border-radius: 6px;
margin: 10px 0;
box-shadow: 0 2px 4px var(--shadow-light);
transition: box-shadow 0.3s ease;
}
.note-preview-content table {
width: 100%;
border-collapse: collapse;
margin: 10px 0;
background: var(--bg-secondary);
border-radius: 6px;
overflow: hidden;
box-shadow: 0 1px 3px var(--shadow-light);
transition: background-color 0.3s ease, box-shadow 0.3s ease;
}
.note-preview-content th,
.note-preview-content td {
padding: 8px 12px;
text-align: left;
border-bottom: 1px solid var(--border-primary);
color: var(--text-primary);
transition: color 0.3s ease, border-color 0.3s ease;
}
.note-preview-content th {
background: var(--bg-tertiary);
font-weight: bold;
color: var(--text-primary);
transition: background-color 0.3s ease, color 0.3s ease;
}
.note-preview-content tr:hover {
background: var(--bg-quaternary);
transition: background-color 0.3s ease;
}
.note-preview-content hr {
border: none;
height: 1px;
background: var(--border-primary);
margin: 20px 0;
transition: background-color 0.3s ease;
}
/* Специальные стили для темной темы в предпросмотре */
[data-theme="dark"] .note-preview-container {
background: var(--bg-tertiary);
border-color: var(--accent-color);
}
[data-theme="dark"] .note-preview-header {
color: var(--accent-color);
border-bottom-color: var(--border-primary);
}
[data-theme="dark"] .note-preview-content {
background: var(--bg-secondary);
color: var(--text-primary);
}
[data-theme="dark"] .note-preview-content code {
background: var(--bg-quaternary);
color: #e6e6e6;
border: 1px solid var(--border-primary);
}
[data-theme="dark"] .note-preview-content pre {
background: var(--bg-quaternary);
color: #e6e6e6;
border: 1px solid var(--border-primary);
}
[data-theme="dark"] .note-preview-content pre code {
background: transparent;
border: none;
color: #e6e6e6;
}
[data-theme="dark"] .note-preview-content blockquote {
background-color: var(--bg-tertiary);
border-left-color: var(--accent-color);
color: var(--text-secondary);
}
[data-theme="dark"] .note-preview-content table {
background: var(--bg-secondary);
box-shadow: 0 1px 3px var(--shadow-light);
}
[data-theme="dark"] .note-preview-content th {
background: var(--bg-tertiary);
color: var(--text-primary);
}
[data-theme="dark"] .note-preview-content th,
[data-theme="dark"] .note-preview-content td {
border-bottom-color: var(--border-primary);
color: var(--text-primary);
}
[data-theme="dark"] .note-preview-content tr:hover {
background: var(--bg-quaternary);
}
[data-theme="dark"] .note-preview-content img {
box-shadow: 0 2px 4px var(--shadow-light);
}
/* Стили для чекбоксов в предпросмотре */
.note-preview-content input[type="checkbox"] {
cursor: pointer;
margin-right: 8px;
width: 18px;
height: 18px;
accent-color: var(--accent-color, #007bff);
vertical-align: middle;
position: relative;
top: -1px;
}
/* Стили для элементов списка с чекбоксами в предпросмотре */
.note-preview-content .task-list-item {
list-style-type: none;
margin-left: -20px;
padding: 0;
line-height: 1.5;
transition: all 0.3s ease;
}
.note-preview-content .task-list-item:has(input[type="checkbox"]:checked) {
opacity: 0.65;
text-decoration: line-through;
color: var(--text-muted);
}
.note-preview-content .task-list-item input[type="checkbox"]:checked ~ * {
text-decoration: line-through;
color: var(--text-muted);
}
.note-preview-content .task-list-item:has(input[type="checkbox"]:checked) * {
text-decoration: line-through;
color: var(--text-muted);
}
.note-preview-content .task-list-item:hover {
background-color: rgba(var(--accent-color-rgb), 0.05);
border-radius: 4px;
padding-left: 4px;
margin-left: -24px;
}
/* Альтернативный вариант для перечеркивания всего текста в элементе */
.note-preview-content input[type="checkbox"]:checked {
text-decoration: none;
}
.note-preview-content input[type="checkbox"]:checked + * {
text-decoration: line-through;
color: var(--text-muted);
}
/* Если marked.js не добавляет класс task-list-item, используем :has селектор */
.note-preview-content li:has(input[type="checkbox"]) {
list-style-type: none;
margin-left: -20px;
padding: 0;
line-height: 1.5;
transition: all 0.3s ease;
}
.note-preview-content li:has(input[type="checkbox"]:checked) {
opacity: 0.65;
text-decoration: line-through;
color: var(--text-muted);
}
.note-preview-content
li:has(input[type="checkbox"])
input[type="checkbox"]:checked {
text-decoration: none;
}
.note-preview-content li:has(input[type="checkbox"]:checked) label,
.note-preview-content li:has(input[type="checkbox"]:checked) span,
.note-preview-content li:has(input[type="checkbox"]:checked) p {
text-decoration: line-through;
color: var(--text-muted);
}
.note-preview-content li:has(input[type="checkbox"]:checked) * {
text-decoration: line-through;
color: var(--text-muted);
}
.note-preview-content li:has(input[type="checkbox"]):hover {
background-color: rgba(var(--accent-color-rgb), 0.05);
border-radius: 4px;
padding-left: 4px;
margin-left: -24px;
}
.clear-images-btn {
background: #dc3545;
color: white;
border: none;
padding: 4px 8px;
border-radius: 4px;
cursor: pointer;
font-size: 12px;
transition: background-color 0.3s ease;
}
.clear-images-btn:hover {
background: #c82333;
}
.image-preview-list {
display: flex;
flex-wrap: wrap;
gap: 10px;
}
.image-preview-item {
position: relative;
border: 1px solid #dee2e6;
border-radius: 6px;
overflow: hidden;
background: white;
}
.image-preview-item img {
width: 100px;
height: 100px;
object-fit: cover;
display: block;
}
.image-preview-item .remove-image-btn {
position: absolute;
top: 2px;
right: 2px;
background: rgba(220, 53, 69, 0.8);
color: white;
border: none;
border-radius: 50%;
width: 24px; /* Увеличиваем размер для touch */
height: 24px; /* Увеличиваем размер для touch */
cursor: pointer;
font-size: 14px; /* Увеличиваем размер шрифта */
display: flex;
align-items: center;
justify-content: center;
transition: background-color 0.3s ease;
/* Улучшения для мобильных устройств */
touch-action: manipulation;
-webkit-tap-highlight-color: transparent;
user-select: none;
-webkit-user-select: none;
}
.image-preview-item .remove-image-btn:hover {
background: rgba(220, 53, 69, 1);
}
/* Стили для кнопок удаления изображений и файлов в режиме редактирования */
.image-preview-item .image-preview-remove {
position: absolute;
top: 2px;
right: 2px;
background: rgba(220, 53, 69, 0.9);
color: white;
border: none;
border-radius: 50%;
width: 28px;
height: 28px;
cursor: pointer;
font-size: 16px;
display: flex;
align-items: center;
justify-content: center;
transition: all 0.3s ease;
touch-action: manipulation;
-webkit-tap-highlight-color: transparent;
user-select: none;
-webkit-user-select: none;
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
z-index: 10;
}
.image-preview-item .image-preview-remove:hover {
background: rgba(220, 53, 69, 1);
transform: scale(1.1);
box-shadow: 0 3px 6px rgba(0, 0, 0, 0.3);
}
.image-preview-item .image-preview-remove:active {
transform: scale(0.95);
}
.file-preview-item .file-preview-remove {
background: rgba(220, 53, 69, 0.9);
color: white;
border: none;
border-radius: 50%;
width: 28px;
height: 28px;
cursor: pointer;
font-size: 16px;
display: flex;
align-items: center;
justify-content: center;
flex-shrink: 0;
transition: all 0.3s ease;
touch-action: manipulation;
-webkit-tap-highlight-color: transparent;
user-select: none;
-webkit-user-select: none;
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
margin-left: auto;
}
.file-preview-item .file-preview-remove:hover {
background: rgba(220, 53, 69, 1);
transform: scale(1.1);
box-shadow: 0 3px 6px rgba(0, 0, 0, 0.3);
}
.file-preview-item .file-preview-remove:active {
transform: scale(0.95);
}
/* Стили для кнопки восстановления (зеленая) */
.image-preview-item .image-preview-remove.restore-btn,
.file-preview-item .file-preview-remove.restore-btn {
background: rgba(40, 167, 69, 0.9) !important;
}
.image-preview-item .image-preview-remove.restore-btn:hover,
.file-preview-item .file-preview-remove.restore-btn:hover {
background: rgba(40, 167, 69, 1) !important;
}
.image-preview-item .image-preview-remove[style*="green"],
.file-preview-item .file-preview-remove[style*="green"] {
background: rgba(40, 167, 69, 0.9) !important;
}
.image-preview-item .image-preview-remove[style*="green"]:hover,
.file-preview-item .file-preview-remove[style*="green"]:hover {
background: rgba(40, 167, 69, 1) !important;
}
.image-preview-item .image-info {
padding: 4px 6px;
font-size: 10px;
color: #6c757d;
background: #f8f9fa;
word-break: break-all;
}
/* Стили для изображений в заметках */
.note-image {
width: 150px;
height: 150px;
object-fit: cover;
border-radius: 6px;
margin: 10px 0;
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
cursor: pointer;
transition: transform 0.2s ease;
}
.note-image:hover {
transform: scale(1.02);
box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}
.note-image::after {
content: "🔍";
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
background: rgba(0, 0, 0, 0.7);
color: white;
padding: 8px;
border-radius: 50%;
font-size: 16px;
opacity: 0;
transition: opacity 0.2s ease;
pointer-events: none;
}
.note-image:hover::after {
opacity: 1;
}
.note-images-container {
margin: 10px 0;
display: flex;
flex-wrap: wrap;
gap: 10px;
}
.note-image-item {
position: relative;
display: inline-block;
}
.note-image-item .note-image {
position: relative;
}
.note-files-container {
margin: 10px 0;
display: flex;
flex-direction: column;
gap: 8px;
}
.note-file-item {
display: flex;
align-items: center;
}
.note-file-link {
display: flex;
align-items: center;
padding: 10px;
background: #f8f9fa;
border: 1px solid #dee2e6;
border-radius: 6px;
text-decoration: none;
color: inherit;
gap: 12px;
width: 100%;
transition: all 0.2s;
}
.note-file-link:hover {
background: #e9ecef;
border-color: var(--accent-color, #007bff);
transform: translateY(-1px);
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}
.note-file-link .file-icon {
font-size: 32px;
color: var(--accent-color, #007bff);
flex-shrink: 0;
}
.note-file-link .file-info {
flex: 1;
min-width: 0;
}
.note-file-link .file-name {
font-weight: 500;
color: #333;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.note-file-link .file-size {
font-size: 12px;
color: #666;
margin-top: 2px;
}
.note-image-item .remove-note-image-btn {
position: absolute;
top: 5px;
right: 5px;
background: rgba(220, 53, 69, 0.8);
color: white;
border: none;
border-radius: 50%;
width: 24px;
height: 24px;
cursor: pointer;
font-size: 14px;
display: flex;
align-items: center;
justify-content: center;
transition: background-color 0.3s ease;
opacity: 0;
}
.note-image-item:hover .remove-note-image-btn {
opacity: 1;
}
.note-image-item .remove-note-image-btn:hover {
background: rgba(220, 53, 69, 1);
}
/* Модальное окно для просмотра изображений */
.image-modal {
display: none;
position: fixed;
z-index: 1000;
left: 0;
top: 0;
width: 100%;
height: 100%;
background-color: rgba(0, 0, 0, 0.9);
cursor: pointer;
}
.image-modal-content {
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
max-width: 90%;
max-height: 90%;
object-fit: contain;
}
.image-modal-close {
position: absolute;
top: 15px;
right: 35px;
color: #f1f1f1;
font-size: 40px;
font-weight: bold;
cursor: pointer;
}
.image-modal-close:hover {
color: #bbb;
}
/* Модальное окно подтверждения */
.modal {
display: none;
position: fixed;
z-index: 1000;
left: 0;
top: 0;
width: 100%;
height: 100%;
background-color: rgba(0, 0, 0, 0.5);
backdrop-filter: blur(2px);
}
.modal-content {
background-color: #fff;
margin: 10% auto;
padding: 0;
border-radius: 8px;
width: 90%;
max-width: 500px;
box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
animation: modalFadeIn 0.3s ease-out;
}
@keyframes modalFadeIn {
from {
opacity: 0;
transform: translateY(-20px);
}
to {
opacity: 1;
transform: translateY(0);
}
}
.modal-header {
padding: 20px 25px;
border-bottom: 1px solid #eee;
display: flex;
justify-content: space-between;
align-items: center;
}
.modal-header h3 {
margin: 0;
color: #333;
font-size: 20px;
}
.modal-close {
color: #aaa;
font-size: 28px;
font-weight: bold;
cursor: pointer;
line-height: 1;
}
.modal-close:hover {
color: #666;
}
.modal-body {
padding: 25px;
color: #555;
line-height: 1.5;
}
.modal-footer {
padding: 20px 25px;
border-top: 1px solid #eee;
display: flex;
justify-content: flex-end;
gap: 10px;
}
/* Темная тема для модального окна */
[data-theme="dark"] .modal-content {
background-color: var(--bg-secondary);
color: var(--text-primary);
}
[data-theme="dark"] .modal-header {
border-bottom-color: var(--border-primary);
}
[data-theme="dark"] .modal-header h3 {
color: var(--text-primary);
}
[data-theme="dark"] .modal-close {
color: var(--text-secondary);
}
[data-theme="dark"] .modal-close:hover {
color: var(--text-primary);
}
[data-theme="dark"] .modal-body {
color: var(--text-secondary);
}
[data-theme="dark"] .modal-footer {
border-top-color: var(--border-primary);
}
/* Стили для поля пароля в модальном окне */
.modal-password-input {
width: 100%;
padding: 10px;
border: 1px solid var(--border-secondary);
border-radius: 4px;
font-size: 16px;
background-color: var(--bg-tertiary);
color: var(--text-primary);
box-sizing: border-box;
transition: all 0.3s ease;
}
.modal-password-input:focus {
outline: none;
border-color: var(--border-focus);
background-color: var(--bg-secondary);
box-shadow: 0 0 0 2px rgba(74, 158, 255, 0.25);
}
.modal-password-input::placeholder {
color: var(--text-muted);
}
/* Адаптивность для изображений */
@media (max-width: 768px) {
.image-preview-list {
justify-content: center;
}
.note-images-container {
justify-content: center;
}
.image-preview-item img {
width: 80px;
height: 80px;
}
/* Улучшения для мобильных устройств */
.markdown-buttons .btnMarkdown {
min-height: 48px; /* Увеличиваем высоту для touch */
padding: 8px 12px;
margin: 2px;
}
.image-preview-item .remove-image-btn {
width: 28px; /* Еще больше для мобильных */
height: 28px;
font-size: 16px;
}
.image-preview-item .image-preview-remove {
width: 32px;
height: 32px;
font-size: 18px;
}
.file-preview-item .file-preview-remove {
width: 32px;
height: 32px;
font-size: 18px;
}
.clear-images-btn {
min-height: 44px; /* Минимальная высота для touch */
padding: 8px 16px;
font-size: 14px;
}
.note-image {
width: 120px;
height: 120px;
}
}
/* Стили для выбора цветового акцента */
.accent-color-picker {
display: flex;
gap: 10px;
margin-bottom: 10px;
flex-wrap: wrap;
}
.color-option {
width: 40px;
height: 40px;
border-radius: 50%;
cursor: pointer;
border: 3px solid transparent;
transition: all 0.3s ease;
position: relative;
}
.color-option:hover {
transform: scale(1.1);
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}
.color-option.selected {
border-color: #333;
transform: scale(1.1);
box-shadow: 0 0 0 2px white, 0 0 0 4px #333;
}
.color-option::after {
content: "✓";
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
color: white;
font-weight: bold;
font-size: 18px;
opacity: 0;
transition: opacity 0.2s ease;
}
.color-option.selected::after {
opacity: 1;
}
#accentColor {
width: 60px;
height: 40px;
border: none;
border-radius: 5px;
cursor: pointer;
}
/* Стили для страницы настроек */
.settings-tabs {
display: flex;
gap: 10px;
margin: 20px 0;
border-bottom: 2px solid #e0e0e0;
flex-wrap: wrap;
}
.settings-tab {
padding: 10px 20px;
background: none;
border: none;
border-bottom: 3px solid transparent;
cursor: pointer;
font-size: 16px;
color: #666;
transition: all 0.3s ease;
display: flex;
align-items: center;
gap: 8px;
}
.settings-tab:hover {
color: var(--accent-color, #007bff);
background: rgba(var(--accent-color-rgb), 0.05);
}
.settings-tab.active {
color: var(--accent-color, #007bff);
border-bottom-color: var(--accent-color, #007bff);
font-weight: bold;
}
.settings-content {
margin-top: 20px;
}
.tab-content {
display: none;
}
.tab-content.active {
display: block;
}
/* Архивные заметки */
.archived-notes-list {
display: flex;
flex-direction: column;
gap: 15px;
}
.archived-note-item {
background: var(--bg-secondary);
border: 1px solid var(--border-primary);
border-radius: 8px;
padding: 15px;
transition: all 0.3s ease;
color: var(--text-primary);
}
.archived-note-item:hover {
box-shadow: 0 2px 8px var(--shadow-light);
}
.archived-note-header {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 10px;
flex-wrap: wrap;
gap: 10px;
}
.archived-note-date {
font-size: 12px;
color: var(--text-muted);
}
.archived-note-actions {
display: flex;
gap: 8px;
}
.btn-restore,
.btn-delete-permanent {
padding: 6px 12px;
border: 1px solid var(--border-secondary);
border-radius: 5px;
background: var(--bg-tertiary);
color: var(--text-primary);
cursor: pointer;
font-size: 13px;
transition: all 0.3s ease;
display: flex;
align-items: center;
gap: 4px;
}
.btn-restore {
color: var(--accent-color, #007bff);
border-color: var(--accent-color, #007bff);
}
.btn-restore:hover {
background: var(--accent-color, #007bff);
color: white;
}
.btn-delete-permanent {
color: #dc3545;
border-color: #dc3545;
}
.btn-delete-permanent:hover {
background: #dc3545;
color: white;
}
/* Стили для новых кнопок */
.btn-primary {
background-color: var(--accent-color, #007bff);
color: white;
border: 1px solid var(--accent-color, #007bff);
padding: 10px 20px;
border-radius: 5px;
cursor: pointer;
font-size: 14px;
transition: all 0.3s ease;
display: inline-flex;
align-items: center;
gap: 6px;
}
.btn-primary:hover {
background-color: var(--accent-color, #007bff);
border-color: var(--accent-color, #007bff);
opacity: 0.9;
filter: brightness(0.9);
}
.btn-primary:disabled {
background-color: #6c757d;
border-color: #6c757d;
cursor: not-allowed;
opacity: 0.6;
}
.btn-danger {
background-color: #dc3545;
color: white;
border: 1px solid #dc3545;
padding: 10px 20px;
border-radius: 5px;
cursor: pointer;
font-size: 14px;
transition: all 0.3s ease;
display: inline-flex;
align-items: center;
gap: 6px;
}
.btn-danger:hover {
background-color: #c82333;
border-color: #bd2130;
}
.btn-danger:disabled {
background-color: #6c757d;
border-color: #6c757d;
cursor: not-allowed;
opacity: 0.6;
}
/* Стили для опасной зоны */
.danger-zone {
background-color: var(--bg-secondary);
border: 2px solid #dc3545;
border-radius: 8px;
padding: 20px;
margin-top: 20px;
position: relative;
}
.danger-zone::before {
content: "⚠️";
position: absolute;
top: -10px;
left: 20px;
background-color: var(--bg-primary);
padding: 0 10px;
font-size: 16px;
}
.danger-zone h3 {
color: #dc3545;
margin-top: 0;
margin-bottom: 15px;
font-size: 18px;
font-weight: bold;
}
.danger-zone p {
color: var(--text-secondary);
font-size: 14px;
line-height: 1.5;
margin-bottom: 15px;
}
.danger-zone .btn-danger {
background-color: #dc3545;
border-color: #dc3545;
font-weight: 600;
padding: 12px 24px;
font-size: 15px;
}
.danger-zone .btn-danger:hover {
background-color: #c82333;
border-color: #bd2130;
transform: translateY(-1px);
box-shadow: 0 4px 8px rgba(220, 53, 69, 0.3);
}
.btn-secondary {
background-color: var(--bg-tertiary);
color: var(--text-primary);
border: 1px solid var(--border-secondary);
padding: 10px 20px;
border-radius: 5px;
cursor: pointer;
font-size: 14px;
transition: all 0.3s ease;
}
.btn-secondary:hover {
background-color: var(--bg-quaternary);
}
.btn-secondary.active {
background-color: var(--accent-color);
color: white;
border-color: var(--accent-color);
}
.archived-note-content {
font-size: 14px;
color: var(--text-primary);
line-height: 1.5;
max-height: 100px;
overflow: hidden;
text-overflow: ellipsis;
word-wrap: break-word;
overflow-wrap: break-word;
}
.archived-note-images {
margin-top: 10px;
font-size: 12px;
color: var(--text-secondary);
font-style: italic;
}
/* История действий */
.logs-filters {
display: flex;
gap: 10px;
margin-bottom: 20px;
flex-wrap: wrap;
}
.log-filter-select {
flex: 1;
min-width: 200px;
padding: 8px 12px;
border: 1px solid var(--border-secondary);
border-radius: 5px;
font-size: 14px;
background-color: var(--bg-tertiary);
color: var(--text-primary);
}
.log-filter-select:focus {
outline: none;
border-color: var(--accent-color, #007bff);
}
.logs-table-container {
overflow-x: auto;
margin-bottom: 20px;
}
.logs-table {
width: 100%;
border-collapse: collapse;
background: var(--bg-secondary);
color: var(--text-primary);
border-radius: 8px;
overflow: hidden;
box-shadow: 0 1px 3px var(--shadow-light);
}
.logs-table thead {
background: var(--bg-tertiary);
}
.logs-table th {
padding: 12px;
text-align: left;
font-weight: bold;
color: var(--text-primary);
border-bottom: 2px solid var(--border-primary);
font-size: 14px;
}
.logs-table td {
padding: 12px;
border-bottom: 1px solid var(--border-primary);
font-size: 13px;
color: var(--text-secondary);
}
.logs-table tbody tr:hover {
background: var(--bg-quaternary);
}
.log-action-badge {
display: inline-block;
padding: 4px 8px;
border-radius: 4px;
font-size: 12px;
font-weight: 500;
white-space: nowrap;
}
.log-action-login,
.log-action-register {
background: #d4edda;
color: #155724;
}
.log-action-logout {
background: #f8d7da;
color: #721c24;
}
.log-action-note_create {
background: #d1ecf1;
color: #0c5460;
}
.log-action-note_update {
background: #fff3cd;
color: #856404;
}
.log-action-note_delete,
.log-action-note_delete_permanent {
background: #f8d7da;
color: #721c24;
}
.log-action-note_pin {
background: #e7e7ff;
color: #4a4aff;
}
.log-action-note_archive {
background: #e2e3e5;
color: #383d41;
}
.log-action-note_unarchive {
background: #d4edda;
color: #155724;
}
.log-action-profile_update {
background: #fce4ec;
color: #c2185b;
}
.load-more-container {
text-align: center;
margin: 20px 0;
}
/* Стили для закрепленных заметок */
.note-pinned {
border-left: 4px solid #ffc107;
background: var(--bg-secondary);
}
.pin-indicator {
display: inline-flex;
align-items: center;
gap: 4px;
color: #ffc107;
font-size: 12px;
font-weight: bold;
margin-left: 10px;
}
/* Адаптивность для настроек */
@media (max-width: 768px) {
.settings-tabs {
flex-direction: column;
}
.settings-tab {
width: 100%;
justify-content: center;
}
.archived-note-header {
flex-direction: column;
align-items: flex-start;
}
.archived-note-actions {
width: 100%;
justify-content: flex-start;
}
.logs-table {
font-size: 12px;
}
.logs-table th,
.logs-table td {
padding: 8px;
}
.logs-filters {
flex-direction: column;
}
.log-filter-select {
width: 100%;
}
}
/* Анимация загрузки для AI кнопки */
@keyframes spin {
from {
transform: rotate(0deg);
}
to {
transform: rotate(360deg);
}
}
.log-action-ai_improve {
background: #d1ecf1;
color: #0c5460;
}
/* Стили для скрытого текста (спойлеров) */
.spoiler {
background: linear-gradient(45deg, #f0f0f0, #e8e8e8);
color: transparent;
cursor: pointer;
border-radius: 4px;
padding: 3px 6px;
user-select: none;
transition: all 0.3s ease;
position: relative;
border: 1px solid #ddd;
font-weight: 500;
backdrop-filter: blur(2px);
-webkit-backdrop-filter: blur(2px);
text-shadow: 0 0 8px rgba(0, 0, 0, 0.3);
}
.spoiler::before {
content: "";
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
background: rgba(255, 255, 255, 0.8);
border-radius: 4px;
filter: blur(1px);
z-index: -1;
}
.spoiler:hover {
background: linear-gradient(45deg, #e8e8e8, #d8d8d8);
transform: scale(1.02);
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}
.spoiler:hover::before {
background: rgba(255, 255, 255, 0.9);
}
.spoiler.revealed {
background: linear-gradient(45deg, #e8f5e8, #d4edda);
color: #155724;
border-color: #c3e6cb;
box-shadow: 0 0 0 2px rgba(40, 167, 69, 0.25);
text-shadow: none;
user-select: text;
-webkit-user-select: text;
cursor: text;
}
.spoiler.revealed::before {
display: none;
}
.spoiler.revealed:hover {
background: linear-gradient(45deg, #d4edda, #c3e6cb);
box-shadow: 0 0 0 2px rgba(40, 167, 69, 0.35);
}
/* Стили для файлов */
.file-preview-container {
margin: 15px 0;
padding: 15px;
background: #f0f8ff;
border: 2px dashed #b0d4f1;
border-radius: 8px;
touch-action: manipulation;
-webkit-tap-highlight-color: transparent;
}
.file-preview-header {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 10px;
font-weight: 600;
color: #495057;
}
.file-preview-list {
display: flex;
flex-direction: column;
gap: 10px;
}
.file-preview-item {
display: flex;
align-items: center;
padding: 6px 10px;
background: white;
border-radius: 6px;
border: 1px solid #dee2e6;
gap: 12px;
min-height: 40px;
}
.file-preview-item .file-icon {
font-size: 24px;
color: var(--accent-color, #007bff);
flex-shrink: 0;
}
.file-preview-item .file-info {
flex: 1;
min-width: 0;
}
.file-preview-item .file-info-edit {
flex: 1;
min-width: 0;
}
.file-preview-item .file-name {
font-weight: 500;
color: #333;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
font-size: 14px;
line-height: 1.2;
}
.file-preview-item .file-size {
font-size: 11px;
color: #666;
margin-top: 1px;
line-height: 1.2;
}
.file-info-edit .file-name {
font-weight: 500;
color: #333;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
font-size: 14px;
line-height: 1.2;
}
.file-info-edit .file-size {
font-size: 11px;
color: #666;
margin-top: 1px;
line-height: 1.2;
}
.file-preview-item .remove-file-btn {
background: #dc3545;
color: white;
border: none;
border-radius: 50%;
width: 24px;
height: 24px;
cursor: pointer;
font-size: 14px;
display: flex;
align-items: center;
justify-content: center;
flex-shrink: 0;
transition: background-color 0.2s;
}
.file-preview-item .remove-file-btn:hover {
background: #c82333;
}
.clear-files-btn {
background: #dc3545;
color: white;
border: none;
padding: 4px 8px;
border-radius: 4px;
cursor: pointer;
font-size: 12px;
transition: background-color 0.3s ease;
}
.clear-files-btn:hover {
background: #c82333;
}
/* Темная тема для файлов */
[data-theme="dark"] .file-preview-container {
background: #2a3a4a;
border-color: #4a5a6a;
}
[data-theme="dark"] .file-preview-header {
color: var(--text-primary);
}
[data-theme="dark"] .file-preview-item {
background: var(--bg-secondary);
border-color: var(--border-primary);
}
[data-theme="dark"] .file-preview-item .file-name {
color: var(--text-primary);
font-size: 14px;
line-height: 1.2;
}
[data-theme="dark"] .file-preview-item .file-size {
color: var(--text-secondary);
font-size: 11px;
margin-top: 1px;
line-height: 1.2;
}
[data-theme="dark"] .file-info-edit .file-name {
color: var(--text-primary);
font-size: 14px;
line-height: 1.2;
}
[data-theme="dark"] .file-info-edit .file-size {
color: var(--text-secondary);
font-size: 11px;
margin-top: 1px;
line-height: 1.2;
}
/* Темная тема для файлов в режиме редактирования */
[data-theme="dark"]
.textNote
.file-preview-container
.file-preview-item
.file-name {
color: var(--text-primary);
font-size: 14px;
line-height: 1.2;
}
[data-theme="dark"]
.textNote
.file-preview-container
.file-preview-item
.file-size {
color: var(--text-secondary);
font-size: 11px;
margin-top: 1px;
line-height: 1.2;
}
[data-theme="dark"] .note-file-link {
background: var(--bg-tertiary);
border-color: var(--border-primary);
color: var(--text-primary);
}
[data-theme="dark"] .note-file-link:hover {
background: var(--bg-hover);
border-color: var(--accent-color);
}
[data-theme="dark"] .note-file-link .file-name {
color: var(--text-primary);
}
[data-theme="dark"] .note-file-link .file-size {
color: var(--text-secondary);
}
/* Темная тема для изображений */
[data-theme="dark"] .image-preview-container {
background: #2a3a4a;
border-color: #4a5a6a;
}
[data-theme="dark"] .image-preview-header {
color: var(--text-primary);
}
[data-theme="dark"] .image-preview-item {
background: var(--bg-secondary);
border-color: var(--border-primary);
}
[data-theme="dark"] .image-preview-item .image-info {
background: var(--bg-tertiary);
color: var(--text-secondary);
}
/* Темная тема для кнопок удаления */
[data-theme="dark"] .image-preview-item .image-preview-remove {
background: rgba(220, 53, 69, 0.85);
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
}
[data-theme="dark"] .image-preview-item .image-preview-remove:hover {
background: rgba(220, 53, 69, 1);
box-shadow: 0 3px 6px rgba(0, 0, 0, 0.5);
}
[data-theme="dark"] .file-preview-item .file-preview-remove {
background: rgba(220, 53, 69, 0.85);
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
}
[data-theme="dark"] .file-preview-item .file-preview-remove:hover {
background: rgba(220, 53, 69, 1);
box-shadow: 0 3px 6px rgba(0, 0, 0, 0.5);
}
[data-theme="dark"] .image-preview-item .image-preview-remove.restore-btn,
[data-theme="dark"] .file-preview-item .file-preview-remove.restore-btn {
background: rgba(40, 167, 69, 0.85) !important;
}
[data-theme="dark"] .image-preview-item .image-preview-remove.restore-btn:hover,
[data-theme="dark"] .file-preview-item .file-preview-remove.restore-btn:hover {
background: rgba(40, 167, 69, 1) !important;
}
[data-theme="dark"] .image-preview-item .image-preview-remove[style*="green"],
[data-theme="dark"] .file-preview-item .file-preview-remove[style*="green"] {
background: rgba(40, 167, 69, 0.85) !important;
}
[data-theme="dark"]
.image-preview-item
.image-preview-remove[style*="green"]:hover,
[data-theme="dark"]
.file-preview-item
.file-preview-remove[style*="green"]:hover {
background: rgba(40, 167, 69, 1) !important;
}
[data-theme="dark"] .note-images-container {
background: transparent;
}
[data-theme="dark"] .note-image-item {
border-color: var(--border-primary);
}
[data-theme="dark"] .note-image {
border-color: var(--border-primary);
}
[data-theme="dark"] .note-image:hover::after {
background: rgba(0, 0, 0, 0.7);
}
.btnMarkdown .iconify[data-icon="mdi:menu-down"] {
color: #1976d2;
}
/* ========================================
МОБИЛЬНАЯ ВЕРСИЯ
======================================== */
/* Кнопка открытия мобильного меню */
.mobile-menu-btn {
display: none;
position: fixed;
top: 15px;
left: 15px;
z-index: 999;
background: var(--bg-secondary);
border: 1px solid var(--border-secondary);
border-radius: 8px;
padding: 10px 12px;
cursor: pointer;
box-shadow: 0 2px 8px var(--shadow-light);
transition: all 0.3s ease;
}
.mobile-menu-btn:hover {
background: var(--bg-quaternary);
box-shadow: 0 4px 12px var(--shadow-medium);
}
.mobile-menu-btn .iconify {
font-size: 24px;
color: var(--text-primary);
}
/* Мобильный сайдбар */
.mobile-sidebar {
display: flex;
flex-direction: column;
position: fixed;
top: 0;
left: -85vw;
width: 85vw;
max-width: 320px;
height: 100vh;
background: var(--bg-secondary);
color: var(--text-primary);
box-shadow: 2px 0 10px var(--shadow-light);
transition: left 0.3s ease;
z-index: 1000;
overflow-y: auto;
}
.mobile-sidebar.open {
left: 0;
}
.sidebar-close-btn {
display: flex;
align-items: center;
justify-content: center;
width: 40px;
height: 40px;
padding: 0;
margin: 10px 10px 10px auto;
background: var(--bg-tertiary);
border: 1px solid var(--border-secondary);
border-radius: 8px;
cursor: pointer;
transition: background 0.3s ease;
}
.sidebar-close-btn:hover {
background: var(--bg-quaternary);
}
.sidebar-close-btn .iconify {
font-size: 20px;
color: var(--text-primary);
}
.sidebar-content {
padding: 10px 12px;
overflow-y: auto;
flex: 1;
}
/* Секции в мобильном сайдбаре */
.mobile-calendar-section,
.mobile-search-section,
.mobile-tags-section {
margin-bottom: 20px;
padding-bottom: 15px;
border-bottom: 1px solid var(--border-primary);
}
.mobile-tags-section {
border-bottom: none;
}
/* Заголовки секций */
.search-header,
.tags-header {
margin-bottom: 10px;
}
.search-title,
.tags-title {
font-size: 13px;
font-weight: bold;
color: var(--text-primary);
display: flex;
align-items: center;
gap: 5px;
}
.search-title .iconify,
.tags-title .iconify {
font-size: 16px;
color: var(--accent-color);
}
/* Оверлей */
.mobile-sidebar-overlay {
display: none;
position: fixed;
top: 0;
left: 0;
right: 0;
bottom: 0;
background: rgba(0, 0, 0, 0.5);
z-index: 999;
opacity: 0;
transition: opacity 0.3s ease;
}
.mobile-sidebar-overlay.open {
display: block;
opacity: 1;
}
/* Медиа-запросы для мобильных устройств */
@media (max-width: 768px) {
/* Показываем мобильную кнопку меню */
.mobile-menu-btn {
display: flex;
align-items: center;
justify-content: center;
}
/* Скрываем десктопный сайдбар */
.container-leftside,
.sidebar {
display: none !important;
}
/* Адаптируем body */
body {
flex-direction: column;
gap: 0;
padding: 0 10px;
padding-top: 20px;
}
/* Центральная колонка на всю ширину */
.center {
width: 100% !important;
max-width: 100% !important;
}
/* Контейнеры заметок */
.container {
width: 100%;
max-width: 100%;
margin-top: 60px; /* Отступ для кнопки меню */
}
/* Уменьшаем отступ сверху для первого блока "Мои заметки" на мобильных */
.center > .container:first-child {
margin-top: 3px;
}
/* Убираем margin-top у заметок на мобильных, так как gap уже обеспечивает отступы */
.notes-container .container {
margin-top: 0;
}
/* Заметки */
.notes-container {
padding-bottom: 80px;
margin-top: 16px; /* Отступ сверху для одинакового расстояния между блоком "Мои заметки" и первой заметкой на мобильных */
gap: 16px; /* Отступ между заметками на мобильных */
}
/* Стили для пустого сообщения на мобильных */
.empty-message {
padding: 0 15px;
font-size: 14px;
}
/* Header адаптация */
.notes-header {
gap: 10px;
align-items: flex-start;
}
.notes-header-left {
width: auto;
min-width: 0;
/* flex-direction: column; */
align-items: flex-start;
gap: 8px;
}
/* Фильтры */
.filter-indicator {
font-size: 12px;
display: inline-flex !important;
max-width: min(300px, 100%) !important;
width: fit-content !important;
box-sizing: border-box !important;
}
.filter-indicator-text {
overflow: hidden !important;
text-overflow: ellipsis !important;
white-space: nowrap !important;
}
/* Markdown кнопки */
.markdown-buttons .btnMarkdown {
min-height: 44px;
padding: 8px 10px;
margin: 2px;
font-size: 13px;
}
/* Textarea */
.textInput {
font-size: 14px;
min-height: 100px;
}
/* Изображения */
.image-preview-list,
.note-images-container {
justify-content: center;
}
.image-preview-item img,
.note-image {
width: 80px;
height: 80px;
}
/* Уведомления */
.notification {
left: 10px;
right: 10px;
max-width: none;
}
/* Footer */
.footer {
font-size: 11px;
padding: 8px 0;
}
}
/* Очень маленькие экраны */
.mobile-menu-btn .iconify {
font-size: 20px;
}
.container {
margin-top: 50px;
padding: 12px;
}
.markdown-buttons .btnMarkdown {
padding: 6px 8px;
font-size: 12px;
}
.user-info > * {
font-size: 12px;
}
}
/* Стили для загрузочного оверлея */
.loading-overlay {
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
background-color: rgba(0, 0, 0, 0.5);
backdrop-filter: blur(2px);
display: flex;
justify-content: center;
align-items: center;
z-index: 1000;
}
.loading-content {
background-color: var(--bg-color);
padding: 20px 30px;
border-radius: 8px;
box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
display: flex;
align-items: center;
justify-content: center;
min-width: 80px;
min-height: 80px;
}
/* Анимированный спиннер */
.loading-spinner {
width: 50px;
height: 50px;
border: 4px solid transparent;
border-top: 4px solid var(--accent-color, #007bff);
border-right: 4px solid var(--accent-color, #007bff);
border-bottom: 4px solid transparent;
border-left: 4px solid transparent;
border-radius: 50%;
animation: loading-spin 0.8s linear infinite;
opacity: 0.8;
}
@keyframes loading-spin {
to {
transform: rotate(360deg);
}
}
/* Темная тема для загрузочного оверлея */
[data-theme="dark"] .loading-content {
box-shadow: 0 4px 20px rgba(0, 0, 0, 0.6);
}