:root {
    --theme-bg-primary: #FFFFFF;
    --theme-bg-secondary: #F9FAFB;
    --theme-bg-tertiary: #F3F4F6;
    --theme-bg-quaternary: #E5E7EB;
    --theme-bg-elevated: #FFFFFF;
    --theme-bg-overlay: rgba(255, 255, 255, 0.8);
    --theme-bg-shallow: #f2f2f2;
    --theme-bg-muted: #F3F4F6;
    --theme-bg-accent: rgba(37, 99, 235, 0.08);

    --theme-border-primary: #D1D5DB;
    --theme-border-secondary: #E5E7EB;
    --theme-border-light: #F3F4F6;

    --theme-text-primary: #000000;
    --theme-text-secondary: #374151;
    --theme-text-muted: #6B7280;
    --theme-text-disabled: #9CA3AF;
    --theme-text-inverse: #FFFFFF;

    --theme-text-white: #fff;
    --theme-text-black: #000;
    --theme-tag-text: #fff;

    --theme-primary: #2563EB;
    --theme-tag-bg: #2563EB;
    --theme-primary-light: #3B82F6;
    --theme-primary-dark: #1D4ED8;
    --theme-border-focus: #2563EB;

    --theme-success: #2563EB;
    --theme-success-light: #3B82F6;
    --theme-success-dark: #1D4ED8;

    --theme-warning: #FFA726;
    --theme-warning-light: #FFB74D;
    --theme-warning-dark: #F57C00;

    --theme-error: #FF4444;
    --theme-error-light: #FF6B6B;
    --theme-error-dark: #E53E3E;
    --theme-border-error: #FF4444;
    --theme-border-warning: #FFA726;

    --theme-info: #5EBCFF;
    --theme-info-light: #7ECAFF;
    --theme-info-dark: #3FA8FF;

    --theme-shadow-xs: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --theme-shadow-sm: 0 1px 3px 0 rgba(0, 0, 0, 0.075);
    --theme-shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --theme-shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.15);
    --theme-shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.2);
    --theme-shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    --theme-shadow-inner: inset 0 2px 4px 0 rgba(0, 0, 0, 0.06);

    --theme-gradient-primary: var(--theme-primary);
    --theme-gradient-success: linear-gradient(135deg, var(--theme-success), var(--theme-success-dark));
    --theme-gradient-warning: linear-gradient(135deg, var(--theme-warning), var(--theme-warning-dark));
    --theme-gradient-error: linear-gradient(135deg, var(--theme-error), var(--theme-error-dark));
    --theme-gradient-soft: linear-gradient(135deg, rgba(42, 219, 92, 0.1), rgba(94, 188, 255, 0.1));

    --theme-radius-none: 0;
    --theme-radius-xs: 0.125rem;
    --theme-radius-sm: 0.25rem;
    --theme-radius-md: 0.375rem;
    --theme-radius-lg: 0.5rem;
    --theme-radius-xl: 0.75rem;
    --theme-radius-2xl: 1rem;
    --theme-radius-3xl: 1.5rem;
    --theme-radius-full: 9999px;

    --theme-spacing-0: 0;
    --theme-spacing-px: 1px;
    --theme-spacing-0-5: 0.125rem;
    --theme-spacing-1: 0.25rem;
    --theme-spacing-1-5: 0.375rem;
    --theme-spacing-2: 0.5rem;
    --theme-spacing-2-5: 0.625rem;
    --theme-spacing-3: 0.75rem;
    --theme-spacing-3-5: 0.875rem;
    --theme-spacing-4: 1rem;
    --theme-spacing-5: 1.25rem;
    --theme-spacing-6: 1.5rem;
    --theme-spacing-7: 1.75rem;
    --theme-spacing-8: 2rem;
    --theme-spacing-9: 2.25rem;
    --theme-spacing-10: 2.5rem;
    --theme-spacing-12: 3rem;
    --theme-spacing-16: 4rem;
    --theme-spacing-20: 5rem;
    --theme-spacing-24: 6rem;

    --theme-font-size-xs: 0.75rem;
    --theme-font-size-sm: 0.875rem;
    --theme-font-size-base: 1rem;
    --theme-font-size-lg: 1.125rem;
    --theme-font-size-xl: 1.25rem;
    --theme-font-size-2xl: 1.5rem;
    --theme-font-size-3xl: 1.875rem;
    --theme-font-size-4xl: 2.25rem;

    --theme-line-height-none: 1;
    --theme-line-height-tight: 1.25;
    --theme-line-height-snug: 1.375;
    --theme-line-height-normal: 1.5;
    --theme-line-height-relaxed: 1.625;
    --theme-line-height-loose: 2;

    --theme-transition-fast: 0.15s ease;
    --theme-transition-normal: 0.3s ease;
    --theme-transition-slow: 0.5s ease;
    --theme-transition-all: all var(--theme-transition-normal);

    --theme-breakpoint-sm: 640px;
    --theme-breakpoint-md: 768px;
    --theme-breakpoint-lg: 1024px;
    --theme-breakpoint-xl: 1280px;
    --theme-breakpoint-2xl: 1536px;

    --theme-z-dropdown: 1000;
    --theme-z-sticky: 1020;
    --theme-z-fixed: 1030;
    --theme-z-modal-backdrop: 1040;
    --theme-z-modal: 1050;
    --theme-z-popover: 1060;
    --theme-z-tooltip: 1070;
    --theme-z-toast: 1080;
}

[data-theme='dark'],
.dark-theme {
    --theme-bg-primary: #090D13;
    --theme-bg-secondary: #0D1219;
    --theme-bg-tertiary: #141B24;
    --theme-bg-quaternary: #1C2531;
    --theme-bg-elevated: #171F2A;
    --theme-bg-overlay: rgba(10, 14, 20, 0.78);
    --theme-bg-shallow: #070A10;
    --theme-bg-muted: #161E28;
    --theme-bg-accent: rgba(59, 130, 246, 0.16);

    --theme-border-primary: #2A3442;
    --theme-border-secondary: #1C2531;
    --theme-border-light: #3A4658;

    --theme-text-primary: #E7ECF2;
    --theme-text-secondary: #C5CDD8;
    --theme-text-muted: #97A2AF;
    --theme-text-disabled: #6D7886;
    --theme-text-inverse: #070A10;
}

[data-style-preset='green'],
.theme-preset-green {
    --theme-primary: #16A34A;
    --theme-tag-bg: #16A34A;
    --theme-primary-light: #22C55E;
    --theme-primary-dark: #15803D;
    --theme-border-focus: #16A34A;
    --theme-success: #16A34A;
    --theme-success-light: #22C55E;
    --theme-success-dark: #15803D;
    --theme-info: #4ADE80;
    --theme-info-light: #86EFAC;
    --theme-info-dark: #22C55E;
    --theme-gradient-primary: linear-gradient(135deg, #22C55E, #15803D);
    --theme-gradient-soft: linear-gradient(135deg, rgba(34, 197, 94, 0.12), rgba(16, 185, 129, 0.10));
}

[data-style-preset='green'][data-theme='light'],
.theme-preset-green[data-theme='light'] {
    --theme-bg-overlay: rgba(248, 255, 250, 0.86);
    --theme-bg-accent: rgba(22, 163, 74, 0.08);
}

[data-style-preset='green'][data-theme='dark'],
.theme-preset-green[data-theme='dark'] {
    --theme-bg-overlay: rgba(4, 19, 10, 0.82);
    --theme-bg-accent: rgba(34, 197, 94, 0.16);
}

[data-style-preset='yellow'],
.theme-preset-yellow {
    --theme-primary: #D49A1D;
    --theme-tag-bg: #D49A1D;
    --theme-primary-light: #E9B949;
    --theme-primary-dark: #B47E0F;
    --theme-border-focus: #D49A1D;
    --theme-success: #D49A1D;
    --theme-success-light: #E9B949;
    --theme-success-dark: #B47E0F;
    --theme-info: #E8C35B;
    --theme-info-light: #F2DA8B;
    --theme-info-dark: #C9981A;
    --theme-warning: #E7A72C;
    --theme-warning-light: #F3C45E;
    --theme-warning-dark: #C78212;
    --theme-gradient-primary: linear-gradient(135deg, #F0C85A, #D49A1D);
    --theme-gradient-soft: linear-gradient(135deg, rgba(240,200,90,0.14), rgba(212,154,29,0.10));
}

[data-style-preset='yellow'][data-theme='light'],
.theme-preset-yellow[data-theme='light'] {
    --theme-bg-primary: #FFFBEF;
    --theme-bg-secondary: #FAF4DE;
    --theme-bg-tertiary: #F4EBCB;
    --theme-bg-quaternary: #EBDDAA;
    --theme-bg-elevated: #FFFDF4;
    --theme-bg-overlay: rgba(255, 250, 235, 0.88);
    --theme-bg-shallow: #FFF7D9;
    --theme-bg-muted: #F6EFCF;
    --theme-bg-accent: rgba(212, 154, 29, 0.10);
    --theme-border-primary: #E6D39A;
    --theme-border-secondary: #F0E2B7;
    --theme-border-light: #DDBF6E;
    --theme-text-primary: #2F2410;
    --theme-text-secondary: #5B4824;
    --theme-text-muted: #8A7340;
}

[data-style-preset='ghibli'],
.theme-preset-ghibli {
    --theme-primary: #4C8B5A;
    --theme-tag-bg: #4C8B5A;
    --theme-primary-light: #6AAE78;
    --theme-primary-dark: #3B6E47;
    --theme-border-focus: #4C8B5A;
    --theme-success: #4C8B5A;
    --theme-success-light: #6AAE78;
    --theme-success-dark: #3B6E47;
    --theme-info: #7CAFA4;
    --theme-info-light: #A8D2C8;
    --theme-info-dark: #5E968A;
    --theme-warning: #D8A24E;
    --theme-warning-light: #E6BD72;
    --theme-warning-dark: #B9832F;
    --theme-gradient-primary: linear-gradient(135deg, #78B377, #4C8B5A);
    --theme-gradient-soft: linear-gradient(135deg, rgba(120, 179, 119, 0.14), rgba(124, 175, 164, 0.10));
    --theme-radius-xl: 0.9rem;
    --theme-radius-2xl: 1.15rem;
    --theme-radius-3xl: 1.65rem;
}

[data-style-preset='ghibli'][data-theme='light'],
.theme-preset-ghibli[data-theme='light'] {
    --theme-bg-primary: #F7F4EA;
    --theme-bg-secondary: #F1ECDC;
    --theme-bg-tertiary: #E8E2CF;
    --theme-bg-quaternary: #DDD5C0;
    --theme-bg-elevated: #FBF8EF;
    --theme-bg-overlay: rgba(247, 244, 234, 0.88);
    --theme-bg-shallow: #EEE8D8;
    --theme-bg-muted: #E8E2CF;
    --theme-bg-accent: rgba(76, 139, 90, 0.10);
    --theme-border-primary: #D3C8AF;
    --theme-border-secondary: #E1D8C4;
    --theme-border-light: #EEE7D8;
    --theme-text-primary: #2A2A22;
    --theme-text-secondary: #4B4B3F;
    --theme-text-muted: #777260;
}

[data-style-preset='ghibli'][data-theme='dark'],
.theme-preset-ghibli[data-theme='dark'] {
    --theme-bg-primary: #151B18;
    --theme-bg-secondary: #1B2420;
    --theme-bg-tertiary: #243029;
    --theme-bg-quaternary: #2D3B33;
    --theme-bg-elevated: #314239;
    --theme-bg-overlay: rgba(17, 24, 20, 0.86);
    --theme-bg-shallow: #101613;
    --theme-bg-muted: #2D3B33;
    --theme-bg-accent: rgba(120, 179, 119, 0.18);
    --theme-border-primary: #44554A;
    --theme-border-secondary: #314239;
    --theme-border-light: #56695D;
    --theme-text-primary: #F2F0E6;
    --theme-text-secondary: #D8D6CA;
    --theme-text-muted: #A2AA9D;
}


.pagination {
    display: flex;
    align-items: center;
    gap: var(--theme-spacing-1);
}

.pagination > li {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--theme-font-size-sm);
    font-weight: 600;
    font-family: Arial, sans-serif;
    border: 1px solid var(--theme-border-primary);
    background-color: var(--theme-bg-secondary);
    border-radius: var(--theme-radius-full);
    transition: var(--theme-transition-all);
    cursor: pointer;
    user-select: none;
}

.pagination > li > a {
    color: var(--theme-text-primary);
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    border-radius: inherit;
    transition: var(--theme-transition-all);
}

.pagination > li:hover {
    background-color: var(--theme-bg-tertiary);
    border-color: var(--theme-border-light);
    transform: translateY(-1px);
    box-shadow: var(--theme-shadow-sm);
}

.pagination > li:hover > a {
    color: var(--theme-text-primary);
}

.pagination > .active {
    background: var(--theme-gradient-primary);
    border-color: var(--theme-primary);
    color: var(--theme-text-white);
    box-shadow: var(--theme-shadow-md);
}

.pagination > .active > a {
    color: var(--theme-text-primary);
}

.pagination > .active:hover {
    background: var(--theme-primary-dark);
    transform: translateY(-1px);
    box-shadow: var(--theme-shadow-lg);
}

.pagination > .disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

.pagination > .noBorder {
    border: none;
    background: transparent;
    cursor: default;
}

.pagination > .noBorder:hover {
    background: transparent;
    transform: none;
    box-shadow: none;
}

.pagination > li img {
    display: inline-block;
    width: 20px;
    height: 20px;
    filter: brightness(0) invert(1);
    transition: var(--theme-transition-all);
}

.pagination > li:first-child,
.pagination > li:last-child {
    width: 40px;
}

@media (max-width: 767px) {
    .pagination > li {
        width: 36px;
        height: 36px;
        font-size: var(--theme-font-size-xs);
    }

    .pagination {
        gap: 2px;
    }

    .pagination > li img {
        width: 16px;
        height: 16px;
    }
}

@media (max-width: 480px) {
    .pagination > li {
        width: 32px;
        height: 32px;
        font-size: 0.75rem;
    }

    .pagination > li img {
        width: 14px;
        height: 14px;
    }
}

html.zf-ui-booting .hidden{display:none !important;}
.zf-desktop-nav-boot{
    opacity:1;
    visibility:visible;
    transition:opacity .22s ease, visibility 0s linear 0s;
}
html.zf-ui-booting .zf-desktop-nav-boot{
    opacity:0 !important;
    visibility:hidden !important;
}
html.zf-ui-booting .zf-desktop-nav-boot *{
    transition:none !important;
}
#mainHeader .zf-header-progress{
    position:absolute;
    left:0;
    top:0;
    width:100%;
    height:2px;
    overflow:hidden;
    pointer-events:none;
    opacity:0;
    transition:opacity .16s ease;
    z-index:2;
    background:color-mix(in srgb, var(--theme-border-primary) 45%, transparent);
}
#mainHeader .zf-header-progress::before{
    content:'';
    position:absolute;
    left:0;
    top:0;
    height:100%;
    width:36%;
    background:linear-gradient(90deg, transparent 0%, var(--theme-primary) 55%, transparent 100%);
    transform:translateX(-130%);
    animation:zf-header-top-loading 1s cubic-bezier(.4,0,.2,1) infinite;
}
html.zf-ui-booting #mainHeader .zf-header-progress{
    opacity:1;
}
@keyframes zf-header-top-loading{
    0%{ transform:translateX(-130%); }
    100%{ transform:translateX(380%); }
}
@media (prefers-reduced-motion: reduce){
    .zf-desktop-nav-boot,
    #mainHeader .zf-header-progress{
        transition:none !important;
    }
    #mainHeader .zf-header-progress::before{
        animation:none !important;
    }
}
html.zf-low-motion .zf-desktop-nav-boot,
html.zf-low-motion #mainHeader .zf-header-progress,
html.zf-low-motion .theme-back-to-top{
    transition:none !important;
}
html.zf-low-motion #mainHeader .zf-header-progress::before{
    animation:none !important;
}
html.zf-low-motion .theme-back-to-top{
    transform:none !important;
}
html.zf-theme-switching *,
html.zf-theme-switching *::before,
html.zf-theme-switching *::after{
    transition:none !important;
    animation-duration:0s !important;
    animation-delay:0s !important;
}
.zf-theme-fade-overlay{
    position:fixed;
    inset:0;
    pointer-events:none;
    z-index:10060;
    opacity:1;
    background:var(--theme-bg-secondary, #F9FAFB);
    transition:opacity .24s ease-out;
}
.zf-theme-fade-overlay.zf-theme-fade-overlay-out{
    opacity:0;
}
.footer-backlink-scroll{-webkit-overflow-scrolling:touch;scrollbar-width:none}
.footer-backlink-scroll::-webkit-scrollbar{display:none}
.footer-backlink-track>*{flex:0 0 auto}
.footer-backlink-track a{display:inline-flex;align-items:center}
.footer-backlink-track img{display:block;height:54px;width:auto}
.footer-backlink-scroll.footer-backlink-scroll--static{overflow-x:auto;overflow-y:hidden}
.footer-backlink-scroll.footer-backlink-scroll--static .footer-backlink-track{
    display:flex;
    gap:1rem;
    width:max-content;
    min-width:100%;
    flex-wrap:nowrap;
    transform:none !important;
}
html.zf-low-motion .footer-backlink-scroll{
    scroll-behavior:auto !important;
}
