.catfish-lens-wrapper {
    max-width: 600px;
    margin: 0 auto;
    font-family: 'Inter', sans-serif;
}

.cl-dropzone {
    border: 2px dashed #CBD5E1;
    border-radius: 12px;
    padding: 3rem 2rem;
    text-align: center;
    background: #F8FAFC;
    cursor: pointer;
    transition: all 0.2s ease;
}

.cl-dropzone:hover, .cl-dropzone.dragover {
    border-color: #FF4B4B;
    background: #FEF2F2;
}

.cl-dropzone-content svg {
    color: #94A3B8;
    margin-bottom: 1rem;
}

.cl-dropzone h3 {
    margin: 0 0 0.5rem 0;
    color: #1E293B;
    font-size: 1.25rem;
}

.cl-dropzone p {
    margin: 0;
    color: #64748B;
}

/* Scanning UI */
.cl-scanning-ui {
    text-align: center;
    padding: 2rem 0;
}

.cl-scan-comparison-wrap {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1.5rem;
    margin: 0 auto 1.5rem;
}

.cl-scanner {
    position: relative;
    width: 200px;
    height: 200px;
    margin: 0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

.cl-scanner img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cl-match-box-wrap {
    position: relative;
    width: 200px;
    height: 200px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    background: #e2e8f0;
}

.cl-match-box-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(8px);
    transition: opacity 0.4s ease;
}

.cl-match-overlay-text {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    background: rgba(0,0,0,0.6);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.35rem 0;
    text-align: center;
    backdrop-filter: blur(4px);
    letter-spacing: 0.05em;
    text-transform: uppercase;
    z-index: 10;
}

.cl-comparison-divider {
    display: flex;
    align-items: center;
    justify-content: center;
}

.cl-scanner-bar {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: #FF4B4B;
    box-shadow: 0 0 15px 5px rgba(255, 75, 75, 0.4);
    animation: scan 2s infinite linear;
}

@keyframes scan {
    0% { top: 0; opacity: 0; }
    10% { opacity: 1; }
    90% { opacity: 1; }
    100% { top: 100%; opacity: 0; }
}

/* ====== 5-Step Scan Engine ====== */
.cl-scan-engine {
    padding: 0 0.25rem;
    max-width: 480px;
    margin: 0 auto;
}

/* Step indicator row */
.cl-steps-nav {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    margin-bottom: 1.1rem;
}
.cl-step-node {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.3rem;
    flex-shrink: 0;
    width: 44px;
}
.cl-step-circle {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #E2E8F0;
    color: #94A3B8;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
    transition: all 0.35s cubic-bezier(0.4,0,0.2,1);
    position: relative;
}
.cl-step-node.active .cl-step-circle {
    background: #FF4B4B;
    color: #fff;
    box-shadow: 0 0 0 5px rgba(255,75,75,0.15);
    transform: scale(1.12);
}
.cl-step-node.done .cl-step-circle {
    background: #10B981;
    color: #fff;
    transform: scale(1);
}
.cl-step-lbl {
    font-size: 0.58rem;
    font-weight: 600;
    color: #CBD5E1;
    text-align: center;
    letter-spacing: 0.02em;
    transition: color 0.3s;
    white-space: nowrap;
}
.cl-step-node.active .cl-step-lbl { color: #FF4B4B; }
.cl-step-node.done .cl-step-lbl   { color: #10B981; }

.cl-step-line {
    flex: 1;
    height: 2px;
    margin-top: 15px; /* align with circle center */
    border-radius: 1px;
    background: #E2E8F0;
    transition: background 0.5s ease;
    min-width: 8px;
}
.cl-step-line.filled { background: #10B981; }

/* Current step panel */
.cl-step-panel {
    background: #F8FAFC;
    border: 1px solid #E2E8F0;
    border-radius: 12px;
    padding: 1rem 1.1rem;
    margin-bottom: 0.85rem;
}
.cl-step-header {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    margin-bottom: 0.45rem;
    flex-wrap: wrap;
}
.cl-step-badge {
    font-size: 0.65rem;
    font-weight: 700;
    color: #FF4B4B;
    background: rgba(255,75,75,0.09);
    padding: 0.18rem 0.55rem;
    border-radius: 999px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    white-space: nowrap;
    flex-shrink: 0;
}
.cl-step-name {
    font-size: 0.9rem;
    font-weight: 700;
    color: #0F172A;
}
.cl-step-detail {
    font-size: 0.8rem;
    color: #64748B;
    margin: 0 0 0.75rem 0;
    font-style: italic;
    min-height: 1.1em;
    transition: opacity 0.2s ease;
}
.cl-step-progress {
    height: 6px;
    background: #E2E8F0;
    border-radius: 999px;
    overflow: hidden;
}
.cl-step-progress-bar {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #FF4B4B, #FF8C8C);
    border-radius: 999px;
    transition: width 0.12s linear;
}

/* --- Advanced Data Mining UI Effects --- */
.cl-live-stats {
    display: flex;
    justify-content: space-between;
    margin-top: 1rem;
    padding: 0.5rem 0.75rem;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    color: #475569;
}
.cl-stat-label span {
    font-family: monospace;
    font-size: 0.85rem;
    display: inline-block;
    min-width: 60px;
    text-align: right;
}

.cl-terminal-log {
    margin-top: 0.75rem;
    background: transparent;
    color: #64748b;
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
    height: 95px;
    overflow: hidden;
    position: relative;
    line-height: 1.4;
    text-align: left;
}

.cl-terminal-line {
    opacity: 0.6;
    margin: 0 !important;
    padding: 2px 0 !important;
}
.cl-terminal-line:last-child {
    opacity: 1;
    color: #10b981;
    font-weight: bold;
}

    /* Removed separate overall wrap */

.cl-progress {
    width: 100%;
    max-width: 300px;
    margin: 0 auto 1.5rem;
    height: 8px;
    background: #E2E8F0;
    border-radius: 9999px;
    overflow: hidden;
}

.cl-progress-bar {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #FF4B4B, #FF7B7B);
    border-radius: 9999px;
    transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}


/* Results */
.cl-matches-container {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

/* App Icon Row — continuously scrolling marquee of platform icons */
.cl-scan-icons-wrap {
    position: relative;
    z-index: 10;
    margin: -0.25rem auto 0.75rem;
    width: 100%;
    overflow: hidden;
    min-height: 46px;
    /* Gradient mask to fade edges */
    -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 10%, #000 90%, transparent 100%);
    mask-image: linear-gradient(90deg, transparent 0%, #000 10%, #000 90%, transparent 100%);
}

.cl-icon-group {
    display: none;
}
.cl-icon-group.active {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: max-content;
    animation: marqueeScroll 12s linear infinite;
}

.cl-app-icon {
    width: 36px;
    height: 36px;
    min-width: 36px;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-family: 'Inter', sans-serif;
    font-weight: 800;
    font-size: 0.6rem;
    letter-spacing: -0.02em;
    box-shadow: 0 2px 8px rgba(0,0,0,0.18);
    overflow: hidden;
    line-height: 1;
    text-align: center;
    flex-shrink: 0;
}

.cl-app-icon span {
    font-size: 1.05rem;
    line-height: 1;
}

@keyframes marqueeScroll {
    0%   { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* ================= Results & Paywall UI ================= */
.cl-results-ui {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.08);
    overflow: hidden;
    position: relative;
    padding-bottom: 2rem;
}

/* 1. Combined Header */
.cl-results-header-combined {
    background: #fff;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid #e2e8f0;
}
.cl-rh-left, .cl-rh-right {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex: 1;
}
.cl-rh-left { justify-content: flex-start; }
.cl-rh-right { justify-content: flex-end; }
.cl-rh-divider {
    width: 1px;
    height: 60px;
    background: #e2e8f0;
    margin: 0 0.5rem;
}

/* Matches Side */
.cl-results-target-wrap {
    width: 60px; height: 60px;
    border-radius: 12px;
    overflow: hidden;
    flex-shrink: 0;
    position: relative;
    border: 2px solid #e2e8f0; /* Color will be dynamically set by JS */
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}
.cl-results-target-wrap img {
    width: 100%; height: 100%;
    object-fit: cover;
    filter: blur(4px);
    transform: scale(1.1);
}
.cl-rh-matches-text h3 {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 800;
    color: #1e293b;
    line-height: 1.2;
}
.cl-highlight-count { color: #e11d48; font-size: 1.25rem; }
.cl-rh-sub {
    font-size: 0.75rem;
    color: #64748B;
    margin-top: 0.2rem;
    font-weight: 500;
}

/* Risk Meter Side */
.cl-risk-meter {
    position: relative;
    width: 60px; height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.cl-risk-pulse {
    position: absolute; inset: 0;
    border-radius: 50%; background: #e11d48; opacity: 0.2;
    animation: cl-pulse 2s infinite;
}
@keyframes cl-pulse {
    0% { transform: scale(0.95); opacity: 0.4; }
    50% { transform: scale(1.25); opacity: 0; }
    100% { transform: scale(0.95); opacity: 0; }
}
.cl-risk-circle {
    position: relative;
    width: 50px; height: 50px;
    background: #fff;
    border: 4px solid #e11d48;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    z-index: 2; color: #e11d48;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}
.cl-risk-value { font-size: 1.15rem; font-weight: 800; line-height: 1; }
.cl-rh-risk-text { text-align: left; }
.cl-risk-title { font-size: 0.95rem; font-weight: 800; color: #1e293b; margin: 0;}
.cl-risk-title span { color: #e11d48; }

/* Summary Text below combined header */
.cl-results-summary-text {
    padding: 1rem 1.5rem;
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    font-size: 0.8rem;
    color: #475569;
    line-height: 1.5;
    text-align: left;
}

/* 2. Blurred Masonry Teaser */
.cl-matches-teaser {
    padding: 2rem 1.5rem;
    position: relative;
}
.cl-teaser-title {
    font-size: 1.1rem;
    color: #1e293b;
    margin-bottom: 1rem;
    text-align: left;
    font-weight: 800;
}
.cl-teaser-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}
.cl-teaser-box {
    border-radius: 12px;
    overflow: hidden;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 6px rgba(0,0,0,0.04);
    display: flex;
    flex-direction: column;
}
.cl-teaser-img {
    height: 130px;
    background-size: cover;
    background-position: center;
    filter: blur(10px) brightness(0.95);
    transform: scale(1.15); /* hides blur artifact edges */
}
.cl-teaser-meta {
    padding: 0.75rem;
    text-align: left;
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    background: #fff;
    position: relative;
    z-index: 2;
}
.cl-meta-platform { font-size: 0.7rem; font-weight: 700; color: #334155; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cl-meta-match { font-size: 0.65rem; font-weight: 800; color: #10b981; text-transform: uppercase;}



/* IP-Based Information Box */
.cl-ip-security-notice {
    margin: 1.5rem 1.5rem 0.5rem;
    background: #eff6ff;
    border: 1px solid #bfdbfe;
    border-radius: 8px;
    padding: 1rem;
    display: flex;
    gap: 1rem;
    align-items: flex-start;
}
.cl-ip-shield {
    color: #3b82f6;
    flex-shrink: 0;
    margin-top: 0.1rem;
}
.cl-ip-text {
    font-size: 0.75rem;
    color: #1e3a8a;
    line-height: 1.5;
    text-align: left;
}
.cl-ip-headline {
    font-weight: 800;
    font-size: 0.85rem;
    margin-bottom: 0.2rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}
.cl-ip-timer { color: #e11d48; font-family: monospace; font-size: 0.85rem; }

/* Bottom Teaser Gradient */
.cl-tease-gradient-bottom {
    position: absolute;
    bottom: 0; left: 0; right: 0; height: 60px;
    background: linear-gradient(to top, rgba(255,255,255,1), rgba(255,255,255,0));
    pointer-events: none;
    z-index: 5;
}

/* 3. Direct Unlock Action */
.cl-direct-unlock-wrap {
    padding: 0 1.5rem 1.5rem;
    text-align: left;
    background: #fff;
    position: relative;
    z-index: 10;
}
.cl-paywall-bullets {
    text-align: left;
    list-style: none;
    padding: 0;
    margin: 0 0 1.5rem 0;
}
.cl-paywall-bullets li {
    font-size: 0.85rem;
    font-weight: 500;
    color: #475569;
    margin-bottom: 0.6rem;
    display: flex;
    gap: 0.5rem;
    align-items: flex-start;
}
.cl-paywall-btn {
    display: block;
    width: 100%;
    padding: 1rem;
    background: linear-gradient(135deg, #10b981, #059669);
    color: #fff;
    font-weight: 800;
    font-size: 1.1rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(16, 185, 129, 0.4);
    text-decoration: none;
    transition: transform 0.2s, box-shadow 0.2s;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    text-align: center;
}
.cl-paywall-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.5);
}

.cl-btn {
    display: block;
    width: 100%;
    padding: 1rem;
    background: #F1F5F9;
    color: #475569;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
    font-size: 1rem;
}

#cl-reset-btn {
    background: transparent;
    border: 1px solid #CBD5E1;
    color: #64748B;
    margin: 1rem 1.5rem 0;
    width: calc(100% - 3rem);
}
@media (max-width: 480px) {
    #cl-reset-btn {
        margin: 1rem 1rem 0;
        width: calc(100% - 2rem);
    }
}

.cl-btn:hover {
    background: #E2E8F0;
}

@media (max-width: 480px) {
    .cl-results-header-combined { flex-direction: column; gap: 1rem; padding: 1rem; }
    .cl-rh-divider { width: 100%; height: 1px; margin: 0; }
    .cl-rh-left, .cl-rh-right { width: 100%; justify-content: flex-start; }
    .cl-ip-security-notice { margin: 1rem 1rem 0; }
    .cl-matches-teaser { padding: 1.5rem 1rem; }
    .cl-direct-unlock-wrap { padding: 0 1rem 1rem; }
}
