/* Navbar Styles */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 50px;
  z-index: 1000;
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0.8), transparent);
  /* Subtle gradient for readability */
  transition: background 0.3s ease;
}

.nav-left {
  display: flex;
  align-items: center;
}

.logo-img {
  height: 70px;
  /* Increased size */
  width: auto;
  transition: transform 0.3s ease;
}

.logo-img:hover {
  transform: scale(1.05);
  /* Interactive feel */
}

.nav-center {
  display: flex;
  gap: 40px;
  /* Larger gap as requested */
  align-items: center;
}

.nav-link {
  text-decoration: none;
  color: #fff;
  font-family: "Aileron", sans-serif;
  /* Matching the slogan font preference or similar */
  font-size: 16px;
  font-weight: 300;
  text-transform: uppercase;
  letter-spacing: 1px;
  position: relative;
  transition: color 0.3s ease;
}

.nav-link::after {
  content: "";
  position: absolute;
  width: 0;
  height: 1px;
  bottom: -5px;
  left: 0;
  background-color: #fff;
  transition: width 0.3s ease;
}

.nav-link:hover::after {
  width: 100%;
}

.nav-right {
    position: relative; /* anchor for dropdown */
  display: flex;
  align-items: center;
}

/* Hamburger Menu */
.hamburger {
  display: none;
  cursor: pointer;
  z-index: 1002;
  /* Above mobile menu */
  flex-direction: column;
  justify-content: space-between;
  width: 30px;
  height: 21px;
}

.bar {
  width: 100%;
  height: 3px;
  background-color: #fff;
  transition: all 0.3s ease;
  border-radius: 2px;
}

.hamburger.active .bar:nth-child(1) {
  transform: translateY(9px) rotate(45deg);
}

.hamburger.active .bar:nth-child(2) {
  opacity: 0;
}

.hamburger.active .bar:nth-child(3) {
  transform: translateY(-9px) rotate(-45deg);
}

/* Mobile Menu Overlay */
.mobile-menu {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  background: rgba(10, 10, 10, 0.98);
  /* Less transparent for readability */
  backdrop-filter: blur(15px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 40px;
  z-index: 1001;
  /* Below hamburger, above everything else */
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
}

.mobile-menu.active {
  opacity: 1;
  pointer-events: all;
}

.mobile-nav-link {
  font-family: "Forum", serif;
  font-size: 32px;
  color: #fff;
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 2px;
  transition: color 0.3s;
}

.mobile-nav-link:hover {
  color: rgba(255, 255, 255, 0.6);
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .navbar {
    padding: 15px 20px;
  }

  .logo-img {
    height: 50px;
    /* Slightly smaller on mobile */
  }

  .nav-center,
  .nav-right {
    display: none;
    /* Hide default nav items */
  }

  .hamburger {
    display: flex;
    /* Show hamburger */
  }
}
/* Cart Icon & Badge */
.cart-icon-container {
  position: relative;
  cursor: pointer;
  color: #fff;
  margin-right: 20px;
  display: flex;
  align-items: center;
}

.cart-count {
  position: absolute;
  top: -8px;
  right: -8px;
  background-color: #ff4d4d;
  color: white;
  font-size: 12px;
  border-radius: 50%;
  width: 18px;
  height: 18px;
  display: flex;
  justify-content: center;
  align-items: center;
  font-family: "Mulish", sans-serif;
  font-weight: 700;
}

/* Cart Overlay/Sidebar */
.cart-overlay {
  position: fixed;
  top: 0;
  right: -400px; /* Hidden off-screen */
  width: 350px;
  height: 100vh;
  background: rgba(15, 15, 15, 0.95);
  backdrop-filter: blur(10px);
  z-index: 2000; /* Above everything */
  transition: right 0.3s ease;
  box-shadow: -5px 0 15px rgba(0, 0, 0, 0.5);
  display: flex;
  flex-direction: column;
}

/* Cart dropdown open state */
.cart-dropdown.open {
    display: block;
}

.cart-overlay.open {
  right: 0;
}

.cart-container {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 20px;
  width: 100%;
  box-sizing: border-box;
}

.cart-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding-bottom: 15px;
  margin-bottom: 20px;
}

.cart-header h3 {
  margin: 0;
  color: #fff;
  font-family: "Forum", serif;
  font-weight: 400;
}

.close-cart {
  font-size: 30px;
  color: #fff;
  cursor: pointer;
  line-height: 1;
}

.cart-items {
  flex-grow: 1;
  overflow-y: auto;
  color: #fff;
  font-family: "Mulish", sans-serif;
}

.cart-item {
  display: flex;
  gap: 15px;
  margin-bottom: 15px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  padding-bottom: 15px;
}

.cart-item-img {
  width: 60px;
  height: 60px;
  object-fit: contain;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 4px;
}

.cart-item-details {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
}

.cart-item-title {
  font-weight: 600;
  font-size: 14px;
}

.cart-item-price {
  font-size: 14px;
  color: #aaa;
}

.cart-item-remove {
  color: #ff4d4d;
  cursor: pointer;
  font-size: 12px;
  align-self: flex-end;
}

.cart-footer {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 20px;
  margin-top: auto;
}

.cart-total {
  display: flex;
  justify-content: space-between;
  color: #fff;
  font-family: "Forum", serif;
  font-size: 18px;
  margin-bottom: 20px;
}

.checkout-btn {
  width: 100%;
  background: #fff;
  color: #000;
  border: none;
  padding: 12px;
  font-family: "Mulish", sans-serif;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.3s;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.checkout-btn:hover {
  background: #e0e0e0;
}

.empty-cart-msg {
  text-align: center;
  color: #aaa;
  margin-top: 50px;
}

/* Cart Dropdown (hover) */
.cart-dropdown {
  position: absolute;
  top: 100%;
  right: 0;
  width: 300px;
  background: rgba(10, 10, 10, 0.4); /* More transparent */
  backdrop-filter: blur(20px); /* Stronger blur */
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 20px;
  display: none;
  z-index: 1500;
}

/* Show dropdown on hover */
.cart-icon-container:hover .cart-dropdown {
  display: block;
}

.cart-dropdown .cart-header {
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  margin-bottom: 10px;
  padding-bottom: 5px;
}

.cart-dropdown .cart-footer {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  margin-top: 10px;
  padding-top: 10px;
}

/* Cart Item Styling */
.cart-items {
  max-height: 300px;
  overflow-y: auto;
}

.cart-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.cart-item:last-child {
  border-bottom: none;
}

.cart-item-img {
  width: 50px;
  height: 50px;
  object-fit: cover;
  border-radius: 4px;
  margin-right: 12px;
}

.cart-item-details {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.cart-item-title {
  font-family: "Mulish", sans-serif;
  font-weight: 600;
  font-size: 14px;
  color: #fff;
  margin-bottom: 4px;
}

.cart-item-price {
  font-size: 12px;
  color: #ccc;
}

.cart-item-actions {
  display: flex;
  align-items: center;
  margin-left: 10px;
}

.cart-separator {
  color: #666;
  margin-right: 8px;
  font-size: 14px;
}

.cart-item-remove {
  cursor: pointer;
  color: #ff4d4d;
  font-size: 14px;
  font-weight: bold;
  transition: color 0.2s;
}

.cart-item-remove:hover {
  color: #e60000;
}

/* Ensure checkout button is prominent */
.checkout-btn {
    width: 100%;
    padding: 14px;
    background-color: transparent;
    color: #4CAF50;
    border: 2px solid #4CAF50;
    border-radius: 4px;
    font-size: 16px;
    font-weight: bold;
    text-transform: uppercase;
    cursor: pointer;
    margin-top: 10px;
}

.checkout-btn:hover {
    background-color: #4CAF50;
    color: #fff;
}

/* Success Toast */
.cart-toast {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%) translateY(-100px);
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: #fff;
  padding: 15px 25px;
  border-radius: 50px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
  z-index: 9999;
  border: 1px solid rgba(255, 255, 255, 0.1);
  opacity: 0;
  transition: all 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  pointer-events: none;
}

.cart-toast.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

.cart-toast-content {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: "Mulish", sans-serif;
  font-weight: 600;
}

.cart-toast-icon {
  background: #4CAF50;
  color: #fff;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: bold;
}
