:root {
    --hp-cards-gap: 30px;
    --accent-blue: #003FC9;
    --primary: #00c1ff;
    --accent: #a600ff50;
    --lightblue: #00A3FF;
    --lighttext: #292929;
    --dark-color: #202020;
    --text: white;
    --white: #fff;
    --header-height: 50px;
    --glass-color: rgba(255,255,255, 0.2);
    --transition: 0.3s ease;
}

* {
    box-sizing: border-box;
    font-family: 'Raleway', sans-serif;
}

body {
    margin: 0;
    padding: 0;
    color: var(--text);
    overflow-x: hidden;
    background: url("/assets/background.svg");
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center center;
    background-attachment: fixed;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased; /* Chrome */
    -moz-osx-font-smoothing: grayscale; /* Firefox macOS */
    text-rendering: optimizeLegibility;
}

body * {
    color: inherit;
}

a {
    -webkit-tap-highlight-color: transparent;
}

a:hover {
    font-weight: bold;
    color: var(--accent-blue);
}

li {
    margin: 0.6rem;
}

.section {
    margin: 2rem 0;
    padding: 1rem;
}

h1.page-heading {
    margin: 0.85rem 1rem;
}

/* Header Styles */
.header {
    position: fixed;
    top: 10px;
    width: calc(100% - 20px);
    left: 10px;
    height: var(--header-height);
    background: transparent;
    box-shadow: 0 2px 3px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 9999px;
    padding: 20px;
}

.header .header-logo .site-logo {
    display: flex;
    gap: 10px;
    align-items: center;
}

.header .header-logo img {
    height: 30px;
}

.header a {
    text-decoration: none;
}

.header .header-logo-main-part {
    font-weight: 600;
}

.hamburger {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 24px;
    height: 18px;
    background: none;
    border: none;
    cursor: pointer;
}


/* Sidebar Styles */
.sidebar {
    position: fixed;
    top: calc(var(--header-height) + 20px);
    left: 10px;
    width: 80vw;
    max-width: 250px;
    height: calc(100% - var(--header-height) - 20px - 10px);
    background: transparent;
    box-shadow: 4px 0 3px rgba(0, 0, 0, 0.05);
    padding: 10px 5px 5px 5px;
    transform: translateX(-120%);
    transition: var(--transition);
    z-index: 999;
    background: rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 30px;
    overflow-y: scroll;
}

.sidebar * {
    margin: 0;
    padding: 0;
}

.sidebar ul > li {
    margin: 10px 0;
    padding: 10px 20px;
}

.sidebar ul > li:hover, .sidebar ul > li.active {
    background: rgba(0,0,0,0.25);
    color: white;
    box-shadow: 0 0 8px #0075FF70;
}

.sidebar ul > li a {
    position: relative;
    width: 100%;
    height: 100%;
}

.sidebar a {
    color: white;
}

.sidebar ul li a.disabled {
    pointer-events: none;
    cursor: not-allowed;
}

.sidebar.active {
    transform: translateX(0);
}

.backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: #00000050;
    opacity: 0;
    pointer-events: none;
    transition: var(--transition);
    z-index: 998;
}

.backdrop.visible {
    opacity: 1;
    pointer-events: all;
}

nav ul {
    list-style: none;
    margin-top: 1rem;
}

nav li {
    display: flex;
    margin: 1.2rem;
    margin-bottom: 5px;
    border-radius: 9999px;
    padding: 10px 20px;
}

nav a {
    text-decoration: none;
    font-weight: 400;
    position: relative;
    -webkit-tap-highlight-color: transparent;
}


.footer {
    position: relative;
    width: 100%;
    padding: 10px 20px;
    margin-top: 40px;
}

.footer .copyright-notice {
    text-align: center;
    font-size: 1rem;
}


main {
    margin-top: var(--header-height);
    min-height: calc(100vh - var(--header-height) - 20px - 10px);
    padding: 1rem;
}

/* For desktop */
@media (min-width: 768px) {
    .page-wrapper {
        display: flex;
        justify-content: flex-end;
        align-content: stretch;
        gap: 20px;
    }

    main {
        transition: width 2s ease;
    }

    .sidebar.active {
        display: block;
        transtion: width 3s ease;
        flex-shrink: 0;
    }

    main.sidebar-visible {
        width: calc(100vw - 250px);

    }
    main.sidebar-invisible {
        width: 100%;
        transition: width 3s ease;
    }
    .backdrop {
        display: none;
    }
    .section {
        padding: 0 8rem;
        margin: 4rem 0;
    }
    
    h1.page-heading {
        margin: 0.85rem 8rem;
    }
}

@media (min-width: 768px) and (max-width: 1024px) {
    .section {
        padding: 0 4rem;
        margin: 4rem 0;
    }
}

/* Codeblock styles */
.code-container {
    background: black;
    box-shadow: 0 0 4px rgba(255,255,255,0.25);
    border-radius: 12px;
    max-width: 400px;
    padding: 0.5rem 1rem;
}

.code-container .code-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.code-container .code-header select {
    max-width: calc(100% - 20px - 40px);
    flex-grow: 1;
    background: #2a2a2a;
    color: white;
    border: none;
    border-radius: 6px;
    padding: 6px 12px;
    font-family: monospace;
    cursor: pointer;
}

.code-container .code-header button {
    flex-shrink: 0;
    width: 40px;
    aspect-ratio: 1;
    background: none;
    border: none;
}

.code-container .code-header button svg {
    fill: white;
    width: 20px;
    height: 20px;
}

.code-container .code-header button.cp-success svg {
    fill: #00FF02;
}

.code-container .code-header button.cp-failed svg {
    fill: #FF5300;
}

.code-container pre {
    margin: 0 !important;
    padding: 0 !important;
}


/* Reusable components */
.content-centered {
    display: flex;
    justify-content: center;
    align-items: center;
}

.themed-button {
    color: white;
    font-weight: 500;
    border-radius: 8px;
    background: var(--accent-blue);
    border: none;
    padding: 12px 1.5rem;
    box-shadow: 0 0 8px rgba(0,0,0,0.2);
    display: inline-block;
    text-decoration: none;
    webkit-tap-highlight-color: transparent;
}

.themed-button:hover {
    background: white;
    color: var(--accent-blue);
    font-weight: 600;
    transition: all 0.5s ease;
}


/* Default classes setting */
a.nostyle-anchor {
    color: currentColor;
    text-decoration: none;
}

.hidden {
    display: none !important;
}

.typing:after {
    content: "";
    border-right: 2px solid white;
    animation: blink-caret 0.7s step-end infinite;
}

.typing.done-typing:after {
    border-right: none;
}

.ruling {
    display: block;
    border-radius: 999px;
    width: 80%;
    max-width: 450px;
    height: 4px;
    margin-block: 10px;
    margin-inline: auto;
    background-color: rgba(256, 256, 256, 0.5);
}