/* Illegal Astronauts Website */
/*
    MARK: Root
*/
:root {
    /* Colors */
    --white: #ffffff;
    --black: #000000;
    --primary-light: #f4f9ff;
    --primary-dark: #0d1117;
    --accent-1: #0f19f8;
    --accent-1-hover: #050db5;
    --accent-2: #ff1e90;
    --accent-2-hover: #d1006a;
    --accent-3: #1e90ff;
    --accent-positive: #8ef80f;
    --accent-positive-hover: #65b505;
    --accent-warning: #f8ee0f;
    --accent-negative: #f9304e;
    --social-instagram: #f00075;
    --social-instagram-hover: #a40050;
    --social-youtube: #ff0000;
    --social-youtube-hover: #b30000;
    --social-twitter: #1d9bf0;
    --social-twitter-hover: #0c71b5;
    --social-substack: #ff6416;
    --social-substack-hover: #c94300;

    /* Sizes */
    --nav-size-in: 64px;
    --nav-size-out: 250px;
}

/*
    MARK: Fonts
*/
@font-face {
    font-family: "ia Writer Mono";
    src: url("iAWriterMonoV.ttf") format("truetype");
}

@font-face {
    font-family: "Inter";
    src: url("InterVariable.ttf") format("truetype");
    font-weight: 300;
}

@font-face {
    font-family: "NewComputerModern10";
    src: url("NewCM10-Regular.ttf") format("truetype");
    font-weight: normal;
    font-style: normal;
}

/*
    MARK: Animations
*/
@keyframes blink {
    0%, 49.999%, 100% {
        opacity: 1;
    }
    50%, 99.999% {
        opacity: 0;
    }
}

/*
    MARK: General
*/
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    display: flex;
    width: 100vw;
    height: 100vh;
    font-family: "Inter", sans-serif;
    color: var(--primary-dark);
    background-color: var(--primary-light);
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: "ia Writer Mono", monospace;
    text-transform: uppercase;
}

::selection {
    color: var(--primary-light);
    background: var(--primary-dark);
}

p.highlights {
    line-height: 1.4;
}

span.highlight {
    color: var(--primary-light);
    background-color: var(--primary-dark);
    padding: 0px 4px;
}

span.highlight.a1 {
    color: var(--primary-light);
    background-color: var(--accent-1);
}

a {
    display: inline-block;
    text-decoration: none;
    color: var(--accent-1);
    border-bottom: 1px solid var(--accent-1);
}

a:hover {
    color: var(--primary-light);
    background-color: var(--accent-1);
}

hr {
    display: block;
    height: 3px;
    border: none;
    background-color: var(--primary-dark);
    margin: 10px 0;
}

#navdrawer {
    background: var(--accent-1);
    color: var(--primary-light);
    width: var(--nav-size-in);
    transition: width 0.3s;
    overflow: hidden;
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 100;
}

#navdrawer:hover {
    width: var(--nav-size-out);
}

#navdrawer ul {
    padding: 0;
    margin: 0;
    list-style: none;
    height: 100%;
    display: flex;
    flex-direction: column;
    flex-wrap: nowrap;
}

#navdrawer li {
    color: var(--primary-light);
    overflow-x: hidden;
}

#navdrawer li.top {
    width: var(--nav-size-in);
    aspect-ratio: 1;
    display: flex;
    align-content: center;
    justify-content: center;
    align-items: center;
}

#navdrawer li.bottom {
    width: 100%;
    height: var(--nav-size-in);
    aspect-ratio: 1;
    display: flex;
    align-content: center;
    justify-content: flex-end;
    align-items: center;
}

#navdrawer li.mobile {
    display: none;
}

#navdrawer li.top > span {
    font-size: 42px;
}

#navdrawer li.buffer {
    flex-grow: 1;
}

#navdrawer li.bottom > svg {
    display: inline-block;
    min-width: var(--nav-size-in);
    min-height: var(--nav-size-in);
    width: var(--nav-size-in);
    height: var(--nav-size-in);
    aspect-ratio: 1;
    padding: 8px;
}

#navdrawer li.bottom > .lucide-arrow-left-to-line {
    display: none;
}

#navdrawer:hover li.bottom > .lucide-arrow-left-to-line {
    display: inline-block;
}

#navdrawer:hover li.bottom > .lucide-arrow-right-from-line {
    display: none;
}

#navdrawer li > a {
    width: 100%;
    font-family: "ia Writer Mono", monospace;
    text-transform: uppercase;
    color: var(--primary-light);
    display: flex;
    height: var(--nav-size-in);
    aspect-ratio: 1;
    align-items: center;
    font-size: 24px;
    transition: font-size 0.3s;
    white-space: nowrap;
}

#navdrawer li > a:hover {
    background-color: var(--accent-1-hover);
}

#navdrawer li > a > svg {
    display: inline-block;
    min-width: var(--nav-size-in);
    min-height: var(--nav-size-in);
    width: var(--nav-size-in);
    height: var(--nav-size-in);
    aspect-ratio: 1;
    padding: 8px;
}

#navdrawer li.active > a > svg,
#navdrawer li.active > a > span {
    color: var(--accent-positive);
}

#navdrawer li > a > span {
    display: inline-block;
    padding: 8px;
}

#content {
    margin-left: var(--nav-size-in);
    flex: 1;
    transition: margin-left 0.3s;
}

::-webkit-scrollbar {
    width: 20px;
}

::-webkit-scrollbar-track {
    background: var(--accent-1);
}

::-webkit-scrollbar-thumb {
    background: var(--accent-positive);
}

::-webkit-scrollbar-thumb:hover {
    cursor: grab;
    background: var(--accent-positive-hover);
}

#footer {
    position: relative;
    height: var(--nav-size-in);
    color: var(--primary-light);
    background-color: var(--accent-1);
}

#footer a {
    color: var(--primary-light);
    border-bottom: 1px var(--primary-light) dotted;
}

#footer a:hover {
    border-bottom: 1px var(--primary-light) solid;
}

#footer > div {
    position: absolute;
    top: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    align-content: center;
    justify-content: center;
}

#footer > .left {
    left: 16px;
}

#footer > .right {
    right: 16px;
    text-align: right;
}

/*
    MARK: Socials Block
*/
.block.socials {
    display: grid;
}

.block.socials > a {
    border: none;
    display: flex;
    justify-content: center;
    align-items: center;
}

.block.socials > a > svg {
    width: 10%;
    height: auto;
    aspect-ratio: 1;
}

.block.socials > a > span {
    font-family: "ia Writer Mono", monospace;
    text-transform: uppercase;
    font-size: 2em;
    padding-left: 16px;
}

.block.socials > .instagram {
    color: var(--primary-light) !important;
    background-color: var(--social-instagram) !important;
}

.block.socials > .instagram:hover {
    color: var(--primary-light) !important;
    background-color: var(--social-instagram-hover) !important;
}

.block.socials > .twitter {
    color: var(--primary-light) !important;
    background-color: var(--social-twitter) !important;
}

.block.socials > .twitter:hover {
    color: var(--primary-light) !important;
    background-color: var(--social-twitter-hover) !important;
}

.block.socials > .substack {
    color: var(--primary-light) !important;
    background-color: var(--social-substack) !important;
}

.block.socials > .substack:hover {
    color: var(--primary-light) !important;
    background-color: var(--social-substack-hover) !important;
}

/*
    MARK: Attributions Page
*/
#attributions #content {
    padding: 32px;
}

#attributions h1,
#attributions h2,
#attributions h3,
#attributions p {
    margin-bottom: 16px;
}

/*
    MARK: Index Page
*/
#index #content {
    overflow-x: hidden;
}

#index #banner {
    height: 10vh;
    display: flex;
    align-content: center;
    justify-content: center;
    align-items: center;
    color: var(--primary-light);
    background-color: var(--accent-1);
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
}

#index #banner h1 {
    font-size: 4em;
}

#index #banner h1::after {
    content: "_";
    animation: infinite linear 2s blink;
}

#book {
    height: 64%;
    aspect-ratio: 0.625; /* 5x8 */
    background-color: transparent;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    transition: transform 0.1s cubic-bezier(.25,.8,.25,1);
    transform-style: preserve-3d;
    will-change: transform;
    transform: perspective(600px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
    padding: 32px 0 0 0;
}

#book > img {
    display: block;
    width: 100%;
    border-radius: 2px;
}

#index #header {
    width: 100%;
    height: 100vh;
    display: flex;
    align-content: center;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: hidden;
    background-image: url(../images/satellite_1.jpg);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

#index #header .left {
    position: absolute;
    left: 0;
    bottom: 0;
}

#index #header .right {
    position: absolute;
    right: 0;
    bottom: 0;
}

#index #header .cta > a {
    font-size: 2em;
    padding: 32px;
    color: var(--primary-dark);
    background-color: var(--accent-positive);
    border-bottom: 0;
}

#index #header .cta > a:hover {
    background-color: var(--accent-positive-hover);
}

#index #details .intro {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
}

#index #details .intro > div {
    width: 50%;
}

#index #details .intro > .title,
#index #details .intro > .subtitle {
    padding: 32px;
    display: flex;
    align-content: center;
    justify-content: center;
    align-items: center;
}

#index #details .intro > .subtitle {
    color: var(--primary-light);
    background-color: var(--accent-1);
    display: flex;
    align-content: center;
    justify-content: center;
    align-items: center;
}

#index #details .intro > .subtitle p {
    font-size: 24px;
    line-height: 1.75;
    text-align: justify;
}

#index #details .intro > .title {
    text-align: center;
    font-size: 2em;
    color: var(--primary-light);
    background-color: var(--accent-1);
}

#index #details .intro > .img {
    min-height: 420px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

#index #details .intro > .img > div {
    position: absolute;
    overflow: hidden;
    width: 100%;
}

#index #details .intro > .img > div > img {
    display: block;
    width: 100%;
    background-color: var(--primary-dark);
}

#index #details .intro > .quote {
    display: flex;
    align-content: center;
    justify-content: center;
    align-items: center;
    color: var(--primary-light);
    background-color: var(--accent-2);
    min-height: 420px;
}

#index #details .intro > .quote p {
    font-family: "ia Writer Mono", monospace;
    font-weight: bold;
    font-size: 3em;
    text-align: center;
}

#index #details .doc {
    padding: 32px;
    color: var(--primary-light);
    background-color: var(--accent-1);
    font-family: "NewComputerModern10", cursive;
}

#index #details .doc > div {
    color: var(--primary-dark);
    background-color: var(--primary-light);
    padding: 64px;
    width: 75%;
    max-width: 900px;
    min-width: 300px;
    aspect-ratio: 9 / 16;
    margin: 0 auto;
    box-shadow: #00000040 4px 4px 10px 0px;
}

#index #details .doc .header {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-content: center;
    align-items: center;
    justify-content: flex-start;
    margin-bottom: 42px;
}

#index #details .doc .header .logo {
    width: 32%;
}

#index #details .doc .header .logo svg {
    width: 100%;
}

#index #details .doc .header .text {
    width: 68%;
    padding-left: 16px;
}

#index #details .doc .header .text p {
    line-height: initial;
    margin-bottom: 4px;
    text-indent: 0;
    text-align: left;
}

#index #details .doc .header .text p.brand {
    color: var(--accent-1);
    font-weight: bold;
}

#index #details .doc .highlight {
    color: var(--primary-light);
    background-color: var(--primary-dark);
}

#index #details .doc p {
    font-size: 24px;
    line-height: 1.75;
    margin-bottom: 32px;
    text-indent: 32px;
    text-align: justify;
}

#index #details .doc p:last-child {
    text-align: center;
    text-indent: 0;
    margin-bottom: 0;
}

#index #engage .banner {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 128px;
    color: var(--primary-light);
    background-color: var(--accent-1);
}

#index #engage .banner > h2 {
    font-size: 2em;
}

#index #engage .content {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    height: 420px;
}

#index #engage .content > div {
    width: 50%;
    display: grid;
}

#index #engage .content > div > a {
    color: var(--primary-dark);
    background-color: var(--accent-positive);
    border: none;
    display: flex;
    justify-content: center;
    align-items: center;
}

#index #engage .content > div > a:hover {
    background-color: var(--accent-positive-hover);
}

#index #engage .content > div > a > svg {
    width: 10%;
    height: auto;
    aspect-ratio: 1;
}

#index #engage .content > div > a > span {
    font-family: "ia Writer Mono", monospace;
    text-transform: uppercase;
    font-size: 2em;
    padding-left: 16px;
}

/*
    MARK: Book 1 Page
*/
#book1 #content {
    overflow-x: hidden;
}

#book1 #content > .header {
    height: 10vh;
    color: var(--primary-light);
    background-color: var(--accent-1);
    display: flex;
    justify-content: center;
    align-content: center;
    align-items: center;
}

#book1 #content .content {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-content: center;
    align-items: center;
    justify-content: center;
    overflow-x: hidden;
    background-image: url(../images/planet3.png);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

#book1 #content .content > div {
    width: 50%;
}

#book1 #content .content > .cover {
    display: flex;
    align-content: center;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    padding: 32px;
}

#book1 #content .content > .cover > img {
    display: block;
    width: 75%;
    max-width: 406px;
    max-height: 650px;
    aspect-ratio: 0.625;
    box-shadow: #00000040 4px 4px 10px 0px;
    border-radius: 2px;
}

#book1 #content .content > .details {
    display: grid;
    grid-template-rows: auto;
}

#book1 #content .content > .details .header,
#book1 #content .content > .details > .blurb {
    display: flex;
    align-content: center;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    padding: 32px;
}

#book1 #content .content > .details > .blurb {
    background-color: var(--primary-light);
}

#book1 #content .content > .details .headerCta {
    display: block;
    color: initial;
    border-bottom: none;
    background-color: var(--accent-positive);
}

#book1 #content .content > .details .headerCta:hover {
    background-color: var(--accent-positive-hover);
}

#book1 #content .content > .details .header {
    font-size: 2em;
}

#book1 #content .content > .details > .blurb > p {
    margin-bottom: 16px;
    font-size: 18px;
}

#book1 #content .content > .details > .blurb > p:last-child {
    margin-bottom: 0;
}

#book1 #content .content .linkouts {
    color: var(--primary-light);
    background-color: var(--accent-1);
    padding: 16px;
    text-align: center;
}

#book1 #content .content .linkouts .publisher {
    margin-bottom: 16px;
    font-size: 18px;
    color: var(--primary-light);
}

#book1 #content .content .linkouts .publisher > a {
    font-family: "NewComputerModern10", cursive;
    font-size: 20px;
    color: var(--primary-light);
    border-color: var(--primary-light);
}

#book1 #content .content .linkouts .publisher > a:hover {
    background-color: var(--accent-1-hover);
}

#book1 #content .content .linkouts .seller {
    display: flex;
    justify-content: center;
    align-items: center;
    align-content: center;
}

#book1 #content .content .linkouts .seller > a {
    display: block;
    padding: 32px;
    max-width: 512px;
}

#book1 #content .content .linkouts .seller > a:hover {
    background-color: var(--accent-1-hover);
}

#book1 #content .content .linkouts .seller > a > img {
    display: block;
    width: 100%;
}

/*
    MARK: Mobile Overrides
*/
@media (max-width: 800px) {
    :root {
        --nav-size-in: 48px;
        --nav-size-out: 180px;
    }

    body {
        flex-direction: column;
        min-width: 0;
        min-height: 0;
        font-size: 16px;
    }

    #navdrawer {
        position: fixed;
        width: 100vw;
        height: var(--nav-size-in);
        top: 0;
        left: 0;
        z-index: 1000;
        transition: height 0.3s, width 0.3s;
        overflow-x: auto;
        overflow-y: hidden;
    }

    #navdrawer.navHover {
        width: 100vw;
        height: 100vh;
    }

    #navdrawer ul {
        height: 100%;
        align-items: center;
        justify-content: flex-end;
    }

    #navdrawer li,
    #navdrawer li.top,
    #navdrawer li.bottom {
        font-size: 1em;
        display: none;
    }

    #navdrawer li.buffer {
        display: none;
    }

    #navdrawer li.mobile {
        display: flex;
        align-content: center;
        align-items: center;
        justify-content: space-between;
        flex-direction: row;
        width: 100%;
        height: 100%;
        padding: 0 16px;
    }
    
    #navdrawer li.mobile > span {
        display: block;
        font-size: 2em;
        width: var(--nav-size-in);
        text-align: center;
    }

    #navdrawer li.mobile > svg {
        width: var(--nav-size-in);
        aspect-ratio: 1;
    }

    #navdrawer li.mobile > .lucide-arrow-up-from-line {
        display: none;
    }

    #navdrawer.navHover li.item {
        display: initial;
        width: 100%;
    }

    #navdrawer.navHover li.mobile {
        height: var(--nav-size-in);
        margin-top: var(--nav-size-in);
    }

    #navdrawer.navHover li.mobile > .lucide-arrow-up-from-line {
        display: block;
    }

    #navdrawer.navHover li.mobile > .lucide-arrow-down-from-line {
        display: none;
    }

    #navdrawer li > a {
        font-size: 1em;
        height: var(--nav-size-in);
        padding: 0 8px;
    }

    #navdrawer.navHover li > a {
        justify-content: space-between;
    }

    #navdrawer:hover { /* Disable the actual hover effect */
        width: inherit;
    }

    #navdrawer li > a > svg {
        width: 32px;
        height: 32px;
        min-width: 32px;
        min-height: 32px;
        padding: 4px;
    }

    #navdrawer li.top > span {
        font-size: 1.5em;
    }

    #content {
        margin-left: 0;
        margin-top: var(--nav-size-in);
    }

    #footer {
        height: auto;
        padding: 8px 0;
        position: static;
        text-align: center;
    }

    #footer > div,
    #footer > .left,
    #footer > .right {
        position: static;
        display: block;
        text-align: center;
        padding: 0;
    }

    /* Index Page */
    #index #header {
        flex-direction: column;
        height: auto;
        min-height: 60vh;
        padding: 16px 0;
        background-position: center top;
    }

    #index #banner {
        position: static;
        height: auto;
        margin-bottom: 16px;
        background-color: transparent;
    }

    #index #banner h1 {
        font-size: 2em;
        text-align: center;
    }

    #book {
        width: 80vw;
        height: 52vh;
        max-width: 320px;
        margin: 0 auto 16px auto;
        display: flex;
        align-content: center;
        justify-content: center;
        align-items: center;
        padding: 32px 0;
    }

    #book > img {
        height: 100%;
        width: auto;
    }

    #index #header .left,
    #index #header .right {
        position: static;
        width: 100%;
        text-align: center;
        margin: 8px 0;
    }

    #index #header .cta > a {
        font-size: 1.2em;
        padding: 16px;
        width: 90vw;
        max-width: 320px;
        margin: 0 auto;
        display: block;
    }

    #index #details .intro {
        flex-direction: column;
    }

    #index #details .intro > div {
        width: 100%;
        min-width: 0;
        padding: 8px 0;
    }

    #index #details .intro > .img {
        min-height: 180px;
    }

    #index #details .intro > .quote {
        min-height: 120px;
        font-size: 1.2em;
    }

    #index #details .doc {
        padding: 12px;
    }

    #index #details .doc > div {
        width: 100%;
        padding: 42px;
        max-width: initial;
        min-width: initial;
    }

    #index #engage .banner {
        height: auto;
        padding: 8px 0;
    }

    #index #engage .content {
        flex-direction: column;
        height: auto;
    }

    #index #engage .content > div {
        width: 100%;
        min-width: 0;
    }

    #index #engage .content > div > a {
        font-size: 1em;
        padding: 12px;
    }

    /* Book1 Page */
    #book1 #content > .header {
        height: auto;
        font-size: 1.2em;
        padding: 8px 0;
        text-align: center;
    }

    #book1 #content .content {
        flex-direction: column;
        height: auto;
    }

    #book1 #content .content > div {
        width: 100%;
        min-width: 0;
    }

    #book1 #content .content > .cover {
        padding: 16px;
    }

    #book1 #content .content > .cover > img {
        width: auto;
        height: 100%;
        max-width: 320px;
        max-height: 400px;
    }

    #book1 #content .content > .details .header,
    #book1 #content .content > .details > .blurb {
        font-size: 1em;
    }

    #book1 #content .content > .details > .blurb > p {
        font-size: 1em;
    }

    /* Socials block */
    .block.socials > a {
        height: 75px;
    }

    .block.socials > a > svg {
        width: 32px;
        height: 32px;
    }

    .block.socials > a > span {
        font-size: 1em;
        padding-left: 8px;
    }
}
