.aif-section {
    --aif-ink: #0a0a0a;
    --aif-muted: rgba(26, 26, 26, 0.62);
    --aif-line: rgba(15, 23, 42, 0.08);
    background: #f7f7f5;
    color: var(--aif-ink);
    isolation: isolate;
}
.aif-bg {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    background:
        radial-gradient(50% 40% at 92% 8%, color-mix(in srgb, var(--aif-accent) 4%, transparent) 0%, transparent 70%),
        radial-gradient(40% 35% at 8% 92%, rgba(99, 102, 241, 0.04) 0%, transparent 75%),
        linear-gradient(180deg, #fafaf8 0%, #f6f5f3 100%);
}
.aif-wrap {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
    position: relative;
    z-index: 1;
}
@media (min-width: 768px) { .aif-wrap { padding: 0 40px; } }

/* Header */
.aif-header { max-width: 720px; margin-bottom: 44px; }
.aif-eyebrow {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: rgba(26, 26, 26, 0.45);
    margin-bottom: 16px;
}
.aif-title {
    margin: 0;
    color: #0a0a0a;
    font-size: 1.875rem;
    line-height: 1.05;
    letter-spacing: -0.025em;
    font-weight: 700;
}
@media (min-width: 768px) {
    .aif-title { font-size: 3rem; }
}
.aif-subtitle {
    margin: 16px 0 0;
    color: rgba(26, 26, 26, 0.6);
    font-size: 16px;
    line-height: 1.6;
    max-width: 600px;
    font-weight: 400;
}

/* Rows: 2 / 3 / 2 */
.aif-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 18px;
    margin-bottom: 18px;
}
.aif-row:last-child { margin-bottom: 0; }
@media (min-width: 768px) {
    .aif-row { gap: 22px; margin-bottom: 22px; }
    .aif-row--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .aif-row--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* Light cards */
.aif-card {
    position: relative;
    background: #ffffff;
    border: 1px solid rgba(15, 23, 42, 0.06);
    border-radius: 24px;
    padding: 28px 28px 0;
    display: flex;
    flex-direction: column;
    gap: 18px;
    overflow: hidden;
    isolation: isolate;
    min-height: 360px;
    transition: transform 0.4s cubic-bezier(.2,.8,.2,1), border-color 0.3s ease, box-shadow 0.4s cubic-bezier(.2,.8,.2,1);
    box-shadow:
        0 0 0 1px rgba(15, 23, 42, 0.02),
        0 1px 2px rgba(15, 23, 42, 0.025),
        0 6px 14px -2px rgba(15, 23, 42, 0.04),
        0 18px 36px -8px rgba(15, 23, 42, 0.05),
        0 36px 72px -16px rgba(15, 23, 42, 0.06);
}
.aif-card::before { content: none; }
.aif-card:hover {
    transform: translateY(-3px);
    border-color: color-mix(in srgb, var(--aif-accent) 15%, rgba(15, 23, 42, 0.08));
    box-shadow:
        0 0 0 1px rgba(15, 23, 42, 0.025),
        0 2px 4px rgba(15, 23, 42, 0.03),
        0 8px 18px -2px rgba(15, 23, 42, 0.05),
        0 24px 48px -8px rgba(15, 23, 42, 0.07),
        0 48px 96px -20px rgba(15, 23, 42, 0.08);
}
.aif-card > * { position: relative; z-index: 1; }
.aif-row--2 .aif-card { min-height: 460px; }
.aif-row--3 .aif-card { min-height: 380px; }

/* Tags */
.aif-card__head { display: flex; align-items: center; justify-content: space-between; }
.aif-tag {
    display: inline-flex;
    align-items: center;
    padding: 5px 12px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: color-mix(in srgb, var(--aif-accent) 80%, #1a1a1a);
    background: color-mix(in srgb, var(--aif-accent) 10%, #fff);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 22%, transparent);
}

/* Copy */
.aif-card__copy { display: flex; flex-direction: column; gap: 10px; }
.aif-card__title {
    margin: 0;
    color: var(--aif-ink);
    font-size: clamp(1.15rem, 1.6vw, 1.5rem);
    font-weight: 600;
    letter-spacing: -0.02em;
    line-height: 1.22;
}
.aif-row--2 .aif-card__title { font-size: clamp(1.375rem, 1.9vw, 1.75rem); }
.aif-card__text {
    margin: 0;
    color: var(--aif-muted);
    font-size: 14.5px;
    line-height: 1.55;
    max-width: 460px;
}

/* Visual area */
.aif-visual {
    position: relative;
    margin: 8px -28px -28px -28px;
    padding: 22px 26px 26px;
    overflow: hidden;
    border-radius: 0 0 24px 24px;
    flex: 1;
    display: flex;
    align-items: stretch;
    background: #fafaf8;
    border-top: 1px solid rgba(15, 23, 42, 0.04);
}
.aif-glow { display: none; }
.aif-glow--alt { display: none; }
.aif-glow--small { display: none; }
.aif-visual > *:not(.aif-glow) { position: relative; z-index: 1; flex: 1; }

/* Insurance card */
.aif-insurance {
    background: #ffffff;
    border: 1px solid rgba(15, 23, 42, 0.08);
    border-radius: 16px;
    padding: 16px 18px;
    align-self: center;
    width: 100%;
    max-width: 380px;
    margin: auto;
    box-shadow: 0 18px 36px -16px rgba(15, 23, 42, 0.18);
}
.aif-insurance__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 12px;
    border-bottom: 1px dashed rgba(15, 23, 42, 0.10);
    margin-bottom: 12px;
}
.aif-insurance__brand { display: flex; align-items: center; gap: 10px; }
.aif-insurance__logo {
    width: 28px; height: 28px;
    border-radius: 8px;
    background: var(--aif-accent);
    box-shadow: 0 2px 8px -2px color-mix(in srgb, var(--aif-accent) 50%, transparent);
}
.aif-insurance__co { font-size: 13px; font-weight: 600; color: var(--aif-ink); letter-spacing: -0.01em; }
.aif-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 10px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.04em;
}
.aif-badge svg { width: 11px; height: 11px; }
.aif-badge--ok {
    background: rgba(31, 140, 70, 0.10);
    color: #1f8c46;
    border: 1px solid rgba(31, 140, 70, 0.22);
}
.aif-insurance__rows { display: flex; flex-direction: column; gap: 8px; }
.aif-insurance__row {
    display: flex; align-items: center; justify-content: space-between;
    font-size: 13px;
    color: rgba(26, 26, 26, 0.55);
}
.aif-insurance__row strong { color: var(--aif-ink); font-weight: 600; font-variant-numeric: tabular-nums; }

/* Calendar / scheduling */
.aif-cal {
    width: 100%;
    max-width: 420px;
    margin: auto;
    align-self: center;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.aif-cal__head {
    display: flex; align-items: center; justify-content: space-between;
    padding: 6px 8px 10px;
    font-size: 12px;
    color: rgba(26, 26, 26, 0.55);
    font-weight: 600;
    letter-spacing: 0.02em;
}
.aif-cal__legend { display: inline-flex; align-items: center; gap: 6px; font-size: 11px; }
.aif-dot { width: 6px; height: 6px; border-radius: 999px; background: rgba(15, 23, 42, 0.20); }
.aif-dot--on { background: var(--aif-accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--aif-accent) 22%, transparent); }
.aif-cal__row { display: grid; grid-template-columns: 56px 1fr; align-items: center; gap: 12px; }
.aif-cal__time {
    font-size: 12px;
    font-variant-numeric: tabular-nums;
    color: rgba(26, 26, 26, 0.45);
    text-align: right;
}
.aif-cal__slot {
    background: #ffffff;
    border: 1px solid rgba(15, 23, 42, 0.08);
    border-radius: 10px;
    padding: 10px 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    font-size: 13px;
    color: rgba(26, 26, 26, 0.78);
}
.aif-cal__slot small { font-size: 11px; color: rgba(26, 26, 26, 0.4); font-variant-numeric: tabular-nums; }
.aif-cal__slot--ghost {
    background: transparent;
    border-style: dashed;
    border-color: rgba(15, 23, 42, 0.10);
    color: rgba(26, 26, 26, 0.42);
}
.aif-cal__slot--filled { border-color: rgba(15, 23, 42, 0.10); }
.aif-cal__slot--suggested {
    background: color-mix(in srgb, var(--aif-accent) 8%, #fff);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 35%, transparent);
    color: var(--aif-ink);
    font-weight: 600;
}
.aif-cal__row--highlight .aif-cal__time { color: color-mix(in srgb, var(--aif-accent) 70%, #1a1a1a); font-weight: 600; }

/* Voice / chat */
.aif-chat { display: flex; flex-direction: column; gap: 8px; align-self: center; width: 100%; }
.aif-bubble {
    max-width: 85%;
    padding: 10px 14px;
    border-radius: 14px;
    font-size: 13.5px;
    line-height: 1.4;
}
.aif-bubble--in {
    align-self: flex-start;
    background: #ffffff;
    border: 1px solid rgba(15, 23, 42, 0.08);
    color: var(--aif-ink);
    border-bottom-left-radius: 6px;
}
.aif-bubble--out {
    align-self: flex-end;
    background: var(--aif-accent);
    color: #fff;
    border-bottom-right-radius: 6px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}
.aif-bubble__live { width: 6px; height: 6px; border-radius: 999px; background: #fff; animation: aifLive 1.6s ease-in-out infinite; }
@keyframes aifLive { 50% { opacity: 0.3; } }

/* Retention stats */
.aif-stat-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    align-self: center;
    width: 100%;
}
.aif-stat {
    background: #ffffff;
    border: 1px solid rgba(15, 23, 42, 0.08);
    border-radius: 14px;
    padding: 14px 16px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.aif-stat__label {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.10em;
    text-transform: uppercase;
    color: rgba(26, 26, 26, 0.48);
}
.aif-stat__num {
    font-size: 28px;
    font-weight: 700;
    color: var(--aif-ink);
    line-height: 1.1;
    font-variant-numeric: tabular-nums;
}
.aif-stat__delta { font-size: 11.5px; color: rgba(26, 26, 26, 0.45); }
.aif-stat--accent {
    background: color-mix(in srgb, var(--aif-accent) 7%, #fff);
    border-color: color-mix(in srgb, var(--aif-accent) 28%, transparent);
}
.aif-stat--accent .aif-stat__num { color: color-mix(in srgb, var(--aif-accent) 75%, #1a1a1a); }

/* SMS reminders */
.aif-sms-stack { display: flex; flex-direction: column; gap: 8px; align-self: center; width: 100%; max-width: 320px; margin: 0 auto; }
.aif-sms {
    background: #ffffff;
    border: 1px solid rgba(15, 23, 42, 0.08);
    border-radius: 12px;
    padding: 10px 14px;
    transition: transform 0.3s ease;
    box-shadow: 0 6px 14px -8px rgba(15, 23, 42, 0.10);
}
.aif-sms--2 { transform: translateX(20px); }
.aif-card--reminders:hover .aif-sms--2 { transform: translateX(0); }
.aif-card--reminders:hover .aif-sms--1 { transform: translateX(-6px); }
.aif-sms__head {
    font-size: 10.5px;
    font-weight: 600;
    letter-spacing: 0.10em;
    text-transform: uppercase;
    color: color-mix(in srgb, var(--aif-accent) 60%, #1a1a1a);
    margin-bottom: 4px;
}
.aif-sms__body { font-size: 12.5px; color: rgba(26, 26, 26, 0.72); line-height: 1.45; }

/* Intake checklist */
.aif-intake {
    width: 100%;
    max-width: 420px;
    margin: auto;
    align-self: center;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.aif-step {
    display: grid;
    grid-template-columns: 28px 1fr auto;
    align-items: center;
    gap: 12px;
    background: #ffffff;
    border: 1px solid rgba(15, 23, 42, 0.08);
    border-radius: 12px;
    padding: 12px 14px;
    font-size: 13.5px;
}
.aif-step__check {
    width: 22px; height: 22px;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.06);
    border: 1.5px solid rgba(15, 23, 42, 0.12);
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.aif-step__check svg { width: 12px; height: 12px; }
.aif-step__name { color: var(--aif-ink); font-weight: 500; }
.aif-step__time { font-size: 11.5px; color: rgba(26, 26, 26, 0.42); font-variant-numeric: tabular-nums; }
.aif-step__time--alert { color: color-mix(in srgb, var(--aif-accent) 70%, #1a1a1a); font-weight: 600; }
.aif-step--done {
    background: color-mix(in srgb, var(--aif-accent) 4%, #fff);
    border-color: color-mix(in srgb, var(--aif-accent) 20%, rgba(15, 23, 42, 0.04));
}
.aif-step--done .aif-step__check {
    background: var(--aif-accent);
    border-color: var(--aif-accent);
    color: #fff;
    box-shadow: 0 4px 10px -4px color-mix(in srgb, var(--aif-accent) 60%, transparent);
}
.aif-step--pending .aif-step__name { color: rgba(26, 26, 26, 0.55); }

/* Triage flow */
.aif-triage {
    width: 100%;
    align-self: center;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
}
.aif-triage__node {
    background: #ffffff;
    border: 1px solid rgba(15, 23, 42, 0.10);
    border-radius: 12px;
    padding: 10px 14px;
    font-size: 13px;
    font-weight: 500;
    color: var(--aif-ink);
    box-shadow: 0 6px 14px -8px rgba(15, 23, 42, 0.14);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}
.aif-triage__node svg { width: 13px; height: 13px; }
.aif-triage__node--start { color: rgba(26, 26, 26, 0.7); }
.aif-triage__node--mid {
    background: #0a0a0a;
    color: #fff;
    border-color: #0a0a0a;
    position: relative;
}
.aif-triage__pulse {
    width: 6px; height: 6px;
    border-radius: 999px;
    background: var(--aif-accent);
    box-shadow: 0 0 0 4px color-mix(in srgb, var(--aif-accent) 30%, transparent);
    animation: aifLive 1.6s ease-in-out infinite;
}
.aif-triage__node--ok {
    background: rgba(31, 140, 70, 0.10);
    color: #1f8c46;
    border-color: rgba(31, 140, 70, 0.22);
}
.aif-triage__node--alert {
    background: color-mix(in srgb, var(--aif-accent) 10%, #fff);
    color: color-mix(in srgb, var(--aif-accent) 75%, #1a1a1a);
    border-color: color-mix(in srgb, var(--aif-accent) 28%, transparent);
}
.aif-triage__col { display: flex; flex-direction: column; gap: 8px; }
.aif-triage__line {
    width: 24px;
    height: 1px;
    background: rgba(15, 23, 42, 0.18);
    position: relative;
}
.aif-triage__line::after {
    content: '';
    position: absolute;
    right: -4px;
    top: -3px;
    width: 0; height: 0;
    border-top: 4px solid transparent;
    border-bottom: 4px solid transparent;
    border-left: 6px solid rgba(15, 23, 42, 0.20);
}
.aif-triage__line--split { background: rgba(15, 23, 42, 0.18); }

/* Mobile */
/* ──────────────────────────────────────────────────
   Minimal idle animations — subtle, looping, respect reduced-motion
   ────────────────────────────────────────────────── */

/* Insurance verified badge — gentle pulse */
.aif-card--insurance .aif-badge--ok {
    animation: aifBadgePulse 3.6s ease-in-out infinite;
}
@keyframes aifBadgePulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(31, 140, 70, 0); }
    50%      { box-shadow: 0 0 0 6px rgba(31, 140, 70, 0); transform: translateZ(0); }
    25%      { box-shadow: 0 0 0 0 rgba(31, 140, 70, 0.30); }
}
.aif-card--insurance .aif-insurance__row:last-child strong {
    animation: aifTimeTick 4.5s ease-in-out infinite;
}
@keyframes aifTimeTick {
    0%, 100% { opacity: 1; }
    48%      { opacity: 1; }
    50%      { opacity: 0.55; }
    52%      { opacity: 1; }
}

/* Schedule — suggested slot soft breathing glow */
.aif-card--schedule .aif-cal__slot--suggested {
    animation: aifSuggested 3.4s ease-in-out infinite;
}
@keyframes aifSuggested {
    0%, 100% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--aif-accent) 0%, transparent); }
    50%      { box-shadow: 0 0 0 6px color-mix(in srgb, var(--aif-accent) 8%, transparent); }
}
.aif-card--schedule .aif-dot--on { animation: aifLive 2s ease-in-out infinite; }

/* Voice — chat bubbles float in & loop */
.aif-card--voice .aif-bubble {
    animation: aifBubbleIn 8s ease-in-out infinite;
    animation-fill-mode: both;
    opacity: 0;
}
.aif-card--voice .aif-bubble:nth-child(1) { animation-delay: 0s; }
.aif-card--voice .aif-bubble:nth-child(2) { animation-delay: 1.4s; }
.aif-card--voice .aif-bubble:nth-child(3) { animation-delay: 2.8s; }
@keyframes aifBubbleIn {
    0%   { opacity: 0; transform: translateY(6px); }
    8%   { opacity: 1; transform: translateY(0); }
    85%  { opacity: 1; transform: translateY(0); }
    100% { opacity: 1; transform: translateY(0); }
}

/* Retention — stat numbers gentle scale */
.aif-card--retain .aif-stat__num {
    display: inline-block;
    transform-origin: left center;
    animation: aifStatPop 5s ease-in-out infinite;
}
.aif-card--retain .aif-stat:nth-child(2) .aif-stat__num { animation-delay: 1s; }
@keyframes aifStatPop {
    0%, 100% { transform: scale(1); }
    50%      { transform: scale(1.04); }
}

/* Reminders — SMS cards drift in stagger */
.aif-card--reminders .aif-sms {
    animation: aifSmsDrift 6.5s ease-in-out infinite;
    will-change: transform, opacity;
}
.aif-card--reminders .aif-sms--1 { animation-delay: 0s; }
.aif-card--reminders .aif-sms--2 { animation-delay: 1.2s; transform: translateX(20px); }
@keyframes aifSmsDrift {
    0%   { transform: translateX(20px); opacity: 0.5; }
    18%  { transform: translateX(0); opacity: 1; }
    78%  { transform: translateX(0); opacity: 1; }
    100% { transform: translateX(20px); opacity: 0.5; }
}
.aif-card--reminders .aif-sms--1 {
    animation-name: aifSmsDriftLeft;
}
@keyframes aifSmsDriftLeft {
    0%   { transform: translateX(-12px); opacity: 0.5; }
    18%  { transform: translateX(0); opacity: 1; }
    78%  { transform: translateX(0); opacity: 1; }
    100% { transform: translateX(-12px); opacity: 0.5; }
}

/* Intake — checks pop in & cycle */
.aif-card--intake .aif-step--done .aif-step__check {
    animation: aifCheckPop 5.5s ease-in-out infinite;
    transform-origin: center;
}
.aif-card--intake .aif-step:nth-child(2) .aif-step__check { animation-delay: 0.6s; }
.aif-card--intake .aif-step--pending .aif-step__check {
    animation: aifPendingSpin 3s linear infinite;
}
@keyframes aifCheckPop {
    0%, 100% { transform: scale(1); }
    8%       { transform: scale(0.85); }
    16%      { transform: scale(1.1); }
    24%      { transform: scale(1); }
}
@keyframes aifPendingSpin {
    0%, 100% { border-color: rgba(15, 23, 42, 0.12); }
    50%      { border-color: color-mix(in srgb, var(--aif-accent) 50%, rgba(15,23,42,0.12)); }
}

/* Triage — line shimmer + dot pulse */
.aif-card--triage .aif-triage__pulse { animation: aifLive 1.6s ease-in-out infinite; }
.aif-card--triage .aif-triage__line { overflow: hidden; }
.aif-card--triage .aif-triage__line::before {
    content: '';
    position: absolute;
    inset: 0;
    width: 8px;
    background: var(--aif-accent);
    opacity: 0.55;
    animation: aifLineShimmer 2.4s linear infinite;
}
@keyframes aifLineShimmer {
    0%   { transform: translateX(-100%); opacity: 0; }
    25%  { opacity: 0.6; }
    100% { transform: translateX(220%); opacity: 0; }
}

/* Reduced motion — kill all idle animations */
@media (prefers-reduced-motion: reduce) {
    .aif-card *,
    .aif-card *::before,
    .aif-card *::after { animation: none !important; }
}

@media (max-width: 767px) {
    .aif-card { padding: 22px 22px 0; min-height: auto; }
    .aif-row--2 .aif-card,
    .aif-row--3 .aif-card { min-height: auto; }
    .aif-visual { margin: 4px -22px -22px -22px; padding: 18px 20px 20px; }
    .aif-card__title { font-size: 1.125rem; }
    .aif-row--2 .aif-card__title { font-size: 1.25rem; }
}

/* ═══════════════════════════════════════════════════════════
   CHATBOT FEATURES VISUALS
   ═══════════════════════════════════════════════════════════ */

/* Multi-channel card */
.aif-cbt-channels {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 4px 0;
}
.aif-cbt-channel {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 10px 12px;
    box-shadow: 0 4px 12px -8px rgba(15, 23, 42, 0.08);
    position: relative;
}
.aif-cbt-channel__icon {
    width: 32px; height: 32px;
    border-radius: 10px;
    background: color-mix(in srgb, var(--aif-accent) 8%, white);
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 16px;
}
.aif-cbt-channel strong { display: block; font-size: 13.5px; color: var(--aif-ink); font-weight: 600; }
.aif-cbt-channel small { font-size: 11.5px; color: var(--aif-muted); }
.aif-cbt-channel__pulse {
    margin-left: auto;
    width: 8px; height: 8px;
    border-radius: 999px;
    background: #1f8c46;
    box-shadow: 0 0 0 4px rgba(31, 140, 70, 0.15);
    animation: aif-pulse 1.6s ease-in-out infinite;
}
.aif-cbt-shared {
    display: flex; align-items: center; gap: 10px;
    margin-top: 4px;
    padding: 8px 12px;
    background: color-mix(in srgb, var(--aif-accent) 6%, white);
    border: 1px dashed color-mix(in srgb, var(--aif-accent) 30%, transparent);
    border-radius: 10px;
    font-size: 12px;
    color: var(--aif-muted);
}
.aif-cbt-shared__brain { font-size: 16px; }

/* In-chat booking card */
.aif-cbt-book {
    position: relative; z-index: 1;
    display: flex; flex-direction: column; gap: 8px;
}
.aif-cbt-book__msg {
    align-self: flex-start;
    background: #f3f3f1;
    padding: 8px 12px;
    border-radius: 12px;
    border-bottom-left-radius: 4px;
    font-size: 13px;
    color: var(--aif-ink);
    max-width: 70%;
}
.aif-cbt-book__slots {
    display: flex; flex-wrap: wrap; gap: 6px;
}
.aif-cbt-book__slot {
    padding: 6px 12px;
    border-radius: 999px;
    background: #fff;
    border: 1px solid rgba(15, 23, 42, 0.10);
    font-size: 12px;
    color: var(--aif-muted);
}
.aif-cbt-book__slot--on {
    background: var(--aif-accent);
    color: #fff;
    border-color: var(--aif-accent);
    box-shadow: 0 4px 10px -2px color-mix(in srgb, var(--aif-accent) 50%, transparent);
    animation: aif-pop 1.8s ease-in-out infinite;
}
.aif-cbt-book__confirm {
    display: flex; align-items: center; gap: 10px;
    background: color-mix(in srgb, var(--aif-accent) 6%, white);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 25%, transparent);
    border-radius: 12px;
    padding: 10px 12px;
}
.aif-cbt-book__check {
    width: 24px; height: 24px;
    border-radius: 999px;
    background: var(--aif-accent);
    color: #fff;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 13px; font-weight: 700;
    flex-shrink: 0;
}
.aif-cbt-book__confirm strong { display: block; font-size: 13px; color: var(--aif-ink); font-weight: 600; }
.aif-cbt-book__confirm small { font-size: 11.5px; color: var(--aif-muted); }

/* Multilingual card */
.aif-cbt-lang {
    position: relative; z-index: 1;
    display: flex; flex-direction: column; gap: 8px;
}
.aif-cbt-lang__row {
    display: flex; align-items: center; gap: 10px;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 8px 12px;
    box-shadow: 0 4px 12px -8px rgba(15, 23, 42, 0.06);
    position: relative;
    opacity: 0.6;
}
.aif-cbt-lang__row--active {
    opacity: 1;
    border-color: color-mix(in srgb, var(--aif-accent) 35%, transparent);
    background: color-mix(in srgb, var(--aif-accent) 5%, white);
}
.aif-cbt-lang__flag {
    font-size: 18px;
    width: 28px; height: 28px;
    display: inline-flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.aif-cbt-lang__msg { font-size: 12.5px; color: var(--aif-ink); flex: 1; }
.aif-cbt-lang__live {
    width: 8px; height: 8px;
    border-radius: 999px;
    background: var(--aif-accent);
    box-shadow: 0 0 0 4px color-mix(in srgb, var(--aif-accent) 25%, transparent);
    animation: aif-pulse 1.4s ease-in-out infinite;
    flex-shrink: 0;
}

/* Policy-bound card */
.aif-cbt-policy {
    position: relative; z-index: 1;
    display: flex; flex-direction: column; gap: 8px;
}
.aif-cbt-policy__bubble {
    align-self: flex-start;
    background: #f3f3f1;
    padding: 8px 12px;
    border-radius: 12px;
    border-bottom-left-radius: 4px;
    font-size: 12.5px;
    color: var(--aif-ink);
    max-width: 80%;
}
.aif-cbt-policy__answer {
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 10px 12px;
    font-size: 12.5px;
    color: var(--aif-ink);
    box-shadow: 0 4px 12px -8px rgba(15, 23, 42, 0.08);
}
.aif-cbt-policy__cite {
    display: block;
    margin-top: 6px;
    padding-top: 6px;
    border-top: 1px dashed var(--aif-line);
    font-size: 10.5px;
    color: color-mix(in srgb, var(--aif-accent) 80%, black);
    font-weight: 600;
}

/* Hand-off card */
.aif-cbt-handoff {
    position: relative; z-index: 1;
    display: flex; flex-direction: column; gap: 10px;
    align-items: center;
}
.aif-cbt-handoff__alert {
    align-self: stretch;
    background: rgba(232, 73, 28, 0.08);
    border: 1px solid rgba(232, 73, 28, 0.22);
    color: #b8331c;
    padding: 6px 10px;
    border-radius: 8px;
    font-size: 11.5px;
    font-weight: 600;
    text-align: center;
}
.aif-cbt-handoff__route {
    display: flex; align-items: center; gap: 12px;
    width: 100%;
    justify-content: center;
}
.aif-cbt-handoff__avatar {
    width: 40px; height: 40px;
    border-radius: 999px;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 16px;
    flex-shrink: 0;
    border: 2px solid #fff;
    box-shadow: 0 4px 12px -4px rgba(15, 23, 42, 0.15);
}
.aif-cbt-handoff__avatar--bot {
    background: color-mix(in srgb, var(--aif-accent) 12%, white);
}
.aif-cbt-handoff__avatar--human {
    background: linear-gradient(135deg, var(--aif-accent) 0%, color-mix(in srgb, var(--aif-accent) 60%, black) 100%);
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.04em;
}
.aif-cbt-handoff__line {
    flex: 1;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--aif-accent), transparent);
    background-size: 200% 100%;
    animation: aif-flow 1.8s linear infinite;
    max-width: 80px;
}
.aif-cbt-handoff__joined {
    display: flex; align-items: center; gap: 6px;
    font-size: 11.5px;
    color: var(--aif-muted);
    font-weight: 500;
}
.aif-cbt-handoff__live {
    width: 7px; height: 7px;
    border-radius: 999px;
    background: #1f8c46;
    box-shadow: 0 0 0 3px rgba(31, 140, 70, 0.18);
    animation: aif-pulse 1.4s ease-in-out infinite;
}

/* Intake card */
.aif-cbt-intake {
    position: relative; z-index: 1;
    display: flex; flex-direction: column; gap: 6px;
}
.aif-cbt-intake__step {
    display: flex; align-items: center; gap: 10px;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 10px;
    padding: 8px 12px;
    font-size: 12.5px;
    color: var(--aif-muted);
    opacity: 0.7;
}
.aif-cbt-intake__step--done { opacity: 1; }
.aif-cbt-intake__step--done span:nth-child(2) { color: var(--aif-ink); font-weight: 500; }
.aif-cbt-intake__step--active {
    opacity: 1;
    background: color-mix(in srgb, var(--aif-accent) 6%, white);
    border-color: color-mix(in srgb, var(--aif-accent) 30%, transparent);
}
.aif-cbt-intake__step--active span:nth-child(2) { color: var(--aif-ink); font-weight: 600; }
.aif-cbt-intake__check {
    width: 20px; height: 20px;
    border-radius: 999px;
    background: var(--aif-accent);
    color: #fff;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 11px; font-weight: 700;
    flex-shrink: 0;
}
.aif-cbt-intake__step:not(.aif-cbt-intake__step--done):not(.aif-cbt-intake__step--active) .aif-cbt-intake__check {
    background: transparent;
    border: 1.5px solid rgba(15, 23, 42, 0.18);
}
.aif-cbt-intake__check--pulse {
    background: transparent !important;
    border: 2px solid var(--aif-accent);
    animation: aif-pulse 1.4s ease-in-out infinite;
}
.aif-cbt-intake__step span:nth-child(2) { flex: 1; }
.aif-cbt-intake__step small { font-size: 10.5px; color: var(--aif-muted); }

/* CRM card */
.aif-cbt-crm {
    position: relative; z-index: 1;
    display: flex; align-items: center; gap: 8px;
}
.aif-cbt-crm__chat {
    flex: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 10px;
}
.aif-cbt-crm__msg {
    background: #f3f3f1;
    padding: 8px 10px;
    border-radius: 10px;
    border-bottom-left-radius: 4px;
    font-size: 11.5px;
    color: var(--aif-ink);
}
.aif-cbt-crm__arrow {
    color: var(--aif-accent);
    font-size: 18px;
    font-weight: 700;
    animation: aif-flow-arrow 1.6s ease-in-out infinite;
}
.aif-cbt-crm__record {
    flex: 1.2;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 10px;
    box-shadow: 0 8px 20px -10px rgba(15, 23, 42, 0.10);
}
.aif-cbt-crm__head {
    font-size: 9.5px;
    font-weight: 700;
    color: var(--aif-muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding-bottom: 4px;
    border-bottom: 1px dashed var(--aif-line);
    margin-bottom: 4px;
}
.aif-cbt-crm__line {
    display: flex; justify-content: space-between;
    font-size: 11px;
    color: var(--aif-muted);
    padding: 1px 0;
}
.aif-cbt-crm__line strong { color: var(--aif-ink); font-weight: 600; }
.aif-cbt-crm__pill {
    display: inline-block;
    margin-top: 4px;
    background: rgba(31, 140, 70, 0.12);
    color: #1f8c46;
    border: 1px solid rgba(31, 140, 70, 0.25);
    border-radius: 999px;
    padding: 2px 8px;
    font-size: 9.5px;
    font-weight: 600;
}

@keyframes aif-pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.18); opacity: 0.7; }
}
@keyframes aif-pop {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.04); }
}
@keyframes aif-flow {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}
@keyframes aif-flow-arrow {
    0%, 100% { transform: translateX(0); opacity: 0.7; }
    50% { transform: translateX(3px); opacity: 1; }
}

/* ═══════════════════════════════════════════════════════════
   SMART BOOKING FEATURES VISUALS
   ═══════════════════════════════════════════════════════════ */

/* Card on file / Deposit */
.aif-sb-deposit {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 14px;
    padding: 14px;
    box-shadow: 0 8px 22px -12px rgba(15, 23, 42, 0.10);
    display: flex; flex-direction: column; gap: 8px;
}
.aif-sb-deposit__head {
    font-size: 11px;
    font-weight: 700;
    color: var(--aif-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding-bottom: 6px;
    border-bottom: 1px dashed var(--aif-line);
}
.aif-sb-deposit__row {
    display: flex; justify-content: space-between;
    font-size: 12.5px;
    color: var(--aif-muted);
}
.aif-sb-deposit__row strong { color: var(--aif-ink); font-weight: 600; }
.aif-sb-deposit__card {
    display: flex; align-items: center; gap: 10px;
    margin-top: 4px;
    padding: 10px 12px;
    background: color-mix(in srgb, var(--aif-accent) 5%, white);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 22%, transparent);
    border-radius: 10px;
}
.aif-sb-deposit__card-icon { font-size: 18px; }
.aif-sb-deposit__card strong { display: block; font-size: 13px; color: var(--aif-ink); font-weight: 600; }
.aif-sb-deposit__card small { font-size: 11px; color: var(--aif-muted); }
.aif-sb-deposit__check {
    margin-left: auto;
    width: 22px; height: 22px;
    border-radius: 999px;
    background: var(--aif-accent);
    color: #fff;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 12px; font-weight: 700;
}
.aif-sb-deposit__stat {
    margin-top: 2px;
    padding: 6px 10px;
    background: rgba(31, 140, 70, 0.08);
    border: 1px solid rgba(31, 140, 70, 0.22);
    border-radius: 8px;
    font-size: 11.5px;
    color: rgba(26, 26, 26, 0.7);
    text-align: center;
}
.aif-sb-deposit__stat strong { color: #1f8c46; font-weight: 700; }

/* Multi-location routing */
.aif-sb-routing { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 8px; }
.aif-sb-routing__msg {
    align-self: flex-start;
    background: #f3f3f1;
    padding: 6px 12px;
    border-radius: 12px;
    border-bottom-left-radius: 4px;
    font-size: 12px;
    color: var(--aif-ink);
}
.aif-sb-routing__list { display: flex; flex-direction: column; gap: 5px; }
.aif-sb-routing__loc {
    display: flex; align-items: center; gap: 10px;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 10px;
    padding: 8px 10px;
    opacity: 0.55;
}
.aif-sb-routing__loc--on {
    opacity: 1;
    background: color-mix(in srgb, var(--aif-accent) 5%, white);
    border-color: color-mix(in srgb, var(--aif-accent) 28%, transparent);
}
.aif-sb-routing__pin {
    color: var(--aif-accent);
    font-size: 14px;
    flex-shrink: 0;
}
.aif-sb-routing__loc strong { display: block; font-size: 12.5px; color: var(--aif-ink); font-weight: 600; }
.aif-sb-routing__loc small { font-size: 11px; color: var(--aif-muted); }
.aif-sb-routing__match {
    margin-left: auto;
    background: var(--aif-accent);
    color: #fff;
    border-radius: 999px;
    padding: 2px 9px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    flex-shrink: 0;
}

/* Urgent slots */
.aif-sb-urgent {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 10px;
    box-shadow: 0 8px 22px -12px rgba(15, 23, 42, 0.10);
}
.aif-sb-urgent__head {
    font-size: 11px;
    font-weight: 700;
    color: var(--aif-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding-bottom: 6px;
    border-bottom: 1px dashed var(--aif-line);
    margin-bottom: 6px;
}
.aif-sb-urgent__slot {
    padding: 6px 8px;
    border-radius: 7px;
    font-size: 11.5px;
    color: var(--aif-muted);
    margin: 2px 0;
}
.aif-sb-urgent__slot--urgent {
    background: color-mix(in srgb, var(--aif-accent) 8%, white);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 30%, transparent);
    color: var(--aif-ink);
    font-weight: 600;
    display: flex; align-items: center; gap: 6px;
}
.aif-sb-urgent__slot--release {
    background: rgba(245, 158, 11, 0.08);
    border: 1px dashed rgba(245, 158, 11, 0.30);
    color: var(--aif-ink);
    font-weight: 500;
    display: flex; align-items: center; gap: 6px;
}
.aif-sb-urgent__bolt {
    color: var(--aif-accent);
    font-size: 12px;
    animation: aif-pulse 1.4s ease-in-out infinite;
}
.aif-sb-urgent__slot--release .aif-sb-urgent__bolt { color: #b8731c; }

/* Self-serve reschedule */
.aif-sb-self { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 6px; }
.aif-sb-self__sms {
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 10px;
    padding: 8px 10px;
    box-shadow: 0 4px 12px -8px rgba(15, 23, 42, 0.06);
}
.aif-sb-self__sms small {
    display: block;
    font-size: 10px;
    color: var(--aif-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-weight: 600;
    margin-bottom: 2px;
}
.aif-sb-self__sms strong {
    display: block;
    font-size: 12.5px;
    color: var(--aif-ink);
    font-weight: 600;
}
.aif-sb-self__link {
    display: inline-block;
    margin-top: 4px;
    color: var(--aif-accent);
    font-size: 11px;
    font-weight: 600;
    text-decoration: underline;
}
.aif-sb-self__chips { display: flex; gap: 5px; flex-wrap: wrap; padding: 0 4px; }
.aif-sb-self__chip {
    padding: 4px 9px;
    border-radius: 999px;
    background: #fff;
    border: 1px solid rgba(15, 23, 42, 0.10);
    font-size: 11px;
    color: var(--aif-muted);
}
.aif-sb-self__chip--on {
    background: var(--aif-accent);
    color: #fff;
    border-color: var(--aif-accent);
    box-shadow: 0 4px 10px -2px color-mix(in srgb, var(--aif-accent) 50%, transparent);
}
.aif-sb-self__done {
    display: flex; align-items: center; gap: 6px;
    margin-top: 4px;
    background: color-mix(in srgb, var(--aif-accent) 5%, white);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 22%, transparent);
    border-radius: 8px;
    padding: 6px 10px;
    font-size: 11.5px;
    font-weight: 600;
    color: var(--aif-ink);
}
.aif-sb-self__check {
    width: 18px; height: 18px;
    border-radius: 999px;
    background: var(--aif-accent);
    color: #fff;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 10px; font-weight: 700;
    flex-shrink: 0;
}

/* Waitlist auto-fill */
.aif-sb-wait { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 6px; }
.aif-sb-wait__cancel {
    background: rgba(232, 73, 28, 0.08);
    border: 1px solid rgba(232, 73, 28, 0.22);
    color: #b8331c;
    padding: 6px 10px;
    border-radius: 8px;
    font-size: 11.5px;
    font-weight: 600;
}
.aif-sb-wait__queue {
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 10px;
    padding: 6px;
    display: flex; flex-direction: column; gap: 3px;
}
.aif-sb-wait__patient {
    display: flex; align-items: center; gap: 8px;
    padding: 5px 8px;
    border-radius: 6px;
    font-size: 12px;
    color: var(--aif-muted);
    opacity: 0.6;
}
.aif-sb-wait__patient--on {
    background: color-mix(in srgb, var(--aif-accent) 5%, white);
    color: var(--aif-ink);
    font-weight: 600;
    opacity: 1;
}
.aif-sb-wait__num {
    width: 18px; height: 18px;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.08);
    color: var(--aif-muted);
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 10px; font-weight: 700;
    flex-shrink: 0;
}
.aif-sb-wait__patient--on .aif-sb-wait__num { background: var(--aif-accent); color: #fff; }
.aif-sb-wait__pill {
    margin-left: auto;
    background: color-mix(in srgb, var(--aif-accent) 12%, white);
    color: var(--aif-accent);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 28%, transparent);
    border-radius: 999px;
    padding: 2px 7px;
    font-size: 9.5px;
    font-weight: 700;
    letter-spacing: 0.03em;
    flex-shrink: 0;
}
.aif-sb-wait__filled {
    display: flex; align-items: center; gap: 6px;
    background: rgba(31, 140, 70, 0.08);
    border: 1px solid rgba(31, 140, 70, 0.22);
    border-radius: 8px;
    padding: 6px 10px;
    font-size: 11.5px;
    font-weight: 600;
    color: rgba(26, 26, 26, 0.8);
}
.aif-sb-wait__check {
    width: 18px; height: 18px;
    border-radius: 999px;
    background: #1f8c46;
    color: #fff;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 10px; font-weight: 700;
    flex-shrink: 0;
}

/* Audit trail */
.aif-sb-audit {
    position: relative; z-index: 1;
    background: #0f1115;
    border: 1px solid #1d2128;
    border-radius: 14px;
    padding: 14px;
    box-shadow: 0 12px 32px -16px rgba(0, 0, 0, 0.30);
    display: flex; flex-direction: column; gap: 6px;
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}
.aif-sb-audit__head {
    font-size: 10.5px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.55);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding-bottom: 6px;
    border-bottom: 1px dashed rgba(255, 255, 255, 0.08);
    margin-bottom: 2px;
}
.aif-sb-audit__row {
    display: flex; align-items: center; gap: 10px;
    padding: 4px 0;
    font-size: 11.5px;
}
.aif-sb-audit__time {
    color: rgba(255, 255, 255, 0.45);
    font-weight: 600;
    flex-shrink: 0;
    min-width: 48px;
}
.aif-sb-audit__action {
    color: rgba(255, 255, 255, 0.75);
    font-weight: 500;
    flex: 1;
}
.aif-sb-audit__action--create { color: #6ee7a8; }
.aif-sb-audit__action--move   { color: #f5b86b; }
.aif-sb-audit__action--ok     { color: var(--aif-accent); filter: brightness(1.4) saturate(1.2); }
.aif-sb-audit__src {
    color: rgba(255, 255, 255, 0.45);
    font-size: 10.5px;
    flex-shrink: 0;
}
.aif-sb-audit__foot {
    margin-top: 4px;
    padding-top: 6px;
    border-top: 1px dashed rgba(255, 255, 255, 0.08);
    font-size: 10px;
    color: rgba(255, 255, 255, 0.40);
    letter-spacing: 0.04em;
}

/* Native integrations / Two-way sync */
.aif-sb-2way { position: relative; z-index: 1; display: flex; align-items: center; gap: 14px; }
.aif-sb-2way__col { display: flex; flex-direction: column; gap: 8px; flex: 1; }
.aif-sb-2way__app {
    display: flex; align-items: center; justify-content: space-between; gap: 8px;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 10px;
    padding: 8px 12px;
    font-size: 12.5px;
    color: var(--aif-ink);
    box-shadow: 0 4px 10px -8px rgba(15, 23, 42, 0.06);
}
.aif-sb-2way__app--brand {
    background: linear-gradient(135deg, color-mix(in srgb, var(--aif-accent) 8%, white) 0%, color-mix(in srgb, var(--aif-accent) 16%, white) 100%);
    border-color: color-mix(in srgb, var(--aif-accent) 30%, transparent);
    color: var(--aif-ink);
    font-weight: 600;
}
.aif-sb-2way__app-name { font-weight: 500; }
.aif-sb-2way__app--brand .aif-sb-2way__app-name { font-weight: 600; }
.aif-sb-2way__arrow {
    color: var(--aif-accent);
    font-size: 14px;
    font-weight: 700;
    animation: aif-flow-arrow 1.6s ease-in-out infinite;
}
.aif-sb-2way__app:nth-child(2) .aif-sb-2way__arrow { animation-delay: 0.2s; }
.aif-sb-2way__app:nth-child(3) .aif-sb-2way__arrow { animation-delay: 0.4s; }
.aif-sb-2way__hub {
    flex: 1.2;
    background: linear-gradient(135deg, color-mix(in srgb, var(--aif-accent) 8%, white) 0%, color-mix(in srgb, var(--aif-accent) 16%, white) 100%);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 30%, transparent);
    border-radius: 12px;
    padding: 12px;
    text-align: center;
    position: relative;
}
.aif-sb-2way__hub-pulse {
    position: absolute;
    top: 8px; right: 10px;
    width: 8px; height: 8px;
    border-radius: 999px;
    background: var(--aif-accent);
    box-shadow: 0 0 0 4px color-mix(in srgb, var(--aif-accent) 25%, transparent);
    animation: aif-pulse 1.4s ease-in-out infinite;
}
.aif-sb-2way__hub strong { display: block; font-size: 13px; color: var(--aif-ink); font-weight: 700; }
.aif-sb-2way__hub small { font-size: 11px; color: var(--aif-muted); }

/* ═══════════════════════════════════════════════════════════
   DIGITAL INTAKE FEATURES VISUALS
   ═══════════════════════════════════════════════════════════ */

/* OCR card */
.aif-di-ocr { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 8px; }
.aif-di-ocr__card {
    position: relative;
    background: linear-gradient(135deg, #1d3a6e 0%, #355285 100%);
    border-radius: 10px;
    padding: 12px 14px;
    color: #fff;
    display: flex; align-items: center; gap: 10px;
    overflow: hidden;
    box-shadow: 0 8px 22px -10px rgba(29, 58, 110, 0.40);
}
.aif-di-ocr__chip { font-size: 18px; }
.aif-di-ocr__caption { font-size: 12px; color: rgba(255, 255, 255, 0.85); }
.aif-di-ocr__scan {
    position: absolute;
    left: 0; right: 0; top: 50%;
    height: 2px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.7), transparent);
    box-shadow: 0 0 12px rgba(255, 255, 255, 0.4);
    animation: aif-di-scan 2s ease-in-out infinite;
}
.aif-di-ocr__fields {
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 10px;
    padding: 10px 12px;
    display: flex; flex-direction: column; gap: 3px;
    box-shadow: 0 4px 12px -8px rgba(15, 23, 42, 0.08);
}
.aif-di-ocr__row {
    display: flex; justify-content: space-between;
    font-size: 12px;
    color: var(--aif-muted);
    padding: 1px 0;
}
.aif-di-ocr__row strong { color: var(--aif-ink); font-weight: 600; }
.aif-di-ocr__pill {
    align-self: flex-start;
    margin-top: 4px;
    background: rgba(31, 140, 70, 0.10);
    border: 1px solid rgba(31, 140, 70, 0.25);
    color: #1f8c46;
    border-radius: 999px;
    padding: 2px 9px;
    font-size: 10.5px;
    font-weight: 700;
}

/* Conditional logic card */
.aif-di-logic { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 6px; align-items: center; }
.aif-di-logic__node {
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 10px;
    padding: 6px 12px;
    font-size: 12px;
    color: var(--aif-ink);
    text-align: center;
}
.aif-di-logic__node--root {
    background: color-mix(in srgb, var(--aif-accent) 10%, white);
    border-color: color-mix(in srgb, var(--aif-accent) 30%, transparent);
    color: var(--aif-ink);
    font-weight: 600;
}
.aif-di-logic__branch {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 6px;
    width: 100%;
}
.aif-di-logic__col {
    display: flex; flex-direction: column; align-items: center; gap: 4px;
    opacity: 0.55;
}
.aif-di-logic__col--on { opacity: 1; }
.aif-di-logic__line {
    width: 1.5px;
    height: 14px;
    background: rgba(15, 23, 42, 0.20);
}
.aif-di-logic__line--on { background: var(--aif-accent); animation: aif-pulse 1.4s ease-in-out infinite; }
.aif-di-logic__col .aif-di-logic__node {
    width: 100%;
    font-size: 11px;
    padding: 5px 8px;
}
.aif-di-logic__node--on {
    background: var(--aif-accent);
    color: #fff;
    border-color: var(--aif-accent);
    font-weight: 600;
    box-shadow: 0 4px 10px -2px color-mix(in srgb, var(--aif-accent) 50%, transparent);
}
.aif-di-logic__leaf {
    font-size: 10px;
    color: var(--aif-muted);
    text-align: center;
}
.aif-di-logic__leaf--on { color: var(--aif-ink); font-weight: 500; }

/* E-signatures */
.aif-di-esig { position: relative; z-index: 1; }
.aif-di-esig__doc {
    font-size: 10.5px;
    font-weight: 700;
    color: var(--aif-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 6px;
}
.aif-di-esig__sig {
    position: relative;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 10px;
    padding: 12px;
    margin-bottom: 6px;
}
.aif-di-esig__name {
    font-family: 'Brush Script MT', cursive, ui-serif, serif;
    font-size: 22px;
    color: var(--aif-accent);
    font-weight: 400;
    font-style: italic;
}
.aif-di-esig__line {
    display: block;
    margin-top: 4px;
    height: 1px;
    background: rgba(15, 23, 42, 0.18);
}
.aif-di-esig__checks { display: flex; gap: 5px; flex-wrap: wrap; }
.aif-di-esig__check {
    background: color-mix(in srgb, var(--aif-accent) 6%, white);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 22%, transparent);
    color: var(--aif-ink);
    border-radius: 999px;
    padding: 3px 9px;
    font-size: 11px;
    font-weight: 500;
}

/* Pre-visit pay */
.aif-di-pay { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 6px; }
.aif-di-pay__row {
    display: flex; justify-content: space-between;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 8px;
    padding: 6px 10px;
    font-size: 12px;
    color: var(--aif-muted);
}
.aif-di-pay__row strong { color: var(--aif-ink); font-weight: 700; }
.aif-di-pay__card {
    display: flex; align-items: center; gap: 8px;
    background: color-mix(in srgb, var(--aif-accent) 6%, white);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 25%, transparent);
    border-radius: 8px;
    padding: 6px 10px;
    font-size: 11.5px;
    color: var(--aif-ink);
    font-weight: 500;
}
.aif-di-pay__live {
    margin-left: auto;
    width: 7px; height: 7px;
    border-radius: 999px;
    background: var(--aif-accent);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--aif-accent) 25%, transparent);
    animation: aif-pulse 1.4s ease-in-out infinite;
}
.aif-di-pay__btn {
    background: var(--aif-accent);
    color: #fff;
    text-align: center;
    border-radius: 8px;
    padding: 7px;
    font-size: 12px;
    font-weight: 600;
    box-shadow: 0 6px 14px -4px color-mix(in srgb, var(--aif-accent) 50%, transparent);
}

/* Multilingual */
.aif-di-multi { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 5px; }
.aif-di-multi__row {
    display: flex; align-items: center; gap: 8px;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 8px;
    padding: 6px 10px;
    font-size: 12px;
    opacity: 0.6;
}
.aif-di-multi__row--on {
    opacity: 1;
    background: color-mix(in srgb, var(--aif-accent) 5%, white);
    border-color: color-mix(in srgb, var(--aif-accent) 25%, transparent);
}
.aif-di-multi__flag {
    width: 22px; height: 22px;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
}
.aif-di-multi__row span:nth-child(2) { font-size: 12px; color: var(--aif-ink); flex: 1; }
.aif-di-multi__live {
    width: 7px; height: 7px;
    border-radius: 999px;
    background: var(--aif-accent);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--aif-accent) 25%, transparent);
    animation: aif-pulse 1.4s ease-in-out infinite;
    flex-shrink: 0;
}

/* EHR sync */
.aif-di-sync { position: relative; z-index: 1; display: flex; align-items: center; gap: 8px; }
.aif-di-sync__form {
    flex: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 10px;
    padding: 10px;
    display: flex; flex-direction: column; gap: 3px;
}
.aif-di-sync__form-head {
    font-size: 9.5px;
    font-weight: 700;
    color: var(--aif-muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding-bottom: 4px;
    border-bottom: 1px dashed var(--aif-line);
    margin-bottom: 2px;
}
.aif-di-sync__row { font-size: 11.5px; color: var(--aif-ink); padding: 1px 0; }
.aif-di-sync__arrow {
    color: var(--aif-accent);
    font-size: 18px;
    font-weight: 700;
    animation: aif-flow-arrow 1.6s ease-in-out infinite;
}
.aif-di-sync__ehr {
    flex: 1.1;
    background: #0f1115;
    border-radius: 10px;
    padding: 10px;
    color: rgba(255, 255, 255, 0.85);
    font-family: ui-monospace, SFMono-Regular, monospace;
    box-shadow: 0 8px 22px -12px rgba(0, 0, 0, 0.30);
}
.aif-di-sync__ehr-head {
    font-size: 9.5px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.55);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding-bottom: 4px;
    border-bottom: 1px dashed rgba(255, 255, 255, 0.10);
    margin-bottom: 4px;
}
.aif-di-sync__ehr-line {
    font-size: 11px;
    color: #6ee7a8;
    padding: 1px 0;
}
.aif-di-sync__ehr-pill {
    display: inline-block;
    margin-top: 4px;
    background: rgba(110, 231, 168, 0.12);
    color: #6ee7a8;
    border: 1px solid rgba(110, 231, 168, 0.30);
    border-radius: 999px;
    padding: 2px 8px;
    font-size: 9.5px;
    font-weight: 700;
}

/* Mobile-first */
.aif-di-mobile { position: relative; z-index: 1; display: flex; align-items: center; gap: 12px; }
.aif-di-mobile__phone {
    flex: 1;
    background: #fff;
    border: 1px solid rgba(15, 23, 42, 0.10);
    border-radius: 16px;
    padding: 12px;
    box-shadow: 0 12px 28px -14px rgba(15, 23, 42, 0.18);
}
.aif-di-mobile__progress {
    height: 4px;
    background: rgba(15, 23, 42, 0.06);
    border-radius: 999px;
    overflow: hidden;
    margin-bottom: 6px;
}
.aif-di-mobile__progress span {
    display: block; height: 100%;
    background: linear-gradient(90deg, color-mix(in srgb, var(--aif-accent) 70%, white) 0%, var(--aif-accent) 100%);
    border-radius: 999px;
}
.aif-di-mobile__step {
    font-size: 10px;
    color: var(--aif-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-weight: 600;
    margin-bottom: 6px;
}
.aif-di-mobile__q { font-size: 13px; color: var(--aif-ink); font-weight: 600; margin-bottom: 8px; }
.aif-di-mobile__opts { display: flex; gap: 6px; margin-bottom: 8px; }
.aif-di-mobile__opt {
    flex: 1;
    text-align: center;
    padding: 7px;
    border-radius: 8px;
    background: #fff;
    border: 1px solid rgba(15, 23, 42, 0.10);
    font-size: 11.5px;
    color: var(--aif-muted);
    font-weight: 500;
}
.aif-di-mobile__opt--on {
    background: var(--aif-accent);
    color: #fff;
    border-color: var(--aif-accent);
    box-shadow: 0 4px 10px -2px color-mix(in srgb, var(--aif-accent) 50%, transparent);
}
.aif-di-mobile__cta {
    background: var(--aif-ink);
    color: #fff;
    text-align: center;
    border-radius: 8px;
    padding: 8px;
    font-size: 12px;
    font-weight: 600;
}
.aif-di-mobile__stat {
    flex: 0.8;
    background: linear-gradient(135deg, color-mix(in srgb, var(--aif-accent) 8%, white) 0%, color-mix(in srgb, var(--aif-accent) 18%, white) 100%);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 30%, transparent);
    border-radius: 12px;
    padding: 12px;
    text-align: center;
}
.aif-di-mobile__stat strong {
    display: block;
    font-size: 28px;
    font-weight: 800;
    color: var(--aif-accent);
    line-height: 1;
}
.aif-di-mobile__stat span {
    display: block;
    margin-top: 4px;
    font-size: 10.5px;
    color: var(--aif-muted);
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

@keyframes aif-di-scan {
    0%, 100% { transform: translateY(-18px); }
    50% { transform: translateY(18px); }
}

/* Smart pre-fill — first vs returning */
.aif-di-prefill {
    position: relative; z-index: 1;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: stretch;
    gap: 8px;
}
.aif-di-prefill__col {
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    display: flex; flex-direction: column; gap: 8px;
    box-shadow: 0 4px 12px -8px rgba(15, 23, 42, 0.06);
}
.aif-di-prefill__col--returning {
    background: color-mix(in srgb, var(--aif-accent) 5%, white);
    border-color: color-mix(in srgb, var(--aif-accent) 25%, transparent);
}
.aif-di-prefill__head {
    font-size: 10.5px;
    font-weight: 700;
    color: var(--aif-muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding-bottom: 6px;
    border-bottom: 1px dashed var(--aif-line);
}
.aif-di-prefill__head--on { color: var(--aif-accent); }
.aif-di-prefill__rows { display: flex; flex-direction: column; gap: 4px; flex: 1; }
.aif-di-prefill__rows span {
    display: block; height: 6px;
    background: rgba(15, 23, 42, 0.08);
    border-radius: 999px;
}
.aif-di-prefill__confirms { display: flex; flex-direction: column; gap: 5px; flex: 1; }
.aif-di-prefill__confirm {
    background: #fff;
    border: 1px solid color-mix(in srgb, var(--aif-accent) 18%, transparent);
    border-radius: 7px;
    padding: 5px 9px;
    font-size: 11px;
    color: var(--aif-ink);
    font-weight: 500;
}
.aif-di-prefill__confirm--update {
    background: color-mix(in srgb, var(--aif-accent) 8%, white);
    color: var(--aif-accent);
    font-weight: 600;
}
.aif-di-prefill__time {
    font-size: 10.5px;
    color: var(--aif-muted);
    font-weight: 600;
    padding-top: 6px;
    border-top: 1px dashed var(--aif-line);
}
.aif-di-prefill__time--on { color: var(--aif-accent); }
.aif-di-prefill__vs {
    align-self: center;
    font-size: 10px;
    font-weight: 700;
    color: var(--aif-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

/* Photo + body markers */
.aif-di-photo {
    position: relative; z-index: 1;
    display: grid;
    grid-template-columns: auto 1fr;
    align-items: center;
    gap: 12px;
}
.aif-di-photo__body {
    position: relative;
    width: 80px; height: 160px;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 6px;
    color: var(--aif-accent);
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
}
.aif-di-photo__body svg {
    width: 100%; height: 100%;
    display: block;
}
.aif-di-photo__marker {
    position: absolute;
    width: 14px; height: 14px;
    border-radius: 999px;
    background: var(--aif-accent);
    box-shadow: 0 0 0 4px color-mix(in srgb, var(--aif-accent) 25%, transparent);
    animation: aif-pulse 1.4s ease-in-out infinite;
    transform: translate(-50%, -50%);
}
.aif-di-photo__label {
    position: absolute;
    background: var(--aif-ink);
    color: #fff;
    padding: 2px 7px;
    border-radius: 6px;
    font-size: 10px;
    font-weight: 600;
    white-space: nowrap;
    transform: translateY(-50%);
}
.aif-di-photo__uploads {
    display: flex; flex-direction: column; gap: 6px;
    flex: 1;
}
.aif-di-photo__thumb {
    background: linear-gradient(135deg, color-mix(in srgb, var(--aif-accent) 6%, white) 0%, color-mix(in srgb, var(--aif-accent) 14%, white) 100%);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 25%, transparent);
    border-radius: 10px;
    padding: 12px;
    font-size: 22px;
    text-align: center;
    box-shadow: 0 4px 12px -8px rgba(15, 23, 42, 0.08);
}
.aif-di-photo__thumb small {
    display: block;
    margin-top: 2px;
    font-size: 10px;
    color: var(--aif-muted);
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}
.aif-di-photo__caption {
    text-align: center;
    font-size: 11px;
    color: var(--aif-muted);
    font-style: italic;
    margin-top: 2px;
}

/* Custom branding */
.aif-di-brand {
    position: relative; z-index: 1;
    background: linear-gradient(180deg, #fcfaf6 0%, #f5f1eb 100%);
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    display: flex; flex-direction: column; gap: 8px;
    box-shadow: 0 6px 16px -10px rgba(44, 79, 122, 0.15);
}
.aif-di-brand__head { display: flex; justify-content: space-between; align-items: center; }
.aif-di-brand__logo {
    font-size: 12px;
    font-weight: 700;
    color: #2c4f7a;
    letter-spacing: 0.02em;
}
.aif-di-brand__step {
    font-size: 10px;
    color: rgba(44, 79, 122, 0.65);
    font-style: italic;
}
.aif-di-brand__title {
    font-size: 13px;
    color: #1e2a3a;
    font-weight: 600;
}
.aif-di-brand__opts { display: flex; gap: 5px; flex-wrap: wrap; }
.aif-di-brand__opt {
    padding: 5px 10px;
    border-radius: 999px;
    background: #fff;
    border: 1px solid rgba(44, 79, 122, 0.18);
    font-size: 11px;
    color: #2c4f7a;
}
.aif-di-brand__opt--on {
    background: #2c4f7a;
    color: #fff;
    border-color: #2c4f7a;
}
.aif-di-brand__swatches {
    display: flex; align-items: center; gap: 5px;
    margin-top: 4px;
    padding-top: 6px;
    border-top: 1px dashed rgba(44, 79, 122, 0.18);
}
.aif-di-brand__sw {
    width: 14px; height: 14px;
    border-radius: 999px;
    border: 2px solid #fff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}
.aif-di-brand__swatches-label {
    margin-left: auto;
    font-size: 10px;
    color: rgba(44, 79, 122, 0.55);
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

/* Kiosk fallback */
.aif-di-kiosk { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 8px; align-items: center; }
.aif-di-kiosk__tablet {
    width: 92%;
    background: #fff;
    border: 1px solid rgba(15, 23, 42, 0.10);
    border-radius: 14px;
    padding: 14px;
    box-shadow: 0 8px 22px -10px rgba(15, 23, 42, 0.18);
    display: flex; flex-direction: column; gap: 8px;
}
.aif-di-kiosk__bar {
    width: 30%;
    height: 4px;
    background: rgba(15, 23, 42, 0.10);
    border-radius: 999px;
    margin: 0 auto;
}
.aif-di-kiosk__title {
    font-size: 13px;
    font-weight: 600;
    color: var(--aif-ink);
    text-align: center;
    line-height: 1.3;
}
.aif-di-kiosk__btn {
    background: var(--aif-accent);
    color: #fff;
    text-align: center;
    border-radius: 8px;
    padding: 8px;
    font-size: 12px;
    font-weight: 600;
    box-shadow: 0 6px 14px -4px color-mix(in srgb, var(--aif-accent) 50%, transparent);
}
.aif-di-kiosk__meta {
    display: flex; align-items: center; gap: 6px;
    font-size: 11px;
    color: var(--aif-muted);
    font-weight: 500;
}
.aif-di-kiosk__pulse {
    width: 7px; height: 7px;
    border-radius: 999px;
    background: var(--aif-accent);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--aif-accent) 25%, transparent);
    animation: aif-pulse 1.4s ease-in-out infinite;
}

/* Live triage */
.aif-di-triage {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 10px 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.10);
    display: flex; flex-direction: column; gap: 5px;
}
.aif-di-triage__head {
    font-size: 10.5px;
    font-weight: 700;
    color: var(--aif-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding-bottom: 5px;
    border-bottom: 1px dashed var(--aif-line);
    margin-bottom: 2px;
}
.aif-di-triage__row {
    display: flex; align-items: center; justify-content: space-between;
    padding: 5px 8px;
    border-radius: 7px;
    font-size: 11.5px;
    background: #fafafa;
}
.aif-di-triage__row--alert {
    background: rgba(232, 73, 28, 0.08);
    border: 1px solid rgba(232, 73, 28, 0.22);
    animation: aif-pulse-soft 1.6s ease-in-out infinite;
}
.aif-di-triage__name { color: var(--aif-ink); font-weight: 500; }
.aif-di-triage__pill {
    border-radius: 999px;
    padding: 2px 8px;
    font-size: 10px;
    font-weight: 700;
    flex-shrink: 0;
}
.aif-di-triage__pill--alert { background: #b8331c; color: #fff; }
.aif-di-triage__pill--ok {
    background: rgba(31, 140, 70, 0.12);
    color: #1f8c46;
    border: 1px solid rgba(31, 140, 70, 0.25);
}
.aif-di-triage__pill--wait {
    background: color-mix(in srgb, var(--aif-accent) 10%, white);
    color: var(--aif-accent);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 25%, transparent);
}
@keyframes aif-pulse-soft {
    0%, 100% { box-shadow: 0 0 0 0 rgba(232, 73, 28, 0.10); }
    50% { box-shadow: 0 0 0 4px rgba(232, 73, 28, 0.16); }
}

/* Provider brief */
.aif-di-prep {
    position: relative; z-index: 1;
    align-self: flex-start;
    width: 100%;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px 14px 14px;
    box-shadow: 0 8px 22px -12px rgba(15, 23, 42, 0.10);
    display: flex; flex-direction: column; gap: 5px;
}
.aif-card--di-prep .aif-visual { padding-bottom: 30px; }
.aif-di-prep__head {
    font-size: 11px;
    font-weight: 700;
    color: var(--aif-muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding-bottom: 5px;
    border-bottom: 1px dashed var(--aif-line);
}
.aif-di-prep__row {
    display: flex; gap: 10px;
    font-size: 11.5px;
    padding: 2px 0;
}
.aif-di-prep__row strong {
    color: var(--aif-muted);
    font-weight: 600;
    width: 50px;
    flex-shrink: 0;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding-top: 2px;
}
.aif-di-prep__row span { color: var(--aif-ink); }
.aif-di-prep__row--flag span {
    color: #b8731c;
    font-weight: 600;
}
.aif-di-prep__pill {
    align-self: flex-start;
    margin-top: 6px;
    background: rgba(31, 140, 70, 0.10);
    color: #1f8c46;
    border: 1px solid rgba(31, 140, 70, 0.25);
    border-radius: 999px;
    padding: 3px 9px;
    font-size: 10px;
    font-weight: 700;
    display: flex; align-items: center; gap: 5px;
}
.aif-di-prep__clock { font-size: 10px; }

/* Mobile-first compact */
.aif-di-mobile--compact { gap: 8px; }
.aif-di-mobile--compact .aif-di-mobile__phone {
    padding: 10px;
    border-radius: 12px;
}
.aif-di-mobile--compact .aif-di-mobile__q { font-size: 12px; }
.aif-di-mobile__stat--compact {
    padding: 10px;
}
.aif-di-mobile__stat--compact strong { font-size: 24px; }
.aif-di-mobile__stat--compact span { font-size: 9.5px; }

/* ═══════════════════════════════════════════════════════════
   AI AFTERCARE FEATURES VISUALS
   ═══════════════════════════════════════════════════════════ */

/* Cadence library */
.aif-ac-cadence {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px 14px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 14px;
}
.aif-ac-cadence__row { display: flex; align-items: center; gap: 12px; }
.aif-ac-cadence__name {
    width: 60px;
    font-size: 11px;
    font-weight: 700;
    color: var(--aif-ink);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    flex-shrink: 0;
}
.aif-ac-cadence__line {
    flex: 1;
    position: relative;
    height: 2px;
    background: rgba(15, 23, 42, 0.10);
    border-radius: 999px;
    margin: 0 18px;
}
.aif-ac-cadence__line::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, var(--aif-accent), color-mix(in srgb, var(--aif-accent) 40%, transparent));
    border-radius: 999px;
    opacity: 0.65;
}
.aif-ac-cadence__pt {
    position: absolute;
    top: 50%;
    transform: translate(-50%, -50%);
    background: #fff;
    border: 1.5px solid var(--aif-accent);
    border-radius: 999px;
    padding: 2px 7px;
    font-size: 10px;
    font-weight: 700;
    color: var(--aif-accent);
    white-space: nowrap;
}
.aif-ac-cadence__pt--mid {
    background: var(--aif-accent);
    color: #fff;
}
.aif-ac-cadence__pill {
    align-self: flex-start;
    margin-top: 4px;
    background: color-mix(in srgb, var(--aif-accent) 6%, white);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 22%, transparent);
    color: var(--aif-accent);
    border-radius: 999px;
    padding: 3px 10px;
    font-size: 10.5px;
    font-weight: 700;
}

/* Sentiment scoring */
.aif-ac-sentiment {
    position: relative; z-index: 1;
    display: flex; flex-direction: column; gap: 10px;
}
.aif-ac-sentiment__msg {
    align-self: flex-start;
    background: #f3f3f1;
    padding: 8px 12px;
    border-radius: 12px;
    border-bottom-left-radius: 4px;
    font-size: 12.5px;
    color: var(--aif-ink);
    max-width: 92%;
    line-height: 1.4;
}
.aif-ac-sentiment__meter {
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 10px;
    padding: 10px 12px;
}
.aif-ac-sentiment__bar {
    position: relative;
    height: 8px;
    background: linear-gradient(90deg, #e8491c 0%, #f0b840 50%, #1f8c46 100%);
    border-radius: 999px;
    margin-bottom: 6px;
}
.aif-ac-sentiment__needle {
    position: absolute;
    top: -3px;
    width: 4px;
    height: 14px;
    background: var(--aif-ink);
    border: 2px solid #fff;
    border-radius: 999px;
    transform: translateX(-50%);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.20);
}
.aif-ac-sentiment__legend {
    display: flex; justify-content: space-between;
    font-size: 9.5px;
    color: var(--aif-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    font-weight: 600;
}
.aif-ac-sentiment__route {
    display: flex; align-items: center; gap: 10px;
    background: color-mix(in srgb, var(--aif-accent) 8%, white);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 28%, transparent);
    border-radius: 10px;
    padding: 8px 12px;
}
.aif-ac-sentiment__score {
    background: #1f8c46;
    color: #fff;
    border-radius: 999px;
    padding: 2px 9px;
    font-size: 11px;
    font-weight: 700;
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-ac-sentiment__arrow { color: var(--aif-accent); font-weight: 700; animation: aif-flow-arrow 1.6s ease-in-out infinite; }
.aif-ac-sentiment__action {
    color: var(--aif-ink);
    font-weight: 600;
    font-size: 12px;
}

/* Multi-channel */
.aif-ac-multi { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 5px; }
.aif-ac-multi__row {
    display: flex; align-items: center; gap: 10px;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 8px;
    padding: 6px 10px;
    font-size: 12px;
    color: var(--aif-ink);
    opacity: 0.55;
}
.aif-ac-multi__row--on {
    opacity: 1;
    background: color-mix(in srgb, var(--aif-accent) 5%, white);
    border-color: color-mix(in srgb, var(--aif-accent) 25%, transparent);
}
.aif-ac-multi__icon { font-size: 14px; }
.aif-ac-multi__check {
    margin-left: auto;
    width: 18px; height: 18px;
    border-radius: 999px;
    background: var(--aif-accent);
    color: #fff;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 10px; font-weight: 700;
}

/* Multilingual */
.aif-ac-lang { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 5px; }
.aif-ac-lang__row {
    display: flex; align-items: center; gap: 8px;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 8px;
    padding: 6px 10px;
    font-size: 12px;
    opacity: 0.55;
}
.aif-ac-lang__row--on {
    opacity: 1;
    background: color-mix(in srgb, var(--aif-accent) 5%, white);
    border-color: color-mix(in srgb, var(--aif-accent) 25%, transparent);
}
.aif-ac-lang__flag {
    width: 22px; height: 22px;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
}
.aif-ac-lang__row span:nth-child(2) { flex: 1; color: var(--aif-ink); }
.aif-ac-lang__live {
    width: 7px; height: 7px;
    border-radius: 999px;
    background: var(--aif-accent);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--aif-accent) 25%, transparent);
    animation: aif-pulse 1.4s ease-in-out infinite;
}

/* Auto-pause */
.aif-ac-pause { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 5px; }
.aif-ac-pause__row {
    display: flex; align-items: center; gap: 12px;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 8px;
    padding: 6px 12px;
    font-size: 11.5px;
}
.aif-ac-pause__row--alert {
    background: rgba(232, 73, 28, 0.06);
    border-color: rgba(232, 73, 28, 0.22);
}
.aif-ac-pause__row--off { opacity: 0.5; }
.aif-ac-pause__time {
    font-weight: 700;
    color: var(--aif-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    font-size: 10px;
    width: 32px;
    flex-shrink: 0;
}
.aif-ac-pause__step {
    flex: 1;
    color: var(--aif-ink);
    font-weight: 500;
}
.aif-ac-pause__step--done { color: #1f8c46; font-weight: 700; }
.aif-ac-pause__step--alert { color: #b8331c; font-weight: 700; }

/* Risk scoring */
.aif-ac-risk {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 6px;
}
.aif-ac-risk__head {
    font-size: 10.5px;
    font-weight: 700;
    color: var(--aif-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding-bottom: 6px;
    border-bottom: 1px dashed var(--aif-line);
    margin-bottom: 2px;
}
.aif-ac-risk__row {
    display: grid;
    grid-template-columns: auto 1fr 80px 32px;
    gap: 8px;
    align-items: center;
    padding: 6px 4px;
    border-radius: 7px;
}
.aif-ac-risk__row--high { background: rgba(232, 73, 28, 0.06); }
.aif-ac-risk__row--mid { background: rgba(245, 184, 64, 0.06); }
.aif-ac-risk__row--low { background: rgba(31, 140, 70, 0.06); }
.aif-ac-risk__name { font-size: 12px; color: var(--aif-ink); font-weight: 600; }
.aif-ac-risk__sub { font-size: 10.5px; color: var(--aif-muted); }
.aif-ac-risk__meter {
    height: 4px;
    background: rgba(15, 23, 42, 0.08);
    border-radius: 999px;
    overflow: hidden;
}
.aif-ac-risk__meter span {
    display: block;
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, #1f8c46 0%, #f0b840 50%, #b8331c 100%);
}
.aif-ac-risk__score {
    font-size: 13px;
    font-weight: 700;
    color: var(--aif-ink);
    font-family: ui-monospace, SFMono-Regular, monospace;
    text-align: right;
}
.aif-ac-risk__row--high .aif-ac-risk__score { color: #b8331c; }
.aif-ac-risk__row--mid .aif-ac-risk__score { color: #b8731c; }
.aif-ac-risk__row--low .aif-ac-risk__score { color: #1f8c46; }

/* Auto-encounter note */
.aif-ac-note {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px 14px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 4px;
}
.aif-ac-note__head {
    font-size: 11px;
    font-weight: 700;
    color: var(--aif-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding-bottom: 6px;
    border-bottom: 1px dashed var(--aif-line);
    margin-bottom: 4px;
}
.aif-ac-note__row {
    display: flex; gap: 10px;
    font-size: 11.5px;
    padding: 2px 0;
}
.aif-ac-note__row strong {
    width: 80px;
    flex-shrink: 0;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--aif-muted);
    font-weight: 700;
    padding-top: 1px;
}
.aif-ac-note__row span { color: var(--aif-ink); font-weight: 500; }
.aif-ac-note__pill {
    align-self: flex-start;
    margin-top: 6px;
    background: rgba(31, 140, 70, 0.10);
    color: #1f8c46;
    border: 1px solid rgba(31, 140, 70, 0.25);
    border-radius: 999px;
    padding: 3px 10px;
    font-size: 10.5px;
    font-weight: 700;
}

/* ═══════════════════════════════════════════════════════════
   MISSED-CALL TEXT-BACK FEATURES VISUALS
   ═══════════════════════════════════════════════════════════ */

/* Time-aware templates */
.aif-mc-templates {
    position: relative; z-index: 1;
    display: flex; flex-direction: column; gap: 6px;
}
.aif-mc-templates__row {
    display: flex; align-items: flex-start; gap: 10px;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 10px;
    padding: 8px 12px;
    box-shadow: 0 4px 12px -8px rgba(15, 23, 42, 0.08);
    opacity: 0.55;
}
.aif-mc-templates__row--on {
    opacity: 1;
    background: color-mix(in srgb, var(--aif-accent) 5%, white);
    border-color: color-mix(in srgb, var(--aif-accent) 25%, transparent);
}
.aif-mc-templates__time {
    font-family: ui-monospace, SFMono-Regular, monospace;
    font-size: 11px;
    color: var(--aif-muted);
    font-weight: 600;
    flex-shrink: 0;
    width: 60px;
    padding-top: 1px;
}
.aif-mc-templates__row strong { display: block; font-size: 12px; color: var(--aif-ink); font-weight: 600; }
.aif-mc-templates__row small { font-size: 11px; color: var(--aif-muted); font-style: italic; }

/* Spam filter */
.aif-mc-spam {
    position: relative; z-index: 1;
    display: flex; flex-direction: column; gap: 5px;
}
.aif-mc-spam__row {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 8px;
    padding: 6px 10px;
    border-radius: 7px;
    font-size: 11.5px;
}
.aif-mc-spam__row--ok {
    background: rgba(31, 140, 70, 0.06);
    border: 1px solid rgba(31, 140, 70, 0.18);
}
.aif-mc-spam__row--block {
    background: rgba(15, 23, 42, 0.04);
    border: 1px dashed rgba(15, 23, 42, 0.18);
    opacity: 0.75;
}
.aif-mc-spam__num {
    font-family: ui-monospace, SFMono-Regular, monospace;
    font-size: 10.5px;
    color: var(--aif-muted);
}
.aif-mc-spam__caller { color: var(--aif-ink); font-weight: 500; }
.aif-mc-spam__row--block .aif-mc-spam__caller { text-decoration: line-through; color: var(--aif-muted); }
.aif-mc-spam__pill {
    border-radius: 999px;
    padding: 2px 8px;
    font-size: 10px;
    font-weight: 700;
    flex-shrink: 0;
}
.aif-mc-spam__pill--ok {
    background: rgba(31, 140, 70, 0.15);
    color: #1f8c46;
    border: 1px solid rgba(31, 140, 70, 0.30);
}
.aif-mc-spam__pill--block {
    background: rgba(15, 23, 42, 0.08);
    color: var(--aif-muted);
    border: 1px solid rgba(15, 23, 42, 0.18);
}
.aif-mc-spam__stat {
    margin-top: 4px;
    padding: 6px 10px;
    background: color-mix(in srgb, var(--aif-accent) 6%, white);
    border: 1px dashed color-mix(in srgb, var(--aif-accent) 25%, transparent);
    border-radius: 8px;
    font-size: 11px;
    color: var(--aif-ink);
    font-weight: 600;
    text-align: center;
}

/* Multilingual */
.aif-mc-lang { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 5px; }
.aif-mc-lang__row {
    display: flex; align-items: center; gap: 8px;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 8px;
    padding: 6px 10px;
    font-size: 12px;
    opacity: 0.55;
}
.aif-mc-lang__row--on {
    opacity: 1;
    background: color-mix(in srgb, var(--aif-accent) 5%, white);
    border-color: color-mix(in srgb, var(--aif-accent) 25%, transparent);
}
.aif-mc-lang__flag {
    width: 22px; height: 22px;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
}
.aif-mc-lang__row span:nth-child(2) { flex: 1; color: var(--aif-ink); }
.aif-mc-lang__live {
    width: 7px; height: 7px;
    border-radius: 999px;
    background: var(--aif-accent);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--aif-accent) 25%, transparent);
    animation: aif-pulse 1.4s ease-in-out infinite;
}

/* TCPA */
.aif-mc-tcpa { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 5px; }
.aif-mc-tcpa__row {
    display: flex; align-items: center; gap: 8px;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 8px;
    padding: 7px 10px;
    font-size: 11.5px;
    color: var(--aif-ink);
}
.aif-mc-tcpa__icon {
    width: 18px; height: 18px;
    border-radius: 999px;
    background: var(--aif-accent);
    color: #fff;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 10px; font-weight: 700;
    flex-shrink: 0;
}
.aif-mc-tcpa__pill {
    align-self: flex-start;
    margin-top: 4px;
    background: color-mix(in srgb, var(--aif-accent) 8%, white);
    color: var(--aif-accent);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 28%, transparent);
    border-radius: 999px;
    padding: 3px 10px;
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: 0.04em;
}

/* Phone integrations */
.aif-mc-integrations { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 5px; }
.aif-mc-integrations__row {
    display: flex; align-items: center; gap: 8px;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 8px;
    padding: 7px 12px;
    font-size: 11.5px;
    color: var(--aif-ink);
    box-shadow: 0 4px 10px -8px rgba(15, 23, 42, 0.06);
}
.aif-mc-integrations__name { font-weight: 500; flex: 1; }
.aif-mc-integrations__pulse {
    width: 7px; height: 7px;
    border-radius: 999px;
    background: #1f8c46;
    box-shadow: 0 0 0 3px rgba(31, 140, 70, 0.18);
    animation: aif-pulse 1.4s ease-in-out infinite;
}
.aif-mc-integrations__more {
    text-align: center;
    font-size: 10.5px;
    color: var(--aif-muted);
    font-style: italic;
    padding: 6px;
    border: 1px dashed rgba(15, 23, 42, 0.12);
    border-radius: 8px;
    background: transparent;
}

/* A/B test */
.aif-mc-ab { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 8px; }
.aif-mc-ab__variant {
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 10px;
    padding: 10px 12px;
    display: flex; flex-direction: column; gap: 5px;
}
.aif-mc-ab__variant--win {
    background: color-mix(in srgb, var(--aif-accent) 5%, white);
    border-color: color-mix(in srgb, var(--aif-accent) 28%, transparent);
}
.aif-mc-ab__head {
    font-size: 10.5px;
    font-weight: 700;
    color: var(--aif-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.aif-mc-ab__head--win { color: var(--aif-accent); }
.aif-mc-ab__sample {
    font-size: 11.5px;
    color: var(--aif-ink);
    font-style: italic;
    line-height: 1.4;
}
.aif-mc-ab__bar {
    height: 5px;
    background: rgba(15, 23, 42, 0.06);
    border-radius: 999px;
    overflow: hidden;
}
.aif-mc-ab__bar-fill {
    height: 100%;
    background: rgba(15, 23, 42, 0.30);
    border-radius: 999px;
    animation: aif-bar-grow 1.4s ease-out;
}
.aif-mc-ab__bar-fill--win {
    background: linear-gradient(90deg, color-mix(in srgb, var(--aif-accent) 70%, white), var(--aif-accent));
}
.aif-mc-ab__rate {
    font-size: 11px;
    font-weight: 700;
    color: var(--aif-muted);
    text-align: right;
}
.aif-mc-ab__variant--win .aif-mc-ab__rate { color: var(--aif-accent); }

/* Recovery analytics */
.aif-mc-analytics {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px 14px;
    box-shadow: 0 8px 22px -12px rgba(15, 23, 42, 0.10);
    display: flex; flex-direction: column; gap: 8px;
}
.aif-mc-analytics__head {
    font-size: 10.5px;
    font-weight: 700;
    color: var(--aif-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding-bottom: 6px;
    border-bottom: 1px dashed var(--aif-line);
}
.aif-mc-analytics__hero {
    display: flex; align-items: baseline; gap: 8px;
    padding: 6px 0;
}
.aif-mc-analytics__hero strong {
    font-size: 32px;
    font-weight: 800;
    color: var(--aif-accent);
    letter-spacing: -0.02em;
    line-height: 1;
}
.aif-mc-analytics__hero small {
    font-size: 11px;
    color: var(--aif-muted);
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}
.aif-mc-analytics__breakdown {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4px;
}
.aif-mc-analytics__row {
    display: flex; justify-content: space-between;
    background: color-mix(in srgb, var(--aif-accent) 5%, white);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 18%, transparent);
    border-radius: 7px;
    padding: 5px 9px;
    font-size: 11px;
    color: var(--aif-ink);
}
.aif-mc-analytics__row strong { font-weight: 700; color: var(--aif-accent); }
.aif-mc-analytics__row--lost {
    background: rgba(15, 23, 42, 0.04);
    border-color: rgba(15, 23, 42, 0.10);
    color: var(--aif-muted);
}
.aif-mc-analytics__row--lost strong { color: var(--aif-muted); }
.aif-mc-analytics__pill {
    align-self: flex-start;
    margin-top: 4px;
    background: rgba(31, 140, 70, 0.10);
    color: #1f8c46;
    border: 1px solid rgba(31, 140, 70, 0.25);
    border-radius: 999px;
    padding: 3px 10px;
    font-size: 10.5px;
    font-weight: 700;
}

/* ═══════════════════════════════════════════════════════════
   APPOINTMENT REMINDERS FEATURES VISUALS
   ═══════════════════════════════════════════════════════════ */

/* Risk-scored cadence */
.aif-ar-cadence {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 10px;
}
.aif-ar-cadence__row {
    display: flex; align-items: center; gap: 10px;
}
.aif-ar-cadence__tier {
    width: 75px;
    flex-shrink: 0;
    font-size: 10.5px;
    font-weight: 700;
    color: var(--aif-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 4px 8px;
    border-radius: 999px;
    text-align: center;
}
.aif-ar-cadence__row--low .aif-ar-cadence__tier { background: rgba(31, 140, 70, 0.12); color: #1f8c46; border: 1px solid rgba(31, 140, 70, 0.22); }
.aif-ar-cadence__row--mid .aif-ar-cadence__tier { background: rgba(245, 184, 64, 0.12); color: #b8731c; border: 1px solid rgba(245, 184, 64, 0.30); }
.aif-ar-cadence__row--high .aif-ar-cadence__tier { background: rgba(232, 73, 28, 0.12); color: #b8331c; border: 1px solid rgba(232, 73, 28, 0.28); }
.aif-ar-cadence__steps { display: flex; gap: 5px; flex-wrap: wrap; }
.aif-ar-cadence__step {
    background: color-mix(in srgb, var(--aif-accent) 5%, white);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 20%, transparent);
    color: var(--aif-ink);
    border-radius: 7px;
    padding: 4px 9px;
    font-size: 11px;
    font-weight: 600;
}

/* Channel preference */
.aif-ar-channel {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 6px;
}
.aif-ar-channel__row {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 10px;
    align-items: center;
    background: #fafaf8;
    border-radius: 8px;
    padding: 7px 10px;
}
.aif-ar-channel__avatar {
    width: 28px; height: 28px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--aif-accent) 0%, color-mix(in srgb, var(--aif-accent) 60%, black) 100%);
    color: #fff;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 11px; font-weight: 700;
}
.aif-ar-channel__name { font-size: 12px; color: var(--aif-ink); font-weight: 500; }
.aif-ar-channel__pick {
    border-radius: 999px;
    padding: 3px 10px;
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: 0.04em;
}
.aif-ar-channel__pick--sms {
    background: color-mix(in srgb, var(--aif-accent) 12%, white);
    color: var(--aif-accent);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 28%, transparent);
}
.aif-ar-channel__pick--email {
    background: rgba(58, 123, 213, 0.12);
    color: #1c4a8c;
    border: 1px solid rgba(58, 123, 213, 0.30);
}
.aif-ar-channel__pick--voice {
    background: rgba(31, 140, 70, 0.12);
    color: #1f8c46;
    border: 1px solid rgba(31, 140, 70, 0.30);
}
.aif-ar-channel__pill {
    align-self: flex-start;
    margin-top: 2px;
    font-size: 10px;
    color: var(--aif-muted);
    font-style: italic;
}

/* Smart send-time */
.aif-ar-time { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 5px; }
.aif-ar-time__row {
    display: flex; justify-content: space-between; align-items: center;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 8px;
    padding: 7px 10px;
    font-size: 12px;
    opacity: 0.55;
}
.aif-ar-time__row--on {
    opacity: 1;
    background: color-mix(in srgb, var(--aif-accent) 5%, white);
    border-color: color-mix(in srgb, var(--aif-accent) 25%, transparent);
}
.aif-ar-time__name { color: var(--aif-ink); font-weight: 500; }
.aif-ar-time__hour {
    font-family: ui-monospace, SFMono-Regular, monospace;
    font-size: 11.5px;
    font-weight: 700;
    color: var(--aif-accent);
}
.aif-ar-time__pill {
    align-self: flex-start;
    margin-top: 4px;
    background: rgba(31, 140, 70, 0.10);
    color: #1f8c46;
    border: 1px solid rgba(31, 140, 70, 0.25);
    border-radius: 999px;
    padding: 3px 9px;
    font-size: 10.5px;
    font-weight: 700;
}

/* Multilingual (reuse pattern) */
.aif-ar-lang { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 5px; }
.aif-ar-lang__row {
    display: flex; align-items: center; gap: 8px;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 8px;
    padding: 6px 10px;
    font-size: 12px;
    opacity: 0.55;
}
.aif-ar-lang__row--on {
    opacity: 1;
    background: color-mix(in srgb, var(--aif-accent) 5%, white);
    border-color: color-mix(in srgb, var(--aif-accent) 25%, transparent);
}
.aif-ar-lang__flag {
    width: 22px; height: 22px;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
}
.aif-ar-lang__row span:nth-child(2) { flex: 1; color: var(--aif-ink); }
.aif-ar-lang__live {
    width: 7px; height: 7px;
    border-radius: 999px;
    background: var(--aif-accent);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--aif-accent) 25%, transparent);
    animation: aif-pulse 1.4s ease-in-out infinite;
}

/* Reply intent */
.aif-ar-intent { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 6px; }
.aif-ar-intent__msg {
    align-self: flex-start;
    background: #f3f3f1;
    border-radius: 12px;
    border-bottom-left-radius: 4px;
    padding: 7px 12px;
    font-size: 12px;
    color: var(--aif-ink);
    max-width: 90%;
    line-height: 1.4;
}
.aif-ar-intent__route {
    display: flex; align-items: center; gap: 8px;
    padding-left: 16px;
}
.aif-ar-intent__arrow { color: var(--aif-accent); font-weight: 700; }
.aif-ar-intent__action {
    border-radius: 999px;
    padding: 3px 10px;
    font-size: 11px;
    font-weight: 700;
}
.aif-ar-intent__action--ok {
    background: rgba(31, 140, 70, 0.12);
    color: #1f8c46;
    border: 1px solid rgba(31, 140, 70, 0.30);
}
.aif-ar-intent__action--alt {
    background: color-mix(in srgb, var(--aif-accent) 12%, white);
    color: var(--aif-accent);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 28%, transparent);
}

/* Visit-type templates */
.aif-ar-templates {
    position: relative; z-index: 1;
    display: flex; flex-direction: column; gap: 6px;
}
.aif-ar-templates__row {
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 10px;
    padding: 8px 12px;
    box-shadow: 0 4px 12px -8px rgba(15, 23, 42, 0.06);
    opacity: 0.6;
}
.aif-ar-templates__row--on {
    opacity: 1;
    background: color-mix(in srgb, var(--aif-accent) 5%, white);
    border-color: color-mix(in srgb, var(--aif-accent) 25%, transparent);
}
.aif-ar-templates__type {
    display: block;
    font-size: 11.5px;
    font-weight: 700;
    color: var(--aif-ink);
    margin-bottom: 3px;
}
.aif-ar-templates__row--on .aif-ar-templates__type { color: var(--aif-accent); }
.aif-ar-templates__row small {
    display: block;
    font-size: 11.5px;
    color: var(--aif-muted);
    font-style: italic;
    line-height: 1.4;
}

/* No-show dashboard */
.aif-ar-dashboard {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px 14px;
    box-shadow: 0 8px 22px -12px rgba(15, 23, 42, 0.10);
    display: flex; flex-direction: column; gap: 10px;
}
.aif-ar-dashboard__head {
    font-size: 10.5px;
    font-weight: 700;
    color: var(--aif-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding-bottom: 6px;
    border-bottom: 1px dashed var(--aif-line);
}
.aif-ar-dashboard__chart {
    display: flex;
    align-items: flex-end;
    gap: 5px;
    height: 90px;
    padding: 0 4px;
}
.aif-ar-dashboard__bar {
    flex: 1;
    background: linear-gradient(180deg, color-mix(in srgb, var(--aif-accent) 50%, white) 0%, color-mix(in srgb, var(--aif-accent) 80%, white) 100%);
    border-radius: 6px 6px 0 0;
    position: relative;
    animation: aif-bar-grow 1.4s ease-out;
    display: flex; align-items: flex-start; justify-content: center;
}
.aif-ar-dashboard__bar span {
    margin-top: -16px;
    font-size: 10px;
    font-weight: 700;
    color: var(--aif-muted);
}
.aif-ar-dashboard__bar--mid {
    background: linear-gradient(180deg, #f5b86b 0%, #e89530 100%);
}
.aif-ar-dashboard__bar--mid span { color: #b8731c; }
.aif-ar-dashboard__bar--good {
    background: linear-gradient(180deg, #6ee7a8 0%, #1f8c46 100%);
}
.aif-ar-dashboard__bar--good span { color: #1f8c46; }
.aif-ar-dashboard__legend {
    display: flex; justify-content: space-between; align-items: center;
    font-size: 11px;
    color: var(--aif-muted);
    font-weight: 600;
    padding-top: 6px;
    border-top: 1px dashed var(--aif-line);
}
.aif-ar-dashboard__pill {
    background: rgba(31, 140, 70, 0.12);
    color: #1f8c46;
    border: 1px solid rgba(31, 140, 70, 0.25);
    border-radius: 999px;
    padding: 3px 10px;
    font-weight: 700;
}

/* ═══════════════════════════════════════════════════════════
   PATIENT CRM FEATURES VISUALS
   ═══════════════════════════════════════════════════════════ */

/* Source attribution */
.aif-crm-source {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 6px;
}
.aif-crm-source__row {
    display: grid;
    grid-template-columns: 90px 1fr 32px;
    gap: 10px;
    align-items: center;
}
.aif-crm-source__name { font-size: 11.5px; color: var(--aif-ink); font-weight: 500; }
.aif-crm-source__bar {
    height: 6px;
    background: rgba(15, 23, 42, 0.06);
    border-radius: 999px;
    overflow: hidden;
}
.aif-crm-source__fill {
    height: 100%;
    background: linear-gradient(90deg, color-mix(in srgb, var(--aif-accent) 70%, white), var(--aif-accent));
    border-radius: 999px;
    animation: aif-bar-grow 1.4s ease-out;
}
.aif-crm-source__num {
    text-align: right;
    font-size: 12px;
    font-weight: 700;
    color: var(--aif-accent);
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-crm-source__hero {
    margin-top: auto;
    padding: 12px 14px;
    background: linear-gradient(135deg, rgba(31, 140, 70, 0.06) 0%, rgba(110, 231, 168, 0.12) 100%);
    border: 1px solid rgba(31, 140, 70, 0.22);
    border-radius: 12px;
    display: flex; align-items: baseline; justify-content: space-between;
    gap: 12px;
}
.aif-crm-source__hero-label {
    font-size: 10.5px;
    font-weight: 700;
    color: rgba(26, 26, 26, 0.55);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.aif-crm-source__hero-amount {
    font-size: 26px;
    font-weight: 800;
    color: #1f8c46;
    letter-spacing: -0.02em;
    line-height: 1;
    font-family: ui-monospace, SFMono-Regular, monospace;
}

/* Consult pipeline */
.aif-crm-pipeline {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 6px;
}
.aif-crm-pipeline__row {
    display: grid;
    grid-template-columns: 110px 1fr 32px;
    align-items: center;
    gap: 10px;
}
.aif-crm-pipeline__name {
    font-size: 11.5px;
    color: var(--aif-ink);
    font-weight: 500;
}
.aif-crm-pipeline__row--won .aif-crm-pipeline__name { color: #1f8c46; font-weight: 600; }
.aif-crm-pipeline__track {
    height: 6px;
    background: rgba(15, 23, 42, 0.06);
    border-radius: 999px;
    overflow: hidden;
}
.aif-crm-pipeline__bar {
    height: 100%;
    background: linear-gradient(90deg, color-mix(in srgb, var(--aif-accent) 70%, white) 0%, var(--aif-accent) 100%);
    border-radius: 999px;
    animation: aif-bar-grow 1.4s ease-out;
}
.aif-crm-pipeline__bar--won {
    background: linear-gradient(90deg, #6ee7a8 0%, #1f8c46 100%);
}
.aif-crm-pipeline__count {
    text-align: right;
    font-size: 12px;
    font-weight: 700;
    color: var(--aif-accent);
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-crm-pipeline__count--won { color: #1f8c46; }
.aif-crm-pipeline__hero {
    margin-top: auto;
    padding: 12px 14px;
    background: linear-gradient(135deg, rgba(31, 140, 70, 0.06) 0%, rgba(110, 231, 168, 0.12) 100%);
    border: 1px solid rgba(31, 140, 70, 0.22);
    border-radius: 12px;
    display: flex; align-items: baseline; justify-content: space-between;
    gap: 12px;
}
.aif-crm-pipeline__hero-label {
    font-size: 10.5px;
    font-weight: 700;
    color: rgba(26, 26, 26, 0.55);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.aif-crm-pipeline__hero-amount {
    font-size: 26px;
    font-weight: 800;
    color: #1f8c46;
    letter-spacing: -0.02em;
    line-height: 1;
    font-family: ui-monospace, SFMono-Regular, monospace;
}

/* EHR sync */
.aif-crm-ehr {
    position: relative; z-index: 1;
    display: flex; align-items: center; gap: 10px;
    justify-content: space-between;
}
.aif-crm-ehr__node {
    flex: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 10px;
    padding: 10px 8px;
    text-align: center;
    box-shadow: 0 4px 12px -8px rgba(15, 23, 42, 0.06);
    position: relative;
}
.aif-crm-ehr__node--crm {
    background: linear-gradient(135deg, color-mix(in srgb, var(--aif-accent) 10%, white) 0%, color-mix(in srgb, var(--aif-accent) 20%, white) 100%);
    border-color: color-mix(in srgb, var(--aif-accent) 30%, transparent);
}
.aif-crm-ehr__node strong { display: block; font-size: 12px; color: var(--aif-ink); font-weight: 700; }
.aif-crm-ehr__node small { font-size: 10px; color: var(--aif-muted); font-style: italic; }
.aif-crm-ehr__pulse {
    position: absolute;
    top: 4px; right: 6px;
    width: 6px; height: 6px;
    border-radius: 999px;
    background: var(--aif-accent);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--aif-accent) 25%, transparent);
    animation: aif-pulse 1.4s ease-in-out infinite;
}
.aif-crm-ehr__arrows {
    display: flex; flex-direction: column; gap: 3px;
    color: var(--aif-accent);
    font-size: 14px;
    font-weight: 700;
}
.aif-crm-ehr__arrow--right { animation: aif-flow-arrow 1.6s ease-in-out infinite; }
.aif-crm-ehr__arrow--left { animation: aif-flow-arrow 1.6s ease-in-out infinite reverse; }

/* Smart dedupe */
.aif-crm-dedupe {
    position: relative; z-index: 1;
    display: flex; flex-direction: column; gap: 5px;
}
.aif-crm-dedupe__row {
    display: flex; align-items: center; gap: 8px;
    background: #fff;
    border: 1px dashed rgba(15, 23, 42, 0.18);
    border-radius: 8px;
    padding: 6px 10px;
    font-size: 11.5px;
}
.aif-crm-dedupe__name { color: var(--aif-ink); font-weight: 600; flex: 1; }
.aif-crm-dedupe__sub {
    font-family: ui-monospace, SFMono-Regular, monospace;
    font-size: 10.5px;
    color: var(--aif-muted);
}
.aif-crm-dedupe__merge {
    display: flex; align-items: center; justify-content: center; gap: 8px;
    margin-top: 2px;
}
.aif-crm-dedupe__arrow {
    color: var(--aif-accent);
    font-size: 14px;
    font-weight: 700;
}
.aif-crm-dedupe__pill {
    background: rgba(31, 140, 70, 0.12);
    color: #1f8c46;
    border: 1px solid rgba(31, 140, 70, 0.30);
    border-radius: 999px;
    padding: 3px 10px;
    font-size: 10.5px;
    font-weight: 700;
}

/* Privacy & access */
.aif-crm-privacy {
    position: relative; z-index: 1;
    display: flex; flex-direction: column; gap: 5px;
}
.aif-crm-privacy__row {
    display: grid;
    grid-template-columns: 75px 1fr;
    gap: 8px;
    align-items: center;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 8px;
    padding: 6px 10px;
}
.aif-crm-privacy__role {
    font-size: 10.5px;
    font-weight: 700;
    color: var(--aif-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}
.aif-crm-privacy__pills { display: flex; gap: 4px; flex-wrap: wrap; }
.aif-crm-privacy__pill {
    border-radius: 999px;
    padding: 2px 7px;
    font-size: 10px;
    font-weight: 700;
}
.aif-crm-privacy__pill--ok {
    background: color-mix(in srgb, var(--aif-accent) 8%, white);
    color: var(--aif-accent);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 25%, transparent);
}
.aif-crm-privacy__pill--all {
    background: var(--aif-ink);
    color: #fff;
    border: 1px solid var(--aif-ink);
}

/* Cohort analytics */
.aif-crm-cohort {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 6px;
}
.aif-crm-cohort__row {
    display: grid;
    grid-template-columns: 110px 1fr;
    gap: 10px;
    align-items: center;
    padding: 8px 10px;
    border-radius: 8px;
    background: #fafafa;
}
.aif-crm-cohort__row--on {
    background: color-mix(in srgb, var(--aif-accent) 6%, white);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 25%, transparent);
}
.aif-crm-cohort__name { font-size: 12px; color: var(--aif-ink); font-weight: 600; }
.aif-crm-cohort__metrics { display: flex; gap: 6px; }
.aif-crm-cohort__m {
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 999px;
    padding: 3px 9px;
    font-size: 10.5px;
    color: var(--aif-muted);
    font-weight: 600;
}
.aif-crm-cohort__m--win {
    background: color-mix(in srgb, var(--aif-accent) 12%, white);
    color: var(--aif-accent);
    border-color: color-mix(in srgb, var(--aif-accent) 30%, transparent);
}

/* Agent control center */
.aif-crm-cockpit {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 14px;
    padding: 12px 14px;
    box-shadow: 0 8px 22px -12px rgba(15, 23, 42, 0.10);
    display: flex; flex-direction: column; gap: 10px;
}
.aif-crm-cockpit__head {
    font-size: 10.5px;
    font-weight: 700;
    color: var(--aif-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding-bottom: 8px;
    border-bottom: 1px dashed var(--aif-line);
}
.aif-crm-cockpit__grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 6px;
}
.aif-crm-cockpit__agent {
    background: #fafafa;
    border: 1px solid var(--aif-line);
    border-radius: 10px;
    padding: 8px 10px;
    display: flex; flex-direction: column; gap: 2px;
    position: relative;
}
.aif-crm-cockpit__top {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 4px;
}
.aif-crm-cockpit__icon { font-size: 16px; }
.aif-crm-cockpit__pulse {
    width: 7px; height: 7px;
    border-radius: 999px;
    background: #1f8c46;
    box-shadow: 0 0 0 3px rgba(31, 140, 70, 0.18);
    animation: aif-pulse 1.4s ease-in-out infinite;
}
.aif-crm-cockpit__agent strong {
    font-size: 11.5px;
    font-weight: 700;
    color: var(--aif-ink);
}
.aif-crm-cockpit__agent small {
    font-size: 10px;
    color: var(--aif-muted);
    font-weight: 500;
}
.aif-crm-cockpit__agent--more {
    background: linear-gradient(135deg, color-mix(in srgb, var(--aif-accent) 8%, white) 0%, color-mix(in srgb, var(--aif-accent) 16%, white) 100%);
    border: 1px dashed color-mix(in srgb, var(--aif-accent) 35%, transparent);
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 14px 10px;
}
.aif-crm-cockpit__agent--more strong {
    color: var(--aif-accent);
    font-size: 13px;
}
.aif-crm-cockpit__agent--more small {
    color: var(--aif-accent);
    font-style: italic;
    font-weight: 600;
}

/* ─────────────────────────────────────────────────────────
   AI Aesthetics — bespoke visuals
   ───────────────────────────────────────────────────────── */

/* Card 1 — AI-suggested combos (3 packages) */
.aif-ae-combo {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    flex: 1;
}
.aif-ae-combo__pkg {
    position: relative;
    padding: 22px 14px 18px;
    border-radius: 12px;
    background: rgba(15, 23, 42, 0.025);
    border: 1px solid rgba(15, 23, 42, 0.06);
    display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    text-align: center;
    gap: 6px;
    transition: transform 0.2s ease, background 0.2s ease;
}
.aif-ae-combo__pkg:hover { transform: translateY(-2px); }
.aif-ae-combo__pkg--rec {
    background: linear-gradient(180deg, color-mix(in srgb, var(--aif-accent) 8%, white) 0%, color-mix(in srgb, var(--aif-accent) 16%, white) 100%);
    border-color: color-mix(in srgb, var(--aif-accent) 38%, transparent);
    box-shadow: 0 10px 22px -12px color-mix(in srgb, var(--aif-accent) 40%, transparent);
}
.aif-ae-combo__badge {
    position: absolute;
    top: -10px; left: 50%;
    transform: translateX(-50%);
    background: var(--aif-accent);
    color: #fff;
    font-size: 9.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding: 4px 11px;
    border-radius: 999px;
    white-space: nowrap;
    box-shadow: 0 4px 8px -3px color-mix(in srgb, var(--aif-accent) 50%, transparent);
}
.aif-ae-combo__name {
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--aif-muted);
}
.aif-ae-combo__pkg--rec .aif-ae-combo__name { color: var(--aif-accent); }
.aif-ae-combo__amt {
    font-size: 26px;
    font-weight: 800;
    color: var(--aif-ink);
    letter-spacing: -0.02em;
    line-height: 1;
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-ae-combo__pkg--rec .aif-ae-combo__amt { color: var(--aif-accent); }
.aif-ae-combo__sub {
    font-size: 10.5px;
    color: var(--aif-muted);
    font-weight: 600;
}

/* Card 3 — Aging timeline preview */
.aif-ae-aging {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 14px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 10px;
    flex: 1;
    justify-content: center;
}
.aif-ae-aging__row {
    position: relative;
    display: grid;
    grid-template-columns: 90px 1fr;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 10px;
    background: rgba(15, 23, 42, 0.025);
    border: 1px solid rgba(15, 23, 42, 0.05);
}
.aif-ae-aging__row--bad {
    background: rgba(220, 38, 38, 0.04);
    border-color: rgba(220, 38, 38, 0.18);
}
.aif-ae-aging__row--good {
    background: rgba(31, 140, 70, 0.06);
    border-color: rgba(31, 140, 70, 0.25);
}
.aif-ae-aging__year {
    font-size: 10.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--aif-muted);
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-ae-aging__row--bad .aif-ae-aging__year { color: #b91c1c; }
.aif-ae-aging__row--good .aif-ae-aging__year { color: #1f8c46; }
.aif-ae-aging__face {
    position: relative;
    height: 56px;
    border-radius: 8px;
    background: linear-gradient(135deg, #fde2c4 0%, #f5d4b8 100%);
    overflow: hidden;
}
.aif-ae-aging__face::before {
    content: "";
    position: absolute;
    inset: 8px;
    border-radius: 50%;
    background: radial-gradient(ellipse at 50% 40%, #fff5e8 0%, #f5d4b8 70%);
    opacity: 0.9;
}
.aif-ae-aging__face::after {
    content: "";
    position: absolute;
    top: 38%; left: 50%;
    transform: translateX(-50%);
    width: 16px; height: 8px;
    border-bottom: 2px solid rgba(15, 23, 42, 0.55);
    border-radius: 0 0 999px 999px;
}
.aif-ae-aging__face--bad {
    background: linear-gradient(135deg, #f0d4c0 0%, #d8a890 100%);
}
.aif-ae-aging__face--bad::after {
    box-shadow:
        0 -8px 0 -6px rgba(15, 23, 42, 0.35),
        -10px 4px 0 -7px rgba(15, 23, 42, 0.4),
        10px 4px 0 -7px rgba(15, 23, 42, 0.4),
        0 8px 0 -7px rgba(15, 23, 42, 0.4);
}
.aif-ae-aging__face--good {
    background: linear-gradient(135deg, #fde7c8 0%, #f5cfa8 100%);
    box-shadow: inset 0 0 0 2px rgba(31, 140, 70, 0.4);
}
.aif-ae-aging__check {
    position: absolute;
    top: 8px; right: 10px;
    width: 22px; height: 22px;
    background: #1f8c46;
    color: #fff;
    border-radius: 999px;
    display: flex; align-items: center; justify-content: center;
    font-size: 13px;
    font-weight: 800;
    box-shadow: 0 4px 8px -3px rgba(31, 140, 70, 0.5);
}

/* Card 5 — Tap-to-learn FAQ-style dropdown */
.aif-ae-faq {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 8px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 4px;
    flex: 1;
}
.aif-ae-faq__item {
    border-radius: 10px;
    border: 1px solid rgba(15, 23, 42, 0.06);
    background: rgba(15, 23, 42, 0.02);
    overflow: hidden;
    transition: background 0.2s ease, border-color 0.2s ease;
}
.aif-ae-faq__item:hover {
    background: rgba(15, 23, 42, 0.04);
}
.aif-ae-faq__item--open {
    background: linear-gradient(180deg, color-mix(in srgb, var(--aif-accent) 5%, white) 0%, color-mix(in srgb, var(--aif-accent) 10%, white) 100%);
    border-color: color-mix(in srgb, var(--aif-accent) 30%, transparent);
    flex: 1;
}
.aif-ae-faq__head {
    display: flex; align-items: center; justify-content: space-between;
    padding: 11px 14px;
    cursor: pointer;
}
.aif-ae-faq__label {
    font-size: 12px;
    font-weight: 700;
    color: var(--aif-ink);
    letter-spacing: -0.005em;
}
.aif-ae-faq__item--open .aif-ae-faq__label {
    color: var(--aif-accent);
    font-weight: 800;
}
.aif-ae-faq__chev {
    font-size: 11px;
    color: var(--aif-muted);
    transition: transform 0.25s ease;
}
.aif-ae-faq__item--open .aif-ae-faq__chev {
    color: var(--aif-accent);
}
.aif-ae-faq__body {
    padding: 4px 14px 12px;
    display: flex; flex-direction: column; gap: 1px;
}
.aif-ae-faq__row {
    display: grid;
    grid-template-columns: 90px 1fr;
    gap: 12px;
    align-items: center;
    padding: 8px 0;
    border-top: 1px dashed color-mix(in srgb, var(--aif-accent) 24%, transparent);
    font-size: 11.5px;
}
.aif-ae-faq__row > span:first-child {
    font-size: 9.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: rgba(26, 26, 26, 0.55);
}
.aif-ae-faq__row > span:last-child {
    color: var(--aif-ink);
    font-weight: 600;
}

/* Card 5 (legacy) — Tap-to-learn education layer */
.aif-ae-learn {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 10px;
    flex: 1;
}
.aif-ae-learn__nav {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 4px;
    padding: 4px;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.04);
}
.aif-ae-learn__tab {
    text-align: center;
    padding: 7px 0;
    font-size: 10.5px;
    font-weight: 700;
    color: var(--aif-muted);
    border-radius: 999px;
    transition: all 0.2s ease;
}
.aif-ae-learn__tab--active {
    background: #fff;
    color: var(--aif-accent);
    box-shadow: 0 2px 6px -2px rgba(15, 23, 42, 0.18);
}
.aif-ae-learn__card {
    flex: 1;
    padding: 18px 16px;
    border-radius: 12px;
    background: linear-gradient(180deg, color-mix(in srgb, var(--aif-accent) 6%, white) 0%, color-mix(in srgb, var(--aif-accent) 14%, white) 100%);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 30%, transparent);
    display: flex; flex-direction: column; gap: 4px;
    align-items: center; text-align: center;
    justify-content: center;
}
.aif-ae-learn__title {
    font-size: 16px;
    font-weight: 800;
    color: var(--aif-accent);
    letter-spacing: -0.01em;
}
.aif-ae-learn__sub {
    font-size: 10.5px;
    color: rgba(15, 23, 42, 0.55);
    font-weight: 600;
    margin-bottom: 10px;
}
.aif-ae-learn__facts {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    width: 100%;
}
.aif-ae-learn__fact {
    padding: 8px 10px;
    border-radius: 8px;
    background: #fff;
    border: 1px solid color-mix(in srgb, var(--aif-accent) 22%, transparent);
    display: flex; flex-direction: column; gap: 2px;
    align-items: center;
    text-align: center;
}
.aif-ae-learn__fact-label {
    font-size: 9.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--aif-muted);
}
.aif-ae-learn__fact-val {
    font-size: 12px;
    font-weight: 800;
    color: var(--aif-ink);
    font-family: ui-monospace, SFMono-Regular, monospace;
    letter-spacing: -0.01em;
}

/* Card 1 (legacy) — Before/after simulation split */
.aif-ae-sim {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 14px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 12px;
    flex: 1;
}
.aif-ae-sim__split {
    display: grid;
    grid-template-columns: 1fr 1px 1fr;
    gap: 0;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid rgba(15, 23, 42, 0.06);
}
.aif-ae-sim__pane {
    padding: 14px 12px;
    display: flex; flex-direction: column; align-items: center; gap: 6px;
    background: rgba(15, 23, 42, 0.025);
}
.aif-ae-sim__pane--after {
    background: linear-gradient(135deg, rgba(31, 140, 70, 0.04) 0%, rgba(110, 231, 168, 0.10) 100%);
}
.aif-ae-sim__divider {
    background: rgba(15, 23, 42, 0.08);
}
.aif-ae-sim__label {
    font-size: 9.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--aif-muted);
    padding: 3px 9px;
    border-radius: 999px;
    background: #fff;
    border: 1px solid rgba(15, 23, 42, 0.08);
}
.aif-ae-sim__label--after {
    color: #1f8c46;
    border-color: rgba(31, 140, 70, 0.3);
    background: rgba(31, 140, 70, 0.08);
}
.aif-ae-sim__face {
    width: 90px; height: 110px;
    color: var(--aif-accent);
}
.aif-ae-sim__pane--after .aif-ae-sim__face { color: #1f8c46; }
.aif-ae-sim__caption {
    font-size: 10px;
    font-weight: 600;
    color: var(--aif-muted);
    text-align: center;
}
.aif-ae-sim__caption--after { color: #1f8c46; font-weight: 700; }
.aif-ae-sim__hero {
    margin-top: auto;
    padding: 12px 14px;
    background: linear-gradient(135deg, rgba(31, 140, 70, 0.06) 0%, rgba(110, 231, 168, 0.12) 100%);
    border: 1px solid rgba(31, 140, 70, 0.22);
    border-radius: 12px;
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    column-gap: 12px;
}
.aif-ae-sim__hero-label {
    font-size: 10.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: rgba(26, 26, 26, 0.55);
    grid-column: 1; grid-row: 1;
    align-self: end;
}
.aif-ae-sim__hero-amount {
    font-size: 28px;
    font-weight: 800;
    color: #1f8c46;
    letter-spacing: -0.02em;
    line-height: 1;
    font-family: ui-monospace, SFMono-Regular, monospace;
    grid-column: 2; grid-row: 1 / span 2;
    align-self: center;
    padding-left: 14px;
    border-left: 1px solid rgba(31, 140, 70, 0.22);
}
.aif-ae-sim__hero-amount small { font-size: 14px; font-weight: 700; margin-left: 1px; }
.aif-ae-sim__hero-side {
    font-size: 10.5px;
    font-weight: 700;
    color: rgba(26, 26, 26, 0.55);
    grid-column: 1; grid-row: 2;
}

/* Card 2 — Treatment canvas (face map with pins + price list) */
.aif-ae-canvas {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 14px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: grid;
    grid-template-columns: 150px 1fr;
    grid-template-rows: 1fr auto;
    gap: 14px;
    flex: 1;
}
.aif-ae-canvas__face {
    grid-row: 1 / span 1;
    grid-column: 1;
    position: relative;
    background: linear-gradient(180deg, color-mix(in srgb, var(--aif-accent) 5%, white) 0%, #fff 100%);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 20%, transparent);
    border-radius: 12px;
    overflow: hidden;
    color: rgba(15, 23, 42, 0.45);
}
.aif-ae-canvas__face-img {
    position: absolute;
    inset: 0;
    width: 100%; height: 100%;
    object-fit: contain;
    padding: 8px;
}
.aif-ae-canvas__pin {
    position: absolute;
    transform: translate(-50%, -50%);
    width: 12px; height: 12px;
    border-radius: 999px;
    background: var(--aif-accent);
    box-shadow: 0 0 0 4px color-mix(in srgb, var(--aif-accent) 25%, transparent);
    animation: aif-ae-canvas-pulse 1.8s ease-in-out infinite;
    z-index: 2;
}
.aif-ae-canvas__pin:nth-of-type(1) { animation-delay: 0.0s; }
.aif-ae-canvas__pin:nth-of-type(2) { animation-delay: 0.25s; }
.aif-ae-canvas__pin:nth-of-type(3) { animation-delay: 0.50s; }
.aif-ae-canvas__pin:nth-of-type(4) { animation-delay: 0.75s; }
@keyframes aif-ae-canvas-pulse {
    0%, 100% { opacity: 0.85; transform: translate(-50%, -50%) scale(1); }
    50%      { opacity: 1;    transform: translate(-50%, -50%) scale(1.2); }
}
.aif-ae-canvas__list {
    grid-row: 1 / span 1;
    grid-column: 2;
    display: flex; flex-direction: column; gap: 5px;
    align-self: stretch;
    justify-content: space-evenly;
}
.aif-ae-canvas__line {
    display: grid;
    grid-template-columns: 12px 1fr auto;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border-radius: 8px;
    background: rgba(15, 23, 42, 0.025);
    border: 1px solid rgba(15, 23, 42, 0.05);
}
.aif-ae-canvas__dot {
    width: 8px; height: 8px;
    border-radius: 999px;
    background: var(--aif-accent);
    box-shadow: 0 0 0 2px color-mix(in srgb, var(--aif-accent) 25%, transparent);
}
.aif-ae-canvas__txt {
    font-size: 11px;
    color: var(--aif-ink);
    font-weight: 600;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.aif-ae-canvas__line strong {
    font-weight: 800;
    font-family: ui-monospace, SFMono-Regular, monospace;
    color: var(--aif-accent);
    font-size: 12px;
    letter-spacing: -0.01em;
}
.aif-ae-canvas__hero {
    grid-row: 2;
    grid-column: 1 / span 2;
    padding: 12px 14px;
    background: linear-gradient(135deg, rgba(31, 140, 70, 0.06) 0%, rgba(110, 231, 168, 0.12) 100%);
    border: 1px solid rgba(31, 140, 70, 0.22);
    border-radius: 12px;
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    column-gap: 12px;
}
.aif-ae-canvas__hero-label {
    font-size: 10.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: rgba(26, 26, 26, 0.55);
    grid-column: 1; grid-row: 1;
    align-self: end;
}
.aif-ae-canvas__hero-amount {
    font-size: 26px;
    font-weight: 800;
    color: #1f8c46;
    letter-spacing: -0.02em;
    line-height: 1;
    font-family: ui-monospace, SFMono-Regular, monospace;
    grid-column: 2; grid-row: 1 / span 2;
    align-self: center;
    padding-left: 14px;
    border-left: 1px solid rgba(31, 140, 70, 0.22);
}
.aif-ae-canvas__hero-side {
    font-size: 10.5px;
    font-weight: 700;
    color: rgba(26, 26, 26, 0.6);
    grid-column: 1; grid-row: 2;
}

/* Card 3 — Patient tablet */
.aif-ae-tablet {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 14px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 10px;
    flex: 1;
    align-items: center;
}
.aif-ae-tablet__device {
    width: 100%;
    max-width: 220px;
    aspect-ratio: 4 / 5;
    background: #0f172a;
    border-radius: 18px;
    padding: 8px;
    box-shadow: 0 12px 28px -16px rgba(15, 23, 42, 0.45);
}
.aif-ae-tablet__screen {
    width: 100%; height: 100%;
    background: linear-gradient(180deg, #fff 0%, #fafaf8 100%);
    border-radius: 12px;
    padding: 10px;
    display: flex; flex-direction: column; gap: 8px;
}
.aif-ae-tablet__title {
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--aif-muted);
    text-align: center;
}
.aif-ae-tablet__compare {
    flex: 1;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4px;
}
.aif-ae-tablet__pane {
    border-radius: 7px;
    display: flex; align-items: center; justify-content: center;
    font-size: 22px;
    font-weight: 800;
    color: rgba(15, 23, 42, 0.4);
    background: rgba(15, 23, 42, 0.06);
}
.aif-ae-tablet__pane--a {
    background: linear-gradient(135deg, rgba(31, 140, 70, 0.12) 0%, rgba(110, 231, 168, 0.22) 100%);
    color: #1f8c46;
}
.aif-ae-tablet__opts {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3px;
}
.aif-ae-tablet__opt {
    text-align: center;
    padding: 4px 0;
    font-size: 9px;
    font-weight: 700;
    color: var(--aif-muted);
    background: rgba(15, 23, 42, 0.04);
    border-radius: 5px;
    border: 1px solid transparent;
}
.aif-ae-tablet__opt--active {
    background: color-mix(in srgb, var(--aif-accent) 12%, white);
    border-color: color-mix(in srgb, var(--aif-accent) 35%, transparent);
    color: var(--aif-accent);
}
.aif-ae-tablet__cta {
    background: #0a0a0a;
    color: #fff;
    text-align: center;
    padding: 6px;
    border-radius: 5px;
    font-size: 9.5px;
    font-weight: 800;
    letter-spacing: 0.02em;
}
.aif-ae-tablet__pill {
    margin-top: auto;
    padding: 8px 12px;
    background: rgba(15, 23, 42, 0.025);
    border: 1px dashed rgba(15, 23, 42, 0.12);
    border-radius: 999px;
    text-align: center;
    font-size: 10px;
    font-weight: 700;
    color: var(--aif-muted);
}

/* Card 4 — Close rate analytics */
.aif-ae-rate {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 8px;
    flex: 1;
}
.aif-ae-rate__row {
    display: grid;
    grid-template-columns: 1fr 38px;
    grid-template-rows: auto auto;
    align-items: center;
    column-gap: 10px;
    row-gap: 4px;
    padding: 6px 0;
}
.aif-ae-rate__name {
    font-size: 11px;
    font-weight: 700;
    color: var(--aif-ink);
    grid-column: 1; grid-row: 1;
}
.aif-ae-rate__pct {
    font-size: 12px;
    font-weight: 800;
    text-align: right;
    font-family: ui-monospace, SFMono-Regular, monospace;
    grid-column: 2; grid-row: 1 / span 2;
    align-self: center;
}
.aif-ae-rate__bar {
    height: 8px;
    background: rgba(15, 23, 42, 0.06);
    border-radius: 999px;
    overflow: hidden;
    grid-column: 1; grid-row: 2;
}
.aif-ae-rate__fill {
    display: block;
    height: 100%;
    width: var(--w);
    border-radius: 999px;
    transition: width 1s cubic-bezier(.2,.8,.2,1);
}
.aif-ae-rate__fill--low { background: rgba(220, 38, 38, 0.55); }
.aif-ae-rate__fill--mid { background: rgba(245, 158, 11, 0.7); }
.aif-ae-rate__fill--hi  { background: linear-gradient(90deg, color-mix(in srgb, #1f8c46 60%, white) 0%, #1f8c46 100%); }
.aif-ae-rate__delta {
    margin-top: auto;
    padding: 12px 14px;
    background: linear-gradient(135deg, rgba(31, 140, 70, 0.06) 0%, rgba(110, 231, 168, 0.12) 100%);
    border: 1px solid rgba(31, 140, 70, 0.22);
    border-radius: 12px;
    display: flex; align-items: baseline; justify-content: space-between;
}
.aif-ae-rate__delta-label {
    font-size: 10.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: rgba(26, 26, 26, 0.55);
}
.aif-ae-rate__delta-val {
    font-size: 26px;
    font-weight: 800;
    color: #1f8c46;
    letter-spacing: -0.02em;
    font-family: ui-monospace, SFMono-Regular, monospace;
}

/* Card 5 — Procedure menu */
.aif-ae-menu {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 6px;
    flex: 1;
}
.aif-ae-menu__item {
    display: grid;
    grid-template-columns: 32px 1fr auto;
    align-items: center;
    gap: 10px;
    padding: 9px 12px;
    border-radius: 10px;
    background: rgba(15, 23, 42, 0.025);
    border: 1px solid rgba(15, 23, 42, 0.05);
}
.aif-ae-menu__icon {
    width: 32px; height: 32px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 8px;
    background: color-mix(in srgb, var(--aif-accent) 10%, white);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 22%, transparent);
    font-size: 16px;
    line-height: 1;
}
.aif-ae-menu__body {
    display: flex; flex-direction: column; gap: 1px;
    min-width: 0;
}
.aif-ae-menu__name {
    font-size: 11.5px;
    font-weight: 700;
    color: var(--aif-ink);
}
.aif-ae-menu__sub {
    font-size: 10px;
    color: var(--aif-muted);
    font-weight: 500;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.aif-ae-menu__check {
    width: 22px; height: 22px;
    display: flex; align-items: center; justify-content: center;
    background: rgba(31, 140, 70, 0.12);
    color: #1f8c46;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 800;
}
.aif-ae-menu__item--more {
    background: linear-gradient(135deg, color-mix(in srgb, var(--aif-accent) 5%, white) 0%, color-mix(in srgb, var(--aif-accent) 12%, white) 100%);
    border: 1px dashed color-mix(in srgb, var(--aif-accent) 30%, transparent);
    grid-template-columns: 32px 1fr;
}
.aif-ae-menu__item--more .aif-ae-menu__icon {
    background: #fff;
    color: var(--aif-accent);
    font-size: 18px;
    font-weight: 800;
}
.aif-ae-menu__item--more .aif-ae-menu__name { color: var(--aif-accent); }

/* Card 6 — Provider review queue */
.aif-ae-review {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 6px;
    flex: 1;
}
.aif-ae-review__head {
    display: flex; align-items: center; justify-content: space-between;
    padding: 0 4px 6px;
    border-bottom: 1px dashed var(--aif-line);
}
.aif-ae-review__title {
    font-size: 10.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--aif-ink);
}
.aif-ae-review__meta {
    font-size: 10px;
    font-weight: 600;
    color: var(--aif-muted);
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-ae-review__row {
    display: grid;
    grid-template-columns: 32px 1fr auto;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    border-radius: 8px;
    background: rgba(15, 23, 42, 0.025);
    border: 1px solid rgba(15, 23, 42, 0.05);
}
.aif-ae-review__row--ok {
    background: rgba(31, 140, 70, 0.06);
    border-color: rgba(31, 140, 70, 0.22);
}
.aif-ae-review__avatar {
    width: 32px; height: 32px;
    border-radius: 999px;
    background: var(--av, #f5b1cf);
    display: flex; align-items: center; justify-content: center;
    font-size: 11px;
    font-weight: 800;
    color: rgba(15, 23, 42, 0.78);
    letter-spacing: 0.04em;
}
.aif-ae-review__body {
    display: flex; flex-direction: column; gap: 1px;
    min-width: 0;
}
.aif-ae-review__name {
    font-size: 11.5px;
    font-weight: 700;
    color: var(--aif-ink);
}
.aif-ae-review__sub {
    font-size: 10px;
    color: var(--aif-muted);
    font-weight: 500;
}
.aif-ae-review__action {
    font-size: 9.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 5px 11px;
    border-radius: 999px;
    background: #fff;
    color: var(--aif-ink);
    border: 1px solid rgba(15, 23, 42, 0.1);
    white-space: nowrap;
}
.aif-ae-review__action--ok {
    background: rgba(31, 140, 70, 0.12);
    color: #1f8c46;
    border: 1px solid rgba(31, 140, 70, 0.3);
}
.aif-ae-review__action--edit {
    background: rgba(245, 158, 11, 0.1);
    color: #b45309;
    border: 1px solid rgba(245, 158, 11, 0.3);
}
.aif-ae-review__pill {
    margin-top: auto;
    padding: 8px 12px;
    background: rgba(15, 23, 42, 0.025);
    border: 1px dashed rgba(15, 23, 42, 0.12);
    border-radius: 999px;
    text-align: center;
    font-size: 10.5px;
    font-weight: 700;
    color: var(--aif-muted);
}

/* Card 7 — Privacy / facial-data */
.aif-ae-priv {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 6px;
    flex: 1;
}
.aif-ae-priv__row {
    display: grid;
    grid-template-columns: 24px 1fr;
    align-items: center;
    gap: 10px;
    padding: 9px 12px;
    border-radius: 10px;
    background: rgba(31, 140, 70, 0.05);
    border: 1px solid rgba(31, 140, 70, 0.18);
}
.aif-ae-priv__icon {
    width: 24px; height: 24px;
    display: flex; align-items: center; justify-content: center;
    background: rgba(31, 140, 70, 0.12);
    color: #1f8c46;
    border-radius: 999px;
    font-weight: 700;
    font-size: 13px;
}
.aif-ae-priv__body { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.aif-ae-priv__title {
    font-size: 11.5px;
    font-weight: 700;
    color: var(--aif-ink);
}
.aif-ae-priv__sub {
    font-size: 10px;
    color: var(--aif-muted);
    font-weight: 500;
}
.aif-ae-priv__pill {
    margin-top: auto;
    padding: 10px 12px;
    background: linear-gradient(135deg, rgba(31, 140, 70, 0.06) 0%, rgba(110, 231, 168, 0.12) 100%);
    border: 1px solid rgba(31, 140, 70, 0.22);
    border-radius: 10px;
    display: flex; align-items: center; gap: 8px;
    font-size: 10.5px;
    font-weight: 700;
    color: #1f8c46;
}
.aif-ae-priv__pill-dot {
    width: 7px; height: 7px;
    border-radius: 999px;
    background: #1f8c46;
    box-shadow: 0 0 0 3px rgba(31, 140, 70, 0.18);
    animation: aif-pulse 1.4s ease-in-out infinite;
}

/* ─────────────────────────────────────────────────────────
   AI Scribe — bespoke visuals
   ───────────────────────────────────────────────────────── */

/* Card 1 — Patient Realm dashboard */
.aif-sc-dash {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 6px;
    flex: 1;
}
.aif-sc-dash__head {
    display: flex; align-items: center; justify-content: space-between;
    padding: 0 4px 8px;
    border-bottom: 1px dashed var(--aif-line);
}
.aif-sc-dash__title {
    font-size: 10.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--aif-ink);
}
.aif-sc-dash__meta {
    font-size: 10px;
    font-weight: 600;
    color: var(--aif-muted);
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-sc-dash__row {
    display: grid;
    grid-template-columns: 28px 1fr auto;
    align-items: center;
    gap: 10px;
    padding: 6px 4px;
    border-radius: 8px;
    transition: background 0.2s ease;
}
.aif-sc-dash__row:hover { background: rgba(15, 23, 42, 0.025); }
.aif-sc-dash__avatar {
    width: 28px; height: 28px;
    border-radius: 999px;
    background: var(--av, #f5b1cf);
    display: flex; align-items: center; justify-content: center;
    font-size: 10px;
    font-weight: 800;
    color: rgba(15, 23, 42, 0.78);
    letter-spacing: 0.04em;
}
.aif-sc-dash__name {
    font-size: 12px;
    font-weight: 700;
    color: var(--aif-ink);
}
.aif-sc-dash__counts {
    display: flex; gap: 5px;
    flex-wrap: wrap;
    justify-content: flex-end;
}
.aif-sc-dash__pill {
    font-size: 9.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 3px 8px;
    border-radius: 999px;
    font-family: ui-monospace, SFMono-Regular, monospace;
    white-space: nowrap;
}
.aif-sc-dash__pill--ok      { background: rgba(31, 140, 70, 0.12); color: #1f8c46; border: 1px solid rgba(31, 140, 70, 0.25); }
.aif-sc-dash__pill--zero    { background: rgba(15, 23, 42, 0.05); color: var(--aif-muted); border: 1px solid rgba(15, 23, 42, 0.06); }
.aif-sc-dash__pill--pending { background: rgba(245, 158, 11, 0.12); color: #b45309; border: 1px solid rgba(245, 158, 11, 0.3); }
.aif-sc-dash__pill--flag    { background: rgba(220, 38, 38, 0.1); color: #b91c1c; border: 1px solid rgba(220, 38, 38, 0.25); }
.aif-sc-dash__hero {
    margin-top: auto;
    padding: 12px 14px;
    background: linear-gradient(135deg, rgba(31, 140, 70, 0.06) 0%, rgba(110, 231, 168, 0.12) 100%);
    border: 1px solid rgba(31, 140, 70, 0.22);
    border-radius: 12px;
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    column-gap: 12px;
}
.aif-sc-dash__hero-label {
    font-size: 10.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: rgba(26, 26, 26, 0.55);
    grid-column: 1; grid-row: 1;
    align-self: end;
}
.aif-sc-dash__hero-amount {
    font-size: 26px;
    font-weight: 800;
    color: #1f8c46;
    letter-spacing: -0.02em;
    line-height: 1;
    font-family: ui-monospace, SFMono-Regular, monospace;
    grid-column: 1; grid-row: 2;
    align-self: start;
}
.aif-sc-dash__hero-side {
    grid-column: 2; grid-row: 1 / span 2;
    align-self: center;
    padding-left: 14px;
    border-left: 1px solid rgba(31, 140, 70, 0.22);
    font-size: 10.5px;
    font-weight: 700;
    color: rgba(26, 26, 26, 0.55);
    text-align: right;
    max-width: 100px;
    line-height: 1.3;
}

/* Card 2 — Devices (capture anywhere) */
.aif-sc-dev {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 14px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 10px;
    flex: 1;
}
.aif-sc-dev__row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}
.aif-sc-dev__device {
    padding: 12px 10px;
    border-radius: 10px;
    background: rgba(15, 23, 42, 0.025);
    border: 1px solid rgba(15, 23, 42, 0.06);
    display: flex; flex-direction: column; align-items: center; gap: 6px;
    transition: transform 0.2s ease, background 0.2s ease;
}
.aif-sc-dev__device:hover {
    transform: translateY(-1px);
    background: color-mix(in srgb, var(--aif-accent) 5%, white);
}
.aif-sc-dev__icon {
    width: 32px; height: 32px;
    display: flex; align-items: center; justify-content: center;
    color: var(--aif-accent);
}
.aif-sc-dev__icon svg { width: 100%; height: 100%; }
.aif-sc-dev__name {
    font-size: 11.5px;
    font-weight: 700;
    color: var(--aif-ink);
}
.aif-sc-dev__meta {
    font-size: 9.5px;
    color: var(--aif-muted);
    font-weight: 500;
    text-align: center;
    line-height: 1.2;
}
.aif-sc-dev__flow {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 12px;
}
.aif-sc-dev__wave {
    display: flex; align-items: center;
    gap: 2px;
    height: 28px;
    padding: 0 4px;
}
.aif-sc-dev__wave > span {
    flex: 1;
    background: linear-gradient(180deg, color-mix(in srgb, var(--aif-accent) 60%, white) 0%, var(--aif-accent) 100%);
    border-radius: 2px;
    height: 30%;
    min-width: 3px;
    transform-origin: center;
}
.aif-ns-anim.is-in .aif-sc-dev__wave > span {
    animation: aif-sc-dev-wave 1.4s ease-in-out infinite;
}
.aif-ns-anim.is-in .aif-sc-dev__wave > span:nth-child(1)  { animation-delay: 0.00s; }
.aif-ns-anim.is-in .aif-sc-dev__wave > span:nth-child(2)  { animation-delay: 0.07s; }
.aif-ns-anim.is-in .aif-sc-dev__wave > span:nth-child(3)  { animation-delay: 0.14s; }
.aif-ns-anim.is-in .aif-sc-dev__wave > span:nth-child(4)  { animation-delay: 0.21s; }
.aif-ns-anim.is-in .aif-sc-dev__wave > span:nth-child(5)  { animation-delay: 0.28s; }
.aif-ns-anim.is-in .aif-sc-dev__wave > span:nth-child(6)  { animation-delay: 0.35s; }
.aif-ns-anim.is-in .aif-sc-dev__wave > span:nth-child(7)  { animation-delay: 0.42s; }
.aif-ns-anim.is-in .aif-sc-dev__wave > span:nth-child(8)  { animation-delay: 0.49s; }
.aif-ns-anim.is-in .aif-sc-dev__wave > span:nth-child(9)  { animation-delay: 0.56s; }
.aif-ns-anim.is-in .aif-sc-dev__wave > span:nth-child(10) { animation-delay: 0.63s; }
.aif-ns-anim.is-in .aif-sc-dev__wave > span:nth-child(11) { animation-delay: 0.70s; }
.aif-ns-anim.is-in .aif-sc-dev__wave > span:nth-child(12) { animation-delay: 0.77s; }
.aif-ns-anim.is-in .aif-sc-dev__wave > span:nth-child(13) { animation-delay: 0.84s; }
.aif-ns-anim.is-in .aif-sc-dev__wave > span:nth-child(14) { animation-delay: 0.91s; }
.aif-ns-anim.is-in .aif-sc-dev__wave > span:nth-child(15) { animation-delay: 0.98s; }
@keyframes aif-sc-dev-wave {
    0%, 100% { height: 22%; }
    25%      { height: 70%; }
    50%      { height: 38%; }
    75%      { height: 90%; }
}
.aif-sc-dev__hub {
    padding: 8px 14px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--aif-accent) 0%, color-mix(in srgb, var(--aif-accent) 70%, #1f8c46) 100%);
    color: #fff;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.18em;
    box-shadow: 0 6px 14px -6px color-mix(in srgb, var(--aif-accent) 60%, transparent);
}
.aif-sc-dev__output {
    display: grid;
    grid-template-columns: 28px 1fr auto;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 10px;
    background: rgba(31, 140, 70, 0.06);
    border: 1px solid rgba(31, 140, 70, 0.22);
}
.aif-sc-dev__output-icon {
    width: 28px; height: 28px;
    display: flex; align-items: center; justify-content: center;
    color: #1f8c46;
}
.aif-sc-dev__output-icon svg { width: 100%; height: 100%; }
.aif-sc-dev__output-body {
    display: flex; flex-direction: column; gap: 1px;
}
.aif-sc-dev__output-name {
    font-size: 12px;
    font-weight: 700;
    color: #1f8c46;
}
.aif-sc-dev__output-meta {
    font-size: 10px;
    color: rgba(31, 140, 70, 0.7);
    font-weight: 500;
}
.aif-sc-dev__output-status {
    font-size: 16px;
    font-weight: 800;
    color: #1f8c46;
    width: 26px; height: 26px;
    display: flex; align-items: center; justify-content: center;
    background: rgba(31, 140, 70, 0.18);
    border-radius: 999px;
}
.aif-sc-dev__pill {
    margin-top: auto;
    padding: 8px 12px;
    background: rgba(15, 23, 42, 0.025);
    border: 1px dashed rgba(15, 23, 42, 0.12);
    border-radius: 999px;
    text-align: center;
    font-size: 11px;
    font-weight: 700;
    color: var(--aif-muted);
}

/* Card 3 — Accent + ESL support */
.aif-sc-accent {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 8px;
    flex: 1;
}
.aif-sc-accent__row {
    display: grid;
    grid-template-columns: 22px 90px 1fr 38px;
    align-items: center;
    gap: 8px;
    padding: 4px 0;
}
.aif-sc-accent__flag {
    font-size: 16px;
    line-height: 1;
}
.aif-sc-accent__name {
    font-size: 11px;
    font-weight: 700;
    color: var(--aif-ink);
}
.aif-sc-accent__bar {
    height: 6px;
    background: rgba(15, 23, 42, 0.06);
    border-radius: 999px;
    overflow: hidden;
}
.aif-sc-accent__fill {
    display: block;
    height: 100%;
    width: var(--w);
    background: linear-gradient(90deg, color-mix(in srgb, #1f8c46 60%, white) 0%, #1f8c46 100%);
    border-radius: 999px;
    transition: width 1.0s cubic-bezier(.2,.8,.2,1);
}
.aif-sc-accent__pct {
    font-size: 10.5px;
    font-weight: 800;
    color: #1f8c46;
    font-family: ui-monospace, SFMono-Regular, monospace;
    text-align: right;
    letter-spacing: 0.02em;
}
.aif-sc-accent__more {
    margin-top: auto;
    padding: 8px 12px;
    background: linear-gradient(135deg, color-mix(in srgb, var(--aif-accent) 5%, white) 0%, color-mix(in srgb, var(--aif-accent) 12%, white) 100%);
    border: 1px dashed color-mix(in srgb, var(--aif-accent) 30%, transparent);
    border-radius: 999px;
    text-align: center;
    font-size: 10.5px;
    font-weight: 700;
    color: var(--aif-accent);
}

/* Card 1 (legacy) — Live capture / transcription */
.aif-sc-listen {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 14px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 12px;
    flex: 1;
}
.aif-sc-listen__head {
    display: flex; align-items: center; gap: 10px;
    padding-bottom: 10px;
    border-bottom: 1px dashed var(--aif-line);
}
.aif-sc-listen__rec {
    width: 10px; height: 10px;
    border-radius: 999px;
    background: #dc2626;
    box-shadow: 0 0 0 4px rgba(220, 38, 38, 0.18);
    animation: aif-pulse 1.4s ease-in-out infinite;
}
.aif-sc-listen__title {
    font-size: 11px;
    font-weight: 800;
    color: var(--aif-ink);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.aif-sc-listen__time {
    margin-left: auto;
    font-size: 11px;
    font-weight: 700;
    color: var(--aif-muted);
    font-family: ui-monospace, SFMono-Regular, monospace;
    letter-spacing: 0.02em;
}
.aif-sc-listen__wave {
    display: flex; align-items: end; justify-content: space-between;
    gap: 3px;
    height: 32px;
    padding: 0 4px;
}
.aif-sc-listen__bar {
    flex: 1;
    background: linear-gradient(180deg, color-mix(in srgb, var(--aif-accent) 70%, white) 0%, var(--aif-accent) 100%);
    border-radius: 2px;
    height: 30%;
    animation: aif-sc-wave 1.4s ease-in-out infinite;
}
.aif-sc-listen__bar:nth-child(2n)  { animation-delay: 0.1s; }
.aif-sc-listen__bar:nth-child(3n)  { animation-delay: 0.2s; }
.aif-sc-listen__bar:nth-child(4n)  { animation-delay: 0.3s; }
.aif-sc-listen__bar:nth-child(5n)  { animation-delay: 0.4s; }
.aif-sc-listen__bar:nth-child(7n)  { animation-delay: 0.5s; }
@keyframes aif-sc-wave {
    0%, 100% { height: 25%; }
    20%      { height: 75%; }
    40%      { height: 45%; }
    60%      { height: 90%; }
    80%      { height: 35%; }
}
.aif-sc-listen__transcript {
    display: flex; flex-direction: column; gap: 6px;
}
.aif-sc-listen__line {
    display: grid;
    grid-template-columns: 64px 1fr;
    align-items: start;
    gap: 8px;
    padding: 6px 8px;
    border-radius: 8px;
    background: rgba(15, 23, 42, 0.025);
    border-left: 2px solid transparent;
}
.aif-sc-listen__line--patient { border-left-color: color-mix(in srgb, var(--aif-accent) 60%, transparent); }
.aif-sc-listen__line--provider { border-left-color: #1f8c46; background: rgba(31, 140, 70, 0.05); }
.aif-sc-listen__who {
    font-size: 9.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--aif-muted);
    padding-top: 1px;
}
.aif-sc-listen__line--provider .aif-sc-listen__who { color: #1f8c46; }
.aif-sc-listen__line--patient .aif-sc-listen__who { color: var(--aif-accent); }
.aif-sc-listen__what {
    font-size: 11.5px;
    color: var(--aif-ink);
    line-height: 1.35;
    font-style: italic;
}
.aif-sc-listen__hero {
    margin-top: auto;
    padding: 12px 14px;
    background: linear-gradient(135deg, rgba(31, 140, 70, 0.06) 0%, rgba(110, 231, 168, 0.12) 100%);
    border: 1px solid rgba(31, 140, 70, 0.22);
    border-radius: 12px;
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
}
.aif-sc-listen__hero-label {
    font-size: 10.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: rgba(26, 26, 26, 0.55);
    grid-column: 1; grid-row: 1;
    align-self: end;
}
.aif-sc-listen__hero-amount {
    font-size: 28px;
    font-weight: 800;
    color: #1f8c46;
    letter-spacing: -0.02em;
    line-height: 1;
    font-family: ui-monospace, SFMono-Regular, monospace;
    grid-column: 2; grid-row: 1 / span 2;
    align-self: center;
    padding-left: 14px;
    border-left: 1px solid rgba(31, 140, 70, 0.22);
}
.aif-sc-listen__hero-amount small {
    font-size: 14px; font-weight: 700; margin-left: 1px;
}
.aif-sc-listen__hero-sub {
    font-size: 10.5px;
    font-weight: 600;
    color: rgba(26, 26, 26, 0.6);
    grid-column: 1; grid-row: 2;
}

/* Card 2 — SOAP note */
.aif-sc-soap {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 14px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 8px;
    flex: 1;
}
.aif-sc-soap__head {
    display: flex; align-items: baseline; justify-content: space-between;
    padding: 0 4px 8px;
    border-bottom: 1px dashed var(--aif-line);
}
.aif-sc-soap__hd-title {
    font-size: 10.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--aif-ink);
}
.aif-sc-soap__hd-meta {
    font-size: 10px;
    font-weight: 600;
    color: var(--aif-muted);
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-sc-soap__section {
    display: grid;
    grid-template-columns: 28px 1fr auto;
    align-items: start;
    gap: 10px;
    padding: 6px 4px;
}
.aif-sc-soap__letter {
    width: 28px; height: 28px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 8px;
    background: color-mix(in srgb, var(--aif-accent) 12%, white);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 30%, transparent);
    color: var(--aif-accent);
    font-weight: 800;
    font-size: 14px;
    line-height: 1;
}
.aif-sc-soap__body {
    display: flex; flex-direction: column; gap: 1px;
    min-width: 0;
}
.aif-sc-soap__sname {
    font-size: 9.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--aif-muted);
}
.aif-sc-soap__text {
    font-size: 11.5px;
    color: var(--aif-ink);
    font-weight: 500;
    line-height: 1.35;
}
.aif-sc-soap__cite {
    font-size: 9.5px;
    font-weight: 700;
    color: var(--aif-muted);
    font-family: ui-monospace, SFMono-Regular, monospace;
    padding-top: 4px;
    letter-spacing: 0.02em;
}
.aif-sc-soap__sign {
    margin-top: auto;
    padding: 12px 14px;
    background: linear-gradient(135deg, rgba(31, 140, 70, 0.06) 0%, rgba(110, 231, 168, 0.12) 100%);
    border: 1px solid rgba(31, 140, 70, 0.22);
    border-radius: 12px;
    display: flex; align-items: center; justify-content: space-between;
}
.aif-sc-soap__sign-status {
    font-size: 10.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: rgba(26, 26, 26, 0.55);
}
.aif-sc-soap__sign-action {
    font-size: 12px;
    font-weight: 700;
    color: #1f8c46;
    font-family: ui-monospace, SFMono-Regular, monospace;
}

/* Card 3 — ICD-10 + CPT codes */
.aif-sc-codes {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 6px;
    flex: 1;
}
.aif-sc-codes__row {
    display: grid;
    grid-template-columns: 50px 70px 1fr 50px;
    align-items: center;
    gap: 8px;
    padding: 9px 10px;
    border-radius: 8px;
    background: rgba(15, 23, 42, 0.025);
    border: 1px solid rgba(15, 23, 42, 0.05);
}
.aif-sc-codes__type {
    font-size: 9px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--aif-muted);
    font-family: ui-monospace, SFMono-Regular, monospace;
    text-align: center;
    background: rgba(15, 23, 42, 0.06);
    padding: 3px 4px;
    border-radius: 4px;
}
.aif-sc-codes__code {
    font-size: 12px;
    font-weight: 800;
    color: var(--aif-ink);
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-sc-codes__desc {
    font-size: 10.5px;
    color: var(--aif-muted);
    font-weight: 500;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.aif-sc-codes__conf {
    font-size: 10px;
    font-weight: 800;
    text-align: center;
    padding: 3px 5px;
    border-radius: 4px;
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-sc-codes__conf--hi  { background: rgba(31, 140, 70, 0.12); color: #1f8c46; }
.aif-sc-codes__conf--mid { background: rgba(245, 158, 11, 0.12); color: #b45309; }
.aif-sc-codes__cite {
    margin-top: auto;
    padding: 9px 10px;
    border-radius: 8px;
    background: rgba(15, 23, 42, 0.025);
    border: 1px dashed rgba(15, 23, 42, 0.1);
    font-size: 10.5px;
    color: var(--aif-muted);
    font-style: italic;
}
.aif-sc-codes__cite em { color: var(--aif-ink); font-style: normal; font-weight: 600; }

/* Card 4 — Speaker diarization */
.aif-sc-dia {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 14px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 12px;
    flex: 1;
    justify-content: center;
}
.aif-sc-dia__legend {
    display: flex; gap: 12px; flex-wrap: wrap;
    font-size: 10.5px;
    font-weight: 700;
    color: var(--aif-muted);
}
.aif-sc-dia__sw {
    display: inline-block;
    width: 9px; height: 9px;
    border-radius: 3px;
    margin-right: 4px;
    vertical-align: -1px;
}
.aif-sc-dia__sw--dr { background: #1f8c46; }
.aif-sc-dia__sw--pt { background: var(--aif-accent); }
.aif-sc-dia__sw--fm { background: #f59e0b; }
.aif-sc-dia__bar {
    display: flex;
    height: 14px;
    border-radius: 999px;
    overflow: hidden;
    border: 1px solid rgba(15, 23, 42, 0.06);
}
.aif-sc-dia__seg {
    height: 100%;
    width: var(--w);
    transition: width 1s ease;
}
.aif-sc-dia__seg--dr { background: #1f8c46; }
.aif-sc-dia__seg--pt { background: var(--aif-accent); }
.aif-sc-dia__seg--fm { background: #f59e0b; }
.aif-sc-dia__stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}
.aif-sc-dia__stat {
    padding: 8px 10px;
    border-radius: 8px;
    background: rgba(15, 23, 42, 0.025);
    border: 1px solid rgba(15, 23, 42, 0.05);
    display: flex; flex-direction: column; gap: 2px;
    text-align: center;
}
.aif-sc-dia__stat-label {
    font-size: 9.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--aif-muted);
}
.aif-sc-dia__stat-val {
    font-size: 18px;
    font-weight: 800;
    line-height: 1;
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-sc-dia__stat-val--dr { color: #1f8c46; }
.aif-sc-dia__stat-val--pt { color: var(--aif-accent); }
.aif-sc-dia__stat-val--fm { color: #f59e0b; }

/* Card 5 — Time saved per visit */
.aif-sc-time {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 14px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 10px;
    flex: 1;
}
.aif-sc-time__row {
    display: grid;
    grid-template-columns: 110px 1fr 50px;
    align-items: center;
    gap: 10px;
}
.aif-sc-time__label {
    font-size: 11px;
    font-weight: 700;
    color: var(--aif-ink);
}
.aif-sc-time__track {
    height: 16px;
    background: rgba(15, 23, 42, 0.06);
    border-radius: 4px;
    overflow: hidden;
}
.aif-sc-time__fill {
    display: block;
    height: 100%;
    width: var(--w);
    border-radius: 4px;
    transition: width 1.1s cubic-bezier(.2,.8,.2,1);
}
.aif-sc-time__fill--manual { background: rgba(220, 38, 38, 0.55); }
.aif-sc-time__fill--agent  { background: linear-gradient(90deg, color-mix(in srgb, #1f8c46 60%, white) 0%, #1f8c46 100%); }
.aif-sc-time__val {
    font-size: 11px;
    font-weight: 800;
    color: var(--aif-muted);
    font-family: ui-monospace, SFMono-Regular, monospace;
    text-align: right;
}
.aif-sc-time__val--good { color: #1f8c46; }
.aif-sc-time__hero {
    margin-top: auto;
    padding: 12px 14px;
    background: linear-gradient(135deg, rgba(31, 140, 70, 0.06) 0%, rgba(110, 231, 168, 0.12) 100%);
    border: 1px solid rgba(31, 140, 70, 0.22);
    border-radius: 12px;
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    column-gap: 12px;
}
.aif-sc-time__hero-label {
    font-size: 9.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: rgba(26, 26, 26, 0.55);
    grid-column: 1; grid-row: 1;
    align-self: end;
}
.aif-sc-time__hero-amount {
    font-size: 26px;
    font-weight: 800;
    color: #1f8c46;
    letter-spacing: -0.02em;
    line-height: 1;
    font-family: ui-monospace, SFMono-Regular, monospace;
    grid-column: 2; grid-row: 1 / span 2;
    align-self: center;
    padding-left: 12px;
    border-left: 1px solid rgba(31, 140, 70, 0.22);
}
.aif-sc-time__hero-amount small { font-size: 12px; font-weight: 700; margin-left: 1px; }
.aif-sc-time__hero-extra {
    font-size: 10.5px;
    font-weight: 600;
    color: rgba(26, 26, 26, 0.65);
    grid-column: 1; grid-row: 2;
}
.aif-sc-time__hero-extra strong { color: #1f8c46; font-weight: 800; }

/* Card 6 — EHR record */
.aif-sc-ehr {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 0;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column;
    flex: 1;
    overflow: hidden;
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-sc-ehr__head {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%);
    border-bottom: 1px solid rgba(15, 23, 42, 0.08);
}
.aif-sc-ehr__hd-app {
    font-size: 10px;
    font-weight: 800;
    color: #fff;
    background: #1d4ed8;
    padding: 3px 7px;
    border-radius: 4px;
    letter-spacing: 0.06em;
}
.aif-sc-ehr__hd-title {
    font-size: 11px;
    color: rgba(15, 23, 42, 0.7);
    font-weight: 600;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.aif-sc-ehr__hd-status {
    font-size: 9.5px;
    font-weight: 800;
    background: rgba(31, 140, 70, 0.12);
    color: #1f8c46;
    padding: 3px 8px;
    border-radius: 999px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}
.aif-sc-ehr__field {
    display: grid;
    grid-template-columns: 130px 1fr;
    gap: 12px;
    align-items: center;
    padding: 7px 14px;
    font-size: 11px;
    border-bottom: 1px dashed rgba(15, 23, 42, 0.05);
}
.aif-sc-ehr__field-label {
    color: rgba(15, 23, 42, 0.5);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    font-size: 9.5px;
}
.aif-sc-ehr__field-value {
    color: var(--aif-ink);
    font-weight: 600;
}
.aif-sc-ehr__field-value--code { color: #1d4ed8; font-weight: 700; }
.aif-sc-ehr__pill {
    margin: auto 14px 14px;
    padding: 8px 12px;
    background: rgba(31, 140, 70, 0.08);
    border: 1px solid rgba(31, 140, 70, 0.22);
    border-radius: 8px;
    display: flex; align-items: center; gap: 8px;
    font-size: 10.5px;
    font-weight: 700;
    color: #1f8c46;
    font-family: -apple-system, BlinkMacSystemFont, sans-serif;
    letter-spacing: 0.02em;
}
.aif-sc-ehr__pill-dot {
    width: 7px; height: 7px;
    border-radius: 999px;
    background: #1f8c46;
    box-shadow: 0 0 0 3px rgba(31, 140, 70, 0.18);
    animation: aif-pulse 1.4s ease-in-out infinite;
}

/* Card 7 — Privacy / consent */
.aif-sc-priv {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 8px;
    flex: 1;
}
.aif-sc-priv__step {
    display: grid;
    grid-template-columns: 24px 1fr;
    align-items: center;
    gap: 10px;
    padding: 9px 12px;
    border-radius: 10px;
    background: rgba(15, 23, 42, 0.025);
    border: 1px solid rgba(15, 23, 42, 0.05);
    transition: background 0.2s ease;
}
.aif-sc-priv__step--ok {
    background: rgba(31, 140, 70, 0.05);
    border-color: rgba(31, 140, 70, 0.18);
}
.aif-sc-priv__icon {
    width: 24px; height: 24px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 999px;
    background: rgba(31, 140, 70, 0.12);
    color: #1f8c46;
    font-size: 13px;
    font-weight: 700;
    line-height: 1;
}
.aif-sc-priv__body {
    display: flex; flex-direction: column; gap: 1px;
    min-width: 0;
}
.aif-sc-priv__title {
    font-size: 11.5px;
    font-weight: 700;
    color: var(--aif-ink);
}
.aif-sc-priv__sub {
    font-size: 10px;
    color: var(--aif-muted);
    font-weight: 500;
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-sc-priv__pill {
    margin-top: auto;
    padding: 10px 12px;
    background: linear-gradient(135deg, rgba(31, 140, 70, 0.06) 0%, rgba(110, 231, 168, 0.12) 100%);
    border: 1px solid rgba(31, 140, 70, 0.22);
    border-radius: 10px;
    display: flex; align-items: center; gap: 8px;
    font-size: 10.5px;
    font-weight: 700;
    color: #1f8c46;
    letter-spacing: 0.02em;
}
.aif-sc-priv__pill-dot {
    width: 7px; height: 7px;
    border-radius: 999px;
    background: #1f8c46;
    box-shadow: 0 0 0 3px rgba(31, 140, 70, 0.18);
    animation: aif-pulse 1.4s ease-in-out infinite;
}

/* ─────────────────────────────────────────────────────────
   AI Workflow Automation — bespoke visuals
   ───────────────────────────────────────────────────────── */

/* Card 1 — Dry-run sandbox preview */
.aif-wf-dry {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 14px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 12px;
    flex: 1;
}
.aif-wf-dry__head {
    display: flex; align-items: center; gap: 6px;
    padding: 0 2px 10px;
    border-bottom: 1px solid var(--aif-line);
}
.aif-wf-dry__tab {
    padding: 5px 11px;
    border-radius: 999px;
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: var(--aif-muted);
    background: rgba(15, 23, 42, 0.035);
    border: 1px solid transparent;
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-wf-dry__tab--active {
    background: color-mix(in srgb, var(--aif-accent) 10%, white);
    border-color: color-mix(in srgb, var(--aif-accent) 30%, transparent);
    color: var(--aif-accent);
}
.aif-wf-dry__range {
    margin-left: auto;
    font-size: 10px;
    color: var(--aif-muted);
    font-weight: 600;
    letter-spacing: 0.04em;
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-wf-dry__results {
    display: flex; flex-direction: column; gap: 8px;
}
.aif-wf-dry__result {
    display: grid;
    grid-template-columns: 32px 1fr;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 10px;
    background: rgba(15, 23, 42, 0.025);
    border: 1px solid rgba(15, 23, 42, 0.05);
}
.aif-wf-dry__result-icon {
    width: 32px; height: 32px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 8px;
    background: color-mix(in srgb, var(--aif-accent) 10%, white);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 22%, transparent);
    color: var(--aif-accent);
    font-size: 15px;
    font-weight: 800;
    line-height: 1;
}
.aif-wf-dry__result-body {
    display: flex; align-items: baseline; gap: 8px;
    min-width: 0;
}
.aif-wf-dry__result-num {
    font-size: 20px;
    font-weight: 800;
    color: var(--aif-ink);
    letter-spacing: -0.02em;
    line-height: 1;
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-wf-dry__result-label {
    font-size: 11.5px;
    color: var(--aif-muted);
    font-weight: 500;
    line-height: 1.3;
}
.aif-wf-dry__hero {
    margin-top: auto;
    padding: 12px 14px;
    background: linear-gradient(135deg, rgba(31, 140, 70, 0.06) 0%, rgba(110, 231, 168, 0.12) 100%);
    border: 1px solid rgba(31, 140, 70, 0.22);
    border-radius: 12px;
    display: flex; align-items: center; justify-content: space-between;
    gap: 12px;
}
.aif-wf-dry__hero-l {
    display: flex; flex-direction: column; gap: 2px;
}
.aif-wf-dry__hero-label {
    font-size: 9.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: rgba(26, 26, 26, 0.55);
}
.aif-wf-dry__hero-amount {
    font-size: 24px;
    font-weight: 800;
    color: #1f8c46;
    letter-spacing: -0.02em;
    line-height: 1;
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-wf-dry__hero-amount--zero { color: #1f8c46; }
.aif-wf-dry__hero-r {
    display: flex; flex-direction: column; gap: 2px;
    align-items: flex-end;
    text-align: right;
}
.aif-wf-dry__hero-cta {
    font-size: 11px;
    font-weight: 700;
    color: #1f8c46;
}
.aif-wf-dry__hero-action {
    font-size: 10px;
    font-weight: 700;
    color: rgba(26, 26, 26, 0.55);
    font-family: ui-monospace, SFMono-Regular, monospace;
    letter-spacing: 0.02em;
}

/* Card 1 (legacy) — Integration network hub (unused) */
.aif-wf-hub {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 10px;
    flex: 1;
    justify-content: center;
}
.aif-wf-hub__row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}
.aif-wf-hub__node {
    padding: 10px;
    border-radius: 10px;
    background: rgba(15, 23, 42, 0.025);
    border: 1px solid rgba(15, 23, 42, 0.06);
    font-size: 11.5px;
    font-weight: 700;
    color: var(--aif-ink);
    text-align: center;
    font-family: ui-monospace, SFMono-Regular, monospace;
    transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}
.aif-wf-hub__node:hover {
    transform: translateY(-1px);
    background: color-mix(in srgb, var(--aif-accent) 6%, white);
    border-color: color-mix(in srgb, var(--aif-accent) 25%, transparent);
}
.aif-wf-hub__center-row {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 12px;
    margin: 4px 0;
}
.aif-wf-hub__center {
    padding: 10px 18px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--aif-accent) 0%, color-mix(in srgb, var(--aif-accent) 70%, #1f8c46) 100%);
    color: #fff;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.18em;
    box-shadow: 0 8px 18px -8px color-mix(in srgb, var(--aif-accent) 60%, transparent);
    text-align: center;
}
.aif-wf-hub__line {
    height: 2px;
    background: repeating-linear-gradient(90deg,
        color-mix(in srgb, var(--aif-accent) 35%, transparent) 0 6px,
        transparent 6px 11px);
    border-radius: 999px;
    position: relative;
    overflow: hidden;
}
.aif-wf-hub__line::after {
    content: "";
    position: absolute;
    top: -3px; left: 0;
    width: 8px; height: 8px;
    border-radius: 999px;
    background: var(--aif-accent);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--aif-accent) 22%, transparent);
    opacity: 0;
}
.aif-ns-anim.is-in .aif-wf-hub__center-row .aif-wf-hub__line:first-child::after {
    animation: aif-wf-hub-flow-l 2.2s ease-in-out infinite;
}
.aif-ns-anim.is-in .aif-wf-hub__center-row .aif-wf-hub__line:last-child::after {
    animation: aif-wf-hub-flow-r 2.2s ease-in-out infinite 0.7s;
}
@keyframes aif-wf-hub-flow-l {
    0%   { left: 0%;   opacity: 0; }
    15%  { opacity: 1; }
    85%  { opacity: 1; }
    100% { left: calc(100% - 8px); opacity: 0; }
}
@keyframes aif-wf-hub-flow-r {
    0%   { left: calc(100% - 8px); opacity: 0; }
    15%  { opacity: 1; }
    85%  { opacity: 1; }
    100% { left: 0%; opacity: 0; }
}
.aif-wf-hub__hero {
    margin-top: auto;
    padding: 12px 14px;
    background: linear-gradient(135deg, rgba(31, 140, 70, 0.06) 0%, rgba(110, 231, 168, 0.12) 100%);
    border: 1px solid rgba(31, 140, 70, 0.22);
    border-radius: 12px;
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    column-gap: 14px;
}
.aif-wf-hub__hero-label {
    font-size: 10.5px;
    font-weight: 700;
    color: rgba(26, 26, 26, 0.55);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    grid-column: 1; grid-row: 1;
    align-self: end;
}
.aif-wf-hub__hero-amount {
    font-size: 26px;
    font-weight: 800;
    color: #1f8c46;
    letter-spacing: -0.02em;
    line-height: 1;
    font-family: ui-monospace, SFMono-Regular, monospace;
    grid-column: 1; grid-row: 2;
    align-self: start;
}
.aif-wf-hub__hero-side {
    display: flex; flex-direction: column; gap: 2px;
    align-items: flex-end;
    grid-column: 2; grid-row: 1 / span 2;
    padding-left: 14px;
    border-left: 1px solid rgba(31, 140, 70, 0.22);
}
.aif-wf-hub__hero-side-label {
    font-size: 9.5px;
    font-weight: 700;
    color: rgba(26, 26, 26, 0.55);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.aif-wf-hub__hero-side-amount {
    font-size: 20px;
    font-weight: 800;
    color: #1f8c46;
    font-family: ui-monospace, SFMono-Regular, monospace;
    line-height: 1;
}

/* Card 2 — Template list (simple, scannable) */
.aif-wf-tpl {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 10px;
    flex: 1;
}
.aif-wf-tpl__list {
    display: flex; flex-direction: column; gap: 6px;
}
.aif-wf-tpl__item {
    display: grid;
    grid-template-columns: 36px 1fr auto;
    align-items: center;
    gap: 12px;
    padding: 9px 12px;
    border-radius: 10px;
    background: rgba(15, 23, 42, 0.025);
    border: 1px solid rgba(15, 23, 42, 0.05);
    transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}
.aif-wf-tpl__item:hover {
    transform: translateY(-1px);
    background: color-mix(in srgb, var(--aif-accent) 5%, white);
    border-color: color-mix(in srgb, var(--aif-accent) 22%, transparent);
}
.aif-wf-tpl__icon {
    width: 36px; height: 36px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 9px;
    background: color-mix(in srgb, var(--aif-accent) 10%, white);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 22%, transparent);
    font-size: 17px;
    line-height: 1;
}
.aif-wf-tpl__body {
    display: flex; flex-direction: column; gap: 1px;
    min-width: 0;
}
.aif-wf-tpl__name {
    font-size: 12px;
    font-weight: 700;
    color: var(--aif-ink);
    line-height: 1.25;
}
.aif-wf-tpl__sub {
    font-size: 10.5px;
    color: var(--aif-muted);
    font-weight: 500;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.aif-wf-tpl__status {
    font-size: 9.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 4px 9px;
    border-radius: 999px;
    white-space: nowrap;
}
.aif-wf-tpl__status--on {
    background: rgba(31, 140, 70, 0.1);
    color: #1f8c46;
    border: 1px solid rgba(31, 140, 70, 0.28);
}
.aif-wf-tpl__item--more {
    background: linear-gradient(135deg, color-mix(in srgb, var(--aif-accent) 5%, white) 0%, color-mix(in srgb, var(--aif-accent) 12%, white) 100%);
    border: 1px dashed color-mix(in srgb, var(--aif-accent) 30%, transparent);
    grid-template-columns: 36px 1fr;
}
.aif-wf-tpl__item--more .aif-wf-tpl__icon {
    background: #fff;
    color: var(--aif-accent);
    font-size: 18px;
    font-weight: 800;
}
.aif-wf-tpl__item--more .aif-wf-tpl__name { color: var(--aif-accent); }
.aif-wf-tpl__hero {
    margin-top: auto;
    padding: 12px 14px;
    background: linear-gradient(135deg, rgba(31, 140, 70, 0.06) 0%, rgba(110, 231, 168, 0.12) 100%);
    border: 1px solid rgba(31, 140, 70, 0.22);
    border-radius: 12px;
    display: flex; align-items: baseline; justify-content: space-between;
    gap: 12px;
}
.aif-wf-tpl__hero-label {
    font-size: 10.5px;
    font-weight: 700;
    color: rgba(26, 26, 26, 0.55);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.aif-wf-tpl__hero-amount {
    font-size: 26px;
    font-weight: 800;
    color: #1f8c46;
    letter-spacing: -0.02em;
    line-height: 1;
    font-family: ui-monospace, SFMono-Regular, monospace;
}

/* Card 2 (legacy) — Visual workflow builder (unused) */
.aif-wf-flow {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 14px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 4px;
    align-items: center;
    flex: 1;
}
.aif-wf-flow__node {
    width: 220px;
    max-width: 100%;
    padding: 10px 14px;
    border-radius: 10px;
    background: #fff;
    border: 1px solid rgba(15, 23, 42, 0.1);
    box-shadow: 0 4px 12px -8px rgba(15, 23, 42, 0.18);
    display: flex; flex-direction: column; gap: 2px;
    text-align: left;
}
.aif-wf-flow__node-tag {
    font-size: 9.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    line-height: 1;
}
.aif-wf-flow__node-label {
    font-size: 12px;
    font-weight: 600;
    color: var(--aif-ink);
    font-family: ui-monospace, SFMono-Regular, monospace;
    line-height: 1.25;
}
.aif-wf-flow__node--trigger {
    background: color-mix(in srgb, var(--aif-accent) 8%, white);
    border-color: color-mix(in srgb, var(--aif-accent) 28%, transparent);
}
.aif-wf-flow__node--trigger .aif-wf-flow__node-tag { color: var(--aif-accent); }
.aif-wf-flow__node--cond {
    background: rgba(245, 158, 11, 0.08);
    border-color: rgba(245, 158, 11, 0.3);
}
.aif-wf-flow__node--cond .aif-wf-flow__node-tag { color: #b45309; }
.aif-wf-flow__node--action {
    background: rgba(31, 140, 70, 0.06);
    border-color: rgba(31, 140, 70, 0.22);
    width: 165px;
}
.aif-wf-flow__node--action .aif-wf-flow__node-tag { color: #1f8c46; }
.aif-wf-flow__line {
    width: 2px; height: 14px;
    background: rgba(15, 23, 42, 0.18);
    border-radius: 999px;
    position: relative;
}
.aif-wf-flow__line::after {
    content: "";
    position: absolute;
    bottom: -2px; left: 50%;
    transform: translateX(-50%);
    border: 4px solid transparent;
    border-top-color: rgba(15, 23, 42, 0.3);
}
.aif-wf-flow__split {
    position: relative;
    width: 220px;
    height: 18px;
}
.aif-wf-flow__split-line {
    position: absolute;
    top: 0;
    width: 50%;
    height: 100%;
    border-top: 2px solid rgba(15, 23, 42, 0.18);
    border-bottom: none;
}
.aif-wf-flow__split-line--l {
    left: 0;
    border-left: 2px solid rgba(15, 23, 42, 0.18);
    border-radius: 0 0 0 8px;
}
.aif-wf-flow__split-line--r {
    right: 0;
    border-right: 2px solid rgba(15, 23, 42, 0.18);
    border-radius: 0 0 8px 0;
}
.aif-wf-flow__row {
    display: flex; gap: 10px;
}
.aif-wf-flow__hero {
    margin-top: auto;
    padding: 12px 14px;
    background: linear-gradient(135deg, rgba(31, 140, 70, 0.06) 0%, rgba(110, 231, 168, 0.12) 100%);
    border: 1px solid rgba(31, 140, 70, 0.22);
    border-radius: 12px;
    display: flex; align-items: baseline; justify-content: space-between;
    width: 100%;
    gap: 12px;
}
.aif-wf-flow__hero-label {
    font-size: 10.5px;
    font-weight: 700;
    color: rgba(26, 26, 26, 0.55);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.aif-wf-flow__hero-amount {
    font-size: 26px;
    font-weight: 800;
    color: #1f8c46;
    letter-spacing: -0.02em;
    line-height: 1;
    font-family: ui-monospace, SFMono-Regular, monospace;
}

/* Card 3 — Real-time sync */
.aif-wf-sync {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 14px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 12px;
    flex: 1;
    justify-content: center;
}
.aif-wf-sync__panel {
    padding: 12px 14px;
    border-radius: 10px;
    background: rgba(15, 23, 42, 0.025);
    border: 1px solid rgba(15, 23, 42, 0.06);
    display: flex; flex-direction: column; gap: 4px;
}
.aif-wf-sync__sys {
    font-size: 9.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--aif-muted);
}
.aif-wf-sync__name {
    font-size: 13px;
    font-weight: 700;
    color: var(--aif-ink);
}
.aif-wf-sync__field {
    font-size: 11px;
    color: var(--aif-muted);
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-wf-sync__field em { color: #1f8c46; font-style: normal; font-weight: 700; }
.aif-wf-sync__wire {
    position: relative;
    height: 30px;
    margin: 0 30px;
    border-top: 2px dashed color-mix(in srgb, var(--aif-accent) 35%, transparent);
}
.aif-wf-sync__dot {
    position: absolute;
    top: -5px;
    width: 8px; height: 8px;
    border-radius: 999px;
    background: var(--aif-accent);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--aif-accent) 22%, transparent);
}
.aif-ns-anim.is-in .aif-wf-sync__dot--d1 { animation: aif-wf-flow 1.6s ease-in-out infinite; }
.aif-ns-anim.is-in .aif-wf-sync__dot--d2 { animation: aif-wf-flow 1.6s ease-in-out infinite 0.4s; }
.aif-ns-anim.is-in .aif-wf-sync__dot--d3 { animation: aif-wf-flow 1.6s ease-in-out infinite 0.8s; }
@keyframes aif-wf-flow {
    0%   { left: 0%;   opacity: 0; }
    10%  { opacity: 1; }
    90%  { opacity: 1; }
    100% { left: 100%; opacity: 0; }
}
.aif-wf-sync__latency {
    position: absolute;
    top: -10px; left: 50%;
    transform: translateX(-50%);
    background: #fff;
    padding: 2px 8px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 800;
    color: #1f8c46;
    border: 1px solid rgba(31, 140, 70, 0.3);
    font-family: ui-monospace, SFMono-Regular, monospace;
}

/* Card 4 — Trigger library chips */
.aif-wf-trig {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 14px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-wrap: wrap; gap: 6px;
    flex: 1;
    align-content: flex-start;
    align-items: flex-start;
}
.aif-wf-trig__chip {
    padding: 6px 11px;
    border-radius: 8px;
    background: rgba(15, 23, 42, 0.04);
    border: 1px solid rgba(15, 23, 42, 0.06);
    font-size: 10.5px;
    font-weight: 700;
    color: var(--aif-ink);
    font-family: ui-monospace, SFMono-Regular, monospace;
    transition: transform 0.2s ease, background 0.2s ease;
}
.aif-wf-trig__chip:hover {
    transform: translateY(-1px);
    background: color-mix(in srgb, var(--aif-accent) 10%, white);
    border-color: color-mix(in srgb, var(--aif-accent) 30%, transparent);
}
.aif-wf-trig__chip--more {
    background: linear-gradient(135deg, color-mix(in srgb, var(--aif-accent) 8%, white) 0%, color-mix(in srgb, var(--aif-accent) 18%, white) 100%);
    border: 1px dashed color-mix(in srgb, var(--aif-accent) 35%, transparent);
    color: var(--aif-accent);
    font-style: italic;
}

/* Card 5 — Hours saved per day */
.aif-wf-hours {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 14px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 12px;
    flex: 1;
}
.aif-wf-hours__chart {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 8px;
    height: 110px;
    align-items: end;
}
.aif-wf-hours__col {
    display: flex; flex-direction: column;
    align-items: center; justify-content: flex-end;
    gap: 6px;
    height: 100%;
}
.aif-wf-hours__bar {
    display: block;
    width: 100%;
    height: 0;
    background: linear-gradient(180deg, color-mix(in srgb, var(--aif-accent) 80%, white) 0%, var(--aif-accent) 100%);
    border-radius: 6px 6px 0 0;
    transition: height 1.0s cubic-bezier(.2, .8, .2, 1);
    min-height: 6px;
}
.aif-ns-anim.is-in .aif-wf-hours__bar {
    height: var(--aif-wf-h, 0%);
}
.aif-wf-hours__day {
    font-size: 9.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--aif-muted);
}
.aif-wf-hours__total {
    margin-top: auto;
    padding: 12px 14px;
    background: linear-gradient(135deg, rgba(31, 140, 70, 0.06) 0%, rgba(110, 231, 168, 0.12) 100%);
    border: 1px solid rgba(31, 140, 70, 0.22);
    border-radius: 10px;
    display: flex; align-items: baseline; justify-content: space-between;
    gap: 10px;
}
.aif-wf-hours__total-label {
    font-size: 9.5px;
    font-weight: 700;
    color: rgba(26, 26, 26, 0.55);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.aif-wf-hours__total-amount {
    font-size: 22px;
    font-weight: 800;
    color: #1f8c46;
    letter-spacing: -0.02em;
    line-height: 1;
    font-family: ui-monospace, SFMono-Regular, monospace;
}

/* Card 6 — Activity log (plain-English, compact) */
.aif-wf-act {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 8px;
    flex: 1;
}
.aif-wf-act__head {
    display: flex; align-items: center; justify-content: space-between;
    padding: 0 4px 6px;
    border-bottom: 1px dashed var(--aif-line);
}
.aif-wf-act__head-title {
    font-size: 10.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--aif-ink);
}
.aif-wf-act__head-meta {
    font-size: 10px;
    font-weight: 600;
    color: var(--aif-muted);
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-wf-act__row {
    display: grid;
    grid-template-columns: 28px 1fr auto;
    gap: 10px;
    padding: 8px 4px;
    align-items: start;
    border-radius: 8px;
    transition: background 0.2s ease;
}
.aif-wf-act__row + .aif-wf-act__row { border-top: 1px solid rgba(15, 23, 42, 0.04); }
.aif-wf-act__row:hover { background: rgba(15, 23, 42, 0.02); }
.aif-wf-act__icon {
    width: 24px; height: 24px;
    border-radius: 999px;
    display: flex; align-items: center; justify-content: center;
    font-size: 13px;
    font-weight: 700;
    line-height: 1;
    margin-top: 1px;
}
.aif-wf-act__icon--ok {
    background: rgba(31, 140, 70, 0.1);
    color: #1f8c46;
    border: 1px solid rgba(31, 140, 70, 0.25);
}
.aif-wf-act__icon--retry {
    background: rgba(245, 158, 11, 0.1);
    color: #b45309;
    border: 1px solid rgba(245, 158, 11, 0.3);
}
.aif-wf-act__body {
    display: flex; flex-direction: column; gap: 2px;
    min-width: 0;
}
.aif-wf-act__title {
    font-size: 11.5px;
    font-weight: 600;
    color: var(--aif-ink);
    line-height: 1.3;
}
.aif-wf-act__title strong { font-weight: 700; }
.aif-wf-act__steps {
    margin: 2px 0 0;
    padding: 0;
    list-style: none;
    display: flex; flex-direction: column; gap: 1px;
}
.aif-wf-act__steps li {
    font-size: 10.5px;
    color: var(--aif-muted);
    padding-left: 10px;
    position: relative;
    line-height: 1.35;
}
.aif-wf-act__steps li::before {
    content: "·";
    position: absolute;
    left: 2px; top: 0;
    color: var(--aif-muted);
    font-weight: 700;
}
.aif-wf-act__time {
    font-size: 10px;
    font-weight: 700;
    color: var(--aif-muted);
    font-family: ui-monospace, SFMono-Regular, monospace;
    letter-spacing: 0.02em;
    margin-top: 4px;
}
.aif-wf-act__foot {
    margin-top: auto;
    display: flex; align-items: center; gap: 8px;
    padding: 8px 4px 0;
    border-top: 1px dashed var(--aif-line);
    font-size: 10px;
    font-weight: 600;
    color: var(--aif-muted);
}
.aif-wf-act__pulse {
    width: 7px; height: 7px;
    border-radius: 999px;
    background: #1f8c46;
    box-shadow: 0 0 0 3px rgba(31, 140, 70, 0.18);
    animation: aif-pulse 1.4s ease-in-out infinite;
}

/* Card 6 (legacy) — Audit + diffs (kept for fallback compat, unused) */
.aif-wf-diff {
    position: relative; z-index: 1;
    background: linear-gradient(180deg, #0f172a 0%, #111827 100%);
    border: 1px solid rgba(15, 23, 42, 0.2);
    border-radius: 12px;
    padding: 0;
    box-shadow: 0 16px 36px -18px rgba(15, 23, 42, 0.55);
    display: flex; flex-direction: column;
    flex: 1;
    overflow: hidden;
}
.aif-wf-diff__bar {
    display: flex; align-items: center; gap: 10px;
    padding: 11px 14px;
    background: rgba(255, 255, 255, 0.03);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-wf-diff__bar-dot {
    width: 8px; height: 8px;
    border-radius: 999px;
    background: #34d399;
    box-shadow: 0 0 0 3px rgba(52, 211, 153, 0.2);
    animation: aif-pulse 1.4s ease-in-out infinite;
}
.aif-wf-diff__bar-title {
    font-size: 11.5px;
    font-weight: 700;
    color: #e2e8f0;
    letter-spacing: 0.02em;
}
.aif-wf-diff__bar-meta {
    margin-left: auto;
    font-size: 10px;
    color: rgba(148, 163, 184, 0.65);
    letter-spacing: 0.04em;
}
.aif-wf-diff__row {
    padding: 12px 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: background 0.3s ease;
}
.aif-wf-diff__row:hover { background: rgba(255, 255, 255, 0.025); }
.aif-wf-diff__head {
    display: grid;
    grid-template-columns: 28px 1fr auto;
    align-items: center;
    gap: 12px;
    margin-bottom: 9px;
}
.aif-wf-diff__icon {
    width: 28px; height: 28px;
    border-radius: 999px;
    display: flex; align-items: center; justify-content: center;
    font-size: 14px;
    font-weight: 700;
    line-height: 1;
}
.aif-wf-diff__icon--ok {
    background: rgba(52, 211, 153, 0.16);
    color: #34d399;
    border: 1px solid rgba(52, 211, 153, 0.35);
}
.aif-wf-diff__icon--retry {
    background: rgba(251, 191, 36, 0.16);
    color: #fbbf24;
    border: 1px solid rgba(251, 191, 36, 0.35);
}
.aif-wf-diff__head-text {
    display: flex; flex-direction: column; gap: 2px;
    min-width: 0;
}
.aif-wf-diff__action {
    font-size: 12px;
    color: #f1f5f9;
    font-weight: 700;
    font-family: ui-monospace, SFMono-Regular, monospace;
    letter-spacing: 0.01em;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.aif-wf-diff__sub {
    font-size: 10px;
    color: rgba(148, 163, 184, 0.7);
    font-weight: 500;
}
.aif-wf-diff__time {
    font-size: 10px;
    color: rgba(148, 163, 184, 0.55);
    font-family: ui-monospace, SFMono-Regular, monospace;
    letter-spacing: 0.02em;
    align-self: start;
    padding-top: 4px;
}
.aif-wf-diff__diff {
    display: flex; flex-direction: column; gap: 2px;
    padding: 8px 12px;
    border-radius: 8px;
    background: rgba(15, 23, 42, 0.4);
    border-left: 2px solid rgba(255, 255, 255, 0.08);
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-wf-diff__line {
    display: grid;
    grid-template-columns: 16px 1fr;
    align-items: baseline;
    gap: 4px;
    font-size: 11px;
    line-height: 1.45;
    color: #cbd5e1;
}
.aif-wf-diff__line em {
    font-style: normal;
    font-weight: 800;
    text-align: center;
    font-size: 11px;
}
.aif-wf-diff__line span { display: contents; color: rgba(203, 213, 225, 0.7); }
.aif-wf-diff__line code {
    color: inherit;
    font-weight: 700;
    background: none;
    padding: 0;
}
.aif-wf-diff__line--minus { color: #fb7185; }
.aif-wf-diff__line--minus em { color: #fb7185; }
.aif-wf-diff__line--minus code { color: #fda4af; }
.aif-wf-diff__line--plus  { color: #34d399; }
.aif-wf-diff__line--plus em { color: #34d399; }
.aif-wf-diff__line--plus code { color: #6ee7b7; }
.aif-wf-diff__line--info  { color: #fbbf24; }
.aif-wf-diff__line--info em { color: #fbbf24; }
.aif-wf-diff__line--info code { color: #fcd34d; }
.aif-wf-diff__foot {
    margin-top: auto;
    display: flex; align-items: center; gap: 8px;
    padding: 11px 14px;
    font-size: 10.5px;
    font-weight: 600;
    color: rgba(148, 163, 184, 0.85);
    background: rgba(255, 255, 255, 0.025);
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    font-family: -apple-system, BlinkMacSystemFont, sans-serif;
    letter-spacing: 0.01em;
}
.aif-wf-diff__pulse {
    width: 7px; height: 7px;
    border-radius: 999px;
    background: #34d399;
    box-shadow: 0 0 0 3px rgba(52, 211, 153, 0.18);
    animation: aif-pulse 1.4s ease-in-out infinite;
}

/* Card 7 — Uptime / resilience (status feed) */
.aif-wf-up {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 8px;
    flex: 1;
}
.aif-wf-up__head {
    display: flex; align-items: center; justify-content: space-between;
    padding: 0 4px 6px;
    border-bottom: 1px dashed var(--aif-line);
}
.aif-wf-up__head-title {
    font-size: 10.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--aif-ink);
}
.aif-wf-up__head-meta {
    font-size: 10px;
    font-weight: 600;
    color: var(--aif-muted);
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-wf-up__metric-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
    padding: 4px 0 6px;
}
.aif-wf-up__metric {
    padding: 8px 10px;
    border-radius: 8px;
    background: rgba(15, 23, 42, 0.025);
    border: 1px solid rgba(15, 23, 42, 0.05);
    display: flex; flex-direction: column; gap: 3px;
}
.aif-wf-up__metric-label {
    font-size: 9px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--aif-muted);
    line-height: 1.2;
}
.aif-wf-up__metric-value {
    font-size: 19px;
    font-weight: 800;
    color: #1f8c46;
    letter-spacing: -0.02em;
    line-height: 1;
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-wf-up__metric-value small {
    font-size: 11.5px; font-weight: 700; margin-left: 1px;
}
.aif-wf-up__metric-value--zero { color: var(--aif-muted); }
.aif-wf-up__events {
    display: flex; flex-direction: column;
}
.aif-wf-up__event {
    display: grid;
    grid-template-columns: 24px 1fr auto;
    gap: 10px;
    padding: 8px 4px;
    align-items: center;
    border-radius: 8px;
    transition: background 0.2s ease;
}
.aif-wf-up__event + .aif-wf-up__event { border-top: 1px solid rgba(15, 23, 42, 0.04); }
.aif-wf-up__event:hover { background: rgba(15, 23, 42, 0.02); }
.aif-wf-up__event-icon {
    width: 24px; height: 24px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 700;
    line-height: 1;
}
.aif-wf-up__event--retry .aif-wf-up__event-icon {
    background: rgba(245, 158, 11, 0.1);
    color: #b45309;
    border: 1px solid rgba(245, 158, 11, 0.3);
}
.aif-wf-up__event--ok .aif-wf-up__event-icon {
    background: rgba(31, 140, 70, 0.1);
    color: #1f8c46;
    border: 1px solid rgba(31, 140, 70, 0.25);
}
.aif-wf-up__event-body {
    display: flex; flex-direction: column; gap: 1px;
    min-width: 0;
}
.aif-wf-up__event-title {
    font-size: 11.5px;
    font-weight: 700;
    color: var(--aif-ink);
    line-height: 1.25;
}
.aif-wf-up__event-sub {
    font-size: 10.5px;
    color: var(--aif-muted);
    font-weight: 500;
    line-height: 1.3;
}
.aif-wf-up__event-time {
    font-size: 10px;
    font-weight: 700;
    color: var(--aif-muted);
    font-family: ui-monospace, SFMono-Regular, monospace;
    letter-spacing: 0.02em;
}
.aif-wf-up__foot {
    margin-top: auto;
    display: flex; align-items: center; gap: 8px;
    padding: 8px 4px 0;
    border-top: 1px dashed var(--aif-line);
    font-size: 10px;
    font-weight: 600;
    color: var(--aif-muted);
}
.aif-wf-up__pulse {
    width: 7px; height: 7px;
    border-radius: 999px;
    background: #1f8c46;
    box-shadow: 0 0 0 3px rgba(31, 140, 70, 0.18);
    animation: aif-pulse 1.4s ease-in-out infinite;
}

/* No-show recovery — Calendar grid with miss → recovered flips */
.aif-ns-cal {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 14px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 12px;
    flex: 1;
}
.aif-ns-cal__head {
    display: flex; align-items: center; justify-content: space-between;
    gap: 10px;
}
.aif-ns-cal__title {
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--aif-muted);
}
.aif-ns-cal__legend {
    display: flex; align-items: center; gap: 8px;
    font-size: 9.5px;
    font-weight: 700;
    color: var(--aif-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.aif-ns-cal__sw {
    display: inline-block;
    width: 9px; height: 9px;
    border-radius: 3px;
    margin-right: 3px;
    vertical-align: -1px;
}
.aif-ns-cal__sw--booked { background: rgba(15, 23, 42, 0.12); }
.aif-ns-cal__sw--missed { background: rgba(220, 38, 38, 0.6); }
.aif-ns-cal__sw--rec { background: #1f8c46; }
.aif-ns-cal__grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 6px;
}
.aif-ns-cal__day {
    text-align: center;
    font-size: 9.5px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--aif-muted);
    padding-bottom: 2px;
}
.aif-ns-cal__cell {
    height: 28px;
    border-radius: 6px;
    background: rgba(15, 23, 42, 0.06);
    border: 1px solid rgba(15, 23, 42, 0.04);
    position: relative;
    transition: background 0.5s ease, border-color 0.5s ease, transform 0.4s ease;
}
.aif-ns-cal__cell--booked {
    background: rgba(15, 23, 42, 0.08);
    border-color: rgba(15, 23, 42, 0.06);
}
.aif-ns-cal__cell--miss {
    background: rgba(220, 38, 38, 0.15);
    border-color: rgba(220, 38, 38, 0.35);
}
.aif-ns-cal__cell--miss::after {
    content: "";
    position: absolute;
    inset: 0;
    background-image: linear-gradient(45deg, rgba(220, 38, 38, 0.55) 1px, transparent 1px),
                      linear-gradient(-45deg, rgba(220, 38, 38, 0.55) 1px, transparent 1px);
    background-size: 6px 6px;
    border-radius: inherit;
    opacity: 0.7;
    transition: opacity 0.4s ease;
}
.aif-ns-anim.is-in .aif-ns-cal__cell--miss[data-recover="1"] {
    background: rgba(31, 140, 70, 0.16);
    border-color: rgba(31, 140, 70, 0.42);
    animation: aif-ns-cal-flip 0.7s cubic-bezier(.2, .8, .2, 1) forwards;
}
.aif-ns-anim.is-in .aif-ns-cal__cell--miss[data-recover="1"]::after {
    opacity: 0;
}
.aif-ns-anim.is-in .aif-ns-cal__cell--miss[data-recover="1"]::before {
    content: "✓";
    position: absolute; inset: 0;
    display: flex; align-items: center; justify-content: center;
    font-size: 14px;
    font-weight: 800;
    color: #1f8c46;
    opacity: 0;
    animation: aif-ns-cal-check 0.6s ease forwards;
    animation-delay: 0.4s;
}
.aif-ns-anim.is-in .aif-ns-cal__cell--miss[data-recover="1"]:nth-of-type(7)  { animation-delay: 0.10s; }
.aif-ns-anim.is-in .aif-ns-cal__cell--miss[data-recover="1"]:nth-of-type(11) { animation-delay: 0.30s; }
.aif-ns-anim.is-in .aif-ns-cal__cell--miss[data-recover="1"]:nth-of-type(20) { animation-delay: 0.55s; }
.aif-ns-anim.is-in .aif-ns-cal__cell--miss[data-recover="1"]:nth-of-type(24) { animation-delay: 0.80s; }
@keyframes aif-ns-cal-flip {
    0%   { transform: scale(1);     }
    45%  { transform: scale(1.18);  }
    100% { transform: scale(1);     }
}
@keyframes aif-ns-cal-check {
    to { opacity: 1; }
}
.aif-ns-cal__hero {
    margin-top: auto;
    padding: 12px 14px;
    background: linear-gradient(135deg, rgba(31, 140, 70, 0.06) 0%, rgba(110, 231, 168, 0.12) 100%);
    border: 1px solid rgba(31, 140, 70, 0.22);
    border-radius: 12px;
    display: grid;
    grid-template-columns: 1fr auto auto;
    align-items: center;
    column-gap: 14px;
}
.aif-ns-cal__hero-label {
    font-size: 10.5px;
    font-weight: 700;
    color: rgba(26, 26, 26, 0.55);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    grid-column: 1; grid-row: 1;
    align-self: end;
}
.aif-ns-cal__hero-amount {
    font-size: 26px;
    font-weight: 800;
    color: #1f8c46;
    letter-spacing: -0.02em;
    line-height: 1;
    font-family: ui-monospace, SFMono-Regular, monospace;
    grid-column: 1; grid-row: 2;
    align-self: start;
}
.aif-ns-cal__hero-side {
    display: flex; flex-direction: column; gap: 2px;
    align-items: flex-end;
    grid-column: 3; grid-row: 1 / span 2;
    padding-left: 12px;
    border-left: 1px solid rgba(31, 140, 70, 0.22);
}
.aif-ns-cal__hero-side-label {
    font-size: 9.5px;
    font-weight: 700;
    color: rgba(26, 26, 26, 0.55);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.aif-ns-cal__hero-side-amount {
    font-size: 18px;
    font-weight: 800;
    color: #1f8c46;
    font-family: ui-monospace, SFMono-Regular, monospace;
    line-height: 1;
}

/* No-show recovery — Patient cards stack */
.aif-ns-patients {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 14px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 12px;
    flex: 1;
}
.aif-ns-patients__list {
    display: flex; flex-direction: column; gap: 8px;
}
.aif-ns-patients__card {
    display: grid;
    grid-template-columns: 36px 1fr auto;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    border-radius: 12px;
    background: #fff;
    border: 1px solid rgba(15, 23, 42, 0.06);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}
.aif-ns-patients__card:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 14px -10px rgba(15, 23, 42, 0.18);
}
.aif-ns-patients__avatar {
    width: 36px; height: 36px;
    border-radius: 999px;
    background: var(--ns-av, #f5b1cf);
    display: flex; align-items: center; justify-content: center;
    font-size: 11.5px;
    font-weight: 800;
    color: rgba(15, 23, 42, 0.78);
    letter-spacing: 0.03em;
}
.aif-ns-patients__info {
    display: flex; flex-direction: column; gap: 2px;
    min-width: 0;
}
.aif-ns-patients__name {
    font-size: 12px;
    font-weight: 700;
    color: var(--aif-ink);
    line-height: 1.2;
}
.aif-ns-patients__meta {
    font-size: 10.5px;
    color: var(--aif-muted);
    font-weight: 500;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.aif-ns-patients__status {
    font-size: 9.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 4px 10px;
    border-radius: 999px;
    white-space: nowrap;
}
.aif-ns-patients__status--sent {
    background: color-mix(in srgb, var(--aif-accent) 8%, white);
    color: var(--aif-accent);
    border: 1px solid color-mix(in srgb, var(--aif-accent) 22%, transparent);
}
.aif-ns-patients__status--engaged {
    background: rgba(99, 102, 241, 0.1);
    color: #4338ca;
    border: 1px solid rgba(99, 102, 241, 0.25);
}
.aif-ns-patients__status--booked {
    background: rgba(31, 140, 70, 0.12);
    color: #1f8c46;
    border: 1px solid rgba(31, 140, 70, 0.3);
}
.aif-ns-patients__hero {
    margin-top: auto;
    padding: 12px 14px;
    background: linear-gradient(135deg, rgba(31, 140, 70, 0.06) 0%, rgba(110, 231, 168, 0.12) 100%);
    border: 1px solid rgba(31, 140, 70, 0.22);
    border-radius: 12px;
    display: flex; align-items: baseline; justify-content: space-between;
    gap: 12px;
}
.aif-ns-patients__hero-label {
    font-size: 10.5px;
    font-weight: 700;
    color: rgba(26, 26, 26, 0.55);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.aif-ns-patients__hero-amount {
    font-size: 26px;
    font-weight: 800;
    color: #1f8c46;
    letter-spacing: -0.02em;
    line-height: 1;
    font-family: ui-monospace, SFMono-Regular, monospace;
}

/* No-show recovery — Live event feed */
.aif-ns-feed {
    position: relative; z-index: 1;
    background: #0f172a;
    border: 1px solid rgba(15, 23, 42, 0.15);
    border-radius: 12px;
    padding: 0;
    box-shadow: 0 12px 28px -16px rgba(15, 23, 42, 0.45);
    display: flex; flex-direction: column;
    flex: 1;
    overflow: hidden;
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-ns-feed__head {
    display: flex; align-items: center; gap: 8px;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.04);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.aif-ns-feed__pulse {
    width: 8px; height: 8px;
    border-radius: 999px;
    background: #34d399;
    box-shadow: 0 0 0 3px rgba(52, 211, 153, 0.18);
    animation: aif-pulse 1.4s ease-in-out infinite;
}
.aif-ns-feed__title {
    font-size: 10.5px;
    font-weight: 700;
    color: #34d399;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}
.aif-ns-feed__hash {
    margin-left: auto;
    font-size: 10px;
    color: rgba(148, 163, 184, 0.7);
    letter-spacing: 0.02em;
}
.aif-ns-feed__body {
    display: flex; flex-direction: column;
    padding: 6px 0;
}
.aif-ns-feed__row {
    display: grid;
    grid-template-columns: 50px 70px 1fr;
    align-items: center;
    gap: 10px;
    padding: 6px 14px;
    font-size: 11px;
    line-height: 1.3;
    border-left: 2px solid transparent;
    transition: border-color 0.3s ease, background 0.3s ease;
}
.aif-ns-feed__row + .aif-ns-feed__row { border-top: 1px dashed rgba(255, 255, 255, 0.05); }
.aif-ns-feed__t {
    color: rgba(148, 163, 184, 0.7);
    font-size: 10px;
    letter-spacing: 0.02em;
}
.aif-ns-feed__op {
    text-align: center;
    font-size: 9.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding: 3px 0;
    border-radius: 4px;
}
.aif-ns-feed__op--info { background: rgba(148, 163, 184, 0.18); color: #cbd5e1; }
.aif-ns-feed__op--warn { background: rgba(251, 191, 36, 0.18); color: #fbbf24; }
.aif-ns-feed__op--act  { background: rgba(232, 52, 122, 0.22); color: #fb7185; }
.aif-ns-feed__op--won  { background: rgba(52, 211, 153, 0.22); color: #34d399; }
.aif-ns-feed__msg {
    color: #e2e8f0;
    font-size: 11px;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.aif-ns-feed__row--won {
    background: rgba(52, 211, 153, 0.06);
    border-left-color: #34d399;
}
.aif-ns-feed__row--won .aif-ns-feed__msg { color: #34d399; font-weight: 700; }
.aif-ns-feed__compare {
    margin-top: auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1px;
    background: rgba(255, 255, 255, 0.05);
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}
.aif-ns-feed__compare-row {
    display: flex; flex-direction: column; gap: 4px;
    padding: 12px 14px;
    background: #0f172a;
}
.aif-ns-feed__compare-row--slow { background: rgba(15, 23, 42, 0.85); }
.aif-ns-feed__compare-label {
    font-size: 9.5px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: rgba(148, 163, 184, 0.75);
}
.aif-ns-feed__compare-val {
    font-size: 26px;
    font-weight: 800;
    color: #94a3b8;
    letter-spacing: -0.02em;
    line-height: 1;
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-ns-feed__compare-val small {
    font-size: 13px;
    font-weight: 700;
    margin-left: 2px;
    color: rgba(148, 163, 184, 0.7);
}
.aif-ns-feed__compare-val--fast { color: #34d399; }
.aif-ns-feed__compare-val--fast small { color: rgba(52, 211, 153, 0.7); }

/* No-show recovery — Smart cadence */
.aif-ns-cadence {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 6px;
    flex: 1;
}
.aif-ns-cadence__row {
    display: grid;
    grid-template-columns: 56px 1fr auto;
    gap: 10px;
    align-items: center;
    padding: 8px 10px;
    border-radius: 10px;
    background: rgba(15, 23, 42, 0.025);
    border: 1px solid rgba(15, 23, 42, 0.04);
}
.aif-ns-cadence__row--done {
    background: color-mix(in srgb, var(--aif-accent) 5%, white);
    border-color: color-mix(in srgb, var(--aif-accent) 18%, transparent);
}
.aif-ns-cadence__row--paused {
    opacity: 0.7;
    background: rgba(15, 23, 42, 0.04);
}
.aif-ns-cadence__channel {
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--aif-accent);
    text-align: center;
    padding: 3px 0;
    border-radius: 999px;
    background: #fff;
    border: 1px solid color-mix(in srgb, var(--aif-accent) 22%, transparent);
}
.aif-ns-cadence__row--paused .aif-ns-cadence__channel {
    color: var(--aif-muted);
    border-color: rgba(15, 23, 42, 0.1);
}
.aif-ns-cadence__msg {
    font-size: 11.5px;
    color: var(--aif-ink);
    font-weight: 500;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.aif-ns-cadence__status {
    font-size: 10px;
    font-weight: 700;
    color: #1f8c46;
    font-family: ui-monospace, SFMono-Regular, monospace;
    letter-spacing: 0.04em;
}
.aif-ns-cadence__row--paused .aif-ns-cadence__status { color: var(--aif-muted); }
.aif-ns-cadence__pill {
    margin-top: auto;
    align-self: stretch;
    text-align: center;
    padding: 8px 12px;
    background: linear-gradient(135deg, rgba(31, 140, 70, 0.06) 0%, rgba(110, 231, 168, 0.12) 100%);
    border: 1px solid rgba(31, 140, 70, 0.22);
    border-radius: 10px;
    font-size: 11px;
    font-weight: 700;
    color: #1f8c46;
    letter-spacing: 0.02em;
}

/* No-show recovery — Treatment-aware */
.aif-ns-treatments {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 8px;
    flex: 1;
}
.aif-ns-treatments__row {
    display: grid;
    grid-template-columns: 1fr auto;
    grid-template-rows: auto auto;
    align-items: center;
    column-gap: 10px;
    row-gap: 5px;
    padding: 8px 10px;
    border-radius: 10px;
    background: rgba(15, 23, 42, 0.025);
    border: 1px solid rgba(15, 23, 42, 0.04);
}
.aif-ns-treatments__name {
    font-size: 11.5px;
    font-weight: 700;
    color: var(--aif-ink);
    grid-column: 1; grid-row: 1;
}
.aif-ns-treatments__cycle {
    font-size: 10px;
    font-weight: 600;
    color: var(--aif-muted);
    font-family: ui-monospace, SFMono-Regular, monospace;
    grid-column: 2; grid-row: 1;
    text-align: right;
}
.aif-ns-treatments__bar {
    height: 6px;
    background: rgba(15, 23, 42, 0.06);
    border-radius: 999px;
    overflow: hidden;
    grid-column: 1; grid-row: 2;
}
.aif-ns-treatments__fill {
    height: 100%;
    background: linear-gradient(90deg, color-mix(in srgb, var(--aif-accent) 70%, white) 0%, var(--aif-accent) 100%);
    border-radius: 999px;
    width: 0;
}
.aif-ns-treatments__tag {
    font-size: 10px;
    font-weight: 700;
    color: var(--aif-accent);
    text-align: right;
    font-family: ui-monospace, SFMono-Regular, monospace;
    letter-spacing: 0.02em;
    grid-column: 2; grid-row: 2;
}

/* No-show recovery — Audit log */
.aif-ns-audit {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 4px;
    flex: 1;
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-ns-audit__head {
    display: grid;
    grid-template-columns: 60px 70px 1fr 80px;
    gap: 10px;
    padding: 6px 8px;
    font-size: 9.5px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--aif-muted);
    border-bottom: 1px dashed var(--aif-line);
}
.aif-ns-audit__row {
    display: grid;
    grid-template-columns: 60px 70px 1fr 80px;
    gap: 10px;
    padding: 8px 8px;
    font-size: 11px;
    align-items: center;
    border-radius: 6px;
    transition: background 0.2s ease;
}
.aif-ns-audit__row:hover { background: rgba(15, 23, 42, 0.025); }
.aif-ns-audit__time { color: var(--aif-muted); font-weight: 600; }
.aif-ns-audit__patient { color: var(--aif-ink); font-weight: 700; }
.aif-ns-audit__action {
    color: var(--aif-ink);
    font-weight: 500;
    font-family: -apple-system, BlinkMacSystemFont, sans-serif;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.aif-ns-audit__status {
    font-size: 9.5px;
    font-weight: 800;
    text-align: center;
    padding: 3px 6px;
    border-radius: 999px;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}
.aif-ns-audit__status--ok {
    background: rgba(31, 140, 70, 0.1);
    color: #1f8c46;
}
.aif-ns-audit__status--stop {
    background: rgba(220, 38, 38, 0.1);
    color: #b91c1c;
}
.aif-ns-audit__foot {
    margin-top: auto;
    display: flex; align-items: center; gap: 8px;
    padding: 10px 8px 4px;
    border-top: 1px dashed var(--aif-line);
    font-size: 10px;
    font-weight: 600;
    color: var(--aif-muted);
    font-family: -apple-system, BlinkMacSystemFont, sans-serif;
}
.aif-ns-audit__pulse {
    width: 7px; height: 7px;
    border-radius: 999px;
    background: #1f8c46;
    box-shadow: 0 0 0 3px rgba(31, 140, 70, 0.18);
    animation: aif-pulse 1.4s ease-in-out infinite;
}

/* No-show recovery — Stats / analytics */
.aif-ns-stats {
    position: relative; z-index: 1;
    background: #fff;
    border: 1px solid var(--aif-line);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 16px -10px rgba(15, 23, 42, 0.08);
    display: flex; flex-direction: column; gap: 12px;
    flex: 1;
}
.aif-ns-stats__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}
.aif-ns-stats__tile {
    padding: 10px 12px;
    border-radius: 10px;
    background: linear-gradient(135deg, rgba(31, 140, 70, 0.06) 0%, rgba(110, 231, 168, 0.12) 100%);
    border: 1px solid rgba(31, 140, 70, 0.18);
    display: flex; flex-direction: column; gap: 3px;
}
.aif-ns-stats__label {
    font-size: 9.5px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: rgba(26, 26, 26, 0.55);
}
.aif-ns-stats__value {
    font-size: 22px;
    font-weight: 800;
    color: #1f8c46;
    letter-spacing: -0.02em;
    line-height: 1.05;
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-ns-stats__delta {
    font-size: 10px;
    font-weight: 700;
    color: #1f8c46;
    font-family: ui-monospace, SFMono-Regular, monospace;
}
.aif-ns-stats__chart {
    display: flex; flex-direction: column; gap: 6px;
    padding: 10px 12px;
    border-radius: 10px;
    background: rgba(15, 23, 42, 0.025);
    border: 1px solid rgba(15, 23, 42, 0.04);
}
.aif-ns-stats__chart-label {
    font-size: 9.5px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--aif-muted);
    margin-bottom: 2px;
}
.aif-ns-stats__chart-row {
    display: grid;
    grid-template-columns: 50px 1fr 36px;
    gap: 8px;
    align-items: center;
    font-size: 11px;
    color: var(--aif-ink);
    font-weight: 600;
}
.aif-ns-stats__chart-bar {
    height: 6px;
    background: rgba(15, 23, 42, 0.06);
    border-radius: 999px;
    overflow: hidden;
}
.aif-ns-stats__chart-fill {
    height: 100%;
    background: linear-gradient(90deg, color-mix(in srgb, var(--aif-accent) 60%, white) 0%, var(--aif-accent) 100%);
    border-radius: 999px;
    width: 0;
}
.aif-ns-stats__chart-row strong {
    text-align: right;
    font-family: ui-monospace, SFMono-Regular, monospace;
    font-weight: 800;
    color: var(--aif-accent);
    font-size: 10.5px;
}

/* No-show recovery animation — bars fill on scroll, counts tick up */
.aif-ns-anim .aif-ns-treatments__fill,
.aif-ns-anim .aif-ns-stats__chart-fill {
    width: 0;
    transition: width 1.1s cubic-bezier(.2, .8, .2, 1);
}
.aif-ns-anim.is-in .aif-ns-treatments__fill,
.aif-ns-anim.is-in .aif-ns-stats__chart-fill {
    width: var(--aif-ns-w, 0%);
}
.aif-ns-anim .aif-wf-dry__result,
.aif-ns-anim .aif-wf-tpl__item,
.aif-ns-anim .aif-wf-trig__chip,
.aif-ns-anim .aif-wf-act__row,
.aif-ns-anim .aif-wf-sync__panel,
.aif-ns-anim .aif-wf-up__metric,
.aif-ns-anim .aif-wf-up__event,
.aif-ns-anim .aif-sc-dash__row,
.aif-ns-anim .aif-sc-dev__device,
.aif-ns-anim .aif-sc-accent__row,
.aif-ns-anim .aif-sc-priv__step,
.aif-ns-anim .aif-sc-ehr__field,
.aif-ns-anim .aif-ae-canvas__line,
.aif-ns-anim .aif-ae-rate__row,
.aif-ns-anim .aif-ae-review__row,
.aif-ns-anim .aif-ae-priv__row,
.aif-ns-anim .aif-ae-combo__pkg,
.aif-ns-anim .aif-ae-aging__row,
.aif-ns-anim .aif-ae-faq__item {
    opacity: 0;
    transform: translateY(6px);
    transition: opacity 0.45s ease, transform 0.45s ease;
}
.aif-ns-anim.is-in .aif-wf-dry__result,
.aif-ns-anim.is-in .aif-wf-tpl__item,
.aif-ns-anim.is-in .aif-wf-trig__chip,
.aif-ns-anim.is-in .aif-wf-act__row,
.aif-ns-anim.is-in .aif-wf-sync__panel,
.aif-ns-anim.is-in .aif-wf-up__metric,
.aif-ns-anim.is-in .aif-wf-up__event,
.aif-ns-anim.is-in .aif-sc-dash__row,
.aif-ns-anim.is-in .aif-sc-dev__device,
.aif-ns-anim.is-in .aif-sc-accent__row,
.aif-ns-anim.is-in .aif-sc-priv__step,
.aif-ns-anim.is-in .aif-sc-ehr__field,
.aif-ns-anim.is-in .aif-ae-canvas__line,
.aif-ns-anim.is-in .aif-ae-rate__row,
.aif-ns-anim.is-in .aif-ae-review__row,
.aif-ns-anim.is-in .aif-ae-priv__row,
.aif-ns-anim.is-in .aif-ae-combo__pkg,
.aif-ns-anim.is-in .aif-ae-aging__row,
.aif-ns-anim.is-in .aif-ae-faq__item { opacity: 1; transform: none; }
.aif-ns-anim.is-in .aif-ae-faq__item:nth-of-type(1) { transition-delay: 0.10s; }
.aif-ns-anim.is-in .aif-ae-faq__item:nth-of-type(2) { transition-delay: 0.22s; }
.aif-ns-anim.is-in .aif-ae-faq__item:nth-of-type(3) { transition-delay: 0.34s; }
.aif-ns-anim.is-in .aif-ae-faq__item:nth-of-type(4) { transition-delay: 0.46s; }
.aif-ns-anim.is-in .aif-ae-combo__pkg:nth-of-type(1) { transition-delay: 0.10s; }
.aif-ns-anim.is-in .aif-ae-combo__pkg:nth-of-type(2) { transition-delay: 0.25s; }
.aif-ns-anim.is-in .aif-ae-combo__pkg:nth-of-type(3) { transition-delay: 0.40s; }
.aif-ns-anim.is-in .aif-ae-aging__row:nth-of-type(1) { transition-delay: 0.10s; }
.aif-ns-anim.is-in .aif-ae-aging__row:nth-of-type(2) { transition-delay: 0.40s; }
.aif-ns-anim.is-in .aif-ae-aging__row:nth-of-type(3) { transition-delay: 0.70s; }
.aif-ns-anim.is-in .aif-ae-learn__r:nth-of-type(1) { transition-delay: 0.10s; }
.aif-ns-anim.is-in .aif-ae-learn__r:nth-of-type(2) { transition-delay: 0.22s; }
.aif-ns-anim.is-in .aif-ae-learn__r:nth-of-type(3) { transition-delay: 0.34s; }
.aif-ns-anim.is-in .aif-ae-learn__r:nth-of-type(4) { transition-delay: 0.46s; }
.aif-ns-anim.is-in .aif-ae-canvas__line:nth-of-type(1) { transition-delay: 0.10s; }
.aif-ns-anim.is-in .aif-ae-canvas__line:nth-of-type(2) { transition-delay: 0.22s; }
.aif-ns-anim.is-in .aif-ae-canvas__line:nth-of-type(3) { transition-delay: 0.34s; }
.aif-ns-anim.is-in .aif-ae-rate__row:nth-of-type(1) { transition-delay: 0.10s; }
.aif-ns-anim.is-in .aif-ae-rate__row:nth-of-type(2) { transition-delay: 0.25s; }
.aif-ns-anim.is-in .aif-ae-rate__row:nth-of-type(3) { transition-delay: 0.40s; }
.aif-ns-anim.is-in .aif-ae-menu__item:nth-of-type(1) { transition-delay: 0.08s; }
.aif-ns-anim.is-in .aif-ae-menu__item:nth-of-type(2) { transition-delay: 0.20s; }
.aif-ns-anim.is-in .aif-ae-menu__item:nth-of-type(3) { transition-delay: 0.32s; }
.aif-ns-anim.is-in .aif-ae-menu__item:nth-of-type(4) { transition-delay: 0.44s; }
.aif-ns-anim.is-in .aif-ae-review__row:nth-of-type(1) { transition-delay: 0.10s; }
.aif-ns-anim.is-in .aif-ae-review__row:nth-of-type(2) { transition-delay: 0.25s; }
.aif-ns-anim.is-in .aif-ae-review__row:nth-of-type(3) { transition-delay: 0.40s; }
.aif-ns-anim.is-in .aif-ae-priv__row:nth-of-type(1) { transition-delay: 0.10s; }
.aif-ns-anim.is-in .aif-ae-priv__row:nth-of-type(2) { transition-delay: 0.22s; }
.aif-ns-anim.is-in .aif-ae-priv__row:nth-of-type(3) { transition-delay: 0.34s; }
.aif-ns-anim.is-in .aif-ae-priv__row:nth-of-type(4) { transition-delay: 0.46s; }
.aif-ns-anim.is-in .aif-sc-dash__row:nth-of-type(1) { transition-delay: 0.08s; }
.aif-ns-anim.is-in .aif-sc-dash__row:nth-of-type(2) { transition-delay: 0.20s; }
.aif-ns-anim.is-in .aif-sc-dash__row:nth-of-type(3) { transition-delay: 0.32s; }
.aif-ns-anim.is-in .aif-sc-dash__row:nth-of-type(4) { transition-delay: 0.44s; }
.aif-ns-anim.is-in .aif-sc-dev__device:nth-of-type(1) { transition-delay: 0.08s; }
.aif-ns-anim.is-in .aif-sc-dev__device:nth-of-type(2) { transition-delay: 0.22s; }
.aif-ns-anim.is-in .aif-sc-dev__device:nth-of-type(3) { transition-delay: 0.36s; }
.aif-ns-anim.is-in .aif-sc-accent__row:nth-of-type(1) { transition-delay: 0.10s; }
.aif-ns-anim.is-in .aif-sc-accent__row:nth-of-type(2) { transition-delay: 0.22s; }
.aif-ns-anim.is-in .aif-sc-accent__row:nth-of-type(3) { transition-delay: 0.34s; }
.aif-ns-anim.is-in .aif-sc-accent__row:nth-of-type(4) { transition-delay: 0.46s; }
.aif-ns-anim.is-in .aif-sc-priv__step:nth-of-type(1) { transition-delay: 0.10s; }
.aif-ns-anim.is-in .aif-sc-priv__step:nth-of-type(2) { transition-delay: 0.22s; }
.aif-ns-anim.is-in .aif-sc-priv__step:nth-of-type(3) { transition-delay: 0.34s; }
.aif-ns-anim.is-in .aif-sc-priv__step:nth-of-type(4) { transition-delay: 0.46s; }
.aif-ns-anim.is-in .aif-sc-ehr__field:nth-of-type(1) { transition-delay: 0.05s; }
.aif-ns-anim.is-in .aif-sc-ehr__field:nth-of-type(2) { transition-delay: 0.18s; }
.aif-ns-anim.is-in .aif-sc-ehr__field:nth-of-type(3) { transition-delay: 0.31s; }
.aif-ns-anim.is-in .aif-sc-ehr__field:nth-of-type(4) { transition-delay: 0.44s; }
.aif-ns-anim.is-in .aif-sc-ehr__field:nth-of-type(5) { transition-delay: 0.57s; }
.aif-ns-anim.is-in .aif-wf-dry__result:nth-of-type(1) { transition-delay: 0.10s; }
.aif-ns-anim.is-in .aif-wf-dry__result:nth-of-type(2) { transition-delay: 0.25s; }
.aif-ns-anim.is-in .aif-wf-dry__result:nth-of-type(3) { transition-delay: 0.40s; }
.aif-ns-anim.is-in .aif-wf-up__event:nth-of-type(1) { transition-delay: 0.10s; }
.aif-ns-anim.is-in .aif-wf-up__event:nth-of-type(2) { transition-delay: 0.25s; }
.aif-ns-anim.is-in .aif-wf-up__event:nth-of-type(3) { transition-delay: 0.40s; }
.aif-ns-anim.is-in .aif-wf-hub__row:nth-of-type(1) .aif-wf-hub__node:nth-child(1) { transition-delay: 0.05s; }
.aif-ns-anim.is-in .aif-wf-hub__row:nth-of-type(1) .aif-wf-hub__node:nth-child(2) { transition-delay: 0.12s; }
.aif-ns-anim.is-in .aif-wf-hub__row:nth-of-type(1) .aif-wf-hub__node:nth-child(3) { transition-delay: 0.19s; }
.aif-ns-anim.is-in .aif-wf-hub__row:nth-of-type(3) .aif-wf-hub__node:nth-child(1) { transition-delay: 0.40s; }
.aif-ns-anim.is-in .aif-wf-hub__row:nth-of-type(3) .aif-wf-hub__node:nth-child(2) { transition-delay: 0.47s; }
.aif-ns-anim.is-in .aif-wf-hub__row:nth-of-type(3) .aif-wf-hub__node:nth-child(3) { transition-delay: 0.54s; }
.aif-ns-anim.is-in .aif-wf-tpl__item:nth-child(1) { transition-delay: 0.05s; }
.aif-ns-anim.is-in .aif-wf-tpl__item:nth-child(2) { transition-delay: 0.18s; }
.aif-ns-anim.is-in .aif-wf-tpl__item:nth-child(3) { transition-delay: 0.31s; }
.aif-ns-anim.is-in .aif-wf-tpl__item:nth-child(4) { transition-delay: 0.44s; }
.aif-ns-anim.is-in .aif-wf-tpl__item:nth-child(5) { transition-delay: 0.57s; }
.aif-ns-anim.is-in .aif-wf-trig__chip:nth-child(1) { transition-delay: 0.05s; }
.aif-ns-anim.is-in .aif-wf-trig__chip:nth-child(2) { transition-delay: 0.12s; }
.aif-ns-anim.is-in .aif-wf-trig__chip:nth-child(3) { transition-delay: 0.19s; }
.aif-ns-anim.is-in .aif-wf-trig__chip:nth-child(4) { transition-delay: 0.26s; }
.aif-ns-anim.is-in .aif-wf-trig__chip:nth-child(5) { transition-delay: 0.33s; }
.aif-ns-anim.is-in .aif-wf-trig__chip:nth-child(6) { transition-delay: 0.40s; }
.aif-ns-anim.is-in .aif-wf-trig__chip:nth-child(7) { transition-delay: 0.47s; }
.aif-ns-anim.is-in .aif-wf-trig__chip:nth-child(8) { transition-delay: 0.54s; }
.aif-ns-anim.is-in .aif-wf-act__row:nth-of-type(1) { transition-delay: 0.10s; }
.aif-ns-anim.is-in .aif-wf-act__row:nth-of-type(2) { transition-delay: 0.25s; }
.aif-ns-anim.is-in .aif-wf-act__row:nth-of-type(3) { transition-delay: 0.40s; }
.aif-ns-anim.is-in .aif-wf-sync__panel:nth-of-type(1) { transition-delay: 0.05s; }
.aif-ns-anim.is-in .aif-wf-sync__panel:nth-of-type(2) { transition-delay: 0.40s; }
.aif-ns-anim.is-in .aif-wf-up__metric:nth-of-type(1) { transition-delay: 0.05s; }
.aif-ns-anim.is-in .aif-wf-up__metric:nth-of-type(2) { transition-delay: 0.20s; }
.aif-ns-anim.is-in .aif-wf-up__metric:nth-of-type(3) { transition-delay: 0.35s; }
.aif-ns-anim .aif-wf-dry__hero,
.aif-ns-anim .aif-wf-tpl__hero,
.aif-ns-anim .aif-wf-hours__total {
    opacity: 0;
    transform: translateY(6px);
    transition: opacity 0.55s ease, transform 0.55s ease;
    transition-delay: 0.95s;
}
.aif-ns-anim.is-in .aif-wf-dry__hero,
.aif-ns-anim.is-in .aif-wf-tpl__hero,
.aif-ns-anim.is-in .aif-wf-hours__total { opacity: 1; transform: none; }
.aif-ns-anim .aif-ns-cal__hero,
.aif-ns-anim .aif-ns-patients__hero,
.aif-ns-anim .aif-ns-cadence__pill,
.aif-ns-anim .aif-ns-feed__compare {
    opacity: 0;
    transform: translateY(6px);
    transition: opacity 0.55s ease, transform 0.55s ease;
    transition-delay: 0.95s;
}
.aif-ns-anim.is-in .aif-ns-cal__hero,
.aif-ns-anim.is-in .aif-ns-patients__hero,
.aif-ns-anim.is-in .aif-ns-cadence__pill,
.aif-ns-anim.is-in .aif-ns-feed__compare {
    opacity: 1;
    transform: none;
}
.aif-ns-anim .aif-ns-audit__row,
.aif-ns-anim .aif-ns-patients__card,
.aif-ns-anim .aif-ns-feed__row {
    opacity: 0;
    transform: translateY(6px);
    transition: opacity 0.45s ease, transform 0.45s ease;
}
.aif-ns-anim.is-in .aif-ns-audit__row,
.aif-ns-anim.is-in .aif-ns-patients__card,
.aif-ns-anim.is-in .aif-ns-feed__row {
    opacity: 1;
    transform: none;
}
.aif-ns-anim.is-in .aif-ns-audit__row:nth-child(2) { transition-delay: 0.10s; }
.aif-ns-anim.is-in .aif-ns-audit__row:nth-child(3) { transition-delay: 0.25s; }
.aif-ns-anim.is-in .aif-ns-audit__row:nth-child(4) { transition-delay: 0.40s; }
.aif-ns-anim.is-in .aif-ns-audit__row:nth-child(5) { transition-delay: 0.55s; }
.aif-ns-anim.is-in .aif-ns-patients__card:nth-child(1) { transition-delay: 0.10s; }
.aif-ns-anim.is-in .aif-ns-patients__card:nth-child(2) { transition-delay: 0.25s; }
.aif-ns-anim.is-in .aif-ns-patients__card:nth-child(3) { transition-delay: 0.40s; }
.aif-ns-anim.is-in .aif-ns-patients__card:nth-child(4) { transition-delay: 0.55s; }
.aif-ns-anim.is-in .aif-ns-feed__row:nth-child(1) { transition-delay: 0.05s; }
.aif-ns-anim.is-in .aif-ns-feed__row:nth-child(2) { transition-delay: 0.30s; }
.aif-ns-anim.is-in .aif-ns-feed__row:nth-child(3) { transition-delay: 0.55s; }
.aif-ns-anim.is-in .aif-ns-feed__row:nth-child(4) { transition-delay: 0.80s; }
@media (prefers-reduced-motion: reduce) {
    .aif-ns-anim .aif-ns-treatments__fill,
    .aif-ns-anim .aif-ns-stats__chart-fill { transition: none; }
    .aif-ns-anim .aif-ns-cal__hero,
    .aif-ns-anim .aif-ns-patients__hero,
    .aif-ns-anim .aif-ns-cadence__pill,
    .aif-ns-anim .aif-ns-audit__row,
    .aif-ns-anim .aif-ns-patients__card,
    .aif-ns-anim .aif-ns-feed__row,
    .aif-ns-anim .aif-ns-feed__compare { transition: none; transform: none; opacity: 1; }
    .aif-ns-anim.is-in .aif-ns-cal__cell--miss[data-recover="1"] { animation: none; }
}
