﻿
    /* =========================================
       AI BG REMOVER — PREMIUM UI
       ========================================= */
    .da-wrapper {
        --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
        --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
        display: flex;
        justify-content: center;
            padding: clamp(0px, 5vw, 0px) 20px;
    }

    .da-panel {
        position: relative;                
        width: 100%;
        max-width: 1200px;
        border-radius: 28px;
        padding: clamp(28px, 5vw, 56px);
        overflow: hidden;
    }

    

    /* ---------- HERO ---------- */
    .da-hero { text-align: center; max-width: 800px; margin: 0 auto; padding: clamp(10px, 4vw, 30px) 0; }

    .da-hero-badge {
        display: inline-flex; align-items: center; gap: 8px;
        font-size: 12.5px; font-weight: 800; letter-spacing: 0.3px;
        color: var(--primary-color); background: var(--primary-light);
        padding: 7px 16px; border-radius: 100px; margin-bottom: 22px;
    }

    .da-hero-title {
        font-size: clamp(30px, 4.4vw, 44px);
        font-weight: 900;
        line-height: 1.15;
        letter-spacing: -0.025em;
        color: var(--text-main);
        margin-bottom: 16px;
    }

    .da-hero-title em {
        font-style: normal;
        background: linear-gradient(120deg, #10b981, var(--primary-color));
        -webkit-background-clip: text; background-clip: text; color: transparent;
    }

    .da-hero-desc { font-size: 16.5px; color: var(--text-muted); line-height: 1.7; margin-bottom: 36px; }

    /* --- DROP ZONE --- */
    .drop-zone { background: var(--bg-body); border: 2px dashed var(--border-color); border-radius: 20px; padding: 40px 20px; text-align: center; cursor: pointer; transition: all 0.3s; margin-bottom: 24px; display: flex; flex-direction: column; align-items: center; justify-content: center; }
    .drop-zone:hover, .drop-zone.drag-over { border-color: var(--primary-color); background: var(--primary-light); }
    .dz-icon { width: 56px; height: 56px; background: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; box-shadow: 0 4px 15px rgba(0,0,0,0.05); margin-bottom: 16px; color: var(--primary-color); }
    .dz-text { font-size: 16px; font-weight: 900; color: var(--text-main); margin-bottom: 8px; }
    .dz-sub { font-size: 13px; font-weight: 700; color: var(--text-muted); }

    /* --- OPTIONS BAR --- */
    .options-bar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; background: var(--card-bg); border: 1px solid var(--border-color); border-radius: 16px; padding: 12px 16px; margin-bottom: 24px; box-shadow: 0 10px 40px rgba(0,0,0,0.02); }
    .ob-lbl { font-size: 11px; font-weight: 800; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; margin-right: 4px; }
    .ob-sep { width: 1px; height: 24px; background: var(--border-color); margin: 0 4px; }
    
    .f-btn { background: var(--bg-body); border: 1px solid var(--border-color); border-radius: 8px; padding: 8px 12px; font-size: 12px; font-weight: 800; color: var(--text-muted); cursor: pointer; transition: all 0.2s; display: flex; align-items: center; gap: 6px; }
    .f-btn:hover { border-color: var(--primary-color); color: var(--primary-color); }
    .f-btn.on { background: var(--primary-light); color: var(--primary-color); border-color: var(--primary-color); }
    
    .color-swatch { width: 28px; height: 28px; border-radius: 8px; border: 2px solid transparent; cursor: pointer; transition: all 0.2s; box-shadow: inset 0 0 0 1px rgba(0,0,0,0.1); }
    .color-swatch:hover { transform: scale(1.1); }
    .color-swatch.on { border-color: var(--primary-color); box-shadow: 0 0 0 2px var(--primary-light); }
    
    .c-input { background: var(--bg-body); border: 1px solid var(--border-color); border-radius: 8px; padding: 8px 12px; font-family: inherit; font-size: 12px; font-weight: 700; color: var(--text-main); outline: none; transition: border-color 0.2s; max-width: 150px; }
    .c-input:focus { border-color: var(--primary-color); }

    /* --- TOOL WIDGET --- */
    .tool-widget { background: var(--card-bg); border: 1px solid var(--border-color); border-radius: 24px; padding: 24px; box-shadow: 0 10px 40px rgba(0,0,0,0.02); min-height: 400px; display: flex; flex-direction: column; }
    
    .state-box { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; background: #f8fafc; border: 1px dashed var(--border-color); border-radius: 16px; padding: 40px 20px; text-align: center; }
    .state-title { font-size: 16px; font-weight: 900; color: var(--text-main); margin-top: 16px; margin-bottom: 8px; }
    .state-body { font-size: 13px; font-weight: 700; color: var(--text-muted); max-width: 380px; line-height: 1.6; }

    /* Progress Box */
    .progress-box { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; background: #f8fafc; border: 1px solid var(--border-color); border-radius: 16px; padding: 40px 20px; text-align: center; }
    .pb-spinner { width: 40px; height: 40px; border: 4px solid var(--border-color); border-top-color: var(--primary-color); border-radius: 50%; animation: spin 1s linear infinite; margin-bottom: 16px; }
    @keyframes spin { to { transform: rotate(360deg); } }
    
    /* ── Comparison Panel & Analytics ── */
    .comparison-panel {
        background: var(--card-bg); border: 1px solid var(--border-color); border-radius: 24px;
        padding: 28px; margin-top: 32px; box-shadow: 0 10px 30px rgba(0,0,0,0.02); margin-bottom: 40px;
    }
    .cp-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; flex-wrap: wrap; gap: 12px; }
    .cp-title { font-size: 16px; font-weight: 800; color: var(--text-main); display: flex; align-items: center; gap: 10px; }
    .cp-badge { font-size: 12px; font-weight: 800; padding: 6px 14px; border-radius: 100px; }
    .badge-high { background: color-mix(in srgb, var(--success, #10b981) 15%, transparent); color: var(--success, #10b981); border: 1px solid color-mix(in srgb, var(--success, #10b981) 30%, transparent); }

    .cp-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
    .cp-card { background: var(--bg-body); border: 1px solid var(--border-color); border-radius: 16px; padding: 20px; display: flex; flex-direction: column; gap: 14px; }
    .cpc-header { display: flex; justify-content: space-between; align-items: center; }
    .cpc-title { font-size: 13.5px; font-weight: 800; color: var(--text-main); }
    .cpc-tag { font-size: 11.5px; font-weight: 800; padding: 4px 10px; border-radius: 6px; }
    .cpc-tag.success { background: color-mix(in srgb, var(--success, #10b981) 15%, transparent); color: var(--success, #10b981); }

    .cpc-body { display: flex; flex-direction: column; gap: 10px; }
    .cpc-stat-row { font-size: 13px; color: var(--text-muted); display: flex; justify-content: space-between; }
    .cpc-stat-row strong { color: var(--text-main); font-weight: 700; }
    .cpc-progress-bar { width: 100%; height: 8px; background: var(--border-color); border-radius: 100px; overflow: hidden; margin-top: 4px; }
    .cpc-progress-fill { height: 100%; background: var(--primary-color); border-radius: 100px; transition: width 0.6s cubic-bezier(0.16, 1, 0.3, 1); }
    .cpc-progress-fill.bg-gradient { background: linear-gradient(90deg, var(--primary-color), var(--primary-gradient-end)); }
    
    .pb-stage { font-size: 16px; font-weight: 900; color: var(--text-main); margin-bottom: 4px; }
    .pb-label { font-size: 12px; font-weight: 700; color: var(--text-muted); margin-bottom: 24px; }
    .pb-bar-wrap { width: 100%; max-width: 300px; height: 8px; background: var(--border-color); border-radius: 4px; overflow: hidden; }
    .pb-bar { height: 100%; background: var(--primary-color); width: 0%; transition: width 0.3s; }

    /* Result Section */
    .result-section { flex: 1; display: flex; flex-direction: column; }
    .rs-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; }
    .rs-title { font-size: 16px; font-weight: 900; color: var(--text-main); display: flex; align-items: center; gap: 8px; }
    .rs-title i { color: #10b981; }
    .rs-actions { display: flex; gap: 8px; flex-wrap: wrap; }
    .act-btn { padding: 10px 16px; border-radius: 10px; font-size: 13px; font-weight: 800; cursor: pointer; display: flex; align-items: center; gap: 8px; transition: all 0.2s; border: none; background: var(--bg-body); color: var(--text-main); border: 1px solid var(--border-color); }
    .act-btn:hover { border-color: var(--primary-color); color: var(--primary-color); }
    .act-btn.primary { background: var(--primary-color); color: #fff; box-shadow: 0 4px 15px rgba(var(--primary-color-rgb), 0.3); border: none; }
    .act-btn.primary:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(var(--primary-color-rgb), 0.4); color: #fff; }
    .act-btn.zip { background: #6366f1; box-shadow: 0 4px 15px rgba(99,102,241,0.3); color: #fff; border: none; }
    .act-btn.zip:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(99,102,241,0.4); color: #fff; }

    /* Thumbnails */
    .thumb-strip { display: flex; gap: 12px; overflow-x: auto; padding-bottom: 16px; margin-bottom: 16px; border-bottom: 1px solid var(--border-color); }
    .thumb-item { width: 64px; height: 64px; border-radius: 12px; border: 2px solid var(--border-color); overflow: hidden; cursor: pointer; position: relative; transition: all 0.2s; flex-shrink: 0; background: #fff; }
    .thumb-item.active { border-color: var(--primary-color); box-shadow: 0 0 0 3px var(--primary-light); }
    .thumb-item img { width: 100%; height: 100%; object-fit: cover; }
    .thumb-spinner { position: absolute; inset: 0; background: rgba(255,255,255,0.8); display: flex; align-items: center; justify-content: center; }
    .thumb-spinner .pb-spinner { width: 20px; height: 20px; border-width: 2px; margin: 0; }
    .thumb-done { position: absolute; bottom: 4px; right: 4px; width: 16px; height: 16px; background: #10b981; border-radius: 50%; color: #fff; display: flex; align-items: center; justify-content: center; box-shadow: 0 2px 4px rgba(0,0,0,0.2); }
    
    /* Compare Area */
    .compare-area { display: grid; grid-template-columns: 1fr 200px; gap: 20px; flex: 1; }
    @media (max-width: 900px) { .compare-area { grid-template-columns: 1fr; } }
    
    .slider-wrapper { position: relative; background: repeating-conic-gradient(rgba(255,255,255,0.05) 0% 25%, transparent 0% 50%) 0 0 / 14px 14px; border-radius: 16px; border: 1px solid var(--border-color); overflow: hidden; min-height: 400px; user-select: none; }
    .sc-layer { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; padding: 20px; }
    .sc-layer img { max-width: 100%; max-height: 100%; object-fit: contain; pointer-events: none; filter: drop-shadow(0 10px 20px rgba(0,0,0,0.1)); }
    
    .sc-divider { position: absolute; top: 0; bottom: 0; width: 2px; background: #ef4444; z-index: 10; pointer-events: none; }
    .sc-handle { position: absolute; top: 50%; width: 36px; height: 36px; background: #ef4444; border: 2px solid #fff; border-radius: 50%; transform: translate(-50%, -50%); display: flex; align-items: center; justify-content: center; cursor: ew-resize; z-index: 11; box-shadow: 0 4px 12px rgba(0,0,0,0.2); }
    
    .sc-lbl { position: absolute; bottom: 16px; background: rgba(0,0,0,0.6); color: #fff; font-size: 11px; font-weight: 800; padding: 6px 12px; border-radius: 100px; z-index: 5; backdrop-filter: blur(4px); }
    .sc-lbl.a { left: 16px; }
    .sc-lbl.b { right: 16px; }

    /* Previews */
    .bg-panels { display: flex; flex-direction: column; gap: 12px; }
    .bg-panel { background: var(--bg-body); border: 1px solid var(--border-color); border-radius: 12px; overflow: hidden; }
    .bgp-label { font-size: 11px; font-weight: 800; color: var(--text-muted); padding: 8px 12px; border-bottom: 1px solid var(--border-color); text-align: center; }
    .bgp-img { height: 100px; display: flex; align-items: center; justify-content: center; padding: 8px; }
    .bgp-img.checker { background: repeating-conic-gradient(#f1f5f9 0% 25%, #fff 0% 50%) 0 0 / 12px 12px; }
    .bgp-img.white { background: #fff; }
    .bgp-img img { max-width: 100%; max-height: 100%; object-fit: contain; }

    /* Meta Strip */
    .meta-strip { display: flex; align-items: center; gap: 12px; margin-top: 20px; padding-top: 16px; border-top: 1px dashed var(--border-color); flex-wrap: wrap; }
    .meta-badge { font-size: 11px; font-weight: 800; padding: 6px 12px; border-radius: 8px; }
    .mb-orig { background: var(--bg-body); color: var(--text-muted); border: 1px solid var(--border-color); }
    .mb-png { background: var(--primary-light); color: var(--primary-color); }
    .mb-dim { background: rgba(16, 185, 129, 0.1); color: #10b981; }

    /* --- STATS STRIP --- */
    .stats-strip { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; margin-top: 24px; margin-bottom: 40px; }
    .sc { background: var(--card-bg); border-radius: 16px; padding: 20px; border: 1px solid var(--border-color); display: flex; flex-direction: column; box-shadow: 0 4px 20px rgba(0,0,0,0.02); }
    .sc-lbl { font-size: 11px; font-weight: 800; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
    .sc-val { font-size: 24px; font-weight: 900; color: var(--text-main); font-family: 'Space Mono', monospace; }
    
    .sc.c-red .sc-lbl i { color: #ef4444; width: 14px; height: 14px; }
    .sc.c-blue .sc-lbl i { color: #3b82f6; width: 14px; height: 14px; }
    .sc.c-indigo .sc-lbl i { color: #6366f1; width: 14px; height: 14px; }
    .sc.c-green .sc-lbl i { color: #10b981; width: 14px; height: 14px; }

    /* Toast */
    .toast { position: fixed; bottom: 24px; right: 24px; background: var(--card-bg); border: 1px solid var(--border-color); border-radius: 12px; padding: 12px 20px; display: flex; align-items: center; gap: 12px; font-size: 13px; font-weight: 700; color: var(--text-main); box-shadow: 0 10px 30px rgba(0,0,0,0.1); z-index: 100000; opacity: 0; pointer-events: none; transform: translateY(20px); transition: all 0.3s var(--ease-spring); }
    .toast.show { opacity: 1; transform: translateY(0); }

    
    
