:root {
    --card-height: 300px;
    --card-width: 300px;

    --accent-dark: #2c1010;

    --accent-primary: #461111;
    --accent-secondary: #A13333;
    --accent-tertiary: #B3541E;

    --form-input-bg: var(--accent-secondary);

    --image-tint: #b3551e31;

    --dot: var(--accent-primary);
    --dot-active: var(--text-default);

    --text-carousel: var(--accent-primary);

    --text-default: #e3bfaa;
    --text-hover: #cba28a;
    --text-bright: #f5e3d9;
    --text-faint: #ac9181;

    --text-link: #c1774d;
    --text-link-hover: #B3541E;
}

::selection {
    color: var(--accent-dark);
    background-color: var(--accent-tertiary);
}

a:link, a:visited {
    text-decoration: underline;
    color: var(--text-link);
}

a:hover {
    color: var(--text-link-hover);
}

a:link.no-decoration, a:visited.no-decoration, a:hover.no-decoration, a:active.no-decoration {
    text-decoration: none;
    color: var(--text-default);
}



body {
    margin: 0;

    font-family: "Kanit", sans-serif;
    font-weight: 300;
    font-style: normal;

    background-color: var(--accent-dark);
    color: var(--text-default);
}

h1 {
    font-family: "Kanit", sans-serif;
    font-weight: 900;
    font-style: normal;
    font-size: 4em;
}

h2 {
    font-family: "Kanit", sans-serif;
    font-weight: 800;
    font-style: normal;
    font-size: 3em;
}

h3 {
    font-family: "Kanit", sans-serif;
    font-weight: 700;
    font-style: normal;
    font-size: 2em;
}

.header h3 {
    font-size: 1.5em;
}

h1, h2, h3, h4, h5, h6 {
    text-align: center;
    margin: 0;
}

p {
    font-size: 1.1em;
}

@media only screen and (max-width: 600px) {
    h1 {
        font-size: 3em;
    }

    h2 {
        font-size: 2em;
    }

    h3 {
        font-size: 1em;
    }

    .header h2 {
        font-size: 1.25em;
    }


    .header h3 {
        font-size: 0.75em;
    }
}

hr {
    border-top: 3px solid var(--text-default);
    margin-top: 5px;
}

/* width */
::-webkit-scrollbar {
    width: 15px;
}

/* Track */
::-webkit-scrollbar-track {
    box-shadow: inset 0 0 5px var(--accent-dark);
}

/* Handle */
::-webkit-scrollbar-thumb {
    background: var(--accent-secondary);
}

/* Handle on hover */
::-webkit-scrollbar-thumb:hover {
    background: var(--accent-tertiary);
}

.filler {
    height: 100vh;
    width: 100vw;
}

.header {
    position: sticky;
    top: 0;
    z-index: 100;
    overflow: hidden;
    height: 15vh;

    -webkit-user-select: none;
    -ms-user-select: none;
    user-select: none;

    background: var(--accent-secondary);

    border-bottom: 4px solid var(--accent-primary);
}

.header .title-container {
    position: absolute;
    top: 0;
    width: 100%;
    height: 100%;
    
    display: flex;
    align-items: center;
    justify-content: center;
}

.header .title {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    width: 20vw;

    background: var(--accent-tertiary);

    position: relative;
    
    cursor: pointer;
}

.header a {
    height: 100%;
    align-self: center;
    display: flex;
    align-items: center;
}

.header .title::before {
    content: "";
    opacity: 1;

    position: absolute;
    left: 0;
    top: 0;
    z-index: -1;

    width: 0px;
    height: 0px;
    border-style: solid;
    border-width: 0 15vh 15vh 0;
    border-color: transparent var(--accent-tertiary) transparent transparent;
    transform: translateX(-100%) rotate(0deg);
}

.header .title::after {
    content: "";
    opacity: 1;

    position: absolute;
    right: 0;
    top: 0;
    z-index: -1;

    width: 0px;
    height: 0px;
    border-style: solid;
    border-width: 15vh 15vh 0 0;
    border-color: var(--accent-tertiary) transparent transparent transparent;
    transform: translateX(100%) rotate(0deg);
}

@media only screen and (max-width: 600px) {
    .header .title::before {
        border-width: 0 15vw 20vh 0;
    }

    .header .title::after {
        border-width: 20vh 15vw 0 0;
    }
}

.header .container {
    position: absolute;
    width: 25vw;
    height: 100%;

    display: flex;
    align-items: center;
    justify-content: space-around;
}

.header .container.left {
    left: 0;
}

.header .container.right {
    right: 0;
}

@media only screen and (max-width: 600px) {
    .header .container {
        flex-direction: column;
    }
}

.header .nav-option {
    position: relative;
    cursor: pointer;
    z-index: 2;
    max-width: 15vw;
    text-align: center;
}

.header .nav-option:hover {
    color: var(--text-hover);
}

.carousel.container {
    position: relative;
    overflow: hidden;
    display: grid;
    grid-template-columns: 1fr;
    grid-template-rows: 1fr;
    cursor: pointer;
}

.carousel.container .see-more {
    position: absolute;
    bottom: 50%;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.carousel-item {
    grid-column: 1;
    grid-row: 1;
    width: 100vw;
    height: 75vh;
    transform-style: preserve-3d;
    transition: transform 1.5s cubic-bezier(0.05, 0.5, 0, 1);
    will-change: transform;
    background-color: #461111;
    overflow: hidden;
}

.carousel-item .see-more {
    position: absolute;
    top: 0%;
    right: 0%;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.see-more button {
    z-index: 3;

    --s: 15px;  /* size of the frame */
    --b: 3px;   /* border thickness */
    --w: 200px; 
    --c: var(--text-carousel);
    color: var(--text-carousel);

    padding: calc(var(--s));
    --_g: var(--c) var(--b),#0000 0 calc(100% - var(--b)), var(--c) 0;
    background:
      linear-gradient(      var(--_g)) 50%/100% var(--_i,100%) no-repeat,
      linear-gradient(90deg,var(--_g)) 50%/var(--_i,100%) 100% no-repeat;
    outline: calc(var(--w)/2) solid rgba(0, 0, 0, 0);
    outline-offset: calc(var(--w)/-2 - 2*var(--s));
    transition: .4s;
    cursor: pointer;
}

@media only screen and (max-width: 600px) {
    .see-more button {
        --w: 300px;
        font-size: 3em;
    }
}

.see-more button:hover {
    outline: var(--b) solid var(--text-default);
    outline-offset: calc(var(--s)/-2);
    --_i: calc(100% - 2*var(--s));
    color: var(--text-default);
}

.carousel-item .see-more button:hover {
    color: #040303;
}

.carousel-item.active {} /* For setting any properties about the currently active carousel item */

.carousel-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    /* object-fit: contain; */
    filter: sepia(30%) saturate(70%);
}

.carousel .nav-dots {
    display: flex;
    justify-content: center;
    align-items: center;
    position: absolute;
    bottom: 30px;
    height: 30px;
    width: 100%;
}

.dot {
    height: 25px;
    width: 25px;
    background-color: var(--dot);
    border-radius: 50%;
    display: inline-block;
    transition: background-color 0.3s ease;
    margin: 15px;
    z-index: 2;

    cursor: pointer;
}

.dot.active {
    background-color: var(--dot-active);
    cursor: default;
}

.carousel .nav-arrows {
    position: absolute;
    display: flex;
    top: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.carousel .nav-arrows button {
    width: 50%;
    height: 100%;
    background-color: #00000000;
}

.carousel .nav-arrows button:hover {}

.project.container {
    width: 100%;

    display: flex;
    align-items: center;
    justify-content: space-around;
    flex-wrap: wrap;

    padding-top: 40px;
    padding-bottom: 40px;

    background-color: var(--accent-primary);
}

.divider {
    min-height: 10vh;
    width: 100%;

    display: flex;
    align-items: center;
    justify-content: center;

    background-color: var(--accent-secondary);
}

.simple-card {
    position: relative;
    width: 25vw;
    height: 500px;

    margin: 20px;
}

@media only screen and (max-width: 600px) {
    .simple-card {
        width: 80vw;
    }
}

.simple-card .wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #0000003d;
    border-radius: 10px;
}

.simple-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: sepia(30%) saturate(70%) opacity(80%);
    transition: filter 0.5s;
    border-radius: 10px;
}

.simple-card:hover img {
    filter: sepia(30%) saturate(40%) opacity(60%);
}

.simple-card:hover button {
    outline: var(--b) solid var(--text-default);
    outline-offset: calc(var(--s)/-2);
    --_i: calc(100% - 2*var(--s));
    color: var(--text-default);
    background-color: var(--accent-primary);
}

.simple-card .content {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    align-items: center;

    transition: transform 0.5s;
}

.simple-card .title {
    color: var(--accent-secondary);
    transition: color 0.5s;
}

.simple-card:hover .title {
    color: var(--text-bright);
}

.simple-card .title h2 {
    text-align: center;
}

.simple-card:hover .content {
    transform: translateY(-10px);
}

button {
    border: 0;
    outline: 0;

    color: var(--text-default);

    font-family: "Kanit", sans-serif;
    font-weight: 400;
    font-style: normal;
    font-size: 2em;

    cursor: pointer;

    background-color: var(--accent-secondary);
}

button:hover {
    background-color: var(--accent-primary);
}

.showcase button {
    padding: 35px;
    border-radius: 10px;
    font-size: 3em;
}

.showcase {
    position: relative;
    overflow: hidden;
    height: 100vh;
    width: 100%;

    display: flex;
    align-items: center;
    justify-content: center;

    background-attachment: fixed;
    background-position: top;
    background-repeat: no-repeat;
    background-size: cover;

    opacity: 80%;
}

.background {
    height: 70vh;
    position: relative;

    display: flex;
    align-items: center;
    justify-content: center;
}

.background h2 {
    z-index: 1;
    font-family: "Kanit", sans-serif;
    font-weight: 600;
    font-style: normal;
    font-size: 4em;
}

.background img {
    position: absolute;
    top: 0;
    left: 0;

    object-fit: cover;
    width: 100%;
    height: 100%;
    filter: sepia(70%) saturate(60%) opacity(60%);
}

.gallery {
    background-color: var(--accent-primary);

    padding-top: 5vh;
    padding-bottom: 10vh;

    display: flex;
    justify-content: space-around;
    align-items: center;
    flex-wrap: wrap;
}

.gallery > img {
    width: 25vw;
    height: 100%;
    margin: 20px;
    object-fit: cover;
    border-radius: 10px;
}

@media only screen and (max-width: 600px) {
    .gallery > img {
        width: 80vw;
    }
}

.contact {
    display: flex;
    margin-bottom: 20vh;
}

@media only screen and (max-width: 600px) {
    .contact {
        flex-direction: column;
    }
}

.contact > * {
    margin: 20px;
}

.contact-form {
    flex: 50%;
    display: flex;
    flex-direction: column;
}

.contact-form h2 {
    align-self: center;
}

.contact-info-text {
    flex: 50%;
}

label {
    font-family: "Kanit", sans-serif;
    font-weight: 600;
    font-style: normal;

    font-size: 1.25em;
}

input, textarea {
    background-color: var(--form-input-bg);
    border: 2px solid var(--accent-secondary);
    color: var(--text-default);

    font-family: "Kanit", sans-serif;
    font-weight: 600;
    font-style: normal;
}

input[type=button], input[type=submit] {
    margin: 20px;
    padding-top: 10px;
    padding-bottom: 10px;
    font-size: 1.5em;
    cursor: pointer;
}

textarea {
    resize: none;
}

input:focus, textarea:focus {
    outline: 2px solid var(--accent-tertiary);
}

::placeholder {
    color: var(--text-faint);
}

.footer {
    background-color: var(--accent-tertiary);

    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.footer > .showcase {
    height: 85vh;
    background-image: url('./assets/general/homepage_footer.jpg');
}

.about-text {
    margin: 40px;
}

.about-text p {
    font-size: 1.2rem;
}

.underline-anim {
    overflow: hidden;
}

.underline-anim::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 0.1em;
    background-color: var(--text-hover);
    opacity: 0;
    transition: opacity 300ms, transform 300ms;
    transform: translate3d(-100%, 0.2em, 0);
}

.underline-anim:hover::after,
.underline-anim:focus::after {
  opacity: 1;
  transform: translate3d(0, 0.2em, 0);
}

.card {
    margin: 20px;
    display: grid;
    place-items: center;
    width: 80vw;
    max-width: 21.875rem;
    height: 28.125rem;
    overflow: hidden;
    box-shadow: 0.25rem 0.25rem 0.5rem rgba(0, 0, 0, 0.25);
    border-radius: 10px;
}

.card > * {
    grid-column: 1 / 2;
    grid-row: 1 / 2;
}

.card-background {
    object-fit: cover;
    max-width: 100%;
    height: 100%;
    filter: sepia(30%) saturate(70%);
}

.card-content {
    display: flex;
    flex-direction: column;

    justify-content: space-between;
    align-self: flex-end;
    height: 55%;
    width: 90%;
    padding: 12% 1.25rem 1.875rem;
    background: linear-gradient(180deg,
            hsla(0, 0%, 0%, 0) 0%,
            hsla(0, 0%, 0%, 0.3) 10%,
            hsl(0, 0%, 0%) 100%);
}

.card-title {
    position: relative;
    width: fit-content;
    width: -moz-fit-content;
}

.card-title::after {
    content: "";
    position: absolute;
    height: 0.3125rem;
    width: calc(100% + 1.25rem);
    bottom: calc((1.25rem - 0.5rem) * -1);
    left: -1.25rem;
    background-color: var(--accent-primary);
    opacity: 1;
    transform: scaleX(1);
    transform-origin: left;
}

.card-button {
    padding: 0.75em 1.6em;
    width: fit-content;
    width: -moz-fit-content;
    font-size: 1.125rem;
}

@media (any-hover: hover) and (any-pointer: fine) {
    .card-content {
        transform: translateY(62%);
        transition: transform 0.5s ease-out;
        transition-delay: 0.5s;
    }

    .card-title::after {
        opacity: 0;
        transform: scaleX(0);
        transition: opacity 0.3s ease-in, transform 0.5s ease-out;
        transition-delay: 0.5s;
        transform-origin: right;
    }

    .card-background {
        transition: transform 0.5s ease-in;
    }

    .card-content-container> :not(.card-title),
    .card-button {
        opacity: 0;
    }

    .card:hover,
    .card:focus-within {
        transition: transform 0.5s ease-in;
    }

    .card:hover .card-content,
    .card:focus-within .card-content {
        transform: translateY(0);
        transition: transform 0.5s ease-in;
    }

    .card:focus-within .card-content {
        transition-duration: 0ms;
    }

    .card:hover .card-background,
    .card:focus-within .card-background {
        transform: scale(1.3);
    }

    .card:hover .card-content-container > :not(.card-title),
    .card:hover .card-button,
    .card:focus-within .card-content-container > :not(.card-title),
    .card:focus-within .card-button {
        opacity: 1;
        transition: 0.5s;
    }

    .card:hover .card-title::after,
    .card:focus-within .card-title::after {
        opacity: 1;
        transform: scaleX(1);
        transform-origin: left;
        transition: opacity 0.5s ease-in, transform 0.5s ease-in;
        transition-delay: 0.5s;
    }

    .card:hover .underline-anim,
    .card:focus .underline-anim {
        opacity: 1;
        transform: translate3d(0, 0.2em, 0);
    }
}

ul {
    margin: 0;
}

#to-top-button {
    position: fixed;
    bottom: 20px;
    right: 5vw;
    padding: 5px;
    display: none;
    border-radius: 10px;
}

#to-top-button:hover {
    background-color: var(--accent-tertiary);
}

.table-of-contents {
    padding: 40px;
    columns: 40vw 2;
    text-decoration: underline;

    font-size: 2em;
    background-color: var(--accent-primary);
}

.table-of-contents a {
    color: var(--text-default);
}

.column-3-list {
    columns: 20vw 3;
}


  
.slant-card {
    display: inline-block;
    width: 30vw;
    text-align: center;
    margin: 10px;
}

.slant-img-container {
    width: 24vw;
    border-radius: 0px 0px 20px 20px;
    display: inline-block;
}

@media only screen and (max-width: 600px) {
    .slant-card {
        width: 80vw;
    }

    .slant-img-container {
        width: 65vw;
    }
}


.slant-card .text-container {
    box-shadow: 0px 0px 10px 0px rgba(0, 0, 0, 0.2);
    padding: 120px 20px 20px 20px;
    border-radius: 20px;
    background: var(--accent-secondary);
    margin: -120px 0px 0px 0px;
    line-height: 19px;
    font-size: 14px;
}

.slant-card .text-container h3 {
    margin: 20px 0px 10px 0px;
    line-height: 1em;
    color: var(--text-bright);
}

@media only screen and (max-width: 600px) {

    .slant-card .text-container h3 {
        font-size: 2em;
    }
}



.project-navigation {
    display: flex;
    flex-wrap: wrap;
    width: 100%;
    justify-content: space-evenly;
    padding-top: 30px;
    padding-bottom: 30px;

    background-color: var(--accent-primary);
}

@media screen and (max-width: 760px) {
    .project-navigation {
        grid-template-columns: repeat(2, 1fr);
   }
}

.gloss-card {
    position: relative;
    z-index: 1;
    padding-bottom: 100%;
    perspective: 1000px;
    cursor: pointer;
}
.gloss-card-image {
    position: absolute;
    z-index: 1;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    background-image: linear-gradient(120deg, #f6d365 0%, #fda085 100%) ;
    filter: sepia(30%) saturate(70%);
    background-size: cover;
    background-position: center;
    perspective-origin: 50% 50%;
    transform-style: preserve-3d;
    transform-origin: top center;
    will-change: transform;
    transform: skewX(0.001deg);
    transition: transform 0.35s ease-in-out;
    display: flex;
    align-items: end;
    justify-content: center;
    color: var(--accent-dark);
    border-radius: 20px;
}
.gloss-card-image::after {
    display: block;
    content: '';
    position: absolute;
    z-index: 100;
    top: 0;
    left: 0;
    width: 100%;
    height: 120%;
    background: linear-gradient(226deg, rgba(255, 255, 255, 0.4) 0%, rgba(255, 255, 255, 0.4) 35%, rgba(255, 255, 255, 0.2) 42%, rgba(255, 255, 255, 0) 60%);
    transform: translateY(-20%);
    will-change: transform;
    transition: transform 0.65s cubic-bezier(0.18, 0.9, 0.58, 1);
    border-radius: 20px;
}
.gloss-card:hover .gloss-card-image {
    transform: rotateX(7deg) translateY(-6px);
}
.gloss-card:hover .gloss-card-image::after {
    transform: translateY(0%);
}
.gloss-card::before {
    display: block;
    content: '';
    position: absolute;
    top: 5%;
    left: 5%;
    width: 90%;
    height: 90%;
    background: rgba(0, 0, 0, 0.5);
    box-shadow: 0 6px 12px 12px rgba(0, 0, 0, 0.4);
    will-change: opacity;
    transform-origin: top center;
    transform: skewX(0.001deg);
    transition: transform 0.35s ease-in-out, opacity 0.5s ease-in-out;
    border-radius: 20px;
}
.gloss-card:hover::before {
    opacity: 0.6;
    transform: rotateX(7deg) translateY(-6px) scale(1.05);
}
