/* ---------------------------------------------------------------------------
   Payments, in GHL's look.

   GHL draws Payments with its HighRise kit (Untitled-UI tokens): Inter, a
   #101828 / #475467 / #667085 text ramp, #EAECF0 hairlines, #D0D5DD input
   borders, #155EEF primary. Everything is scoped under .gp so the rest of the
   app keeps app.css's look. The layouts follow the live screens: one white
   bar with "Payments" and the tabs (four of them dropdowns), a page header
   with a 30px title, and lists in a white card whose first row is the date
   range, search, filters and export.
--------------------------------------------------------------------------- */

.gp, .gp-menu, .gp-modal-back, .gp-pop, .gp-drawer-back {
  --gp-text: #101828; --gp-text-2: #344054; --gp-muted: #475467; --gp-dim: #667085; --gp-faint: #98a2b3;
  --gp-line: #eaecf0; --gp-input: #d0d5dd; --gp-bg: #f9fafb;
  --gp-blue: #155eef; --gp-blue-hover: #004eeb; --gp-blue-50: #eff4ff; --gp-blue-100: #d1e0ff;
  --gp-green: #079455; --gp-red: #d92d20; --gp-amber: #dc6803;
  --gp-shadow: 0 1px 2px rgba(16, 24, 40, .05);
  --gp-shadow-md: 0 4px 8px -2px rgba(16, 24, 40, .1), 0 2px 4px -2px rgba(16, 24, 40, .06);
  font-family: Inter, system-ui, sans-serif; color: var(--gp-text);
}
.gp { background: var(--gp-bg); min-height: 100%; }
.gp *, .gp *::before, .gp *::after, .gp-modal-back *, .gp-menu *, .gp-pop *, .gp-drawer-back * { box-sizing: border-box; }
/* Layout classes set display; `hidden` must still win. */
.gp [hidden], .gp-modal-back [hidden], .gp-menu [hidden], .gp-pop [hidden], .gp-drawer-back [hidden] { display: none !important; }

/* ----- the top bar ----- */
.gp-topnav {
  display: flex; align-items: stretch; gap: 2px; background: #fff; border-bottom: 1px solid var(--gp-line);
  padding: 0 16px 0 20px; min-height: 56px; position: sticky; top: 0; z-index: 20; flex-wrap: wrap;
}
.gp-topnav-title { font-size: 20px; font-weight: 600; align-self: center; margin-right: 22px; white-space: nowrap; }
/* Long labels sit on two lines, as GHL's do ("Invoices &" / "Estimates",
   "Payment" / "Links"), so all eleven tabs fit; a bar still short of room
   wraps rather than hiding Settings and Integrations off its end. */
.gp-tab {
  position: relative; display: inline-flex; align-items: center; gap: 4px; border: 0; background: none;
  padding: 8px 9px; font: 500 14px/1.35 Inter, sans-serif; color: var(--gp-text-2); cursor: pointer;
  flex: none; white-space: nowrap; text-align: left;
}
.gp-tab.wrap { white-space: normal; width: min-content; }
.gp-tab .ico { flex: none; }
.gp-tab:hover { color: var(--gp-blue); }
.gp-tab.on { color: var(--gp-blue); }
.gp-tab.on::after { content: ''; position: absolute; left: 8px; right: 8px; bottom: 0; height: 2px; background: var(--gp-blue); border-radius: 2px; }
.gp-tab .ico { width: 16px; height: 16px; }

.gp-menu {
  position: fixed; z-index: 1000; background: #fff; border: 1px solid var(--gp-line); border-radius: 8px;
  box-shadow: 0 12px 16px -4px rgba(16, 24, 40, .08), 0 4px 6px -2px rgba(16, 24, 40, .03); padding: 4px 0; min-width: 180px;
}
.gp-menu button {
  display: flex; align-items: center; gap: 8px; width: 100%; border: 0; background: none; text-align: left;
  padding: 10px 16px; font: 500 14px Inter, sans-serif; color: var(--gp-text-2); cursor: pointer; white-space: nowrap;
}
.gp-menu button:hover { background: var(--gp-bg); }
.gp-menu button.on { color: var(--gp-blue); }
.gp-menu button.danger { color: var(--gp-red); }
.gp-menu button:disabled { color: var(--gp-faint); cursor: not-allowed; }
.gp-menu .gp-menu-sub { display: block; font-weight: 400; font-size: 12.5px; color: var(--gp-dim); white-space: normal; margin-top: 2px; }
.gp-menu hr { border: 0; border-top: 1px solid var(--gp-line); margin: 4px 0; }
/* Invoices → "+ New", as GHL's CreateInvoiceBtn renders each option:
   py-2 px-4, gap-6, a 24px black icon, text-md title, text-xs grey line. */
.gp-menu.inv-new-menu { padding: 8px 0; border-radius: 8px; }
.gp-menu.inv-new-menu button { align-items: flex-start; gap: 24px; padding: 8px 16px; }
.gp-menu.inv-new-menu button:hover { background: #f2f4f7; }
.gp-menu.inv-new-menu button > svg { width: 24px; height: 24px; margin-top: 8px; color: #000; flex: none; }
.gp-menu.inv-new-menu button > span { font-size: 16px; line-height: 24px; font-weight: 500; color: #000; }
.gp-menu.inv-new-menu .gp-menu-sub { font-size: 12px; line-height: 18px; color: #667085; margin-top: 0; white-space: nowrap; }

/* ----- page frame ----- */
.gp-page { padding: 32px 32px 48px; max-width: 1600px; }
.gp-page.tight { padding: 20px 20px 40px; }
.gp-head { display: flex; align-items: flex-start; gap: 16px; margin-bottom: 32px; flex-wrap: wrap; }
.gp-head h1 { font-size: 30px; line-height: 38px; font-weight: 600; margin: 0; letter-spacing: -0.01em; color: var(--gp-text); }
.gp-head h1 small { font-size: 14px; font-weight: 400; color: var(--gp-dim); margin-left: 6px; letter-spacing: 0; }
.gp-head p { margin: 4px 0 0; font-size: 16px; line-height: 24px; color: var(--gp-muted); max-width: 640px; }
.gp-head p a { color: var(--gp-blue); font-weight: 600; text-decoration: none; }
.gp-head-actions { margin-left: auto; display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
/* The compact white band GHL uses on Abandoned checkouts, Collections, Inventory. */
.gp-band { background: #fff; border-bottom: 1px solid var(--gp-line); padding: 14px 20px; display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.gp-band h1 { font-size: 18px; font-weight: 600; margin: 0; line-height: 26px; }
.gp-band p { margin: 0; font-size: 14px; color: var(--gp-muted); }
.gp-band.flat h1 { font-size: 16px; }
.gp-back { border: 0; background: none; color: var(--gp-text-2); cursor: pointer; padding: 6px; border-radius: 6px; display: inline-grid; place-items: center; }
.gp-back:hover { background: var(--gp-bg); }

/* ----- buttons ----- */
.gp-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 40px; padding: 0 16px;
  border-radius: 8px; border: 1px solid var(--gp-input); background: #fff; color: var(--gp-text-2);
  font: 600 14px Inter, sans-serif; cursor: pointer; box-shadow: var(--gp-shadow); white-space: nowrap; text-decoration: none;
}
.gp-btn:hover { background: var(--gp-bg); }
.gp-btn:disabled { opacity: .5; cursor: not-allowed; }
.gp-btn.primary { background: var(--gp-blue); border-color: var(--gp-blue); color: #fff; }
.gp-btn.primary:hover { background: var(--gp-blue-hover); }
.gp-btn.primary:disabled { background: #b2ccff; border-color: #b2ccff; opacity: 1; }
.gp-btn.danger { background: var(--gp-red); border-color: var(--gp-red); color: #fff; }
.gp-btn.link { border: 0; box-shadow: none; background: none; color: var(--gp-blue); padding: 0 4px; height: auto; }
.gp-btn.link:hover { text-decoration: underline; background: none; }
.gp-btn.sm { height: 36px; padding: 0 14px; }
.gp-btn.icon { width: 40px; padding: 0; }
.gp-btn .ico { width: 18px; height: 18px; }
.gp-iconbtn { border: 0; background: none; width: 32px; height: 32px; border-radius: 6px; display: inline-grid; place-items: center; color: var(--gp-dim); cursor: pointer; }
.gp-iconbtn:hover { background: var(--gp-bg); color: var(--gp-text); }

/* ----- banner ----- */
.gp-banner {
  background: var(--gp-blue-50); border: 1px solid var(--gp-blue-100); border-radius: 12px; padding: 16px 20px;
  display: grid; grid-template-columns: auto 1fr auto; gap: 4px 12px; margin-bottom: 32px; color: var(--gp-blue);
}
.gp-banner > .ico { margin-top: 2px; }
.gp-banner-text { font-size: 14px; font-weight: 500; }
.gp-banner-x { border: 0; background: none; color: var(--gp-dim); cursor: pointer; padding: 2px; }
.gp-banner .gp-btn { grid-column: 2; justify-self: start; margin-top: 12px; color: var(--gp-text-2); }

/* ----- stat cards ----- */
.gp-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-bottom: 32px; }
.gp-stat { background: #fff; border: 1px solid var(--gp-line); border-radius: 12px; box-shadow: var(--gp-shadow-md); padding: 24px; min-width: 0; }
.gp-stat-label { font-size: 15px; color: var(--gp-muted); font-weight: 500; }
.gp-stat-value { font-size: 36px; line-height: 44px; font-weight: 700; margin-top: 12px; letter-spacing: -0.02em; overflow-wrap: anywhere; }
@media (max-width: 1100px) { .gp-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ----- list card ----- */
.gp-card { background: #fff; border: 1px solid var(--gp-line); border-radius: 12px; box-shadow: var(--gp-shadow-md); }
.gp-card.flat { box-shadow: var(--gp-shadow); }
.gp-toolbar { display: flex; align-items: center; gap: 12px; padding: 16px 20px; flex-wrap: wrap; }
.gp-toolbar .grow { flex: 1; }
.gp-toolbar .gp-count { font-size: 15px; color: var(--gp-muted); }

.gp-range {
  display: inline-grid; grid-template-columns: 1fr auto 1fr auto; align-items: center; gap: 8px; height: 44px;
  border: 1px solid var(--gp-input); border-radius: 8px; padding: 0 12px 0 0; background: #fff; min-width: 380px; box-shadow: var(--gp-shadow);
}
.gp-range input { border: 0; outline: 0; font: 15px Inter, sans-serif; color: var(--gp-text); text-align: center; width: 100%; background: none; min-width: 0; }
.gp-range input::placeholder { color: var(--gp-faint); }
.gp-range > .ico { color: var(--gp-faint); }

.gp-search { position: relative; display: inline-flex; align-items: center; }
.gp-search .ico { position: absolute; left: 14px; color: var(--gp-dim); pointer-events: none; }
.gp-search input {
  height: 44px; border: 1px solid var(--gp-input); border-radius: 8px; padding: 0 14px 0 40px; width: 300px;
  font: 15px Inter, sans-serif; color: var(--gp-text); box-shadow: var(--gp-shadow); background: #fff;
}
.gp-search input:focus, .gp-input:focus, .gp-range:focus-within { outline: 0; border-color: #84adff; box-shadow: 0 0 0 4px #d1e0ff; }
.gp-search.sm input { height: 36px; width: 210px; font-size: 14px; }

.gp-table-wrap { overflow-x: auto; }
.gp-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.gp-table th {
  text-align: left; font-weight: 500; font-size: 13.5px; color: var(--gp-muted); background: var(--gp-bg);
  padding: 14px 24px; border-top: 1px solid var(--gp-line); border-bottom: 1px solid var(--gp-line); white-space: nowrap;
}
.gp-table th.sort { cursor: pointer; user-select: none; }
.gp-table th.sort .ico { vertical-align: -3px; margin-left: 6px; color: var(--gp-faint); }
.gp-table td { padding: 16px 24px; border-bottom: 1px solid var(--gp-line); color: var(--gp-muted); vertical-align: middle; white-space: nowrap; }
.gp-table td.wrap { white-space: normal; min-width: 220px; }
.gp-table tr:last-child td { border-bottom: 0; }
.gp-table td.strong, .gp-table td .strong { color: var(--gp-text); font-weight: 500; }
.gp-table td.num, .gp-table th.num { text-align: right; }
.gp-table td.act { width: 56px; text-align: right; padding-right: 16px; }
.gp-table td.chk, .gp-table th.chk { width: 52px; padding-right: 0; }
.gp-table tbody tr.click { cursor: pointer; }
.gp-table tbody tr.click:hover td { background: #fcfcfd; }
.gp-table input[type=checkbox] { width: 18px; height: 18px; accent-color: var(--gp-blue); }
/* GHL's bordered "classic" tables (Collections, Inventory, Abandoned checkouts). */
.gp-table.grid th { background: var(--gp-bg); color: var(--gp-text); font-size: 15px; font-weight: 600; border: 1px solid var(--gp-line); padding: 12px 16px; }
.gp-table.grid td { border: 1px solid var(--gp-line); padding: 12px 16px; color: var(--gp-text); }
.gp-table.grid th .ico { float: right; color: var(--gp-dim); }

.gp-name { display: flex; align-items: center; gap: 16px; color: var(--gp-text); font-weight: 500; }
.gp-name .sub { display: block; font-weight: 400; color: var(--gp-muted); margin-top: 2px; }
.gp-roundico { width: 40px; height: 40px; border-radius: 50%; background: #f2f4f7; display: grid; place-items: center; color: var(--gp-dim); flex: none; border: 1px solid #f2f4f7; }
.gp-thumb { width: 40px; height: 40px; border-radius: 50%; background: #f2f4f7 center/cover; display: grid; place-items: center; color: var(--gp-dim); flex: none; }
.gp-thumb.sq { border-radius: 6px; width: 32px; height: 32px; }
.gp-avatar {
  width: 40px; height: 40px; border-radius: 50%; display: inline-grid; place-items: center; font-size: 15px; font-weight: 500; flex: none;
}
.gp-person { display: flex; align-items: center; gap: 12px; color: var(--gp-muted); min-width: 0; }
.gp-person span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 220px; }
.gp-amount { color: var(--gp-text); font-weight: 600; white-space: nowrap; }
.gp-amount.green { color: var(--gp-green); font-weight: 500; }

.gp-pill {
  display: inline-flex; align-items: center; height: 24px; padding: 0 9px; border-radius: 999px; font-size: 13px; font-weight: 500;
  border: 1px solid; white-space: nowrap;
}
.gp-pill.grey { color: var(--gp-text-2); background: #f9fafb; border-color: #eaecf0; }
.gp-pill.red { color: #b42318; background: #fef3f2; border-color: #fecdca; }
.gp-pill.green { color: #067647; background: #ecfdf3; border-color: #abefc6; }
.gp-pill.blue { color: #175cd3; background: #eff8ff; border-color: #b2ddff; }
.gp-pill.amber { color: #b54708; background: #fffaeb; border-color: #fedf89; }
.gp-pill.purple { color: #5925dc; background: #f4f3ff; border-color: #d9d6fe; }

.gp-empty { padding: 56px 20px 64px; text-align: center; }
.gp-empty-ico { width: 56px; height: 56px; border-radius: 50%; background: var(--gp-blue-100); border: 8px solid var(--gp-blue-50); display: inline-grid; place-items: center; color: var(--gp-blue); box-sizing: content-box; }
.gp-empty h3 { font-size: 18px; font-weight: 500; margin: 16px 0 0; color: var(--gp-text); }
.gp-empty p { font-size: 14px; color: var(--gp-muted); margin: 6px auto 0; max-width: 420px; line-height: 1.5; }
.gp-empty .gp-btn { margin-top: 16px; }
.gp-empty img, .gp-empty svg.art { display: block; margin: 0 auto; }

.gp-pager { display: flex; align-items: center; justify-content: flex-end; gap: 12px; padding: 16px 20px; border-top: 1px solid var(--gp-line); flex-wrap: wrap; }
.gp-pager .pg { min-width: 36px; height: 36px; border-radius: 8px; border: 1px solid var(--gp-input); background: #fff; color: var(--gp-text-2); font: 500 14px Inter, sans-serif; cursor: pointer; padding: 0 10px; }
.gp-pager .pg.on { border-color: var(--gp-blue); color: var(--gp-blue); }
.gp-pager .pg:disabled { color: #d0d5dd; cursor: not-allowed; }
.gp-pager .lbl { font-size: 14px; color: var(--gp-text-2); }
.gp-pager select { height: 36px; border: 1px solid var(--gp-input); border-radius: 8px; padding: 0 8px; font: 14px Inter, sans-serif; color: var(--gp-text-2); background: #fff; }

/* Tabs inside a page (Documents' Draft/Waiting…, Reviews' Pending…). */
.gp-tabs { display: flex; gap: 32px; border-bottom: 1px solid var(--gp-line); margin-bottom: 32px; overflow-x: auto; }
.gp-tabs button { border: 0; background: none; padding: 0 2px 12px; font: 500 16px Inter, sans-serif; color: var(--gp-text-2); cursor: pointer; position: relative; display: inline-flex; gap: 8px; align-items: center; white-space: nowrap; }
.gp-tabs button.on { color: var(--gp-blue); }
.gp-tabs button.on::after { content: ''; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: var(--gp-blue); }
.gp-tabs .cnt { min-width: 26px; height: 26px; border-radius: 50%; border: 1px solid var(--gp-line); display: inline-grid; place-items: center; font-size: 13px; color: var(--gp-text-2); background: #fff; }
.gp-tabs.bold button { font-weight: 600; }
/* Segmented control (Coupons' All · Active · Scheduled · Expired). */
.gp-seg { display: inline-flex; border: 1px solid var(--gp-input); border-radius: 8px; overflow: hidden; box-shadow: var(--gp-shadow); }
.gp-seg button { border: 0; border-right: 1px solid var(--gp-input); background: #fff; padding: 0 20px; height: 44px; font: 500 15px Inter, sans-serif; color: var(--gp-text-2); cursor: pointer; }
.gp-seg button:last-child { border-right: 0; }
.gp-seg button.on { background: var(--gp-bg); color: var(--gp-text); }

/* ----- forms ----- */
.gp-form { display: grid; gap: 20px; }
.gp-field { display: grid; gap: 6px; min-width: 0; }
.gp-field > label, .gp-label { font-size: 14px; font-weight: 500; color: var(--gp-text-2); display: flex; align-items: center; gap: 4px; }
.gp-label .req, .gp-field > label .req { color: var(--gp-red); }
.gp-label .ico { color: var(--gp-faint); }
.gp-hint { font-size: 14px; color: var(--gp-muted); line-height: 1.45; }
.gp-input, .gp-field input:not([type=checkbox]):not([type=radio]), .gp-field select, .gp-field textarea {
  width: 100%; height: 44px; border: 1px solid var(--gp-input); border-radius: 8px; padding: 0 14px; font: 15px Inter, sans-serif;
  color: var(--gp-text); background: #fff; box-shadow: var(--gp-shadow);
}
.gp-field textarea { height: auto; padding: 10px 14px; resize: vertical; min-height: 120px; line-height: 1.5; }
.gp-field input:focus, .gp-field select:focus, .gp-field textarea:focus { outline: 0; border-color: #84adff; box-shadow: 0 0 0 4px #d1e0ff; }
.gp-row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
@media (max-width: 860px) { .gp-row2 { grid-template-columns: 1fr; } }
.gp-check { display: flex; align-items: center; gap: 10px; font-size: 15px; color: var(--gp-text-2); cursor: pointer; }
.gp-check input { width: 18px; height: 18px; accent-color: var(--gp-blue); margin: 0; flex: none; }
.gp-radio { display: flex; align-items: flex-start; gap: 8px; font-size: 15px; color: var(--gp-text-2); cursor: pointer; }
.gp-radio input { width: 18px; height: 18px; accent-color: var(--gp-blue); margin: 2px 0 0; flex: none; }
.gp-switch { position: relative; display: inline-block; width: 44px; height: 24px; flex: none; }
.gp-switch input { opacity: 0; width: 0; height: 0; position: absolute; }
.gp-switch span { position: absolute; inset: 0; border-radius: 12px; background: #f2f4f7; cursor: pointer; transition: .15s; box-shadow: inset 0 0 0 1px #eaecf0; }
.gp-switch span::before { content: ''; position: absolute; width: 20px; height: 20px; left: 2px; top: 2px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(16,24,40,.1), 0 1px 2px rgba(16,24,40,.06); transition: .15s; }
.gp-switch input:checked + span { background: var(--gp-blue); box-shadow: none; }
.gp-switch input:checked + span::before { transform: translateX(20px); }
.gp-switch input:disabled + span { opacity: .5; cursor: not-allowed; }
.gp-counter { position: relative; }
.gp-counter input { padding-right: 70px !important; }
.gp-counter em { position: absolute; right: 14px; top: 50%; transform: translateY(-50%); font-style: normal; font-size: 14px; color: var(--gp-dim); }
.gp-section-title { font-size: 18px; font-weight: 600; color: var(--gp-text); margin: 0 0 4px; }
.gp-panel { background: #fff; border: 1px solid var(--gp-line); border-radius: 12px; box-shadow: var(--gp-shadow); padding: 32px; }
.gp-panel + .gp-panel { margin-top: 32px; }
.gp-footer-bar { position: sticky; bottom: 0; background: #fff; border-top: 1px solid var(--gp-line); padding: 14px 24px; display: flex; gap: 12px; align-items: center; z-index: 5; }
.gp-footer-bar .grow { flex: 1; }
.gp-inline { display: flex; align-items: center; gap: 0; }
.gp-inline > * { border-radius: 0 !important; }
.gp-inline > *:first-child { border-top-left-radius: 8px !important; border-bottom-left-radius: 8px !important; }
.gp-inline > *:last-child { border-top-right-radius: 8px !important; border-bottom-right-radius: 8px !important; }
.gp-inline > * + * { margin-left: -1px; }

/* ----- modal ----- */
.gp-modal-back { position: fixed; inset: 0; background: rgba(52, 64, 84, .7); backdrop-filter: blur(8px); z-index: 900; display: grid; place-items: start center; overflow-y: auto; padding: 0 16px; }
.gp-modal { background: #fff; border-radius: 0 0 12px 12px; width: min(1140px, 100%); box-shadow: 0 20px 24px -4px rgba(16,24,40,.08); display: flex; flex-direction: column; max-height: 100vh; }
.gp-modal.rounded { border-radius: 12px; margin: 48px 0; max-height: calc(100vh - 96px); }
.gp-modal-head { display: flex; align-items: center; padding: 24px 32px 20px; border-bottom: 1px solid var(--gp-line); margin: 0 0; }
.gp-modal-head h2 { font-size: 20px; font-weight: 500; margin: 0; flex: 1; }
.gp-modal-body { padding: 28px 32px; overflow-y: auto; flex: 1; }
.gp-modal-foot { display: flex; gap: 12px; justify-content: flex-end; padding: 16px 32px 24px; border-top: 1px solid var(--gp-line); align-items: center; }
.gp-modal-foot .grow { flex: 1; }

.gp-lines { border: 1px solid var(--gp-line); border-radius: 12px; overflow: hidden; }
.gp-lines-title { font-size: 18px; font-weight: 500; padding: 22px 20px; }
.gp-lines table { width: 100%; border-collapse: collapse; }
.gp-lines th { background: var(--gp-bg); text-align: left; font-size: 14px; font-weight: 500; color: var(--gp-text-2); padding: 20px; }
.gp-lines td { padding: 14px 10px; vertical-align: middle; }
.gp-lines td:first-child { padding-left: 10px; }
.gp-money { display: flex; align-items: center; border: 1px solid var(--gp-input); border-radius: 8px; height: 44px; padding: 0 12px; gap: 10px; box-shadow: var(--gp-shadow); background: #fff; }
.gp-money span { color: var(--gp-text-2); font-size: 15px; }
.gp-money input { border: 0 !important; box-shadow: none !important; padding: 0 !important; height: 40px !important; width: 100%; font: 15px Inter, sans-serif; outline: 0; }

/* ----- settings layout ----- */
.gp-settings { display: grid; grid-template-columns: 420px 1fr; gap: 48px; align-items: start; }
.gp-settings-nav { display: grid; gap: 4px; padding-top: 8px; }
.gp-settings-nav button {
  display: flex; align-items: center; justify-content: space-between; width: 100%; border: 0; background: none; text-align: left;
  padding: 18px 32px; border-radius: 8px; font: 500 16px Inter, sans-serif; color: var(--gp-text-2); cursor: pointer;
}
.gp-settings-nav button.child { padding-left: 64px; }
.gp-settings-nav button.child2 { padding-left: 96px; }
.gp-settings-nav button:hover { background: #f2f4f7; }
.gp-settings-nav button.on { background: #e5edff; color: var(--gp-blue); }
@media (max-width: 1200px) { .gp-settings { grid-template-columns: 280px 1fr; gap: 24px; } .gp-settings-nav button { padding: 14px 18px; } .gp-settings-nav button.child { padding-left: 36px; } .gp-settings-nav button.child2 { padding-left: 54px; } }
@media (max-width: 860px) { .gp-settings { grid-template-columns: 1fr; } }
.gp-choice { border: 1px solid var(--gp-line); border-radius: 12px; padding: 24px 22px; display: grid; grid-template-columns: auto 1fr; gap: 6px 22px; cursor: pointer; }
.gp-choice + .gp-choice { margin-top: 12px; }
.gp-choice.on { border: 2px solid var(--gp-blue); padding: 23px 21px; }
.gp-choice input { width: 20px; height: 20px; accent-color: var(--gp-blue); margin: 0; grid-row: span 2; }
.gp-choice b { font-weight: 500; font-size: 16px; color: var(--gp-text); }
.gp-choice.on b { color: var(--gp-blue); }
.gp-choice span { font-size: 14px; color: var(--gp-muted); }

/* ----- payment link editor ----- */
.gp-editor { display: grid; grid-template-columns: 560px 1fr; min-height: calc(100vh - 140px); }
.gp-editor-left { background: #fff; padding: 32px 52px; border-right: 1px solid var(--gp-line); display: grid; gap: 26px; align-content: start; }
.gp-editor-right { padding: 52px 40px; }
.gp-editor-top { display: flex; align-items: center; gap: 12px; background: #fff; border-bottom: 1px solid var(--gp-line); padding: 14px 40px; }
.gp-editor-top .gp-linkname { margin: 0 auto; border: 1px solid var(--gp-input); border-radius: 8px; height: 44px; width: 240px; text-align: center; font: 16px Inter, sans-serif; }
@media (max-width: 1100px) { .gp-editor { grid-template-columns: 1fr; } .gp-editor-left { padding: 24px; } }
.gp-checkout { background: #fff; border-radius: 4px; box-shadow: 0 8px 24px rgba(16,24,40,.08); display: grid; grid-template-columns: 1fr 1fr; max-width: 1400px; }
.gp-checkout-l { padding: 44px 40px; border-right: 1px solid var(--gp-line); display: flex; flex-direction: column; min-height: 410px; }
.gp-checkout-r { padding: 36px 32px; display: grid; gap: 22px; align-content: start; }
.gp-checkout h3 { font-size: 22px; font-weight: 500; margin: 0 0 22px; padding-bottom: 22px; border-bottom: 2px solid var(--gp-line); }
.gp-checkout .ln { display: flex; justify-content: space-between; padding: 22px 0; font-size: 16px; border-bottom: 2px solid var(--gp-line); }
.gp-checkout .ln.total { border: 0; font-size: 16px; align-items: center; }
.gp-checkout .ln.total b { font-size: 26px; }
.gp-checkout .powered { margin-top: auto; font-size: 14px; }
.gp-checkout .pay { height: 44px; border: 0; border-radius: 6px; color: #fff; font: 500 16px Inter, sans-serif; margin-top: 60px; }
@media (max-width: 1100px) { .gp-checkout { grid-template-columns: 1fr; } }

/* ----- gift card stepper ----- */
.gp-steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; padding: 32px 0 28px; background: #fff; }
.gp-step { text-align: center; position: relative; padding: 0 12px; }
.gp-step::before { content: ''; position: absolute; top: 17px; left: 0; right: 0; height: 2px; background: var(--gp-line); }
.gp-step.done::before, .gp-step.on::before { background: linear-gradient(90deg, var(--gp-blue) 50%, var(--gp-line) 50%); }
.gp-step.done::before { background: var(--gp-blue); }
.gp-step .dot { position: relative; width: 36px; height: 36px; border-radius: 50%; border: 2px solid var(--gp-line); background: #fff; display: inline-grid; place-items: center; font-size: 16px; color: var(--gp-dim); }
.gp-step.on .dot, .gp-step.done .dot { background: var(--gp-blue); border-color: var(--gp-blue); color: #fff; }
.gp-step b { display: block; font-size: 18px; font-weight: 500; color: var(--gp-faint); margin-top: 10px; }
.gp-step span { display: block; font-size: 14px; color: var(--gp-dim); margin-top: 6px; }
.gp-step.on b, .gp-step.done b { color: var(--gp-text); }
.gp-gc-art { width: 320px; height: 180px; border-radius: 14px; display: flex; flex-direction: column; justify-content: space-between; padding: 18px; color: #fff; box-shadow: var(--gp-shadow-md); background: linear-gradient(135deg, #155eef, #7a5af8); background-size: cover; }
.gp-gc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
.gp-gc-pick { border: 2px solid transparent; border-radius: 16px; padding: 4px; cursor: pointer; background: none; }
.gp-gc-pick.on { border-color: var(--gp-blue); }
.gp-gc-pick .gp-gc-art { width: 100%; height: 120px; }
.gp-chips { display: flex; gap: 10px; flex-wrap: wrap; }
.gp-chips button { height: 38px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--gp-input); background: #fff; font: 500 14px Inter, sans-serif; color: var(--gp-text-2); cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }
.gp-chips button.on { border-color: var(--gp-blue); background: var(--gp-blue-50); color: var(--gp-blue); }

/* ----- rich text (terms) ----- */
.gp-rte { border: 1px solid var(--gp-input); border-radius: 8px; overflow: hidden; background: #fff; }
.gp-rte-bar { display: flex; flex-wrap: wrap; gap: 2px; padding: 8px 10px; border-bottom: 1px solid var(--gp-line); align-items: center; }
.gp-rte-bar button { border: 0; background: none; width: 34px; height: 34px; border-radius: 6px; color: var(--gp-text-2); cursor: pointer; display: grid; place-items: center; }
.gp-rte-bar button:hover { background: var(--gp-bg); }
.gp-rte-bar .sep { width: 1px; height: 22px; background: var(--gp-line); margin: 0 6px; }
.gp-rte-bar select { height: 34px; border: 1px solid var(--gp-input); border-radius: 6px; font: 14px Inter, sans-serif; padding: 0 8px; color: var(--gp-text-2); }
.gp-rte-body { min-height: 180px; padding: 14px 16px; font-size: 15px; outline: 0; line-height: 1.6; }
.gp-rte-body:empty::before { content: attr(data-placeholder); color: var(--gp-faint); }

/* ----- detail pages (kept in the new look) ----- */
.gp-detail { background: #fff; border: 1px solid var(--gp-line); border-radius: 12px; box-shadow: var(--gp-shadow); padding: 28px 32px; }
.gp-detail h2 { font-size: 20px; font-weight: 600; margin: 0; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.gp-detail h4 { font-size: 16px; font-weight: 600; margin: 28px 0 12px; }
.gp-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 18px 28px; margin: 22px 0; }
.gp-facts .k { font-size: 13px; color: var(--gp-dim); }
.gp-facts .v { font-size: 15px; color: var(--gp-text); margin-top: 4px; overflow-wrap: anywhere; }
.gp-acts { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 22px; }
.gp-totals { margin-left: auto; max-width: 340px; margin-top: 16px; font-size: 14px; }
.gp-totals .row { display: flex; justify-content: space-between; padding: 6px 0; color: var(--gp-muted); }
.gp-totals .row.grand { color: var(--gp-text); font-weight: 600; font-size: 16px; border-top: 1px solid var(--gp-line); padding-top: 10px; margin-top: 4px; }
.gp-totals .row.due { color: var(--gp-red); font-weight: 600; }
.gp-detail .gp-table td, .gp-detail .gp-table th { padding: 12px 16px; }
.gp-stars { display: inline-flex; gap: 2px; color: #fdb022; }

@media (max-width: 760px) {
  .gp-page { padding: 20px 16px 40px; }
  .gp-head h1 { font-size: 24px; line-height: 32px; }
  .gp-range { min-width: 0; width: 100%; }
  .gp-search input { width: 100%; }
  .gp-search { flex: 1; }
  .gp-stats { grid-template-columns: 1fr; }
}

/* ----- Invoices & Estimates → Settings ----- */
.gp-inv-back { font-size: 18px; font-weight: 500; padding: 0; margin-bottom: 26px; }
.gp-inv-back .ico { width: 22px; height: 22px; }
.gp-inv-head { margin-bottom: 36px; }
.gp-inv-head h1 { font-size: 22px; font-weight: 500; color: var(--gp-muted); margin: 0; }
.gp-inv-head p { margin: 6px 0 0; font-size: 16px; color: var(--gp-dim); }
.gp-inv-panel { padding: 32px; }
.gp-inv-panel-title { font-size: 22px; font-weight: 500; margin: 0 0 24px; color: var(--gp-text); }
.gp-inv-foot { display: flex; justify-content: flex-end; gap: 12px; border-top: 1px solid var(--gp-line); margin-top: 32px; padding-top: 32px; }
.gp-inv-foot .gp-btn { min-width: 166px; height: 52px; font-size: 16px; }
/* A setting with its title and description on the left and a switch on the right. */
.gp-inv-toggle { display: grid; grid-template-columns: 1fr auto; gap: 8px 24px; padding: 28px 0; border-bottom: 1px solid var(--gp-line); }
.gp-inv-toggle:last-child { border-bottom: 0; }
.gp-inv-toggle h3 { font-size: 18px; font-weight: 500; margin: 0; color: var(--gp-text); }
.gp-inv-toggle p { margin: 0; font-size: 15px; color: var(--gp-muted); max-width: 860px; line-height: 1.6; grid-column: 1; }
.gp-inv-toggle .gp-switch { grid-row: 1; grid-column: 2; }
.gp-inv-toggle .gp-inv-more { grid-column: 1 / -1; }
.gp-link-right { color: var(--gp-blue); text-decoration: underline; font-size: 15px; cursor: pointer; background: none; border: 0; padding: 0; }
@media (max-width: 600px) {
  .gp-inv-panel, .gp-panel { padding: 20px 16px; }
  .gp-inv-foot .gp-btn { min-width: 0; flex: 1; }
  .gp-settings-nav button { padding: 12px 14px; }
}

/* ===== Products › Collections · Create / Edit Collection (payments-collection.js) ===== */
.gp-col-page { padding: 12px 12px 32px; }
.gp-col { padding: 20px; gap: 18px; }
.gp-col-alert { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border: 1px solid #fda29b; background: #fef3f2; color: #b42318; border-radius: 8px; font-size: 14px; }
.gp-col-alert strong { display: block; font-weight: 600; margin-bottom: 2px; }
.gp-col-err { font-size: 12.5px; color: var(--gp-red); min-height: 0; }
.gp-col-err:empty { display: none; }
.gp-col-image { height: 150px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; border: 1px solid var(--gp-input); border-radius: 8px; background: #fff; cursor: pointer; padding: 0 24px; text-align: center; }
.gp-col-image:hover { border-color: var(--gp-faint); }
.gp-col-image:focus-visible { outline: 0; border-color: #84adff; box-shadow: 0 0 0 4px #d1e0ff; }
.gp-col-image-ico { width: 36px; height: 36px; border-radius: 50%; background: #f2f4f7; border: 1px solid #f9fafb; display: inline-grid; place-items: center; color: var(--gp-text-2); box-sizing: border-box; }
.gp-col-image-cta { font-size: 15px; font-weight: 600; color: var(--gp-blue); }
.gp-col-image-hint { font-size: 13px; color: var(--gp-dim); }
.gp-col-image-preview { position: relative; }
.gp-col-image-preview img { max-height: 94px; max-width: 100%; display: block; }
.gp-col-image-remove { position: absolute; top: -8px; right: -8px; width: 24px; height: 24px; border-radius: 50%; border: 1px solid #fff; background: #fee4e2; color: var(--gp-text-2); display: grid; place-items: center; cursor: pointer; padding: 0; box-shadow: var(--gp-shadow); }
.gp-col-types { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 760px) { .gp-col-types { grid-template-columns: 1fr; } }
.gp-col-type { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 12px 14px; border: 1px solid var(--gp-line); border-radius: 8px; cursor: pointer; background: #fff; }
.gp-col-type.on { border-color: var(--gp-blue); box-shadow: 0 0 0 1px var(--gp-blue); }
.gp-col-type:focus-within { box-shadow: 0 0 0 4px #d1e0ff; }
.gp-col-type input { width: 18px; height: 18px; accent-color: var(--gp-blue); margin: 2px 0 0; flex: none; }
.gp-col-type-text { display: grid; gap: 4px; }
.gp-col-type-title { font-size: 15px; color: var(--gp-text-2); }
.gp-col-type-sub { font-size: 14px; color: var(--gp-dim); line-height: 1.45; }
.gp-col-body > div { display: grid; gap: 14px; }
.gp-col-search { position: relative; }
.gp-col-results { position: absolute; left: 0; right: 0; top: calc(100% + 4px); z-index: 50; background: #fff; border: 1px solid var(--gp-line); border-radius: 10px; box-shadow: var(--gp-shadow-md); max-height: 288px; overflow-y: auto; }
.gp-col-result { display: flex; align-items: center; gap: 10px; padding: 10px; border-bottom: 1px solid var(--gp-line); cursor: pointer; font-size: 14px; font-weight: 500; color: var(--gp-text); }
.gp-col-result:last-child { border-bottom: 0; }
.gp-col-result:hover { background: var(--gp-bg); }
.gp-col-result input { width: 16px; height: 16px; accent-color: var(--gp-blue); margin: 0; flex: none; }
.gp-col-result .gp-thumb, .gp-col-products-list .gp-thumb { width: 32px; height: 32px; }
.gp-col-products { background: var(--gp-bg); border-radius: 8px; padding: 8px; }
.gp-col-products.empty { height: 110px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 4px; padding: 0 16px; }
.gp-col-empty-ico { width: 34px; height: 34px; border-radius: 50%; background: var(--gp-blue-100); color: var(--gp-blue); display: grid; place-items: center; margin-bottom: 4px; }
.gp-col-empty-title { font-size: 15px; font-weight: 500; color: var(--gp-text); }
.gp-col-empty-sub { font-size: 14px; color: var(--gp-dim); }
.gp-col-products-head { padding: 0 8px 8px; font-weight: 500; color: var(--gp-text-2); font-size: 14px; }
.gp-col-products-list { list-style: none; margin: 0; padding: 8px; max-height: 320px; overflow-y: auto; }
.gp-col-products-list li { display: flex; align-items: center; gap: 12px; height: 48px; padding: 0 8px; border: 1px solid var(--gp-line); border-radius: 6px; background: #fff; margin-bottom: 10px; font-size: 14px; }
.gp-col-pname { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gp-col-more { display: flex; justify-content: center; padding: 4px 0 8px; }
.gp-col-conditions > .gp-field { gap: 4px; }
.gp-col-help { margin: 0; font-size: 12.5px; color: var(--gp-muted); }
.gp-col-match { display: flex; align-items: center; gap: 24px; margin-top: 6px; }
.gp-col-rows { display: grid; gap: 8px; }
.gp-col-row { display: flex; gap: 8px; align-items: center; }
.gp-col-row > select, .gp-col-row > input { flex: 1; min-width: 0; height: 40px; }
.gp-col-row.bad > input { border-color: #f97066; box-shadow: 0 0 0 1px #f97066; }
.gp-iconbtn.danger { color: var(--gp-red); border: 1px solid #fecdca; border-radius: 8px; width: 40px; height: 40px; }
.gp-col-conditions > .gp-btn.link { justify-self: start; }
.gp-counter-area textarea { min-height: 0; padding-bottom: 28px; }
.gp-counter-area em { top: auto; bottom: 10px; transform: none; }
.gp-col-handle { display: flex; align-items: center; border: 1px solid var(--gp-input); border-radius: 8px; background: #fff; box-shadow: var(--gp-shadow); padding-left: 14px; }
.gp-col-handle:focus-within { border-color: #84adff; box-shadow: 0 0 0 4px #d1e0ff; }
.gp-col-prefix { font-size: 14px; color: var(--gp-dim); margin-right: 8px; white-space: nowrap; }
.gp-col-handle input.gp-input { border: 0; box-shadow: none; padding-left: 0; }
.gp-col-handle input.gp-input:focus { box-shadow: none; }
.gp-col-actions { display: flex; gap: 8px; justify-content: center; }
.gp-col-link, .gp-col-cond { border: 0; background: none; padding: 0; font: inherit; color: var(--gp-muted); cursor: pointer; text-align: left; }
.gp-col-link:hover, .gp-col-cond:hover { color: var(--gp-blue); }
.gp-col-cond.none { color: var(--gp-faint); }
.gp-pricing-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.gp-pricing-head .gp-btn.link { font-size: 14px; }
.gp-btn.loading { pointer-events: none; opacity: .7; }

/* ===== Products › Inventory (payments-inventory.js) ===== */
.gp-center { display: flex; justify-content: center; align-items: center; text-align: center; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.gp-inv-card .gp-toolbar { padding: 10px 12px; }
.gp-inv-card .gp-table td { padding-top: 8px; padding-bottom: 8px; }
.gp-inv-card .gp-search input { padding-right: 40px; }
.gp-inv-filter { position: absolute; right: 4px; color: var(--gp-faint); }
.gp-inv-filter.on { color: var(--gp-blue); }
.gp-inv-selected, .gp-inv-changes { font-size: 14px; color: var(--gp-text-2); }
.gp-inv-name { display: flex; align-items: center; gap: 12px; max-width: 400px; min-width: 0; }
.gp-inv-name-text { display: grid; min-width: 0; }
.gp-inv-product { border: 0; background: none; padding: 0; text-align: left; font: 500 15px Inter, sans-serif; color: var(--gp-text); cursor: pointer; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gp-inv-product:hover { color: var(--gp-blue); }
.gp-inv-variant { font-size: 15px; color: var(--gp-text-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gp-input.gp-inv-qty { width: 200px; max-width: 100%; height: 46px; }
.gp-input.invalid, .gp-input.gp-inv-qty.invalid { border-color: #f97066; box-shadow: 0 0 0 1px #f97066; }
.gp-pop { position: fixed; z-index: 1000; background: #fff; border: 1px solid var(--gp-line); border-radius: 10px; box-shadow: var(--gp-shadow-md); max-height: calc(100vh - 40px); overflow-y: auto; }
.gp-pop-title { padding: 12px 14px; font-weight: 600; font-size: 14px; color: var(--gp-text); border-bottom: 1px solid var(--gp-line); }
.gp-pop-foot { display: flex; justify-content: flex-end; gap: 12px; padding: 10px 14px; border-top: 1px solid var(--gp-line); }
.gp-btn.link.muted { color: var(--gp-dim); }
.gp-acc { border-bottom: 1px solid var(--gp-line); }
.gp-acc-head { display: flex; width: 100%; align-items: center; justify-content: space-between; border: 0; background: none; padding: 12px 14px; font: 500 14px Inter, sans-serif; color: var(--gp-text-2); cursor: pointer; }
.gp-acc-body { padding: 0 14px 12px; }
.gp-acc-body select, .gp-acc-body input.gp-input { height: 36px; font-size: 14px; }
.gp-inv-cols { display: grid; gap: 8px; max-height: 180px; overflow-y: auto; }
.gp-inv-cols .gp-check { font-size: 14px; }
.gp-inv-range { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.gp-inv-range-err { font-size: 12px; color: var(--gp-red); margin-top: 4px; }
.gp-inv-range-err:empty { display: none; }
.gp-inv-modal { display: grid; gap: 14px; }
.gp-inv-modal > .gp-hint { margin: -6px 0 2px; }
.gp-check.off { opacity: .5; }
.gp-inv-qrow { display: flex; align-items: flex-end; gap: 10px; flex-wrap: wrap; }
.gp-inv-modes { display: inline-flex; border: 1px solid var(--gp-input); border-radius: 8px; overflow: hidden; }
.gp-inv-mode { display: inline-flex; align-items: center; gap: 6px; border: 0; background: #fff; padding: 0 14px; height: 40px; font: 500 14px Inter, sans-serif; color: var(--gp-text-2); cursor: pointer; }
.gp-inv-mode + .gp-inv-mode { border-left: 1px solid var(--gp-input); }
.gp-inv-mode.on { background: var(--gp-blue-50); color: var(--gp-blue); }
.gp-inv-qfield { display: grid; gap: 6px; flex: 1; min-width: 160px; }
.gp-inv-qfield label { font-size: 14px; font-weight: 500; color: var(--gp-text-2); }
.gp-inv-qfield input { text-align: right; height: 40px; }
.gp-inv-preview { display: grid; gap: 8px; max-height: 192px; overflow-y: auto; background: var(--gp-bg); padding: 8px; border-radius: 10px; }
.gp-inv-preview-head { font-size: 14px; font-weight: 600; }
.gp-inv-preview-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; font-size: 14px; }
.gp-inv-preview-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gp-inv-preview-val { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; color: var(--gp-text-2); }
.gp-inv-tag { background: var(--gp-blue-50); color: var(--gp-blue); border-radius: 999px; padding: 1px 10px; font-weight: 600; }
.gp-hist { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 24px; align-items: start; }
@media (max-width: 760px) { .gp-hist { grid-template-columns: 1fr; } }
.gp-hist-left { display: grid; gap: 12px; }
.gp-hist-title { display: flex; align-items: center; gap: 6px; font-size: 18px; font-weight: 500; }
.gp-hist-head { font-size: 16px; font-weight: 600; margin: 0 0 12px; color: var(--gp-text); }

/* ===== Products › Reviews (payments-reviews.js) ===== */
.gp-rev-page { max-width: 1280px; margin: 0 auto; }
.gp-rev-page .gp-head { margin-bottom: 40px; }
.gp-rev-page .gp-tabs { margin-bottom: 16px; }
.gp-rev-alert { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border: 1px solid #abefc6; background: #ecfdf3; color: #067647; border-radius: 8px; margin-bottom: 16px; font-size: 14px; }
.gp-rev-undo { display: inline-flex; align-items: center; gap: 4px; border: 0; background: none; color: inherit; font: 600 14px Inter, sans-serif; cursor: pointer; text-decoration: underline; }
.gp-rev-open { cursor: pointer; }
.gp-rev-name { font-weight: 600; color: var(--gp-text); }
.gp-rev-email { font-weight: 500; color: var(--gp-muted); font-size: 14px; }
.gp-rev-details { max-width: 240px; }
.gp-rev-headline { font-weight: 600; color: var(--gp-text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gp-rev-comment { color: var(--gp-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gp-rev-time { color: var(--gp-muted); font-size: 14px; }
.gp-rev-rating { display: inline-flex; align-items: center; gap: 4px; }
.gp-rev-rating svg, .gp-rev-stars svg { color: #fdb022; fill: #fdb022; }
.gp-rev-product { display: flex; align-items: center; gap: 10px; min-width: 0; }
.gp-rev-product .gp-thumb { width: 32px; height: 32px; }
.gp-rev-pname { font-weight: 600; color: var(--gp-text); }
.gp-rev-plist { display: grid; gap: 8px; max-height: 180px; overflow-y: auto; margin-top: 6px; }
.gp-rev-plist .gp-check { font-size: 14px; }
.gp-rev-filters > .gp-field { padding: 12px 14px 0; }
.gp-rev-filters > .gp-field:last-of-type { padding-bottom: 12px; }
.gp-rev-filters .gp-hint { font-size: 12.5px; }
.gp-drawer-back { position: fixed; inset: 0; z-index: 900; background: rgba(16, 24, 40, .35); display: flex; justify-content: flex-end; }
.gp-drawer { width: min(502px, 100%); height: 100%; background: #fff; box-shadow: var(--gp-shadow-md); display: flex; flex-direction: column; }
.gp-drawer-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; border-bottom: 1px solid var(--gp-line); }
.gp-drawer-head h2 { margin: 0; font-size: 18px; font-weight: 600; }
.gp-drawer-body { padding: 20px; overflow-y: auto; display: grid; gap: 16px; align-content: start; }
.gp-drawer-body hr { border: 0; border-top: 1px solid var(--gp-line); margin: 0; width: 100%; }
.gp-rev-status { display: grid; gap: 8px; margin-bottom: 8px; }
.gp-rev-q { font-weight: 600; color: var(--gp-text); }
.gp-btn.gp-rev-approve { width: 100%; color: #2e90fa; background: #eff8ff; border-color: #b2ddff; }
.gp-rev-two { display: flex; gap: 8px; }
.gp-rev-two .gp-btn { flex: 1; }
.gp-btn.gp-rev-trash { background: #fef3f2; color: #b42318; border-color: #fecdca; }
.gp-rev-row { display: grid; gap: 6px; }
.gp-rev-label { font-weight: 600; color: var(--gp-text-2); font-size: 14px; }
.gp-rev-product.big .gp-iconbtn { margin-left: auto; }
.gp-rev-cust { display: flex; align-items: center; gap: 10px; }
.gp-rev-av { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-weight: 600; font-size: 13px; flex: none; }
.gp-rev-stars { display: flex; align-items: center; gap: 2px; }
.gp-rev-stars span { margin-left: 6px; }
.gp-rev-body { color: var(--gp-text-2); white-space: pre-wrap; }
.gp-rev-reply { display: grid; gap: 8px; }
.gp-rev-reply textarea { height: auto; padding: 10px 14px; }
.gp-rev-reply .gp-btn { width: 40%; min-width: 180px; }
.gp-rev-replytext { display: flex; align-items: flex-start; gap: 16px; white-space: pre-wrap; color: var(--gp-text-2); }

/* ===== Products list (payments-catalog.js) ===== */
.gp-prod-name { display: grid; gap: 2px; }
.gp-prod-link { border: 0; background: none; padding: 0; font: 500 15px Inter, sans-serif; color: var(--gp-text); cursor: pointer; text-align: left; }
.gp-prod-link:hover { color: var(--gp-blue); }
.gp-prod-price { font-size: 14px; color: var(--gp-muted); text-transform: lowercase; }
.gp-btn.gp-dot { position: relative; }
.gp-btn.gp-dot::after { content: ''; position: absolute; top: 6px; right: 6px; width: 7px; height: 7px; border-radius: 50%; background: #33660f; }
.gp-pf { display: grid; gap: 12px; padding: 14px; }
.gp-pf-head { display: flex; align-items: center; justify-content: space-between; }
.gp-pf-sec { font-size: 13px; font-weight: 600; color: var(--gp-dim); text-transform: uppercase; letter-spacing: .03em; }
.gp-pf-cols { display: grid; gap: 8px; max-height: 160px; overflow-y: auto; margin-top: 6px; }
.gp-pf-cols .gp-check, .gp-bulk-cols .gp-check { font-size: 14px; }
.gp-pf .gp-field select, .gp-pf .gp-field input { height: 38px; font-size: 14px; }
.gp-pf .gp-pop-foot { padding: 10px 0 0; }
.gp-bulk-cols { height: 300px; overflow-y: auto; border: 1px solid var(--gp-line); border-radius: 8px; padding: 8px 12px; display: grid; align-content: start; gap: 12px; margin-top: 12px; }
.gp-info-alert { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 8px; background: var(--gp-blue-50); color: #004eeb; font-size: 14px; margin-top: 14px; }
.gp-modal-body .gp-check { margin-top: 12px; }

/* ===== Create / Edit Product and the price page (payments-product-editor.js) ===== */
.pe { background: var(--gp-bg); min-height: 100%; }
.pe-top { position: sticky; top: 0; z-index: 50; display: grid; grid-template-columns: auto 1fr auto; align-items: center; background: #fff; border-bottom: 1px solid var(--gp-line); padding: 8px 12px; }
.pe-back { display: inline-flex; align-items: center; gap: 4px; border: 0; border-right: 1px solid var(--gp-line); background: none; font: 500 16px Inter, sans-serif; color: var(--gp-text-2); padding: 8px 20px 8px 8px; cursor: pointer; }
.pe-title { text-align: center; font-size: 16px; color: var(--gp-text-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 0 12px; }
.pe-top-right { display: flex; gap: 8px; border-left: 1px solid var(--gp-line); padding-left: 12px; }
.pe-grid { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 24px; padding: 24px; max-width: 1400px; }
.pe-nav { position: sticky; top: 76px; align-self: start; display: grid; gap: 6px; }
.pe-nav-title { font-size: 20px; font-weight: 500; margin: 0 0 12px 8px; color: var(--gp-text); }
.pe-nav-item { border: 0; background: none; text-align: left; padding: 12px 16px; border-radius: 6px; font: 15px Inter, sans-serif; color: var(--gp-text-2); cursor: pointer; }
.pe-nav-item:hover { background: #fff; }
.pe-nav-item.on { background: var(--gp-blue-50); color: var(--gp-blue); }
.pe-cards { display: grid; gap: 24px; min-width: 0; max-width: 960px; }
.pe-card { background: #fff; border: 1px solid var(--gp-line); border-radius: 10px; box-shadow: var(--gp-shadow); padding: 24px 28px; display: grid; gap: 18px; scroll-margin-top: 90px; }
.pe-card[hidden] { display: none; }
.pe-card-title { margin: 0; font-size: 20px; font-weight: 500; color: var(--gp-text); }
.pe-hr { border: 0; border-top: 1px solid var(--gp-line); margin: 4px 0; width: 100%; }
.pe-switch-row { display: inline-flex; align-items: center; gap: 10px; font-size: 15px; color: var(--gp-text); cursor: pointer; }
.pe-md { max-width: 560px; }
.pe-half { max-width: 50%; }
.pe-err { font-size: 13px; color: var(--gp-red); }
.pe-err:empty { display: none; }
.pe-err.req-msg { display: none; }
.show-errors .pe-err.req-msg { display: block; }
.pe-note { display: flex; gap: 6px; align-items: center; font-size: 14px; color: var(--gp-text-2); }
.pe-note:empty { display: none; }
.pe-sub { font-weight: 500; color: var(--gp-text-2); }
.pe-sub-title { margin: 0; font-size: 17px; font-weight: 500; }
.pe-dim > label { color: var(--gp-faint); }
.pe-row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 24px; align-items: start; }
.pe-row3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px 24px; align-items: start; }
.pe-row2[hidden] { display: none; }
@media (max-width: 900px) { .pe-grid { grid-template-columns: 1fr; padding: 12px; } .pe-nav { position: static; } .pe-row2, .pe-row3 { grid-template-columns: 1fr; } }
.pe-label { display: grid; gap: 14px; }
.pe-extras { display: grid; gap: 18px; }
.pe-block { display: grid; gap: 8px; }
.pe-block-title { font-size: 16px; font-weight: 500; color: var(--gp-text); }
.pe-block-sub { margin: 0; font-size: 14px; color: var(--gp-muted); }
.pe-small { font-size: 12.5px; }
.pe-link { border: 0; background: none; padding: 0; font: inherit; color: var(--gp-blue); cursor: pointer; }
.pe-link:hover { text-decoration: underline; }
.pe-tax { max-width: 300px; }
.pe-group { display: flex; align-items: stretch; }
.pe-group > .pe-ms { flex: 1; min-width: 0; }
.pe-group > .pe-ms .pe-ms-box { border-top-right-radius: 0; border-bottom-right-radius: 0; }
.pe-group-btn.gp-iconbtn { border: 1px solid var(--gp-input); border-left: 0; border-radius: 0 8px 8px 0; width: 56px; height: auto; min-height: 44px; }
.pe-ms { position: relative; }
.pe-ms-box { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; min-height: 44px; border: 1px solid var(--gp-input); border-radius: 8px; padding: 6px 36px 6px 12px; background: #fff; cursor: pointer; position: relative; box-shadow: var(--gp-shadow); }
.pe-ms-box > svg { position: absolute; right: 12px; color: var(--gp-dim); }
.pe-ms-box:focus-visible { outline: 0; border-color: #84adff; box-shadow: 0 0 0 4px #d1e0ff; }
.pe-ms-ph { color: var(--gp-faint); font-size: 15px; }
.pe-ms-list { position: absolute; left: 0; right: 0; top: calc(100% + 4px); z-index: 60; background: #fff; border: 1px solid var(--gp-line); border-radius: 8px; box-shadow: var(--gp-shadow-md); max-height: 280px; overflow-y: auto; padding: 6px; display: grid; gap: 2px; }
.pe-ms-q { width: 100%; height: 36px; border: 1px solid var(--gp-line); border-radius: 6px; padding: 0 10px; font: 14px Inter, sans-serif; margin-bottom: 4px; }
.pe-ms-opt { display: flex; align-items: center; gap: 8px; padding: 8px; border-radius: 6px; font-size: 14px; cursor: pointer; }
.pe-ms-opt:hover { background: var(--gp-bg); }
.pe-ms-opt.locked { color: var(--gp-faint); cursor: not-allowed; }
.pe-ms-none { padding: 10px; font-size: 14px; color: var(--gp-dim); }
.pe-chip { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 6px; background: #f2f4f7; font-size: 13px; color: var(--gp-text-2); }
.pe-chip-x { border: 0; background: none; padding: 0; display: inline-grid; color: var(--gp-dim); cursor: pointer; }
.pe-cards-radio { display: grid; gap: 12px; }
.pe-radio-card { display: flex; gap: 14px; align-items: flex-start; padding: 16px 18px; border: 1px solid var(--gp-line); border-radius: 10px; cursor: pointer; }
.pe-radio-card.on { border-color: var(--gp-blue); }
.pe-radio-card.on .pe-radio-title { color: var(--gp-blue); }
.pe-radio-card input { width: 18px; height: 18px; accent-color: var(--gp-blue); margin: 2px 0 0; flex: none; }
.pe-radio-text { display: grid; gap: 4px; }
.pe-radio-title { font-size: 16px; font-weight: 500; color: var(--gp-text); }
.pe-radio-sub { font-size: 14.5px; color: var(--gp-muted); line-height: 1.5; }
.pe-toggle { display: inline-flex; align-items: center; gap: 4px; font-weight: 500; justify-self: start; }
.pe-more { display: grid; gap: 14px; }
.pe-more[hidden] { display: none; }
.pe-meta { font-size: 14px; color: var(--gp-muted); }
.pe-rte { border: 1px solid var(--gp-input); border-radius: 8px; background: #fff; }
.pe-rte-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; padding: 8px 10px; border-bottom: 1px solid var(--gp-line); }
.pe-rte-bar button { border: 0; background: none; width: 30px; height: 30px; display: inline-grid; place-items: center; border-radius: 6px; color: var(--gp-text-2); cursor: pointer; }
.pe-rte-bar button:hover { background: var(--gp-bg); }
.pe-rte-sel { height: 32px; border: 1px solid var(--gp-line); border-radius: 6px; font: 14px Inter, sans-serif; padding: 0 6px; background: #fff; color: var(--gp-text-2); }
.pe-rte-sel.w-size { width: 86px; } .pe-rte-sel.w-block { width: 130px; } .pe-rte-sel.w-font { width: 120px; } .pe-rte-sel.w-line { width: 70px; }
.pe-rte-colour { position: relative; width: 30px; height: 30px; display: inline-grid; place-items: center; border-radius: 6px; cursor: pointer; color: var(--gp-text-2); }
.pe-rte-colour input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.pe-rte-body { min-height: 120px; padding: 12px 14px; outline: 0; font-size: 16px; line-height: 1.5; }
.pe-rte-body:empty::before { content: attr(data-placeholder); color: var(--gp-faint); }
.pe-rte-body table { border-collapse: collapse; width: 100%; }
.pe-rte-body td, .pe-rte-body th { border: 1px solid var(--gp-line); padding: 6px 8px; min-width: 60px; }
.pe-media { display: grid; gap: 12px; }
.pe-upload { display: grid; justify-items: center; gap: 8px; padding: 28px 16px; border: 1px solid var(--gp-line); border-radius: 10px; background: #fff; cursor: pointer; font: 15px Inter, sans-serif; color: var(--gp-muted); }
.pe-upload:hover { border-color: var(--gp-faint); }
.pe-upload-ico { width: 44px; height: 44px; border-radius: 50%; background: #f2f4f7; border: 6px solid #f9fafb; display: grid; place-items: center; color: var(--gp-text-2); box-sizing: content-box; }
.pe-upload-hint { font-size: 14px; color: var(--gp-dim); }
.pe-media-head { display: flex; align-items: center; gap: 10px; font-size: 14px; }
.pe-media-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 12px; }
.pe-tile { position: relative; aspect-ratio: 1; border: 1px solid var(--gp-line); border-radius: 8px; overflow: hidden; background: #fff; padding: 0; }
.pe-tile.first { grid-column: span 2; grid-row: span 2; }
.pe-tile.on { border-color: var(--gp-blue); }
.pe-tile.drag-over { outline: 2px dashed var(--gp-blue); }
.pe-tile img, .pe-tile video { width: 100%; height: 100%; object-fit: cover; display: block; }
.pe-tile input[type=checkbox] { position: absolute; top: 8px; left: 8px; width: 16px; height: 16px; accent-color: var(--gp-blue); }
.pe-drag { position: absolute; top: 6px; right: 6px; background: rgba(255, 255, 255, .85); border-radius: 4px; display: grid; place-items: center; cursor: grab; color: var(--gp-text-2); }
.pe-play { position: absolute; bottom: 8px; left: 8px; background: rgba(16, 24, 40, .6); color: #fff; border-radius: 50%; width: 26px; height: 26px; display: grid; place-items: center; z-index: 1; }
.pe-featured { position: absolute; bottom: 8px; right: 8px; color: var(--gp-blue); background: #fff; border-radius: 50%; display: grid; }
.pe-add-tile, .pe-more-tile { display: grid; place-items: center; border: 1px dashed var(--gp-input); background: var(--gp-bg); cursor: pointer; color: var(--gp-dim); }
.pe-more-tile span { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(16, 24, 40, .55); color: #fff; font-size: 20px; font-weight: 600; }
.pe-plist-head, .pe-prow { display: grid; grid-template-columns: 40px minmax(100px, 1fr) minmax(150px, 1.1fr) minmax(150px, 1.1fr) 100px 36px; gap: 10px; align-items: center; }
.pe-prow .pe-suffix { padding: 0 8px 0 2px; font-size: 13px; color: var(--gp-dim); }
.pe-plist-head { font-size: 14px; font-weight: 600; color: var(--gp-text-2); }
.pe-plist { display: grid; gap: 8px; max-height: calc(100dvh - 16rem); overflow-y: auto; }
.pe-prow { border: 1px solid var(--gp-line); border-radius: 8px; padding: 12px; min-height: 72px; }
.pe-prow.deleted { opacity: .4; }
.pe-prow .gp-input { height: 40px; }
.pe-pimg { width: 40px; height: 40px; border-radius: 50%; border: 0; background: var(--gp-blue-50); color: var(--gp-blue); display: grid; place-items: center; cursor: pointer; overflow: hidden; padding: 0; }
.pe-pimg img { width: 100%; height: 100%; object-fit: cover; }
.pe-pname { min-width: 0; display: grid; gap: 2px; }
.pe-pname > :first-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: left; font-weight: 500; }
.pe-tag { justify-self: start; font-size: 12px; padding: 1px 8px; border-radius: 999px; background: var(--gp-blue-50); color: var(--gp-blue); }
.pe-money { display: flex; align-items: center; border: 1px solid var(--gp-input); border-radius: 8px; background: #fff; box-shadow: var(--gp-shadow); overflow: hidden; }
.pe-money:focus-within { border-color: #84adff; box-shadow: 0 0 0 4px #d1e0ff; }
.pe-money input.gp-input { border: 0; box-shadow: none; flex: 1; min-width: 0; padding: 0 8px; height: 42px; }
.pe-money input.gp-input:focus { box-shadow: none; }
.pe-money.big input.gp-input { height: 46px; }
.pe-prefix, .pe-suffix { padding: 0 10px; color: var(--gp-text-2); font-size: 15px; white-space: nowrap; }
.pe-prefix { padding-right: 0; }
.pe-amount { display: grid; grid-template-columns: 1fr 120px; gap: 10px; }
.pe-price-form { display: grid; gap: 18px; padding-bottom: 12px; border-bottom: 1px solid var(--gp-line); }
.pe-name-row { display: flex; gap: 10px; align-items: flex-end; }
.pe-name-row > .gp-field, .pe-name-row > input { flex: 1; }
.pe-every { display: flex; align-items: center; gap: 8px; }
.pe-every-label { font-size: 14px; color: var(--gp-muted); white-space: nowrap; }
.pe-every input { width: 90px; }
.pe-inv { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 24px; align-items: start; }
.pe-inv-checks { display: grid; gap: 10px; }
.pe-margin { display: grid; gap: 12px; }
.pe-margin .gp-check input:disabled + span { color: var(--gp-faint); }
.pe-tip { display: inline-grid; place-items: center; color: var(--gp-faint); margin-left: 4px; cursor: help; vertical-align: middle; }
.pe-radios { display: flex; gap: 24px; flex-wrap: wrap; }
.pe-margin-row { display: grid; grid-template-columns: 1fr auto 1fr; gap: 12px; align-items: end; }
.pe-arrows { padding-bottom: 12px; color: var(--gp-dim); }
.pe-counted { position: relative; }
.pe-counted textarea { width: 100%; height: auto; padding: 10px 14px 28px; resize: vertical; }
.pe-count { position: absolute; right: 14px; bottom: 10px; font-style: normal; font-size: 13px; color: var(--gp-dim); }
.pe-add-price { justify-self: center; display: inline-flex; align-items: center; gap: 8px; border: 1px dashed var(--gp-input); border-radius: 8px; background: #fff; padding: 10px 22px; font: 500 15px Inter, sans-serif; color: var(--gp-text-2); cursor: pointer; }
.pe-add-price:hover { border-color: var(--gp-blue); color: var(--gp-blue); }
.pe-var-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.gp-btn.pe-soft { background: var(--gp-blue-50); border-color: transparent; color: var(--gp-blue); box-shadow: none; }
.pe-var-edit { display: grid; gap: 14px; }
.pe-var-values { display: grid; gap: 10px; margin-left: 40px; }
.pe-var-edit > .gp-btn { justify-self: start; }
.gp-btn.pe-danger-text { border: 0; box-shadow: none; background: none; color: var(--gp-red); padding: 0 8px; }
.pe-var-done { display: flex; justify-content: space-between; align-items: flex-start; }
.pe-var-name { font-weight: 600; margin-bottom: 6px; }
.pe-var-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.pe-facts { display: grid; grid-template-columns: max-content 1fr; gap: 8px 16px; margin: 0; font-size: 14.5px; }
.pe-facts dt { color: var(--gp-muted); }
.pe-facts dd { margin: 0; color: var(--gp-text); overflow-wrap: anywhere; }
.pe-foot { display: flex; justify-content: flex-end; gap: 12px; padding-bottom: 32px; }
.pe-foot .gp-btn { min-width: 128px; }
.pe-pick { display: flex; flex-wrap: wrap; gap: 12px; }
.pe-pick-tile { display: grid; justify-items: center; gap: 4px; width: 96px; padding: 4px; border: 1px solid var(--gp-input); border-radius: 8px; background: #fff; cursor: pointer; font-size: 12px; color: var(--gp-text-2); }
.pe-pick-tile img { width: 80px; height: 80px; object-fit: cover; border-radius: 6px; }
.pe-pick-tile span { max-width: 88px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pe-pick-tile.add { border-style: dashed; height: 104px; align-content: center; background: var(--gp-bg); }
.pe-pick-tile.on { border-color: var(--gp-blue); box-shadow: 0 0 0 1px var(--gp-blue); }
.pe-pp-back { display: flex; align-items: center; gap: 6px; }
.pe-pp-image { display: grid; justify-items: center; gap: 6px; padding: 20px 24px; border: 1px dashed var(--gp-input); border-radius: 8px; background: #fff; cursor: pointer; color: var(--gp-faint); }
.pe-pp-image img, .pe-pp-image video { max-height: 176px; max-width: 100%; }
.pe-dims { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.pe-digital { display: grid; gap: 14px; }
.pe-seg { display: inline-flex; border: 1px solid var(--gp-input); border-radius: 8px; overflow: hidden; justify-self: start; }
.pe-seg-btn { border: 0; background: #fff; padding: 8px 16px; font: 500 14px Inter, sans-serif; color: var(--gp-text-2); cursor: pointer; }
.pe-seg-btn + .pe-seg-btn { border-left: 1px solid var(--gp-input); }
.pe-seg-btn.on { background: var(--gp-blue-50); color: var(--gp-blue); }
.pe-note-box { background: var(--gp-bg); padding: 12px; border-radius: 8px; font-size: 14px; color: var(--gp-text-2); line-height: 1.5; }
.pe-note-box .gp-btn.link { display: inline; font-size: 14px; }
.pe-files { list-style: none; margin: 0; padding: 0; }
.pe-files li { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--gp-line); }
.pe-file-ico { width: 32px; height: 32px; border-radius: 50%; background: #f2f4f7; display: grid; place-items: center; color: var(--gp-text-2); }
.pe-file-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pe-url-row { display: flex; gap: 16px; align-items: flex-end; flex-wrap: wrap; }
.pe-url-row > .gp-field:first-child { flex: 1; min-width: 240px; }
.pe-w48 { width: 192px; }
