/* ===== Base ===== */
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  background: #f5f7fa;
  color: #222;
}

/* ===== Brand Header (OLD UI) ===== */
.brand-header {
  background: #006bb6;
  text-align: center;
  padding: 14px 10px;
}

.brand-header img {
  height: 56px;
}

/* ===== Layout ===== */
.container {
  max-width: 960px;
  margin: auto;
  padding: 20px;
}

/* ===== Card (OLD UI) ===== */
.card {
  background: #ffffff;
  border-radius: 14px;
  margin: 20px auto;
  padding: 20px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.06);
  max-width: 420px;
}

.card-title {
  font-size: 14px;
  font-weight: 600;
  border-bottom: 1px solid #eee;
  padding-bottom: 8px;
  margin-bottom: 14px;
  display: flex;
  flex-direction: column;
}

/* ===== Badge ===== */
.badge {
  display: none;
  margin-top: 6px;
  padding: 4px 10px;
  font-size: 12px;
  font-weight: 600;
  color: #065f46;
  background: #d1fae5;
  border-radius: 999px;
  width: fit-content;
}

/* ===== Dashboard Tabs ===== */
.dashboard {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  margin: 25px 0;
}

.action-card {
  background: #ffffff;
  border-radius: 12px;
  padding: 22px 15px;
  text-align: center;
  font-size: 17px;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 6px 16px rgba(0,0,0,0.08);
}

.action-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 22px rgba(0,0,0,0.12);
}

/* ===== Forms ===== */
input {
  width: 100%;
  padding: 14px;
  font-size: 15px;
  border-radius: 10px;
  border: 1px solid #dcdcdc;
  margin-bottom: 14px;
}

button {
  width: 100%;
  padding: 14px;
  border-radius: 10px;
  border: none;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}

button.primary { background: #006bb6; color: #fff; }
button.accent { background: #fdb927; color: #111; }

/* ===== Two-step Flow ===== */
.flow-card {
  display: none;
  margin-top: 16px;
}

.flow-card.active {
  display: block;
}

/* ===== Status ===== */
.status {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 6px;
}

.status.success { color: #2e7d32; }
.status.warn { color: #d97706; }
.status.error { color: #d32f2f; }

.meta {
  font-size: 14px;
  color: #6b7280;
  white-space: pre-line;
}

/* ===== Footer ===== */
.footer {
  text-align: center;
  font-size: 12px;
  color: #6b7280;
  margin-top: 30px;
}


/* ===== Brand Header ===== */
.brand-header {
  background: #006bb6;
  padding: 18px 0;
  text-align: center;
}

.brand-header img {
  height: 54px;
}

/* ===== Page Centering ===== */
.page-center {
  display: flex;
  justify-content: center;
  padding: 30px 12px;
}

/* ===== Main Card ===== */
.main-card {
  width: 100%;
  max-width: 420px;
  background: #ffffff;
  border-radius: 18px;
  padding: 20px;
  box-shadow: 0 12px 30px rgba(0,0,0,0.08);
}

/* ===== Card Title ===== */
.card-title {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 14px;
}

.badge {
  display: inline-block;
  margin-top: 6px;
  padding: 4px 10px;
  font-size: 12px;
  font-weight: 600;
  color: #065f46;
  background: #d1fae5;
  border-radius: 999px;
}

/* ===== Segmented Tabs ===== */
.tab-bar {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  background: #eef4ff;
  border-radius: 14px;
  padding: 4px;
  margin: 18px 0;
}

.tab {
  text-align: center;
  padding: 10px 0;
  font-size: 14px;
  font-weight: 600;
  border-radius: 10px;
  cursor: pointer;
  color: #333;
}

.tab.active {
  background: #ffffff;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  color: #006bb6;
}

/* ===== Tab Content ===== */
.tab-content {
  margin-top: 16px;
}

/* ===== Two-step Flow ===== */
.flow-card {
  display: none;
  margin-top: 16px;
}

.flow-card.active {
  display: block;
}


.product-card.horizontal {
  display: flex;
  gap: 14px;
  background: #ffffff;
  border-radius: 18px;
  padding: 14px;
  margin-bottom: 18px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.08);
}

.product-image {
  flex: 0 0 96px;              /* fixed width column */
  height: 120px;               /* 👈 LOCKED HEIGHT */
  background: #f3f4f6;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
}


.product-image img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}
.product-details {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-start; /* 👈 NOT space-between */
  gap: 6px;
}
.product-name {
  font-size: 15px;
  font-weight: 600;
  color: #111827;
}

.product-model,
.product-pack {
  font-size: 13px;
  color: #6b7280;
}
.qty-control {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #f9fafb;
  border-radius: 999px;
  padding: 6px 12px;
  border: 1px solid #e5e7eb;
}

.qty-control button {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid #e5e7eb;
  background: #ffffff;

  display: flex;                 /* 👈 KEY */
  align-items: center;           /* 👈 KEY */
  justify-content: center;       /* 👈 KEY */

  font-size: 20px;
  font-weight: 600;
  line-height: 1;                /* 👈 prevents baseline shift */
  padding: 0;

  color: #111827;
  cursor: pointer;
}

.qty-control .qty {
  font-size: 15px;
  font-weight: 600;
}

.qty-control button.dec {
  font-size: 22px;   /* minus needs slightly bigger */
}

.qty-control button.inc {
  font-size: 20px;
}
