/* ==================================================
   ALAZRA PRODUCT MODAL
================================================== */

body.modal-open {
  overflow: hidden;
}

/* ==================================================
   PRODUCT MODAL
================================================== */

.perfume-modal {
  position: fixed;

  inset: 0;

  z-index: 9999;

  display: flex;

  align-items: center;
  justify-content: center;

  padding: 30px;

  opacity: 0;
  visibility: hidden;

  transition:
    opacity 0.35s ease,
    visibility 0.35s ease;
}

.perfume-modal.active {
  opacity: 1;
  visibility: visible;
}

/* ==================================================
   OVERLAY
================================================== */

.perfume-modal-overlay {
  position: absolute;

  inset: 0;

  background: rgba(15, 13, 10, 0.82);

  backdrop-filter: blur(8px);
}

/* ==================================================
   MODAL BOX
================================================== */

.perfume-modal-box {
  position: relative;

  z-index: 2;

  width: min(1120px, 100%);

  max-height: calc(100vh - 60px);

  overflow: hidden;

  background: #ffffff;

  box-shadow: 0 30px 100px rgba(0, 0, 0, 0.3);
  overflow-y: auto;
}

/* ==================================================
   GRID
================================================== */

.perfume-modal-grid {
  display: grid;

  grid-template-columns:
    minmax(0, 1fr)
    minmax(0, 1fr);

  min-height: 600px;

  max-height: calc(100vh - 60px);
}

/* ==================================================
   IMAGE
================================================== */

.perfume-modal-image {
  position: relative;

  min-height: 600px;

  overflow: hidden;

  background: #18130e;
}

.perfume-modal-image img {
  /* width: auto; */
  height: 100%;

  display: block;

  object-fit: contain;
  position: absolute;
}

/* ==================================================
   DETAILS SIDE
================================================== */

.perfume-modal-details {
  display: flex;
  flex-direction: column;

  min-height: 0;

  padding: 55px 55px 40px;

  overflow: hidden;
}

.modal-product-header {
  flex-shrink: 0;
}

/* ==================================================
   CLOSE
================================================== */

.perfume-modal-close {
  position: absolute;

  top: 25px;
  right: 28px;

  z-index: 10;

  width: 52px;
  height: 52px;

  display: flex;

  align-items: center;
  justify-content: center;

  border: 0;

  border-radius: 50%;

  background: #ffffff;

  color: #171717;

  font-size: 28px;

  line-height: 1;

  cursor: pointer;

  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);

  transition:
    transform 0.3s ease,
    background 0.3s ease;
}

.perfume-modal-close:hover {
  transform: rotate(90deg);

  background: #f4efe7;
}

/* ==================================================
   CATEGORY
================================================== */

.modal-product-category {
  display: block;

  margin-bottom: 20px;

  color: #c59648;

  font-size: 11px;

  font-weight: 600;

  letter-spacing: 4px;

  text-transform: uppercase;
}

/* ==================================================
   PRODUCT NAME
================================================== */

.modal-product-name,
#modalProductName {
  margin: 0 0 22px;

  color: #111111;

  font-family: 'Cormorant Garamond', serif;

  font-size: clamp(52px, 5vw, 76px);

  font-weight: 500;

  line-height: 0.95;

  letter-spacing: -1.5px;
}

/* ==================================================
   DESCRIPTION
================================================== */

.modal-product-description {
  margin: 0 0 35px;

  color: #77736d;

  font-family: 'Poppins', sans-serif;

  font-size: 15px;

  font-weight: 400;

  line-height: 1.9;
}

/* ==================================================
   NOTES
================================================== */

.modal-notes {
  display: grid;

  gap: 20px;

  margin-bottom: 30px;
}

.modal-note-group {
  padding-bottom: 18px;

  border-bottom: 1px solid #ece7df;
}

.modal-note-group:last-child {
  border-bottom: 0;
}

.modal-note-group > span {
  display: block;

  margin-bottom: 7px;

  color: #bd9148;

  font-size: 9px;

  font-weight: 600;

  letter-spacing: 2.5px;

  text-transform: uppercase;
}

.modal-note-group p {
  margin: 0;

  color: #36332f;

  font-size: 13px;

  line-height: 1.7;
}

/* ==================================================
   VIEW MORE BUTTON
================================================== */

.details-toggle {
  width: 100%;

  display: flex;

  align-items: center;
  justify-content: space-between;

  padding: 20px 0;

  margin-top: 5px;

  border: 0;

  border-top: 1px solid #ddd7ce;

  border-bottom: 1px solid #ddd7ce;

  background: transparent;

  color: #222222;

  font-family: 'Poppins', sans-serif;

  font-size: 11px;

  font-weight: 600;

  letter-spacing: 1.8px;

  text-align: left;

  text-transform: uppercase;

  cursor: pointer;
}

.details-toggle strong {
  width: 30px;
  height: 30px;

  display: flex;

  align-items: center;
  justify-content: center;

  border: 1px solid #d8d0c4;

  border-radius: 50%;

  color: #222;

  font-size: 18px;

  font-weight: 400;

  transition: all 0.3s ease;
}

.details-toggle:hover {
  color: #b88a3b;
}

.details-toggle:hover strong,
.details-toggle.active strong {
  background: #b88a3b;

  border-color: #b88a3b;

  color: #ffffff;
}

/* ==================================================
   MORE DETAILS
================================================== */

/*
   IMPORTANT:
   Hidden by default.
*/

.modal-more-details {
  display: none;
}

/*
   IMPORTANT:
   Visible only when JS adds .active
*/

.modal-more-details.active {
  display: block;
}

.modal-more-details::-webkit-scrollbar {
  width: 5px;
}

.modal-more-details::-webkit-scrollbar-track {
  background: #f3f0ea;
}

.modal-more-details::-webkit-scrollbar-thumb {
  background: #c49a52;

  border-radius: 10px;
}

.modal-more-details::-webkit-scrollbar-thumb:hover {
  background: #a87c36;
}

@keyframes modalDetailsOpen {
  from {
    opacity: 0;

    transform: translateY(-8px);
  }

  to {
    opacity: 1;

    transform: translateY(0);
  }
}

/* ==================================================
   DETAIL ITEM
================================================== */

.modal-detail-section {
  padding: 20px 0;

  border-bottom: 1px solid #eee9e1;
}

.modal-detail-section:last-child {
  border-bottom: 0;
}

.modal-detail-label {
  display: block;

  margin-bottom: 8px;

  color: #b88a3b;

  font-size: 9px;

  font-weight: 600;

  letter-spacing: 2px;

  text-transform: uppercase;
}

.modal-detail-text {
  font-size: 12px;
  line-height: 1.7;
}

/* ==================================================
   EMPTY DETAILS
================================================== */

.modal-detail-empty {
  padding: 22px 0;

  color: #77736d;
}

.modal-detail-empty span {
  display: block;

  margin-bottom: 8px;

  color: #b88a3b;

  font-size: 9px;

  font-weight: 600;

  letter-spacing: 2px;
}

.modal-detail-empty p {
  margin: 0;

  font-size: 13px;

  line-height: 1.7;
}

/* ==================================================
   ORDER BUTTON
================================================== */

.modal-order-button {
  width: 100%;

  min-height: 62px;

  border: 0;

  background: #111111;

  color: #ffffff;

  display: flex;

  align-items: center;
  justify-content: center;

  gap: 20px;

  font-family: 'Poppins', sans-serif;

  font-size: 11px;

  font-weight: 600;

  letter-spacing: 2px;

  text-transform: uppercase;

  cursor: pointer;

  transition:
    background 0.3s ease,
    transform 0.3s ease;
  flex-shrink: 0;

  margin-top: 35px;
}

.modal-order-button:hover {
  background: #b88a3b;

  transform: translateY(-2px);
}

.modal-order-button span {
  font-size: 18px;

  transition: transform 0.3s ease;
}

.modal-order-button:hover span {
  transform: translateX(5px);
}

/* ==================================================
   ORDER MODAL
================================================== */

.order-modal {
  position: fixed;

  inset: 0;

  z-index: 10000;

  display: flex;

  align-items: center;
  justify-content: center;

  padding: 25px;

  opacity: 0;
  visibility: hidden;

  transition:
    opacity 0.3s ease,
    visibility 0.3s ease;
}

.order-modal.active {
  opacity: 1;
  visibility: visible;
}

.order-modal-overlay {
  position: absolute;

  inset: 0;

  background: rgba(15, 13, 10, 0.82);

  backdrop-filter: blur(7px);
}

.order-modal-box {
  position: relative;

  z-index: 2;

  width: min(560px, 100%);

  max-height: calc(100vh - 50px);

  overflow-y: auto;

  padding: 50px;

  background: #ffffff;

  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.25);
}

.order-modal-close {
  position: absolute;

  top: 18px;
  right: 20px;

  width: 42px;
  height: 42px;

  border: 0;

  border-radius: 50%;

  background: #f5f2ed;

  color: #222;

  font-size: 24px;

  cursor: pointer;
}

.order-modal-header > span {
  color: #b88a3b;

  font-size: 9px;

  font-weight: 600;

  letter-spacing: 3px;
}

.order-modal-header h2 {
  margin: 10px 0 10px;

  font-family: 'Cormorant Garamond', serif;

  font-size: 48px;

  font-weight: 500;

  line-height: 1;
}

.order-modal-header p {
  margin: 0 0 25px;

  color: #77736d;

  font-size: 13px;

  line-height: 1.7;
}

/* ==================================================
   SELECTED PRODUCT
================================================== */

.order-product {
  display: flex;

  align-items: center;

  gap: 18px;

  padding: 15px;

  margin-bottom: 25px;

  background: #f6f3ed;
}

.order-product img {
  width: 65px;
  height: 65px;

  object-fit: cover;
}

.order-product > div > span {
  color: #b88a3b;

  font-size: 8px;

  font-weight: 600;

  letter-spacing: 1.8px;
}

.order-product h3 {
  margin: 5px 0 0;

  font-family: 'Cormorant Garamond', serif;

  font-size: 26px;

  font-weight: 500;
}

/* ==================================================
   FORM
================================================== */

.order-form {
  display: grid;

  gap: 18px;
}

.form-group {
  display: grid;

  gap: 7px;
}

.form-group label {
  color: #333;

  font-size: 10px;

  font-weight: 600;

  letter-spacing: 1px;

  text-transform: uppercase;
}

.form-group input,
.form-group textarea {
  width: 100%;

  box-sizing: border-box;

  padding: 13px 14px;

  border: 1px solid #ddd8cf;

  outline: none;

  background: #fff;

  color: #222;

  font-family: 'Poppins', sans-serif;

  font-size: 13px;

  transition: border-color 0.25s ease;
}

.form-group textarea {
  resize: vertical;

  min-height: 110px;
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: #b88a3b;
}

.place-order-button {
  min-height: 56px;

  margin-top: 5px;

  border: 0;

  background: #111;

  color: #fff;

  font-size: 10px;

  font-weight: 600;

  letter-spacing: 1.8px;

  text-transform: uppercase;

  cursor: pointer;
}

.place-order-button:hover {
  background: #b88a3b;
}

/* ==================================================
   DETAIL CONTENT
================================================== */

.modal-detail-content {
  margin-top: 4px;
}

.modal-detail-content > p {
  margin: 0;

  color: #55514b;

  font-size: 13px;

  line-height: 1.8;
}

/* ==================================================
   DETAIL SUB SECTION
================================================== */

.modal-detail-subsection {
  padding: 8px 0;
}

.modal-detail-subsection:first-child {
  padding-top: 4px;
}

.modal-detail-subsection:last-child {
  padding-bottom: 4px;
}

.modal-detail-sub-label {
  /* display: block;

  margin-bottom: 6px;

  color: #8a877f;

  font-size: 9px;

  font-weight: 600;

  letter-spacing: 1.8px;

  text-transform: uppercase; */
  margin-bottom: 6px;
  font-size: 8px;
}

.modal-detail-subsection p {
  margin: 0;

  color: #55514b;

  font-size: 13px;

  line-height: 1.8;
}

.modal-detail-nested {
  padding-left: 15px;

  border-left: 1px solid #e4ded4;
}

/* Nested text */

.modal-detail-nested .modal-detail-text {
  color: #55514b;

  font-size: 13px;

  line-height: 1.8;
}

/* Nested labels */

.modal-detail-nested .modal-detail-sub-label {
  color: #b88a3b;

  margin-top: 3px;
}

/* ==================================================
   MOBILE
================================================== */

@media (max-width: 900px) {
  .perfume-modal {
    padding: 15px;
  }

  .perfume-modal-grid {
    grid-template-columns: 1fr;

    max-height: calc(100vh - 30px);

    overflow-y: auto;
  }

  .perfume-modal-image {
    min-height: 330px;

    max-height: 380px;
  }

  .perfume-modal-details {
    padding: 45px 28px 30px;

    overflow: visible;
  }

  .modal-product-name,
  #modalProductName {
    font-size: 52px;
  }

  .perfume-modal-close {
    top: 15px;
    right: 15px;
  }
}

@media (max-width: 600px) {
  .perfume-modal {
    padding: 0;
  }

  .perfume-modal-box {
    width: 100%;

    height: 100%;

    max-height: 100vh;
  }

  .perfume-modal-grid {
    max-height: 100vh;
  }

  .perfume-modal-image {
    min-height: 300px;

    max-height: 320px;
  }

  .perfume-modal-details {
    padding: 35px 22px 25px;
  }

  .modal-product-category {
    font-size: 9px;

    letter-spacing: 3px;
  }

  .modal-product-name,
  #modalProductName {
    font-size: 46px;
  }

  .modal-product-description {
    font-size: 13px;

    line-height: 1.8;
  }

  .order-modal {
    padding: 0;
  }

  .order-modal-box {
    width: 100%;

    height: 100%;

    max-height: 100vh;

    padding: 45px 22px 25px;
  }

  .order-modal-header h2 {
    font-size: 42px;
  }
  .modal-more-details {
    max-height: 260px;

    padding-right: 8px;
  }
}
