@font-face {
    font-family: 'Google Sans Flex';
    src: url('../Client/Assets/googlesansflex/GoogleSansFlex-VariableFont_GRAD,ROND,opsz,slnt,wdth,wght.ttf') format('truetype-variations');
    font-weight: 100 900;
    font-stretch: 25% 151%;
    font-style: oblique 0deg 90deg;
    font-display: swap;
}

*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    user-select: none;
    -webkit-user-drag: none;
}

:root {
    --BgBase: #0d0d0d;
    --BgSurface: #141414;
    --BgSidebar: #111111;
    --BgElevated: #1a1a1a;
    --BgHover: #1f1f1f;
    --BgCode: #181818;
    --BorderColor: #2a2a2a;
    --BorderLight: #333333;
    --TextPrimary: #e8e8e8;
    --TextSecondary: #999999;
    --TextMuted: #666666;
    --AccentBrand: #ffffff;
    --AccentBrandDim: #a7a7a7;
    --AccentGreen: #4caf7d;
    --AccentOrange: #e8a54a;
    --AccentRed: #e55555;
    --SidebarWidth: 280px;
    --RadiusSm: 6px;
    --RadiusMd: 20px;
    --RadiusLg: 14px;
    --TransitionFast: 150ms ease;
    --TransitionNorm: 250ms ease;
}

html {
    font-size: 16px;
}

body {
    font-family: 'Google Sans Flex';
    background: var(--BgBase);
    color: var(--TextPrimary);
    line-height: 1.7;
    display: flex;
    min-height: 100vh;
}

::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

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

::-webkit-scrollbar-thumb {
    background: var(--BorderColor);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--BorderLight);
}

::selection {
    background: var(--AccentBrand);
    color: #fff;
}

a {
    color: var(--AccentBrand);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

.Sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: var(--SidebarWidth);
    height: 100dvh;
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(10px);
    display: flex;
    flex-direction: column;
    z-index: 100;
    overflow: hidden;
    transition: all 0.35s ease, filter 0.7s ease;
}

.SidebarHeader {
    padding: 24px 20px 16px;
    flex-shrink: 0;
}

.BrandRow {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.BrandIcon {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.BrandIcon img {
    width: 100%;
    height: 100%;
    border-radius: 4px;
}

.BrandName {
    font-size: 20px;
    font-weight: 600;
    color: var(--TextPrimary);
}

.SearchWrapper {
    position: relative;
}

.SearchWrapper i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--TextMuted);
    font-size: 14px;
    pointer-events: none;
}

#SearchInput {
    width: 100%;
    padding: 8px 12px 8px 36px;
    background: var(--BgElevated);
    border: 1px solid var(--BorderColor);
    border-radius: 50px;
    color: var(--TextPrimary);
    font-family: inherit;
    font-size: 14px;
    outline: none;
    transition: border var(--TransitionFast);
}

#SearchInput:focus {
    border-color: var(--AccentBrand);
}

#SearchInput::placeholder {
    color: var(--TextMuted);
}

.NavContainer {
    flex: 1;
    overflow-y: auto;
    scrollbar-width: none;
    padding: 12px 0 20px;
}

.NavSection {
    margin-bottom: 4px;
}

.NavSectionTitle {
    padding: 8px 20px 4px;
    font-size: 11px;
    font-weight: 600;
    color: var(--TextMuted);
}

.NavLink {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 20px;
    margin: 10px;
    font-size: 14px;
    color: var(--TextSecondary);
    cursor: pointer;
    border-radius: 50px;
    transition: all var(--TransitionFast);
    text-decoration: none;
}

.NavLink:hover {
    background: var(--BgHover);
    color: var(--TextPrimary);
    text-decoration: none;
}

.NavLink i {
    width: 16px;
    font-size: 13px;
    color: var(--TextMuted);
    flex-shrink: 0;
    text-align: center;
}

.NavLink:hover i {
    color: var(--AccentBrand);
}

.NavLink.ActivePage {
    color: var(--AccentBrand);
    background: rgba(134, 134, 134, 0.08);
}

.NavLink.ActivePage i {
    color: var(--AccentBrand);
}

.NavLink.HiddenBySearch {
    display: none;
}

.SidebarFooter {
    padding: 12px 20px;
    border-top: 1px solid var(--BorderColor);
    font-size: 12px;
    color: var(--TextMuted);
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.SidebarFooter i {
    font-size: 12px;
}

.SidebarFooter span {
    font-size: 8px;
}

.MainContent {
    margin-left: var(--SidebarWidth);
    flex: 1;
    min-height: 100vh;
    padding: 100px 56px 80px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.Page {
    display: none;
    animation: PageFadeIn 0.3s ease;
    width: 100%;
    max-width: 900px;
}

.Page.Visible {
    display: block;
}

@keyframes PageFadeIn {
    from {
        filter: blur(5px);
        transform: scale(0.98);
    }

    to {
        filter: none;
        transform: scale(1);
    }
}

.ContentHeader {
    margin-bottom: 48px;
    padding-bottom: 32px;
    border-bottom: 1px solid var(--BorderColor);
    text-align: center;
}

.WelcomeIcon {
    display: block;
    width: 80px;
    height: 80px;
    margin: 0 auto 16px;
}

.ContentHeader h1 {
    font-size: 36px;
    font-weight: 600;
    letter-spacing: -0.5px;
    margin-bottom: 8px;
}

.ContentHeader p {
    font-size: 16px;
    color: var(--TextSecondary);
    max-width: 600px;
    margin: 0 auto;
}

.DocSection {
    margin-bottom: 56px;
}

.DocSection h2 {
    font-size: 26px;
    font-weight: 600;
    letter-spacing: -0.3px;
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--BorderColor);
    display: flex;
    align-items: center;
    gap: 10px;
}

.DocSection h2 i {
    color: var(--AccentBrand);
    font-size: 22px;
}

.DocSection h3 {
    font-size: 19px;
    font-weight: 500;
    margin: 24px 0 10px;
    color: var(--TextPrimary);
}

.DocSection p {
    font-size: 15px;
    color: var(--TextSecondary);
    margin-bottom: 14px;
}

.DocSection ul,
.DocSection ol {
    margin: 0 0 16px 20px;
    color: var(--TextSecondary);
    font-size: 15px;
}

.DocSection li {
    margin-bottom: 6px;
}

.DocSection li strong {
    color: var(--TextPrimary);
}

.InlineCode {
    background: var(--BgCode);
    color: var(--AccentOrange);
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 13.5px;
    font-family: 'SF Mono', 'Fira Code', 'Consolas', monospace;
    border: 1px solid var(--BorderColor);
}

.CodeBlock {
    background: var(--BgCode);
    border: 1px solid var(--BorderColor);
    border-radius: var(--RadiusMd);
    margin: 16px 0 20px;
    overflow: hidden;
}

.CodeHeader {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 16px;
    background: var(--BgElevated);
    border-bottom: 1px solid var(--BorderColor);
    font-size: 12px;
    color: var(--TextMuted);
}

.CodeHeader i {
    margin-right: 6px;
}

.CopyButton {
    background: none;
    border: none;
    color: var(--TextMuted);
    cursor: pointer;
    font-size: 13px;
    padding: 2px 6px;
    border-radius: 4px;
    transition: all var(--TransitionFast);
    font-family: inherit;
}

.CopyButton:hover {
    color: var(--TextPrimary);
    background: var(--BgHover);
}

.CodeBlock pre {
    padding: 16px;
    overflow-x: scroll;
    font-size: 13.5px;
    line-height: 1.6;
    font-family: monospace;
    color: #d4d4d4;
}

.CodeBlock code {
    background: none;
    padding: 0;
    color: inherit;
}

.NoteBox {
    background: rgba(108, 140, 255, 0.06);
    border-left: 3px solid var(--AccentBrand);
    padding: 14px 18px;
    border-radius: 0 var(--RadiusSm) var(--RadiusSm) 0;
    margin: 16px 0;
    font-size: 14px;
    color: var(--TextSecondary);
}

.NoteBox i {
    color: var(--AccentBrand);
    margin-right: 8px;
}

.WarningBox {
    background: rgba(232, 165, 74, 0.06);
    border-left: 3px solid var(--AccentOrange);
    padding: 14px 18px;
    border-radius: 0 var(--RadiusSm) var(--RadiusSm) 0;
    margin: 16px 0;
    font-size: 14px;
    color: var(--TextSecondary);
}

.WarningBox i {
    color: var(--AccentOrange);
    margin-right: 8px;
}

.Tag {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.TagStable {
    background: rgba(76, 175, 125, 0.15);
    color: var(--AccentGreen);
}

.TagBeta {
    background: rgba(232, 165, 74, 0.15);
    color: var(--AccentOrange);
}

.TagNew {
    background: rgba(108, 140, 255, 0.15);
    color: var(--AccentBrand);
}

.TableWrapper {
    overflow-x: scroll;
    margin: 16px 0 20px;
    border-radius: var(--RadiusSm);
    border: 1px solid var(--BorderColor);
}

.DocTable {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

.DocTable th {
    background: var(--BgElevated);
    color: var(--TextPrimary);
    font-weight: 500;
    text-align: left;
    padding: 10px 14px;
    border-bottom: 1px solid var(--BorderColor);
}

.DocTable td {
    padding: 10px 14px;
    border-bottom: 1px solid var(--BorderColor);
    color: var(--TextSecondary);
}

.DocTable tr:last-child td {
    border-bottom: none;
}

.DocTable td:first-child {
    color: var(--TextPrimary);
    font-weight: 500;
}

.Kbd {
    display: inline-block;
    padding: 2px 8px;
    font-size: 12px;
    font-family: inherit;
    background: var(--BgElevated);
    border: 1px solid var(--BorderColor);
    border-radius: 4px;
    color: var(--TextSecondary);
}

.FeatureGrid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 14px;
    margin: 16px 0 20px;
}

.FeatureCard {
    background: var(--BgElevated);
    border: 1px solid var(--BorderColor);
    border-radius: var(--RadiusMd);
    padding: 20px;
    cursor: pointer;
    transition: border var(--TransitionNorm);
}

.FeatureCard:hover {
    border-color: var(--BorderLight);
}

.FeatureCard i {
    font-size: 24px;
    color: var(--AccentBrand);
    margin-bottom: 12px;
}

.FeatureCard h4 {
    font-size: 15px;
    font-weight: 500;
    margin-bottom: 6px;
}

.FeatureCard p {
    font-size: 13px;
    color: var(--TextMuted);
    margin: 0;
}

.EmptySearch {
    padding: 32px 20px;
    text-align: center;
    color: var(--TextMuted);
    font-size: 14px;
    display: none;
}

.EmptySearch i {
    display: block;
    font-size: 32px;
    margin-bottom: 12px;
    color: var(--BorderColor);
}

.EmptySearch.Visible {
    display: block;
}

.PageNav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 48px;
    padding-top: 24px;
    border-top: 1px solid var(--BorderColor);
}

.PageNavButton {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    background: var(--BgElevated);
    border: 1px solid var(--BorderColor);
    border-radius: var(--RadiusSm);
    color: var(--TextSecondary);
    font-family: inherit;
    font-size: 14px;
    cursor: pointer;
    transition: all var(--TransitionFast);
}

.PageNavButton:hover {
    background: var(--BgHover);
    color: var(--TextPrimary);
    border-color: var(--BorderLight);
}

.PageNavButton:disabled {
    opacity: 0.3;
    cursor: default;
    pointer-events: none;
}

.PageNavButton i {
    font-size: 13px;
}

.PageIndicator {
    font-size: 13px;
    color: var(--TextMuted);
}

@media (max-width: 768px) {
    .Sidebar {
        top: 23px;
        left: 16px;
        width: 40px;
        height: 40px;
        border-radius: 60px;
        filter: blur(10px);
visibility: hidden;        pointer-events: none;
    }

    .BrandRow {
        margin-left: 40px;
    }

    .Sidebar.Open {
        visibility: visible;
        opacity: 1;
        pointer-events: auto;
    top: 0;
    left: 0;
    width: 100dvw;
    height: 100dvh;
    border-radius: 0px;
    filter: none;
}

    .MainContent {
        margin-left: 0;
        padding: 95px 24px 60px;
    }

    .ContentHeader h1 {
        font-size: 28px;
    }

    .MenuToggle {
        display: flex !important;
        position: fixed !important;
        top: 23px !important;
        left: 16px !important;
    }

    .PageNav {
        flex-wrap: wrap;
        gap: 12px;
        justify-content: center;
    }
}

.MenuToggle {
    display: none;
    position: fixed;
    z-index: 200;
    width: 40px;
    height: 40px;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    backdrop-filter: blur(10px);
    appearance: none;
    border-radius:50%;
    color: var(--TextPrimary);
    font-size: 18px;
}

.Overlay {
    display: none;
    position: fixed;
    inset: 0;
    pointer-events: all;
    background: rgba(0, 0, 0, 0.5);
    z-index: 99;
}

.Overlay.Visible {
    display: block;
}

@media (min-width: 769px) {
    .Overlay {
        display: none !important;
    }

    .MenuToggle {
        display: none !important;
    }
}

.MiniIcon {
    width: 12px;
    height: 12px;
}