.sales-workspace {
  color: #602238;
  background: #fff9f6;
  grid-template-columns: 230px minmax(0, 1fr);
  min-height: 100vh;
  display: grid;
}

.sales-sidebar {
  background: #fff8f5;
  min-height: 100vh;
  position: sticky;
  top: 0;
}

.sales-main {
  min-width: 0;
  padding: 26px clamp(14px, 2.8vw, 42px) 70px;
}

.sales-hero {
  background: linear-gradient(110deg, #ffe4e2, #fff2ec);
  border-radius: 18px;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  margin-bottom: 20px;
  padding: 28px 30px;
  display: flex;
}

.sales-hero h1 {
  color: #8e163b;
  font-family: Playfair Display, serif;
  font-size: clamp(28px, 3vw, 44px);
  line-height: 1.2;
}

.sales-hero p:not(.eyebrow) {
  color: #754859;
  margin-top: 6px;
  font-size: 14px;
}

.sales-primary, .sales-action-row button, .sales-action-row a {
  color: #fff;
  cursor: pointer;
  background: #ad2350;
  border: 1px solid #a91b4d;
  border-radius: 9px;
  justify-content: center;
  align-items: center;
  gap: 8px;
  padding: 11px 17px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
}

.sales-primary:hover, .sales-action-row button:hover {
  color: #fff;
  background: #8c143b;
}

.sales-primary:disabled, .sales-action-row button:disabled {
  opacity: .5;
  cursor: not-allowed;
}

.sales-stats {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 18px;
  display: grid;
}

.sales-stat {
  text-align: left;
  background: #fff;
  border: 1px solid #f0dbd5;
  border-radius: 13px;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  gap: 5px;
  min-height: 94px;
  padding: 20px;
  display: flex;
}

.sales-stat strong {
  color: #86163b;
  font-family: Playfair Display, serif;
  font-size: 28px;
  line-height: 1;
}

.sales-stat span {
  color: #795b62;
  font-size: 12px;
}

.sales-stat.selected {
  background: #fff1f1;
  border-color: #c44a70;
}

.sales-tabs {
  border-bottom: 1px solid #ead7d1;
  gap: 18px;
  margin-bottom: 12px;
  display: flex;
  overflow-x: auto;
}

.sales-tabs button {
  color: #785563;
  border-bottom: 2px solid #0000;
  flex: none;
  padding: 12px 5px;
  font-size: 13px;
}

.sales-tabs button.active {
  color: #8a163e;
  border-color: #a51646;
  font-weight: 700;
}

.sales-list {
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 15px;
  display: flex;
}

.sales-list-item {
  text-align: left;
  background: #fff;
  border: 1px solid #eacfc7;
  border-radius: 12px;
  flex: 1;
  justify-content: space-between;
  align-items: center;
  gap: 15px;
  min-width: min(100%, 300px);
  padding: 14px;
  display: flex;
}

.sales-list-item.selected {
  background: #fff1f1;
  border-color: #ad2350;
}

.sales-list-item span {
  flex-direction: column;
  gap: 4px;
  display: flex;
}

.sales-list-item small {
  color: #9e7782;
  overflow-wrap: anywhere;
  font-size: 11px;
}

.sales-list-item em {
  text-transform: capitalize;
  color: #9a2551;
  font-size: 12px;
  font-style: normal;
}

.sales-card {
  background: #fff;
  border: 1px solid #efdcd5;
  border-radius: 15px;
  min-width: 0;
  padding: 20px;
}

.sales-detail-head {
  justify-content: space-between;
  align-items: flex-start;
  gap: 15px;
  margin-bottom: 16px;
  display: flex;
}

.sales-detail-head h2 {
  color: #8b1c41;
  font-family: Playfair Display, serif;
  font-size: 28px;
}

.sales-detail-head p:not(.eyebrow) {
  color: #765665;
  font-size: 13px;
}

.sales-status {
  text-transform: capitalize;
  background: #eee0e5;
  border-radius: 30px;
  padding: 6px 12px;
  font-size: 12px;
}

.sales-status-active {
  color: #126d39;
  background: #def6e8;
}

.sales-status-ended {
  color: #994658;
  background: #f5e1e1;
}

.sales-status-paused {
  color: #84540b;
  background: #fff0cc;
}

.sales-info-grid {
  background: #fff4f1;
  border-radius: 12px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 16px;
  padding: 14px;
  display: grid;
}

.sales-info-grid div {
  flex-direction: column;
  gap: 5px;
  min-width: 0;
  display: flex;
}

.sales-info-grid small {
  color: #906b75;
  font-size: 11px;
}

.sales-info-grid strong {
  overflow-wrap: anywhere;
  font-size: 13px;
}

.sales-action-row {
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
  display: flex;
}

.sales-action-row button, .sales-action-row a {
  color: #8b1c42;
  background: #fff2f0;
  border-color: #efd0d0;
  padding: 9px 12px;
  font-size: 12px;
}

.sales-action-row a:hover {
  color: #8b1c42;
  background: #fce5e4;
}

.sales-products-head {
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin: 10px 0;
  display: flex;
}

.sales-products-head h3, .sales-editor h3 {
  font-family: Playfair Display, serif;
  font-size: 19px;
}

.sales-products-head button, .sales-secondary {
  color: #941d46;
  background: #fff0ee;
  border: 1px solid #f1dad6;
  border-radius: 9px;
  justify-content: center;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  font-size: 12px;
  font-weight: 600;
  display: inline-flex;
}

.sales-products {
  gap: 9px;
  display: grid;
}

.sales-product {
  border: 1px solid #f5e4e0;
  border-radius: 12px;
  align-items: center;
  gap: 14px;
  padding: 10px;
  display: flex;
}

.sales-product > img, .sales-image-empty {
  object-fit: cover;
  background: #fff0ee;
  border-radius: 9px;
  flex: none;
  place-items: center;
  width: 75px;
  height: 64px;
  display: grid;
}

.sales-product > div {
  flex-direction: column;
  flex: 1;
  gap: 5px;
  min-width: 0;
  display: flex;
}

.sales-product strong {
  font-size: 13px;
}

.sales-product small {
  color: #a55770;
  font-size: 12px;
}

.sales-switch-label {
  cursor: pointer;
  align-items: center;
  gap: 8px;
  display: flex;
  position: relative;
}

.sales-switch-label input {
  opacity: 0;
  cursor: pointer;
  width: 40px;
  height: 24px;
  position: absolute;
}

.sales-switch {
  background: #c8c1c2;
  border-radius: 24px;
  align-items: center;
  width: 42px;
  height: 25px;
  padding: 3px;
  transition: background .2s;
  display: inline-flex;
}

.sales-switch:before {
  content: "";
  background: #fff;
  border-radius: 50%;
  width: 19px;
  height: 19px;
  transition: transform .2s;
  box-shadow: 0 1px 3px #0002;
}

.sales-switch-label input:checked + .sales-switch {
  background: #39aa70;
}

.sales-switch-label input:checked + .sales-switch:before {
  transform: translateX(17px);
}

.sales-switch-label input:focus-visible + .sales-switch {
  outline-offset: 3px;
  outline: 2px solid #8f2448;
}

.sales-error, .sales-success, .sales-warning {
  border-radius: 8px;
  margin: 12px 0;
  padding: 12px 14px;
  font-size: 13px;
}

.sales-error {
  color: #9d253b;
  background: #fff0ed;
}

.sales-success {
  color: #216e3e;
  background: #e6f7eb;
}

.sales-warning {
  color: #80520f;
  background: #fff6df;
}

.sales-error button {
  margin-left: 10px;
  text-decoration: underline;
}

.sales-empty {
  color: #9c7883;
  padding: 20px;
  font-size: 13px;
}

.sales-editor-backdrop {
  z-index: 1000;
  background: #25131a80;
  justify-content: flex-end;
  display: flex;
  position: fixed;
  inset: 0;
}

.sales-editor {
  background: #fffaf8;
  width: min(100%, 620px);
  height: 100%;
  padding: 28px;
  overflow: auto;
  box-shadow: -12px 0 30px #19090c22;
}

.sales-editor > header {
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 18px;
  display: flex;
}

.sales-editor > header h2 {
  color: #8e1940;
  font-family: Playfair Display, serif;
  font-size: 30px;
}

.sales-fields, .sales-new-product {
  gap: 13px;
  display: grid;
}

.sales-fields label, .sales-new-product label {
  color: #773349;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  display: grid;
}

.sales-fields input, .sales-fields textarea, .sales-fields select, .sales-new-product input, .sales-new-product textarea {
  color: #462035;
  background: #fff;
  border: 1px solid #eacbc7;
  border-radius: 8px;
  width: 100%;
  min-height: 40px;
  padding: 11px;
  font-weight: 400;
}

.sales-fields textarea, .sales-new-product textarea {
  min-height: 72px;
}

.sales-two-fields {
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  display: grid;
}

.sales-editor-products {
  gap: 8px;
  margin: 10px 0;
  display: grid;
}

.sales-editor-products > div {
  border: 1px solid #efdcd9;
  border-radius: 8px;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 8px;
  display: flex;
}

.sales-editor-products label {
  flex: 1;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  display: flex;
}

.sales-editor-products input {
  border: 1px solid #efd5d1;
  border-radius: 8px;
  max-width: 100px;
  padding: 6px;
}

.sales-editor-products button {
  color: #a6224e;
  font-size: 11px;
}

.sales-new-product {
  background: #fff3ef;
  border: 1px dashed #d7a2a4;
  border-radius: 12px;
  margin: 14px 0;
  padding: 16px;
}

.sales-new-product .sales-upload {
  border: 1px dashed #aa5674;
  border-radius: 10px;
  align-items: center;
  gap: 9px;
  padding: 14px;
  display: flex;
  position: relative;
}

.sales-upload input {
  opacity: 0;
  cursor: pointer;
  position: absolute;
  inset: 0;
}

.sales-upload-preview {
  object-fit: cover;
  border-radius: 10px;
  max-width: 145px;
  max-height: 115px;
}

.sales-editor footer {
  background: #fffaf8;
  border-top: 1px solid #f0dcd5;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 16px;
  padding: 15px 0;
  display: flex;
  position: sticky;
  bottom: -28px;
}

@media (width <= 1040px) {
  .sales-workspace {
    grid-template-columns: 180px 1fr;
  }

  .sales-info-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (width <= 780px) {
  .sales-workspace {
    display: block;
  }

  .sales-sidebar {
    min-height: auto;
    padding: 8px 12px;
    position: static;
  }

  .sales-sidebar nav {
    white-space: nowrap;
    gap: 8px;
    padding-bottom: 8px;
    display: flex;
    overflow-x: auto;
  }

  .sales-sidebar nav a {
    flex: none;
  }

  .sales-sidebar .owner-signoff {
    display: none;
  }

  .sales-main {
    padding: 16px 12px 75px;
  }

  .sales-hero {
    flex-wrap: wrap;
    padding: 18px;
  }

  .sales-stats {
    grid-template-columns: 1fr 1fr;
  }

  .sales-stat {
    min-height: 75px;
    padding: 14px;
  }

  .sales-info-grid {
    grid-template-columns: 1fr 1fr;
  }

  .sales-editor {
    padding: 18px;
  }

  .sales-editor footer {
    bottom: -18px;
  }

  .sales-two-fields {
    grid-template-columns: 1fr;
  }
}

@media (width <= 410px) {
  .sales-info-grid {
    grid-template-columns: 1fr;
  }

  .sales-product {
    gap: 7px;
  }

  .sales-product > img, .sales-image-empty {
    width: 55px;
    height: 54px;
  }

  .sales-switch-label {
    gap: 4px;
  }

  .sales-switch-label small {
    font-size: 10px;
  }
}

.sale-public-message {
  text-align: center;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 15px;
  min-height: 60vh;
  padding: 60px 15px;
  display: flex;
}

.sale-public-message h1 {
  color: #8d1941;
  font-family: Playfair Display, serif;
  font-size: 36px;
}

.sale-public-message h2 {
  color: #8d1941;
  font-size: 18px;
}

.sale-public-message a, .sale-public-message button, .sale-public-book, .sales-receipt a {
  color: #fff;
  background: #b51b50;
  border: 0;
  border-radius: 8px;
  justify-content: center;
  align-items: center;
  gap: 8px;
  padding: 12px 18px;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
}

.sale-public-hero {
  text-align: center;
  color: #66233d;
  background: linear-gradient(125deg, #ffddd9, #fff5ef);
  border-radius: 18px;
  max-width: 1250px;
  margin: 20px auto 30px;
  padding: clamp(25px, 5vw, 76px);
}

.sale-public-hero h1 {
  color: #94204a;
  margin: 6px 0 14px;
  font-family: Playfair Display, serif;
  font-size: clamp(35px, 5.5vw, 66px);
}

.sale-public-hero > p:not(.eyebrow):not(.sale-code) {
  font-size: 16px;
}

.sale-public-hero > div {
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
  margin-top: 25px;
  display: flex;
}

.sale-public-hero > div span {
  background: #fff9f8;
  border: 1px solid #f0d4d5;
  border-radius: 8px;
  align-items: center;
  gap: 6px;
  padding: 10px 13px;
  font-size: 12px;
  display: inline-flex;
}

.sale-public-hero .sale-code {
  background: #fff7ef;
  border: 1px dashed #b95674;
  border-radius: 8px;
  margin-top: 18px;
  padding: 9px 14px;
  font-size: 12px;
  display: inline-block;
}

.sale-public-grid-section {
  padding-top: 15px;
  padding-bottom: 45px;
}

.sale-public .diwali-product {
  min-width: 0;
}

.sale-public .diwali-product > img {
  object-fit: cover;
  width: 100%;
  height: 230px;
}

.sale-public-book {
  cursor: pointer;
  width: 100%;
  margin: 14px 0 4px;
}

.sale-public-book:disabled {
  cursor: not-allowed;
  background: #b4a1a4;
}

.sale-public-enquiry .sales-fields {
  margin-top: 15px;
}

.sale-public-enquiry .sales-consent {
  align-items: flex-start;
  gap: 10px;
  display: flex;
}

.sale-public-enquiry .sales-consent input {
  flex: none;
  width: 18px;
  height: 18px;
  min-height: 18px;
}

.sales-receipt {
  justify-items: start;
  gap: 16px;
  padding: 10px;
  display: grid;
}

.sales-receipt svg {
  color: #469667;
}

@media (width <= 600px) {
  .sale-public-hero {
    border-radius: 12px;
    margin: 10px;
    padding: 32px 16px;
  }

  .sale-public-hero > div {
    gap: 7px;
  }

  .sale-public-hero > div span {
    justify-content: center;
    width: 100%;
  }

  .sale-public .diwali-products {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .sale-public .diwali-product {
    padding: 10px;
  }

  .sale-public .diwali-product > img {
    height: 150px;
  }

  .sale-public-book {
    padding: 10px 5px;
    font-size: 11px;
  }

  .sale-public-enquiry {
    width: 100%;
  }
}

@media (width <= 380px) {
  .sale-public .diwali-products {
    grid-template-columns: 1fr;
  }
}

.diwali-page .diwali-collection .diwali-product, .diwali-page .diwali-collection .diwali-product-copy, .diwali-page .diwali-collection .diwali-product-actions, .diwali-page .diwali-collection .diwali-product-copy > div:not(.diwali-product-actions) {
  min-width: 0;
}

.diwali-page .diwali-collection .diwali-product-actions {
  flex-wrap: wrap;
  align-items: stretch;
  gap: 10px;
  display: flex;
}

.diwali-page .diwali-collection .diwali-product-actions .sale-public-book {
  text-align: center;
  white-space: normal;
  flex: 175px;
  width: auto;
  min-height: 44px;
  margin: 0;
  padding: 11px 13px;
  font-size: 12px;
  line-height: 1.35;
}

@media (width <= 767px) {
  .diwali-page, .diwali-page .diwali-collection, .diwali-page .diwali-products {
    min-width: 0;
  }

  .diwali-page .diwali-collection .diwali-products {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
    display: grid;
  }

  .diwali-page .diwali-collection .diwali-product {
    flex-direction: column;
    gap: 0;
    width: 100%;
    max-width: 100%;
    padding: 8px;
    display: flex;
    overflow: hidden;
  }

  .diwali-page .diwali-collection .diwali-product > img, .diwali-page .diwali-collection .diwali-product > div[aria-label="Product photo being prepared"] {
    aspect-ratio: 4 / 3;
    object-fit: contain;
    background-color: #f8efe8;
    border-radius: 9px;
    width: 100%;
    max-width: 100%;
    height: auto;
    display: block;
  }

  .diwali-page .diwali-collection .diwali-product-copy {
    flex-direction: column;
    gap: 7px;
    width: 100%;
    min-width: 0;
    padding: 15px 9px 10px;
    display: flex;
  }

  .diwali-page .diwali-collection .diwali-product-copy > span {
    align-self: flex-start;
  }

  .diwali-page .diwali-collection .diwali-product h2 {
    overflow-wrap: break-word;
    width: 100%;
    margin: 0;
    font-size: clamp(21px, 6vw, 27px);
    line-height: 1.2;
  }

  .diwali-page .diwali-collection .diwali-product-copy > div:not(.diwali-product-actions) {
    flex-wrap: wrap;
    align-items: baseline;
    gap: 8px;
    display: flex;
  }

  .diwali-page .diwali-collection .diwali-product strong {
    white-space: nowrap;
    margin: 0;
    font-size: 22px;
    display: inline;
  }

  .diwali-page .diwali-collection .diwali-product p {
    overflow-wrap: break-word;
    max-width: none;
    margin: 2px 0 9px;
    font-size: 13px;
    line-height: 1.55;
  }

  .diwali-page .diwali-collection .diwali-product-actions {
    grid-template-columns: minmax(0, 1fr);
    gap: 9px;
    width: 100%;
    display: grid;
  }

  .diwali-page .diwali-collection .diwali-product-actions .sale-public-book {
    min-width: 0;
    min-height: 46px;
    margin: 0;
    padding: 11px 12px;
    font-size: 13px;
    width: 100% !important;
  }

  .diwali-page .diwali-section-head, .diwali-page .diwali-section-head > div {
    min-width: 0;
  }

  .diwali-page .diwali-intro h1 {
    overflow-wrap: break-word;
  }
}
