/* Shared surfaces for the account, activity and stock screens. */
.kv, .ref-box, .stats-heading, .announcement, .withdrawal-card,
.join-wrap, .stock-card, .stock-search {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--card);
  box-shadow: var(--shadow);
}

/* Service and country picker */
.steps {
  display: flex;
  align-items: center;
  gap: 9px;
  width: fit-content;
  max-width: 100%;
  margin: 0 0 18px;
}
.steps .dot {
  flex: none;
  width: 8px;
  height: 8px;
  border: 2px solid #a9acbd;
  border-radius: 50%;
}
.steps .dot.on { border-color: var(--accent); background: var(--accent); }
.steps .ln { flex: 0 1 30px; width: 30px; height: 2px; background: var(--line); }
.steps .ln.on { background: var(--accent); }
.steps .lbl { color: var(--muted); font-size: 13px; font-weight: 600; overflow-wrap: anywhere; }
.steps .lbl.on { color: var(--accent-ink); }
.picker-title, .picker-head .n, .stats-heading h2, .join-title {
  color: var(--ink);
  font-size: clamp(23px, 4.2vw, 30px);
  font-weight: 750;
  letter-spacing: -.035em;
  line-height: 1.22;
  overflow-wrap: anywhere;
}
.picker-title { margin: 0 0 15px; }
.picker-head, .stats-heading { display: flex; align-items: center; gap: 14px; }
.picker-head { margin-bottom: 16px; }
.picker-head > div, .stats-heading > div { min-width: 0; }
.picker-head .svc-ico, .stats-heading-icon {
  flex: none;
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 14px;
}
.picker-head .svc-ico { background: var(--card); border: 1px solid var(--line); }
.picker-head .k, .stats-heading p { font-size: 13px; color: var(--muted); }
.picker-head .k { margin-bottom: 2px; font-weight: 600; }
.search, .stats-search {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 0 14px;
  margin-bottom: 14px;
  color: var(--muted);
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
}
.search:focus-within, .stats-search:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.search .mag, .chev { display: grid; place-items: center; flex: none; }
.search .icon, .stats-search .icon { width: 18px; height: 18px; }
.search input, .stats-search input {
  flex: 1;
  width: 100%;
  min-width: 0;
  min-height: 46px;
  padding: 7px 0;
  font: inherit;
  font-size: 16px;
  color: var(--ink);
  background: transparent;
  border: 0;
  outline: 0;
}
.search input::placeholder, .stats-search input::placeholder { color: var(--muted); opacity: 1; }
.row, .top-service-row {
  display: flex;
  align-items: center;
  width: 100%;
  gap: 12px;
  padding: 13px 16px;
  color: var(--ink);
  background: var(--card);
  border: 0;
  border-bottom: 1px solid var(--line);
  font: inherit;
  text-align: start;
}
.row:last-child, .top-service-row:last-child { border-bottom: 0; }
.row:focus-visible, .top-service-row:focus-visible { outline-offset: -3px; }
.row .r-ico {
  display: grid;
  flex: none;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: var(--bg);
}
.row .r-main, .top-service-row strong { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.row .r-t, .top-service-row strong { font-size: 15px; font-weight: 650; }
.row .r-s { display: block; margin-top: 2px; font-size: 12px; color: var(--muted); }
.chev { color: var(--muted); }
.chev .icon { width: 16px; height: 16px; }
.pill, .withdrawal-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  padding: 4px 10px;
  border-radius: 100px;
  font-size: 12px;
  font-weight: 650;
  line-height: 1.4;
  overflow-wrap: anywhere;
}
.pill { color: var(--accent-ink); background: var(--accent-soft); font-variant-numeric: tabular-nums; }
#back-svc, .stats-back, #withdrawal-back { margin-top: 14px; }

/* Profile */
.profile-layout, .profile-column { display: grid; min-width: 0; align-content: start; gap: 14px; }
.profile-column > .kv, .profile-column > .ref-box { margin: 0; }
.kv, .ref-box, .announcement, .withdrawal-card { margin-bottom: 14px; }
.kv { padding: 2px 18px; }
.kv .r, .pref-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
  overflow-wrap: anywhere;
}
.kv .r:last-child, .pref-row:last-child { border: 0; }
.kv .k { color: var(--muted); font-size: 14px; }
.kv .v { min-width: 0; max-width: 65%; font-weight: 650; text-align: end; }
.pref-row { font-weight: 600; }
.pref-row .btn { min-height: 40px; padding: 7px 12px; font-size: 13px; }
.pref-row .btn[aria-label] { min-width: 40px; }
.ref-box { padding: 18px; }
.ref-box .link {
  margin: 12px 0;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--bg);
  color: var(--muted);
  font-size: 13px;
  overflow-wrap: anywhere;
}
.ref-box .acts, .sheet .row2 { display: flex; gap: 9px; }
.ref-box .acts .btn, .sheet .row2 .btn { flex: 1; min-width: 0; overflow-wrap: anywhere; }

/* Live traffic, rankings, notifications and withdrawal history */
.live-controls { display: flex; align-items: center; gap: 9px; margin-bottom: 14px; }
.live-controls .seg { flex: 1; min-width: 0; margin-bottom: 0; }
.seg { display: flex; gap: 3px; padding: 4px; margin-bottom: 14px; border-radius: 13px; background: #eaeaf2; }
.seg button {
  flex: 1;
  min-width: 0;
  min-height: 36px;
  padding: 6px 8px;
  border: 1px solid transparent;
  border-radius: 9px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 13px;
  font-weight: 650;
  overflow-wrap: anywhere;
}
.seg button.on { background: var(--card); color: var(--accent-ink); box-shadow: 0 1px 4px #2729411a; }
.stats-icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 13px;
  color: var(--accent-ink);
  background: var(--card);
}
.stats-heading { padding: 20px; margin-bottom: 14px; }
.stats-heading-icon { color: var(--accent-ink); background: var(--accent-soft); }
.stats-heading-icon .icon { width: 24px; height: 24px; }
.stats-heading h2 { margin: 0; }
.stats-heading p { margin: 4px 0 0; }
.top-service-row { min-height: 57px; }
.service-rank {
  display: grid;
  place-items: center;
  flex: none;
  width: 27px;
  height: 27px;
  border-radius: 8px;
  background: var(--bg);
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}
.top-service-row:first-child .service-rank { color: var(--accent-ink); background: var(--accent-soft); }
.service-count { font-size: 13px; font-weight: 650; font-variant-numeric: tabular-nums; }
.announcement, .withdrawal-card { padding: 16px 18px; overflow-wrap: anywhere; }
.announcement-head, .announcement-head strong { display: flex; align-items: center; gap: 8px; }
.announcement-head { justify-content: space-between; flex-wrap: wrap; }
.announcement-head .icon { width: 18px; height: 18px; color: var(--accent); }
.announcement-head .ago { color: var(--muted); font-size: 12px; }
.announcement-text { white-space: pre-wrap; line-height: 1.6; }
.announcement-media { min-width: 0; margin: 12px 0; }
.announcement-media img, .announcement-media video {
  display: block;
  max-width: 100%;
  max-height: 370px;
  object-fit: contain;
  border-radius: 12px;
}
.announcement-media audio, .announcement-media a { max-width: 100%; }
.announcement-media a { text-decoration: none; }
.withdrawal-card .announcement-head { margin-bottom: 8px; }
.withdrawal-card .announcement-head strong { font-size: 19px; font-variant-numeric: tabular-nums; }
.withdrawal-card p { margin: 9px 0; }
.withdrawal-status { color: var(--muted); background: var(--bg); }
.withdrawal-status.approved { color: var(--green); background: var(--green-soft); }
.withdrawal-status.credited { color: var(--green); background: var(--green-soft); }
.withdrawal-status.rejected { color: var(--danger); background: color-mix(in srgb, var(--danger) 12%, var(--card)); }
.withdrawal-status.pending { color: #b47a14; background: color-mix(in srgb, #e0a22b 16%, var(--card)); }

/* Telegram channel verification */
.join-wrap { max-width: 490px; margin: 0 auto; padding: clamp(20px, 4vw, 32px); text-align: center; }
.join-title { margin: 13px 0 5px; }
.join-sub { margin: 0 auto 20px; max-width: 36ch; color: var(--muted); line-height: 1.55; }
.join-list { display: grid; gap: 8px; margin-bottom: 16px; }
.join-row {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 12px 14px;
  border-radius: 12px;
  color: var(--accent-ink);
  background: var(--accent-soft);
  text-align: start;
  text-decoration: none;
}
.join-name { flex: 1; min-width: 0; font-weight: 650; overflow-wrap: anywhere; }
.join-row .icon { width: 17px; height: 17px; }

/* Bottom sheets */
.sheet-wrap {
  position: fixed;
  z-index: 60;
  inset: 0;
  display: grid;
  align-items: end;
  justify-items: center;
}
.sheet-backdrop { position: absolute; inset: 0; background: rgba(20, 22, 40, .43); }
.sheet {
  position: relative;
  width: 100%;
  max-width: 480px;
  max-height: 92vh;
  max-height: 92dvh;
  overflow: auto;
  overscroll-behavior: contain;
  padding: 12px max(20px, env(safe-area-inset-right)) calc(20px + var(--safe-b)) max(20px, env(safe-area-inset-left));
  border-radius: 23px 23px 0 0;
  background: var(--card);
  box-shadow: 0 -10px 42px #1e204221;
}
.grip { width: 38px; height: 4px; margin: 0 auto 17px; border-radius: 100px; background: #c6c6d5; }
.sheet h3 { margin: 0 0 8px; font-size: 22px; line-height: 1.25; letter-spacing: -.025em; }
.sheet p { margin: 0 0 16px; color: var(--muted); font-size: 14px; line-height: 1.55; }
.sheet .remember {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  margin-bottom: 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
}
.sheet .remember .t { font-size: 14px; font-weight: 650; }
.sheet .remember .s { margin-top: 2px; color: var(--muted); font-size: 12px; }
.sheet .row2 #pfx-cancel { flex: none; min-width: 46px; }
.switch {
  flex: none;
  display: flex;
  align-items: center;
  width: 44px;
  height: 26px;
  padding: 3px;
  border: 0;
  border-radius: 100px;
  background: #a0a3b5;
  cursor: pointer;
}
.switch::after {
  content: "";
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: white;
  box-shadow: 0 1px 3px #16182e30;
}
.switch.on { background: var(--accent); }
.switch.on::after { transform: translateX(18px); }
.menu-item {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  min-height: 49px;
  padding: 12px 4px;
  border: 0;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  background: none;
  font: inherit;
  font-weight: 600;
  text-align: start;
}
.menu-item:last-child { border-bottom: 0; }
.menu-item .icon { width: 19px; height: 19px; color: var(--accent-ink); }

/* Stock monitoring and preferences */
.stock-tools { min-width: 0; overflow-wrap: anywhere; }
.stock-back { margin-bottom: 12px; }
.stock-tools .stock-section { margin-top: 24px; }
.stock-tools .r-ico { color: var(--accent-ink); background: var(--accent-soft); }
.stock-card, .stock-search { margin: 12px 0; padding: 16px 18px; }
.stock-ident { display: flex; align-items: center; gap: 10px; }
.stock-copy { flex: 1; min-width: 0; }
.stock-meta { margin-top: 9px; }
.stock-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.stock-actions .btn { min-width: 0; max-width: 100%; font-size: 13px; }
.stock-actions .pill:first-child { margin-inline-end: auto; }
.stock-search, .stock-form { display: grid; gap: 14px; }
.stock-filter, .stock-form label { display: grid; align-content: start; gap: 6px; min-width: 0; }
.stock-filter label, .stock-form label { font-size: 13px; font-weight: 650; }
.stock-query-row { display: flex; gap: 8px; min-width: 0; }
.stock-query-row input { flex: 1; }
.stock-tools select, .stock-tools input:not([type="checkbox"]) {
  width: 100%;
  min-width: 0;
  max-width: 100%;
  min-height: 44px;
  padding: 7px 11px;
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--ink);
  background: var(--bg);
  font: inherit;
  font-size: 16px;
  font-weight: 400;
}
.stock-tools input:focus-visible, .stock-tools select:focus-visible {
  border-color: var(--accent);
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}
.stock-tools :disabled { cursor: not-allowed; opacity: .55; }
.stock-form p, .stock-form .stock-actions { margin: 0; }
.stock-form .stock-check { display: flex; align-items: center; gap: 10px; min-height: 36px; }
.stock-check input { flex: none; width: 20px; height: 20px; margin: 0; accent-color: var(--accent); }
.stock-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.stock-metrics { margin-top: 14px; }
.stock-metrics > div { padding: 10px 12px; border-radius: 10px; background: var(--bg); }
.stock-metrics strong { display: block; margin-top: 3px; font-variant-numeric: tabular-nums; }

@media (hover: hover) {
  .row:hover:not(:disabled), .top-service-row:hover, .menu-item:hover,
  .stats-icon:hover, .join-row:hover { background: var(--accent-soft); }
}
@media (min-width: 600px) {
  .sheet-wrap { align-items: center; padding: 16px; }
  .sheet { border-radius: 22px; padding: 24px; }
  .sheet .grip { display: none; }
}
@media (min-width: 680px) {
  .stock-search { grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); align-items: end; }
}
@media (min-width: 700px) {
  .profile-layout { grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 20px; }
}
@media (max-width: 370px) {
  .row, .top-service-row { gap: 9px; padding-inline: 11px; }
  .stock-card, .stock-search, .ref-box, .stats-heading { padding: 14px; }
  .stock-form .stock-grid { grid-template-columns: 1fr; }
  .pref-row { gap: 8px; }
}
@media (prefers-reduced-motion: no-preference) {
  .sheet { animation: sheet-enter .18s ease-out; }
  .switch::after { transition: transform .15s ease-out; }
  @keyframes sheet-enter {
    from { transform: translateY(14px); opacity: .8; }
    to { transform: translateY(0); opacity: 1; }
  }
}

/* Deposit history rows reuse the withdrawal list layout. */
.deposit-list { display: grid; gap: 0; }
.deposit-entry { display: grid; gap: 4px; padding: 12px 0; }
.deposit-entry .withdrawal-entry-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; }

/* Deposit history cards */
.deposit-entry {
  padding: 14px; margin-bottom: 10px; border: 1px solid var(--line);
  border-radius: var(--radius); background: var(--card); box-shadow: var(--shadow);
}
.deposit-entry + .deposit-entry { border-top: 1px solid var(--line); }
.deposit-entry .withdrawal-entry-head strong { font-size: 18px; font-weight: 760; color: var(--ink); }
.deposit-entry .receipt-note { font-size: 13px; color: var(--muted); }
.deposit-receipt-btn { margin-top: 6px; justify-self: start; }

/* Receipt overlay (opens inside the Mini App) */
.receipt-overlay {
  position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center;
  padding: 16px; background: rgba(12, 11, 25, .62);
}
.receipt-sheet {
  display: grid; gap: 12px; width: min(420px, 100%); max-height: 100%;
  padding: 14px; border-radius: var(--radius); background: var(--card);
}
.receipt-img { display: block; width: 100%; height: auto; border-radius: 12px; }

/* Deposit card: user photo centered at the top */
.deposit-photo-wrap {
  display: grid; place-items: center; width: 84px; height: 84px; margin: 0 auto 10px;
  border-radius: 50%; overflow: hidden; background: var(--accent-soft); color: var(--accent-ink);
  box-shadow: 0 0 0 3px var(--card), 0 0 0 4px var(--line);
}
.deposit-photo { width: 100%; height: 100%; object-fit: cover; display: block; }
.deposit-photo-fallback { display: grid; place-items: center; width: 100%; height: 100%; }
.deposit-photo-fallback .icon { width: 36px; height: 36px; }
.deposit-entry { text-align: center; }
.deposit-entry .withdrawal-entry-head { justify-content: center; }
.deposit-txid code { word-break: break-all; font-size: 12px; }
.deposit-receipt-btn { justify-self: center; }

/* OTP monitor: range filters and pager */
.monitor-ranges { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0 6px; }
.monitor-ranges .pill {
  border: 1px solid var(--line); border-radius: 99px; padding: 7px 13px;
  background: var(--card); color: var(--muted); font: inherit; font-size: 13px; font-weight: 650; cursor: pointer;
}
.monitor-ranges .pill.on { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-ink); }
.monitor-pager { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 12px 0; }
.monitor-pager .btn { min-width: 96px; }
.monitor-pager .btn:disabled { opacity: .45; cursor: default; }

/* OTP monitor cards */
.monitor-card {
  display: grid; gap: 10px; padding: 14px; margin-bottom: 10px;
  border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--card); box-shadow: var(--shadow);
}
.mon-top { display: flex; align-items: center; gap: 12px; }
.mon-svc .svc, .mon-svc .svc-pick { width: 40px; height: 40px; }
.mon-title { display: grid; gap: 2px; min-width: 0; flex: 1; }
.mon-service { font-size: 15px; font-weight: 720; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mon-panel { font-size: 12px; color: var(--muted); }
.mon-otp {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 17px; font-weight: 760;
  letter-spacing: .08em; color: var(--green); background: var(--green-soft);
  padding: 6px 11px; border-radius: 10px; cursor: pointer; user-select: all;
}
.mon-meta { display: flex; flex-wrap: wrap; gap: 6px; }
.mon-chip {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 9px; border-radius: 99px;
  background: var(--bg); color: var(--muted); font-size: 12px; font-weight: 600;
}
.mon-num code { color: var(--ink); background: none; }
.mon-foot {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding-top: 8px; border-top: 1px dashed var(--line);
}
.mon-user-wrap { display: flex; align-items: center; gap: 6px; min-width: 0; }
.mon-user { display: inline-flex; align-items: center; gap: 5px; font-size: 13px; font-weight: 680; color: var(--accent-ink); }
.mon-user .icon { width: 14px; height: 14px; }
.mon-uid { font-size: 11px; color: var(--muted); }
.mon-none { color: var(--muted); font-weight: 600; }
.mon-time { font-size: 11px; color: var(--muted); white-space: nowrap; }

/* ── UI polish pass ─────────────────────────────────────────────
   Loaded after style.css, so these refine the base look without
   changing layout. Goals: comfortable touch targets, clear press
   feedback, a clear primary/secondary hierarchy, softer cards. */

.btn {
  min-height: 44px;                       /* Telegram-friendly touch target */
  border-radius: 13px;
  font-weight: 650;
  letter-spacing: .01em;
  transition: transform .12s ease, background-color .15s ease, box-shadow .15s ease, opacity .15s ease;
  -webkit-tap-highlight-color: transparent;
}
.btn:not(:disabled):active { transform: scale(.975); }
.btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.btn.primary {
  background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 92%, #fff) 0%, var(--accent) 100%);
  box-shadow: 0 6px 16px -8px color-mix(in srgb, var(--accent) 70%, transparent);
}
.btn.primary:not(:disabled):hover { filter: brightness(1.05); }
.btn.soft:not(:disabled):hover, .btn.ghost:not(:disabled):hover { background: var(--accent-soft); }
.btn.pill-btn { min-height: 38px; padding: 7px 13px; font-size: 13px; border-radius: 99px; }
.btn.rel { border-color: color-mix(in srgb, var(--danger) 35%, var(--line)); }
.btn.rel:not(:disabled):hover { background: color-mix(in srgb, var(--danger) 8%, var(--card)); }

/* Cards: softer border, lift on hover/press for pointer and touch */
.monitor-card, .deposit-entry, .panel-health-entry {
  transition: transform .15s ease, box-shadow .2s ease;
}
.monitor-card:active, .deposit-entry:active { transform: scale(.992); }
@media (hover: hover) {
  .monitor-card:hover, .deposit-entry:hover {
    box-shadow: 0 8px 22px -14px rgba(29, 27, 62, .35);
  }
}

/* Monitor range pills: clearer selected state and touch size */
.monitor-ranges .pill { min-height: 38px; padding: 8px 15px; transition: background-color .15s ease, color .15s ease; }
.monitor-ranges .pill:active { transform: scale(.97); }
.monitor-ranges .pill.on { box-shadow: inset 0 0 0 1px var(--accent); }

/* Pager */
.monitor-pager .btn { min-height: 44px; }

/* Status pills: a little more weight so state reads at a glance */
.withdrawal-status { font-weight: 700; letter-spacing: .01em; }

/* Respect reduced-motion preferences */
@media (prefers-reduced-motion: reduce) {
  .btn, .monitor-card, .deposit-entry, .monitor-ranges .pill { transition: none; }
  .btn:not(:disabled):active, .monitor-card:active, .deposit-entry:active { transform: none; }
}

/* OTP chip: flips to "Copied" for a moment after a tap */
.mon-otp { transition: background-color .2s ease, color .2s ease, transform .12s ease; }
.mon-otp:active { transform: scale(.96); }
.mon-otp.copied { background: var(--green); color: #fff; }

/* Custom panels admin screen */
.cp-form { display: grid; gap: 12px; padding: 14px; margin-bottom: 14px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); box-shadow: var(--shadow); }
.cp-field { display: grid; gap: 6px; }
.cp-field > span { font-size: 12px; font-weight: 650; color: var(--muted); letter-spacing: .01em; }
.cp-input {
  width: 100%; min-height: 44px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px;
  background: var(--bg); color: var(--ink); font: inherit; font-size: 15px;
}
.cp-input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.cp-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }
.cp-actions .btn { min-width: 110px; }
.cp-actions .btn:disabled { opacity: .45; cursor: not-allowed; }

.cp-report { border-radius: 14px; padding: 12px; display: grid; gap: 10px; border: 1px solid var(--line); background: var(--bg); }
.cp-report.ok { border-color: color-mix(in srgb, var(--green) 40%, var(--line)); background: var(--green-soft); }
.cp-report.bad { border-color: color-mix(in srgb, var(--danger) 40%, var(--line)); background: color-mix(in srgb, var(--danger) 8%, var(--card)); }
.cp-verdict { margin: 0; font-weight: 700; color: var(--ink); }
.cp-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.cp-step { display: grid; grid-template-columns: 12px 1fr; column-gap: 8px; font-size: 13px; color: var(--ink); }
.cp-dot { width: 10px; height: 10px; border-radius: 50%; margin-top: 5px; background: var(--muted); }
.cp-step.pass .cp-dot { background: var(--green); }
.cp-step.fail .cp-dot { background: var(--danger); }
.cp-detail { display: block; grid-column: 2; font-size: 12px; color: var(--muted); }
.cp-keys { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.cp-keys > span { font-size: 12px; font-weight: 650; color: var(--muted); margin-right: 4px; }
.cp-keys code { padding: 3px 8px; border-radius: 99px; background: var(--card); border: 1px solid var(--line); font-size: 12px; }
.cp-sample { display: grid; gap: 3px; font-size: 13px; color: var(--ink); }

.cp-list { display: grid; gap: 10px; margin-top: 12px; }
.cp-card { padding: 14px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); box-shadow: var(--shadow); display: grid; gap: 10px; }
.cp-card.on { border-left: 4px solid var(--green); }
.cp-card.off { border-left: 4px solid var(--line); }
.cp-card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.cp-card-head strong { font-size: 16px; color: var(--ink); }
.cp-state { font-size: 11px; font-weight: 750; letter-spacing: .06em; padding: 4px 9px; border-radius: 99px; }
.cp-card.on .cp-state { background: var(--green-soft); color: var(--green); }
.cp-card.off .cp-state { background: var(--bg); color: var(--muted); }
.cp-meta { display: flex; flex-wrap: wrap; gap: 6px 12px; font-size: 12px; color: var(--muted); }
.cp-meta code { color: var(--ink); }
.cp-card-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.cp-card-actions .btn { min-height: 38px; }
.cp-form + .cp-list { margin-top: 0; }
@media (prefers-reduced-motion: reduce) { .cp-input { transition: none; } }

/* Verify report: raw reply and list picker */
.cp-raw { border: 1px solid var(--line); border-radius: 12px; background: var(--card); overflow: hidden; }
.cp-raw summary { cursor: pointer; padding: 10px 12px; font-size: 13px; font-weight: 650; color: var(--ink); }
.cp-raw pre {
  margin: 0; padding: 10px 12px; max-height: 320px; overflow: auto;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12px; line-height: 1.45;
  color: var(--ink); white-space: pre; border-top: 1px solid var(--line);
}
.cp-paths { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.cp-paths > span { font-size: 12px; font-weight: 650; color: var(--muted); }

/* Request tester */
.rt-bar { display: grid; grid-template-columns: 110px 1fr auto; gap: 8px; align-items: center; margin: 8px 0 14px; }
.rt-bar .btn { min-height: 44px; }
.rt-h { font-size: 13px; font-weight: 700; color: var(--muted); margin: 14px 0 6px; letter-spacing: .02em; }
.rt-group { display: grid; gap: 8px; }
.rt-kv { display: grid; grid-template-columns: 1fr 1fr auto; gap: 6px; align-items: center; }
.rt-body { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 13px; resize: vertical; }
.rt-result { margin-top: 16px; padding: 12px; border-radius: 14px; display: grid; gap: 10px; border: 1px solid var(--line); background: var(--card); }
.rt-result.ok { border-color: color-mix(in srgb, var(--green) 40%, var(--line)); }
.rt-result.bad { border-color: color-mix(in srgb, var(--danger) 40%, var(--line)); }
.rt-status { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 6px; }
.rt-status strong { font-size: 16px; color: var(--ink); }
.rt-status span { font-size: 12px; color: var(--muted); }
.rt-note { margin: 0; font-size: 13px; color: var(--ink); }
.rt-result pre {
  margin: 0; padding: 10px 12px; max-height: 360px; overflow: auto; border-radius: 10px;
  background: var(--bg); color: var(--ink); white-space: pre-wrap; word-break: break-word;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12px; line-height: 1.45;
}
.rt-result summary { cursor: pointer; font-size: 13px; font-weight: 650; color: var(--ink); }
.rt-hdrs { display: grid; gap: 4px; margin-top: 6px; }
.rt-hdr { display: grid; grid-template-columns: minmax(120px, auto) 1fr; gap: 8px; font-size: 12px; }
.rt-hdr span { color: var(--muted); word-break: break-all; }
@media (max-width: 520px) {
  .rt-bar { grid-template-columns: 1fr; }
  .rt-kv { grid-template-columns: 1fr; }
}

/* Request tester: auth, tools, history */
.rt-auth { display: grid; gap: 8px; }
.rt-tools { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px; }
.rt-seg { display: inline-flex; border: 1px solid var(--line); border-radius: 99px; overflow: hidden; }
.rt-seg button { border: 0; background: var(--card); color: var(--muted); padding: 7px 14px; font: inherit; font-size: 13px; font-weight: 650; cursor: pointer; min-height: 36px; }
.rt-seg button.on { background: var(--accent-soft); color: var(--accent-ink); }
.rt-code.ok { color: var(--green); }
.rt-code.bad { color: var(--danger); }
.rt-body-pre {
  margin: 0; padding: 10px 12px; max-height: 360px; overflow: auto; border-radius: 10px;
  background: var(--bg); color: var(--ink); white-space: pre-wrap; word-break: break-word;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12px; line-height: 1.45;
}
.rt-history { display: grid; gap: 6px; }
.rt-hist {
  display: grid; grid-template-columns: 56px 1fr auto; gap: 8px; align-items: center; text-align: left;
  padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--card);
  color: var(--ink); font: inherit; font-size: 13px; cursor: pointer; min-height: 44px;
}
.rt-hist:active { transform: scale(.985); }
.rt-hist-method { font-weight: 750; color: var(--accent-ink); }
.rt-hist-url { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); }
.rt-hist-status { font-weight: 750; }
.rt-hist-status.ok { color: var(--green); }
.rt-hist-status.bad { color: var(--danger); }

/* Custom panels screen: space the action buttons and list apart */
.cp-toolbar { display: grid; gap: 10px; margin: 6px 0 14px; }
.cp-toolbar .btn { margin: 0; }

.rt-warn { margin: 10px 0 0; padding: 10px 12px; border-radius: 12px; font-size: 13px; color: var(--danger); background: color-mix(in srgb, var(--danger) 10%, var(--card)); border: 1px solid color-mix(in srgb, var(--danger) 35%, var(--line)); }
