:root {
  --primary-color: #f93822;
  --dark-color: #000000;
  --white-color: #ffffff;
  --gray-color: #dee2e6;
  --blur-color: #0d6efd;
  --secondary-color: #a9a9a9;
  --secondary-color-mute: #dcdcdc;
  --invalide-color: #dc3545;

  --opacity-primary: #f9382230;
  --opacity-dark: #00000033;
  --opacity-gray: #dee2e646;
  --opacity-blur: #0d6efd40;
  --opacity-secondary-mute: #dcdcdc46;
  --opacity-invalide-color: #dc354540;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html,
body {
  height: 100%;
  width: 100%;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
}

body {
  min-height: 100vh;
  height: 100vh;
  height: -webkit-fill-available;
}

.container {
  padding-top: calc(1.5rem * 0.5);
  padding-bottom: calc(1.5rem * 0.5);
}

.h-overlay {
  width: 100%;
  height: 100%;
  min-height: 100vh;
  min-height: -webkit-fill-available;
  overflow-y: auto;
}

div.h-overlay {
  position: unset !important;
}
div.h-overlay div.bg-light {
  opacity: 1 !important;
  background-color: var(--white-color) !important;
}

.bg-base {
  background-image: url(/img/beauty/bg-base.webp);
  background-size: cover;
  background-repeat: no-repeat;
  background-position: top;
  background-attachment: fixed;
}

.layout-wrapper {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow-y: auto;
  padding-bottom: 94px;
}

/* Footer Menu CSS */
.footer-nemnu {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  padding: 0.5rem 1rem;
  padding-top: 0.75rem;
  background-color: var(--white-color);
  border-top-left-radius: 2rem;
  border-top-right-radius: 2rem;
  box-shadow: 0 -5px 50px var(--opacity-dark);
  transform: translateZ(0);
}

.footer-nemnu .menu-link {
  width: 100%;

  & .menu-item {
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.25rem;
  }
}

.footer-nemnu .menu-link .menu-item {
  opacity: 0.4;
  color: var(--primary-color);

  & .item-icon {
    flex: 1;
    padding: 5px 6px;
    border-radius: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  & .icon-size {
    width: 35px;
    height: 36px;
  }
  & .icon-card-size {
    width: 35px;
    height: 28px;
  }
  & .icon-card {
    background: url("/img/beauty/icon/card.webp");
    background-repeat: no-repeat;
  }
  & .icon-point {
    background: url("/img/beauty/icon/gift.webp");
    background-repeat: no-repeat;
  }
  & .icon-privilege {
    background: url("/img/beauty/icon/privilege.webp");
    background-repeat: no-repeat;
  }
  & .base-icon {
    opacity: 0.7;
    background-size: 100% !important;
    display: -webkit-inline-box;
  }
}
.footer-nemnu .menu-link .menu-item.menu-active {
  opacity: 1;

  & .item-icon {
    background-color: var(--opacity-primary);
  }

  & .icon-card {
    background: url("/img/beauty/icon/card-active.webp");
    background-repeat: no-repeat;
  }
  & .icon-point {
    background: url("/img/beauty/icon/gift-active.webp");
    background-repeat: no-repeat;
  }
  & .icon-privilege {
    background: url("/img/beauty/icon/privilege-active.webp");
    background-repeat: no-repeat;
  }
  & .base-icon {
    opacity: 1;
  }
}
/* End Footer Menu CSS */

.card-wrapper {
  overflow: hidden;
  position: relative;
}

.card-image {
  margin: 12px;
  padding: 8px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

label {
  font-weight: bold;
}

.btn-language-wrapper {
  width: 50px;
  height: 50px;
  position: absolute;
  top: 0;
  right: 0;
  margin: 20px;
  border-radius: 100%;
  box-shadow: 0 5px 20px var(--opacity-dark);
  background-image: url(/img/beauty/icon/language.webp);
  background-size: 3.5rem;
  background-position: center;
  background-repeat: no-repeat;
}

.btn-back-wrapper {
  width: 45px;
  height: 45px;
  display: flex;
  justify-content: center;
  border-radius: 100%;
  position: absolute;
  top: 0;
  left: 0;
  margin: 20px;
  padding: 10px;
  box-shadow: 0 5px 20px var(--opacity-dark);
  background-image: url(/img/beauty/icon/left.webp);
  background-size: 1.125rem;
  background-position: center;
  background-repeat: no-repeat;
}

span.i-edit {
  margin-top: 2px;
  display: block;
  width: 18px;
  height: 18px;
  background-image: url(/img/beauty/icon/edit.webp);
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
}

span.i-eye {
  margin-top: 2px;
  display: block;
  width: 24px;
  height: 20px;
  background-image: url(/img/beauty/icon/gift-active.webp);
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
}

span.i-coins {
  margin-top: 8px;
  display: block;
  width: 34px;
  height: 34px;
  background-image: url(/img/beauty/icon/coins.webp);
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
}

.content-bg {
  flex: 1;
  height: 100%;
  background-color: var(--white-color);
  border-top-left-radius: 2rem;
  border-top-right-radius: 2rem;
  box-shadow: 0 5px 20px var(--opacity-dark);
}

.content-wrapper {
  margin: 12px;
  padding: 8px;
  padding-bottom: 2.125rem;
}

.heading-wrapper {
  & .flex-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
  }

  & h2,
  h3,
  h4 {
    margin: 0px !important;
  }

  & span.i-edit {
    margin-top: 0px;
    width: 34px;
    height: 34px;
  }
}

.color-primary {
  color: var(--primary-color) !important;
}

button.btn-primary {
  background-color: var(--primary-color) !important;
  border: 1px solid var(--primary-color) !important;
  & :disabled {
    opacity: 0.7;
  }
}
button.btn-secondary {
  color: var(--secondary-color) !important;
  background-color: var(--gray-color) !important;
  border: 1px solid var(--secondary-color-mute) !important;

  & :disabled {
    opacity: 0.7;
  }
}

.loader-wrapper {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 150px;
}

.boun-ceball {
  position: relative;
  display: inline-block;
  height: 37px;
  width: 15px;
}

.boun-ceball:before {
  position: absolute;
  content: "";
  display: block;
  top: 0;
  width: 15px;
  height: 15px;
  border-radius: 50%;
  background-color: var(--primary-color);
  transform-origin: 50%;
  -webkit-animation: bounce 500ms alternate infinite ease;
  animation: bounce 500ms alternate infinite ease;
}

.loader-content {
  color: var(--primary-color);
  display: inline-block;
  margin-left: 10px;
  margin-bottom: 5px;
}

.tabs .card-header {
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
}

.tabs .card-header-pills {
  width: 100%;
  max-width: 400px;
  border-radius: 50px;
  background-color: var(--secondary-color-mute);
}
.tabs .card-header-pills .nav-item {
  width: 50%;
}
.tabs .card-header-pills .nav-item .nav-link {
  color: var(--secondary-color);
  border-radius: 50px;
}
.tabs .card-header-pills .nav-item .nav-link.active {
  color: var(--white-color);
  background-color: var(--primary-color);
  border-radius: 50px;
}

.tab-content {
  margin-top: 1.5rem;
}

input[type="text"],
input[type="number"],
input[type="email"],
input[type="tel"],
input[type="search"] {
  padding: 12px !important;
}

.custom-control-inline {
  display: flex;
  align-items: center;
}
input[type="radio"] {
  width: 22px;
  height: 22px;
}
input[type="radio"]:checked {
  accent-color: var(--primary-color);
}

/* สำหรับให้แน่ใจว่า cursor เป็น pointer */
.custom-control-label,
.form-check-label {
  cursor: pointer;
}

.otp-wrapper {
  width: 100%;
  max-width: 320px;
  margin: auto;
  display: flex;
  gap: 10px;
}

.otp-input {
  width: 100%;
  height: 50px;
  padding: 10px;
  font-size: 1.25rem;
  border-radius: 4px;
  border: 1px solid var(--gray-color);
  text-align: center;
  box-sizing: border-box;
}

.otp-input:focus,
.otp-input:active {
  border: 1px solid var(--blur-color) !important;
  box-shadow: 0 0 0 0.25rem var(--opacity-blur);
  outline: none;
}

.modal-dialog .modal-content {
  border-radius: 2rem;
}

.modal-dialog header .close {
  border: none;
  background: none;
  font-size: 3.25rem;
  line-height: 16px;
}

.autocomplete .autocomplete__box {
  padding: 0px;
}
.autocomplete div.autocomplete__box {
  border: none !important;
}
.autocomplete ul.autocomplete__results {
  max-height: 220px;
}
.autocomplete .autocomplete__box span {
  position: absolute;
  right: 14px;
}
.autocomplete .autocomplete__box .autocomplete__inputs {
  padding: 0px;
}
.autocomplete .autocomplete__box .autocomplete__inputs input {
  border: 1px solid var(--gray-color);
  border-radius: 0.375rem;
  padding-right: 2.5rem !important;

  &:focus,
  &:active {
    outline: none;
    box-shadow: none;
    border-color: var(--blur-color);
    box-shadow: 0 0 0 0.25rem var(--opacity-blur);
    transition: border-color 0.15s, box-shadow 0.15s;
  }
}
.autocomplete.invalide .autocomplete__box .autocomplete__inputs input {
  border: 1px solid var(--invalide-color);
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' width='12' height='12' fill='none' stroke='%23dc3545'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath stroke-linejoin='round' d='M5.8 3.6h.4L6 6.5z'/%3e%3ccircle cx='6' cy='8.2' r='.6' fill='%23dc3545' stroke='none'/%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right calc(0.375em + 0.1875rem) center;
  background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);

  &:focus,
  &:active {
    border-color: var(--invalide-color);
    box-shadow: 0 0 0 0.25rem var(--opacity-invalide-color);
  }
}

.autocomplete__results__item {
  margin: 0px !important;
  padding: 6px !important;
  border-bottom: 1px solid var(--opacity-secondary-mute);
}
.autocomplete__results__item:hover {
  background-color: var(--opacity-secondary-mute) !important;
}
.autocomplete__results__item:last-child {
  padding: 6px !important;
  border-bottom: 0px;
}
.bi-three-dots g path {
  color: var(--primary-color);
}

.vdp-datepicker input {
  display: block;
  width: 100%;
  line-height: 1.5;
  background-color: var(--white-color);
  border: 1px solid var(--gray-color);
  border-radius: 0.375rem;
}

.vdp-datepicker.invalide input {
  border: 1px solid var(--invalide-color);
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' width='12' height='12' fill='none' stroke='%23dc3545'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath stroke-linejoin='round' d='M5.8 3.6h.4L6 6.5z'/%3e%3ccircle cx='6' cy='8.2' r='.6' fill='%23dc3545' stroke='none'/%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right calc(0.375em + 0.1875rem) center;
  background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);

  &:focus,
  &:active {
    border-color: var(--invalide-color);
    box-shadow: 0 0 0 0.25rem var(--opacity-invalide-color);
  }
}
.vdp-datepicker .vdp-datepicker__calendar {
  width: 100%;
  max-width: 320px;
  border-bottom-left-radius: 0.375rem;
  border-bottom-right-radius: 0.375rem;
}
.vdp-datepicker .vdp-datepicker__calendar .cell.selected {
  font-weight: bold;
  color: var(--white-color);
  background-color: var(--primary-color) !important;
}
.vdp-datepicker .vdp-datepicker__calendar .cell:hover {
  border-color: var(--primary-color) !important;
}
.vdp-datepicker .vdp-datepicker__calendar .cell.disabled:hover {
  border-color: var(--white-color) !important;
  background-color: initial !important;
  cursor: not-allowed;
}

input[type="text"] {
  &:focus,
  &:active {
    outline: none;
    box-shadow: none;
    border-color: var(--blur-color);
    box-shadow: 0 0 0 0.25rem var(--opacity-blur);
    transition: border-color 0.15s, box-shadow 0.15s;
  }
}

small.text-invalide {
  color: var(--invalide-color) !important;
}

.wrapper-consent {
  display: flex;
  gap: 10px;
}
.form-check-input {
  width: 22px !important;
  height: 22px !important;
  border-radius: 50px !important;
  flex-shrink: 0;
}

.form-switch .form-check-input {
  width: 48px !important;
  height: 28px !important;
  margin: 0px;
}

.form-check-input:checked {
  background-color: var(--primary-color) !important;
  border-color: var(--primary-color) !important;
}
.i-triangle {
  font-size: 20px;
  margin: 6px 1px;
}

/* Member CSS */
.information-wrapper {
  margin: 12px;
  margin-top: 0px;
  padding: 8px;
}
.information-detail {
  padding: 24px;
  background-color: var(--white-color);
  border-radius: 2rem;
}
div .exp-d-wrapper {
  font-size: 13px;
}

.qr-code {
  max-width: 100%;
  height: auto;
}

div.barcode-wrapper {
  overflow: hidden;
  width: 100%;
  max-width: 150px;
  align-items: center;
  justify-content: start;
}
div.barcode-wrapper svg {
  width: 100%;
  max-height: 65px;
}

.coupon-wrapper {
  height: 100%;
  padding-top: 10px;
  overflow-y: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  scroll-behavior: smooth;

  &::-webkit-scrollbar {
    display: none;
  }
}

.coupon-list {
  margin: 10px 22px;
  margin-bottom: 32px;
}
.coupon-item {
  padding: 14px;
  background-color: var(--white-color);
  border-radius: 2rem;
  box-shadow: 0 5px 20px var(--opacity-dark);

  & .coupon-image {
    width: 100%;
    max-width: 120px;

    & img {
      width: 100%;
      border-radius: 0.875rem;
    }
  }

  & .coupon-image-use {
    filter: grayscale(100%);
    transition: filter 0.5s ease-in-out;
  }

  & span.i-gift {
    display: block;
    width: 22px;
    height: 22px;
    background-image: url(/img/beauty/icon/gift-active.webp);
    background-size: contain;
    background-position: center;
    background-repeat: no-repeat;
  }
}

.coupon-lg-image {
  width: 100%;
  max-width: 400px;
  margin: auto;
  border-radius: 0.875rem;
}

.text-truncate-1 {
  margin-bottom: 0px;
  max-width: 100%;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}
.text-truncate-2 {
  margin-bottom: 0px;
  max-width: 100%;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

.text-description {
  line-height: 1;
  font-size: 14px;
}

.coupon-date-wrapper {
  display: flex;
  flex-direction: column;

  & span {
    font-size: 12px;
  }
}

/* End Member CSS */

@keyframes bounce {
  0% {
    top: 30px;
    height: 5px;
    border-radius: 60px 60px 20px 20px;
    transform: scaleX(2);
  }
  35% {
    height: 15px;
    border-radius: 50%;
    transform: scaleX(1);
  }
  100% {
    top: 0;
  }
}

.tag-wrapper {
  width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  white-space: nowrap;
  scrollbar-width: none;
  -ms-overflow-style: none;
  scroll-behavior: smooth;

  &::-webkit-scrollbar {
    display: none;
  }

  & .tag-list {
    display: inline-flex;
    padding: 0px 24px;
    margin: 0;
    list-style: none;

    & .tag-item {
      flex-shrink: 0;
      margin: 12px 8px;
      padding: 6px 12px;
      font-size: 14px;
      color: var(--primary-color);
      border: 1px solid var(--primary-color);
      border-radius: 50px;
      cursor: pointer;
      white-space: nowrap;
      transition: all 0.3s ease;

      &:hover {
        background-color: var(--opacity-primary);
        box-shadow: 0 3px 8px var(--opacity-dark);
      }
    }
    & .tag-active {
      color: var(--white-color);
      background-color: var(--primary-color);
      box-shadow: 0 3px 8px var(--opacity-dark);

      &:hover {
        color: var(--white-color);
        background-color: var(--primary-color);
      }
    }
  }
}

.center-wrapper {
  width: 100%;
  padding: 0px 32px;
  text-align: center;
}

.center-wrapper.content-absolute {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.center-wrapper.content-static {
  height: 100%;
  position: static;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sidebar-heading-wrapper {
  position: relative;
  margin: 12px;
  padding: 8px;
  padding-top: 72px;

  & .btn-back-wrapper {
    margin: 10px;
  }
}

.menu-list .menu-item,
.menu-item-lang {
  padding: 12px 0px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border-bottom: 1px solid var(--gray-color);

  & .menu-text p,
  h6 {
    margin: 0px;
  }

  & menu-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
  }
}

.menu-item-lang {
  margin: 16px 0px;
  padding: 6px;
  border: none;
  background-color: var(--opacity-gray);
  box-shadow: 0 3px 8px var(--secondary-color-mute);
  border-radius: 50px;

  & span.i-flag {
    display: block;
    width: 48px;
    height: 48px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border: 2px solid var(--white-color);
    border-radius: 100%;
  }

  & span.i-flag-th {
    background-image: url(/img/beauty/icon/flag-th.webp);
  }
  & span.i-flag-en {
    background-image: url(/img/beauty/icon/flag-en.webp);
  }
}

.section-wrapper {
  & h1 {
    font-size: 2rem;
  }
}

.wrapper-logo {
  margin: 12px;
  padding: 0px 1.75rem;
  overflow: hidden;

  & img {
    width: 100%;
  }
}

.close-position {
  position: absolute;
  top: 50%;
  right: 8px;
  transform: translateY(-50%);
}
