08-12-周三_14-20-35

This commit is contained in:
AaronXu
2026-08-12 14:20:36 +08:00
parent 977f7eec96
commit 56dd5b5adf
16 changed files with 1867 additions and 4 deletions
@@ -0,0 +1,761 @@
/* ==================== CSS Variables & Reset ==================== */
:root {
--primary: #6366f1;
--primary-hover: #4f46e5;
--primary-light: #eef2ff;
--primary-soft: #e0e7ff;
--success: #10b981;
--warning: #f59e0b;
--danger: #ef4444;
--danger-hover: #dc2626;
--bg: #f8fafc;
--bg-card: #ffffff;
--bg-hover: #f1f5f9;
--text: #0f172a;
--text-secondary: #64748b;
--text-muted: #94a3b8;
--border: #e2e8f0;
--border-light: #f1f5f9;
--shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
--shadow: 0 1px 3px rgba(0,0,0,0.1), 0 1px 2px rgba(0,0,0,0.06);
--shadow-md: 0 4px 6px rgba(0,0,0,0.07), 0 2px 4px rgba(0,0,0,0.06);
--shadow-lg: 0 10px 15px rgba(0,0,0,0.1), 0 4px 6px rgba(0,0,0,0.05);
--shadow-xl: 0 20px 25px rgba(0,0,0,0.1), 0 10px 10px rgba(0,0,0,0.04);
--radius-sm: 8px;
--radius: 12px;
--radius-lg: 16px;
--radius-xl: 20px;
--transition: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
--transition-slow: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
background: var(--bg);
color: var(--text);
line-height: 1.6;
min-height: 100vh;
-webkit-font-smoothing: antialiased;
}
a { text-decoration: none; color: inherit; }
button { cursor: pointer; font-family: inherit; border: none; outline: none; }
input, textarea, select { font-family: inherit; outline: none; }
/* ==================== Animations ==================== */
@keyframes fadeInUp {
from { opacity: 0; transform: translateY(24px); }
to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
from { opacity: 0; }
to { opacity: 1; }
}
@keyframes fadeInScale {
from { opacity: 0; transform: scale(0.95); }
to { opacity: 1; transform: scale(1); }
}
@keyframes slideInLeft {
from { opacity: 0; transform: translateX(-20px); }
to { opacity: 1; transform: translateX(0); }
}
@keyframes slideInRight {
from { opacity: 0; transform: translateX(20px); }
to { opacity: 1; transform: translateX(0); }
}
@keyframes float {
0%, 100% { transform: translateY(0); }
50% { transform: translateY(-8px); }
}
@keyframes pulse {
0%, 100% { opacity: 1; }
50% { opacity: 0.6; }
}
.anim-fade-up { animation: fadeInUp 0.6s cubic-bezier(0.4,0,0.2,1) both; }
.anim-fade-up-d1 { animation-delay: 0.05s; }
.anim-fade-up-d2 { animation-delay: 0.1s; }
.anim-fade-up-d3 { animation-delay: 0.15s; }
.anim-fade-up-d4 { animation-delay: 0.2s; }
.anim-fade-up-d5 { animation-delay: 0.25s; }
.anim-fade-up-d6 { animation-delay: 0.3s; }
.anim-scale-in { animation: fadeInScale 0.3s cubic-bezier(0.4,0,0.2,1) both; }
/* ==================== Navbar ==================== */
.navbar {
position: sticky; top: 0; z-index: 100;
background: rgba(255,255,255,0.85);
backdrop-filter: blur(20px);
-webkit-backdrop-filter: blur(20px);
border-bottom: 1px solid var(--border);
padding: 0 2rem;
height: 64px;
display: flex;
align-items: center;
justify-content: space-between;
}
.navbar-brand {
font-size: 1.5rem; font-weight: 800;
background: linear-gradient(135deg, var(--primary), #8b5cf6);
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
display: flex; align-items: center; gap: 0.5rem;
}
.logo-icon {
width: 36px; height: 36px;
background: linear-gradient(135deg, var(--primary), #8b5cf6);
border-radius: var(--radius-sm);
display: flex; align-items: center; justify-content: center;
font-size: 1.2rem;
-webkit-text-fill-color: white;
}
.navbar-actions {
display: flex; align-items: center; gap: 0.75rem;
}
/* ==================== Buttons ==================== */
.btn {
padding: 0.5rem 1.25rem; border-radius: var(--radius-sm);
font-size: 0.9rem; font-weight: 600;
transition: all var(--transition);
display: inline-flex; align-items: center; gap: 0.4rem;
}
.btn-primary {
background: linear-gradient(135deg, var(--primary), #8b5cf6);
color: white;
box-shadow: 0 2px 8px rgba(99,102,241,0.3);
}
.btn-primary:hover {
transform: translateY(-1px);
box-shadow: 0 4px 14px rgba(99,102,241,0.4);
}
.btn-outline {
background: transparent; color: var(--primary);
border: 2px solid var(--primary-soft);
}
.btn-outline:hover {
background: var(--primary-light); border-color: var(--primary);
}
.btn-ghost {
background: transparent; color: var(--text-secondary);
}
.btn-ghost:hover { background: var(--bg-hover); color: var(--text); }
.btn-sm { padding: 0.35rem 0.85rem; font-size: 0.8rem; }
.btn-danger { background: var(--danger); color: white; }
.btn-danger:hover { background: var(--danger-hover); transform: translateY(-1px); }
.btn-success { background: var(--success); color: white; }
.btn-success:hover { opacity: 0.9; transform: translateY(-1px); }
.btn-warning { background: var(--warning); color: white; }
/* ==================== User Menu ==================== */
.user-avatar {
width: 36px; height: 36px; border-radius: 50%;
background: linear-gradient(135deg, var(--primary), #8b5cf6);
color: white;
display: flex; align-items: center; justify-content: center;
font-weight: 700; font-size: 0.9rem;
}
.user-menu {
display: flex; align-items: center; gap: 0.5rem;
padding: 0.3rem 0.85rem; border-radius: 100px;
cursor: pointer; transition: var(--transition); position: relative;
}
.user-menu:hover { background: var(--bg-hover); }
.user-dropdown {
position: absolute; top: calc(100% + 8px); right: 0;
background: var(--bg-card); border-radius: var(--radius);
box-shadow: var(--shadow-xl); border: 1px solid var(--border);
min-width: 180px; padding: 0.5rem;
animation: fadeInScale 0.2s ease both;
display: none; z-index: 50;
}
.user-dropdown.show { display: block; }
.user-dropdown a {
display: flex; align-items: center; gap: 0.5rem;
padding: 0.6rem 0.85rem; border-radius: var(--radius-sm);
font-size: 0.9rem; transition: var(--transition);
}
.user-dropdown a:hover { background: var(--primary-light); color: var(--primary); }
.user-dropdown .divider { height: 1px; background: var(--border); margin: 0.25rem 0; }
/* ==================== Layout ==================== */
.container { max-width: 1280px; margin: 0 auto; padding: 2rem; }
.main-content { display: flex; gap: 2rem; }
/* ==================== Sidebar ==================== */
.sidebar {
width: 260px; flex-shrink: 0;
position: sticky; top: 88px; height: fit-content;
animation: slideInLeft 0.5s ease both;
}
.category-panel {
background: var(--bg-card); border-radius: var(--radius-lg);
box-shadow: var(--shadow); border: 1px solid var(--border);
overflow: hidden;
}
.category-panel-header {
padding: 1.25rem 1.25rem 0.75rem;
font-weight: 700; font-size: 1rem;
display: flex; align-items: center; gap: 0.5rem;
}
.category-list {
list-style: none; padding: 0 0.5rem 0.75rem;
}
.category-item { margin: 0.15rem 0; }
.category-item a {
display: flex; align-items: center; justify-content: space-between;
padding: 0.65rem 0.85rem; border-radius: var(--radius-sm);
font-size: 0.9rem; transition: all var(--transition);
color: var(--text-secondary); cursor: pointer;
}
.category-item a:hover,
.category-item a.active {
background: var(--primary-light); color: var(--primary); font-weight: 600;
}
.category-item .count {
background: var(--border-light); padding: 0.15rem 0.55rem;
border-radius: 100px; font-size: 0.75rem; font-weight: 600;
color: var(--text-muted);
}
.category-item a.active .count {
background: var(--primary-soft); color: var(--primary);
}
/* ==================== Content Area ==================== */
.content-area { flex: 1; min-width: 0; }
.content-header {
display: flex; align-items: center; justify-content: space-between;
margin-bottom: 1.5rem;
animation: fadeInUp 0.5s ease both;
}
.content-header h2 { font-size: 1.5rem; font-weight: 700; }
.search-box { position: relative; }
.search-box input {
padding: 0.55rem 1rem 0.55rem 2.5rem;
border: 2px solid var(--border); border-radius: 100px;
font-size: 0.9rem; width: 260px;
transition: all var(--transition); background: var(--bg-card);
}
.search-box input:focus {
border-color: var(--primary); box-shadow: 0 0 0 3px rgba(99,102,241,0.1);
width: 300px;
}
.search-box .search-icon {
position: absolute; left: 0.85rem; top: 50%;
transform: translateY(-50%);
color: var(--text-muted); font-size: 0.9rem;
}
/* ==================== Notes Grid ==================== */
.notes-grid {
display: grid;
grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
gap: 1.25rem;
}
.note-card {
display: block;
background: var(--bg-card); border-radius: var(--radius-lg);
border: 1px solid var(--border); padding: 1.5rem;
transition: all var(--transition-slow);
cursor: pointer; position: relative; overflow: hidden;
animation: fadeInUp 0.5s ease both;
color: inherit;
text-decoration: none;
}
.note-card:hover {
transform: translateY(-4px);
box-shadow: var(--shadow-xl);
border-color: var(--primary-soft);
}
.note-card::before {
content: ''; position: absolute; top: 0; left: 0; right: 0;
height: 3px;
background: linear-gradient(90deg, var(--primary), #8b5cf6, #a78bfa);
transform: scaleX(0); transform-origin: left;
transition: transform var(--transition-slow);
}
.note-card:hover::before { transform: scaleX(1); }
.note-category {
display: inline-flex; align-items: center; gap: 0.3rem;
padding: 0.2rem 0.7rem; border-radius: 100px;
font-size: 0.75rem; font-weight: 600; margin-bottom: 0.75rem;
}
.note-title {
font-size: 1.1rem; font-weight: 700; margin-bottom: 0.5rem;
line-height: 1.4;
display: -webkit-box;
-webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.note-excerpt {
color: var(--text-secondary); font-size: 0.88rem;
line-height: 1.6; margin-bottom: 1rem;
display: -webkit-box;
-webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.note-meta {
display: flex; align-items: center; justify-content: space-between;
font-size: 0.8rem; color: var(--text-muted);
padding-top: 0.75rem; border-top: 1px solid var(--border-light);
}
.note-meta span { display: flex; align-items: center; gap: 0.3rem; }
/* ==================== Note Detail Modal ==================== */
.note-detail-overlay {
position: fixed; inset: 0;
background: rgba(15,23,42,0.5); backdrop-filter: blur(4px);
z-index: 200;
display: flex; align-items: center; justify-content: center;
animation: fadeIn 0.2s ease both;
}
.note-detail {
background: var(--bg-card); border-radius: var(--radius-xl);
width: 90%; max-width: 750px; max-height: 90vh; overflow-y: auto;
box-shadow: var(--shadow-xl);
animation: fadeInScale 0.3s ease both;
}
.note-detail-header {
padding: 1.5rem 2rem; border-bottom: 1px solid var(--border);
display: flex; align-items: center; justify-content: space-between;
position: sticky; top: 0; background: var(--bg-card); z-index: 1;
border-radius: var(--radius-xl) var(--radius-xl) 0 0;
}
.note-detail-header h3 { font-size: 1.3rem; }
.note-detail-close {
width: 36px; height: 36px; border-radius: 50%;
display: flex; align-items: center; justify-content: center;
background: var(--bg-hover); font-size: 1.2rem;
transition: var(--transition); cursor: pointer;
}
.note-detail-close:hover { background: var(--border); }
.note-detail-body { padding: 2rem; }
.note-full-content {
font-size: 1rem; line-height: 1.8; white-space: pre-wrap;
}
.note-detail-info {
display: flex; gap: 1.5rem; margin: 1.25rem 0;
padding: 1rem; background: var(--bg);
border-radius: var(--radius); font-size: 0.85rem;
color: var(--text-secondary);
}
/* ==================== Comments ==================== */
.comments-section { padding: 0 2rem 2rem; }
.comments-section h4 {
font-size: 1.1rem; margin-bottom: 1rem;
display: flex; align-items: center; gap: 0.5rem;
}
.comment-form {
display: flex; gap: 0.75rem; margin-bottom: 1.5rem;
}
.comment-form input {
flex: 1; padding: 0.65rem 1rem;
border: 2px solid var(--border); border-radius: 100px;
font-size: 0.9rem; transition: var(--transition);
}
.comment-form input:focus {
border-color: var(--primary);
box-shadow: 0 0 0 3px rgba(99,102,241,0.1);
}
.comment-form button {
padding: 0.6rem 1.5rem; border-radius: 100px;
background: var(--primary); color: white; font-weight: 600;
transition: var(--transition);
}
.comment-form button:hover { background: var(--primary-hover); }
.comment-list { list-style: none; display: flex; flex-direction: column; gap: 0.75rem; }
.comment-item {
background: var(--bg); padding: 1rem 1.25rem;
border-radius: var(--radius);
animation: fadeInUp 0.4s ease both;
display: flex; gap: 0.75rem;
}
.comment-avatar {
width: 36px; height: 36px; border-radius: 50%;
background: linear-gradient(135deg, #a78bfa, #6366f1);
color: white;
display: flex; align-items: center; justify-content: center;
font-weight: 700; font-size: 0.8rem; flex-shrink: 0;
}
.comment-body { flex: 1; }
.comment-author { font-weight: 600; font-size: 0.9rem; }
.comment-time { font-size: 0.75rem; color: var(--text-muted); margin-left: 0.5rem; }
.comment-text { font-size: 0.88rem; color: var(--text-secondary); margin-top: 0.25rem; }
.comment-actions { display: flex; gap: 0.5rem; margin-top: 0.4rem; }
.comment-actions button {
font-size: 0.75rem; color: var(--text-muted); background: none;
padding: 0.2rem 0.5rem; border-radius: 4px; transition: var(--transition);
}
.comment-actions button:hover { color: var(--danger); background: #fef2f2; }
/* ==================== Modals ==================== */
.modal-overlay {
position: fixed; inset: 0;
background: rgba(15,23,42,0.5); backdrop-filter: blur(4px);
z-index: 300;
display: flex; align-items: center; justify-content: center;
animation: fadeIn 0.2s ease both;
}
.login-modal {
background: var(--bg-card); border-radius: var(--radius-xl);
padding: 2.5rem; width: 90%; max-width: 420px;
box-shadow: var(--shadow-xl);
animation: fadeInScale 0.3s ease both;
}
.login-modal h2 { font-size: 1.5rem; text-align: center; margin-bottom: 0.5rem; }
.login-modal .subtitle {
text-align: center; color: var(--text-secondary);
font-size: 0.9rem; margin-bottom: 2rem;
}
.form-group { margin-bottom: 1.25rem; }
.form-group label {
display: block; font-size: 0.85rem; font-weight: 600;
margin-bottom: 0.4rem; color: var(--text);
}
.form-group input,
.form-group select,
.form-group textarea {
width: 100%; padding: 0.7rem 1rem;
border: 2px solid var(--border); border-radius: var(--radius-sm);
font-size: 0.9rem; transition: all var(--transition);
background: var(--bg);
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
border-color: var(--primary);
box-shadow: 0 0 0 3px rgba(99,102,241,0.1);
}
.form-group textarea { resize: vertical; min-height: 100px; }
.login-modal .btn-primary { width: 100%; justify-content: center; padding: 0.75rem; }
.login-hint {
text-align: center; margin-top: 1rem;
font-size: 0.8rem; color: var(--text-muted);
}
.form-modal {
background: var(--bg-card); border-radius: var(--radius-xl);
padding: 2rem; width: 90%; max-width: 520px;
box-shadow: var(--shadow-xl);
animation: fadeInScale 0.3s ease both;
max-height: 85vh; overflow-y: auto;
}
.form-modal h3 { margin-bottom: 1.5rem; font-size: 1.2rem; }
.form-actions { display: flex; gap: 0.75rem; justify-content: flex-end; margin-top: 1.5rem; }
/* ==================== Admin ==================== */
.admin-layout { display: flex; min-height: calc(100vh - 64px); }
.admin-sidebar {
width: 240px; background: var(--bg-card);
border-right: 1px solid var(--border);
padding: 1.5rem 0;
display: flex; flex-direction: column;
animation: slideInLeft 0.4s ease both;
}
.admin-nav-item {
display: flex; align-items: center; gap: 0.75rem;
padding: 0.75rem 1.5rem; font-size: 0.9rem; font-weight: 500;
color: var(--text-secondary); transition: var(--transition);
border-left: 3px solid transparent; cursor: pointer;
}
.admin-nav-item:hover { background: var(--bg-hover); color: var(--text); }
.admin-nav-item.active {
color: var(--primary); background: var(--primary-light);
border-left-color: var(--primary); font-weight: 600;
}
.admin-main {
flex: 1; padding: 2rem; overflow-y: auto;
animation: fadeInUp 0.5s ease both;
}
.admin-panel {
background: var(--bg-card); border-radius: var(--radius-lg);
box-shadow: var(--shadow); border: 1px solid var(--border);
overflow: hidden;
}
.admin-panel-header {
padding: 1.25rem 1.5rem; border-bottom: 1px solid var(--border);
display: flex; align-items: center; justify-content: space-between;
}
.admin-panel-header h3 { font-size: 1.1rem; }
.admin-panel-body { padding: 1.5rem; }
.admin-table { width: 100%; border-collapse: collapse; }
.admin-table th {
text-align: left; padding: 0.75rem 1rem;
font-size: 0.8rem; font-weight: 700; color: var(--text-muted);
text-transform: uppercase; letter-spacing: 0.05em;
background: var(--bg); border-bottom: 2px solid var(--border);
}
.admin-table td {
padding: 0.85rem 1rem; font-size: 0.9rem;
border-bottom: 1px solid var(--border-light);
}
.admin-table tbody tr { transition: var(--transition); }
.admin-table tbody tr:hover { background: var(--bg-hover); }
.admin-table .actions { display: flex; gap: 0.4rem; }
.badge {
display: inline-flex; padding: 0.2rem 0.6rem;
border-radius: 100px; font-size: 0.75rem; font-weight: 600;
}
.badge-admin { background: #fef3c7; color: #d97706; }
.badge-user { background: #e0e7ff; color: #4f46e5; }
.badge-category { background: #d1fae5; color: #059669; }
/* ==================== Admin Tabs ==================== */
.admin-header {
text-align: center; padding: 2rem 0 1.5rem;
animation: fadeInUp 0.5s ease both;
}
.admin-header h1 { font-size: 1.8rem; font-weight: 800; }
.admin-tabs {
display: flex; gap: 0.5rem; margin-bottom: 2rem;
background: var(--bg-card); padding: 0.4rem;
border-radius: var(--radius); border: 1px solid var(--border);
animation: fadeInUp 0.5s 0.05s ease both;
}
.admin-tab {
flex: 1; padding: 0.7rem 1rem; border-radius: var(--radius-sm);
font-size: 0.88rem; font-weight: 600; color: var(--text-secondary);
background: transparent; transition: all var(--transition);
cursor: pointer; border: none; text-align: center;
}
.admin-tab:hover { color: var(--text); background: var(--bg-hover); }
.admin-tab.active {
color: white;
background: linear-gradient(135deg, var(--primary), #8b5cf6);
box-shadow: var(--shadow-sm);
}
/* ==================== Admin Section ==================== */
.section-header {
display: flex; align-items: center; justify-content: space-between;
margin-bottom: 1.25rem;
}
.section-header h2 { font-size: 1.2rem; font-weight: 700; }
.data-table {
background: var(--bg-card); border-radius: var(--radius-lg);
box-shadow: var(--shadow); border: 1px solid var(--border);
overflow: hidden;
animation: fadeInUp 0.4s ease both;
}
.data-table table { width: 100%; border-collapse: collapse; }
.data-table thead { background: var(--bg); }
.data-table th {
text-align: left; padding: 0.75rem 1rem;
font-size: 0.8rem; font-weight: 700; color: var(--text-muted);
text-transform: uppercase; letter-spacing: 0.05em;
border-bottom: 2px solid var(--border);
}
.data-table td {
padding: 0.85rem 1rem; font-size: 0.9rem;
border-bottom: 1px solid var(--border-light);
color: var(--text);
}
.data-table tbody tr { transition: var(--transition); }
.data-table tbody tr:hover { background: var(--bg-hover); }
.data-table tbody tr:last-child td { border-bottom: none; }
.data-table .btn { white-space: nowrap; }
.color-dot {
display: inline-block; width: 14px; height: 14px;
border-radius: 50%; vertical-align: middle; margin-right: 4px;
border: 2px solid rgba(0,0,0,0.05);
}
/* ==================== Back Link ==================== */
.back-link {
display: inline-flex; align-items: center; gap: 0.3rem;
color: var(--primary); font-weight: 600; font-size: 0.9rem;
margin-bottom: 1.5rem; transition: var(--transition);
}
.back-link:hover { color: var(--primary-hover); transform: translateX(-3px); }
/* ==================== Note Detail Page ==================== */
.note-detail-header {
background: var(--bg-card); border-radius: var(--radius-lg);
padding: 2rem; border: 1px solid var(--border);
animation: fadeInUp 0.5s ease both;
}
.note-detail-header h1 { font-size: 1.6rem; font-weight: 800; margin-bottom: 1rem; }
.note-detail-meta {
display: flex; flex-wrap: wrap; gap: 1rem; align-items: center;
font-size: 0.85rem; color: var(--text-secondary);
}
.note-detail-meta span {
display: flex; align-items: center; gap: 0.3rem;
}
.note-detail-body {
background: var(--bg-card); border-radius: var(--radius-lg);
padding: 2rem; margin-top: 1rem;
border: 1px solid var(--border);
animation: fadeInUp 0.5s 0.1s ease both;
}
.note-detail-body p {
font-size: 1rem; line-height: 1.9; white-space: pre-wrap;
color: var(--text);
}
/* ==================== Comment Section (Page) ==================== */
.comment-section {
margin-top: 1.5rem;
background: var(--bg-card); border-radius: var(--radius-lg);
padding: 2rem; border: 1px solid var(--border);
animation: fadeInUp 0.5s 0.15s ease both;
}
.comment-section h3 {
font-size: 1.1rem; margin-bottom: 1rem;
display: flex; align-items: center; gap: 0.5rem;
}
.comment-section .comment-item {
background: var(--bg); margin-bottom: 0.75rem;
}
.comment-section .comment-item:last-child { margin-bottom: 0; }
.comment-meta { margin-bottom: 0.2rem; }
.comment-meta strong { font-size: 0.9rem; margin-right: 0.5rem; }
.comment-meta span { font-size: 0.75rem; color: var(--text-muted); }
.comment-form-wrapper {
margin-top: 1.5rem; padding-top: 1.5rem;
border-top: 1px solid var(--border);
}
.comment-form-wrapper h4 {
font-size: 1rem; margin-bottom: 0.75rem;
display: flex; align-items: center; gap: 0.4rem;
}
.comment-form-wrapper .comment-form {
display: flex; flex-direction: column; gap: 0.75rem;
}
.comment-form-wrapper .form-group { margin-bottom: 0; }
.comment-form-wrapper .form-group input,
.comment-form-wrapper .form-group textarea {
width: 100%; padding: 0.7rem 1rem;
border: 2px solid var(--border); border-radius: var(--radius-sm);
font-size: 0.9rem; transition: all var(--transition);
background: var(--bg);
}
.comment-form-wrapper .form-group input:focus,
.comment-form-wrapper .form-group textarea:focus {
border-color: var(--primary);
box-shadow: 0 0 0 3px rgba(99,102,241,0.1);
}
.comment-form-wrapper .btn-primary { align-self: flex-start; }
/* ==================== Toast ==================== */
.toast-container {
position: fixed; top: 1.5rem; right: 1.5rem; z-index: 9999;
display: flex; flex-direction: column; gap: 0.5rem;
}
.toast {
padding: 0.85rem 1.25rem; background: var(--bg-card);
border-radius: var(--radius); box-shadow: var(--shadow-lg);
font-size: 0.9rem; font-weight: 500;
animation: slideInRight 0.3s ease both;
display: flex; align-items: center; gap: 0.5rem;
border-left: 4px solid;
}
.toast-success { border-left-color: var(--success); }
.toast-error { border-left-color: var(--danger); }
.toast-info { border-left-color: var(--primary); }
/* ==================== Empty State ==================== */
.empty-state {
text-align: center; padding: 3rem 2rem; color: var(--text-muted);
}
.empty-state .empty-icon { font-size: 3.5rem; margin-bottom: 1rem; animation: float 3s ease-in-out infinite; }
.empty-state p { font-size: 0.95rem; }
/* ==================== Hero Section ==================== */
.hero {
text-align: center; padding: 3rem 2rem;
background: linear-gradient(135deg, #eef2ff 0%, #faf5ff 50%, #f0f9ff 100%);
border-radius: var(--radius-xl); margin-bottom: 2rem;
animation: fadeInUp 0.6s ease both;
}
.hero h1 {
font-size: 2.2rem; font-weight: 800;
background: linear-gradient(135deg, var(--primary), #8b5cf6);
-webkit-background-clip: text; -webkit-text-fill-color: transparent;
margin-bottom: 0.75rem;
}
.hero p { color: var(--text-secondary); font-size: 1.05rem; max-width: 500px; margin: 0 auto; }
/* ==================== Responsive ==================== */
@media (max-width: 768px) {
.main-content { flex-direction: column; }
.sidebar { width: 100%; position: static; }
.category-list { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.category-item a { padding: 0.4rem 0.7rem; font-size: 0.8rem; }
.notes-grid { grid-template-columns: 1fr; }
.admin-layout { flex-direction: column; }
.admin-sidebar {
width: 100%; flex-direction: row; overflow-x: auto;
padding: 0.75rem; border-right: none; border-bottom: 1px solid var(--border);
}
.admin-nav-item {
border-left: none; border-bottom: 2px solid transparent;
white-space: nowrap; padding: 0.5rem 1rem;
}
.admin-nav-item.active { border-left-color: transparent; border-bottom-color: var(--primary); }
.admin-main { padding: 1rem; }
.navbar { padding: 0 1rem; }
.container { padding: 1rem; }
.hero { padding: 2rem 1rem; }
.hero h1 { font-size: 1.6rem; }
.search-box input { width: 180px; }
.search-box input:focus { width: 220px; }
}
/* Scrollbar */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 100px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }