/* Single Post Page - BudMarket */

/* Variables */
:root {
    --sp-primary: #E31E24;
    --sp-primary-hover: #c31118;
    --sp-text: #333333;
    --sp-text-light: #666666;
    --sp-text-muted: #999999;
    --sp-bg: #ffffff;
    --sp-bg-light: #f8f9fa;
    --sp-border: #e1e1e1;
    --sp-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    --sp-radius: 8px;
}

.single-post-page {
    background: var(--sp-bg);
}

/* Breadcrumbs */
.post-breadcrumbs {
    background: var(--sp-bg-light);
    border-bottom: 1px solid var(--sp-border);
}

.post-breadcrumbs .breadcrumb {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 15px 0;
    font-size: 14px;
}

.post-breadcrumbs .breadcrumb a {
    color: var(--sp-text-light);
    text-decoration: none;
    transition: color 0.2s;
}

.post-breadcrumbs .breadcrumb a:hover {
    color: var(--sp-primary);
}

.post-breadcrumbs .breadcrumb .separator {
    color: var(--sp-text-muted);
}

.post-breadcrumbs .breadcrumb .current {
    color: var(--sp-text);
    font-weight: 500;
    max-width: 300px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Post Header */
.post-header {
    padding: 50px 0 40px;
    text-align: center;
}

.post-categories {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 20px;
}

.category-tag {
    display: inline-block;
    background: var(--sp-primary);
    color: white;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    transition: background 0.2s;
}

.category-tag:hover {
    background: var(--sp-primary-hover);
    color: white;
    text-decoration: none;
}

.post-title {
    font-size: 36px;
    font-weight: 700;
    color: var(--sp-text);
    line-height: 1.3;
    margin: 0 0 25px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.post-meta {
    display: flex;
    justify-content: center;
    gap: 25px;
    font-size: 14px;
    color: var(--sp-text-light);
}

.post-meta .meta-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.post-meta svg {
    color: var(--sp-primary);
}

/* Featured Image */
.post-featured-image {
    padding-bottom: 40px;
}

.post-featured-image .container {
    max-width: 900px;
}

.post-featured-image .featured-img {
    width: 100%;
    height: auto;
    border-radius: var(--sp-radius);
    box-shadow: var(--sp-shadow);
}

/* Post Layout */
.post-content-wrapper {
    padding: 0 0 60px;
}

.post-layout {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 50px;
    align-items: start;
}

/* Main Content */
.post-content {
    max-width: 100%;
}

.post-content h2,
.post-content h3,
.post-content h4 {
    color: var(--sp-text);
    margin-top: 35px;
    margin-bottom: 15px;
}

.post-content h2 {
    font-size: 28px;
}

.post-content h3 {
    font-size: 22px;
}

.post-content h4 {
    font-size: 18px;
}

.post-content p {
    color: var(--sp-text);
    line-height: 1.8;
    margin-bottom: 20px;
    font-size: 16px;
}

.post-content ul,
.post-content ol {
    margin-bottom: 20px;
    padding-left: 25px;
}

.post-content li {
    color: var(--sp-text);
    line-height: 1.7;
    margin-bottom: 8px;
}

.post-content img {
    max-width: 100%;
    height: auto;
    border-radius: var(--sp-radius);
    margin: 25px 0;
}

.post-content blockquote {
    border-left: 4px solid var(--sp-primary);
    padding: 20px 25px;
    margin: 30px 0;
    background: var(--sp-bg-light);
    border-radius: 0 var(--sp-radius) var(--sp-radius) 0;
}

.post-content blockquote p {
    font-style: italic;
    margin: 0;
    color: var(--sp-text-light);
}

.post-content a {
    color: var(--sp-primary);
    text-decoration: underline;
}

.post-content a:hover {
    color: var(--sp-primary-hover);
}

/* Tags */
.post-tags {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    padding: 25px 0;
    border-top: 1px solid var(--sp-border);
    margin-top: 40px;
}

.tags-label {
    font-weight: 500;
    color: var(--sp-text);
}

.post-tags .tag {
    display: inline-block;
    padding: 5px 12px;
    background: var(--sp-bg-light);
    color: var(--sp-text-light);
    border-radius: 4px;
    font-size: 13px;
    text-decoration: none;
    transition: all 0.2s;
}

.post-tags .tag:hover {
    background: var(--sp-primary);
    color: white;
}

/* Share */
.post-share {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 25px 0;
    border-top: 1px solid var(--sp-border);
}

.share-label {
    font-weight: 500;
    color: var(--sp-text);
}

.share-buttons {
    display: flex;
    gap: 10px;
}

.share-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--sp-bg-light);
    color: var(--sp-text-light);
    text-decoration: none;
    transition: all 0.2s;
}

.share-btn:hover {
    color: white;
}

.share-btn.facebook:hover {
    background: #1877F2;
}

.share-btn.twitter:hover {
    background: #000000;
}

.share-btn.telegram:hover {
    background: #0088cc;
}

.share-btn.email:hover {
    background: var(--sp-primary);
}

/* Sidebar */
.post-sidebar {
    position: sticky;
    top: 100px;
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.sidebar-widget {
    background: var(--sp-bg-light);
    border-radius: var(--sp-radius);
    padding: 20px;
}

.widget-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--sp-text);
    margin: 0 0 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--sp-primary);
}

/* Author Widget */
.author-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.author-info img {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
}

.author-details {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.author-label {
    font-size: 12px;
    color: var(--sp-text-muted);
    text-transform: uppercase;
}

.author-name {
    font-size: 16px;
    font-weight: 600;
    color: var(--sp-text);
}

/* Categories Widget */
.categories-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.categories-list li {
    margin-bottom: 8px;
}

.categories-list li:last-child {
    margin-bottom: 0;
}

.categories-list a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--sp-text-light);
    text-decoration: none;
    padding: 8px 0;
    border-bottom: 1px solid var(--sp-border);
    transition: color 0.2s;
}

.categories-list a:hover {
    color: var(--sp-primary);
}

.categories-list .count {
    font-size: 12px;
    color: var(--sp-text-muted);
}

/* Related Posts */
.related-posts-section {
    background: var(--sp-bg-light);
    padding: 60px 0;
}

.related-posts-section .section-title {
    font-size: 28px;
    font-weight: 700;
    color: var(--sp-text);
    text-align: center;
    margin: 0 0 40px;
}

.related-posts-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.related-post-card {
    background: var(--sp-bg);
    border-radius: var(--sp-radius);
    overflow: hidden;
    box-shadow: var(--sp-shadow);
    transition: transform 0.2s, box-shadow 0.2s;
}

.related-post-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
}

.related-post-card .post-image {
    display: block;
    aspect-ratio: 16/10;
    overflow: hidden;
}

.related-post-card .post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.related-post-card:hover .post-image img {
    transform: scale(1.05);
}

.related-post-card .post-info {
    padding: 20px;
}

.related-post-card .post-category {
    display: inline-block;
    font-size: 12px;
    color: var(--sp-primary);
    text-decoration: none;
    font-weight: 500;
    margin-bottom: 10px;
}

.related-post-card .post-title {
    font-size: 16px;
    font-weight: 600;
    line-height: 1.4;
    margin: 0 0 12px;
}

.related-post-card .post-title a {
    color: var(--sp-text);
    text-decoration: none;
    transition: color 0.2s;
}

.related-post-card .post-title a:hover {
    color: var(--sp-primary);
}

.related-post-card .post-date {
    font-size: 13px;
    color: var(--sp-text-muted);
}

/* View All Posts */
.view-all-posts {
    text-align: center;
    margin-top: 40px;
}

.btn-outline {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    border: 2px solid var(--sp-primary);
    color: var(--sp-primary);
    border-radius: var(--sp-radius);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.2s;
}

.btn-outline:hover {
    background: var(--sp-primary);
    color: white;
    text-decoration: none;
}

/* Responsive */
@media (max-width: 1024px) {
    .post-layout {
        grid-template-columns: 1fr;
    }

    .post-sidebar {
        position: static;
        flex-direction: row;
        flex-wrap: wrap;
    }

    .sidebar-widget {
        flex: 1;
        min-width: 250px;
    }
}

@media (max-width: 768px) {
    .post-title {
        font-size: 28px;
    }

    .post-meta {
        flex-direction: column;
        gap: 10px;
    }

    .related-posts-grid {
        grid-template-columns: 1fr;
    }

    .post-sidebar {
        flex-direction: column;
    }

    .sidebar-widget {
        min-width: 100%;
    }
}

@media (max-width: 576px) {
    .post-header {
        padding: 30px 0;
    }

    .post-title {
        font-size: 24px;
    }

    .post-content h2 {
        font-size: 22px;
    }

    .post-content h3 {
        font-size: 18px;
    }

    .post-share {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
}