:root {
  --dsi-primary-color: #0cb6f4;
  --dsi-success-color: #22c55e;
  --dsi-error-color: #dc2626;
  --dsi-default-color: #6b7280;
  --dsi-border-color: #c5c5c5;
  --dsi-sky-bg: #0cb6f41a;
  --dsi-light-bg: #f5f5f5;
  --dsi-default-bg: #f8f9fa;
  --dsi-dark-text: #111111;
}

.py-8 {
  padding-top: 4rem;
  padding-bottom: 4rem;
}

.dsi-category-link,
.dsi-btn-default,
.dsi-btn-primary {
  font-size: 16px;
  font-weight: 600;
  line-height: 24px;
  background: var(--dsi-light-bg);
  color: var(--dsi-dark-text);
  border: 2px solid;
  border-color: var(--dsi-light-bg);
  padding: 7px 20px;
  border-radius: 100px;
  text-align: center;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.3s ease;
}

#product button.dsi-btn-default {
  padding: 2px 12px;
  font-size: 14px;
  font-weight: 600;
}

.dsi-btn-primary {
  background: var(--dsi-primary-color);
  color: #fff;
  border-color: var(--dsi-primary-color);
}

.dsi-category-link.active,
.dsi-category-link:hover,
.dsi-btn-default:hover,
.dsi-btn-primary:hover,
.dsi-btn-default.active,
.dsi-btn-primary.active {
  background: var(--dsi-sky-bg);
  color: var(--dsi-primary-color);
  border-color: var(--dsi-primary-color);
}

.dsi-product-card {
  transition:
    transform 0.3s,
    box-shadow 0.3s;
  height: 100%;
  width: 100%;
  display: flex;
  flex-direction: column;
  border-radius: 16px;
  background: #fafafa;
  border: #e7e7e7 solid 1px;
}

.dsi-product-card > .dsi-link {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
}

.dsi-product-card .card-body {
  flex: 1 1 auto;
}

.dsi-product-card .card-footer {
  margin-top: auto;
  margin-bottom: 0 !important;
  gap: 12px;
  flex-wrap: nowrap;
}

.dsi-product-card .card-footer .card-category {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Keep product tiles in each row at a consistent card height. */
.dsi-product-item {
  display: flex;
}

.dsi-product-card .card-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--dsi-dark-text);
  transition: color 0.3s ease;
}

.dsi-product-card .dsi-link:hover .card-title {
  color: var(--dsi-primary-color);
}

.dsi-product-card .card-category {
  font-size: 16px;
  font-weight: 400;
  color: var(--dsi-dark-text);
  transition: color 0.3s ease;
}

.dsi-product-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
  border-radius: 16px;
}

.dsi-product-image {
  height: 200px;
  object-fit: cover;
  border-radius: 16px;
}

/* Container */
.dsi-search-box {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  width: min(100%, 335px);
  margin-left: auto;
  transition: all 0.3s ease;
}

/* Input */
.dsi-search-input {
  width: 100%;
  flex: 1 1 auto;
  min-width: 0;
  height: 42px;
  padding: 10px 40px 10px 14px;
  border-radius: 50px;
  border: 1px solid var(--dsi-border-color);
  outline: none;
  transition: all 0.3s ease;
  background: var(--dsi-default-bg);
}

.dsi-clear-search {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  width: 22px;
  height: 22px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--dsi-default-color);
  line-height: 1;
  font-size: 18px;
  display: none;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
}

.dsi-clear-search:hover {
  background: var(--dsi-sky-bg);
  color: var(--dsi-default-color);
}

.dsi-clear-search.is-visible {
  display: inline-flex;
}

/* ✨ Focus Animation */
.dsi-search-box:focus-within {
  width: min(100%, 425px);
}

.dsi-search-box:focus-within .dsi-search-input {
  background: #fff;
  border-color: var(--dsi-primary-color);
  box-shadow: 0 0 0 3px rgba(12, 182, 244, 0.15);
}

/* Placeholder smooth fade */
.dsi-search-input::placeholder {
  transition: opacity 0.3s;
}

.dsi-search-input:focus::placeholder {
  opacity: 0.6;
}

.dsi-product-image-wrap {
  position: relative;
  overflow: hidden;
  background: transparent;
}
.dsi-product-image-wrap .card-img-top {
  width: 100%;
  height: 296px;
  object-fit: cover;
  object-position: center;
  display: block;
}
.dsi-product-image-wrap .dsi-no-image {
  width: 100%;
  height: 296px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--dsi-light-bg);
  border-radius: 16px;
}
@media (max-width: 767px) {
  .dsi-search-box {
    width: 100%;
  }
}

.dsi-modal-image-wrap {
  position: relative;
  background: var(--dsi-light-bg);
  border-radius: 8px;
  overflow: hidden;
}

.dsi-modal-main-img {
  width: 100%;
  height: 380px;
  object-fit: cover;
  display: block;
}

.dsi-modal-no-image {
  width: 100%;
  height: 380px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--dsi-light-bg);
  border-radius: 8px;
}

.dsi-modal-thumb-strip {
  display: flex;
  gap: 6px;
  margin-top: 10px;
  flex-wrap: wrap;
}

.dsi-modal-thumb {
  width: 64px;
  height: 64px;
  object-fit: cover;
  border-radius: 5px;
  border: 2px solid var(--dsi-border-color);
  cursor: pointer;
  transition: border-color 0.15s;
}

.dsi-modal-thumb:hover,
.dsi-modal-thumb.active {
  border-color: var(--dsi-primary-color);
}

.dsi-sp-image-wrap {
  position: relative;
  background: var(--dsi-light-bg);
  border-radius: 8px;
  overflow: hidden;
}
.dsi-sp-main-img {
  width: 100%;
  max-height: 570px;
  object-fit: cover;
  display: block;
  border-radius: 16px;
  transition: transform 0.12s ease-out;
  transform-origin: center center;
  cursor: zoom-in;
}
.dsi-sp-no-image {
  width: 100%;
  height: 470px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--dsi-light-bg);
  border-radius: 16px;
}
.dsi-sp-thumb-strip {
  display: flex;
  gap: 6px;
  margin-top: 10px;
  flex-wrap: wrap;
}
.dsi-sp-thumb-strip img {
  width: 64px;
  height: 64px;
  object-fit: cover;
  border-radius: 5px;
  border: 2px solid var(--dsi-light-bg);
  cursor: pointer;
  transition: border-color 0.15s;
}
.dsi-sp-thumb-strip img:hover,
.dsi-sp-thumb-strip img.active {
  border-color: var(--dsi-primary-color);
}

.dsi-pagination {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 28px;
}
.dsi-pagination a,
.dsi-pagination span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 10px;
  border: 1px solid var(--dsi-border-color);
  border-radius: 6px;
  text-decoration: none;
  color: var(--dsi-primary-color);
  font-size: 14px;
  background: #fff;
}
.dsi-pagination a:hover {
  background: var(--dsi-light-bg);
  border-color: var(--dsi-primary-color);
}
.dsi-pagination span.current {
  background: var(--dsi-primary-color);
  color: #fff;
  border-color: var(--dsi-primary-color);
  font-weight: 600;
}
.dsi-pagination span.disabled {
  color: var(--dsi-default-color);
  cursor: not-allowed;
  background: var(--dsi-light-bg);
}

.pickup-info {
  font-size: 1rem;
  line-height: 24px;
  padding: 10px 20px;
  border-radius: 12px;
  background: var(--dsi-light-bg);
}

.dsi-upload-box {
  border: 2px dashed var(--dsi-border-color);
  border-radius: 10px;
  padding: 13px 20px 9px;
  text-align: center;
  cursor: pointer;
  transition:
    border-color 0.2s,
    background 0.2s;
  position: relative;
}

.dsi-upload-box.dragover {
  border-color: var(--dsi-primary-color);
  background: var(--dsi-sky-bg);
}

.dsi-file-input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  width: 100%;
  height: 100%;
  z-index: 2;
}

.dsi-drop-zone-inner {
  pointer-events: none;
  position: relative;
  z-index: 1;
}

#dsi-upload-preview {
  position: relative;
  z-index: 3;
}

.dsi-upload-icon {
  width: 40px;
  height: 40px;
  color: var(--dsi-dark-text);
  margin-bottom: 8px;
}

.dsi-drop-label {
  font-size: 1rem;
  font-weight: 500;
  color: var(--dsi-dark-text);
}

.dsi-file-entry + .dsi-file-entry {
  margin-top: 6px;
}

#dsi-upload-preview .file-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 10px;
  border: 1px solid var(--dsi-light-bg);
  border-radius: 6px;
  background: transparent;
  font-size: 0.875rem;
  gap: 8px;
}

#dsi-upload-preview .dsi-file-type {
  flex-shrink: 0;
  width: auto;
  min-width: 110px;
  font-size: 0.8rem;
}

#dsi-upload-preview .file-info {
  display: flex;
  flex-direction: column;
  text-align: left;
  overflow: hidden;
}

#dsi-upload-preview .file-name {
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 220px;
}

#dsi-upload-preview .file-size {
  font-size: 0.78rem;
  color: var(--dsi-dark-text);
}

.dsi-remove-file,
.dsi-remove-item {
  cursor: pointer;
  color: var(--dsi-default-color);
  font-size: 1rem;
  flex-shrink: 0;
  background: none;
  border: none;
  padding: 0 4px;
  line-height: 1;
}

.dsi-remove-file:hover,
.dsi-remove-item:hover {
  color: var(--dsi-error-color);
}

.dsi-image-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
  min-height: 0;
}

.dsi-image-item {
  position: relative;
  width: 72px;
}

.dsi-image-item img {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border: 1px solid #dcdcde;
  border-radius: 4px;
  display: block;
}

.dsi-image-item a.dsi-remove-img {
  position: absolute;
  top: -6px;
  right: -6px;
  width: 18px;
  height: 18px;
  line-height: 16px;
  text-align: center;
  background: var(--dsi-error-color);
  color: #fff;
  border-radius: 50%;
  font-size: 12px;
  font-weight: bold;
  text-decoration: none;
  display: block;
  cursor: pointer;
  border: 1px solid #fff;
}

.dsi-image-item a.dsi-remove-img:hover {
  background: rgba(220, 53, 69, 0.25);
}

.dsi-img-actions {
  display: flex;
  gap: 6px;
  align-items: center;
  flex-wrap: wrap;
}

#dsi-upload-preview .dsi-upload-btn {
  flex-shrink: 0;
  padding: 2px 8px;
  font-size: 0.8rem;
  line-height: 1.4;
}

.dsi-zone-type-wrap {
  position: relative;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--dsi-border-color);
}

.dsi-zone-type-label {
  font-size: 0.8rem;
  color: var(--dsi-default-color);
  white-space: nowrap;
  margin: 0;
}

#dsi-zone-type {
  flex: 1;
  font-size: 0.85rem;
}

#dsi-zone-type.is-invalid {
  border-color: var(--dsi-error-color);
  box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25);
}

.dsi-pending-hint {
  width: 100%;
  margin: 4px 0 0;
  font-size: 0.78rem;
  color: var(--dsi-error-color);
}

.dsi-file-missing-msg {
  margin: 8px 0 8px;
  padding: 8px 12px;
  font-size: 0.85rem;
  color: var(--dsi-error-color);
  background: var(--dsi-error-bg);
  border: 1px solid var(--dsi-error-border);
  border-radius: 6px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 100px;
  text-transform: capitalize;
  line-height: 1;
}

.badge.info {
  background: #e7f1ff;
  color: #0d6efd;
}

.badge.pending {
  background: #fff3cd;
  color: #856404;
}

.badge.error {
  background: #f8d7da;
  color: #dc2626;
}

.badge.success {
  background: #d1e7dd;
  color: #198754;
}

.dsi-progress-wrap {
  height: 5px;
  background: var(--dsi-light-bg);
  border-radius: 3px;
  margin-top: 6px;
  overflow: hidden;
}

.dsi-progress-bar {
  height: 100%;
  width: 0%;
  border-radius: 3px;
  transition: width 0.2s ease;
  background: var(--dsi-primary-color);
}

.dsi-progress-bar.success {
  background: var(--dsi-success-color);
}

.dsi-progress-bar.error {
  background: var(--dsi-error-color);
}

.dsi-upload-error {
  margin-top: 6px;
  padding: 6px 10px;
  font-size: 0.8rem;
  color: var(--dsi-error-color);
  background: var(--dsi-error-bg);
  border: 1px solid var(--dsi-error-border);
  border-radius: 4px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.dsi-upload-error i {
  flex-shrink: 0;
}

.dsi-cart-sidebar {
  max-height: 80vh;
  overflow-y: auto;
}

.dsi-toast-container {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 9999;
}

.modal.fade .modal-dialog {
  transform: scale(0.8);
  transition: all 0.3s ease;
}

.modal.show .modal-dialog {
  transform: scale(1);
}

.is-invalid {
  border-color: var(--dsi-error-color) !important;
}

#dsi-checkout-form-container .dsi-native-payment-select {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.dsi-checkout-form input,
.dsi-checkout-form select {
  background: #f5fcfe;
  border: 1px solid #f5fcfe;
  border-radius: 14px;
  padding: 10px;
  width: 100%;
}

.dsi-checkout-form input[type="checkbox"],
.dsi-checkout-form input[type="radio"] {
  appearance: none;
  -webkit-appearance: none;
  width: 12px;
  height: 12px;
  border: 2px solid var(--dsi-border-color);
  border-radius: 6px;
  display: inline-block;
  position: relative;
  cursor: pointer;
}

.dsi-checkout-form input[type="checkbox"]:checked,
.dsi-checkout-form input[type="radio"]:checked {
  background-color: var(--dsi-primary-color);
  border-color: var(--dsi-primary-color);
}

.dsi-checkout-form input[type="checkbox"]:checked::after {
  content: "\f00c"; /* FontAwesome check */
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  color: #fff;
  position: absolute;
  font-size: 12px;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.dsi-checkout-form input:focus,
.dsi-checkout-form select:focus {
  background: #fff;
  border-color: var(--dsi-primary-color);
  box-shadow: 0 0 0 3px rgba(12, 182, 244, 0.15);
  outline: none;
}

.dsi-checkout-form .text-required {
  color: #5aafe1;
  transition: opacity 0.3s ease;
}

.dsi-checkout-form input::placeholder,
.dsi-checkout-form select::placeholder {
  color: #9ca3af;
  transition: opacity 0.3s ease;
}

.dsi-checkout-form select {
  appearance: none;
  background-image: url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A//www.w3.org/2000/svg%22%20width%3D%2212%22%20height%3D%228%22%20viewBox%3D%220%200%2012%208%22%3E%3Cpath%20fill%3D%22%236b7280%22%20d%3D%22M6.70710678,7.70710678 C6.31658249,8.09763107 5.68341751,8.09763107 5.29289322,7.70710678 L0.292893219,2.70710678 C-0.0976310659,2.31658249 -0.0976310659,1.68341751 0.292893219,1.29289322 C0.68341751,0.902368933 1.31658249,0.902368933 1.70710678,1.29289322 L6,5.58578644 L10.2928932,1.29289322 C10.6834175,0.902368933 11.3165825,0.902368933 11.7071068,1.29289322 C12.0976311,1.68341751 12.0976311,2.31658249 11.7071068,2.70710678 L6.70710678,7.70710678 Z%22/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
}

#dsi-checkout-form-container .dsi-payment-panel {
  border: 1px solid #c9c9c9;
  border-radius: 12px;
  background: #f5f5f5;
  overflow: hidden;
}

#dsi-checkout-form-container .dsi-payment-option {
  border-bottom: 1px solid #d7d7d7;
}

#dsi-checkout-form-container .dsi-payment-option:last-child {
  border-bottom: 0;
}

#dsi-checkout-form-container .dsi-payment-radio {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

#dsi-checkout-form-container .dsi-payment-option-label {
  position: relative;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin: 0;
  padding: 14px 16px 14px 54px;
  background: white;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

#dsi-checkout-form-container .dsi-payment-option-label::before {
  content: "";
  position: absolute;
  left: 16px;
  top: 50%;
  width: 20px;
  height: 20px;
  border: 1px solid #c4c8cf;
  border-radius: 50%;
  background: #fff;
  transform: translateY(-50%);
}

#dsi-checkout-form-container .dsi-payment-option-label::after {
  content: "";
  position: absolute;
  left: 22px;
  top: 50%;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--dsi-primary-color);
  transform: translateY(-50%) scale(0);
  transition: transform 0.15s ease;
}

#dsi-checkout-form-container .dsi-payment-option-title {
  font-size: 1.05rem;
  font-weight: 600;
  color: #1d1f23;
}

#dsi-checkout-form-container .dsi-payment-option-subtitle {
  font-size: 0.88rem;
  color: #6f7276;
}

#dsi-checkout-form-container .dsi-card-brands {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

#dsi-checkout-form-container .dsi-payment-option-body {
  display: none;
  padding: 16px;
  background: #f4f4f4;
}

#dsi-checkout-form-container
  .dsi-payment-radio:checked
  + .dsi-payment-option-label {
  background: #f5f6ff;
  border: 1px solid var(--dsi-primary-color);
}

#dsi-checkout-form-container
  .dsi-payment-option:first-of-type
  .dsi-payment-radio:checked
  + .dsi-payment-option-label {
  border-radius: 12px 12px 0 0;
}

#dsi-checkout-form-container
  .dsi-payment-radio:checked
  + .dsi-payment-option-label::before {
  border-color: var(--dsi-primary-color);
}

#dsi-checkout-form-container
  .dsi-payment-radio:checked
  + .dsi-payment-option-label::after {
  transform: translateY(-50%) scale(1);
}

#dsi-checkout-form-container
  .dsi-payment-radio:checked
  + .dsi-payment-option-label
  .dsi-payment-option-title {
  color: #0f172a;
}

#dsi-checkout-form-container
  .dsi-payment-radio:checked
  + .dsi-payment-option-label
  + .dsi-payment-option-body {
  display: block;
}

#dsi-checkout-form-container #card-element {
  min-height: 46px;
  background: #fff;
  border: 1px solid #d6d6d6;
  border-radius: 10px;
  padding: 12px;
}

#dsi-checkout-form-container #paypal-button-container {
  min-height: 44px;
}

@media (max-width: 575px) {
  #dsi-checkout-form-container .dsi-payment-option-title {
    font-size: 0.96rem;
  }
}
