
:root {
    --surface: #171d24;
    --text: #dce3e9;
    --blue: #73a7ff;
    --shadow: 0 5px 48px rgba(0,0,0,.32);
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: #101418;
    color: var(--text);
    font-family: Inter, system-ui, sans-serif;
}

/* Title bar */

.titlebar {
    width: 100%;
    height: 80px;
    display: flex;
    align-items: center;
    padding: 10px 20px;
    background: var(--surface);
    box-shadow: var(--shadow);
}

.logo {
    height: 60px;
}

.desktop-menu {
    margin-left: auto;
    display: flex;
    gap: 25px;
}

.desktop-menu a,
.mobile-sidebar a {
    color: var(--text);
    text-decoration: none;
}

.desktop-menu a:hover,
.mobile-sidebar a:hover {
    color: var(--blue);
}

/* Mobile button */

.menu-button {
    display: none;
    margin-left: auto;
    background: none;
    border: none;
    color: var(--text);
    font-size: 32px;
    cursor: pointer;
}

/* Mobile sidebar */

.mobile-sidebar {
    position: fixed;
    top: 0;
    left: -280px;

    width: 280px;
    height: 100dvh;

    background: var(--surface);

    display: flex;
    flex-direction: column;
    gap: 20px;

    padding: 20px;

    transition: left .3s ease;

    z-index: 1000;
}

.mobile-sidebar.open {
    left: 0;
}

.sidebar-spacer {
    flex: 1;
}

.close-menu {
    background: none;
    border: 1px solid var(--text);
    color: var(--text);
    padding: 10px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
}

.close-menu:hover {
    color: var(--blue);
}

.sidebar-logo {
    width: 200px;
    margin-bottom: 20px;
}

.menu-button {
    display: none;
    background: none;
    border: none;
    color: var(--text);
    font-size: 32px;
    cursor: pointer;
}

/* Mobile layout */

@media (max-width: 700px) {

    .titlebar {
        display: none;
    }

    .menu-button {
        display: block;
        position: absolute;
        top: 28px;
        left: 15px;
        z-index: 999;
        height: fit-content !important;
        margin: 0;
        padding: 0;
    }
}


:root {
    color-scheme: light;

    --bg: #101418;
    --surface: #ffffff;
    --surface-2: #202833;
    --surface-3: #dde8f2;

    --text: #213044;
    --text2: #000000;
    --text3: var(--muted);
    --text4: #435368;

    --muted: #66778c;
    --line: #b7c5d6;
    --line-strong: #4c5867;

    --blue: #73a7ff;
    --blue-soft: #d7e8ff;
    --blue-softer: #eaf3ff;

    --lime: #9cff35;
    --lime-soft: #dcffb5;
    --lime-text: #195700;
    --lime-glow: rgba(156, 255, 53, .56);

    --penciaalerasebutton: #d7e1ee;

    --danger: #d93025;
    --danger-soft: #ffe7e5;

    --shell: rgba(255, 255, 255, .48);

    --shadow: 0 0px 46px rgba(28, 48, 74, .12);

    --radius: 999px;

    --shadow-color: #bebebe;
    --shadow-color2: #bebebe;

    --cell-size: clamp(34px, 8.2vmin, 64px);
    --board-size: calc(var(--cell-size) * 9);

    font-family:
        Inter,
        ui-sans-serif,
        system-ui,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;
}

html.dark,
body.dark {
    color-scheme: dark;

    --bg: #101418;
    --surface: #171d24;
    --surface-2: #202833;
    --surface-3: #2a3442;

    --text: #95a4b6;
    --muted: #98a7b8;

    --line: #4e6177;

    --blue: #73a7ff;
    --blue-soft: #203a5f;
    --blue-softer: #1b2c45;

    --lime: #a7ff48;
    --pencilerasebutton: #26313f;
    --lime-soft: #263d1d;
    --lime-text: #bcff76;
    --lime-glow: rgba(167, 255, 72, .46);

    --text2: #dce3e9;
    --text3: #bec9da;
    --text4: #bbc6d4;

    --danger: #ff8a80;
    --danger-soft: #4c2424;

    --shadow-color: #232930;
    --shadow-color2: #343c45;

    --shell: rgba(255, 255, 255, .045);
    --shadow: 0 5px 48px rgba(0, 0, 0, .32);
}

* {
    box-sizing: border-box;
}

a,
a:visited {
    color: inherit;
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 2px;
    transition: color 0.15s ease;
    cursor: pointer;
}

a:hover,
a:focus-visible {
    color: var(--blue);
}

a:active {
    color: var(--blue);
}

.about-container {
    height: 100vh;
}

body {
    margin: 0;

    background:
        radial-gradient(
            circle at 15% 15%,
            color-mix(in srgb, var(--blue) 10%, transparent),
            transparent 30%
        ),
        linear-gradient(
            135deg,
            var(--bg),
            color-mix(in srgb, var(--surface-2) 40%, var(--bg))
        );

    color: var(--text);

    display: grid;
    place-items: center;

    letter-spacing: 0;
}

html {
    min-height: 100%;

    background:
        radial-gradient(
            circle at 15% 15%,
            color-mix(in srgb, var(--blue) 10%, transparent),
            transparent 30%
        ),
        linear-gradient(
            135deg,
            var(--bg),
            color-mix(in srgb, var(--surface-2) 40%, var(--bg))
        );
}

button,
input[type="button"],
input[type="submit"] {
    cursor: pointer;
}


/* Mobile */

@media (orientation: portrait) and (max-width: 700px) {

    ul {
        padding-left: 25px;
        padding-right: 5px;
    }

    li {
        margin-bottom: 5px;
    }

    li:last-child {
        margin-bottom: 0;
    }

    .card {
        padding-top: 0 !important;
    }

    .why {
        margin-top: 15px !important;
    }

    /*
       Keep the responsive sizing instead of forcing
       every button to 100px tall.
    */

    .whatamidoingwithmylife {
        height: fit-content !important;
        flex-direction: column;
    }

    .title {
        width: 80%;
        transform: translateX(55px);
        margin-top: 23px;
    }

    .close-menu {
        height: fit-content;
    }
}


* {
    box-sizing: border-box;
}

.warning {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: clamp(12px, 1.2vw, 18px);
    padding: clamp(20px, 2vw, 30px);
}

h1 {
    margin: 0;

    /*
       2.3vw on normal screens,
       but never smaller than 28px.
    */
    font-size: clamp(28px, 2.3vw, 52px);
}

p {
    margin: 0;

    font-size: clamp(16px, 1.2vw, 22px);
    line-height: 1.5;
}


/* Buttons */

button {
    position: relative;

    margin-top: 0;

    border: none;
    background: transparent;

    color: #fff;

    /*
       Keeps the original vw behaviour,
       but prevents microscopic text on phones.
    */
    font-size: clamp(16px, 1vw, 22px);

    cursor: pointer;

    /*
       Original:
       width: 12vw;
       height: 3vw;

       Now with sensible minimums.
    */
    width: clamp(130px, 12vw, 220px);
    height: clamp(48px, 3vw, 70px);

    z-index: 0;
}

button::before {
    content: "";

    position: absolute;
    inset: 0;

    background: #1f2026;

    border-radius: 100000px;

    z-index: -1;

    transition:
        background 0.2s ease,
        transform 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
}

button:hover::before {
    background: #2f3038;
}

button:active::before {
    transform: scaleX(1.2) scaleY(1.03);
}

button.spring::before {
    animation: buttonSpring 0.5s ease-out;
}

@keyframes buttonSpring {

    0% {
        transform: scaleX(1.2) scaleY(1.03);
    }

    30% {
        transform: scaleX(0.92) scaleY(0.98);
    }

    55% {
        transform: scaleX(1.12) scaleY(1.01);
    }

    78% {
        transform: scaleX(0.97) scaleY(0.99);
    }

    100% {
        transform: scaleX(1) scaleY(1);
    }
}
