:root{
    --header: #E83151;
    --bgc: #E0A9AB;
    --cards: #F3E1DD;
    --font: #333;
    --border: #666;
    --white: whitesmoke;
    --alt: #ff647e;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    background-color: var(--bgc);
    color: var(--font);
    overflow-x: hidden;
}

a {
    color: var(--header);
    font-weight: 600;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

header, footer{
    background-color: var(--header);
    color: var(--white);
    text-align: center;
    padding: 20px;
}

header h1 {
    margin: 0 0 10px 0;
}

header div button {
    width: 100px;
    height: 25px;
    font-size: 14px;
    font-weight: 600;
    text-align: center;
    background-color: var(--cards);
    border: none;
    border-radius: 20px;
    color: var(--header);
    margin: 5px;
}

header div button:hover {
    background-color: var(--white);
    border: solid 2px var(--alt);
}

header div button:active {
    opacity: 70%;
}

main {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-evenly;
    gap: 20px;
    padding: 50px 0;
    overflow-y: auto;
}

footer a {
    color: white;
    text-decoration: underline;
}

footer a:hover {
    text-decoration: none;
}

.item {
    flex: 0 0 calc(33.33% - 20px);
    background-color: var(--cards);
    border-radius: 5px;
    padding: 20px;
    margin-bottom: 20px;
    width: 340px;
    height: auto;
    z-index: 25;
    transition: .5s ease;
}
.item:hover {
    transform: translate(-5px, -5px);
    box-shadow: 10px 10px 0 var(--alt);
}

.item h3 {
    font-size: 20px;
    margin: 0 0 10px 0;
    line-height: 25px;
}

.item h3 span {
    color: white;
    font-size: 19px;
    font-weight: 500;
    font-family:Cambria, Cochin, Georgia, Times, 'Times New Roman', serif;
    background-color: var(--font);
    border: var(--font) 2px solid;
    border-radius: 7px;
    padding: 0 2px 1px 2px;
    margin: 0 5px 0 0;
}

.item .tag{
    padding: 3px 8px 3px;
    margin: 0 2px;
    color: var(--white);
    font-size: 16px;
    font-weight: 600;
    background-color: var(--alt);
    border-radius: 100px;
}


.item img {
    max-width: 100%;
    object-fit: contain;
    height: 400px;
    margin: 0 auto;
    border-radius: 5px;
    margin: 10px 0;
}

.item .desc {
    font-size: 18px;
    color: var(--border);
    width: 300px;
    min-height: 200px;
    max-height: 250px;
    opacity: 90%;
    padding: 15px;
    margin: 0 auto;
    border-radius: 10px;
    border: var(--border) solid 2px;
    overflow-y: auto;
}

.item .desc p{
    margin-bottom: 18px;
}

.item .desc code{
    background-color: var(--bgc);
    color: black;
    font-family:'Lucida Sans', 'Lucida Sans Regular', 'Lucida Grande', 'Lucida Sans Unicode', Geneva, Verdana, sans-serif;
    font-weight: 600;
    font-size: 17px;
}

footer p span{
    background-color: whitesmoke; 
    border-radius: 5px; 
    padding: 1.5px 0.5px 2px 0.5px;
}

#up{
    display: flex;
    position: fixed;
    height: 0px;
    width: 70px;
    opacity: 0;
    transform: translateY(1000%);
    z-index: 80;
    border-radius: 3px;
    background-color: var(--cards);
    top: 88vh;
    left: 93.5vw;
    transition: 0.5s ease-in-out;
    cursor: pointer;
}

#up img {
    margin: 4px;
    align-items: center;
}

.dnone {
    opacity: 50%;
}

.dnone h3 span{
    color: white;
    font-size: 19px;
    font-weight: 500;
    font-family:Cambria, Cochin, Georgia, Times, 'Times New Roman', serif;
    background-color: red;
    border: red 2px solid;
    border-radius: 7px;
    padding: 0 2px 1px 2px;
    margin: 0 5px 0 0;
}

.item .desc::-webkit-scrollbar{
	width: 8px;
}

@media (max-width: 768px) {
    .item {
        flex: 0 0 calc(50% - 20px);
    }
}

@media (max-width: 480px) {
    .item {
        flex: 0 0 calc(100% - 20px);
    }
    
    #up{
        position: fixed;
        top: 85vh;
        left: 75vw;
    }

    body{
        overflow-x: hidden;
    }
}

/* Scroll style */
::-webkit-scrollbar{
	width: 12px;
}
::-webkit-scrollbar-track{
    background-color: transparent;
}
::-webkit-scrollbar-thumb{
	background: var(--header);
	border-radius: 100vw;
	opacity: 0;
}
::-webkit-scrollbar-thumb:hover{
	background: var(--alt);
}
@supports (scrollbar-color: red blue){
	*{
		scrollbar-color: var(--header);
		scrollbar-width: auto;
	}
}

body::-webkit-scrollbar-track{
    background-color: var(--cards);
}
body::-webkit-scrollbar-thumb{
    border: var(--cards) solid 1px;
}
