/* Base container styles */
.call-logs-header {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 8px;
}
.call-logs-header h1 {
  margin: 0;
}
.call-logs-title {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1 1 auto;
}
.storevoiceai-sync-calls {
  appearance: none;
  display: inline-grid;
  place-items: center;
  box-sizing: border-box;
  width: 34px;
  height: 34px;
  min-width: 34px;
  min-height: 34px;
  max-width: 34px;
  max-height: 34px;
  padding: 0;
  margin: 0;
  border: 1px solid #3858ff;
  border-radius: 50%;
  background: #fff;
  color: #3858ff;
  cursor: pointer;
  line-height: 1;
  vertical-align: middle;
}
.storevoiceai-sync-calls:hover,
.storevoiceai-sync-calls:focus {
  border-color: #2141e8;
  color: #2141e8;
  background: #f7f9ff;
}
.storevoiceai-sync-calls:focus {
  outline: 2px solid transparent;
  box-shadow: 0 0 0 1px #2141e8;
}
.storevoiceai-sync-calls:disabled {
  cursor: progress;
  opacity: 0.8;
}
.storevoiceai-sync-calls .dashicons {
  width: 16px;
  height: 16px;
  font-size: 16px;
  line-height: 16px;
}
.storevoiceai-sync-calls .spinner {
  display: none;
  float: none;
  margin: 0;
}
.storevoiceai-sync-calls.is-syncing .dashicons {
  display: none;
}
.storevoiceai-sync-calls.is-syncing .spinner {
  display: inline-block;
  visibility: visible;
}
.call-logs-filters {
  display: inline-flex;
  align-items: center;
  background: #fff;
  border: 1px solid #e2e4e7;
  border-radius: 999px;
  padding: 4px;
  gap: 4px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}
.call-logs-filter {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 14px;
  height: 32px;
  border-radius: 999px;
  transition: background-color 0.15s ease;
}
.call-logs-filter:hover {
  background: #f6f9fc;
}
.call-logs-filter:focus-within {
  background: #eef3fb;
}
.call-logs-filter__label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #6c7178;
}
input[type="date"].call-logs-date-input {
  border: none;
  box-shadow: none;
  background: transparent;
  padding: 0;
  margin: 0;
  font-size: 13px;
  color: #1d2327;
  font-family: inherit;
  outline: none;
  min-width: 120px;
}
input[type="date"].call-logs-date-input:focus {
  border: none;
  box-shadow: none;
  outline: none;
}
.call-logs-date-input::-webkit-calendar-picker-indicator {
  filter: invert(40%);
  cursor: pointer;
  opacity: 0.7;
}
.call-logs-date-input::-webkit-calendar-picker-indicator:hover {
  opacity: 1;
}
.call-logs-date-clear {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: transparent;
  color: #6c7178;
  border: none;
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
  text-decoration: none;
  transition: background-color 0.15s ease, color 0.15s ease;
}
.call-logs-date-clear:hover,
.call-logs-date-clear:focus {
  background: #f6f9fc;
  color: #1d2327;
  outline: none;
}
.call-logs-date-clear.is-active {
  background: #fdecec;
  color: #b32d2e;
}
.call-logs-date-clear.is-active:hover,
.call-logs-date-clear.is-active:focus {
  background: #fad5d5;
  color: #8a1f1f;
}
.call-logs-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 4rem 1rem;
  min-height: 280px;
  margin: 0;
  color: #6c7178;
  text-align: center;
}
.call-logs-empty__icon {
  width: 56px;
  height: 56px;
  color: #c3c4c7;
}
.call-logs-empty__text {
  margin: 0;
  font-style: italic;
}

.call-logs-container {
  margin-top: 20px;
  background: #fff;
  border: 1px solid #e2e4e7;
  border-radius: 16px;
  padding: 8px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
  overflow: hidden;
}

.storevoiceai-call-logs-table.wp-list-table {
  border: none;
  background: transparent;
  box-shadow: none;
  border-collapse: separate;
  border-spacing: 0;
}
.storevoiceai-call-logs-table thead th {
  background: transparent;
  border-bottom: 1px solid #ececef;
  color: #6c7178;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: 11px;
  font-weight: 600;
  padding: 14px 16px;
}
.storevoiceai-call-logs-table tbody td {
  padding: 14px 16px;
  border-top: 1px solid #f0f0f1;
  border-bottom: none;
  vertical-align: middle;
  background: transparent;
  color: #1d2327;
  font-size: 14px;
}
.storevoiceai-call-logs-table tbody tr:first-child td {
  border-top: none;
}
.storevoiceai-call-logs-table.striped > tbody > tr:nth-child(odd) {
  background: transparent;
}

.storevoiceai-call-row {
  cursor: pointer;
  transition: background-color 0.15s ease;
}
.storevoiceai-call-row:hover {
  background-color: #f6f9fc !important;
}
.storevoiceai-call-row:focus-visible {
  outline: 2px solid #2271b1;
  outline-offset: -2px;
}
.storevoiceai-call-logs-table code {
  font-size: 12px;
  color: #50575e;
  background: #f5f5f7;
  padding: 2px 8px;
  border-radius: 999px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.storevoiceai-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 500;
  background: #f0f0f1;
  color: #3c434a;
  white-space: nowrap;
}
.storevoiceai-pill--type {
  background: #eef3fb;
  color: #1f4c7a;
}
.storevoiceai-pill--status-ok {
  background: #e7f5ec;
  color: #1f7a3c;
}
.storevoiceai-pill--status-warn {
  background: #fdf3df;
  color: #7a5b1f;
}
.storevoiceai-pill--status-bad {
  background: #fdecec;
  color: #8a1f1f;
}
.storevoiceai-pill__dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.7;
}

.storevoiceai-call-logs-table th:nth-child(1),
.storevoiceai-call-logs-table td:nth-child(1) {
  width: 18%;
}
.storevoiceai-call-logs-table th:nth-child(2),
.storevoiceai-call-logs-table td:nth-child(2) {
  width: 28%;
}
.storevoiceai-call-logs-table th:nth-child(3),
.storevoiceai-call-logs-table td:nth-child(3) {
  width: 12%;
}
.storevoiceai-call-logs-table th:nth-child(4),
.storevoiceai-call-logs-table td:nth-child(4) {
  width: 12%;
}
.storevoiceai-call-logs-table th:nth-child(5),
.storevoiceai-call-logs-table td:nth-child(5) {
  width: 16%;
}
.storevoiceai-actions-col {
  width: 14%;
  text-align: right;
}
.storevoiceai-call-logs-table .button {
  border-radius: 999px;
  padding: 4px 14px;
  font-size: 12px;
  height: auto;
  min-height: 28px;
  line-height: 20px;
}

.dashboard-container {
  margin-top: 20px;
}

.dashboard-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 8px;
}
.dashboard-header h1 {
  margin: 0;
}
.dashboard-range-tabs {
  display: inline-flex;
  background: #fff;
  border: 1px solid #dcdcde;
  border-radius: 999px;
  padding: 3px;
  gap: 2px;
}
.dashboard-range-tab {
  border: none;
  background: transparent;
  color: #50575e;
  font-size: 13px;
  font-weight: 500;
  padding: 6px 14px;
  border-radius: 999px;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease;
}
.dashboard-range-tab:hover {
  color: #1d2327;
}
.dashboard-range-tab.is-active {
  background: #2271b1;
  color: #fff;
}
.dashboard-range-tab:focus {
  outline: 2px solid #2271b1;
  outline-offset: 2px;
}
.dashboard-range-tab.is-active:focus {
  outline-color: #135e96;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  margin-top: 20px;
}

.dashboard-card {
  background: #fff;
  border: 1px solid #ddd;
  padding: 20px;
  border-radius: 16px;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.billing-page-header {
  max-width: 960px;
}
.billing-page-header h1 {
  margin-bottom: 6px;
  color: #111827;
  font-weight: 700;
}
.billing-page-header p {
  margin: 0;
  color: #253858;
  font-size: 15px;
}
.billing-dashboard {
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-width: 1680px;
}
.billing-summary-panel {
  display: grid;
  grid-template-columns: auto minmax(260px, 1fr) auto;
  align-items: center;
  gap: 18px;
  padding: 18px 22px;
  border: 1px solid #f2c28f;
  border-radius: 8px;
  background: #fff7ed;
  color: #172033;
}
.billing-summary-panel[hidden] {
  display: none !important;
}
.billing-summary-panel--warning {
  border-color: #e6a95f;
  background: #fff8e5;
}
.billing-summary-panel--exhausted {
  border-color: #f0b27a;
  background: #fff5eb;
}
.billing-summary-icon {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 8px;
  background: #fff;
  color: #ff6b00;
}
.billing-summary-icon .dashicons {
  width: 26px;
  height: 26px;
  font-size: 26px;
}
.billing-summary-panel:not(.billing-summary-panel--warning):not(.billing-summary-panel--exhausted) .billing-summary-icon {
  color: #16a34a;
}
.billing-summary-copy {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}
.billing-summary-copy strong {
  color: #111827;
  font-size: 15px;
}
.billing-summary-copy span {
  color: #253858;
  font-size: 14px;
  line-height: 1.45;
}
.billing-summary-stats {
  display: grid;
  grid-template-columns: repeat(3, auto);
  align-items: center;
  gap: 22px;
}
.billing-summary-stats > div {
  min-width: 124px;
  padding-left: 22px;
  border-left: 1px solid rgba(226, 118, 0, 0.18);
}
.billing-summary-stats span {
  display: block;
  color: #253858;
  font-size: 12px;
  font-weight: 500;
}
.billing-summary-stats strong {
  display: block;
  margin-top: 4px;
  color: #111827;
  font-size: 18px;
  line-height: 1.2;
}
.billing-status-pill {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 132px !important;
  min-height: 34px;
  padding: 0 14px !important;
  border: 1px solid #bbf7d0 !important;
  border-radius: 8px;
  background: #f0fdf4;
  color: #166534 !important;
  font-size: 12px !important;
  font-weight: 700;
}
.billing-status-pill span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentcolor;
}
.billing-status-pill--active {
  border-color: #fed7aa !important;
  background: #fff7ed;
  color: #ea580c !important;
}
.billing-cards-grid,
.billing-tables-grid {
  display: grid;
  grid-template-columns: minmax(280px, 0.95fr) minmax(360px, 1.25fr) minmax(220px, 0.8fr);
  gap: 16px;
}
.billing-tables-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.billing-card,
.billing-chart-panel,
.billing-table-panel {
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}
.billing-card {
  min-height: 136px;
  padding: 18px 22px;
}
/* Anchor the .phone-subscription-wall paywall to the card and keep it within
   the rounded corners for free-plan users. */
.billing-card--locked {
  position: relative;
  overflow: hidden;
}
/* Lighter, semi-transparent treatment on the billing cards so the locked
   content behind the paywall stays partly visible. */
.billing-card--locked .phone-subscription-wall {
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(3px);
}
.billing-card--locked .phone-subscription-wall__content {
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
}
.billing-card-header,
.billing-panel-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}
.billing-card-header {
  justify-content: flex-start;
}
.billing-card-header--action {
  align-items: center;
}
.billing-card-layout {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  align-items: start;
  gap: 14px;
}
.billing-card-content {
  min-width: 0;
}
.billing-card-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}
.billing-card-header h3,
.billing-card-title-row h3,
.billing-panel-header h3 {
  margin: 0;
  color: #111827;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.25;
}
.billing-card-header p {
  margin: 4px 0 0;
  color: #253858;
  font-size: 13px;
  line-height: 1.4;
}
.billing-card-title-row p {
  margin: 2px 0 0;
  color: #253858;
  font-size: 13px;
  line-height: 1.4;
  text-align: right;
}
.billing-card-icon {
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  border-radius: 8px;
}
.billing-card-icon .dashicons {
  width: 22px;
  height: 22px;
  font-size: 22px;
}
.billing-card-icon--orange {
  background: #fff2e5;
  color: #f97316;
}
.billing-card-icon--green {
  background: #ecfdf5;
  color: #16a34a;
}
.billing-card-icon--purple {
  background: #f3e8ff;
  color: #7c3aed;
}
.billing-card--wallet {
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 18px 22px;
}
.billing-card--wallet .billing-card-header {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) auto;
  align-items: start;
  gap: 14px;
}
.billing-card--wallet .billing-card-icon {
  width: 42px;
  height: 42px;
  background: #ecfff4;
}
.billing-card--wallet .billing-card-icon .dashicons {
  width: 22px;
  height: 22px;
  font-size: 22px;
}
.billing-wallet-main {
  min-width: 0;
}
.billing-card--wallet .billing-wallet-main h3 {
  margin: 0 0 8px;
  color: #111827;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.2;
}
.billing-card--wallet .storevoiceai-topup-checkout {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-left: auto;
  min-width: 78px;
  min-height: 34px;
  padding: 0 16px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
  text-align: center;
}
.storevoiceai-topup-checkout.is-disabled {
  border-color: #cbd5e1 !important;
  background: #f8fafc !important;
  color: #64748b !important;
  cursor: not-allowed;
  pointer-events: auto;
}
.storevoiceai-stripe-modal[hidden] {
  display: none !important;
}
.storevoiceai-stripe-modal {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(15, 23, 42, 0.45);
}
.storevoiceai-stripe-modal__panel {
  width: min(960px, 100%);
  max-height: min(820px, calc(100vh - 48px));
  overflow: auto;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 24px 80px rgba(15, 23, 42, 0.24);
}
.storevoiceai-stripe-modal__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 22px;
  border-bottom: 1px solid #e2e8f0;
}
.storevoiceai-stripe-modal__header h2 {
  margin: 0;
  color: #111827;
  font-size: 18px;
  line-height: 1.25;
}
.storevoiceai-stripe-modal__header p {
  margin: 6px 0 0;
  color: #334e7d;
  font-size: 13px;
  line-height: 1.4;
}
.storevoiceai-stripe-modal__close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border: 1px solid #dbe3ef;
  border-radius: 8px;
  background: #fff;
  color: #334155;
  cursor: pointer;
  font-size: 22px;
  line-height: 1;
}
.storevoiceai-stripe-modal__close:hover,
.storevoiceai-stripe-modal__close:focus {
  border-color: #94a3b8;
  color: #111827;
  outline: none;
}
.storevoiceai-stripe-checkout {
  min-height: 520px;
  padding: 18px 22px 22px;
}
.storevoiceai-stripe-checkout--loading {
  display: flex;
  align-items: center;
  justify-content: center;
  color: #52657f;
  font-size: 14px;
}
.storevoiceai-stripe-checkout__loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}
.storevoiceai-spinner {
  display: inline-block;
  width: 28px;
  height: 28px;
  border: 3px solid #dcdcde;
  border-top-color: #2271b1;
  border-radius: 50%;
  animation: storevoiceai-spin 0.7s linear infinite;
  flex-shrink: 0;
}
.billing-card--wallet .billing-wallet-balance {
  margin: 0 0 8px;
}
.billing-wallet-note,
.billing-rate,
.billing-rate-note {
  margin: 14px 0 0;
  color: #253858;
}
.billing-card--wallet .billing-wallet-balance strong {
  color: #00b938;
  font-size: 24px;
  line-height: 1.15;
  font-weight: 700;
}
.billing-card--wallet .billing-wallet-balance span {
  margin-left: 6px;
  color: #253858;
  font-size: 14px;
  font-weight: 700;
}
.billing-wallet-note {
  margin: 0;
  color: #334e7d;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.35;
}
.billing-rate strong {
  color: #5b21e5;
  font-size: 26px;
  line-height: 1.15;
}
.billing-rate-note {
  margin-top: 8px;
  font-size: 13px;
  line-height: 1.35;
}
.billing-info-icon {
  margin-left: auto;
  color: #4b628c;
}
.billing-topup-row {
  display: grid;
  grid-template-columns: 106px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  margin-top: auto;
}
.billing-topup-row > span {
  color: #253858;
  font-size: 13px;
  font-weight: 700;
}
.billing-topup-row--disabled {
  align-items: start;
}
.billing-topup-message {
  margin: 0;
  color: #64748b;
  font-size: 13px;
  line-height: 1.4;
}
.billing-topup-options {
  display: flex;
  flex-wrap: nowrap;
  gap: 8px;
  min-width: 0;
  overflow-x: auto;
  padding: 2px 0;
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.billing-topup-options::-webkit-scrollbar {
  display: none;
}
.billing-topup-option {
  flex: 0 0 auto;
  min-width: 58px;
  min-height: 32px;
  padding: 0 12px;
  border: 1px solid #dbe3ef;
  border-radius: 8px;
  background: #fff;
  color: #28446f;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.06);
}
.billing-topup-option:hover,
.billing-topup-option:focus {
  border-color: #1f6feb;
  color: #1f6feb;
  outline: none;
}
.billing-topup-option.is-active {
  border-color: #b7d3ff;
  background: #edf5ff;
  color: #1f6feb;
}
.billing-topup-option:disabled {
  border-color: #e2e8f0;
  background: #f8fafc;
  color: #94a3b8;
  cursor: not-allowed;
  box-shadow: none;
}
.billing-chart-panel,
.billing-table-panel {
  min-width: 0;
  overflow: hidden;
  padding: 16px 22px 18px;
}
.billing-table-panel--wallet-empty {
  display: flex;
  flex-direction: column;
}
.billing-table-panel--wallet-empty .billing-table-wrap {
  display: flex;
  flex: 1;
}
.billing-chart-panel .billing-panel-header {
  align-items: flex-start;
  margin-bottom: 12px;
}
.billing-chart-panel .dashboard-range-tabs {
  border-radius: 8px;
}
.billing-chart-panel .dashboard-range-tab {
  border-radius: 6px;
}
.billing-usage-totals {
  display: grid;
  grid-template-columns: repeat(3, minmax(160px, auto));
  gap: 16px;
  margin-top: 14px;
}
.billing-usage-total {
  display: grid;
  grid-template-columns: auto 1fr;
  column-gap: 7px;
  row-gap: 4px;
  align-items: center;
  color: #253858;
  font-size: 13px;
}
.billing-usage-total strong {
  grid-column: 2;
  color: #111827;
  font-size: 18px;
  line-height: 1.15;
}
.billing-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}
.billing-dot--blue {
  background: #1f6feb;
}
.billing-dot--orange {
  background: #ff7a1a;
}
.billing-dot--purple {
  background: #6d28d9;
}
.billing-chart-canvas {
  position: relative;
  min-height: 260px;
}
.billing-chart-canvas canvas {
  width: 100% !important;
  height: 260px !important;
}
.billing-chart-unavailable {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 260px;
  margin: 0;
  padding: 1rem;
  color: #50575e;
  font-style: italic;
  text-align: center;
}
.billing-chart-skeleton {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-end;
  gap: 10px;
  padding: 12px 4px 28px;
}
.billing-chart-skeleton__bar {
  flex: 1 1 auto;
  border-radius: 6px 6px 0 0;
  background: linear-gradient(90deg, #ececef 0%, #f6f7f7 50%, #ececef 100%);
  background-size: 200% 100%;
  animation: storevoiceai-skeleton-shimmer 1.2s ease-in-out infinite;
}
.billing-table-wrap {
  width: 100%;
  max-width: 100%;
  margin-top: 8px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.billing-table {
  width: 100%;
  min-width: 560px;
  border-collapse: collapse;
  color: #172033;
}
.billing-table th,
.billing-table td {
  padding: 10px 12px;
  border-bottom: 1px solid #eef2f7;
  text-align: left;
  font-size: 13px;
  white-space: nowrap;
}
.billing-table th {
  background: #f8fafc;
  color: #334e7d;
  font-size: 12px;
  font-weight: 700;
}
.billing-table tbody tr:last-child td {
  border-bottom: none;
}
.billing-table-footer {
  margin-top: 12px;
  color: #334e7d;
  font-size: 13px;
}
.billing-empty-state {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 112px;
  padding: 14px;
  border: 1px dashed #cbd5e1;
  border-radius: 8px;
  background: #f8fafc;
  color: #52657f;
  font-size: 13px;
  text-align: center;
}
.billing-empty-state__icon {
  flex: 0 0 auto;
  width: 34px;
  height: 34px;
  color: #64748b;
}
.billing-table-panel--wallet-empty .billing-empty-state {
  flex: 1;
  width: 100%;
  flex-direction: column;
  font-size: 15px;
  line-height: 1.4;
}
.billing-transaction-type {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.billing-transaction-type span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #ff7a1a;
}
.billing-transaction-type--topup span {
  background: #16a34a;
}
.billing-amount-positive {
  color: #00a32a;
  font-weight: 700;
}

.minutes-quota-card {
  background: #fff;
  border: 1px solid #ddd;
  padding: 1.25rem 1.5rem;
  border-radius: 16px;
  max-width: 640px;
}
.storevoiceai-minutes-admin-notice.notice {
  display: flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  max-width: calc(100% - 24px);
  margin: 0 auto 16px;
  padding: 10px 12px;
  border: 1px solid #f0b849 !important;
  border-radius: 10px;
  background: #fff8e5 !important;
  color: #1d2327;
}
.call-logs-title .storevoiceai-minutes-admin-notice.notice {
  flex: 0 1 auto;
  margin: 0 auto;
}
.storevoiceai-minutes-admin-notice p {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin: 0;
  text-align: center;
}
.storevoiceai-minutes-admin-notice__action.button {
  min-height: 30px;
  margin-left: 0;
  border-color: #111827;
  border-radius: 8px;
  background: #111827;
  color: #fff;
}
.storevoiceai-minutes-admin-notice__action.button:hover,
.storevoiceai-minutes-admin-notice__action.button:focus {
  border-color: #000;
  background: #000;
  color: #fff;
}
body.storevoiceai-minutes-exhausted #retell-wrapper {
  display: none !important;
}
.minutes-quota-card h3 {
  margin: 0 0 0.75rem;
}
.minutes-usage {
  font-size: 1.25rem;
  margin: 0 0 0.5rem;
}
.minutes-usage strong {
  font-size: 2rem;
  color: #2271b1;
}
.minutes-progress {
  width: 100%;
  height: 10px;
  background: #f0f0f1;
  border-radius: 5px;
  overflow: hidden;
  margin-bottom: 0.5rem;
}
.minutes-progress__bar {
  height: 100%;
  background: #2271b1;
  transition: width 0.3s ease;
}
.minutes-progress__bar--warning {
  background: #b85c00;
}
.minutes-progress__bar--exhausted {
  background: #d63638;
}
.minutes-quota-alert {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0.85rem 0 1rem;
  padding: 12px 14px;
  border: 1px solid #f0b849;
  border-radius: 4px;
  background: #fff8e5;
  color: #1d2327;
}
.minutes-quota-alert .dashicons {
  flex: 0 0 auto;
  color: #b85c00;
}
.minutes-quota-alert--exhausted {
  border-color: #f0b849;
  background: #fff8e5;
}
.minutes-quota-alert--exhausted .dashicons {
  color: #b85c00;
}
.minutes-quota-alert p {
  flex: 1;
  margin: 0;
}
.minutes-quota-alert__action {
  flex: 0 0 auto;
  white-space: nowrap;
}
.minutes-remaining {
  margin: 0 0 1rem;
  color: #50575e;
}
.minutes-remaining--exhausted {
  color: #f97316;
  font-weight: 700;
}
.minutes-subscribe {
  margin-top: 0.5rem;
}
.minutes-subscribe.button {
  padding: 3px 14px;
  min-height: 30px;
}

.minutes-skeleton {
  position: relative;
  display: inline-block;
  border-radius: 6px;
  background: linear-gradient(90deg, #ececef 0%, #f6f7f7 50%, #ececef 100%);
  background-size: 200% 100%;
  animation: storevoiceai-skeleton-shimmer 1.2s ease-in-out infinite;
  color: transparent !important;
  overflow: hidden;
}
.minutes-skeleton--usage {
  width: 60%;
  height: 2.25rem;
  margin: 0 0 0.5rem;
}
.minutes-skeleton--line {
  width: 45%;
  height: 1rem;
  margin: 0 0 1rem;
}
.minutes-skeleton--title {
  width: 170px;
  height: 1rem;
  margin: 0 0 0.75rem;
}
.minutes-skeleton--metric {
  width: 132px;
  height: 2rem;
}
.minutes-skeleton--button {
  width: 200px;
  height: 36px;
  border-radius: 10px;
  margin-top: 0.5rem;
}
.minutes-progress__bar.minutes-skeleton {
  width: 30% !important;
  height: 100%;
  background: linear-gradient(90deg, #ececef 0%, #d8d9dc 50%, #ececef 100%);
  background-size: 200% 100%;
}
@keyframes storevoiceai-skeleton-shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

#storevoiceai-settings .button,
#storevoiceai-create-assistant__button,
.minutes-subscribe.button,
.minutes-quota-alert__action.button {
  border-radius: 10px;
  padding: 6px 16px;
  height: auto;
  min-height: 36px;
}
#storevoiceai-create-assistant__button {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  height: 44px !important;
  min-height: 44px !important;
  padding: 0 40px !important;
  line-height: 1.2 !important;
}
.minutes-active-plan {
  margin: 0.5rem 0 0;
  padding: 0.5rem 0.75rem;
  background: #edfaef;
  border: 1px solid #b8e0c2;
  border-radius: 8px;
  color: #215d2c;
  font-weight: 600;
  display: inline-block;
}
.minutes-plot-container {
  background: #fff;
  border: 1px solid #ddd;
  padding: 1.25rem 1.5rem;
  border-radius: 16px;
  margin-top: 1.5rem;
  max-width: 960px;
}
.minutes-plot-container h3 {
  margin: 0 0 1rem;
}
.minutes-plot-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 1rem;
}
.minutes-plot-header h3 {
  margin: 0;
}
.dashboard-number {
  font-size: 24px;
  font-weight: bold;
  color: #2271b1;
  margin: 10px 0;
}
.dashboard-unit {
  font-size: 14px;
  font-weight: normal;
  color: #50575e;
  margin-left: 4px;
}
.dashboard-charts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-top: 20px;
}
@media (max-width: 960px) {
  .dashboard-charts {
    grid-template-columns: 1fr;
  }
}
.dashboard-chart-container {
  background: #fff;
  border: 1px solid #ddd;
  padding: 1.25rem 1.5rem;
  border-radius: 16px;
}
.dashboard-chart-container h3 {
  margin: 0 0 1rem;
}
.dashboard-chart-canvas {
  position: relative;
  height: 360px;
}
.dashboard-chart-canvas > canvas {
  width: 100% !important;
  height: 100% !important;
}
.dashboard-empty {
  color: #50575e;
  margin: 0;
  font-style: italic;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  text-align: center;
  padding: 1rem;
}
.dashboard-empty__icon {
  width: 48px;
  height: 48px;
  color: #c3c4c7;
}

/* KPI card rows. The primary row weights Total Calls / Resolution / Deflection
   at 3 / 5 / 4; the secondary row holds four equal cards. */
.dashboard-grid--primary {
  grid-template-columns: 3fr 5fr 4fr;
}
.dashboard-grid--secondary {
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-top: 14px;
}
.dashboard-grid--secondary .dashboard-card {
  min-height: 132px;
  padding: 14px 16px;
}
.dashboard-grid--secondary .dashboard-card h3 {
  margin: 0 0 8px;
  font-size: 15px;
}
.dashboard-grid--secondary .dashboard-number {
  margin: 4px 0;
}
@media (max-width: 960px) {
  .dashboard-grid--primary,
  .dashboard-grid--secondary {
    grid-template-columns: 1fr;
  }
}
.dashboard-sublabel {
  margin: 6px 0 0;
  color: #50575e;
  font-size: 13px;
  line-height: 1.4;
}

/* Circular progress ring for the percentage stat cards */
.resolution-gauge {
  position: relative;
  width: 110px;
  height: 110px;
  margin: 12px auto 4px;
  border-radius: 50%;
  background: conic-gradient(#2271b1 calc(var(--gauge-value, 0) * 1%), #f0f0f1 0);
}
.resolution-gauge::before {
  content: "";
  position: absolute;
  inset: 12px;
  border-radius: 50%;
  background: #fff;
}
.resolution-gauge__value {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  font-weight: 700;
  color: #2271b1;
}
.resolution-gauge__unit {
  font-size: 12px;
  font-weight: 600;
  margin-left: 1px;
}

/* Modal styles */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  /* Above the WordPress admin menu (#adminmenuwrap, z-index 9990) and admin bar
     (#wpadminbar, z-index 99999) so the overlay covers the sidebar instead of
     rendering behind it. */
  z-index: 100000;
  overflow-y: auto; /* Allow scrolling of the entire modal overlay */
  padding: 20px; /* Add padding to prevent content from touching screen edges */
}

.modal-content {
  position: relative;
  background-color: #fff;
  margin: 10% auto;
  padding: 20px;
  width: 80%;
  max-width: 600px;
  border-radius: 16px;
}

.call-detail-modal {
  width: 94%;
  max-width: 1320px;
  margin: 4vh auto;
  padding: 0;
  display: flex;
  flex-direction: column;
  max-height: 92vh;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.18);
}
.call-detail-header {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid #ececef;
}
.call-detail-header h2 {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 600;
}
.call-detail-body {
  display: grid;
  grid-template-columns: minmax(0, 4fr) minmax(0, 6fr);
  gap: 1.5rem;
  padding: 1.5rem;
  overflow: hidden;
  flex: 1;
  min-height: 0;
}
.call-detail-left,
.call-detail-right {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  overflow-y: auto;
}
.call-detail-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  background: #f6f7f7;
  border: 1px solid #ececef;
  border-radius: 12px;
  padding: 1rem 1.25rem;
}
.call-detail-meta__item {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.call-detail-meta__label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #6c7178;
}
.call-detail-meta__value {
  font-size: 14px;
  color: #1d2327;
  word-break: break-word;
}
.call-detail-section h3 {
  margin: 0 0 0.5rem;
  font-size: 0.95rem;
  font-weight: 600;
  color: #1d2327;
}
.call-detail-summary {
  margin: 0;
  line-height: 1.55;
  color: #3c434a;
}
.call-detail-empty {
  margin: 0;
  color: #6c7178;
  font-style: italic;
}
.call-detail-section .call-recording {
  width: 100%;
}

.close {
  position: absolute;
  right: 14px;
  top: 12px;
  font-size: 22px;
  line-height: 1;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: none;
  background: transparent;
  color: #50575e;
  cursor: pointer;
  z-index: 1;
}
.close:hover {
  background: #f0f0f1;
  color: #1d2327;
}

.call-details {
  margin-top: 20px;
}

.call-details p {
  margin: 10px 0;
}

.transcript-section {
  margin-top: 0;
  padding-top: 0;
  border-top: none;
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
}

.transcript-section h3 {
  margin-bottom: 10px;
}

.call-detail-modal .transcript-content {
  flex: 1;
  min-height: 0;
  max-height: none;
  background: #f9fafb;
  border: 1px solid #ececef;
  border-radius: 12px;
  padding: 1rem 1.25rem;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  overflow-y: auto;
}
.transcript-line {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 0.5rem 0.75rem;
  border-radius: 10px;
  background: #fff;
  border: 1px solid #ececef;
  align-self: flex-start;
  max-width: 90%;
}
.transcript-line--user {
  align-self: flex-end;
  background: #e7f1fb;
  border-color: #cfdff2;
}
.transcript-line--agent {
  background: #fff;
}
.transcript-speaker {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #6c7178;
}
.transcript-text {
  color: #1d2327;
  white-space: pre-wrap;
  word-wrap: break-word;
}

.transcript-content {
  white-space: pre-line;
  word-wrap: break-word;
  background: #f9f9f9;
  border: 1px solid #eee;
  border-radius: 16px;
  padding: 15px;
  max-height: 60vh;
  overflow-y: auto;
  font-family: monospace;
  line-height: 1.5;
}
.transcript-content br {
  margin-bottom: 0.5em;
  display: block;
  content: "";
}

@media (max-width: 900px) {
  .call-detail-modal {
    width: 96%;
  }
  .call-detail-body {
    grid-template-columns: 1fr;
  }
  .call-detail-meta {
    grid-template-columns: 1fr 1fr;
  }
}

/* Scrollbar styling for webkit browsers */
.transcript-content::-webkit-scrollbar {
  width: 8px;
}

.transcript-content::-webkit-scrollbar-track {
  background: #f1f1f1;
}

.transcript-content::-webkit-scrollbar-thumb {
  background: #888;
  border-radius: 4px;
}

.transcript-content::-webkit-scrollbar-thumb:hover {
  background: #555;
}

.recording-section {
  margin: 20px 0;
  padding: 15px;
  background: #f9f9f9;
  border: 1px solid #eee;
  border-radius: 16px;
}

.recording-section h3 {
  margin-bottom: 10px;
}

/* Style the audio player to match WordPress admin UI */
.call-recording {
  width: 100%;
  margin: 5px 0;
}

/* Improve audio player appearance in Webkit browsers */
.call-recording::-webkit-media-controls-panel {
  background-color: #fff;
}

.call-recording::-webkit-media-controls-current-time-display,
.call-recording::-webkit-media-controls-time-remaining-display {
  color: #3c434a;
}

@media screen and (max-width: 782px) {
  .modal-content {
    width: 95%;
    margin: 20px auto;
    padding: 15px;
  }

  .transcript-content {
    max-height: 50vh; /* Slightly smaller on mobile devices */
    padding: 10px;
  }
}

/* Form field groups */
.form-field-group {
  margin-bottom: 24px;
  padding-bottom: 24px;
  border-bottom: 1px solid #ddd;
}

.form-field-group:last-child {
  border-bottom: none;
}

/* Input styling to match WooCommerce */
input[type="text"],
input[type="tel"],
textarea {
  border: 1px solid #8c8f94;
  border-radius: 10px;
  padding: 0 12px;
  width: 600px;
  max-width: 100%;
  background: #fff;
}

.storevoiceai-agent-fields {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
  gap: 20px;
  align-items: start;
}
.storevoiceai-agent-fields .storevoiceai-field {
  min-width: 0;
}
.storevoiceai-agent-fields .storevoiceai-field h4 {
  margin: 0 0 2px;
}
.storevoiceai-agent-fields .storevoiceai-field .description {
  margin-top: 0;
}
.storevoiceai-agent-fields input[type="text"],
.storevoiceai-agent-fields input[type="tel"],
.storevoiceai-agent-fields input[type="email"],
.storevoiceai-agent-fields textarea {
  width: 100%;
  max-width: 100%;
}
.storevoiceai-agent-fields input[type="text"],
.storevoiceai-agent-fields input[type="tel"],
.storevoiceai-agent-fields input[type="email"] {
  height: 40px;
  padding: 8px 12px;
}
.storevoiceai-agent-fields textarea {
  min-height: 0;
}
.storevoiceai-agent-fields .storevoiceai-field__label-spaced {
  margin-top: 2.5rem;
}
.storevoiceai-agent-fields .voice-card {
  margin-top: 1.25rem;
  width: 100%;
}
.storevoiceai-agent-fields .voice-selector {
  margin: 0;
  padding: 0;
  width: 100%;
  border: 0;
}

.voice-preview__button {
  appearance: none;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 0;
  background: #f0f0f0;
  cursor: pointer;
  transition: background-color 0.15s ease, box-shadow 0.15s ease, color 0.15s ease;
}

.voice-preview__button:not(:disabled):hover,
.voice-preview__button:not(:disabled):focus,
.voice-preview__button.is-playing {
  background: #111827;
  color: #fff;
  outline: none;
}

.voice-preview__button:focus {
  box-shadow: 0 0 0 2px #fff, 0 0 0 4px #2271b1;
}

.voice-preview__button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.voice-preview__button:not(:disabled):hover .voice-avatar__initial,
.voice-preview__button:not(:disabled):focus .voice-avatar__initial,
.voice-preview__button.is-playing .voice-avatar__initial {
  opacity: 0;
}

.voice-avatar__initial {
  transition: opacity 0.15s ease;
}

.voice-avatar__play {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 20px;
  line-height: 40px;
  opacity: 0;
  transition: opacity 0.15s ease;
}

.voice-preview__button .voice-avatar__play.dashicons {
  width: 100%;
  height: 100%;
  font-size: 20px;
  line-height: 40px;
}

.voice-preview__button:not(:disabled):hover .voice-avatar__play,
.voice-preview__button:not(:disabled):focus .voice-avatar__play,
.voice-preview__button.is-playing .voice-avatar__play {
  opacity: 1;
}

.voice-preview__button--unavailable .voice-avatar__play,
.voice-preview__button--error .voice-avatar__play {
  display: none;
}

.voice-preview__button .dashicons {
  width: 16px;
  height: 16px;
}

.voice-preview__button--error {
  background: #fcf0f1;
  color: #8a1f1f;
}

.voice-filters {
  display: flex;
  gap: 8px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}
.voice-filters select.voice-filter,
select.voice-filter {
  flex: 1 1 0;
  min-width: 140px;
  height: 36px;
  padding: 0 36px 0 14px;
  border: 1px solid #8c8f94;
  border-radius: 999px !important;
  background-color: #fff;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8' fill='none' stroke='%2350575e' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'><polyline points='1 1.5 6 6.5 11 1.5'/></svg>");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 12px 8px;
  font-size: 13px;
  color: #1d2327;
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
  appearance: none !important;
  box-shadow: none;
}
.voice-filter:focus {
  border-color: #2271b1;
  box-shadow: 0 0 0 1px #2271b1;
  outline: 2px solid transparent;
}
@media (max-width: 782px) {
  .storevoiceai-agent-fields {
    grid-template-columns: 1fr;
  }
}

input[type="text"]:focus,
input[type="tel"]:focus,
input[type="email"]:focus {
  border-color: #2271b1;
  box-shadow: 0 0 0 1px #2271b1;
  outline: 2px solid transparent;
}

/* Inline field validation */
.storevoiceai-agent-fields input.storevoiceai-input-error,
.storevoiceai-agent-fields input.storevoiceai-input-error:focus {
  border-color: #d63638;
  box-shadow: 0 0 0 1px #d63638;
}
.storevoiceai-field-error {
  margin: 4px 0 0;
  color: #d63638;
  font-size: 13px;
}

.storevoiceai-transfer-card {
  position: relative;
  width: 100%;
  box-sizing: border-box;
  padding: 14px;
  border: 1px solid #dcdcde;
  border-radius: 10px;
  background: #fff;
  overflow: hidden;
}

.storevoiceai-transfer-card--locked {
  min-height: 260px;
}

.storevoiceai-transfer-card--loading {
  min-height: 260px;
}

.storevoiceai-transfer-skeleton {
  position: absolute;
  inset: 0;
  /* Above .phone-subscription-wall (z-index: 5) so the wall never flashes
     during the load window before phoneNumbersChanged resolves. */
  z-index: 10;
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
  padding: 14px;
  background: #fff;
}

.storevoiceai-transfer-card:not(.storevoiceai-transfer-card--loading) .storevoiceai-transfer-skeleton {
  display: none;
}

.storevoiceai-transfer-skeleton__line,
.storevoiceai-transfer-skeleton__input,
.storevoiceai-transfer-skeleton__toggle {
  position: relative;
  overflow: hidden;
  border-radius: 6px;
  background: #eef1f5;
}

.storevoiceai-transfer-skeleton__line--title {
  width: 160px;
  height: 14px;
  margin-bottom: 10px;
}

.storevoiceai-transfer-skeleton__line--text {
  width: 100%;
  max-width: 280px;
  height: 11px;
  margin-bottom: 14px;
}

.storevoiceai-transfer-skeleton__input {
  width: 100%;
  height: 34px;
  border-radius: 8px;
  margin-bottom: 16px;
}

.storevoiceai-transfer-skeleton__divider {
  height: 1px;
  margin: 0 0 16px;
  background: #e0e0e0;
}

.storevoiceai-transfer-skeleton__switch {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.storevoiceai-transfer-skeleton__switch .storevoiceai-transfer-skeleton__line--text {
  flex: 1 1 auto;
  margin-bottom: 0;
}

.storevoiceai-transfer-skeleton__toggle {
  flex: 0 0 40px;
  width: 40px;
  height: 22px;
  border-radius: 999px;
}

.storevoiceai-transfer-skeleton__line::after,
.storevoiceai-transfer-skeleton__input::after,
.storevoiceai-transfer-skeleton__toggle::after {
  content: "";
  position: absolute;
  inset: 0;
  transform: translateX(-100%);
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.75), transparent);
  animation: phone-skeleton-shimmer 1.15s infinite;
}

.storevoiceai-transfer-card h5 {
  margin: 0 0 4px;
  color: #1d2327;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.35;
}

.storevoiceai-transfer-phone-section {
  margin-bottom: 16px;
}

.storevoiceai-transfer-phone-section .description {
  margin-bottom: 8px;
}

.storevoiceai-working-hours-card {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid #e0e0e0;
}

.storevoiceai-policies {
  margin-top: 6px;
}

.storevoiceai-policy-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  align-items: start;
}

.storevoiceai-policy-grid .storevoiceai-field {
  min-width: 0;
}

.storevoiceai-policy-grid .storevoiceai-field h4 {
  margin-bottom: 6px;
}

.storevoiceai-policy-grid .storevoiceai-greeting {
  width: 100%;
  max-width: none;
  min-height: 118px;
}

#storevoiceai-owner-email-card input[type="email"] {
  width: 100%;
  max-width: 100%;
}

@media (max-width: 782px) {
  .storevoiceai-policy-grid {
    grid-template-columns: 1fr;
  }
}

.storevoiceai-switch-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.storevoiceai-switch-row__label {
  display: block;
  color: #1d2327;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.3;
}

.storevoiceai-switch-row__hint {
  display: block;
  margin-top: 3px;
  color: #646970;
  font-size: 12px;
  line-height: 1.4;
}

.storevoiceai-switch {
  position: relative;
  flex: 0 0 auto;
  width: 46px;
  height: 27px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: #c3c4c7;
  cursor: pointer;
  transition: background-color 0.15s ease, box-shadow 0.15s ease;
}

.storevoiceai-switch:focus {
  outline: none;
  box-shadow: 0 0 0 1px #2271b1, 0 0 0 4px rgba(34, 113, 177, 0.16);
}

.storevoiceai-switch__thumb {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 21px;
  height: 21px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.22);
  transition: transform 0.15s ease;
}

.storevoiceai-switch--on {
  background: #111827;
}

.storevoiceai-switch--on .storevoiceai-switch__thumb {
  transform: translateX(19px);
}

.storevoiceai-hours {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 14px;
  padding-top: 14px;
}

.storevoiceai-hours[hidden] {
  display: none;
}

.storevoiceai-hours__row {
  display: grid;
  grid-template-columns: 48px 102px minmax(290px, 1fr);
  align-items: center;
  gap: 12px;
}

.storevoiceai-hours__day {
  color: #1d2327;
  font-size: 13px;
  font-weight: 700;
}

.storevoiceai-hours__off {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #1d2327;
  cursor: pointer;
  font-size: 13px;
  user-select: none;
}

.storevoiceai-hours__off-box {
  width: 17px;
  height: 17px;
  margin: 0;
  accent-color: #111827;
}

.storevoiceai-hours__times {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.storevoiceai-hours__time {
  width: 132px;
  min-height: 34px;
  padding: 4px 8px;
  border: 1px solid #8c8f94;
  border-radius: 8px;
  background: #fff;
  color: #1d2327;
  font: inherit;
  font-size: 13px;
}

.storevoiceai-hours__time:focus {
  border-color: #2271b1;
  box-shadow: 0 0 0 1px #2271b1;
  outline: 2px solid transparent;
}

.storevoiceai-hours__dash {
  color: #646970;
}

@media (max-width: 782px) {
  .storevoiceai-switch-row {
    align-items: flex-start;
  }

  .storevoiceai-hours__row {
    grid-template-columns: 42px 1fr;
  }

  .storevoiceai-hours__times {
    grid-column: 1 / -1;
  }
}

/* Section headers */
.section-header {
  font-size: 1.3em;
  font-weight: 600;
  margin: 1.5em 0 1em;
  padding-bottom: 0.5em;
  border-bottom: 1px solid #ddd;
}

/* Voice selector improvements */

.voice-card {
  border: 1px solid #ccc;
  border-radius: 8px;
  padding: 12px;
  background-color: #fff;
  width: 600px;
  max-width: 100%;
  box-sizing: border-box;
}

.voice-selector {
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid #ccc;
  border-radius: 8px;
  padding: 16px 10px;
  background-color: #fff;
  margin: 12px 0;
  width: 600px;
  max-width: 100%;
  box-sizing: border-box;
}

.voice-avatar {
  width: 40px;
  height: 40px;
  flex: 0 0 40px;
  border-radius: 50%;
  background: #f0f0f0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: bold;
  color: #333;
}

.voice-details {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.dropdown {
  display: flex;
  align-items: center;
  cursor: pointer;
  width: 100%;
}

.voice-dropdown {
  position: relative;
}

.voice-native-select {
  display: none !important;
}

.dropdown select {
  font: inherit;
  color: #007bff;
  cursor: pointer;
  width: 100%;
  max-width: none;
  box-sizing: border-box;
  min-height: 36px;
  padding: 0 14px;
  border: 1px solid #8c8f94;
  border-radius: 999px;
  background-color: #fff;
}

.dropdown select:focus {
  outline: none;
}

.voice-dropdown__button {
  appearance: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  min-height: 40px;
  padding: 0 14px 0 18px;
  border: 1px solid #8c8f94;
  border-radius: 999px;
  background: #fff;
  color: #06f;
  cursor: pointer;
  font: inherit;
  line-height: 1.2;
  text-align: left;
}

.voice-dropdown__button:focus {
  border-color: #2271b1;
  box-shadow: 0 0 0 1px #2271b1;
  outline: 2px solid transparent;
}

.voice-dropdown__button .dashicons {
  flex: 0 0 auto;
  color: #50575e;
}

#voiceDropdownLabel {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.voice-dropdown__menu {
  position: absolute;
  z-index: 20;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  max-height: 280px;
  overflow-y: auto;
  padding: 6px;
  border: 1px solid #c3c4c7;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.16);
}

.voice-dropdown__menu[hidden] {
  display: none;
}

.voice-dropdown__option {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 6px 10px;
  border-radius: 8px;
  color: #1d2327;
  cursor: pointer;
}

.voice-dropdown__option:hover,
.voice-dropdown__option:focus,
.voice-dropdown__option.is-selected {
  background: #f0f6fc;
  outline: none;
}

.voice-dropdown__option-text {
  display: flex;
  align-items: baseline;
  gap: 6px;
  min-width: 0;
  color: #1d2327;
  font-weight: 600;
}

.voice-dropdown__option-meta {
  color: #646970;
  font-size: 12px;
  font-weight: 400;
}

.voice-dropdown__empty {
  padding: 10px;
  color: #646970;
}

.voice-option__play {
  appearance: none;
  display: inline-grid;
  place-items: center;
  flex: 0 0 28px;
  width: 28px;
  height: 28px;
  padding: 0;
  border: 1px solid #111827;
  border-radius: 50%;
  background: #111827;
  color: #fff;
  cursor: pointer;
}

.voice-option__play:hover,
.voice-option__play:focus,
.voice-option__play.is-playing {
  background: #000;
  border-color: #000;
  outline: none;
}

.voice-option__play:focus {
  box-shadow: 0 0 0 2px #fff, 0 0 0 4px #2271b1;
}

.voice-option__play:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.voice-option__play.voice-preview__button--error {
  background: #fcf0f1;
  border-color: #b32d2e;
  color: #8a1f1f;
}

.voice-option__play .dashicons {
  width: 15px;
  height: 15px;
  font-size: 15px;
  line-height: 15px;
}

/* Phone setup section */
/* Update the CSS */
.phone-setup {
  position: relative;
  background: #fff;
  border-radius: 8px;
  padding: 24px;
  margin-top: 24px;
  overflow: hidden;
}

.phone-setup .section-header {
  margin-top: 0;
}

.phone-setup-grid {
  display: grid;
  grid-template-columns: minmax(200px, 400px) minmax(200px, 1fr);
  gap: 24px;
  align-items: end;
}

.phone-setup-grid[hidden],
.phone-setup-grid.phone-setup-grid--hidden {
  display: none !important;
}

.selector-group {
  margin-bottom: 0;
}

.selector-group label {
  display: block;
  margin-bottom: 8px;
  color: #1d2327;
  font-size: 14px;
  font-weight: normal;
}

.storevoiceai-greeting {
  width: 100%;
  max-width: 600px;
  min-height: 30px;
  padding: 8px 12px;
  border: 1px solid #8c8f94;
  border-radius: 10px;
  font-size: 14px;
  line-height: 1.5;
  resize: vertical;
  background: #fff;
}

.storevoiceai-greeting:focus {
  border-color: #2271b1;
  box-shadow: 0 0 0 1px #2271b1;
  outline: 2px solid transparent;
}

.storevoiceai-greeting::placeholder {
  color: #757575;
}

#storevoiceai-country-select.country-select {
  width: 100%;
  height: 36px;
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid #8c8f94;
  border-radius: 10px;
  background-color: #fff;
  font-size: 14px;
  line-height: 1.5;
}

.area-code-wrapper {
  display: flex;
  gap: 8px;
}

.area-code-wrapper input[type="text"] {
  flex: 1;
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid #8c8f94;
  border-radius: 10px;
  font-size: 14px;
  transition:
    border-color 0.15s ease,
    box-shadow 0.15s ease;
}

.area-code-wrapper input[type="text"]:focus {
  border-color: #2271b1;
  box-shadow: 0 0 0 1px #2271b1;
  outline: 2px solid transparent;
}

.search-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 36px;
  min-width: 150px;
  padding: 8px 16px;
  background: #2271b1;
  color: #fff;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  white-space: nowrap;
  font-size: 14px;
  transition:
    background-color 0.15s ease,
    opacity 0.15s ease;
}

.search-button:hover:not(:disabled) {
  background: #135e96;
}

.search-button:disabled,
.search-button.is-disabled {
  background: #a7aaad;
  cursor: not-allowed;
  opacity: 0.85;
}

.search-button.is-loading {
  background: #135e96;
  cursor: progress;
}

.search-button.is-loading::before {
  content: "";
  width: 14px;
  height: 14px;
  border: 2px solid rgba(255, 255, 255, 0.4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: storevoiceai-spin 0.7s linear infinite;
}

.phone-search-loading {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 16px;
  padding: 14px 16px;
  border: 1px solid #dcdcde;
  border-left: 4px solid #2271b1;
  border-radius: 4px;
  background: #fff;
  color: #3c434a;
}

.phone-spinner {
  display: inline-block;
  width: 18px;
  height: 18px;
  border: 2px solid #dcdcde;
  border-top-color: #2271b1;
  border-radius: 50%;
  animation: storevoiceai-spin 0.7s linear infinite;
  flex-shrink: 0;
}

@keyframes storevoiceai-spin {
  to {
    transform: rotate(360deg);
  }
}

/* Responsive adjustments */
@media screen and (max-width: 782px) {
  .phone-setup-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .selector-group {
    margin-bottom: 16px;
  }
}
/* Phone number list table */
.phone-numbers-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 16px;
}

.phone-numbers-table th,
.phone-numbers-table td {
  padding: 12px;
  text-align: left;
  border-bottom: 1px solid #ddd;
}

.phone-numbers-table th {
  background: #f0f0f1;
  font-weight: 600;
}

.buy-number-button {
  background: #2271b1;
  color: #fff;
  border: none;
  padding: 6px 12px;
  border-radius: 3px;
  cursor: pointer;
}

.buy-number-button:hover {
  background: #135e96;
}

.phone-empty-state {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 16px;
  padding: 14px 16px;
  border: 1px solid #dcdcde;
  border-left: 4px solid #dba617;
  border-radius: 4px;
  background: #fff;
  color: #3c434a;
}

.phone-empty-state .dashicons {
  color: #dba617;
  margin-top: 1px;
}

.phone-empty-state strong {
  display: block;
  margin-bottom: 4px;
}

.phone-empty-state p {
  margin: 0;
}

.phone-subscription-wall {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 36px 24px;
  background: rgba(255, 255, 255, 0.76);
  backdrop-filter: blur(1px);
}

.phone-subscription-wall__content {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: min(470px, 100%);
  padding: 24px 30px;
  border: 1px solid #c3d3e8;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  color: #1d2327;
  text-align: center;
}

.phone-subscription-wall__icon {
  width: 28px;
  height: 28px;
  margin-bottom: 8px;
  color: #2271b1;
  font-size: 28px;
  line-height: 28px;
}

.phone-subscription-wall__content strong {
  display: block;
  margin-bottom: 6px;
  font-size: 16px;
}

.phone-subscription-wall__content p {
  margin: 0 0 14px;
  color: #3c434a;
}

.phone-subscription-wall__action.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  height: 38px;
  min-height: 38px;
  margin-top: 2px;
  padding: 0 20px;
  border-radius: 999px;
  line-height: 1;
}

.storevoiceai-notice {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 16px;
  padding: 12px 14px;
  border: 1px solid #dcdcde;
  border-radius: 4px;
  background: #fff;
  color: #1d2327;
  font-size: 14px;
  line-height: 1.4;
  opacity: 0;
  transform: translateY(-4px);
  transition:
    opacity 0.2s ease,
    transform 0.2s ease;
}

.storevoiceai-notice[hidden] {
  display: none;
}

.storevoiceai-notice--is-visible {
  opacity: 1;
  transform: translateY(0);
}

.storevoiceai-notice .dashicons {
  flex-shrink: 0;
  font-size: 20px;
  width: 20px;
  height: 20px;
}

.storevoiceai-notice__message {
  flex: 1;
}

.storevoiceai-notice__action {
  flex-shrink: 0;
  margin-right: 4px;
}

.storevoiceai-notice__action[hidden] {
  display: none;
}

.storevoiceai-notice__close {
  background: transparent;
  border: none;
  cursor: pointer;
  color: #646970;
  font-size: 18px;
  line-height: 1;
  padding: 4px 6px;
  border-radius: 3px;
}

.storevoiceai-notice__close:hover {
  color: #1d2327;
  background: #f0f0f1;
}

.storevoiceai-notice--success {
  border-color: #c8e6c9;
  background: #f0f9f0;
}

.storevoiceai-notice--success .dashicons {
  color: #00a32a;
}

.storevoiceai-notice--error {
  border-color: #f0c7cc;
  background: #fcf0f1;
}

.storevoiceai-notice--error .dashicons {
  color: #d63638;
}

.phone-numbers-list__heading {
  margin: 20px 0 8px;
  font-size: 14px;
  font-weight: 600;
  color: #1d2327;
}

.phone-numbers-list__description {
  margin: 20px 0 8px;
  color: #50575e;
  font-size: 14px;
  font-weight: 400;
}

.phone-numbers-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border: 1px solid #dcdcde;
  border-radius: 16px;
  background: #fff;
  overflow: hidden;
}

.phone-numbers-list__item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid #f0f0f1;
}

.phone-numbers-list__item:last-child {
  border-bottom: none;
}

.phone-numbers-list__number {
  flex: 1 1 auto;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 14px;
  color: #1d2327;
}

.phone-numbers-list__icon {
  display: inline-grid;
  place-items: center;
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #f0f6fc;
  color: #2271b1;
}

.phone-numbers-list__icon .dashicons {
  width: 18px;
  height: 18px;
  font-size: 18px;
  line-height: 18px;
}

.phone-numbers-list__delete {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 1px solid transparent;
  border-radius: 4px;
  background: transparent;
  color: #646970;
  cursor: pointer;
  transition:
    background-color 0.15s ease,
    color 0.15s ease,
    border-color 0.15s ease;
}

.phone-numbers-list__delete:hover,
.phone-numbers-list__delete:focus {
  color: #d63638;
  background: #fcf0f1;
  border-color: #f1c0c2;
  outline: none;
}

.phone-numbers-list__delete .dashicons {
  font-size: 18px;
  width: 18px;
  height: 18px;
}

.phone-number-skeleton {
  margin-top: 20px;
}

.phone-number-skeleton__card {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 58px;
  padding: 12px 16px;
  border: 1px solid #dcdcde;
  border-radius: 16px;
  background: #fff;
}

.phone-number-skeleton__icon,
.phone-number-skeleton__line,
.phone-number-skeleton__action {
  position: relative;
  overflow: hidden;
  border-radius: 999px;
  background: #eef1f5;
}

.phone-number-skeleton__icon {
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
}

.phone-number-skeleton__line--text {
  width: 260px;
  max-width: 70%;
  height: 14px;
  margin: 0 0 10px;
}

.phone-number-skeleton__line--number {
  flex: 1 1 auto;
  max-width: 180px;
  height: 16px;
}

.phone-number-skeleton__action {
  flex: 0 0 28px;
  width: 28px;
  height: 28px;
  margin-left: auto;
}

.phone-number-skeleton__icon::after,
.phone-number-skeleton__line::after,
.phone-number-skeleton__action::after {
  content: "";
  position: absolute;
  inset: 0;
  transform: translateX(-100%);
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.75), transparent);
  animation: phone-skeleton-shimmer 1.15s infinite;
}

@keyframes phone-skeleton-shimmer {
  100% {
    transform: translateX(100%);
  }
}

.phone-modal {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  transition: opacity 0.15s ease;
}

.phone-modal[hidden] {
  display: none;
}

.phone-modal--is-visible {
  opacity: 1;
}

.phone-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
}

.phone-modal__dialog {
  position: relative;
  width: 100%;
  max-width: 440px;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.25);
  padding: 24px;
  transform: translateY(-6px);
  transition: transform 0.15s ease;
}

.phone-modal--is-visible .phone-modal__dialog {
  transform: translateY(0);
}

.phone-modal__title {
  margin: 0 0 8px;
  font-size: 18px;
  color: #1d2327;
}

.phone-modal__body {
  margin: 0 0 20px;
  font-size: 14px;
  line-height: 1.5;
  color: #3c434a;
}

.phone-modal__actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.phone-modal__confirm.button-primary {
  background: #d63638;
  border-color: #d63638;
  color: #fff;
}

.phone-modal__confirm.button-primary:hover:not(:disabled),
.phone-modal__confirm.button-primary:focus:not(:disabled) {
  background: #b32d2e;
  border-color: #b32d2e;
  color: #fff;
}

.phone-modal__confirm:disabled {
  opacity: 0.7;
  cursor: progress;
}

/* Feedback link styling */
.feedback-link {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid #ddd;
  color: #2271b1;
  text-decoration: none;
}

.feedback-link:hover {
  color: #135e96;
}

.knowledge-base-section {
  background: #fff;
  border-radius: 8px;
  padding: 24px;
  margin-top: 24px;
}

.knowledge-base-section .section-header {
  margin-top: 0;
}

.knowledge-base-section .kb-page-picker label {
  display: block;
  margin-bottom: 8px;
  color: #1d2327;
  font-size: 14px;
  font-weight: normal;
}

/* ── Select2 KB picker — vertically centre tags and cursor ── */
.knowledge-base-section .select2-selection--multiple {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  min-height: 36px;
  padding: 4px 6px;
}

.knowledge-base-section
  .select2-selection--multiple
  .select2-selection__rendered {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px;
  padding: 0;
  margin: 0;
  width: 100%;
}

.knowledge-base-section
  .select2-selection--multiple
  .select2-selection__choice {
  margin: 0; /* remove default top margin that pushes things down */
  line-height: 1.4;
}

.knowledge-base-section .select2-search--inline {
  display: flex;
  align-items: center;
  margin: 0;
}

.knowledge-base-section .select2-search__field {
  margin: 0 !important; /* Select2 injects margin-top inline */
  padding: 0;
  height: auto;
  line-height: 1.4;
}

.storevoiceai-field__label-spaced {
  margin-top: 15px;
}
.storevoiceai-kb-page-select {
  width: 100%;
}
.storevoiceai-kb-response {
  margin-top: 8px;
}

/* Inline loading + error states for sections that fetch data over AJAX.
   Matches the look of the existing .call-logs-empty / .dashboard-empty cards. */
.storevoiceai-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 56px 20px;
  color: #6c7178;
  font-size: 13px;
}
.storevoiceai-loading .spinner {
  float: none;
  margin: 0;
}

.storevoiceai-error {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 10px;
  padding: 48px 24px;
  margin: 0;
  background: #fff;
  border: 1px solid #f0d5d5;
  border-radius: 16px;
  color: #51565c;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}
.storevoiceai-error__icon {
  width: 44px;
  height: 44px;
  color: #d63638;
  background: #fce8e8;
  border-radius: 50%;
  padding: 8px;
  flex-shrink: 0;
}
.storevoiceai-error__title {
  font-size: 16px;
  font-weight: 600;
  color: #1d2327;
  margin: 4px 0 0;
}
.storevoiceai-error__message {
  font-size: 13px;
  max-width: 480px;
  margin: 0;
  line-height: 1.55;
  color: #6c7178;
}
.storevoiceai-error__actions {
  display: flex;
  gap: 8px;
  margin-top: 8px;
  flex-wrap: wrap;
  justify-content: center;
}
.storevoiceai-error__actions .button {
  min-width: 120px;
}

.storevoiceai-global-error {
  margin: 12px 0 16px;
}

/* First-run dashboard spotlight tour */
.svai-tour {
  position: fixed;
  inset: 0;
  z-index: 100000;
  pointer-events: none;
}
/* Four dim rects frame the target, leaving the spotlighted element fully
   visible through the gap. Inline styles from JS set top/left/width/height. */
.svai-tour__dim {
  position: fixed;
  background: rgba(15, 23, 42, 0.62);
  pointer-events: auto;
  transition: top 0.18s ease, left 0.18s ease, width 0.18s ease, height 0.18s ease;
}
.svai-tour__ring {
  position: fixed;
  border-radius: 12px;
  border: 2px solid rgba(99, 102, 241, 0.95);
  box-shadow:
    0 0 0 4px rgba(99, 102, 241, 0.22),
    0 0 32px rgba(99, 102, 241, 0.45);
  pointer-events: auto;
  cursor: pointer;
  transition: top 0.18s ease, left 0.18s ease, width 0.18s ease, height 0.18s ease;
  animation: svai-tour-pulse 1.8s ease-in-out infinite;
  display: none;
}
@keyframes svai-tour-pulse {
  0%, 100% {
    box-shadow:
      0 0 0 4px rgba(99, 102, 241, 0.22),
      0 0 32px rgba(99, 102, 241, 0.45);
  }
  50% {
    box-shadow:
      0 0 0 8px rgba(99, 102, 241, 0.12),
      0 0 44px rgba(99, 102, 241, 0.7);
  }
}
.svai-tour__card {
  position: fixed;
  width: min(340px, calc(100vw - 32px));
  background: #ffffff;
  border-radius: 14px;
  padding: 20px 22px 18px;
  box-shadow: 0 24px 56px rgba(15, 23, 42, 0.32);
  pointer-events: auto;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  color: #1f2937;
}
.svai-tour__close {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 28px;
  height: 28px;
  border: 0;
  background: transparent;
  font-size: 22px;
  line-height: 1;
  color: #6b7280;
  cursor: pointer;
  border-radius: 6px;
}
.svai-tour__close:hover {
  background: #f3f4f6;
  color: #111827;
}
.svai-tour__step {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #6366f1;
  margin-bottom: 6px;
}
.svai-tour__title {
  margin: 0 0 6px;
  font-size: 17px;
  font-weight: 600;
  line-height: 1.3;
  color: #0f172a;
}
.svai-tour__body {
  margin: 0 0 16px;
  font-size: 13.5px;
  line-height: 1.55;
  color: #4b5563;
}
.svai-tour__actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.svai-tour__skip {
  background: transparent;
  border: 0;
  padding: 6px 4px;
  font-size: 12.5px;
  color: #6b7280;
  cursor: pointer;
  text-decoration: underline;
}
.svai-tour__skip:hover {
  color: #111827;
}
.svai-tour__nav {
  display: flex;
  gap: 8px;
}

@media (max-width: 1200px) {
  .billing-summary-panel {
    grid-template-columns: auto 1fr;
  }
  .billing-summary-stats {
    grid-column: 1 / -1;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .billing-summary-stats > div {
    min-width: 0;
  }
  .billing-cards-grid {
    grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.15fr);
  }
  .billing-card--rate {
    grid-column: 1 / -1;
  }
  .billing-usage-totals {
    grid-template-columns: repeat(2, minmax(160px, 1fr));
  }
}

@media (max-width: 782px) {
  .billing-page-header p {
    font-size: 14px;
  }
  .billing-summary-panel,
  .billing-cards-grid,
  .billing-tables-grid {
    grid-template-columns: 1fr;
  }
  .billing-summary-panel {
    padding: 16px;
  }
  .billing-summary-stats {
    grid-template-columns: 1fr;
    gap: 12px;
  }
  .billing-summary-stats > div {
    padding: 12px 0 0;
    border-top: 1px solid rgba(226, 118, 0, 0.18);
    border-left: 0;
  }
  .billing-status-pill {
    justify-self: start;
    padding-top: 0 !important;
  }
  .billing-card,
  .billing-chart-panel,
  .billing-table-panel {
    padding: 16px;
  }
  .billing-card--rate {
    grid-column: auto;
  }
  .billing-card-header--action {
    align-items: flex-start;
    flex-wrap: wrap;
  }
  .billing-card-title-row {
    flex-direction: column;
    gap: 4px;
  }
  .billing-card-title-row p {
    text-align: left;
  }
  .billing-card--wallet .billing-card-header {
    grid-template-columns: 54px minmax(0, 1fr);
  }
  .billing-card--wallet .storevoiceai-topup-checkout {
    grid-column: 2;
    justify-self: start;
    margin-left: 0;
  }
  .storevoiceai-stripe-modal {
    align-items: stretch;
    padding: 12px;
  }
  .storevoiceai-stripe-modal__panel {
    max-height: calc(100vh - 24px);
  }
  .storevoiceai-stripe-modal__header,
  .storevoiceai-stripe-checkout {
    padding: 16px;
  }
  .billing-topup-row,
  .billing-usage-totals {
    grid-template-columns: 1fr;
  }
  .billing-chart-panel .billing-panel-header {
    flex-direction: column;
  }
  .billing-chart-canvas,
  .billing-chart-canvas canvas {
    min-height: 230px;
    height: 230px !important;
  }
}
