/* ==========================================================================
   JewishLogos UI — a small shadcn-style design system (no shadcn dependency).
   Everything is scoped under .jl-app so it can't leak into the theme.
   Tokens use the shadcn names, prefixed --jl-.
   ========================================================================== */

.jl-app {
  --jl-background: 0 0% 100%;
  --jl-foreground: 240 10% 3.9%;
  --jl-card: 0 0% 100%;
  --jl-card-foreground: 240 10% 3.9%;
  --jl-primary: 240 5.9% 10%;
  --jl-primary-foreground: 0 0% 98%;
  --jl-secondary: 240 4.8% 95.9%;
  --jl-secondary-foreground: 240 5.9% 10%;
  --jl-muted: 240 4.8% 95.9%;
  --jl-muted-foreground: 240 3.8% 46.1%;
  --jl-accent: 240 4.8% 95.9%;
  --jl-accent-foreground: 240 5.9% 10%;
  --jl-destructive: 0 84.2% 60.2%;
  --jl-destructive-foreground: 0 0% 98%;
  --jl-success: 142 71% 29%;
  --jl-border: 240 5.9% 90%;
  --jl-input: 240 5.9% 90%;
  --jl-ring: 240 5.9% 10%;
  --jl-radius: .5rem;
  --jl-ease: cubic-bezier(.22, 1, .36, 1);

  box-sizing: border-box;
  color: hsl(var(--jl-foreground));
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
.jl-app.jl-dark, .jl-dark .jl-app {
  --jl-background: 240 10% 3.9%;
  --jl-foreground: 0 0% 98%;
  --jl-card: 240 10% 3.9%;
  --jl-card-foreground: 0 0% 98%;
  --jl-primary: 0 0% 98%;
  --jl-primary-foreground: 240 5.9% 10%;
  --jl-secondary: 240 3.7% 15.9%;
  --jl-secondary-foreground: 0 0% 98%;
  --jl-muted: 240 3.7% 15.9%;
  --jl-muted-foreground: 240 5% 64.9%;
  --jl-accent: 240 3.7% 15.9%;
  --jl-accent-foreground: 0 0% 98%;
  --jl-border: 240 3.7% 15.9%;
  --jl-input: 240 3.7% 15.9%;
  --jl-ring: 240 4.9% 83.9%;
}
.jl-app *, .jl-app *::before, .jl-app *::after { box-sizing: border-box; }
/* :where() keeps these at zero extra specificity so button links (.jl-btn) keep their own colours */
.jl-app a:where(:not(.jl-btn)) { color: inherit; text-underline-offset: 3px; }
.jl-app a:where(:not(.jl-btn)):hover { text-decoration: underline; }

/* Button links must win over theme link styles (a, a:visited, a:hover) */
.jl-app a.jl-btn, .jl-app a.jl-btn:hover, .jl-app a.jl-btn:visited, .jl-app a.jl-btn:focus { text-decoration: none; }
.jl-app a.jl-btn-default, .jl-app a.jl-btn-default:hover, .jl-app a.jl-btn-default:visited, .jl-app a.jl-btn-default:focus { color: hsl(var(--jl-primary-foreground)); }
.jl-app a.jl-btn-secondary, .jl-app a.jl-btn-secondary:hover, .jl-app a.jl-btn-secondary:visited { color: hsl(var(--jl-secondary-foreground)); }
.jl-app a.jl-btn-outline, .jl-app a.jl-btn-outline:hover, .jl-app a.jl-btn-outline:visited,
.jl-app a.jl-btn-ghost, .jl-app a.jl-btn-ghost:hover, .jl-app a.jl-btn-ghost:visited { color: hsl(var(--jl-foreground)); }
.jl-app a.jl-btn-destructive, .jl-app a.jl-btn-destructive:hover, .jl-app a.jl-btn-destructive:visited { color: hsl(var(--jl-destructive-foreground)); }
.jl-app [hidden] { display: none !important; }

/* ---- Layout ------------------------------------------------------------ */
.jl-dashboard, .jl-public { max-width: 1040px; margin: 0 auto; padding: 24px 16px 64px; }
.jl-dashboard > .jl-auth { max-width: 420px; margin: 24px auto; }
.jl-row { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; }
.jl-gap { gap: 14px; justify-content: flex-start; }
.jl-center { text-align: center; }
.jl-grid { display: grid; gap: 16px; margin-bottom: 16px; }
.jl-grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 800px) { .jl-grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 420px) { .jl-grid-4 { grid-template-columns: 1fr; } }

.jl-dash-header { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 16px; margin-bottom: 24px; }
.jl-dash-title { margin: 0; font-size: 24px; font-weight: 700; letter-spacing: -.02em; line-height: 1.2; display: flex; align-items: center; gap: 6px; }
.jl-subtitle { margin: 20px 0 10px; font-size: 14px; font-weight: 600; }
.jl-bio { margin: 6px 0 10px; max-width: 60ch; color: hsl(var(--jl-muted-foreground)); }

/* ---- Card -------------------------------------------------------------- */
.jl-card {
  background: hsl(var(--jl-card)); color: hsl(var(--jl-card-foreground));
  border: 1px solid hsl(var(--jl-border)); border-radius: calc(var(--jl-radius) + 4px);
  box-shadow: 0 1px 2px 0 rgb(0 0 0 / .05); margin-bottom: 16px;
  transition: box-shadow .2s var(--jl-ease), border-color .2s var(--jl-ease);
}
.jl-card:hover { box-shadow: 0 4px 14px -6px rgb(0 0 0 / .12); }
.jl-card-header { padding: 20px 20px 0; }
.jl-card-content { padding: 20px; }
.jl-card-header + .jl-card-content { padding-top: 16px; }
.jl-card-title { margin: 0; font-size: 18px; font-weight: 600; letter-spacing: -.01em; line-height: 1.3; display: flex; align-items: center; gap: 6px; }
.jl-card-desc { margin: 4px 0 0; color: hsl(var(--jl-muted-foreground)); font-size: 13px; }

/* ---- Stat -------------------------------------------------------------- */
.jl-stat { padding: 18px 20px; margin-bottom: 0; }
.jl-stat-label { color: hsl(var(--jl-muted-foreground)); font-size: 13px; font-weight: 500; }
.jl-stat-value { font-size: 30px; font-weight: 700; letter-spacing: -.03em; line-height: 1.2; margin-top: 4px; font-variant-numeric: tabular-nums; }
.jl-stat-hint { color: hsl(var(--jl-muted-foreground)); font-size: 12px; margin-top: 2px; }

/* ---- Button ------------------------------------------------------------ */
.jl-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; white-space: nowrap;
  height: 36px; padding: 0 16px; border-radius: var(--jl-radius); border: 1px solid transparent;
  font: inherit; font-size: 14px; font-weight: 500; line-height: 1; cursor: pointer; text-decoration: none;
  transition: background-color .15s, color .15s, border-color .15s, transform .12s var(--jl-ease), box-shadow .15s;
}
.jl-btn:hover { text-decoration: none; }
.jl-btn:active { transform: scale(.97); }
.jl-btn:focus-visible, .jl-input:focus-visible, .jl-tabs-trigger:focus-visible, .jl-link-btn:focus-visible {
  outline: 2px solid hsl(var(--jl-ring)); outline-offset: 2px;
}
.jl-btn:disabled, .jl-btn[aria-busy="true"] { opacity: .55; pointer-events: none; }
.jl-btn-default { background: hsl(var(--jl-primary)); color: hsl(var(--jl-primary-foreground)); }
.jl-btn-default:hover { background: hsl(var(--jl-primary) / .9); color: hsl(var(--jl-primary-foreground)); }
.jl-btn-secondary { background: hsl(var(--jl-secondary)); color: hsl(var(--jl-secondary-foreground)); }
.jl-btn-secondary:hover { background: hsl(var(--jl-secondary) / .8); }
.jl-btn-outline { background: hsl(var(--jl-background)); border-color: hsl(var(--jl-input)); color: hsl(var(--jl-foreground)); }
.jl-btn-outline:hover { background: hsl(var(--jl-accent)); }
.jl-btn-ghost { background: transparent; color: hsl(var(--jl-foreground)); }
.jl-btn-ghost:hover { background: hsl(var(--jl-accent)); }
.jl-btn-destructive { background: hsl(var(--jl-destructive)); color: hsl(var(--jl-destructive-foreground)); }
.jl-btn-sm { height: 30px; padding: 0 12px; font-size: 13px; }
.jl-btn-block { width: 100%; }
.jl-btn[aria-busy="true"]::after {
  content: ""; width: 14px; height: 14px; border-radius: 50%;
  border: 2px solid currentColor; border-right-color: transparent; animation: jl-spin .7s linear infinite;
}
.jl-link-btn { background: none; border: 0; padding: 0; font: inherit; color: hsl(var(--jl-foreground)); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.jl-link-btn:hover { color: hsl(var(--jl-muted-foreground)); }
@keyframes jl-spin { to { transform: rotate(360deg); } }

/* ---- Form -------------------------------------------------------------- */
.jl-form { display: block; }
.jl-field { margin-bottom: 14px; }
.jl-label { display: block; font-size: 14px; font-weight: 500; margin-bottom: 6px; }
.jl-input {
  display: block; width: 100%; height: 36px; padding: 0 12px; border-radius: var(--jl-radius);
  border: 1px solid hsl(var(--jl-input)); background: transparent; color: inherit; font: inherit; font-size: 14px;
  box-shadow: 0 1px 2px 0 rgb(0 0 0 / .04); transition: border-color .15s, box-shadow .15s;
}
.jl-input::placeholder { color: hsl(var(--jl-muted-foreground)); }
.jl-input:focus { outline: none; border-color: hsl(var(--jl-ring)); box-shadow: 0 0 0 3px hsl(var(--jl-ring) / .12); }
.jl-textarea { height: auto; padding: 8px 12px; resize: vertical; min-height: 84px; }
.jl-help { margin: 6px 0 0; font-size: 12px; color: hsl(var(--jl-muted-foreground)); }
.jl-otp-input { text-align: center; font-size: 22px; letter-spacing: .5em; height: 48px; font-variant-numeric: tabular-nums; }
.jl-inline { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.jl-inline .jl-input { flex: 1 1 220px; width: auto; }
.jl-turnstile { margin: 4px 0 14px; display: flex; justify-content: center; }
.jl-form-error { margin: 0 0 12px; }

/* ---- Alert ------------------------------------------------------------- */
.jl-alert { padding: 10px 14px; border-radius: var(--jl-radius); border: 1px solid hsl(var(--jl-border)); font-size: 13px; margin: 0 0 14px; background: hsl(var(--jl-muted)); }
.jl-alert-info { background: hsl(var(--jl-secondary)); }
.jl-alert-warn { border-color: hsl(38 92% 50% / .5); background: hsl(38 92% 50% / .1); }
.jl-alert-error { border-color: hsl(var(--jl-destructive) / .5); background: hsl(var(--jl-destructive) / .08); color: hsl(var(--jl-destructive)); }

/* ---- Tabs -------------------------------------------------------------- */
.jl-tabs-list { display: inline-flex; gap: 2px; padding: 4px; background: hsl(var(--jl-muted)); border-radius: calc(var(--jl-radius) + 2px); margin-bottom: 18px; }
.jl-tabs-trigger {
  border: 0; background: transparent; font: inherit; font-size: 14px; font-weight: 500; cursor: pointer;
  padding: 6px 14px; border-radius: var(--jl-radius); color: hsl(var(--jl-muted-foreground)); transition: background .15s, color .15s, box-shadow .15s;
}
.jl-tabs-trigger:hover { color: hsl(var(--jl-foreground)); }
.jl-tabs-trigger[aria-selected="true"] { background: hsl(var(--jl-background)); color: hsl(var(--jl-foreground)); box-shadow: 0 1px 3px rgb(0 0 0 / .1); }
.jl-auth .jl-tabs-list { display: flex; }
.jl-auth .jl-tabs-trigger { flex: 1; }
.jl-tabs-content[hidden] { display: none; }
.jl-tabs-content { animation: jl-tab-in .35s var(--jl-ease) both; }
@keyframes jl-tab-in { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

/* ---- Separator, badge, avatar ------------------------------------------ */
.jl-separator { display: flex; align-items: center; gap: 12px; margin: 18px 0; color: hsl(var(--jl-muted-foreground)); font-size: 12px; text-transform: uppercase; letter-spacing: .06em; }
.jl-separator::before, .jl-separator::after { content: ""; flex: 1; height: 1px; background: hsl(var(--jl-border)); }
.jl-google { display: flex; justify-content: center; min-height: 44px; }

.jl-badge { display: inline-flex; align-items: center; border-radius: 999px; padding: 2px 10px; font-size: 12px; font-weight: 600; line-height: 1.4; border: 1px solid transparent; }
.jl-badge-default { background: hsl(var(--jl-primary)); color: hsl(var(--jl-primary-foreground)); }
.jl-badge-secondary { background: hsl(var(--jl-secondary)); color: hsl(var(--jl-secondary-foreground)); }
.jl-badge-outline { border-color: hsl(var(--jl-border)); color: hsl(var(--jl-foreground)); }
.jl-badge-success { background: hsl(var(--jl-success) / .12); color: hsl(var(--jl-success)); }

.jl-avatar { display: inline-flex; flex: none; align-items: center; justify-content: center; overflow: hidden; border-radius: 50%; background: hsl(var(--jl-muted)); color: hsl(var(--jl-muted-foreground)); font-weight: 600; }
.jl-avatar-sm { width: 28px; height: 28px; font-size: 11px; }
.jl-avatar-md { width: 48px; height: 48px; font-size: 16px; }
.jl-avatar-lg { width: 88px; height: 88px; font-size: 28px; }
.jl-avatar-img, .jl-avatar img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; display: block; }
.jl-verified { display: inline-flex; width: 16px; height: 16px; color: hsl(210 90% 50%); vertical-align: middle; }
.jl-verified svg { width: 100%; height: 100%; }

/* ---- Table ------------------------------------------------------------- */
.jl-table-wrap { overflow-x: auto; }
.jl-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.jl-table th { text-align: left; font-weight: 500; color: hsl(var(--jl-muted-foreground)); padding: 10px 12px; border-bottom: 1px solid hsl(var(--jl-border)); white-space: nowrap; }
.jl-table td { padding: 10px 12px; border-bottom: 1px solid hsl(var(--jl-border)); vertical-align: middle; }
.jl-table tbody tr { transition: background .15s; }
.jl-table tbody tr:hover { background: hsl(var(--jl-muted) / .5); }
.jl-table tbody tr:last-child td { border-bottom: 0; }
.jl-num { text-align: right !important; font-variant-numeric: tabular-nums; }
.jl-logo-cell { display: flex; align-items: center; gap: 12px; min-width: 160px; }
.jl-thumb-wrap { width: 56px; height: 40px; flex: none; display: flex; align-items: center; justify-content: center; background: hsl(var(--jl-muted)); border-radius: 6px; padding: 4px; }
.jl-thumb { max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; }
.jl-empty { text-align: center; padding: 28px 0; color: hsl(var(--jl-muted-foreground)); }
.jl-empty p { margin: 0 0 12px; }

/* ---- Agencies / members ------------------------------------------------ */
.jl-member-list { list-style: none; margin: 0; padding: 0; }
.jl-member { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid hsl(var(--jl-border)); }
.jl-member:last-child { border-bottom: 0; }
.jl-member-name { flex: 1; font-weight: 500; }
.jl-team { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 0 24px; }
.jl-details { margin-top: 18px; border-top: 1px solid hsl(var(--jl-border)); padding-top: 14px; }
.jl-details summary { cursor: pointer; font-weight: 500; margin-bottom: 14px; }
.jl-invite { border-color: hsl(var(--jl-primary) / .35); }
.jl-links { display: flex; gap: 6px; margin-top: 8px; }
.jl-link { display: inline-flex; width: 32px; height: 32px; align-items: center; justify-content: center; border-radius: 50%; border: 1px solid hsl(var(--jl-border)); transition: background .15s, transform .15s var(--jl-ease); }
.jl-link:hover { background: hsl(var(--jl-accent)); transform: translateY(-1px); text-decoration: none; }
.jl-link svg { width: 15px; height: 15px; }

/* ---- Public logo grid -------------------------------------------------- */
.jl-logo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 14px; }
.jl-logo-tile { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 18px 12px 12px; border: 1px solid hsl(var(--jl-border)); border-radius: calc(var(--jl-radius) + 4px); text-decoration: none; background: hsl(var(--jl-card)); transition: transform .2s var(--jl-ease), box-shadow .2s var(--jl-ease); }
.jl-logo-tile:hover { transform: translateY(-2px); box-shadow: 0 8px 20px -10px rgb(0 0 0 / .2); text-decoration: none; }
.jl-logo-tile img { height: 64px; width: auto; max-width: 100%; object-fit: contain; }
.jl-logo-tile span { font-size: 13px; color: hsl(var(--jl-muted-foreground)); text-align: center; }

/* ---- Credits block (use jl_credits() on logo pages) -------------------- */
.jl-credits { margin: 16px 0; }
.jl-credits-label { font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; color: hsl(var(--jl-muted-foreground)); margin-bottom: 8px; }
.jl-credits-list { list-style: none; margin: 0 0 8px; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.jl-credit { display: inline-flex; align-items: center; gap: 8px; padding: 4px 12px 4px 4px; border: 1px solid hsl(var(--jl-border)); border-radius: 999px; background: hsl(var(--jl-card)); transition: border-color .15s, transform .15s var(--jl-ease); }
.jl-credit:hover { border-color: hsl(var(--jl-foreground) / .3); transform: translateY(-1px); }
.jl-credit-name { font-weight: 500; display: inline-flex; align-items: center; gap: 4px; }
.jl-credits-shared { margin: 0; font-size: 13px; color: hsl(var(--jl-muted-foreground)); }

/* ---- Upload form: credit picker ---------------------------------------- */
.jl-credit-box { border: 1px solid hsl(var(--jl-border)); border-radius: calc(var(--jl-radius) + 2px); padding: 14px 16px; margin: 0; min-width: 0; }
.jl-credit-box legend { padding: 0 6px; }
.jl-check { display: flex; align-items: center; gap: 10px; padding: 6px 0; cursor: pointer; font-size: 14px; }
.jl-check input { appearance: none; -webkit-appearance: none; width: 16px; height: 16px; margin: 0; flex: none; border: 1px solid hsl(var(--jl-primary)); border-radius: 4px; background: transparent; display: grid; place-content: center; cursor: pointer; transition: background .12s, transform .12s var(--jl-ease); }
.jl-check input:active { transform: scale(.88); }
.jl-check input::after { content: ""; width: 9px; height: 5px; border-left: 2px solid hsl(var(--jl-primary-foreground)); border-bottom: 2px solid hsl(var(--jl-primary-foreground)); transform: rotate(-45deg) scale(0); margin-top: -2px; transition: transform .12s var(--jl-ease); }
.jl-check input:checked { background: hsl(var(--jl-primary)); }
.jl-check input:checked::after { transform: rotate(-45deg) scale(1); }
.jl-check input:focus-visible { outline: 2px solid hsl(var(--jl-ring)); outline-offset: 2px; }
.jl-check-strong { font-weight: 600; }
.jl-check em { font-weight: 400; font-style: normal; color: hsl(var(--jl-muted-foreground)); }
.jl-credit-search { margin: 10px 0 6px; }
.jl-credit-agency { margin-top: 10px; padding-top: 8px; border-top: 1px dashed hsl(var(--jl-border)); }
.jl-credit-member { padding-left: 26px; }

/* ---- Toast ------------------------------------------------------------- */
.jl-toasts { position: fixed; right: 16px; bottom: 16px; z-index: 100000; display: flex; flex-direction: column; gap: 8px; max-width: min(360px, calc(100vw - 32px)); }
.jl-toast { padding: 12px 16px; border-radius: var(--jl-radius); background: hsl(240 10% 3.9%); color: #fafafa; font-size: 14px; box-shadow: 0 10px 30px -10px rgb(0 0 0 / .4); animation: jl-toast-in .35s var(--jl-ease) both; }
.jl-toast.jl-toast-error { background: hsl(0 72% 45%); }
.jl-toast.jl-toast-out { animation: jl-toast-out .25s ease forwards; }
@keyframes jl-toast-in { from { opacity: 0; transform: translateY(8px) scale(.97); } to { opacity: 1; transform: none; } }
@keyframes jl-toast-out { to { opacity: 0; transform: translateY(4px); } }

/* ---- Confirm dialog ---------------------------------------------------- */
.jl-dialog { border: 1px solid hsl(var(--jl-border)); border-radius: calc(var(--jl-radius) + 4px); padding: 22px; max-width: 380px; width: calc(100% - 32px); color: hsl(var(--jl-foreground)); background: hsl(var(--jl-background)); box-shadow: 0 20px 50px -12px rgb(0 0 0 / .35); animation: jl-tab-in .25s var(--jl-ease) both; }
.jl-dialog::backdrop { background: rgb(0 0 0 / .45); backdrop-filter: blur(2px); }
.jl-dialog p { margin: 0 0 18px; font-size: 15px; }
.jl-dialog-actions { display: flex; justify-content: flex-end; gap: 8px; }

@media (max-width: 600px) {
  .jl-card-header, .jl-card-content { padding-left: 16px; padding-right: 16px; }
  .jl-dash-header { align-items: flex-start; }
}

/* ---- Credit picker: search + checkbox cards ---------------------------- */
.jl-credit-picker { position: relative; }
.jl-picker-search { position: relative; }
.jl-picker-results {
  position: absolute; z-index: 30; left: 0; right: 0; top: calc(100% + 4px); max-height: 320px; overflow-y: auto;
  background: hsl(var(--jl-background)); border: 1px solid hsl(var(--jl-border)); border-radius: var(--jl-radius);
  box-shadow: 0 12px 30px -10px rgb(0 0 0 / .25); padding: 4px; animation: jl-tab-in .2s var(--jl-ease) both;
}
.jl-picker-result {
  display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; padding: 8px 10px;
  border: 0; background: transparent; border-radius: calc(var(--jl-radius) - 2px); cursor: pointer; font: inherit; color: inherit;
}
.jl-picker-result:hover, .jl-picker-result:focus-visible { background: hsl(var(--jl-accent)); outline: none; }
.jl-picker-empty { padding: 12px; color: hsl(var(--jl-muted-foreground)); font-size: 13px; text-align: center; }
.jl-cc-text { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; }
.jl-cc-text strong { font-weight: 600; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.jl-cc-text small { color: hsl(var(--jl-muted-foreground)); font-size: 12px; }

.jl-credit-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(215px, 1fr)); gap: 10px; margin-top: 12px; }
.jl-credit-card {
  position: relative; display: flex; align-items: center; gap: 10px; padding: 10px 40px 10px 10px; cursor: pointer;
  border: 1px solid hsl(var(--jl-border)); border-radius: calc(var(--jl-radius) + 2px); background: hsl(var(--jl-card));
  transition: border-color .15s, box-shadow .15s, background .15s, transform .12s var(--jl-ease);
}
.jl-credit-card:hover { border-color: hsl(var(--jl-foreground) / .35); }
.jl-credit-card:active { transform: scale(.985); }
.jl-credit-card input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.jl-credit-card:focus-within { outline: 2px solid hsl(var(--jl-ring)); outline-offset: 2px; }
.jl-credit-card.is-checked { border-color: hsl(var(--jl-primary)); background: hsl(var(--jl-primary) / .04); box-shadow: 0 0 0 1px hsl(var(--jl-primary)); }
.jl-cc-check {
  position: absolute; right: 12px; top: 50%; width: 18px; height: 18px; margin-top: -9px; border-radius: 50%;
  border: 1px solid hsl(var(--jl-input)); display: grid; place-content: center; transition: background .15s, border-color .15s;
}
.jl-cc-check::after { content: ""; width: 9px; height: 5px; border-left: 2px solid hsl(var(--jl-primary-foreground)); border-bottom: 2px solid hsl(var(--jl-primary-foreground)); transform: rotate(-45deg) scale(0); margin-top: -2px; transition: transform .15s var(--jl-ease); }
.jl-credit-card.is-checked .jl-cc-check { background: hsl(var(--jl-primary)); border-color: hsl(var(--jl-primary)); }
.jl-credit-card.is-checked .jl-cc-check::after { transform: rotate(-45deg) scale(1); }
.jl-flash { animation: jl-flash .7s var(--jl-ease); }
@keyframes jl-flash { 0% { transform: scale(.96); box-shadow: 0 0 0 4px hsl(var(--jl-primary) / .25); } 100% { transform: none; } }

/* ---- Misc dashboard bits ----------------------------------------------- */
.jl-visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.jl-photo-row { display: flex; align-items: center; gap: 18px; margin-bottom: 20px; }
.jl-photo-row .jl-help { margin-top: 8px; }
.jl-grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); margin-bottom: 0; }
@media (max-width: 600px) { .jl-grid-2 { grid-template-columns: 1fr; } }
.jl-cat-box { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 0 12px; max-height: 190px; overflow-y: auto; padding: 8px 12px; border: 1px solid hsl(var(--jl-input)); border-radius: var(--jl-radius); }
.jl-edit-row > td { background: hsl(var(--jl-muted) / .45); padding: 20px; }
.jl-edit-row .jl-credit-picker { margin: 4px 0 16px; }
.jl-edit-actions { margin-top: 6px; }
.jl-actions { white-space: nowrap; text-align: right; }

/* ---- Claim call-to-action (credits block) ------------------------------ */
.jl-claim { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin-top: 10px; padding: 10px 14px; border: 1px dashed hsl(var(--jl-border)); border-radius: var(--jl-radius); }
.jl-claim-text { color: hsl(var(--jl-muted-foreground)); font-size: 13px; }
.jl-dialog .jl-check { padding: 4px 0; }

/* ---- Upload form: shadcn skin for Dropzone + SlimSelect ---------------- */
.jl-upload { max-width: 680px; margin: 0 auto; padding: 24px 16px 64px; }
.jl-optional { font-weight: 400; color: hsl(var(--jl-muted-foreground)); }
.jl-app .dropzone {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center; min-height: 150px; padding: 16px;
  border: 1.5px dashed hsl(var(--jl-input)); border-radius: calc(var(--jl-radius) + 2px); background: hsl(var(--jl-muted) / .35);
  transition: border-color .15s, background .15s;
}
.jl-app .dropzone:hover, .jl-app .dropzone.dz-drag-hover { border-style: dashed; border-color: hsl(var(--jl-primary)); background: hsl(var(--jl-muted) / .7); }
.jl-app .dropzone .dz-message { margin: 0; text-align: center; }
.jl-app .jldz-button {
  display: inline-flex; align-items: center; justify-content: center; height: 36px; padding: 0 16px; border-radius: var(--jl-radius);
  border: 1px solid hsl(var(--jl-input)); background: hsl(var(--jl-background)); color: hsl(var(--jl-foreground));
  font: inherit; font-size: 14px; font-weight: 500; cursor: pointer; transition: background .15s, transform .12s var(--jl-ease);
}
.jl-app .jldz-button:hover { background: hsl(var(--jl-accent)); }
.jl-app .jldz-button:active { transform: scale(.97); }
.jl-app .jldz-placeholder__paragraph { margin: 8px 0 0; color: hsl(var(--jl-muted-foreground)); font-size: 13px; }
.jl-app .dropzone .dz-preview .dz-image { border-radius: var(--jl-radius); background: hsl(var(--jl-card)); border: 1px solid hsl(var(--jl-border)); }
.jl-app .dropzone .dz-preview .dz-remove { color: hsl(var(--jl-destructive)); font-size: 13px; margin-top: 6px; }
.jl-app .dropzone .dz-preview .dz-error-message { border-radius: var(--jl-radius); background: hsl(var(--jl-destructive)); }

/* SlimSelect themed with the same tokens */
.jl-app {
  --ss-primary-color: hsl(var(--jl-primary));
  --ss-bg-color: hsl(var(--jl-background));
  --ss-font-color: hsl(var(--jl-foreground));
  --ss-placeholder-color: hsl(var(--jl-muted-foreground));
  --ss-border-color: hsl(var(--jl-input));
  --ss-focus-color: hsl(var(--jl-ring));
  --ss-highlight-color: hsl(var(--jl-accent));
  --ss-main-height: 36px;
  --ss-border-radius: var(--jl-radius);
  --ss-spacing-l: 8px; --ss-spacing-m: 6px; --ss-spacing-s: 4px;
}
.jl-app .ss-main { box-shadow: 0 1px 2px 0 rgb(0 0 0 / .04); font-size: 14px; }
.jl-app .ss-main .ss-values .ss-value { background: hsl(var(--jl-primary)); color: hsl(var(--jl-primary-foreground)); border-radius: 4px; }
.jl-app .ss-content { border-radius: var(--jl-radius); box-shadow: 0 12px 30px -10px rgb(0 0 0 / .25); }
.jl-app .ss-content .ss-list .ss-option:hover, .jl-app .ss-content .ss-list .ss-option.ss-highlighted { background: hsl(var(--jl-accent)); color: hsl(var(--jl-foreground)); }

/* ---- Credit picker: heading, cards, then search ------------------------ */
.jl-picker-head { margin-bottom: 4px; }
.jl-picker-title { margin: 0; font-size: 15px; font-weight: 600; letter-spacing: -.01em; }
.jl-picker-desc { margin: 2px 0 0; color: hsl(var(--jl-muted-foreground)); font-size: 13px; }
.jl-credit-cards { margin-top: 10px; }
.jl-picker-search { margin-top: 14px; }

/* ---- Onboarding + agency finder ---------------------------------------- */
.jl-onboard { max-width: 640px; margin: 0 auto; }
.jl-onboard-head { margin-bottom: 20px; }
.jl-agency-finder { margin-top: 4px; }
.jl-agency-results { margin-top: 10px; }
.jl-exists-offer { margin-top: 12px; }

/* ---- Header buttons + terms notice ------------------------------------- */
.jl-header-buttons { display: inline-flex; align-items: center; gap: 8px; }
.jl-terms a { color: inherit; }

/* Theme button resets (Bricks/Elementor often style bare <button>) must not change ours */
.jl-app button.jl-btn-default { background: hsl(var(--jl-primary)); color: hsl(var(--jl-primary-foreground)); }
.jl-app button.jl-btn-outline { background: hsl(var(--jl-background)); color: hsl(var(--jl-foreground)); border-color: hsl(var(--jl-input)); }
.jl-app button.jl-btn-ghost { background: transparent; color: hsl(var(--jl-foreground)); }

/* ---- Agency danger zone ------------------------------------------------ */
.jl-danger-zone { margin-top: 20px; padding-top: 14px; border-top: 1px dashed hsl(var(--jl-border)); }
.jl-danger-zone .jl-help { margin: 0 0 10px; }
