* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: Arial, Helvetica, sans-serif;
    background: #f7f8fc;
    color: #222;
    transition: 0.3s;
}


/* ================= HEADER ================= */

.header {
    min-height: 75px;
    background: white;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 12px 6%;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 15px rgba(0,0,0,0.08);
}

.logo {
    font-size: 25px;
    font-weight: bold;
    display: flex;
    align-items: center;
    gap: 10px;
    white-space: nowrap;
}

.logo i {
    font-size: 30px;
    color: #ff4b2b;
}

.logo span span {
    color: #ff4b2b;
}


/* SEARCH */

.search-box {
    display: flex;
    width: 40%;
    height: 44px;
    border: 1px solid #ddd;
    border-radius: 25px;
    overflow: hidden;
    background: white;
}

.search-box input {
    flex: 1;
    border: none;
    outline: none;
    padding: 0 18px;
    font-size: 14px;
}

.search-box button {
    width: 55px;
    border: none;
    background: #ff4b2b;
    color: white;
    cursor: pointer;
}


/* HEADER BUTTONS */

.header-actions {
    display: flex;
    gap: 10px;
}

.header-actions button {
    position: relative;
    width: 42px;
    height: 42px;
    border: none;
    border-radius: 50%;
    background: #f1f1f1;
    cursor: pointer;
    font-size: 17px;
    transition: 0.3s;
}

.header-actions button:hover {
    background: #ff4b2b;
    color: white;
    transform: translateY(-2px);
}

.header-actions span {
    position: absolute;
    top: -5px;
    right: -4px;
    background: #ff4b2b;
    color: white;
    width: 19px;
    height: 19px;
    border-radius: 50%;
    font-size: 11px;
    display: flex;
    justify-content: center;
    align-items: center;
}


/* ================= NAVBAR ================= */

.navbar {
    background: #111;
    display: flex;
    justify-content: center;
    gap: 45px;
    padding: 15px;
}

.navbar a {
    color: white;
    text-decoration: none;
    font-size: 14px;
    transition: 0.3s;
}

.navbar a:hover {
    color: #ff6b4a;
}


/* ================= HERO ================= */

.hero {
    min-height: 500px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 70px 9%;
    background: linear-gradient(135deg, #fff1ed, #fff);
    overflow: hidden;
}

.hero-content {
    max-width: 600px;
}

.small-title {
    color: #ff4b2b;
    font-weight: bold;
    letter-spacing: 3px;
}

.hero h1 {
    font-size: 65px;
    margin: 10px 0;
}

.hero h1 span {
    color: #ff4b2b;
}

.hero h2 {
    font-size: 27px;
    margin-bottom: 15px;
}

.hero p {
    color: #666;
    line-height: 1.7;
}

.hero-buttons {
    margin-top: 30px;
    display: flex;
    gap: 15px;
}

.primary-btn,
.secondary-btn,
.offer-btn {
    padding: 14px 25px;
    border-radius: 30px;
    text-decoration: none;
    display: inline-block;
    transition: 0.3s;
}

.primary-btn {
    background: #ff4b2b;
    color: white;
}

.secondary-btn {
    border: 2px solid #ff4b2b;
    color: #ff4b2b;
}

.primary-btn:hover,
.secondary-btn:hover,
.offer-btn:hover {
    transform: translateY(-3px);
}


/* HERO GRAPHIC */

.hero-image {
    position: relative;
    width: 380px;
    height: 380px;
}

.hero-circle {
    width: 330px;
    height: 330px;
    border-radius: 50%;
    background: linear-gradient(135deg, #ff4b2b, #ff9068);
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 120px;
    box-shadow: 0 25px 50px rgba(255,75,43,0.25);
}

.floating-card {
    position: absolute;
    background: white;
    padding: 13px 18px;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.12);
    z-index: 2;
    font-weight: bold;
}

.floating-card i {
    color: #ff4b2b;
    margin-right: 5px;
}

.card-one {
    top: 45px;
    left: -30px;
}

.card-two {
    bottom: 50px;
    right: 0;
}


/* ================= SECTION ================= */

section {
    padding: 70px 8%;
}

.section-heading {
    text-align: center;
    margin-bottom: 35px;
}

.section-heading p {
    color: #ff4b2b;
    font-weight: bold;
    letter-spacing: 2px;
}

.section-heading h2 {
    font-size: 35px;
    margin: 8px 0;
}

.section-heading span {
    color: #777;
}


/* ================= CATEGORIES ================= */

.category-container {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 20px;
}

.category-card {
    border: none;
    background: white;
    padding: 30px 15px;
    border-radius: 18px;
    cursor: pointer;
    box-shadow: 0 5px 20px rgba(0,0,0,0.07);
    transition: 0.3s;
}

.category-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.12);
}

.category-icon {
    font-size: 42px;
    margin-bottom: 12px;
}

.category-card p {
    color: #777;
    margin-top: 5px;
}


/* ================= OFFER ================= */

.offer-section {
    margin: 20px 8%;
    padding: 50px;
    border-radius: 25px;
    background: linear-gradient(120deg, #ff4b2b, #ff9068);
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.offer-content p {
    margin-bottom: 10px;
}

.offer-content h2 {
    font-size: 50px;
}

.offer-content h3 {
    font-size: 30px;
    margin-bottom: 10px;
}

.offer-btn {
    background: white;
    color: #ff4b2b;
    margin-top: 15px;
}

.offer-icon {
    font-size: 120px;
}


/* ================= FILTER ================= */

.filter-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    gap: 20px;
}

.filter-categories {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.filter-btn {
    border: 1px solid #ddd;
    background: white;
    padding: 10px 18px;
    border-radius: 20px;
    cursor: pointer;
    transition: 0.3s;
}

.filter-btn.active,
.filter-btn:hover {
    background: #ff4b2b;
    color: white;
    border-color: #ff4b2b;
}

#sortSelect {
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 20px;
    outline: none;
}


/* ================= PRODUCTS ================= */

.product-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 25px;
}

.product-card {
    background: white;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0,0,0,0.07);
    transition: 0.3s;
    position: relative;
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.13);
}

.product-image {
    height: 220px;
    background: #f5f5f5;
    position: relative;
    overflow: hidden;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: 0.5s;
}

.product-card:hover .product-image img {
    transform: scale(1.08);
}

.sale-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: #ff4b2b;
    color: white;
    padding: 6px 10px;
    border-radius: 15px;
    font-size: 11px;
    font-weight: bold;
}

.wishlist {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 38px;
    height: 38px;
    border: none;
    border-radius: 50%;
    background: white;
    cursor: pointer;
    font-size: 17px;
    transition: 0.3s;
}

.wishlist:hover,
.wishlist.active {
    color: #ff4b2b;
}

.product-info {
    padding: 18px;
}

.product-category {
    color: #ff4b2b;
    font-size: 12px;
    font-weight: bold;
    text-transform: uppercase;
}

.product-info h3 {
    margin: 8px 0;
}

.product-description {
    color: #777;
    font-size: 13px;
    line-height: 1.5;
    min-height: 38px;
}

.rating {
    color: #ffb400;
    font-size: 13px;
    margin: 10px 0;
}

.price {
    font-size: 21px;
    font-weight: bold;
}

.old-price {
    color: #999;
    text-decoration: line-through;
    font-size: 13px;
    margin-left: 5px;
}

.product-buttons {
    display: flex;
    gap: 8px;
    margin-top: 15px;
}

.add-cart,
.quick-view {
    border: none;
    padding: 10px;
    border-radius: 8px;
    cursor: pointer;
}

.add-cart {
    flex: 1;
    background: #ff4b2b;
    color: white;
}

.add-cart:hover {
    background: #e63e21;
}

.quick-view {
    width: 42px;
    background: #eee;
}


/* ================= FEATURES ================= */

.features-section {
    background: white;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 25px;
}

.feature {
    display: flex;
    align-items: center;
    gap: 15px;
}

.feature > i {
    font-size: 30px;
    color: #ff4b2b;
}

.feature p {
    color: #777;
    font-size: 13px;
    margin-top: 5px;
}


/* ================= FOOTER ================= */

footer {
    background: #111;
    color: white;
    padding: 60px 8% 20px;
}

.footer-container {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
}

.footer-column h3 {
    margin-bottom: 20px;
}

.footer-column a {
    display: block;
    color: #bbb;
    text-decoration: none;
    margin: 10px 0;
}

.footer-column a:hover {
    color: #ff4b2b;
}

.footer-column p {
    color: #aaa;
    line-height: 1.7;
}

.footer-logo {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 15px;
}

.social-icons {
    display: flex;
    gap: 12px;
}

.social-icons a {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: #222;
    display: flex !important;
    justify-content: center;
    align-items: center;
    color: white;
    font-size: 20px;
    margin: 0 !important;
}

.social-icons a:hover {
    background: #ff4b2b;
    transform: translateY(-4px);
}

.footer-bottom {
    border-top: 1px solid #333;
    margin-top: 40px;
    padding-top: 20px;
    text-align: center;
    color: #888;
}


/* ================= CART ================= */

.cart-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    display: none;
    z-index: 1998;
}

.cart-overlay.show {
    display: block;
}

.cart-sidebar {
    position: fixed;
    right: -430px;
    top: 0;
    width: 410px;
    height: 100vh;
    background: white;
    z-index: 2000;
    transition: 0.4s;
    display: flex;
    flex-direction: column;
}

.cart-sidebar.open {
    right: 0;
}

.cart-header {
    padding: 20px;
    display: flex;
    justify-content: space-between;
    border-bottom: 1px solid #ddd;
}

.cart-header button {
    border: none;
    background: none;
    font-size: 22px;
    cursor: pointer;
}

.cart-items {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
}

.cart-item {
    display: flex;
    gap: 12px;
    padding: 15px 0;
    border-bottom: 1px solid #eee;
}

.cart-item-image {
    width: 70px;
    height: 70px;
    object-fit: cover;
    border-radius: 10px;
}

.cart-item-info {
    flex: 1;
}

.cart-item-info h4 {
    margin-bottom: 5px;
}

.cart-price {
    color: #ff4b2b;
    font-weight: bold;
}

.quantity {
    display: flex;
    gap: 8px;
    align-items: center;
    margin-top: 8px;
}

.quantity button {
    width: 27px;
    height: 27px;
    border: none;
    background: #eee;
    cursor: pointer;
    border-radius: 5px;
}

.remove {
    border: none;
    background: none;
    color: #ff4b2b;
    cursor: pointer;
    font-size: 17px;
}

.empty-cart {
    text-align: center;
    padding: 60px 10px;
    color: #777;
}

.cart-bottom {
    padding: 20px;
    border-top: 1px solid #ddd;
}

.cart-total {
    display: flex;
    justify-content: space-between;
    font-size: 20px;
    margin-bottom: 15px;
}

.checkout-btn {
    width: 100%;
    padding: 15px;
    background: #ff4b2b;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
}


/* ================= MODAL ================= */

.modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.65);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 3000;
}

.modal.show {
    display: flex;
}

.modal-content {
    background: white;
    width: 650px;
    max-width: 90%;
    padding: 30px;
    border-radius: 20px;
    position: relative;
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    border: none;
    background: #eee;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 2;
}

.modal-product {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 25px;
    align-items: center;
}

.modal-product img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    border-radius: 15px;
}

.modal-product h2 {
    margin-bottom: 10px;
}

.modal-product p {
    color: #666;
    line-height: 1.6;
    margin: 15px 0;
}


/* ================= TOAST ================= */

.toast {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: #111;
    color: white;
    padding: 15px 20px;
    border-radius: 10px;
    display: flex;
    gap: 10px;
    transform: translateY(100px);
    transition: 0.4s;
    z-index: 5000;
}

.toast.show {
    transform: translateY(0);
}

.toast i {
    color: #4ade80;
}


/* ================= DARK MODE ================= */

body.dark-mode {
    background: #151515;
    color: white;
}

body.dark-mode .header,
body.dark-mode .category-card,
body.dark-mode .product-card,
body.dark-mode .feature,
body.dark-mode .cart-sidebar,
body.dark-mode .modal-content,
body.dark-mode .search-box,
body.dark-mode .filter-btn,
body.dark-mode #sortSelect {
    background: #222;
    color: white;
}

body.dark-mode .hero {
    background: linear-gradient(135deg, #202020, #151515);
}

body.dark-mode .hero p,
body.dark-mode .section-heading span,
body.dark-mode .product-description,
body.dark-mode .category-card p,
body.dark-mode .feature p {
    color: #aaa;
}

body.dark-mode .filter-btn {
    border-color: #444;
}

body.dark-mode .search-box {
    border-color: #444;
}

body.dark-mode .search-box input {
    background: #222;
    color: white;
}

body.dark-mode .cart-item {
    border-color: #444;
}


/* ================= RESPONSIVE ================= */

@media (max-width: 1100px) {

    .product-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .category-container {
        grid-template-columns: repeat(3, 1fr);
    }

    .features-section {
        grid-template-columns: repeat(2, 1fr);
    }

    .hero-image {
        display: none;
    }
}


@media (max-width: 750px) {

    .header {
        padding: 15px;
        flex-wrap: wrap;
    }

    .search-box {
        width: 100%;
        order: 3;
    }

    .navbar {
        gap: 20px;
        overflow-x: auto;
        justify-content: flex-start;
    }

    .hero {
        padding: 50px 6%;
    }

    .hero h1 {
        font-size: 45px;
    }

    .category-container,
    .product-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .filter-bar {
        flex-direction: column;
        align-items: stretch;
    }

    .offer-section {
        margin: 10px;
        padding: 30px;
    }

    .offer-icon {
        display: none;
    }

    .footer-container {
        grid-template-columns: 1fr 1fr;
    }

    .cart-sidebar {
        width: 90%;
    }

    .modal-product {
        grid-template-columns: 1fr;
    }
}


@media (max-width: 480px) {

    .logo {
        font-size: 20px;
    }

    .header-actions {
        gap: 5px;
    }

    .header-actions button {
        width: 38px;
        height: 38px;
    }

    .category-container,
    .product-grid {
        grid-template-columns: 1fr;
    }

    .features-section {
        grid-template-columns: 1fr;
    }

    .footer-container {
        grid-template-columns: 1fr;
    }

    .hero h1 {
        font-size: 40px;
    }

    .hero h2 {
        font-size: 22px;
    }

    .offer-content h2 {
        font-size: 38px;
    }
}