@import url('ThemeVariables.css');

body {
    margin: 0px;
    padding: 0px;
    /* Remove margin/padding added by the browser */
    font-family: Tahoma, Helvetica, Arial, Georgia;
    background-color: var(--general-bg);
}

.main-container {
    display: flex;
    align-items: center;
    justify-content: center;
}

#page-content-container {
    display: flex;
    flex-direction: column;

    margin-left: 80px;
    box-shadow: var(--box-shadow);
    background-attachment: fixed;
}

/***** BANNER STYLING *****/
/*************************/
.banner {
    display: flex;
    flex-direction: column;
    align-items: center;
    row-gap: .25em;

    padding-top: 40px;
    padding-bottom: 20px;
    padding-right: 20px;
    padding-left: 20px;

    box-shadow: inset 0 0 0 1000px var(--background);
    background-attachment: fixed;
    color: var(--text-color-darkbg);

    h1 {
        margin-top: .25em;
        margin-bottom: .25em;
    }
}

.banner-links-container {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: row;
    flex-wrap: wrap;
    margin-bottom: 10px;
    padding: 0 10% 1em 10%;
    column-gap: 1em;
    row-gap: 1em;
    border-bottom: 1px solid gray;
}

.banner-link {
    display: inline-flex;
    padding: 4px 6px 4px 6px;
    background-color: white;
    border-radius: 5px;
    align-items: center;
    column-gap: .5em;
    transition: all 0.1s;
    font-size: large;
    white-space: nowrap;

    img {
        width: 24px;
        object-fit: contain;
    }
}

.banner-link-shieldio {

    transform: scale(1.3);
    margin-left: 1em;
    margin-right: 1em;

    .link-img {
        box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19);
        transition: all 0.1s;
    }
}

.banner-link-shieldio:hover {
    transform: scale(1.2);
    box-shadow: 0 0 10px var(--banner-link-hover-color);
    cursor: pointer;
}

/***** BANNER LINKS *****/
.banner-link-tag {
    text-decoration: none;
}

.banner-link.website-tag {
    background: linear-gradient(165deg, rgb(56, 140, 204) 0%, rgb(64, 84, 180) 100%);

    img {
        width: 1em;
    }

    a {
        color: white;
    }
}

.banner-link.github-tag {
    background: linear-gradient(180deg, rgba(18, 18, 18, 1) 0%, rgba(0, 0, 0, 1) 100%);

    img {
        filter: invert(1);
    }

    a {
        color: white;
    }
}

.banner-link:hover {
    transform: scale(1.1);
    box-shadow: 0 0 10px var(--banner-link-hover-color);
    cursor: pointer;
}


/* .project-tag styled in core.css */


/***** TEXT AREA *****/
/*************************/
.text-area-container {
    display: flex;
    flex-direction: column;
    align-self: center;
    align-items: center;
    overflow: hidden;

    margin-top: 40px;
    margin-bottom: 40px;
    padding-top: 20px;
    padding-bottom: 40px;

    width: 100%;
    max-width: 1000px;
    box-shadow: inset 0 0 100px 1000px var(--textarea-boxshadow);
}

.text-segment-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-bottom: 30px;
    width: 100%;
}

.text-segment {
    display: flex;
    flex-direction: column;
    align-items: center;

    padding-left: 10%;
    padding-right: 10%;
    line-height: 1.5;

    color: var(--text-color-darkbg);
}

/***** Headings *****/
.text-heading {
    color: var(--text-color-darkbg);
    white-space: nowrap;
    margin-bottom: 0;
}

.text-heading-with-img {
    display: flex;
    align-items: center;
    column-gap: 20px;
    margin-top: 10px;

    img {
        object-fit: contain;
        width: 3em;
        height: auto;
        filter: var(--icon-filter);
    }

    .text-heading {
        margin-top: 0;
        margin-right: 3em;
        /* Offset by img width */
    }
}

/***** Paragraphs *****/
.text-paragraph {
    margin-bottom: 0;
}
a {
    color: var(--text-link);
    text-decoration: none;
}
a:hover {
    color: var(--text-link-hover);
    text-decoration: underline;
}

.text-code-block {
    border-radius: 5px;
    padding: 1px 5px 1px 5px;
    color: var(--code-block-text);
    background-color: var(--code-block-bg);
    font-family: Tahoma, Helvetica, Arial, Georgia;
}

.project-end {
    display: flex;
    flex-direction: column;
    text-align: center;
    margin-top: 40px;
}

#last-updated-msg {
    color: var(--text-color-darkbg);
    font-style: oblique;
    font-size: small;
    text-decoration: underline;
}

/***** IMAGE SEGMENTS *****/
/*************************/
.image-banner {
    width: 80%;
}

/***** VIDEO SEGMENTS *****/
/*************************/
.video-segment {
    display: flex;
    flex-wrap: wrap;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    column-gap: 2em;
    row-gap: 1em;
    padding: 20px;
    margin-top: 20px;
    margin-bottom: 20px;
    background-color: var(--background-alt2);
    box-shadow: 0 0 5px 2px var(--glow-border);
}

iframe {
    min-width: 321px;
    /* YT has multiple thumbnail sizes, smaller than this and the blurriest image will be used */
    aspect-ratio: 16 / 9;
    box-shadow: 0 0 5px 2px var(--glow-border);
}

/***** BULLET POINT SEGMENT *****/
.bullet-point-container {
    display: flex;
    flex-direction: column;
    align-items: center;

    width: 80%;
    padding-bottom: 10px;
    background-color: var(--background-alt2);
    box-shadow: 0 0 5px 2px var(--glow-border);
    color: var(--text-color-darkbg);

    ul {
        max-width: 80%;
        min-width: 300px;
        padding-right: 20px;
        /* Due to the bullet point */
    }

    li+li {
        margin-top: 15px;
    }

    .below-bullet-paragraph {
        text-align: center;
    }

    a {
        color: var(--text-link);
    }
}

/***** CLOSEABLE SEGMENTS *****/
/*****************************/
.closeable-img-group {
    cursor: pointer;
    text-align: center;
    margin-left: auto;
    margin-right: auto;
    color: var(--text-color-darkbg);
    padding-bottom: 20px;

    summary {
        padding-top: 20px;
        padding-bottom: 20px;

        margin-left: auto;
        margin-right: auto;
    }

    summary::marker {
        color: var(--summary-marker-color);
    }

    summary::after {
        content: " show images";
    }

    .closeable[open]>summary::after {
        content: " hide images";
    }
}

.image-group-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    row-gap: 20px;
    column-gap: 20px;
    padding-left: 20px;
    padding-right: 20px;

    img {
        flex: 1;
        padding: 0;
        object-fit: fill;
        width: 300px;
        min-width: 300px;
        max-width: 400px;
        height: 225px;
        border-radius: 15px;
        box-shadow: 0 4px 8px 0 var(--glow-border);
        transition: transform 0.5s;
    }

    img:hover {
        transform: scale(1.1);
        cursor: pointer;
    }
}

/***** SWIPER JS *****/
/*TODO Why does this only work when nested?? and pagination only works outside it...*/
.image-swiper-container {

    width: 80%;
    margin-left: auto;
    margin-right: auto;

    .basicSwiper {
        display: flex;
        justify-content: center;
        align-items: center;
    }

    .swiper-wrapper {
        width: 90%;

        img {
            margin-top: 2px;
            width: 90%;
            object-fit: cover;
            box-shadow: 0 0 5px 2px var(--glow-border);
        }
    }
}

.pagination {
    display: flex;
    justify-content: center;
    align-items: center;

    padding-top: 10px;
    padding-bottom: 10px;
}

/***** PRISM JS *****/
/*******************/
.code-snippet-container {
    width: 80%;
    background-color: var(--code-background-color) !important;
    scrollbar-color: var(--scrollbar-colors);
}

/***** MOBILE STUFF *****/
/***********************/
@media only screen and (max-width: 600px) {

    #page-content-container {
        margin-left: 0;
    }

    .image-swiper-container {
        min-width: 90%;
    }

    .code-snippet-container {
        width: 75%;
    }
}

@media screen and (max-width: 450px) {

    .swiper-button-next,
    .swiper-button-prev {
        visibility: hidden;
    }

    .image-swiper-container {
        min-width: 100%;
    }

    .banner-links-container {
        padding: 0 0 1em 0;
        min-width: 80%;
    }

    .banner-link-shieldio {
        transform: scale(1.1);
        margin-left: .25em;
        margin-right: .25em;
    }

    .text-heading-with-img {
        img {
            display: none;
        }

        .text-heading {
            margin-right: 0;
        }
    }

    .bullet-point-container {
        width: 100%;
    }
}