:root {
    --primary: #b6895b;
    --bg: #010101;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    outline: none;
    border: none;
    text-decoration: none;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', sans-serif;
    background-color: var(--bg);
    color: #fff;
    overflow-x: hidden;
}

/* Navbar */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.4rem 7%;
    background-color: rgba(1, 1, 1, .8);
    border-bottom: 1px solid #513c28;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 9999;
}

.navbar .navbar-logo {
    font-size: 2rem;
    font-weight: 700;
    color: #fff;
    font-style: italic;
}

.navbar .navbar-logo span {
    color: var(--primary);
}

.navbar .navbar-nav a {
    color: #fff;
    display: inline-block;
    font-size: 1.3rem;
    margin: 0 1rem;
}

.navbar .navbar-nav a:hover {
    color: var(--primary);
}

.navbar .navbar-nav a::after {
    content: '';
    display: block;
    padding-bottom: .5rem;
    border-bottom: .1rem solid var(--primary);
    transform: scaleX(0);
    transition: .2s linear;
}

.navbar .navbar-nav a:hover::after {
    transform: scaleX(0.5);
}

.navbar .navbar-extra a {
    color: #fff;
    margin: 0 .5rem;
}

.navbar .navbar-extra a:hover {
    color: var(--primary);
}

#hamburger-menu {
    display: none;
}

/* Search Form */
.navbar .search-form {
    position: absolute;
    top: 115%;
    right: 7%;
    background-color: #fff;
    width: 50rem;
    height: 5rem;
    display: flex;
    border-radius: 20px;
    overflow: hidden;
    align-items: center;
    transform: scaleY(0);
    transform-origin: top;
    transition: .3s;
}

.navbar .search-form.active {
    transform: scaleY(1);
}

.navbar .search-form input {
    width: 100%;
    height: 100%;
    font-size: 1.2rem;
    color: var(--bg);
    padding: 1rem;
}

.navbar .search-form label {
    font-size: 2rem;
    margin-right: 2rem;
    color: var(--bg);
    cursor: pointer;
}

/* Shopping Cart */
#shopping-cart-button {
    position: relative;
}

#shopping-cart-button .quantity-badge {
    display: inline-block;
    top: 0;
    right: -10px;
    background-color: red;
    color: #fff;
    border-radius: 50%;
    padding: 1px 5px;
    font-size: .8rem;
    position: absolute;
}

.shopping-cart {
    position: absolute;
    top: 100%;
    right: -100%;
    background-color: #fff;
    color: var(--bg);
    width: 35rem;
    height: 100vh;
    padding: 0 1.5rem;
    overflow-y: auto;
    max-height: 627px;
    border-radius: 0 0 0 10px;
    transition: .3s;
}

.shopping-cart.active {
    right: 0;
}

.shopping-cart .cart-item {
    margin: 2rem 0;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #666;
    position: relative;
}


.shopping-cart img {
    height: 4rem;
    border-radius: 50%;
}

.shopping-cart h3 {
    font-size: 1.4rem;
}

.shopping-cart .item-price {
    font-size: 1.2rem;
}

.shopping-cart .cart-item #remove-product,
.shopping-cart .cart-item #add-product {
    display: inline-block;
    padding: 2px 5px;
    cursor: pointer;
    margin: 0 8px;
    background-color: black;
    color: white;
    font-weight: bold;
    font-size: 1.1rem;
}

.shopping-cart h4 {
    text-align: center;
    margin-top: 2rem;
    font-size: 1.6rem;
}

/* Form Checkout */
.form-container {
    width: 100%;
    display: flex;
    justify-content: center;
    border-top: 1px dashed black;
    margin-top: 2rem;
    padding: 1rem;
}

.form-container h5 {
    font-size: 1.4rem;
    margin-bottom: 1rem;
    text-align: center;
}

.form-container form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    width: 100%;
}

.form-container form label {
    display: flex;
    flex-direction: column;
}

.form-container form label span {
    font-size: 1.2rem;
    margin-bottom: .5rem;
}

.form-container form input {
    padding: .5rem;
    border: 1px solid black;
    border-radius: 5px;
    font-size: 1.2rem;
}

.form-container .checkoutBtn {
    padding: .5rem;
    border: 1px solid black;
    border-radius: 5px;
    font-size: 1.2rem;
    background-color: black;
    color: white;
    cursor: pointer;
    transition: .3s;
}

.form-container .checkoutBtn.disabled {
    opacity: .5;
    cursor: not-allowed;
}

.form-container .checkoutBtn:not(.disabled):hover {
    background-color: var(--primary);
    color: white;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    background-image: url('../img/kopi.jpg');
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    position: relative;
    mask-image: linear-gradient(rgba(0, 0, 0, 1) 90%, rgba(0, 0, 0, 0));
}

/* .hero::after {
    content: '';
    display: block;
    position: absolute;
    width: 100%;
    height: 30%;
    bottom: 0;
    background: linear-gradient(0deg, rgba(1, 1, 3, 1) 8%, rgba(255, 255, 255, 0) 50%);
} */

.hero .content {
    padding: 1.4rem 5%;
    max-width: 60rem;
    position: fixed;
    animation: fadeInSlideUp 1s ease-out forwards;
}

@keyframes fadeInSlideUp {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero .content h1 {
    font-size: 5em;
    color: #fff;
    text-shadow: 1px 1px 3px rgba(1, 1, 3, .5);
    line-height: 1.2;
}

.hero .content h1 span {
    color: var(--primary);
}

.hero .content p {
    font-size: 1.6rem;
    margin-top: 1rem;
    line-height: 1.4;
    font-weight: 100;
    text-shadow: 1px 1px 3px rgba(1, 1, 3, .5);
}

.hero .content .cta {
    margin-top: 1rem;
    display: inline-block;
    padding: 1rem 3rem;
    font-size: 1.4rem;
    color: #fff;
    background-color: var(--primary);
    border-radius: .5rem;
    box-shadow: 1px 1px 3px rgba(1, 1, 3, .5);
}

/* About Section */
.about,
.menu,
.products,
.contact {
    padding: 8rem 7% 1.4rem;
}

.about h2,
.menu h2,
.products h2,
.contact h2 {
    display: block;
    text-align: center;
    font-size: 2.6rem;
    margin-bottom: 3rem;
}

.about h2 span,
.menu h2 span,
.products h2 span,
.contact h2 span {
    color: var(--primary);
}

.about .row {
    display: flex;
}

.about .row .about-img {
    flex: 1 1 45rem;
}

.about .row .about-img img {
    width: 100%;
    border-radius: 20px;
    animation: revealing;
    animation-timeline: view(block);
    animation-range: cover 0% cover 50%;
    margin: 0px;
}

@keyframes revealing {
    from {
        margin-left: 100vw;
        filter: blur(50px);
        opacity: 0.5;
    }

    to {
        margin: 0px;
        filter: blur(0px);
        opacity: 1;
    }
}

.about .row .content {
    flex: 1 1 35rem;
    padding: 0 1rem;
}

.about .row .content h3 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    animation: text-reveal linear forwards;
    animation-timeline: view();
    animation-range: entry 0% cover 50%;
}

@keyframes text-reveal {
    from {
        transform: translateY(100%);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.about .row .content p {
    margin-bottom: 0.8rem;
    font-size: 1.4rem;
    font-weight: 100;
    line-height: 1.6;
    animation: text-reveal linear forwards;
    animation-timeline: view();
    animation-range: entry 0% cover 50%;
}

/* Menu Section */
.menu h2,
.products h2,
.contact h2 {
    margin-bottom: 1rem;
}

.menu p,
.products p,
.contact p {
    display: block;
    text-align: center;
    max-width: 30rem;
    margin: auto;
    font-weight: 100;
    line-height: 1.6;
}

.menu .row {
    display: flex;
    flex-wrap: wrap;
    margin-top: 5rem;
    justify-content: center;
}

.menu .row .menu-card {
    text-align: center;
    padding-bottom: 4rem;
}

.menu .row .menu-card img {
    border-radius: 50%;
    width: 80%;
}

.menu .row .menu-card .menu-card-title {
    margin: 1rem auto .5rem;
}

/* Products Section */
.products .row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(30rem, 1fr));
    gap: 1.5rem;
    margin-top: 4rem;
}

.products .product-card {
    text-align: center;
    border: 1px solid #666;
    padding: 2rem;
}

.products .product-icons a {
    width: 4rem;
    height: 4rem;
    color: #fff;
    margin: 1rem;
    border: 1px solid #666;
    background-color: var(--primary);
    border-radius: 50%;
    display: inline-flex;
    justify-content: center;
    align-items: center;

}

.products .product-icons a:hover {
    transform: scale(1.05);
    transition: .2s ease-in-out;
    color: #666;
    background-color: #fff;
    border-color: var(--primary);
}

.products .product-image img {
    height: 25rem;
}

.products .product-content h3 {
    font-size: 2rem;
    margin: 1rem 0 0.5rem;
}

.products .product-star {
    font-size: 1.7rem;
    padding: 1rem;
    color: var(--primary);
}

.products .product-star .star-full {
    fill: var(--primary);
}

.products .product-price {
    font-size: 1.6rem;
    font-weight: bold;
}

/* Contact Section */
.contact .row {
    display: flex;
    margin-top: 2rem;
    background-color: #222;
}

.contact .row .map {
    flex: 1 1 45rem;
    width: 100%;
    object-fit: cover;
}

.contact .row form {
    flex: 1 1 45rem;
    padding: 5rem 2rem;
    text-align: center;
}

.contact .row form .input-group {
    display: flex;
    align-items: center;
    margin-top: 2rem;
    background-color: var(--bg);
    border: 1px solid #eee;
    padding-left: 2rem;
}

.contact .row form .input-group input {
    width: 100%;
    padding: 2rem;
    font-size: 1.7rem;
    background: none;
    color: #fff;
}

.contact .row form .btn {
    margin-top: 3rem;
    display: inline-block;
    padding: 1rem 3rem;
    font-size: 1.7rem;
    color: #fff;
    background-color: var(--primary);
    cursor: pointer;
}

/* Footer */
footer {
    background-color: rgb(80, 63, 42);
    text-align: center;
    padding: 1rem 0 1rem;
    margin-top: 3rem;
}

footer .socials {
    padding: 1rem 0;
}

footer .socials a {
    color: #fff;
    margin: 1rem;
}

footer .socials a:hover,
footer .links a:hover {
    color: var(--bg);
}

footer .links {
    margin-bottom: 1.4rem;
}

footer .links a {
    color: #fff;
    padding: .7rem 1rem;
}

footer .credit {
    font-size: 0.8rem;
}

footer .credit a {
    color: var(--bg);
    font-weight: 700;
}

/* Modal Box */
/* Item Detail */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, .7);
    display: none;
    z-index: 10000;
    animation: animatemodal .4s;
}

.modal-container {
    margin: 15% auto;
    background-color: #fefefe;
    color: var(--bg);
    padding: 1.2rem;
    width: 80%;
    position: relative;
    border: 1px solid #666;
    border-radius: 10px;
}

/* Modal Animation */
@keyframes animatemodal {
    from {
        top: -300px;
        opacity: 0;
    }

    to {
        top: 0;
        opacity: 1;
    }
}


.modal-container .modal-close-btn {
    position: absolute;
    top: .5rem;
    right: 1.2rem;
    font-size: 2rem;
    color: var(--bg);
    cursor: pointer;
}

.modal-container .modal-close-btn:hover {
    color: red;
}

.modal-content {
    display: flex;
    flex-wrap: nowrap;
    gap: 2rem;
}

.modal-content img {
    height: 23rem;
    margin-bottom: 2rem;
    margin-right: 2rem;
}

.modal-content .product-price {
    font-size: 1.3rem;
}

.modal-content .product-price span {
    text-decoration: line-through;
    font-size: 1rem;
}

.modal-container h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.modal-container p {
    font-size: 1.4rem;
    margin-top: 1.2rem;
    margin-bottom: 1rem;
    line-height: 1.6rem;
}

.modal-content a {
    display: flex;
    gap: 1rem;
    width: 12rem;
    background-color: var(--primary);
    color: #fff;
    margin-top: 1rem;
    padding: 1rem 1.5rem;
}


/* Media Query */
/* Laptop */
@media (max-width: 1366px) {
    html {
        font-size: 75%;
    }
}

/* Tablet */
@media (max-width: 802px) {
    html {
        font-size: 62.5%;
    }

    #hamburger-menu {
        display: inline-block;
    }

    .navbar .navbar-nav {
        position: absolute;
        top: 100%;
        right: -100%;
        background-color: #fff;
        width: 30rem;
        height: 100vh;
        transition: .3s;
    }

    .navbar .navbar-nav.active {
        right: 0;
    }

    .navbar .navbar-nav a {
        color: var(--bg);
        display: block;
        margin: 1.5rem;
        padding: .5rem;
        font-size: 2rem;
    }

    .navbar .navbar-nav a::after {
        transform-origin: 0 0;
    }

    .navbar .navbar-nav a:hover::after {
        transform: scaleX(.2);
    }

    .navbar .search-form {
        width: 90%;
        right: 2rem;
    }

    .about .row {
        flex-wrap: wrap;
    }

    .about .row .about-img img {
        height: 24rem;
        object-fit: cover;
        object-position: center;
    }

    .about .row .content {
        padding: 0;
    }

    .about .row .content h3 {
        margin-top: 1rem;
        font-size: 2rem;
    }

    .menu p {
        font-size: 1.2rem;
    }

    .contact .row {
        flex-wrap: wrap;
    }

    .contact .row .map {
        height: 30rem;
    }

    .contact .row form {
        padding-top: 0;
    }

    .modal-content {
        flex-wrap: wrap;
        justify-content: center;
    }
}

/* Mobile */
@media (max-width: 450px) {
    html {
        font-size: 55%;
    }
}