*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Darker Grotesque', sans-serif;
}

header {
   
    color: white;
    padding: 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid #FF4136;
}

.user-panel {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    min-width: 0;
}

#user-info {
    color: #000;
    font-weight: bold;
    overflow-wrap: break-word;
    word-break: break-word;
}

#login-link,
#change-password-link,
#logout-btn {
    background-color: #FF4136;
    color: white;
    text-decoration: none;
    border: none;
    border-radius: 6px;
    padding: 8px 12px;
    cursor: pointer;
    font-size: 14px;
}

#login-link:hover,
#change-password-link:hover,
#logout-btn:hover {
    background-color: #d63030;
}

.logo {
    height: 60px;
}

.cart-toggle-wrapper {
  position: relative;
}

.cart-icon {
  cursor: pointer;
  padding: 8px 8px;
  background-color: #FF4136;
  border-radius: 6px;
  font-weight: bold;
  color: white;

}

.cart-icon:hover {
  background-color: #d63030;
}


.cart-panel {
  position: fixed;
  top: 70px;
  right: 20px;
  width: 320px;
  background-color: #fff;
  border: 1px solid #ccc;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  
  opacity: 0;
  pointer-events: none;
  
  padding: 20px;
  z-index: 1000;
}


.cart-toggle-wrapper:hover .cart-panel {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}


.cart-panel, .cart-panel * {
    color: #333;
}

.cart-panel h3 {
    margin-bottom: 15px;
    
}

.cart-panel li {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid #eee;
}

.qty-control {
    display: flex;
    align-items: center;
    gap: 8px;
}

.qty-btn {
    background-color: #FF4136;
    color: white;
    border: none;
    width: 28px;
    height: 28px;
    border-radius: 6px;
    font-size: 18px;
    cursor: pointer;
}

.qty-btn:hover {
    background-color: #d32f2f;
}

.quantity {
    font-weight: bold;
    min-width: 20px;
    text-align: center;
}


/*done*/

.navigation-bar {
    margin: 10px auto 0;
    font-size: 18px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 0 20px;
    max-width: 1700px;
    width: 100%;
}

.navigation-bar a {
    color: #FF4136;
    text-decoration: none;
    overflow-wrap: break-word;
    word-break: break-word;
}

.navigation-bar a:hover {
    text-decoration: underline;
}

.navigation-bar .sep {
    color: #000000;
    font-weight: bold;
}

.content {
    display: flex;
    max-width: 1700px;
    width: 100%;
    margin: 8px auto;
    gap: 20px;
    padding: 0 20px;
    align-items: flex-start;
}

.categories {
    width: 220px;
    min-width: 220px;
    max-width: 220px;
    background-color: white;
    border-right: 2px solid #000000;
    padding-right: 12px;
}

.categories h2 {
    text-align: center;
    font-size: 25px;
}

.categories ul {
    list-style: none;
    padding: 0;
    width: 100%;
}

.categories li {
    width: 100%;
}

.categories li a {
    display: block;
    width: 100%;
    padding: 10px;
    text-decoration: none;
    color: black;
    overflow-wrap: break-word;
    word-break: break-word;
    white-space: normal;
}

.categories li a:hover,
.categories li a.active {
    background: #f0f0f0;
    font-weight: bold;
}

.product-area {
    flex: 1;
    min-width: 0;
}



.product-area h2 {
    font-size: 25px;
}


.product-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
}

/* done */

.product {
   
    
    padding: 12px;
    width: calc(25% - 16px);
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: transform 0.12s, box-shadow 0.12s;
    
}

.product:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 16px rgba(0,0,0,0.1);
}

.product img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
    width: 183px;
    height: 275px;
    object-fit: cover;     
    display: block;

}

.product-name {
    margin: 10px 0 6px 0;
    font-size: 16px;
    text-decoration: none;
}

.product-name a{
    
    text-decoration: none;
    color: black;
}

.product-price {
    margin: 0 0 10px 0;
    font-weight: bold;
}

.add-to-cart {
    background-color: #FF4136;
    color: white;
    border: none;
    padding: 8px 12px;
    border-radius: 4px;
    cursor: pointer;
    
    
}

.add-to-cart:hover {
    background: #d32f2f;
}

.detail-wrapper {
    padding: 2rem 1rem;
    max-width: 1200px;
    margin: 0 auto;
}

.detail-layout {
    display: flex;
    flex-wrap: wrap;
    gap: 2.5rem;
    
}

.detail-image {
    flex: 0 0 600px;
}

.detail-image img {
    
    border-radius: 12px;
    width: 600px;
  height: 900px;
  object-fit: cover;
  display: block;
    
}

.detail-info {
    flex: 1;
    min-width: 320px;
}

.detail-info h2 {
    margin: 0 0 0.8rem 0;
    font-weight: bold;
    font-size: 2.1rem;
    color: #222;
}

.detail-price {
    font-size: 1.8rem;
    font-weight: bold;
    color: #FF4136;
    margin: 0 0 1.2rem 0;
}

.detail-desc {
    font-size: 1.1rem;
    line-height: 1.65;
    color: #000000;
    margin: 0 0 1.8rem 0;
    max-width: 580px;
}

.detail-info .add-to-cart {
    font-size: 1.1rem;
    padding: 0.9rem 2.2rem;
}



@media (max-width: 1000px) {
    .product { width: calc(33.333% - 16px); }
}

@media (max-width: 700px) {
    .content { flex-direction: column; }
    .categories { width: 100%; }
    .product { width: calc(50% - 16px); }

    header {
        flex-direction: column;
        gap: 12px;
        align-items: flex-start;
    }

    .user-panel {
        width: 100%;
    }
}

@media (max-width: 420px) {
    .product { width: 100%; }
}

