/* Brand Partner Dashboard — ReWrap design language */

:root {
  --bp-ink: #14141a;
  --bp-muted: #667085;
  --bp-canvas: #f7f7f9;
  --bp-panel: #ffffff;
  --bp-line: rgba(20, 20, 26, 0.08);
  --bp-pink: #ff4d8d;
  --bp-orange: #ff7a3d;
  --bp-green: #1fa97a;
  --bp-indigo: #1e1b4b;
  --bp-warn: #b45309;
  --bp-danger: #c81e1e;
  --bp-sidebar: #111118;
  --bp-sidebar-text: rgba(255, 255, 255, 0.72);
  --bp-sidebar-active: #ffffff;
  --bp-font: "Manrope", "Segoe UI", sans-serif;
  --bp-display: "Syne", "Manrope", sans-serif;
  --bp-grad: linear-gradient(135deg, #ff4d8d 0%, #ff7a3d 55%, #ffb020 100%);
  --bp-radius: 14px;
  --bp-shadow: 0 10px 30px rgba(15, 23, 42, 0.06);
  --bp-sidebar-w: 248px;
}

*,
*::before,
*::after { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
  background: var(--bp-canvas);
  color: var(--bp-ink);
  font-family: var(--bp-font);
  font-size: 14px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
img { max-width: 100%; display: block; }

.bp-shell {
  display: grid;
  grid-template-columns: var(--bp-sidebar-w) 1fr;
  min-height: 100vh;
}

.bp-sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  background: var(--bp-sidebar);
  color: var(--bp-sidebar-text);
  padding: 22px 14px 18px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  overflow-y: auto;
}

.bp-brand-mark {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 4px 8px 12px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.bp-brand-mark img {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: #fff;
}

.bp-brand-mark__text strong {
  display: block;
  color: #fff;
  font-family: var(--bp-display);
  font-size: 15px;
  letter-spacing: -0.02em;
}

.bp-brand-mark__text span {
  font-size: 11px;
  color: rgba(255,255,255,0.5);
}

.bp-partner-chip {
  margin: 0 8px;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
}

.bp-partner-chip__label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(255,255,255,0.45);
}

.bp-partner-chip__name {
  color: #fff;
  font-weight: 700;
  margin-top: 2px;
}

.bp-nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
}

.bp-nav a {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 10px;
  color: var(--bp-sidebar-text);
  transition: background 0.18s ease, color 0.18s ease;
}

.bp-nav a:hover {
  background: rgba(255,255,255,0.06);
  color: #fff;
}

.bp-nav a.is-active {
  background: rgba(255,255,255,0.1);
  color: var(--bp-sidebar-active);
  font-weight: 650;
}

.bp-nav a.is-active::before {
  content: "";
  position: absolute;
  left: 0;
  top: 10px;
  bottom: 10px;
  width: 3px;
  border-radius: 0 3px 3px 0;
  background: var(--bp-grad);
  animation: bp-slide-in 0.25s ease;
}

@keyframes bp-slide-in {
  from { transform: scaleY(0.4); opacity: 0; }
  to { transform: scaleY(1); opacity: 1; }
}

.bp-nav__ico {
  width: 18px;
  text-align: center;
  opacity: 0.85;
  font-size: 13px;
}

.bp-sidebar__foot {
  padding: 8px;
  border-top: 1px solid rgba(255,255,255,0.08);
}

.bp-sidebar__foot form { margin: 0; }

.bp-main {
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.bp-topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 28px;
  background: rgba(247, 247, 249, 0.86);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--bp-line);
}

.bp-topbar h1 {
  margin: 0;
  font-family: var(--bp-display);
  font-size: 22px;
  letter-spacing: -0.03em;
}

.bp-topbar__meta {
  color: var(--bp-muted);
  font-size: 12px;
  margin-top: 2px;
}

.bp-topbar__right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.bp-content {
  padding: 22px 28px 40px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.bp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  font-weight: 650;
  transition: transform 0.15s ease, box-shadow 0.15s ease, opacity 0.15s ease;
}

.bp-btn:hover { transform: translateY(-1px); }
.bp-btn:active { transform: translateY(0); }

.bp-btn--grad {
  background: var(--bp-grad);
  color: #fff;
  box-shadow: 0 8px 20px rgba(255, 77, 141, 0.28);
}

.bp-btn--ghost {
  background: transparent;
  border-color: var(--bp-line);
  color: var(--bp-ink);
}

.bp-btn--dark {
  background: var(--bp-indigo);
  color: #fff;
}

.bp-btn--sm {
  padding: 7px 12px;
  font-size: 12px;
}

.bp-btn--block { width: 100%; }

.bp-messages { display: flex; flex-direction: column; gap: 8px; }
.bp-flash {
  padding: 12px 14px;
  border-radius: 12px;
  background: #eef8f3;
  border: 1px solid rgba(31, 169, 122, 0.25);
  color: #0f5c42;
}
.bp-flash--error {
  background: #fff1f1;
  border-color: rgba(200, 30, 30, 0.2);
  color: #8a1515;
}

.bp-grid {
  display: grid;
  gap: 14px;
}

.bp-grid--kpi {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.bp-grid--2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.bp-grid--studio {
  grid-template-columns: minmax(280px, 0.95fr) minmax(0, 1.15fr);
}

.bp-card {
  background: var(--bp-panel);
  border: 1px solid var(--bp-line);
  border-radius: var(--bp-radius);
  box-shadow: var(--bp-shadow);
  padding: 18px;
}

.bp-card__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.bp-card__head h2,
.bp-card__head h3 {
  margin: 0;
  font-family: var(--bp-display);
  font-size: 16px;
  letter-spacing: -0.02em;
}

.bp-card__head p {
  margin: 4px 0 0;
  color: var(--bp-muted);
  font-size: 12px;
}

.bp-kpi {
  position: relative;
  overflow: hidden;
}

.bp-kpi__label {
  color: var(--bp-muted);
  font-size: 12px;
  font-weight: 600;
}

.bp-kpi__value {
  margin-top: 8px;
  font-family: var(--bp-display);
  font-size: 28px;
  letter-spacing: -0.04em;
  font-weight: 700;
}

.bp-kpi__hint {
  margin-top: 6px;
  font-size: 12px;
  color: var(--bp-muted);
}

.bp-kpi__spark {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 28px;
  margin-top: 12px;
}

.bp-kpi__spark span {
  flex: 1;
  border-radius: 3px 3px 0 0;
  background: var(--bp-grad);
  opacity: 0.55;
  min-height: 4px;
  transform-origin: bottom;
  animation: bp-bar 0.6s ease both;
}

@keyframes bp-bar {
  from { transform: scaleY(0.2); opacity: 0; }
  to { transform: scaleY(1); opacity: 0.55; }
}

.bp-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 650;
  background: #f2f4f7;
  color: #344054;
}

.bp-chip--live { background: #e8f8f1; color: #0f7a52; }
.bp-chip--draft { background: #f2f4f7; color: #475467; }
.bp-chip--review { background: #fff6e8; color: var(--bp-warn); }
.bp-chip--paused { background: #f4f2ff; color: #5b2eff; }
.bp-chip--available { background: #eef5ff; color: #0a66c2; }
.bp-chip--claimed { background: #f2f4f7; color: #667085; }
.bp-chip--done { background: #e8f8f1; color: #0f7a52; }
.bp-chip--transit { background: #eef5ff; color: #0a66c2; }
.bp-chip--packed { background: #fff6e8; color: var(--bp-warn); }
.bp-chip--confirmed { background: #f4f2ff; color: #5b2eff; }

.bp-table-wrap { overflow-x: auto; }
.bp-table {
  width: 100%;
  border-collapse: collapse;
}
.bp-table th,
.bp-table td {
  text-align: left;
  padding: 12px 10px;
  border-bottom: 1px solid var(--bp-line);
  vertical-align: middle;
}
.bp-table th {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--bp-muted);
  font-weight: 700;
}
.bp-table tr:last-child td { border-bottom: 0; }
.bp-table tbody tr:hover td { background: #fafafa; }

.bp-empty {
  padding: 36px 20px;
  text-align: center;
  color: var(--bp-muted);
}
.bp-empty h3 {
  margin: 0 0 6px;
  color: var(--bp-ink);
  font-family: var(--bp-display);
}
.bp-empty p { margin: 0 0 16px; }

.bp-checklist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.bp-checklist li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--bp-line);
  background: #fafafa;
}
.bp-checklist li.is-done {
  background: #f3fbf7;
  border-color: rgba(31, 169, 122, 0.2);
}
.bp-check {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid #d0d5dd;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 10px;
}
.bp-checklist li.is-done .bp-check {
  border-color: var(--bp-green);
  background: var(--bp-green);
  color: #fff;
}

.bp-field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.bp-field label {
  font-size: 12px;
  font-weight: 650;
  color: #344054;
}
.bp-field input,
.bp-field select,
.bp-field textarea {
  padding: 11px 12px;
  border-radius: 12px;
  border: 1px solid #d0d5dd;
  background: #fff;
  color: var(--bp-ink);
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.bp-field input:focus,
.bp-field select:focus,
.bp-field textarea:focus {
  border-color: #ff7a3d;
  box-shadow: 0 0 0 3px rgba(255, 122, 61, 0.15);
}
.bp-field textarea { min-height: 88px; resize: vertical; }
.bp-field__hint { font-size: 11px; color: var(--bp-muted); }

.bp-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

.bp-theme-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}
.bp-theme {
  border: 1px solid var(--bp-line);
  border-radius: 12px;
  padding: 10px;
  cursor: pointer;
  background: #fff;
  text-align: left;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.bp-theme.is-active {
  border-color: transparent;
  box-shadow: 0 0 0 2px #14141a;
}
.bp-theme__swatch {
  height: 28px;
  border-radius: 8px;
  margin-bottom: 8px;
  background: linear-gradient(135deg, var(--t1), var(--t2));
}
.bp-theme__label { font-size: 12px; font-weight: 650; }

.bp-preview-phone {
  margin: 0 auto;
  width: min(100%, 320px);
  border-radius: 28px;
  padding: 14px;
  background: #0f1115;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.28);
}
.bp-preview-screen {
  background: #f7f7f9;
  border-radius: 20px;
  padding: 14px;
  min-height: 420px;
}
.bp-preview-card {
  border-radius: 16px;
  border: 1px solid var(--rw-border, rgba(0,0,0,0.08));
  background: #fff;
  overflow: hidden;
  transition: background 0.28s ease, border-color 0.28s ease, color 0.28s ease;
}
.bp-preview-card__media {
  height: 150px;
  background:
    linear-gradient(180deg, transparent, rgba(0,0,0,0.04)),
    var(--rw-bg-soft, #ffe8ef);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 12px;
  position: relative;
}
.bp-preview-card__media img {
  max-height: 120px;
  object-fit: contain;
}
.bp-preview-stamp {
  position: absolute;
  top: 10px;
  right: 10px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--rw-accent, var(--bp-pink));
  background: rgba(255,255,255,0.9);
  padding: 4px 8px;
  border-radius: 999px;
}
.bp-preview-body { padding: 14px; color: var(--rw-text, #14141a); }
.bp-preview-eyebrow {
  font-size: 11px;
  color: var(--rw-muted, #667085);
  margin-bottom: 4px;
}
.bp-preview-brand {
  font-family: var(--bp-display);
  font-weight: 800;
  color: var(--rw-accent, var(--bp-pink));
  font-size: 15px;
  margin-bottom: 6px;
}
.bp-preview-title {
  font-size: 18px;
  font-weight: 750;
  letter-spacing: -0.02em;
  margin: 0 0 8px;
}
.bp-preview-meta {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
}
.bp-preview-price {
  font-family: var(--bp-display);
  font-size: 22px;
  font-weight: 750;
}
.bp-preview-unit { color: var(--rw-muted, #667085); font-size: 12px; }
.bp-preview-cta {
  margin-top: 14px;
  width: 100%;
  border: 0;
  border-radius: 999px;
  padding: 11px;
  background: #102f2b;
  color: #fff;
  font-weight: 700;
}

.bp-calc {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.bp-calc__item {
  padding: 12px;
  border-radius: 12px;
  background: #fafafa;
  border: 1px solid var(--bp-line);
}
.bp-calc__item strong {
  display: block;
  font-family: var(--bp-display);
  font-size: 20px;
  margin-top: 4px;
  letter-spacing: -0.03em;
}
.bp-calc__item span { font-size: 11px; color: var(--bp-muted); font-weight: 650; }
.bp-calc__item--accent {
  background: linear-gradient(180deg, #fff8f4, #fff);
  border-color: rgba(255, 122, 61, 0.25);
}
.bp-calc__item--accent strong { color: #c2410c; }

.bp-product-pick {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}
.bp-product-pick a {
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px solid var(--bp-line);
  background: #fff;
  font-size: 12px;
  font-weight: 650;
}
.bp-product-pick a.is-active {
  background: var(--bp-indigo);
  color: #fff;
  border-color: var(--bp-indigo);
}

.bp-catalog-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.bp-sku {
  border: 1px solid var(--bp-line);
  border-radius: 14px;
  padding: 14px;
  background: #fff;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 180px;
}
.bp-sku__top {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: flex-start;
}
.bp-sku h3 {
  margin: 0;
  font-size: 15px;
  font-family: var(--bp-display);
}
.bp-sku p {
  margin: 0;
  color: var(--bp-muted);
  font-size: 12px;
}
.bp-sku__foot {
  margin-top: auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.bp-login {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(ellipse 60% 50% at 15% 20%, rgba(255, 77, 141, 0.14), transparent),
    radial-gradient(ellipse 50% 40% at 90% 80%, rgba(255, 122, 61, 0.12), transparent),
    #fdfdfd;
}
.bp-login__card {
  width: min(100%, 420px);
  background: #fff;
  border: 1px solid var(--bp-line);
  border-radius: 20px;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.08);
  padding: 28px;
}
.bp-login__logo {
  width: 64px;
  height: 64px;
  margin: 0 auto 12px;
}
.bp-login__card h1 {
  margin: 0 0 6px;
  text-align: center;
  font-family: var(--bp-display);
  font-size: 26px;
  letter-spacing: -0.03em;
}
.bp-login__card .lede {
  text-align: center;
  color: var(--bp-muted);
  margin: 0 0 22px;
}

.bp-menu-toggle {
  display: none;
  border: 1px solid var(--bp-line);
  background: #fff;
  border-radius: 10px;
  padding: 8px 10px;
  cursor: pointer;
}

.bp-ledger-credit { color: var(--bp-green); font-weight: 700; }
.bp-ledger-debit { color: var(--bp-danger); font-weight: 700; }
.bp-ledger-payout { color: #5b2eff; font-weight: 700; }

/* Overview — model story hero */
.bp-model-hero {
  position: relative;
  overflow: hidden;
  border-radius: 22px;
  padding: 36px 40px 34px;
  color: #fff;
  background:
    linear-gradient(135deg, #1a1024 0%, #1e1b4b 42%, #2a1538 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 24px 50px rgba(30, 27, 75, 0.28);
  animation: bp-hero-in 0.55s ease both;
}

@keyframes bp-hero-in {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.bp-model-hero__glow {
  position: absolute;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 77, 141, 0.45), transparent 68%);
  top: -180px;
  right: -80px;
  pointer-events: none;
  filter: blur(4px);
  animation: bp-glow-drift 8s ease-in-out infinite alternate;
}

.bp-model-hero__glow--2 {
  width: 320px;
  height: 320px;
  background: radial-gradient(circle, rgba(255, 122, 61, 0.35), transparent 70%);
  top: auto;
  bottom: -160px;
  left: -60px;
  right: auto;
  animation-delay: -3s;
}

@keyframes bp-glow-drift {
  from { transform: translate(0, 0) scale(1); }
  to { transform: translate(-24px, 16px) scale(1.08); }
}

.bp-model-hero__eyebrow {
  position: relative;
  margin: 0 0 12px;
  font-size: 11px;
  font-weight: 750;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}

.bp-model-hero__headline {
  position: relative;
  margin: 0;
  max-width: 18ch;
  font-family: var(--bp-display);
  font-size: clamp(28px, 4.2vw, 44px);
  line-height: 1.08;
  letter-spacing: -0.04em;
  font-weight: 800;
}

.bp-model-hero__headline em {
  font-style: normal;
  background: var(--bp-grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.bp-model-hero__lede {
  position: relative;
  margin: 16px 0 0;
  max-width: 58ch;
  font-size: 15px;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.72);
}

.bp-model-hero__lede strong {
  color: #fff;
  font-weight: 750;
}

.bp-model-hero__pillars {
  position: relative;
  list-style: none;
  margin: 26px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.bp-model-hero__pillars li {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 16px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(8px);
  font-size: 13px;
  color: rgba(255, 255, 255, 0.78);
}

.bp-model-hero__pillar-k {
  font-family: var(--bp-display);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: var(--bp-grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.bp-model-hero__actions {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.bp-model-hero__ghost {
  color: #fff !important;
  border-color: rgba(255, 255, 255, 0.22) !important;
}

.bp-model-hero__ghost:hover {
  background: rgba(255, 255, 255, 0.08) !important;
}

@media (max-width: 1100px) {
  .bp-grid--kpi { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .bp-catalog-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .bp-grid--studio { grid-template-columns: 1fr; }
  .bp-model-hero__pillars { grid-template-columns: 1fr; }
}

@media (max-width: 860px) {
  .bp-shell { grid-template-columns: 1fr; }
  .bp-sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    width: min(86vw, 280px);
    z-index: 40;
    transform: translateX(-105%);
    transition: transform 0.22s ease;
  }
  .bp-shell.is-nav-open .bp-sidebar { transform: translateX(0); }
  .bp-shell.is-nav-open::after {
    content: "";
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.4);
    z-index: 30;
  }
  .bp-menu-toggle { display: inline-flex; }
  .bp-topbar, .bp-content { padding-left: 16px; padding-right: 16px; }
  .bp-grid--2, .bp-row, .bp-calc { grid-template-columns: 1fr; }
  .bp-catalog-grid { grid-template-columns: 1fr; }
  .bp-theme-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .bp-model-hero { padding: 26px 20px 24px; }
  .bp-model-hero__headline { max-width: none; }
}
