/* Content Tools Blog Custom Styles */

/* Typography improvements for blog content */
.prose h1 { 
    font-size: 1.875rem;
    font-weight: 700;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

@media (min-width: 768px) {
    .prose h1 { font-size: 2.25rem; }
}

.prose h2 { 
    font-size: 1.5rem;
    font-weight: 700;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
}

@media (min-width: 768px) {
    .prose h2 { font-size: 1.875rem; }
}

.prose h3 { 
    font-size: 1.25rem;
    font-weight: 600;
    margin-top: 1.25rem;
    margin-bottom: 0.5rem;
}

@media (min-width: 768px) {
    .prose h3 { font-size: 1.5rem; }
}

.prose h4 { 
    font-size: 1.125rem;
    font-weight: 600;
    margin-top: 1rem;
    margin-bottom: 0.5rem;
}

@media (min-width: 768px) {
    .prose h4 { font-size: 1.25rem; }
}

.prose p { 
    margin-bottom: 1.5rem;
    line-height: 1.625;
}

.prose ul { 
    list-style-type: disc;
    padding-left: 1.5rem;
    margin-bottom: 1.5rem;
}

.prose ul li {
    margin-bottom: 0.5rem;
}

.prose ol { 
    list-style-type: decimal;
    padding-left: 1.5rem;
    margin-bottom: 1.5rem;
}

.prose ol li {
    margin-bottom: 0.5rem;
}

.prose li { 
    line-height: 1.625;
}

.prose blockquote {
    border-left-width: 4px;
    border-left-color: #7c3aed;
    padding-left: 1rem;
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
    margin-top: 1.5rem;
    margin-bottom: 1.5rem;
    font-style: italic;
    color: #374151;
    background-color: #f9fafb;
}

.prose code {
    background-color: #f3f4f6;
    padding-left: 0.5rem;
    padding-right: 0.5rem;
    padding-top: 0.25rem;
    padding-bottom: 0.25rem;
    border-radius: 0.25rem;
    font-size: 0.875rem;
    font-family: ui-monospace, SFMono-Regular, "SF Mono", Consolas, "Liberation Mono", Menlo, monospace;
}

.prose pre {
    background-color: #111827;
    color: #f3f4f6;
    padding: 1rem;
    border-radius: 0.5rem;
    overflow-x: auto;
    margin-top: 1.5rem;
    margin-bottom: 1.5rem;
}

.prose pre code {
    background-color: transparent;
    padding: 0;
}

.prose a {
    color: #7c3aed;
    text-decoration: underline;
}

.prose a:hover {
    color: #6d28d9;
}

.prose img {
    border-radius: 0.5rem;
    margin-top: 1.5rem;
    margin-bottom: 1.5rem;
    width: 100%;
}

.prose table {
    width: 100%;
    margin-top: 1.5rem;
    margin-bottom: 1.5rem;
    border-collapse: collapse;
}

.prose th {
    background-color: #f9fafb;
    font-weight: 600;
    text-align: left;
    padding: 0.75rem;
    border-bottom-width: 2px;
    border-bottom-color: #e5e7eb;
}

.prose td {
    padding: 0.75rem;
    border-bottom-width: 1px;
    border-bottom-color: #e5e7eb;
}

/* Pagination styles */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    margin-top: 3rem;
}

.pagination a,
.pagination span {
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    font-size: 0.875rem;
    font-weight: 500;
}

.pagination a {
    color: #374151;
    background-color: white;
    border: 1px solid #d1d5db;
}

.pagination a:hover {
    background-color: #f9fafb;
}

.pagination span.current {
    color: white;
    background-color: #7c3aed;
    border: 1px solid #7c3aed;
}

/* Line clamp utility */
.line-clamp-3 {
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

/* Ghost-specific overrides */
.kg-card {
    margin-top: 2rem;
    margin-bottom: 2rem;
}

.kg-image-card img {
    width: 100%;
    border-radius: 0.5rem;
}

/* Required Ghost width classes */
.kg-width-wide {
    position: relative;
    width: 85vw;
    min-width: 100%;
    max-width: 1280px;
    margin: 2rem auto;
}

.kg-width-full {
    position: relative;
    width: 100vw;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    margin-top: 2rem;
    margin-bottom: 2rem;
}

/* Ensure images in wide/full cards are responsive */
.kg-width-wide img,
.kg-width-full img {
    width: 100%;
    height: auto;
    display: block;
}

.kg-gallery-card {
    margin-top: 2rem;
    margin-bottom: 2rem;
}

.kg-gallery-container {
    display: grid;
    gap: 1rem;
}

.kg-gallery-row {
    display: flex;
    gap: 1rem;
}

.kg-gallery-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 0.25rem;
}

.kg-bookmark-card {
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    padding: 1rem;
    margin-top: 1.5rem;
    margin-bottom: 1.5rem;
    transition: box-shadow 0.2s;
}

.kg-bookmark-card:hover {
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.kg-bookmark-container {
    display: flex;
}

.kg-bookmark-content {
    flex: 1;
    padding-right: 1rem;
}

.kg-bookmark-title {
    font-weight: 700;
    font-size: 1.125rem;
    margin-bottom: 0.5rem;
}

.kg-bookmark-description {
    color: #4b5563;
    font-size: 0.875rem;
    margin-bottom: 0.5rem;
}

.kg-bookmark-metadata {
    display: flex;
    align-items: center;
    font-size: 0.75rem;
    color: #6b7280;
}

.kg-bookmark-thumbnail {
    width: 8rem;
    height: 8rem;
    object-fit: cover;
    border-radius: 0.25rem;
}

/* Comments iframe container */
#comments-container {
    background-color: #f9fafb;
    border-radius: 0.5rem;
    padding: 1rem;
}

#comments-container iframe {
    width: 100%;
    border-radius: 0.25rem;
    background-color: white;
}