/**
 * VDaily Format - Modern Post Styling with CodeMirror
 * Version: 1.0.0
 */

/* Modern content container - Optimized with reduced padding */
.vdaily-format-content {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif !important;
    font-size: 18px !important;
    line-height: 1.8 !important;
    color: #333 !important;
    max-width: 800px !important;
    margin: 0 auto !important;
    padding: 10px !important;
}

/* Headings - Reduced margins */
.vdaily-format-content h1,
.vdaily-format-content h2,
.vdaily-format-content h3,
.vdaily-format-content h4,
.vdaily-format-content h5,
.vdaily-format-content h6 {
    font-weight: 600 !important;
    margin-top: 1.2em !important;
    margin-bottom: 0.6em !important;
    line-height: 1.3 !important;
    color: #1a1a1a !important;
}

.vdaily-format-content h1 {
    font-size: 2.5em !important;
    border-bottom: 3px solid #0073aa !important;
    padding-bottom: 0.2em !important;
}

.vdaily-format-content h2 {
    font-size: 2em !important;
    border-bottom: 2px solid #0073aa !important;
    padding-bottom: 0.2em !important;
}

.vdaily-format-content h3 {
    font-size: 1.75em !important;
}

.vdaily-format-content h4 {
    font-size: 1.5em !important;
}

/* Paragraphs - Reduced margin */
.vdaily-format-content p {
    margin-bottom: 0.8em !important;
}

/* Links */
.vdaily-format-content a {
    color: #0073aa !important;
    text-decoration: none !important;
    border-bottom: 1px solid transparent !important;
    transition: all 0.3s ease !important;
}

.vdaily-format-content a:hover {
    color: #005177 !important;
    border-bottom-color: #005177 !important;
}

/* Lists - Reduced margins and padding */
.vdaily-format-content ul,
.vdaily-format-content ol {
    margin-bottom: 0.8em !important;
    padding-left: 1.5em !important;
}

.vdaily-format-content li {
    margin-bottom: 0.3em !important;
}

/* Blockquotes - Reduced margins and padding */
.vdaily-format-content blockquote {
    border-left: 4px solid #0073aa !important;
    padding-left: 1em !important;
    margin: 0.8em 0 !important;
    font-style: italic !important;
    color: #666 !important;
    background: #f5f5f5 !important;
    padding: 0.8em 1em !important;
    border-radius: 4px !important;
}

/* Images - Reduced margin */
.vdaily-format-content img {
    max-width: 100% !important;
    height: auto !important;
    border-radius: 8px !important;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1) !important;
    margin: 0.8em 0 !important;
}

/* Code blocks - Dracula theme with reduced margins and padding */
.vdaily-format-content pre {
    background: #282a36 !important;
    border-radius: 8px !important;
    padding: 1em !important;
    overflow-x: auto !important;
    margin: 0.8em 0 !important;
    position: relative !important;
}

.vdaily-format-content pre code {
    background: transparent !important;
    padding: 0 !important;
    border: none !important;
    border-radius: 0 !important;
    color: #f8f8f2 !important;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', 'Consolas', 'source-code-pro', monospace !important;
    font-size: 14px !important;
    line-height: 1.5 !important;
    display: block !important;
}

/* Inline code */
.vdaily-format-content code {
    background: #f4f4f4 !important;
    padding: 0.2em 0.4em !important;
    border-radius: 3px !important;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', 'Consolas', 'source-code-pro', monospace !important;
    font-size: 0.9em !important;
    color: #e83e8c !important;
    border: 1px solid #e1e1e1 !important;
}

/* CodeMirror styling adjustments */
.vdaily-format-content .CodeMirror {
    height: auto !important;
    border-radius: 8px !important;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', 'Consolas', 'source-code-pro', monospace !important;
    font-size: 14px !important;
    line-height: 1.5 !important;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1) !important;
}

.vdaily-format-content .CodeMirror-scroll {
    min-height: 100px !important;
}

/* Code block wrapper - Reduced margin */
.vdaily-format-content .code-block-wrapper {
    position: relative !important;
    margin: 0.8em 0 !important;
}

.vdaily-format-content .code-block-language {
    position: absolute !important;
    top: 8px !important;
    right: 8px !important;
    background: rgba(255, 255, 255, 0.1) !important;
    color: #f8f8f2 !important;
    padding: 4px 12px !important;
    border-radius: 4px !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
    z-index: 10 !important;
}

/* Tables - Reduced margin */
.vdaily-format-content table {
    width: 100% !important;
    border-collapse: collapse !important;
    margin: 0.8em 0 !important;
    background: #fff !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1) !important;
    border-radius: 8px !important;
    overflow: hidden !important;
}

.vdaily-format-content th,
.vdaily-format-content td {
    padding: 12px 15px !important;
    text-align: left !important;
    border-bottom: 1px solid #e1e1e1 !important;
}

.vdaily-format-content th {
    background: #0073aa !important;
    color: #fff !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;
    font-size: 0.9em !important;
    letter-spacing: 0.5px !important;
}

.vdaily-format-content tr:last-child td {
    border-bottom: none !important;
}

.vdaily-format-content tr:hover {
    background: #f9f9f9 !important;
}

/* Horizontal rule */
.vdaily-format-content hr {
    border: none !important;
    border-top: 2px solid #e1e1e1 !important;
    margin: 2em 0 !important;
}

/* Copy button for code blocks */
.vdaily-format-content .code-copy-button {
    position: absolute !important;
    top: 8px !important;
    right: 8px !important;
    background: #44475a !important;
    color: #f8f8f2 !important;
    border: 1px solid #6272a4 !important;
    padding: 6px 12px !important;
    border-radius: 4px !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    z-index: 10 !important;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
}

.vdaily-format-content .code-copy-button:hover {
    background: #6272a4 !important;
    color: #fff !important;
}

.vdaily-format-content .code-copy-button:active {
    background: #50fa7b !important;
    color: #282a36 !important;
}

.vdaily-format-content .code-copy-button.copied {
    background: #50fa7b !important;
    color: #282a36 !important;
}

/* Responsive design */
@media (max-width: 768px) {
    .vdaily-format-content {
        font-size: 16px !important;
        padding: 8px !important;
    }
    
    .vdaily-format-content h1 {
        font-size: 2em !important;
    }
    
    .vdaily-format-content h2 {
        font-size: 1.75em !important;
    }
    
    .vdaily-format-content h3 {
        font-size: 1.5em !important;
    }
    
    .vdaily-format-content pre {
        padding: 0.8em !important;
    }
    
    .vdaily-format-content .CodeMirror {
        font-size: 12px !important;
    }
}
