@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap');

:root {
    /* --- BRAND PALETTE (UXT PRO) --- */
    --accent: #00B3CC;
    --success: #34D399;
    --danger: #EF4444;

    /* Dark Theme (Default) */
    --bg-main: #0E1012;
    --bg-grad-1: color-mix(in oklab, #0057B7 20%, transparent);
    --bg-grad-2: color-mix(in oklab, #FFD700 25%, transparent);
    --panel: #13171A;
    --surface-1: #1A1F23;
    --bg-secondary: var(--surface-1);
    --surface-2: #21262B;

    --text-primary: #f8fafc;
    --text-primary: #f8fafc;
    --text-headings: #f8fafc;
    /* Fallback */
    --text-h1: #f8fafc;
    --text-h2: #f8fafc;
    --text-h3: #f8fafc;
    --text-h4: #f8fafc;
    --text-secondary: #A8B0B6;
    --border: #2A3137;
    --success: #34D399;
    --danger: #EF4444;

    /* Header & Menu */
    --header-bg: #13171A;
    --header-op: 70%;
    --header-blur: 10px;
    --header-padding: 10px;
    --header-inline-padding: 16px;
    --header-inline-padding-mobile: 16px;
    --header-text: #A8B0B6;
    --header-text-hover: #00B3CC;
    --header-offset: 60px;

    --dropdown-bg: #13171A;
    --dropdown-op: 80%;
    --dropdown-blur: 20px;
    --dropdown-radius: 24px;
    --dropdown-gradient: none;

    --lang-bg: #13171A;
    --lang-op: 80%;
    --lang-blur: 15px;
    --lang-radius: 12px;
    --lang-text: #A8B0B6;
    --lang-text-hover: #00B3CC;
    --search-icon: #A8B0B6;
    --sun-icon: #FFD700;
    --moon-icon: #A8B0B6;

    /* Content & FAQ Blocks */
    --content-panel-bg: var(--surface-1);
    --content-panel-op: 15%;
    --content-panel-blur: 24px;
    --content-panel-saturate: 110%;

    /* Tables */
    --table-bg: color-mix(in srgb, #13171A 30%, transparent);
    --table-blur: 20px;
    --table-hover-bg: color-mix(in srgb, #1A1F23 40%, transparent);

    /* Calendar */
    --calendar-bg: color-mix(in srgb, #13171A 80%, transparent);
    --calendar-blur: 16px;

    /* Popups */
    --popup-bg: color-mix(in srgb, #13171A 65%, transparent);
    --popup-blur: 24px;

    --hero-align-title: left;
    --hero-sub-display: none;
    --hero-align-sub: left;
    --hero-crumb-display: none;
    --hero-crumb-justify: flex-start;
    --hero-crumb-order: 0;
    --hero-panel-bg: #1A1F23;
    --hero-panel-op: 10%;
    --hero-panel-blur: 40px;

    /* Glass Effect Tokens */
    --glass-bg: rgba(19, 23, 26, 0.7);
    --glass-border: rgba(255, 255, 255, 0.08);

    /* Layout & Spacing */
    --font-main: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --container-max: 1440px;
    --space-xs: 4px;
    --space-sm: 12px;
    --space-md: 24px;
    --space-lg: 30px;
    --space-xl: 60px;

    /* --- BORDER RADIUS SYSTEM --- */
    --radius-xl: 20px;
    /* Popups, Dropdowns, Large Cards */
    --radius-lg: 16px;
    /* Section Blocks, Standard Cards */
    --radius-md: 12px;
    /* Inputs, Buttons, Inner Blocks */
    --radius-sm: 8px;
    /* Small Tags, Badges, Inner Items */
    --radius-xs: 4px;
    /* Tiny indicators */
    --radius-menu: 12px;
    --radius-input: 8px;

    /* Header Transparent State */
    --header-trans-op: 0%;
    --btn-trans-glass-op: 30%;
    /* Typography Sizes (Base 16px) */
    --fs-h1: 2.5rem;
    /* 48px */
    --fs-h2: 2.5rem;
    /* 40px */
    --fs-h3: 1.5rem;
    /* 24px */
    --fs-h4: 1.25rem;
    /* 20px */
    --fs-body-lg: 1.125rem;
    /* 18px */
    --fs-body: 1rem;
    /* 16px */
    --fs-small: 0.875rem;
    /* 14px */

    --ease: cubic-bezier(0.4, 0, 0.2, 1);
    --transition: 0.3s var(--ease);

    /* Debugger (Set to 1 to see borders) */
    --debug-alignment: 0;
}

/* NUCLEAR ALIGNMENT DEBUGGER */
.container:where([style*="--debug-alignment: 1"]),
body:has(.debug-on) .container {
    outline: 2px solid rgba(255, 0, 0, 0.3) !important;
    position: relative;
}

.container::after:where([style*="--debug-alignment: 1"]),
body:has(.debug-on) .container::after {
    content: "CONTAINER";
    position: absolute;
    top: 0;
    left: 0;
    background: red;
    color: white;
    font-size: 10px;
    padding: 2px 5px;
    z-index: 9999;
}

/* Light Theme overrides */
body.light-theme {
    --bg-main: #F7FAFB;
    --bg-grad-1: color-mix(in oklab, var(--accent) 30%, transparent);
    --bg-grad-2: color-mix(in oklab, #F5A623 25%, transparent);
    --panel: #FFFFFF;

    /* Content Blocks Light */
    --content-panel-bg: var(--surface-1);
    --content-panel-op: 15%;
    --content-panel-blur: 24px;
    --content-panel-saturate: 110%;
    --hero-panel-bg: #F1F5F9;
    --hero-panel-op: 10%;
    --hero-panel-blur: 40px;
    --surface-1: #F1F5F9;
    --surface-2: #E2E8F0;
    --text-primary: #0F172A;
    --text-headings: #0F172A;
    --text-h1: #0F172A;
    --text-h2: #0F172A;
    --text-h3: #0F172A;
    --text-h4: #0F172A;
    --text-secondary: #475569;
    --border: #CBD5E1;
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(0, 0, 0, 0.08);

    --header-bg: #FFFFFF;
    --header-op: 70%;
    --header-blur: 10px;
    --header-offset: 60px;
    --header-text: #475569;
    --header-text-hover: #00B3CC;

    --dropdown-bg: #FFFFFF;
    --dropdown-op: 80%;
    --dropdown-blur: 20px;
    --dropdown-radius: 24px;

    --lang-bg: #FFFFFF;
    --lang-op: 80%;
    --lang-blur: 15px;
    --lang-radius: 12px;
    --lang-text: #475569;
    --lang-text-hover: #00B3CC;

    --search-icon: #475569;
    --sun-icon: #F59E0B;
    --moon-icon: #64748B;

    --table-bg: color-mix(in srgb, #FFFFFF 80%, transparent);
    --table-hover-bg: color-mix(in srgb, #F1F5F9 50%, transparent);
    --calendar-bg: color-mix(in srgb, #FFFFFF 80%, transparent);
    --popup-bg: color-mix(in srgb, #FFFFFF 75%, transparent);
}

/* Base resets */
.container {
    max-width: var(--container-max);
    width: 100%;
    margin-left: auto;
    margin-right: auto;
    padding-left: var(--header-inline-padding);
    padding-right: var(--header-inline-padding);
    box-sizing: border-box;
}

@media (max-width: 768px) {
    .container {
        padding-left: var(--header-inline-padding-mobile, 16px);
        padding-right: var(--header-inline-padding-mobile, 16px);
    }
    :root {
        --fs-h1: 1.875rem; /* ~30px */
        --fs-h2: 1.625rem; /* ~26px */
        --fs-h3: 1.375rem; /* ~22px */
    }
}

html {
    overflow-x: visible !important;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: var(--bg-main);
}

::-webkit-scrollbar-thumb {
    background: rgba(168, 176, 182, 0.45);
    /* Slightly more visible */
    border-radius: 10px;
    border: 3px solid var(--bg-main);
    /* Wider border for more "floating" look */
    transition: all 0.3s ease;
}

/* Light up when hovering ANYWHERE on the scrollbar track */
::-webkit-scrollbar:hover ::-webkit-scrollbar-thumb {
    background: rgba(168, 176, 182, 0.7);
}

body.light-theme ::-webkit-scrollbar-thumb {
    background: rgba(15, 23, 42, 0.25);
}

body.light-theme ::-webkit-scrollbar:hover ::-webkit-scrollbar-thumb {
    background: rgba(15, 23, 42, 0.4);
}

/* Intensive glow when hovering directly on the handle */
::-webkit-scrollbar-thumb:hover {
    background: var(--accent) !important;
    border-width: 2px;
    /* Thicken the handle on direct hover */
}

body {
    margin: 0;
    padding-top: var(--header-offset, 80px);
    font-family: var(--font-main);
    background-color: var(--bg-main);
    background-image:
        radial-gradient(at 80% 10%, var(--bg-grad-1) 0px, transparent 50%),
        radial-gradient(at 10% 90%, var(--bg-grad-2) 0px, transparent 50%) !important;
    background-repeat: no-repeat !important;
    background-size: 100vw 100vh !important;
    background-attachment: fixed !important;
    color: var(--text-primary);
    -webkit-font-smoothing: antialiased;
    letter-spacing: -0.011em;
    min-height: 100vh;
    overflow-x: visible !important;
    position: relative;
}

/* Корекція для адмін-панелі WordPress */
.admin-bar body {
    padding-top: calc(var(--header-offset, 80px) + 32px);
}

@media screen and (max-width: 782px) {
    .admin-bar body {
        padding-top: calc(var(--header-offset, 80px) + 46px);
    }
}

.theme-dark {
    background-color: var(--bg-main);
    color: var(--text-primary);
}

/* Typography Headings */
h1 {
    font-size: var(--fs-h1);
}

h2 {
    font-size: var(--fs-h2);
}

h3 {
    font-size: var(--fs-h3);
}

h4 {
    font-size: var(--fs-h4);
}

h1,
h2,
h3,
h4 {
    font-weight: 700;
    line-height: 1.1;
    margin: 0;
    letter-spacing: -0.02em;
}

h1 {
    color: var(--text-h1);
}

h2 {
    color: var(--text-h2);
}

h3 {
    color: var(--text-h3);
}

h4 {
    color: var(--text-h4);
}

.text-gradient {
    background: linear-gradient(135deg, var(--accent) 0%, #00e5ff 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* UI KIT UTILITIES */
.uikit-h1 {
    font-size: var(--fs-h1);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.04em;
    color: var(--text-headings);
}

.uikit-h2 {
    font-size: var(--fs-h2);
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.03em;
    color: var(--text-headings);
}

.uikit-h3 {
    font-size: var(--fs-h3);
    font-weight: 700;
    line-height: 1.3;
    letter-spacing: -0.02em;
    color: var(--text-headings);
}

.uikit-h4 {
    font-size: var(--fs-h4);
    font-weight: 700;
    line-height: 1.4;
    letter-spacing: -0.01em;
    color: var(--text-headings);
}

.uikit-text-sec {
    color: var(--text-secondary);
    font-size: var(--fs-body);
    opacity: 0.9;
}

.uikit-text-small {
    color: var(--text-secondary);
    font-size: var(--fs-small);
}

/* Glass Components */
.glass {
    background: var(--glass-bg);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    border: none;
    border-radius: var(--radius-lg);
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

.glass:hover {
    box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.5);
}

body.light-theme .glass {
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.1);
}

body.light-theme .glass:hover {
    box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.15);
}

.card-premium {
    border: none;
    transition: all 0.4s var(--ease);
    overflow: hidden;
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.2);
}

.card-premium:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.4);
}

/* Global Fallbacks & Placeholders */
.uxt-fallback-bg {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s var(--ease);
    display: block;
}

.uxt-text-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--bg-secondary), var(--surface-1));
    display: flex !important;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 4px;
    opacity: 0.2;
    font-size: 2rem;
    color: var(--accent);
    user-select: none;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 28px;
    border-radius: var(--radius-md);
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.4s var(--ease);
    border: none;
    font-family: var(--font-main);
    text-decoration: none;
    letter-spacing: -0.01em;
    position: relative;
    line-height: normal;
}

.btn-primary {
    background: var(--accent);
    color: #fff;
    box-shadow: 0 4px 15px rgba(0, 179, 204, 0.2);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 25px rgba(0, 179, 204, 0.4);
}

.btn-primary:active {
    transform: translateY(-1px) scale(0.98);
}

.btn-secondary {
    background: transparent;
    color: var(--text-secondary);
    box-shadow: inset 0 0 0 1px var(--accent);
}

.btn-secondary:hover {
    background: rgba(0, 179, 204, 0.05);
    color: var(--accent);
    box-shadow: inset 0 0 0 1px var(--accent), 0 0 20px rgba(0, 179, 204, 0.2);
}

.btn-glass {
    background: rgba(255, 255, 255, 0.05);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border: none;
    color: var(--text-primary);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.btn-glass:hover {
    background: rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
    transform: translateY(-2px);
}

.btn-icon-glass {
    background-color: color-mix(in oklab, var(--surface-1) 30%, transparent);
    background-image: linear-gradient(135deg, color-mix(in oklab, var(--bg-grad-2) 15%, transparent), color-mix(in oklab, var(--bg-grad-1) 15%, transparent));
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border: none;
    color: var(--text-primary);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.btn-icon-glass:hover {
    box-shadow: 0 8px 25px color-mix(in oklab, var(--accent) 30%, transparent);
    transform: translateY(-3px);
    background-image: linear-gradient(135deg, color-mix(in oklab, var(--bg-grad-2) 25%, transparent), color-mix(in oklab, var(--bg-grad-1) 25%, transparent));
}

.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
}

.btn-ghost:hover {
    background: var(--surface-2);
    color: var(--text-primary);
}

.btn-danger {
    background: var(--danger);
    color: #fff;
}

.btn-danger:hover {
    box-shadow: 0 10px 25px rgba(239, 68, 68, 0.4);
    transform: translateY(-2px);
}

.btn-secondary-danger {
    background: transparent;
    color: var(--text-secondary);
    box-shadow: inset 0 0 0 1px var(--danger);
}

.btn-secondary-danger:hover {
    background: rgba(239, 68, 68, 0.05);
    color: var(--danger);
    box-shadow: inset 0 0 0 1px var(--danger), 0 5px 15px rgba(239, 68, 68, 0.2);
    transform: translateY(-2px);
}

.btn-icon {
    padding: 0;
    width: 44px;
    height: 44px;
    min-width: 44px;
    border-radius: 50%;
}

.btn-icon svg {
    width: 20px;
    height: 20px;
    stroke-width: 2.5;
}

/* Loading State */
.btn-loader {
    width: 18px;
    height: 18px;
    border: 2px solid currentColor;
    border-bottom-color: transparent;
    border-radius: 50%;
    display: none;
    animation: btn-rotate 1s linear infinite;
}

.btn.loading {
    pointer-events: none;
    color: transparent !important;
}

.btn.loading .btn-loader {
    display: block;
    position: absolute;
    left: 50%;
    top: 50%;
    margin-left: -9px;
    margin-top: -9px;
    color: #fff;
}

@keyframes btn-rotate {
    to {
        transform: rotate(360deg);
    }
}

/* Tooltips */
.tooltip-wrapper {
    position: relative;
    display: inline-block;
}

.tooltip {
    position: absolute;
    bottom: calc(100% + 12px);
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    background: var(--panel);
    color: var(--text-primary);
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 0.8rem;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s var(--ease);
    border: 1px solid var(--border);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
    z-index: 100;
}

.tooltip-wrapper:hover .tooltip {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

/* Link Style */
.btn-link {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: var(--accent);
    font-weight: 700;
    font-size: 0.95rem;
    text-decoration: none;
    transition: all 0.3s var(--ease);
}

.btn-link:hover {
    color: #fff;
}

.light-theme .btn-link:hover {
    color: var(--text-primary);
}

.btn-link svg {
    width: 20px;
    height: 20px;
    stroke-width: 2.5;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.btn-link:hover svg {
    transform: translateX(10px);
}

/* --- CHOICE ELEMENTS (CHECKBOX, RADIO, TOGGLES) --- */
.choice-wrapper {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
    color: var(--text-primary);
    font-weight: 500;
}

.choice-wrapper input {
    display: none;
}

.choice-visual {
    width: 22px;
    height: 22px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.5s var(--ease);
    flex-shrink: 0;
    background-color: color-mix(in oklab, var(--surface-1) 30%, transparent);
    background-image: linear-gradient(135deg, color-mix(in oklab, var(--bg-grad-2) 15%, transparent), color-mix(in oklab, var(--bg-grad-1) 15%, transparent));
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    border: none;
}

.choice-wrapper:hover .choice-visual {
    box-shadow: 0 0 15px 2px color-mix(in oklab, var(--accent) 40%, transparent);
}

/* Checkbox styles */
.checkbox-visual {
    border-radius: 6px;
}

.checkbox-visual svg {
    width: 16px;
    height: 16px;
    opacity: 0;
    transform: scale(0.5);
    transition: all 0.3s var(--ease);
    stroke-width: 3.5;
}

.choice-wrapper input:checked+.checkbox-visual {
    background-color: transparent;
    box-shadow: 0 0 15px 2px color-mix(in oklab, var(--accent) 40%, transparent);
}

.choice-wrapper input:checked+.checkbox-visual svg {
    color: var(--accent);
    opacity: 1;
    transform: scale(1);
}

/* Radio styles */
.radio-visual {
    border-radius: 50%;
}

.radio-visual .inner-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: var(--accent);
    opacity: 0;
    transform: scale(0.5);
    transition: all 0.3s var(--ease);
}

.choice-wrapper input:checked+.radio-visual {
    background-color: transparent;
    box-shadow: 0 0 15px 2px color-mix(in oklab, var(--accent) 40%, transparent);
}

.choice-wrapper input:checked+.radio-visual .inner-dot {
    opacity: 1;
    transform: scale(1);
}

/* Simple Toggle switch */
.toggle-switch-simple {
    --w: 52px;
    --h: 28px;
    position: relative;
    width: var(--w);
    height: var(--h);
    border-radius: 999px;
    cursor: pointer;
    background-color: color-mix(in oklab, var(--surface-2) 30%, transparent);
    background-image: linear-gradient(135deg, color-mix(in oklab, var(--bg-grad-2) 15%, transparent), color-mix(in oklab, var(--bg-grad-1) 15%, transparent));
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
    transition: all 0.3s var(--ease);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.toggle-switch-simple:hover {
    box-shadow: 0 0 15px 2px color-mix(in oklab, var(--accent) 40%, transparent);
}

.toggle-switch-simple input {
    display: none;
}

.toggle-switch-simple .knob {
    position: absolute;
    top: 3px;
    left: 3px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background-color: var(--text-secondary);
    transition: all 0.4s var(--ease);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.toggle-switch-simple input:checked+.knob {
    transform: translateX(calc(var(--w) - 22px - 6px));
    background-color: var(--accent);
    box-shadow: 0 0 15px color-mix(in oklab, var(--accent) 40%, transparent);
}

/* Premium Theme Switch (with icons) */
.theme-switch-final {
    --w: 56px;
    --h: 30px;
    position: relative;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: var(--w) !important;
    height: var(--h) !important;
    line-height: var(--h) !important;
    border-radius: var(--h);
    cursor: pointer;
    border: none !important;
    background-color: color-mix(in oklab, var(--surface-2) 30%, transparent);
    background-image: linear-gradient(135deg, color-mix(in oklab, var(--bg-grad-2) 15%, transparent), color-mix(in oklab, var(--bg-grad-1) 15%, transparent));
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
    transition: all 0.5s var(--ease);
    padding: 0 !important;
    margin: 0 !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1), var(--header-edge-shadow-bottom, 0 0 0 transparent), var(--header-edge-shadow-top, 0 0 0 transparent);
    outline: none;
    -webkit-tap-highlight-color: transparent;
    box-sizing: border-box !important;
}

.theme-switch-final:hover,
.theme-switch-final:focus,
.theme-switch-final:active {
    outline: none;
}

.theme-switch-final .knob-final {
    position: absolute;
    top: 3px;
    left: 3px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background-color: color-mix(in oklab, var(--surface-1) 30%, transparent);
    background-image: linear-gradient(135deg, color-mix(in oklab, var(--bg-grad-2) 15%, transparent), color-mix(in oklab, var(--bg-grad-1) 15%, transparent));
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
    transition: transform 0.4s var(--ease), background-color 0.3s var(--ease), box-shadow 0.3s var(--ease);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    border: none;
}

.theme-switch-final:hover .knob-final {
    background-color: color-mix(in oklab, var(--surface-1) 50%, transparent);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3), 0 0 10px 2px color-mix(in oklab, var(--accent) 25%, transparent);
}

.theme-switch-final.toggled .knob-final,
.theme-switch-branded.toggled .knob-final {
    transform: translateX(26px) !important;
}

.theme-switch-final .knob-final svg {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 14px;
    height: 14px;
    transition: all 0.4s var(--ease);
    color: var(--accent);
    background: transparent;
    margin: 0 !important;
}

.theme-switch-branded .knob-final svg {
    width: 16px;
    height: 16px;
}

.theme-switch-final .knob-final .icon-sun {
    opacity: 0;
    visibility: hidden;
    transform: translate(-50%, -50%) rotate(-90deg) scale(0.5);
    color: var(--sun-icon, var(--accent));
}

.theme-switch-final.toggled .knob-final .icon-sun {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, -50%) rotate(0deg) scale(1);
}

.theme-switch-final .knob-final .icon-moon {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, -50%) rotate(0deg) scale(1);
    color: var(--moon-icon, var(--accent));
}

.theme-switch-final.toggled .knob-final .icon-moon {
    opacity: 0;
    visibility: hidden;
    transform: translate(-50%, -50%) rotate(90deg) scale(0.5);
}

/* --- INPUT STYLES --- */
.input-wrapper {
    position: relative;
    width: 100%;
}

.input-base {
    width: 100%;
    padding: 12px 16px;
    background-color: transparent;
    color: var(--text-primary) !important;
    border: none;
    border-radius: var(--radius-input);
    font-size: 1rem;
    font-family: var(--font-main);
    transition: all 0.3s var(--ease);
    line-height: normal;
    box-sizing: border-box;
    outline: none;
    position: relative;
    z-index: 2;
}

.input-base::placeholder {
    color: var(--text-secondary);
    opacity: 0.8 !important;
    /* Збільшено видимість */
}

.input-glass {
    background-color: color-mix(in oklab, var(--surface-1) 30%, transparent);
    background-image: linear-gradient(135deg, color-mix(in oklab, var(--bg-grad-2) 15%, transparent), color-mix(in oklab, var(--bg-grad-1) 15%, transparent));
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.input-glass:hover {
    box-shadow: 0 0 20px 2px color-mix(in oklab, var(--accent) 30%, transparent);
}

.input-glass:focus {
    box-shadow: 0 0 25px 5px color-mix(in oklab, var(--accent) 40%, transparent);
    background-color: color-mix(in oklab, var(--surface-1) 50%, transparent);
}

.input-underline {
    border-radius: 0;
    border-bottom: 2px solid var(--border);
    padding-left: 4px;
    padding-right: 4px;
}

.input-underline:hover {
    border-bottom-color: color-mix(in oklab, var(--accent) 50%, var(--border));
}

.input-underline:focus {
    border-bottom-color: var(--accent);
    box-shadow: 0 10px 15px -10px color-mix(in oklab, var(--accent) 30%, transparent);
}

.input-filled {
    background-color: var(--surface-2);
}

.input-filled:focus {
    background-color: var(--surface-1);
    box-shadow: inset 0 0 0 1px var(--accent);
}

/* Floating Labels */
.floating-label-wrapper {
    position: relative;
}

.floating-label {
    position: absolute;
    top: 50%;
    left: 16px;
    transform: translateY(-50%);
    color: var(--text-secondary);
    pointer-events: none;
    transition: all 0.3s var(--ease);
    font-size: 1rem;
    opacity: 0.8;
    z-index: 5;
}

/* Align label to top for textareas */
.floating-label-wrapper textarea.input-base+.floating-label {
    top: 14px;
    transform: none;
}

.floating-label-wrapper .input-base:focus+.floating-label,
.floating-label-wrapper .input-base:not(:placeholder-shown)+.floating-label {
    top: -12px;
    /* Піднято вище, щоб не заважати тексту */
    left: 12px;
    font-size: 0.75rem;
    color: var(--accent);
    transform: translateY(0);
    background: var(--bg-main);
    padding: 0 8px;
    z-index: 10;
    border-radius: 4px;
    opacity: 1;
}

/* Specific for Glass inputs in floating wrapper */
.floating-label-wrapper .input-glass:focus+.floating-label,
.floating-label-wrapper .input-glass:not(:placeholder-shown)+.floating-label {
    background-color: color-mix(in oklab, var(--surface-1) 80%, transparent);
    background-image: linear-gradient(135deg, color-mix(in oklab, var(--bg-grad-2) 15%, transparent), color-mix(in oklab, var(--bg-grad-1) 15%, transparent));
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
    color: var(--text-primary);
}

/* Icon Support */
.input-with-icon {
    padding-left: 48px;
}

.input-icon {
    position: absolute;
    top: 50%;
    left: 16px;
    transform: translateY(-50%);
    color: var(--text-secondary);
    width: 20px;
    height: 20px;
    pointer-events: none;
    transition: color 0.3s var(--ease);
    z-index: 10;
}

.input-wrapper:focus-within .input-icon {
    color: var(--accent);
}

/* Error States */
.has-error .input-base {
    box-shadow: 0 0 0 1px var(--danger) !important;
}

.has-error .input-glass {
    box-shadow: 0 0 20px rgba(239, 68, 68, 0.2), 0 0 0 1px var(--danger) !important;
}

.has-error .input-underline {
    border-bottom-color: var(--danger) !important;
    box-shadow: none !important;
}

.error-message {
    color: var(--danger);
    font-size: 0.8rem;
    margin-top: 6px;
    padding-left: 4px;
    font-weight: 500;
}

.has-error .floating-label {
    color: var(--danger) !important;
}

/* Custom Select Mirror Styles (Scoped to UI Kit) */
.wm-select-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 16px;
    background-color: color-mix(in oklab, var(--surface-1) 30%, transparent);
    background-image: linear-gradient(135deg, color-mix(in oklab, var(--bg-grad-2) 15%, transparent), color-mix(in oklab, var(--bg-grad-1) 15%, transparent));
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    color: var(--text-primary);
    border-radius: var(--radius-input);
    border: none;
    cursor: pointer;
    transition: all 0.3s var(--ease);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    font-family: inherit;
    font-weight: 500;
    font-size: 1rem;
}

.wm-select-label {
    color: var(--text-secondary);
    opacity: 0.6;
    transition: all 0.3s var(--ease);
}

.wm-select-btn.selected .wm-select-label {
    color: var(--text-primary);
    opacity: 1;
}

.wm-select-btn:hover {
    box-shadow: 0 0 20px 2px color-mix(in oklab, var(--accent) 30%, transparent);
}

.wm-select-btn svg {
    width: 18px;
    height: 18px;
    transition: transform 0.3s var(--ease);
    color: var(--text-secondary);
}

.wm-select-btn[aria-expanded="true"] svg {
    transform: rotate(180deg);
    color: var(--accent);
}

.dropdown {
    position: relative;
    width: 100%;
}

.dd-menu {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    /* Opaque Input Gradient Style */
    background-color: var(--surface-1);
    background-image: linear-gradient(135deg, color-mix(in oklab, var(--bg-grad-2) 15%, transparent), color-mix(in oklab, var(--bg-grad-1) 15%, transparent));
    /* No backdrop filter for opaque */
    border: 1px solid var(--border);
    border-radius: var(--dropdown-radius);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
    z-index: 200;
    padding: 12px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s var(--ease);
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.dd-menu.open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dd-item {
    width: 100%;
    padding: 14px 20px;
    border-radius: 12px;
    cursor: pointer;
    color: var(--text-primary);
    transition: all 0.2s ease;
    border: none;
    background: transparent;
    text-align: left;
    font-weight: 500;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

body.light-theme .dd-item {
    color: var(--text-h4);
}



.dd-item:hover {
    background: transparent;
    color: var(--accent);
}

.dd-item.selected {
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
    font-weight: 700;
}

body.light-theme .dd-item.selected {
    background: color-mix(in oklab, var(--accent) 10%, transparent);
    color: var(--accent);
}

/* ======================================================= */
/* HEADER STYLES (UXT PRO EXCLUSIVE) */
/* ======================================================= */

.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    z-index: 99999;
}

.header-inner {
    display: flex;
    align-items: center;
    gap: 12px;
    padding-block: var(--header-padding);
    max-width: var(--container-max);
    margin: 0 auto;
    padding-inline: var(--header-inline-padding, 16px);
    width: 100%;
    position: relative;
    box-sizing: border-box;
}

@media (max-width: 1024px) {
    .header-inner {
        padding-inline: var(--header-inline-padding-mobile, 16px) !important;
    }
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    text-decoration: none;
    color: var(--text-primary);
}

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

.grow {
    flex: 1;
}

.header-controls {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* Header Buttons */
.header-btn,
.lang-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    user-select: none;
    color: var(--text-secondary);
    height: 30px;
    padding: 0 12px;
    border: none;
    background: transparent;
    cursor: pointer;
    border-radius: 999px;
    transition: all .3s var(--ease);
    box-shadow: none;
    text-decoration: none;
    font-size: 1rem;
    /* Consistent font size */
    font-weight: 500;
    font-family: var(--font-main);
    box-shadow: var(--header-edge-shadow-bottom), var(--header-edge-shadow-top);
}

body.light-theme .header-btn,
body.light-theme .lang-btn {
    color: var(--text-h4);
}

.header-btn:hover,
.lang-btn:hover,
#demo-header-lang-btn:hover {
    color: var(--accent);
    background: transparent !important;
    box-shadow: none !important;
}

/* Dropdowns in Header */
.dropdown {
    position: relative;
}

/* Header Menu Styling - Base dropdown behavior */
.dropdown .menu,
.dropdown .sub-menu {
    pointer-events: none;
    transition: all .3s var(--ease);
}

.dropdown:hover .menu,
.dropdown.open .menu,
.dropdown:hover .sub-menu,
.dropdown.open .sub-menu {
    pointer-events: all;
}

#multiLevelMenu:hover .menu,
#multiLevelMenu.open .menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.menu-item {
    list-style: none;
}

.menu-item>a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    color: var(--text-secondary);
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.2s ease;
    font-weight: 500;
    font-size: 1rem;
}

.menu-item>a:hover {
    background: var(--surface-1);
    color: var(--accent);
}

.menu-item.current-menu-item>a {
    color: var(--accent);
    background: color-mix(in oklab, var(--accent) 10%, transparent);
    font-weight: 700;
}

/* Search Bar Row (Styles moved to header.css for better integration) */

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

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

/* Search Bar Row (Styles handled in header.css) */
/*
.search-input-container {
    padding-block: 10px;
    justify-content: center;
}

.search-input-wrapper {
    max-width: 600px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    width: 100%;
}
*/






































































































/* --- CONTENT BLOCKS (SEO & FAQ) --- */

/* SEO & FAQ PANELS */
.seo-panel {
    background: var(--glass-bg) !important;
    border-radius: var(--radius-xl);
    padding: 60px;
    -webkit-backdrop-filter: blur(var(--content-panel-blur)) saturate(var(--content-panel-saturate)) !important;
    backdrop-filter: blur(var(--content-panel-blur)) saturate(var(--content-panel-saturate)) !important;
    box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.15);
    max-width: var(--container-max);
    margin: 60px auto;
    border: none !important;
}

.faq-panel {
    background: var(--glass-bg) !important;
    border-radius: var(--radius-xl);
    padding: 60px;
    -webkit-backdrop-filter: blur(var(--content-panel-blur)) saturate(var(--content-panel-saturate)) !important;
    backdrop-filter: blur(var(--content-panel-blur)) saturate(var(--content-panel-saturate)) !important;
    box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.15);
    max-width: var(--container-max);
    margin: 60px auto;
    border: none !important;
}

@media (max-width: 768px) {

    .seo-panel,
    .faq-panel {
        padding: 40px 20px;
        margin: 30px 0;
        border-radius: var(--radius-lg);
    }
}

.seo-section-title,
.faq-section-title {
    font-size: var(--fs-h2);
    font-weight: 700;
    text-align: left;
    margin-top: 0;
    margin-bottom: 40px;
    color: var(--text-headings, var(--text-primary));
}

.no-reveal {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
}

/* SEO Content */
.seo-block h3,
.seo-block h4 {
    font-size: 1.25rem;
    color: var(--text-primary);
    margin-top: 24px;
    margin-bottom: 12px;
    font-weight: 700;
}

.seo-block p {
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 1em;
}

.seo-block ul {
    color: var(--text-secondary);
    padding-left: 20px;
    line-height: 1.7;
}

/* Custom Scrollbar for SEO */
.thin-track-scrollbar::-webkit-scrollbar {
    width: 6px;
}

.thin-track-scrollbar::-webkit-scrollbar-track {
    background: transparent;
}

.thin-track-scrollbar::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 10px;
}

.smooth-fade-scroll {
    mask-image: linear-gradient(to bottom, transparent, black 30px, black calc(100% - 30px), transparent);
    -webkit-mask-image: linear-gradient(to bottom, transparent, black 30px, black calc(100% - 30px), transparent);
    padding: 20px 0;
}



/* FAQ Accordion Item Styling */
.faq-accordion-item {
    position: relative;
    transition: all 0.4s var(--ease);
    margin-bottom: 0;
}

/* Vertical Accent Line (Short & Delicate) */
.faq-accordion-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 2px;
    height: 0;
    background: var(--accent);
    border-radius: 4px;
    transition: height 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 5;
}

.faq-accordion-item.active::before {
    height: calc(100% - 32px);
    /* Nearly full height with top/bottom padding */
}

.faq-accordion-header {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    text-align: left;
    padding: 24px 24px;
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    background: transparent;
    border: none;
    box-shadow: none;
    cursor: pointer;
    position: relative;
    transition: color 0.3s var(--ease);
}

/* Static gray track (always visible) */
.faq-accordion-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 24px;
    right: 24px;
    height: 1px;
    background: var(--border);
    opacity: 0.3;
    transition: opacity 0.3s var(--ease);
}

body.light-theme .faq-accordion-header::after {
    opacity: 0.25;
    background: rgba(0, 0, 0, 0.2);
}

/* Premium filling line (expands from center on hover) */
.faq-accordion-header::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 1px;
    background-color: var(--accent);
    box-shadow: 0 0 10px var(--accent);
    transition: width 0.4s var(--ease);
    z-index: 2;
}

.faq-accordion-header:hover,
.faq-accordion-item.active .faq-accordion-header {
    color: var(--accent);
}

/* On hover: the blue line fills the track */
.faq-accordion-header:hover::before {
    width: calc(100% - 48px);
}


/* Icon */
.faq-accordion-item .icon {
    position: relative;
    width: 24px;
    height: 24px;
    color: var(--text-secondary);
    transition: color .3s var(--ease);
    flex-shrink: 0;
}

.faq-accordion-item.active .icon,
.faq-accordion-header:hover .icon {
    color: var(--accent);
}

.faq-accordion-item .icon span {
    display: block;
    position: absolute;
    top: 50%;
    left: 50%;
    width: 14px;
    height: 2px;
    background-color: currentColor;
    transform: translate(-50%, -50%);
    transition: transform 0.4s var(--ease), opacity 0.4s var(--ease);
    border-radius: 2px;
}

.faq-accordion-item .icon span:last-child {
    transform: translate(-50%, -50%) rotate(90deg);
}

.faq-accordion-item.active .icon span:last-child {
    transform: translate(-50%, -50%) rotate(180deg);
    opacity: 0;
}

/* Content */
.faq-accordion-content {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.6s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.5s ease 0.05s, visibility 0s linear 0.6s;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
}

.faq-accordion-item.active .faq-accordion-content {
    grid-template-rows: 1fr;
    opacity: 1;
    visibility: visible;
    transition: grid-template-rows 0.6s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.5s ease 0.1s, visibility 0s linear 0s;
}

.faq-accordion-content-inner {
    min-height: 0;
    padding: 0 24px 32px 24px;
    color: var(--text-secondary);
    line-height: 1.7;
}

/* --- PAGE HEADER (GLASS) --- */
/* --- PAGE HEADER (GLASS) --- */
.page-header-glass {
    background: color-mix(in oklab, var(--hero-panel-bg) var(--hero-panel-op), transparent);
    -webkit-backdrop-filter: blur(var(--hero-panel-blur));
    backdrop-filter: blur(var(--hero-panel-blur));
    border-radius: var(--radius-xl);
    padding: 60px 40px;
    margin: 0 auto 60px auto;
    max-width: var(--container-max);
    display: flex;
    flex-direction: column;
    gap: 20px;
    box-shadow: 0 30px 60px -15px rgba(0, 0, 0, 0.2);
    min-width: 0;
    /* Prevents container from breaking parent width */
}

.page-header-glass h1 {
    margin: 0;
    line-height: 1.1;
    text-align: var(--hero-align-title);
    font-size: var(--fs-h1);
    color: var(--text-h1);
}

.page-header-glass .subtitle {
    display: var(--hero-sub-display);
    text-align: var(--hero-align-sub);
    color: var(--text-secondary);
    font-size: var(--fs-body-lg);
    max-width: 100%;
    margin: 0;
}

.page-header-glass .breadcrumbs-wrapper {
    display: var(--hero-crumb-display, flex);
    justify-content: var(--hero-crumb-justify, flex-start);
    width: 100%;
    max-width: 100%;
    order: var(--hero-crumb-order, 0);
    overflow: hidden;
    position: relative;
    mask-image: linear-gradient(to right, black 90%, transparent 100%);
    -webkit-mask-image: linear-gradient(to right, black 90%, transparent 100%);
    /* DEBUG */
    /* border: 1px solid red; */
    /* Ensure children can receive pointer events */
    pointer-events: auto;
}

/* Modifiers for UI Kit & Templates */
.page-header-glass.hero-left {
    align-items: flex-start;
    text-align: left;
}

.page-header-glass.hero-center {
    align-items: center;
    text-align: center;
}

.page-header-glass.hero-center .breadcrumb-list {
    justify-content: center;
}

.page-header-glass.hero-crumbs-top .breadcrumbs-wrapper {
    order: -1;
    margin-bottom: 20px;
    margin-top: 0;
}

.page-header-glass.hero-crumbs-bottom .breadcrumbs-wrapper {
    order: 1;
    margin-top: 20px;
}

.page-header-glass.hero-center.hero-crumbs-left-top .breadcrumbs-wrapper {
    order: -1;
    margin-bottom: 20px;
    margin-top: 0;
}

.page-header-glass.hero-center.hero-crumbs-left-top .breadcrumb-list {
    justify-content: flex-start;
}

/* Breadcrumbs Styles */
.breadcrumb-list {
    display: flex;
    flex-wrap: nowrap;
    gap: 8px;
    list-style: none;
    padding: 0;
    margin: 0;
    overflow-x: auto;
    /* IMPORTANT: Flex items need min-width: 0 to shrink below content size if needed, though we want scroll */
    min-width: 0;
    max-width: 100%;
    scrollbar-width: none;
    -ms-overflow-style: none;
    -webkit-overflow-scrolling: touch;
    cursor: grab;
    -webkit-user-select: none;
    user-select: none;
    touch-action: pan-x;
    /* Explicitly allow horizontal scroll */
}

.breadcrumb-list:active,
.breadcrumb-list.grabbing {
    cursor: grabbing;
}

.breadcrumb-list::-webkit-scrollbar {
    display: none;
}

.breadcrumb-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    color: var(--text-secondary);
    white-space: nowrap;
    flex-shrink: 0;
}

.breadcrumb-link {
    text-decoration: none;
    color: var(--text-secondary);
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 6px;
    opacity: 0.8;
}

.breadcrumb-link:hover {
    color: var(--accent);
    opacity: 1;
}

.breadcrumb-separator {
    opacity: 0.3;
}

.breadcrumb-current {
    opacity: 0.5;
}

.breadcrumb-home-icon {
    width: 16px;
    height: 16px;
    stroke-width: 2px;
}

/* Horizontal scroll for breadcrumbs on mobile */
/* Horizontal scroll enhancement for mobile (already global now, just adjusting mask) */
@media (max-width: 768px) {
    .breadcrumbs-wrapper {
        mask-image: linear-gradient(to right, black 80%, transparent 100%);
        -webkit-mask-image: linear-gradient(to right, black 80%, transparent 100%);
    }

    .breadcrumb-list {
        gap: 12px;
        padding-bottom: 15px;
        margin-bottom: -15px;
    }
}

/* ============================================
   UTILITY CLASSES - UI Kit Components
   ============================================ */

/* --- PAGINATION (GLASS PREMIUM) --- */
.uxt-pagination {
    margin-top: 50px;
    display: flex;
    justify-content: center;
}

.uxt-pagination .nav-links {
    display: flex;
    gap: 12px;
    align-items: center;
}

.uxt-pagination .page-numbers {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 46px;
    height: 46px;
    padding: 0 10px;
    background-color: color-mix(in oklab, var(--surface-1) 30%, transparent);
    background-image: linear-gradient(135deg, color-mix(in oklab, var(--bg-grad-2) 15%, transparent), color-mix(in oklab, var(--bg-grad-1) 15%, transparent));
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 700;
    font-size: 0.95rem;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
    box-shadow:
        0 4px 12px rgba(0, 0, 0, 0.1),
        0 0 0 0 rgba(0, 179, 204, 0);
}

.uxt-pagination .page-numbers:hover:not(.dots):not(.current) {
    background: color-mix(in oklab, var(--surface-1) 80%, transparent);
    color: var(--text-primary);
    transform: translateY(-3px);
    box-shadow:
        0 12px 24px -8px rgba(0, 0, 0, 0.4),
        0 0 20px color-mix(in oklab, var(--accent) 35%, transparent);
}

.uxt-pagination .page-numbers.current {
    background: var(--accent);
    color: #fff;
    box-shadow:
        0 10px 25px -8px rgba(0, 179, 204, 0.5),
        0 0 20px color-mix(in oklab, var(--accent) 40%, transparent);
    transform: translateY(-2px) scale(1.05);
}

.uxt-pagination .page-numbers.dots {
    background: transparent;
    border: none;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    box-shadow: none;
    cursor: default;
    min-width: 30px;
}

@media (max-width: 768px) {

    /* MOBILE COMPACT PAGINATION (v3) */
    .uxt-pagination .nav-links {
        display: flex;
        flex-wrap: wrap;
        /* Safety wrap */
        justify-content: center;
        gap: 5px;
        /* Small gap to fit more items */
        width: 100%;
        padding: 20px 0;
        /* Vertical safe area */
        margin: 0;
        mask-image: none;
        -webkit-mask-image: none;
        overflow: visible;
    }

    /* Reset: Show all items provided by PHP, but make them small */
    .uxt-pagination .page-numbers {
        display: flex;
        align-items: center;
        justify-content: center;
        min-width: 32px;
        /* Small touch targets */
        height: 32px;
        padding: 0 4px;
        font-size: 0.85rem;
        border-radius: 8px;
        flex-shrink: 0;
    }

    /* Standardize arrows */
    .uxt-pagination .page-numbers.prev,
    .uxt-pagination .page-numbers.next {
        width: 32px;
        height: 32px;
        font-size: 1rem;
    }

    /* Current page indicator */
    .uxt-pagination .page-numbers.current {
        min-width: 32px;
        padding: 0 8px;
        font-weight: 800;
        height: 32px;
    }

    /* Dots */
    .uxt-pagination .page-numbers.dots {
        min-width: 16px;
        height: 32px;
        display: flex;
        background: transparent !important;
        box-shadow: none !important;
    }
}

/* --- Component Titles (Accent style) --- */
.uikit-comp-title {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--accent);
    font-weight: 950;
    margin: 0;
    line-height: 1.4;
}

/* --- Danger Titles (Error states) --- */
.uikit-danger-title {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--danger);
    font-weight: 950;
    margin: 0;
    line-height: 1.4;
}

/* --- Accent Text --- */
.uikit-accent {
    color: var(--accent);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* --- Primary Text --- */
.uikit-text-pri {
    color: var(--text-primary);
}

/* --- Secondary Text --- */
.uikit-text-sec {
    color: var(--text-secondary);
}

/* --- Choice Labels (text beside checkbox/radio/toggle) --- */
.choice-label {
    color: var(--text-primary);
    font-weight: 500;
    font-size: 0.95rem;
}

/* --- Popup & Glass Panel Elements --- */
.wm-glass-panel {
    background: var(--popup-bg);
    -webkit-backdrop-filter: blur(var(--popup-blur));
    backdrop-filter: blur(var(--popup-blur));
    border-radius: var(--radius-xl);
    padding: 32px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    border: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    width: 90%;
    max-width: 400px;
    overflow: hidden;
    position: relative;
}

.wm-close-minimal {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.3s var(--ease);
    z-index: 10;
}

.wm-close-minimal:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
}

@keyframes pulse-red {
    0% {
        box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.4);
    }

    70% {
        box-shadow: 0 0 0 15px rgba(239, 68, 68, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(239, 68, 68, 0);
    }
}

.pulse-red {
    animation: pulse-red 2s infinite;
}

.wm-glass-title {
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 8px;
    position: relative;
    z-index: 3;
}

.wm-glass-panel-content {
    color: var(--text-primary);
    line-height: 1.5;
    position: relative;
    z-index: 3;
}

.wm-glass-panel-content p {
    margin: 0 0 15px 0;
}

.wm-glass-panel-content p:last-child {
    margin-bottom: 0;
}

/* --- Select Labels --- */
.wm-select-label {
    color: var(--text-secondary);
    font-weight: 500;
    transition: var(--transition);
}

.wm-select-btn:hover .wm-select-label {
    color: var(--accent);
}

/* --- Code Labels (component class names) --- */
.uikit-code-label {
    display: inline-block;
    background: color-mix(in srgb, var(--accent), transparent 90%);
    color: var(--accent);
    font-family: 'Consolas', 'Monaco', monospace;
    font-size: 0.8rem;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: var(--radius-sm);
    border: 1px solid color-mix(in srgb, var(--accent), transparent 70%);
    margin-top: 10px;
}

/* --- Code Snippets --- */
.uikit-code-snippet {
    background: color-mix(in srgb, var(--surface-1), transparent 50%);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 8px 14px;
    font-family: 'Consolas', 'Monaco', monospace;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* --- Description Text (in cards) --- */
.uikit-desc {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin: 0;
    line-height: 1.5;
}

/* --- Radius Utility Classes --- */
.uikit-radius-xl {
    border-radius: var(--radius-xl);
}

.uikit-radius-lg {
    border-radius: var(--radius-lg);
}

.uikit-radius-md {
    border-radius: var(--radius-md);
}

.uikit-radius-sm {
    border-radius: var(--radius-sm);
}

.uikit-radius-xs {
    border-radius: var(--radius-xs);
}

/* --- TAGS & BADGES --- */
.tag-glow-variant {
    display: inline-flex;
    align-items: center;
    padding: 7px 18px;
    background-color: color-mix(in oklab, var(--surface-1) 30%, transparent);
    background-image: linear-gradient(135deg, color-mix(in oklab, var(--bg-grad-2) 15%, transparent), color-mix(in oklab, var(--bg-grad-1) 15%, transparent));
    color: var(--text-secondary);
    border-radius: 22px;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
    border: none;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    box-shadow:
        0 4px 12px rgba(0, 0, 0, 0.1),
        0 0 0 0 rgba(0, 179, 204, 0);
}

.tag-glow-variant:hover {
    background: color-mix(in oklab, var(--surface-1) 80%, transparent);
    color: var(--text-primary);
    transform: translateY(-3px);
    box-shadow:
        0 12px 24px -8px rgba(0, 0, 0, 0.4),
        0 0 20px color-mix(in oklab, var(--accent) 35%, transparent);
}

/* --- CATEGORY BADGES --- */
.meta-cats {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.meta-cat-badge {
    display: inline-flex;
    align-items: center;
    background: color-mix(in oklab, var(--accent) 15%, transparent);
    color: var(--accent);
    padding: 7px 18px;
    border-radius: 99px;
    text-decoration: none;
    font-weight: 700;
    transition: all 0.3s var(--ease);
    font-size: 0.85rem;
    letter-spacing: 0.02em;
    line-height: 1;
    -webkit-backdrop-filter: blur(4px);
    backdrop-filter: blur(4px);
    border: none;
}

.meta-cat-badge:hover {
    background: var(--accent);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 179, 204, 0.3);
}

/* ============================================
   END UTILITY CLASSES
   ============================================ */

/* --- UXT SECTION SYSTEM (UI KIT STANDARD) --- */
/* This is the master spacing rule for all homepage blocks. 
   We use ONLY top padding to prevent double-spacing. */
.uxt-section,
.latest-news-block-section,
.popular-categories-section,
.uxt-curiosities-section,
.homepage-seo-container {
    padding-top: var(--space-xl) !important;
    padding-bottom: 0 !important;
    margin-top: 0 !important;
    margin-bottom: 0 !important;
    display: block;
    width: 100%;
}

/* Special Case: Match heritage gap (same as between tiles) for the first section following the header 
   (Uses var(--space-md) instead of var(--space-xl) for a tighter fit) */
.main-content-raw>section:first-child,
.main-content-raw>.container:first-child,
.hero-wrapper {
    padding-top: var(--space-md) !important;
    margin-top: 0 !important;
}

/* --- GLOBAL SPACING RESET (DESKTOP & MOBILE) --- */
/* This ensures NO element inside our main wrapper can push sections apart.
   ONLY padding-top of the section itself is allowed to create space. */
.main-content-raw>* {
    margin-bottom: 0 !important;
    margin-top: 0 !important;
}

/* --- GLOBAL SECTION SPACING SYSTEM --- */
/* This is the master rule for all homepage blocks. 
   We ONLY use padding-top for spacing. 
   Margin-bottom/Padding-bottom are strictly zeroed to prevent double-gaps. */
.main-content-raw {
    padding-bottom: var(--space-lg) !important;
    /* Safety gap before footer (30px) */
}

.uxt-section,
.latest-news-block-section,
.popular-categories-section,
.uxt-curiosities-section {
    padding-top: var(--space-xl) !important;
    /* Standard 60px */
    padding-bottom: 0 !important;
    margin-top: 0 !important;
    margin-bottom: 0 !important;
    position: relative;
    background: transparent !important;
}

/* SEO Section specific spacing - Clean Implementation */
.homepage-seo-section {
    padding-top: var(--space-xl) !important;
    /* Restore standard 60px spacing */
    padding-bottom: 0 !important;
    margin-top: 0 !important;
    margin-bottom: 0 !important;
    position: relative;
    display: block !important;
    /* Ensure block behavior */
    min-height: var(--space-xl);
    /* Ensure minimum height */
    background: transparent !important;
    border: none !important;
    /* Ensure no border */
}

.homepage-seo-container {
    padding-top: 0 !important;
    /* crucial: prevent double padding */
    padding-bottom: 0 !important;
    margin-top: 0 !important;
    margin-bottom: 0 !important;
    background: transparent !important;
}


/* Kill ALL margins/paddings for stray elements injected by WordPress globally */
.main-content-raw>p,
.main-content-raw>br,
.main-content-raw>div:not([class]),
.main-content-raw>span:empty,
.main-content-raw>p:empty {
    display: none !important;
    margin: 0 !important;
    padding: 0 !important;
    height: 0 !important;
    width: 0 !important;
    overflow: hidden !important;
}

/* Zero out local margins of internal grid containers to prevent height spill */
/* Nuclear Cleanup: No internal element should push the section bottom */
.lnb-news-grid,
.lnb-tiles-column,
.lnb-container-sidebar,
.pc-grid,
.cur-layout-grid,
.ad-unit-wrap,
.lnb-tile,
.container,
.sticky-sidebar,
aside[class*="column"] {
    margin-bottom: 0 !important;
    padding-bottom: 0 !important;
    margin-top: 0 !important;
}

/* Ensure any last-child inside these containers also has no margin */
/* Recursive fix: targets any element that is the last child of its container 
   We ONLY zero out margin-bottom here to preserve internal paddings of cards/tiles. */
.latest-news-block-section *:last-child,
.popular-categories-section *:last-child,
.uxt-curiosities-section *:last-child,
.homepage-seo-container *:last-child {
    margin-bottom: 0 !important;
}

/* Force specific containers to stay tight */
.latest-news-block-section .container,
.popular-categories-section .container,
.uxt-curiosities-section .container,
.homepage-seo-container .container {
    padding-bottom: 0 !important;
    margin-bottom: 0 !important;
}

@media (max-width: 768px) {

    /* Mobile specific overrides */
    .uxt-section,
    .latest-news-block-section,
    .popular-categories-section,
    .uxt-curiosities-section {
        padding-top: var(--space-xl) !important;
    }

    /* Force the last block's safety margin before footer */
    .main-content-raw>*:last-child {
        padding-bottom: var(--space-lg) !important;
    }
}

/* Specific fix for Hero - it must not have any bottom gap */
.hero-wrapper {
    margin-bottom: 0 !important;
    padding-bottom: 0 !important;
}

/* Spacing handled by global system above */

/* --- UNIFIED SECTION HEADERS (STANDARD RHYTHM) --- */
.lnb-section-header,
.pc-header,
.seo-section-header {
    margin-bottom: var(--space-lg) !important;
    /* Standard 30px gap */
    padding-bottom: 0 !important;
    margin-top: 0 !important;
    display: flex !important;
    justify-content: space-between !important;
    align-items: flex-end !important;
    border-left: 4px solid var(--accent) !important;
    padding-left: 20px !important;
}

/* Force all titles to have identical vertical footprint */
.lnb-section-header .uikit-h2,
.lnb-section-header h2,
.pc-header .pc-title,
.pc-header h2,
.seo-section-header .seo-section-title,
.seo-section-header h2,
.faq-section-header .faq-section-title,
.faq-section-header h2 {
    margin: 0 !important;
    padding: 0 !important;
    line-height: 1.2 !important;
    font-size: var(--fs-h2) !important;
}

/* Reset individual block top margins to rely on header's bottom margin */
.seo-panel,
.lnb-news-grid,
.pc-grid,
.cur-layout-grid {
    margin-top: 0 !important;
}

.seo-section-header {
    /* Rules inherited from unified section headers above */
    margin-bottom: var(--space-lg) !important;
    border-left: 4px solid var(--accent);
    padding-left: 20px;
}

.seo-section-title {
    /* Rules inherited from unified titles above */
    font-weight: 700;
    color: var(--text-headings);
    text-align: left;
}

.seo-panel {
    background: var(--surface-1);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    /* Increased to 60px for a more airy, premium feel */
    text-align: left;
}

.seo-block h3 {
    margin-top: var(--space-lg);
    margin-bottom: 15px;
    font-size: var(--fs-h3);
    color: var(--text-headings);
}

.seo-block h3:first-child {
    margin-top: 0;
}

.seo-block p {
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 20px;
}

.seo-block ul {
    margin-top: 15px;
    padding-left: 20px;
    color: var(--text-secondary);
}

.seo-block li {
    margin-bottom: 10px;
}

@media (max-width: 768px) {
    .seo-section-header {
        margin-bottom: 15px !important;
    }

    .seo-panel {
        padding: 30px !important;
        /* Balanced mobile padding */
    }

    .seo-block h3 {
        margin-top: 25px !important;
        margin-bottom: 15px !important;
    }

    .seo-block p {
        margin-bottom: 20px !important;
        /* More airy paragraphs */
    }

    .seo-block ul {
        margin-bottom: 15px !important;
    }

    .seo-block li {
        margin-bottom: 12px !important;
        /* Space between list items */
    }
}

/* Fix Ad Unit Margins when inside grids to prevent double spacing - Desktop Only */
@media (min-width: 951px) {

    .lnb-news-grid .ad-unit-wrap,
    .lnb-tiles-column .ad-unit-wrap,
    .cur-list-column .ad-unit-wrap {}
}

/* --- NUCLEAR DEBUG SPACING MODE --- */
/* This mode is only active when enabled in UXI Pro Settings -> Layout */
.uxt-spacing-debug .hero-wrapper,
.uxt-spacing-debug .latest-news-block-section,
.uxt-spacing-debug .popular-categories-section,
.uxt-spacing-debug .uxt-curiosities-section,
.uxt-spacing-debug .homepage-seo-container {
    outline: 4px solid #ff00ea !important;
    position: relative !important;
}

.uxt-spacing-debug .latest-news-block-section::before,
.uxt-spacing-debug .popular-categories-section::before,
.uxt-spacing-debug .uxt-curiosities-section::before,
.uxt-spacing-debug .homepage-seo-container::before {
    content: var(--debug-xl-label, "GAP 60PX") !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: var(--space-xl) !important;
    background: rgba(255, 0, 0, 0.4) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    color: white !important;
    font-size: 14px !important;
    font-weight: 900 !important;
    z-index: 99999 !important;
    pointer-events: none !important;
    text-transform: uppercase !important;
}

.uxt-spacing-debug .lnb-section-header,
.uxt-spacing-debug .pc-header,
.uxt-spacing-debug .seo-section-header {
    outline: 2px solid #00ff00 !important;
    background: rgba(0, 255, 0, 0.1) !important;
}

.uxt-spacing-debug .lnb-news-grid,
.uxt-spacing-debug .pc-grid,
.uxt-spacing-debug .cur-layout-grid,
.uxt-spacing-debug .seo-panel {
    outline: 2px solid cyan !important;
}