/* Import Inter font family from Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@100..900&display=swap');

/* Overall Styling */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Inter", sans-serif;
}

/* Custom CSS Variables */
:root {
    --bg-main-color: white;
    --text-main-color: black;
    --footer-color: black;
    --custom-green: #5d9c69;
    --d: 2500ms;
    --angle: 90deg;
    --gradX: 100%;
    --gradY: 50%;
}

/* Body Styling */
body {
    min-height: 100vh;
    background: rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

/* Start Navigation Bar Styling */
nav {
    position: fixed;
    top: 0;
    z-index: 100;
    display: flex;
    width: 100%;
    height: 5rem;
    justify-content: space-between;
    align-items: center;
    padding: 1rem calc((100vw - 1300px) / 2);
    box-shadow: 0 0 .3rem rgba(0, 0, 0, .2);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    user-select: none;
}

/* TOM Text Styling */
.logo {
    font-size: 1.5rem;
    font-weight: 500;
    color: var(--text-main-color);
    text-decoration: none;
    transition: .2s ease;
    user-select: none;
}

.logo:hover {
    color: var(--custom-green); /* Title text turns green on hover */
}

/* Menu Styling */
.top-menu {
    position: relative;
    margin: 0 .3rem;
    padding: .6rem .9rem;
    border-radius: 20px;
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-main-color);
    text-decoration: none;
    transition: background-color 0.2s ease, color 0.3s;
    user-select: none;
}

.top-menu:hover {
    background-color: rgba(220, 220, 220, 0.5);
}

.top-menu.active {
    background: var(--custom-green); /* Active green button */
    color: var(--bg-main-color); /* White text */
    transition: box-shadow .2s ease; 
}

.top-menu.active:hover {
    box-shadow: 0 0 .3rem var(--custom-green); /* Green box shadow on button of active page when active */
}

.icon {
    display: none; /* Keep icon hidden when wide screen */
    color: white;
    transition: 0.25s;
    background: var(--nav-bar-color);
}

.icon:hover {
    color: black;
    background: var(--nav-bar-color);
}
/* End Navigation Bar Styling */

/* Start Footer Styling */
footer {
    position: fixed;
    z-index: 100;
    bottom: 0;
    display: flex;
    flex-direction: column;
    padding: .4rem 0 .6rem;
    width: 100%;
    align-items: center;
    justify-content: center;
    text-align: center;
    background-color: var(--footer-color);
    color: var(--bg-main-color);
    user-select: none;
}

/* Footer Link Styling */
footer a {
    display: flex;
    margin-bottom: .2rem;
    width: 3rem;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    color: var(--bg-main-color);
    text-decoration: none;
}

/* Footer Github Icon Styling */
footer .github {
    width: 3rem;
    height: 3rem;
    fill: var(--bg-main-color);
    transition: 0.1s;
}

footer .github:hover {
    fill: var(--custom-green);
}

footer p {
    font-size: 0.75rem;
    margin: 0;
    background-color: transparent;
}
/* End Footer Styling */

/* Start Home Styling */
/* Left hidden */
.hidden {
    opacity: 0;
    filter: blur(5px);
    transform: translateX(-100%);
    transition: all 1s;
}

/* Left shown */
.show {
    opacity: 1;
    filter: blur(0);
    transform: translateX(0);
}

/* Right hidden */
.hidden-tom {
    opacity: 0;
    filter: blur(5px);
    transform: translateX(100%);
    transition: transform 1s;
}

/* Right shown */
.show-tom {
    opacity: 1;
    filter: blur(0);
    transform: translateX(0);
}

.effect:nth-child(2) {
    transition-delay: 360ms; /* Transition delay */
}

.tom-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    height: 85vh;
    padding: 0rem calc((100vw - 1300px) / 2);
}

.column-left {
    display: flex;
    flex-direction: column;
    padding-left: 5rem;
    height: 49rem;
    align-items: flex-start;
    justify-content: center;
}

.column-left h1 {
    font-weight: 700;
    margin-bottom: 1rem;
    font-size: 3.5rem;
    color: var(--custom-green);
}

.column-left .caption {
    margin-bottom: 2rem;
    font-size: 1.4rem;
    color: var(--text-main-color);
}

.column-right {
    display: flex;
    flex-direction: column;
    padding-right: 5rem;
    height: 53rem;
    align-items: flex-start;
    justify-content: center;
}

.tom-button {
    position: relative;
    display: flex;
    flex-direction: row;
    padding: 1rem 2rem;
    width: 20rem;
    height: 4rem;
    align-items: center;
    justify-content: center;
    border-radius: 50px;
    border: none;
    box-shadow: 0 0 .5rem var(--custom-green);
    background: var(--custom-green);
    text-decoration: none;
    --offset: 30px;
    overflow: hidden;
    cursor: pointer;
    transition: .2s;
    user-select: none;
    margin-top: 0.4rem;
}

.tom-button:hover {
    box-shadow: 0 0 .3rem black;
    background: black;
}

.tom-button-icon {
    position: absolute;
    left: 1rem;
    width: 2rem;
    height: 2rem;
    fill: var(--bg-main-color);
}

.tom-button p {
    position: absolute;
    left: 3.5rem;
    font-size: 1.2rem;
    font-weight: 500;
    color: var(--bg-main-color);
}

.column-right a {
    margin-left: 8rem;
    width: 27rem;
}

.column-right .tom-image {
    width: 100%;
    height: auto;
    user-select: none;
    transition: scale .3s ease;
}

.column-right .tom-image:hover {
    scale: 1.1;
}

/* End Home Styling */

/* Start Animation Styling */
.exit {
    filter: blur(5px);
    opacity: 0;
    transform: translateY(100%);
    transition: all 1s ease-in-out
}

@property --angle {
    syntax: '<angle>';
    initial-value: 90deg;
    inherits: true;
}

@keyframes rotate {
    from {
        transform: translate(-50%, -50%) scale(1.9) rotate(0turn);
    }

    to {
        transform: translate(-50%, -50%) scale(1.9) rotate(1turn);
    }
}

@media(prefers-reduced-motion) {
    .hidden {
        transition: none;
    }
}
/*  End Animation Styling */

/* Start Responsiveness Styling */
@media screen and (max-width: 768px) {
    .tom-container {
        grid-template-columns: 1fr;
    }

    .column-right {
        height: 12rem;
    }
}

/* Collapsed menu visible once screen width under 1182px */
@media screen and (max-width: 1182px) { 
    body {
        overflow: scroll;
    }
    
    nav {
        flex-direction: row;
        align-items: flex-start;
        background: var(--nav-bar-color);
    }

    .logo {
        margin: 0.75rem 0rem 0rem 1rem;
    }

    .top-menu {
        display: none; 
    }

    .icon {
        display: block;
        float: right;
        padding: 14px 16px;
        background: var(--nav-bar-color);
        border-radius: 50%;
        color: black;
    }

    .icon:hover {
        background: rgb(186, 186, 186);
    }

    .nav-items.responsive .top-menu {
        display: block;
        background-color: var(--bg-main-color);
        margin: 1rem;
    }

    .nav-items.responsive {
        position: relative;
        background-color: white;
        color: black;
        z-index: 1;
        border-radius: 15px;
        box-shadow: 0px 8px 16px rgba(28, 28, 28, 0.288);
        position: absolute;
        right: 0; 
        top: 60px; 
        width: auto;
        border: 2px solid var(--custom-green);
    }

    .nav-items.responsive a {
        float: none;
        color: black;
        padding: 12px 16px;
        text-decoration: none;
        display: block;
        text-align: left;
        background-color: var(--bg-main-color);
    }

    .nav-items.responsive a:hover {
        background-color: var(--custom-green);
        color: white;
    }

    .nav-items.responsive {
        display: block;
    }
}
/* End Responsiveness Styling */