body {
    font-family: 'Inter', sans-serif;
    background-color: #F9FAFB;
    color: #1F2937;
}

a {
    color: var(--primary-color, #4F46E5);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--primary-color-dark, #3730A3);
}

.blog-gradient-text {
    background: linear-gradient(to right, var(--primary-color, #6366F1), var(--primary-color-light, #8B5CF6));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

blockquote {
    border-left: 4px solid var(--primary-color-light, #818CF8);
    padding-left: 1rem;
    margin-left: 0;
    margin-right: 0;
    font-style: italic;
    color: #4B5563;
}

pre {
    background-color: #F3F4F6;
    padding: 1rem;
    border-radius: 0.5rem;
    overflow-x: auto;
    color: #111827;
    border: 1px solid #E5E7EB;
}

code {
    font-family: monospace;
    color: #374151;
}

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

.post-content img {
    max-width: 100%;
    height: auto;
    border-radius: 0.5rem;
    margin-top: 1rem;
    margin-bottom: 1rem;
    border: 1px solid #E5E7EB;
}

.post-content a {
    color: var(--primary-color, #4F46E5);
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 2px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.post-content a:hover {
    color: var(--primary-color-dark, #3730A3);
    text-decoration-thickness: 2px;
    background-color: rgba(79, 70, 229, 0.1);
    border-radius: 0.125rem;
    padding: 0.125rem 0.25rem;
    margin: -0.125rem -0.25rem;
}

.blog-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 1rem;
    border: 1px solid transparent;
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: 0.375rem;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    color: white;
    background-color: var(--primary-color, #5B21B6);
    transition: background-color 0.2s ease-in-out;
    text-decoration: none;
    cursor: pointer;
}

.blog-button:hover {
    background-color: var(--primary-color-dark, #4C1D95);
    color: white;
    text-decoration: none;
}

.blog-button:focus {
    outline: 2px solid transparent;
    outline-offset: 2px;
    box-shadow: 0 0 0 2px white, 0 0 0 4px var(--primary-color, #4F46E5);
}

.blog-button-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 1rem;
    border: 1px solid #D1D5DB;
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: 0.375rem;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    color: #374151;
    background-color: white;
    transition: background-color 0.2s ease-in-out;
    text-decoration: none;
    cursor: pointer;
}

.blog-button-secondary:hover {
    background-color: #F9FAFB;
    border-color: #9CA3AF;
    color: #1F2937;
    text-decoration: none;
}

.blog-button-danger {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 1rem;
    border: 1px solid transparent;
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: 0.375rem;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    color: white;
    background-color: #DC2626;
    transition: background-color 0.2s ease-in-out;
    text-decoration: none;
    cursor: pointer;
}

.blog-button-danger:hover {
    background-color: #B91C1C;
    color: white;
    text-decoration: none;
}

/* Quill Editor Height */
#editor-container {
    min-height: 400px;
    height: auto;
    background-color: white;
    border: 1px solid #E5E7EB;
    border-radius: 0.375rem;
    transition: height 0.3s ease;
}

#editor-container.expanded {
    min-height: 600px;
}

.editor-controls {
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
    margin-top: 0.5rem;
    margin-bottom: 1rem;
}

.expand-editor-button,
.markdown-toggle-button,
.paste-markdown-button {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.25rem 0.5rem;
    font-size: 0.75rem;
    color: #6B7280;
    background-color: transparent;
    border: 1px solid #E5E7EB;
    border-radius: 0.25rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.expand-editor-button:hover,
.markdown-toggle-button:hover,
.paste-markdown-button:hover {
    background-color: #F3F4F6;
    color: #374151;
}

.markdown-toggle-button {
    background-color: #F3F4F6;
}

.paste-markdown-button {
    background-color: #EDE9FE;
    color: #5B21B6;
    border-color: #DDD6FE;
}

.paste-markdown-button:hover {
    background-color: #DDD6FE;
    color: #4C1D95;
}

/* Markdown Editor Styling */
#markdown-editor {
    min-height: 400px;
    font-family: 'Courier New', Courier, monospace;
    line-height: 1.5;
    background-color: #FAFAFA;
    border: 1px solid #E5E7EB;
    border-radius: 0.375rem;
    padding: 1rem;
    resize: vertical;
}

#markdown-editor:focus {
    outline: none;
    border-color: var(--primary-color, #4F46E5);
    box-shadow: 0 0 0 1px var(--primary-color, #4F46E5);
    background-color: white;
}

/* Basic Input Styling */
.form-input {
    width: 100%;
    padding: 0.5rem 0.75rem;
    border: 1px solid #D1D5DB;
    border-radius: 0.375rem;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    transition: border-color 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}

.form-input:focus {
    outline: none;
    border-color: var(--primary-color, #4F46E5);
    box-shadow: 0 0 0 1px var(--primary-color, #4F46E5);
}

.form-label {
    display: block;
    margin-bottom: 0.25rem;
    font-weight: 500;
    color: #374151;
}

.post-content h1,
.post-content h2,
.post-content h3 {
    font-weight: bold;
    margin-top: 1.5em;
    margin-bottom: 0.5em;
}

.post-content ul,
.post-content ol {
    margin-left: 2em;
    margin-bottom: 1em;
}

.post-content li {
    list-style-type: disc;
    margin-bottom: 0.25em;
}

.post-content blockquote {
    border-left: 4px solid #ddd;
    padding-left: 1em;
    color: #555;
    font-style: italic;
}

/* Table styling for editor and blog posts (override Tailwind prose) */
.ql-editor table,
.post-content table,
.prose table {
    border-collapse: collapse !important;
    width: 100% !important;
    margin: 1rem 0 !important;
}

.ql-editor table td,
.ql-editor table th,
.post-content table td,
.post-content table th,
.prose table td,
.prose table th {
    border: 1px solid #e5e7eb !important;
    padding: 0.75rem 1rem !important;
    text-align: left;
}

.ql-editor table th,
.post-content table th,
.prose table th {
    background-color: #f9fafb;
    font-weight: 600;
}

.ql-editor table tr:hover,
.post-content table tr:hover,
.prose table tr:hover {
    background-color: #f9fafb;
}

/* Admin Tab Navigation */
.admin-tab {
    color: #6B7280;
    border-color: transparent;
    cursor: pointer;
    background: none;
    transition: all 0.2s ease;
}

.admin-tab:hover {
    color: #374151;
    border-color: #D1D5DB;
}

.admin-tab.active {
    color: var(--primary-color, #5B21B6);
    border-color: var(--primary-color, #5B21B6);
}

/* Footer Column Editor */
.footer-column-editor {
    background-color: #F3F4F6;
    border: 1px solid #D1D5DB;
    border-left: 4px solid var(--primary-color, #5B21B6);
    border-radius: 0.5rem;
    padding: 1rem;
    margin-bottom: 1rem;
}

.footer-column-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #E5E7EB;
}

.footer-column-header .column-label {
    font-size: 0.75rem;
    font-weight: 600;
    color: #6B7280;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    white-space: nowrap;
}

.footer-column-header input[type="text"] {
    max-width: 250px;
}

.footer-links-container {
    margin-left: 0.5rem;
    padding-left: 0.75rem;
    border-left: 2px solid #E5E7EB;
}

.footer-link-item {
    display: flex;
    gap: 0.5rem;
    align-items: center;
    margin-bottom: 0.5rem;
    padding: 0.5rem;
    background-color: white;
    border-radius: 0.375rem;
    border: 1px solid #E5E7EB;
}

.footer-link-item .link-label-input {
    width: 180px;
    flex-shrink: 0;
}

.footer-link-item .link-url-input {
    width: 280px;
    flex-shrink: 0;
}

.footer-link-item .link-actions {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    margin-left: auto;
}

.reorder-btn {
    background: none;
    border: 1px solid #D1D5DB;
    border-radius: 0.25rem;
    padding: 0.125rem 0.375rem;
    font-size: 0.75rem;
    color: #6B7280;
    cursor: pointer;
    transition: all 0.15s ease;
}

.reorder-btn:hover {
    background-color: #F3F4F6;
    color: #374151;
    border-color: #9CA3AF;
}

.reorder-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

/* Color picker enhancement */
.color-picker-wrapper {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.color-picker-wrapper input[type="color"] {
    width: 3rem;
    height: 2.5rem;
    padding: 0;
    border: 1px solid #D1D5DB;
    border-radius: 0.375rem;
    cursor: pointer;
}

.color-picker-wrapper input[type="text"] {
    width: 8rem;
}
