/**
 * Single Pages CSS
 * Styling for single blog posts and single services
 */

/* ===== SINGLE POST STYLES ===== */

/* Post Header Section */
.post-header-section {
    padding: 40px 0 20px;
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%);
    border-bottom: 1px solid var(--border-color);
}

.post-header-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

/* Breadcrumb */
.post-breadcrumb {
    margin-bottom: 20px;
    font-size: 0.9rem;
}

.post-breadcrumb a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.post-breadcrumb a:hover {
    color: var(--accent-color);
}

.breadcrumb-separator {
    margin: 0 8px;
    color: var(--text-muted);
}

.breadcrumb-current {
    color: var(--text-primary);
    font-weight: 500;
}

/* Category Badge */
.post-category-badge {
    display: inline-block;
    padding: 6px 16px;
    border-radius: 20px;
    color: white;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 20px;
}

/* Post Title */
.post-title {
    font-size: var(--text-4xl);
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: var(--spacing-md);
    color: var(--text-primary);
}

/* Post Meta */
.post-meta {
    display: flex;
    justify-content: center;
    gap: var(--spacing-md);
    flex-wrap: wrap;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

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

.meta-icon {
    color: var(--accent-color);
}

.meta-author a {
    color: inherit;
    text-decoration: none;
}

.meta-author a:hover {
    color: var(--accent-color);
}

/* Featured Image */
.post-featured-image {
    padding: 0;
}

.featured-image-wrapper {
    margin: 40px 0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.post-featured-img {
    width: 100%;
    height: auto;
    display: block;
}

/* Post Content Section */
.post-content-section {
    padding: 60px 0;
}

.post-layout {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 60px;
    max-width: 1200px;
    margin: 0 auto;
}

.post-content-wrapper {
    background: white;
}

/* Post Content */
.post-content {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #495057;
    margin-bottom: 40px;
}

.post-content h2,
.post-content h3,
.post-content h4 {
    color: #212529;
    margin: 30px 0 15px;
    font-weight: 600;
}

.post-content h2 {
    font-size: 1.8rem;
}

.post-content h3 {
    font-size: 1.5rem;
}

.post-content h4 {
    font-size: 1.3rem;
}

.post-content p {
    margin-bottom: 20px;
}

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

.post-content li {
    margin-bottom: 8px;
}

.post-content blockquote {
    background: #f8f9fa;
    border-left: 4px solid #e53e3e;
    padding: 20px 30px;
    margin: 30px 0;
    font-style: italic;
    font-size: 1.1rem;
}

.post-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 20px 0;
}

/* Page Links (Pagination) */
.page-links {
    margin: 30px 0;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    text-align: center;
}

.page-links-title {
    font-weight: 600;
    margin-right: 10px;
}

.page-links a,
.page-links > span {
    display: inline-block;
    padding: 8px 12px;
    margin: 0 4px;
    background: white;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    text-decoration: none;
    color: #495057;
    transition: all 0.3s ease;
}

.page-links a:hover {
    background: #e53e3e;
    color: white;
    border-color: #e53e3e;
}

/* Post Footer */
.post-footer {
    margin-top: 40px;
    padding-top: 40px;
    border-top: 1px solid #dee2e6;
}

/* Tags */
.post-tags {
    margin-bottom: 30px;
}

.tags-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 15px;
    color: #495057;
}

.tags-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.tag-link {
    padding: 6px 12px;
    background: #f8f9fa;
    color: #6c757d;
    text-decoration: none;
    border-radius: 20px;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.tag-link:hover {
    background: #e53e3e;
    color: white;
}

/* Share Buttons */
.post-share {
    margin-top: 30px;
}

.share-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 15px;
    color: #495057;
}

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

.share-button {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: #f8f9fa;
    color: #495057;
    text-decoration: none;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    cursor: pointer;
}

.share-button:hover {
    background: #e53e3e;
    color: white;
    border-color: #e53e3e;
    transform: translateY(-2px);
}

.share-facebook:hover {
    background: #1877f2;
    border-color: #1877f2;
}

.share-twitter:hover {
    background: #1da1f2;
    border-color: #1da1f2;
}

.share-linkedin:hover {
    background: #0077b5;
    border-color: #0077b5;
}

/* Post Sidebar */
.post-sidebar {
    padding-left: 20px;
}

/* Author Box */
.author-box {
    background: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    margin-bottom: 40px;
    text-align: center;
}

.author-avatar {
    margin-bottom: 20px;
}

.author-avatar img {
    border-radius: 50%;
    border: 4px solid #f8f9fa;
}

.author-name {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 10px;
    color: #212529;
}

.author-bio {
    color: #6c757d;
    line-height: 1.6;
    margin-bottom: 20px;
}

.author-link {
    color: #e53e3e;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.author-link:hover {
    color: #c53030;
}

/* Related Posts */
.related-posts {
    background: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    margin-bottom: 40px;
}

.related-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 20px;
    color: #212529;
}

.related-posts-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.related-post-item {
    display: flex;
    gap: 15px;
    align-items: flex-start;
}

.related-post-thumb {
    flex-shrink: 0;
    width: 80px;
    height: 80px;
    border-radius: 8px;
    overflow: hidden;
}

.related-post-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.related-post-content {
    flex: 1;
}

.related-post-title {
    margin: 0 0 8px 0;
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.4;
}

.related-post-title a {
    color: #495057;
    text-decoration: none;
    transition: color 0.3s ease;
}

.related-post-title a:hover {
    color: #e53e3e;
}

.related-post-date {
    font-size: 0.85rem;
    color: #6c757d;
}

/* Sidebar Categories */
.sidebar-categories {
    background: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
}

.widget-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 20px;
    color: #212529;
}

.categories-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.category-item {
    margin-bottom: 12px;
}

.category-item a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #495057;
    text-decoration: none;
    padding: 8px 0;
    transition: color 0.3s ease;
}

.category-item a:hover {
    color: #e53e3e;
}

.post-count {
    font-size: 0.85rem;
    color: #6c757d;
}

/* Post Navigation */
.post-navigation-section {
    padding: 60px 0;
    background: #f8f9fa;
    border-top: 1px solid #dee2e6;
}

.post-navigation {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
}

.nav-previous,
.nav-next {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    transition: transform 0.3s ease;
}

.nav-previous:hover,
.nav-next:hover {
    transform: translateY(-5px);
}

.nav-link {
    display: block;
    padding: 30px;
    text-decoration: none;
    color: inherit;
}

.nav-direction {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    color: #6c757d;
    margin-bottom: 10px;
}

.nav-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #495057;
    line-height: 1.4;
    margin: 0;
    transition: color 0.3s ease;
}

.nav-link:hover .nav-title {
    color: #e53e3e;
}

.nav-next .nav-direction {
    justify-content: flex-end;
}

/* Comments Section */
.comments-section {
    padding: 60px 0;
    background: white;
}

.comments-wrapper {
    max-width: 800px;
    margin: 0 auto;
}

/* ===== SINGLE SERVICE STYLES ===== */

/* Service Header Section */
.service-header-section {
    padding: 40px 0 20px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-bottom: 1px solid #dee2e6;
}

.service-header-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.service-breadcrumb {
    margin-bottom: 20px;
    font-size: 0.9rem;
}

.service-breadcrumb a {
    color: #6c757d;
    text-decoration: none;
    transition: color 0.3s ease;
}

.service-breadcrumb a:hover {
    color: #e53e3e;
}

.service-title {
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 20px;
    color: #212529;
}

.service-meta {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
}

.service-meta .meta-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: rgba(229, 62, 62, 0.1);
    border-radius: 25px;
    color: #e53e3e;
    font-weight: 600;
}

/* Service Featured Image */
.service-featured-image {
    padding: 0;
}

.service-featured-img {
    width: 100%;
    height: auto;
    display: block;
}

/* Service Content Section */
.service-content-section {
    padding: 60px 0;
}

.service-layout {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 60px;
    max-width: 1200px;
    margin: 0 auto;
}

.service-content-wrapper {
    background: white;
}

/* Service Content */
.service-content {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #495057;
    margin-bottom: 40px;
}

.service-content h2,
.service-content h3,
.service-content h4 {
    color: #212529;
    margin: 30px 0 15px;
    font-weight: 600;
}

/* Service Details */
.service-details {
    margin-bottom: 40px;
    padding: 30px;
    background: #f8f9fa;
    border-radius: 12px;
}

.details-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 25px;
    color: #212529;
}

.details-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.detail-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 20px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.detail-icon {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    background: rgba(229, 62, 62, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #e53e3e;
}

.detail-info {
    flex: 1;
}

.detail-label {
    font-size: 0.9rem;
    font-weight: 600;
    color: #6c757d;
    margin: 0 0 5px 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.detail-value {
    font-size: 1.1rem;
    font-weight: 600;
    color: #212529;
    margin: 0;
}

/* Service CTA */
.service-cta {
    padding: 40px;
    background: linear-gradient(135deg, #e53e3e 0%, #c53030 100%);
    color: white;
    border-radius: 12px;
    text-align: center;
}

.cta-title {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 15px;
}

.cta-description {
    font-size: 1.1rem;
    margin-bottom: 30px;
    opacity: 0.9;
}

.cta-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

.cta-button {
    padding: 12px 24px;
    border: 2px solid white;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.cta-button.primary {
    background: white;
}

.cta-button.primary:hover {
    background: transparent;
    color: white;
}

.cta-button.secondary {
    background: transparent;
    color: white;
}

.cta-button.secondary:hover {
    background: white;
    color: #e53e3e;
}

/* Service Sidebar */
.service-sidebar {
    padding-left: 20px;
}

/* Related Services */
.related-services {
    background: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    margin-bottom: 40px;
}

.related-services-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.related-service-item {
    display: flex;
    gap: 15px;
    align-items: flex-start;
}

.related-service-thumb {
    flex-shrink: 0;
    width: 80px;
    height: 80px;
    border-radius: 8px;
    overflow: hidden;
}

.related-service-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.related-service-content {
    flex: 1;
}

.related-service-title {
    margin: 0 0 8px 0;
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.4;
}

.related-service-title a {
    color: #495057;
    text-decoration: none;
    transition: color 0.3s ease;
}

.related-service-title a:hover {
    color: #e53e3e;
}

.related-service-price {
    font-size: 0.9rem;
    font-weight: 600;
    color: #e53e3e;
}

/* Sidebar Contact */
.sidebar-contact {
    margin-bottom: 40px;
}

.contact-card {
    background: linear-gradient(135deg, #e53e3e 0%, #c53030 100%);
    color: white;
    padding: 30px;
    border-radius: 12px;
    text-align: center;
}

.contact-icon {
    margin-bottom: 20px;
}

.contact-svg-icon {
    color: rgba(255, 255, 255, 0.9);
}

.contact-title {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 15px;
}

.contact-description {
    margin-bottom: 25px;
    opacity: 0.9;
    line-height: 1.6;
}

.contact-button {
    display: inline-block;
    padding: 12px 24px;
    background: white;
    color: #e53e3e;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.contact-button:hover {
    background: rgba(255, 255, 255, 0.9);
    transform: translateY(-2px);
}

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

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

.service-categories-list a {
    display: block;
    color: #495057;
    text-decoration: none;
    padding: 8px 0;
    transition: color 0.3s ease;
}

.service-categories-list a:hover {
    color: #e53e3e;
}

/* Service Navigation */
.service-navigation-section {
    padding: 60px 0;
    background: #f8f9fa;
    border-top: 1px solid #dee2e6;
}

.service-navigation {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
}

/* Offset đầu trang cho các header section của single để tránh bị header che */
.post-header-section,
.service-header-section,
.job-header {
	padding-top: calc(var(--header-offset) + 40px);
}

/* Với màn hình nhỏ, offset sẽ dựa theo biến đã điều chỉnh ở :root trong mobile-menu.css */
@media (max-width: 768px) {
	.post-header-section,
	.service-header-section,
	.job-header {
		padding-top: calc(var(--header-offset) + 20px);
	}
}

/* ===== RESPONSIVE STYLES ===== */

@media (max-width: 1024px) {
    .post-layout,
    .service-layout {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .post-sidebar,
    .service-sidebar {
        padding-left: 0;
    }
    
    .post-navigation,
    .service-navigation {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

@media (max-width: 768px) {
    .post-title,
    .service-title {
        font-size: 2rem;
    }
    
    .post-meta,
    .service-meta {
        justify-content: flex-start;
        flex-direction: column;
        gap: 10px;
    }
    
    .post-content,
    .service-content {
        font-size: 1rem;
    }
    
    .details-grid {
        grid-template-columns: 1fr;
    }
    
    .share-buttons {
        justify-content: center;
    }
    
    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .related-post-item,
    .related-service-item {
        flex-direction: column;
        text-align: center;
    }
    
    .related-post-thumb,
    .related-service-thumb {
        width: 100%;
        height: 200px;
    }
}

@media (max-width: 480px) {
    .post-header-section,
    .service-header-section {
        padding: 20px 0 10px;
    }
    
    .post-content-section,
    .service-content-section {
        padding: 40px 0;
    }
    
    .post-title,
    .service-title {
        font-size: 1.8rem;
    }
    
    .featured-image-wrapper {
        margin: 20px 0;
    }
    
    .author-box,
    .related-posts,
    .related-services,
    .sidebar-categories,
    .contact-card {
        padding: 20px;
    }
    
    .service-details {
        padding: 20px;
    }
    
    .service-cta {
        padding: 30px 20px;
    }
    
    .nav-previous,
    .nav-next {
        padding: 20px;
    }
} 