/*
Theme Name: Wesper Gadget Custom
Theme URI: https://gadgethacks.com/
Description: Custom Wesper child theme with a Gadget Hacks inspired homepage post layout.
Author: Custom
Template: wesper
Version: 1.0.0
Text Domain: wesper-gadget-custom
*/

/* ═══════════════════════════════════════════════════════════
   DESIGN TOKENS — Light (default) + Dark
═══════════════════════════════════════════════════════════ */

:root {
    --wgc-font-heading: 'Sora', system-ui, sans-serif;
    --wgc-font-body:    'Inter', system-ui, sans-serif;
    --wgc-font-mono:    'JetBrains Mono', ui-monospace, 'Fira Code', 'Courier New', monospace;

    /* Surfaces */
    --bg:        #f2f3f5;
    --bg-alt:    #e8eaef;
    --surface:   #ffffff;
    --surface-2: #f8f9fb;
    --surface-3: #f0f2f5;

    /* Typography */
    --text:      #0b0f1a;
    --text-2:    #4b5675;
    --text-3:    #8d99b0;

    /* Accents */
    --green:     #50a800;
    --green-h:   #438f00;
    --green-b:   #22d17f;
    --red:       #e0382c;
    --red-2:     #c3312c;
    --blue:      #1a73e8;
    --blue-h:    #0b57d0;

    /* Borders */
    --border:    #dce0e8;
    --border-2:  #edf0f5;

    /* Shadows */
    --sh-xs: 0 1px 3px rgba(11,15,26,.06), 0 1px 2px rgba(11,15,26,.04);
    --sh-sm: 0 2px 12px rgba(11,15,26,.08), 0 1px 4px rgba(11,15,26,.05);
    --sh-md: 0 4px 24px rgba(11,15,26,.10), 0 2px 8px rgba(11,15,26,.06);
    --sh-lg: 0 8px 40px rgba(11,15,26,.14), 0 3px 12px rgba(11,15,26,.08);

    /* Header chrome */
    --hdr:       #050608;
    --hdr-text:  #e8eaed;
    --nav-text:  #c8cdd8;
    --nav-div:   rgba(255,255,255,.18);
    --net-link:  rgba(255,255,255,.58);
    --net-act:   #c3312c;

    /* Mobile drawer */
    --drawer:    #0f1117;
    --drawer-f:  #090b10;

    /* Cyber panel (related articles) */
    --panel:     #0d1117;
    --panel-2:   #161b22;
    --panel-t:   #e2e8f0;
    --panel-m:   rgba(226,232,240,.38);
    --panel-b:   rgba(34,209,127,.10);
    --panel-b2:  rgba(34,209,127,.18);

    /* Radii */
    --r-sm:  6px;
    --r-md:  10px;
    --r-lg:  14px;
    --r-xl:  20px;
    --r-2xl: 28px;

    /* Motion */
    --ease: 0.22s ease;
    --ease-fast: 0.14s ease;

    /* Admin bar height placeholder */
    --wgc-admin-bar-h: 0px;
    --wgc-site-header-h: 106px;
}

/* ── Dark theme overrides ── */
[data-theme="dark"] {
    --bg:        #090c15;
    --bg-alt:    #050710;
    --surface:   #0f1221;
    --surface-2: #161929;
    --surface-3: #1c2034;

    --text:      #eef0ff;
    --text-2:    #a8b2d0;
    --text-3:    #5e6a90;

    --green:     #4ade80;
    --green-h:   #22c55e;
    --green-b:   #34e88a;
    --red:       #fc6b6b;
    --red-2:     #ef4444;
    --blue:      #60a5fa;
    --blue-h:    #93c5fd;

    --border:    #1e2445;
    --border-2:  #131730;

    --sh-xs: 0 1px 4px rgba(0,0,0,.5);
    --sh-sm: 0 2px 14px rgba(0,0,0,.6), 0 1px 4px rgba(0,0,0,.4);
    --sh-md: 0 4px 28px rgba(0,0,0,.7), 0 2px 8px rgba(0,0,0,.5);
    --sh-lg: 0 8px 48px rgba(0,0,0,.8), 0 3px 14px rgba(0,0,0,.6);

    --hdr:       #05060e;
    --hdr-text:  #c8d0ec;
    --nav-text:  #4f5a80;
    --nav-div:   rgba(255,255,255,.07);
    --net-link:  rgba(255,255,255,.40);

    --drawer:    #05060e;
    --drawer-f:  #030409;

    --panel:     #05060e;
    --panel-2:   #0a0c18;
    --panel-t:   #d0d8f4;
    --panel-m:   rgba(208,216,244,.28);
    --panel-b:   rgba(74,222,128,.07);
    --panel-b2:  rgba(74,222,128,.14);
}

/* ── Smooth transitions on theme switch ── */
*,
*::before,
*::after {
    transition:
        background-color var(--ease),
        border-color var(--ease),
        color var(--ease-fast),
        box-shadow var(--ease),
        fill var(--ease-fast);
}
/* But never on layout/transform/opacity driven by JS */
.wgc-slide,
.wgc-hero-slide,
.wgc-dot,
.wgc-theme-toggle,
.wgc-theme-toggle *,
.wgc-rel-arrow,
.wgc-rel-card::before,
.wgc-rel-img,
.jl_mobile_nav_wrapper,
.jl_mobile_nav_wrapper *,
img {
    transition: none;
}
img {
    -webkit-user-drag: none;
    -webkit-user-select: none;
    user-select: none;
}

/* ═══════════════════════════════════════════════════════════
   GLOBAL
═══════════════════════════════════════════════════════════ */

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    font-family: var(--wgc-font-body);
    background: var(--bg);
    color: var(--text);
}

/* ═══════════════════════════════════════════════════════════
   HEADER
═══════════════════════════════════════════════════════════ */

.wgc-site-header {
    position: relative;
    z-index: 20;
    width: 100%;
    background: var(--hdr);
    color: var(--hdr-text);
    font-family: var(--wgc-font-body);
}

/* ── Network bar ── */

.wgc-network-bar {
    display: flex;
    align-items: center;
    height: 31px;
    overflow: hidden;
    background: linear-gradient(110deg, #3a2225 0%, #211719 50%, #0e1419 100%);
    border-top: 1px solid rgba(255,255,255,.10);
}

.wgc-network-links {
    display: flex;
    flex: 1 1 auto;
    min-width: 0;
    height: 100%;
    overflow: hidden;
}

.wgc-network-link {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 1 1 25%;
    min-width: 0;
    height: 31px;
    padding: 0 11px;
    color: var(--net-link);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .02em;
    line-height: 1;
    text-decoration: none;
    white-space: nowrap;
    transition: color var(--ease-fast);
}

.wgc-network-link:hover {
    color: #fff;
}

.wgc-network-link.is-active {
    background: var(--net-act);
    color: #fff;
}

/* ── Theme toggle (coffee-shop style: bordered button + swappable icon) ── */

.wgc-theme-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    flex: 0 0 auto;
    height: 100%;
    padding: 0 13px;
    border: 0;
    border-left: 1px solid rgba(255,255,255,.10);
    background: transparent;
    color: rgba(255,255,255,.62);
    cursor: pointer;
    font-family: var(--wgc-font-body);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .03em;
    white-space: nowrap;
    user-select: none;
}

.wgc-theme-toggle:hover {
    background: rgba(255,255,255,.08);
    color: #fff;
}

.wgc-theme-toggle:focus-visible {
    outline: 2px solid rgba(255,255,255,.4);
    outline-offset: -3px;
}

/* The inner pill-badge that holds icon + label */
.wgc-t-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 8px;
    border: 1px solid rgba(255,255,255,.18);
    border-radius: 5px;
    background: rgba(255,255,255,.05);
    color: inherit;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .04em;
    transition: border-color .2s, background .2s !important;
}

.wgc-theme-toggle:hover .wgc-t-badge {
    border-color: rgba(255,255,255,.36);
    background: rgba(255,255,255,.10);
}

/* SVG icons */
.wgc-t-icon { display: block; flex-shrink: 0; width: 13px; height: 13px; }

/* Light mode: show moon badge, hide sun */
:root:not([data-theme="dark"]) .wgc-t-sun  { display: none; }
:root:not([data-theme="dark"]) .wgc-t-moon { display: inline-flex; }

/* Dark mode: show sun badge, hide moon */
[data-theme="dark"] .wgc-t-moon { display: none; }
[data-theme="dark"] .wgc-t-sun  { display: inline-flex; }

/* ── Main bar ── */

.wgc-main-bar {
    display: flex;
    align-items: center;
    height: 75px;
    min-width: 0;
    background: var(--hdr);
    border-bottom: 1px solid rgba(255,255,255,.06);
}

.wgc-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    align-self: stretch;
    padding: 0 16px;
    background: linear-gradient(135deg, #050608 0%, #0e1512 52%, #071b14 100%);
    text-decoration: none;
    border-right: 1px solid rgba(255,255,255,.07);
}

.wgc-logo-img {
    display: block;
    max-height: 52px;
    width: auto;
    object-fit: contain;
    border: 2px solid var(--green-b);
    border-radius: var(--r-md);
    box-shadow: 0 0 18px rgba(34,209,127,.28), 0 0 6px rgba(34,209,127,.14);
}

.wgc-logo-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    flex: 0 0 46px;
    border: 2px solid var(--green-b);
    border-radius: var(--r-md);
    background: #020403;
    color: #fff;
    box-shadow: 0 0 18px rgba(34,209,127,.20), inset 0 0 12px rgba(34,209,127,.16);
}

.wgc-logo-name {
    display: none;
    color: var(--hdr-text);
    font-size: 19px;
    font-weight: 900;
    letter-spacing: 0;
    line-height: 1;
    white-space: nowrap;
}

.wgc-primary-nav {
    display: block;
    min-width: 0;
    flex: 1 1 auto;
    overflow: hidden;
    padding: 0 12px;
}

.wgc-category-track {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    min-width: 0;
    width: 100%;
}

.wgc-category-track a {
    position: relative;
    flex: 0 1 auto;
    min-width: 0;
    padding: 0 clamp(9px,1.05vw,18px);
    color: var(--nav-text);
    font-size: clamp(14px,1.12vw,19px);
    font-weight: 700;
    letter-spacing: .01em;
    line-height: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    text-decoration: none;
    white-space: nowrap;
    transition: color var(--ease-fast);
}

.wgc-category-track a:nth-child(n+8) { display: none; }

.wgc-category-track a + a::before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    width: 1px;
    height: 14px;
    background: var(--nav-div);
    transform: translateY(-50%);
}

.wgc-nav-count-medium a { font-size: clamp(13px,1vw,17px); }
.wgc-nav-count-many a   { font-size: clamp(12px,.92vw,16px); }

.wgc-category-track a:hover   { color: #fff; }
.wgc-category-track a.is-current { color: #fff; }

.wgc-category-track a.is-current::after {
    content: "";
    display: block;
    height: 3px;
    margin-top: 9px;
    background: var(--red-2);
    border-radius: var(--r-full, 999px);
}

.wgc-header-actions {
    display: flex;
    align-items: center;
    gap: 18px;
    flex: 0 0 auto;
    padding: 0 18px 0 4px;
}

.wgc-icon-button {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--hdr-text);
    cursor: pointer;
    transition: color var(--ease-fast);
}

.wgc-icon-button:hover { color: #fff; }

.wgc-search::before {
    content: "";
    width: 22px;
    height: 22px;
    border: 3px solid currentColor;
    border-radius: 50%;
}

.wgc-search::after {
    content: "";
    position: absolute;
    width: 15px;
    height: 3px;
    background: currentColor;
    transform: translate(13px,13px) rotate(45deg);
    transform-origin: center;
    border-radius: 2px;
}

.wgc-menu {
    flex-direction: column;
    gap: 7px;
}

.wgc-menu span {
    display: block;
    width: 28px;
    height: 3px;
    background: currentColor;
    border-radius: 3px;
}

.wgc-menu .jlm_w { display: none; }

/* ═══════════════════════════════════════════════════════════
   MOBILE DRAWER
═══════════════════════════════════════════════════════════ */

.wgc-mobile-drawer.jl_mobile_nav_wrapper {
    --wgc-drawer-fixed-h: 269px;
    --wgc-drawer-footer-h: 50px;
    top: 0 !important;
    bottom: 0 !important;
    left: 0 !important;
    right: 0 !important;
    height: 100vh !important;
    height: 100dvh !important;
    width: 100vw !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
    background: var(--drawer) !important;
    box-shadow: none !important;
    border: 0 !important;
    overflow: hidden !important;
}

.wgc-mobile-drawer .wgc-mobile-drawer-inner {
    display: flex !important;
    flex-direction: column !important;
    position: relative !important;
    left: 0 !important;
    right: 0 !important;
    width: 100vw !important;
    max-width: none !important;
    height: 100vh !important;
    height: 100dvh !important;
    min-height: 0;
    margin: 0 !important;
    padding: 0 !important;
    background: var(--drawer) !important;
    color: var(--hdr-text);
    border: 0 !important;
    box-shadow: none !important;
    overflow: hidden;
}

body .wgc-mobile-drawer,
body .wgc-mobile-drawer.jl_mobile_nav_wrapper,
body .wgc-mobile-drawer #nav,
body .wgc-mobile-drawer .jl_mobile_nav_inner {
    box-sizing: border-box;
    width: 100vw !important;
    max-width: none !important;
    height: 100vh !important;
    height: 100dvh !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background-color: var(--drawer) !important;
    overflow: hidden !important;
}

body .wgc-mobile-drawer #nav.wgc-mobile-drawer-inner,
body .wgc-mobile-drawer .jl_mobile_nav_inner.wgc-mobile-drawer-inner {
    display: flex !important;
    flex-direction: column !important;
    position: relative !important;
}

body .wgc-mobile-drawer.menu_mobile_active,
body .wgc-mobile-drawer.jl_mobile_nav_open,
body .wgc-mobile-drawer.nav_active {
    transform: translateX(0) !important;
}

body .mobile_menu_overlay { background: rgba(0,0,0,.75) !important; }

body.wgc-drawer-open {
    overflow: hidden !important;
    position: fixed !important;
    width: 100% !important;
}

.wgc-site-header {
    position: sticky;
    top: 0;
    z-index: 999;
    transition: transform 0.28s ease;
    will-change: transform;
}

.wgc-site-header.wgc-header-hidden { transform: none; }

.wgc-drawer-fixed-header {
    position: sticky;
    top: 0;
    z-index: 20;
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
    background: var(--drawer-f);
    box-shadow: 0 1px 0 rgba(255,255,255,.05);
    will-change: transform;
}

.wgc-drawer-top {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    height: 72px !important;
    min-height: 72px !important;
    padding: 12px 22px;
    background: var(--drawer-f);
    z-index: 20;
    box-sizing: border-box;
}

.wgc-drawer-top.is-collapsed {
    min-height: 72px !important;
    height: 72px !important;
    padding: 12px 22px;
    overflow: visible;
}

.wgc-drawer-logo {
    display: flex !important;
    align-items: center;
    justify-content: flex-start;
    text-decoration: none;
    padding: 4px 0;
}

.wgc-drawer-logo-img {
    display: block;
    max-height: 44px;
    width: auto;
    object-fit: contain;
    border: 2px solid var(--green-b);
    border-radius: var(--r-md);
    box-shadow: 0 0 18px rgba(34,209,127,.28), 0 0 6px rgba(34,209,127,.14);
}

.wgc-drawer-logo-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    flex: 0 0 50px;
    border: 2px solid var(--green-b);
    border-radius: var(--r-md);
    background: #020403;
    color: #fff;
    box-shadow: 0 0 18px rgba(34,209,127,.20), inset 0 0 12px rgba(34,209,127,.14);
}

.wgc-drawer-close {
    position: relative;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: pointer;
}

.wgc-drawer-close span {
    position: absolute;
    left: 4px;
    top: 20px;
    display: block;
    width: 38px;
    height: 4px;
    background: rgba(255,255,255,.8);
    border-radius: 4px;
}

.wgc-drawer-close span:first-child { transform: rotate(45deg); }
.wgc-drawer-close span:last-child  { transform: rotate(-45deg); }

.wgc-drawer-network {
    display: grid;
    height: 124px !important;
    grid-template-columns: repeat(2,minmax(0,1fr));
    gap: 0;
    padding: 18px 22px 22px;
    background: var(--drawer-f);
    z-index: 19;
    box-sizing: border-box;
}

.wgc-drawer-network.is-sticky { top: auto !important; }

.wgc-drawer-network a {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 0 8px;
    color: rgba(255,255,255,.55);
    border: 1px solid rgba(255,255,255,.10);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .02em;
    line-height: 1;
    text-decoration: none;
    white-space: nowrap;
}

.wgc-drawer-network:not(:hover):not(:focus-within) a.is-selected,
.wgc-drawer-network a.is-selected,
.wgc-drawer-network a:hover,
.wgc-drawer-network a:focus {
    background: var(--green);
    color: #fff;
    border-color: var(--green);
}

.wgc-drawer-categories {
    display: flex;
    flex: 1 1 auto;
    min-height: 0;
    overflow: hidden;
    background: var(--drawer);
}

.wgc-drawer-heading {
    z-index: 18;
    display: flex;
    align-items: center;
    height: 73px !important;
    padding: 0 24px;
    background: var(--green);
    color: #fff;
    font-size: 26px;
    font-weight: 300;
    letter-spacing: .04em;
    line-height: 1;
    text-transform: uppercase;
}

.wgc-drawer-category-list {
    display: block;
    flex: 1 1 auto;
    width: 100%;
    height: 100%;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,.14) transparent;
}

.wgc-drawer-category-list::-webkit-scrollbar { width: 4px; }
.wgc-drawer-category-list::-webkit-scrollbar-track { background: transparent; }
.wgc-drawer-category-list::-webkit-scrollbar-thumb { background: rgba(255,255,255,.14); border-radius: 4px; }

.wgc-drawer-category-list a {
    display: block;
    padding: 18px 24px;
    color: rgba(255,255,255,.46);
    border-bottom: 1px solid rgba(255,255,255,.04);
    font-size: 21px;
    font-weight: 300;
    letter-spacing: .03em;
    line-height: 1.15;
    text-decoration: none;
    text-transform: uppercase;
    transition: color var(--ease-fast), padding-left var(--ease);
}

.wgc-drawer-category-list a:hover,
.wgc-drawer-category-list a:focus {
    color: #fff;
    padding-left: 30px;
}

.wgc-drawer-more-info { margin-top: 10px; }

.wgc-drawer-more-heading {
    width: 100%;
    margin: 0;
    box-sizing: border-box;
}

.wgc-drawer-more-list { display: block; background: var(--drawer); }

.wgc-drawer-more-list ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.wgc-drawer-more-list .menu-item {
    display: block;
    margin: 0;
    padding: 0;
    list-style: none;
}

.wgc-drawer-more-list a {
    display: block;
    padding: 18px 24px;
    color: rgba(255,255,255,.46);
    border-bottom: 1px solid rgba(255,255,255,.04);
    font-size: 21px;
    font-weight: 300;
    letter-spacing: .03em;
    line-height: 1.15;
    text-decoration: none;
    text-transform: uppercase;
    transition: color var(--ease-fast), padding-left var(--ease);
}

.wgc-drawer-more-list a:hover,
.wgc-drawer-more-list a:focus {
    color: #fff;
    padding-left: 30px;
}

.wgc-drawer-footer {
    position: relative !important;
    z-index: 20;
    flex: 0 0 var(--wgc-drawer-footer-h);
    height: var(--wgc-drawer-footer-h) !important;
    max-height: none;
    overflow: visible;
    padding: 10px 22px;
    opacity: 1;
    background: var(--drawer-f);
    color: rgba(255,255,255,.30);
    border-top: 1px solid rgba(255,255,255,.05);
    font-size: 12px;
    line-height: 1.4;
    text-align: center;
}

.wgc-drawer-footer.is-visible { max-height: none; opacity: 1; }

@media (max-width: 640px) {
    .wgc-mobile-drawer.jl_mobile_nav_wrapper {
        --wgc-drawer-fixed-h: 257px;
        --wgc-drawer-footer-h: 50px;
    }
    .wgc-drawer-top { min-height: 69px !important; height: 69px !important; padding: 12px 18px; }
    .wgc-drawer-logo-mark { width: 45px; height: 45px; flex-basis: 45px; border-radius: 7px; }
    .wgc-drawer-network { height: 118px !important; padding: 16px 18px 18px; }
    .wgc-drawer-heading { height: 70px !important; }
}

.wgc-mobile-drawer .nav_mb_f,
.wgc-mobile-drawer .jl_mobile_nav_inner > .nav_mb_f,
.wgc-mobile-drawer .cp_txt {
    display: none !important;
}

/* ═══════════════════════════════════════════════════════════
   LAYOUT POSITIONING
═══════════════════════════════════════════════════════════ */

body .options_layout_container {
    padding-top: var(--wgc-site-header-h) !important;
}

body header.wgc-site-header {
    position: fixed !important;
    top: var(--wgc-admin-bar-h, 0px) !important;
    left: 0 !important;
    right: 0 !important;
    z-index: 99999 !important;
    width: 100% !important;
    transform: none !important;
}

body.admin-bar header.wgc-site-header { top: 32px !important; }

#wpadminbar { z-index: 100000 !important; }

/* ═══════════════════════════════════════════════════════════
   HOME PAGE
═══════════════════════════════════════════════════════════ */

.wgc-home {
    max-width: 1180px;
    margin: 0 auto;
    padding: 28px 15px 56px;
}

/* ── Shared blocks ── */

.wgc-news-slider,
.wgc-cat-section {
    background: var(--surface);
    border-radius: var(--r-lg);
    box-shadow: var(--sh-sm);
    border: 1px solid var(--border-2);
    margin-bottom: 28px;
    overflow: hidden;
    padding: 22px 18px;
}

.wgc-block-heading {
    margin: 0 0 16px;
    color: var(--text);
    font-family: var(--wgc-font-body);
    font-size: 18px;
    font-weight: 900;
    letter-spacing: .06em;
    line-height: 1;
    text-transform: uppercase;
}

/* ── Slider ── */

.wgc-slider-wrap { position: relative; border-radius: var(--r-md); overflow: hidden; }
.wgc-slider-track { position: relative; }
.wgc-slide { display: none; }
.wgc-slide.is-active { display: block; animation: wgcFadeIn .4s ease; }

@keyframes wgcFadeIn { from { opacity:0; } to { opacity:1; } }

.wgc-slide-link {
    display: block;
    position: relative;
    text-decoration: none;
}

.wgc-slide-link .wgc-image,
.wgc-slide-link .wgc-placeholder {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border-radius: var(--r-md);
}

.wgc-slide-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 48px 22px 48px;
    background: linear-gradient(to top,rgba(0,0,0,.72) 0%,transparent 100%);
    border-radius: 0 0 var(--r-md) var(--r-md);
}

.wgc-slide-title {
    margin: 0;
    color: #fff;
    font-family: var(--wgc-font-body);
    font-size: clamp(18px,3.2vw,32px);
    font-weight: 800;
    line-height: 1.22;
    text-shadow: 0 1px 4px rgba(0,0,0,.4);
}

.wgc-slider-dots {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    position: absolute;
    bottom: 14px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
}

.wgc-dot {
    width: 10px;
    height: 10px;
    padding: 0;
    border: 2px solid rgba(255,255,255,.65);
    border-radius: 50%;
    background: transparent;
    cursor: pointer;
}

.wgc-dot.is-active { background: var(--red); border-color: var(--red); }

/* ── Category card grid ── */

.wgc-post-grid {
    display: grid;
    grid-template-columns: repeat(4,minmax(0,1fr));
    gap: 18px;
}

.wgc-grid-card { margin: 0; }

.wgc-grid-card-link {
    display: block;
    text-decoration: none;
    color: inherit;
}

.wgc-grid-card-img {
    position: relative;
    overflow: hidden;
    border-radius: var(--r-md);
    background: var(--surface-3);
    aspect-ratio: 4 / 3;
}

.wgc-grid-card-img .wgc-image,
.wgc-grid-card-img .wgc-placeholder {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: var(--r-md);
    transition: transform .3s ease !important;
}

.wgc-grid-card-link:hover .wgc-grid-card-img .wgc-image { transform: scale(1.05) !important; }

.wgc-grid-card-date {
    display: flex;
    align-items: center;
    gap: 6px;
    position: absolute;
    bottom: 10px;
    left: 10px;
    padding: 4px 8px 4px 0;
    color: #fff;
    font-family: var(--wgc-font-body);
    font-size: 12px;
    font-weight: 600;
    line-height: 1;
    text-shadow: 0 1px 3px rgba(0,0,0,.5);
}

.wgc-date-bar {
    display: inline-block;
    width: 3px;
    height: 14px;
    background: var(--red);
    border-radius: 2px;
    flex-shrink: 0;
}

.wgc-grid-card-title {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin: 10px 0 0;
    color: var(--text);
    font-family: var(--wgc-font-body);
    font-size: 14px;
    font-weight: 700;
    line-height: 1.38;
    transition: color var(--ease-fast) !important;
}

.wgc-title-bar {
    display: inline-block;
    width: 3px;
    min-height: 18px;
    background: var(--red);
    border-radius: 2px;
    flex-shrink: 0;
    margin-top: 2px;
}

.wgc-grid-card-link:hover .wgc-grid-card-title { color: var(--red) !important; }

/* ── Responsive ── */

@media (max-width: 900px) {
    .wgc-post-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 14px; }
    .wgc-news-slider, .wgc-cat-section { border-radius: var(--r-md); padding: 16px 14px; }
    .wgc-block-heading { font-size: 16px; }
    .wgc-slide-overlay { padding: 32px 16px 40px; }
}

@media (max-width: 640px) {
    .wgc-post-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }
    .wgc-block-heading { font-size: 14px; margin-bottom: 12px; }
    .wgc-news-slider, .wgc-cat-section { border-radius: var(--r-sm); padding: 14px 12px; margin-bottom: 16px; }
    .wgc-slide-title { font-size: 16px; }
    .wgc-grid-card-title { font-size: 13px; }
    .wgc-grid-card-date { font-size: 11px; }
}

/* ── Section titles ── */

.wgc-section-title {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin: 0 0 15px;
    color: var(--text);
    font-size: 15px;
    line-height: 1.2;
}

.wgc-section-title span { color: var(--text-3); }
.wgc-section-title strong { font-weight: 800; }

/* ── Featured section ── */

.wgc-featured {
    padding-bottom: 26px;
    margin-bottom: 26px;
    border-bottom: 1px solid var(--border);
}

.wgc-featured-grid {
    display: grid;
    grid-template-columns: minmax(0,1.38fr) minmax(250px,.82fr);
    grid-auto-flow: dense;
    gap: 18px;
}

.wgc-card,
.wgc-row { margin: 0; }

.wgc-card--lead { grid-row: span 2; }

.wgc-media {
    position: relative;
    display: block;
    overflow: hidden;
    background: var(--surface-3);
}

.wgc-card .wgc-media { aspect-ratio: 16 / 9; }
.wgc-card--small .wgc-media, .wgc-row .wgc-media { aspect-ratio: 16 / 10; }

.wgc-image {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 0;
    transition: transform .28s ease !important;
}

.wgc-placeholder { background: linear-gradient(135deg,var(--surface-3),var(--surface-2)); }

.wgc-media:hover .wgc-image { transform: scale(1.04) !important; }

.wgc-card-body { padding-top: 10px; }

.wgc-kicker {
    margin: 0 0 8px;
    color: var(--red);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .06em;
    line-height: 1;
    text-transform: uppercase;
}

.wgc-title {
    margin: 0;
    color: var(--text);
    font-weight: 800;
    letter-spacing: -.01em;
    transition: color var(--ease-fast) !important;
}

.wgc-card--lead .wgc-title  { font-size: 30px; line-height: 1.14; }
.wgc-card--small .wgc-title { font-size: 18px; line-height: 1.2; }
.wgc-row .wgc-title          { font-size: 24px; line-height: 1.2; }

.wgc-title a {
    color: inherit;
    text-decoration: none;
    transition: color var(--ease-fast) !important;
}

.wgc-title a:hover { color: var(--red) !important; }

.wgc-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 12px;
    margin-top: 9px;
    color: var(--text-3);
    font-size: 13px;
    line-height: 1.35;
}

.wgc-meta a { color: var(--text-2); transition: color var(--ease-fast) !important; }
.wgc-meta a:hover { color: var(--red) !important; }

.wgc-list { display: grid; }

.wgc-row {
    display: grid;
    grid-template-columns: 280px minmax(0,1fr);
    gap: 21px;
    padding: 22px 0;
    border-bottom: 1px solid var(--border);
}

.wgc-excerpt {
    margin-top: 10px;
    color: var(--text-2);
    font-size: 15px;
    line-height: 1.55;
}

.wgc-pagination { margin-top: 30px; }

/* ── Responsive header + home ── */

@media (max-width: 900px) {
    body { --wgc-site-header-h: 134px; }

    .wgc-network-bar { height: 38px; }
    .wgc-network-link { height: 38px; padding: 0 10px; font-size: 15px; }
    .wgc-theme-toggle { height: 38px; }
    .wgc-main-bar { height: 96px; }
    .wgc-logo { flex-basis: 202px; padding: 0 18px; }
    .wgc-logo-mark { width: 50px; height: 50px; flex-basis: 50px; }
    .wgc-logo-name { font-size: 22px; }

    .wgc-primary-nav {
        overflow-x: auto;
        overflow-y: hidden;
        padding-left: 16px;
        scrollbar-width: none;
        -webkit-overflow-scrolling: touch;
    }
    .wgc-primary-nav::-webkit-scrollbar { display: none; }
    .wgc-category-track { justify-content: flex-start; gap: 0; width: max-content; min-width: 100%; }
    .wgc-category-track a:nth-child(n+8) { display: block; }
    .wgc-category-track a,
    .wgc-nav-count-medium a,
    .wgc-nav-count-many a { flex: 0 0 auto; overflow: visible; text-overflow: clip; padding: 0 18px; font-size: 22px; }

    .wgc-header-actions { gap: 16px; padding-right: 18px; }
    .wgc-icon-button { width: 42px; height: 42px; }
    .wgc-search::before { width: 30px; height: 30px; border-width: 3px; }
    .wgc-search::after { width: 18px; height: 3px; transform: translate(16px,17px) rotate(45deg); }
    .wgc-menu { gap: 8px; }
    .wgc-menu span { width: 36px; height: 4px; }

    .wgc-featured-grid { grid-template-columns: 1fr; }
    .wgc-card--lead { grid-row: auto; }
    .wgc-row { grid-template-columns: 220px minmax(0,1fr); }
}

@media (max-width: 640px) {
    body { --wgc-site-header-h: 105px; }

    body.admin-bar header.wgc-site-header { top: 46px !important; }
    html #wpadminbar { position: fixed !important; }

    .wgc-network-bar { height: 31px; }
    .wgc-network-link { height: 31px; padding: 0 4px; font-size: 11px; }
    .wgc-theme-toggle { height: 31px; width: auto; padding: 0 9px; }
    .wgc-t-badge { font-size: 0; gap: 0; padding: 2px 5px; }
    .wgc-t-icon { width: 14px; height: 14px; }
    .wgc-main-bar { height: 74px; }
    .wgc-logo { flex-basis: 78px; padding: 0 10px; gap: 0; }
    .wgc-logo-img { max-height: 62px; }
    .wgc-logo-mark { width: 45px; height: 45px; flex-basis: 45px; border-radius: 7px; }
    .wgc-logo-name { display: none; }
    .wgc-primary-nav { padding-left: 11px; }
    .wgc-category-track { gap: 0; }
    .wgc-category-track a,
    .wgc-nav-count-medium a,
    .wgc-nav-count-many a { padding: 0 13px; font-size: 17px; }
    .wgc-header-actions { gap: 10px; padding-right: 10px; }
    .wgc-icon-button { width: 32px; height: 32px; }
    .wgc-search::before { width: 22px; height: 22px; border-width: 2.5px; }
    .wgc-search::after { width: 13px; height: 2.5px; transform: translate(12px,13px) rotate(45deg); }
    .wgc-menu { gap: 6px; }
    .wgc-menu span { width: 26px; height: 3px; }
    .wgc-home { padding: 20px 15px 42px; }
    .wgc-card--lead .wgc-title { font-size: 23px; }
    .wgc-card--small .wgc-title, .wgc-row .wgc-title { font-size: 20px; }
    .wgc-row { grid-template-columns: 1fr; gap: 12px; padding: 20px 0; }
}

/* ── Clean homepage layout ── */

.wgc-homepage {
    width: 100%;
    margin: 0;
    padding: 28px 18px 44px;
    background: var(--bg);
}

.wgc-hero-news,
.wgc-feature-posts {
    width: min(1220px,100%);
    margin: 0 auto 30px;
    padding: 34px 30px 42px;
    background: var(--surface);
    border-radius: var(--r-2xl);
    border: 1px solid var(--border-2);
    box-shadow: var(--sh-md);
}

.wgc-home-heading {
    margin: 0 0 32px;
    color: var(--text);
    font-family: var(--wgc-font-body);
    font-size: clamp(30px,4.2vw,56px);
    font-weight: 900;
    line-height: 1;
    letter-spacing: -.01em;
    text-transform: uppercase;
}

.wgc-hero-slider { position: relative; overflow: hidden; border-radius: var(--r-xl); }

.wgc-hero-slides {
    position: relative;
    aspect-ratio: 16 / 9;
    min-height: 420px;
    background: #111;
    border-radius: var(--r-xl);
    overflow: hidden;
}

.wgc-hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    visibility: hidden;
    transition: opacity .45s ease, visibility .45s ease !important;
}

.wgc-hero-slide.is-active { opacity: 1; visibility: visible; z-index: 1; }

.wgc-hero-link,
.wgc-hero-link .wgc-image,
.wgc-hero-link .wgc-placeholder { display: block; width: 100%; height: 100%; }

.wgc-hero-link { position: relative; color: #fff; text-decoration: none; }

.wgc-hero-link .wgc-image,
.wgc-hero-link .wgc-placeholder { object-fit: cover; border-radius: 0; }

.wgc-hero-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top,rgba(0,0,0,.82) 0%,rgba(0,0,0,.34) 42%,rgba(0,0,0,.08) 100%);
}

.wgc-hero-title {
    position: absolute;
    left: 32px;
    right: 32px;
    bottom: 96px;
    margin: 0;
    color: #fff;
    font-family: var(--wgc-font-body);
    font-size: clamp(30px,5.2vw,64px);
    font-weight: 900;
    line-height: 1.18;
    letter-spacing: -.01em;
    text-shadow: 0 2px 8px rgba(0,0,0,.7);
}

.wgc-hero-dots {
    position: absolute;
    left: 50%;
    bottom: 30px;
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 24px;
    transform: translateX(-50%);
}

.wgc-hero-dot {
    width: 34px;
    height: 34px;
    padding: 0;
    border: 5px solid rgba(255,255,255,.82);
    border-radius: 50%;
    background: rgba(255,255,255,.82);
    cursor: pointer;
}

.wgc-hero-dot.is-active { background: var(--red-2); box-shadow: inset 0 0 0 5px #fff; }

.wgc-feature-grid {
    display: grid;
    grid-template-columns: repeat(4,minmax(0,1fr));
    gap: 34px 24px;
}

.wgc-feature-card { margin: 0; }

.wgc-feature-link {
    display: block;
    color: var(--text);
    text-decoration: none;
}

.wgc-feature-media {
    position: relative;
    overflow: hidden;
    aspect-ratio: 4 / 3;
    border-radius: var(--r-2xl);
    background: #111;
}

.wgc-feature-media .wgc-image,
.wgc-feature-media .wgc-placeholder {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .35s ease !important;
}

.wgc-feature-link:hover .wgc-feature-media .wgc-image { transform: scale(1.05) !important; }

.wgc-feature-media::after {
    content: "";
    position: absolute;
    inset: 45% 0 0;
    background: linear-gradient(to top,rgba(0,0,0,.7),transparent);
}

.wgc-feature-date {
    position: absolute;
    left: 18px;
    right: 14px;
    bottom: 18px;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 8px;
    color: #fff;
    font-size: clamp(14px,1.4vw,22px);
    font-weight: 300;
    line-height: 1.1;
    text-shadow: 0 1px 4px rgba(0,0,0,.7);
}

.wgc-feature-date span,
.wgc-feature-title span { display: block; flex: 0 0 7px; width: 7px; background: var(--red-2); }

.wgc-feature-date span { height: 34px; }

.wgc-feature-title {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 24px 0 0;
    color: var(--text);
    font-family: var(--wgc-font-body);
    font-size: clamp(20px,2.1vw,34px);
    font-weight: 900;
    line-height: 1.28;
    letter-spacing: -.01em;
    transition: color var(--ease-fast) !important;
}

.wgc-feature-title span { height: 42px; margin-top: 4px; }

.wgc-feature-link:hover .wgc-feature-title { color: var(--red-2) !important; }

@media (max-width: 900px) {
    .wgc-homepage { padding: 30px 16px 38px; }
    .wgc-hero-news, .wgc-feature-posts { padding: 30px 22px 34px; border-radius: 28px; }
    .wgc-hero-slides { min-height: 520px; aspect-ratio: 4 / 3; border-radius: 26px; }
    .wgc-feature-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}

@media (max-width: 640px) {
    .wgc-homepage { padding: 24px 12px 30px; }
    .wgc-hero-news, .wgc-feature-posts { padding: 22px 18px 28px; border-radius: 22px; }
    .wgc-home-heading { margin-bottom: 22px; font-size: 30px; }
    .wgc-hero-slides { min-height: 360px; border-radius: 20px; }
    .wgc-hero-slider { border-radius: 20px; }
    .wgc-hero-title { left: 20px; right: 20px; bottom: 70px; font-size: 30px; }
    .wgc-hero-dots { bottom: 22px; gap: 16px; }
    .wgc-hero-dot { width: 22px; height: 22px; border-width: 4px; }
    .wgc-feature-grid { gap: 26px 16px; }
    .wgc-feature-media { border-radius: 18px; }
    .wgc-feature-date { left: 10px; bottom: 12px; font-size: 13px; }
    .wgc-feature-title { margin-top: 14px; gap: 7px; font-size: 18px; }
    .wgc-feature-title span { height: 32px; }
}

/* ═══════════════════════════════════════════════════════════
   SINGLE POST
═══════════════════════════════════════════════════════════ */

.wgc-single-main {
    background: var(--bg);
    color: var(--text);
    font-family: var(--wgc-font-body);
}

.wgc-single-article {
    width: min(100%,820px);
    margin: 0 auto;
    padding: 24px 32px 56px;
    background: var(--bg);
}

.wgc-single-hero { display: block; }

/* ── Category badge ── */
.wgc-single-category {
    display: inline-flex;
    align-items: center;
    min-height: 52px;
    max-width: 100%;
    margin: 0 0 12px;
    padding: 0 28px;
    border-radius: 0 var(--r-lg) var(--r-lg) 0;
    background: var(--green);
    color: #fff;
    font-size: clamp(16px,3vw,28px);
    font-weight: 600;
    letter-spacing: .01em;
    line-height: 1;
    text-decoration: none;
    transition: background var(--ease-fast) !important;
}

.wgc-single-category:hover { color: #fff; background: var(--green-h) !important; }

/* ── Post title ── */
.wgc-single-title {
    margin: 0 0 18px;
    color: var(--text);
    font-family: var(--wgc-font-heading);
    font-size: clamp(32px,6.5vw,54px);
    font-weight: 800;
    letter-spacing: -.02em;
    line-height: 1.18;
}

/* ── Byline ── */
.wgc-single-byline,
.wgc-single-byline a,
.wgc-single-date {
    color: var(--text-2);
    font-weight: 600;
    line-height: 1.32;
    text-decoration: none;
}

.wgc-single-byline {
    margin-bottom: 6px;
    font-size: clamp(16px,2.8vw,23px);
    font-weight: 400;
}

.wgc-single-byline a {
    font-size: inherit;
    transition: color var(--ease-fast) !important;
}

.wgc-single-byline a:hover { color: var(--blue) !important; }

/* ── Dates + meta row ── */
.wgc-single-dates {
    display: grid;
    gap: 5px;
    margin-bottom: 32px;
}

.wgc-single-date {
    display: flex;
    align-items: center;
    gap: 9px;
    font-size: clamp(13px,2.2vw,17px);
    color: var(--text-2);
}

/* ── Date icons ── */
.wgc-date-icon {
    position: relative;
    display: inline-block;
    flex: 0 0 20px;
    width: 20px;
    height: 20px;
    color: var(--text-3);
}

.wgc-date-icon-clock {
    border: 2px solid currentColor;
    border-radius: 50%;
}

.wgc-date-icon-clock::before,
.wgc-date-icon-clock::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    width: 2px;
    border-radius: 3px;
    background: currentColor;
    transform-origin: 50% 0;
}

.wgc-date-icon-clock::before {
    height: 6px;
    transform: translate(-50%,-1px) rotate(0deg);
}

.wgc-date-icon-clock::after {
    height: 6px;
    transform: translate(-50%,-1px) rotate(115deg);
}

.wgc-date-icon-calendar {
    border: 2px solid currentColor;
    border-radius: 4px;
}

.wgc-date-icon-calendar::before {
    content: "";
    position: absolute;
    left: 3px;
    right: 3px;
    top: 6px;
    height: 2px;
    background: currentColor;
}

.wgc-date-icon-calendar::after {
    content: "";
    position: absolute;
    left: 4px;
    top: -5px;
    width: 10px;
    height: 7px;
    border-left: 2px solid currentColor;
    border-right: 2px solid currentColor;
}

/* Eye icon (admin view count) */
.wgc-date-icon-eye {
    border: 2px solid currentColor;
    border-radius: 50% 50% 50% 50% / 40% 40% 60% 60%;
    width: 20px;
    height: 13px;
    flex: 0 0 20px;
    margin-top: 3px;
}

.wgc-date-icon-eye::before {
    content: "";
    position: absolute;
    width: 6px;
    height: 6px;
    background: currentColor;
    border-radius: 50%;
    top: 50%;
    left: 50%;
    transform: translate(-50%,-50%);
}

/* ── Featured image ── */
.wgc-single-featured { margin: 0 0 34px; }

.wgc-single-featured img {
    display: block;
    width: 100%;
    height: auto;
    max-height: 640px;
    object-fit: cover;
    border-radius: var(--r-xl);
}

.wgc-single-featured figcaption {
    margin-top: 10px;
    color: var(--text-3);
    font-size: 13px;
    line-height: 1.5;
    text-align: center;
}

/* ── Article body ── */
.wgc-single-body { position: relative; }

.wgc-single-content {
    color: var(--text);
    font-family: var(--wgc-font-body);
    font-size: clamp(18px,3.2vw,26px);
    font-weight: 400;
    line-height: 1.7;
    letter-spacing: 0;
}

.wgc-single-content p { margin: 0 0 1.1em; }

.wgc-single-content a {
    color: var(--blue);
    text-decoration: underline;
    text-decoration-thickness: .08em;
    text-underline-offset: .18em;
    transition: color var(--ease-fast) !important;
}

.wgc-single-content a:hover { color: var(--blue-h) !important; }

.wgc-single-content img {
    max-width: 100%;
    height: auto;
    border-radius: var(--r-lg);
}

.wgc-single-content h2,
.wgc-single-content h3,
.wgc-single-content h4 {
    color: var(--text);
    font-family: var(--wgc-font-heading);
    font-weight: 800;
    letter-spacing: -.02em;
    line-height: 1.2;
}

.wgc-single-content h2 { margin: 1.35em 0 .55em; font-size: clamp(28px,4.8vw,40px); }
.wgc-single-content h3 { margin: 1.25em 0 .5em;  font-size: clamp(24px,4vw,34px); }

/* ── Author verified badge ── */
.wgc-author-verified {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    max-width: 100%;
    vertical-align: baseline;
}

.wgc-verified-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 16px;
    width: 16px;
    height: 16px;
    margin-left: 1px;
    vertical-align: -3px;
}

.wgc-verified-badge svg { display: block; width: 100%; height: 100%; }

.jl_relsec_wrap .wgc-verified-badge { flex: 0 0 22px; width: 22px; height: 22px; vertical-align: -5px; }

/* ── Blockquotes ── */
.wgc-single-content blockquote,
.wgc-single-content .wp-block-quote,
.wgc-single-content .wp-block-pullquote {
    position: relative;
    margin: 1.45em 0;
    padding: 28px 30px 28px 34px;
    border: 0;
    border-left: 5px solid var(--blue);
    border-radius: var(--r-sm);
    background: var(--surface);
    color: var(--text);
    box-shadow: var(--sh-sm);
}

.wgc-single-content blockquote::before,
.wgc-single-content .wp-block-quote::before {
    content: "";
    position: absolute;
    top: 18px;
    right: 24px;
    width: 38px;
    height: 32px;
    opacity: .10;
    background:
        radial-gradient(circle at 9px 9px,  var(--blue) 0 8px, transparent 9px),
        radial-gradient(circle at 28px 9px, var(--blue) 0 8px, transparent 9px);
}

.wgc-single-content blockquote p,
.wgc-single-content .wp-block-quote p,
.wgc-single-content .wp-block-pullquote p {
    margin: 0 0 .75em;
    color: inherit;
    font-size: clamp(19px,3.2vw,28px);
    font-weight: 700;
    line-height: 1.42;
}

.wgc-single-content blockquote p:last-child,
.wgc-single-content .wp-block-quote p:last-child,
.wgc-single-content .wp-block-pullquote p:last-child { margin-bottom: 0; }

.wgc-single-content blockquote cite,
.wgc-single-content blockquote footer,
.wgc-single-content .wp-block-quote cite,
.wgc-single-content .wp-block-quote footer,
.wgc-single-content .wp-block-pullquote cite {
    display: block;
    margin-top: 14px;
    color: var(--text-3);
    font-size: 14px;
    font-style: normal;
    font-weight: 700;
    letter-spacing: .04em;
}

.wgc-single-content .wp-block-pullquote { padding-top: 34px; padding-bottom: 34px; text-align: left; }

.wgc-single-content .wp-block-pullquote blockquote {
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}

.wgc-single-content .wp-block-pullquote blockquote::before { display: none; }

.wgc-single-main .single_tag_share,
.wgc-single-main .jl_sfoot,
.wgc-single-main .jl_auth_single,
.wgc-single-main .single_section_comment {
    margin-top: 34px;
}

@media (max-width: 640px) {
    .wgc-single-article { padding: 14px 18px 44px; }
    .wgc-single-category { min-height: 44px; margin-left: -18px; padding: 0 22px 0 28px; }
    .wgc-single-title { margin-bottom: 16px; }
    .wgc-single-dates { margin-bottom: 28px; }
    .wgc-single-featured img { border-radius: var(--r-lg); }
}

/* ═══════════════════════════════════════════════════════════
   SINGLE POST — SIDEBAR
═══════════════════════════════════════════════════════════ */

.wgc-single-wrap { display: block; }

@media (min-width: 1024px) {
    .wgc-single-wrap {
        display: flex;
        align-items: flex-start;
        gap: 28px;
        max-width: 1420px;
        margin: 0 auto;
        padding: 0 28px;
    }

    .wgc-single-wrap .wgc-single-main { flex: 1 1 0; min-width: 0; }
    .wgc-single-wrap .wgc-single-article { width: 100%; max-width: 100%; margin: 0; }

    .wgc-single-sidebar-wrap {
        flex: 0 0 296px;
        width: 296px;
        padding-top: 24px;
        position: sticky;
        top: calc(var(--wgc-site-header-h,106px) + 16px);
        max-height: calc(100vh - var(--wgc-site-header-h,106px) - 32px);
        overflow-y: auto;
        scrollbar-width: thin;
        scrollbar-color: var(--border) transparent;
    }

    .wgc-single-sidebar-wrap::-webkit-scrollbar { width: 4px; }
    .wgc-single-sidebar-wrap::-webkit-scrollbar-track { background: transparent; }
    .wgc-single-sidebar-wrap::-webkit-scrollbar-thumb { background: var(--border); border-radius: 4px; }
}

@media (min-width: 600px) and (max-width: 1023px) {
    .wgc-single-sidebar-wrap {
        display: grid;
        grid-template-columns: repeat(2,minmax(0,1fr));
        gap: 20px;
        padding: 8px 24px 40px;
    }
}

@media (max-width: 599px) {
    .wgc-single-sidebar-wrap { display: block; padding: 0 18px 36px; }
}

/* ── Sidebar widget card ── */
.wgc-sb-widget {
    margin-bottom: 20px;
    padding: 16px 18px 18px;
    background: var(--surface);
    border-radius: var(--r-lg);
    border: 1px solid var(--border-2);
    box-shadow: var(--sh-xs);
}

@media (min-width: 600px) and (max-width: 1023px) {
    .wgc-sb-widget { margin-bottom: 0; }
    .wgc-sb-share { grid-column: 1 / -1; }
}

@media (max-width: 599px) { .wgc-sb-widget { margin-bottom: 16px; } }

.wgc-sb-title {
    margin: 0 0 12px;
    padding-bottom: 9px;
    border-bottom: 2px solid var(--green);
    color: var(--text);
    font-family: var(--wgc-font-body);
    font-size: 11px;
    font-weight: 900;
    letter-spacing: .08em;
    line-height: 1;
    text-transform: uppercase;
}

/* ── Social share ── */
.wgc-sb-share-grid {
    display: grid;
    grid-template-columns: repeat(2,minmax(0,1fr));
    gap: 9px;
}

.wgc-sb-share-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 9px 10px;
    border: 0;
    border-radius: var(--r-sm);
    color: #fff;
    cursor: pointer;
    font-family: var(--wgc-font-body);
    font-size: 13px;
    font-weight: 700;
    line-height: 1;
    text-decoration: none;
    white-space: nowrap;
    transition: filter .18s ease, transform .12s ease !important;
}

.wgc-sb-share-btn:hover { filter: brightness(1.12); transform: translateY(-1px); color: #fff; }
.wgc-sb-share-btn svg { flex: 0 0 16px; width: 16px; height: 16px; }

.wgc-share-fb  { background: #1877f2; }
.wgc-share-x   { background: #000; }
.wgc-share-wa  { background: #25d366; }
.wgc-share-copy { background: var(--text-2); }
.wgc-share-copy.is-copied { background: var(--green); }

/* ── Recent posts ── */
.wgc-sb-posts-list { margin: 0; padding: 0; list-style: none; }

.wgc-sb-post-item {
    display: flex;
    align-items: flex-start;
    gap: 11px;
    padding: 10px 0;
    border-bottom: 1px solid var(--border-2);
}

.wgc-sb-post-item:first-child { padding-top: 0; }
.wgc-sb-post-item:last-child  { border-bottom: 0; padding-bottom: 0; }

.wgc-sb-post-thumb {
    flex: 0 0 68px;
    width: 68px;
    height: 68px;
    border-radius: var(--r-sm);
    overflow: hidden;
    display: block;
    background: var(--surface-3);
}

.wgc-sb-post-thumb img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: var(--r-sm);
    transition: transform .2s ease !important;
}

.wgc-sb-post-item:hover .wgc-sb-post-thumb img { transform: scale(1.06) !important; }

.wgc-sb-post-body { flex: 1 1 0; min-width: 0; }

.wgc-sb-post-title {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 5px;
    color: var(--text);
    font-family: var(--wgc-font-body);
    font-size: 13px;
    font-weight: 700;
    line-height: 1.42;
    text-decoration: none;
    transition: color var(--ease-fast) !important;
}

.wgc-sb-post-title:hover { color: var(--green) !important; }

.wgc-sb-post-date {
    display: block;
    color: var(--text-3);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .02em;
}

/* ── Categories ── */
.wgc-sb-cat-list { margin: 0; padding: 0; list-style: none; }

.wgc-sb-cat-item { border-bottom: 1px solid var(--border-2); }
.wgc-sb-cat-item:last-child { border-bottom: 0; }

.wgc-sb-cat-item a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 9px 0;
    color: var(--text);
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: color var(--ease-fast) !important;
}

.wgc-sb-cat-item a:hover { color: var(--green) !important; }

.wgc-sb-cat-name { flex: 1 1 0; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.wgc-sb-cat-count {
    flex: 0 0 auto;
    padding: 2px 7px;
    border-radius: 999px;
    background: var(--surface-3);
    color: var(--text-3);
    font-size: 11px;
    font-weight: 700;
    line-height: 18px;
    transition: background var(--ease), color var(--ease-fast) !important;
}

.wgc-sb-cat-item a:hover .wgc-sb-cat-count { background: var(--green); color: #fff; }

/* ═══════════════════════════════════════════════════════════
   GLOBAL IMAGE CURVES
═══════════════════════════════════════════════════════════ */

.wgc-single-content img,
.wgc-single-content figure img,
.wgc-single-content .wp-block-image img,
.wgc-single-content .wp-block-cover img { border-radius: var(--r-lg); }

.wgc-single-featured img { border-radius: var(--r-xl); }

/* ═══════════════════════════════════════════════════════════
   AUTHOR BOX
═══════════════════════════════════════════════════════════ */

.wgc-author-box {
    position: relative;
    margin-top: 44px;
    padding: 28px 28px 28px 22px;
    background: var(--surface);
    border-radius: var(--r-lg);
    border-left: 3px solid var(--green);
    border: 1px solid var(--border-2);
    border-left: 3px solid var(--green);
    box-shadow: var(--sh-sm);
    overflow: hidden;
}

.wgc-author-box::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(80,168,0,.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(80,168,0,.04) 1px, transparent 1px);
    background-size: 28px 28px;
    pointer-events: none;
    z-index: 0;
}

.wgc-author-box::after {
    content: "";
    position: absolute;
    top: -40px;
    right: -40px;
    width: 160px;
    height: 160px;
    background: radial-gradient(circle,rgba(80,168,0,.07) 0%,transparent 65%);
    pointer-events: none;
    z-index: 0;
}

.wgc-author-box-label,
.wgc-author-box-inner { position: relative; z-index: 1; }

.wgc-author-box-label {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 18px;
    font-family: var(--wgc-font-mono);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .12em;
    color: var(--green);
    text-transform: uppercase;
}

.wgc-author-box-label::before { content: "//"; font-size: 12px; opacity: .6; }

.wgc-author-box-inner {
    display: flex;
    align-items: flex-start;
    gap: 22px;
}

.wgc-author-avatar-wrap { flex: 0 0 88px; width: 88px; }
.wgc-author-avatar-wrap a { display: block; }

.wgc-author-avatar-img {
    display: block !important;
    width: 88px !important;
    height: 88px !important;
    border-radius: 50% !important;
    border: 3px solid var(--green) !important;
    box-shadow: 0 0 0 3px rgba(80,168,0,.14) !important;
    object-fit: cover !important;
}

.wgc-author-info { flex: 1; min-width: 0; }

.wgc-author-name {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    margin: 0 0 4px;
    font-family: var(--wgc-font-heading);
    font-size: 18px;
    font-weight: 800;
    line-height: 1.2;
    color: var(--text);
}

.wgc-author-name a { color: var(--text); text-decoration: none; transition: color var(--ease-fast) !important; }
.wgc-author-name a:hover { color: var(--green) !important; }

.wgc-author-role {
    margin-bottom: 10px;
    font-family: var(--wgc-font-mono);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .06em;
    color: var(--green);
}

.wgc-author-bio {
    margin: 0 0 16px;
    color: var(--text-2);
    font-size: 14px;
    line-height: 1.7;
}

.wgc-author-posts-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 18px;
    border: 1px solid rgba(80,168,0,.4);
    border-radius: var(--r-sm);
    background: rgba(80,168,0,.06);
    color: var(--green);
    font-family: var(--wgc-font-mono);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .05em;
    text-decoration: none;
    text-transform: uppercase;
    transition: background var(--ease), border-color var(--ease) !important;
}

.wgc-author-posts-btn:hover {
    background: rgba(80,168,0,.12) !important;
    border-color: var(--green) !important;
    color: var(--green-h) !important;
}

.wgc-author-posts-btn svg { flex: 0 0 14px; width: 14px; height: 14px; }

@media (max-width: 599px) {
    .wgc-author-box { padding: 22px 18px 22px 16px; }
    .wgc-author-box-inner { flex-direction: column; align-items: center; text-align: center; gap: 16px; }
    .wgc-author-name { justify-content: center; }
}

/* ═══════════════════════════════════════════════════════════
   RELATED ARTICLES — CYBER PANEL
═══════════════════════════════════════════════════════════ */

.wgc-related-section {
    margin-top: 44px;
    border-radius: var(--r-lg);
    overflow: hidden;
    border: 1px solid var(--panel-b2);
    background: var(--panel);
}

.wgc-related-header {
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 14px 20px;
    background: rgba(34,209,127,.05);
    border-bottom: 1px solid var(--panel-b2);
}

.wgc-related-icon { display: flex; align-items: center; color: var(--green-b); flex: 0 0 20px; }
.wgc-related-icon svg { width: 20px; height: 20px; }

.wgc-related-title {
    margin: 0;
    font-family: var(--wgc-font-mono);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .14em;
    color: var(--green-b);
    text-transform: uppercase;
}

.wgc-related-title::before { content: "// "; opacity: .6; }

.wgc-related-grid {
    display: grid;
    grid-template-columns: repeat(2,minmax(0,1fr));
    gap: 1px;
    background: var(--panel-b);
}

@media (min-width: 768px)  { .wgc-related-grid { grid-template-columns: repeat(4,minmax(0,1fr)); } }
@media (max-width: 480px)  { .wgc-related-grid { grid-template-columns: 1fr; } }

.wgc-rel-card { position: relative; background: var(--panel); }
.wgc-rel-card:hover { background: var(--panel-2); }

.wgc-rel-card-link { display: block; text-decoration: none; color: inherit; height: 100%; }

.wgc-rel-media {
    position: relative;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: var(--panel-2);
    border-radius: var(--r-md) var(--r-md) 0 0;
}

.wgc-rel-img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: var(--r-md) var(--r-md) 0 0;
    transition: transform .4s ease !important;
}

.wgc-rel-card-link:hover .wgc-rel-img { transform: scale(1.07) !important; }

.wgc-rel-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--panel-2) 0%, var(--panel) 100%);
}

.wgc-rel-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top,rgba(13,17,23,.88) 0%,rgba(13,17,23,.18) 55%,transparent 100%);
    border-radius: var(--r-md) var(--r-md) 0 0;
}

.wgc-rel-cat {
    position: absolute;
    top: 9px;
    left: 9px;
    z-index: 2;
    padding: 3px 9px;
    background: var(--green-b);
    color: #0d1117;
    font-family: var(--wgc-font-mono);
    font-size: 9px;
    font-weight: 900;
    letter-spacing: .1em;
    text-transform: uppercase;
    border-radius: var(--r-sm);
}

.wgc-rel-body {
    padding: 12px 14px 14px;
    border-top: 1px solid var(--panel-b);
}

.wgc-rel-post-title {
    margin: 0 0 10px;
    color: var(--panel-t);
    font-family: var(--wgc-font-body);
    font-size: 13px;
    font-weight: 700;
    line-height: 1.42;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color var(--ease-fast) !important;
}

.wgc-rel-card-link:hover .wgc-rel-post-title { color: var(--green-b) !important; }

.wgc-rel-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    color: var(--panel-m);
    font-family: var(--wgc-font-mono);
    font-size: 10px;
    letter-spacing: .04em;
}

.wgc-rel-arrow {
    color: var(--green-b);
    font-size: 13px;
    opacity: 0;
    transform: translateX(-4px);
    transition: opacity .18s, transform .18s !important;
}

.wgc-rel-card-link:hover .wgc-rel-arrow { opacity: 1 !important; transform: translateX(0) !important; }

.wgc-rel-card::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--green-b);
    transform: scaleY(0);
    transform-origin: bottom;
    transition: transform .22s ease !important;
    z-index: 2;
}

.wgc-rel-card:hover::before { transform: scaleY(1) !important; }


/* ═══════════════════════════════════════════════════════════
   DARK MODE — COMPREHENSIVE EXPLICIT OVERRIDES
   These use !important to beat hardcoded parent-theme colors.
═══════════════════════════════════════════════════════════ */

/* ── Surfaces & backgrounds ── */
[data-theme="dark"] body,
[data-theme="dark"] .options_layout_wrapper,
[data-theme="dark"] .options_layout_container {
    background-color: var(--bg) !important;
    color: var(--text) !important;
}

[data-theme="dark"] .wgc-single-main,
[data-theme="dark"] .wgc-single-article,
[data-theme="dark"] .wgc-single-hero {
    background: var(--bg) !important;
    color: var(--text) !important;
}

[data-theme="dark"] .wgc-news-slider,
[data-theme="dark"] .wgc-cat-section,
[data-theme="dark"] .wgc-hero-news,
[data-theme="dark"] .wgc-feature-posts,
[data-theme="dark"] .wgc-homepage {
    background: var(--surface) !important;
    border-color: var(--border-2) !important;
    color: var(--text) !important;
}

[data-theme="dark"] .wgc-sb-widget,
[data-theme="dark"] .wgc-author-box {
    background: var(--surface) !important;
    border-color: var(--border) !important;
    color: var(--text) !important;
}

/* ── ALL headings & titles ── */
[data-theme="dark"] .wgc-single-title,
[data-theme="dark"] .wgc-home-heading,
[data-theme="dark"] .wgc-block-heading,
[data-theme="dark"] .wgc-section-title,
[data-theme="dark"] .wgc-title,
[data-theme="dark"] .wgc-title a,
[data-theme="dark"] .wgc-card--lead .wgc-title,
[data-theme="dark"] .wgc-card--small .wgc-title,
[data-theme="dark"] .wgc-row .wgc-title,
[data-theme="dark"] .wgc-feature-title,
[data-theme="dark"] .wgc-author-name,
[data-theme="dark"] .wgc-author-name a,
[data-theme="dark"] .wgc-sb-post-title,
[data-theme="dark"] .wgc-sb-title {
    color: var(--text) !important;
}

/* ── Post content headings ── */
[data-theme="dark"] .wgc-single-content,
[data-theme="dark"] .wgc-single-content h1,
[data-theme="dark"] .wgc-single-content h2,
[data-theme="dark"] .wgc-single-content h3,
[data-theme="dark"] .wgc-single-content h4,
[data-theme="dark"] .wgc-single-content h5,
[data-theme="dark"] .wgc-single-content h6,
[data-theme="dark"] .wgc-single-content p,
[data-theme="dark"] .wgc-single-content li,
[data-theme="dark"] .wgc-single-content td,
[data-theme="dark"] .jl_content,
[data-theme="dark"] .post_content,
[data-theme="dark"] .entry-content,
[data-theme="dark"] .entry-content h1,
[data-theme="dark"] .entry-content h2,
[data-theme="dark"] .entry-content h3,
[data-theme="dark"] .entry-content h4,
[data-theme="dark"] .entry-content p {
    color: var(--text) !important;
    background: transparent !important;
}

/* ── Secondary text ── */
[data-theme="dark"] .wgc-single-byline,
[data-theme="dark"] .wgc-single-byline a,
[data-theme="dark"] .wgc-single-date,
[data-theme="dark"] .wgc-meta,
[data-theme="dark"] .wgc-meta a,
[data-theme="dark"] .wgc-excerpt,
[data-theme="dark"] .wgc-author-bio,
[data-theme="dark"] .wgc-sb-post-date,
[data-theme="dark"] .wgc-single-dates,
[data-theme="dark"] .wgc-date-icon {
    color: var(--text-2) !important;
}

/* ── Sidebar widget borders ── */
[data-theme="dark"] .wgc-sb-post-item,
[data-theme="dark"] .wgc-sb-cat-item {
    border-color: var(--border-2) !important;
}

[data-theme="dark"] .wgc-sb-cat-count {
    background: var(--surface-2) !important;
    color: var(--text-3) !important;
}

/* ── Blockquotes ── */
[data-theme="dark"] .wgc-single-content blockquote,
[data-theme="dark"] .wgc-single-content .wp-block-quote,
[data-theme="dark"] .wgc-single-content .wp-block-pullquote {
    background: var(--surface) !important;
    color: var(--text) !important;
    border-left-color: var(--blue) !important;
}

[data-theme="dark"] .wgc-single-content blockquote p,
[data-theme="dark"] .wgc-single-content .wp-block-quote p,
[data-theme="dark"] .wgc-single-content .wp-block-pullquote p {
    color: var(--text) !important;
}

/* ── Cards & grids ── */
[data-theme="dark"] .wgc-grid-card-title,
[data-theme="dark"] .wgc-grid-card-date { color: var(--text) !important; }

[data-theme="dark"] .wgc-grid-card-img,
[data-theme="dark"] .wgc-media { background: var(--surface-2) !important; }

/* ── Borders ── */
[data-theme="dark"] .wgc-featured,
[data-theme="dark"] .wgc-row { border-bottom-color: var(--border) !important; }

/* ── Parent theme generic overrides ── */
[data-theme="dark"] .jl_post_content,
[data-theme="dark"] .jl_post_content *:not(img):not(pre):not(code),
[data-theme="dark"] .jl-main-block,
[data-theme="dark"] .jl_content *:not(img):not(pre):not(code) {
    color: var(--text) !important;
    background-color: transparent !important;
}

[data-theme="dark"] .jl_sfoot,
[data-theme="dark"] .jl_sfoot *,
[data-theme="dark"] .jl_auth_single,
[data-theme="dark"] .jl_auth_single *,
[data-theme="dark"] .single_section_comment,
[data-theme="dark"] .single_section_comment * {
    background: var(--surface) !important;
    color: var(--text-2) !important;
    border-color: var(--border) !important;
}

/* Parent theme links in dark */
[data-theme="dark"] .wgc-single-content a { color: var(--blue) !important; }
[data-theme="dark"] .wgc-single-content a:hover { color: var(--blue-h) !important; }

/* ── Author box dark fixes ── */
[data-theme="dark"] .wgc-author-box-label { color: var(--green) !important; }
[data-theme="dark"] .wgc-author-role      { color: var(--green) !important; }
[data-theme="dark"] .wgc-author-posts-btn {
    border-color: rgba(74,222,128,.35) !important;
    background: rgba(74,222,128,.06) !important;
    color: var(--green) !important;
}

/* ── Tags & single footer ── */
[data-theme="dark"] .single_tag_share,
[data-theme="dark"] .single_tag_share *,
[data-theme="dark"] .jl_t_tag,
[data-theme="dark"] .jl_t_tag * {
    background: var(--surface-2) !important;
    color: var(--text-2) !important;
    border-color: var(--border) !important;
}

/* ── Comments section ── */
[data-theme="dark"] #comments,
[data-theme="dark"] .comment-list,
[data-theme="dark"] .comment-list *:not(img) {
    background: transparent !important;
    color: var(--text-2) !important;
    border-color: var(--border) !important;
}

[data-theme="dark"] .comment-form *,
[data-theme="dark"] #respond *:not(input):not(textarea) {
    color: var(--text-2) !important;
    background: transparent !important;
}

[data-theme="dark"] #respond input,
[data-theme="dark"] #respond textarea {
    background: var(--surface-2) !important;
    color: var(--text) !important;
    border-color: var(--border) !important;
}

/* ── Pagination ── */
[data-theme="dark"] .wgc-pagination,
[data-theme="dark"] .wgc-pagination *,
[data-theme="dark"] .jl_pag *,
[data-theme="dark"] .jl_pagination * {
    background: var(--surface) !important;
    color: var(--text-2) !important;
    border-color: var(--border) !important;
}

/* ── Homepage bg ── */
[data-theme="dark"] body,
[data-theme="dark"] .wgc-home,
[data-theme="dark"] .wgc-homepage { background: var(--bg) !important; }

[data-theme="dark"] .wgc-hero-news,
[data-theme="dark"] .wgc-feature-posts {
    background: var(--surface) !important;
    border-color: var(--border-2) !important;
}

[data-theme="dark"] .wgc-section-title span { color: var(--text-3) !important; }
[data-theme="dark"] .wgc-kicker { color: var(--red) !important; }

/* ── Archive / Category / Search pages — parent theme containers ── */
[data-theme="dark"] .archive_wrap,
[data-theme="dark"] .category_wrap,
[data-theme="dark"] .jl_blog_wrap,
[data-theme="dark"] .jl_search_wrap,
[data-theme="dark"] .jl_archive_wrap,
[data-theme="dark"] .jl_index_wrap,
[data-theme="dark"] .jl_posts_wrap {
    background: var(--bg) !important;
    color: var(--text) !important;
}

[data-theme="dark"] .jl_post_item,
[data-theme="dark"] .jl_post_box,
[data-theme="dark"] .jl_post_card,
[data-theme="dark"] .jl_item_wrap,
[data-theme="dark"] .post-item,
[data-theme="dark"] .post-card,
[data-theme="dark"] .article-card {
    background: var(--surface) !important;
    border-color: var(--border-2) !important;
    color: var(--text) !important;
}

[data-theme="dark"] .jl_post_item *:not(img):not(iframe):not(.wgc-verified-badge),
[data-theme="dark"] .jl_post_box *:not(img):not(iframe),
[data-theme="dark"] .jl_post_card *:not(img):not(iframe) {
    color: inherit !important;
    background: transparent !important;
}

[data-theme="dark"] .jl_cat_title,
[data-theme="dark"] .jl_archive_title,
[data-theme="dark"] .jl_page_title,
[data-theme="dark"] .page-header,
[data-theme="dark"] .page-title,
[data-theme="dark"] .archive-title,
[data-theme="dark"] .category-title {
    color: var(--text) !important;
    background: transparent !important;
    border-color: var(--border) !important;
}

/* ── Search results ── */
[data-theme="dark"] .search-results,
[data-theme="dark"] .search-no-results,
[data-theme="dark"] .jl_search_form input[type="search"],
[data-theme="dark"] .search-field {
    background: var(--surface-2) !important;
    color: var(--text) !important;
    border-color: var(--border) !important;
}

/* ── Wesper post-list cards (archive layout) ── */
[data-theme="dark"] .jl_relsec_wrap,
[data-theme="dark"] .jl_relsec_wrap *:not(img):not(.wgc-verified-badge) {
    background: transparent !important;
    color: var(--text-2) !important;
}

[data-theme="dark"] .jl_relsec_wrap h2,
[data-theme="dark"] .jl_relsec_wrap h3,
[data-theme="dark"] .jl_relsec_wrap .jl_rel_title {
    color: var(--text) !important;
}

/* ── Mobile logo height increase (overrides wesper parent at 767px) ── */
@media only screen and (max-width: 767px) {
    .logo_small_wrapper_table .logo_small_wrapper .logo_link img {
        max-width: 150px !important;
    }
}

/* ═══════════════════════════════════════════════════════════
   DARK MODE — PARENT THEME CSS VARIABLE REMAPPING
   The parent theme sets --jl-* variables on `body`, not :root,
   so we must target `[data-theme="dark"] body` to ensure our
   overrides beat the body-level declarations and cascade to
   all descendant elements (archive titles, category labels,
   sidebar widgets, post meta, etc.).
═══════════════════════════════════════════════════════════ */

[data-theme="dark"] body {
    /* Core colors */
    --jl-bg-color:              #090c15;
    --jl-txt-color:             #eef0ff;
    --jl-except-color:          #a8b2d0;
    --jl-meta-color:            #a8b2d0;
    --jl-post-line-color:       #1e2445;
    --jl-main-color:            #4ade80;

    /* Single post content */
    --jl-single-color:          #eef0ff;
    --jl-single-link-color:     #60a5fa;
    --jl-single-link-hcolor:    #93c5fd;
    --jl-single-head-color:     #eef0ff;
    --jl-theme-head-color:      #eef0ff;
    --jl-single-h1-color:       #eef0ff;
    --jl-single-h2-color:       #d0d8f4;
    --jl-single-h3-color:       #d0d8f4;
    --jl-single-h4-color:       #d0d8f4;
    --jl-single-h5-color:       #d0d8f4;
    --jl-single-h6-color:       #d0d8f4;

    /* Navigation */
    --jl-menu-bg:               #05060e;
    --jl-menu-color:            #eef0ff;
    --jl-menu-line-color:       #1e2445;
    --jl-sub-bg-color:          #0f1221;
    --jl-sub-menu-color:        #a8b2d0;
    --jl-sub-line-color:        #1e2445;
    --jl-topbar-bg:             #05060e;
    --jl-topbar-color:          #a8b2d0;

    /* Header / logo */
    --jl-logo-bg:               #05060e;
    --jl-logo-color:            #eef0ff;
    --jl-logo-txt-color:        #eef0ff;
    --jl-logo-txt-side-color:   #eef0ff;

    /* Buttons / comments */
    --jl-btn-bg:                #0f1221;
    --jl-comment-btn-link:      #4ade80;
    --jl-comment-btn-linkc:     #090c15;
    --jl-author-bg:             #0f1221;

    /* Footer */
    --jl-foot-bg:               #05060e;
    --jl-foot-color:            #a8b2d0;
    --jl-foot-link:             #60a5fa;
    --jl-foot-hlink:            #93c5fd;
    --jl-foot-head:             #eef0ff;
    --jl-foot-line:             #1e2445;
}

/* ── Archive / Category page title ── */
[data-theme="dark"] .jl_pc_sec_title,
[data-theme="dark"] .jl_pc_sec_h,
[data-theme="dark"] .jl_pc_sec_title h1,
[data-theme="dark"] .jl_pc_sec_title h2,
[data-theme="dark"] .jl_pc_sec_title h3 {
    color: var(--text) !important;
    background: transparent !important;
}

[data-theme="dark"] .post_subtitle_text,
[data-theme="dark"] .post_subtitle_text p {
    color: var(--text-2) !important;
}

/* ── Breadcrumb ── */
[data-theme="dark"] .jl_breadcrumbs,
[data-theme="dark"] .jl_breadcrumbs a,
[data-theme="dark"] .jl_breadcrumbs span {
    color: var(--text-3) !important;
}

/* ── Archive / Category / Author — post list cards ── */
[data-theme="dark"] .jl_block_content,
[data-theme="dark"] .jl_wrapper_cat,
[data-theme="dark"] .jl-main-block,
[data-theme="dark"] .jl_fli_wrap,
[data-theme="dark"] .jl_main_list_cw,
[data-theme="dark"] .jl_lm_list {
    background: var(--bg) !important;
    color: var(--text) !important;
}

[data-theme="dark"] .jl_clist_layout {
    background: var(--surface) !important;
    border-color: var(--border) !important;
}

[data-theme="dark"] .jl_li_in {
    background: transparent !important;
}

[data-theme="dark"] .jl_fe_title a,
[data-theme="dark"] .jl_fe_title {
    color: var(--text) !important;
}

[data-theme="dark"] .jl_fe_des,
[data-theme="dark"] .jl_fe_text p {
    color: var(--text-2) !important;
}

[data-theme="dark"] .jl_fe_text {
    background: transparent !important;
    color: var(--text) !important;
}

/* Post category labels (.jl_cat_txt uses var(--jl-txt-color) by default — remap to accent) */
[data-theme="dark"] .jl_f_cat .jl_cat_txt,
[data-theme="dark"] .jl_f_cat .jl_cat_txt:hover {
    color: var(--green) !important;
}

/* Post meta spans (.jl_post_meta span uses var(--jl-meta-color)) */
[data-theme="dark"] .jl_post_meta span,
[data-theme="dark"] .jl_post_meta a,
[data-theme="dark"] .jl_post_meta span a,
[data-theme="dark"] .post-date {
    color: var(--text-3) !important;
}

/* Divider lines between archive posts */
[data-theme="dark"] .jl_clist_layout + .jl_clist_layout,
[data-theme="dark"] .jl_lisep + .jl_lisep {
    border-top-color: var(--border) !important;
}

/* ── Sidebar widget titles & content ── */
[data-theme="dark"] .widget-title,
[data-theme="dark"] .widget-title h2,
[data-theme="dark"] .widget-title h3,
[data-theme="dark"] h3.widget-title {
    color: var(--text) !important;
    border-bottom-color: var(--border) !important;
    background: transparent !important;
}

[data-theme="dark"] .jl_smmain_side,
[data-theme="dark"] .jl_sidebar_w {
    color: var(--text) !important;
    background: transparent !important;
}

/* Sidebar category list links */
[data-theme="dark"] .jl_smmain_side .widget ul li a,
[data-theme="dark"] .jl_sidebar_w .widget ul li a,
[data-theme="dark"] .jl_smmain_side a,
[data-theme="dark"] .jl_sidebar_w a {
    color: var(--text-2) !important;
}

[data-theme="dark"] .jl_smmain_side .widget ul li a:hover,
[data-theme="dark"] .jl_sidebar_w .widget ul li a:hover {
    color: var(--green) !important;
}

/* Sidebar category post counts */
[data-theme="dark"] .jl_smmain_side .widget ul li,
[data-theme="dark"] .jl_sidebar_w .widget ul li {
    color: var(--text-3) !important;
    border-color: var(--border) !important;
}

/* ── Author archive page header ── */
[data-theme="dark"] .jl_auth_head,
[data-theme="dark"] .jl_info_auth,
[data-theme="dark"] .author-description,
[data-theme="dark"] .author-description h5,
[data-theme="dark"] .author-description h5 a {
    color: var(--text) !important;
    background: transparent !important;
}

[data-theme="dark"] .author-description p,
[data-theme="dark"] .jl_auth_lbl {
    color: var(--text-2) !important;
}

[data-theme="dark"] .author_postcount,
[data-theme="dark"] .author_commentcount {
    color: var(--text-2) !important;
    background: rgba(74, 222, 128, .12) !important;
}

[data-theme="dark"] .jl_auth_link li a {
    color: var(--text-3) !important;
}

[data-theme="dark"] .jl_auth_link li a:hover {
    color: var(--green) !important;
}

/* ── Mobile side-drawer ── */
[data-theme="dark"] #jl_sb_nav.jl_mobile_nav_wrapper {
    background: var(--drawer) !important;
    color: var(--text) !important;
    box-shadow: none !important;
}

[data-theme="dark"] #jl_sb_nav .menu_moble_slide li a {
    color: var(--text) !important;
}

[data-theme="dark"] #jl_sb_nav .menu_moble_slide > li + li {
    border-color: var(--border) !important;
}

/* The close (X) icon bars — hardcoded #000 in parent theme */
[data-theme="dark"] .jl_close_wapper .jl_close_1,
[data-theme="dark"] .jl_close_wapper .jl_close_2 {
    background-color: var(--text) !important;
}

/* Drawer footer (social + copyright) */
[data-theme="dark"] .nav_mb_f {
    background: var(--drawer-f) !important;
    color: var(--text-2) !important;
}

[data-theme="dark"] .nav_mb_f .jl_sh_ic_li li a,
[data-theme="dark"] .nav_mb_f .cp_txt,
[data-theme="dark"] .nav_mb_f .cp_txt a {
    color: var(--text-3) !important;
}

/* Search overlay inside drawer */
[data-theme="dark"] .search_form_menu_personal {
    background: var(--drawer) !important;
}

[data-theme="dark"] .search_form_menu_personal input[type="search"],
[data-theme="dark"] .search_form_menu_personal .search-field {
    background: var(--surface-2) !important;
    color: var(--text) !important;
    border-color: var(--border) !important;
}

/* ── Footer ── */
[data-theme="dark"] .jl_footer,
[data-theme="dark"] .jl_footer_section,
[data-theme="dark"] .jl_foot_wrap,
[data-theme="dark"] footer,
[data-theme="dark"] .footer-widget-area,
[data-theme="dark"] .jl_foot_inner {
    background: var(--drawer-f) !important;
    border-color: var(--border) !important;
}

[data-theme="dark"] .jl_footer a,
[data-theme="dark"] .jl_foot_wrap a {
    color: var(--blue) !important;
}

[data-theme="dark"] .jl_footer a:hover,
[data-theme="dark"] .jl_foot_wrap a:hover {
    color: var(--blue-h) !important;
}

/* ═══════════════════════════════════════════════════════════
   DARK MODE — HOMEPAGE (exh-* hardcoded in parent template)
   home-page-builder.php injects a <style> with `body .exh-*`
   selectors (specificity 0,0,1,1). We use
   `[data-theme="dark"] body .exh-*` (specificity 0,1,1,1) to
   win when both sides use !important.
═══════════════════════════════════════════════════════════ */

[data-theme="dark"] body .exh-home-wrap {
    background: var(--bg) !important;
}

[data-theme="dark"] body .exh-slider-card,
[data-theme="dark"] body .exh-grid-card-wrap {
    background: var(--surface) !important;
    box-shadow: var(--sh-md) !important;
}

[data-theme="dark"] body .exh-heading {
    color: var(--text) !important;
}

[data-theme="dark"] body .exh-post-link {
    color: var(--text) !important;
}

[data-theme="dark"] body .exh-post-title {
    color: var(--text) !important;
}

/* ═══════════════════════════════════════════════════════════
   DARK MODE — BUTTONS & FORM ELEMENTS
═══════════════════════════════════════════════════════════ */

/* ── Pagination dots (hardcoded color:#000 in parent theme) ── */
[data-theme="dark"] .jellywp_pagination ul li .page-numbers.dots {
    color: var(--text-3) !important;
}

/* ── Pagination numbered items ── */
[data-theme="dark"] .jellywp_pagination ul li a,
[data-theme="dark"] .jellywp_pagination ul li span:not(.page-numbers.dots) {
    background: var(--surface) !important;
    color: var(--text-2) !important;
    border: 1px solid var(--border) !important;
}

[data-theme="dark"] .jellywp_pagination ul li a:hover,
[data-theme="dark"] .jellywp_pagination ul li span.current {
    background: var(--green) !important;
    color: #fff !important;
    border-color: var(--green) !important;
}

/* ── Infinite scroll "load more" link (hardcoded #fff / #ececec) ── */
[data-theme="dark"] .jelly-infinite-scroll a {
    background: var(--surface) !important;
    border-color: var(--border) !important;
    color: var(--text) !important;
}

[data-theme="dark"] .jelly-infinite-scroll a:hover,
[data-theme="dark"] .jelly-infinite-scroll a:focus {
    background: var(--surface-2) !important;
    border-color: var(--green) !important;
    color: var(--green) !important;
}

/* ── Load-more block button (jl_lmore_c) ── */
[data-theme="dark"] .jl_lmore_c {
    border: 2px solid var(--green) !important;
}

[data-theme="dark"] .jl_lmore_c:hover {
    background: var(--surface-2) !important;
    border-color: var(--green) !important;
}

/* ── Next / prev block nav ── */
[data-theme="dark"] .pagination-nextprev .jl-foot-nav {
    color: var(--text-2) !important;
    border-color: var(--border) !important;
    background: var(--surface) !important;
}

[data-theme="dark"] .pagination-nextprev .jl-foot-nav:hover {
    background: var(--green) !important;
    border-color: var(--green) !important;
    color: #fff !important;
}

/* ── Generic button hover — add border so it stays visible on dark bg ── */
[data-theme="dark"] button:not(.wgc-icon-button):not(.wgc-theme-toggle):not(.wgc-drawer-close):not(.exh-dot):not(.wgc-hero-dot):not(.wgc-dot) {
    border: 1px solid var(--border) !important;
}

[data-theme="dark"] button:not(.wgc-icon-button):not(.wgc-theme-toggle):not(.wgc-drawer-close):not(.exh-dot):not(.wgc-hero-dot):not(.wgc-dot):hover {
    border-color: var(--green) !important;
}

/* ── Submit / primary action buttons ── */
[data-theme="dark"] input[type='submit'],
[data-theme="dark"] .jl_comment_btn,
[data-theme="dark"] .jl_comment_btn input[type='submit'] {
    background: var(--green) !important;
    border: 2px solid var(--green) !important;
    color: #fff !important;
}

[data-theme="dark"] input[type='submit']:hover,
[data-theme="dark"] .jl_comment_btn:hover,
[data-theme="dark"] .jl_comment_btn input[type='submit']:hover {
    background: var(--green-h) !important;
    border-color: var(--green-h) !important;
}

/* ── Form inputs & textareas ── */
[data-theme="dark"] input[type='text'],
[data-theme="dark"] input[type='tel'],
[data-theme="dark"] input[type='password'],
[data-theme="dark"] input[type='email'],
[data-theme="dark"] input[type='url'],
[data-theme="dark"] input[type='search'],
[data-theme="dark"] input[type='number'],
[data-theme="dark"] textarea,
[data-theme="dark"] select {
    background: var(--surface-2) !important;
    color: var(--text) !important;
    border-color: var(--border) !important;
}

[data-theme="dark"] input[type='text']:focus,
[data-theme="dark"] input[type='email']:focus,
[data-theme="dark"] input[type='search']:focus,
[data-theme="dark"] textarea:focus,
[data-theme="dark"] select:focus {
    border-color: var(--green) !important;
    outline: none !important;
    box-shadow: 0 0 0 2px rgba(74,222,128,.15) !important;
}

/* ── WP Gutenberg button blocks ── */
[data-theme="dark"] .wp-block-button__link {
    background: var(--green) !important;
    color: #fff !important;
    border: 2px solid var(--green) !important;
}

[data-theme="dark"] .wp-block-button.is-style-outline .wp-block-button__link {
    background: transparent !important;
    color: var(--green) !important;
    border-color: var(--green) !important;
}

/* ── Cookie notice / GDPR buttons (hardcoded dark bg in parent) ── */
[data-theme="dark"] .jl_cookie_btn,
[data-theme="dark"] .jl_cookie_btn a {
    background: var(--green) !important;
    border: 1px solid var(--green) !important;
    color: #fff !important;
}

/* ═══════════════════════════════════════════════════════════
   ARCHIVE / CATEGORY / AUTHOR — DISCOVER-STYLE GRID
═══════════════════════════════════════════════════════════ */

.wgc-archive-wrap {
    width: 100%;
    margin: 0;
    padding: 28px 18px 46px;
    background: #f3f4f6;
    box-sizing: border-box;
}

.wgc-archive-section {
    width: min(1220px, 100%);
    margin: 0 auto;
    padding: 34px 30px 42px;
    background: #fff;
    border-radius: 26px;
    border: 1px solid rgba(11,15,40,.08);
    box-shadow: 0 2px 8px rgba(11,15,40,.06), 0 10px 36px rgba(11,15,40,.09);
    box-sizing: border-box;
}

.wgc-archive-header {
    margin-bottom: 28px;
    padding-bottom: 16px;
    border-bottom: 3px solid #50a800;
}

.wgc-archive-heading {
    margin: 0;
    color: #061732;
    font-family: Arial, Helvetica, sans-serif;
    font-size: clamp(24px, 3vw, 44px);
    font-weight: 900;
    line-height: 1;
    text-transform: uppercase;
}

.wgc-archive-desc {
    margin: 10px 0 0;
    color: #555;
    font-size: 15px;
    line-height: 1.5;
}

.wgc-arc-empty {
    padding: 48px 0;
    text-align: center;
    color: #666;
    font-size: 16px;
}

/* ── Card styles for exh-* classes on archive pages ── */

.wgc-archive-section .exh-discover-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 30px 24px;
}

.wgc-archive-section .exh-post-card { margin: 0; }

.wgc-archive-section .exh-post-link {
    display: block;
    color: #0f1525;
    text-decoration: none;
    transition: transform .22s ease;
}

.wgc-archive-section .exh-post-link:hover { transform: translateY(-5px); }

.wgc-archive-section .exh-post-media {
    position: relative;
    overflow: hidden;
    aspect-ratio: 4 / 3;
    border-radius: 20px;
    background: #111;
    box-shadow: 0 3px 14px rgba(0,0,0,.16);
}

.wgc-archive-section .exh-post-media img,
.wgc-archive-section .exh-placeholder {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.wgc-archive-section .exh-placeholder {
    background: linear-gradient(135deg, #222, #555);
}

.wgc-archive-section .exh-post-media::after {
    content: "";
    position: absolute;
    inset: 45% 0 0;
    background: linear-gradient(to top, rgba(0,0,0,.72), transparent);
}

.wgc-archive-section .exh-post-date {
    position: absolute;
    left: 16px;
    right: 12px;
    bottom: 16px;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 8px;
    color: #fff;
    font-size: clamp(12px, 1.1vw, 17px);
    font-weight: 300;
    line-height: 1.1;
    text-shadow: 0 1px 4px rgba(0,0,0,.7);
}

.wgc-archive-section .exh-red-bar {
    display: block;
    flex: 0 0 3px;
    width: 3px;
    height: 20px;
    background: #d50016;
    flex-shrink: 0;
}

.wgc-archive-section .exh-post-title {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 18px 0 0;
    color: #0f1525;
    font-family: Arial, Helvetica, sans-serif;
    font-size: clamp(16px, 1.5vw, 26px);
    font-weight: 900;
    line-height: 1.26;
}

.wgc-archive-section .exh-post-title .exh-red-bar {
    height: 24px;
    margin-top: 3px;
}

.wgc-archive-section .exh-load-more {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin: 34px auto 0;
    padding: 14px 30px;
    border: 0;
    border-radius: 6px;
    background: #0a0a0a;
    color: #fff;
    font-size: 16px;
    font-weight: 900;
    text-transform: uppercase;
    cursor: pointer;
}

.wgc-archive-section .exh-load-more::before {
    content: "";
    display: none;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255,255,255,.45);
    border-top-color: #fff;
    border-radius: 50%;
    animation: exhLoadSpin .75s linear infinite;
}

.wgc-archive-section .exh-load-more.is-loading::before { display: inline-block; }
.wgc-archive-section .exh-load-more.is-loading { opacity: .82; cursor: wait; }

@media (max-width: 760px) {
    .wgc-archive-wrap { padding: 20px 12px 32px; }
    .wgc-archive-section { padding: 22px 16px 28px; border-radius: 20px; }
    .wgc-archive-section .exh-discover-grid { gap: 20px 12px; }
    .wgc-archive-section .exh-post-media { border-radius: 14px; }
    .wgc-archive-section .exh-post-date { left: 10px; bottom: 10px; font-size: 12px; }
    .wgc-archive-section .exh-red-bar { height: 16px; }
    .wgc-archive-section .exh-post-title { font-size: 16px; margin-top: 10px; gap: 7px; }
    .wgc-archive-section .exh-post-title .exh-red-bar { height: 18px; }
}

@media (max-width: 480px) {
    .wgc-archive-section .exh-discover-grid { grid-template-columns: 1fr; }
    .wgc-archive-section .exh-post-media { aspect-ratio: 16 / 9; }
}

/* ── Dark mode ── */
[data-theme="dark"] .wgc-archive-wrap { background: #03040a; }

[data-theme="dark"] .wgc-archive-section {
    background: #07090f;
    border-color: rgba(74,222,128,.16);
    box-shadow: 0 0 0 1px rgba(74,222,128,.05), 0 8px 44px rgba(0,0,0,.82);
}

[data-theme="dark"] .wgc-archive-header { border-bottom-color: #4ade80; }
[data-theme="dark"] .wgc-archive-heading { color: #f0f4ff; }
[data-theme="dark"] .wgc-archive-desc { color: #a0aab8; }

[data-theme="dark"] .wgc-archive-section .exh-post-link { color: #eef0ff; }
[data-theme="dark"] .wgc-archive-section .exh-red-bar { background: #4ade80; }
[data-theme="dark"] .wgc-archive-section .exh-post-title { color: #eef0ff; }
[data-theme="dark"] .wgc-archive-section .exh-post-media { box-shadow: 0 4px 24px rgba(0,0,0,.65); }

[data-theme="dark"] .wgc-archive-section .exh-load-more {
    background: rgba(74,222,128,.10);
    border: 1.5px solid rgba(74,222,128,.40);
    color: #4ade80;
}
