/* ============================================================
   app.css  —  Apple Health AI Agent page styles
   ============================================================ */

/* ── Page base ─────────────────────────────────────────────── */
.app-page {
    background: var(--lighter);
}

/* ── Base font: Manrope everywhere except the phone mockup ─── */
body,
.demo-section,
.app-hero,
.sources-section,
.privacy-section,
.demo-steps,
.step-item,
.step-title,
.step-desc,
.app-hero-text,
.app-hero-chips,
.ahc,
.sources-section *,
.privacy-section * {
    font-family: 'Playfair Display', Georgia, serif;
}

/* ── Phone mockup uses iOS system fonts, not the page font ─── */
.iphone16,
.iphone16-screen,
.iphone16 * {
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Helvetica Neue", Arial, sans-serif;
}



/* ── Hero ──────────────────────────────────────────────────── */
.app-hero {
    padding: 148px 24px 60px;
    max-width: 720px;
    margin: 0 auto;
    text-align: center;
}

.app-eyebrow {
    display: inline-block;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.1em;
    color: #7c3aed;
    text-transform: uppercase;
    margin-bottom: 20px;
}

.app-hero h1 {
    color: var(--text);
    margin-bottom: 20px;
}

.app-hero p {
    font-size: 1.125rem;
    max-width: 520px;
    margin: 0 auto 36px;
}

.app-hero-chips {
    display: flex;
    gap: 10px;
    justify-content: center;
    flex-wrap: wrap;
}

.ahc {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: white;
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 500;
    color: var(--text);
    box-shadow: var(--shadow);
}

.ahc-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
        transform: scale(1)
    }

    50% {
        opacity: 0.6;
        transform: scale(0.85)
    }
}

/* ── Demo section ──────────────────────────────────────────── */
.demo-section {
    padding: 0 24px 100px;
    max-width: 1200px;
    margin: 0 auto;
}

.demo-wrap {
    display: flex;
    gap: 64px;
    align-items: flex-start;
}

/* ── Step navigator (left) ─────────────────────────────────── */
.demo-steps {
    flex: 0 0 300px;
    position: sticky;
    top: 100px;
}

.demo-steps-label {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: rgba(100, 100, 130, 0.5);
    margin-bottom: 28px;
}

/* ── Steps track ─────────────────────────────────────────────── */
.steps-track {
    display: flex;
    flex-direction: column;
}

.step-item {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    cursor: pointer;
    position: relative;
    padding: 0 0 0 0;
}

/* ── Left node column: number badge + connecting line ────────── */
.step-node {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex-shrink: 0;
    width: 32px;
}

.step-num {
    width: 32px;
    height: 32px;
    border-radius: 10px;
    border: 1.5px solid rgba(0, 0, 0, 0.1);
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: 700;
    color: rgba(100, 100, 130, 0.45);
    letter-spacing: 0.02em;
    transition: all 0.25s ease;
    position: relative;
    z-index: 1;
}

.step-line {
    width: 1.5px;
    flex: 1;
    min-height: 20px;
    background: rgba(0, 0, 0, 0.08);
    margin: 4px 0;
    position: relative;
    overflow: hidden;
}

.step-line::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 0%;
    background: linear-gradient(180deg, #6366f1, #a78bfa);
    transition: height 0.4s ease;
}

/* ── Step content (right of the badge) ───────────────────────── */
.step-content {
    flex: 1;
    padding: 4px 0 24px;
    transition: all 0.25s;
}

.step-title {
    font-size: 13.5px;
    font-weight: 600;
    color: rgba(26, 26, 46, 0.4);
    margin-bottom: 3px;
    transition: color 0.25s;
    letter-spacing: -0.01em;
}

.step-desc {
    font-size: 12px;
    color: rgba(26, 26, 46, 0.35);
    line-height: 1.5;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.3s ease, opacity 0.3s ease;
}

/* ── Inactive hover ──────────────────────────────────────────── */
.step-item:hover .step-num {
    border-color: rgba(99, 102, 241, 0.3);
    color: rgba(99, 102, 241, 0.6);
}

/* ── Active step ─────────────────────────────────────────────── */
.step-item.active .step-num {
    background: linear-gradient(135deg, #6366f1, #a78bfa);
    border-color: transparent;
    color: white;
    box-shadow: 0 4px 14px rgba(99, 102, 241, 0.35);
}

.step-item.active .step-line::after {
    height: 100%;
}

.step-item.active .step-title {
    color: #1a1a2e;
    font-weight: 700;
}

.step-item.active .step-desc {
    max-height: 80px;
    opacity: 1;
    color: rgba(26, 26, 46, 0.55);
}

/* Passed steps (before active) */
.step-item.passed .step-num {
    background: rgba(99, 102, 241, 0.08);
    border-color: rgba(99, 102, 241, 0.2);
    color: #6366f1;
}

.step-item.passed .step-title {
    color: rgba(26, 26, 46, 0.55);
}

.step-item.passed .step-line::after {
    height: 100%;
}

/* ── Step nav buttons ────────────────────────────────────────── */
.step-nav {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 12px;
    padding-left: 48px;
}

.step-btn {
    border: 1.5px solid rgba(0, 0, 0, 0.1);
    background: white;
    border-radius: 999px;
    padding: 8px 20px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    font-family: var(--font);
    color: rgba(26, 26, 46, 0.5);
    transition: all 0.2s;
    letter-spacing: 0.01em;
}

.step-btn:hover:not(:disabled) {
    border-color: #6366f1;
    color: #6366f1;
    background: rgba(99, 102, 241, 0.04);
}

.step-btn:disabled {
    opacity: 0.3;
    cursor: default;
}

.step-btn--primary {
    background: linear-gradient(135deg, #6366f1, #a78bfa);
    color: white;
    border-color: transparent;
    box-shadow: 0 4px 14px rgba(99, 102, 241, 0.3);
}

.step-btn--primary:hover:not(:disabled) {
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
    transform: translateY(-1px);
    background: linear-gradient(135deg, #5457e0, #9f7afa);
    color: white;
}

.step-counter {
    font-size: 11px;
    font-weight: 600;
    color: rgba(26, 26, 46, 0.3);
    flex: 1;
    text-align: center;
    letter-spacing: 0.04em;
}

/* ── Phone mockup (right) ──────────────────────────────────── */
.demo-phone-wrap {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: sticky;
    top: 80px;
}

/* ── iPhone 16 frame ─────────────────────────────────────── */
.iphone16 {
    position: relative;
    width: 320px;
    /* iPhone 16 aspect ratio 19.5:9 → height ≈ 693px */
    height: 693px;
    background: linear-gradient(160deg, #3a3a3c 0%, #1c1c1e 40%, #2c2c2e 100%);
    border-radius: 50px;
    box-shadow:
        0 0 0 1.5px rgba(255, 255, 255, 0.18),
        /* inner highlight */
        0 0 0 3px #1a1a1a,
        /* gap */
        0 0 0 4.5px rgba(255, 255, 255, 0.08),
        /* outer rim */
        0 40px 100px rgba(0, 0, 0, 0.45),
        0 15px 35px rgba(0, 0, 0, 0.3);
    flex-shrink: 0;
}

/* Side buttons */
.iphone16-btn {
    position: absolute;
    background: linear-gradient(160deg, #3a3a3c, #1c1c1e);
    border-radius: 3px;
}

/* Action button (left top, small) */
.iphone16-action {
    left: -3px;
    top: 108px;
    width: 3.5px;
    height: 30px;
    border-radius: 2px 0 0 2px;
}

/* Volume up */
.iphone16-vol-up {
    left: -3px;
    top: 154px;
    width: 3.5px;
    height: 56px;
    border-radius: 2px 0 0 2px;
}

/* Volume down */
.iphone16-vol-down {
    left: -3px;
    top: 220px;
    width: 3.5px;
    height: 56px;
    border-radius: 2px 0 0 2px;
}

/* Power / side button (right) */
.iphone16-power {
    right: -3px;
    top: 170px;
    width: 3.5px;
    height: 78px;
    border-radius: 0 2px 2px 0;
}

/* Screen area */
.iphone16-screen {
    position: absolute;
    inset: 6px;
    background: #f5f5f7;
    border-radius: 45px;
    overflow: hidden;
}

/* Dynamic Island */
.iphone16-island {
    position: absolute;
    top: 12px;
    left: 50%;
    transform: translateX(-50%);
    width: 120px;
    height: 34px;
    background: #000;
    border-radius: 20px;
    z-index: 60;
    pointer-events: none;
}

/* ── iOS Lock Screen ─────────────────────────────────────────── */
.lock-screen {
    position: absolute;
    inset: 0;
    z-index: 50;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border-radius: 45px;
    transition: transform 0.55s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.45s ease;
    cursor: pointer;
    user-select: none;
}

.lock-screen.dismissed {
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
}

/* Wallpaper */
.lock-wallpaper {
    position: absolute;
    inset: 0;
    background-image: url('img/minimal-heroscreen-iphone-wallpaper-4k.jpg');
    background-size: cover;
    background-position: center;
    border-radius: 45px;
}

/* Gradient overlay for text legibility */
.lock-wallpaper::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(0,0,0,0.18) 0%,
        rgba(0,0,0,0.04) 25%,
        rgba(0,0,0,0.0) 50%,
        rgba(0,0,0,0.2) 72%,
        rgba(0,0,0,0.5) 100%
    );
    border-radius: 45px;
}

/* Status bar — time LEFT, icons RIGHT — sits level with the Dynamic Island */
.lock-statusbar {
    position: relative;
    z-index: 2;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 22px 0;
}

.lock-sb-time {
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', sans-serif;
    font-size: 15px;
    font-weight: 600;
    color: white;
    letter-spacing: -0.3px;
}

.lock-sb-icons {
    display: flex;
    align-items: center;
    gap: 5px;
}

/* Clock area — centered, date above big time */
.lock-clock-area {
    position: relative;
    z-index: 2;
    text-align: center;
    margin-top: 32px;
    padding: 0 16px;
}

.lock-clock-date {
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', sans-serif;
    font-size: 15px;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.92);
    letter-spacing: 0.01em;
    margin-bottom: 0;
}

.lock-clock-time {
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', sans-serif;
    font-size: 80px;
    font-weight: 200;
    color: white;
    letter-spacing: -4px;
    line-height: 1;
    text-shadow: 0 2px 24px rgba(0,0,0,0.25);
}

/* Notifications — push to lower half */
.lock-notifs {
    position: relative;
    z-index: 2;
    margin-top: auto;
    padding: 0 12px 10px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.lock-notif {
    background: rgba(30, 26, 50, 0.68);
    backdrop-filter: blur(28px) saturate(160%);
    -webkit-backdrop-filter: blur(28px) saturate(160%);
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 20px;
    padding: 12px 14px 12px;
    animation: notifSlideIn 0.6s 0.8s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

@keyframes notifSlideIn {
    from { transform: translateY(20px); opacity: 0; }
    to   { transform: translateY(0);    opacity: 1; }
}

.lock-notif-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
}

.lock-notif-icon {
    width: 24px;
    height: 24px;
    border-radius: 6px;
    overflow: hidden;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lock-notif-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 6px;
}

.lock-notif-app {
    font-family: -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 11.5px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.55);
    letter-spacing: 0.02em;
    flex: 1;
}

.lock-notif-time {
    font-family: -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.38);
}

.lock-notif-title {
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', sans-serif;
    font-size: 13.5px;
    font-weight: 600;
    color: #fff;
    margin-bottom: 3px;
}

.lock-notif-body {
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', sans-serif;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.65);
    line-height: 1.45;
    margin-bottom: 10px;
}

.lock-notif-actions {
    display: flex;
    gap: 8px;
}

.lock-pill {
    flex: 1;
    border: none;
    outline: none;
    border-radius: 999px;
    padding: 7px 0;
    cursor: pointer;
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', sans-serif;
    font-size: 12px;
    font-weight: 600;
    transition: opacity 0.15s, transform 0.1s;
}

.lock-pill:active {
    opacity: 0.8;
    transform: scale(0.97);
}

.lock-pill--secondary {
    background: rgba(255, 255, 255, 0.18);
    color: rgba(255, 255, 255, 0.85);
}

.lock-pill--primary {
    background: rgba(99, 102, 241, 0.85);
    color: #fff;
    flex: 1.2;
}

/* Bottom hint */
.lock-bottom-bar {
    position: relative;
    z-index: 2;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10px 28px 20px;
}

.lock-swipe-hint {
    font-family: -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.45);
    letter-spacing: 0.04em;
    animation: hintPulse 2s 1s ease-in-out infinite;
}

@keyframes hintPulse {

    0%,
    100% {
        opacity: 0.4;
    }

    50% {
        opacity: 0.85;
    }
}


/* ── Individual screens ─────────────────────────────────────── */
.screen {
    display: none;
    padding: 62px 16px 28px;
    /* 62px top clears Dynamic Island */
    background: #f5f5f7;
    height: 100%;
    box-sizing: border-box;
    overflow-y: auto;
}

.screen.active {
    display: block;
    animation: screenIn 0.32s cubic-bezier(0.4, 0, 0.2, 1) both;
}

.screen.prev {
    animation: screenOut 0.25s cubic-bezier(0.4, 0, 0.2, 1) both;
}

@keyframes screenIn {
    from {
        opacity: 0;
        transform: translateX(24px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes screenOut {
    from {
        opacity: 1;
        transform: translateX(0);
    }

    to {
        opacity: 0;
        transform: translateX(-24px);
    }
}

/* Screen header */
.screen-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 18px;
}

.sh-greeting {
    font-size: 15px;
    font-weight: 700;
    color: #111;
}

.sh-date {
    font-size: 11px;
    color: #8e8e93;
    margin-top: 2px;
}

.sh-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(135deg, #7c3aed, #a78bfa);
    color: white;
    font-size: 13px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.sh-share {
    font-size: 12px;
    color: #7c3aed;
    font-weight: 600;
    cursor: pointer;
}

/* Screen 0 — dashboard */
.status-ring-wrap {
    position: relative;
    display: flex;
    justify-content: center;
    margin-bottom: 18px;
}

.status-ring-center {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
}

.src-score {
    font-size: 1.8rem;
    font-weight: 900;
    color: #34C759;
}

.src-label {
    font-size: 10px;
    color: #8e8e93;
}

.dash-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-bottom: 14px;
}

.dash-card {
    background: white;
    border-radius: 14px;
    padding: 12px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
}

.dc-icon {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    margin-bottom: 8px;
}

.dc-val {
    font-size: 1.1rem;
    font-weight: 800;
    color: #111;
}

.dc-val span {
    font-size: 11px;
    font-weight: 500;
    color: #8e8e93;
}

.dc-label {
    font-size: 10px;
    color: #8e8e93;
    margin-top: 1px;
}

.dc-trend {
    font-size: 10px;
    font-weight: 600;
    margin-top: 4px;
}

.dc-trend.up {
    color: #34C759;
}

.dc-trend.neutral {
    color: #FF9500;
}

.agent-quiet {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(52, 199, 89, 0.08);
    border-radius: 999px;
    padding: 7px 12px;
    font-size: 11px;
    color: #34C759;
    font-weight: 500;
    margin-bottom: 14px;
}

.aq-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #34C759;
    animation: pulse 1.8s ease-in-out infinite;
    flex-shrink: 0;
}

.data-feed-label {
    font-size: 10px;
    font-weight: 700;
    color: #8e8e93;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 8px;
}

.data-feed {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.df-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 11px;
    color: #48484a;
    background: white;
    border-radius: 10px;
    padding: 8px 10px;
}

.df-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    flex-shrink: 0;
}

/* Screen 1 — baseline */
.baseline-intro {
    font-size: 12px;
    color: #48484a;
    line-height: 1.5;
    margin-bottom: 16px;
}

.baseline-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.bl-item {
    background: white;
    border-radius: 12px;
    padding: 10px 12px;
}

.bl-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
}

.bl-label {
    font-size: 11px;
    font-weight: 700;
    color: #111;
}

.bl-range {
    font-size: 10px;
    color: #8e8e93;
}

.bl-track {
    height: 5px;
    background: #f0f0f4;
    border-radius: 3px;
    position: relative;
    overflow: visible;
}

.bl-fill {
    position: absolute;
    height: 100%;
    border-radius: 3px;
    opacity: 0.4;
}

.bl-now {
    position: absolute;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: white;
    border: 2px solid #7c3aed;
    box-shadow: 0 0 0 2px rgba(124, 58, 237, 0.2);
}

.bl-footer {
    font-size: 10px;
    color: #8e8e93;
    text-align: center;
    margin-top: 14px;
}

/* Screen 2 — alert */
.alert-card {
    background: white;
    border-radius: 16px;
    padding: 14px;
    border: 1px solid rgba(245, 158, 11, 0.2);
    margin-bottom: 14px;
    box-shadow: 0 4px 20px rgba(245, 158, 11, 0.08);
}

.alert-card-header {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-bottom: 12px;
}

.alert-icon {
    font-size: 24px;
}

.alert-title {
    font-size: 13px;
    font-weight: 700;
    color: #111;
}

.alert-sub {
    font-size: 11px;
    color: #8e8e93;
}

.alert-signals {
    display: flex;
    flex-direction: column;
    gap: 7px;
    margin-bottom: 12px;
}

.sig-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.sig-bar-wrap {
    flex: 0 0 80px;
    height: 5px;
    background: #f0f0f4;
    border-radius: 3px;
    overflow: hidden;
}

.sig-bar {
    height: 100%;
    border-radius: 3px;
}

.sig-label {
    font-size: 11px;
    color: #48484a;
}

.sig-label strong {
    color: #111;
}

.alert-context {
    font-size: 11px;
    color: #8e8e93;
    line-height: 1.5;
}

.alert-message {
    display: flex;
    gap: 8px;
    align-items: flex-end;
    margin-bottom: 16px;
}

.am-avatar {
    font-size: 20px;
    flex-shrink: 0;
}

.am-bubble {
    background: #7c3aed;
    color: white;
    border-radius: 14px 14px 14px 4px;
    padding: 10px 12px;
    font-size: 12px;
    line-height: 1.5;
}

.alert-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.aa-btn {
    width: 100%;
    padding: 11px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 600;
    font-family: var(--font);
    border: 1px solid var(--border);
    background: white;
    color: var(--text);
    cursor: pointer;
    transition: all 0.2s;
}

.aa-btn--primary {
    background: #7c3aed;
    color: white;
    border-color: #7c3aed;
}

.aa-btn--primary:hover {
    background: #6d28d9;
}

.aa-btn:not(.aa-btn--primary):hover {
    background: var(--lighter);
}

/* Screen 3 — summary */
.brief-card {
    background: white;
    border-radius: 14px;
    padding: 14px;
    margin-bottom: 14px;
    border-left: 3px solid #7c3aed;
}

.brief-label {
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 0.12em;
    color: #7c3aed;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.brief-body {
    font-size: 12px;
    line-height: 1.6;
    color: #48484a;
}

.timeline-mini {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 16px;
}

.tm-row {
    display: flex;
    gap: 10px;
    align-items: flex-start;
}

.tm-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
    margin-top: 3px;
}

.tm-text {
    font-size: 11px;
    color: #48484a;
    line-height: 1.5;
}

.brief-action {
    background: white;
    border-radius: 14px;
    padding: 12px;
}

.ba-text {
    font-size: 12px;
    color: #48484a;
    margin-bottom: 10px;
}

.ba-btn {
    width: 100%;
}

/* Screen 4 — provider matching */
.filter-chips {
    display: flex;
    gap: 6px;
    margin-bottom: 14px;
    flex-wrap: wrap;
}

.fc {
    padding: 5px 12px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    background: white;
    border: 1px solid var(--border);
    color: var(--muted);
    transition: all 0.2s;
}

.fc.active {
    background: #7c3aed;
    color: white;
    border-color: #7c3aed;
}

.provider-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.provider-card {
    background: white;
    border-radius: 14px;
    padding: 12px;
    border: 1px solid var(--border);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    position: relative;
}

.provider-card--best {
    border-color: rgba(124, 58, 237, 0.25);
    box-shadow: 0 4px 16px rgba(124, 58, 237, 0.1);
}

.best-badge {
    font-size: 10px;
    font-weight: 700;
    color: #7c3aed;
    background: rgba(124, 58, 237, 0.1);
    border-radius: 6px;
    padding: 2px 7px;
    display: inline-block;
    margin-bottom: 8px;
}

.prov-top {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-bottom: 8px;
}

.prov-avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 12px;
    font-weight: 800;
    flex-shrink: 0;
}

.prov-name {
    font-size: 13px;
    font-weight: 700;
    color: #111;
}

.prov-spec {
    font-size: 10px;
    color: #8e8e93;
}

.prov-stars {
    font-size: 10px;
    color: #f59e0b;
    margin-top: 2px;
}

.prov-stars span {
    color: #8e8e93;
}

.prov-price {
    font-size: 14px;
    font-weight: 800;
    color: #111;
    margin-left: auto;
}

.prov-reason {
    font-size: 11px;
    color: #48484a;
    margin-bottom: 10px;
    line-height: 1.5;
}

.prov-btn {
    width: 100%;
    padding: 9px;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 700;
    font-family: var(--font);
    cursor: pointer;
    border: none;
    background: #7c3aed;
    color: white;
    transition: all 0.2s;
}

.prov-btn:hover {
    background: #6d28d9;
}

.prov-btn--ghost {
    background: transparent;
    border: 1px solid var(--border);
    color: var(--muted);
}

.prov-btn--ghost:hover {
    background: var(--lighter);
    color: var(--text);
}

/* Screen 5 — connected */
.booked-card {
    background: white;
    border-radius: 14px;
    padding: 14px;
    margin-bottom: 16px;
    border: 1px solid rgba(52, 199, 89, 0.2);
}

.booked-check {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #34C759;
    color: white;
    font-size: 13px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-left: auto;
    flex-shrink: 0;
}

.brief-shared {
    display: flex;
    gap: 10px;
    align-items: center;
    background: rgba(124, 58, 237, 0.06);
    border-radius: 10px;
    padding: 10px;
    margin-top: 10px;
}

.bs-icon {
    font-size: 20px;
}

.bs-title {
    font-size: 12px;
    font-weight: 700;
    color: #111;
}

.bs-sub {
    font-size: 10px;
    color: #8e8e93;
    line-height: 1.4;
    margin-top: 2px;
}

.followup-section {
    background: white;
    border-radius: 14px;
    padding: 12px;
    margin-bottom: 14px;
}

.fu-label {
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #8e8e93;
    margin-bottom: 10px;
}

.fu-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 11px;
    color: #48484a;
    margin-bottom: 7px;
}

.fu-check {
    width: 14px;
    height: 14px;
    border: 2px solid #d1d1d6;
    border-radius: 50%;
    flex-shrink: 0;
}

.agent-message {
    display: flex;
    gap: 8px;
    align-items: flex-end;
    margin-bottom: 14px;
}

.complete-status {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 11px;
    color: #34C759;
    font-weight: 600;
    justify-content: center;
}

.cs-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #34C759;
    animation: pulse 1.8s ease-in-out infinite;
}

/* Phone progress dots */
.phone-progress {
    display: flex;
    gap: 7px;
    margin-top: 18px;
}

.pp-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: rgba(124, 58, 237, 0.2);
    cursor: pointer;
    transition: all 0.3s;
}

.pp-dot.active {
    background: #7c3aed;
    width: 22px;
    border-radius: 4px;
}

/* ── Data Sources section — looping marquee ──────────────────── */
.sources-section {
    padding: 100px 0 80px;
    background: white;
    overflow: hidden;
}

/* Full-width strip that clips the scrolling track */
.sources-marquee-wrap {
    position: relative;
    width: 100%;
    overflow: hidden;
    margin-top: 56px;
    /* Edge fade masks */
    -webkit-mask-image: linear-gradient(to right,
            transparent 0%,
            black 8%,
            black 92%,
            transparent 100%);
    mask-image: linear-gradient(to right,
            transparent 0%,
            black 8%,
            black 92%,
            transparent 100%);
}

/* The scrolling inner track — wide enough to hold all cards + gap */
.sources-marquee {
    display: flex;
    gap: 20px;
    width: max-content;
    animation: marqueeScroll 40s linear infinite;
}

/* Pause on hover */
.sources-marquee-wrap:hover .sources-marquee {
    animation-play-state: paused;
}

@keyframes marqueeScroll {
    from {
        transform: translateX(0);
    }

    to {
        transform: translateX(-50%);
    }

    /* 50% = one full set */
}

/* Individual cards — full bleed image + glassmorphic text panel */
.source-card {
    position: relative;
    width: 280px;
    height: 360px;
    flex-shrink: 0;
    border-radius: 22px;
    overflow: hidden;
    cursor: default;
    transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1),
        box-shadow 0.35s ease;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.14), 0 1px 4px rgba(0, 0, 0, 0.06);
}

.source-card:hover {
    transform: translateY(-6px) scale(1.015);
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.22), 0 4px 12px rgba(0, 0, 0, 0.10);
}

/* Full-bleed background image */
.card-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform 0.5s ease;
}

.source-card:hover .card-bg {
    transform: scale(1.06);
}

/* Frosted glass text panel at the bottom */
.card-glass {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 16px 18px 18px;
    background: rgba(255, 255, 255, 0.72);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-top: 1px solid rgba(255, 255, 255, 0.85);
}

.card-glass h4 {
    font-size: 14px;
    font-weight: 700;
    color: #111118;
    margin-bottom: 4px;
    letter-spacing: -0.01em;
}

.card-glass p {
    font-size: 11.5px;
    color: rgba(17, 17, 24, 0.65);
    line-height: 1.5;
    margin-bottom: 10px;
}

.source-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

.source-tags span {
    font-size: 10px;
    font-weight: 700;
    color: #6366f1;
    background: rgba(99, 102, 241, 0.12);
    border-radius: 5px;
    padding: 2px 8px;
    letter-spacing: 0.01em;
}



/* ── Privacy section ─────────────────────────────────────────── */
.privacy-section {
    padding: 100px 0;
    background: var(--dark);
}

.privacy-inner {
    max-width: 640px;
    margin: 0 auto;
    text-align: center;
}

.priv-icon {
    font-size: 40px;
    margin-bottom: 20px;
    display: block;
}

.privacy-inner h2 {
    color: white;
    margin-bottom: 16px;
}

.privacy-inner p {
    color: rgba(255, 255, 255, 0.6);
    max-width: 480px;
    margin: 0 auto 36px;
}

.priv-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

.priv-tag {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 999px;
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.8);
}


/* ── Responsive ─────────────────────────────────────────────── */
@media (max-width: 900px) {
    .demo-wrap {
        flex-direction: column;
        align-items: center;
    }

    .demo-steps {
        position: static;
        flex: none;
        width: 100%;
        max-width: 500px;
    }

    .demo-phone-wrap {
        position: static;
    }

    .sources-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 600px) {
    .sources-grid {
        grid-template-columns: 1fr;
    }

    .demo-phone {
        width: 290px;
    }
}

/* ═══════════════════════════════════════════════════════════════
   Light-style AI chat screens (Dribbble-inspired)
   ═══════════════════════════════════════════════════════════════ */

/* ── Screen base resets (override the default grey bg) ───────── */
.screen {
    padding: 0;
    background: transparent;
    position: relative;
    display: flex;
    flex-direction: column;
}

.screen.active {
    display: flex;
}

/* ── Misty gradient phone background ─────────────────────────── */
.lc-bg {
    position: absolute;
    inset: 0;
    background: linear-gradient(160deg, #dde1ea 0%, #cfd3e0 40%, #d8d5e8 100%);
    z-index: 0;
}

.lc-bg--blue {
    background: linear-gradient(160deg, #dde8f0 0%, #cfdae8 40%, #d5ddf4 100%);
}

.lc-bg--amber {
    background: linear-gradient(160deg, #f0ebe0 0%, #e8dece 40%, #f0e2c8 100%);
}

.lc-bg--purple {
    background: linear-gradient(160deg, #e5dff0 0%, #d8d0ec 40%, #ded5f0 100%);
}

.lc-bg--teal {
    background: linear-gradient(160deg, #ddf0ec 0%, #cfe8e4 40%, #d0eae8 100%);
}

.lc-bg--green {
    background: linear-gradient(160deg, #ddf0e4 0%, #cfe8d8 40%, #d8ede0 100%);
}

/* ── Iridescent orb (CSS-only, animates hue every screen) ────── */
.lc-orb {
    position: absolute;
    top: -60px;
    left: 50%;
    transform: translateX(-50%);
    width: 260px;
    height: 260px;
    border-radius: 50%;
    background: conic-gradient(from 0deg,
            #a78bfa, #818cf8, #38bdf8, #34d399, #fbbf24, #f87171, #c084fc, #a78bfa);
    filter: blur(28px) saturate(1.4);
    opacity: 0.52;
    animation: orbSpin 8s linear infinite;
    z-index: 1;
    pointer-events: none;
}

.lc-orb--blue {
    background: conic-gradient(from 0deg, #38bdf8, #818cf8, #6366f1, #38bdf8);
    opacity: 0.48;
}

.lc-orb--amber {
    background: conic-gradient(from 0deg, #f59e0b, #f87171, #fbbf24, #f59e0b);
    opacity: 0.45;
}

.lc-orb--purple {
    background: conic-gradient(from 0deg, #a78bfa, #c084fc, #818cf8, #a78bfa);
    opacity: 0.5;
}

.lc-orb--teal {
    background: conic-gradient(from 0deg, #34d399, #38bdf8, #06b6d4, #34d399);
    opacity: 0.45;
}

.lc-orb--green {
    background: conic-gradient(from 0deg, #34d399, #4ade80, #86efac, #34d399);
    opacity: 0.45;
}

.lc-orb--green-soft {
    background: conic-gradient(from 0deg, #86efac, #34C759, #4ade80, #86efac);
    opacity: 0.4;
}

@keyframes orbSpin {
    from {
        transform: translateX(-50%) rotate(0deg);
    }

    to {
        transform: translateX(-50%) rotate(360deg);
    }
}

/* ── All content above the orb ───────────────────────────────── */
.lc-greeting,
.lc-card,
.lc-user-msg,
.lc-user-msg--top,
.lc-card-meta,
.lc-action-btns,
.lc-input-bar,
.prov2-card {
    position: relative;
    z-index: 2;
}

/* ── Greeting (screen 0, 2, 5 — shown when no user query) ────── */
.lc-greeting {
    margin-top: 160px;
    padding: 0 20px 10px;
    text-align: center;
}

.lc-hello {
    font-size: 20px;
    font-weight: 700;
    color: #1a1a2e;
    letter-spacing: -0.4px;
    line-height: 1.25;
}

.lc-hello--alert {
    color: #92400e;
}

.lc-hello--ok {
    color: #14532d;
}

.lc-sub {
    font-size: 12px;
    color: rgba(26, 26, 46, 0.5);
    margin-top: 4px;
}

/* ── User message pill (right-aligned glass bubble) ──────────── */
.lc-user-msg {
    align-self: flex-end;
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.9);
    border-radius: 18px 18px 4px 18px;
    font-size: 12px;
    font-weight: 500;
    color: #1a1a2e;
    padding: 8px 14px;
    margin: 0 14px 8px auto;
    max-width: 75%;
}

.lc-user-msg--top {
    margin-top: 140px;
    margin-bottom: 6px;
}

/* ── Generation meta label ───────────────────────────────────── */
.lc-card-meta {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.04em;
    color: rgba(100, 100, 140, 0.7);
    text-align: left;
    padding: 0 16px 6px;
}

.lc-card-meta--top {
    padding-top: 0;
}

/* ── White glass content card ────────────────────────────────── */
.lc-card {
    background: rgba(255, 255, 255, 0.72);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.95);
    border-radius: 18px;
    padding: 14px 14px 12px;
    margin: 0 12px 10px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.08);
}

.lc-card--alert {
    border-color: rgba(251, 191, 36, 0.3);
    box-shadow: 0 4px 24px rgba(245, 158, 11, 0.12);
}

.lc-card--success {
    border-color: rgba(52, 199, 89, 0.3);
    box-shadow: 0 4px 24px rgba(52, 199, 89, 0.12);
}

.lc-card-title {
    font-size: 12px;
    font-weight: 700;
    color: #1a1a2e;
    margin-bottom: 10px;
}

/* ── Score ring row ─────────────────────────────────────────── */
.lc-score-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
}

.lc-score-ring {
    position: relative;
    flex-shrink: 0;
}

.lc-score-val {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    font-weight: 800;
    color: #34C759;
}

.lc-vitals {
    flex: 1;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5px 10px;
}

.lc-vital {
    display: flex;
    align-items: center;
    gap: 5px;
}

.lc-vdot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    flex-shrink: 0;
}

.lc-vv {
    font-size: 11px;
    font-weight: 600;
    color: #1a1a2e;
}

.lc-vl {
    font-size: 10px;
    color: rgba(26, 26, 46, 0.45);
    margin-left: 1px;
}

/* ── Data tags row ─────────────────────────────────────────── */
.lc-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-top: 6px;
}

.lc-tag {
    font-size: 10px;
    font-weight: 600;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 999px;
    padding: 3px 9px;
    border: 1px solid rgba(255, 255, 255, 0.9);
}

/* ── Baseline bars ─────────────────────────────────────────── */
.bl2-item {
    margin-bottom: 9px;
}

.bl2-label {
    display: flex;
    justify-content: space-between;
    font-size: 10.5px;
    font-weight: 600;
    color: #1a1a2e;
    margin-bottom: 4px;
}

.bl2-label span {
    font-weight: 400;
    color: rgba(26, 26, 46, 0.5);
}

.bl2-track {
    position: relative;
    height: 6px;
    background: rgba(0, 0, 0, 0.07);
    border-radius: 99px;
    overflow: visible;
}

.bl2-fill {
    position: absolute;
    top: 0;
    height: 100%;
    border-radius: 99px;
    opacity: 0.75;
}

.bl2-now {
    position: absolute;
    top: -3px;
    width: 12px;
    height: 12px;
    background: white;
    border: 2px solid #6366f1;
    border-radius: 50%;
    transform: translateX(-50%);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.15);
}

.bl2-legend {
    font-size: 9px;
    color: rgba(26, 26, 46, 0.4);
    margin-top: 8px;
    text-align: center;
}

/* ── Alert bars ────────────────────────────────────────────── */
.alert2-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 7px;
}

.a2-bar-wrap {
    flex: 1;
    height: 6px;
    background: rgba(0, 0, 0, 0.07);
    border-radius: 99px;
    overflow: hidden;
}

.a2-bar {
    height: 100%;
    border-radius: 99px;
}

.a2-label {
    font-size: 10px;
    font-weight: 500;
    color: #1a1a2e;
    white-space: nowrap;
    min-width: 80px;
}

.a2-note {
    font-size: 10px;
    color: rgba(26, 26, 46, 0.55);
    margin-top: 8px;
}

/* ── Brief timeline ─────────────────────────────────────────── */
.brief2-body {
    font-size: 11.5px;
    color: #1a1a2e;
    line-height: 1.5;
}

.brief2-timeline {
    margin-top: 10px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.bt-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.bt-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    flex-shrink: 0;
}

.bt-text {
    font-size: 10.5px;
    color: #1a1a2e;
}

/* ── Provider cards (light style) ───────────────────────────── */
.prov2-card {
    background: rgba(255, 255, 255, 0.72);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.95);
    border-radius: 16px;
    padding: 12px 12px 10px;
    margin: 0 12px 8px;
    box-shadow: 0 3px 16px rgba(0, 0, 0, 0.07);
}

.prov2-card--best {
    border-color: rgba(99, 102, 241, 0.25);
}

.prov2-badge {
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.06em;
    color: #6366f1;
    margin-bottom: 6px;
}

.prov2-row {
    display: flex;
    align-items: center;
    gap: 9px;
}

.prov2-av {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: 700;
    color: white;
    flex-shrink: 0;
}

.prov2-info {
    flex: 1;
}

.prov2-name {
    font-size: 11.5px;
    font-weight: 700;
    color: #1a1a2e;
}

.prov2-spec {
    font-size: 9.5px;
    color: rgba(26, 26, 46, 0.5);
    margin-top: 1px;
}

.prov2-price {
    font-size: 13px;
    font-weight: 800;
    color: #1a1a2e;
}

.prov2-note {
    font-size: 10px;
    color: rgba(26, 26, 46, 0.55);
    margin-top: 7px;
}

/* ── Action buttons ─────────────────────────────────────────── */
.lc-action-btns {
    display: flex;
    gap: 8px;
    padding: 0 12px 8px;
}

.lc-btn-primary {
    background: #1a1a2e;
    color: white;
    border: none;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 600;
    padding: 9px 18px;
    cursor: pointer;
    transition: opacity 0.15s;
}

.lc-btn-primary:hover {
    opacity: 0.8;
}

.lc-btn-ghost {
    background: rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: 999px;
    font-size: 11px;
    font-weight: 600;
    color: #1a1a2e;
    padding: 9px 18px;
    cursor: pointer;
    backdrop-filter: blur(8px);
    transition: opacity 0.15s;
}

.lc-btn-ghost:hover {
    opacity: 0.75;
}

/* ── Floating input bar ──────────────────────────────────────── */
.lc-input-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: auto 12px 14px;
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.9);
    border-radius: 999px;
    padding: 8px 8px 8px 16px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.lc-prompt {
    flex: 1;
    font-size: 11.5px;
    color: rgba(26, 26, 46, 0.4);
}

.lc-send {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(135deg, #6366f1, #a78bfa);
    color: white;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: transform 0.15s;
    line-height: 1;
}

.lc-send:hover {
    transform: scale(1.08);
}

/* ── Booked tick / brief shared ─────────────────────────────── */
.booked-tick {
    width: 26px;
    height: 26px;
    background: #34C759;
    border-radius: 50%;
    color: white;
    font-size: 13px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.brief-shared2 {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 10.5px;
    color: rgba(26, 26, 46, 0.6);
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid rgba(0, 0, 0, 0.06);
}

/* ── Follow-up items ─────────────────────────────────────────── */
.fu2-item {
    font-size: 11px;
    color: rgba(26, 26, 46, 0.65);
    padding: 4px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.fu2-item:last-child {
    border-bottom: none;
}

/* ═══════════════════════════════════════════════════════════════
   Chat conversation system — Alison AI
   ═══════════════════════════════════════════════════════════════ */

/* ── Phone screen layout ────────────────────────────────────── */
.iphone16-screen {
    display: flex;
    flex-direction: column;
}

/* ── Animated background & orb for the chat screen ─────────── */
.chat-lc-bg {
    position: absolute;
    inset: 0;
    background: linear-gradient(160deg, #ddf0e4, #cfe8d8, #d8ede0);
    transition: background 1s ease;
    z-index: 0;
}

.chat-lc-orb {
    position: absolute;
    top: -60px;
    left: 50%;
    transform: translateX(-50%);
    width: 280px;
    height: 280px;
    border-radius: 50%;
    background: conic-gradient(from 0deg, #34d399, #4ade80, #86efac, #34d399);
    filter: blur(30px) saturate(1.4);
    opacity: 0.48;
    animation: orbSpin 10s linear infinite;
    z-index: 1;
    pointer-events: none;
    transition: background 1s ease;
}

/* ── Chat thread ─────────────────────────────────────────────── */
.chat-thread {
    position: relative;
    z-index: 2;
    flex: 1;
    overflow-y: auto;
    padding: 68px 10px 6px;
    /* 68px clears Dynamic Island */
    display: flex;
    flex-direction: column;
    gap: 6px;
    scroll-behavior: smooth;
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.chat-thread::-webkit-scrollbar {
    display: none;
}

/* ── Message row ─────────────────────────────────────────────── */
.msg-row {
    display: flex;
    align-items: flex-end;
    gap: 6px;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.msg-row.msg-in {
    opacity: 1;
    transform: translateY(0);
}

.msg-row--user {
    flex-direction: row-reverse;
}

.msg-row--alison {
    flex-direction: row;
}

/* ── Avatars ─────────────────────────────────────────────────── */
.msg-avatar {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 700;
}

.msg-avatar--alison {
    background: linear-gradient(135deg, #6366f1, #a78bfa);
    color: white;
    font-size: 10px;
}

.msg-avatar--user {
    background: linear-gradient(135deg, #1a1a2e, #3a3a5c);
    color: white;
    font-size: 11px;
}

.msg-avatar--invis {
    opacity: 0;
    pointer-events: none;
}

/* ── Bubbles ─────────────────────────────────────────────────── */
.msg-bubble {
    max-width: 78%;
    padding: 9px 13px;
    border-radius: 18px;
    font-size: 12px;
    line-height: 1.45;
    font-weight: 400;
}

.msg-bubble--alison {
    background: rgba(255, 255, 255, 0.82);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.95);
    color: #1a1a2e;
    border-bottom-left-radius: 5px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.msg-bubble--user {
    background: #1a1a2e;
    color: rgba(255, 255, 255, 0.95);
    border-bottom-right-radius: 5px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.18);
}

/* ── Rich card (inline content card attached to Alison msg) ─── */
.msg-card {
    max-width: calc(100% - 38px);
    background: rgba(255, 255, 255, 0.82);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.95);
    border-radius: 16px;
    border-bottom-left-radius: 5px;
    padding: 12px 13px 10px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.09);
}

/* When a gradient card sits inside msg-card, strip the wrapper */
.msg-card:has(.notify-card) {
    background: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border: none;
    border-radius: 0;
    padding: 0;
    box-shadow: none;
}

/* ── Gradient notification card (banking-card style) ────────── */
.notify-card {
    background: linear-gradient(135deg, #b57bee 0%, #c97bbf 35%, #d4836e 70%, #e8a96a 100%);
    border-radius: 20px;
    padding: 16px 18px 14px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 110px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 8px 28px rgba(181, 123, 238, 0.35);
}

.notify-card::before {
    content: '';
    position: absolute;
    top: -30px;
    right: -20px;
    width: 130px;
    height: 130px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    pointer-events: none;
}

.notify-card::after {
    content: '';
    position: absolute;
    bottom: -40px;
    left: 30px;
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.07);
    pointer-events: none;
}

.nc-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    position: relative;
    z-index: 1;
}

.nc-title {
    font-size: 15px;
    font-weight: 700;
    color: #fff;
    letter-spacing: -0.2px;
    line-height: 1.2;
}

.nc-sub {
    font-size: 10.5px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.72);
    letter-spacing: 0.08em;
    margin-top: 2px;
}

.nc-badge {
    background: rgba(255, 255, 255, 0.22);
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 999px;
    padding: 3px 10px;
    font-size: 11px;
    font-weight: 600;
    color: #fff;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.nc-bottom {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    position: relative;
    z-index: 1;
}

.nc-value {
    font-size: 34px;
    font-weight: 300;
    color: #fff;
    letter-spacing: -1.5px;
    line-height: 1;
}

.nc-brand {
    font-size: 14px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.9);
    letter-spacing: 0.06em;
}

.nc-actions {
    display: flex;
    gap: 8px;
    margin-top: 12px;
    position: relative;
    z-index: 1;
}

.nc-btn {
    flex: 1;
    border-radius: 999px;
    padding: 7px 0;
    text-align: center;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
}

.nc-btn--ghost {
    background: rgba(255, 255, 255, 0.18);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: rgba(255, 255, 255, 0.85);
}

.nc-btn--solid {
    background: rgba(255, 255, 255, 0.92);
    color: #b57bee;
}

/* ── Typing indicator dots ───────────────────────────────────── */
.typing-dots {
    display: flex;
    align-items: center;
    gap: 4px;
    background: rgba(255, 255, 255, 0.82);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.95);
    border-radius: 18px;
    border-bottom-left-radius: 5px;
    padding: 10px 14px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    opacity: 1;
}

.typing-dots span {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: rgba(99, 102, 241, 0.6);
    animation: dotBounce 1.2s ease-in-out infinite;
}

.typing-dots span:nth-child(2) {
    animation-delay: 0.2s;
}

.typing-dots span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes dotBounce {

    0%,
    60%,
    100% {
        transform: translateY(0);
        opacity: 0.5;
    }

    30% {
        transform: translateY(-6px);
        opacity: 1;
    }
}

/* ── iOS keyboard simulation ────────────────────────────────── */
.ios-keyboard {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 10;
    background: rgba(210, 213, 222, 0.97);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: 0 0 48px 48px;
    padding: 8px 6px 16px;
    transform: translateY(100%);
    transition: transform 0.28s cubic-bezier(0.4, 0, 0.2, 1);
}

.ios-keyboard.kb-visible {
    transform: translateY(0);
}

/* Typing bar inside keyboard */
.ios-kb-bar {
    display: flex;
    align-items: center;
    gap: 6px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 12px;
    padding: 7px 8px 7px 12px;
    margin-bottom: 8px;
    border: 1px solid rgba(255, 255, 255, 0.9);
}

.ios-kb-typing {
    flex: 1;
    font-size: 12px;
    color: #1a1a2e;
    min-height: 16px;
    font-family: inherit;
    letter-spacing: 0.01em;
    word-break: break-word;
}

.ios-kb-send {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: none;
    background: rgba(180, 182, 195, 0.7);
    color: white;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
    flex-shrink: 0;
}

.ios-kb-send.kb-send-ready {
    background: #6366f1;
}

/* Keyboard rows */
.ios-kb-keys {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.ios-kb-row {
    display: flex;
    justify-content: center;
    gap: 4px;
}

.ios-kb-row span {
    background: rgba(255, 255, 255, 0.9);
    border-radius: 5px;
    height: 34px;
    min-width: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 500;
    color: #1a1a2e;
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.25);
    flex: 1;
    max-width: 28px;
    cursor: default;
    user-select: none;
}

.ios-kb-wide {
    max-width: 40px !important;
    font-size: 11px !important;
    background: rgba(178, 181, 195, 0.8) !important;
}

.ios-kb-space {
    max-width: 130px !important;
}

.ios-kb-ret {
    max-width: 80px !important;
}

.ios-kb-bottom {
    gap: 5px;
}

/* ── Input bar z-index fix for chat ────────────────────────── */
#chatInputBar {
    position: relative;
    z-index: 3;
    margin: 4px 10px 12px;
    flex-shrink: 0;
}

/* ── Score ring in cards ────────────────────────────────────── */
.cc-score-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
}

.cc-score-ring {
    position: relative;
    flex-shrink: 0;
}

.cc-score-val {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    font-weight: 800;
    color: #34C759;
}