/* Post Category & Sidebar Premium Styles */

.post-item {
    transition: all 0.3s ease;
    padding: 15px 0;
}

.post-item:hover {
    background-color: #fcfcfc;
}

.post-item-image img {
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.post-item:hover .post-item-image img {
    transform: scale(1.02);
}

.post-item-title {
    font-family: 'Oswald', sans-serif;
    color: var(--mainColor);
    font-weight: 600;
    margin-top: 5px;
}

.post-item-title-link:hover .post-item-title {
    color: var(--subColor);
}

.post-item-meta {
    color: #888;
    font-size: 0.9rem;
}

.post-item-excerpt {
    color: #555;
    line-height: 1.6;
}

/* Sidebar Styling */
.sidebar-navigation {
    border-radius: 0;
    overflow: hidden;
    border: 1px solid #f0f0f0;
}

.sidebar-title {
    background-color: var(--mainColor);
    color: #fff;
    padding: 12px 15px;
    margin-bottom: 0;
    font-family: 'Oswald', sans-serif;
    font-size: 1.1rem;
    text-transform: uppercase;
    position: relative;
}

.sidebar-title:after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 15px;
    width: 40px;
    height: 3px;
    background-color: var(--hoverColor);
}

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

.sidebar-menu li {
    border-bottom: 1px solid #f9f9f9;
}

.sidebar-menu li:last-child {
    border-bottom: none;
}

.sidebar-menu li a {
    display: block;
    padding: 10px 15px;
    color: #444;
    transition: all 0.2s ease;
    font-weight: 500;
}

.sidebar-menu li a:hover {
    background-color: #f8f9fa;
    color: var(--mainColor);
    padding-left: 20px;
}

/* Sidebar Recent Posts */
.sidebar-post {
    padding: 12px 15px;
}

.sidebar-post-link {
    display: flex;
    gap: 12px;
    align-items: center;
}

.sidebar-post-thumb {
    border-radius: 4px;
    object-fit: cover;
    flex-shrink: 0;
}

.sidebar-post-title {
    font-size: 0.95rem;
    line-height: 1.4;
    color: #333;
    font-weight: 500;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.sidebar-post-link:hover .sidebar-post-title {
    color: var(--mainColor);
}

/* Sidebar Search Box */
.box-search-sidebar {
    border-radius: 0;
    overflow: hidden;
    border: 1px solid #f0f0f0;
}

.box-search-sidebar .input-group {
    background: #fff;
}

.box-search-sidebar input {
    border: none;
    padding: 12px 15px;
    font-size: 0.95rem;
}

.box-search-sidebar input:focus {
    box-shadow: none;
}

.box-search-sidebar .btn {
    border: none;
    background: var(--mainColor);
    color: #fff;
    padding: 0 20px;
    clip-path: polygon(8px 0%, 100% 0%, 100% 100%, 0% 100%);
}

/* Contact Form Sidebar */
.contact-form-sidebar {
    padding: 15px;
}

.contact-form-sidebar .form-control {
    border-radius: 4px;
    border: 1px solid #eee;
    padding: 10px;
    font-size: 0.9rem;
}

/* Post Detail Page */
.post-detail-title {
    font-family: 'Oswald', sans-serif;
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--textColor);
    line-height: 1.3;
}

.post-detail-meta {
    font-size: 0.95rem;
    border-bottom: 1px solid #eee;
    padding-bottom: 15px;
}

.post-detail-banner {
    position: relative;
    overflow: hidden;
    clip-path: polygon(0 0, 100% 0, 100% calc(100% - 30px), calc(100% - 30px) 100%, 0 100%);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.post-detail-banner img {
    transition: transform 0.5s ease;
}

.post-detail-banner:hover img {
    transform: scale(1.03);
}

.post-detail-content {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #333;
}

.post-detail-content h2,
.post-detail-content h3 {
    font-family: 'Oswald', sans-serif;
    margin-top: 30px;
    margin-bottom: 15px;
    color: var(--mainColor);
}

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

/* TOC Styling */
.toc-wrapper {
    background: #f8f9fa;
    border: 1px solid #eee;
    margin-bottom: 30px;
    border-left: 4px solid var(--mainColor);
}

.toc-header {
    background: #eee;
    padding: 10px 15px;
    font-weight: 700;
    font-family: 'Oswald', sans-serif;
    text-transform: uppercase;
}

.toc-body {
    padding: 15px;
}

.toc-body ul {
    list-style: none;
    padding-left: 0;
    margin-bottom: 0;
}

.toc-body ul li {
    margin-bottom: 8px;
}

.toc-body ul li a {
    color: #555;
    text-decoration: none;
    transition: all 0.2s;
}

.toc-body ul li a:hover {
    color: var(--mainColor);
    padding-left: 5px;
}

/* Related Posts */
.section-title-premium {
    font-family: 'Oswald', sans-serif;
    font-size: 1.8rem;
    text-transform: uppercase;
    position: relative;
    padding-bottom: 15px;
}

.section-title-premium:after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 4px;
    background: var(--subColor);
    clip-path: polygon(0 0, 100% 0, 85% 100%, 0 100%);
}

.related-post-item {
    background: #fff;
    transition: transform 0.3s;
    height: 100%;
}

.related-post-item:hover {
    transform: translateY(-5px);
}

.related-thumb {
    aspect-ratio: 16/10;
    overflow: hidden;
    clip-path: polygon(0 0, 100% 0, 100% calc(100% - 15px), calc(100% - 15px) 100%, 0 100%);
}

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

.related-title {
    font-size: 1rem;
    font-weight: 600;
    color: #333;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.contact-form-sidebar .btn-primary {
    background-color: var(--mainColor);
    border: none;
    font-weight: bold;
    text-transform: uppercase;
    font-family: 'Oswald', sans-serif;
    padding: 10px;
    max-width: none;
    /* Phủ định max-width 150px từ style.css */
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 0;
    clip-path: polygon(8px 0%, 100% 0%, calc(100% - 8px) 100%, 0% 100%);
    position: relative;
    overflow: hidden;
}

.contact-form-sidebar .btn-primary span {
    position: relative;
    z-index: 2;
}