

.cl-page {
    margin: 0;
    padding: 0;
    background: #fff;
    color: #1a1a2e;
    font-family: "DM Sans", sans-serif;
    -webkit-font-smoothing: antialiased;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ── CSS Variables ───────────────────────────────────────── */
:root {
    --cl-accent:        #3b6ef8;
    --cl-accent-hover:  #2a55d6;
    --cl-text:          #1a1a2e;
    --cl-muted:         #888;
    --cl-border:        #e8e8ef;
    --cl-card-bg:       #ffffff;
    --cl-radius:        14px;
    --cl-shadow:        0 2px 16px rgba(0, 0, 0, 0.06);
    --cl-shadow-hover:  0 8px 32px rgba(0, 0, 0, 0.12);
    --cl-header-h:      68px;

    /* Tag colours */
    --cl-tag-new:       #E64B5F;
    --cl-tag-bugfix:    #FE8425;
    --cl-tag-improved:  #008AFF;
    --cl-tag-default:   #008AFF;
}

/* ═══════════════════════════════════════════════════════════
   SITE HEADER
═══════════════════════════════════════════════════════════ */
.cl-site-header {
    position: sticky;
    top: 0;
    z-index: 500;
    background: #fff;
    border-bottom: 1px solid var(--cl-border);
    height: var(--cl-header-h);
}

.cl-site-header__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 32px;
    height: 100%;
    gap: 32px;
}

/* Logo / site name */
.cl-site-header__logo {
    display: inline-flex;
    align-items: center;
    flex-shrink: 0;
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--cl-text);
    gap: 10px;
}

.cl-site-header__logo img {
    height: 36px;
    width: auto;
    display: block;
}

/* Nav menu */
.cl-site-header__nav { flex: 1; }

.cl-nav-menu {
    display: flex;
    align-items: center;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 4px;
}

.cl-nav-menu li { position: relative; }

.cl-nav-menu a {
    display: block;
    padding: 8px 14px;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--cl-text);
    text-decoration: none;
    border-radius: 7px;
    transition: background 0.15s, color 0.15s;
    white-space: nowrap;
}

.cl-nav-menu a:hover,
.cl-nav-menu .current-menu-item > a,
.cl-nav-menu .current-menu-ancestor > a {
    background: #f0f4ff;
    color: var(--cl-accent);
}

/* Dropdown sub-menu */
.cl-nav-menu .sub-menu {
    display: none;
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    min-width: 200px;
    background: #fff;
    border: 1px solid var(--cl-border);
    border-radius: 10px;
    box-shadow: var(--cl-shadow-hover);
    list-style: none;
    margin: 0;
    padding: 6px;
    z-index: 600;
}

.cl-nav-menu li:hover > .sub-menu { display: block; }

.cl-nav-menu .sub-menu a {
    border-radius: 6px;
    padding: 8px 12px;
}

/* Hamburger (hidden on desktop) */
.cl-nav-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 36px;
    height: 36px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    flex-shrink: 0;
}

.cl-nav-toggle span {
    display: block;
    height: 2px;
    width: 100%;
    background: var(--cl-text);
    border-radius: 2px;
    transition: transform 0.2s, opacity 0.2s;
}

/* Open state */
.cl-nav-toggle.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.cl-nav-toggle.is-open span:nth-child(2) { opacity: 0; }
.cl-nav-toggle.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ═══════════════════════════════════════════════════════════
   SITE FOOTER
═══════════════════════════════════════════════════════════ */
.cl-site-footer {
    margin-top: auto;
    border-top: 1px solid var(--cl-border);
    background: #fff;
}

.cl-site-footer__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 32px;
}

.cl-site-footer__copy {
    font-size: 0.85rem;
    color: var(--cl-muted);
}

.cl-site-footer__copy a {
    color: var(--cl-muted);
    text-decoration: none;
}

.cl-site-footer__copy a:hover { color: var(--cl-accent); }

.cl-footer-menu {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 4px;
}

.cl-footer-menu a {
    font-size: 0.85rem;
    color: var(--cl-muted);
    text-decoration: none;
    padding: 4px 10px;
    border-radius: 5px;
    transition: color 0.15s;
}

.cl-footer-menu a:hover { color: var(--cl-accent); }

/* ═══════════════════════════════════════════════════════════
   PAGE WRAPPERS
═══════════════════════════════════════════════════════════ */

/* Archive page wrapper */
.cl-archive-page {
    flex: 1;
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
}

.cl-archive-heading {
    font-size: 2.2rem;
    font-weight: 700;
    letter-spacing: -0.04em;
    color: var(--cl-text);
    margin: 0 0 8px;
}

.cl-archive-subheading {
    font-size: 1rem;
    color: var(--cl-muted);
    margin: 0 0 52px;
}

/* Single page wrapper */
.cl-single-wrap {
    display: flex;
    gap: 100px;
    max-width: 1000px;
    width: 100%;
    margin: 148px auto 80px;
    align-items: flex-start;
    flex: 1;
}

/* ═══════════════════════════════════════════════════════════
   SINGLE PAGE — LEFT SIDEBAR
═══════════════════════════════════════════════════════════ */
.cl-single-sidebar {
    flex: 0 0 150px;
    position: sticky;
    top: calc(var(--cl-header-h) + 20px);
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 18px 16px;
    border: 1px solid var(--cl-border);
    border-radius: 5px;
    background: #fff;
}

.cl-back-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--cl-accent);
    text-decoration: none;
    transition: gap 0.15s ease;
}
a.cl-back-link:focus {
    outline: none!important;
    box-shadow: none!important;

}

.cl-back-link:hover { gap: 10px; }

.cl-single-date {
    display: block;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--cl-text);
}

.cl-single-version {
    display: block;
    font-size: 28px;
    font-weight: 600;
    color: #000;
}

/* ═══════════════════════════════════════════════════════════
   SINGLE PAGE — MAIN CONTENT
═══════════════════════════════════════════════════════════ */


.cl-single-thumbnail {
    border-radius: var(--cl-radius);
    overflow: hidden;
    margin-bottom: 40px;
    line-height: 0;
}

.cl-single-thumbnail img {
    width: 100%;
    height: auto;
    display: block;
}

.cl-single-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 18px;
}

.cl-single-title {
    font-size: 2rem;
    font-weight: 700;
    line-height: 1.3;
    color: var(--cl-text);
    letter-spacing: -0.03em;
    margin: 0 0 20px;
}

/* Prose content */
.cl-single-content { font-size: 1rem; line-height: 1.8; color: #444; }
.cl-single-content p                 { margin: 0 0 1.2em; }
.cl-single-content h2,
.cl-single-content h3,
.cl-single-content h4                { color: var(--cl-text); margin: 1.8em 0 .6em; font-weight: 700; }
.cl-single-content ul,
.cl-single-content ol                { padding-left: 1.5em; margin-bottom: 1.2em; }
.cl-single-content li                { margin-bottom: .4em; }
.cl-single-content a                 { color: var(--cl-accent); text-underline-offset: 3px; }
.cl-single-content img               { max-width: 100%; border-radius: 8px; margin: 1em 0; }
.cl-single-content blockquote {
    border-left: 3px solid var(--cl-accent);
    margin: 1.5em 0;
    padding: .5em 0 .5em 1.2em;
    color: #666;
    font-style: italic;
}
.cl-single-content code {
    background: #f3f4f6;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: .88em;
}
.cl-single-content pre {
    background: #1a1a2e;
    color: #e8e8ef;
    padding: 20px;
    border-radius: 10px;
    overflow-x: auto;
    margin: 1.5em 0;
}
.cl-single-content pre code { background: none; padding: 0; }

/* Prev / Next nav */
.cl-single-nav {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 52px;
    padding-top: 28px;
    border-top: 1px solid var(--cl-border);
}

.cl-nav-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: .88rem;
    font-weight: 600;
    color: var(--cl-accent);
    text-decoration: none;
    padding: 9px 18px;
    border: 1px solid var(--cl-border);
    border-radius: 8px;
    background: #fff;
    max-width: 48%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: border-color .15s, box-shadow .15s, transform .15s;
}

.cl-nav-btn:hover {
    border-color: var(--cl-accent);
    box-shadow: 0 2px 8px rgba(59, 110, 248, .15);
    transform: translateY(-1px);
    color: var(--cl-accent);
}

.cl-nav-btn.is-next { margin-left: auto; }
.cl-wrapper,
.cl-wrapper * { box-sizing: border-box; }

.cl-entry {
    display: flex;
    gap: 140px;
    padding: 148px 0;
    border-bottom: 1px solid var(--cl-border);
}

.cl-entry:last-child { border-bottom: none; }

/* Left column */
.cl-meta { 
    padding-top: 6px;
    flex-basis: 20%;
    position: sticky;
    top: 50px;
    align-self: flex-start;
    gap: 6px;
    display: flex;
    flex-direction: column;
}

.cl-version {
    display: block;
    font-size: 32px;
    font-weight: 700;
    color: #000;
    line-height: 100%;
}

.cl-date {
    display: block;
    font-size: 18px;
    color: #5C626A;
    line-height: 32px;
}

/* Right column: card */
.cl-card {
    flex-basis: 80%;
    background: var(--cl-card-bg);   
    overflow: hidden;
    transition: box-shadow 0.25s ease, transform 0.2s ease;
}
/* Thumbnail */
.cl-thumbnail { line-height: 0; overflow: hidden; }
.cl-thumbnail a { display: block; }
.cl-thumbnail img {
    width: 100%;
    display: block;
    transition: transform 0.4s ease;
}

/* Tags (shared between archive card and single page) */
.cl-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding-top: 40px;
}

.cl-tag,
.cl-stag {
    display: inline-flex;
    align-items: center;
    font-size: 16px;
    font-weight: 600;
    padding: 7px 20px;
    border-radius: 75px;
    text-decoration: none;
    color: #fff;
    line-height: 1.2;
    background: var(--cl-tag-default);
    transition: opacity 0.15s ease, transform 0.15s ease;
}

.cl-tag:hover,
.cl-stag:hover { opacity: 0.88; color: #fff; transform: translateY(-1px); }

/* Slug colour overrides */
.cl-tag--new,
.cl-stag--new                                   { background: var(--cl-tag-new); }
.cl-tag--bug-fixing,  .cl-stag--bug-fixing,
.cl-tag--bugfix,      .cl-stag--bugfix,
.cl-tag--bug-fix,     .cl-stag--bug-fix          { background: var(--cl-tag-bugfix); }
.cl-tag--improved,    .cl-stag--improved,
.cl-tag--improvement, .cl-stag--improvement,
.cl-tag--enhancement, .cl-stag--enhancement      { background: var(--cl-tag-improved); }

/* Card body */
.cl-body { 
    padding-top: 18px; 
}

.cl-title {
    margin: 0;
    font-size: 24px;
    font-weight: 700;
    line-height: 1.4;
    color: #000;
}

.cl-title a { text-decoration: none; color: inherit; transition: color 0.15s; }
.cl-title a:hover { color: var(--cl-accent); }

.cl-excerpt {
    margin-top: 18px;
    font-size: 18px;
    line-height: 1.5;
    color: #475569;
}

/* See More button */
.cl-see-more {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 18px;
    font-weight: 400;
    color: #fff;
    line-height: 32px;
    background: #0066FF;
    padding: 4px 16px;
    border-radius: 10px;
    text-decoration: none;
    transition: background 0.18s ease, transform 0.15s ease, box-shadow 0.18s ease;
    box-shadow: 0 2px 8px rgba(59, 110, 248, 0.3);
}

.cl-see-more:hover {
    background: var(--cl-accent-hover);
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(59, 110, 248, 0.4);
}

.cl-see-more svg { flex-shrink: 0; transition: transform 0.15s; }
.cl-see-more:hover svg { transform: translateX(3px); }

/* ═══════════════════════════════════════════════════════════
   PAGINATION
═══════════════════════════════════════════════════════════ */
.cl-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 48px;
    padding: 16px 0 32px;
}

.cl-page-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    font-weight: 500;
    padding: 8px 15px;
    border-radius: 8px;
    border: 1px solid #E2E2E7;
    background: #fff;
    color: #464654;
    text-decoration: none;
    cursor: pointer;
    line-height: 20px;
    transition: border-color 0.15s, background 0.15s, color 0.15s, box-shadow 0.15s;
}

.cl-page-btn:hover:not(.cl-disabled):not(.cl-active) {
    border-color: var(--cl-accent);
    color: var(--cl-accent);
    box-shadow: 0 2px 8px rgba(59, 110, 248, 0.15);
}

.cl-page-num {
    justify-content: center;
}

.cl-page-btn.cl-active {
    background: #2563EB;
    border-color: #2563EB;
    color: #fff;
    font-weight: 700;
    box-shadow: 0 2px 8px rgba(59, 110, 248, 0.35);
    cursor: default;
    pointer-events: none;
}

.cl-page-btn.cl-disabled {
    opacity: 0.4;
    cursor: not-allowed;
    pointer-events: none;
    background-color: #F1F5F9;
}

.cl-page-dots {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    color: var(--cl-muted);
    padding: 8px 4px;
    min-width: 32px;
}

/* ═══════════════════════════════════════════════════════════
   MISC
═══════════════════════════════════════════════════════════ */
.cl-empty {
    color: var(--cl-muted);
    font-style: italic;
    text-align: center;
    padding: 40px 0;
}

/* ═══════════════════════════════════════════════════════════
   RESPONSIVE
═══════════════════════════════════════════════════════════ */
@media (max-width: 1024px) {
    .cl-single-wrap {
        padding: 0 20px;
    }
}
@media (max-width: 900px) {
    .cl-site-header__inner { 
        padding: 0 20px; 
    }
    .cl-archive-page       { 
        padding: 36px 20px 60px; 
    }
    .cl-single-wrap { 
        gap: 36px; 
    }
    
}
@media (max-width: 767px){
    .cl-meta,
    .cl-single-sidebar {
        position: static;
    }
    .cl-entry {
        flex-wrap: wrap;
        gap: 60px;
        padding: 45px 0;
    }
    .cl-single-wrap        { 
        padding: 0 20px; 
        gap: 36px; 
        flex-wrap: wrap;
    }
    .cl-card,
    .cl-meta {
        flex-basis: 100%;
    }
}
