:root {
    --primary-color: #6b46c1;
    /* Purple - often associated with spirituality */
    --primary-hover: #553c9a;
    --secondary-color: #f8f7fc;
    /* Light purple tint */
    --text-primary: #2d3748;
    --text-secondary: #718096;
    --border-color: #e2e8f0;
    --success-color: #38a169;
    /* Green - growth */
    --error-color: #e53e3e;
    --warning-color: #d69e2e;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

/* Blog Form Styling */
.blog-form-container {
    background-color: white;
    border-radius: 12px;
    box-shadow: var(--shadow-md);
    padding: clamp(15px, 5vw, 30px);
    margin-bottom: 30px;
    border: 1px solid var(--border-color);
}

.form-header {
    margin-bottom: 25px;
    text-align: center;
}

.form-title {
    font-size: clamp(1.2rem, 5vw, 1.75rem);
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 8px;
}

.form-description {
    color: var(--text-secondary);
    font-size: 16px;
}

.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    font-size: 14px;
    color: var(--text-primary);
}

.form-input,
.form-textarea,
.form-select {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.3s;
    font-family: inherit;
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(107, 70, 193, 0.1);
}

.form-textarea {
    min-height: 200px;
    resize: vertical;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

/* AI Suggestion Box */
.ai-suggestion {
    background: linear-gradient(135deg, #f6f5ff 0%, #f0ebff 100%);
    border-radius: 10px;
    padding: 18px;
    margin-bottom: 25px;
    display: none;
    border: 1px solid #e3d9ff;
}

.ai-suggestion.show {
    display: block;
}

.ai-suggestion-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.ai-suggestion-title {
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--primary-color);
}

.ai-badge {
    background-color: var(--primary-color);
    color: white;
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 12px;
}

.ai-suggestion-text {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
}

.ai-actions {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.ai-button {
    padding: 8px 16px;
    border: none;
    border-radius: 6px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
    font-weight: 500;
}

.ai-accept {
    background-color: var(--success-color);
    color: white;
}

.ai-accept:hover {
    background-color: #2f855a;
}

.ai-reject {
    background-color: white;
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}

.ai-reject:hover {
    background-color: var(--secondary-color);
}

/* Form Actions */
.form-actions {
    display: flex;
    justify-content: space-between;
    margin-top: 30px;
}

.btn {
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 500;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
    border: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    transform: translateY(-1px);
}

.btn-secondary {
    background-color: white;
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background-color: var(--secondary-color);
}

.btn-ai {
    background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%);
    color: white;
}

.btn-ai:hover {
    background: linear-gradient(135deg, #7c3aed 0%, #6d28d9 100%);
    transform: translateY(-1px);
}

/* Blog Posts List */
.blog-posts-container {
    background-color: white;
    border-radius: 12px;
    box-shadow: var(--shadow-md);
    padding: clamp(15px, 5vw, 30px);
    border: 1px solid var(--border-color);
}

.posts-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.posts-title {
    font-size: 22px;
    font-weight: 600;
    color: var(--text-primary);
}

.search-box {
    position: relative;
    width: 300px;
}

.search-input {
    width: 100%;
    padding: 10px 40px 10px 16px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 14px;
}

.search-icon {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-secondary);
}

.blog-post {
    border-bottom: 1px solid var(--border-color);
    padding: 24px 0;
    transition: all 0.2s;
}

.blog-post:hover {
    background-color: var(--secondary-color);
    margin: 0 -10px;
    padding: 24px 10px;
    border-radius: 8px;
}

.blog-post:last-child {
    border-bottom: none;
}

.post-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.post-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
}

.post-status {
    font-size: 12px;
    padding: 5px 10px;
    border-radius: 20px;
    font-weight: 500;
}

.status-published {
    background-color: #c6f6d5;
    color: #22543d;
}

.status-draft {
    background-color: #fed7d7;
    color: #742a2a;
}

.post-meta {
    display: flex;
    gap: 20px;
    margin-bottom: 12px;
    font-size: 14px;
    color: var(--text-secondary);
}

.post-excerpt {
    margin-bottom: 16px;
    color: var(--text-secondary);
    line-height: 1.6;
}

.post-actions {
    display: flex;
    gap: 10px;
}

.post-action-btn {
    padding: 8px 16px;
    border: none;
    border-radius: 6px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
}

.edit-btn {
    background-color: var(--secondary-color);
    color: var(--text-primary);
}

.edit-btn:hover {
    background-color: #e2e8f0;
}

.delete-btn:hover {
    background-color: #fc8181;
}

.view-btn {
    background-color: var(--primary-color);
    color: white !important;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.view-btn:hover {
    background-color: var(--primary-hover);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(26, 43, 109, 0.2);
}

.pdf-btn {
    background: #f1f5f9;
    color: #1e293b;
    border: 1px solid #e2e8f0;
}

.pdf-btn:hover {
    background: #e2e8f0;
    color: #2563eb;
    border-color: #2563eb;
}

.pdf-btn i {
    color: #ef4444;
}

/* Toast Notification */
.toast {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background-color: white;
    border-radius: 10px;
    box-shadow: var(--shadow-lg);
    padding: 16px 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 300px;
    transform: translateX(400px);
    transition: transform 0.3s ease-in-out;
    z-index: 1000;
}

.toast.show {
    transform: translateX(0);
}

.toast-icon {
    font-size: 20px;
}

.toast-success .toast-icon {
    color: var(--success-color);
}

.toast-error .toast-icon {
    color: var(--error-color);
}

.toast-message {
    flex: 1;
}

.toast-title {
    font-weight: 600;
    margin-bottom: 2px;
}

.toast-text {
    font-size: 14px;
    color: var(--text-secondary);
}

.toast-close {
    background: none;
    border: none;
    font-size: 18px;
    color: var(--text-secondary);
    cursor: pointer;
}

/* Responsive Design */
@media (max-width: 768px) {

    .blog-form-container,
    .blog-posts-container {
        padding: 20px 15px !important;
        border-radius: 8px;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .search-box {
        width: 100%;
        margin-top: 10px;
    }

    .posts-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .form-actions {
        flex-direction: column;
        gap: 10px;
    }

    .btn {
        width: 100%;
        justify-content: center;
    }
}

/* PDF Viewer Modal Styles */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 3000;
    backdrop-filter: blur(5px);
}

.modal-content {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
}

.modal-header {
    padding: 15px 25px;
    background: #fff;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h4 {
    color: #1a2b6d;
    font-family: 'Playfair Display', serif;
    font-size: 1.25rem;
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.8rem;
    color: #94a3b8;
    cursor: pointer;
    line-height: 1;
}

.modal-close:hover {
    color: #ef4444;
}

/* PDF Toolbar Stylings (re-standardized) */
.pdf-toolbar {
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    padding: 10px 15px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.pdf-controls-group {
    display: flex;
    align-items: center;
    gap: 8px;
}

.pdf-nav-btn, .pdf-zoom-btn, .pdf-action-btn {
    padding: 6px 14px;
    border-radius: 4px;
    border: 1px solid #cbd5e0;
    background: white;
    color: #475569;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 6px;
}

.pdf-nav-btn:hover:not(:disabled), 
.pdf-zoom-btn:hover, 
.pdf-action-btn:hover {
    background: #1a2b6d;
    color: white;
    border-color: #1a2b6d;
}

.pdf-nav-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.pdf-page-badge, .pdf-zoom-badge {
    font-size: 0.8rem;
    font-weight: 700;
    color: #1a2b6d;
    background: #f1f5f9;
    padding: 4px 12px;
    border-radius: 20px;
    min-width: 80px;
    text-align: center;
}

.pdf-canvas-wrapper {
    padding: 20px;
    display: flex;
    justify-content: center;
    width: 100%;
}

.pdf-page-canvas {
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.2);
    background: white;
    max-width: 100%;
}