.back-link {
    display: inline-block;
    margin-bottom: 1rem;
    color: var(--primary-color, #667eea);
    text-decoration: none;
    font-weight: 500;
    transition: transform 0.2s ease;
}

.back-link:hover {
    transform: translateX(-5px);
}

.search-box {
    margin-bottom: 2rem;
}

.search-input {
    width: 100%;
    padding: 1rem 1.5rem;
    font-size: 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    outline: none;
    transition: all 0.3s ease;
    background: white;
}

.search-input:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.notes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.note-card {
    background: white;
    border-radius: 16px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    text-decoration: none;
    color: inherit;
    display: block;
    border: 2px solid transparent;
}

.note-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.15);
    border-color: #667eea;
}

.note-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    display: block;
}

.note-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #2d3748;
}

.note-description {
    font-size: 0.875rem;
    color: #718096;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.note-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.75rem;
    color: #a0aec0;
}

.note-date {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.note-tags {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-top: 0.75rem;
}

.note-tag {
    padding: 0.25rem 0.75rem;
    background: #edf2f7;
    border-radius: 12px;
    font-size: 0.75rem;
    color: #4a5568;
    font-weight: 500;
}

.empty-state {
    text-align: center;
    padding: 4rem 2rem;
    color: #a0aec0;
    font-size: 1.125rem;
}

/* 笔记查看页面样式 */
.note-viewer {
    max-width: 800px;
    margin: 0 auto;
}

.note-content {
    background: white;
    border-radius: 16px;
    padding: 2.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    line-height: 1.8;
}

.note-content h1 {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: #2d3748;
    border-bottom: 3px solid #667eea;
    padding-bottom: 0.5rem;
}

.note-content h2 {
    font-size: 1.5rem;
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: #2d3748;
}

.note-content h3 {
    font-size: 1.25rem;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
    color: #4a5568;
}

.note-content p {
    margin-bottom: 1rem;
    color: #4a5568;
}

.note-content code {
    background: #f7fafc;
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
    color: #e53e3e;
}

.note-content pre {
    background: #2d3748;
    color: #f7fafc;
    padding: 1.5rem;
    border-radius: 8px;
    overflow-x: auto;
    margin-bottom: 1rem;
}

.note-content pre code {
    background: none;
    padding: 0;
    color: #f7fafc;
}

.note-content ul, .note-content ol {
    margin-bottom: 1rem;
    padding-left: 2rem;
}

.note-content li {
    margin-bottom: 0.5rem;
    color: #4a5568;
}

.note-content blockquote {
    border-left: 4px solid #667eea;
    padding-left: 1rem;
    margin: 1rem 0;
    color: #718096;
    font-style: italic;
}

.note-content a {
    color: #667eea;
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s;
}

.note-content a:hover {
    border-bottom-color: #667eea;
}

.note-content hr {
    border: none;
    border-top: 2px solid #e2e8f0;
    margin: 2rem 0;
}

.note-content table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1rem;
}

.note-content th,
.note-content td {
    padding: 0.75rem;
    border: 1px solid #e2e8f0;
    text-align: left;
}

.note-content th {
    background: #f7fafc;
    font-weight: 600;
    color: #2d3748;
}

.loading {
    text-align: center;
    padding: 3rem;
    color: #a0aec0;
}
