* {
  box-sizing: border-box;
}

.container {
  /*max-width: 420px;
  margin: auto;
  padding: 24px 16px;*/
}

h1, h2 {
  margin-bottom: 12px;
}

input,
textarea,
select {
  width: 100%;
  padding: 12px 14px;
  margin-bottom: 12px;

  font-size: 14px;
  line-height: 1.4;

  border-radius: 12px;
  border: 1px solid #dcdcdc;
  background: #fff;
  color: #222;

  outline: none;
}

input::placeholder,
textarea::placeholder {
  color: #aaa;
}

input:focus,
textarea:focus,
select:focus {
  border-color: #0F3D2E;
}

button {
  width: 100%;
  padding: 14px;
  margin-top: 6px;

  border-radius: 14px;
  border: none;

  background: #0F3D2E;
  color: #fff;

  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}

/* === STICKY HEADER IOS STYLE === */
.form-header {
  position: sticky;
  top: 0;
  z-index: 999;

  display: flex;
  align-items: center;
  justify-content: space-between;

  background: #fff;

  /* === KUNCI NAIK === */
  padding: 12px 16px;
  padding-top: calc(env(safe-area-inset-top) + 8px);

  border-bottom: 1px solid #eee;
}

/* kasih ruang agar konten tidak ketutup */
.products-page {
  padding-top: 0 !important;
}

/* title */
.form-header h2 {
  font-size: 17px;
  font-weight: 600;
  margin: 0;
}

/* back button */
.form-header .back {
  color: #111;
  font-size: 18px;
  text-decoration: none;
}

/* tombol tambah */
.form-header .btn-add {
  background: #0f3d2e;
  color: #fff;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 12px;
  text-decoration: none;
}

/* === ^^BATAS STICKY HEADER IOS STYLE === 

.card {
  background: #fff;
  border-radius: 18px;
  padding: 20px;
  box-shadow: 0 10px 28px rgba(0,0,0,.06);
}*/


.card{
  background:#fff;
  border-radius:16px;
  padding:16px;
  margin-bottom:16px;
  box-shadow:0 10px 24px rgba(0,0,0,.06);
}

.text-muted {
  color: #777;
  font-size: 13px;
}

.link {
  color: #0F3D2E;
  text-decoration: none;
  font-weight: 600;
}

input::-ms-reveal,
input::-ms-clear {
  display: none;
}

/* === PRODUCTS PAGE === */

.products-page {
  max-width: 420px;
  margin: 0 auto;
}

.page-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.page-header h2 {
  font-size: 20px;
  font-weight: 700;
}

.btn-primary {
  background: linear-gradient(135deg, #0F3D2E, #1B5E46);
  color: #fff;
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
}

.product-card {
  background: #fff;
  border-radius: 18px;
  padding: 16px;
  margin-bottom: 14px;
  box-shadow: 0 12px 26px rgba(0,0,0,0.06);
}

.product-title {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 6px;
}

.product-badge {
  display: flex;
  gap: 6px;
  margin-bottom: 8px;
}

.badge {
  font-size: 11px;
  padding: 4px 10px;
  border-radius: 999px;
  font-weight: 600;
}

.badge-skin {
  background: #EAF4F0;
  color: #0F3D2E;
}

.badge-bpom {
  background: #F2F6FF;
  color: #1A73E8;
}

.product-desc {
  font-size: 13px;
  color: #555;
  line-height: 1.5;
}

.product-actions {
  margin-top: 12px;
  font-size: 13px;
  color: #777;
}

.product-actions a {
  color: #0F3D2E;
  text-decoration: none;
  font-weight: 600;
}

.product-actions .danger {
  color: #C62828;
}

/* === PRODUCT FORM === */

.form-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 16px 0;
}

.form-header h2 {
  font-size: 20px;
  font-weight: 700;
  margin: 0;
}

.back-link {
  font-size: 18px;
  text-decoration: none;
  color: #0F3D2E;
  font-weight: 700;
}

.product-form-card {
  background: #fff;
  border-radius: 20px;
  padding: 18px;
  box-shadow: 0 14px 30px rgba(0,0,0,0.06);
}

.form-group {
  margin-bottom: 14px;
}

.form-group input,
.form-group textarea {
  width: 100%;
  border: 1px solid #e3e3e3;
  border-radius: 14px;
  padding: 12px 14px;
  font-size: 14px;
  outline: none;
  background: #fff;
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: #0F3D2E;
}

.form-check {
  margin: 10px 0 14px;
  font-size: 14px;
  color: #333;
}

.form-check input {
  margin-right: 6px;
}

.btn-primary.full {
  width: 100%;
  border: none;
  border-radius: 16px;
  padding: 14px;
  font-size: 15px;
  font-weight: 700;
  background: linear-gradient(135deg, #0F3D2E, #1B5E46);
  color: #fff;
  cursor: pointer;
}

/* === PRODUCTS PAGE === */

.products-page {
  padding-bottom: 40px;
}

.page-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 16px 0;
}

.page-header h2 {
  font-size: 20px;
  font-weight: 700;
  margin: 0;
}

.btn-add {
  background: #0F3D2E;
  color: #fff;
  padding: 8px 14px;
  border-radius: 12px;
  font-size: 13px;
  text-decoration: none;
  font-weight: 600;
}

/* .product-card definition was conflicting with Marketplace grid */

.product-thumb img {
  width: 72px;
  height: 72px;
  border-radius: 14px;
  object-fit: cover;
  background: #f1f1f1;
}

.product-info {
  flex: 1;
}

.product-title {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 4px;
}

.product-badges {
  display: flex;
  gap: 6px;
  margin-bottom: 6px;
}

.badge {
  font-size: 11px;
  padding: 4px 8px;
  border-radius: 999px;
  font-weight: 600;
}

.badge-skincare {
  background: #EAF4F0;
  color: #0F3D2E;
}

.badge-bpom {
  background: #EEF3FF;
  color: #1a73e8;
}

.product-desc {
  font-size: 13px;
  color: #555;
  margin-bottom: 8px;
}

.product-actions {
  font-size: 12px;
}

.product-actions a {
  color: #0F3D2E;
  text-decoration: none;
  font-weight: 600;
}

.empty-state {
  background: #fff;
  border-radius: 16px;
  padding: 20px;
  text-align: center;
  color: #777;
}
.badge-featured {
  background: linear-gradient(135deg,#C9A24D,#A8842C);
  color:#fff;
}

.product-images{
  display:flex;
  gap:12px;
  flex-wrap:wrap;
  margin-top:10px;
}

/* ADD */
.add-box{
  width:66px;
  height:66px;
  border-radius:16px;
  border:2px dashed #ddd;
  background:#fafafa;
  display:flex;
  flex-direction:column;
  justify-content:center;
  align-items:center;
  color:#999;
  cursor:pointer;
}
.add-box i{
  font-size:20px;
  margin-bottom:4px;
}

@supports (padding: max(0px)) {
  .form-header {
    padding-top: calc(env(safe-area-inset-top) + 12px);
  }
}

/* IMAGE ITEM
.img-item{
  position:relative;
  width:66px;
  height:66px;
  border-radius:16px;
  overflow:hidden;
}

.img-item img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}

.label-primary{
  position:absolute;
  bottom:6px;
  left:6px;
  background:#E53935;
  color:#fff;
  font-size:11px;
  padding:3px 8px;
  border-radius:10px;
  font-weight:600;
  z-index:999;
  display:flex;
  align-items:center;
  gap:4px;
}

.label-set-primary{
  position:absolute;
  bottom:6px;
  left:6px;
  background:rgba(0,0,0,.65);
  color:#fff;
  font-size:11px;
  padding:3px 8px;
  border-radius:10px;
  z-index:999;
  cursor:pointer;
}

.img-remove{
  position:absolute;
  top:-6px;
  right:-6px;
  width:22px;
  height:22px;
  background:#111;
  color:#fff;
  border-radius:50%;
  display:flex;
  align-items:center;
  justify-content:center;
  text-decoration:none;
  font-size:12px;
}

#imagePreview{
  display:flex;
  gap:12px;
}*/

