/* =====================================================================
   hepa — visual polish layer (v26 "Cathedral Light")
   Loaded after helpr.css. Styling only: no layout or behaviour depends on it,
   so removing this file restores the previous look exactly.
   ===================================================================== */
:root {
  --canvas: #FBF9FF;
  --line: #EAE3F5; --line-2: #DCD1EE;
  --shadow: 0 1px 2px rgba(30,21,48,.04), 0 10px 30px -14px rgba(46,20,96,.18);
  --shadow-lg: 0 2px 6px rgba(30,21,48,.05), 0 30px 60px -24px rgba(46,20,96,.32);
  --shadow-glow: 0 18px 40px -18px rgba(75,39,133,.55);
  --grad-royal: linear-gradient(135deg, #6A40B5 0%, #4B2785 48%, #2E1460 100%);
  --grad-gold: linear-gradient(135deg, #F6DE98 0%, #E2B653 55%, #C99632 100%);
  --grad-soft: linear-gradient(160deg, #FFFFFF 0%, #FAF6FF 100%);
  --ring: 0 0 0 4px rgba(124,84,201,.16);
  --spring: cubic-bezier(.34,1.56,.64,1);
}

/* ---------- canvas: soft light from the "windows" */
body {
  background:
    radial-gradient(1100px 600px at 8% -8%, rgba(142,102,217,.13), transparent 60%),
    radial-gradient(900px 520px at 100% 0%, rgba(243,215,138,.18), transparent 60%),
    radial-gradient(800px 600px at 50% 110%, rgba(94,54,163,.07), transparent 60%),
    var(--canvas);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
}
.app-body {
  background:
    radial-gradient(900px 500px at 100% -10%, rgba(243,215,138,.16), transparent 60%),
    radial-gradient(900px 600px at 20% -20%, rgba(142,102,217,.12), transparent 60%),
    #F6F2FC;
  background-attachment: fixed;
}
h1, h2 { text-wrap: balance; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: #D9CDEE; border-radius: 99px; border: 2px solid transparent; background-clip: padding-box; }
::-webkit-scrollbar-thumb:hover { background-color: #BFADE0; }

/* smooth page-to-page fades in browsers that support it (pure CSS, links work as before) */
@view-transition { navigation: auto; }
::view-transition-old(root) { animation: vt-out .18s ease both; }
::view-transition-new(root) { animation: vt-in .32s cubic-bezier(.22,.8,.24,1) both; }
@keyframes vt-out { to { opacity: 0; } }
@keyframes vt-in { from { opacity: 0; transform: translateY(6px); } }

/* ---------- entrance motion */
@keyframes p-up { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes p-pop { from { opacity: 0; transform: scale(.96); } to { opacity: 1; transform: none; } }
@keyframes p-shine { from { transform: translateX(-120%) skewX(-18deg); } to { transform: translateX(220%) skewX(-18deg); } }
@keyframes p-float { 0%, 100% { transform: translate3d(0,0,0); } 50% { transform: translate3d(0,-14px,0); } }
@keyframes p-pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(209,43,43,.45); } 70% { box-shadow: 0 0 0 8px rgba(209,43,43,0); } }
@keyframes p-ring { 0% { transform: scale(0); opacity: .45; } 100% { transform: scale(2.6); opacity: 0; } }

.app-content > *, main > .section > .container > *:not(.hero), .auth .panel .card, .auth .side {
  animation: p-up .55s cubic-bezier(.22,.8,.24,1) both;
}
.app-content > *:nth-child(2) { animation-delay: .05s; } .app-content > *:nth-child(3) { animation-delay: .1s; }
.app-content > *:nth-child(4) { animation-delay: .15s; } .app-content > *:nth-child(5) { animation-delay: .2s; }
.app-content > *:nth-child(n+6) { animation-delay: .24s; }
.auth .side { animation-delay: .08s; }
.kpis > *, .tiles > *, .getting-started > *, .org-grid > *, .mk-grid > *, .media-grid > *, .plans > *, .stat-strip > *, .cat-tiles > *, .choice-grid > * {
  animation: p-pop .5s cubic-bezier(.22,.8,.24,1) both;
}
.kpis > *:nth-child(2), .tiles > *:nth-child(2), .getting-started > *:nth-child(2), .org-grid > *:nth-child(2), .mk-grid > *:nth-child(2), .plans > *:nth-child(2), .stat-strip > *:nth-child(2), .cat-tiles > *:nth-child(2), .choice-grid > *:nth-child(2) { animation-delay: .06s; }
.kpis > *:nth-child(3), .tiles > *:nth-child(3), .getting-started > *:nth-child(3), .org-grid > *:nth-child(3), .mk-grid > *:nth-child(3), .plans > *:nth-child(3), .stat-strip > *:nth-child(3), .cat-tiles > *:nth-child(3), .choice-grid > *:nth-child(3) { animation-delay: .12s; }
.kpis > *:nth-child(4), .tiles > *:nth-child(4), .getting-started > *:nth-child(4), .org-grid > *:nth-child(4), .mk-grid > *:nth-child(4), .stat-strip > *:nth-child(4), .cat-tiles > *:nth-child(4), .choice-grid > *:nth-child(4) { animation-delay: .18s; }
.kpis > *:nth-child(n+5), .tiles > *:nth-child(n+5), .getting-started > *:nth-child(n+5), .org-grid > *:nth-child(n+5), .mk-grid > *:nth-child(n+5), .stat-strip > *:nth-child(n+5), .cat-tiles > *:nth-child(n+5), .choice-grid > *:nth-child(n+5) { animation-delay: .22s; }

/* ---------- header */
.site-header .bar { background: rgba(255,255,255,.72); border-color: rgba(234,227,245,.9);
  box-shadow: 0 1px 0 rgba(255,255,255,.8) inset, var(--shadow); }
.nav a:not(.btn) { position: relative; }
.nav a:not(.btn)::after { content: ""; position: absolute; left: 50%; bottom: 3px; width: 0; height: 2px; border-radius: 2px; background: var(--gold);
  transform: translateX(-50%); transition: width .3s cubic-bezier(.22,.8,.24,1); }
.nav a:not(.btn):hover::after, .nav a.on::after { width: 18px; }

/* ---------- buttons */
.btn { position: relative; overflow: hidden; isolation: isolate; letter-spacing: .005em; }
.btn::after { content: ""; position: absolute; top: 0; bottom: 0; left: 0; width: 45%; z-index: -1; pointer-events: none;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.35), transparent); transform: translateX(-120%) skewX(-18deg); }
.btn-primary:hover::after, .btn-gold:hover::after { animation: p-shine .75s ease; }
.btn-primary { background: var(--grad-royal); background-size: 140% 140%; background-position: 0 0; border-color: transparent;
  box-shadow: 0 1px 0 rgba(255,255,255,.18) inset, var(--shadow-glow); transition: transform .2s var(--ease), box-shadow .25s, background-position .4s; }
.btn-primary:hover { background: var(--grad-royal); background-size: 140% 140%; background-position: 100% 100%; box-shadow: 0 1px 0 rgba(255,255,255,.2) inset, 0 22px 44px -18px rgba(75,39,133,.7); }
.btn-gold { background: var(--grad-gold); color: #241806; box-shadow: 0 1px 0 rgba(255,255,255,.45) inset, 0 16px 32px -16px rgba(201,150,50,.9); }
.btn-gold:hover { background: var(--grad-gold); color: #241806; box-shadow: 0 1px 0 rgba(255,255,255,.5) inset, 0 22px 40px -16px rgba(201,150,50,1); }
.btn-ghost { background: rgba(255,255,255,.85); backdrop-filter: blur(6px); box-shadow: 0 1px 2px rgba(30,21,48,.04); }
.btn-ghost:hover { box-shadow: 0 10px 22px -14px rgba(75,39,133,.5); }
.btn-danger { background: linear-gradient(135deg, #D2402F, #A11F14); box-shadow: 0 14px 26px -16px rgba(180,35,24,.9); }
.btn-danger:hover { color: #fff; filter: brightness(1.06); }
.btn .ripple { position: absolute; border-radius: 50%; width: 80px; height: 80px; margin: -40px 0 0 -40px; background: rgba(255,255,255,.45);
  pointer-events: none; animation: p-ring .6s ease-out forwards; z-index: -1; }
.btn-ghost .ripple, .btn-google .ripple { background: rgba(75,39,133,.18); }
.pill-btn { transition: background .2s, border-color .2s, transform .2s var(--ease), box-shadow .2s; }
.pill-btn:hover { transform: translateY(-1px); box-shadow: 0 8px 18px -12px rgba(75,39,133,.5); border-color: var(--line-2); }
.link-btn { transition: color .2s; } .link-btn:hover { color: var(--deep); text-decoration: underline; text-underline-offset: 3px; }

/* ---------- cards */
.card { background: var(--grad-soft); border-color: var(--line); border-radius: 26px;
  box-shadow: 0 1px 0 rgba(255,255,255,.9) inset, var(--shadow); transition: box-shadow .3s, border-color .3s, transform .3s var(--ease); }
.card.flat { box-shadow: 0 1px 0 rgba(255,255,255,.9) inset; }
.card.tint { background: linear-gradient(160deg, #F6F0FE, #EFE6FC); }
.card.gold { background: linear-gradient(160deg, #FFF8E6, #FFEFC8); }
.card > h2:first-child, .card > h3:first-child { position: relative; }
.app-content .card:hover { border-color: var(--line-2); box-shadow: 0 1px 0 rgba(255,255,255,.9) inset, 0 18px 40px -22px rgba(46,20,96,.28); }
.card-link:hover { transform: translateY(-5px); }
.banner { background: var(--grad-soft); border-radius: 28px; }
.banner::before { width: 6px; background: linear-gradient(180deg, var(--gold), var(--royal)); }
.panel-royal { background: radial-gradient(600px 300px at 90% 0%, rgba(243,215,138,.25), transparent 60%), var(--grad-royal); box-shadow: var(--shadow-lg); }
.empty { background: linear-gradient(160deg, #FFFFFF, #FAF6FF); border-color: #D8CBEE; }

/* ---------- forms: every field on the platform */
label { letter-spacing: .005em; }
.input, select.input, textarea.input,
form input[type=text], form input[type=email], form input[type=password], form input[type=tel], form input[type=number], form input[type=url],
form input[type=search], form input[type=date], form input[type=datetime-local], form input[type=time], form input[type=month], form select, form textarea {
  width: 100%; padding: 13px 16px; border: 1.5px solid var(--line-2); border-radius: 14px; font: inherit; color: var(--ink);
  background-color: #FDFCFF; box-shadow: 0 1px 2px rgba(30,21,48,.04) inset;
  transition: border-color .2s, box-shadow .25s, background-color .2s;
}
/* inputs that a template sizes on purpose keep their own width */
form .filters .input, form .rule-row .input, form .bulkbar .input, form.row > .input, form .phone-row select, form .phone-row input,
.chat-reply textarea { width: auto; }
.filters .input { width: auto; } .phone-row select { width: auto; } .phone-row input { width: auto; }
.input:hover, form input:hover:not([type=checkbox]):not([type=radio]):not([type=submit]):not([type=file]):not([type=range]), form select:hover, form textarea:hover { border-color: #C6B6E2; background-color: #fff; }
.input:focus, form input:focus:not([type=checkbox]):not([type=radio]):not([type=file]):not([type=range]), form select:focus, form textarea:focus, .chat-reply textarea:focus {
  border-color: #7C54C9; background-color: #fff; outline: none; box-shadow: var(--ring), 0 8px 22px -14px rgba(75,39,133,.45);
}
.input::placeholder, input::placeholder, textarea::placeholder { color: #A79DB8; }
textarea.input, form textarea { min-height: 112px; line-height: 1.55; resize: vertical; }
/* custom select arrow */
select.input, form select {
  -webkit-appearance: none; appearance: none; padding-right: 44px; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%234B2785' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 16px center; background-size: 14px;
}
select[multiple].input, form select[multiple] { background-image: none; padding-right: 16px; min-height: 120px; }
input[type=color].input, form input[type=color] { height: 50px; padding: 5px; width: 88px; cursor: pointer; }
input[type=date], input[type=datetime-local], input[type=time] { min-height: 50px; }
::-webkit-calendar-picker-indicator { cursor: pointer; opacity: .65; filter: invert(19%) sepia(54%) saturate(2400%) hue-rotate(250deg); }
/* checkboxes & radios */
input[type=checkbox], input[type=radio] {
  -webkit-appearance: none; appearance: none; width: 20px; height: 20px; margin: 0 8px 0 0; vertical-align: -4px; flex-shrink: 0;
  border: 1.8px solid #BFAEDD; background: #fff; cursor: pointer; display: inline-grid; place-content: center;
  transition: background .2s, border-color .2s, box-shadow .2s, transform .2s var(--spring);
}
input[type=checkbox] { border-radius: 6px; } input[type=radio] { border-radius: 50%; }
input[type=checkbox]::before { content: ""; width: 11px; height: 11px; transform: scale(0); transition: transform .22s var(--spring);
  clip-path: polygon(14% 44%, 0 65%, 50% 100%, 100% 16%, 80% 0%, 43% 62%); background: #fff; }
input[type=radio]::before { content: ""; width: 9px; height: 9px; border-radius: 50%; transform: scale(0); transition: transform .22s var(--spring); background: #fff; }
input[type=checkbox]:checked, input[type=radio]:checked { background: var(--grad-royal); border-color: transparent; }
input[type=checkbox]:checked::before, input[type=radio]:checked::before { transform: scale(1); }
input[type=checkbox]:hover, input[type=radio]:hover { border-color: var(--royal); }
input[type=checkbox]:focus-visible, input[type=radio]:focus-visible { outline: none; box-shadow: var(--ring); }
input[type=checkbox]:active, input[type=radio]:active { transform: scale(.9); }
input[type=checkbox]:disabled, input[type=radio]:disabled { opacity: .5; cursor: not-allowed; }
/* hidden pickers (tiles, chips) keep their invisible inputs */
.type-pick input, .choice input, .cat-tiles input { opacity: 0 !important; position: absolute; pointer-events: none; }
.check-row { display: flex; align-items: center; gap: 2px; }
.check-row label { margin: 0; }
/* file inputs */
input[type=file] { font: inherit; font-size: .9rem; color: var(--muted); width: 100%; padding: 10px; border: 1.5px dashed #CDBEE6; border-radius: 16px; background: #FDFCFF; cursor: pointer;
  transition: border-color .2s, background .2s; }
input[type=file]:hover { border-color: var(--royal); background: #F8F3FF; }
input[type=file]::file-selector-button { font: 700 .85rem var(--font); border: 0; border-radius: 999px; padding: 9px 16px; margin-right: 12px; cursor: pointer;
  background: var(--grad-royal); color: #fff; box-shadow: 0 8px 18px -10px rgba(75,39,133,.8); transition: filter .2s; }
input[type=file]::file-selector-button:hover { filter: brightness(1.1); }
input[type=range] { accent-color: var(--royal); width: 100%; }
.form-field { margin-bottom: 18px; }
.form-field label { margin-bottom: 7px; }
.help { color: #857C96; }
.errorlist { display: flex; flex-direction: column; gap: 2px; animation: p-up .3s both; }
.errorlist li::before { content: "⚠ "; }
.form-field:has(.errorlist) .input, .form-field:has(.errorlist) input, .form-field:has(.errorlist) select, .form-field:has(.errorlist) textarea { border-color: #E3A39B; background: #FFF9F8; }
.amount-input { padding: 16px 18px !important; }
.pw-wrap .pw-eye { border-radius: 10px; padding: 6px 10px; }
.pw-wrap .pw-eye:hover { background: var(--tint); }

/* picker tiles */
.type-pick .opt, .choice span, .cat-tiles .ct { background: var(--grad-soft); border-radius: 18px; box-shadow: 0 1px 2px rgba(30,21,48,.04); }
.type-pick .opt:hover, .choice span:hover, .cat-tiles .ct:hover { transform: translateY(-2px); box-shadow: 0 14px 28px -18px rgba(75,39,133,.55); }
.choice input:checked + span { background: var(--grad-royal); }
.cat-tiles .ct { transition: border-color .2s, box-shadow .2s, transform .25s var(--spring), background .2s; }
.cat-tiles input:checked + .ct { background: linear-gradient(160deg, #F4ECFF, #ECE0FD); transform: translateY(-2px); box-shadow: 0 0 0 3px rgba(75,39,133,.14), 0 14px 28px -18px rgba(75,39,133,.6); }
.amount-chips button, .quick-amounts .btn { transition: all .2s var(--ease); }
.amount-chips button { background: #FDFCFF; }
.amount-chips button:hover { border-color: var(--royal); transform: translateY(-1px); }
.amount-chips button.on { background: var(--grad-royal); border-color: transparent; box-shadow: 0 10px 20px -12px rgba(75,39,133,.9); }
.chips label { transition: all .2s var(--ease); } .chips label:hover { border-color: var(--line-2); transform: translateY(-1px); }
.chips label input { margin-right: 2px; }
.chip { transition: all .2s var(--ease); } .chip:hover { border-color: var(--royal); color: var(--royal); text-decoration: none; }
.chip.on { background: var(--grad-royal); border-color: transparent; color: #fff; }

/* ---------- badges / alerts / notices */
.badge { border: 1px solid rgba(75,39,133,.08); }
.badge.success { border-color: rgba(35,122,82,.15); } .badge.error { border-color: rgba(180,35,24,.15); }
.badge.warn { border-color: rgba(138,90,0,.15); } .badge.gold { border-color: rgba(122,84,16,.15); }
.alert { position: relative; padding-left: 46px; border-radius: 18px; box-shadow: 0 10px 24px -18px rgba(30,21,48,.35); }
.alert::before { position: absolute; left: 16px; top: 13px; width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center;
  font-size: .72rem; font-weight: 800; color: #fff; content: "i"; background: var(--gold-ink); }
.alert.success::before { content: "✓"; background: var(--success); }
.alert.error::before { content: "!"; background: var(--error); }
.notice { border: 1px solid rgba(75,39,133,.08); }
.help-pop { box-shadow: var(--shadow); }

/* ---------- tables */
.table-wrap, .card > table, .card > .table-wrap { border-radius: 18px; }
.table-wrap { border: 1px solid var(--line); background: #fff; box-shadow: 0 1px 2px rgba(30,21,48,.03); }
table { background: transparent; }
th { background: linear-gradient(180deg, #FAF7FF, #F5F0FD); color: #7A6F8E; text-transform: uppercase; letter-spacing: .06em; font-size: .7rem; padding-top: 12px; padding-bottom: 12px; }
thead th:first-child, tr:first-child > th:first-child { border-top-left-radius: 14px; }
thead th:last-child, tr:first-child > th:last-child { border-top-right-radius: 14px; }
tbody tr:nth-child(even) td { background: rgba(250,247,255,.6); }
tbody tr:hover td { background: #F5EFFE; }
td { border-bottom-color: #F0EBF7; }
.money { color: var(--ink); }

/* ---------- dashboard shell: deep-royal sidebar */
.sidebar { background:
    radial-gradient(400px 260px at 0% 0%, rgba(142,102,217,.35), transparent 60%),
    radial-gradient(360px 300px at 100% 100%, rgba(217,172,72,.16), transparent 60%),
    linear-gradient(180deg, #2E1460 0%, #24104D 60%, #1E0D41 100%);
  border-right: 0; box-shadow: 8px 0 30px -18px rgba(30,13,65,.6); color: #E9E1F8; scrollbar-color: rgba(255,255,255,.2) transparent; }
.sidebar::-webkit-scrollbar-thumb { background: rgba(255,255,255,.18); }
.sb-logo { background: #fff; border-radius: 14px; padding: 6px 10px; display: inline-block; box-shadow: 0 8px 20px -12px rgba(0,0,0,.6); }
.sb-logo img { height: 28px; }
.sb-close { background: rgba(255,255,255,.12); color: #fff; }
.sb-context, .sb-context.org { background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.1); color: #fff; backdrop-filter: blur(6px); }
.sb-context strong { color: #fff; }
.sb-context .muted, .sb-context small { color: #BDAEDD !important; }
.sb-context .avatar { background: rgba(255,255,255,.14); color: #fff; }
.sidebar .sb-kicker { color: var(--gold-2); letter-spacing: .04em; }
.sb-label { color: #9C8CC0; text-transform: uppercase; letter-spacing: .1em; font-size: .66rem; }
.sb-link { color: #DCD2F0; position: relative; transition: background .2s, color .2s, padding-left .25s var(--ease); }
.sb-link .ico { color: #A897CC; }
.sb-link:hover { background: rgba(255,255,255,.08); color: #fff; padding-left: 16px; }
.sb-link:hover .ico { color: var(--gold-2); }
.sb-link.on { background: linear-gradient(90deg, rgba(255,255,255,.18), rgba(255,255,255,.06)); color: #fff; box-shadow: 0 1px 0 rgba(255,255,255,.1) inset; }
.sb-link.on::before { content: ""; position: absolute; left: -14px; top: 9px; bottom: 9px; width: 4px; border-radius: 0 4px 4px 0; background: var(--grad-gold); box-shadow: 0 0 12px rgba(243,215,138,.8); }
.sb-link.on .ico { color: var(--gold-2); }
.sb-link em { background: rgba(255,255,255,.14); color: #fff; }
.sb-link em.gold { background: var(--grad-gold); color: #241806; }
.sb-bottom { border-top-color: rgba(255,255,255,.1); }
.sb-org { color: #EDE6FA; } .sb-org small { color: #A897CC; }
.sb-org:hover { background: rgba(255,255,255,.08); color: #fff; }
.sb-org .avatar { background: rgba(255,255,255,.14); color: #fff; }
.sb-user { color: #fff; } .sb-user small { color: #A897CC; } .sb-user:hover { background: rgba(255,255,255,.08); color: #fff; }
.sb-user .avatar { background: var(--grad-gold); color: #241806; }
.sidebar .do-more { background: linear-gradient(135deg, rgba(243,215,138,.22), rgba(243,215,138,.08)); color: #F6E2A8 !important; border: 1px solid rgba(243,215,138,.25); }
.sidebar .muted { color: #A897CC; }
.sidebar a:not(.sb-link):not(.sb-org):not(.sb-user):not(.sb-logo):not(.btn) { color: #E3D8F7; }
.sidebar .badge { background: rgba(255,255,255,.12); color: #fff; border-color: rgba(255,255,255,.12); }
.sidebar .badge.success { background: rgba(63,191,127,.18); color: #9BE7C0; }
.sidebar .badge.warn, .sidebar .badge.gold { background: rgba(243,215,138,.18); color: #F6E2A8; }
.sidebar details.sb-more > summary { color: #9C8CC0; }
.sidebar .adv-toggle, .sidebar .adv-toggle * { color: #DCD2F0; }
.sidebar .btn-ghost { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.18); color: #fff; }

.topbar { background: rgba(246,242,252,.72); border-bottom-color: rgba(234,227,245,.8); }
.tb-title { background: linear-gradient(90deg, var(--ink), var(--royal)); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.tb-crumb { -webkit-text-fill-color: var(--muted); }
.tb-icon, .tb-help, .tb-menu { transition: transform .2s var(--ease), box-shadow .2s, color .2s, border-color .2s; box-shadow: 0 1px 2px rgba(30,21,48,.04); }
.tb-icon:hover, .tb-help:hover, .tb-menu:hover { transform: translateY(-2px); box-shadow: 0 10px 20px -12px rgba(75,39,133,.5); }
.tb-icon .dot, .bell .dot { animation: p-pulse 2.2s infinite; }

/* ---------- dashboard blocks */
.hello h1 { background: linear-gradient(100deg, var(--ink) 30%, var(--royal) 100%); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.kpi-tile, .tile, .gs-item, .org-tile { background: var(--grad-soft); box-shadow: 0 1px 0 rgba(255,255,255,.9) inset, var(--shadow); border-radius: 22px; position: relative; overflow: hidden; }
.kpi-tile::before, .tile::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 3px; background: linear-gradient(90deg, transparent, rgba(124,84,201,.55), transparent);
  opacity: 0; transition: opacity .3s; }
.kpi-tile:hover::before, .tile:hover::before { opacity: 1; }
.tile { transition: transform .25s var(--ease), box-shadow .25s, border-color .25s; }
.tile:hover { transform: translateY(-4px); box-shadow: 0 22px 40px -24px rgba(46,20,96,.45); border-color: var(--line-2); }
.tile .ti, .kpi-ico { background: linear-gradient(145deg, #F3ECFF, #E7DBFB); box-shadow: 0 1px 0 #fff inset, 0 6px 14px -8px rgba(75,39,133,.45); transition: transform .3s var(--spring); }
.tile:hover .ti, .kpi-tile:hover .kpi-ico { transform: scale(1.08) rotate(-4deg); }
.tile.gold { background: linear-gradient(160deg, #FFF9EA, #FFF1CF); }
.tile.gold .ti, .kpi-ico.gold { background: var(--grad-gold); color: #3C2A06; }
.kpi-ico.green { background: linear-gradient(145deg, #E2F6EB, #C9EBD8); }
.kpi-num, .stat { background: linear-gradient(100deg, var(--ink), var(--royal)); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.gs-item { transition: transform .25s var(--ease), box-shadow .25s, border-color .25s; }
.gs-item:hover { transform: translateY(-3px); box-shadow: 0 18px 32px -22px rgba(46,20,96,.45); }
.gs-item.done { background: linear-gradient(160deg, #EEF9F3, #DDF2E6); }
.org-tile { transition: transform .25s var(--ease), box-shadow .25s, border-color .25s, background .25s; }
.org-tile:hover { transform: translateY(-3px); background: linear-gradient(160deg, #FFFFFF, #F5EEFF); box-shadow: 0 18px 32px -22px rgba(46,20,96,.45); }
.code-chip { background: linear-gradient(145deg, #F4EDFF, #E9DEFC); box-shadow: 0 1px 0 #fff inset, 0 10px 22px -16px rgba(75,39,133,.6); }
.date-chip { background: var(--grad-gold); color: #3C2A06; box-shadow: 0 8px 18px -12px rgba(201,150,50,.9); }
.date-chip b { color: #241806; }
.event-row, .feed-row { transition: background .2s, padding-left .25s var(--ease); border-radius: 12px; }
.event-row:hover { background: rgba(244,238,253,.7); padding-left: 8px; }
.step-tabs { background: rgba(255,255,255,.8); backdrop-filter: blur(8px); box-shadow: 0 1px 2px rgba(30,21,48,.04); }
.step-tabs a { transition: background .2s, color .2s; }
.step-tabs a.on { background: var(--grad-royal); box-shadow: 0 10px 20px -14px rgba(75,39,133,.9); }
.progress { background: #EDE5FA; box-shadow: 0 1px 2px rgba(30,21,48,.06) inset; }
.progress > i { background: linear-gradient(90deg, #6A40B5, #4B2785 50%, #D9AC48); position: relative; overflow: hidden; }
.progress > i::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, transparent, rgba(255,255,255,.45), transparent); animation: p-shine 2.4s 1.2s infinite; }
.tick.done { background: linear-gradient(135deg, #2F9A68, #1E6E49); box-shadow: 0 6px 14px -8px rgba(35,122,82,.9); animation: p-pop .4s var(--spring) both; }
.timeline > div::before { background: var(--grad-gold); box-shadow: 0 0 0 4px rgba(243,215,138,.3); }
.tour { background: radial-gradient(500px 220px at 100% 0%, rgba(243,215,138,.25), transparent 60%), var(--grad-royal); box-shadow: var(--shadow-lg); }
.mh-hero { background: radial-gradient(500px 220px at 100% 0%, rgba(243,215,138,.25), transparent 60%), var(--grad-royal); box-shadow: var(--shadow-lg); }
.bulkbar { background: linear-gradient(135deg, #2E1460, #1E0D41); animation: p-up .3s both; }
.rows { border-color: var(--line); border-radius: 20px; background: #fff; box-shadow: 0 1px 2px rgba(30,21,48,.03); }
.rowi { border-top-color: #F0EBF7; transition: background .2s; }
.rowi:hover { background: #FAF6FF; }
.btabs { background: rgba(255,255,255,.88); backdrop-filter: saturate(170%) blur(14px); -webkit-backdrop-filter: saturate(170%) blur(14px); box-shadow: 0 -10px 30px -20px rgba(46,20,96,.4); }
.btabs a.on { position: relative; }
.btabs a.on::before { content: ""; position: absolute; top: -6px; left: 30%; right: 30%; height: 3px; border-radius: 0 0 4px 4px; background: var(--grad-royal); }

/* ---------- public pages */
.hero { position: relative; }
.hero::before, .hero::after { content: ""; position: absolute; z-index: -1; border-radius: 50%; filter: blur(60px); pointer-events: none; }
.hero::before { width: 420px; height: 420px; left: -120px; top: -60px; background: rgba(142,102,217,.22); animation: p-float 9s ease-in-out infinite; }
.hero::after { width: 360px; height: 360px; right: -80px; top: 120px; background: rgba(243,215,138,.28); animation: p-float 11s ease-in-out infinite reverse; }
.hero h1 { background: linear-gradient(100deg, var(--ink) 20%, var(--royal) 70%, #8E66D9); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; padding-bottom: .06em; }
.hero .kicker { background: rgba(255,255,255,.8); backdrop-filter: blur(8px); }
.hero .proof strong { background: var(--grad-royal); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.window .mosaic { animation: p-float 8s 2.5s ease-in-out infinite; }
.journey .step { background: var(--grad-soft); box-shadow: var(--shadow); transition: transform .3s var(--ease), box-shadow .3s; }
.journey .step:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.feature-ico { background: linear-gradient(145deg, #F3ECFF, #E7DBFB); box-shadow: 0 1px 0 #fff inset, 0 8px 18px -10px rgba(75,39,133,.5); }
.bento .card { transition: transform .3s var(--ease), box-shadow .3s; }
.bento .card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.section-head h2 { position: relative; }
.auth { position: relative; }
.auth .panel .card { border: 1px solid rgba(234,227,245,.9); background: rgba(255,255,255,.88); backdrop-filter: blur(14px); box-shadow: 0 1px 0 #fff inset, var(--shadow-lg); }
.auth .side h1 { background: linear-gradient(100deg, var(--ink) 20%, var(--royal)); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.steps-dots i { transition: width .35s var(--ease), background .3s; }
.church-hero { box-shadow: inset 0 -80px 80px -40px rgba(30,13,65,.45); }
.site-footer .inner { background: radial-gradient(600px 300px at 100% 0%, rgba(142,102,217,.3), transparent 60%), radial-gradient(500px 260px at 0% 100%, rgba(217,172,72,.14), transparent 60%), #2A1650; box-shadow: var(--shadow-lg); }
.site-footer a { transition: color .2s, padding-left .25s var(--ease); }
.site-footer a:hover { padding-left: 3px; text-decoration: none; }
.receipt .card { position: relative; overflow: hidden; }
.receipt .card::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 6px; background: linear-gradient(90deg, #6A40B5, #D9AC48); }

/* marketplace, media, plans */
.mk-card { transition: transform .3s var(--ease), box-shadow .3s, border-color .3s; }
.mk-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); border-color: var(--line-2); text-decoration: none; }
.mk-photo { background: linear-gradient(145deg, #EFE6FC, #FFF1CF); overflow: hidden; }
.mk-photo img { transition: transform .6s var(--ease); } .mk-card:hover .mk-photo img { transform: scale(1.06); }
.media-card { transition: transform .3s var(--ease), box-shadow .3s; box-shadow: var(--shadow); border-radius: 20px; }
.media-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.media-card .th img { transition: transform .6s var(--ease); } .media-card:hover .th img { transform: scale(1.05); }
.media-card .th .tag.live, .live-tag { animation: p-pulse 2s infinite; }
.plan { transition: transform .3s var(--ease), box-shadow .3s; } .plan:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.plan.best { border: 0; background: linear-gradient(#fff, #fff) padding-box, var(--grad-gold) border-box; border: 2px solid transparent; }
.bubble { box-shadow: 0 6px 16px -12px rgba(30,21,48,.4); animation: p-pop .3s both; }
.bubble.me { background: var(--grad-royal); }
.thread .msg { animation: p-up .35s both; }
.approve-facts { background: linear-gradient(160deg, #FBF8FF, #F6F0FE); border: 1px solid var(--line); }
.post-media { border-radius: 18px; }
.pagination a, .pagination span { transition: all .2s var(--ease); }

/* ---------- mobile niceties */
@media (max-width: 1000px) {
  .sidebar { box-shadow: 20px 0 60px -20px rgba(30,13,65,.7); }
  .app.sb-open .sb-scrim { backdrop-filter: blur(3px); }
}
@media (max-width: 640px) {
  .card { border-radius: 22px; }
  .hero::before, .hero::after { display: none; }
  body, .app-body { background-attachment: scroll; }
}

/* ---------- respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  .app-content > *, main > .section > .container > *, .auth .panel .card, .auth .side,
  .kpis > *, .tiles > *, .getting-started > *, .org-grid > *, .mk-grid > *, .media-grid > *, .plans > *, .stat-strip > *, .cat-tiles > *, .choice-grid > * { opacity: 1 !important; transform: none !important; }
  @view-transition { navigation: none; }
}
@media print {
  body, .app-body { background: #fff !important; }
  .sidebar, .topbar, .btabs { display: none !important; }
  .card { background: #fff !important; box-shadow: none !important; }
  .kpi-num, .stat, .hello h1, .hero h1, .tb-title { -webkit-text-fill-color: currentColor !important; background: none !important; }
}

/* inline forms (search bars, filters) keep inputs beside their buttons */
.row > input:not([type=checkbox]):not([type=radio]), .row > select, .row > textarea,
form.row input:not([type=checkbox]):not([type=radio]):not([type=hidden]), form.row select, .mk-search .input { width: auto; flex: 1 1 160px; min-width: 0; }
.chat-reply textarea { flex: 1; }

/* dark sidebar column runs the full height of long pages */
@media (min-width: 1001px) { .app { background: linear-gradient(90deg, #22104A 0, #22104A 284px, transparent 284px); } }

/* ---------- mobile responsiveness safety net */
.split > *, .grid > *, .kpis > *, .tiles > *, .bento > *, .plans > *, .journey > *, .org-grid > *, .getting-started > *, .hero .container > * { min-width: 0; }
@media (max-width: 980px) { .split { grid-template-columns: minmax(0,1fr); } }
@media (max-width: 700px) {
  img, video, iframe, svg, canvas { max-width: 100%; }
  .card, .banner, .panel-royal { overflow-wrap: anywhere; }
  .hello { align-items: flex-start; }
  .hello .row, .list-head > .row { width: 100%; }
  .section-head { align-items: flex-start; }
  .banner { padding: 22px 20px; }
  .banner .glass-strip { width: 90px; opacity: .5; }
  .code-chip { font-size: 1.1rem; letter-spacing: .14em; }
  dl.kv { grid-template-columns: minmax(0,1fr); }
  .table-wrap { -webkit-overflow-scrolling: touch; }
  .main-table, .card > table, .stack > table, .page table { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .step-tabs { border-radius: 18px; }
  .btn-lg { padding: 14px 22px; }
  .auth .panel .card { padding: 24px 20px; }
  .type-pick { grid-template-columns: minmax(0,1fr) minmax(0,1fr); }
  .site-footer .inner { padding: 36px 22px 22px; }
}
@media (max-width: 420px) {
  .kpis { grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 10px; }
  .kpi-tile { padding: 14px; column-gap: 10px; }
  .kpi-ico { width: 38px; height: 38px; }
  .kpi-num { font-size: 1.3rem; }
  .tiles { gap: 10px; }
  .tile { padding: 14px; min-height: 88px; }
  .container { padding: 0 16px; }
}
