/* Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: #f5f7fa;
  color: #333;
}

/* Main Dashboard Layout */
.dashboard-container {
  display: flex;
  max-width: 1200px;
  margin: 40px auto;
  background-color: #fff;
  box-shadow: 0 0 10px rgba(0,0,0,0.1);
  border-radius: 12px;
  overflow: hidden;
}

/* Sidebar Navigation */
.sidebar {
  width: 150px;
  background-color: #e91e63;
  padding: 20px;
  display: flex;
  flex-direction: column;
}

.sidebar h2 {
  color: #fff;
  margin-bottom: 30px;
  font-size: 22px;
  font-weight: 600;
}

.sidebar button {
  background: none;
  border: none;
  text-align: left;
  padding: 12px 15px;
  font-size: 16px;
  color: #fff;
  margin-bottom: 10px;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.3s;
}

.sidebar button:hover,
.sidebar button.active {
  background-color: #c2185b;
}

.hidden {
  display: none;
}

.tab-link.active {
  background-color: #f0f0f0;
}

/* Right Content Area */
.content {
  flex: 1;
  padding: 30px;
}

.section-heading {
  font-size: 24px;
  margin-bottom: 20px;
  color: #e91e63;
}

/* Profile Form */
form input,
form select,
form textarea {
  width: 100%;
  padding: 10px;
  margin-bottom: 20px;
  border: 1px solid #ccc;
  border-radius: 8px;
  font-size: 15px;
}

form input[disabled] {
  background-color: #eee;
}

button#editProfileBtn,
button#saveProfileBtn,
button#logoutBtn {
  padding: 10px 20px;
  background-color: #e91e63;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-weight: bold;
  cursor: pointer;
  margin-right: 10px;
  transition: background 0.3s;
}

button#saveProfileBtn.hidden,
button#editProfileBtn.hidden {
  display: none;
}

button:hover {
  background-color: #c2185b;
}

/* Section visibility */
.tab-section {
  display: none;
}

.tab-section.active {
  display: block;
}

/* Order Card */
.order-card {
  display: flex;
  gap: 20px;
  margin: 10px 0;
  padding: 15px;
  background: #67656527;
  border-radius: 8px;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.1);
}

.order-card img {
  width: 90px;
  height: 120px;
  object-fit: cover;
  border-radius: 6px;
}
.cart-card {
  display: flex;
  gap: 20px;
  justify-content: center;
  margin: 10px 0;
  padding: 15px;
  background: #67656527;
  border-radius: 8px;
  flex-direction: column;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.1);
}
.cart-card img {
  width: 90px;
  height: 120px;
  object-fit: cover;
  border-radius: 6px;
}

.order-details h2 {
  color: #c98622db;
}

.order-details h3 {
  margin: 0;
  color: #000;
}

.order-details p {
  margin: 5px 0;
}

.order-status {
  font-weight: bold;
  color: green;
}

/* Cancel Button */
.cancel-btn {
  background-color: #ff4d4f;
  color: white;
  border: none;
  padding: 10px 18px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.3s ease, transform 0.2s ease;
  float: right;
  margin-top: 10px;
}

.cancel-btn:hover {
  background-color: #d9363e;
  transform: scale(1.05);
}

.cancel-btn:active {
  transform: scale(0.98);
}

/* Fancy animated buttons for confirmation modal */
#confirmCancelYes, #confirmCancelNo {
  background: linear-gradient(135deg, #4CAF50, #2E7D32); /* green gradient */
  color: white;
  padding: 10px 20px;
  margin: 10px 15px 0 0;
  border: none;
  border-radius: 25px;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

#confirmCancelNo {
  background: linear-gradient(135deg, #F44336, #C62828); /* red gradient */
}

#confirmCancelYes:hover,
#confirmCancelNo:hover {
  transform: scale(1.08);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
}

#confirmCancelYes:active,
#confirmCancelNo:active {
  transform: scale(0.96);
}

.dialog-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.6);
  display: flex;
  justify-content: center;
  align-items: center;
  animation: fadeIn 0.3s ease-in-out;
  z-index: 1000;
}

.dialog-box {
  background: #fff;
  padding: 20px 30px;
  border-radius: 10px;
  text-align: center;
  animation: popIn 0.3s ease;
  box-shadow: 0 5px 20px rgba(0,0,0,0.2);
}

.dialog-actions {
  margin-top: 20px;
}

.yes-btn, .no-btn {
  padding: 8px 16px;
  margin: 0 10px;
  border: none;
  border-radius: 5px;
  cursor: pointer;
}

.yes-btn {
  background-color: #e74c3c;
  color: white;
}

.no-btn {
  background-color: #ccc;
}

.hidden {
  display: none;
}

@keyframes popIn {
  from { transform: scale(0.9); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}


/* Modal */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9998;
}

.modal.hidden {
  display: none;
}

.modal-content {
  background: white;
  padding: 20px;
  border-radius: 10px;
  width: 90%;
  max-width: 500px;
  text-align: center;
  position: relative;
}

#closeModal {
  position: absolute;
  top: 10px;
  right: 20px;
  cursor: pointer;
  font-weight: bold;
  font-size: 20px;
}

/* Toast Notification */
.toast {
  position: fixed;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  background: #323232;
  color: white;
  padding: 12px 24px;
  border-radius: 8px;
  font-size: 16px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.5s ease, bottom 0.5s ease;
  z-index: 9999;
}

.toast.show {
  opacity: 1;
  bottom: 50px;
  pointer-events: auto;
}

/* Responsive */
@media (max-width: 768px) {
  .dashboard-container {
    flex-direction: column;
  }

  .sidebar {
    width: 100%;
    flex-direction: row;
    overflow-x: auto;
    padding: 10px;
  }

  .sidebar h2 {
    display: none;
  }

  .sidebar button {
    flex: 1;
    margin: 5px;
    padding: 10px;
    font-size: 14px;
  }

  .content {
    padding: 20px;
  }

  .order-details h2 {
    color: #d0631b;
    font-size: medium;
  }
}
