html, body, * {
  box-sizing: border-box;
}

body:has(.popup.show) {
  overflow: hidden;
}
.db_panel{
  display: none;
}
.mt20 { margin-top: 20px; }
.mt40 { margin-top: 40px; }

table {
  border-collapse: collapse;
  border-spacing: 0px;
}

table th,
table td {
  padding: 10px;
  border: 1px solid #999999;
}

fieldgroup, .fieldgroup {
  border: 1px solid #d9d9d9;
  border-radius: 6px;
  margin-top: 15px;
  display: block;
  position: relative;
}
fieldgroup.flex-wrap,
.fieldgroup.flex-wrap{
  flex-wrap: wrap;
}
.fieldgroup:has(.safix),
fieldgroup:has(.safix) {
  display: flex;
  align-items: center;
}

.fieldgroup .group_note,
fieldgroup .group_note{
  width: 100%;
  font-size: 10px;
  padding: 5px;
  color: #666666;
}
.fieldgroup .label,
fieldgroup label {
  position: absolute;
  font-size: 10px;
  background: #ffffff;
  top: -5px;
  left: 5px;
  padding: 0px 5px;
}
.fieldgroup label{
  padding: 15px 5px;
  display: inline-block;
}
.fieldgroup label input[type="checkbox"],
.fieldgroup label input[type="radio"]{
  display: inline-block;
  margin-right: 5px;
}
.fieldgroup input[type="text"],
fieldgroup input[type="text"],
fieldgroup select,
fieldgroup textarea{
  width: 100%;
  border: 0px;
  font-size: 16px;
  padding: 15px 10px 10px;
  border-radius: 6px;
  outline: none;
  font-weight: normal;
  line-height: 1.4;
  height: 46px;
}
fieldgroup select{
  width: calc(100% - 10px);
}
.group_row{
  display: flex;
  gap: 10px;
}
.group_row .group_cell_half{
  width: calc( (100% - 10px) / 2 );
}
.group_row .group_cell_auto{
  width: auto;
}
.group_row #item_ship_days {
  width: 140px;
}
.group_row #item_ship_size {
  width: 70px;
}
.error_note{
  margin-top: 20px;
  border: 1px solid #ff5555;
  border-radius: 6px;
  background: #ffdddd;  
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 10px;
}
.error_note[data-res=""]{
  display: none;
}
.error_note[data-res="ok"]{
  border: 1px solid #4ec34e;
  background: #d5ffa6;
}
.error_note[data-res="ok"] > div:before{
  font-family: "Font Awesome 6 Free";
  content: '\f06a';
  color: #4ec34e;
  font-weight: 900;
  margin-right: 5px;  
}
.error_note[data-res="ng"] > div:before{
  font-family: "Font Awesome 6 Free";
  content: '\f06a';
  color: #ff5555;
  font-weight: 900;
  margin-right: 5px;  
}

#holder-name{
  margin-bottom: 10px;
}
#input_holder_name{
  border-radius: 6px;
  border: 1px solid #d9d9d9;
  height: 50px;
  margin: 0;
  box-sizing: border-box;
  width: 100%;
  background-color: rgba(0,0,0,0);
  font-family: "Square Sans Text VF","Square Sans Text",Arial,sans-serif;
  font-weight: 400;
  font-size: 16px;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  padding-left: 16px;
}

#input_holder_name:focus {
    outline: none
}

#input_holder_name:invalid {
    box-shadow: none
}


#store_dashboard .db_main {
  display: flex;
  height: 100vh;
  font-size: 14px;
}
#store_dashboard .db_menu {
  background: #f9f9f9;
  padding: 20px 15px;
  min-width: 230px;
}
#store_dashboard .db_menu i {
  display: inline-block;
  margin-right: 10px;
  width: 20px;
  text-align: center;
}
#store_dashboard .db_menu h1 {
  padding: 10px 15px;
  font-weight: bold;
  background: #dddddd;
  border-radius: 5px;
  margin-bottom: 10px;
}
#store_dashboard .db_menu dd{
  margin: 0px;
  cursor: pointer;
  padding: 10px 15px;
  border-radius: 5px;
  color: #666666;
}
#store_dashboard .db_menu dd:hover,
#store_dashboard .db_menu dd.active{
  background: #d9e7ee;
  color: #000000;
}

#store_dashboard .db_content {
  padding: 20px 15px;
  width: 100%;
  height: 100%;
  overflow-y: scroll;
}
#store_dashboard .db_content form{
  width: 100%;
  max-width: 520px;
}
#store_dashboard .db_content h2 {
  font-size: 18px;
  font-weight: bold;
  margin-bottom: 20px;
  
}
#panel_conf_store textarea {
  min-height: 6em;
}

.db_menu_separater:before{
  content: '';
  display: block;
  border-top: 1px solid #dddddd;
  margin: 10px 0px;
}

.btn_primary{
  width: 100%;
  margin-top: 20px;
  background: #358ee3;
  color: #ffffff;
  font-weight:bold;
  font-size: 16px;
  border: 0px;
  border-radius: 5px;
  height: 50px;
  cursor: pointer;
}
.btn_primary:hover{
  background: #66acee;
  opacity: 1;
}

.btn_secondary{
  border: 1px solid #358ee3;
  background: #ffffff;
  color: #358ee3;
  border-radius: 5px;
  cursor: pointer;
}
.btn_secondary:hover{
  background: #358ee3;
  color: #ffffff;
  opacity: 1;
}

#card-container{
  margin-top: 10px;
}

#panel_shipment:has(input[name="use_ship_free"][value="use"]:checked) #ship_free_amount{
  display: flex;
}
#ship_free_amount{
  display: none;
}
#ship_free_price{
  width: 100px;
  text-align: right;
}

.ship_fee_list .ship_fee_template,
.ship_fee_list tr.size_template {
  display: none;
}
.ship_fee_list td:has(.btn_ship_fee_add_col),
.ship_fee_list td:has(.btn_ship_fee_add_row) {
  position: relative;
}
.ship_fee_list tbody tr:has(.btn_ship_fee_add_row):hover button,
.ship_fee_list thead:hover button.btn_ship_fee_add_row,
.ship_fee_list td:has(.btn_ship_fee_add_row):hover button,
.ship_fee_list td:has(.btn_ship_fee_add_col):hover button {
  display: block;
}
.ship_fee_list td .btn_ship_fee_remove_col,
.ship_fee_list td .btn_ship_fee_remove_row,
.ship_fee_list td .btn_ship_fee_add_col,
.ship_fee_list td .btn_ship_fee_add_row{
  display: none;
  position: absolute;
  right: 0px;
  width: 16px;
  height: 16px;
  text-align: center;
  line-height: 15px;
  font-size: 11px;
  font-weight: bold;
  border: 2px solid #cccccc;
  background: #ffffff;
  border-radius: 100px;
  color: #009900;
  top: 50%;
  right: -8px;
  transform: translateY(-50%);
  padding: 0px;
  z-index: 2;
}
.ship_fee_list td .btn_ship_fee_add_col:hover,
.ship_fee_list td .btn_ship_fee_add_row:hover{
  background: #009900;
  color: #ffffff;
  opacity: 1;
}
.ship_fee_list td .btn_ship_fee_add_row{
  right: auto;
  top: auto;
  left: 50%;
  transform: translateX(-50%);
  bottom: -8px;
}
.ship_fee_list td .btn_ship_fee_remove_col i,
.ship_fee_list td .btn_ship_fee_remove_row i,
.ship_fee_list td .btn_ship_fee_add_col i,
.ship_fee_list td .btn_ship_fee_add_row i{
  text-align: center;
  display: block;
  opacity: 1;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translateX(-50%) translateY(-50%);
}
.ship_fee_list td .btn_ship_fee_remove_col,
.ship_fee_list td .btn_ship_fee_remove_row{
  border: 0px;
  font-size: 14px;
  color: #cc0000;
  opacity: 1;
  right: auto;
  left: -8px;
}
.ship_fee_list td .btn_ship_fee_remove_col{
  top: -8px;
  left: 50%;
  transform: translateX(-50%);
}

.ship_fee_list td.size_input div {
  display: flex;
}

.ship_fee_list {
  margin: 10px 5px;
}

.ship_fee_list .scroll_area{
  overflow: scroll;
  max-height: 0px;
  scrollbar-width: thin;
  scrollbar-color: #999999 transparent;
  display: block;
  transition: 0.5s;
  /* height: 0px; */
}

#ship_fee .ship_fee {
  margin-top: 10px;
}
#ship_fee .ship_fee_list thead td{
  white-space: nowrap;
  padding: 5px 10px;
}
#ship_fee .ship_fee_list td,
#ship_fee .ship_fee_list input{
  padding: 1px 5px;
}
#ship_fee .ship_fee_list input.ship_fee_name{
  padding: 5px 10px;
}
#ship_fee .ship_fee_list table{
  margin: 8px;
}
#ship_fee .ship_fee_list td input{
  text-align: right;
}
textarea::placeholder,
input::placeholder{
  color: #cccccc;
}
#ship_fee .ship_fee_list thead td:nth-child(1){
  min-width: 110px;
  max-width: 110px;
  width: 110px;
}
#ship_fee .ship_fee_list thead td{
  text-align: center;
  top: 0px;
  left: 0px;
  width: 95px;
  padding: 10px;
  background: #eeeeee;
  /* z-index: 1; */
}
#ship_fee .ship_fee_list thead .area_select{
  cursor: pointer;
}
#ship_fee .ship_fee_list thead .area_select:hover{
  opacity: 0.7;
}
#ship_fee .ship_fee_list thead .selected_area{
  display: flex;
  flex-wrap: wrap;
  margin-top: 5px;
  gap: 5px;
}
#ship_fee .ship_fee_list thead .selected_area input{
  display: none;
}
#ship_fee .ship_fee_list thead .selected_area label {
  font-size: 10px;
  background: #3496c8;
  color: #ffffff;
  padding: 3px 5px;
  border-radius: 4px;
}
.size_input div {
  display: flex;
  align-items: center;
  gap: 5px;
}
.size_input span {
  font-size: 12px;
}
.ship_fee_header{
  position: relative;
  display: flex;
  gap: 5px;
  align-items: center;
}
.btn_ship_fee_remove_col i,
.btn_ship_fee_remove_row i,
.ship_fee_header i{
  width: 20px;
  font-family: "Font Awesome 6 Free";
  display: inline-block;
  opacity: 0.5;
  cursor: pointer;
}
.ship_fee_header i:hover{
  opacity: 1;
}
.ship_fee_header label {
  padding: 0px;
}
.ship_fee_header label .ship_fee_open{
  display: none !important;
}
.ship_fee_header i.ship_fee_copy:before{
  content: '\f24d';  
}
.btn_ship_fee_remove_col i:before,
.btn_ship_fee_remove_row i:before,
.ship_fee_header i.ship_fee_delete:before{
  content: '\f057';  
}
.ship_fee_header .ship_fee_open + i:before{
  content: '\f107';
  font-weight: bold;
}
.ship_fee:has(.ship_fee_open:checked) .ship_fee_open + i:before{
  content: '\f106';
  font-weight: bold;
}
.ship_fee:has(.ship_fee_open:checked) .scroll_area{
  display: block;
  max-height: 200px;
}
.ship_fee_footer{
  text-align: right;
  margin: 0px 5px 5px;
}

.popup {
  visibility: hidden;
  position: fixed;
  top: 0px;
  left: 0px;
  right: 0px;
  bottom: 0px;
  background: rgba(0, 0, 0, 0.3);
  transition: 0.5s;
  opacity: 0;
  z-index: 5;
}
.popup.show {
  visibility: visible;
  opacity: 1;
}
.popup_box {
  position: absolute;
  width: 800px;
  height: 400px;
  max-height: 70dvh;
  max-width: 80vw;
  background: #ffffff;
  top: 50%;
  left: 50%;
  transform: translateY(-50%) translateX(-50%);
  border-radius: 10px;
  box-shadow: 0px 0px 10px rgba(0,0,0,0.3);
}
.popup_header {
  padding: 10px;
  text-align: center;
}
.popup_close {
  position: absolute;
  top: 5px;
  right: 5px;
  color: #cc0000;
  background: none;
  border: none;
  font-size: 20px;
  width: 20px;
  height: 20px;
  padding: 0px;
}
.popup_close i {
  padding: 0px;
  margin: 0px;
}

#popup_loading .popup_box {
  width: 300px;
  height: 200px;
}
#popup_loading .popup_body {
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content:space-evenly;
  color: #666666;
  letter-spacing: 4px;
}
#popup_loading .popup_body i {
  width: 64px;
  height: 64px;
  background: conic-gradient(#ffffff 0%, #666666 10%, #ffffff 90%) ;
  border-radius: 100px;
  position: relative;
  animation-name: loading_rotate;
  animation-duration: 1s;
  animation-timing-function:linear;
  animation-iteration-count: infinite;
}
@keyframes loading_rotate{
  0%{
    transform: rotate(0deg);
  }
  100%{
    transform: rotate(-360deg);
  }
}
#popup_loading .popup_body i:before {
  content: '';
  display: block;
  width: 54px;
  height: 54px;
  background: #ffffff;
  border-radius: 100px;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translateX(-50%) translateY(-50%);
}

#store_dashboard .popup_header h2{
  margin: 0px;
}

.popup_body {
  display: flex;
  flex-direction: column;
  height: calc(100% - 50px);
}
.popup .search_area{
  padding: 0px 10px;
}
.popup .search_area input{
  border: 0px;
  background: #eeeeee;
  width: 100%;
  padding: 8px 10px;
  font-size: 16px;
  border-radius: 6px;
  outline: none;
}
.popup .select_area{
  margin: 10px;
  margin-right: 10px;
  height: calc(100% - 75px);
  overflow-y: scroll;
  scrollbar-color: #999999 rgba(0,0,0,0)
}
.popup .select_area label{
  display: block;
  width: 100%;
  padding: 10px 5px;
  border-bottom: 1px solid #cccccc;
  display: flex;
  align-items: center;
  gap: 5px;
}
.popup .select_area label:hover{
  background: #eeeeee;
}
#popup_select_area .btn_primary {
  margin: 0px 10px;
  width: calc(100% - 20px);
}
#popup_select_area .area_not_found {
  display: none;
}

.payment_bank_on{
  display: none;
}
#payment_bank:has(#check_paymethod_bank:checked) .payment_bank_on{
  display: inherit;
}

#item_catalog{
  position: relative;
}
#item_catalog .label{
  z-index: 1;
}
#item_catalog label{
  padding: 0px;
  width: 100%;
}
#inp_item_catalog{
  width: 100%;
}
#catalog_list {
  display: none;
  position: absolute;
  z-index: 1;
  background: #ffffff;
  width: calc(100% + 2px);
  left: -1px;
  border: 1px solid #cccccc;
  border-top: 0px;
  margin-top: -6px;
  box-shadow: 0px 5px 3px rgba(0,0,0,0.1);
  max-height: 70dvh;
  overflow-y: scroll;
  
}
#catalog_list li{
  padding: 10px 10px;
}
#catalog_list li:hover{
  background: #358ee3;
  color: #ffffff;
}
#item_catalog:has(#inp_item_catalog:focus) #catalog_list,
#item_catalog:has(#inp_item_catalog:active) #catalog_list {
  display: block;
}
#item_size:has(select option[value=""]:last-child),
#item_status:has(select option[value=""]:last-child),
#item_category #cat_b option[value=""]:last-child,
#item_category #cat_b:has(option[value="---"]:checked),
#item_category #cat_a:has(option[value=""]:checked) + #cat_b{
  display: none;
}
#item_category #cat_b{
  display: block;
  padding-top: 0px;
}
#btn_catalog_clear i,
#btn_catalog_clear{
  border: 0px;
  width: 14px;
  height: 14px;
  display: block;
  margin: 0px;
  padding: 0px;
  background: none;
}
#btn_catalog_clear{
  padding: 5px;
  position: absolute;
  top: 13px;
  right: 15px;
}
#panel_listing h3{
  margin-top: 30px;
  font-weight: bold;
}
#panel_listing #item_detail textarea{
  height: 10em;
}
#item_images:has(.template:last-child),
#item_images .template{
  display: none;
}
#item_images .images{
  display: flex;
  overflow-x: auto;
  padding: 0px 8px;
}
#item_images label{
  text-align: center;
  cursor: pointer;
  position: relative;
}
#item_images label .thumb{
  width: 90px;
  height: 90px;
  background: #eeeeee;
  background-repeat: no-repeat;
  background-position: center;
  background-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSI0MCIgaGVpZ2h0PSI0MCIgdmlld0JveD0iMCAwIDUxMiA1MTIiPjxwYXRoIGZpbGw9IiNjY2NjY2MiIGQ9Ik0xNDkuMSA2NC44TDEzOC43IDk2IDY0IDk2QzI4LjcgOTYgMCAxMjQuNyAwIDE2MEwwIDQxNmMwIDM1LjMgMjguNyA2NCA2NCA2NGwzODQgMGMzNS4zIDAgNjQtMjguNyA2NC02NGwwLTI1NmMwLTM1LjMtMjguNy02NC02NC02NGwtNzQuNyAwTDM2Mi45IDY0LjhDMzU2LjQgNDUuMiAzMzguMSAzMiAzMTcuNCAzMkwxOTQuNiAzMmMtMjAuNyAwLTM5IDEzLjItNDUuNSAzMi44ek0yNTYgMTkyYTk2IDk2IDAgMSAxIDAgMTkyIDk2IDk2IDAgMSAxIDAtMTkyeiIvPjwvc3ZnPg==");
}
#item_images label .thumb[style]{
  background-size: contain;
}
#item_images label input{
  display: inline-block;
  width: 1px;
  height: 1px;
  outline: none;
}
#item_images label button{
  display: none;
}
#item_images label:has(.thumb[style]) button{
  display: block;
  position: absolute;
  top: 18px;
  right: 8px;
  padding: 0px;
  border: 0px;
  background: none;
  color: #cc0000;
  opacity: 0.7;
  background: #ffffff;
  border-radius: 100px;
  padding: 1px;
  width: 16px;
  height: 16px;
}

.group_row:has(#item_publish) .group_cell_auto{
  width: 100%;
}

#item_ship_fee input,
#item_price input,
#item_stock input{
  text-align: right;
}

#item_ship_fee .safix,
#item_price .safix{
  padding-right: 10px;
  display: block;
  position: relative;
  top: 2px;
  color: #666666;
}

#item_ship_size,
#item_ship_fee,
#item_ship_method {
  display: none;
}
#panel_listing:has(input[name="item_shipment"][value="calc"]:checked) #item_ship_size,
#panel_listing:has(input[name="item_shipment"][value="calc"]:checked) #item_ship_method{
  display: inherit;
}
#panel_listing:has(input[name="item_shipment"][value="sum"]:checked) #item_ship_fee{
  display: inherit;
}