/* ═══════════════════════════════════════════════════════════════════
   Provalta — hero device mockup
   A flat-frame Android flagship (Galaxy-style) that spins in, then runs a
   scripted tour of the real Provalta app UI with preview data.
   The app is authored at real dp sizes on a 384×858 canvas and scaled to
   fit the display, so values here match src/app/*.tsx StyleSheets.
   ═══════════════════════════════════════════════════════════════════ */

.phone-stage {
  --pw: 300px; --ph: 648px; --depth: 9px;
  position: relative; z-index: 1;
  width: var(--pw); height: var(--ph); margin: 0 auto;
  perspective: 1800px;
}
.phone-tilt {
  width: 100%; height: 100%; transform-style: preserve-3d;
  transform: rotateX(var(--tx, 0deg)) rotateY(var(--ty, 0deg));
  transition: transform 0.6s cubic-bezier(.2, .7, .2, 1);
}
.phone { position: relative; width: 100%; height: 100%; transform-style: preserve-3d; }
/* No opacity in these keyframes: an animated opacity flattens preserve-3d,
   which would show the screen mirrored instead of the back panel. */
.phone-stage { animation: stage-in 0.5s ease-out both; }
@keyframes stage-in { from { opacity: 0; } to { opacity: 1; } }
.phone.spin { animation: phone-spin 2.6s cubic-bezier(.22, .8, .22, 1) both; }
@keyframes phone-spin {
  0%   { transform: translateY(40px) rotateX(16deg) rotateY(-540deg) scale(.72); }
  72%  { transform: translateY(-6px) rotateX(-4deg) rotateY(14deg) scale(1.02); }
  100% { transform: none; }
}

/* faces */
.phone-face {
  position: absolute; inset: 0; border-radius: 44px; padding: 3px;
  backface-visibility: hidden; -webkit-backface-visibility: hidden;
  /* satin aluminium frame */
  background:
    linear-gradient(90deg, #2B313C 0%, #A7B0BE 2.2%, #5E6674 5%, #2A2F39 14%, #20252E 50%, #2A2F39 86%, #5E6674 95%, #A7B0BE 97.8%, #2B313C 100%);
}
.phone-front {
  transform: translateZ(calc(var(--depth) / 2));
  box-shadow:
    0 50px 90px -20px rgba(0, 0, 0, 0.75),
    0 30px 60px -30px rgba(37, 99, 235, 0.35),
    inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}
.phone-back { transform: rotateY(180deg) translateZ(calc(var(--depth) / 2)); }
.phone-edge {
  position: absolute; backface-visibility: hidden; -webkit-backface-visibility: hidden;
  background: linear-gradient(90deg, #1B1F27, #8D96A5 30%, #C3CAD5 50%, #8D96A5 70%, #1B1F27);
}
.phone-edge.l, .phone-edge.r { top: 38px; bottom: 38px; width: var(--depth); left: calc(50% - var(--depth) / 2); }
.phone-edge.r { transform: rotateY(90deg) translateZ(calc(var(--pw) / 2)); }
.phone-edge.l { transform: rotateY(-90deg) translateZ(calc(var(--pw) / 2)); }
.phone-edge.t, .phone-edge.b {
  left: 38px; right: 38px; height: var(--depth); top: calc(50% - var(--depth) / 2);
  background: linear-gradient(180deg, #1B1F27, #8D96A5 30%, #C3CAD5 50%, #8D96A5 70%, #1B1F27);
}
.phone-edge.t { transform: rotateX(90deg) translateZ(calc(var(--ph) / 2)); }
.phone-edge.b { transform: rotateX(-90deg) translateZ(calc(var(--ph) / 2)); }

/* side keys (right edge, front view) */
.phone-key {
  position: absolute; right: -2px; width: 3px; border-radius: 0 2px 2px 0;
  background: linear-gradient(90deg, #6B7381, #B9C1CD 60%, #4A515C);
  box-shadow: 1px 0 2px rgba(0, 0, 0, 0.5);
}
.phone-key.vol { top: 128px; height: 66px; }
.phone-key.pwr { top: 206px; height: 40px; }

/* black bezel + display */
.phone-bezel {
  width: 100%; height: 100%; border-radius: 41px; padding: 6px;
  background: #010204; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.05);
}
.phone-display {
  position: relative; width: 100%; height: 100%; border-radius: 35px; overflow: hidden;
  background: #060D1C; isolation: isolate;
}
.phone-display::after { /* glass reflection */
  content: ""; position: absolute; inset: 0; z-index: 30; pointer-events: none;
  background: linear-gradient(118deg, rgba(255, 255, 255, 0.07) 0%, rgba(255, 255, 255, 0.02) 26%, transparent 40%);
}
.phone-punch {
  position: absolute; top: 9px; left: 50%; z-index: 31; transform: translateX(-50%);
  width: 10px; height: 10px; border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #1D2A44 0 18%, #04060B 40%);
  box-shadow: 0 0 0 1.5px #000;
}

/* back glass + floating triple camera */
.phone-back-glass {
  position: relative; width: 100%; height: 100%; border-radius: 41px; overflow: hidden;
  background:
    radial-gradient(120% 80% at 20% 0%, rgba(147, 197, 253, 0.18), transparent 55%),
    linear-gradient(165deg, #2C3B57 0%, #1A2438 48%, #23314B 100%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.07);
}
.phone-back-glass::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(115deg, transparent 30%, rgba(255, 255, 255, 0.08) 45%, transparent 60%);
}
.cam-col { position: absolute; top: 26px; left: 26px; display: flex; flex-direction: column; gap: 9px; }
.cam {
  width: 42px; height: 42px; border-radius: 50%; position: relative;
  background: radial-gradient(circle, #05070C 0 44%, #1D2433 46% 52%, #0A0D14 54%);
  box-shadow: 0 0 0 2.5px #8C95A4, 0 0 0 3.5px #2A303A, 0 4px 10px rgba(0, 0, 0, 0.5);
}
.cam::after {
  content: ""; position: absolute; top: 12px; left: 12px; width: 18px; height: 18px; border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, rgba(96, 165, 250, 0.55), rgba(124, 58, 237, 0.25) 45%, transparent 70%);
}
.cam-flash {
  position: absolute; top: 34px; left: 82px; width: 11px; height: 11px; border-radius: 50%;
  background: radial-gradient(circle, #F8F1DF 0 40%, #B9B2A0 70%);
  box-shadow: 0 0 0 1.5px #59606B;
}
.cam-mic { position: absolute; top: 60px; left: 85px; width: 4px; height: 4px; border-radius: 50%; background: #0B0F17; }

/* ── App canvas (dp units, scaled to the display) ── */
.pv-app {
  --s: calc((var(--pw) - 18px) / 384px);
  position: absolute; left: 0; top: 0; width: 384px; height: 858px;
  transform: scale(0.734375); transform-origin: 0 0;
  font-family: 'Roboto', 'Inter', system-ui, sans-serif; color: #fff; line-height: 1.25;
  overflow: hidden; text-align: left; -webkit-font-smoothing: antialiased;
}
.pv-app .feather { width: var(--i, 18px); height: var(--i, 18px); stroke-width: 2; flex-shrink: 0; display: block; }
.pv-app p, .pv-app h4, .pv-app h5 { margin: 0; }
.pv-app [hidden] { display: none !important; }

.pv-status {
  position: absolute; z-index: 20; top: 0; left: 0; right: 0; height: 34px;
  display: flex; align-items: center; justify-content: space-between; padding: 4px 26px 0;
  font-size: 14px; font-weight: 500; color: #fff; pointer-events: none;
}
.pv-status-icons { display: flex; gap: 6px; align-items: center; }
.pv-status-icons .feather { --i: 14px; }
.pv-navbar {
  position: absolute; z-index: 20; left: 50%; bottom: 8px; transform: translateX(-50%);
  width: 112px; height: 4px; border-radius: 999px; background: rgba(255, 255, 255, 0.72);
}

/* screens & navigation */
.pv-screen {
  position: absolute; inset: 0; display: flex; flex-direction: column; overflow: hidden;
  background: #060D1C; padding-top: 34px;
  isolation: isolate; /* keeps .pv-bg (z-index:-1) above this background */
  transform: translateX(100%); visibility: hidden;
  transition: transform 0.42s cubic-bezier(.2, .8, .2, 1), filter 0.42s ease, visibility 0s linear 0.42s;
}
.pv-screen.active { transform: none; visibility: visible; transition-delay: 0s; }
.pv-screen.behind { transform: translateX(-26%); filter: brightness(0.55); visibility: visible; transition-delay: 0s; }
.pv-bg { position: absolute; inset: 0; z-index: -1; background-size: cover; background-position: center; }
.pv-bg::after { content: ""; position: absolute; inset: 0; background: var(--ov, rgba(5, 10, 20, 0.78)); }
.pv-body { flex: 1; overflow: hidden; position: relative; }
.pv-tap {
  position: absolute; z-index: 40; width: 46px; height: 46px; margin: -23px 0 0 -23px; border-radius: 50%;
  background: rgba(255, 255, 255, 0.45); box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.5);
  opacity: 0; transform: scale(0.3); pointer-events: none;
}
.pv-tap.go { animation: pv-tap 0.6s ease-out; }
@keyframes pv-tap {
  0% { opacity: 0.95; transform: scale(0.35); }
  100% { opacity: 0; transform: scale(1.5); }
}

/* shared atoms */
.pv-iconbtn {
  position: relative; width: 44px; height: 44px; border-radius: 12px; flex-shrink: 0;
  background: rgba(255, 255, 255, 0.12); display: grid; place-items: center; color: #fff;
}
.pv-iconbtn .feather { --i: 22px; }
.pv-row { display: flex; align-items: center; }
.pv-grow { flex: 1; min-width: 0; }
.pv-sechead { display: flex; justify-content: space-between; align-items: center; margin-bottom: -4px; }
.pv-sectitle { font-size: 17px; font-weight: 800; }
.pv-link { color: #3B82F6; font-size: 14px; font-weight: 600; }
.pv-badge {
  align-self: flex-start; display: inline-block; padding: 3px 8px; border-radius: 20px;
  border: 1px solid var(--c); background: color-mix(in srgb, var(--c) 13%, transparent);
  color: var(--c); font-size: 10px; font-weight: 700; transition: all 0.3s ease;
}
.pv-card {
  background: rgba(14, 22, 42, 0.92); border-radius: 20px;
  border: 1px solid rgba(59, 130, 246, 0.12); overflow: hidden;
}
.pv-muted { color: #64748B; }
.pv-ellipsis { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ── Dashboard ── */
.db-top { display: flex; justify-content: space-between; padding: 8px 20px 4px; }
.db-top-right { display: flex; gap: 10px; align-items: center; }
.db-ai {
  display: flex; align-items: center; gap: 5px; height: 44px; padding: 0 16px; border-radius: 22px;
  background: linear-gradient(135deg, #7C3AED, #3B82F6); box-shadow: 0 4px 10px rgba(124, 58, 237, 0.5);
  font-size: 14px; font-weight: 800; letter-spacing: 0.5px;
}
.db-ai .feather { --i: 15px; }
.db-dot {
  position: absolute; top: 6px; right: 6px; width: 10px; height: 10px; border-radius: 5px;
  background: #EF4444; border: 2px solid #060D1C;
}
.db-greet { padding: 10px 22px 20px; }
.db-greet-line { color: #CBD5E1; font-size: 16px; font-weight: 500; }
.db-greet-name { font-size: 32px; font-weight: 900; margin-top: 2px; }
.db-greet-sub { color: #64748B; font-size: 14px; margin-top: 4px; }
.db-scroll { display: flex; flex-direction: column; gap: 14px; padding: 0 16px 60px; }
.db-portfolio {
  position: relative; height: 168px; padding: 20px; border-radius: 22px; overflow: hidden;
  background: rgba(11, 20, 42, 0.97); border: 1px solid rgba(59, 130, 246, 0.25);
  box-shadow: 0 8px 20px rgba(29, 78, 216, 0.3);
}
.db-spark { position: absolute; right: 0; bottom: 0; }
.db-port-top { position: relative; display: flex; justify-content: space-between; align-items: center; margin-bottom: 4px; }
.db-port-label { display: flex; align-items: center; gap: 8px; color: #94A3B8; font-size: 13px; font-weight: 500; }
.db-port-label .feather { --i: 15px; }
.db-port-badge {
  background: rgba(37, 99, 235, 0.22); border-radius: 20px; padding: 5px 12px;
  border: 1px solid rgba(96, 165, 250, 0.35); color: #93C5FD; font-weight: 700; font-size: 13px;
}
.db-port-value { position: relative; font-size: 38px; font-weight: 900; letter-spacing: -1.5px; margin-top: 2px; }
.db-port-growth { position: relative; display: flex; align-items: center; gap: 6px; margin-top: 10px; font-size: 15px; }
.db-port-growth .feather { --i: 16px; color: #22C55E; }
.db-port-growth b { color: #22C55E; font-weight: 800; }
.db-port-growth span { color: #94A3B8; font-weight: 500; }
.db-summary { display: flex; gap: 12px; }
.db-sum-card {
  flex: 1; padding: 18px; border-radius: 22px;
  background: rgba(13, 25, 50, 0.95); border: 1px solid rgba(59, 130, 246, 0.18);
  box-shadow: 0 6px 12px rgba(37, 99, 235, 0.18);
}
.db-sum-icon {
  width: 40px; height: 40px; border-radius: 12px; margin-bottom: 14px;
  background: rgba(37, 99, 235, 0.15); display: grid; place-items: center; color: #4F8DFF;
}
.db-sum-label { color: #B8C3D9; font-size: 13px; line-height: 20px; margin-bottom: 8px; }
.db-sum-amount { font-size: 24px; font-weight: 800; margin-bottom: 8px; }
.db-trend { display: flex; align-items: center; gap: 3px; color: #22C55E; font-size: 13px; font-weight: 700; }
.db-trend .feather { --i: 13px; }
.db-tiles { display: flex; gap: 8px; }
.db-tile {
  flex: 1; display: flex; flex-direction: column; gap: 3px; padding: 12px; border-radius: 16px;
  background: rgba(14, 22, 42, 0.92); border: 1px solid rgba(59, 130, 246, 0.12);
}
.db-tile-icon { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; margin-bottom: 4px; }
.db-tile-icon .feather { --i: 16px; }
.db-tile-label { color: #64748B; font-size: 10px; font-weight: 500; }
.db-tile-value { font-size: 17px; font-weight: 800; }
.db-tile-green { color: #22C55E; font-size: 11px; font-weight: 600; }
.db-list { padding: 4px 0; }
.db-due-row { display: flex; align-items: center; padding: 12px 14px; }
.db-due-row + .db-due-row, .db-prop-row + .db-prop-row { border-top: 1px solid rgba(255, 255, 255, 0.06); }
.db-due-icon {
  width: 36px; height: 36px; border-radius: 11px; margin-right: 10px; display: grid; place-items: center;
  color: var(--c); background: color-mix(in srgb, var(--c) 10%, transparent);
}
.db-due-icon .feather { --i: 16px; }
.db-name { font-size: 14px; font-weight: 800; }
.db-sub { color: #64748B; font-size: 12px; margin: 2px 0 6px; }
.db-due-right { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; margin-left: 10px; }
.db-amount { font-size: 14px; font-weight: 800; }
.db-paid-btn {
  display: flex; align-items: center; gap: 5px; padding: 6px 10px; border-radius: 10px;
  background: rgba(34, 197, 94, 0.12); border: 1px solid rgba(34, 197, 94, 0.35);
  color: #22C55E; font-size: 12px; font-weight: 800;
}
.db-paid-btn .feather { --i: 13px; }
.db-prop-row { display: flex; align-items: center; padding: 12px 14px; }
.db-thumb { width: 68px; height: 68px; border-radius: 14px; background: #1E293B center / cover no-repeat; flex-shrink: 0; }
.db-prop-info { flex: 1; min-width: 0; margin-left: 12px; display: flex; flex-direction: column; }
.db-prop-name { font-size: 14px; font-weight: 700; }
.db-prop-addr { color: #64748B; font-size: 11px; margin: 2px 0 6px; }
.db-prop-right { text-align: right; }
.db-prop-value { font-size: 13px; font-weight: 700; }
.db-prop-sub { color: #64748B; font-size: 11px; margin-top: 2px; }
.db-chev { color: #4B5563; margin-left: 6px; }
.db-export {
  display: flex; align-items: center; gap: 5px; padding: 6px 10px; border-radius: 10px;
  background: rgba(59, 130, 246, 0.12); border: 1px solid rgba(59, 130, 246, 0.3);
  color: #3B82F6; font-size: 12px; font-weight: 700;
}
.db-export .feather { --i: 15px; }
.db-act { padding: 16px; }
.db-act-row { display: flex; align-items: center; }
.db-act-row + .db-act-row { border-top: 1px solid rgba(255, 255, 255, 0.06); margin-top: 14px; padding-top: 14px; }
.db-act-icon { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; flex-shrink: 0; }
.db-act-text { flex: 1; min-width: 0; margin-left: 12px; }
.db-act-label { font-size: 14px; font-weight: 700; }
.db-act-sub { color: #64748B; font-size: 12px; margin-top: 2px; }
.db-act-amt { font-size: 14px; font-weight: 800; text-align: right; }
.db-act-date { color: #64748B; font-size: 12px; margin-top: 2px; text-align: right; }

/* drawer */
.db-drawer {
  position: absolute; z-index: 15; left: 0; top: 0; bottom: 0; width: 288px; padding: 54px 20px 20px;
  background: #080F1E; border-right: 1px solid rgba(59, 130, 246, 0.15);
  box-shadow: 0 0 24px rgba(0, 0, 0, 0.5);
  transform: translateX(-100%); transition: transform 0.32s cubic-bezier(.2, .8, .2, 1);
}
.db-drawer.open { transform: none; }
.db-drawer-title { font-size: 20px; font-weight: 800; margin-bottom: 4px; }
.db-drawer-sub { color: #64748B; margin-bottom: 24px; font-size: 14px; }
.db-drawer-item {
  display: flex; align-items: center; gap: 14px; padding: 14px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05); font-size: 16px; font-weight: 600;
}
.db-drawer-item .feather { --i: 20px; color: #3B82F6; }

/* ── Shared screen chrome (ScreenHeader + cards, tenants.tsx / maintenance.tsx) ── */
.sc-scroll { display: flex; flex-direction: column; gap: 14px; padding: 8px 16px 60px; }
.sc-head { display: flex; align-items: center; gap: 12px; min-height: 48px; margin-bottom: 6px; }
.sc-back {
  width: 42px; height: 42px; border-radius: 14px; flex-shrink: 0; display: grid; place-items: center;
  background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.25);
}
.sc-back .feather { --i: 22px; }
.sc-title { font-size: 23px; font-weight: 800; letter-spacing: -0.4px; white-space: nowrap; }
.sc-subtitle { color: #8B93A7; font-size: 12px; font-weight: 600; margin-top: 3px; }
.sc-spacer { width: 42px; }
.sc-right .feather { --i: 20px; }
.sc-summary { display: flex; gap: 12px; }
.sc-sum-card {
  flex: 1; padding: 18px; border-radius: 22px;
  background: rgba(13, 25, 50, 0.95); border: 1px solid rgba(59, 130, 246, 0.18);
}
.sc-sum-icon { width: 40px; height: 40px; border-radius: 12px; margin-bottom: 14px; display: grid; place-items: center; }
.sc-sum-label { color: #B8C3D9; font-size: 13px; line-height: 20px; margin-bottom: 8px; }
.sc-sum-amount { font-size: 24px; font-weight: 800; margin-bottom: 4px; }
.sc-sum-sub { color: #64748B; font-size: 12px; }
.sc-actions { display: flex; gap: 10px; }
.sc-primary {
  flex: 1; display: flex; align-items: center; justify-content: center; gap: 8px;
  padding: 14px 0; border-radius: 16px; background: #2563EB; font-size: 16px; font-weight: 800;
}
.sc-primary .feather { --i: 20px; }
.sc-primary.sc-full { margin-bottom: 6px; }
.sc-square {
  width: 52px; border-radius: 16px; display: grid; place-items: center;
  background: #1E40AF; border: 1px solid rgba(96, 165, 250, 0.3);
}
.sc-square .feather { --i: 20px; }
.sc-card {
  padding: 14px; border-radius: 22px;
  background: rgba(14, 22, 42, 0.92); border: 1px solid rgba(59, 130, 246, 0.18);
}
.sc-card-top { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.sc-avatar {
  width: 44px; height: 44px; border-radius: 14px; flex-shrink: 0; display: grid; place-items: center;
  background: rgba(59, 130, 246, 0.15); border: 1px solid rgba(59, 130, 246, 0.2); color: #60A5FA;
}
.sc-avatar .feather { --i: 20px; }
.sc-avatar-accent {
  color: var(--c); background: color-mix(in srgb, var(--c) 15%, transparent);
  border-color: color-mix(in srgb, var(--c) 30%, transparent); transition: all 0.3s ease;
}
.sc-avatar-accent .feather { --i: 18px; }
.sc-name { font-size: 16px; font-weight: 900; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sc-prop { color: #94A3B8; font-size: 13px; margin-top: 2px; }
.sc-email { color: #60A5FA; font-size: 12px; margin-top: 1px; }
.sc-more {
  width: 34px; height: 34px; border-radius: 10px; flex-shrink: 0; display: grid; place-items: center;
  background: rgba(255, 255, 255, 0.06); color: #94A3B8;
}
.sc-desc { color: #94A3B8; font-size: 13px; line-height: 20px; margin: -2px 0 10px; }
.sc-details { display: flex; align-items: flex-start; gap: 12px; }
.sc-details > :last-child { margin-left: auto; }
.sc-dlabel { color: #64748B; font-size: 11px; margin-bottom: 2px; }
.sc-rent { color: #22C55E; font-size: 18px; font-weight: 900; }
.sc-dvalue { font-size: 14px; font-weight: 700; margin-top: 2px; }
.sc-status-col { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.sc-status {
  display: inline-flex; align-items: center; gap: 4px; padding: 5px 10px; border-radius: 20px;
  color: var(--c); background: color-mix(in srgb, var(--c) 13%, transparent);
  border: 1px solid color-mix(in srgb, var(--c) 27%, transparent);
  font-size: 11px; transition: all 0.3s ease;
}
.sc-status b { font-weight: 800; }
.sc-status .feather { --i: 12px; }
.sc-autopay { background: rgba(59, 130, 246, 0.15); border-color: rgba(59, 130, 246, 0.4); }
.sc-markpaid, .sc-toggle {
  display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 12px;
  padding: 12px 0; border-radius: 14px; font-size: 14px; font-weight: 800;
}
.sc-markpaid { color: #22C55E; background: rgba(34, 197, 94, 0.12); border: 1px solid rgba(34, 197, 94, 0.35); }
.sc-markpaid .feather, .sc-toggle .feather { --i: 16px; }
.sc-toggle {
  color: var(--c); background: color-mix(in srgb, var(--c) 12%, transparent);
  border: 1px solid color-mix(in srgb, var(--c) 35%, transparent); transition: all 0.3s ease;
}
.sc-toggle b { font-weight: 800; }
.sc-paidrow {
  display: flex; align-items: center; gap: 8px; margin-top: 12px; padding: 12px 14px; border-radius: 14px;
  color: #22C55E; background: rgba(34, 197, 94, 0.1); border: 1px solid rgba(34, 197, 94, 0.3);
}
.sc-paidrow[hidden] { display: none; }
.sc-paidrow .feather { --i: 14px; }
.sc-paidrow b { flex: 1; font-size: 13px; font-weight: 800; }
.sc-paidrow span { color: #64748B; font-size: 12px; font-weight: 600; }
.pv-flash { animation: pv-flash 0.9s ease; }
@keyframes pv-flash { 0% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.6); } 100% { box-shadow: 0 0 0 14px rgba(34, 197, 94, 0); } }

/* ── Insights (insights.tsx) ── */
.in-scroll { padding: 8px 16px 60px; }
.in-dl { background: rgba(59, 130, 246, 0.15); color: #4F8DFF; }
.in-dl .feather { --i: 18px; }
.in-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.in-card {
  padding: 16px; border-radius: 22px;
  background: rgba(12, 24, 46, 0.96); border: 1px solid rgba(59, 130, 246, 0.15);
}
.in-icon {
  width: 40px; height: 40px; border-radius: 14px; margin-bottom: 12px; display: grid; place-items: center;
  color: var(--c); background: color-mix(in srgb, var(--c) 15%, transparent);
}
.in-label { color: #9FB2D6; font-size: 12px; }
.in-value { font-size: 22px; font-weight: 900; margin: 4px 0 8px; }
.in-trend { display: flex; align-items: center; gap: 4px; color: #22C55E; font-size: 12px; font-weight: 700; }
.in-trend .feather { --i: 13px; }
.in-chart {
  padding: 20px; border-radius: 24px;
  background: rgba(12, 24, 46, 0.96); border: 1px solid rgba(59, 130, 246, 0.15);
  box-shadow: 0 10px 18px rgba(37, 99, 235, 0.18);
}
.in-chart-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; font-size: 18px; font-weight: 800; }
.in-pill {
  display: flex; align-items: center; gap: 4px; padding: 6px 10px; border-radius: 10px;
  background: rgba(255, 255, 255, 0.06); color: #CBD5E1; font-size: 12px; font-weight: 500;
}
.in-pill .feather { --i: 14px; color: #94A3B8; }
.in-legend { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-bottom: 14px; color: #94A3B8; font-size: 12px; }
.in-legend span { display: flex; align-items: center; gap: 6px; }
.in-legend span::before { content: ""; width: 10px; height: 10px; border-radius: 3px; background: var(--c); }
#inLine { display: block; overflow: visible; }
.in-line-path { stroke-dasharray: 1; stroke-dashoffset: 1; }
.pv-screen.active .in-line-path { animation: in-draw 1.6s 0.3s ease-out forwards; }
@keyframes in-draw { to { stroke-dashoffset: 0; } }
.in-donut-wrap { display: flex; align-items: center; }
.in-donut { position: relative; width: 140px; height: 140px; flex-shrink: 0; display: grid; place-items: center; }
.in-donut::before {
  content: ""; position: absolute; inset: 0; border-radius: 50%;
  background: conic-gradient(#EC4899 0 53%, #3B82F6 0 75%, #06B6D4 0 87%, #22C55E 0 94%, #F59E0B 0 100%);
  -webkit-mask: radial-gradient(circle, transparent 29px, #000 30px);
  mask: radial-gradient(circle, transparent 29px, #000 30px);
}
.in-donut > div { position: relative; text-align: center; }
.in-donut b { display: block; font-size: 15px; font-weight: 900; }
.in-donut span { color: #94A3B8; font-size: 11px; }
.in-donut-legend { flex: 1; margin-left: 16px; }
.in-donut-legend > div { display: flex; align-items: center; margin-bottom: 10px; }
.in-donut-legend i { width: 12px; height: 12px; border-radius: 6px; margin-right: 10px; background: var(--c); flex-shrink: 0; }
.in-donut-legend p { flex: 1; display: flex; flex-direction: column; }
.in-donut-legend b { font-size: 13px; font-weight: 700; }
.in-donut-legend span { color: #94A3B8; font-size: 12px; }
.in-donut-legend em { font-style: normal; font-size: 13px; font-weight: 800; }
.in-bars { display: flex; align-items: flex-end; justify-content: space-between; height: 170px; padding: 0 2px 20px; position: relative; border-bottom: 1px solid rgba(59, 130, 246, 0.15); }
.in-bars > div { position: relative; display: flex; align-items: flex-end; gap: 4px; height: 100%; }
.in-bars span { width: 12px; border-radius: 4px 4px 0 0; height: 0; transition: height 0.9s cubic-bezier(.2, .8, .2, 1); }
.in-bars em { position: absolute; bottom: -20px; left: 0; font-style: normal; font-size: 11px; color: #94A3B8; }
.in-gauge { position: relative; width: 170px; margin: 0 auto; }
.in-gauge svg { display: block; }
.in-gauge-fill { stroke-dasharray: 0 100; transition: stroke-dasharray 1.2s cubic-bezier(.2, .8, .2, 1); }
.pv-screen.active .in-gauge-fill { stroke-dasharray: 88.8 100; }
.in-gauge-text { position: absolute; left: 0; right: 0; top: 44px; text-align: center; }
.in-gauge-text b { display: block; font-size: 24px; font-weight: 900; }
.in-gauge-text span { color: #94A3B8; font-size: 12px; }
.in-gauge-scale { display: flex; justify-content: space-between; padding: 4px 4px 0; color: #64748B; font-size: 11px; }

/* ── AI Assistant (ai-assistant.tsx) ── */
.ai-head {
  display: flex; align-items: center; gap: 8px; padding: 8px 16px 12px;
  border-bottom: 1px solid rgba(59, 130, 246, 0.15);
}
.ai-head .sc-back { margin-right: 4px; }
.ai-head .sc-title { font-size: 20px; }
.ai-box {
  width: 40px; height: 40px; border-radius: 12px; flex-shrink: 0; display: grid; place-items: center;
  background: rgba(59, 130, 246, 0.15); border: 1px solid rgba(59, 130, 246, 0.3); color: #93C5FD;
}
.ai-box .feather { --i: 16px; }
.ai-list { display: flex; flex-direction: column; gap: 10px; padding: 16px; transition: transform 0.35s ease; }
.ai-msg { max-width: 85%; padding: 12px; border-radius: 16px; font-size: 14px; line-height: 20px; animation: ai-in 0.35s ease-out; }
.ai-msg.bot { align-self: flex-start; color: #E2E8F0; background: rgba(14, 22, 42, 0.95); border: 1px solid rgba(59, 130, 246, 0.2); }
.ai-msg.bot .feather { --i: 14px; color: #93C5FD; margin-bottom: 4px; }
.ai-msg.bot b { font-weight: 800; color: #fff; }
.ai-msg.user { align-self: flex-end; background: #2563EB; color: #fff; }
.ai-msg.thinking { display: flex; flex-direction: column; align-items: center; gap: 6px; color: #94A3B8; padding: 14px 18px; }
/* Thinking: the Provalta logo pulses and bobs while a soft glow spreads behind it (matches the app). */
.ai-think { position: relative; width: 36px; height: 36px; display: grid; place-items: center; flex-shrink: 0; }
.ai-think img { position: relative; width: 30px; height: 30px; object-fit: contain; animation: ai-think-logo 1.3s ease-in-out infinite; }
.ai-think-ring { position: absolute; inset: 0; border-radius: 50%; background: rgba(59, 130, 246, 0.18); animation: ai-think-ring 1.3s ease-out infinite; }
@keyframes ai-think-logo { 0%, 100% { transform: translateY(1.5px) scale(0.9); } 50% { transform: translateY(-1.5px) scale(1.08); } }
@keyframes ai-think-ring { from { transform: scale(0.8); opacity: 0.55; } to { transform: scale(1.6); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .ai-think img, .ai-think-ring { animation: none; } }
.ai-spinner { width: 14px; height: 14px; border-radius: 50%; border: 2px solid rgba(147, 197, 253, 0.3); border-top-color: #93C5FD; animation: ai-spin 0.8s linear infinite; }
@keyframes ai-spin { to { transform: rotate(360deg); } }
@keyframes ai-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.ai-chips { display: flex; gap: 8px; padding: 8px 16px; overflow: hidden; white-space: nowrap; }
.ai-chips span {
  flex-shrink: 0; padding: 8px 12px; border-radius: 20px;
  background: rgba(59, 130, 246, 0.12); border: 1px solid rgba(59, 130, 246, 0.3);
  color: #93C5FD; font-size: 12px; font-weight: 600;
}
.ai-inputbar { display: flex; align-items: flex-end; gap: 10px; padding: 16px 16px 30px; border-top: 1px solid rgba(59, 130, 246, 0.15); }
.ai-input {
  flex: 1; min-height: 46px; display: flex; align-items: center; padding: 12px 14px; border-radius: 14px;
  background: rgba(14, 22, 42, 0.95); border: 1px solid rgba(59, 130, 246, 0.25); font-size: 14px;
}
.ai-placeholder { color: #475569; }
.ai-typed:not(:empty) { color: #fff; }
.ai-typed:not(:empty)::after { content: ""; display: inline-block; width: 1.5px; height: 16px; margin-left: 1px; vertical-align: -3px; background: #93C5FD; animation: ai-caret 1s steps(1) infinite; }
.ai-input.has-text .ai-placeholder { display: none; }
@keyframes ai-caret { 50% { opacity: 0; } }
.ai-send {
  width: 46px; height: 46px; border-radius: 14px; flex-shrink: 0; display: grid; place-items: center;
  background: #2563EB; opacity: 0.4; transition: opacity 0.2s ease;
}
.ai-send.ready { opacity: 1; }

.pv-app.off { filter: brightness(0); transition: filter 0.35s ease; }
.pv-app { transition: filter 0.45s ease; }

/* ── Utilities step (Add Property → step 4), port of add-property.tsx ── */
.util-stage .phone-tilt { --tx: 4deg; --ty: -10deg; }
.util-stage .phone-front { transform: none; }
.ut-scroll { display: flex; flex-direction: column; padding: 8px 16px 40px; }
.ut-progress { margin: 6px 0 18px; }
.ut-progress p { color: #94A3B8; font-size: 12px; margin-bottom: 10px; }
.ut-dots { display: flex; justify-content: space-between; }
.ut-dot {
  width: 26px; height: 26px; border-radius: 999px; display: grid; place-items: center;
  background: rgba(30, 41, 59, 0.9); border: 1px solid rgba(59, 130, 246, 0.14);
  color: #94A3B8; font-size: 12px; font-weight: 800;
}
.ut-dot.on { background: #3B82F6; border-color: #3B82F6; color: #fff; }
.ut-card {
  background: rgba(15, 23, 42, 0.9); border-radius: 28px; padding: 16px;
  border: 1px solid rgba(59, 130, 246, 0.18);
}
.ut-cardhead { display: flex; align-items: flex-start; margin-bottom: 16px; }
.ut-headicon {
  width: 40px; height: 40px; border-radius: 14px; margin-right: 12px; flex-shrink: 0;
  display: grid; place-items: center; color: #60A5FA;
  background: rgba(59, 130, 246, 0.14); border: 1px solid rgba(59, 130, 246, 0.22);
}
.ut-headicon .feather { --i: 20px; }
.ut-steptitle { font-size: 18px; font-weight: 900; margin-bottom: 4px !important; }
.ut-stepsub { color: #94A3B8; font-size: 12px; line-height: 18px; }
.ut-connect {
  display: flex; align-items: center; padding: 12px; border-radius: 18px; margin-bottom: 10px;
  background: rgba(16, 185, 129, 0.12); border: 1px solid rgba(16, 185, 129, 0.35);
}
.ut-connect-ic {
  width: 38px; height: 38px; border-radius: 13px; margin-right: 12px; flex-shrink: 0;
  display: grid; place-items: center; background: #10B981; color: #fff;
}
.ut-connect-ic .feather { --i: 16px; }
.ut-connect b { font-size: 14px; }
.ut-connect-sub { color: #6EE7B7; font-size: 11px; font-weight: 600; margin-top: 2px; }
.ut-chev { --i: 16px; color: #94A3B8; }
.ut-banner {
  display: flex; align-items: center; gap: 8px; padding: 10px; border-radius: 14px; margin-bottom: 10px;
  background: rgba(52, 211, 153, 0.08); border: 1px solid rgba(52, 211, 153, 0.25);
  color: #6EE7B7; font-size: 11px; font-weight: 600; line-height: 17px;
}
.ut-banner .feather { --i: 14px; color: #34D399; }
.ut-item {
  display: flex; align-items: center; padding: 12px; border-radius: 16px; margin-bottom: 10px;
  background: rgba(30, 41, 59, 0.65); border: 1px solid rgba(59, 130, 246, 0.10);
}
.ut-chip {
  width: 36px; height: 36px; border-radius: 12px; margin-right: 12px; flex-shrink: 0;
  display: grid; place-items: center; color: var(--c);
  background: color-mix(in srgb, var(--c) 13%, transparent);
}
.ut-chip .feather { --i: 16px; }
.ut-text { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.ut-text b { font-size: 14px; font-weight: 900; }
.ut-detail, .ut-ph { font-size: 12px; font-weight: 600; margin-top: 2px; line-height: 17px; color: #94A3B8; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ut-ph { color: #64748B; }
.ut-amt { display: flex; flex-direction: column; align-items: flex-end; flex-shrink: 1; max-width: 34%; margin-left: 4px; }
.ut-amt b { font-size: 13px; font-weight: 800; }
.ut-amt i { font-style: normal; color: #64748B; font-size: 10px; font-weight: 600; margin-top: 2px; text-align: right; }
.ut-add { color: #3B82F6; font-size: 13px; font-weight: 800; }
.ut-link {
  margin-left: 8px; width: 36px; height: 36px; border-radius: 12px; flex-shrink: 0;
  display: grid; place-items: center; color: #34D399;
  background: rgba(52, 211, 153, 0.12); border: 1px solid rgba(52, 211, 153, 0.22);
}
.ut-link .feather { --i: 15px; }

@media (max-width: 640px) {
  .phone-stage { zoom: 0.86; }
}
@media (prefers-reduced-motion: reduce) {
  .phone.spin, .phone-stage { animation: none; }
  .pv-screen, .db-drawer, .phone-tilt { transition: none; }
}
