/* Rahboom global styles — light theme, RTL */
:root {
  --brand: #0ea5e9;
  --bg: #f8fafc;
  --text: #0f172a;
}

html, body {
  font-family: 'Vazirmatn', system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
}

* { -webkit-tap-highlight-color: transparent; }

img, video { max-width: 100%; height: auto; }

/* Smooth focus rings, RTL friendly */
input:focus, select:focus, textarea:focus, button:focus {
  outline: 2px solid #38bdf8;
  outline-offset: 2px;
}

/* Persian numerals in inputs */
input[type="number"] { font-variant-numeric: tabular-nums; }

/* Slider helpers */
.no-scrollbar::-webkit-scrollbar { display: none; }
.no-scrollbar { -ms-overflow-style: none; scrollbar-width: none; }

/* Line clamp utility (in case Tailwind plugin not loaded) */
.line-clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.line-clamp-3 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ============================================================================
   Panel shell — collapsible RTL sidebar (admin / owner / consumer)
   Re-theme the whole panel UI by editing the --ps-* variables below.
   ============================================================================ */
:root {
  --ps-w: 266px;
  --ps-rail: 78px;
  --ps-bg1: #0f172a;     /* slate-900 */
  --ps-bg2: #082f49;     /* sky-950   */
  --ps-accent: #0ea5e9;  /* brand-500 */
  --ps-accent2: #0284c7; /* brand-600 */
  --ps-text: #cbd5e1;    /* slate-300 */
  --ps-muted: #8193a7;
}

.panel-shell { display: flex; align-items: stretch; min-height: 100vh; }
.panel-main { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; }
.panel-content { width: 100%; max-width: 1280px; margin-inline: auto; padding: 1.5rem; }
@media (min-width: 640px)  { .panel-content { padding: 2rem; } }
@media (min-width: 1024px) { .panel-content { padding: 2rem 2.5rem; } }

.panel-sidebar {
  flex: 0 0 var(--ps-w); width: var(--ps-w);
  position: sticky; top: 0; height: 100vh;
  display: flex; flex-direction: column;
  background: linear-gradient(198deg, var(--ps-bg1), var(--ps-bg2));
  color: var(--ps-text); z-index: 40;
  box-shadow: 0 0 50px -20px rgba(8, 47, 73, .6);
  transition: width .28s cubic-bezier(.4, 0, .2, 1), flex-basis .28s cubic-bezier(.4, 0, .2, 1), transform .28s ease;
}

/* brand / head */
.ps-head { display: flex; align-items: center; gap: .5rem; padding: 1.1rem 1rem .85rem; }
.ps-brand { display: flex; align-items: center; gap: .6rem; min-width: 0; color: #fff; }
.ps-logo {
  width: 38px; height: 38px; flex: 0 0 38px; border-radius: 12px;
  display: grid; place-items: center; font-weight: 800; color: #fff; overflow: hidden;
  background: linear-gradient(135deg, var(--ps-accent), var(--ps-accent2));
  box-shadow: 0 8px 18px -7px rgba(14, 165, 233, .75);
}
.ps-logo img { width: 100%; height: 100%; object-fit: cover; }
.ps-brand-text { display: flex; flex-direction: column; line-height: 1.2; min-width: 0; }
.ps-brand-title { font-weight: 800; color: #fff; font-size: .98rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ps-brand-sub { font-size: .7rem; color: var(--ps-muted); white-space: nowrap; }
.ps-collapse { margin-inline-start: auto; color: var(--ps-muted); padding: .35rem; border-radius: 9px; display: grid; place-items: center; background: transparent; border: 0; cursor: pointer; }
.ps-collapse:hover { color: #fff; background: rgba(255, 255, 255, .08); }

/* keyboard-only focus ring inside the sidebar (no stuck outline on mouse click) */
.panel-sidebar button:focus { outline: none; }
.panel-sidebar button:focus-visible { outline: 2px solid var(--ps-accent); outline-offset: 2px; }

/* nav */
.ps-nav { flex: 1 1 auto; overflow-y: auto; overflow-x: hidden; padding: .35rem .6rem 1rem; }
.ps-nav::-webkit-scrollbar { width: 6px; }
.ps-nav::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, .12); border-radius: 3px; }

.ps-link, .ps-group-head {
  width: 100%; display: flex; align-items: center; gap: .7rem;
  padding: .6rem .7rem; margin: .12rem 0; border-radius: 12px;
  color: var(--ps-text); font-size: .9rem; font-weight: 500; font-family: inherit;
  background: transparent; border: 0; cursor: pointer; text-align: start;
  transition: background .15s, color .15s;
}
.ps-link:hover, .ps-group-head:hover { background: rgba(255, 255, 255, .07); color: #fff; }
.ps-link.active {
  background: linear-gradient(135deg, var(--ps-accent), var(--ps-accent2));
  color: #fff; box-shadow: 0 12px 24px -12px rgba(14, 165, 233, .9);
}
.ps-link.active .ps-ico { color: #fff; }
.ps-ico { flex: 0 0 20px; display: grid; place-items: center; color: inherit; }
.ps-label { flex: 1 1 auto; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.ps-badge { flex: 0 0 auto; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: #f43f5e; color: #fff; font-size: .67rem; font-weight: 700; display: grid; place-items: center; line-height: 1; }
.ps-link.active .ps-badge { background: rgba(255, 255, 255, .28); }

/* groups (accordion) */
.ps-group { margin-top: .05rem; }
.ps-chevron { transition: transform .25s ease; color: var(--ps-muted); flex: 0 0 16px; }
.ps-group.open > .ps-group-head .ps-chevron { transform: rotate(180deg); }
.ps-group-items { overflow: hidden; max-height: 0; transition: max-height .28s ease; }
.ps-sublink {
  display: flex; align-items: center; gap: .6rem;
  padding: .48rem .7rem; padding-inline-start: 2.1rem; margin: .1rem 0;
  border-radius: 10px; color: var(--ps-muted); font-size: .85rem;
  transition: background .15s, color .15s;
}
.ps-sublink:hover { background: rgba(255, 255, 255, .05); color: #fff; }
.ps-sublink.active { color: #fff; background: rgba(14, 165, 233, .16); font-weight: 600; }
.ps-dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .5; flex: 0 0 6px; }
.ps-sublink.active .ps-dot { opacity: 1; background: var(--ps-accent); }

/* footer */
.ps-foot { padding: .55rem .6rem .9rem; border-top: 1px solid rgba(255, 255, 255, .08); display: flex; flex-direction: column; gap: .1rem; }
.ps-user { display: flex; align-items: center; gap: .6rem; padding: .45rem .55rem; margin-bottom: .25rem; }
.ps-avatar { width: 34px; height: 34px; flex: 0 0 34px; border-radius: 10px; overflow: hidden; display: grid; place-items: center; background: rgba(255, 255, 255, .12); color: #fff; font-weight: 700; }
.ps-avatar img { width: 100%; height: 100%; object-fit: cover; }
.ps-user-text { display: flex; flex-direction: column; line-height: 1.25; min-width: 0; }
.ps-user-name { color: #fff; font-size: .85rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ps-user-role { color: var(--ps-muted); font-size: .7rem; }
.ps-foot-form { margin: 0; }
.ps-foot-link { display: flex; align-items: center; gap: .7rem; width: 100%; padding: .55rem .7rem; border-radius: 11px; color: var(--ps-text); font-size: .87rem; font-family: inherit; background: transparent; border: 0; cursor: pointer; text-align: start; transition: background .15s, color .15s; }
.ps-foot-link:hover { background: rgba(255, 255, 255, .07); color: #fff; }
.ps-logout { color: #fda4af; }
.ps-logout:hover { background: rgba(244, 63, 94, .15); color: #fff; }

/* topbar — always visible (carries the notification bell); menu+title are mobile-only */
.panel-topbar {
  display: flex; align-items: center; gap: .35rem;
  height: 56px; padding: 0 1rem; background: #fff; border-bottom: 1px solid #e2e8f0;
  position: sticky; top: 0; z-index: 30;
}
.panel-overlay { display: none; }
.ps-topbar-spacer { flex: 1 1 auto; }
.ps-icon-btn { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 11px; color: #0f172a; background: transparent; border: 0; cursor: pointer; }
.ps-icon-btn:hover { background: #f1f5f9; }
.ps-topbar-menu { display: none; }
.ps-topbar-title { display: none; font-weight: 700; color: #0f172a; font-size: .92rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* notification bell + dropdown */
.ps-bell { position: relative; }
.ps-bell-btn { position: relative; }
.ps-bell-dot {
  position: absolute; top: 3px; inset-inline-end: 3px; min-width: 17px; height: 17px; padding: 0 4px;
  display: grid; place-items: center; border-radius: 999px; background: #ef4444; color: #fff;
  font-size: 10px; font-weight: 700; line-height: 1; box-shadow: 0 0 0 2px #fff;
}
.ps-bell-menu {
  position: absolute; top: calc(100% + 8px); inset-inline-end: 0; width: 340px; max-width: calc(100vw - 1.5rem);
  background: #fff; border: 1px solid #e2e8f0; border-radius: 16px; box-shadow: 0 24px 48px -16px rgba(15, 23, 42, .35);
  overflow: hidden; z-index: 50;
}
.ps-bell-head { padding: .8rem 1rem; font-weight: 700; font-size: .9rem; color: #0f172a; border-bottom: 1px solid #f1f5f9; display: flex; align-items: center; justify-content: space-between; }
.ps-bell-headcount { font-size: 11px; font-weight: 700; color: #ef4444; background: #fef2f2; border-radius: 999px; padding: 2px 8px; }
.ps-bell-list { max-height: 60vh; overflow-y: auto; }
.ps-bell-empty { padding: 2rem 1rem; text-align: center; color: #94a3b8; font-size: .85rem; }
.ps-bell-item { display: block; padding: .7rem 1rem; border-bottom: 1px solid #f1f5f9; text-decoration: none; }
.ps-bell-item:hover { background: #f8fafc; }
.ps-bell-item.is-unread { background: #f0f7ff; }
.ps-bell-item.is-unread:hover { background: #e6f1ff; }
.ps-bell-item-title { font-weight: 600; font-size: .84rem; color: #0f172a; }
.ps-bell-item-body { font-size: .78rem; color: #64748b; margin-top: 2px; line-height: 1.6; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.ps-bell-item-time { font-size: 11px; color: #94a3b8; margin-top: 4px; }
.ps-bell-foot { display: block; text-align: center; padding: .7rem; font-size: .82rem; font-weight: 600; color: var(--ps-accent, #ea580c); text-decoration: none; background: #fff; }
.ps-bell-foot:hover { background: #f8fafc; }

/* desktop collapsed (icon rail) — rail behaviour is desktop-only */
@media (min-width: 1024px) {
  .panel-shell.ps-collapsed .panel-sidebar { width: var(--ps-rail); flex-basis: var(--ps-rail); }
  .panel-shell.ps-collapsed .ps-label,
  .panel-shell.ps-collapsed .ps-brand-text,
  .panel-shell.ps-collapsed .ps-chevron,
  .panel-shell.ps-collapsed .ps-user-text,
  .panel-shell.ps-collapsed .ps-badge { display: none; }
  .panel-shell.ps-collapsed .ps-group-items { display: none; }
  .panel-shell.ps-collapsed .ps-link,
  .panel-shell.ps-collapsed .ps-group-head,
  .panel-shell.ps-collapsed .ps-foot-link { justify-content: center; padding-inline: .6rem; }
  .panel-shell.ps-collapsed .ps-sublink { padding-inline-start: .7rem; }
  /* rail header: logo on top, the (still-clickable) expand toggle below it */
  .panel-shell.ps-collapsed .ps-head { flex-direction: column; align-items: center; gap: .55rem; padding: 1rem .4rem .65rem; }
  .panel-shell.ps-collapsed .ps-brand,
  .panel-shell.ps-collapsed .ps-user { justify-content: center; }
  .panel-shell.ps-collapsed .ps-collapse { margin-inline-start: 0; }
  .panel-shell.ps-collapsed .ps-collapse svg { transform: rotate(180deg); } /* hint: now reopens */
}

@media (prefers-reduced-motion: reduce) {
  .panel-sidebar, .ps-group-items, .ps-chevron { transition: none; }
}

/* mobile (<1024px): off-canvas drawer */
@media (max-width: 1023px) {
  .panel-topbar { padding: 0 .65rem; }
  .panel-topbar .ps-topbar-menu { display: grid; }
  .panel-topbar .ps-topbar-title { display: block; }
  /* dropdown spans the viewport width (minus a margin) so it never overflows on phones */
  .ps-bell-menu { position: fixed; top: 60px; inset-inline: .75rem; width: auto; max-width: none; }
  .panel-sidebar {
    position: fixed; top: 0; bottom: 0; right: 0; height: 100%;
    width: min(86vw, var(--ps-w)); flex-basis: auto;
    transform: translateX(100%);
    box-shadow: -16px 0 48px -12px rgba(0, 0, 0, .55);
  }
  .panel-shell.ps-drawer .panel-sidebar { transform: translateX(0); }
  .panel-shell.ps-drawer .panel-overlay { display: block; position: fixed; inset: 0; background: rgba(15, 23, 42, .5); z-index: 35; }
  /* rail toggle is desktop-only; on mobile you use the drawer instead */
  .ps-collapse { display: none; }
}

/* ============================================================
   Landing — "Deep Ocean" theme (public home page)
   Hand-written so it's never purged by Tailwind. Effects only;
   layout/spacing stays in Tailwind utilities in the EJS.
   ============================================================ */
:root {
  --ocean-teal: #0d9488;
  --ocean-teal-bright: #14b8a6;
  --ocean-navy: #1e3a5f;
  --ocean-navy-deep: #0b1726;
  --ocean-coral: #ff6b4a;
}

/* Hero: living teal→navy gradient + soft aurora blobs */
.rb-hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(125deg, #0b1726 0%, #11233b 28%, #134e4a 60%, #0d9488 100%);
  background-size: 220% 220%;
  animation: rb-gradient 20s ease infinite;
}
@keyframes rb-gradient {
  0%   { background-position: 0% 50%; }
  50%  { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}
.rb-hero::before, .rb-hero::after {
  content: ""; position: absolute; border-radius: 50%;
  filter: blur(72px); pointer-events: none; z-index: 0;
}
.rb-hero::before {
  width: 460px; height: 460px; background: #14b8a6; opacity: .42;
  top: -150px; inset-inline-start: -90px; animation: rb-float 15s ease-in-out infinite;
}
.rb-hero::after {
  width: 380px; height: 380px; background: #ff6b4a; opacity: .26;
  bottom: -160px; inset-inline-end: -70px; animation: rb-float 18s ease-in-out infinite reverse;
}
@keyframes rb-float {
  0%, 100% { transform: translate(0, 0); }
  50%      { transform: translate(24px, -26px); }
}
.rb-hero > * { position: relative; z-index: 1; }

/* ============================================================
   Home hero — light marketplace composition
   ============================================================ */
.rb-home-hero {
  position: relative;
  background: radial-gradient(circle at 15% 45%, rgba(255,255,255,.96) 0 18%, transparent 48%),
              linear-gradient(112deg, #f8faf9 0%, #f5fbf9 42%, #d7f8f1 100%);
}
.rb-home-hero::after {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .3;
  background-image: radial-gradient(rgba(15, 23, 42, .11) .6px, transparent .6px);
  background-size: 5px 5px; mask-image: linear-gradient(90deg, transparent, #000 32%, #000 100%);
}
.rb-home-hero > div { position: relative; z-index: 1; }
.rb-home-kicker { display: inline-flex; align-items: center; gap: .55rem; border: 1px solid #70e4d5; color: #128a82; background: rgba(255,255,255,.35); border-radius: 999px; padding: .55rem 1rem; font-size: .95rem; font-weight: 600; }
.rb-home-kicker i, .rb-demo-callout i { width: .62rem; height: .62rem; border-radius: 999px; display: inline-block; background: #ff7357; }
.rb-home-title { color: #071226; font-size: clamp(2.5rem, 5.2vw, 5.25rem); font-weight: 700; line-height: 1.35; letter-spacing: -.045em; }
.rb-home-subtitle { color: #71859f; font-size: clamp(1rem, 1.45vw, 1.35rem); line-height: 2.1; max-width: 57rem; }
.rb-home-cta { position: relative; overflow: hidden; background: linear-gradient(112deg, #fff 0%, #f5fffc 52%, #dffbf3 100%); border: 1px solid rgba(20,184,166,.12); }
.rb-home-cta::after { content: ""; position: absolute; inset: auto -8% -75% 20%; height: 13rem; border-radius: 50%; background: rgba(20,184,166,.13); filter: blur(34px); pointer-events: none; }
.rb-home-cta > * { position: relative; z-index: 1; }
.rb-hero-cards { transform: rotate(-1deg); }
.rb-demo-card { position: absolute; display: block; width: min(67%, 17.5rem); min-height: 19.5rem; padding: 1rem; border-radius: 1.35rem; color: #111827; background: #fff; border: 1px solid rgba(148,163,184,.22); box-shadow: 0 22px 28px -18px rgba(15, 23, 42, .38), 0 2px 3px rgba(15, 23, 42, .08); transition: transform .35s cubic-bezier(.22,.61,.36,1), box-shadow .35s ease; }
.rb-demo-card:hover { box-shadow: 0 30px 44px -20px rgba(15, 23, 42, .5); z-index: 5; }
.rb-demo-card-agahi { left: 3%; bottom: 1.2rem; background: linear-gradient(#fff2eb 0 45%, #fff 45%); transform: rotate(3deg); }
.rb-demo-card-agahi:hover { transform: rotate(3deg) translateY(-9px) scale(1.02); }
.rb-demo-card-ai { right: 2%; top: .3rem; background: linear-gradient(#f5eee1 0 45%, #fff 45%); transform: rotate(-5deg); }
.rb-demo-card-ai:hover { transform: rotate(-5deg) translateY(-9px) scale(1.02); }
.rb-demo-topline { display: flex; align-items: center; justify-content: flex-start; gap: .35rem; flex-wrap: wrap; }
.rb-demo-special, .rb-demo-pill { display: inline-flex; align-items: center; gap: .25rem; padding: .32rem .58rem; border-radius: 999px; background: #fff; color: #1e293b; font-size: .68rem; font-weight: 700; box-shadow: 0 4px 10px -6px rgba(15,23,42,.35); }
.rb-demo-special { background: #ff711a; color: #fff; }
.rb-demo-purple { color: #6437ca; }
.rb-demo-blue { color: #2563eb; }
.rb-demo-brand { display: flex; align-items: center; justify-content: center; gap: .55rem; margin-top: 3.3rem; font-size: 1.12rem; }
.rb-demo-logo { display: grid; place-items: center; width: 2.7rem; height: 2.7rem; border-radius: .8rem; background: #ff641d; color: #fff; font-size: 1.7rem; font-weight: 700; }
.rb-demo-claude { justify-content: flex-start; font-size: 1.55rem; direction: ltr; }
.rb-claude-mark { color: #ee704d; font-size: 2.1rem; }
.rb-demo-card h3 { margin-top: 1.2rem; padding-top: 1rem; border-top: 1px solid rgba(148,163,184,.17); text-align: center; font-size: .93rem; line-height: 1.8; font-weight: 700; }
.rb-demo-orange { display: block; margin-top: .35rem; color: #ff641d; font-size: 1.15rem; }
.rb-demo-price { display: block; margin-top: .35rem; color: #ff641d; direction: rtl; font-size: 1.18rem; }
.rb-demo-price small { color: #94a3b8; font-size: .65rem; font-weight: 500; }
.rb-demo-meta { display: flex; justify-content: space-between; gap: .4rem; margin-top: .8rem; padding-top: .7rem; border-top: 1px solid #e8edf2; color: #8ba0b8; font-size: .68rem; }
.rb-demo-button { display: block; margin-top: 1.35rem; border-radius: .65rem; padding: .7rem .5rem; background: #081226; color: #fff; text-align: center; font-size: .75rem; font-weight: 700; }
.rb-demo-callout { position: absolute; z-index: 6; display: inline-flex; align-items: center; gap: .55rem; padding: .8rem 1.15rem; border-radius: 999px; background: rgba(255,255,255,.94); color: #1b273b; font-size: .95rem; font-weight: 700; box-shadow: 0 14px 24px -16px rgba(15,23,42,.35); }
.rb-demo-callout-top { left: -1%; top: 2.2rem; }
.rb-demo-callout-bottom { left: -4%; bottom: .15rem; }
@media (max-width: 639px) {
  .rb-home-title { font-size: 2.45rem; }
  .rb-demo-card { width: 68%; min-height: 17rem; padding: .75rem; }
  .rb-demo-brand { margin-top: 2.2rem; }
  .rb-demo-card h3 { margin-top: .75rem; padding-top: .7rem; font-size: .78rem; }
  .rb-demo-meta { font-size: .57rem; }
  .rb-demo-button { margin-top: .8rem; padding: .55rem .4rem; }
  .rb-demo-callout { font-size: .72rem; padding: .6rem .85rem; }
  .rb-demo-callout-top { left: 0; top: 1.2rem; }
  .rb-demo-callout-bottom { left: -1%; bottom: .2rem; }
}

/* AI catalogue album on the home page */
.rb-ai-album { background: #ecfff8; border-radius: 1.65rem; }
.rb-ai-album-icon { display: grid; place-items: center; width: 3.1rem; height: 3.1rem; border-radius: 1rem; color: #0d9488; background: #d4f7eb; }
.rb-ai-album-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 1.25rem; }
.rb-ai-home-card { display: block; overflow: hidden; border-radius: 1.3rem; background: #fff; box-shadow: 0 14px 26px -19px rgba(15,23,42,.32); transition: transform .3s ease, box-shadow .3s ease; }
.rb-ai-home-card:hover { transform: translateY(-6px); box-shadow: 0 24px 32px -18px rgba(15,23,42,.32); }
.rb-ai-home-cover { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 10.3rem; gap: .7rem; color: #171b2c; }
.rb-ai-home-cover.has-image { display: block; padding: 0; overflow: hidden; }
.rb-ai-home-image { display: block; width: 100%; height: 10.3rem; object-fit: cover; }
.rb-ai-home-cover.claude { background: #f6eee1; }
.rb-ai-home-cover.chatgpt { background: #eef0f6; }
.rb-ai-home-cover.midjourney { background: #e8ebfb; }
.rb-ai-home-cover.figma { background: #eee7ff; }
.rb-ai-home-cover strong { font-size: 1.45rem; font-weight: 800; }
.rb-ai-home-mark { font-size: 2.2rem; line-height: 1; color: #f07852; }
.chatgpt .rb-ai-home-mark { color: #0fa88b; }
.midjourney .rb-ai-home-mark { color: #4c63be; }
.figma .rb-ai-home-mark { color: #7d50ef; }
.rb-ai-home-body { padding: 1.05rem 1.1rem 1.2rem; }
.rb-ai-home-body h3 { min-height: 2.9rem; color: #182237; font-size: 1rem; font-weight: 800; line-height: 1.8; }
.rb-ai-home-price-row { display: flex; align-items: baseline; gap: .35rem; margin-top: .55rem; min-height: 2.25rem; direction: rtl; }
.rb-ai-home-price-row strong { color: #fb641f; font-size: 1.23rem; white-space: nowrap; }
.rb-ai-home-price-row span { color: #8996a8; font-size: .68rem; }
.rb-ai-home-price-row small { margin-inline-start: auto; color: #7d8795; font-size: .82rem; }
.rb-ai-home-button { display: block; margin-top: 1.25rem; padding: .7rem .5rem; border-radius: .75rem; background: #0c162c; color: #fff; text-align: center; font-size: .8rem; font-weight: 700; }
.rb-ai-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; margin-top: 1.7rem; padding: 0 .5rem; }
.rb-ai-step { display: flex; align-items: flex-start; gap: .7rem; color: #172238; }
.rb-ai-step > span { display: grid; place-items: center; flex: 0 0 2rem; width: 2rem; height: 2rem; border-radius: 999px; background: #0c162c; color: #fff; font-size: .8rem; font-weight: 800; }
.rb-ai-step strong { display: block; font-size: 1rem; line-height: 1.8; }
.rb-ai-step p { margin-top: .2rem; color: #718096; font-size: .78rem; line-height: 1.9; }
@media (max-width: 1023px) {
  .rb-ai-album-grid { display: flex; overflow-x: auto; padding: .2rem .2rem .7rem; scroll-snap-type: x proximity; }
  .rb-ai-home-card { flex: 0 0 min(17rem, 76vw); scroll-snap-align: start; }
}
@media (max-width: 639px) {
  .rb-ai-album { border-radius: 1.2rem; }
  .rb-ai-album-icon { width: 2.65rem; height: 2.65rem; }
  .rb-ai-album h2 { font-size: 1.25rem; }
  .rb-ai-album p { font-size: .72rem; }
  .rb-ai-home-cover { min-height: 9.3rem; }
  .rb-ai-home-image { height: 9.3rem; }
  .rb-ai-home-cover strong { font-size: 1.2rem; }
  .rb-ai-steps { grid-template-columns: 1fr; gap: 1rem; margin-top: 1.2rem; }
}

/* Subtle grid texture overlay for the hero */
.rb-grid {
  position: absolute; inset: 0; z-index: 0; pointer-events: none; opacity: .35;
  background-image:
    linear-gradient(rgba(255,255,255,.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.05) 1px, transparent 1px);
  background-size: 44px 44px;
  -webkit-mask-image: radial-gradient(ellipse at 50% 0%, #000 35%, transparent 78%);
          mask-image: radial-gradient(ellipse at 50% 0%, #000 35%, transparent 78%);
}

/* Frosted glass (search bar / chips on the hero) */
.rb-glass {
  background: rgba(255,255,255,.10);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,.18);
}
.rb-glass-strong {
  background: rgba(255,255,255,.92);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}

/* Scroll reveal — gated on .rb-js so content is visible if JS never runs */
.rb-js .rb-reveal { opacity: 0; transform: translateY(24px); }
.rb-reveal { transition: opacity .7s cubic-bezier(.22,.61,.36,1), transform .7s cubic-bezier(.22,.61,.36,1); }
.rb-reveal.is-in { opacity: 1; transform: none; }
.rb-reveal[data-d="1"] { transition-delay: .07s; }
.rb-reveal[data-d="2"] { transition-delay: .14s; }
.rb-reveal[data-d="3"] { transition-delay: .21s; }
.rb-reveal[data-d="4"] { transition-delay: .28s; }

/* Horizontal album strips */
.rb-album {
  display: flex; gap: .6rem; overflow-x: auto;
  scroll-snap-type: x proximity; scroll-behavior: smooth;
  padding: .25rem .25rem 1rem;
  scroll-padding-inline: .25rem;
  direction: rtl;
}
@media (min-width: 640px) { .rb-album { gap: 1rem; } }
.rb-album > * { scroll-snap-align: start; flex: 0 0 auto; }

/* Album cards */
.rb-card { transition: transform .38s cubic-bezier(.22,.61,.36,1), box-shadow .38s ease; will-change: transform; }
.rb-card:hover { transform: translateY(-7px); }
.rb-thumb { overflow: hidden; }
.rb-thumb img { transition: transform .65s cubic-bezier(.22,.61,.36,1); }
.rb-card:hover .rb-thumb img { transform: scale(1.08); }

/* Round arrow controls for albums */
.rb-arrow {
  display: inline-grid; place-items: center; width: 38px; height: 38px;
  border-radius: 9999px; transition: background .2s, color .2s, transform .2s, box-shadow .2s;
}
.rb-arrow:hover { transform: scale(1.08); }
.rb-arrow:disabled { opacity: .35; cursor: default; transform: none; }

/* Shimmer sweep on accent buttons */
.rb-btn { position: relative; overflow: hidden; }
.rb-btn::after {
  content: ""; position: absolute; inset: 0; transform: translateX(-130%);
  background: linear-gradient(120deg, transparent 30%, rgba(255,255,255,.4) 50%, transparent 70%);
}
.rb-btn:hover::after { transform: translateX(130%); transition: transform .85s ease; }

/* Service pill underline-grow */
.rb-pill { transition: background .2s, color .2s, border-color .2s, transform .2s; }
.rb-pill:hover { transform: translateY(-2px); }

@media (prefers-reduced-motion: reduce) {
  .rb-hero, .rb-hero::before, .rb-hero::after { animation: none; }
  .rb-js .rb-reveal { opacity: 1; transform: none; }
  .rb-reveal, .rb-card, .rb-thumb img, .rb-arrow, .rb-btn::after, .rb-pill { transition: none; }
}

/* ============================================================
   Mobile app-style bottom navigation + services sheet (public)
   Hand-written (never purged). Shown only below 1024px.
   ============================================================ */
@media (max-width: 1023px) {
  body.has-bottom-nav { padding-bottom: calc(4.25rem + env(safe-area-inset-bottom)); }
}
.rb-noscroll { overflow: hidden; }

.rb-bottomnav {
  position: fixed; inset-inline: 0; bottom: 0; z-index: 50;
  display: flex; align-items: stretch;
  background: rgba(255, 255, 255, .92);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border-top: 1px solid #e2e8f0;
  box-shadow: 0 -8px 24px -12px rgba(15, 23, 42, .18);
  padding-bottom: env(safe-area-inset-bottom);
}
.rb-bottomnav > a, .rb-bottomnav > button {
  position: relative; flex: 1 1 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  padding: .5rem 0 .55rem; min-height: 56px;
  background: none; border: 0; cursor: pointer;
  color: #64748b; font-size: 11px; font-weight: 600; font-family: inherit;
  -webkit-tap-highlight-color: transparent; transition: color .15s ease;
}
.rb-bottomnav > a:active, .rb-bottomnav > button:active { color: #0f766e; }
.rb-bottomnav .is-active { color: var(--ocean-teal); }
.rb-bottomnav .is-active::before {
  content: ""; position: absolute; top: 0; inset-inline-start: 50%; transform: translateX(50%);
  width: 26px; height: 3px; border-radius: 0 0 3px 3px; background: var(--ocean-teal);
}

.rb-sheet { position: fixed; inset: 0; z-index: 60; display: none; }
.rb-sheet.is-open { display: block; }
.rb-sheet-backdrop { position: absolute; inset: 0; background: rgba(15, 23, 42, .5); opacity: 0; transition: opacity .25s ease; }
.rb-sheet.is-open .rb-sheet-backdrop { opacity: 1; }
.rb-sheet-panel {
  position: absolute; inset-inline: 0; bottom: 0;
  background: #fff; border-radius: 1.25rem 1.25rem 0 0;
  padding: .5rem 1rem calc(1rem + env(safe-area-inset-bottom));
  max-height: 86vh; overflow-y: auto;
  transform: translateY(100%); transition: transform .3s cubic-bezier(.22, .61, .36, 1);
  box-shadow: 0 -18px 48px -12px rgba(15, 23, 42, .4);
}
.rb-sheet.is-open .rb-sheet-panel { transform: none; }
.rb-sheet-handle { width: 40px; height: 4px; border-radius: 9999px; background: #cbd5e1; margin: .25rem auto .75rem; }

/* Desktop never shows the mobile chrome */
@media (min-width: 1024px) {
  .rb-bottomnav { display: none; }
  .rb-sheet, .rb-sheet.is-open { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .rb-sheet-backdrop, .rb-sheet-panel { transition: none; }
}

/* ============================================================
   Public catalog pages — light marketplace grids
   ============================================================ */
.rb-catalog-page { min-height: 100vh; background: #f7f9fb; }
.rb-breadcrumb { color: #94a3b8; font-size: .75rem; margin-bottom: .5rem; }
.rb-catalog-title { color: #101a2d; font-family: 'Estedad', 'Vazirmatn', sans-serif; font-size: clamp(1.8rem, 3.1vw, 3rem); font-weight: 700; line-height: 1.45; }
.rb-catalog-subtitle { color: #7c8b9f; font-size: .85rem; margin-top: .2rem; }
.rb-catalog-toolbar { display: flex; align-items: center; gap: 1rem; padding: .85rem; margin-top: .9rem; background: #fff; border: 1px solid #edf1f5; border-radius: 1.25rem; box-shadow: 0 14px 30px -24px rgba(15,23,42,.28); direction: rtl; }
.rb-catalog-search { display: flex; align-items: center; gap: .65rem; flex: 1; min-width: 0; color: #9aabc0; background: #f1f4f8; border-radius: .8rem; padding-inline-start: .9rem; direction: rtl; }
.rb-catalog-search input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; color: #1e293b; font: inherit; font-size: .82rem; padding: .78rem .25rem; direction: rtl; text-align: right; }
.rb-catalog-submit { flex: 0 0 auto; border: 0; border-radius: .75rem; padding: .72rem 2.1rem; background: #ff6b4a; color: #fff; cursor: pointer; font: inherit; font-size: .8rem; font-weight: 700; box-shadow: 0 10px 20px -14px #ff6b4a; }
.rb-catalog-sort { display: flex; align-items: center; gap: .35rem; flex: 0 0 auto; color: #8492a5; font-size: .75rem; white-space: nowrap; direction: rtl; }
.rb-catalog-sort a { color: #637287; padding: .55rem .75rem; border-radius: .7rem; }
.rb-catalog-sort a.is-active { color: #182238; background: #eef2f7; font-weight: 700; }
.rb-chip-rail { display: flex; align-items: center; gap: .5rem; overflow-x: auto; padding: .7rem .1rem; scrollbar-width: none; }
.rb-chip-rail::-webkit-scrollbar { display: none; }
.rb-chip-label { color: #8a98a9; font-size: .75rem; font-weight: 700; white-space: nowrap; margin-inline-end: .25rem; }
.rb-filter-chip { display: inline-flex; align-items: center; gap: .25rem; flex: 0 0 auto; padding: .55rem .85rem; border: 1px solid #e2e8f0; border-radius: 999px; background: #fff; color: #64748b; font-size: .76rem; white-space: nowrap; transition: .2s ease; }
.rb-filter-chip:hover { border-color: #cbd5e1; color: #1e293b; }
.rb-filter-chip.is-active { background: #111b30; border-color: #111b30; color: #fff; }
.rb-chip-rail-country { border-top: 1px solid #edf1f5; }
.rb-listing-grid, .rb-ai-catalog-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 1.25rem; direction: rtl; }
.rb-listing-card, .rb-ai-catalog-card { display: block; overflow: hidden; border: 1px solid #e7edf3; border-radius: 1.2rem; background: #fff; box-shadow: 0 12px 25px -20px rgba(15,23,42,.35); transition: transform .28s ease, box-shadow .28s ease, border-color .28s ease; direction: rtl; }
.rb-listing-card:hover, .rb-ai-catalog-card:hover { transform: translateY(-5px); border-color: #cbd5e1; box-shadow: 0 24px 32px -20px rgba(15,23,42,.35); }
.rb-listing-cover { position: relative; height: 9.4rem; overflow: hidden; background: linear-gradient(145deg, #eef3f8, #e2e9f1); }
.rb-listing-cover img { width: 100%; height: 100%; object-fit: cover; }
.rb-card-badges { position: absolute; inset-inline: .7rem; top: .65rem; display: flex; flex-wrap: wrap; gap: .35rem; direction: rtl; }
.rb-card-badges span { padding: .25rem .5rem; border-radius: .55rem; background: rgba(255,255,255,.9); color: #536174; font-size: .58rem; font-weight: 700; box-shadow: 0 3px 8px -6px rgba(15,23,42,.5); }
.rb-bookmark { position: absolute; bottom: .55rem; inset-inline-start: .7rem; display: grid; place-items: center; width: 1.65rem; height: 1.65rem; border-radius: 50%; background: rgba(255,255,255,.92); color: #334155; font-size: 1rem; }
.rb-listing-body { padding: .8rem .85rem .9rem; direction: rtl; text-align: right; }
.rb-listing-category { color: #94a3b8; font-size: .63rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rb-listing-body h2, .rb-ai-catalog-body h2 { min-height: 2.9rem; margin-top: .3rem; color: #172238; font-size: .8rem; font-weight: 800; line-height: 1.8; }
.rb-listing-price { min-height: 1.8rem; margin-top: .35rem; color: #fb641f; font-weight: 700; }
.rb-listing-price .rb-price-num { font-size: 1rem; }
.rb-listing-meta { display: flex; justify-content: space-between; gap: .3rem; padding-top: .55rem; margin-top: .35rem; border-top: 1px solid #edf1f5; color: #94a3b8; font-size: .59rem; white-space: nowrap; direction: rtl; }
.rb-listing-button, .rb-ai-catalog-button { display: block; margin-top: .85rem; padding: .62rem .4rem; border-radius: .6rem; background: #0e182d; color: #fff; text-align: center; font-size: .68rem; font-weight: 700; }
.rb-empty-state { padding: 5rem 1rem; border: 1px dashed #dbe3ec; border-radius: 1.2rem; background: #fff; color: #64748b; text-align: center; }
.rb-pagination { display: flex; align-items: center; justify-content: center; gap: .35rem; margin-top: 2.5rem; }
.rb-pagination a, .rb-pagination > span { display: grid; place-items: center; min-width: 2.25rem; height: 2.25rem; padding: 0 .55rem; border: 1px solid #e2e8f0; border-radius: .65rem; background: #fff; color: #64748b; font-size: .75rem; }
.rb-pagination a.is-active { border-color: #111b30; background: #111b30; color: #fff; }
.rb-ai-catalog-hero { background: #eafff7; }
.rb-ai-catalog-hero .rb-catalog-title { margin-top: .25rem; }
.rb-ai-hero-pills { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: .45rem; margin-top: 1rem; }
.rb-ai-hero-pills span { padding: .42rem .8rem; border-radius: 999px; background: #fff; color: #0d9488; font-size: .68rem; font-weight: 700; }
.rb-ai-category-rail { padding-top: 0; }
.rb-ai-toolbar { margin-top: .35rem; }
.rb-ai-catalog-cover { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .6rem; height: 7.45rem; color: #171b2c; }
.rb-ai-catalog-cover.has-image { display: block; padding: 0; overflow: hidden; }
.rb-ai-catalog-image { display: block; width: 100%; height: 7.45rem; object-fit: cover; }
.rb-ai-catalog-cover > span { color: #f07852; font-size: 2rem; line-height: 1; }
.rb-ai-catalog-cover strong { font-size: 1.2rem; font-weight: 800; }
.rb-ai-catalog-cover.claude { background: #f6eee1; }
.rb-ai-catalog-cover.chatgpt { background: #eef0f6; }
.rb-ai-catalog-cover.midjourney { background: #e8ebfb; }
.rb-ai-catalog-cover.figma { background: #eee7ff; }
.rb-ai-catalog-cover.higgsfield { background: #ffecef; }
.rb-ai-catalog-cover.cursor { background: #edf1f4; }
.rb-ai-catalog-cover.chatgpt > span { color: #0fa88b; }
.rb-ai-catalog-cover.midjourney > span { color: #4c63be; }
.rb-ai-catalog-cover.figma > span { color: #7d50ef; }
.rb-ai-catalog-cover.higgsfield > span { color: #f3265d; }
.rb-ai-catalog-cover.cursor > span { color: #1f2937; }
.rb-ai-catalog-body { padding: .8rem .85rem .9rem; direction: rtl; text-align: right; }
.rb-ai-catalog-price { display: flex; align-items: baseline; gap: .3rem; min-height: 2rem; margin-top: .35rem; direction: rtl; }
.rb-ai-catalog-price strong { color: #fb641f; font-size: 1rem; white-space: nowrap; }
.rb-ai-catalog-price span { color: #94a3b8; font-size: .6rem; }
.rb-ai-catalog-price small { margin-inline-start: auto; color: #718096; font-size: .72rem; }
.rb-ai-catalog-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; margin-top: 2.6rem; padding: 0 .5rem; }
.rb-ai-catalog-steps > div { display: flex; align-items: center; justify-content: center; gap: .55rem; color: #172238; font-size: .86rem; font-weight: 800; }
.rb-ai-catalog-steps span { display: grid; place-items: center; width: 2rem; height: 2rem; border-radius: 999px; background: #111b30; color: #fff; font-size: .75rem; }
@media (max-width: 1100px) {
  .rb-listing-grid, .rb-ai-catalog-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 800px) {
  .rb-listing-grid, .rb-ai-catalog-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .8rem; }
  .rb-catalog-toolbar { flex-direction: column; align-items: stretch; }
  .rb-catalog-sort { justify-content: flex-end; }
}
@media (max-width: 560px) {
  .rb-listing-grid, .rb-ai-catalog-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .65rem; }
  .rb-listing-cover { height: 7rem; }
  .rb-listing-body, .rb-ai-catalog-body { padding: .65rem; }
  .rb-listing-body h2, .rb-ai-catalog-body h2 { font-size: .7rem; min-height: 2.55rem; }
  .rb-listing-meta { font-size: .52rem; }
  .rb-catalog-submit { padding-inline: 1.35rem; }
  .rb-ai-catalog-cover { height: 6.2rem; }
  .rb-ai-catalog-image { height: 6.2rem; }
  .rb-ai-catalog-cover strong { font-size: .95rem; }
  .rb-ai-catalog-steps { grid-template-columns: 1fr; gap: .85rem; margin-top: 1.7rem; }
  .rb-ai-catalog-steps > div { justify-content: flex-start; font-size: .75rem; }
}

/* ============================================================
   Premium landing — self-hosted Estedad display font (titles +
   prices only; Vazirmatn stays for body). woff2 ships in the zip
   (public/fonts not excluded) → no runtime CDN, works in Iran.
   ============================================================ */
@font-face { font-family: 'Estedad'; src: url('/static/fonts/Estedad-Medium.woff2') format('woff2');   font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: 'Estedad'; src: url('/static/fonts/Estedad-SemiBold.woff2') format('woff2'); font-weight: 600; font-style: normal; font-display: swap; }
@font-face { font-family: 'Estedad'; src: url('/static/fonts/Estedad-Bold.woff2') format('woff2');     font-weight: 700; font-style: normal; font-display: swap; }

/* Display utility (hand-written so Tailwind never purges it) */
.rb-display { font-family: 'Estedad', 'Vazirmatn', system-ui, sans-serif; letter-spacing: -.012em; }

/* Premium price block — confident tabular number, demoted unit */
.rb-price { display: inline-flex; align-items: flex-end; gap: .28rem; line-height: 1.05; white-space: nowrap; }
.rb-price-from { font-size: 11px; color: #94a3b8; margin-bottom: 3px; font-weight: 400; }
.rb-price-num { font-family: 'Estedad', 'Vazirmatn', system-ui, sans-serif; font-size: 15px; font-weight: 600; letter-spacing: .2px; font-feature-settings: 'tnum'; color: inherit; }
.rb-price-unit { display: inline-flex; flex-direction: column; align-items: flex-start; font-size: 10px; color: #64748b; margin-bottom: 2px; font-weight: 500; line-height: 1.22; }
.rb-price-suffix { font-size: 9px; color: #b6c0cc; font-weight: 400; }
.rb-price-lg .rb-price-num { font-size: 27px; }
.rb-price-lg .rb-price-from { font-size: 13px; margin-bottom: 6px; }
.rb-price-lg .rb-price-unit { font-size: 12px; margin-bottom: 4px; }

/* Tracked eyebrow/kicker above section titles */
.rb-eyebrow { display: inline-block; font-family: 'Estedad', 'Vazirmatn', sans-serif; font-size: 11px; font-weight: 600; letter-spacing: .16em; color: #0d9488; margin-bottom: .35rem; }
.rb-eyebrow.coral { color: #f4502a; }
.rb-eyebrow.ink   { color: #3b5b86; }

/* Softer, layered card depth (overrides Tailwind shadow-soft/lift, which load earlier) */
.rb-card { box-shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 10px 26px -16px rgba(15, 23, 42, .16); }
.rb-card:hover { box-shadow: 0 1px 2px rgba(15, 23, 42, .05), 0 24px 50px -22px rgba(15, 23, 42, .30); }

/* Frosted pill badge for cards */
.rb-badge { backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }

/* ============================================================
   «چرا راه بوم؟» — animated escrow trust flow (home page).
   A coral "money" dot travels along the 4-step track (پرداخت ←
   امانت ← تحویل ← آزادسازی) and each node lights up as it arrives.
   Pure CSS, 9s loop; disabled under prefers-reduced-motion.
   ============================================================ */
.rb-flow { position: relative; padding: 1.25rem 0 .25rem; }
.rb-flow-steps { position: relative; display: grid; grid-template-columns: repeat(4, 1fr); gap: .5rem; }
/* the connecting track between node centers */
.rb-flow-steps::before {
  content: ""; position: absolute; top: 24px; right: 12.5%; left: 12.5%; height: 2px;
  background: linear-gradient(to left, rgba(255,255,255,.06), rgba(255,255,255,.22), rgba(255,255,255,.06));
}
.rb-flow-step { position: relative; display: flex; flex-direction: column; align-items: center; gap: .6rem; text-align: center; }
.rb-flow-node {
  width: 48px; height: 48px; border-radius: 9999px; display: grid; place-items: center;
  color: #fff; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.22);
  position: relative; z-index: 1;
  animation: rb-flow-node 9s infinite;
}
.rb-flow-step:nth-child(2) .rb-flow-node { animation-delay: 2.25s; }
.rb-flow-step:nth-child(3) .rb-flow-node { animation-delay: 4.5s; }
.rb-flow-step:nth-child(4) .rb-flow-node { animation-delay: 6.75s; }
.rb-flow-lbl { font-size: 11px; font-weight: 600; color: rgba(255,255,255,.85); line-height: 1.6; }
.rb-flow-dot {
  position: absolute; top: calc(1.25rem + 24px); inset-inline-start: 12.5%;
  width: 12px; height: 12px; margin-top: -6px; margin-inline-start: -6px; border-radius: 9999px;
  background: #ff8a5c; z-index: 2;
  box-shadow: 0 0 0 4px rgba(244, 80, 42, .25), 0 0 16px rgba(244, 80, 42, .8);
  animation: rb-flow-dot 9s infinite;
}
/* hold ~8% on each node, travel ~17% between nodes */
@keyframes rb-flow-dot {
  0%   { inset-inline-start: 12.5%; opacity: 0; }
  3%   { opacity: 1; }
  8%   { inset-inline-start: 12.5%; }
  25%  { inset-inline-start: 37.5%; }
  33%  { inset-inline-start: 37.5%; }
  50%  { inset-inline-start: 62.5%; }
  58%  { inset-inline-start: 62.5%; }
  75%  { inset-inline-start: 87.5%; }
  95%  { inset-inline-start: 87.5%; opacity: 1; }
  100% { inset-inline-start: 87.5%; opacity: 0; }
}
/* node "lights up" while the dot sits on it (delays stagger the same cycle) */
@keyframes rb-flow-node {
  0%, 100% { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.22); box-shadow: none; transform: none; }
  2%       { transform: scale(1.12); }
  5%, 20%  { background: rgba(244, 80, 42, .28); border-color: rgba(255, 138, 92, .9); box-shadow: 0 0 18px rgba(244, 80, 42, .45); transform: none; }
  30%      { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.22); box-shadow: none; }
}
@media (prefers-reduced-motion: reduce) {
  .rb-flow-dot { display: none; }
  .rb-flow-node { animation: none; }
}

/* Hero search — premium focus glow */
.rb-search:focus-within { box-shadow: 0 0 0 3px rgba(20, 184, 166, .28), 0 16px 40px -16px rgba(13, 148, 136, .45); border-color: rgba(255,255,255,.4); }

/* ============================================================
   Agahi (classifieds) structured ad form — segmented controls,
   pill toggles, checkable chips, hashtag input, map. Coral accent
   to match the mobile ad-form design. Hand-written (never purged).
   ============================================================ */
:root { --ag-accent: #f4502a; --ag-accent-soft: #fff1ec; --ag-border: #e6e9ef; }

/* Segmented (radio group) */
.ag-seg { display: inline-flex; background: #f1f4f8; border: 1px solid var(--ag-border); border-radius: 12px; padding: 3px; gap: 3px; width: 100%; }
.ag-seg-opt { flex: 1; }
.ag-seg-opt input { position: absolute; opacity: 0; pointer-events: none; }
.ag-seg-opt span { display: block; text-align: center; font-size: 13px; font-weight: 600; color: #64748b; padding: 8px 6px; border-radius: 9px; cursor: pointer; transition: background .15s, color .15s, box-shadow .15s; }
.ag-seg-opt:has(input:checked) span { background: #fff; color: var(--ag-accent); box-shadow: 0 1px 3px rgba(15,23,42,.12); }
.ag-seg-opt input:focus-visible + span { outline: 2px solid var(--ag-accent); outline-offset: 1px; }

/* Pill toggle */
.ag-toggle { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; user-select: none; }
.ag-toggle input { position: absolute; opacity: 0; pointer-events: none; }
.ag-toggle-track { position: relative; width: 44px; height: 25px; background: #cdd5df; border-radius: 999px; transition: background .18s; flex: 0 0 auto; }
.ag-toggle-track::after { content: ''; position: absolute; top: 3px; right: 3px; width: 19px; height: 19px; background: #fff; border-radius: 50%; transition: transform .18s; box-shadow: 0 1px 2px rgba(0,0,0,.25); }
.ag-toggle input:checked + .ag-toggle-track { background: var(--ag-accent); }
.ag-toggle input:checked + .ag-toggle-track::after { transform: translateX(-19px); }
.ag-toggle-label { font-size: 13px; font-weight: 600; color: #475569; }

/* Checkable chips (accessories / multiselect) */
.ag-chip { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--ag-border); background: #fff; border-radius: 999px; padding: 7px 14px; font-size: 13px; font-weight: 600; color: #475569; cursor: pointer; transition: all .15s; }
.ag-chip input { position: absolute; opacity: 0; pointer-events: none; }
.ag-chip::before { content: '+'; font-weight: 700; color: #94a3b8; }
.ag-chip:has(input:checked) { border-color: var(--ag-accent); background: var(--ag-accent-soft); color: var(--ag-accent); }
.ag-chip:has(input:checked)::before { content: '✓'; color: var(--ag-accent); }

/* Hashtag input */
.ag-tags { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; border: 1px solid var(--ag-border); border-radius: 12px; padding: 8px; }
.ag-tags:focus-within { border-color: var(--ag-accent); }
.ag-tag { display: inline-flex; align-items: center; gap: 6px; background: var(--ag-accent-soft); color: var(--ag-accent); border-radius: 999px; padding: 4px 10px; font-size: 12px; font-weight: 600; }
.ag-tag button { color: var(--ag-accent); font-weight: 700; line-height: 1; opacity: .7; }
.ag-tag button:hover { opacity: 1; }
.ag-tags input.ag-tags-field { flex: 1; min-width: 8rem; border: 0; outline: 0; font-size: 13px; padding: 4px; background: transparent; }

/* Map (Leaflet) */
.ag-map { height: 240px; width: 100%; border-radius: 14px; overflow: hidden; border: 1px solid var(--ag-border); z-index: 0; }
.ag-map-hint { font-size: 11px; color: #94a3b8; margin-top: 6px; }
