.callout {
    margin: 16px 0;
    padding: 16px 20px;
    border-left: 4px solid #3b82f6;
    background: #f0f9ff;
    border-radius: 4px;
}

.callout p:first-child {
    margin-top: 0;
}

.callout p:last-child {
    margin-bottom: 0;
}

.video-wrapper {
    position: relative;
    padding-bottom: 56.25%; 
    height: 0;
    overflow: hidden;
    margin: 16px 0;
}

.video-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

figure {
    margin: 16px 0;
    text-align: center;
}

figure img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
}

figcaption {
    margin-top: 8px;
    font-size: 0.875rem;
    color: #6b7280;
    font-style: italic;
}

pre {
    background: #1e293b;
    color: #e2e8f0;
    padding: 16px;
    border-radius: 8px;
    overflow-x: auto;
    margin: 16px 0;
}

pre code {
    background: transparent;
    padding: 0;
    border-radius: 0;
    color: inherit;
}

code {
    background: #f1f5f9;
    color: #1f2937;
    padding: 2px 6px;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 0.875em;
}

/* Plain text code blocks */
code.language-plaintext,
code.language-plain,
pre.language-plaintext,
pre.language-plain {
    color: #1f2937 !important;
    background: #f8fafc !important;
}

blockquote {
    margin: 16px 0;
    padding: 12px 20px;
    border-left: 4px solid #d1d5db;
    background: #f9fafb;
    font-style: italic;
    color: #4b5563;
}

ul, ol {
    margin: 12px 0;
    padding-left: 24px;
}

li {
    margin: 6px 0;
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
    margin-top: 24px;
    margin-bottom: 12px;
    font-weight: 600;
}

h4 {
    font-size: 1.125rem;
    color: #1f2937;
}

html body .notion-toggle *,
html body .notion-toggle *::before,
html body .notion-toggle *::after {
    box-sizing: border-box !important;
}

html body .notion-toggle,
html body article .notion-toggle,
html body .entry-content .notion-toggle,
html body .post-content .notion-toggle,
html body main .notion-toggle,
.notion-toggle,
article .notion-toggle,
.entry-content .notion-toggle,
.post-content .notion-toggle,
main .notion-toggle {
    margin: 16px 0 !important;
    border: 1px solid #e5e7eb !important;
    border-radius: 8px !important;
    background: transparent !important;
    overflow: hidden !important;
    color: inherit !important;
    display: block !important;
    width: 100% !important;
    box-sizing: border-box !important;
    float: none !important;
    position: relative !important;
    clear: both !important;
}

html body .notion-toggle-header,
html body article .notion-toggle-header,
html body .entry-content .notion-toggle-header,
html body .post-content .notion-toggle-header,
html body main .notion-toggle-header,
html body .notion-toggle > .notion-toggle-header,
.notion-toggle-header,
article .notion-toggle-header,
.entry-content .notion-toggle-header,
.post-content .notion-toggle-header,
main .notion-toggle-header,
.notion-toggle > .notion-toggle-header {
    display: flex !important;
    align-items: center !important;
    padding: 18px 24px !important;
    cursor: pointer !important;
    user-select: none !important;
    background: transparent !important;
    border-bottom: none !important;
    transition: all 0.2s ease !important;
    position: relative !important;
    color: inherit !important;
    min-height: 60px !important;
    box-sizing: border-box !important;
    flex-direction: row !important;
    justify-content: flex-start !important;
    flex-wrap: nowrap !important;
    gap: 0 !important;
    text-align: left !important;
    width: 100% !important;
}

.notion-toggle-header:hover {
    background: transparent !important;
    opacity: 0.8;
}

.notion-toggle-header:focus {
    outline: 2px solid #3b82f6;
    outline-offset: -2px;
}

html body .notion-toggle-arrow,
html body article .notion-toggle-arrow,
html body .entry-content .notion-toggle-arrow,
html body .post-content .notion-toggle-arrow,
html body main .notion-toggle-arrow,
html body .notion-toggle-header > .notion-toggle-arrow,
.notion-toggle-arrow,
article .notion-toggle-arrow,
.entry-content .notion-toggle-arrow,
.post-content .notion-toggle-arrow,
main .notion-toggle-arrow,
.notion-toggle-header > .notion-toggle-arrow {
    margin-right: 12px !important;
    margin-left: 0 !important;
    margin-top: 0 !important;
    margin-bottom: 0 !important;
    padding: 0 !important;
    transition: transform 0.3s ease !important;
    color: #0066cc !important;
    opacity: 0.8 !important;
    width: 24px !important;
    height: 24px !important;
    min-width: 24px !important;
    min-height: 24px !important;
    max-width: 24px !important;
    max-height: 24px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex-shrink: 0 !important;
    border-radius: 50% !important;
    align-self: center !important;
    vertical-align: middle !important;
    order: 0 !important;
    flex-grow: 0 !important;
    float: none !important;
    position: relative !important;
    line-height: 24px !important;
    text-align: center !important;
}

html body .notion-toggle-arrow::before,
html body article .notion-toggle-arrow::before,
html body .entry-content .notion-toggle-arrow::before,
html body .post-content .notion-toggle-arrow::before,
html body main .notion-toggle-arrow::before,
.notion-toggle-arrow::before {
    content: "▼" !important;
    font-size: 14px !important;
    font-weight: bold !important;
    transform: rotate(-90deg) !important;
    transition: transform 0.3s ease !important;
    display: inline-block !important;
    line-height: 1 !important;
    vertical-align: middle !important;
    margin: 0 !important;
    padding: 0 !important;
    width: auto !important;
    height: auto !important;
    position: relative !important;
    float: none !important;
}

html body .notion-toggle-open .notion-toggle-arrow::before,
html body article .notion-toggle-open .notion-toggle-arrow::before,
html body .entry-content .notion-toggle-open .notion-toggle-arrow::before,
html body .post-content .notion-toggle-open .notion-toggle-arrow::before,
html body main .notion-toggle-open .notion-toggle-arrow::before,
.notion-toggle-open .notion-toggle-arrow::before {
    transform: rotate(0deg) !important;
}

html body .notion-toggle-title,
html body article .notion-toggle-title,
html body .entry-content .notion-toggle-title,
html body .post-content .notion-toggle-title,
html body main .notion-toggle-title,
html body .notion-toggle-header > .notion-toggle-title,
.notion-toggle-title,
article .notion-toggle-title,
.entry-content .notion-toggle-title,
.post-content .notion-toggle-title,
main .notion-toggle-title,
.notion-toggle-header > .notion-toggle-title {
    font-weight: 600 !important;
    color: #1a202c !important;
    flex: 1 !important;
    line-height: 1.5 !important;
    font-size: 18px !important;
    padding: 0 !important;
    margin: 0 !important;
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    flex-direction: row !important;
    justify-content: flex-start !important;
    flex-wrap: nowrap !important;
    order: 1 !important;
    flex-grow: 1 !important;
    flex-shrink: 1 !important;
    min-width: 0 !important;
    float: none !important;
    position: relative !important;
    text-align: left !important;
}

html body .notion-toggle-title strong,
html body article .notion-toggle-title strong,
html body .entry-content .notion-toggle-title strong,
html body .post-content .notion-toggle-title strong,
html body main .notion-toggle-title strong,
html body .notion-toggle .notion-toggle-title strong,
html body div.notion-toggle-title strong,
html body [class*="notion-toggle-title"] strong,
.notion-toggle-title strong,
article .notion-toggle-title strong,
.entry-content .notion-toggle-title strong,
.post-content .notion-toggle-title strong,
main .notion-toggle-title strong,
.notion-toggle .notion-toggle-title strong,
div.notion-toggle-title strong,
[class*="notion-toggle-title"] strong {
    font-weight: 700 !important;
    color: #2d3748 !important;
    display: inline !important;
    margin: 0 !important;
    padding: 0 !important;
    line-height: 1.5 !important;
    vertical-align: middle !important;
    float: none !important;
    position: relative !important;
    flex-shrink: 0 !important;
    box-sizing: border-box !important;
    white-space: normal !important;
}

html body .notion-toggle-title .notion-toggle-icon,
html body article .notion-toggle-title .notion-toggle-icon,
html body .entry-content .notion-toggle-title .notion-toggle-icon,
html body .post-content .notion-toggle-title .notion-toggle-icon,
html body main .notion-toggle-title .notion-toggle-icon,
html body .notion-toggle .notion-toggle-title .notion-toggle-icon,
html body div.notion-toggle-title .notion-toggle-icon,
html body [class*="notion-toggle-title"] .notion-toggle-icon,
.notion-toggle-title .notion-toggle-icon,
article .notion-toggle-title .notion-toggle-icon,
.entry-content .notion-toggle-title .notion-toggle-icon,
.post-content .notion-toggle-title .notion-toggle-icon,
main .notion-toggle-title .notion-toggle-icon,
.notion-toggle .notion-toggle-title .notion-toggle-icon,
div.notion-toggle-title .notion-toggle-icon,
[class*="notion-toggle-title"] .notion-toggle-icon {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 20px !important;
    line-height: 1 !important;
    flex-shrink: 0 !important;
    align-self: center !important;
    vertical-align: middle !important;
    margin: 0 !important;
    padding: 0 !important;
    width: auto !important;
    height: auto !important;
    float: none !important;
    position: relative !important;
    flex-grow: 0 !important;
    flex-basis: auto !important;
    box-sizing: border-box !important;
    text-align: center !important;
    white-space: nowrap !important;
}

.notion-toggle-content {
    display: none;
    padding: 0;
    max-height: 0;
    background: transparent;
    border-top: none;
    color: inherit;
    width: 100%;
    box-sizing: border-box;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    transition: max-height 0.4s ease-in-out, opacity 0.3s ease, padding 0.3s ease;
}

.notion-toggle-open .notion-toggle-content {
    display: block;
    padding: 20px;
    max-height: none;
    height: auto;
    opacity: 1;
    visibility: visible;
    overflow: visible;
}

.notion-toggle-content.opening {
    transition: max-height 0.6s cubic-bezier(0.4, 0, 0.2, 1), 
                opacity 0.3s ease, 
                padding 0.3s ease;
}

.notion-toggle-content.closing {
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), 
                opacity 0.3s ease, 
                padding 0.3s ease;
}

.notion-toggle-content img,
.notion-toggle-content video,
.notion-toggle-content iframe {
    max-width: 100%;
    height: auto;
}

.notion-toggle-content {
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.notion-toggle-content * {
    box-sizing: border-box;
}

.notion-toggle .notion-toggle {
    margin: 12px 0;
    border-color: #e5e7eb;
}

.notion-toggle .notion-toggle .notion-toggle-header {
    background: transparent;
    padding: 12px 16px;
}

.notion-toggle .notion-toggle .notion-toggle-header:hover {
    background: transparent;
    opacity: 0.8;
}

.notion-toggle .notion-toggle .notion-toggle-content {
    padding: 16px;
    background: transparent;
}

.nested-toggle-content {
    margin: 16px 0;
    padding: 12px 16px;
    background: #ffffff;
    border-left: 3px solid #e5e7eb;
    border-radius: 6px;
}

.nested-toggle-title {
    font-size: 16px;
    font-weight: 600;
    color: #2d3748;
    margin: 0 0 12px 0;
    padding: 0;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 8px;
}

.notion-image {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 15px 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.notion-image:hover {
    transform: scale(1.02);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.notion-toggle pre {
    background: #f8fafc;
    color: #1f2937;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 20px;
    margin: 20px 0;
    overflow-x: auto;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 14px;
    line-height: 1.6;
}

.notion-toggle code {
    background: #f1f5f9;
    color: #1f2937;
    padding: 2px 6px;
    border-radius: 4px;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.9em;
    color: #e11d48;
}

.notion-toggle pre code {
    background: none;
    padding: 0;
    color: #1f2937;
}

.notion-toggle blockquote {
    border-left: 4px solid #3b82f6;
    margin: 20px 0;
    padding: 16px 24px;
    background: #f8fafc;
    border-radius: 0 8px 8px 0;
    font-style: italic;
    color: inherit;
    opacity: 0.8;
    line-height: 1.7;
}

.notion-toggle ul,
.notion-toggle ol {
    margin: 16px 0;
    padding-left: 28px;
}

.notion-toggle li {
    margin: 8px 0;
    line-height: 1.7;
}

.notion-toggle ul:first-child,
.notion-toggle ol:first-child {
    margin-top: 0;
}

.notion-toggle ul:last-child,
.notion-toggle ol:last-child {
    margin-bottom: 0;
}

.notion-toggle h1,
.notion-toggle h2,
.notion-toggle h3,
.notion-toggle h4,
.notion-toggle h5,
.notion-toggle h6 {
    margin: 24px 0 16px 0;
    color: inherit;
    line-height: 1.4;
}

.notion-toggle h1:first-child,
.notion-toggle h2:first-child,
.notion-toggle h3:first-child,
.notion-toggle h4:first-child,
.notion-toggle h5:first-child,
.notion-toggle h6:first-child {
    margin-top: 0;
}

.notion-toggle h1 { font-size: 1.8em; font-weight: 700; }
.notion-toggle h2 { font-size: 1.5em; font-weight: 600; }
.notion-toggle h3 { font-size: 1.3em; font-weight: 600; }
.notion-toggle h4 { font-size: 1.1em; font-weight: 500; }
.notion-toggle h5 { font-size: 1em; font-weight: 500; }
.notion-toggle h6 { font-size: 0.9em; font-weight: 500; }

.notion-toggle p {
    margin: 16px 0;
    line-height: 1.7;
    color: inherit;
}

.notion-toggle p:first-child {
    margin-top: 0;
}

.notion-toggle p:last-child {
    margin-bottom: 0;
}

.notion-toggle a {
    color: #3b82f6;
    text-decoration: underline;
    transition: color 0.2s ease;
}

.notion-toggle a:hover {
    color: #1d4ed8;
}

.notion-toggle hr {
    border: none;
    border-top: 2px solid #e5e7eb;
    margin: 32px 0;
    border-radius: 1px;
}

.notion-toggle-controls {
    margin: 20px 0;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.notion-toggle-btn {
    padding: 8px 16px;
    background: #3b82f6;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.2s ease;
}

.notion-toggle-btn:hover {
    background: #2563eb;
}

.notion-toggle-btn:focus {
    outline: 2px solid #3b82f6;
    outline-offset: 2px;
}

.notion-toggle-search {
    padding: 8px 12px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 14px;
    min-width: 200px;
}

.notion-toggle-search:focus {
    outline: 2px solid #3b82f6;
    outline-offset: 2px;
    border-color: #3b82f6;
}

@media (max-width: 768px) {
    .notion-toggle {
        margin: 12px 0;
    }
    
    .notion-toggle-header {
        padding: 14px 16px;
        min-height: 52px;
    }
    
    .notion-toggle-arrow {
        width: 20px;
        height: 20px;
        min-width: 20px;
        min-height: 20px;
        margin-right: 10px;
    }
    
    .notion-toggle-arrow::before {
        font-size: 12px;
    }
    
    .notion-toggle-title {
        font-size: 16px;
        gap: 6px;
    }
    
    .notion-toggle-title .notion-toggle-icon {
        font-size: 18px;
    }
    
    .notion-toggle-content {
        padding: 16px;
    }
    
    .notion-toggle .notion-toggle .notion-toggle-content {
        padding: 12px;
    }
    
    .notion-toggle p {
        margin: 14px 0;
        line-height: 1.8;
    }
    
    .notion-toggle ul,
    .notion-toggle ol {
        margin: 14px 0;
        padding-left: 24px;
    }
    
    .notion-toggle pre {
        padding: 16px;
        margin: 16px 0;
        font-size: 13px;
    }
    
    .notion-toggle blockquote {
        margin: 16px 0;
        padding: 14px 20px;
    }
    
    .notion-toggle-controls {
        flex-direction: column;
    }
    
    .notion-toggle-search {
        min-width: 100%;
    }
    
    
    .notion-video {
        margin: 16px 0;
    }
    
    .notion-video iframe {
        min-height: 200px;
    }
    
    .notion-toggle-content .notion-video iframe {
        min-height: 180px;
    }
}

/* Dark mode styles removed - toggle inherits colors from theme */

.notion-video {
    position: relative;
    width: 100%;
    max-width: 100%;
    margin: 20px 0;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    background: #000;
}

.notion-video iframe {
    width: 100%;
    aspect-ratio: 16/9;
    min-height: 400px;
    border: none;
    display: block;
}

.notion-video video {
    width: 100%;
    height: auto;
    display: block;
}

.notion-toggle-content .notion-video {
    margin: 16px 0;
}

.notion-toggle-content .notion-video iframe {
    min-height: 300px;
}

.notion-video iframe,
.notion-video video {
    max-width: 100% !important;
    width: 100% !important;
}

article .notion-video,
.entry-content .notion-video,
.post-content .notion-video,
main .notion-video {
    width: 100% !important;
    max-width: 100% !important;
}

@media (max-width: 600px) {
    .notion-video iframe {
        min-height: 200px;
    }
}

@media (min-width: 601px) and (max-width: 900px) {
    .notion-video iframe {
        min-height: 300px;
    }
}

@media (min-width: 901px) {
    .notion-video iframe {
        min-height: 450px;
    }
}

.notion-button-wrapper {
    margin: 16px 0;
    text-align: left;
}

.notion-button,
article .notion-button,
.entry-content .notion-button,
.post-content .notion-button,
main .notion-button {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 12px 24px !important;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    color: #ffffff !important;
    text-decoration: none !important;
    border-radius: 8px !important;
    font-weight: 600 !important;
    font-size: 15px !important;
    line-height: 1.5 !important;
    transition: all 0.3s ease !important;
    border: none !important;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3) !important;
    cursor: pointer !important;
    text-align: center !important;
    min-width: 120px !important;
}

.notion-button:hover,
article .notion-button:hover,
.entry-content .notion-button:hover,
.post-content .notion-button:hover,
main .notion-button:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4) !important;
    color: #ffffff !important;
    text-decoration: none !important;
}

.notion-button:active,
article .notion-button:active,
.entry-content .notion-button:active,
.post-content .notion-button:active,
main .notion-button:active {
    transform: translateY(0) !important;
    box-shadow: 0 2px 6px rgba(102, 126, 234, 0.3) !important;
}

.notion-callout .notion-button-wrapper {
    margin: 12px 0 0 0;
}

.notion-toggle-content .notion-button-wrapper {
    margin: 12px 0;
}

@media (max-width: 600px) {
    .notion-button {
        padding: 10px 20px !important;
        font-size: 14px !important;
        min-width: 100px !important;
    }
}

.notion-link-preview {
    margin: 16px 0;
    padding: 16px;
    background: #f8f9fa;
    border-left: 4px solid #667eea;
    border-radius: 6px;
}

.notion-link-preview a {
    color: #667eea;
    text-decoration: none;
    font-weight: 500;
    word-break: break-all;
}

.notion-link-preview a:hover {
    text-decoration: underline;
    color: #764ba2;
}

@media (prefers-color-scheme: dark) {
    .notion-link-preview {
        background: #1e293b;
        border-left-color: #818cf8;
    }
    
    .notion-link-preview a {
        color: #818cf8;
    }
    
    .notion-link-preview a:hover {
        color: #a78bfa;
    }
}

.notion-file {
    margin: 16px 0;
    padding: 16px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    display: flex;
    align-items: center;
    transition: background-color 0.2s ease;
}

.notion-file:hover {
    background: #f1f5f9;
}

.notion-file-link {
    display: flex;
    align-items: center;
    color: #3b82f6;
    text-decoration: none;
    font-weight: 500;
}

.notion-file-link::before {
    content: "📄";
    margin-right: 8px;
    font-size: 20px;
}

.notion-bookmark {
    margin: 16px 0;
    padding: 16px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    transition: background-color 0.2s ease;
}

.notion-bookmark:hover {
    background: #f1f5f9;
}

.notion-bookmark a {
    color: #3b82f6;
    font-weight: 500;
    text-decoration: none;
    display: block;
    margin-bottom: 8px;
}

.notion-bookmark-caption {
    color: #64748b;
    font-size: 0.9em;
}

.notion-callout {
    margin: 16px 0;
    padding: 16px;
    border-radius: 8px;
    display: flex;
    align-items: flex-start;
    background: #f8fafc;
    border-left: 4px solid #3b82f6;
}

.notion-callout-icon {
    margin-right: 12px;
    font-size: 20px;
    line-height: 1;
}

.notion-callout-content {
    flex: 1;
}

.notion-table-container {
    margin: 20px 0;
    overflow-x: auto;
}

.notion-table {
    width: 100%;
    border-collapse: collapse;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
}

.notion-table th,
.notion-table td {
    padding: 12px 16px;
    border: 1px solid #e2e8f0;
    text-align: left;
}

.notion-table th {
    background: #f8fafc;
    font-weight: 600;
}

.notion-table tr:nth-child(even) {
    background: #f8fafc;
}

.notion-column-list {
    display: flex;
    gap: 20px;
    margin: 20px 0;
}

.notion-column {
    flex: 1;
    min-width: 0;
}

@media (max-width: 768px) {
    .notion-column-list {
        flex-direction: column;
    }
}

.notion-ai-block {
    margin: 16px 0;
    padding: 16px;
    border-radius: 8px;
    background-color: #f0f7ff;
    border-left: 4px solid #0066ff;
}

.notion-synced-block {
    margin: 16px 0;
    padding: 8px;
    border: 1px dashed #ccc;
    border-radius: 8px;
}

.notion-child-page {
    margin: 16px 0;
    padding: 12px 16px;
    background-color: #f9f9f9;
    border-radius: 6px;
    border: 1px solid #e0e0e0;
}

.notion-child-page a {
    display: flex;
    align-items: center;
    color: #0066cc;
    text-decoration: none;
    font-weight: 500;
}

.notion-child-page a::before {
    content: '📄';
    margin-right: 8px;
    font-size: 18px;
}

.notion-child-database {
    margin: 16px 0;
    padding: 12px 16px;
    background-color: #f5f5f5;
    border-radius: 6px;
    border: 1px solid #e0e0e0;
}

.notion-child-database a {
    display: flex;
    align-items: center;
    color: #0066cc;
    text-decoration: none;
    font-weight: 500;
}

.notion-child-database a::before {
    content: '📂';
    margin-right: 8px;
    font-size: 18px;
}

.notion-template {
    margin: 16px 0;
    padding: 12px 16px;
    background-color: #f5f5ff;
    border-radius: 6px;
    border: 1px solid #e0e0e0;
    font-style: italic;
}

.notion-link-to-page {
    margin: 12px 0;
    display: inline-block;
}

.notion-link-to-page a {
    display: flex;
    align-items: center;
    color: #0066cc;
    text-decoration: none;
    padding: 6px 12px;
    background-color: #f0f0f0;
    border-radius: 4px;
    font-size: 14px;
}

.notion-link-to-page a::before {
    content: '🔗';
    margin-right: 6px;
    font-size: 14px;
}

.notion-table-of-contents {
    margin: 16px 0;
    padding: 16px;
    background-color: #f9f9f9;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
}

.notion-callout-interactive {
    margin: 20px 0;
    border-radius: 8px;
    overflow: hidden;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    transition: all 0.2s ease;
}

.notion-callout-interactive.notion-callout-default {
    border-left: 4px solid #3b82f6;
}

.notion-callout-interactive.notion-callout-gray {
    border-left: 4px solid #6b7280;
}

.notion-callout-interactive.notion-callout-brown {
    border-left: 4px solid #92400e;
}

.notion-callout-interactive.notion-callout-orange {
    border-left: 4px solid #ea580c;
}

.notion-callout-interactive.notion-callout-yellow {
    border-left: 4px solid #ca8504;
}

.notion-callout-interactive.notion-callout-green {
    border-left: 4px solid #15803d;
}

.notion-callout-interactive.notion-callout-blue {
    border-left: 4px solid #1e40af;
}

.notion-callout-interactive.notion-callout-purple {
    border-left: 4px solid #6b21a8;
}

.notion-callout-interactive.notion-callout-pink {
    border-left: 4px solid #be185d;
}

.notion-callout-interactive.notion-callout-red {
    border-left: 4px solid #b91c1c;
}

/* Скрытие контента по умолчанию для интерактивных callout */
.notion-callout-interactive .notion-callout-content {
    display: none;
    padding: 0 20px 16px 52px;
}

/* Показ контента при открытом состоянии */
.notion-callout-interactive.notion-callout-open .notion-callout-content {
    display: block;
}

.notion-callout-header {
    display: flex;
    align-items: center;
    padding: 16px 20px;
    cursor: pointer;
    user-select: none;
    background: #ffffff;
    transition: all 0.2s ease;
    position: relative;
    min-height: 56px;
    box-sizing: border-box;
}

.notion-callout-header:hover {
    background: #f9fafb;
}

.notion-callout-header:focus {
    outline: 2px solid #3b82f6;
    outline-offset: -2px;
}

.notion-callout-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 32px;
    margin-right: 12px;
    flex-shrink: 0;
    font-size: 24px;
}

.notion-callout-icon-emoji {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1;
}

.notion-callout-icon-image {
    width: 32px;
    height: 32px;
    object-fit: contain;
    border-radius: 4px;
}

.notion-callout-text {
    flex: 1;
    font-weight: 600;
    font-size: 16px;
    color: #1f2937;
    line-height: 1.5;
}

.notion-callout-toggle-arrow {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-left: 12px;
    flex-shrink: 0;
    font-size: 18px;
    color: #3b82f6;
    transition: transform 0.3s ease;
}

.notion-callout-header[data-state="open"] .notion-callout-toggle-arrow {
    transform: rotate(180deg);
}

.notion-callout-toggle-arrow.collapsed {
    transform: rotate(0deg);
}

.notion-callout-content {
    padding: 0 20px 16px 52px;
    background: #ffffff;
    display: block;
    animation: notion-fade-in 0.3s ease;
}

.notion-callout-content.collapsed {
    display: none;
}

.notion-callout-content > * {
    margin-top: 12px;
    margin-bottom: 12px;
}

.notion-callout-content > *:first-child {
    margin-top: 0;
}

.notion-callout-content > *:last-child {
    margin-bottom: 0;
}

.notion-callout-content .notion-toggle {
    margin-left: -32px;
    margin-right: -20px;
}

.notion-callout-open {
    margin: 20px 0;
    border-radius: 8px;
    overflow: hidden;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    transition: all 0.2s ease;
}

.notion-callout-open.notion-callout-default {
    border-left: 4px solid #3b82f6;
}

.notion-callout-open.notion-callout-gray {
    border-left: 4px solid #6b7280;
}

.notion-callout-open.notion-callout-brown {
    border-left: 4px solid #92400e;
}

.notion-callout-open.notion-callout-orange {
    border-left: 4px solid #ea580c;
}

.notion-callout-open.notion-callout-yellow {
    border-left: 4px solid #ca8504;
}

.notion-callout-open.notion-callout-green {
    border-left: 4px solid #15803d;
}

.notion-callout-open.notion-callout-blue {
    border-left: 4px solid #1e40af;
}

.notion-callout-open.notion-callout-purple {
    border-left: 4px solid #6b21a8;
}

.notion-callout-open.notion-callout-pink {
    border-left: 4px solid #be185d;
}

.notion-callout-open.notion-callout-red {
    border-left: 4px solid #b91c1c;
}

.notion-callout-header-open {
    display: flex;
    align-items: center;
    padding: 16px 20px;
    background: #ffffff;
    position: relative;
    min-height: 56px;
    box-sizing: border-box;
}

.notion-callout-header-open:hover {
    background: #f9fafb;
}

.notion-callout-content-open {
    padding: 0 20px 16px 52px;
    background: #ffffff;
    display: block;
}

.notion-callout-content-open > * {
    margin-top: 12px;
    margin-bottom: 12px;
}

.notion-callout-content-open > *:first-child {
    margin-top: 0;
}

.notion-callout-content-open > *:last-child {
    margin-bottom: 0;
}

.notion-callout-content-open .notion-toggle {
    margin-left: -32px;
    margin-right: -20px;
}

.notion-callout-content-open img {
    max-width: 100%;
    height: auto;
    border-radius: 6px;
    margin: 12px 0;
}

.notion-callout-content-open .notion-table-container {
    margin: 12px 0;
}

@keyframes notion-fade-in {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.notion-toggle {
    animation: notion-fade-in 0.3s ease forwards;
}

@media print {
    .notion-toggle-header {
        background: none !important;
        border: none !important;
        cursor: default !important;
    }
    
    .notion-toggle-arrow {
        display: none !important;
    }
    
    .notion-toggle-content {
        display: block !important;
        max-height: none !important;
        opacity: 1 !important;
        padding: 0 !important;
    }
    
    .notion-toggle-controls {
        display: none !important;
    }
}

@media print {
    .notion-callout-interactive {
        border: none;
        break-inside: avoid;
    }
    
    .notion-callout-header {
        background: none;
        padding: 0;
        border: none;
        cursor: default;
    }
    
    .notion-callout-toggle-arrow {
        display: none;
    }
    
    .notion-callout-content {
        display: block !important;
        padding: 0;
    }
}

@media (max-width: 768px) {
    .notion-callout-header {
        padding: 12px 16px;
        min-height: 48px;
    }
    
    .notion-callout-content {
        padding: 0 16px 12px 48px;
    }
}

/* Sync Modal Styles */
.sync-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: none;
}

.sync-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
}

.sync-modal-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    border-radius: 20px;
    box-shadow: 0 32px 64px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(255, 255, 255, 0.1);
    max-width: 650px;
    width: 90%;
    max-height: 85vh;
    overflow: hidden;
    animation: modalFadeIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.sync-modal-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 24px 30px;
    border-bottom: none;
}

.sync-modal-header h2 {
    margin: 0;
    font-size: 24px;
    font-weight: 600;
    color: white;
}

.sync-modal-body {
    padding: 30px;
    max-height: 400px;
    overflow-y: auto;
}

.sync-modal-footer {
    padding: 24px 30px;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border-top: 2px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
        transform: translate(-50%, -60%);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%);
    }
}

body.modal-open {
    overflow: hidden;
}

/* Sync Progress Modal Styles */
.progress-stats {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 8px;
}

.progress-stats #progress-count {
    font-size: 14px;
    color: #666;
}

.progress-stats #progress-percent {
    font-size: 16px;
    font-weight: 600;
    color: #0066cc;
}

.sync-progress-list {
    max-height: 450px;
    overflow-y: auto;
    border: 2px solid #f1f5f9;
    border-radius: 12px;
    background: #ffffff;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
}

.sync-progress-item {
    display: flex;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid #f1f5f9;
    transition: all 0.3s ease;
    gap: 12px;
}

.sync-progress-item:last-child {
    border-bottom: none;
}

.sync-progress-item.processing {
    background-color: #f8fafc;
}

.sync-progress-item.completed {
    background-color: #f0fdf4;
}

.sync-progress-item.failed {
    background-color: #fef2f2;
}

.sync-progress-status {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.sync-progress-status.loading {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.sync-progress-status.completed {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    font-size: 20px;
    font-weight: bold;
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
}

.sync-progress-status.failed {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
    font-size: 18px;
    font-weight: bold;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.4);
}

.sync-progress-title {
    flex: 1;
    font-weight: 600;
    font-size: 16px;
    color: #1f2937;
}

.sync-progress-title.processing {
    color: #374151;
}

.sync-progress-title.completed {
    color: #065f46;
}

.sync-progress-title.failed {
    color: #991b1b;
}

.progress-summary {
    display: flex;
    gap: 20px;
    margin-right: auto;
}

.summary-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    color: #666;
}

.summary-item .summary-icon {
    font-size: 16px;
    font-weight: bold;
}

.summary-item .summary-icon.error {
    color: #ef4444;
}

.summary-item .summary-icon:not(.error) {
    color: #10b981;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-spinner-small {
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.6);
    border-radius: 50%;
    border-top-color: #ffffff;
    animation: spin 1s linear infinite;
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
}
