.main-content {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 1rem;
}

.page-header {
    text-align: center;
    margin-bottom: 3rem;
}

.page-header h1 {
    font-size: 2.5rem;
    color: #333;
    margin-bottom: 1rem;
}

.page-header p {
    font-size: 1.1rem;
    color: #666;
    max-width: 600px;
    margin: 0 auto;
}

.search-container {
    text-align: center;
    margin-bottom: 2rem;
}

.search-box {
    width: 100%;
    max-width: 400px;
    padding: 0.75rem 1rem;
    border: 2px solid #e9ecef;
    border-radius: 25px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.search-box:focus {
    outline: none;
    border-color: #007bff;
}

.filter-container {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 0.5rem 1rem;
    border: 2px solid #e9ecef;
    background: white;
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    color: #666;
}

.filter-btn:hover {
    background: #f8f9fa;
    border-color: #007bff;
}

.filter-btn.active {
    background: #007bff;
    border-color: #007bff;
    color: white;
}

.filter-btn.math.active {
    background: #ff6b6b;
    border-color: #ff6b6b;
}

.filter-btn.physics.active {
    background: #4ecdc4;
    border-color: #4ecdc4;
}

.filter-btn.geology.active {
    background: #45b7d1;
    border-color: #45b7d1;
}

.filter-btn.literature.active {
    background: #96ceb4;
    border-color: #96ceb4;
}

.filter-btn.chemistry.active {
    background: #e74c3c;
    border-color: #e74c3c;
}

.stats-bar {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 2rem;
    display: flex;
    justify-content: space-around;
    text-align: center;
}

.stat-item {
    flex: 1;
}

.stat-number {
    font-size: 1.5rem;
    font-weight: bold;
    color: #007bff;
}

.stat-label {
    font-size: 0.9rem;
    color: #666;
    margin-top: 0.25rem;
}

.notes-section {
    margin-bottom: 3rem;
}

.section-title {
    font-size: 1.8rem;
    color: #333;
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 3px solid #007bff;
    display: inline-block;
}

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

.note-card {
    background: #fff;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 1.5rem;
    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease;
    position: relative;
}

.note-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
}

.note-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.75rem;
}

.note-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: #333;
    line-height: 1.3;
    flex: 1;
    margin-right: 1rem;
}

.note-status {
    font-size: 1.2rem;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    font-weight: 500;
    white-space: nowrap;
}

.note-status.completed {
    background: #d4edda;
    color: #155724;
}

.note-status.in-progress {
    background: #fff3cd;
    color: #856404;
}

.note-status.planned {
    background: #e2e3e5;
    color: #383d41;
}

.note-source {
    font-size: 0.9rem;
    color: #007bff;
    margin-bottom: 1rem;
    font-weight: 500;
    font-style: italic;
}

.note-preview {
    color: #666;
    font-size: 0.95rem;
    line-height: 1.5;
    margin-bottom: 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.note-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.tag {
    background: #e7f3ff;
    color: #0066cc;
    padding: 0.25rem 0.5rem;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 500;
}

.note-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1rem;
    border-top: 1px solid #eee;
    font-size: 0.85rem;
}

.note-date {
    color: #888;
}

.note-chapters {
    color: #666;
    font-weight: 500;
}

.subject-math {
    border-left: 4px solid #ff6b6b;
}

.subject-physics {
    border-left: 4px solid #4ecdc4;
}

.subject-geology {
    border-left: 4px solid #45b7d1;
}

.subject-literature {
    border-left: 4px solid #96ceb4;
}

.subject-chemistry {
    border-left: 4px solid #e74c3c;
}

.quick-access {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 2rem;
    margin-bottom: 2rem;
}

.quick-access .section-title {
    margin-bottom: 1.5rem;
    border-bottom-color: #28a745;
}

.quick-links {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.quick-link {
    display: flex;
    align-items: center;
    padding: 1rem;
    background: white;
    border-radius: 8px;
    text-decoration: none;
    color: #333;
    font-weight: 500;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.quick-link:hover {
    background: #007bff;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.3);
    text-decoration: none;
}

@media (max-width: 768px) {
    .page-header h1 {
        font-size: 2rem;
    }

    .notes-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .note-card {
        padding: 1rem;
    }

    .note-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .note-title {
        margin-right: 0;
    }

    .note-status {
        align-self: flex-start;
    }

    .stats-bar {
        flex-direction: column;
        gap: 1rem;
    }

    .note-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .search-box {
        max-width: 100%;
    }

    .filter-container {
        justify-content: flex-start;
        overflow-x: auto;
        padding-bottom: 0.5rem;
    }

    .filter-btn {
        flex-shrink: 0;
    }

    .quick-links {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .section-title {
        font-size: 1.5rem;
    }

    .note-title {
        font-size: 1.1rem;
    }

    .note-card {
        padding: 0.75rem;
    }

    .filter-btn {
        padding: 0.4rem 0.8rem;
        font-size: 0.85rem;
    }
}

/* Additional animations and effects */
.note-card {
    opacity: 1;
    transition:
        opacity 0.3s ease,
        transform 0.2s ease,
        box-shadow 0.2s ease;
}

.note-card[style*="display: none"] {
    opacity: 0;
}

.tag {
    transition: all 0.2s ease;
}

.tag:hover {
    background: #0066cc;
    color: white;
    transform: scale(1.05);
}

.note-source:hover {
    color: #0056b3;
    cursor: pointer;
}

/* Loading state placeholder */
.note-card.loading {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* Modal styles */
.modal {
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.4);
    animation: fadeIn 0.3s ease;
}

.modal-content {
    background-color: #fff;
    margin: 2% auto;
    padding: 10px;
    border-radius: 8px;
    width: 95%;
    max-width: 1200px;
    max-height: 90vh;
    overflow: hidden;
    position: relative;
    animation: slideIn 0.3s ease;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

@media (max-width: 768px) {
    .modal-content {
        width: 100%;
        height: 100vh;
        max-height: 100vh;
        margin: 0;
        border-radius: 0;
        animation: slideInMobile 0.3s ease;
    }
}

@media (max-width: 480px) {
    .modal-header {
        flex-direction: column;
        align-items: stretch;
        gap: 1rem;
        padding: 1rem;
    }

    .modal-header h3 {
        text-align: center;
        font-size: 1.1rem !important;
    }

    .modal-header > div {
        justify-content: space-between;
    }

    .download-btn {
        font-size: 0.8rem;
        padding: 0.4rem 0.8rem;
    }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid #e1e4e8;
    background: #fafbfc;
    min-height: 60px;
}

#modal-body {
    padding: 0;
    max-height: calc(90vh - 80px);
    overflow-y: auto;
}

/* Custom scrollbar styling for modal */
#modal-body::-webkit-scrollbar {
    width: 12px;
}

#modal-body::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 6px;
}

#modal-body::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 6px;
    border: 2px solid #f1f1f1;
}

#modal-body::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* Firefox scrollbar */
#modal-body {
    scrollbar-width: thin;
    scrollbar-color: #c1c1c1 #f1f1f1;
}

.close {
    color: #aaa;
    font-size: 2rem;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s ease;
    background: none;
    border: none;
}

.close:hover {
    color: #000;
}

.download-btn {
    background: #28a745;
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: background 0.3s ease;
}

.download-btn:hover {
    background: #218838;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes slideInMobile {
    from {
        transform: translateY(100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Recent notes list */
.recent-notes-list {
    margin-top: 1rem;
}

.recent-note-item {
    padding: 0.75rem;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.recent-note-title {
    font-weight: 500;
    color: #333;
}

.recent-note-date {
    color: #666;
    font-size: 0.9rem;
}

/* Favorites list */
.favorites-list {
    margin-top: 1rem;
}

.favorite-item {
    padding: 0.75rem;
    border-bottom: 1px solid #eee;
    background: #f8f9fa;
    border-radius: 6px;
    margin-bottom: 0.5rem;
}

.favorite-title {
    font-weight: 500;
    color: #333;
}

.favorite-subject {
    color: #666;
    font-size: 0.9rem;
    text-transform: capitalize;
}

/* Templates list */
.templates-list {
    margin-top: 1rem;
}

.template-item {
    margin-bottom: 1.5rem;
    padding: 1rem;
    border: 1px solid #e9ecef;
    border-radius: 8px;
}

.template-item h4 {
    color: #333;
    margin-bottom: 0.5rem;
}

.template-preview {
    background: #f8f9fa;
    padding: 1rem;
    border-radius: 6px;
    font-size: 0.9rem;
}

.template-preview p {
    margin: 0.5rem 0;
    color: #666;
}

/* Quick link button styles */
.quick-link {
    background: none;
    border: none;
    width: 100%;
    text-align: left;
    cursor: pointer;
    font-family: inherit;
}

/* Favorite card indication */
.note-card.favorite {
    border: 3px solid gold !important;
}

/* Dark theme for modal */
[data-theme="dark"] .modal-content {
    background-color: #1e1e1e;
    color: #dcddde;
    border: 1px solid #404040;
}

[data-theme="dark"] .modal-header {
    background: #21262d;
    border-bottom-color: #30363d;
}

[data-theme="dark"] #modal-title {
    color: #ffffff !important;
}

[data-theme="dark"] .close {
    color: #b9bbbe;
}

[data-theme="dark"] .close:hover {
    color: #ffffff;
}

[data-theme="dark"] .recent-note-item,
[data-theme="dark"] .favorite-item,
[data-theme="dark"] .template-item {
    border-bottom-color: #404040;
    background: #1f1f1f;
}

[data-theme="dark"] .recent-note-title,
[data-theme="dark"] .favorite-title,
[data-theme="dark"] .template-item h4 {
    color: #f0f0f0;
}

[data-theme="dark"] .recent-note-date,
[data-theme="dark"] .favorite-subject {
    color: #b0b0b0;
}

[data-theme="dark"] .template-preview {
    background: #404040;
    color: #e0e0e0;
}

[data-theme="dark"] .template-preview p {
    color: #b0b0b0;
}

/* Focus states for accessibility */
.filter-btn:focus,
.search-box:focus,
.quick-link:focus {
    outline: 2px solid #007bff;
    outline-offset: 2px;
}

.note-card:focus-within {
    outline: 2px solid #007bff;
    outline-offset: 2px;
}

/* Favorites help text */
.favorites-help {
    margin-top: 1rem;
    text-align: center;
}

.favorites-help p {
    color: #666;
    font-size: 0.9rem;
    margin: 0;
}

/* Notification animations */
@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOutRight {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

/* Dark theme for favorites help */
[data-theme="dark"] .favorites-help p {
    color: #b0b0b0;
}

/* Note viewer styles */
.note-viewer {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", sans-serif;
}

.note-content-markdown {
    line-height: 1.7;
    color: #24292f;
    font-size: 15px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans", Helvetica, Arial, sans-serif;
    padding: 2rem 3rem;
    max-width: none;
}

@media (max-width: 768px) {
    .note-content-markdown {
        padding: 1.5rem 2rem;
        font-size: 14px;
    }
}

@media (max-width: 480px) {
    .note-content-markdown {
        padding: 1rem 1.5rem;
        font-size: 13px;
    }

    .note-content-markdown h1 {
        font-size: 1.6rem;
    }

    .note-content-markdown h2 {
        font-size: 1.3rem;
    }

    .note-content-markdown h3 {
        font-size: 1.1rem;
    }

    .note-content-markdown pre {
        font-size: 0.8em;
        padding: 0.75rem;
        overflow-x: auto;
    }

    .note-content-markdown table {
        font-size: 0.85em;
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }

    .note-content-markdown mjx-container[jax="CHTML"][display="true"] {
        font-size: 0.9em;
        padding: 0.75em;
        overflow-x: auto;
    }
}

.note-content-markdown h1,
.note-content-markdown h2,
.note-content-markdown h3,
.note-content-markdown h4,
.note-content-markdown h5,
.note-content-markdown h6 {
    color: #1f2328;
    margin-top: 2rem;
    margin-bottom: 1rem;
    font-weight: 600;
    line-height: 1.3;
}

.note-content-markdown h1 {
    font-size: 1.9rem;
    border-bottom: 1px solid #d1d9e0;
    padding-bottom: 0.5rem;
    margin-top: 0;
}

.note-content-markdown h2 {
    font-size: 1.45rem;
    border-bottom: 1px solid #d1d9e0;
    padding-bottom: 0.3rem;
}

.note-content-markdown h3 {
    font-size: 1.25rem;
    color: #1f2328;
}

.note-content-markdown p {
    margin-bottom: 1rem;
    color: #24292f;
}

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

.note-content-markdown li {
    margin-bottom: 0.25rem;
}

.note-content-markdown code {
    background: #f6f8fa;
    color: #24292f;
    padding: 0.2em 0.4em;
    border-radius: 6px;
    font-family:
        ui-monospace, SFMono-Regular, "SF Mono", Monaco, "Cascadia Code", "Roboto Mono", Consolas, "Courier New",
        monospace;
    font-size: 0.85em;
}

.note-content-markdown pre {
    background: #f6f8fa;
    padding: 1rem;
    border-radius: 6px;
    overflow-x: auto;
    border: 1px solid #d1d9e0;
    font-size: 0.85em;
    line-height: 1.45;
}

.note-content-markdown pre code {
    background: transparent;
    padding: 0;
    border-radius: 0;
    color: #24292f;
}

.note-content-markdown blockquote {
    border-left: 0.25em solid #d1d9e0;
    margin: 1rem 0;
    padding: 0 1em;
    color: #656d76;
}

.note-content-markdown strong {
    font-weight: 600;
    color: #1f2328;
}

.note-content-markdown em {
    font-style: italic;
    color: #24292f;
}

.note-content-markdown table {
    border-collapse: collapse;
    margin: 1.5rem 0;
    width: 100%;
    overflow: auto;
    border-spacing: 0;
}

.note-content-markdown table th,
.note-content-markdown table td {
    padding: 8px 13px;
    border: 1px solid #d1d9e0;
    text-align: left;
}

.note-content-markdown table th {
    background: #f6f8fa;
    font-weight: 600;
    color: #1f2328;
}

.note-content-markdown table tbody tr:nth-child(even) {
    background: #f6f8fa;
}

.note-content-markdown table tbody tr:hover {
    background: #f0f3f6;
}

/* Math expressions styling */
.note-content-markdown .MathJax {
    font-size: 1.1em !important;
}

.note-content-markdown mjx-container {
    margin: 0.5em 0;
}

.note-content-markdown mjx-container[display="true"] {
    margin: 1em 0;
}

/* Inline math styling */
.note-content-markdown mjx-container[jax="CHTML"][display="false"] {
    display: inline-block;
    margin: 0 0.1em;
    padding: 0.1em 0.2em;
    background: rgba(175, 184, 193, 0.2);
    border-radius: 3px;
}

/* Block math styling */
.note-content-markdown mjx-container[jax="CHTML"][display="true"] {
    background: #f6f8fa;
    border: 1px solid #d1d9e0;
    border-radius: 6px;
    padding: 1em;
    margin: 1.5em 0;
    text-align: center;
    overflow-x: auto;
}

/* Task list items */
.note-content-markdown .task-list-item {
    list-style-type: none;
    margin-left: -1.5em;
}

.note-content-markdown .task-list-item input {
    margin-right: 0.5em;
}

/* Tags styling */
.note-content-markdown p:last-child {
    border-top: 1px solid #d1d9e0;
    padding-top: 1rem;
    margin-top: 2rem;
    color: #656d76;
    font-size: 0.9em;
}

/* Image styling for embedded images */
.note-content-markdown img,
.note-content-markdown .obsidian-embed-image {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 1.5rem auto;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Handle images with size specifications */
.note-content-markdown img[width],
.note-content-markdown .obsidian-embed-image[width] {
    max-width: 100%;
    width: auto;
}

/* Specific size constraints for common image widths */
.note-content-markdown img,
.note-content-markdown .obsidian-embed-image {
    max-width: min(600px, 100%);
}

/* Center align images */
.note-content-markdown p:has(img),
.note-content-markdown p:has(.obsidian-embed-image) {
    text-align: center;
}

/* For browsers that don't support :has() */
.note-content-markdown p img,
.note-content-markdown p .obsidian-embed-image {
    margin: 1rem auto;
    display: block;
}

.clickable-title {
    transition: color 0.3s ease;
}

.clickable-title:hover {
    color: #007bff;
}

.error-message {
    text-align: center;
    padding: 2rem;
}

.error-message h3 {
    color: #666;
    margin-bottom: 1rem;
}

.error-message p {
    color: #888;
    margin-bottom: 0.5rem;
}

/* Dark theme for note viewer */
[data-theme="dark"] .modal-header {
    background: #1f1f1f;
    border-bottom-color: #404040;
}

[data-theme="dark"] .download-btn {
    background: #28a745;
}

[data-theme="dark"] .download-btn:hover {
    background: #218838;
}

[data-theme="dark"] .note-content-markdown {
    color: #dcddde;
    background: #1e1e1e;
}

[data-theme="dark"] .note-content-markdown h1,
[data-theme="dark"] .note-content-markdown h2,
[data-theme="dark"] .note-content-markdown h3,
[data-theme="dark"] .note-content-markdown h4,
[data-theme="dark"] .note-content-markdown h5,
[data-theme="dark"] .note-content-markdown h6 {
    color: #ffffff;
}

[data-theme="dark"] .note-content-markdown h1 {
    border-bottom-color: #404040;
}

[data-theme="dark"] .note-content-markdown h2 {
    border-bottom-color: #404040;
}

[data-theme="dark"] .note-content-markdown p {
    color: #dcddde;
}

[data-theme="dark"] .note-content-markdown code {
    background: #2a2a2a;
    color: #ff7b72;
    border: 1px solid #404040;
}

[data-theme="dark"] .note-content-markdown pre {
    background: #0d1117;
    border: 1px solid #30363d;
    color: #e6edf3;
}

[data-theme="dark"] .note-content-markdown pre code {
    background: transparent;
    color: #e6edf3;
    border: none;
}

[data-theme="dark"] .note-content-markdown blockquote {
    border-left-color: #30363d;
    color: #8b949e;
    background: transparent;
}

[data-theme="dark"] .note-content-markdown strong {
    color: #ffffff;
}

[data-theme="dark"] .note-content-markdown em {
    color: #dcddde;
}

[data-theme="dark"] .note-content-markdown table {
    color: #dcddde;
}

[data-theme="dark"] .note-content-markdown table th,
[data-theme="dark"] .note-content-markdown table td {
    border-color: #30363d;
}

[data-theme="dark"] .note-content-markdown table th {
    background: #21262d;
    color: #ffffff;
}

[data-theme="dark"] .note-content-markdown table tbody tr:nth-child(even) {
    background: #161b22;
}

[data-theme="dark"] .note-content-markdown table tbody tr:hover {
    background: #21262d;
}

[data-theme="dark"] .note-content-markdown mjx-container[jax="CHTML"][display="false"] {
    background: rgba(110, 118, 129, 0.2);
}

[data-theme="dark"] .note-content-markdown mjx-container[jax="CHTML"][display="true"] {
    background: #0d1117;
    border-color: #30363d;
    color: #e6edf3;
}

[data-theme="dark"] .note-content-markdown p:last-child {
    border-top-color: #30363d;
    color: #8b949e;
}

[data-theme="dark"] .clickable-title:hover {
    color: #4dabf7;
}

[data-theme="dark"] .error-message h3 {
    color: #f0f0f0;
}

[data-theme="dark"] .error-message p {
    color: #b0b0b0;
}

/* Dark theme scrollbar */
[data-theme="dark"] #modal-body::-webkit-scrollbar-track {
    background: #21262d;
}

[data-theme="dark"] #modal-body::-webkit-scrollbar-thumb {
    background: #6e7681;
    border-color: #21262d;
}

[data-theme="dark"] #modal-body::-webkit-scrollbar-thumb:hover {
    background: #8b949e;
}

[data-theme="dark"] #modal-body {
    scrollbar-color: #6e7681 #21262d;
}

/* Loading spinner animation */
@keyframes spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

/* Dark theme for loading indicator */
[data-theme="dark"] .loading-indicator {
    color: #dcddde !important;
}

[data-theme="dark"] .spinner {
    border-color: #30363d !important;
    border-top-color: #4dabf7 !important;
}

/* Dark theme image styling */
[data-theme="dark"] .note-content-markdown img,
[data-theme="dark"] .note-content-markdown .obsidian-embed-image {
    box-shadow: 0 2px 8px rgba(255, 255, 255, 0.1);
}

/* Enhanced favorites help section */
.favorites-help {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 1.5rem;
    margin-top: 1rem;
}

.favorites-help p {
    margin: 0.5rem 0;
    font-size: 0.95rem;
    line-height: 1.5;
}

/* Dark theme for favorites help */
[data-theme="dark"] .favorites-help {
    background: #2d2d2d;
    border-color: #444;
    color: #dcddde;
}

/* Clickable favorite titles in modal */
.clickable-favorite-title {
    cursor: pointer !important;
    text-decoration: underline !important;
    color: #007bff !important;
    transition: color 0.3s ease;
}

.clickable-favorite-title:hover {
    color: #0056b3 !important;
}

[data-theme="dark"] .clickable-favorite-title {
    color: #4dabf7 !important;
}

[data-theme="dark"] .clickable-favorite-title:hover {
    color: #74c0fc !important;
}

/* Dark theme for all modal content elements */
[data-theme="dark"] .modal-content p,
[data-theme="dark"] .modal-content div,
[data-theme="dark"] .modal-content span {
    color: #dcddde;
}

[data-theme="dark"] .modal-content h3,
[data-theme="dark"] .modal-content h4 {
    color: #ffffff !important;
}

[data-theme="dark"] .modal-content .favorite-item,
[data-theme="dark"] .modal-content .recent-note-item,
[data-theme="dark"] .modal-content .template-item {
    background: #2d2d2d !important;
    border-color: #404040 !important;
    color: #dcddde !important;
}

[data-theme="dark"] .modal-content .favorite-title,
[data-theme="dark"] .modal-content .recent-note-title {
    color: #ffffff !important;
}

[data-theme="dark"] .modal-content .favorite-subject,
[data-theme="dark"] .modal-content .recent-note-date {
    color: #8b949e !important;
}

[data-theme="dark"] .modal-content .template-preview {
    background: #404040 !important;
    color: #dcddde !important;
}

[data-theme="dark"] .modal-content .template-preview p {
    color: #dcddde !important;
}

[data-theme="dark"] .modal-content code {
    background: #404040 !important;
    color: #e0e0e0 !important;
}

[data-theme="dark"] .modal-content strong {
    color: #ffffff;
}

[data-theme="dark"] .modal-content ul,
[data-theme="dark"] .modal-content li {
    color: #dcddde;
}

.modal-content {
}

.mod-h3 {
    margin-left: 10px;
}
