@font-face {
  font-family: "IranYekan";
  src: url("../fonts/iranyekanwebregular.b95439c1.b95439c1.woff") format("woff");
  font-weight: normal;
  font-style: normal;
}
/* ===== BASE ===== */
body {
  font-family: "IranYekan", sans-serif;
  background-color: #f8f9fa;
}
.fw-black {
  font-weight: 900;
}

/* ===== PRIMARY COLOR OVERRIDES ===== */
.txt-primary {
  color: #5900ff !important;
}
.bg-primary {
  background-color: #5900ff !important;
}
.btn-primary {
  background-color: #5900ff !important;
  border-color: #5900ff !important;
  color: #fff !important;
}
.btn-primary:hover {
  background-color: #4a00d4 !important;
  border-color: #4a00d4 !important;
  color: #fff !important;
}
.btn-outline-primary {
  color: #5900ff !important;
  border-color: #5900ff !important;
}
.btn-outline-primary:hover {
  background-color: #5900ff !important;
  border-color: #5900ff !important;
  color: #fff !important;
}
.bg-primary-subtle {
  background-color: #f0e8ff !important;
}
.text-primary-emphasis {
  color: #5900ff !important;
}
.badge.bg-primary {
  background-color: #5900ff !important;
}

/* ===== HEADER ===== */
.custom-header-btn {
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #dee2e6;
  border-radius: 8px;
  background-color: #fff;
  color: #333;
  transition: all 0.2s ease-in-out;
}
.custom-header-btn:hover {
  background-color: #f8f9fa;
  border-color: #ced4da;
}

.custom-user-dropdown {
  border-radius: 12px;
  border: 1px solid #efefef;
  padding: 0.5rem 0;
  min-width: 230px;
  text-align: right;
}
.custom-user-dropdown .dropdown-item {
  padding: 0.7rem 1.2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-direction: row-reverse;
  color: #4a5568;
  font-size: 0.92rem;
  transition: background 0.15s;
}
.custom-user-dropdown .dropdown-item i {
  font-size: 1.05rem;
  color: #718096;
}
.custom-user-dropdown .dropdown-item:hover {
  background-color: #f7fafc;
  color: #1a202c;
}
.custom-user-dropdown .dropdown-item.text-danger i {
  color: #dc3545 !important;
}
.custom-header-btn.dropdown-toggle::after {
  display: none !important;
}

/* ===== SEARCH ===== */
.search-results-container {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
  max-height: 420px;
  overflow-y: auto;
  z-index: 1050;
  padding: 12px 0;
  border: 1px solid #e9ecef;
}
.search-results-container .result-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  cursor: pointer;
  transition: background 0.15s;
  border-bottom: 1px solid #f1f1f1;
}
.search-results-container .result-item:last-child {
  border-bottom: none;
}
.search-results-container .result-item:hover {
  background: #f8f9fa;
}
.search-results-container .result-item img {
  width: 48px;
  height: 48px;
  object-fit: cover;
  border-radius: 8px;
}
.search-results-container .result-item .info {
  flex: 1;
}
.search-results-container .result-item .info .name {
  font-weight: 600;
  font-size: 14px;
  color: #212529;
}
.search-results-container .result-item .info .price {
  font-size: 13px;
  color: #5900ff;
}
.search-results-container .empty-state {
  padding: 30px 16px;
  text-align: center;
  color: #6c757d;
}
#mobileSearchResults {
  position: static;
  box-shadow: none;
  border: none;
  max-height: 300px;
}

.badge-count {
  position: absolute;
  top: -2px;
  left: -2px;
  font-size: 10px;
  padding: 2px 5px;
  border-radius: 50%;
  background-color: #f1f1f1;
  color: #000;
}
.dropdown-menu .dropdown-item:hover {
  transition: 0.1s;
  color: #5900ff;
  transform: translateX(-2px);
  background: none;
}

/* ===== MEGA MENU ===== */
@media (min-width: 992px) {
  .nav-item.dropdown {
    position: static;
  }
  .nav-item.dropdown .dropdown-menu {
    width: 100%;
    left: 0;
    right: 0;
    top: 100%;
    margin-top: 0;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    border-radius: 0 0 12px 12px;
    border-color: #f1f1f1;
    padding: 1.5rem;
    display: block;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.2s ease-in-out;
  }
  .nav-item.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }
}

/* ===== PANEL LAYOUT ===== */
.panel-shell {
  display: flex;
  align-items: flex-start;
  gap: 24px;
  padding: 24px;
}
.panel-sidebar {
  width: 270px;
  flex-shrink: 0;
  position: sticky;
  top: 90px;
}
.panel-main {
  flex: 1;
  min-width: 0;
}

.panel-profile-card {
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 7px 29px 0 rgba(100, 100, 111, 0.12);
  padding: 24px 20px;
  text-align: center;
  margin-bottom: 16px;
}
.panel-avatar {
  width: 76px;
  height: 76px;
  border-radius: 50%;
  background: #5900ff;
  color: #fff;
  font-weight: 800;
  font-size: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 12px auto;
}
.panel-profile-card h6 {
  font-weight: 700;
  margin-bottom: 2px;
  color: #212529;
}
.panel-profile-card span {
  font-size: 12.5px;
  color: #adb5bd;
}

.panel-nav {
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 7px 29px 0 rgba(100, 100, 111, 0.12);
  overflow: hidden;
}
.panel-nav .nav-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-direction: row-reverse;
  gap: 10px;
  padding: 14px 20px;
  color: #4a5568;
  font-size: 14px;
  font-weight: 600;
  border-bottom: 1px solid #f1f1f1;
  border-radius: 0;
  cursor: pointer;
}
.panel-nav .nav-link:last-child {
  border-bottom: none;
}
.panel-nav .nav-link i {
  font-size: 15px;
  color: #718096;
  width: 20px;
  text-align: center;
}
.panel-nav .nav-link:hover {
  background-color: #f7fafc;
  color: #1a202c;
}
.panel-nav .nav-link.active {
  background-color: #f0e8ff;
  color: #212529;
  border-right: 3px solid #5900ff;
}
.panel-nav .nav-link.active i {
  color: #5900ff;
}
.panel-nav .nav-link.text-danger,
.panel-nav .nav-link.text-danger i {
  color: #dc3545 !important;
}

/* ===== STAT CARDS ===== */
.stat-card {
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 7px 29px 0 rgba(100, 100, 111, 0.12);
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 14px;
  height: 100%;
}
.stat-card i {
  width: 50px;
  height: 50px;
  min-width: 50px;
  border-radius: 12px;
  background: #5900ff;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
}
.stat-card h4 {
  font-weight: 800;
  margin: 0;
  color: #212529;
}
.stat-card p {
  margin: 0;
  font-size: 12.5px;
  color: #6c757d;
}

/* ===== SECTION CARD ===== */
.panel-section {
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 7px 29px 0 rgba(100, 100, 111, 0.12);
  padding: 24px;
  margin-bottom: 24px;
}
.panel-section-title {
  font-weight: 800;
  font-size: 1.1rem;
  margin-bottom: 20px;
  color: #212529;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* ===== ORDERS TABLE ===== */
.orders-table th {
  font-size: 12.5px;
  color: #868e96;
  font-weight: 700;
  border-bottom: 2px solid #f1f1f1;
  padding: 10px 8px;
}
.orders-table td {
  font-size: 13.5px;
  color: #212529;
  padding: 14px 8px;
  border-bottom: 1px solid #f1f1f1;
  vertical-align: middle;
}
.order-status {
  font-size: 11.5px;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: 20px;
}
.order-status.delivered {
  background: #d1f5df;
  color: #1a7f4b;
}
.order-status.shipping {
  background: #fff3cd;
  color: #a1720a;
}
.order-status.processing {
  background: #e0e7ff;
  color: #3a4bc4;
}
.order-status.cancelled {
  background: #fde2e2;
  color: #c0392b;
}

/* ===== WISHLIST ===== */
.mini-card {
  border: 1px solid #f1f1f1;
  border-radius: 12px;
  padding: 16px;
  display: flex;
  gap: 14px;
  align-items: center;
  margin-bottom: 12px;
}
.mini-card img {
  width: 60px;
  height: 60px;
  border-radius: 10px;
  object-fit: cover;
  background: #f8f9fa;
}
.mini-card .price {
  color: #5900ff;
  font-weight: 700;
  font-size: 14px;
}

/* ===== ADDRESSES ===== */
.address-card {
  border: 1px solid #f1f1f1;
  border-radius: 12px;
  padding: 18px;
  margin-bottom: 12px;
  position: relative;
}
.address-card .badge-default {
  position: absolute;
  top: 14px;
  left: 14px;
  font-size: 11px;
  background: #f0e8ff;
  color: #5900ff;
  padding: 4px 10px;
  border-radius: 20px;
  font-weight: 700;
}

/* ===== WALLET ===== */
.wallet-balance-box {
  background: linear-gradient(120deg, #212529, #343a40);
  border-radius: 14px;
  padding: 26px;
  color: #fff;
  margin-bottom: 20px;
}
.wallet-balance-box span {
  color: #adb5bd;
  font-size: 13px;
}
.wallet-balance-box h2 {
  font-weight: 800;
  color: #5900ff;
  margin: 6px 0 0 0;
}

/* ===== PANEL PAGES ===== */
.panel-page {
  display: none;
}
.panel-page.active {
  display: block;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 992px) {
  .panel-shell {
    padding: 16px;
  }
}

@media (max-width: 570px) {
  .panel-shell {
    display: flex !important;
    flex-direction: column;
    gap: 16px;
    padding: 12px;
  }

  .panel-sidebar {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    grid-template-rows: auto;
    gap: 8px;
    position: static;
    width: 100%;
    height: auto;
    top: 0;
    background: transparent;
    box-shadow: none;
    padding: 0;
  }

  .panel-profile-card {
    grid-column: span 2 / span 2;
    grid-row: 1 / auto;
    margin: 0;
  }

  .panel-nav {
    grid-column: span 3 / span 3;
    grid-row: 1 / auto;
    grid-column-start: 3;
    margin: 0;
    box-shadow: none;
    display: flex;
    flex-direction: column;
    gap: 2px;
  }

  .panel-main {
    width: 100%;
    padding: 0;
  }

  .stat-card {
    padding: 14px;
  }
  .stat-card i {
    width: 40px;
    height: 40px;
    min-width: 40px;
    font-size: 16px;
  }
  .stat-card h4 {
    font-size: 1.1rem;
  }

  .panel-nav .nav-link {
    padding: 10px 14px;
    font-size: 13px;
    border-bottom: 1px solid #f1f1f1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    flex-direction: row;
  }
  .panel-nav .nav-link:last-child {
    border-bottom: none;
  }
}

@media (max-width: 700px) {
  .stat-card {
    padding: 10px;
    justify-content: space-evenly;
  }
  .stat-card i {
    scale: 0.8;
  }
  .stat-card div {
    scale: 0.8;
  }
  .stat-card h5 {
    font-size: 1.2rem;
    position: relative;
  }
}

@media screen and (min-width: 572px) and (max-width: 678px) {
  .stat-card h5 {
    font-size: 0.9rem;
    position: relative;
  }
}

@media screen and (min-width: 768px) and (max-width: 1015px) {
  .stat-card {
    display: block;
    padding: 10px;
    justify-content: space-between;
  }
  .stat-card i {
    scale: 1;
  }
  .stat-card div {
    scale: 0.8;
  }
  .stat-card h5 {
    font-size: 1.2rem;
    position: relative;
  }
}
.accordion-button[data-bs-target="#flush-collapseFour"]::after {
  display: none !important;
}
