/* ========================================
   Single Post Page Additional Styles
   Progress Bar, Back to Top, Similar Posts, Comments
   ======================================== */

/* Progress Bar (fixed at top) */
.progress-bar {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
    z-index: 9999;
    width: 0%;
    transition: width 0.1s linear;
}

/* Back to Top Circular Button */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 1000;
    cursor: pointer;
    width: 50px;
    height: 50px;
    display: none;
    background: rgba(20, 20, 30, 0.8);
    border-radius: 50%;
    backdrop-filter: blur(4px);
    transition: all 0.3s ease;
}
.back-to-top.visible {
    display: block;
}
.back-to-top svg {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}
.progress-circle-bg {
    fill: none;
    stroke: rgba(255,255,255,0.1);
    stroke-width: 3;
}
.progress-circle-fill {
    fill: none;
    stroke: url(#KA_progressGradient);
    stroke-width: 3;
    stroke-linecap: round;
    transition: stroke-dashoffset 0.1s linear;
}
.back-to-top .icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #fff;
    font-size: 1.2rem;
}

/* Single Post Container */
.single-post-section {
    padding: 120px 0 60px;
}
.single-post-wrapper {
    max-width: 800px;
    margin: 0 auto;
}
.single-post .post-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    color: var(--text-muted);
    font-size: 0.85rem;
    margin-bottom: 24px;
    flex-wrap: wrap;
}
.single-post .post-title {
    font-size: 2.4rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin-bottom: 20px;
}
.single-post .post-thumbnail {
    margin: 20px 0 30px;
}
.single-post .post-thumbnail img {
    width: 100%;
    border-radius: 12px;
}
.single-post .post-content {
    font-size: 1.05rem;
    line-height: 1.8;
    color: var(--text-muted);
}
.single-post .post-content p {
    margin-bottom: 20px;
}
.post-footer {
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
}
.post-taxonomies {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 20px;
}
.post-categories-list,
.post-tags-list {
    font-size: 0.85rem;
}
.tax-label {
    color: var(--text-white);
    margin-right: 8px;
}
.post-share {
    display: flex;
    gap: 12px;
    align-items: center;
}
.post-share a {
    color: var(--text-muted);
    transition: color 0.2s;
}
.post-share a:hover {
    color: var(--primary-light);
}
.author-bio-box {
    display: flex;
    gap: 24px;
    background: var(--bg-secondary);
    padding: 24px;
    border-radius: 16px;
    margin: 40px 0;
}
.author-avatar img {
    width: 70px;
    height: 70px;
    border-radius: 50%;
}
.author-info h4 {
    margin-bottom: 8px;
}
.author-info p {
    font-size: 0.9rem;
    color: var(--text-muted);
}
.author-archive-link {
    display: inline-block;
    margin-top: 10px;
    font-size: 0.85rem;
    color: var(--primary-light);
}
.post-navigation {
    display: flex;
    justify-content: space-between;
    margin: 40px 0 50px;
}
.nav-previous a,
.nav-next a {
    color: var(--primary-light);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
}
.nav-previous a:hover,
.nav-next a:hover {
    gap: 12px;
}

/* Similar Posts */
.similar-posts {
    margin-top: 50px;
}
.similar-posts h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 24px;
}
.similar-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
}
.similar-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.2s;
}
.similar-card:hover {
    transform: translateY(-4px);
    border-color: var(--primary);
}
.similar-card img {
    width: 100%;
    aspect-ratio: 16/9;
    object-fit: cover;
}
.similar-card .card-body {
    padding: 16px;
}
.similar-card h4 {
    font-size: 1rem;
    margin-bottom: 8px;
}
.similar-card h4 a {
    color: white;
    text-decoration: none;
}
.similar-card p {
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* Comments Section */
.comments-section {
    margin-top: 60px;
}
.comments-section h3 {
    font-size: 1.5rem;
    margin-bottom: 24px;
}
.comment-list {
    list-style: none;
    margin-bottom: 40px;
}
.comment {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
}
.comment-body {
    color: var(--text-muted);
    line-height: 1.6;
}
.comment-meta {
    margin-bottom: 10px;
    font-size: 0.85rem;
}
.comment-author {
    font-weight: 700;
    color: white;
}
.comment-time {
    color: var(--text-muted);
    margin-left: 12px;
}
.reply-link {
    margin-top: 10px;
    display: inline-block;
    font-size: 0.8rem;
}
.comment-respond {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 24px;
    margin-top: 30px;
}
.comment-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}
.comment-form input,
.comment-form textarea {
    background: var(--bg-primary);
    border: 1px solid var(--border);
    padding: 12px;
    border-radius: 8px;
    color: white;
    width: 100%;
}
.comment-form .form-submit {
    margin-top: 10px;
}
.comment-form .submit {
    background: var(--primary);
    color: white;
    border: none;
    padding: 10px 24px;
    border-radius: 40px;
    cursor: pointer;
    transition: background 0.2s;
}
.comment-form .submit:hover {
    background: var(--primary-dark);
}
.emoji-picker {
    position: relative;
    margin-top: 10px;
}
.emoji-btn {
    background: none;
    border: none;
    font-size: 1.3rem;
    cursor: pointer;
    color: var(--text-muted);
}
.emoji-grid {
    position: absolute;
    bottom: 40px;
    left: 0;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 8px;
    display: none;
    grid-template-columns: repeat(6, 30px);
    gap: 5px;
    z-index: 100;
}
.emoji-grid.active {
    display: grid;
}
.emoji-grid button {
    background: none;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    padding: 5px;
}