/* =========================
   MK Box Builder - Clean UI
   ========================= */

.mkbb {
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color: rgba(0,0,0,.88);
}
.mkbb * { box-sizing: border-box; }

/* ---------- Header ---------- */
.mkbb-header{
  display:flex;
  gap:16px;
  align-items:center;
  justify-content:space-between;
  margin: 6px 0 16px;
}

.mkbb-headcopy .mkbb-eyebrow{
  margin:0;
  font-size:12px;
  letter-spacing:.08em;
  text-transform:uppercase;
  color: rgba(0,0,0,.55);
}

.mkbb-subtitle{
  margin:6px 0 0;
  font-size:15px;
  line-height:1.35;
  color: rgba(0,0,0,.82);
}
.mkbb-subtitle .mkbb-subtle{ opacity:.7; }

.mkbb-chips{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  justify-content:flex-end;
}

.mkbb-chip{
  display:flex;
  align-items:center;
  gap:8px;
  padding:8px 10px;
  border-radius:999px;
  border:1px solid rgba(0,0,0,.08);
  background: rgba(255,255,255,.92);
}

.mkbb-chip-label{ font-size:12px; opacity:.6; }
.mkbb-chip-value{ font-size:13px; font-weight:650; }

#mkbb-ind-status.is-ready{
  border-color: rgba(34,197,94,.30);
  background: rgba(34,197,94,.08);
}
#mkbb-ind-status.is-missing{
  border-color: rgba(245,158,11,.28);
  background: rgba(245,158,11,.08);
}

@media (max-width: 640px){
  .mkbb-header{
    flex-direction:column;
    align-items:flex-start;
    gap:12px;
  }
  .mkbb-chips{ justify-content:flex-start; }
}

/* ---------- Layout ---------- */
.mkbb-layout{
  display:grid;
  grid-template-columns: 1.5fr .85fr;
  gap:16px;
}
@media (max-width: 960px){
  .mkbb-layout{ grid-template-columns: 1fr; }
}

/* ---------- Toolbar ---------- */
.mkbb-toolbar{
  display:flex;
  gap:10px;
  margin-bottom:12px;
}
.mkbb-search, .mkbb-select{
  width:100%;
  padding:10px 12px;
  border-radius:14px;
  border:1px solid rgba(0,0,0,.10);
  background:#fff;
}

/* ---------- Product Grid ---------- */
#mkbb-products{
  display:grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap:12px;
}
@media (max-width: 960px){
  #mkbb-products{ grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 520px){
  #mkbb-products{ grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ---------- Product Card ---------- */
.mkbb-product{
  border:1px solid rgba(0,0,0,.08);
  border-radius:18px;
  padding:12px;
  background:#fff;
  display:flex;
  flex-direction:column;
  gap:10px;
  position:relative;
}

.mkbb-product img{
  width:100%;
  height:auto;
  border-radius:14px;
  display:block;
  background: rgba(0,0,0,.02);
}

.mkbb-product h4{
  margin:0;
  font-size:14px;
  line-height:1.25;
}

.mkbb-price{
  font-weight:650;
  margin-top:2px;
}

.mkbb-product.has-qty{
  border-color: rgba(122,179,139,.40);
  box-shadow: 0 10px 26px rgba(122,179,139,.08);
}

/* Card actions */
.mkbb-actions{
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:8px;
  margin-top:auto;
}

/* Product card: stepper ortalı olsun */
.mkbb-actions--stepper{
  justify-content: center !important;
}

/* ---------- Buttons ---------- */
.mkbb-btn{
  border-radius:14px;
  border:1px solid rgba(0,0,0,.10);
  padding:10px 12px;
  cursor:pointer;
  background:#fff;
  color: rgba(0,0,0,.85);
}

.mkbb-btn:disabled{
  opacity:.45;
  cursor:not-allowed;
}

/* ghost is subtle */
.mkbb-btn-ghost{
  background: rgba(0,0,0,.04);
  border-color: rgba(0,0,0,.06);
}
.mkbb-btn-ghost:hover{
  background: rgba(0,0,0,.06);
}

/* product "Ekle" (qty=0) -> real CTA in-card */
.mkbb-add{
  width:100%;
  justify-content:center;
  border:none;
  background: rgb(122, 179, 139);
  color:#fff;
  font-weight:650;
  border-radius:14px;
  padding:10px 12px;
  box-shadow: 0 10px 22px rgba(122,179,139,.18);
}
.mkbb-add:hover{
  filter: brightness(.98);
  transform: translateY(-1px);
}
.mkbb-add:active{ transform: translateY(0); }

/* ===== Stepper v2 (product card) - premium ===== */
.mkbb-stepper{
  padding:6px;
  border:1px solid rgba(0,0,0,.06);
  background: rgba(255,255,255,.96);
  box-shadow: 0 10px 24px rgba(0,0,0,.06);
  width: fit-content !important;
  margin: 0 auto !important;
}

.mkbb-step{
  width:38px;
  height:38px;
  background: rgba(122,179,139,.14);              /* brand tint */
  color: rgba(0,0,0,.78);
  font-weight:700;
  border: 1px solid rgba(122,179,139,.18);
}

.mkbb-step:hover{
  background: rgba(122,179,139,.20);
}

.mkbb-step:active{
  transform: scale(.96);
}

.mkbb-step__qty{
  font-size:14px;
  font-weight:800;
  color: rgba(0,0,0,.85);
  min-width:34px;
  margin:10px;
}

/* Ortayı ayırmak için çok ince çizgi hissi (opsiyonel) */
.mkbb-stepper .mkbb-step__qty{
  position:relative;
}
.mkbb-stepper .mkbb-step__qty:before,
.mkbb-stepper .mkbb-step__qty:after{
  content:"";
  position:absolute;
  top:50%;
  width:1px;
  height:18px;
  transform: translateY(-50%);
  background: rgba(0,0,0,.06);
}
.mkbb-stepper .mkbb-step__qty:before{ left:-10px; }
.mkbb-stepper .mkbb-step__qty:after{ right:-10px; }

/* ---------- Right Card (box) ---------- */
.mkbb-right .mkbb-card{
  border:1px solid rgba(0,0,0,.08);
  border-radius:18px;
  padding:12px;
  background:#fff;
  position: sticky;
  top: 16px;
}
@media (max-width: 960px){
  .mkbb-right .mkbb-card{ position: static; }
}

.mkbb-card-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
}
.mkbb-card-head h3{ margin:0; font-size:16px; }

/* Box list */
.mkbb-boxlist{
  margin-top:10px;
  display:flex;
  flex-direction:column;
  gap:10px;
}

.mkbb-line{
  display:flex;
  justify-content:space-between;
  gap:10px;
  align-items:flex-start;
  border:1px solid rgba(0,0,0,.08);
  border-radius:14px;
  padding:10px;
  background: #fff;
}

.mkbb-line small{
  opacity:.65;
  display:block;
  margin-top:2px;
}

/* Locked badge */
.mkbb-badge{
  font-size:12px;
  padding:4px 8px;
  border-radius:999px;
  border:1px solid rgba(0,0,0,.10);
  background: rgba(0,0,0,.03);
}

/* Box line qty controls (minimal) */
.mkbb-line .mkbb-qty{
  display:flex;
  align-items:center;
  gap:6px;
}

.mkbb-line .mkbb-qty .mkbb-btn{
  width:32px;
  height:32px;
  padding:0;
  border-radius:999px;
  border:1px solid rgba(0,0,0,.08);
  background: rgba(0,0,0,.04);
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:16px;
}
.mkbb-line .mkbb-qty .mkbb-btn:hover{
  background: rgba(0,0,0,.06);
}

.mkbb-line .mkbb-qty .mkbb-pill{
  border:none;
  background: transparent;
  padding:0 6px;
  font-weight:750;
  min-width:18px;
  text-align:center;
}

/* Summary + CTA */
.mkbb-summary{
  margin-top:10px;
  padding-top:10px;
  border-top:1px solid rgba(0,0,0,.08);
}
.mkbb-row{
  display:flex;
  justify-content:space-between;
  align-items:center;
}

.mkbb-btn-primary{
  background-color: rgb(122, 179, 139) !important;
  color:#fff;
  border:none;
  width:100%;
  margin-top:10px;
  border-radius:14px;
  box-shadow: 0 10px 26px rgba(122,179,139,.18);
  transition: transform .12s ease, box-shadow .12s ease, opacity .12s ease;
}
.mkbb-btn-primary:hover{
  transform: translateY(-1px);
  box-shadow: 0 14px 32px rgba(122,179,139,.22);
}
.mkbb-btn-primary:active{ transform: translateY(0); }
.mkbb-btn-primary:disabled{ opacity:.45; box-shadow:none; cursor:not-allowed; }

/* Misc */
.mkbb-muted{ opacity:.7; }
.mkbb-help{ margin-top:10px; font-size:13px; opacity:.8; }
.mkbb-alert{ padding:12px; border-radius:14px; border:1px solid rgba(0,0,0,.10); background:#fff; }
