/*-----------------------------------*\
 * #ecommerce.css
 * Custom styles for functional e-commerce components
\*-----------------------------------*/

/* Custom variables and theme colors extending style.css */
:root {
  --glass-bg: rgba(255, 255, 255, 0.85);
  --glass-border: rgba(255, 255, 255, 0.4);
  --box-shadow-premium: 0 10px 30px -5px rgba(0, 0, 0, 0.1), 0 5px 15px -8px rgba(0, 0, 0, 0.05);
  --box-shadow-hover: 0 20px 40px -5px rgba(0, 0, 0, 0.15), 0 10px 20px -8px rgba(0, 0, 0, 0.1);
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 24px;
}

/* ==========================================================================
   TOAST NOTIFICATIONS
   ========================================================================== */
#toast-container {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 12px;
  pointer-events: none;
  max-width: 380px;
  width: 100%;
}

.toast-notification {
  pointer-events: auto;
  background: var(--white);
  border-left: 5px solid var(--bittersweet);
  padding: 16px;
  border-radius: var(--radius-sm);
  box-shadow: var(--box-shadow-premium);
  display: flex;
  align-items: center;
  gap: 12px;
  transform: translateX(120%);
  transition: transform 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.3s ease;
  opacity: 0;
  position: relative;
  overflow: hidden;
}

.toast-notification.show {
  transform: translateX(0);
  opacity: 1;
}

.toast-notification.success {
  border-left-color: #10b981;
}

.toast-notification.info {
  border-left-color: #3b82f6;
}

.toast-notification.warning {
  border-left-color: #f59e0b;
}

.toast-icon {
  font-size: 24px;
  flex-shrink: 0;
}

.toast-notification.success .toast-icon { color: #10b981; }
.toast-notification.info .toast-icon { color: #3b82f6; }
.toast-notification.warning .toast-icon { color: #f59e0b; }

.toast-content {
  flex-grow: 1;
}

.toast-title {
  font-family: var(--ff-roboto);
  font-weight: var(--fw-700);
  font-size: 1.4rem;
  margin-bottom: 2px;
  color: var(--rich-black-fogra-29);
}

.toast-msg {
  font-size: 1.2rem;
  color: var(--onyx);
}

.toast-close {
  color: var(--gray-x-11-gray);
  cursor: pointer;
  font-size: 16px;
  transition: var(--transition-1);
}

.toast-close:hover {
  color: var(--bittersweet);
}

.toast-progress {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 3px;
  background: var(--bittersweet);
  width: 100%;
}

.toast-notification.success .toast-progress { background: #10b981; }
.toast-notification.info .toast-progress { background: #3b82f6; }
.toast-notification.warning .toast-progress { background: #f59e0b; }

/* ==========================================================================
   DRAWERS (CART & WISHLIST)
   ========================================================================== */
.drawer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.drawer-overlay.active {
  opacity: 1;
  pointer-events: all;
}

.drawer-panel {
  position: fixed;
  top: 0;
  right: -450px;
  width: 420px;
  max-width: 100%;
  height: 100%;
  background: var(--white);
  box-shadow: -10px 0 30px rgba(0, 0, 0, 0.15);
  z-index: 1001;
  display: flex;
  flex-direction: column;
  transition: right 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.drawer-panel.active {
  right: 0;
}

.drawer-header {
  padding: 20px;
  border-bottom: 1px solid var(--gainsboro);
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--cultured);
}

.drawer-title {
  font-family: var(--ff-josefin-sans);
  font-size: var(--fs-4);
  font-weight: var(--fw-700);
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--rich-black-fogra-29);
}

.drawer-title ion-icon {
  font-size: 24px;
}

.drawer-close-btn {
  font-size: 24px;
  color: var(--rich-black-fogra-29);
  transition: var(--transition-1);
}

.drawer-close-btn:hover {
  color: var(--bittersweet);
}

.drawer-body {
  flex-grow: 1;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.drawer-empty-state {
  margin: auto;
  text-align: center;
  color: var(--gray-x-11-gray);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.drawer-empty-state ion-icon {
  font-size: 64px;
}

.drawer-footer {
  padding: 20px;
  border-top: 1px solid var(--gainsboro);
  background: var(--cultured);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Items in Drawer */
.drawer-item {
  display: flex;
  gap: 12px;
  padding-bottom: 15px;
  border-bottom: 1px solid var(--gainsboro);
}

.drawer-item-img {
  width: 80px;
  height: 80px;
  background: var(--cultured);
  border-radius: var(--radius-sm);
  overflow: hidden;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.drawer-item-img img {
  width: 90%;
  height: 90%;
  object-fit: contain;
}

.drawer-item-details {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.drawer-item-title {
  font-size: 1.4rem;
  font-weight: var(--fw-600);
  color: var(--rich-black-fogra-29);
  line-height: 1.3;
}

.drawer-item-variant {
  font-size: 1.1rem;
  color: var(--onyx);
  margin-top: 2px;
}

.drawer-item-price {
  font-family: var(--ff-roboto);
  font-size: 1.4rem;
  color: var(--bittersweet);
  font-weight: var(--fw-600);
  margin-top: 4px;
}

.drawer-item-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 8px;
}

.quantity-picker {
  display: flex;
  align-items: center;
  border: 1px solid var(--gainsboro);
  border-radius: 30px;
  overflow: hidden;
  background: var(--white);
}

.qty-btn {
  padding: 6px 12px;
  font-size: 1.2rem;
  font-weight: bold;
  color: var(--rich-black-fogra-29);
  transition: var(--transition-1);
}

.qty-btn:hover {
  background: var(--gainsboro);
}

.qty-val {
  padding: 0 10px;
  font-size: 1.3rem;
  font-family: var(--ff-roboto);
  font-weight: var(--fw-600);
}

.item-remove-btn {
  font-size: 18px;
  color: var(--gray-x-11-gray);
  transition: var(--transition-1);
}

.item-remove-btn:hover {
  color: var(--bittersweet);
}

/* Cart Summary Layout */
.cart-summary-line {
  display: flex;
  justify-content: space-between;
  font-size: 1.4rem;
  color: var(--onyx);
}

.cart-summary-line.total {
  font-size: 1.8rem;
  font-weight: var(--fw-700);
  color: var(--rich-black-fogra-29);
  border-top: 1px dashed var(--gray-x-11-gray);
  padding-top: 10px;
  margin-top: 5px;
}

.promo-code-box {
  display: flex;
  gap: 8px;
  margin-bottom: 5px;
}

.promo-input {
  border: 1px solid var(--gainsboro);
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  background: var(--white);
  font-size: 1.3rem;
}

.promo-btn {
  background: var(--rich-black-fogra-29);
  color: var(--white);
  padding: 8px 15px;
  border-radius: var(--radius-sm);
  font-size: 1.3rem;
  font-weight: var(--fw-600);
  transition: var(--transition-1);
}

.promo-btn:hover {
  background: var(--bittersweet);
}

/* Wishlist actions */
.wishlist-to-cart-btn {
  background: var(--bittersweet);
  color: var(--white);
  border-radius: 30px;
  font-size: 1.2rem;
  padding: 6px 12px;
  font-weight: var(--fw-600);
  display: flex;
  align-items: center;
  gap: 4px;
}

.wishlist-to-cart-btn:hover {
  background: var(--salmon);
}

/* ==========================================================================
   MODAL DIALOGS (GENERAL FRAMEWORK)
   ========================================================================== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(5px);
  z-index: 2000;
  opacity: 0;
  pointer-events: none;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  transition: opacity 0.3s ease;
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: all;
}

.modal-wrapper {
  background: var(--white);
  border-radius: var(--radius-md);
  box-shadow: var(--box-shadow-premium);
  max-width: 800px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  transform: scale(0.9);
  transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.15);
}

.modal-overlay.active .modal-wrapper {
  transform: scale(1);
}

.modal-close {
  position: absolute;
  top: 15px;
  right: 15px;
  font-size: 24px;
  color: var(--rich-black-fogra-29);
  z-index: 10;
  cursor: pointer;
  transition: var(--transition-1);
}

.modal-close:hover {
  color: var(--bittersweet);
}

/* ==========================================================================
   QUICK VIEW MODAL
   ========================================================================== */
.quickview-container {
  display: grid;
  grid-template-columns: 1fr;
  gap: 25px;
  padding: 30px;
}

@media (min-width: 600px) {
  .quickview-container {
    grid-template-columns: 1fr 1.2fr;
  }
}

.quickview-media {
  background: var(--cultured);
  border-radius: var(--radius-md);
  padding: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 320px;
}

.quickview-media img {
  max-height: 100%;
  max-width: 100%;
  object-fit: contain;
}

.quickview-details {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.quickview-brand {
  font-size: 1.2rem;
  text-transform: uppercase;
  color: var(--gray-x-11-gray);
  font-weight: var(--fw-700);
}

.quickview-title {
  font-size: 2.4rem;
  color: var(--rich-black-fogra-29);
  line-height: 1.2;
}

.quickview-price-row {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--ff-roboto);
}

.quickview-price {
  font-size: 2.2rem;
  color: var(--bittersweet);
  font-weight: var(--fw-700);
}

.quickview-old-price {
  font-size: 1.6rem;
  color: var(--gray-x-11-gray);
  text-decoration: line-through;
}

.quickview-rating {
  display: flex;
  align-items: center;
  gap: 4px;
  color: #f59e0b;
  font-size: 1.4rem;
}

.quickview-rating-text {
  color: var(--onyx);
  font-size: 1.2rem;
  margin-left: 6px;
}

.quickview-desc {
  font-size: 1.4rem;
  color: var(--onyx);
  line-height: 1.6;
}

/* Variant selectors */
.quickview-selectors {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.selector-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.selector-label {
  font-size: 1.3rem;
  font-weight: var(--fw-700);
  color: var(--rich-black-fogra-29);
  text-transform: uppercase;
}

.size-options {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.size-pill {
  border: 1px solid var(--gainsboro);
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-size: 1.3rem;
  font-family: var(--ff-roboto);
  cursor: pointer;
  transition: var(--transition-1);
}

.size-pill:hover {
  border-color: var(--rich-black-fogra-29);
}

.size-pill.active {
  background: var(--rich-black-fogra-29);
  color: var(--white);
  border-color: var(--rich-black-fogra-29);
}

.color-options {
  display: flex;
  gap: 12px;
}

.color-dot {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  cursor: pointer;
  border: 2px solid transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  transition: var(--transition-1);
}

.color-dot:hover {
  transform: scale(1.1);
}

.color-dot.active {
  border-color: var(--rich-black-fogra-29);
  transform: scale(1.15);
}

.color-dot-inner {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 1px solid rgba(0, 0, 0, 0.1);
}

.quickview-actions {
  display: flex;
  gap: 12px;
  margin-top: 10px;
}

.quickview-add-cart {
  flex-grow: 1;
  justify-content: center;
  border-radius: var(--radius-sm);
}

.quickview-wishlist-toggle {
  background: var(--cultured);
  border: 1px solid var(--gainsboro);
  color: var(--rich-black-fogra-29);
  font-size: 20px;
  padding: 12px;
  border-radius: var(--radius-sm);
  transition: var(--transition-1);
}

.quickview-wishlist-toggle:hover {
  background: var(--gainsboro);
}

.quickview-wishlist-toggle.active {
  color: var(--bittersweet);
  background: hsla(5, 100%, 69%, 0.1);
  border-color: var(--bittersweet);
}

/* ==========================================================================
   COMPARE FLOATING BAR & COMPARISON MODAL
   ========================================================================== */
#compare-bar {
  position: fixed;
  bottom: -100px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--rich-black-fogra-29);
  color: var(--white);
  padding: 12px 24px;
  border-radius: 40px 40px 0 0;
  display: flex;
  align-items: center;
  gap: 20px;
  box-shadow: 0 -5px 25px rgba(0,0,0,0.25);
  z-index: 999;
  transition: bottom 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

#compare-bar.active {
  bottom: 0;
}

.compare-bar-items {
  display: flex;
  gap: 10px;
}

.compare-bar-thumb {
  width: 40px;
  height: 40px;
  background: var(--white);
  border-radius: 50%;
  border: 2px solid var(--bittersweet);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.compare-bar-thumb img {
  width: 80%;
  height: 80%;
  object-fit: contain;
}

.compare-bar-remove {
  position: absolute;
  top: -2px;
  right: -2px;
  background: red;
  color: white;
  font-size: 10px;
  border-radius: 50%;
  width: 14px;
  height: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.compare-btn {
  background: var(--bittersweet);
  color: var(--white);
  padding: 8px 20px;
  border-radius: 20px;
  font-size: 1.3rem;
  font-weight: var(--fw-600);
}

.compare-btn:hover {
  background: var(--salmon);
}

.compare-clear-btn {
  color: var(--gray-x-11-gray);
  font-size: 1.3rem;
}

.compare-clear-btn:hover {
  color: var(--white);
}

/* Compare Matrix inside Modal */
.compare-modal-content {
  padding: 30px;
}

.compare-modal-title {
  font-size: 2.2rem;
  margin-bottom: 20px;
  color: var(--rich-black-fogra-29);
  text-align: center;
}

.compare-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 10px;
}

.compare-table th, .compare-table td {
  padding: 12px 16px;
  border: 1px solid var(--gainsboro);
  text-align: center;
  font-size: 1.4rem;
}

.compare-table th {
  background: var(--cultured);
  font-weight: var(--fw-700);
  color: var(--rich-black-fogra-29);
  width: 25%;
}

.compare-table td.compare-header-cell {
  background: var(--white);
}

.compare-table-img {
  width: 120px;
  height: 120px;
  background: var(--cultured);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 10px;
}

.compare-table-img img {
  max-width: 90%;
  max-height: 90%;
  object-fit: contain;
}

.compare-table-name {
  font-weight: var(--fw-700);
  font-size: 1.4rem;
  color: var(--rich-black-fogra-29);
  line-height: 1.3;
}

.compare-table .compare-price {
  color: var(--bittersweet);
  font-weight: var(--fw-700);
  font-family: var(--ff-roboto);
}

.compare-color-pills, .compare-size-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  justify-content: center;
}

.compare-color-pill {
  padding: 2px 8px;
  background: var(--cultured);
  border-radius: 10px;
  font-size: 1.1rem;
  border: 1px solid var(--gainsboro);
}

.compare-size-pill {
  padding: 2px 6px;
  background: var(--cultured);
  border-radius: 4px;
  font-size: 1.1rem;
  font-family: var(--ff-roboto);
}

.compare-remove-cell-btn {
  background: var(--rich-black-fogra-29);
  color: var(--white);
  font-size: 1.1rem;
  padding: 6px 12px;
  border-radius: 4px;
  margin: 10px auto 0;
}

.compare-remove-cell-btn:hover {
  background: var(--bittersweet);
}

/* ==========================================================================
   LIVE SEARCH OVERLAY
   ========================================================================== */
.search-overlay {
  position: fixed;
  inset: 0;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(10px);
  z-index: 1500;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 40px 20px;
}

.search-overlay.active {
  opacity: 1;
  pointer-events: all;
}

.search-container {
  max-width: 650px;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 30px;
  margin-top: 60px;
}

.search-field-wrapper {
  display: flex;
  align-items: center;
  border-bottom: 2px solid var(--rich-black-fogra-29);
  padding-bottom: 10px;
}

.search-field-wrapper ion-icon {
  font-size: 28px;
  color: var(--rich-black-fogra-29);
}

.search-input-field {
  font-family: var(--ff-josefin-sans);
  font-size: 2.4rem;
  font-weight: var(--fw-500);
  color: var(--rich-black-fogra-29);
  padding: 0 15px;
}

.search-input-field::placeholder {
  color: var(--gray-x-11-gray);
}

.search-close-btn {
  position: absolute;
  top: 30px;
  right: 30px;
  font-size: 32px;
  color: var(--rich-black-fogra-29);
  cursor: pointer;
  transition: var(--transition-1);
}

.search-close-btn:hover {
  color: var(--bittersweet);
}

.search-results-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: 55vh;
  overflow-y: auto;
  padding-right: 10px;
}

.search-result-item {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 10px;
  border-radius: var(--radius-sm);
  transition: var(--transition-1);
  cursor: pointer;
  border: 1px solid transparent;
}

.search-result-item:hover {
  background: var(--cultured);
  border-color: var(--gainsboro);
}

.search-result-img {
  width: 60px;
  height: 60px;
  background: var(--white);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--gainsboro);
}

.search-result-img img {
  max-width: 90%;
  max-height: 90%;
  object-fit: contain;
}

.search-result-info {
  flex-grow: 1;
}

.search-result-title {
  font-size: 1.5rem;
  font-weight: var(--fw-600);
  color: var(--rich-black-fogra-29);
}

.search-result-brand {
  font-size: 1.1rem;
  color: var(--gray-x-11-gray);
  text-transform: uppercase;
}

.search-result-price {
  font-family: var(--ff-roboto);
  font-size: 1.4rem;
  font-weight: var(--fw-600);
  color: var(--bittersweet);
}

/* ==========================================================================
   CHECKOUT WIZARD (MODAL FLOW)
   ========================================================================== */
.checkout-container {
  padding: 30px;
}

.checkout-steps {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
  position: relative;
  max-width: 500px;
  margin-inline: auto;
}

.checkout-steps::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--gainsboro);
  z-index: 1;
  transform: translateY(-50%);
}

.checkout-step-progress {
  position: absolute;
  top: 50%;
  left: 0;
  width: 0%;
  height: 2px;
  background: var(--bittersweet);
  z-index: 2;
  transform: translateY(-50%);
  transition: width 0.3s ease;
}

.checkout-step-dot {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--white);
  border: 2px solid var(--gainsboro);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  font-weight: var(--fw-700);
  position: relative;
  z-index: 3;
  transition: var(--transition-1);
}

.checkout-step-dot.active {
  border-color: var(--bittersweet);
  background: var(--bittersweet);
  color: var(--white);
}

.checkout-step-dot.done {
  border-color: #10b981;
  background: #10b981;
  color: var(--white);
}

.checkout-panel {
  display: none;
  animation: fadeIn 0.4s ease;
}

.checkout-panel.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.checkout-form-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 15px;
  margin-bottom: 20px;
}

@media (min-width: 600px) {
  .checkout-form-grid {
    grid-template-columns: 1fr 1fr;
  }
  .form-full-width {
    grid-column: span 2;
  }
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group label {
  font-size: 1.2rem;
  font-weight: var(--fw-700);
  color: var(--rich-black-fogra-29);
}

.form-input {
  border: 1px solid var(--gainsboro);
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 1.4rem;
  background: var(--white);
  transition: var(--transition-1);
}

.form-input:focus {
  border-color: var(--bittersweet);
  outline: none;
}

.checkout-footer-nav {
  display: flex;
  justify-content: space-between;
  margin-top: 30px;
  border-top: 1px solid var(--gainsboro);
  padding-top: 20px;
}

.checkout-summary-scroll {
  max-height: 250px;
  overflow-y: auto;
  border: 1px solid var(--gainsboro);
  border-radius: var(--radius-sm);
  padding: 15px;
  margin-bottom: 20px;
  background: var(--cultured);
}

.checkout-summary-item {
  display: flex;
  justify-content: space-between;
  font-size: 1.3rem;
  padding-bottom: 8px;
  margin-bottom: 8px;
  border-bottom: 1px solid rgba(0,0,0,0.05);
}

/* Payment Spinner */
.payment-loader {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  gap: 20px;
}

.spinner {
  width: 50px;
  height: 50px;
  border: 4px solid var(--gainsboro);
  border-top-color: var(--bittersweet);
  border-radius: 50%;
  animation: spin 1s infinite linear;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.checkout-success-view {
  text-align: center;
  padding: 40px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
}

.success-checkmark {
  font-size: 64px;
  color: #10b981;
  background: rgba(16, 185, 129, 0.1);
  padding: 20px;
  border-radius: 50%;
}

.success-order-id {
  font-family: var(--ff-roboto);
  font-weight: var(--fw-700);
  background: var(--cultured);
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 1.3rem;
  margin-top: 5px;
}

/* ==========================================================================
   ADMIN / CUSTOMER DASHBOARD MODAL
   ========================================================================== */
.dashboard-container {
  display: flex;
  flex-direction: column;
  min-height: 500px;
}

@media (min-width: 768px) {
  .dashboard-container {
    flex-direction: row;
  }
}

.dashboard-sidebar {
  width: 100%;
  background: var(--cultured);
  border-bottom: 1px solid var(--gainsboro);
  padding: 20px;
  display: flex;
  flex-direction: row;
  gap: 10px;
  flex-wrap: wrap;
}

@media (min-width: 768px) {
  .dashboard-sidebar {
    width: 220px;
    border-bottom: none;
    border-right: 1px solid var(--gainsboro);
    flex-direction: column;
    flex-wrap: nowrap;
    padding: 30px 20px;
    gap: 15px;
  }
}

.dashboard-tab-btn {
  font-family: var(--ff-josefin-sans);
  font-size: 1.4rem;
  font-weight: var(--fw-600);
  color: var(--onyx);
  padding: 10px 15px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  gap: 8px;
  width: auto;
  transition: var(--transition-1);
}

@media (min-width: 768px) {
  .dashboard-tab-btn {
    width: 100%;
  }
}

.dashboard-tab-btn:hover {
  background: rgba(0,0,0,0.05);
}

.dashboard-tab-btn.active {
  background: var(--rich-black-fogra-29);
  color: var(--white);
}

.dashboard-tab-btn ion-icon {
  font-size: 18px;
}

.dashboard-content {
  flex-grow: 1;
  padding: 30px;
  overflow-y: auto;
  max-height: 80vh;
}

.dashboard-section {
  display: none;
  animation: fadeIn 0.4s ease;
}

.dashboard-section.active {
  display: block;
}

.dashboard-section-title {
  font-size: 2.2rem;
  margin-bottom: 20px;
  color: var(--rich-black-fogra-29);
  border-bottom: 1px solid var(--gainsboro);
  padding-bottom: 10px;
}

/* Orders History List */
.orders-list {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.order-card {
  border: 1px solid var(--gainsboro);
  border-radius: var(--radius-sm);
  background: var(--white);
  overflow: hidden;
}

.order-card-header {
  background: var(--cultured);
  padding: 12px 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  border-bottom: 1px solid var(--gainsboro);
}

.order-meta {
  display: flex;
  gap: 15px;
  font-size: 1.2rem;
  color: var(--onyx);
}

.order-status-badge {
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 1.1rem;
  font-weight: var(--fw-700);
}

.order-status-badge.pending { background: #fef3c7; color: #d97706; }
.order-status-badge.processing { background: #dbeafe; color: #2563eb; }
.order-status-badge.completed { background: #d1fae5; color: #059669; }

.order-card-body {
  padding: 15px;
}

.order-summary-details {
  font-size: 1.3rem;
  color: var(--onyx);
  margin-top: 10px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  border-top: 1px dashed var(--gainsboro);
  padding-top: 10px;
}

/* Analytics Stats Grid */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 15px;
  margin-bottom: 25px;
}

.stat-card {
  background: var(--cultured);
  border: 1px solid var(--gainsboro);
  border-radius: var(--radius-sm);
  padding: 15px;
  text-align: center;
}

.stat-val {
  font-family: var(--ff-roboto);
  font-size: 2.2rem;
  font-weight: var(--fw-700);
  color: var(--bittersweet);
  margin-top: 4px;
}

.stat-lbl {
  font-size: 1.2rem;
  color: var(--onyx);
  text-transform: uppercase;
}

/* Simulated Analytics Chart */
.chart-container {
  border: 1px solid var(--gainsboro);
  border-radius: var(--radius-sm);
  padding: 20px;
  background: var(--white);
}

.chart-title {
  font-size: 1.4rem;
  font-weight: var(--fw-700);
  margin-bottom: 15px;
  color: var(--rich-black-fogra-29);
}

.svg-chart {
  width: 100%;
  height: 200px;
  overflow: visible;
}

/* Product catalog manage dashboard */
.manage-catalog-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

@media (min-width: 900px) {
  .manage-catalog-grid {
    grid-template-columns: 1.2fr 1fr;
  }
}

.add-product-form {
  background: var(--cultured);
  border: 1px solid var(--gainsboro);
  padding: 20px;
  border-radius: var(--radius-sm);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.add-product-btn {
  background: var(--bittersweet);
  color: var(--white);
  padding: 12px;
  font-weight: var(--fw-600);
  border-radius: var(--radius-sm);
  margin-top: 10px;
  text-align: center;
}

.add-product-btn:hover {
  background: var(--salmon);
}

.catalog-manage-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 450px;
  overflow-y: auto;
  padding-right: 5px;
}

.catalog-manage-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px;
  border: 1px solid var(--gainsboro);
  border-radius: var(--radius-sm);
}

.catalog-manage-img {
  width: 50px;
  height: 50px;
  background: var(--cultured);
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.catalog-manage-img img {
  max-width: 90%;
  max-height: 90%;
  object-fit: contain;
}

.catalog-manage-info {
  flex-grow: 1;
}

.catalog-manage-name {
  font-size: 1.3rem;
  font-weight: var(--fw-600);
}

.catalog-manage-price {
  font-family: var(--ff-roboto);
  font-size: 1.2rem;
  color: var(--bittersweet);
}

.catalog-delete-btn {
  color: red;
  font-size: 18px;
  padding: 8px;
  cursor: pointer;
}

/* Dynamic product cards badges */
.card-badge.sale {
  background: var(--black);
}

/* Custom Sorting dropdown in UI */
.catalog-control-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 15px;
  margin-bottom: 25px;
}

.sorting-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
}

.sorting-wrapper label {
  font-size: 1.3rem;
  font-weight: var(--fw-600);
  color: var(--rich-black-fogra-29);
}

.sorting-select {
  border: 1px solid var(--gainsboro);
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  background: var(--white);
  font-size: 1.3rem;
  color: var(--onyx);
  outline: none;
  cursor: pointer;
}

.sorting-select:focus {
  border-color: var(--bittersweet);
}

/* Additional UI indicators */
.nav-action-btn {
  position: relative;
}

/* Wishlist heart toggle states in catalog */
.card-action-btn.wishlisted {
  background: var(--bittersweet);
  color: var(--white);
}

.card-action-btn.compared {
  background: var(--rich-black-fogra-29);
  color: var(--white);
}
