@font-face {
    font-family: "Poppins SemiBold";
    src: url("/assets/Poppins/Poppins-Regular.ttf");
}

:root{
    --body-width: min(calc(90vw), 720px);
    

    --radius: 12.8px;
}

body{
    font-family: "Poppins SemiBold";
    /* background-color: rgb(55, 55, 177); */
    background-color: rgb(130, 130, 141);
    background-image: linear-gradient(to bottom, rgb(179, 179, 199), rgb(121, 121, 141));
    background-size: cover;
    background-size: 100dvh;
    /* height: 100dvh; */ /* Remove it maybe? */
    margin: 0; 
    background-attachment: fixed;

    color: white;
    /* background: radial-gradient(circle at 50% 5%, rgba(255,255,255,.16), transparent 34%), linear-gradient(180deg, var(--bg-top), var(--bg-bottom)); */
}

body >:first-child{
    margin-top: 250px;
    
}


.return{
    border-radius: 10px;
    background: linear-gradient(145deg, rgba(106,109,133,.34), rgba(91,94,117,.24));
    box-sizing: border-box;
    padding: 5px 10px;
    display: inline-block;

    color: rgba(255, 255, 255, 0.849);
    
    
    /* width: 200px; */
    /* margin-inline: auto; */
    margin-bottom: 1rem;
}

.return svg{
    margin-left: -2px;
    margin-right: 0.4rem;
    height: 20px;
    translate: 0 -2px;
    vertical-align: middle;
    fill: rgba(255, 255, 255, 0.849);
}


main{
    margin-inline: auto;
    width: var(--body-width);
}

.card {
    user-select: none;
    box-sizing: border-box;

    
    
    background: linear-gradient(145deg, rgba(106,109,133,.34), rgba(91,94,117,.24));

    border-radius: var(--radius);

    min-height: 304px;
    display: grid;
    grid-template-columns: 1fr 1fr;

    gap: 22.4px;

    padding: 16px 40px;
    align-items: center;

    overflow: hidden;
}

.card div{
    text-align: center;
}

.error-code {
    font-size: clamp(75.2px, 14.4vw, 120px);

    line-height: .85;
    font-weight: 900;
    letter-spacing: -.08em;
    margin: 0 0 19.2px;
    translate: -0.4rem;
    color: #eeeef8;
    text-shadow: 0 11.2px 24px rgba(55, 57, 77, .18);
}

.card h1 {
    margin: 0 0 14.4px;
    font-size: clamp(24px, 3.2vw, 36.8px);
    line-height: 1;
    letter-spacing: -.04em;
    color: rgba(255, 255, 255, 0.836);
    /* white-space: nowrap; */
}


.art {
    position: relative;
    min-height: 232px;
    display: grid;
    place-items: center;
    perspective: 720px;
}

.box {
    position: relative;
    width: 192px;
    height: 136px;
    border-radius: 11.2px;
    background: linear-gradient(145deg, #a8a9bc, #777a93);
    /* box-shadow: 0 34px 45px rgba(47, 49, 67, .28); */
    transform: rotateX(8deg) rotateY(-8deg);
    z-index: 2;

    

    clip-path: polygon(    
        0 0,
        16.8px 0,
        96px 28.8px,
        175.2px 0,
        100% 0,
        100% 100%,
        0 100%
    );
}

.boxbefore {
    content: "";
    position: absolute;
    /* left: 18px; */
    /* top: -34px; */
    translate: 0 calc(-66.4px);
    width: 163.2px;
    height: 56px;
    background: linear-gradient(145deg, #c5c6d4, #8f91a7);
    transform: rotateX(8deg) rotateY(-8deg);
    clip-path: polygon(0 50%, 50% 0, 100% 50%, 50% 100%);
    filter: drop-shadow(0 6.4px 12px rgba(44,46,61,.16));
    z-index: 0;
}

.boxshadow{
    position: absolute;
    width: 192px;
    height: 136px;
    border-radius: 11.2px;
    box-shadow: 0 27.2px 36px rgba(47, 49, 67, .28);
    transform: rotateX(8deg) rotateY(-8deg);
}

.box::after {
    content: "☘";
    position: absolute;
    inset: 0;
    translate: 0 0.8rem;
    display: grid;
    place-items: center;
    font-size: 4.4rem;
    color: rgba(255,255,255,.42);
    text-shadow: 0 2px 0 rgba(255,255,255,.2);
}

.page-card {
    position: absolute;
    width: 120px;
    height: 148px;
    top: 14.4px;
    left: 50%;
    transform: translateX(-50%) rotate(12deg);
    border-radius: 9.6px;
    background: linear-gradient(145deg, #d1d2df, #a2a4b8);
    box-shadow: 0 14.4px 24px rgba(46,48,66,.24);
    z-index: 1;
}

.page-card::before {
    content: "";
    position: absolute;
    left: 50%;
    transform: translate(-50%, -50%);
    top: 50%;
    width: 57.6px;
    height: 70.4px;
    border: 3.2px dotted rgba(55,57,76,.72);
    border-radius: 4.8px;
    /* clip-path: polygon(0 0, 70% 0, 100% 24%, 100% 100%, 0 100%); */
}

.cube {
    position: absolute;
    border-radius: 3px;
    
    background: #c9cad7c5;
    /* background: linear-gradient(145deg, #c9cad7, #85889f); */

    
    transform: rotate(30deg);
    box-shadow: 0 6.4px 12.8px rgba(48,49,68,.2);


    box-sizing: border-box;

    --s: 4px;  /* control the size of the wave */
    --w: 26.4px; /* preferred  width */
  
    width: round(var(--w),4*var(--s)); 
    aspect-ratio: 1;
    padding: var(--s);
    border: var(--s) solid #0000;
    
    border-radius: calc(3.5*var(--s)); /* for the image */
    mask: 
        radial-gradient(calc(sqrt(2)*var(--s)),#000 calc(100% - 1px),#0000),
        conic-gradient(#000 0 0) content-box,
        radial-gradient(calc(sqrt(2)*var(--s)),#0000 100%,#000 calc(100% + 1px)) 
        var(--s) var(--s) padding-box;
    mask-size: calc(var(--s)*4) calc(var(--s)*4);
}

a{
    text-decoration: none;
    color: unset;
    user-select: none;
}

.cube.one { 
    left: 5%; top: 25%;  
    transform: rotate(-25deg);
}
.cube.two { 
    right: 8%; top: 18%; 
    transform: rotate(30deg);
}
.cube.three { 
    right: 2%; top: 54%; 
    transform: rotate(-30deg);

}


@media( width < 499px){
    .card{
        grid-template-columns: 1fr;
        grid-template-areas: "top bottom";
        gap: 0px;
    }

    .card > :first-child {
        margin-top: -0.8rem;
        grid-row: 2;
    }

    .card > :last-child {
        grid-row: 1;
    }

    .error-code{
        display: none;
        font-size: 75.2px;
    }
}