:root {
    --primary: #0A66C2;
    --secondary: #00D4FF;
    --bg: #F5F9FC;
    --text: #1E293B;
    --heading: #071827;
    --header-bg: #FFFFFF;
    --footer-bg: #071827;
    --white: #fff;
    --muted: #64748B;
    --border: #E2E8F0;
    --soft: #EFF6FF;
    --shadow: 0 18px 45px rgba(15, 23, 42, .08);
    --shadow-hover: 0 24px 60px rgba(15, 23, 42, .14);
    --radius: 24px
}

* {
    box-sizing: border-box
}

html {
    scroll-behavior: smooth
}

body {
    margin: 0;
    font-family: "Be Vietnam Pro", Arial, Helvetica, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.7;
    font-size: 16px
}

a {
    color: inherit;
    text-decoration: none;
    transition: .2s ease
}

a:hover {
    color: var(--primary)
}

img {
    display: block;
    max-width: 100%;
    height: auto
}

.container {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 999;
    background: var(--header-bg);
    border-bottom: 1px solid rgba(226, 232, 240, .9);
    box-shadow: 0 8px 28px rgba(15, 23, 42, .04)
}

.header-inner {
    min-height: 78px;
    display: flex;
    align-items: center;
    gap: 24px
}

.site-logo a {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--heading);
    font-weight: 800
}

.logo-icon {
    width: 44px;
    height: 44px;
    border-radius: 15px;
    display: grid;
    place-items: center;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: #fff;
    font-size: 22px;
    box-shadow: 0 12px 28px rgba(10, 102, 194, .22)
}

.logo-text {
    font-size: 23px;
    letter-spacing: -.5px
}

.custom-logo-img {
    max-height: 85px;
    width: auto;
    object-fit: contain;
}

.main-navigation {
    flex: 1
}

.main-menu {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 26px;
    list-style: none;
    margin: 0;
    padding: 0
}

.main-menu li {
    position: relative
}

.main-menu a {
    color: var(--heading);
    font-weight: 700;
    font-size: 15px
}

.main-menu a:hover {
    color: var(--primary)
}

.main-menu .sub-menu {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 220px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 16px;
    box-shadow: var(--shadow);
    list-style: none;
    padding: 10px;
    margin: 7px 0 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: .2s ease
}

.main-menu li:hover>.sub-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0)
}

.main-menu .sub-menu a {
    display: block;
    padding: 9px 10px;
    border-radius: 10px
}

.main-menu .sub-menu a:hover {
    background: var(--soft)
}

.header-search form {
    display: flex;
    align-items: center;
    background: #f8fafc;
    border: 1px solid var(--border);
    border-radius: 999px;
    overflow: hidden
}

.header-search input {
    border: 0;
    outline: 0;
    background: transparent;
    padding: 11px 14px;
    width: 180px;
    color: var(--text)
}

.header-search button {
    border: 0;
    background: var(--primary);
    color: #fff;
    padding: 11px 15px;
    cursor: pointer;
    font-weight: 700
}

.header-cta a {
    display: inline-flex;
    padding: 11px 18px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: #fff;
    font-weight: 800;
    white-space: nowrap;
    box-shadow: 0 10px 24px rgba(10, 102, 194, .22)
}

.header-cta a:hover {
    color: #fff;
    transform: translateY(-1px)
}

.menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 12px;
    background: var(--primary);
    cursor: pointer;
    padding: 10px
}

.menu-toggle span {
    display: block;
    height: 2px;
    background: #fff;
    margin: 5px 0;
    border-radius: 99px
}

.hero-section {
    position: relative;
    overflow: hidden;
    padding: 84px 0;
    background: radial-gradient(circle at 85% 20%, rgba(0, 212, 255, .26), transparent 30%), radial-gradient(circle at 10% 10%, rgba(10, 102, 194, .14), transparent 25%), linear-gradient(135deg, #fff, #eaf6ff)
}

.hero-section:before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: linear-gradient(rgba(10, 102, 194, .06) 1px, transparent 1px), linear-gradient(90deg, rgba(10, 102, 194, .06) 1px, transparent 1px);
    background-size: 34px 34px;
    opacity: .8
}

.hero-grid {
    position: relative;
    display: grid;
    grid-template-columns: 1.08fr .92fr;
    gap: 54px;
    align-items: center
}

.hero-badge,
.section-heading span,
.tun-widget-title span,
.archive-header span {
    display: inline-flex;
    align-items: center;
    padding: 8px 14px;
    border-radius: 999px;
    background: rgba(10, 102, 194, .1);
    color: var(--primary);
    font-weight: 800;
    font-size: 14px;
    margin-bottom: 14px
}

.archive-header span {
    color: white;
    background: rgb(255 255 255 / 19%);
}

.hero-content h1 {
    font-size: clamp(36px, 5vw, 62px);
    line-height: 1.08;
    letter-spacing: -1.6px;
    color: var(--heading);
    margin: 0 0 20px
}

.hero-content p {
    font-size: 18px;
    color: var(--muted);
    max-width: 660px;
    margin: 0 0 30px
}

.hero-actions {
    display: flex;
    gap: 14px;
    flex-wrap: wrap
}

.btn-primary,
.btn-outline {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 13px 22px;
    border-radius: 14px;
    font-weight: 800
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), #034EA2);
    color: #fff;
    box-shadow: 0 14px 30px rgba(10, 102, 194, .25)
}

.btn-primary:hover {
    color: #fff;
    transform: translateY(-2px)
}

.btn-outline {
    background: #fff;
    color: var(--primary);
    border: 1px solid rgba(10, 102, 194, .28)
}

.btn-outline:hover {
    background: var(--primary);
    color: #fff
}

/* =========================================================
   HERO CODE BOX - JS TYPING STYLE
========================================================= */

.tech-window {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(0, 212, 255, 0.12);
}

/* Ánh sáng nhẹ trong khung code */
.tech-window::after {
    content: "";
    position: absolute;
    top: -80px;
    right: -80px;
    width: 180px;
    height: 180px;
    background: radial-gradient(circle, rgba(0, 212, 255, 0.20), transparent 65%);
    pointer-events: none;
}

/* =========================================================
   HERO CODE BOX - 3 DOTS LOADING ANIMATION
========================================================= */

.tech-window-header {
    display: flex;
    align-items: center;
    gap: 9px;
}

.tech-window-header span {
    position: relative;
    width: 13px;
    height: 13px;
    border-radius: 50%;
    background: #00d4ff;
    box-shadow: 0 0 0 rgba(0, 212, 255, 0);
    animation: tunCodeDotLoadingWave 1.15s ease-in-out infinite;
}

.tech-window-header span:nth-child(1) {
    animation-delay: 0s;
}

.tech-window-header span:nth-child(2) {
    animation-delay: 0.18s;
}

.tech-window-header span:nth-child(3) {
    animation-delay: 0.36s;
}

/* Hiệu ứng vòng sáng lan ra khi chấm active */
.tech-window-header span::after {
    content: "";
    position: absolute;
    inset: -5px;
    border-radius: 50%;
    background: rgba(0, 212, 255, 0.22);
    transform: scale(0.4);
    opacity: 0;
    animation: tunCodeDotRipple 1.15s ease-in-out infinite;
}

.tech-window-header span:nth-child(1)::after {
    animation-delay: 0s;
}

.tech-window-header span:nth-child(2)::after {
    animation-delay: 0.18s;
}

.tech-window-header span:nth-child(3)::after {
    animation-delay: 0.36s;
}

@keyframes tunCodeDotLoadingWave {

    0%,
    80%,
    100% {
        transform: translateY(0) scale(0.85);
        opacity: 0.55;
        box-shadow: 0 0 0 rgba(0, 212, 255, 0);
    }

    40% {
        transform: translateY(-6px) scale(1.15);
        opacity: 1;
        box-shadow: 0 0 18px rgba(0, 212, 255, 0.75);
    }
}

@keyframes tunCodeDotRipple {
    0% {
        transform: scale(0.4);
        opacity: 0;
    }

    35% {
        transform: scale(1);
        opacity: 1;
    }

    80%,
    100% {
        transform: scale(1.45);
        opacity: 0;
    }
}

/* Vùng code */
.tech-code {
    position: relative;
    z-index: 2;
    min-height: 150px;
}

.tech-code pre {
    margin: 0;
    white-space: pre-wrap;
}

.tech-code code {
    display: inline;
    color: #b8f5ff;
    font-family: "Courier New", Consolas, monospace;
    font-size: 16px;
    line-height: 1.75;
}

/* Con trỏ đang nhập */
.tech-code::after {
    content: "";
    display: inline-block;
    width: 9px;
    height: 22px;
    background: #00d4ff;
    margin-left: 4px;
    border-radius: 2px;
    vertical-align: -4px;
    animation: tunCodeCursorBlink 0.75s steps(2, start) infinite;
}

/* Hover khung code */
.tech-window:hover {
    box-shadow: 0 34px 90px rgba(7, 24, 39, 0.34);
}

/* 3 chấm nhảy */
@keyframes tunCodeDotTyping {

    0%,
    100% {
        transform: translateY(0);
        opacity: 0.55;
    }

    50% {
        transform: translateY(-5px);
        opacity: 1;
    }
}

/* Con trỏ nhấp nháy */
@keyframes tunCodeCursorBlink {

    0%,
    45% {
        opacity: 1;
    }

    46%,
    100% {
        opacity: 0;
    }
}

/* Mobile */
@media (max-width: 680px) {
    .tech-code {
        min-height: auto;
    }

    .tech-code code {
        font-size: 14px;
        line-height: 1.65;
    }

    .tech-code::after {
        height: 18px;
        width: 7px;
    }
}

.tech-window {
    background: #071827;
    color: #b8f5ff;
    border-radius: 30px;
    padding: 22px;
    box-shadow: 0 28px 80px rgba(7, 24, 39, .28);
    transform: rotate(1deg)
}

.tech-window-header {
    display: flex;
    gap: 8px;
    margin-bottom: 18px
}

.tech-window-header span {
    width: 13px;
    height: 13px;
    border-radius: 999px;
    background: var(--secondary)
}

.tech-code pre {
    margin: 0;
    white-space: pre-wrap;
    font-size: 15px
}

.category-section,
.featured-section,
.archive-content,
.single-section {
    padding: 64px 0
}

.section-heading {
    text-align: center;
    margin-bottom: 34px
}

.section-heading h2 {
    margin: 0 0 10px;
    color: var(--heading);
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.2;
    letter-spacing: -.8px
}

.section-heading p {
    margin: 0;
    color: var(--muted)
}

.section-between {
    text-align: left;
    display: flex;
    justify-content: space-between;
    gap: 20px;
    align-items: flex-end
}

.section-link {
    color: var(--primary);
    font-weight: 800;
    white-space: nowrap
}

/* =========================================================
   SIDEBAR - TOP VIEWED POSTS
========================================================= */

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

.tun-sidebar-top-item {
    padding: 13px 0;
    border-bottom: 1px solid var(--border);
    transition: all 0.25s ease;
}

.tun-sidebar-top-item:last-child {
    border-bottom: 0;
}

.tun-sidebar-top-item a {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.tun-top-rank {
    min-width: 58px;
    height: 34px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: #ffffff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 900;
    box-shadow: 0 8px 20px rgba(10, 102, 194, 0.2);
}

.tun-top-info {
    flex: 1;
    min-width: 0;
}

.tun-top-info strong {
    display: block;
    color: var(--heading);
    font-size: 15px;
    line-height: 1.45;
    font-weight: 800;
}

.tun-top-info small {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 5px;
    color: var(--muted);
    font-size: 13px;
    font-weight: 700;
}

.tun-sidebar-top-item:hover {
    transform: translateX(5px);
}

.tun-sidebar-top-item:hover .tun-top-info strong {
    color: var(--primary);
}

.tun-sidebar-top-item.top-1 .tun-top-rank {
    background: linear-gradient(135deg, #ff9f1c, #ffbf00);
    box-shadow: 0 8px 22px rgba(255, 159, 28, 0.3);
}

.tun-sidebar-top-item.top-2 .tun-top-rank {
    background: linear-gradient(135deg, #0A66C2, #00D4FF);
}

.tun-sidebar-top-item.top-3 .tun-top-rank {
    background: linear-gradient(135deg, #2563EB, #38BDF8);
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px
}

.category-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 22px;
    padding: 22px;
    display: flex;
    align-items: center;
    gap: 14px;
    box-shadow: var(--shadow)
}

.category-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-hover);
    border-color: rgb(10 102 194 / 82%);
}

.category-icon {
    width: 48px;
    height: 48px;
    border-radius: 16px;
    display: grid;
    place-items: center;
    color: #fff;
    font-weight: 900;
    font-size: 22px;
    background: linear-gradient(135deg, var(--primary), var(--secondary))
}

.category-card h3 {
    margin: 0 0 3px;
    color: var(--heading);
    font-size: 18px
}

.category-card p {
    margin: 0;
    color: var(--muted);
    font-size: 14px
}

/* =========================================================
   CATEGORY CHILD HORIZONTAL - FULL WIDTH ABOVE CONTENT
========================================================= */

.category-child-horizontal-box {
    margin: 0 0 34px;
    padding: 26px;
    border-radius: 30px;
    background:
        radial-gradient(circle at top right, rgba(0, 212, 255, 0.14), transparent 42%),
        linear-gradient(135deg, #ffffff 0%, #f7fbff 100%);
    border: 1px solid rgba(10, 102, 194, 0.10);
    box-shadow:
        0 18px 45px rgba(15, 23, 42, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.category-child-horizontal-heading {
    margin-bottom: 20px;
}

.category-child-horizontal-heading span {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 7px 13px;
    border-radius: 999px;
    background: rgba(10, 102, 194, 0.10);
    color: var(--primary);
    font-size: 13px;
    font-weight: 900;
    margin-bottom: 10px;
}

.category-child-horizontal-heading span::before {
    content: "";
    width: 8px;
    height: 8px;
    min-width: 8px;
    border-radius: 999px;
    background: var(--secondary);
    box-shadow: 0 0 0 5px rgba(0, 212, 255, 0.14);
}

.category-child-horizontal-heading h2 {
    margin: 0;
    color: var(--heading);
    font-size: 28px;
    line-height: 1.25;
    letter-spacing: -0.6px;
    font-weight: 900;
}

.category-child-horizontal-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
}

.category-child-horizontal-card {
    display: flex;
    align-items: center;
    gap: 13px;
    min-width: 0;
    padding: 16px;
    border-radius: 20px;
    background: rgba(248, 251, 255, 0.92);
    border: 1px solid rgba(10, 102, 194, 0.08);
    transition:
        transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
        box-shadow 0.35s ease,
        border-color 0.35s ease,
        background-color 0.35s ease;
}

.category-child-horizontal-card:hover {
    transform: translateY(-5px);
    background: #ffffff;
    border-color: rgba(0, 212, 255, 0.28);
    box-shadow: 0 18px 42px rgba(15, 23, 42, 0.10);
}

.category-child-horizontal-icon {
    width: 50px;
    height: 50px;
    min-width: 50px;
    border-radius: 17px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    font-size: 20px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    box-shadow: 0 12px 26px rgba(10, 102, 194, 0.20);
}

.category-child-horizontal-content {
    min-width: 0;
    flex: 1;
}

.category-child-horizontal-content strong {
    display: block;
    color: var(--heading);
    font-size: 16px;
    line-height: 1.35;
    font-weight: 900;
}

.category-child-horizontal-content small {
    display: block;
    margin-top: 4px;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.4;
}

.category-child-horizontal-card:hover .category-child-horizontal-content strong {
    color: var(--primary);
}

/* Tablet */
@media (max-width: 1100px) {
    .category-child-horizontal-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* Mobile */
@media (max-width: 680px) {
    .category-child-horizontal-box {
        padding: 18px;
        border-radius: 22px;
        margin-bottom: 26px;
    }

    .category-child-horizontal-heading h2 {
        font-size: 22px;
    }

    .category-child-horizontal-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .category-child-horizontal-card {
        padding: 14px;
        border-radius: 18px;
    }

    .category-child-horizontal-icon {
        width: 46px;
        height: 46px;
        min-width: 46px;
        border-radius: 15px;
        font-size: 18px;
    }
}

/* End */
.content-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 330px;
    gap: 32px;
    align-items: start
}

.content-layout.no-sidebar {
    grid-template-columns: 1fr
}

.post-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 26px
}

.no-sidebar .post-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr))
}

/* =========================================================
   SIDEBAR CATEGORY COUNT - MODERN BADGE STYLE
========================================================= */

.tun-category-count-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.tun-category-count-list li {
    padding: 0 !important;
    border-bottom: 1px solid rgba(226, 232, 240, 0.75);
}

.tun-category-count-list li:last-child {
    border-bottom: 0;
}

.tun-category-count-list a {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 14px 12px;
    border-radius: 16px;
    color: var(--heading);
    font-weight: 800;
    line-height: 1.45;
    overflow: hidden;
    transition:
        transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
        background-color 0.35s ease,
        color 0.28s ease;
}

/* Nền hover nhẹ */
.tun-category-count-list a::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background:
        radial-gradient(circle at right, rgba(0, 212, 255, 0.14), transparent 42%),
        linear-gradient(135deg, rgba(10, 102, 194, 0.07), rgba(0, 212, 255, 0.06));
    opacity: 0;
    transition: opacity 0.35s ease;
    pointer-events: none;
}

.tun-category-count-list a:hover {
    transform: translateX(5px);
    color: var(--primary);
}

.tun-category-count-list a:hover::before {
    opacity: 1;
}

.tun-category-count-list .cat-name,
.tun-category-count-list .cat-count {
    position: relative;
    z-index: 2;
}

.tun-category-count-list .cat-name {
    flex: 1;
    min-width: 0;
}

/* Badge số lượng */
.tun-category-count-list .cat-count {
    min-width: 34px;
    height: 28px;
    padding: 0 10px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;

    background: #eef7ff;
    color: var(--primary);
    border: 1px solid rgba(10, 102, 194, 0.12);
    font-size: 12px;
    font-weight: 900;
    line-height: 1;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85);

    transition:
        transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
        background 0.35s ease,
        color 0.35s ease,
        box-shadow 0.35s ease;
}

.tun-category-count-list a:hover .cat-count {
    color: #ffffff;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    transform: scale(1.08);
    box-shadow:
        0 10px 22px rgba(10, 102, 194, 0.22),
        0 0 0 4px rgba(0, 212, 255, 0.10);
}

/* =========================================================
   POST CARD - CLEAN SMOOTH HOVER
========================================================= */

.tun-post-card {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    min-height: 100%;
    overflow: hidden;

    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: 26px;
    box-shadow: var(--shadow);

    transform: translate3d(0, 0, 0);
    will-change: transform, box-shadow, border-color;
    backface-visibility: hidden;

    transition:
        transform 0.65s cubic-bezier(0.16, 1, 0.3, 1),
        box-shadow 0.6s cubic-bezier(0.16, 1, 0.3, 1),
        border-color 0.45s ease;
}

.tun-post-card:hover {
    z-index: 5;
    transform: translate3d(0, -5px, 0) !important;
    border-color: rgba(0, 212, 255, 0.26);
    box-shadow:
        0 24px 60px rgba(15, 23, 42, 0.13),
        0 0 0 1px rgba(0, 212, 255, 0.10),
        0 0 22px rgba(0, 212, 255, 0.06);
}

.tun-post-card::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 4;
    pointer-events: none;
    opacity: 0;
    background:
        linear-gradient(120deg,
            transparent 0%,
            rgba(0, 212, 255, 0.08) 35%,
            rgba(255, 255, 255, 0.36) 50%,
            rgba(0, 212, 255, 0.08) 65%,
            transparent 100%);
    transform: translateX(-120%);
}

.tun-post-card:hover::after {
    animation: tunPostCardShine 1.35s ease forwards;
}

@keyframes tunPostCardShine {
    0% {
        opacity: 0;
        transform: translateX(-120%);
    }

    25% {
        opacity: 1;
    }

    100% {
        opacity: 0;
        transform: translateX(120%);
    }
}

.tun-post-thumb {
    position: relative;
    display: block;
    aspect-ratio: 16 / 9.5;
    overflow: hidden;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
}

.tun-post-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .35s ease
}

.tun-post-card:hover .tun-post-thumb img {
    transform: scale(1.06)
}

.tun-post-no-thumb {
    width: 100%;
    height: 100%;
    display: grid;
    place-items: center;
    color: #fff;
    font-size: 24px;
    font-weight: 900;
    background: radial-gradient(circle at top right, rgba(255, 255, 255, .28), transparent 35%), linear-gradient(135deg, var(--primary), var(--secondary))
}

.tun-post-date {
    position: absolute;
    right: 14px;
    bottom: 14px;
    background: rgba(255, 255, 255, .92);
    color: var(--heading);
    padding: 7px 11px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 800;
    backdrop-filter: blur(8px);
}

.tun-post-body {
    padding: 22px;
    display: flex;
    flex-direction: column;
    flex: 1
}

.tun-post-meta {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
    margin-bottom: 11px;
    font-size: 13px
}

.tun-post-cat a {
    display: inline-flex;
    padding: 5px 10px;
    border-radius: 999px;
    background: rgba(10, 102, 194, .1);
    color: var(--primary);
    font-weight: 800
}

.tun-post-read {
    color: var(--muted);
    white-space: nowrap
}

.tun-post-title {
    margin: 0 0 10px;
    font-size: 21px;
    line-height: 1.35;
    color: var(--heading);
    letter-spacing: -.3px
}

.tun-post-title a {
    color: var(--heading)
}

.tun-post-title a:hover {
    color: var(--primary)
}

.tun-post-excerpt {
    margin: 0 0 20px;
    color: var(--muted);
    font-size: 15px;
    flex: 1
}

.tun-post-footer {
    margin-top: auto;
    padding-top: 16px;
    border-top: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px
}

.tun-author {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--muted);
    font-weight: 700;
    font-size: 13px
}

.tun-author img {
    width: 32px;
    height: 32px;
    border-radius: 999px
}

.tun-readmore {
    color: var(--primary);
    font-weight: 900;
    white-space: nowrap
}

.sidebar {
    display: flex;
    flex-direction: column;
    gap: 22px;
    position: sticky;
    top: 100px;
}

.tun-widget,
.empty-box,
.error-box,
.post_tags_widget,
.tun-download-box {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 22px;
    box-shadow: var(--shadow)
}

.tun-widget-title {
    margin: 0 0 16px;
    color: var(--heading);
    font-size: 20px;
    line-height: 1.3
}

.sidebar-search-form {
    display: flex;
    gap: 8px
}

.sidebar-search-form input {
    width: 100%;
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 11px 12px;
    outline: none
}

.sidebar-search-form button {
    border: 0;
    border-radius: 12px;
    padding: 0 15px;
    background: var(--primary);
    color: #fff;
    font-weight: 800;
    cursor: pointer
}

.tun-widget ul {
    list-style: none;
    padding: 0;
    margin: 0
}

.tun-widget li {
    padding: 10px 0;
    border-bottom: 1px solid var(--border)
}

.tun-widget li:last-child {
    border-bottom: 0
}

.sidebar-post-list a {
    display: block;
    color: var(--heading);
    font-weight: 800;
    line-height: 1.45
}

.sidebar-post-list span {
    display: block;
    color: var(--muted);
    font-size: 13px;
    margin-top: 3px
}

.tag-cloud,
.box-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px
}

.tag-cloud a,
.box-tags a {
    display: inline-flex;
    padding: 7px 10px;
    border-radius: 999px;
    background: var(--soft);
    color: var(--primary);
    font-weight: 800
}

.archive-header {
    padding: 64px 0;
    background: radial-gradient(circle at right, rgba(0, 212, 255, .18), transparent 30%), linear-gradient(135deg, var(--heading), var(--primary));
    color: #fff
}

.archive-header h1 {
    margin: 0 0 10px;
    font-size: clamp(32px, 5vw, 52px);
    line-height: 1.15;
    letter-spacing: -1px;
    color: #fff
}

.archive-header p,
.archive-description {
    margin: 0;
    color: #d7ecff;
    max-width: 760px
}



.single-layout .single-post {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 30px;
    padding: 36px;
    box-shadow: var(--shadow)
}

.single-header {
    margin-bottom: 28px
}

.single-meta {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 16px
}

.single-meta span {
    display: inline-flex;
    background: var(--soft);
    color: var(--primary);
    padding: 7px 11px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 800;
    align-items: center;
}

.single-meta span i {
    padding-right: 4px;
}

.single-header h1 {
    margin: 0 0 16px;
    color: var(--heading);
    font-size: clamp(34px, 5vw, 54px);
    line-height: 1.15;
    letter-spacing: -1.2px
}

.single-excerpt {
    margin: 0 0 20px;
    color: var(--muted);
    font-size: 18px
}

.single-author {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--muted)
}

.single-author img {
    border-radius: 999px
}

.single-author strong {
    display: block;
    color: var(--heading)
}

.single-author span {
    display: block;
    font-size: 14px
}

.single-thumb {
    border-radius: 26px;
    overflow: hidden;
    margin: 28px 0
}

.single-thumb img {
    width: 100%;
    height: auto
}

.entry-content {
    font-size: 18px;
    color: var(--text)
}

.entry-content h2,
.entry-content h3,
.entry-content h4 {
    color: var(--heading);
    line-height: 1.25;
    margin-top: 34px;
    margin-bottom: 14px
}

.entry-content h2 {
    font-size: 31px
}

.entry-content h3 {
    font-size: 25px
}

.entry-content p {
    margin: 0 0 18px
}

.entry-content a {
    color: var(--primary);
    font-weight: 800
}

.entry-content blockquote {
    margin: 26px 0;
    padding: 20px 22px;
    border-left: 5px solid var(--primary);
    background: var(--soft);
    border-radius: 16px;
    color: var(--heading);
    font-weight: 700
}

.entry-content pre {
    background: #071827;
    color: #b8f5ff;
    padding: 22px;
    border-radius: 18px;
    overflow: auto;
    font-size: 15px
}

.entry-content code {
    background: var(--soft);
    color: var(--primary);
    padding: 3px 6px;
    border-radius: 6px
}

.entry-content pre code {
    background: transparent;
    color: inherit;
    padding: 0
}

.post-tags {
    margin-top: 34px;
    padding-top: 22px;
    border-top: 1px solid var(--border);
    color: var(--muted)
}

.post-tags a {
    display: inline-flex;
    padding: 6px 10px;
    margin: 4px;
    background: var(--soft);
    border-radius: 999px;
    color: var(--primary);
    font-weight: 800
}

.post-navigation {
    margin-top: 28px;
    padding-top: 22px;
    border-top: 1px solid var(--border);
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px
}

.post-navigation a {
    display: block;
    background: #f8fafc;
    border: 1px solid var(--border);
    padding: 16px;
    border-radius: 16px;
    color: var(--heading);
    font-weight: 800
}

.related-posts {
    margin-top: 44px
}

.related-posts h2 {
    color: var(--heading);
    font-size: 28px;
    margin-bottom: 20px
}

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

.related-grid .tun-post-title {
    font-size: 18px
}

.related-grid .tun-post-excerpt,
.related-grid .tun-author {
    display: none
}

.pagination {
    margin-top: 34px
}

.nav-links {
    display: flex;
    gap: 8px;
    flex-wrap: wrap
}

.nav-links a,
.nav-links span {
    display: inline-flex;
    min-width: 42px;
    height: 42px;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: #fff;
    border: 1px solid var(--border);
    color: var(--heading);
    font-weight: 800
}

.nav-links .current {
    background: var(--primary);
    color: #fff
}

/* =========================================================
   SINGLE POST IMAGE - SOFT BLUR OVERLAY + BOX SHADOW
========================================================= */

.single-post figure,
.entry-content figure,
.entry-content .wp-block-image {
    position: relative;
    width: 100% !important;
    max-width: 100% !important;
    margin: 28px auto;
    overflow: hidden;
    border-radius: 20px;
    background: #ffffff;
    box-shadow:
        0 18px 45px rgba(15, 23, 42, 0.12),
        0 0 0 1px rgba(226, 232, 240, 0.85);
}

/* Lớp mờ/ánh sáng phủ lên ảnh */
.single-post figure::after,
.entry-content figure::after,
.entry-content .wp-block-image::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(135deg,
            rgba(0, 212, 255, 0.10),
            transparent 38%,
            rgba(10, 102, 194, 0.08)),
        linear-gradient(to bottom,
            rgba(255, 255, 255, 0.06),
            rgba(7, 24, 39, 0.08));
    opacity: 0.75;
    pointer-events: none;
    transition: opacity 0.35s ease;
    z-index: 2;
}

/* Ảnh */
.single-post figure img,
.entry-content figure img,
.entry-content .wp-block-image img,
.entry-content img {
    display: block;
    width: 100%;
    max-width: 100% !important;
    height: auto !important;
    object-fit: contain;
    border-radius: 20px;
    box-shadow: none;
    transition:
        transform 0.55s cubic-bezier(0.16, 1, 0.3, 1),
        filter 0.35s ease;
}

/* Hover ảnh */
.single-post figure:hover,
.entry-content figure:hover,
.entry-content .wp-block-image:hover {
    box-shadow:
        0 24px 60px rgba(15, 23, 42, 0.16),
        0 0 0 1px rgba(0, 212, 255, 0.22);
}

.single-post figure:hover::after,
.entry-content figure:hover::after,
.entry-content .wp-block-image:hover::after {
    opacity: 0.35;
}

.single-post figure:hover img,
.entry-content figure:hover img,
.entry-content .wp-block-image:hover img {
    transform: scale(1.015);
    filter: saturate(1.05) contrast(1.03);
}

/* Caption */
.single-post figure figcaption,
.entry-content figure figcaption,
.wp-caption-text {
    position: relative;
    z-index: 3;
    margin: 0;
    padding: 10px 14px 12px;
    background: #ffffff;
    color: var(--muted);
    font-size: 14px;
    text-align: center;
    border-top: 1px solid var(--border);
}

/* =========================================================
   RANDOM READ MORE BOX IN SINGLE POST
========================================================= */

.tun-random-readmore-box {
    position: relative;
    margin: 32px 0;
    padding: 22px;
    border-radius: 22px;
    background:
        radial-gradient(circle at top right, rgba(0, 212, 255, 0.12), transparent 42%),
        linear-gradient(135deg, #f8fbff, #ffffff);
    border: 1px solid rgba(10, 102, 194, 0.14);
    box-shadow:
        0 16px 42px rgba(15, 23, 42, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.8);
    overflow: hidden;
}

.tun-random-readmore-box::before {
    content: "";
    position: absolute;
    left: 22px;
    right: 22px;
    top: 0;
    height: 4px;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    box-shadow: 0 0 18px rgba(0, 212, 255, 0.32);
}

.tun-random-readmore-title {
    margin-bottom: 14px;
}

.tun-random-readmore-title span {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--heading);
    font-size: 18px;
    font-weight: 900;
}

.tun-random-readmore-title span::before {
    content: "";
    width: 9px;
    height: 9px;
    border-radius: 999px;
    background: var(--secondary);
    box-shadow: 0 0 0 5px rgba(0, 212, 255, 0.14);
}

.tun-random-readmore-list {
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
}

.tun-random-readmore-list li {
    margin: 0 !important;
    padding: 0 !important;
}

.tun-random-readmore-list li+li {
    margin-top: 10px !important;
}

.tun-random-readmore-list a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 13px 14px;
    border-radius: 16px;
    background: rgba(10, 102, 194, 0.055);
    color: var(--heading);
    font-weight: 800;
    line-height: 1.45;
    text-decoration: none !important;
    background-image: none !important;
    transition:
        transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
        background-color 0.28s ease,
        color 0.28s ease,
        box-shadow 0.28s ease;
}

.tun-random-readmore-list a:hover {
    transform: translateX(6px);
    background: linear-gradient(135deg, rgba(10, 102, 194, 0.1), rgba(0, 212, 255, 0.12));
    color: var(--primary);
    box-shadow: 0 10px 26px rgba(10, 102, 194, 0.10);
}

.tun-random-readmore-icon {
    width: 32px;
    height: 32px;
    min-width: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: #ffffff;
    font-size: 13px;
    box-shadow: 0 8px 18px rgba(10, 102, 194, 0.18);
}

.tun-random-readmore-text {
    flex: 1;
}

/* Mobile */
@media (max-width: 680px) {
    .tun-random-readmore-box {
        padding: 18px;
        border-radius: 18px;
    }

    .tun-random-readmore-title span {
        font-size: 16px;
    }

    .tun-random-readmore-list a {
        padding: 12px;
    }
}

/* =========================================================
   MODERN FOOTER + PARTICLES EFFECT
========================================================= */

.tun-particles-footer {
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(circle at 15% 20%, rgba(0, 212, 255, 0.16), transparent 28%),
        radial-gradient(circle at 85% 10%, rgba(10, 102, 194, 0.18), transparent 32%),
        linear-gradient(135deg, #061522 0%, #071827 45%, #03111f 100%);
    color: #ffffff;
    padding-top: 72px;
}

/* Lớp particles */
#tun-footer-particles {
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: auto;
}

/* Lớp lưới công nghệ */
.tun-particles-footer::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
    background-size: 36px 36px;
    opacity: 0.45;
    z-index: 1;
    pointer-events: none;
}

/* Ánh sáng chạy nhẹ phía dưới */
.tun-particles-footer::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: -160px;
    width: 760px;
    height: 320px;
    transform: translateX(-50%);
    background: radial-gradient(circle, rgba(0, 212, 255, 0.22), transparent 65%);
    filter: blur(8px);
    z-index: 1;
    pointer-events: none;
}

/* Đưa nội dung footer lên trên particles */
.tun-particles-footer .container,
.tun-particles-footer .footer-bottom {
    position: relative;
    z-index: 2;
}

/* Layout footer */
.tun-particles-footer .footer-grid {
    padding-bottom: 54px;
}

/* Tiêu đề footer */
.tun-particles-footer .footer-col h3 {
    position: relative;
    display: inline-flex;
    align-items: center;
    margin-bottom: 20px;
    font-size: 22px;
    color: #ffffff;
    letter-spacing: -0.3px;
}

.tun-particles-footer .footer-col h3::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -8px;
    width: 42px;
    height: 3px;
    border-radius: 999px;
    background: linear-gradient(90deg, #0A66C2, #00D4FF);
    box-shadow: 0 0 18px rgba(0, 212, 255, 0.45);
}

/* Text */
.tun-particles-footer .footer-col p {
    color: rgba(220, 239, 255, 0.86);
    font-size: 16px;
    line-height: 1.8;
}

/* Link */
.tun-particles-footer .footer-col a {
    position: relative;
    display: inline-flex;
    color: rgba(220, 239, 255, 0.9);
    line-height: 1.55;
    transition:
        color 0.28s ease,
        transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.tun-particles-footer .footer-col a:hover {
    color: #00D4FF;
    transform: translateX(5px);
}

/* Danh sách link */
.tun-particles-footer .footer-col li {
    margin-bottom: 12px;
}

/* Footer social nếu có */
.tun-particles-footer .footer-socials a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 9px 14px;
    border-radius: 999px;
    background: rgba(0, 212, 255, 0.1);
    border: 1px solid rgba(0, 212, 255, 0.18);
    color: #ffffff;
    font-weight: 800;
}

.tun-particles-footer .footer-socials a:hover {
    color: #ffffff;
    transform: translateY(-4px);
    background: linear-gradient(135deg, #0A66C2, #00D4FF);
    box-shadow: 0 14px 30px rgba(0, 212, 255, 0.22);
}

/* Copyright */
.tun-particles-footer .footer-bottom {
    margin-top: 0;
    padding: 24px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.09);
    background: rgba(0, 0, 0, 0.12);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.tun-particles-footer .footer-bottom p {
    margin: 0;
    color: rgba(220, 239, 255, 0.88);
    font-weight: 600;
    letter-spacing: 0.2px;
}

/* Responsive */
@media (max-width: 920px) {
    .tun-particles-footer {
        padding-top: 52px;
    }

    .tun-particles-footer .footer-col {
        padding: 20px;
    }
}

@media (max-width: 680px) {
    .tun-particles-footer .footer-grid {
        gap: 18px;
    }

    .tun-particles-footer .footer-col {
        border-radius: 18px;
    }

    .tun-particles-footer .footer-col:hover {
        transform: none;
    }

    #tun-footer-particles {
        opacity: 0.55;
    }
}

.site-footer {
    background: var(--footer-bg);
    color: #fff;
    padding-top: 58px
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
    gap: 34px
}

.footer-col h3 {
    margin: 0 0 16px;
    color: #fff;
    font-size: 21px
}

.footer-col p,
.footer-col a {
    color: #b8c7d9
}

.footer-col ul,
.footer-menu {
    list-style: none;
    padding: 0;
    margin: 0
}

.footer-col li {
    margin-bottom: 10px
}

.footer-col a:hover {
    color: #fff
}

.footer-contact p {
    margin: 8px 0
}

.footer-socials {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 18px
}

.footer-socials a {
    display: inline-flex;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, .08);
    color: #fff;
    font-size: 14px;
    font-weight: 800
}

.footer-socials a:hover {
    background: var(--primary)
}

.footer-bottom {
    margin-top: 44px;
    padding: 20px 0;
    border-top: 1px solid rgba(255, 255, 255, .1);
    text-align: center;
    color: #b8c7d9
}

.error-page {
    min-height: 60vh;
    display: flex;
    align-items: center;
    padding: 80px 0
}

.error-box {
    text-align: center
}

.error-box span {
    display: block;
    font-size: 88px;
    font-weight: 900;
    color: var(--primary);
    line-height: 1
}

.error-box h1 {
    color: var(--heading);
    font-size: 36px
}

.tun-top-view-list {
    list-style: none;
    margin: 0;
    padding: 0
}

.tun-top-view-list li {
    border-bottom: 1px solid var(--border);
    padding: 12px 0
}

.tun-top-view-list li:last-child {
    border-bottom: 0
}

.tun-top-view-list a {
    display: flex;
    gap: 12px;
    align-items: flex-start
}

a.next.page-numbers {
    padding: 15px;
}

.tun-top-number {
    min-width: 54px;
    height: 34px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 900
}

.tun-top-content strong {
    display: block;
    color: var(--heading);
    line-height: 1.45
}

.tun-top-content small {
    display: block;
    margin-top: 4px;
    color: var(--muted)
}

.single-layout .pld-like-dislike-wrap.pld-custom img {
    max-width: 30px !important;
}

.sc-button-center {
    text-align: center;
    margin: 24px 0
}

.sc-button,
.tun-download-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 13px 24px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: #fff !important;
    font-weight: 900;
    box-shadow: 0 12px 28px rgba(10, 102, 194, .24);
    border: 0;
    cursor: pointer
}

.tun-download-count {
    margin: 12px 0 0;
    color: var(--muted);
    font-weight: 700
}

.tun-countdown {
    margin-top: 14px;
    color: #dc2626;
    font-weight: 800
}

@media(max-width:1100px) {
    .header-search {
        display: none
    }

    .no-sidebar .post-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr))
    }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr)
    }

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

@media(max-width:920px) {

    .hero-grid,
    .content-layout {
        grid-template-columns: 1fr
    }

    .category-grid {
        grid-template-columns: repeat(2, 1fr)
    }

    .header-cta {
        display: none
    }

    .main-navigation {
        position: absolute;
        top: 78px;
        left: 16px;
        right: 16px;
        background: #fff;
        border: 1px solid var(--border);
        border-radius: 20px;
        box-shadow: var(--shadow);
        padding: 18px;
        display: none
    }

    .main-navigation.active {
        display: block
    }

    .main-menu {
        flex-direction: column;
        align-items: flex-start;
        gap: 0
    }

    .main-menu li {
        width: 100%
    }

    .main-menu a {
        display: block;
        padding: 11px 4px
    }

    .main-menu .sub-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        margin: 0;
        box-shadow: none;
        border: 0;
        padding-left: 14px;
        background: transparent
    }

    .menu-toggle {
        display: block;
        margin-left: auto
    }

    .section-between {
        flex-direction: column;
        align-items: flex-start
    }
}

@media(max-width:680px) {
    .container {
        width: min(100% - 24px, 1180px)
    }

    .hero-section {
        padding: 58px 0
    }

    .hero-content h1 {
        font-size: 36px
    }

    .post-grid,
    .no-sidebar .post-grid,
    .category-grid {
        grid-template-columns: 1fr
    }

    .single-post {
        padding: 22px;
        border-radius: 22px
    }

    .single-header h1 {
        font-size: 32px
    }

    .post-navigation {
        grid-template-columns: 1fr
    }

    .footer-grid {
        grid-template-columns: 1fr
    }

    .custom-logo-img {
        max-height: 42px
    }

    .logo-text {
        font-size: 20px
    }

    .tech-window {
        transform: none
    }
}


/* =========================================================
   TUN TECH BLOG - COMPLETE MODERN SMOOTH EFFECTS
   Style hover hiện đại, mượt, ổn định, dùng cho web công nghệ
========================================================= */

:root {
    --tun-ease: cubic-bezier(0.16, 1, 0.3, 1);
    --tun-hover-shadow: 0 24px 70px rgba(15, 23, 42, 0.12);
    --tun-blue-glow: 0 0 0 1px rgba(10, 102, 194, 0.16),
        0 18px 48px rgba(10, 102, 194, 0.13);
}

/* Global render */
body {
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

::selection {
    background: var(--primary);
    color: #ffffff;
}

/* Base transition tối ưu, không dùng transition: all */
a,
button,
input,
textarea {
    transition:
        color .25s ease,
        background-color .25s ease,
        border-color .25s ease,
        box-shadow .25s ease;
}

.tun-post-card,
.category-card,
.tun-widget,
.btn-primary,
.btn-outline,
.header-cta a,
.sc-button,
.tun-download-btn,
.footer-socials a,
.nav-links a,
.tag-cloud a,
.box-tags a,
.post-tags a,
.tun-sidebar-top-item,
.tun-top-rank,
.category-icon {
    transition:
        transform .45s var(--tun-ease),
        box-shadow .45s var(--tun-ease),
        border-color .35s ease,
        background-color .35s ease,
        color .35s ease,
        opacity .35s ease;
    will-change: transform;
    transform: translate3d(0, 0, 0);
    backface-visibility: hidden;
}

.tun-post-thumb img,
.single-thumb img,
.entry-content img {
    transition:
        transform .75s var(--tun-ease),
        filter .45s ease,
        box-shadow .45s ease,
        opacity .45s ease;
    will-change: transform;
    backface-visibility: hidden;
}

/* Header glass */
.site-header {
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.site-logo a {
    transition:
        transform .32s var(--tun-ease),
        color .25s ease;
}

.site-logo a:hover {
    transform: translate3d(0, -1px, 0);
}

/* Logo shine */
.logo-icon {
    position: relative;
    overflow: hidden;
}

.logo-icon::after {
    content: "";
    position: absolute;
    top: 0;
    left: -120%;
    width: 80%;
    height: 100%;
    background: linear-gradient(120deg, transparent, rgba(255, 255, 255, .38), transparent);
    transform: skewX(-20deg);
    pointer-events: none;
}

.site-logo a:hover .logo-icon::after {
    animation: tunModernLogoShine .85s ease;
}

/* Menu cha underline mượt */
@media (min-width: 921px) {
    .main-menu>li>a {
        position: relative;
        transition:
            color .25s ease,
            transform .32s var(--tun-ease);
    }

    .main-menu>li>a::after {
        content: "";
        position: absolute;
        left: 0;
        bottom: -7px;
        width: 0;
        height: 3px;
        border-radius: 999px;
        background: linear-gradient(135deg, var(--primary), var(--secondary));
        transition: width .36s var(--tun-ease);
    }

    .main-menu>li>a:hover::after,
    .main-menu>li.current-menu-item>a::after,
    .main-menu>li.current-menu-parent>a::after {
        width: 100%;
    }
}

/* Dropdown menu: border gradient xanh chạy clockwise */
@media (min-width: 921px) {
    .main-menu .sub-menu {
        position: absolute;
        overflow: hidden;
        border: 0 !important;
        border-radius: 18px !important;
        padding: 14px !important;
        background: #ffffff !important;
        box-shadow: 0 18px 45px rgba(15, 23, 42, .14);
        z-index: 999;
        transform-origin: top left;
        transition:
            opacity .28s ease,
            visibility .28s ease,
            transform .42s var(--tun-ease);
    }

    .main-menu li:hover>.sub-menu {
        animation: tunModernDropdownOpen .24s ease both;
    }

    .main-menu .sub-menu::before {
        content: "";
        position: absolute;
        inset: 0;
        border-radius: 18px;
        padding: 2px;
        background: conic-gradient(from 0deg,
                #0A66C2,
                #00D4FF,
                #38BDF8,
                #2563EB,
                #00D4FF,
                #0A66C2);
        pointer-events: none;
        z-index: 1;

        -webkit-mask:
            linear-gradient(#000 0 0) content-box,
            linear-gradient(#000 0 0);
        -webkit-mask-composite: xor;
        mask-composite: exclude;
    }

    .main-menu .sub-menu li,
    .main-menu .sub-menu a {
        position: relative;
        z-index: 3;
    }

    .main-menu .sub-menu a {
        display: block;
        padding: 11px 12px !important;
        border-radius: 12px;
        color: var(--heading);
        background: transparent;
        transition:
            transform .35s var(--tun-ease),
            color .28s ease,
            background-color .28s ease;
    }

    .main-menu .sub-menu a:hover {
        background: rgba(10, 102, 194, .08);
        color: var(--primary);
        transform: translate3d(6px, 0, 0);
    }
}

/* Search focus */
.header-search form,
.sidebar-search-form,
.sidebar-search-form input {
    transition:
        border-color .25s ease,
        box-shadow .25s ease,
        background-color .25s ease;
}

.header-search form:focus-within,
.sidebar-search-form:focus-within {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(10, 102, 194, .1);
    background: #ffffff;
}

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

/* Buttons premium */
.btn-primary,
.header-cta a,
.sc-button,
.tun-download-btn {
    position: relative;
    overflow: hidden;
}

.btn-primary::after,
.header-cta a::after,
.sc-button::after,
.tun-download-btn::after {
    content: "";
    position: absolute;
    top: 0;
    left: -90%;
    width: 55%;
    height: 100%;
    background: linear-gradient(120deg, transparent, rgba(255, 255, 255, .42), transparent);
    transform: skewX(-22deg);
    pointer-events: none;
    opacity: 0;
}

.btn-primary:hover::after,
.header-cta a:hover::after,
.sc-button:hover::after,
.tun-download-btn:hover::after {
    opacity: 1;
    animation: tunModernButtonShine .95s ease;
}

.btn-primary:hover,
.header-cta a:hover,
.sc-button:hover,
.tun-download-btn:hover {
    transform: translate3d(0, -5px, 0);
    box-shadow:
        0 20px 46px rgba(10, 102, 194, .32),
        0 0 0 7px rgba(0, 212, 255, .08);
}

.btn-outline:hover {
    transform: translate3d(0, -5px, 0);
    box-shadow: 0 18px 42px rgba(10, 102, 194, .15);
}

/* CTA nhấp nháy nhẹ */
.header-cta a {
    animation: tunModernCtaPulse 2.2s ease-in-out infinite;
}

/* Hero intro */
.hero-content {
    animation: tunModernFadeUp .6s var(--tun-ease) both;
}

.hero-visual {
    animation: tunModernFadeRight .7s var(--tun-ease) .08s both;
}

/* Badge dot */
.hero-badge,
.tun-widget-title span,
.section-heading span,
.archive-header span {
    gap: 8px;
}

.hero-badge::before,
.tun-widget-title span::before,
.section-heading span::before,
.archive-header span::before {
    content: "";
    width: 8px;
    height: 8px;
    min-width: 8px;
    border-radius: 50%;
    background: var(--secondary);
    box-shadow: 0 0 0 5px rgba(0, 212, 255, .14);
}

.tun-widget-title span {
    font-size: 16px;

}

/* Hero code box */
.tech-window {
    animation: tunModernFloat 4.5s ease-in-out infinite;
}

.tech-window:hover {
    box-shadow: 0 34px 90px rgba(7, 24, 39, .34);
}

/* 3 dots loading */
.tech-window-header {
    display: flex;
    align-items: center;
    gap: 9px;
}

.tech-window-header span {
    position: relative;
    width: 13px;
    height: 13px;
    border-radius: 50%;
    background: #00d4ff;
    box-shadow: 0 0 0 rgba(0, 212, 255, 0);
    animation: tunModernCodeDotLoading 1.15s ease-in-out infinite;
}

.tech-window-header span:nth-child(1) {
    animation-delay: 0s;
}

.tech-window-header span:nth-child(2) {
    animation-delay: .18s;
}

.tech-window-header span:nth-child(3) {
    animation-delay: .36s;
}

.tech-window-header span::after {
    content: "";
    position: absolute;
    inset: -5px;
    border-radius: 50%;
    background: rgba(0, 212, 255, .22);
    transform: scale(.4);
    opacity: 0;
    animation: tunModernCodeDotRipple 1.15s ease-in-out infinite;
}

.tech-window-header span:nth-child(1)::after {
    animation-delay: 0s;
}

.tech-window-header span:nth-child(2)::after {
    animation-delay: .18s;
}

.tech-window-header span:nth-child(3)::after {
    animation-delay: .36s;
}

/* Code cursor */
.tech-code::after {
    content: "";
    display: inline-block;
    width: 9px;
    height: 22px;
    background: #00d4ff;
    margin-left: 4px;
    border-radius: 2px;
    vertical-align: -4px;
    animation: tunModernCodeCursorBlink .75s steps(2, start) infinite;
}

/* Card bài viết: Modern Lift + Glow */
.tun-post-card {
    position: relative;
}

.tun-post-card:hover {
    transform: translate3d(0, -8px, 0);
    box-shadow: var(--tun-blue-glow);
    border-color: rgb(0 212 255 / .32);
}

.tun-post-card:hover .tun-post-thumb img {
    transform: scale(1.075);
    filter: saturate(1.06) contrast(1.03);
}

.tun-post-thumb {
    position: relative;
    box-shadow: inset 0 -80px 80px rgba(7, 24, 39, .12);
}

.tun-post-thumb::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(0, 212, 255, .14), transparent 45%, rgba(10, 102, 194, .12));
    opacity: 0;
    z-index: 1;
    pointer-events: none;
    transition: opacity .45s ease;
}

.tun-post-card:hover .tun-post-thumb::before {
    opacity: 1;
}

.tun-post-date {
    z-index: 2;
    box-shadow: 0 8px 18px rgba(15, 23, 42, .12);
}

/* Post title underline gradient */
.tun-post-title a {
    background-image: linear-gradient(90deg, var(--primary), var(--secondary));
    background-repeat: no-repeat;
    background-size: 0% 2px;
    background-position: 0 100%;
    transition:
        color .35s ease,
        background-size .45s var(--tun-ease);
}

.tun-post-title a:hover {
    color: var(--primary);
    background-size: 100% 2px;
    text-decoration: none;
}

/* Read more */
.tun-readmore {
    display: inline-flex;
    align-items: center;
    gap: 7px;
}

.tun-readmore i {
    transition: transform .4s var(--tun-ease);
}

.tun-readmore:hover i {
    transform: translateX(6px);
}

/* Category hover app/SaaS */
.category-card {
    position: relative;
    overflow: hidden;
}

.category-card:hover {
    transform: translate3d(0, -8px, 0);
    box-shadow: var(--tun-blue-glow);
    border-color: rgba(0, 212, 255, .32);
}

.category-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at top right, rgba(0, 212, 255, .16), transparent 42%);
    opacity: 0;
    pointer-events: none;
    transition: opacity .45s ease;
}

.category-card:hover::after {
    opacity: 1;
}

.category-card:hover .category-icon {
    transform: scale(1.08) rotate(-3deg);
    box-shadow: 0 14px 30px rgba(10, 102, 194, .24);
}

.category-icon {
    transition:
        transform .45s var(--tun-ease),
        box-shadow .45s ease;
}

/* Sidebar */
.tun-widget:hover {
    transform: translate3d(0, -6px, 0);
    box-shadow: 0 22px 60px rgba(15, 23, 42, .10);
    border-color: rgba(10, 102, 194, .14);
}

/* Bỏ chấm/icon tự sinh trước title sidebar */
.sidebar .tun-widget-title::before {
    content: none !important;
    display: none !important;
}

.sidebar .tun-widget-title {
    gap: 0 !important;
}

/* Sidebar links */
.tun-widget li a {
    transition:
        color .25s ease,
        padding-left .28s var(--tun-ease);
}

.tun-widget li a:hover {
    padding-left: 6px;
}

/* Top viewed sidebar */
.tun-sidebar-top-item:hover {
    transform: translate3d(7px, 0, 0);
}

.tun-sidebar-top-item:hover .tun-top-rank {
    transform: scale(1.06);
}

.tun-sidebar-top-item:hover .tun-top-info strong {
    color: var(--primary);
}

.tun-top-rank {
    transition:
        transform .38s var(--tun-ease),
        box-shadow .38s ease;
}

/* Tags */
.tag-cloud a,
.box-tags a,
.post-tags a {
    position: relative;
    overflow: hidden;
}

.tag-cloud a:hover,
.box-tags a:hover,
.post-tags a:hover {
    transform: translate3d(0, -4px, 0);
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: #ffffff;
    box-shadow: 0 12px 26px rgba(10, 102, 194, .20);
}

/* Single images */
.single-thumb:hover img {
    transform: scale(1.025);
}

.entry-content img:hover {
    transform: scale(1.012);
    box-shadow: 0 18px 45px rgba(15, 23, 42, .10);
}

.entry-content pre {
    box-shadow: 0 18px 45px rgba(7, 24, 39, .16);
}

.entry-content blockquote {
    box-shadow: 0 12px 30px rgba(10, 102, 194, .08);
}

/* Pagination */
.nav-links a:hover {
    transform: translate3d(0, -4px, 0);
    background: var(--primary);
    color: #ffffff;
    border-color: var(--primary);
    box-shadow: 0 12px 26px rgba(10, 102, 194, .18);
}

/* Footer social */
.footer-socials a:hover {
    transform: translate3d(0, -4px, 0);
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    box-shadow: 0 14px 28px rgba(10, 102, 194, .24);
}

/* Active press */
.btn-primary:active,
.btn-outline:active,
.header-cta a:active,
.sc-button:active,
.tun-download-btn:active,
.tun-post-card:active,
.category-card:active,
.nav-links a:active,
.tag-cloud a:active,
.box-tags a:active {
    transform: translate3d(0, -1px, 0) scale(.985);
}

/* Mobile */
@media (max-width: 920px) {
    .main-navigation.active {
        animation: tunModernDropdownOpen .22s ease both;
    }

    .main-menu>li>a::after {
        display: none;
    }

    .tech-window {
        animation: none;
    }
}

@media (max-width: 768px) {

    .tun-post-card:hover,
    .category-card:hover,
    .tun-widget:hover,
    .btn-primary:hover,
    .btn-outline:hover,
    .header-cta a:hover,
    .sc-button:hover,
    .tun-download-btn:hover {
        transform: none;
    }

    .tun-post-card:hover .tun-post-thumb img,
    .single-thumb:hover img,
    .entry-content img:hover {
        transform: none;
    }
}

/* Reduce motion */
@media (prefers-reduced-motion: reduce) {

    .tun-post-card,
    .category-card,
    .tun-widget,
    .btn-primary,
    .btn-outline,
    .header-cta a,
    .sc-button,
    .tun-download-btn,
    .footer-socials a,
    .nav-links a,
    .tag-cloud a,
    .box-tags a,
    .post-tags a,
    .tun-post-thumb img,
    .single-thumb img,
    .entry-content img,
    .tech-window,
    .tech-window-header span {
        transition: none !important;
        animation: none !important;
        transform: none !important;
    }
}

/* Keyframes */
@keyframes tunModernFadeUp {
    from {
        opacity: 0;
        transform: translateY(16px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes tunModernFadeRight {
    from {
        opacity: 0;
        transform: translateX(22px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes tunModernDropdownOpen {
    from {
        opacity: 0;
        transform: translateY(8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes tunModernFloat {

    0%,
    100% {
        transform: translateY(0) rotate(1deg);
    }

    50% {
        transform: translateY(-8px) rotate(1deg);
    }
}

@keyframes tunModernLogoShine {
    from {
        left: -120%;
    }

    to {
        left: 130%;
    }
}

@keyframes tunModernButtonShine {
    from {
        left: -90%;
    }

    to {
        left: 135%;
    }
}

@keyframes tunModernCtaPulse {

    0%,
    100% {
        filter: brightness(1);
    }

    50% {
        filter: brightness(1.12);
    }
}

@keyframes tunModernSubMenuBorderSpin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

@keyframes tunModernCodeDotLoading {

    0%,
    80%,
    100% {
        transform: translateY(0) scale(.85);
        opacity: .55;
        box-shadow: 0 0 0 rgba(0, 212, 255, 0);
    }

    40% {
        transform: translateY(-6px) scale(1.15);
        opacity: 1;
        box-shadow: 0 0 18px rgba(0, 212, 255, .75);
    }
}

@keyframes tunModernCodeDotRipple {
    0% {
        transform: scale(.4);
        opacity: 0;
    }

    35% {
        transform: scale(1);
        opacity: 1;
    }

    80%,
    100% {
        transform: scale(1.45);
        opacity: 0;
    }
}

@keyframes tunModernCodeCursorBlink {

    0%,
    45% {
        opacity: 1;
    }

    46%,
    100% {
        opacity: 0;
    }
}

/* =========================================================
   RELATED POSTS SLIDER
   Desktop: 2 bài / Mobile: 1 bài
========================================================= */

.related-slider-section {
    margin-top: 52px;
}

.related-slider-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 24px;
}

.related-slider-heading h2 {
    position: relative;
    margin: 0;
    color: var(--heading);
    font-size: 30px;
    font-weight: 900;
    letter-spacing: -0.5px;
}

.related-slider-heading h2::after {
    content: "";
    display: block;
    width: 68px;
    height: 4px;
    margin-top: 10px;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
}

.related-slider-controls {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.related-slider-btn {
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: #ffffff;
    cursor: pointer;
    box-shadow: 0 12px 26px rgba(10, 102, 194, 0.22);
    transition:
        transform 0.32s cubic-bezier(0.16, 1, 0.3, 1),
        box-shadow 0.32s ease,
        opacity 0.25s ease;
}

.related-slider-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 18px 38px rgba(10, 102, 194, 0.30);
}

.related-slider-btn:active {
    transform: scale(0.96);
}

.related-slider-wrapper {
    position: relative;
    overflow: hidden;
    width: 100%;
}

.related-slider-track {
    display: flex;
    gap: 20px;
    will-change: transform;
    transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}

.related-slider-item {
    flex: 0 0 calc((100% - 20px) / 2);
    min-width: calc((100% - 20px) / 2);
}

.related-slider-item .tun-post-card {
    height: 100%;
}

.related-slider-item .tun-post-excerpt,
.related-slider-item .tun-author {
    display: none;
}

/* Mobile: 1 bài / slide */
@media (max-width: 768px) {
    .related-slider-heading {
        align-items: flex-start;
    }

    .related-slider-heading h2 {
        font-size: 26px;
    }

    .related-slider-item {
        flex: 0 0 100%;
        min-width: 100%;
    }

    .related-slider-track {
        gap: 0;
    }
}

/* =========================================================
   ABOUT PAGE - TUNLAMWEB PROFILE STYLE
========================================================= */

.tun-about-page {
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(circle at 12% 8%, rgba(0, 212, 255, 0.12), transparent 28%),
        radial-gradient(circle at 88% 12%, rgba(10, 102, 194, 0.12), transparent 30%),
        linear-gradient(180deg, #f8fbff 0%, var(--bg) 100%);
}

.tun-about-page::before {
    content: "";
    position: fixed;
    inset: 0;
    background-image:
        linear-gradient(rgba(10, 102, 194, 0.045) 1px, transparent 1px),
        linear-gradient(90deg, rgba(10, 102, 194, 0.045) 1px, transparent 1px);
    background-size: 36px 36px;
    pointer-events: none;
    z-index: 0;
}

.tun-about-container {
    position: relative;
    z-index: 1;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
}

.tun-about-hero {
    padding: 82px 0 46px;
}

.tun-about-hero-grid {
    display: grid;
    grid-template-columns: 390px minmax(0, 1fr);
    gap: 42px;
    align-items: center;
}

/* Profile Card */
.tun-about-profile-card {
    position: relative;
    overflow: hidden;
    border-radius: 32px;
    padding: 24px;
    background:
        radial-gradient(circle at top right, rgba(0, 212, 255, 0.18), transparent 42%),
        linear-gradient(145deg, #071827, #0a2440);
    color: #ffffff;
    box-shadow: 0 28px 80px rgba(7, 24, 39, 0.22);
}

.tun-about-profile-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
    background-size: 28px 28px;
    pointer-events: none;
}

.tun-about-avatar {
    position: relative;
    z-index: 1;
    overflow: hidden;
    border-radius: 26px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.tun-about-avatar img {
    width: 100%;
    aspect-ratio: 1 / 1.08;
    object-fit: cover;
}

.tun-about-profile-info {
    position: relative;
    z-index: 1;
    padding-top: 22px;
}

.tun-about-badge,
.tun-section-label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border-radius: 999px;
    background: rgba(10, 102, 194, 0.10);
    color: var(--primary);
    font-size: 14px;
    font-weight: 900;
    margin-bottom: 14px;
}

.tun-about-badge {
    color: #ffffff;
    background: rgba(0, 212, 255, 0.13);
    border: 1px solid rgba(0, 212, 255, 0.20);
}

.tun-section-label::before,
.tun-about-badge::before {
    content: "";
    width: 8px;
    height: 8px;
    min-width: 8px;
    border-radius: 999px;
    background: var(--secondary);
    box-shadow: 0 0 0 5px rgba(0, 212, 255, 0.14);
}

.tun-about-profile-info h1 {
    margin: 0 0 8px;
    font-size: 38px;
    line-height: 1.1;
    letter-spacing: -1px;
    color: #ffffff;
}

.tun-about-profile-info p {
    margin: 0;
    color: rgba(220, 239, 255, 0.86);
}

.tun-about-socials {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 22px;
}

.tun-about-socials a {
    width: 42px;
    height: 42px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(0, 212, 255, 0.16);
    transition:
        transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
        background-color 0.35s ease,
        box-shadow 0.35s ease;
}

.tun-about-socials a:hover {
    transform: translateY(-4px);
    color: #ffffff;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    box-shadow: 0 14px 30px rgba(0, 212, 255, 0.22);
}

/* Hero Content */
.tun-about-hero-content h2 {
    margin: 0 0 22px;
    color: var(--heading);
    font-size: clamp(34px, 4.8vw, 55px);
    line-height: 1.12;
    letter-spacing: -1.5px;
    font-weight: 900;
}

.tun-about-hero-content p {
    margin: 0 0 28px;
    color: var(--muted);
    font-size: 18px;
    line-height: 1.8;
}

.tun-about-actions,
.tun-contact-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
}

.tun-about-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 13px 22px;
    border-radius: 999px;
    font-weight: 900;
    transition:
        transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
        box-shadow 0.35s ease,
        background-color 0.35s ease,
        color 0.35s ease;
}

.tun-about-btn.primary {
    color: #ffffff;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    box-shadow: 0 14px 30px rgba(10, 102, 194, 0.24);
}

.tun-about-btn.outline {
    color: var(--primary);
    background: #ffffff;
    border: 1px solid rgba(10, 102, 194, 0.24);
}

.tun-about-btn:hover {
    transform: translateY(-4px);
}

.tun-about-btn.primary:hover {
    color: #ffffff;
    box-shadow: 0 20px 46px rgba(10, 102, 194, 0.34);
}

.tun-about-btn.outline:hover {
    color: #ffffff;
    background: var(--primary);
}

/* =========================================================
   ABOUT INFO CARDS - FIXED SPACING + COMPACT STYLE
   Gọn, đúng khoảng cách với các section khác
========================================================= */

/* Wrapper thông tin nhanh */
.tun-info-grid {
    width: 100%;
    max-width: 100%;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;

    /* Khoảng cách chuẩn với hero và section Câu chuyện */
    margin: 34px 0 64px;
}

/* Card */
.tun-info-card {
    position: relative;
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
    min-height: 112px;
    padding: 18px 20px;
    border-radius: 24px;
    background:
        radial-gradient(circle at top right, rgba(0, 212, 255, 0.12), transparent 42%),
        linear-gradient(135deg, #ffffff 0%, #f6fbff 100%);
    border: 1px solid rgba(10, 102, 194, 0.10);
    box-shadow:
        0 16px 38px rgba(15, 23, 42, 0.07),
        inset 0 1px 0 rgba(255, 255, 255, 0.9);
    overflow: hidden;
    transition:
        transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
        box-shadow 0.35s ease,
        border-color 0.35s ease;
}

/* Line trên card */
.tun-info-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 26px;
    right: 26px;
    height: 4px;
    border-radius: 0 0 999px 999px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    box-shadow: 0 0 18px rgba(0, 212, 255, 0.28);
}

/* Tắt lớp after cũ nếu có */
.tun-info-card::after {
    content: none !important;
    display: none !important;
}

.tun-info-card:hover {
    transform: translateY(-5px);
    border-color: rgba(0, 212, 255, 0.26);
    box-shadow:
        0 24px 52px rgba(15, 23, 42, 0.11),
        0 0 0 1px rgba(0, 212, 255, 0.10);
}

/* Icon */
.tun-info-icon {
    width: 54px;
    height: 54px;
    min-width: 54px;
    border-radius: 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #0A66C2, #00D4FF);
    color: #ffffff;
    font-size: 21px;
    box-shadow:
        0 14px 28px rgba(10, 102, 194, 0.22),
        inset 0 1px 0 rgba(255, 255, 255, 0.22);
    transition:
        transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
        box-shadow 0.35s ease;
}

.tun-info-card:hover .tun-info-icon {
    transform: scale(1.06) rotate(-3deg);
    box-shadow:
        0 18px 34px rgba(10, 102, 194, 0.28),
        inset 0 1px 0 rgba(255, 255, 255, 0.24);
}

/* Content */
.tun-info-content {
    flex: 1;
    min-width: 0;
}

.tun-info-content span {
    display: block;
    margin: 0 0 5px;
    color: #64748B;
    font-size: 13px;
    font-weight: 900;
    line-height: 1.25;
    text-transform: uppercase;
    letter-spacing: 0.25px;
}

.tun-info-content strong {
    display: block;
    color: var(--heading);
    font-size: 18px;
    line-height: 1.32;
    font-weight: 900;
    letter-spacing: -0.25px;
}

/* Fix khoảng cách section ngay sau info grid */
.tun-info-grid+.tun-about-section,
.tun-about-container+.tun-about-container.tun-about-section {
    padding-top: 0;
}

/* Nếu phần Câu chuyện nằm ngay sau info thì căn khoảng cách đẹp hơn */
.tun-info-grid+.tun-section-heading,
.tun-info-grid+section,
.tun-info-grid+div {
    margin-top: 0;
}

/* Tablet */
@media (max-width: 1180px) {
    .tun-info-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 18px;
        margin: 30px 0 58px;
    }
}

/* Mobile */
@media (max-width: 680px) {
    .tun-info-grid {
        grid-template-columns: 1fr;
        gap: 14px;
        margin: 26px 0 46px;
    }

    .tun-info-card {
        min-height: 96px;
        padding: 16px 18px;
        border-radius: 20px;
        gap: 13px;
    }

    .tun-info-card::before {
        left: 22px;
        right: 22px;
    }

    .tun-info-icon {
        width: 48px;
        height: 48px;
        min-width: 48px;
        border-radius: 16px;
        font-size: 19px;
    }

    .tun-info-content span {
        font-size: 12px;
    }

    .tun-info-content strong {
        font-size: 17px;
    }
}

/* Sections */
.tun-about-section {
    padding: 18px 0 72px;
}

.tun-section-heading {
    max-width: 760px;
    margin-bottom: 34px;
}

.tun-section-heading h2 {
    margin: 0 0 12px;
    color: var(--heading);
    font-size: clamp(30px, 4vw, 44px);
    line-height: 1.16;
    letter-spacing: -1px;
    font-weight: 900;
}

.tun-section-heading p {
    margin: 0;
    color: var(--muted);
    font-size: 17px;
}

.tun-story-box {
    padding: 32px;
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
}

.tun-story-box p {
    margin: 0 0 18px;
    color: var(--text);
    font-size: 18px;
    line-height: 1.85;
}

.tun-story-box p:last-child {
    margin-bottom: 0;
}

/* Skills Cards */
.tun-skill-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}

.tun-skill-card {
    position: relative;
    overflow: hidden;
    padding: 26px;
    border-radius: 26px;
    background: #ffffff;
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
    transition:
        transform 0.45s cubic-bezier(0.16, 1, 0.3, 1),
        box-shadow 0.45s ease,
        border-color 0.35s ease;
}

.tun-skill-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at top right, rgba(0, 212, 255, 0.14), transparent 42%);
    opacity: 0;
    transition: opacity 0.35s ease;
    pointer-events: none;
}

.tun-skill-card:hover {
    transform: translateY(-8px);
    border-color: rgba(0, 212, 255, 0.32);
    box-shadow:
        0 0 0 1px rgba(10, 102, 194, 0.12),
        0 22px 58px rgba(15, 23, 42, 0.12);
}

.tun-skill-card:hover::after {
    opacity: 1;
}

.tun-skill-icon {
    width: 58px;
    height: 58px;
    border-radius: 18px;
    display: grid;
    place-items: center;
    color: #ffffff;
    font-size: 24px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    box-shadow: 0 14px 30px rgba(10, 102, 194, 0.22);
    margin-bottom: 18px;
}

.tun-skill-card h3 {
    margin: 0 0 10px;
    color: var(--heading);
    font-size: 21px;
}

.tun-skill-card p {
    margin: 0;
    color: var(--muted);
    line-height: 1.75;
}

/* Timeline */
.tun-timeline {
    position: relative;
    display: grid;
    gap: 20px;
}

.tun-timeline::before {
    content: "";
    position: absolute;
    left: 154px;
    top: 0;
    bottom: 0;
    width: 3px;
    border-radius: 999px;
    background: linear-gradient(180deg, var(--primary), var(--secondary));
    opacity: 0.28;
}

.tun-timeline-item {
    position: relative;
    display: grid;
    grid-template-columns: 130px minmax(0, 1fr);
    gap: 48px;
    align-items: start;
}

.tun-timeline-date {
    display: inline-flex;
    justify-content: center;
    padding: 9px 12px;
    border-radius: 999px;
    background: rgba(10, 102, 194, 0.10);
    color: var(--primary);
    font-size: 13px;
    font-weight: 900;
}

.tun-timeline-content {
    position: relative;
    padding: 24px;
    border-radius: 24px;
    background: #ffffff;
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
}

.tun-timeline-content::before {
    content: "";
    position: absolute;
    left: -30px;
    top: 10px;
    width: 15px;
    height: 15px;
    border-radius: 999px;
    background: var(--secondary);
    box-shadow: 0 0 0 7px rgba(0, 212, 255, 0.14), 0 0 22px rgba(0, 212, 255, 0.44);
}

.tun-timeline-content h3 {
    margin: 0 0 6px;
    color: var(--heading);
    font-size: 22px;
}

.tun-timeline-content h4 {
    margin: 0 0 14px;
    color: var(--primary);
    font-size: 15px;
}

.tun-timeline-content ul {
    margin: 0;
    padding-left: 18px;
    color: var(--text);
}

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

/* Progress */
.tun-progress-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
}

.tun-progress-item {
    padding: 20px;
    border-radius: 22px;
    background: #ffffff;
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
}

.tun-progress-top {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.tun-progress-top span {
    color: var(--heading);
    font-weight: 900;
}

.tun-progress-top strong {
    color: var(--primary);
}

.tun-progress-bar {
    position: relative;
    overflow: hidden;
    height: 11px;
    border-radius: 999px;
    background: rgba(10, 102, 194, 0.10);
}

.tun-progress-bar span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    box-shadow: 0 0 18px rgba(0, 212, 255, 0.38);
}

/* Contact */
.tun-contact-box {
    position: relative;
    overflow: hidden;
    padding: 42px;
    border-radius: 32px;
    background:
        radial-gradient(circle at top right, rgba(0, 212, 255, 0.18), transparent 38%),
        linear-gradient(135deg, #071827, #0a2440);
    color: #ffffff;
    box-shadow: 0 28px 80px rgba(7, 24, 39, 0.22);
}

.tun-contact-box h2 {
    margin: 0 0 16px;
    color: #ffffff;
    font-size: clamp(30px, 4vw, 44px);
    line-height: 1.18;
    letter-spacing: -1px;
}

.tun-contact-box p {
    margin: 0 0 26px;
    color: rgba(220, 239, 255, 0.88);
    font-size: 17px;
    max-width: 860px;
}

.tun-contact-box .tun-section-label {
    color: #ffffff;
    background: rgba(0, 212, 255, 0.13);
    border: 1px solid rgba(0, 212, 255, 0.20);
}

/* Responsive */
@media (max-width: 1024px) {

    .tun-about-hero-grid,
    .tun-info-grid,
    .tun-skill-grid,
    .tun-progress-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .tun-about-hero-content {
        grid-column: span 2;
    }
}

@media (max-width: 768px) {
    .tun-about-hero {
        padding: 54px 0 34px;
    }

    .tun-about-hero-grid,
    .tun-info-grid,
    .tun-skill-grid,
    .tun-progress-grid {
        grid-template-columns: 1fr;
    }

    .tun-about-hero-content {
        grid-column: auto;
    }

    .tun-about-hero-content h2 {
        font-size: 34px;
    }

    .tun-story-box,
    .tun-contact-box {
        padding: 24px;
        border-radius: 24px;
    }

    .tun-timeline::before {
        left: 8px;
    }

    .tun-timeline-item {
        grid-template-columns: 1fr;
        gap: 14px;
        padding-left: 28px;
    }

    .tun-timeline-date {
        justify-content: flex-start;
        width: fit-content;
    }

    .tun-timeline-content::before {
        left: -27px;
        top: 24px;
    }
}

/* =========================================================
   TUNLAMWEB PORTFOLIO / PROJECT COMPLETE STYLE
   Dành cho post type featured_item của Flatsome
========================================================= */

/* =========================================================
   1. PROJECT COMMON
========================================================= */

.tun-project-archive-main,
.tun-project-single-main {
    background:
        radial-gradient(circle at 12% 8%, rgba(0, 212, 255, 0.12), transparent 28%),
        radial-gradient(circle at 88% 12%, rgba(10, 102, 194, 0.12), transparent 30%),
        linear-gradient(180deg, #f8fbff 0%, var(--bg) 100%);
    overflow: hidden;
}

.tun-project-grid,
.tun-project-archive-grid {
    width: 100%;
    max-width: 100%;
}

.tun-project-empty {
    padding: 28px;
    border-radius: 24px;
    background: #ffffff;
    border: 1px solid rgba(10, 102, 194, 0.10);
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.08);
}

.tun-project-empty h3 {
    margin: 0 0 8px;
    color: var(--heading);
    font-size: 22px;
    font-weight: 900;
}

.tun-project-empty p {
    margin: 0;
    color: var(--muted);
}


/* =========================================================
   2. PROJECT CARD - DÙNG CHO SECTION DỰ ÁN NỔI BẬT
========================================================= */

.tun-project-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
}

.tun-project-featured-grid {
    margin-top: 28px;
}

.tun-project-card {
    position: relative;
    overflow: hidden;
    border-radius: 28px;
    background:
        radial-gradient(circle at top right, rgba(0, 212, 255, 0.10), transparent 42%),
        #ffffff;
    border: 1px solid rgba(10, 102, 194, 0.10);
    box-shadow:
        0 18px 45px rgba(15, 23, 42, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.9);
    transition:
        transform 0.42s cubic-bezier(0.16, 1, 0.3, 1),
        box-shadow 0.35s ease,
        border-color 0.35s ease;
}

.tun-project-card:hover {
    transform: translateY(-8px);
    border-color: rgba(0, 212, 255, 0.30);
    box-shadow:
        0 28px 68px rgba(15, 23, 42, 0.14),
        0 0 0 1px rgba(0, 212, 255, 0.12);
}

/* Ảnh ngang 16/8 không mất hình */
.tun-project-thumb {
    position: relative;
    display: block;
    width: 100%;
    aspect-ratio: 16 / 8;
    overflow: hidden;
    background:
        radial-gradient(circle at top right, rgba(0, 212, 255, 0.18), transparent 38%),
        linear-gradient(135deg, #eef8ff, #ffffff);
}

.tun-project-thumb img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    padding: 10px;
    border-radius: 22px;
    transition:
        transform 0.58s cubic-bezier(0.16, 1, 0.3, 1),
        filter 0.35s ease;
}

.tun-project-card:hover .tun-project-thumb img {
    transform: scale(1.025);
    filter: saturate(1.05) contrast(1.03);
}

/* Overlay nhẹ */
.tun-project-thumb::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(to bottom,
            transparent 45%,
            rgba(7, 24, 39, 0.42));
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.35s ease;
}

.tun-project-card:hover .tun-project-thumb::after {
    opacity: 1;
}

/* Nút xem dự án trên ảnh */
.tun-project-view {
    position: absolute;
    left: 18px;
    bottom: 18px;
    z-index: 3;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.94);
    color: var(--primary);
    font-size: 13px;
    font-weight: 900;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transform: translateY(10px);
    opacity: 0;
    transition:
        transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
        opacity 0.35s ease,
        background-color 0.35s ease,
        color 0.35s ease;
}

.tun-project-card:hover .tun-project-view {
    transform: translateY(0);
    opacity: 1;
}

.tun-project-view:hover {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: #ffffff;
}

/* Không có ảnh */
.tun-project-no-thumb {
    width: 100%;
    height: 100%;
    min-height: 220px;
    display: grid;
    place-items: center;
    color: #ffffff;
    font-size: 42px;
    background:
        radial-gradient(circle at top right, rgba(255, 255, 255, 0.28), transparent 35%),
        linear-gradient(135deg, var(--primary), var(--secondary));
}

.tun-project-body {
    padding: 22px;
}

.tun-project-cats {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
}

.tun-project-cats span,
.tun-project-cats a {
    display: inline-flex;
    align-items: center;
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(10, 102, 194, 0.08);
    color: var(--primary);
    font-size: 12px;
    font-weight: 900;
    line-height: 1.2;
}

.tun-project-cats a:hover {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: #ffffff;
}

.tun-project-body h3 {
    margin: 0 0 10px;
    color: var(--heading);
    font-size: 21px;
    line-height: 1.35;
    font-weight: 900;
    letter-spacing: -0.35px;
}

.tun-project-body h3 a {
    color: inherit;
}

.tun-project-body h3 a:hover {
    color: var(--primary);
}

.tun-project-body p {
    margin: 0;
    color: var(--muted);
    font-size: 15px;
    line-height: 1.7;
}

.tun-project-more {
    margin-top: 32px;
    text-align: center;
}

.tun-project-more .tun-about-btn {
    gap: 8px;
}


/* =========================================================
   3. PROJECT ARCHIVE HERO
========================================================= */

.tun-project-archive-hero {
    position: relative;
    padding: 76px 0 52px;
    overflow: hidden;
}

.tun-project-archive-hero::before,
.tun-project-single-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(10, 102, 194, 0.045) 1px, transparent 1px),
        linear-gradient(90deg, rgba(10, 102, 194, 0.045) 1px, transparent 1px);
    background-size: 36px 36px;
    pointer-events: none;
}

.tun-project-archive-hero .container,
.tun-project-single-hero .container {
    position: relative;
    z-index: 2;
}

.tun-project-archive-hero h1 {
    margin: 0 0 16px;
    color: var(--heading);
    font-size: clamp(38px, 5vw, 62px);
    line-height: 1.1;
    letter-spacing: -1.6px;
    font-weight: 900;
}

.tun-project-archive-hero p,
.tun-project-tax-desc {
    max-width: 760px;
    margin: 0;
    color: var(--muted);
    font-size: 18px;
    line-height: 1.8;
}

.tun-project-archive-section {
    padding: 24px 0 76px;
}


/* =========================================================
   4. PROJECT FILTER
========================================================= */

.tun-project-filter {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 30px;
}

.tun-project-filter a {
    display: inline-flex;
    align-items: center;
    padding: 9px 14px;
    border-radius: 999px;
    background: #ffffff;
    border: 1px solid rgba(10, 102, 194, 0.12);
    color: var(--heading);
    font-size: 14px;
    font-weight: 800;
    box-shadow: 0 8px 22px rgba(15, 23, 42, 0.05);
    transition:
        transform 0.32s cubic-bezier(0.16, 1, 0.3, 1),
        background-color 0.3s ease,
        color 0.3s ease,
        border-color 0.3s ease;
}

.tun-project-filter a:hover,
.tun-project-filter a.active {
    color: #ffffff;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-color: transparent;
    transform: translateY(-2px);
}


/* =========================================================
   5. PROJECT ARCHIVE CARD - LAYOUT KHÁC SECTION NỔI BẬT
========================================================= */

.tun-project-archive-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px;
}

.tun-project-archive-card {
    display: grid;
    grid-template-columns: 48% minmax(0, 1fr);
    min-height: 280px;
    overflow: hidden;
    border-radius: 30px;
    background:
        radial-gradient(circle at top right, rgba(0, 212, 255, 0.10), transparent 42%),
        #ffffff;
    border: 1px solid rgba(10, 102, 194, 0.10);
    box-shadow:
        0 18px 45px rgba(15, 23, 42, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.9);
    transition:
        transform 0.42s cubic-bezier(0.16, 1, 0.3, 1),
        box-shadow 0.35s ease,
        border-color 0.35s ease;
}

.tun-project-archive-card:hover {
    transform: translateY(-8px);
    border-color: rgba(0, 212, 255, 0.30);
    box-shadow:
        0 28px 68px rgba(15, 23, 42, 0.14),
        0 0 0 1px rgba(0, 212, 255, 0.12);
}

/* Ảnh archive: 16/8, không bị mất hình */
.tun-project-archive-thumb {
    position: relative;
    display: block;
    width: 100%;
    height: 100%;
    min-height: 260px;
    overflow: hidden;
    background:
        radial-gradient(circle at top right, rgba(0, 212, 255, 0.18), transparent 38%),
        linear-gradient(135deg, #eef8ff, #ffffff);
}

.tun-project-archive-thumb img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    padding: 10px;
    transition:
        transform 0.58s cubic-bezier(0.16, 1, 0.3, 1),
        filter 0.35s ease;
}

.tun-project-archive-card:hover .tun-project-archive-thumb img {
    transform: scale(1.025);
    filter: saturate(1.05) contrast(1.03);
}

.tun-project-archive-overlay {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: flex;
    align-items: flex-end;
    padding: 20px;
    background:
        linear-gradient(to bottom,
            transparent 45%,
            rgba(7, 24, 39, 0.42));
    opacity: 0;
    transition: opacity 0.35s ease;
}

.tun-project-archive-card:hover .tun-project-archive-overlay {
    opacity: 1;
}

.tun-project-archive-overlay span {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.94);
    color: var(--primary);
    font-size: 13px;
    font-weight: 900;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.tun-project-archive-body {
    padding: 26px;
    min-width: 0;
}

.tun-project-archive-body h2 {
    margin: 0 0 12px;
    color: var(--heading);
    font-size: 24px;
    line-height: 1.28;
    letter-spacing: -0.5px;
    font-weight: 900;
}

.tun-project-archive-body h2 a {
    color: inherit;
}

.tun-project-archive-body h2 a:hover {
    color: var(--primary);
}

.tun-project-archive-body p {
    margin: 0 0 18px;
    color: var(--muted);
    line-height: 1.75;
}

.tun-project-readmore {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--primary);
    font-weight: 900;
}

.tun-project-readmore i {
    transition: transform 0.3s ease;
}

.tun-project-readmore:hover i {
    transform: translateX(5px);
}

.tun-project-pagination {
    margin-top: 36px;
}


/* =========================================================
   6. PROJECT SINGLE HERO
========================================================= */

.tun-project-single-hero {
    position: relative;
    padding: 76px 0 54px;
    overflow: hidden;
}

.tun-project-single-hero-grid {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
    gap: 42px;
    align-items: center;
}

.tun-project-single-info h1 {
    margin: 0 0 18px;
    color: var(--heading);
    font-size: clamp(38px, 5vw, 62px);
    line-height: 1.1;
    letter-spacing: -1.6px;
    font-weight: 900;
}

.tun-project-single-info p {
    margin: 0 0 20px;
    color: var(--muted);
    font-size: 18px;
    line-height: 1.8;
}

.tun-project-single-info .tun-project-cats {
    margin: 18px 0 0;
}

/* Meta */
.tun-project-single-meta {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    margin-top: 24px;
}

.tun-project-single-meta div {
    padding: 16px;
    border-radius: 18px;
    background: #ffffff;
    border: 1px solid rgba(10, 102, 194, 0.10);
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.06);
}

.tun-project-single-meta span {
    display: block;
    color: var(--muted);
    font-size: 13px;
    font-weight: 800;
    margin-bottom: 5px;
}

.tun-project-single-meta strong {
    color: var(--heading);
    font-weight: 900;
}

/* Ảnh chi tiết dự án */
.tun-project-single-preview {
    position: relative;
    display: block;
    width: 100%;
    aspect-ratio: 16 / 8;
    overflow: hidden;
    border-radius: 32px;
    background:
        radial-gradient(circle at top right, rgba(0, 212, 255, 0.18), transparent 38%),
        linear-gradient(135deg, #eef8ff, #ffffff);
    border: 1px solid rgba(10, 102, 194, 0.12);
    box-shadow: 0 28px 80px rgba(15, 23, 42, 0.14);
}

.tun-project-single-preview img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    padding: 12px;
    transition:
        transform 0.58s cubic-bezier(0.16, 1, 0.3, 1),
        filter 0.35s ease;
}

.tun-project-single-preview:hover img {
    transform: scale(1.02);
    filter: saturate(1.05) contrast(1.03);
}


/* =========================================================
   7. PROJECT SINGLE CONTENT
========================================================= */

.tun-project-single-content-section {
    padding: 26px 0 76px;
}

.tun-project-single-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 330px;
    gap: 32px;
    align-items: start;
}

.tun-project-single-content {
    min-width: 0;
    padding: 38px;
    border-radius: 30px;
    background: rgba(255, 255, 255, 0.94);
    border: 1px solid rgba(226, 232, 240, 0.9);
    box-shadow: 0 20px 60px rgba(15, 23, 42, 0.08);
}

.tun-project-single-content .entry-content {
    font-size: 17px;
    line-height: 1.85;
}

.tun-project-single-content .entry-content img {
    max-width: 100%;
    height: auto;
    border-radius: 18px;
}

/* Sidebar chi tiết */
.tun-project-single-sidebar {
    position: sticky;
    top: 100px;
    display: grid;
    gap: 18px;
}

.tun-project-side-box {
    padding: 22px;
    border-radius: 24px;
    background: #ffffff;
    border: 1px solid rgba(10, 102, 194, 0.10);
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.08);
}

.tun-project-side-box h3 {
    margin: 0 0 16px;
    color: var(--heading);
    font-size: 21px;
    font-weight: 900;
}

.tun-project-side-box ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.tun-project-side-box li {
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
}

.tun-project-side-box li:last-child {
    border-bottom: 0;
}

.tun-project-side-box span {
    display: block;
    color: var(--muted);
    font-size: 13px;
    font-weight: 800;
    margin-bottom: 3px;
}

.tun-project-side-box strong {
    color: var(--heading);
    font-weight: 900;
    line-height: 1.45;
}

.tun-project-cta-box {
    background:
        radial-gradient(circle at top right, rgba(0, 212, 255, 0.15), transparent 42%),
        linear-gradient(135deg, #071827, #0a2440);
    color: #ffffff;
}

.tun-project-cta-box h3 {
    color: #ffffff;
}

.tun-project-cta-box p {
    color: rgba(220, 239, 255, 0.86);
    line-height: 1.75;
}

.tun-project-cta-box .tun-about-btn {
    margin-top: 10px;
}


/* =========================================================
   8. RELATED PROJECTS
========================================================= */

.tun-project-related-section {
    padding: 0 0 78px;
}

.tun-project-related-section .tun-section-heading {
    margin-bottom: 28px;
}


/* =========================================================
   9. RESPONSIVE
========================================================= */

@media (max-width: 1100px) {
    .tun-project-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .tun-project-archive-grid {
        grid-template-columns: 1fr;
    }

    .tun-project-single-hero-grid,
    .tun-project-single-layout {
        grid-template-columns: 1fr;
    }

    .tun-project-single-sidebar {
        position: static;
    }
}

@media (max-width: 768px) {

    .tun-project-archive-hero,
    .tun-project-single-hero {
        padding: 52px 0 34px;
    }

    .tun-project-archive-hero h1,
    .tun-project-single-info h1 {
        font-size: 36px;
        letter-spacing: -0.8px;
    }

    .tun-project-archive-hero p,
    .tun-project-single-info p {
        font-size: 16px;
    }

    .tun-project-grid {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .tun-project-archive-card {
        grid-template-columns: 1fr;
        min-height: auto;
        border-radius: 24px;
    }

    .tun-project-archive-thumb {
        height: auto;
        min-height: auto;
        aspect-ratio: 16 / 8;
    }

    .tun-project-archive-body,
    .tun-project-body {
        padding: 18px;
    }

    .tun-project-archive-body h2,
    .tun-project-body h3 {
        font-size: 20px;
    }

    .tun-project-single-preview {
        border-radius: 24px;
    }

    .tun-project-single-content {
        padding: 24px;
        border-radius: 24px;
    }

    .tun-project-single-meta {
        grid-template-columns: 1fr;
    }

    .tun-project-view {
        opacity: 1;
        transform: translateY(0);
    }

    .tun-project-archive-overlay {
        opacity: 1;
    }
}

@media (max-width: 480px) {

    .tun-project-thumb img,
    .tun-project-archive-thumb img,
    .tun-project-single-preview img {
        padding: 6px;
    }

    .tun-project-cats span,
    .tun-project-cats a {
        font-size: 11px;
    }
}

/* =========================================================
   ABOUT PAGE - FEATURED PORTFOLIO TABS
========================================================= */

.tun-portfolio-tabs {
    position: relative;
    margin-top: 28px;
}

.tun-portfolio-tab-nav {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 28px;
    padding: 8px;
    border-radius: 999px;
    width: fit-content;
    max-width: 100%;
    background: rgba(255, 255, 255, 0.76);
    border: 1px solid rgba(10, 102, 194, 0.10);
    box-shadow:
        0 16px 42px rgba(15, 23, 42, 0.07),
        inset 0 1px 0 rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.tun-portfolio-tab-btn {
    border: 0;
    min-height: 42px;
    padding: 10px 16px;
    border-radius: 999px;
    background: transparent;
    color: var(--heading);
    font-size: 14px;
    font-weight: 900;
    cursor: pointer;
    transition:
        transform 0.3s cubic-bezier(0.16, 1, 0.3, 1),
        background-color 0.3s ease,
        color 0.3s ease,
        box-shadow 0.3s ease;
}

.tun-portfolio-tab-btn:hover {
    color: var(--primary);
    transform: translateY(-2px);
}

.tun-portfolio-tab-btn.active {
    color: #ffffff;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    box-shadow: 0 12px 26px rgba(10, 102, 194, 0.22);
}

.tun-portfolio-tab-panel {
    display: none;
    animation: tunPortfolioFadeUp 0.38s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.tun-portfolio-tab-panel.active {
    display: block;
}

.tun-portfolio-more {
    margin-top: 34px;
    text-align: center;
}

.tun-portfolio-more .tun-about-btn {
    gap: 8px;
}

/* Dùng lại grid dự án nhưng căn spacing cho section about */
#tun-projects .tun-project-grid {
    margin-top: 0;
}

#tun-projects .tun-project-card {
    height: 100%;
}

#tun-projects .tun-project-thumb {
    aspect-ratio: 16 / 8;
}

#tun-projects .tun-project-thumb img {
    object-fit: contain;
    padding: 10px;
}

/* Mobile */
@media (max-width: 768px) {
    .tun-portfolio-tab-nav {
        width: 100%;
        border-radius: 22px;
        justify-content: flex-start;
    }

    .tun-portfolio-tab-btn {
        flex: 1 1 auto;
        min-width: auto;
    }
}

@keyframes tunPortfolioFadeUp {
    from {
        opacity: 0;
        transform: translateY(14px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* =========================================================
   TUNLAMWEB - CUSTOM SCROLLBAR
========================================================= */

/* Chrome, Edge, Safari */
::-webkit-scrollbar {
    width: 12px;
}

::-webkit-scrollbar-track {
    background: #eaf6ff;
    border-left: 1px solid rgba(10, 102, 194, 0.08);
}

::-webkit-scrollbar-thumb {
    border-radius: 999px;
    border: 3px solid #eaf6ff;
    background:
        linear-gradient(180deg,
            var(--primary),
            var(--secondary));
    box-shadow:
        inset 0 0 0 1px rgba(255, 255, 255, 0.22),
        0 0 14px rgba(0, 212, 255, 0.35);
}

::-webkit-scrollbar-thumb:hover {
    background:
        linear-gradient(180deg,
            #00D4FF,
            #0A66C2);
}

/* Firefox */
html {
    scrollbar-width: thin;
    scrollbar-color: var(--primary) #eaf6ff;
}

/* =========================================================
   FINAL FIX - SINGLE POST MOBILE OVERFLOW
   Dán ở cuối file để ghi đè mọi CSS cũ
========================================================= */

html,
body {
    max-width: 100%;
    overflow-x: hidden;
}

body {
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.site-main,
.single-section,
.single-section .container,
.content-layout,
.single-layout,
.main-content,
.single-post,
.entry-content,
.sidebar {
    max-width: 100%;
    min-width: 0;
}

.single-layout,
.content-layout {
    width: 100%;
}

.single-post * {
    box-sizing: border-box;
}

.single-header h1,
.single-excerpt,
.entry-content,
.entry-content p,
.entry-content li,
.entry-content a,
.post-tags,
.post-navigation a {
    max-width: 100%;
    overflow-wrap: anywhere;
    word-break: normal;
}

.entry-content img,
.entry-content figure,
.entry-content .wp-block-image,
.single-thumb,
.single-thumb img,
.single-post figure,
.single-post figure img {
    max-width: 100% !important;
}

.entry-content iframe,
.entry-content video,
.entry-content embed,
.entry-content object {
    display: block;
    width: 100% !important;
    max-width: 100% !important;
}

.entry-content table {
    display: block;
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    border-collapse: collapse;
}

.entry-content pre {
    max-width: 100%;
    overflow-x: auto;
    white-space: pre-wrap;
    word-break: break-word;
}

.entry-content code {
    white-space: pre-wrap;
    word-break: break-word;
}

/* Box xem thêm bài viết khác */
.tun-random-readmore-box {
    width: 100%;
    max-width: 100%;
    overflow: hidden;
}

.tun-random-readmore-list,
.tun-random-readmore-list li,
.tun-random-readmore-list a {
    width: 100%;
    max-width: 100%;
    min-width: 0;
}

.tun-random-readmore-list a {
    display: flex;
    align-items: center;
}

.tun-random-readmore-icon {
    flex: 0 0 32px;
}

.tun-random-readmore-text {
    display: block;
    flex: 1 1 auto;
    min-width: 0;
    max-width: 100%;
    overflow-wrap: anywhere;
    word-break: normal;
}

@media (max-width: 920px) {

    .content-layout,
    .single-layout {
        display: grid;
        grid-template-columns: 1fr !important;
        gap: 28px;
    }

    .sidebar {
        position: static;
        width: 100%;
    }
}

@media (max-width: 768px) {
    .single-section {
        padding: 34px 0 !important;
    }

    .single-section .container,
    .container {
        width: min(100% - 24px, 1180px) !important;
        max-width: 100% !important;
    }

    .single-layout .single-post,
    .single-post {
        width: 100%;
        max-width: 100%;
        padding: 20px !important;
        border-radius: 22px !important;
        overflow: hidden;
    }

    .single-header {
        margin-bottom: 22px;
    }

    .single-header h1 {
        font-size: 30px !important;
        line-height: 1.22 !important;
        letter-spacing: -0.6px;
    }

    .single-excerpt {
        font-size: 16px;
        line-height: 1.7;
    }

    .single-meta {
        gap: 8px;
    }

    .single-meta span {
        font-size: 12px;
        padding: 6px 9px;
    }

    .single-author {
        align-items: flex-start;
    }

    .entry-content {
        font-size: 16px !important;
        line-height: 1.8;
        max-width: 100%;
    }

    .entry-content h2 {
        font-size: 24px !important;
        line-height: 1.3;
    }

    .entry-content h3 {
        font-size: 21px !important;
        line-height: 1.32;
    }

    .entry-content ul,
    .entry-content ol {
        padding-left: 22px;
    }

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

    .tun-random-readmore-box {
        margin: 24px 0;
        padding: 16px !important;
        border-radius: 18px !important;
    }

    .tun-random-readmore-title span {
        font-size: 16px !important;
        line-height: 1.35;
    }

    .tun-random-readmore-list a {
        align-items: flex-start;
        gap: 10px;
        padding: 12px !important;
        border-radius: 14px;
        font-size: 15px;
        line-height: 1.45;
    }

    .tun-random-readmore-icon {
        width: 28px !important;
        height: 28px !important;
        min-width: 28px !important;
        flex-basis: 28px;
        font-size: 12px;
        margin-top: 2px;
    }

    .tun-random-readmore-text {
        font-size: 15px;
        line-height: 1.45;
    }

    .post-navigation {
        grid-template-columns: 1fr !important;
    }

    .post-navigation a {
        overflow-wrap: anywhere;
    }
}

@media (max-width: 480px) {

    .single-section .container,
    .container {
        width: min(100% - 18px, 1180px) !important;
    }

    .single-layout .single-post,
    .single-post {
        padding: 16px !important;
        border-radius: 18px !important;
    }

    .single-header h1 {
        font-size: 27px !important;
    }

    .entry-content {
        font-size: 15.8px !important;
    }

    .tun-random-readmore-box {
        padding: 14px !important;
    }

    .tun-random-readmore-list a {
        padding: 11px !important;
    }
}

/* Chặn các phần tử có style width cố định từ Gutenberg/shortcode/plugin */
@media (max-width: 768px) {
    .single-post [style*="width"] {
        max-width: 100% !important;
    }
}
/* =========================================================
   GLOBAL SCROLL TO - SLIDE DOWN EFFECT
   Dùng chung cho mọi section có id
========================================================= */

html {
    scroll-behavior: smooth;
}

/* Tự chừa khoảng header khi scroll tới section */
[id] {
    scroll-margin-top: var(--tun-scroll-offset, 110px);
}

/* Mobile */
@media (max-width: 768px) {
    [id] {
        scroll-margin-top: var(--tun-scroll-offset-mobile, 90px);
    }
}

/* Khi section được scroll tới */
.tun-scroll-active {
    animation: tunScrollSlideDown 0.85s cubic-bezier(0.16, 1, 0.3, 1) both;
}

/* Hiệu ứng trượt từ trên xuống */
@keyframes tunScrollSlideDown {
    0% {
        opacity: 0;
        transform: translate3d(0, -38px, 0);
        filter: blur(6px);
    }

    60% {
        opacity: 1;
        transform: translate3d(0, 6px, 0);
        filter: blur(0);
    }

    100% {
        opacity: 1;
        transform: translate3d(0, 0, 0);
        filter: blur(0);
    }
}

/* Tôn trọng người dùng tắt motion */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .tun-scroll-active {
        animation: none !important;
    }
}


/* =========================================================
   FIX SIDEBAR STICKY ONLY
   Chỉ fix sticky sidebar, không thay đổi các style khác
========================================================= */

/* Cho phép sticky hoạt động trong các khung cha chính */
.content-layout,
.single-layout,
.main-content,
.archive-content,
.single-section,
.site-main {
    overflow: visible !important;
}

/* Không để grid kéo sidebar cao bằng cột nội dung */
.content-layout,
.single-layout {
    align-items: start !important;
}

/* Sticky sidebar */
.sidebar {
    position: sticky !important;
    top: 100px;
    align-self: start;
    height: fit-content;
    z-index: 10;
}

/* Trang chi tiết bài viết */
.single-layout .sidebar {
    position: sticky !important;
    top: 100px;
    align-self: start;
}

/* Mobile/tablet: tắt sticky để tránh lỗi bố cục */
@media (max-width: 920px) {
    .sidebar,
    .single-layout .sidebar {
        position: static !important;
        top: auto;
        align-self: auto;
        height: auto;
    }
}

/* =========================================================
   FIX SIDEBAR STICKY ONLY - STRONG VERSION
   Chỉ fix sticky sidebar, không đổi style widget/card
========================================================= */

/* Các thẻ cha không được chặn sticky */
html,
body,
.site-main,
.archive-content,
.single-section,
.featured-section,
.category-section,
.content-layout,
.single-layout,
.main-content,
.container {
    overflow: visible !important;
}

/* Riêng body chỉ chặn ngang nếu cần, không dùng overflow hidden toàn bộ */
body {
    overflow-x: clip !important;
}

@supports not (overflow: clip) {
    body {
        overflow-x: hidden !important;
    }
}

/* Layout phải align start để sidebar không bị kéo cao bằng content */
.content-layout,
.single-layout {
    align-items: start !important;
}

/* Sidebar sticky chính */
.sidebar {
    position: -webkit-sticky !important;
    position: sticky !important;
    top: 100px !important;
    align-self: start !important;
    height: fit-content !important;
    z-index: 10;
}

/* Nếu sidebar nằm trong single layout */
.single-layout .sidebar {
    position: -webkit-sticky !important;
    position: sticky !important;
    top: 100px !important;
    align-self: start !important;
    height: fit-content !important;
}

/* Tablet/mobile tắt sticky để không lỗi bố cục */
@media (max-width: 920px) {
    .sidebar,
    .single-layout .sidebar {
        position: static !important;
        top: auto !important;
        align-self: auto !important;
        height: auto !important;
    }
}