:root {
    --primary-color: #FFDB58;
    --primary-color-dark: #706007;
    --secondary-color: #FFD700;
    --background-color: #A9A9A9;
    --dark-background-color: #070706;
    --text-color: #ffffff;
    --danger-color: #ff4d4d;
    --sucess-color: #4CAF50;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

body {
    background-color: var(--text-color);
    color: #333;
    height: 100vh;
}

/* NAVBAR */
.nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0px 40px;
    background-color: var(--dark-background-color);
    backdrop-filter: blur(10px);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 100;
}

.logo {
    width: 150px;
    height: auto;
}

.logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.nav-center a {
    margin: 0 15px;
    text-decoration: none;
    text-transform: uppercase;
    font-size: 16px;
    color: #ffffff;
    font-weight: 500;
    opacity: 0.85;
}

.nav-center a:hover {
    opacity: 1;
    color: var(--secondary-color);
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

.nav-right a {
    margin-left: 30px;
}

.cart {
    font-size: 20px;
    color: var(--background-color);
    cursor: pointer;
    text-decoration: none;
}

.cart-badge {
    position: absolute;
    top: 55px;
    right: 30px;
    background-color: var(--danger-color);
    color: #fff;
    border-radius: 50%;
    padding: 2px 6px;
    font-size: 10px;
    font-weight: bold;
}

/* SEARCH */
.search-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.search-toggle {
    color: var(--background-color);
    font-size: 20px;
    cursor: pointer;
    text-decoration: none;
}

/* hidden by default */
.search-input {
    position: absolute;
    right: 35px;
    width: 0;
    opacity: 0;
    padding: 8px 0;
    border: none;
    border-radius: 6px;
    outline: none;
    background: #fff;
    color: #000;
    font-size: 14px;
    transition:
        width 0.3s ease,
        opacity 0.2s ease,
        padding 0.3s ease;
}

/* visible */
.search-wrapper.active .search-input {
    width: 220px;
    opacity: 1;
    padding: 8px 12px;
}

.burger {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
}

.burger span {
    width: 25px;
    height: 3px;
    background: var(--primary-color);
    border-radius: 2px;
    transition: 0.3s;
}

/* CART DRAWER */
.cart-drawer {
    position: fixed;
    top: 0;
    right: 0;
    width: 360px;
    height: 100vh;
    background: var(--dark-background-color);
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.4);
    transform: translateX(100%);
    transition: transform 0.4s ease;
    z-index: 1001;
    display: flex;
    flex-direction: column;
}

.cart-drawer.active {
    transform: translateX(0);
}

/* OVERLAY */
.cart-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    z-index: 1000;
}

.cart-overlay.active {
    opacity: 1;
    pointer-events: all;
}

/* CART CONTENT */
.cart-header {
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.cart-header h3 {
    font-size: 20px;
    color: var(--primary-color);
}

.close-cart {
    background: none;
    border: none;
    color: #fff;
    font-size: 22px;
    cursor: pointer;
}

.cart-body {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
}

.cart-footer {
    padding: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* HERO SECTION */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    padding: 0 40px;
    background: linear-gradient(to right, rgba(11, 15, 26, 0.5), rgba(11, 15, 26, 0.1)), url('../assets/landing.jpg') no-repeat center center/cover;
}

.hero-content {
    max-width: 600px;
}

.hero h1 {
    font-size: 56px;
    line-height: 1.1;
    color: var(--primary-color);
}

.hero p {
    margin: 20px 0 35px;
    font-size: 18px;
    opacity: 0.85;
    color: #fff;
}

/* BUTTONS */
.btn {
    padding: 14px 28px;
    border-radius: 10px;
    font-size: 16px;
    cursor: pointer;
    margin-right: 15px;
    border: none;
}

.btn.primary {
    background: var(--primary-color);
    color: #000;
    transition: transform 0.2s ease;
    animation: pop 2s infinite;
    text-decoration: none;
}

.btn.outline {
    background: transparent;
    border: 1px solid var(--primary-color);
    color: var(--primary-color);
}

/* CATEGORY */
.categories {
    padding: 50px 20px;
    background: var(--text-color);
    width: 90%;
    margin: auto;
}

.categories h2 {
    font-size: 20px;
    text-transform: uppercase;
    margin-bottom: 20px;
    color: var(--dark-background-color);
    margin-bottom: 20px;
}

.category-slider {
    display: flex;
    gap: 15px;
    overflow-x: auto;
    padding-bottom: 10px;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
    /* smooth scrolling */
}

.category-slider::-webkit-scrollbar {
    height: 3px;
    border-radius: 10px;
}

.category-slider::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

.category-card {
    flex: 0 0 auto;
    /* prevent shrinking */
    background: var(--background-color);
    color: var(--text-color);
    padding: 12px 25px;
    border-radius: 50px;
    text-decoration: none;
    /* capsule shape */
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.3s, background 0.3s;
    white-space: nowrap;
    /* prevent text wrap */
    scroll-snap-align: start;
}

.category-card:hover {
    background: var(--primary-color);
    color: #000;
    transform: scale(1.05);
}

@keyframes pop {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 rgba(0, 0, 0, 0);
    }

    50% {
        transform: scale(1.1);
        box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
    }

    100% {
        transform: scale(1);
        box-shadow: 0 0 0 rgba(0, 0, 0, 0);
    }
}

/* PRODUCTS */
.products {
    padding: 30px 20px;
    background: var(--text-color);
}

.products h2 {
    font-size: 28px;
    color: var(--dark-background-color);
    margin-bottom: 30px;
    text-align: center;
    text-transform: uppercase;
}

.product-grid {
    display: grid;
    gap: 25px;
    max-width: 90%;
    justify-content: center;
    margin: auto;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
}


/* ABOUT SECTION */
.about-section {
    padding: 80px 30px;
    margin-top: 100px;
    height: 100%;
    color: var(--dark-background-color);
}

.about-container {
    max-width: 90%;
    margin: auto;
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 50px;
    align-items: center;
}

.about-section h2 {
    font-size: 32px;
    color: #000;
    margin-bottom: 20px;
    text-transform: uppercase;
    text-align: center;
}

.about-section p {
    font-size: 16px;
    line-height: 1.8;
    opacity: 0.9;
    margin-bottom: 15px;
    line-height: 1.8;
    opacity: 0.9;
    margin-bottom: 15px;
}

.about-services h3 {
    font-size: 22px;
    margin-bottom: 20px;
    color: #000000;
    text-transform: uppercase;
}

.about-services ul {
    list-style: none;
    padding: 0;
}

.about-services ul li {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
    font-size: 15px;
    opacity: 0.9;
}

.about-services ul li i {
    color: var(--dark-background-color);
    margin-right: 12px;
    font-size: 14px;
}

/* PRODUCT CARD */
.product-link {
    text-decoration: none;
    color: inherit;
}

.product-card {
    border: 1px solid #eee;
    padding: 15px 15px 30px 15px;
    border-radius: 6px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
    cursor: pointer;
    text-align: center;
    transition: 0.3s;
}

.product-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    margin-bottom: 10px;
}

.product-card h3 {
    margin: 10px 0 5px;
    color: #000;
}

.product-card .price {
    color: #1e7e34;
    margin-bottom: 30px;
    font-size: 18px;
    font-weight: bold;
}

.product-card .button {
    padding: 10px 12px;
    border: none;
    background: #000;
    text-decoration: none;
    color: #fff;
    border-radius: 5px;
    cursor: pointer;
    transition: 0.3s;
}

.product-card .button:hover {
    background: var(--primary-color);
    color: #000;
}

.out{
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-bottom: 15px;
    margin-top: -30px;
    border: 1px solid #fff;
    color: #ad0707;
}

.container {
    max-width: 1200px;
    margin: 120px auto;
    background: #fff;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
}

.product-wrapper {
    display: flex;
    gap: 50px;
    flex-wrap: wrap;
}

.product-image {
    flex: 1;
}

.product-image img {
    width: 100%;
    border-radius: 10px;
}

.product-details {
    flex: 1;
}

.product-details h1 {
    font-size: 28px;
    margin-bottom: 10px;
}

.price {
    font-size: 24px;
    color: #1e7e34;
    margin-bottom: 20px;
}

.description {
    margin-bottom: 25px;
    color: #555;
    line-height: 1.6;
}

.section-title {
    margin-bottom: 10px;
    font-weight: bold;
}

.sizes button {
    padding: 10px 15px;
    margin-right: 10px;
    margin-bottom: 10px;
    border: 1px solid #ddd;
    background: #fff;
    cursor: pointer;
    border-radius: 5px;
    transition: 0.3s;
}

.sizes button:hover {
    background: #000;
    color: #fff;
}

.colors {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
}

.color-circle {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    cursor: pointer;
    border: 2px solid #ccc;
    transition: 0.3s;
}

.color-circle:hover {
    transform: scale(1.1);
    border-color: #000;
}

.add-to-cart {
    width: 100%;
    padding: 15px;
    border: none;
    background: #000;
    color: #fff;
    font-size: 16px;
    cursor: pointer;
    border-radius: 5px;
    transition: 0.3s;
}

.add-to-cart:hover {
    background: #333;
}

@media (max-width: 768px) {
    .product-wrapper {
        flex-direction: column;
    }
}

/* RESPONSIVE */
@media (max-width: 900px) {}

/* FOOTER */
.footer {
    background-color: #000;
    color: #fff;
    padding: 40px 30px 20px;
    margin-top: 30px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
    max-width: 90%;
    margin: auto;
}

.footer h3 {
    color: var(--secondary-color);
    font-size: 20px;
    margin-bottom: 15px;
    text-transform: uppercase;
}

.footer p {
    font-size: 14px;
    line-height: 1.7;
    opacity: 0.85;
}

/* LINKS */
.footer-section ul {
    list-style: none;
    padding: 0;
}

.footer-section ul li {
    margin-bottom: 10px;
}

.footer-section ul li a {
    text-decoration: none;
    color: #fff;
    font-size: 16px;
    transition: color 0.3s ease;
}

.footer-section ul li a:hover {
    color: var(--primary-color);
}

/* SOCIALS */
.social-icons {
    display: flex;
    gap: 15px;
}

.social-icons a {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    border-radius: 50%;
    color: #fff;
    font-size: 16px;
    transition: all 0.3s ease;
}

.social-icons a:hover {
    background: var(--primary-color);
    color: #000;
    transform: translateY(-4px);
}

/* CONTACT */
.footer-section.contact p {
    margin-bottom: 8px;
    font-size: 14px;
}

/* BOTTOM */
.footer-bottom {
    border-top: 1px solid rgb(0, 0, 0);
    background-color: #000000;
    margin-top: 40px;
    padding-top: 15px;
    padding-bottom: 20px;
    text-align: center;
    font-size: 13px;
    opacity: 0.7;
}

/* BACK TO TOP CTA */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--primary-color);
    color: #000;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s ease;
    z-index: 999;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}

/* show state */
.back-to-top.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* hover pop */
.back-to-top:hover {
    transform: translateY(-4px) scale(1.05);
}

/* Full-screen loader overlay */
#page-loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #fff;
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 1;
    transition: opacity 0.5s ease;
    /* smooth fade-out */
}

/* Hide loader after fade */
#page-loader.hidden {
    opacity: 0;
    pointer-events: none;
}

/* Dots container */
.dots-loader {
    display: flex;
    gap: 8px;
}

/* Individual dots */
.dots-loader span {
    width: 15px;
    height: 15px;
    background-color: #000;
    border-radius: 50%;
    display: inline-block;
    animation: bounce 0.6s infinite alternate;
}

/* Stagger the animation */
.dots-loader span:nth-child(2) {
    animation-delay: 0.2s;
}

.dots-loader span:nth-child(3) {
    animation-delay: 0.4s;
}

/* Bounce animation */
@keyframes bounce {
    from {
        transform: translateY(0);
    }

    to {
        transform: translateY(-15px);
    }
}

/* RESPONSIVE */
@media (max-width: 1000px) {
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Large laptops / tablets */
@media (max-width: 1200px) {
    .product-grid {
        grid-template-columns: repeat(3, 1fr);
        /* 3 columns */
    }
}

/* Mobile devices */
@media (max-width: 600px) {
    .product-grid {
        grid-template-columns: repeat(2, 1fr);
        /* still 2 columns on mobile */
    }

    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .social-icons {
        justify-content: center;
    }

    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 44px;
        height: 44px;
    }
}

/* RESPONSIVENESS */
@media (max-width: 1080px) {
    .search-input {
        position: fixed;
        top: 100px;
        /* height of your nav */
        left: 0;
        right: 0;
        color: #000;
        width: 100%;
        border-radius: 10px;
        border: #A9A9A9 solid 2px;
        background: #FFF;
        /* backdrop-filter: blur(20px); */
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
        padding: 0 20px;
        margin: 10px;
        height: 0;
        opacity: 0;
        z-index: 999;
        transition:
            height 0.3s ease,
            opacity 0.2s ease;
    }

    .search-wrapper.active .search-input {
        width: 95%;
        height: 50px;
        opacity: 1;
        padding: 0 20px;
    }

    .search-input::placeholder {
        color: #000;
        opacity: 1;
        /* important for Firefox */
    }
}

@media (max-width: 900px) {
    .nav {
        padding: 0 20px;
    }

    .logo {
        width: 120px;
    }

    .burger {
        display: flex;
        margin-left: 20px;
        width: 20px;
    }

    .nav-center {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: var(--dark-background-color);
        /* animation setup */
        max-height: 0;
        overflow: hidden;
        opacity: 0;
        transform: translateY(-10px);
        display: flex;
        flex-direction: column;
        gap: 15px;
        padding: 20px 0;

        transition:
            max-height 0.5s ease,
            opacity 0.4s ease,
            transform 0.4s ease;
        text-align: center;
    }

    .nav-center.active {
        display: flex;
        max-height: 300px;
        opacity: 1;
        transform: translateY(0);
    }

    .nav-right a {
        margin-left: 15px;
    }

    .cart-badge {
        top: 45px;
        right: 70px;
    }

    .search-wrapper {
        position: static;
    }

    .search-toggle {
        font-size: 18px;
    }

    .cart {
        font-size: 18px;
    }

    .search-input {
        position: fixed;
        top: 90px;
        /* height of your nav */
        left: 0;
        right: 0;
        width: 100%;
        color: #000;
        border-radius: 10px;
        padding: 0 20px;
        margin: 10px;
        height: 0;
        opacity: 0;
        z-index: 999;
        transition:
            height 0.3s ease,
            opacity 0.2s ease;
    }

    .search-wrapper.active .search-input {
        width: 95%;
        height: 50px;
        opacity: 1;
        padding: 0 20px;
    }

    .product-grid {
        grid-template-columns: repeat(2, 1fr);
        max-width: 100%;
        /* 2 columns */
    }

    .categories {
        max-width: 100%;
    }

    .about-container {
        grid-template-columns: 1fr;
        text-align: center;
    }


}