/* ============================================================
   Trang tin tức — chi tiết bài viết (Design System)
   File: public/client/css/tin-tuc.css
   Áp dụng cho mọi trang /tin-tuc/*
   Palette đồng bộ với phần Công cụ — primary #1a73e8 / Material
   ============================================================ */

:root {
    --tt-primary: #1a73e8;
    --tt-primary-dark: #1557b0;
    --tt-primary-soft: #e8f0fe;
    --tt-primary-tint: #f0f6ff;
    --tt-text: #202124;
    --tt-text-strong: #0f1419;
    --tt-text-muted: #5f6368;
    --tt-text-light: #80868b;
    --tt-border: #e8eaed;
    --tt-border-soft: #f1f3f4;
    --tt-border-strong: #dadce0;
    --tt-panel: #f8fafc;
    --tt-panel-2: #f8f9fa;
    --tt-shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.08);
    --tt-shadow-md: 0 2px 6px rgba(15, 23, 42, 0.10);
    --tt-shadow-lg: 0 6px 18px rgba(15, 23, 42, 0.10);
    --tt-radius-sm: 6px;
    --tt-radius: 8px;
    --tt-radius-lg: 12px;
    --tt-radius-pill: 999px;
    --tt-content-max: 760px;
    --tt-page-max: 1200px;
}

/* ============================================================
   Reading progress bar (fixed top)
   ============================================================ */
.tt-progress-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: transparent;
    z-index: 9999;
    pointer-events: none;
}

.tt-progress-bar__fill {
    display: block;
    height: 100%;
    width: 0;
    background: linear-gradient(90deg, var(--tt-primary), #4285f4);
    transition: width 0.08s linear;
    box-shadow: 0 0 8px rgba(26, 115, 232, 0.4);
}

/* ============================================================
   Hero (cover image + breadcrumb + title + meta)
   ============================================================ */
.tt-hero {
    position: relative;
    width: 100%;
    min-height: 360px;
    overflow: hidden;
    color: #fff;
    background: #1a1a1a;
    isolation: isolate;
}

.tt-hero__media {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.tt-hero__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    filter: brightness(0.85);
}

.tt-hero__overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    background:
        linear-gradient(180deg, rgba(0, 0, 0, 0.15) 0%, rgba(0, 0, 0, 0.55) 60%, rgba(0, 0, 0, 0.85) 100%),
        linear-gradient(135deg, rgba(26, 115, 232, 0.35) 0%, rgba(0, 0, 0, 0) 60%);
}

.tt-hero__inner {
    position: relative;
    z-index: 2;
    max-width: var(--tt-page-max);
    margin: 0 auto;
    padding: 32px 24px 28px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    min-height: 360px;
}

.tt-hero__breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    margin-bottom: 16px;
}

.tt-hero__breadcrumb a {
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    transition: color 0.2s;
}

.tt-hero__breadcrumb a:hover {
    color: #fff;
    text-decoration: underline;
}

.tt-hero__breadcrumb-sep {
    color: rgba(255, 255, 255, 0.5);
}

.tt-hero__breadcrumb-current {
    color: #fff;
    font-weight: 500;
    max-width: 360px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.tt-hero__category {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--tt-primary);
    color: #fff;
    padding: 4px 12px;
    border-radius: var(--tt-radius-pill);
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    text-decoration: none;
    margin-bottom: 14px;
    align-self: flex-start;
    transition: background 0.2s;
}

.tt-hero__category:hover {
    background: var(--tt-primary-dark);
    color: #fff;
}

.tt-hero__title {
    font-size: 38px;
    font-weight: 700;
    line-height: 1.25;
    color: #fff;
    margin: 0 0 18px 0;
    letter-spacing: -0.01em;
    max-width: 920px;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.35);
}

.tt-hero__meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 18px;
    color: rgba(255, 255, 255, 0.92);
    font-size: 14px;
}

.tt-hero__meta-item {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.tt-hero__meta-item i {
    font-size: 13px;
    opacity: 0.8;
}

.tt-hero__author {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.tt-hero__avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--tt-primary) 0%, #4285f4 100%);
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 13px;
    border: 2px solid rgba(255, 255, 255, 0.4);
}

.tt-hero__author-name {
    font-weight: 500;
}

/* Hero variant — không có cover */
.tt-hero--no-image {
    background:
        radial-gradient(circle at 20% 20%, rgba(26, 115, 232, 0.2) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(66, 133, 244, 0.15) 0%, transparent 50%),
        linear-gradient(135deg, #1a1a1a 0%, #2c2c2c 100%);
    min-height: 280px;
}

.tt-hero--no-image .tt-hero__inner {
    min-height: 280px;
}

/* ============================================================
   Page layout (3-col: rail | main | sidebar)
   ============================================================ */
.tt-article-page {
    max-width: var(--tt-page-max);
    margin: 0 auto;
    padding: 32px 24px 48px;
    display: grid;
    grid-template-columns: 1fr;
    gap: 32px;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
}

@media (min-width: 992px) {
    .tt-article-page {
        grid-template-columns: minmax(0, 1fr) 300px;
        gap: 36px;
        align-items: start;
    }
}

@media (min-width: 1200px) {
    .tt-article-page {
        grid-template-columns: 56px minmax(0, 1fr) 300px;
        gap: 28px;
    }
}

/* ============================================================
   Share rail (vertical, sticky, desktop XL only)
   ============================================================ */
.tt-share-rail {
    position: sticky;
    top: 90px;
    align-self: start;
}

.tt-share-rail .tt-share-bar--vertical {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 12px 6px;
    background: #fff;
    border: 1px solid var(--tt-border);
    border-radius: var(--tt-radius);
    box-shadow: var(--tt-shadow-sm);
}

.tt-share-bar__label {
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--tt-text-muted);
    text-align: center;
    margin-bottom: 4px;
}

.tt-share-btn {
    width: 40px;
    height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--tt-panel-2);
    border: 1px solid var(--tt-border);
    color: var(--tt-text-muted);
    font-size: 15px;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.18s ease;
}

.tt-share-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--tt-shadow-md);
    color: #fff;
}

.tt-share-btn--fb:hover    { background: #1877f2; border-color: #1877f2; }
.tt-share-btn--x:hover     { background: #000;    border-color: #000;    }
.tt-share-btn--in:hover    { background: #0a66c2; border-color: #0a66c2; }
.tt-share-btn--copy:hover  { background: var(--tt-primary); border-color: var(--tt-primary); }
.tt-share-btn--print:hover { background: #5f6368; border-color: #5f6368; }

/* Share bar — horizontal (mobile / tablet / desktop ≤ xl) */
.tt-share-bar--horizontal {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    margin: 0 0 24px 0;
    background: var(--tt-panel-2);
    border: 1px solid var(--tt-border);
    border-radius: var(--tt-radius);
}

.tt-share-bar--horizontal .tt-share-bar__label {
    text-align: left;
    margin: 0;
    margin-right: auto;
}

@media (min-width: 1200px) {
    .tt-share-bar--horizontal {
        display: none;
    }
}

@media (max-width: 1199.98px) {
    .tt-share-rail {
        display: none !important;
    }
}

/* Toast cho copy link */
.tt-toast {
    position: fixed;
    bottom: 90px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: #202124;
    color: #fff;
    padding: 10px 20px;
    border-radius: var(--tt-radius);
    font-size: 14px;
    box-shadow: var(--tt-shadow-lg);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease, transform 0.25s ease;
    z-index: 9998;
}

.tt-toast.is-show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* ============================================================
   Article main column
   ============================================================ */
.tt-article-main {
    min-width: 0;
}

.tt-excerpt {
    font-size: 17px;
    line-height: 1.65;
    color: var(--tt-text-muted);
    padding: 16px 20px;
    background: var(--tt-primary-tint);
    border-left: 4px solid var(--tt-primary);
    border-radius: 4px 8px 8px 4px;
    margin: 0 0 28px 0;
    font-style: italic;
}

/* ============================================================
   Table of Contents
   ============================================================ */
.tt-toc {
    border: 1px solid var(--tt-border);
    background: #fff;
    border-radius: var(--tt-radius);
    margin: 0 0 32px 0;
    overflow: hidden;
}

.tt-toc__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    background: var(--tt-panel-2);
    border-bottom: 1px solid var(--tt-border);
    cursor: pointer;
    user-select: none;
}

.tt-toc__title {
    font-size: 14px;
    font-weight: 600;
    color: var(--tt-text);
    margin: 0;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.tt-toc__title i {
    color: var(--tt-primary);
}

.tt-toc__toggle {
    background: none;
    border: 0;
    color: var(--tt-text-muted);
    font-size: 14px;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 4px;
    transition: background 0.15s;
}

.tt-toc__toggle:hover {
    background: var(--tt-border-soft);
}

.tt-toc__toggle i {
    transition: transform 0.25s ease;
}

.tt-toc.is-collapsed .tt-toc__toggle i {
    transform: rotate(-90deg);
}

.tt-toc__body {
    max-height: 480px;
    overflow-y: auto;
    transition: max-height 0.3s ease;
}

.tt-toc.is-collapsed .tt-toc__body {
    max-height: 0;
    overflow: hidden;
}

.tt-toc__list {
    list-style: none;
    padding: 12px 0;
    margin: 0;
    counter-reset: tt-toc-num;
}

.tt-toc__item {
    margin: 0;
    padding: 0;
}

.tt-toc__link {
    display: block;
    padding: 6px 18px 6px 18px;
    font-size: 14px;
    line-height: 1.5;
    color: var(--tt-text);
    text-decoration: none;
    border-left: 3px solid transparent;
    transition: all 0.18s ease;
}

.tt-toc__link:hover {
    color: var(--tt-primary);
    background: var(--tt-primary-tint);
    border-left-color: var(--tt-primary-soft);
    text-decoration: none;
}

.tt-toc__link.is-active {
    color: var(--tt-primary);
    background: var(--tt-primary-tint);
    border-left-color: var(--tt-primary);
    font-weight: 500;
}

.tt-toc__item--lvl-2 .tt-toc__link { padding-left: 36px; font-size: 13.5px; color: var(--tt-text-muted); }
.tt-toc__item--lvl-3 .tt-toc__link { padding-left: 54px; font-size: 13px;   color: var(--tt-text-muted); }
.tt-toc__item--lvl-4 .tt-toc__link { padding-left: 72px; font-size: 12.5px; color: var(--tt-text-light); }

/* ============================================================
   Article body — typography
   ============================================================ */
.tt-article-body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
    font-size: 16.5px;
    line-height: 1.8;
    color: var(--tt-text);
    word-wrap: break-word;
}

.tt-article-body > *:first-child {
    margin-top: 0;
}

.tt-article-body p {
    margin: 0 0 18px 0;
    text-align: justify;
}

.tt-article-body p:empty,
.tt-article-body p > br:only-child {
    display: none;
}

.tt-article-body h1,
.tt-article-body h2,
.tt-article-body h3,
.tt-article-body h4,
.tt-article-body h5,
.tt-article-body h6 {
    font-weight: 700;
    color: var(--tt-text-strong);
    margin: 36px 0 16px 0;
    line-height: 1.35;
    scroll-margin-top: 90px;
    letter-spacing: -0.01em;
}

.tt-article-body h1 { font-size: 28px; }
.tt-article-body h2 {
    font-size: 24px;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--tt-border);
}
.tt-article-body h3 { font-size: 20px; }
.tt-article-body h4 { font-size: 17px; color: var(--tt-primary); }
.tt-article-body h5 { font-size: 15px; }
.tt-article-body h6 { font-size: 14px; text-transform: uppercase; letter-spacing: 0.05em; color: var(--tt-text-muted); }

.tt-article-body strong,
.tt-article-body b {
    font-weight: 700;
    color: var(--tt-text-strong);
}

.tt-article-body em,
.tt-article-body i {
    font-style: italic;
}

.tt-article-body a {
    color: var(--tt-primary);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color 0.18s ease, color 0.18s ease;
}

.tt-article-body a:hover {
    color: var(--tt-primary-dark);
    border-bottom-color: var(--tt-primary-dark);
}

.tt-article-body ul,
.tt-article-body ol {
    margin: 0 0 20px 0;
    padding-left: 28px;
}

.tt-article-body li {
    margin-bottom: 8px;
    line-height: 1.75;
}

.tt-article-body ul li::marker {
    color: var(--tt-primary);
}

.tt-article-body ol li::marker {
    color: var(--tt-primary);
    font-weight: 600;
}

.tt-article-body blockquote {
    margin: 24px 0;
    padding: 16px 20px;
    background: var(--tt-primary-tint);
    border-left: 4px solid var(--tt-primary);
    border-radius: 4px 8px 8px 4px;
    font-style: italic;
    color: var(--tt-text);
    position: relative;
}

.tt-article-body blockquote::before {
    content: "\201C";
    position: absolute;
    top: -8px;
    left: 12px;
    font-size: 56px;
    line-height: 1;
    color: var(--tt-primary);
    opacity: 0.18;
    font-family: Georgia, serif;
}

.tt-article-body blockquote p:last-child { margin-bottom: 0; }

.tt-article-body img {
    max-width: 100%;
    height: auto;
    border-radius: var(--tt-radius);
    margin: 16px auto;
    display: block;
    box-shadow: var(--tt-shadow-sm);
}

.tt-article-body figure {
    margin: 24px 0;
    text-align: center;
}

.tt-article-body figcaption {
    font-size: 13px;
    color: var(--tt-text-muted);
    font-style: italic;
    margin-top: 8px;
}

.tt-article-body code {
    background: var(--tt-panel-2);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.92em;
    font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
    color: #d63384;
    border: 1px solid var(--tt-border);
}

.tt-article-body pre {
    background: #0f1419;
    color: #e8eaed;
    padding: 16px 20px;
    border-radius: var(--tt-radius);
    overflow-x: auto;
    margin: 20px 0;
    font-size: 14px;
    line-height: 1.6;
}

.tt-article-body pre code {
    background: transparent;
    color: inherit;
    border: 0;
    padding: 0;
}

.tt-article-body hr {
    border: 0;
    height: 1px;
    background: var(--tt-border);
    margin: 36px 0;
}

/* Tables */
.tt-article-body table {
    width: 100%;
    border-collapse: collapse;
    margin: 24px 0;
    font-size: 14.5px;
    border: 1px solid var(--tt-border);
    border-radius: var(--tt-radius);
    overflow: hidden;
    box-shadow: var(--tt-shadow-sm);
}

.tt-article-body table thead {
    background: var(--tt-panel-2);
}

.tt-article-body table th {
    padding: 12px 14px;
    text-align: left;
    font-weight: 600;
    color: var(--tt-text-strong);
    border-bottom: 2px solid var(--tt-border-strong);
    background: var(--tt-panel-2);
}

.tt-article-body table td {
    padding: 12px 14px;
    border-bottom: 1px solid var(--tt-border);
    vertical-align: top;
}

.tt-article-body table tr:last-child td {
    border-bottom: 0;
}

.tt-article-body table tr:hover td {
    background: var(--tt-panel-2);
}

/* Drop cap cho paragraph đầu tiên */
.tt-article-body > p:first-of-type::first-letter {
    float: left;
    font-size: 52px;
    line-height: 0.95;
    font-weight: 700;
    color: var(--tt-primary);
    margin: 4px 10px 0 0;
    font-family: Georgia, serif;
}

/* Print friendly */
@media print {
    .tt-progress-bar,
    .tt-share-rail,
    .tt-share-bar--horizontal,
    .tt-back-to-top,
    .tt-toc__toggle,
    .tt-sidebar,
    .tt-related,
    .tt-rating {
        display: none !important;
    }

    .tt-hero {
        min-height: auto;
        background: none;
        color: #000;
    }

    .tt-hero__media,
    .tt-hero__overlay {
        display: none !important;
    }

    .tt-hero__title,
    .tt-hero__breadcrumb,
    .tt-hero__breadcrumb a,
    .tt-hero__meta {
        color: #000 !important;
        text-shadow: none !important;
    }

    .tt-article-page {
        display: block;
    }
}

/* ============================================================
   Tag chips
   ============================================================ */
.tt-tag-chips {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin: 32px 0 0 0;
    padding-top: 24px;
    border-top: 1px solid var(--tt-border);
}

.tt-tag-chips__label {
    font-size: 13px;
    font-weight: 600;
    color: var(--tt-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-right: 4px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.tt-tag-chip {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 6px 14px;
    background: var(--tt-panel-2);
    color: var(--tt-text);
    border: 1px solid var(--tt-border);
    border-radius: var(--tt-radius-pill);
    font-size: 13px;
    text-decoration: none;
    transition: all 0.18s ease;
}

.tt-tag-chip:hover {
    background: var(--tt-primary-soft);
    color: var(--tt-primary);
    border-color: var(--tt-primary-soft);
    transform: translateY(-1px);
}

/* ============================================================
   Rating widget (giữ markup kksr-* cũ)
   ============================================================ */
.tt-rating {
    margin: 32px 0;
    padding: 16px 20px;
    background: var(--tt-panel-2);
    border: 1px solid var(--tt-border);
    border-radius: var(--tt-radius);
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
}

.tt-rating .kksr-stars {
    display: inline-flex;
    gap: 4px;
}

.tt-rating .kksr-stars-inactive {
    display: inline-flex;
    gap: 4px;
}

.tt-rating .kksr-star {
    color: #f9ab00;
    font-size: 18px;
}

.tt-rating .kksr-legend {
    font-size: 14px;
    color: var(--tt-text-muted);
}

.tt-rating .kksr-score,
.tt-rating .kksr-count {
    color: var(--tt-text);
    font-weight: 600;
}

.tt-rating .kksr-muted {
    color: var(--tt-text-light);
}

/* ============================================================
   Author card
   ============================================================ */
.tt-author-card {
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 20px;
    margin: 36px 0;
    background: linear-gradient(135deg, var(--tt-primary-tint) 0%, #ffffff 60%);
    border: 1px solid var(--tt-border);
    border-radius: var(--tt-radius-lg);
}

.tt-author-card__avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--tt-primary) 0%, #4285f4 100%);
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: 600;
    flex-shrink: 0;
    border: 3px solid #fff;
    box-shadow: var(--tt-shadow-sm);
}

.tt-author-card__body {
    min-width: 0;
}

.tt-author-card__role {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--tt-primary);
    margin-bottom: 4px;
}

.tt-author-card__name {
    font-size: 18px;
    font-weight: 600;
    color: var(--tt-text-strong);
    margin: 0 0 4px 0;
}

.tt-author-card__bio {
    font-size: 14px;
    color: var(--tt-text-muted);
    margin: 0;
    line-height: 1.55;
}

/* ============================================================
   Related posts grid
   ============================================================ */
.tt-related {
    margin-top: 48px;
    padding-top: 32px;
    border-top: 2px solid var(--tt-border);
}

.tt-related__title {
    font-size: 22px;
    font-weight: 700;
    color: var(--tt-text-strong);
    margin: 0 0 20px 0;
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.tt-related__title::before {
    content: "";
    width: 4px;
    height: 22px;
    background: var(--tt-primary);
    border-radius: 2px;
}

.tt-related__grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 18px;
}

@media (min-width: 600px) {
    .tt-related__grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 992px) {
    .tt-related__grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.tt-related__card {
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid var(--tt-border);
    border-radius: var(--tt-radius-lg);
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
    height: 100%;
}

.tt-related__card:hover {
    transform: translateY(-4px);
    box-shadow: var(--tt-shadow-lg);
    border-color: var(--tt-primary-soft);
    text-decoration: none;
    color: inherit;
}

.tt-related__thumb {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: var(--tt-panel-2);
}

.tt-related__thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.45s ease;
}

.tt-related__card:hover .tt-related__thumb img {
    transform: scale(1.06);
}

.tt-related__body {
    padding: 16px 18px 18px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.tt-related__heading {
    font-size: 15.5px;
    font-weight: 600;
    line-height: 1.4;
    color: var(--tt-text-strong);
    margin: 0 0 8px 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    line-clamp: 2;
    overflow: hidden;
    transition: color 0.18s ease;
}

.tt-related__card:hover .tt-related__heading {
    color: var(--tt-primary);
}

.tt-related__excerpt {
    font-size: 13.5px;
    line-height: 1.55;
    color: var(--tt-text-muted);
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    line-clamp: 2;
    overflow: hidden;
}

/* ============================================================
   Sidebar (sticky desktop)
   ============================================================ */
.tt-sidebar {
    min-width: 0;
}

@media (min-width: 992px) {
    .tt-sidebar {
        position: sticky;
        top: 90px;
        align-self: start;
        max-height: calc(100vh - 110px);
        overflow-y: auto;
        padding-right: 4px;
    }

    .tt-sidebar::-webkit-scrollbar {
        width: 6px;
    }
    .tt-sidebar::-webkit-scrollbar-thumb {
        background: var(--tt-border-strong);
        border-radius: 3px;
    }
}

/* Override scope cho component left-sidebar-menu khi nằm trong tt-sidebar */
.tt-sidebar .gc-sidebar-menu {
    background: #fff;
    border: 1px solid var(--tt-border);
    border-radius: var(--tt-radius-lg);
    padding: 16px;
    margin-bottom: 16px;
    box-shadow: var(--tt-shadow-sm);
}

.tt-sidebar .gc-sidebar-title {
    display: block;
    font-size: 14px;
    font-weight: 700;
    color: var(--tt-text-strong);
    background: transparent;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin: 0 0 12px 0;
    padding: 0 0 10px 0;
    border: 0;
    border-bottom: 2px solid var(--tt-primary);
    box-shadow: none;
    width: max-content;
    max-width: 100%;
}

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

.tt-sidebar .gc-sidebar-item {
    margin: 0;
}

.tt-sidebar .gc-sidebar-link {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 8px;
    padding: 8px 0;
    color: var(--tt-text);
    text-decoration: none;
    font-size: 13.5px;
    line-height: 1.5;
    border-bottom: 1px dashed var(--tt-border-soft);
    transition: color 0.18s ease;
}

.tt-sidebar .gc-sidebar-item:last-child .gc-sidebar-link {
    border-bottom: 0;
}

.tt-sidebar .gc-sidebar-link:hover {
    color: var(--tt-primary);
}

.tt-sidebar .gc-sidebar-link:hover .gc-sidebar-text {
    text-decoration: underline;
}

.tt-sidebar .gc-sidebar-text {
    flex: 1;
    min-width: 0;
}

.tt-sidebar .gc-sidebar-badge {
    flex-shrink: 0;
    background: var(--tt-primary-soft);
    color: var(--tt-primary);
    font-size: 11px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: var(--tt-radius-pill);
}

/* ============================================================
   Back-to-top FAB
   ============================================================ */
.tt-back-to-top {
    position: fixed;
    right: 24px;
    bottom: 24px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--tt-primary);
    color: #fff;
    border: 0;
    box-shadow: var(--tt-shadow-md);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(12px);
    transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s, background 0.18s;
    z-index: 1000;
}

.tt-back-to-top.is-show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.tt-back-to-top:hover {
    background: var(--tt-primary-dark);
    box-shadow: var(--tt-shadow-lg);
    transform: translateY(-2px);
}

/* ============================================================
   Responsive — mobile / tablet
   ============================================================ */
@media (max-width: 991.98px) {
    .tt-hero {
        min-height: 280px;
    }
    .tt-hero__inner {
        min-height: 280px;
        padding: 24px 18px 22px;
    }
    .tt-hero__title {
        font-size: 28px;
    }
    .tt-hero__meta {
        gap: 12px;
        font-size: 13px;
    }
    .tt-hero__breadcrumb-current {
        max-width: 220px;
    }

    .tt-article-page {
        padding: 24px 16px 36px;
        gap: 24px;
    }

    .tt-article-body {
        font-size: 15.5px;
        line-height: 1.75;
    }

    .tt-article-body h1 { font-size: 24px; }
    .tt-article-body h2 { font-size: 20px; }
    .tt-article-body h3 { font-size: 18px; }
}

@media (max-width: 575.98px) {
    .tt-hero__title {
        font-size: 22px;
        line-height: 1.3;
    }
    .tt-hero__meta {
        gap: 10px;
        font-size: 12.5px;
    }

    .tt-share-bar--horizontal {
        gap: 6px;
        padding: 10px 12px;
    }
    .tt-share-btn {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }

    .tt-author-card {
        flex-direction: column;
        text-align: center;
    }

    .tt-back-to-top {
        right: 16px;
        bottom: 16px;
    }

    .tt-article-body {
        text-align: left;
    }
    .tt-article-body p {
        text-align: left;
    }

    .tt-article-body > p:first-of-type::first-letter {
        font-size: 42px;
    }
}
