/**
 * CatfishNumr Image Search Styles
 * Professional styles for image search with animations
 * 
 * @version 1.0.0
 * @author Fisnik Murati
 */

/* ============================================
   3-Step Process Indicator — Redesigned
   ============================================ */

.image-search-steps {
    margin-bottom: 1.75rem;
    padding: 0.5rem 1rem 0;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
}

.steps-container {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    position: relative;
    max-width: 520px;
    margin: 0 auto;
    width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
    padding-top: 4px;
}

/* Base track line */
.steps-container::before {
    content: '';
    position: absolute;
    top: 22px;
    left: calc(16.67% + 4px);
    right: calc(16.67% + 4px);
    height: 2px;
    background: #e2e8f0;
    z-index: 1;
    border-radius: 2px;
}

/* Filled progress overlay */
.steps-container::after {
    content: '';
    position: absolute;
    top: 22px;
    left: calc(16.67% + 4px);
    height: 2px;
    background: linear-gradient(90deg, #007cfa, #0051c3);
    z-index: 2;
    border-radius: 2px;
    width: 0%;
    transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.steps-container.progress-1::after { width: 0%; }
.steps-container.progress-2::after { width: 50%; }
.steps-container.progress-3::after { width: 100%; }

.step-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    position: relative;
    z-index: 3;
    flex: 1;
    max-width: 160px;
    gap: 8px;
}

.step-number {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: #fff;
    color: #94a3b8;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 15px;
    transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    border: 2px solid #e2e8f0;
    position: relative;
    z-index: 3;
    flex-shrink: 0;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}

.step-item.active .step-number {
    background: #007cfa;
    color: #fff;
    border-color: #007cfa;
    box-shadow: 0 0 0 4px rgba(0, 124, 250, 0.15), 0 4px 12px rgba(0, 124, 250, 0.35);
    transform: scale(1.08);
}

.step-item.completed .step-number {
    background: linear-gradient(135deg, #10b981, #059669);
    color: #fff;
    border-color: #10b981;
    box-shadow: 0 4px 10px rgba(16, 185, 129, 0.3);
}

/* Checkmark for completed state */
.step-item.completed .step-number::after {
    content: '✓';
    position: absolute;
    font-size: 16px;
    font-weight: 800;
}

.step-item.completed .step-number-digit {
    display: none;
}

.step-content {
    text-align: center;
}

.step-title {
    font-weight: 500;
    font-size: 12px;
    color: #94a3b8;
    margin: 0;
    letter-spacing: 0.01em;
    line-height: 1.3;
    transition: color 0.3s ease;
    white-space: nowrap;
}

.step-item.active .step-title {
    color: #007cfa;
    font-weight: 700;
    font-size: 12px;
}

.step-item.completed .step-title {
    color: #10b981;
    font-weight: 600;
}

@media (max-width: 480px) {
    .steps-container {
        padding: 4px 0 0;
        max-width: 100%;
    }

    .steps-container::before,
    .steps-container::after {
        top: 18px;
        left: calc(16.67% + 2px);
        right: calc(16.67% + 2px);
    }

    .steps-container.progress-2::after { width: 50%; }
    .steps-container.progress-3::after { width: 100%; }

    .step-number {
        width: 36px;
        height: 36px;
        font-size: 13px;
    }

    .step-title {
        font-size: 10px;
    }

    .step-item.active .step-title {
        font-size: 10px;
    }
}

/* ============================================
   Image Search Animation Container
   ============================================ */

.catfishnumr-search-animation {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 0px !important;
    margin: 0px !important;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
}

/* Desktop/PC improvements */
@media (min-width: 1024px) {
    .catfishnumr-search-animation {
        max-width: 800px;
        margin: 2rem auto;
        padding: 2.5rem;
    }
}

@media (min-width: 1280px) {
    .catfishnumr-search-animation {
        max-width: 900px;
        padding: 3rem;
    }
}

.catfishnumr-search-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.catfishnumr-search-header p {
    font-size: 1.5rem;
    font-weight: 700;
    color: #16a34a;
    margin: 0;
}

/* ============================================
   Image Preview and Scanning
   ============================================ */

.search-image-img {
    position: relative;
    width: 200px;
    height: 200px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    background-color: #f3f4f6;
    background-size: cover;
    background-position: center;
    max-width: 100%;
    box-sizing: border-box;
}

/* Desktop image size improvements */
@media (min-width: 1024px) {
    .search-image-img {
        width: 220px;
        height: 220px;
    }
}

@media (min-width: 1280px) {
    .search-image-img {
        width: 240px;
        height: 240px;
    }
}

.search-image-img.scanning {
    animation: pulse-border 2s ease-in-out infinite;
}

@keyframes pulse-border {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.7);
    }
    50% {
        box-shadow: 0 0 0 15px rgba(59, 130, 246, 0);
    }
}

.search-image-blur {
    background: rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(4px);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 8px;
}

.possible-matches-count {
    color: #dc2626;
    font-weight: 700;
    font-size: 2rem;
    padding: 1rem;
}

/* ============================================
   Scan Status Checklist — Redesigned
   ============================================ */

.catfishnumr-progress-text {
    width: 100%;
    padding: 0 0.25rem;
}

.catfishnumr-progress-text ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
}

.catfishnumr-progress-text ul li {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    padding: 0.45rem 0.625rem;
    border-radius: 8px;
    transition: background 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

/* ── Icon bubble ── */
.scan-step-icon {
    width: 20px;
    height: 20px;
    min-width: 20px;
    border-radius: 50%;
    border: 2px solid #e2e8f0;
    background: #fff;
    flex-shrink: 0;
    box-sizing: border-box;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ── Label text ── */
.scan-step-label {
    font-size: 0.8125rem;
    font-weight: 500;
    color: #94a3b8;
    line-height: 1.35;
    letter-spacing: 0.01em;
    transition: color 0.3s ease, font-weight 0.2s ease;
}

/* ── Completed: active item that has a subsequent active sibling ── */
.catfishnumr-progress-text ul li.active:has(~ li.active) .scan-step-icon {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    border-color: #10b981;
    box-shadow: 0 2px 6px rgba(16, 185, 129, 0.3);
}

.catfishnumr-progress-text ul li.active:has(~ li.active) .scan-step-icon::after {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M2.5 6.5l2.5 2.5 4.5-5' stroke='%23fff' stroke-width='1.6' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-size: 62% 62%;
    background-repeat: no-repeat;
    background-position: center;
}

.catfishnumr-progress-text ul li.active:has(~ li.active) .scan-step-label {
    color: #059669;
    font-weight: 600;
}

/* ── In-progress: last active item (no subsequent active sibling) ── */
.catfishnumr-progress-text ul li.active:not(:has(~ li.active)) {
    background: linear-gradient(90deg, rgba(0,124,250,0.07), rgba(0,81,195,0.03));
}

.catfishnumr-progress-text ul li.active:not(:has(~ li.active)) .scan-step-icon {
    border-color: #007cfa;
    background: #fff;
    box-shadow: 0 0 0 4px rgba(0, 124, 250, 0.14), 0 2px 8px rgba(0, 124, 250, 0.2);
    animation: cn-step-ring 1.5s ease-in-out infinite;
}

.catfishnumr-progress-text ul li.active:not(:has(~ li.active)) .scan-step-icon::before {
    content: '';
    position: absolute;
    inset: 3px;
    border-radius: 50%;
    background: #007cfa;
    animation: cn-step-dot 1.5s ease-in-out infinite;
}

@keyframes cn-step-ring {
    0%, 100% { box-shadow: 0 0 0 4px rgba(0, 124, 250, 0.14), 0 2px 8px rgba(0, 124, 250, 0.2); }
    50%       { box-shadow: 0 0 0 7px rgba(0, 124, 250, 0.05), 0 2px 8px rgba(0, 124, 250, 0.06); }
}

@keyframes cn-step-dot {
    0%, 100% { opacity: 1; transform: scale(1); }
    50%       { opacity: 0.55; transform: scale(0.72); }
}

.catfishnumr-progress-text ul li.active:not(:has(~ li.active)) .scan-step-label {
    color: #007cfa;
    font-weight: 700;
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50%       { opacity: 0.7; transform: scale(1.2); }
}

/* ============================================
   Social Media Slideshow
   ============================================ */

.social-media-slideshow {
    width: 100%;
    max-width: 100%;
    overflow: hidden;
    padding: 1rem 0;
    margin: 1rem 0;
    box-sizing: border-box;
}

.social-media-slideshow ul {
    display: flex;
    animation: infinite-scroll 30s linear infinite;
}

.social-media-slideshow ul li {
    display: inline-block;
    margin: 0 0.5rem;
}

.social-media-slideshow ul li img {
    width: 40px;
    height: 40px;
    object-fit: contain;
    opacity: 0.8;
    transition: all 0.3s ease;
}

.social-media-slideshow ul li img:hover {
    opacity: 1;
    transform: scale(1.1);
}

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

/* ============================================
   Search Results and Notifications
   ============================================ */

.search-result {
    background: #fef3c7;
    border: 1px solid #fbbf24;
    border-radius: 8px;
    padding: 1.5rem;
    margin: 1rem 0;
    text-align: center;
}

.search-result label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 1.125rem;
}

.notification {
    padding: 1rem;
    border-radius: 8px;
    margin: 1rem 0;
    text-align: center;
    animation: fade-in 0.5s ease;
}

.search-notify-adult {
    background: #fef2f2;
    border: 2px solid #ef4444;
}

.search-notify-adult p {
    color: #dc2626;
    font-weight: 600;
    margin: 0;
}

@keyframes fade-in {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ============================================
   Progress Footer — Redesigned
   ============================================ */

.catfishnumr-search-footer {
    padding-top: 0.25rem;
}

.progress-updates {
    width: 100%;
}

.scan-progress-label-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    margin-bottom: 0.625rem;
}

.progress-step {
    font-size: 0.9375rem;
    font-weight: 700;
    color: #1e293b;
    margin: 0;
    letter-spacing: -0.015em;
}

.step-description {
    font-size: 0.6875rem;
    font-weight: 700;
    color: #94a3b8;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    white-space: nowrap;
    flex-shrink: 0;
}

.scan-progress-track {
    width: 100%;
    height: 10px;
    background: #f1f5f9;
    border-radius: 100px;
    overflow: hidden;
    position: relative;
}

.catfishnumr-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #0051c3 0%, #007cfa 55%, #38bdf8 100%);
    border-radius: 100px;
    transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    min-width: 0;
    position: relative;
    overflow: hidden;
    font-size: 0;
    color: transparent;
}

.catfishnumr-progress-bar::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.3) 50%, transparent 100%);
    animation: cn-shimmer 1.8s linear infinite;
}

@keyframes cn-shimmer {
    0%   { transform: translateX(-150%); }
    100% { transform: translateX(150%); }
}

.btn-get-results {
    background: linear-gradient(135deg, #007cfa 0%, #0051c3 100%);
    color: #ffffff;
    padding: 1rem 2rem;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 600;
    text-align: center;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-block;
    box-shadow: 0 4px 14px rgba(0, 124, 250, 0.35);
}

.btn-get-results:hover {
    background: linear-gradient(135deg, #0069d9 0%, #0040a0 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 124, 250, 0.45);
    color: #ffffff;
}

/* ============================================
   Results Summary & "Get Results" CTA
   ============================================ */

.image-search-results-summary {
    text-align: center;
    padding: 36px 24px 28px;
    max-width: 560px;
    margin: 0 auto;
    animation: cn-fade-up 0.4s cubic-bezier(0.4, 0, 0.2, 1) both;
}

@keyframes cn-fade-up {
    from { opacity: 0; transform: translateY(16px); }
    to   { opacity: 1; transform: translateY(0); }
}

.image-search-results-summary .results-count-display {
    margin-bottom: 28px;
}

.image-search-results-summary .results-count-display i {
    display: block;
    font-size: 52px;
    color: #10b981;
    margin-bottom: 14px;
    animation: cn-pop 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) 0.1s both;
}

@keyframes cn-pop {
    from { opacity: 0; transform: scale(0.6); }
    to   { opacity: 1; transform: scale(1); }
}

.image-search-results-summary .results-count-display h3 {
    margin: 0 0 8px 0;
    color: #1e293b;
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.025em;
}

.image-search-results-summary .results-count-display p {
    margin: 0;
    color: #64748b;
    font-size: 1.05rem;
}

.image-search-results-summary .results-count-display p strong {
    color: #007cfa;
    font-size: 1.4rem;
    font-weight: 800;
}

.get-results-button-container {
    display: flex;
    justify-content: center;
}

.btn-get-results-image-search {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 16px 48px;
    background: linear-gradient(135deg, #007cfa 0%, #0051c3 100%);
    color: #fff !important;
    border: none;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1),
                box-shadow 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 16px rgba(0, 124, 250, 0.4);
    letter-spacing: 0.01em;
    min-width: 200px;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    animation: cn-fade-up 0.45s cubic-bezier(0.4, 0, 0.2, 1) 0.2s both;
}

.btn-get-results-image-search:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 28px rgba(0, 124, 250, 0.5);
}

.btn-get-results-image-search:active {
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(0, 124, 250, 0.4);
    transition-duration: 0.1s;
}

.btn-get-results-image-search i {
    font-size: 1rem;
}

@media (max-width: 480px) {
    .btn-get-results-image-search {
        width: 100%;
        padding: 15px 24px;
        font-size: 1rem;
        border-radius: 10px;
    }

    .image-search-results-summary {
        padding: 28px 16px 20px;
    }
}

/* ============================================
   FilePond Custom Styles
   ============================================ */

.filepond--root {
    font-family: inherit;
    margin-bottom: 1.5rem;
}

.filepond--panel-root {
    background-color: #f8fafc;
    border: 2px dashed #cbd5e1;
    border-radius: 14px;
    transition: border-color 0.2s ease, background-color 0.2s ease;
}

.filepond--root:hover .filepond--panel-root,
.filepond--root.filepond--hopper .filepond--panel-root {
    border-color: #007cfa;
    background-color: rgba(0, 124, 250, 0.03);
}

.filepond--drop-label {
    color: #4b5563;
    font-size: 1rem;
    display: flex !important;
    flex-direction: column !important;
    align-items: center;
    gap: 0.35em;
    text-align: center;
}

.catfish-filepond-label-line1 {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.35em;
}

.catfish-filepond-label-line2 {
    display: block;
    font-size: 0.85em;
    opacity: 0.7;
}

.filepond--label-action {
    color: #3b82f6;
    font-weight: 600;
    text-decoration: none;
}

.filepond--label-action:hover {
    color: #2563eb;
    text-decoration: underline;
}

.filepond--drip-blob {
    background-color: #3b82f6;
}

.filepond--file {
    color: #1f2937;
}

.filepond--file-status {
    color: #6b7280;
}

.filepond--file-info {
    color: #374151;
}

/* Active state when dragging */
.filepond--root.filepond--hopper {
    border-color: #3b82f6;
}

/* Hide FilePond PQINA branding/credits */
.filepond--credits,
.filepond--credits *,
[class*="filepond--credits"],
[class*="filepond"][class*="credits"],
.filepond--root [data-credit],
.filepond--root a[href*="pqina"],
.filepond--root a[href*="filepond"],
.filepond--root::after {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    height: 0 !important;
    width: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
}

/* Hide any "Powered by" text */
.filepond--root::before {
    content: none !important;
    display: none !important;
}

/* Hide any credit links or text containing PQINA/FilePond branding */
.filepond--root *:not([class*="filepond--label"]):not([class*="filepond--file"]):not([class*="filepond--panel"]) {
    text-decoration: none !important;
}

.filepond--root [href*="pqina"],
.filepond--root [href*="filepond"],
.filepond--root span:contains("PQINA"),
.filepond--root span:contains("Powered by"),
.filepond--root div:contains("PQINA"),
.filepond--root div:contains("Powered by") {
    display: none !important;
    visibility: hidden !important;
}

/* ============================================
   Image Upload Section Toggle
   ============================================ */

.image-search-upload-section {
    animation: fade-in 0.3s ease;
}

.image-search-animation-section {
    animation: fade-in 0.3s ease;
    padding: 0px !important;
}

/* Desktop container centering */
@media (min-width: 1024px) {
    #imageSearchAnimationSection {
        display: flex;
        justify-content: center;
        width: 100%;
        max-width: 100%;
    }
    
    #imageSearchAnimationSection > * {
        width: 100%;
        max-width: 100%;
    }
}

/* ============================================
   Responsive Grid
   ============================================ */

.grid {
    display: grid;
    gap: 1.5rem;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.grid-cols-3 {
    grid-template-columns: repeat(3, 1fr);
}

/* Make progress steps full width - stack image and steps vertically */
.catfishnumr-search-body .grid.grid-cols-3 {
    grid-template-columns: 1fr !important;
    gap: 1.5rem;
}

.catfishnumr-search-body .grid .col-span-3 {
    grid-column: span 1 !important;
    width: 100% !important;
    max-width: 100% !important;
}

/* Desktop/PC grid improvements */
@media (min-width: 1024px) {
    .catfishnumr-search-body .grid.grid-cols-3 {
        grid-template-columns: 1fr !important;
        gap: 2rem;
    }
    
    .catfishnumr-search-body .grid .col-span-3.sm\:col-span-2 {
        display: flex;
        justify-content: center;
        align-items: center;
        width: 100% !important;
        max-width: 100% !important;
    }
    
    .catfishnumr-progress-text {
        width: 100% !important;
        max-width: 100% !important;
        justify-self: stretch !important;
    }
    
    .catfishnumr-progress-text ul {
        width: 100% !important;
        max-width: 100% !important;
    }
}

@media (max-width: 768px) {
    .grid-cols-3 {
        grid-template-columns: 1fr;
    }
    
    .catfishnumr-search-body {
        gap: 1rem;
    }
    
    .social-media-slideshow ul li img {
        width: 32px;
        height: 32px;
    }
    
    .possible-matches-count {
        font-size: 1.5rem;
        padding: 0.75rem;
    }
    
    .search-result {
        padding: 1rem;
    }
    
    .search-result label {
        font-size: 1rem;
    }
    
    .notification {
        padding: 0.75rem;
        font-size: 0.875rem;
    }
}

.col-span-3 {
    grid-column: span 3 / span 3;
}

.col-span-2 {
    grid-column: span 2 / span 2;
}

.col-span-1 {
    grid-column: span 1 / span 1;
}

@media (min-width: 640px) {
    .sm\:col-span-2 {
        grid-column: span 2 / span 2;
    }
    
    .sm\:col-span-1 {
        grid-column: span 1 / span 1;
    }
}

/* ============================================
   Utility Classes
   ============================================ */

.flex {
    display: flex;
}

.flex-col {
    flex-direction: column;
}

.gap-y-8 {
    row-gap: 2rem;
}

.justify-center {
    justify-content: center;
}

.justify-self-center {
    justify-self: center;
}

/* Override justify-self-center for progress text to make it full width */
.catfishnumr-progress-text.justify-self-center {
    justify-self: stretch !important;
    width: 100% !important;
    max-width: 100% !important;
}

.max-w-2xl {
    max-width: 42rem;
}


.max-w-fit {
    max-width: fit-content;
}

/* Override max-w-fit for progress text to make it full width */
.catfishnumr-progress-text .max-w-fit,
.catfishnumr-progress-text ul.max-w-fit {
    max-width: 100% !important;
    width: 100% !important;
}

.hidden {
    display: none;
}

.text-center {
    text-align: center;
}

.sm\:text-left {
    text-align: left;
}

@media (min-width: 640px) {
    .sm\:text-left {
        text-align: left;
    }
}

/* ============================================
   Responsive Design
   ============================================ */

@media (max-width: 640px) {
    .catfishnumr-search-animation {
        padding: 1rem 0.75rem;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
        margin: 1rem 0;
    }
    
    .grid {
        gap: 0.75rem;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }
    
    .search-image-img {
        width: 120px;
        height: 120px;
        max-width: 100%;
    }
    
    .catfishnumr-progress-text ul li {
        font-size: 0.8rem;
        padding: 0.5rem 0.5rem;
        padding-left: 1.75rem;
        word-wrap: break-word;
        max-width: 100%;
        line-height: 1.4;
    }
    
    .col-span-3,
    .sm\:col-span-2,
    .sm\:col-span-1 {
        grid-column: span 3 / span 3;
        max-width: 100%;
    }
    
    .catfishnumr-search-header p {
        font-size: 1.25rem;
    }
    
    .catfishnumr-progress-text {
        margin-top: 1rem;
    }
    
    .catfishnumr-search-footer {
        padding: 0.5rem 0;
    }
    
    .progress-step {
        font-size: 1rem;
    }
    
    .step-description {
        font-size: 0.875rem;
    }
    
    .package-option {
        padding: 14px;
    }
    
    .package-option h4 {
        font-size: 1.1rem;
    }
    
    .package-option .package-features {
        font-size: 13px;
        line-height: 1.5;
    }
    
    .package-option .package-button {
        padding: 10px 16px;
        font-size: 0.9rem;
        width: 100%;
        text-align: center;
    }
    
    .upgrade-section {
        padding: 16px 18px;
    }
    
    .upgrade-section .upgrade-header h3 {
        font-size: 18px;
    }
    
    .upgrade-section .upgrade-header p {
        font-size: 13px;
    }
    
    .btn-get-results-fake {
        padding: 14px 24px !important;
        font-size: 16px !important;
        min-width: auto !important;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }
    
    #imageSearchGetResultsBtn {
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
        padding: 14px 24px !important;
        font-size: 16px !important;
    }
    
    .image-search-results-summary {
        padding: 30px 15px !important;
    }
    
    .results-count-display h3 {
        font-size: 1.25rem !important;
    }
    
    .results-count-display p {
        font-size: 1rem !important;
    }
    
    .results-count-display strong {
        font-size: 1.1rem !important;
    }
    
    .fake-results-container {
        padding: 10px 15px !important;
    }
    
    .results-summary {
        padding: 20px 15px !important;
    }
    
    .match-count {
        padding: 15px !important;
    }
    
    .match-count h3 {
        font-size: 18px !important;
    }
    
    .match-count span {
        font-size: 24px !important;
    }
}

/* ============================================
   Animations
   ============================================ */

@keyframes bounce {
    0%, 100% {
        transform: translateY(0);
        animation-timing-function: cubic-bezier(0.8, 0, 1, 1);
    }
    50% {
        transform: translateY(-10px);
        animation-timing-function: cubic-bezier(0, 0, 0.2, 1);
    }
}

.animate-bounce {
    animation: bounce 1s infinite;
}

/* ============================================
   Tailwind-like Utilities
   ============================================ */

.text-2xl {
    font-size: 1.5rem;
    line-height: 2rem;
}

.text-lg {
    font-size: 1.125rem;
    line-height: 1.75rem;
}

.text-md {
    font-size: 1rem;
    line-height: 1.5rem;
}

.text-sm {
    font-size: 0.875rem;
    line-height: 1.25rem;
}

.font-bold {
    font-weight: 700;
}

.italic {
    font-style: italic;
}

.mt-2 {
    margin-top: 0.5rem;
}

.mt-4 {
    margin-top: 1rem;
}

.mt-8 {
    margin-top: 2rem;
}

.mb-2 {
    margin-bottom: 0.5rem;
}

.my-6 {
    margin-top: 1.5rem;
    margin-bottom: 1.5rem;
}

.p-4 {
    padding: 1rem;
}

.p-6 {
    padding: 1.5rem;
}

.py-2 {
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
}

.pb-4 {
    padding-bottom: 1rem;
}

.rounded-lg {
    border-radius: 0.5rem;
}

.rounded-md {
    border-radius: 0.375rem;
}

.rounded-full {
    border-radius: 9999px;
}

.shadow {
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
}

.shadow-2xl {
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.bg-white {
    background-color: #ffffff;
}

.bg-gray-500 {
    background-color: #6b7280;
}

.bg-opacity-80 {
    --tw-bg-opacity: 0.8;
}

.text-white {
    color: #ffffff;
}

.text-green-700 {
    color: #15803d;
}

.text-green-600 {
    color: #16a34a;
}

.text-red {
    color: #dc2626;
}

.border {
    border-width: 1px;
}

.border-gray-200 {
    border-color: #e5e7eb;
}

.border-solid {
    border-style: solid;
}

.border-2 {
    border-width: 2px;
}

.bg-white-200 {
    background-color: #f3f4f6;
}

.ease-in-out {
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

.duration-300 {
    transition-duration: 300ms;
}

/* Position utilities */
.absolute {
    position: absolute;
}

.relative {
    position: relative;
}

.top-0 {
    top: 0;
}

.left-0 {
    left: 0;
}

/* Width utilities */
.w-full {
    width: 100%;
}

.w-\[200px\] {
    width: 200px;
}

.h-\[200px\] {
    height: 200px;
}

/* Backdrop utilities */
.backdrop-blur-sm {
    backdrop-filter: blur(4px);
}

.backdrop-blur-md {
    backdrop-filter: blur(12px);
}

/* ============================================
   Payment Packages Preview Styles
   ============================================ */

.catfishnumr-payment-packages-preview {
    position: relative;
    overflow: hidden;
}

.catfishnumr-payment-packages-preview::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #28a745, #ffc107, #6f42c1);
}

.package-card {
    transition: all 0.3s ease;
    cursor: pointer;
}

.package-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.package-card.standard:hover {
    border-color: #28a745;
}

.package-card.premium:hover {
    border-color: #ffc107;
    box-shadow: 0 20px 40px rgba(255, 193, 7, 0.3);
}

.package-card.enterprise:hover {
    border-color: #6f42c1;
}

.btn-package {
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-package::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.btn-package:hover::before {
    left: 100%;
}

.btn-package:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

.discovery-features .feature-item {
    transition: all 0.3s ease;
}

.discovery-features .feature-item:hover {
    transform: scale(1.05);
}

.upgrade-notice {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { opacity: 1; }
    50% { opacity: 0.8; }
    100% { opacity: 1; }
}

.unlock-notice {
    animation: glow 3s ease-in-out infinite alternate;
}

@keyframes glow {
    from { box-shadow: 0 0 10px rgba(21, 101, 192, 0.3); }
    to { box-shadow: 0 0 20px rgba(21, 101, 192, 0.6); }
}

/* Packages container styling */
.packages-container {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    margin-top: 1.5rem;
}

/* Responsive two-column layout for fake results + upgrade section */
.results-grid {
    grid-template-columns: 1fr;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
    gap: 20px;
}

.fake-results-container {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.fake-results-container .left-col {
    width: 100%;
    max-width: 100%;
}

.fake-results-container .results-summary {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.fake-results-container .results-grid {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

@media (min-width: 900px) {
    .fake-results-container {
        grid-template-columns: 1fr 1fr;
        gap: 20px;
        align-items: start;
    }
    
    .fake-results-container .left-col {
        order: 1;
    }
    
    .fake-results-container .results-grid {
        order: 2;
    }
    
    .results-grid {
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }
}

@media (max-width: 899px) {
    .fake-results-container {
        grid-template-columns: 1fr;
    }
    
    .results-grid {
        grid-template-columns: 1fr;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }
}

/* Upgrade section styles */
.upgrade-section {
    background: #ffffff;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 20px 24px;
    box-shadow: 0 4px 18px rgba(0,0,0,0.06);
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
}

.upgrade-section .upgrade-header {
    text-align: center;
    margin-bottom: 18px;
}

.upgrade-section .upgrade-header h3 {
    margin: 0 0 6px 0;
    font-size: 20px;
    color: #222;
}

.upgrade-section .upgrade-header p {
    margin: 0;
    color: #5f6b7a;
    font-size: 14px;
}

.upgrade-packages {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.package-option {
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    padding: 18px;
    background: #fff;
    transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
    word-wrap: break-word;
    position: relative;
}

.package-content-wrapper {
    display: flex;
    flex-direction: column;
    gap: 15px;
    width: 100%;
}

.package-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    width: 100%;
}

.package-title-section {
    flex: 1;
    min-width: 0;
}

.package-button-section {
    flex-shrink: 0;
    display: flex;
    align-items: center;
}

.package-left-section {
    width: 100%;
}

.package-right-section {
    display: none;
}

.package-option h4 {
    margin: 0;
    color: #333;
    font-size: 1.25rem;
    font-weight: 700;
}

.package-option .package-features {
    color: #666;
    font-size: 14px;
    line-height: 1.6;
    margin-top: 12px;
    margin-bottom: 10px;
}

.package-option .package-button {
    display: inline-block;
    border-radius: 8px;
    padding: 10px 18px;
    text-decoration: none;
    font-weight: 600;
    white-space: nowrap;
    text-align: center;
    margin: 0px !important;
}

.package-option .standard-btn {
    background: #2d71e3;
    color: #fff;
}

.package-option .premium-btn {
    background: linear-gradient(45deg, #8a6cff, #b18cff);
    color: #fff;
}

.package-option .package-info {
    margin-top: 10px;
    color: #666;
    font-size: 12px;
}

/* Responsive: Stack button below on mobile */
@media (max-width: 768px) {
    .package-header-row {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
    }
    
    .package-button-section {
        width: 100%;
    }
    
    .package-option .package-button {
        width: 100%;
        text-align: center;
    }
}

.premium-highlight {
    border-color: #8a6cff;
    position: relative;
}

.premium-highlight .popular-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #8a6cff, #b18cff);
    color: #fff;
    padding: 6px 12px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    box-shadow: 0 6px 14px rgba(138,108,255,0.35);
}

.package-option:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.08);
}

/* Multi-face picker (Human.js) — matches Catfish Lens behavior */
.cn-face-select-modal {
    position: fixed;
    inset: 0;
    z-index: 100050;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background: rgba(15, 23, 42, 0.72);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    box-sizing: border-box;
}
.cn-face-select-dialog {
    position: relative;
    max-width: 520px;
    width: 100%;
    max-height: min(90vh, 640px);
    overflow: auto;
    padding: 1.5rem 1.5rem 1.25rem;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 24px 48px rgba(15, 23, 42, 0.25);
    box-sizing: border-box;
}
.cn-face-select-close {
    position: absolute;
    top: 0.65rem;
    right: 0.65rem;
    width: 2.25rem;
    height: 2.25rem;
    border: none;
    border-radius: 8px;
    background: #f1f5f9;
    color: #475569;
    font-size: 1.35rem;
    line-height: 1;
    cursor: pointer;
}
.cn-face-select-close:hover { background: #e2e8f0; color: #0f172a; }
.cn-face-select-title {
    margin: 0 2rem 0.35rem 0;
    font-size: 1.25rem;
    font-weight: 700;
    color: #0f172a;
}
.cn-face-select-sub {
    margin: 0 0 1.1rem;
    font-size: 0.9rem;
    color: #64748b;
    line-height: 1.45;
}
.cn-face-select-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 0.75rem;
    margin-bottom: 1.1rem;
}
.cn-face-select-card {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.45rem;
    padding: 0.5rem;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    background: #f8fafc;
    cursor: pointer;
    text-align: left;
    font: inherit;
    transition: border-color 0.15s, box-shadow 0.15s;
}
.cn-face-select-card:hover {
    border-color: #6366f1;
    box-shadow: 0 4px 14px rgba(99, 102, 241, 0.2);
}
.cn-face-select-card-img-wrap {
    display: block;
    aspect-ratio: 1;
    border-radius: 8px;
    overflow: hidden;
    background: #e2e8f0;
}
.cn-face-select-card-img-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.cn-face-select-card-meta {
    font-size: 0.75rem;
    font-weight: 600;
    color: #475569;
}
.cn-face-select-cancel {
    width: 100%;
    padding: 0.65rem 1rem;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    background: #fff;
    color: #334155;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
}
.cn-face-select-cancel:hover { background: #f8fafc; }

