.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 36px;
  padding: 0 14px;
  border-radius: var(--radius-md);
  font-weight: 600;
  white-space: nowrap;
  transition:
    background var(--duration) var(--ease),
    border-color var(--duration) var(--ease),
    color var(--duration) var(--ease),
    box-shadow var(--duration) var(--ease);
}

.btn--primary {
  color: var(--ink-900);
  background: var(--gold-gradient);
  box-shadow:
    inset 0 1px 0 rgb(255 255 255 / 35%),
    var(--shadow-sm);
}

.btn--primary:hover {
  filter: brightness(1.04);
}

.btn--dark {
  color: #fff;
  background: var(--ink-900);
}

.btn--outline {
  background: var(--surface);
  border: 1px solid var(--border);
}

.btn--outline:hover {
  background: var(--surface-soft);
}

.btn--ghost:hover {
  background: var(--surface-muted);
}

/* Warna brand omnichannel platform (override btn-primary di omnichannel-theme.scss). */
.btn--brand {
  color: #fff;
  background: var(--nav-badge);
}

.btn--brand:hover {
  background: #987439;
}

.btn--outline-brand {
  color: var(--nav-badge);
  border: 1px solid var(--nav-badge);
}

.btn--outline-brand:hover {
  color: #fff;
  background: var(--nav-badge);
}

.btn--danger {
  color: #fff;
  background: var(--red-500);
}

.btn--sm {
  height: 30px;
  padding: 0 12px;
  font-size: var(--fs-sm);
  border-radius: var(--radius-sm);
}

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

.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  background: var(--surface);
  border: 1px solid var(--border);
  transition:
    background var(--duration) var(--ease),
    color var(--duration) var(--ease);
}

.icon-btn:hover,
.icon-btn[aria-expanded="true"] {
  color: var(--text);
  background: var(--surface-soft);
}

.icon-btn--gold,
.icon-btn--gold:hover,
.icon-btn--gold[aria-expanded="true"] {
  color: var(--ink-900);
  background: var(--gold-gradient);
  border-color: transparent;
}

.icon-btn--plain {
  border-color: transparent;
  background: transparent;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 34px;
  padding: 0 14px;
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  background: var(--surface-muted);
  font-weight: 500;
  white-space: nowrap;
  transition:
    background var(--duration) var(--ease),
    color var(--duration) var(--ease);
}

.chip:hover {
  background: var(--surface-pill);
}

.chip[aria-pressed="true"],
.chip[aria-selected="true"] {
  color: #fff;
  background: var(--ink-900);
}

.chip__count {
  min-width: 26px;
  padding: 1px 7px;
  border-radius: var(--radius-full);
  font-size: var(--fs-sm);
  font-weight: 600;
  text-align: center;
  background: var(--surface-count);
}

.chip[aria-pressed="true"] .chip__count,
.chip[aria-selected="true"] .chip__count {
  color: var(--ink-900);
  background: var(--gold-500);
}

.chip--sm {
  height: 30px;
  padding: 0 12px;
  font-size: var(--fs-md);
  border-radius: var(--radius-sm);
  background: var(--surface);
  border: 1px solid var(--border);
}

.chip--sm[aria-pressed="true"] {
  border-color: var(--ink-900);
}

.avatar {
  position: relative;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  color: #fff;
  font-weight: 700;
  font-size: var(--fs-lg);
  letter-spacing: 0.02em;
}

.avatar--md {
  width: 40px;
  height: 40px;
  font-size: var(--fs-base);
}

.avatar--sm {
  width: 36px;
  height: 36px;
  font-size: var(--fs-md);
}

.avatar--xs {
  width: 22px;
  height: 22px;
  font-size: var(--fs-2xs);
}

.avatar--unknown {
  color: var(--text-faint);
  background: var(--surface-pill);
}

.avatar--slate {
  background: linear-gradient(160deg, #6f7d96, #4d5a70);
}
.avatar--lilac {
  background: linear-gradient(160deg, #aa90c2, #86699f);
}
.avatar--bronze {
  background: linear-gradient(160deg, #bd8f62, #95683f);
}
.avatar--sage {
  background: linear-gradient(160deg, #80a381, #5d7f5f);
}
.avatar--rose {
  background: linear-gradient(160deg, #c98a8a, #a86565);
}
.avatar--teal {
  background: linear-gradient(160deg, #6fa2a0, #4c7e7c);
}
.avatar--gold {
  background: linear-gradient(160deg, #c39868, #9d7040);
}

.avatar__channel {
  position: absolute;
  right: -3px;
  bottom: -3px;
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--surface);
  box-shadow: 0 0 0 2px var(--surface);
}

.avatar__presence {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 2px solid var(--surface);
  background: var(--text-faint);
}

.avatar__presence--online {
  background: var(--green-500);
}

.avatar__presence--away {
  background: var(--orange-500);
}

.channel-icon {
  width: 16px;
  height: 16px;
}

.channel-icon--whatsapp {
  color: var(--whatsapp);
}
.channel-icon--instagram {
  color: var(--instagram);
}
.channel-icon--tiktok {
  color: var(--tiktok);
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 20px;
  padding: 0 8px;
  border-radius: var(--radius-xs);
  font-size: var(--fs-xs);
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
}

.badge--lead {
  color: var(--blue-500);
  background: var(--blue-100);
}
.badge--booking {
  color: var(--gold-700);
  background: #f6eedd;
}
.badge--jamaah {
  color: var(--green-500);
  background: var(--green-100);
}
.badge--handle {
  color: var(--text-muted);
  background: var(--surface-muted);
  letter-spacing: 0.02em;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 22px;
  padding: 0 9px;
  border-radius: var(--radius-full);
  font-size: var(--fs-sm);
  font-weight: 600;
  white-space: nowrap;
}

.pill__dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

.pill--green {
  color: var(--green-500);
  background: var(--green-100);
}
.pill--orange {
  color: var(--orange-600);
  background: var(--orange-100);
}
.pill--neutral {
  color: var(--text-muted);
  background: var(--surface-muted);
}
.pill--purple {
  color: var(--purple-500);
  background: var(--purple-100);
}
.pill--blue {
  color: var(--blue-500);
  background: var(--blue-100);
}
.pill--red {
  color: var(--red-500);
  background: var(--red-100);
}
.pill--gold {
  color: var(--gold-700);
  background: #f6eedd;
}

.lead-badge {
  display: inline-flex;
  align-items: center;
  height: 18px;
  padding: 0 7px;
  border-radius: var(--radius-xs);
  font-size: var(--fs-xs);
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
}

.lead-badge--blue {
  color: var(--blue-500);
  background: var(--blue-100);
}
.lead-badge--orange {
  color: var(--orange-600);
  background: var(--orange-100);
}
.lead-badge--red {
  color: var(--red-500);
  background: var(--red-100);
}
.lead-badge--green {
  color: var(--green-500);
  background: var(--green-100);
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 20px;
  padding: 0 7px;
  border-radius: var(--radius-xs);
  font-size: var(--fs-xs);
  font-weight: 600;
  white-space: nowrap;
}

.count-dot {
  display: inline-grid;
  place-items: center;
  min-width: 24px;
  height: 24px;
  padding: 0 6px;
  border-radius: var(--radius-full);
  font-size: var(--fs-sm);
  font-weight: 700;
  color: var(--ink-900);
  background: var(--gold-500);
}

.field {
  display: grid;
  gap: 6px;
}

.field__label {
  font-size: var(--fs-sm);
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.input,
.select,
.textarea {
  width: 100%;
  height: 38px;
  padding: 0 12px;
  border-radius: var(--radius-md);
  background: var(--surface);
  border: 1px solid var(--border);
  transition:
    border-color var(--duration) var(--ease),
    box-shadow var(--duration) var(--ease);
}

.input:focus,
.select:focus,
.textarea:focus {
  outline: none;
  border-color: var(--gold-500);
  box-shadow: var(--focus-ring);
}

.input[readonly] {
  color: var(--text-secondary);
  background: var(--surface-muted);
}

.select--sm {
  height: 36px;
  padding-inline: 10px;
  border-radius: var(--radius-sm);
}

.select--inline {
  width: auto;
  max-width: 100%;
  height: 30px;
  padding-inline: 8px;
  font-size: var(--fs-sm);
  border-radius: var(--radius-xs);
}

.textarea {
  height: auto;
  min-height: 96px;
  padding: 10px 12px;
  resize: vertical;
}

.section-label {
  font-size: var(--fs-sm);
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.link-btn {
  font-size: var(--fs-md);
  font-weight: 700;
  color: var(--gold-700);
}

.link-btn:hover {
  text-decoration: underline;
}

.multi-select {
  position: relative;
}

.multi-select__control {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  min-height: 42px;
  padding: 5px 36px 5px 8px;
  border-radius: var(--radius-md);
  background: var(--surface);
  border: 1px solid var(--border);
  cursor: text;
  transition:
    border-color var(--duration) var(--ease),
    box-shadow var(--duration) var(--ease);
}

.multi-select__control:focus-within {
  border-color: var(--gold-500);
  box-shadow: var(--focus-ring);
}

.multi-select__chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 26px;
  padding: 0 4px 0 10px;
  border-radius: var(--radius-full);
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--gold-700);
  background: linear-gradient(180deg, #faf4e6, #f3e9d3);
  border: 1px solid #ecdcb8;
  animation: pop-in 160ms var(--ease);
}

.multi-select__chip-remove {
  display: grid;
  place-items: center;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  color: var(--gold-700);
}

.multi-select__chip-remove:hover {
  color: #fff;
  background: var(--gold-600);
}

.multi-select__chip-remove .icon {
  width: 12px;
  height: 12px;
}

.multi-select__input {
  flex: 1;
  min-width: 120px;
  height: 28px;
  padding: 0 4px;
  border: 0;
  background: transparent;
}

.multi-select__input:focus {
  outline: none;
  box-shadow: none;
}

.multi-select__input::placeholder {
  color: var(--text-faint);
}

.multi-select__caret {
  position: absolute;
  top: 12px;
  right: 12px;
  color: var(--text-muted);
  pointer-events: none;
  transition: transform var(--duration) var(--ease);
}

.multi-select:has([aria-expanded="true"]) .multi-select__caret {
  transform: rotate(180deg);
}

.multi-select__list {
  position: fixed;
  z-index: 60;
  max-height: 240px;
  overflow-y: auto;
  padding: 6px;
  border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
  animation: fade-in var(--duration) var(--ease);
}

.multi-select__option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  border-radius: var(--radius-sm);
  cursor: pointer;
}

.multi-select__option:hover,
.multi-select__option.is-active {
  background: var(--surface-active);
}

.multi-select__option.is-selected {
  color: var(--gold-700);
  font-weight: 600;
}

.multi-select__check {
  display: grid;
  place-items: center;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  color: transparent;
  border: 1px solid var(--border);
  transition:
    background var(--duration) var(--ease),
    color var(--duration) var(--ease);
}

.multi-select__check .icon {
  width: 11px;
  height: 11px;
  stroke-width: 2.4;
}

.multi-select__option.is-selected .multi-select__check {
  color: var(--ink-900);
  background: var(--gold-gradient);
  border-color: transparent;
}

.multi-select__label {
  flex: 1;
}

.multi-select__label mark {
  color: inherit;
  background: none;
  text-decoration: underline;
  text-decoration-color: var(--gold-500);
  text-underline-offset: 3px;
}

.multi-select__hint {
  font-size: var(--fs-xs);
  color: var(--text-muted);
}

.multi-select__empty {
  padding: 12px 10px;
  font-size: var(--fs-sm);
  text-align: center;
  color: var(--text-muted);
}
