        /* Setup Checklist Styles */
        .setup-checklist {
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            border-radius: 16px;
            padding: 24px 28px;
            margin-bottom: 24px;
            color: white;
            box-shadow: 0 4px 20px rgba(102, 126, 234, 0.3);
        }
        .setup-checklist.completed {
            background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
            box-shadow: 0 4px 20px rgba(17, 153, 142, 0.3);
        }
        .checklist-header {
            margin-bottom: 20px;
        }
        .checklist-title-row {
            display: flex;
            justify-content: space-between;
            align-items: center;
            flex-wrap: wrap;
            gap: 12px;
        }
        .checklist-header h2 {
            margin: 0;
            font-size: 22px;
            font-weight: 700;
        }
        .checklist-header-right {
            display: flex;
            align-items: center;
            gap: 16px;
        }
        .checklist-progress {
            display: flex;
            align-items: center;
            gap: 12px;
        }
        .checklist-toggle {
            background: rgba(255,255,255,0.15);
            border: none;
            border-radius: 6px;
            width: 32px;
            height: 32px;
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            transition: all 0.2s ease;
            color: white;
        }
        .checklist-toggle:hover {
            background: rgba(255,255,255,0.25);
        }
        .checklist-toggle svg {
            transition: transform 0.3s ease;
        }
        .setup-checklist.collapsed .checklist-toggle svg {
            transform: rotate(-90deg);
        }
        .setup-checklist.collapsed .checklist-steps,
        .setup-checklist.collapsed .checklist-footer,
        .setup-checklist.collapsed .checklist-subtitle {
            display: none;
        }
        .setup-checklist.collapsed {
            padding: 16px 28px;
        }
        .setup-checklist.collapsed .checklist-header {
            margin-bottom: 0;
        }
        .progress-text {
            font-size: 14px;
            opacity: 0.9;
            white-space: nowrap;
        }
        .progress-bar {
            width: 120px;
            height: 8px;
            background: rgba(255,255,255,0.3);
            border-radius: 4px;
            overflow: hidden;
        }
        .progress-fill {
            height: 100%;
            background: white;
            border-radius: 4px;
            transition: width 0.5s ease;
        }
        .checklist-subtitle {
            margin: 8px 0 0 0;
            opacity: 0.85;
            font-size: 15px;
        }
        .checklist-steps {
            display: flex;
            flex-direction: column;
            gap: 10px;
        }
        .checklist-step {
            display: flex;
            align-items: center;
            gap: 16px;
            background: rgba(255,255,255,0.12);
            border-radius: 10px;
            padding: 14px 18px;
            transition: all 0.2s ease;
        }
        .checklist-step:hover {
            background: rgba(255,255,255,0.18);
        }
        .step-left {
            flex-shrink: 0;
        }
        .step-number {
            display: flex;
            align-items: center;
            justify-content: center;
            width: 28px;
            height: 28px;
            background: rgba(255,255,255,0.2);
            border-radius: 50%;
            font-size: 14px;
            font-weight: 700;
        }
        .step-content {
            flex: 1;
            min-width: 0;
        }
        .step-title {
            font-size: 15px;
            font-weight: 600;
            margin: 0 0 2px 0;
        }
        .step-description {
            font-size: 13px;
            opacity: 0.75;
            margin: 0;
        }
        .step-right {
            display: flex;
            align-items: center;
            gap: 12px;
            flex-shrink: 0;
        }
        .step-status {
            font-size: 12px;
            font-weight: 600;
            text-transform: uppercase;
            letter-spacing: 0.5px;
            padding: 4px 10px;
            border-radius: 4px;
            display: none;
        }
        .step-action {
            background: white !important;
            color: #667eea !important;
            border: none !important;
            font-weight: 600;
            font-size: 13px;
            padding: 8px 16px;
            border-radius: 6px;
            white-space: nowrap;
        }
        .step-action:hover:not(:disabled) {
            background: #f0f0f0 !important;
        }
        .step-action:disabled {
            opacity: 0.4;
            cursor: not-allowed;
        }

        /* Completed state */
        .checklist-step.completed {
            background: rgba(255,255,255,0.2);
        }
        .checklist-step.completed .step-number {
            background: white;
            color: #667eea;
        }
        .checklist-step.completed .step-number::after {
            content: '✓';
            position: absolute;
        }
        .checklist-step.completed .step-number {
            font-size: 0;
            position: relative;
        }
        .checklist-step.completed .step-number::after {
            font-size: 14px;
        }
        .checklist-step.completed .step-title {
            text-decoration: line-through;
            opacity: 0.7;
        }
        .checklist-step.completed .step-action {
            background: rgba(255,255,255,0.25) !important;
            color: white !important;
        }

        /* In Progress state */
        .checklist-step.in-progress {
            background: rgba(255,255,255,0.22);
            box-shadow: inset 0 0 0 2px rgba(255,255,255,0.4);
        }
        .checklist-step.in-progress .step-number {
            background: white;
            color: #667eea;
        }
        .checklist-step.in-progress .step-status {
            display: block;
            background: rgba(255,255,255,0.25);
            color: white;
        }
        .checklist-step.in-progress .step-status::before {
            content: 'In Progress';
        }

        /* Attention pulse animation for Continue button navigation */
        @keyframes attention-pulse {
            0% {
                box-shadow: 0 0 0 0 rgba(26, 172, 184, 0.6);
                transform: scale(1);
            }
            50% {
                box-shadow: 0 0 0 12px rgba(26, 172, 184, 0);
                transform: scale(1.02);
            }
            100% {
                box-shadow: 0 0 0 0 rgba(26, 172, 184, 0);
                transform: scale(1);
            }
        }

        .checklist-step.attention-pulse {
            animation: attention-pulse 0.8s ease-in-out 3;
            border-radius: 12px;
            background: rgba(26, 172, 184, 0.15) !important;
        }

        /* Pixel status styles for step 3 */
        .step-status.pixel-tested,
        .step-status.pixel-configured,
        .step-status.pixel-not-set {
            display: inline-block;
        }
        .step-status.pixel-tested {
            background: rgba(34, 197, 94, 0.3);
            color: #bbf7d0;
        }
        .step-status.pixel-configured {
            background: rgba(234, 179, 8, 0.3);
            color: #fef08a;
        }
        .step-status.pixel-not-set {
            background: rgba(255, 255, 255, 0.15);
            color: rgba(255, 255, 255, 0.7);
        }

        .checklist-footer {
            margin-top: 16px;
            text-align: center;
        }
        .btn-text {
            background: none;
            border: none;
            color: rgba(255,255,255,0.6);
            font-size: 13px;
            cursor: pointer;
            padding: 8px 16px;
            transition: color 0.2s;
        }
        .btn-text:hover {
            color: white;
        }

        /* Celebration animation when all complete */
        @keyframes celebrate {
            0%, 100% { transform: scale(1); }
            50% { transform: scale(1.02); }
        }
        .setup-checklist.all-complete {
            animation: celebrate 0.5s ease;
        }

        /* Responsive */
        @media (max-width: 600px) {
            .checklist-step {
                flex-wrap: wrap;
            }
            .step-right {
                width: 100%;
                justify-content: space-between;
                margin-top: 10px;
            }
            .checklist-title-row {
                flex-direction: column;
                align-items: flex-start;
            }
        }

        /* Wizard Modal Styles */
        .modal {
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            z-index: 1000;
            display: flex;
            align-items: center;
            justify-content: center;
        }
        .modal-backdrop {
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: rgba(0,0,0,0.6);
        }
        .modal-content {
            position: relative;
            background: var(--color-surface);
            border-radius: 16px;
            max-width: 600px;
            width: 90%;
            max-height: 90vh;
            overflow-y: auto;
            box-shadow: 0 20px 60px rgba(0,0,0,0.3);
        }
        .modal-large {
            max-width: 700px;
        }
        .modal-close {
            position: absolute;
            top: 16px;
            right: 16px;
            background: none;
            border: none;
            font-size: 24px;
            cursor: pointer;
            color: var(--color-text-light);
            z-index: 10;
        }
        .wizard-step {
            padding: 32px;
        }
        .wizard-header {
            text-align: center;
            margin-bottom: 24px;
        }
        .wizard-step-indicator {
            display: inline-block;
            background: var(--color-primary);
            color: white;
            padding: 4px 12px;
            border-radius: 20px;
            font-size: 12px;
            margin-bottom: 12px;
        }
        .wizard-header h2 {
            margin: 0;
            font-size: 24px;
        }
        .wizard-body {
            margin-bottom: 24px;
        }
        .wizard-icon {
            font-size: 64px;
            text-align: center;
            margin-bottom: 16px;
        }
        .wizard-icon-success {
            color: var(--color-success);
        }
        .wizard-list {
            list-style: none;
            padding: 0;
            margin: 16px 0;
        }
        .wizard-list li {
            padding: 8px 0;
            font-size: 15px;
        }
        .wizard-info-box {
            background: var(--color-background);
            border: 1px solid var(--color-border);
            border-radius: 8px;
            padding: 16px;
            margin-top: 20px;
        }
        .wizard-info-box strong {
            display: block;
            margin-bottom: 4px;
        }
        .wizard-info-box p {
            margin: 0;
            color: var(--color-text-light);
            font-size: 14px;
        }
        .wizard-info-success {
            background: #d4edda;
            border-color: #c3e6cb;
        }
        .wizard-footer {
            display: flex;
            justify-content: space-between;
            gap: 12px;
            padding-top: 16px;
            border-top: 1px solid var(--color-border);
        }
        .wizard-subtitle {
            margin: 8px 0 0 0;
            color: var(--color-text-light);
            font-size: 15px;
        }
        /* Embed Modal Styles */
        .embed-option {
            margin-bottom: 20px;
            padding: 16px;
            background: var(--color-background);
            border: 1px solid var(--color-border);
            border-radius: 12px;
        }
        .embed-option:last-of-type {
            margin-bottom: 0;
        }
        .embed-recommended {
            border-color: var(--color-primary);
            background: rgba(102, 126, 234, 0.05);
        }
        .embed-option-header {
            display: flex;
            align-items: center;
            gap: 10px;
            margin-bottom: 4px;
        }
        .embed-option-title {
            margin: 0;
            font-size: 16px;
            font-weight: 600;
        }
        .embed-badge {
            display: inline-block;
            background: var(--color-primary);
            color: white;
            font-size: 11px;
            font-weight: 600;
            padding: 2px 8px;
            border-radius: 10px;
            text-transform: uppercase;
        }
        .embed-option-desc {
            margin: 0 0 12px 0;
            font-size: 14px;
            color: var(--color-text-light);
        }
        .embed-code-box {
            display: flex;
            flex-direction: column;
            gap: 8px;
        }
        .embed-code-input {
            width: 100%;
            font-family: 'SF Mono', Monaco, 'Courier New', monospace;
            font-size: 12px;
            padding: 10px 12px;
            border: 1px solid var(--color-border);
            border-radius: 8px;
            background: var(--color-surface);
            color: var(--color-text);
            resize: none;
        }
        .embed-code-input:focus {
            outline: none;
            border-color: var(--color-primary);
        }
        .embed-code-box .btn {
            align-self: flex-start;
        }
        .embed-tips-list {
            margin: 8px 0 0 0;
            padding-left: 20px;
            font-size: 14px;
            color: var(--color-text-light);
        }
        .embed-tips-list li {
            margin-bottom: 6px;
        }
        .embed-tips-list li:last-child {
            margin-bottom: 0;
        }
        .embed-tips-list strong {
            color: var(--color-text);
        }
        .wizard-choice-cards {
            display: flex;
            flex-direction: column;
            gap: 12px;
        }
        .wizard-choice-card {
            display: flex;
            align-items: center;
            gap: 16px;
            padding: 16px 20px;
            background: var(--color-background);
            border: 2px solid var(--color-border);
            border-radius: 12px;
            cursor: pointer;
            transition: all 0.2s;
            text-align: left;
        }
        .wizard-choice-card:hover {
            border-color: var(--color-primary);
            background: white;
        }
        .choice-icon {
            font-size: 32px;
        }
        .choice-title {
            display: block;
            font-weight: 600;
            font-size: 16px;
        }
        .choice-desc {
            display: block;
            font-size: 13px;
            color: var(--color-text-light);
        }
        .wizard-instructions {
            display: flex;
            flex-direction: column;
            gap: 20px;
        }
        .instruction-step {
            display: flex;
            gap: 16px;
            align-items: flex-start;
        }
        .step-number {
            flex-shrink: 0;
            width: 32px;
            height: 32px;
            background: var(--color-primary);
            color: white;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            font-weight: 600;
        }
        .step-content {
            flex: 1;
        }
        .step-content p {
            margin: 0 0 8px 0;
        }
        .step-hint {
            font-size: 13px;
            color: var(--color-text-light);
        }
        .btn-external::after {
            content: '';
        }
        .wizard-form {
            margin-bottom: 24px;
        }
        .form-label {
            display: block;
            font-weight: 500;
            margin-bottom: 8px;
        }
        .form-input {
            width: 100%;
            padding: 12px 16px;
            font-size: 18px;
            border: 2px solid var(--color-border);
            border-radius: 8px;
            letter-spacing: 2px;
        }
        .form-input:focus {
            outline: none;
            border-color: var(--color-primary);
        }
        .form-hint {
            font-size: 13px;
            color: var(--color-text-light);
            margin-top: 8px;
        }
        .wizard-success-text {
            font-size: 18px;
            text-align: center;
            margin-bottom: 8px;
        }
        .wizard-test-section {
            margin-top: 24px;
            padding-top: 24px;
            border-top: 1px solid var(--color-border);
        }
        .wizard-test-section h4 {
            margin: 0 0 16px 0;
        }
        .wizard-test-buttons {
            display: flex;
            align-items: center;
            gap: 16px;
            margin-top: 20px;
        }
        .test-status {
            font-size: 14px;
        }
        .test-status.success {
            color: var(--color-success);
        }
        .btn-small {
            padding: 8px 16px;
            font-size: 13px;
        }

        /* Details/Summary for expandable content */
        .wizard-details {
            margin-top: 20px;
            border: 1px solid var(--color-border);
            border-radius: 8px;
            overflow: hidden;
        }
        .wizard-details summary {
            padding: 12px 16px;
            background: var(--color-background);
            cursor: pointer;
            user-select: none;
        }
        .wizard-details summary:hover {
            background: #eee;
        }
        .wizard-details[open] summary {
            border-bottom: 1px solid var(--color-border);
        }
        .wizard-details > div {
            padding: 0 16px 16px 16px;
        }

        /* Settings page additions */
        .settings-description {
            color: var(--color-text-light);
            font-size: 14px;
            margin: -8px 0 16px 0;
        }
        .coming-soon-badge {
            background: var(--color-warning);
            color: #000;
            padding: 4px 12px;
            border-radius: 20px;
            font-size: 12px;
            font-weight: 600;
        }

        /* Pixel Test Section */
        .pixel-test-section {
            margin-top: 20px;
            padding: 20px;
            background: var(--color-background);
            border-radius: 12px;
            border: 1px solid var(--color-border);
        }
        .pixel-test-section h4 {
            margin: 0 0 16px 0;
            font-size: 16px;
        }
        .pixel-test-instructions {
            margin-bottom: 16px;
        }
        .pixel-test-instructions ol {
            margin: 8px 0;
            padding-left: 20px;
        }
        .pixel-test-instructions li {
            margin: 8px 0;
            font-size: 14px;
        }
        .pixel-test-instructions a {
            color: var(--color-primary);
        }
        .pixel-test-actions {
            display: flex;
            align-items: center;
            gap: 16px;
            margin-bottom: 20px;
        }
        .pixel-test-events {
            padding-top: 16px;
            border-top: 1px solid var(--color-border);
        }
        .pixel-test-events ul {
            margin: 8px 0;
            padding-left: 20px;
        }
        .pixel-test-events li {
            margin: 6px 0;
            font-size: 14px;
        }
        .pixel-test-events code {
            background: var(--color-surface);
            padding: 2px 6px;
            border-radius: 4px;
            font-size: 13px;
            color: var(--color-primary);
        }

        /* Upgrade Cards Container */
        .upgrade-cards-container {
            display: flex;
            gap: 24px;
            margin-top: 16px;
            flex-wrap: wrap;
        }
        /* Upgrade Card - Vertical Style */
        .upgrade-card {
            background: white;
            border: 2px solid var(--color-border);
            border-radius: 16px;
            padding: 32px 28px;
            text-align: center;
            flex: 1;
            min-width: 280px;
            max-width: 350px;
            position: relative;
            transition: transform 0.2s, box-shadow 0.2s;
        }
        .upgrade-card:hover {
            transform: translateY(-4px);
            box-shadow: 0 8px 24px rgba(0,0,0,0.1);
        }
        .upgrade-card.featured {
            border-color: var(--color-primary);
            box-shadow: 0 4px 16px rgba(102, 126, 234, 0.2);
        }
        .upgrade-card-badge {
            position: absolute;
            top: -12px;
            left: 50%;
            transform: translateX(-50%);
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            color: white;
            padding: 6px 16px;
            border-radius: 20px;
            font-size: 12px;
            font-weight: 600;
            text-transform: uppercase;
            letter-spacing: 0.5px;
        }
        .upgrade-card-icon {
            font-size: 40px;
            margin-bottom: 16px;
        }
        .upgrade-card-title {
            font-size: 22px;
            font-weight: 700;
            color: var(--color-text);
            margin-bottom: 8px;
        }
        .upgrade-card-price {
            font-size: 36px;
            font-weight: 800;
            color: var(--color-primary);
            margin-bottom: 4px;
        }
        .upgrade-card-price span {
            font-size: 16px;
            font-weight: 500;
            color: var(--color-text-light);
        }
        .upgrade-card-subtitle {
            font-size: 14px;
            color: var(--color-text-light);
            margin-bottom: 24px;
        }
        .upgrade-features-list {
            list-style: none;
            padding: 0;
            margin: 0 0 24px 0;
            text-align: left;
        }
        .upgrade-features-list li {
            display: flex;
            align-items: center;
            gap: 10px;
            font-size: 14px;
            padding: 8px 0;
            border-bottom: 1px solid var(--color-border);
        }
        .upgrade-features-list li:last-child {
            border-bottom: none;
        }
        .upgrade-features-list .check-icon {
            width: 20px;
            height: 20px;
            background: rgba(102, 126, 234, 0.1);
            color: var(--color-primary);
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 11px;
            flex-shrink: 0;
        }
        .upgrade-card .btn-upgrade {
            width: 100%;
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            color: white;
            border: none;
            padding: 14px 24px;
            font-size: 16px;
            font-weight: 600;
            border-radius: 8px;
            cursor: pointer;
            transition: transform 0.2s, box-shadow 0.2s;
        }
        .upgrade-card .btn-upgrade:hover {
            transform: translateY(-2px);
            box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
        }
        .no-upgrades-message {
            color: var(--color-text-light);
            font-style: italic;
        }

        .loading-fullpage {
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            min-height: 100vh;
            gap: 16px;
        }
        .spinner {
            width: 40px;
            height: 40px;
            border: 4px solid var(--color-border);
            border-top-color: var(--color-primary);
            border-radius: 50%;
            animation: spin 1s linear infinite;
        }
        @keyframes spin {
            to { transform: rotate(360deg); }
        }

        /* Funnel Builder Styles */
        .modal-fullscreen {
            max-width: 900px;
            width: 95%;
            height: 90vh;
            max-height: 90vh;
            display: flex;
            flex-direction: column;
        }
        .builder-container {
            flex: 1;
            display: flex;
            flex-direction: column;
            overflow: hidden;
        }
        .builder-step {
            flex: 1;
            display: flex;
            flex-direction: column;
            padding: 24px 32px;
            overflow: hidden;
        }
        .builder-header {
            text-align: center;
            margin-bottom: 24px;
        }
        .builder-header h2 {
            margin: 0 0 8px 0;
            font-size: 24px;
        }
        .builder-header p {
            margin: 0;
            color: var(--color-text-light);
        }
        .builder-header.compact {
            display: flex;
            justify-content: space-between;
            align-items: center;
            text-align: left;
            padding-bottom: 16px;
            border-bottom: 1px solid var(--color-border);
            margin-bottom: 16px;
        }
        .builder-header.compact h2 {
            font-size: 18px;
            margin: 0;
        }
        .builder-header-info {
            display: flex;
            align-items: center;
            gap: 16px;
        }
        .builder-progress {
            font-size: 13px;
            color: var(--color-text-light);
            background: var(--color-background);
            padding: 4px 12px;
            border-radius: 12px;
        }
        .builder-body {
            flex: 1;
            display: flex;
            flex-direction: column;
            justify-content: center;
        }
        .builder-form {
            max-width: 500px;
            margin: 0 auto;
            width: 100%;
        }
        .form-input-large {
            font-size: 20px;
            padding: 16px 20px;
            letter-spacing: normal;
        }
        .form-error {
            color: #dc3545;
            font-size: 14px;
            margin-top: 8px;
            font-weight: 500;
        }
        .funnel-url-preview {
            margin-top: 16px;
            padding: 12px 16px;
            background: var(--color-background);
            border-radius: 8px;
            font-size: 14px;
        }
        .url-label {
            color: var(--color-text-light);
            display: block;
            margin-bottom: 4px;
        }
        .url-value {
            font-family: monospace;
            color: var(--color-primary);
            font-weight: 500;
        }
        .url-upgrade {
            margin-top: 12px;
            padding-top: 12px;
            border-top: 1px solid var(--color-border);
            display: flex;
            align-items: center;
            gap: 8px;
            font-size: 13px;
        }
        .url-upgrade-text {
            color: var(--color-text-light);
        }
        .btn-link {
            background: none;
            border: none;
            color: var(--color-primary);
            font-weight: 600;
            cursor: pointer;
            padding: 0;
            font-size: 13px;
        }
        .btn-link:hover {
            text-decoration: underline;
        }
        .builder-footer {
            display: flex;
            justify-content: space-between;
            gap: 12px;
            padding-top: 24px;
            border-top: 1px solid var(--color-border);
        }

        /* Chat Styles */
        .chat-container {
            flex: 1;
            display: flex;
            flex-direction: column;
            overflow: hidden;
            background: var(--color-background);
            border-radius: 12px;
            border: 1px solid var(--color-border);
        }
        .chat-messages {
            flex: 1;
            overflow-y: auto;
            padding: 16px;
            display: flex;
            flex-direction: column;
            gap: 12px;
        }
        .chat-message {
            max-width: 80%;
            padding: 12px 16px;
            border-radius: 16px;
            font-size: 15px;
            line-height: 1.5;
        }
        .chat-message-user {
            align-self: flex-end;
            background: var(--color-primary);
            color: white;
            border-bottom-right-radius: 4px;
        }
        .chat-message-assistant {
            align-self: flex-start;
            background: var(--color-surface);
            border: 1px solid var(--color-border);
            border-bottom-left-radius: 4px;
        }
        .chat-message-system {
            align-self: center;
            background: #fff3cd;
            color: #856404;
            font-size: 13px;
            padding: 8px 16px;
        }
        .chat-input-area {
            display: flex;
            gap: 12px;
            padding: 16px;
            border-top: 1px solid var(--color-border);
            background: var(--color-surface);
        }
        .chat-input {
            flex: 1;
            padding: 12px 16px;
            border: 2px solid var(--color-border);
            border-radius: 8px;
            font-size: 15px;
            resize: none;
            font-family: inherit;
        }
        .chat-input:focus {
            outline: none;
            border-color: var(--color-primary);
        }
        /* Chat input area buttons - same height */
        .chat-input-area .btn {
            min-height: 40px;
            height: 40px;
            padding: 8px 16px;
        }
        /* Mic Button */
        .chat-mic-btn {
            width: 40px;
            height: 40px;
            min-width: 40px;
            border: 1px solid var(--color-border);
            border-radius: 8px;
            background: var(--color-surface);
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            transition: all 0.2s ease;
            color: var(--color-text-light);
            position: relative;
            overflow: hidden;
            flex-shrink: 0;
        }
        .chat-mic-btn:hover {
            border-color: var(--color-primary);
            color: var(--color-primary);
        }
        .chat-mic-btn .mic-icon {
            width: 18px;
            height: 18px;
            transition: opacity 0.2s ease;
        }
        .chat-mic-btn .equalizer-bars {
            display: none;
            align-items: flex-end;
            justify-content: center;
            gap: 2px;
            height: 18px;
        }
        .chat-mic-btn .eq-bar {
            width: 3px;
            min-height: 3px;
            background: white;
            border-radius: 1px;
            transition: height 0.05s ease;
        }
        .chat-mic-btn .stop-label {
            display: none;
            font-size: 11px;
            font-weight: 600;
            text-transform: uppercase;
            letter-spacing: 0.5px;
        }
        .chat-mic-btn.recording {
            background: #ef4444;
            border-color: #ef4444;
            color: white;
            width: auto;
            min-width: 70px;
            padding: 0 10px;
            gap: 6px;
        }
        .chat-mic-btn.recording .mic-icon {
            display: none;
        }
        .chat-mic-btn.recording .equalizer-bars {
            display: flex;
        }
        .chat-mic-btn.recording .stop-label {
            display: block;
        }
        /* Fallback animation when no audio analysis */
        .chat-mic-btn.recording .eq-bar:nth-child(1) { animation: eq-bounce 0.6s ease-in-out infinite 0.0s; }
        .chat-mic-btn.recording .eq-bar:nth-child(2) { animation: eq-bounce 0.6s ease-in-out infinite 0.1s; }
        .chat-mic-btn.recording .eq-bar:nth-child(3) { animation: eq-bounce 0.6s ease-in-out infinite 0.2s; }
        .chat-mic-btn.recording .eq-bar:nth-child(4) { animation: eq-bounce 0.6s ease-in-out infinite 0.1s; }
        .chat-mic-btn.recording .eq-bar:nth-child(5) { animation: eq-bounce 0.6s ease-in-out infinite 0.0s; }
        @keyframes eq-bounce {
            0%, 100% { height: 4px; }
            50% { height: 16px; }
        }
        /* When audio levels are being set via JS, disable animation */
        .chat-mic-btn.recording.audio-active .eq-bar {
            animation: none;
        }
        .chat-mic-btn.processing {
            background: var(--color-primary);
            border-color: var(--color-primary);
            color: white;
            cursor: wait;
        }
        .chat-mic-btn.processing .mic-icon {
            display: block;
            animation: pulse-processing 0.8s ease-in-out infinite;
        }
        .chat-mic-btn.processing .equalizer-bars {
            display: none;
        }
        @keyframes pulse-processing {
            0%, 100% { opacity: 1; }
            50% { opacity: 0.4; }
        }
        /* First-time hint animation */
        .chat-mic-btn.hint-pulse {
            animation: hint-glow 2s ease-in-out infinite;
        }
        @keyframes hint-glow {
            0%, 100% {
                box-shadow: 0 0 0 0 rgba(99, 102, 241, 0);
                border-color: var(--color-border);
            }
            50% {
                box-shadow: 0 0 0 6px rgba(99, 102, 241, 0.3);
                border-color: var(--color-primary);
            }
        }
        .typing-indicator {
            display: flex;
            gap: 4px;
            padding: 12px 16px;
        }
        .typing-indicator span {
            width: 8px;
            height: 8px;
            background: var(--color-text-light);
            border-radius: 50%;
            animation: typing 1.4s infinite ease-in-out;
        }
        .typing-indicator span:nth-child(1) { animation-delay: -0.32s; }
        .typing-indicator span:nth-child(2) { animation-delay: -0.16s; }
        @keyframes typing {
            0%, 80%, 100% { transform: scale(0.6); opacity: 0.5; }
            40% { transform: scale(1); opacity: 1; }
        }

        /* Generating State */
        .generating-state {
            text-align: center;
            padding: 40px;
        }
        .generating-spinner {
            width: 60px;
            height: 60px;
            border: 4px solid var(--color-border);
            border-top-color: var(--color-primary);
            border-radius: 50%;
            animation: spin 1s linear infinite;
            margin: 0 auto 24px;
        }
        .generating-text {
            font-size: 18px;
            color: var(--color-text);
            margin-bottom: 32px;
        }
        .generating-steps {
            display: flex;
            flex-direction: column;
            gap: 12px;
            max-width: 300px;
            margin: 0 auto;
            text-align: left;
        }
        .gen-step {
            display: flex;
            align-items: center;
            gap: 12px;
            font-size: 14px;
            color: var(--color-text-light);
        }
        .gen-step.active {
            color: var(--color-primary);
            font-weight: 500;
        }
        .gen-step.done {
            color: var(--color-success);
        }
        .gen-step.done .gen-icon {
            color: var(--color-success);
        }

        /* Success State */
        .success-state {
            text-align: center;
            padding: 40px;
        }
        .success-icon {
            font-size: 80px;
            margin-bottom: 16px;
        }
        .success-state h3 {
            font-size: 24px;
            margin: 0 0 8px 0;
        }
        .success-url {
            margin-bottom: 32px;
        }
        .success-url a {
            color: var(--color-primary);
            font-size: 16px;
            text-decoration: none;
        }
        .success-url a:hover {
            text-decoration: underline;
        }
        .success-actions {
            display: flex;
            justify-content: center;
            gap: 16px;
        }

        .btn-success {
            background: var(--color-success);
            color: white;
        }
        .btn-success:hover {
            background: #0d8f6f;
        }

        /* Pixel Test Results */
        .pixel-test-results {
            background: var(--color-gray-50, #f9fafb);
            border-radius: 8px;
            padding: 16px;
            margin: 16px 0;
        }
        .test-result-row {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 8px 0;
            border-bottom: 1px solid var(--color-gray-200, #e5e7eb);
        }
        .test-result-row:last-child {
            border-bottom: none;
        }
        .test-label {
            font-weight: 500;
            color: var(--color-gray-700, #374151);
        }
        .test-status {
            font-size: 14px;
            padding: 4px 8px;
            border-radius: 4px;
        }
        .test-status.pending {
            color: var(--color-gray-500, #6b7280);
            background: var(--color-gray-100, #f3f4f6);
        }
        .test-status.success {
            color: var(--color-success, #10a37f);
            background: rgba(16, 163, 127, 0.1);
        }
        .test-status.error {
            color: var(--color-error, #ef4444);
            background: rgba(239, 68, 68, 0.1);
        }

        /* Token Status Box */
        .token-status-configured {
            display: flex;
            align-items: center;
            gap: 12px;
            padding: 12px 16px;
            background: rgba(16, 163, 127, 0.1);
            border: 1px solid var(--color-success, #10a37f);
            border-radius: 8px;
            color: var(--color-success, #10a37f);
            margin-bottom: 12px;
        }
        .token-status-icon {
            font-size: 18px;
        }
        .token-status-configured .btn-small {
            margin-left: auto;
            padding: 4px 12px;
            font-size: 12px;
        }

        .hidden { display: none !important; }

        /* Settings Card Grid */
        .settings-card-grid {
            display: grid;
            grid-template-columns: repeat(2, 1fr);
            gap: 16px;
            max-width: 800px;
        }
        @media (max-width: 600px) {
            .settings-card-grid {
                grid-template-columns: 1fr;
            }
        }
        .settings-card {
            display: flex;
            align-items: center;
            gap: 16px;
            padding: 20px;
            background: white;
            border: 1px solid #e5e7eb;
            border-radius: 12px;
            cursor: pointer;
            transition: all 0.2s ease;
        }
        .settings-card:hover {
            border-color: var(--primary-color, #667eea);
            box-shadow: 0 4px 12px rgba(102, 126, 234, 0.15);
            transform: translateY(-2px);
        }
        .settings-card-icon {
            font-size: 28px;
            flex-shrink: 0;
        }
        .settings-card-content {
            flex: 1;
            min-width: 0;
        }
        .settings-card-title {
            margin: 0 0 4px 0;
            font-size: 16px;
            font-weight: 600;
            color: #1f2937;
        }
        .settings-card-hint {
            margin: 0;
            font-size: 13px;
            color: #6b7280;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }
        .settings-card-hint.needs-setup {
            color: #f59e0b;
        }
        .settings-card-hint.complete {
            color: #10b981;
        }
        .settings-card-hint.optional {
            color: #9ca3af;
        }
        /* Status indicator dot */
        .status-dot {
            display: inline-block;
            width: 8px;
            height: 8px;
            border-radius: 50%;
            margin-right: 6px;
            vertical-align: middle;
        }
        .status-dot.pending {
            background: #fbbf24;
        }
        .status-dot.complete {
            background: #10b981;
        }
        .status-dot.optional {
            background: #d1d5db;
        }
        .status-dot.configured {
            background: #10b981;
        }
        .settings-card-arrow {
            font-size: 18px;
            color: #9ca3af;
            flex-shrink: 0;
        }

        /* Webhook Card Styles */
        .webhook-card {
            background: #f9fafb;
            border: 1px solid #e5e7eb;
            border-radius: 12px;
            margin-bottom: 16px;
            overflow: hidden;
        }
        .webhook-card-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 16px 20px;
            background: white;
            border-bottom: 1px solid #e5e7eb;
        }
        .webhook-card-title {
            display: flex;
            align-items: center;
            gap: 12px;
        }
        .webhook-card-title h3 {
            margin: 0;
            font-size: 16px;
            font-weight: 600;
        }
        .webhook-icon {
            font-size: 20px;
        }
        .webhook-card-body {
            padding: 20px;
        }
        .webhook-card-body.disabled {
            opacity: 0.5;
            pointer-events: none;
        }
        /* Custom Webhook Items */
        .custom-webhook-item {
            background: white;
            border: 1px solid #e5e7eb;
            border-radius: 8px;
            padding: 16px;
            margin-bottom: 12px;
        }
        .custom-webhook-item:last-child {
            margin-bottom: 0;
        }
        .custom-webhook-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 12px;
        }
        .custom-webhook-header .webhook-name-input {
            flex: 1;
            max-width: 250px;
            font-weight: 500;
        }
        .custom-webhook-actions {
            display: flex;
            align-items: center;
            gap: 12px;
        }
        .custom-webhook-fields {
            display: grid;
            grid-template-columns: 1fr auto;
            gap: 12px;
            align-items: end;
        }
        .custom-webhook-fields .form-group {
            margin-bottom: 0;
        }
        .btn-remove-webhook {
            color: #dc2626;
            background: none;
            border: none;
            cursor: pointer;
            padding: 4px 8px;
            font-size: 14px;
        }
        .btn-remove-webhook:hover {
            background: #fee2e2;
            border-radius: 4px;
        }
        .no-webhooks-message {
            text-align: center;
            padding: 24px;
            color: #6b7280;
        }
        .no-webhooks-message.hidden {
            display: none;
        }
        .no-webhooks-message p {
            margin-bottom: 12px;
        }
        #custom-webhooks-list:not(:empty) + .no-webhooks-message {
            display: none;
        }
        /* Toggle Switch */
        .toggle-switch {
            position: relative;
            display: inline-block;
            width: 48px;
            height: 26px;
        }
        .toggle-switch input {
            opacity: 0;
            width: 0;
            height: 0;
        }
        .toggle-slider {
            position: absolute;
            cursor: pointer;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background-color: #d1d5db;
            border-radius: 26px;
            transition: 0.3s;
        }
        .toggle-slider:before {
            position: absolute;
            content: "";
            height: 20px;
            width: 20px;
            left: 3px;
            bottom: 3px;
            background-color: white;
            border-radius: 50%;
            transition: 0.3s;
        }
        .toggle-switch input:checked + .toggle-slider {
            background-color: #10b981;
        }
        .toggle-switch input:checked + .toggle-slider:before {
            transform: translateX(22px);
        }
        /* Webhook Info Box */
        .webhook-info-box {
            background: #eff6ff;
            border: 1px solid #bfdbfe;
            border-radius: 8px;
            padding: 16px 20px;
            margin-top: 24px;
        }
        .webhook-info-box h4 {
            margin: 0 0 8px 0;
            font-size: 14px;
            color: #1e40af;
        }
        .webhook-info-box ul {
            margin: 0;
            padding-left: 20px;
            color: #3b82f6;
            font-size: 13px;
        }
        .webhook-info-box li {
            margin-bottom: 4px;
        }

        /* Webhook fields grid */
        .webhook-fields-grid {
            display: grid;
            grid-template-columns: repeat(2, 1fr);
            gap: 10px;
        }
        .checkbox-label {
            display: flex;
            align-items: center;
            gap: 8px;
            cursor: pointer;
            font-size: 14px;
            color: #374151;
        }
        .checkbox-label input[type="checkbox"] {
            width: 16px;
            height: 16px;
            cursor: pointer;
        }

        /* Webhook payload preview */
        .webhook-payload-preview {
            background: #1e293b;
            border-radius: 8px;
            padding: 15px;
            margin-top: 20px;
        }
        .webhook-payload-preview h4 {
            color: #94a3b8;
            margin: 0 0 10px 0;
            font-size: 13px;
            text-transform: uppercase;
            letter-spacing: 0.5px;
        }
        .webhook-payload-preview pre {
            background: #0f172a;
            color: #22d3ee;
            padding: 15px;
            border-radius: 6px;
            margin: 0;
            overflow-x: auto;
            font-size: 12px;
            line-height: 1.5;
            max-height: 300px;
            overflow-y: auto;
        }
        .webhook-test-result {
            margin-top: 12px;
            padding: 10px;
            border-radius: 6px;
            font-size: 13px;
        }
        .webhook-test-result.success {
            background: #065f46;
            color: #a7f3d0;
        }
        .webhook-test-result.error {
            background: #7f1d1d;
            color: #fecaca;
        }
        .webhook-test-result.pending {
            background: #3730a3;
            color: #c7d2fe;
        }
        .webhook-test-result:empty {
            display: none;
        }

        /* Settings Detail View */
        .settings-detail-view {
            max-width: 600px;
        }
        .settings-back-btn {
            background: none;
            border: none;
            color: var(--primary-color, #667eea);
            font-size: 14px;
            cursor: pointer;
            padding: 8px 0;
            margin-bottom: 16px;
        }
        .settings-back-btn:hover {
            text-decoration: underline;
        }
        .settings-detail-view h2 {
            margin: 0 0 8px 0;
            font-size: 24px;
            color: #1f2937;
        }
        .section-description {
            color: #6b7280;
            margin: 0 0 24px 0;
            font-size: 14px;
        }
        .settings-form {
            background: white;
            border: 1px solid #e5e7eb;
            border-radius: 12px;
            padding: 24px;
        }
        .form-group {
            margin-bottom: 20px;
        }
        .form-group:last-child {
            margin-bottom: 0;
        }
        .form-group label {
            display: block;
            font-weight: 500;
            color: #374151;
            margin-bottom: 6px;
            font-size: 14px;
        }
        .form-input {
            width: 100%;
            padding: 10px 14px;
            border: 1px solid #d1d5db;
            border-radius: 8px;
            font-size: 14px;
            transition: border-color 0.2s;
            box-sizing: border-box;
        }
        .form-input:focus {
            outline: none;
            border-color: var(--primary-color, #667eea);
            box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
        }
        .form-input:disabled {
            background: #f3f4f6;
            color: #6b7280;
        }
        .form-hint {
            font-size: 12px;
            color: #9ca3af;
            margin: 4px 0 0 0;
        }
        .form-actions {
            display: flex;
            gap: 12px;
            margin-top: 24px;
            padding-top: 20px;
            border-top: 1px solid #e5e7eb;
        }

        /* URL List for funnel URLs */
        .url-list {
            display: flex;
            flex-direction: column;
            gap: 8px;
            margin-bottom: 12px;
        }
        .url-item {
            display: flex;
            align-items: center;
            gap: 8px;
            padding: 8px 12px;
            background: #f9fafb;
            border-radius: 6px;
            font-size: 13px;
        }
        .url-item a {
            flex: 1;
            color: var(--primary-color, #667eea);
            text-decoration: none;
            overflow: hidden;
            text-overflow: ellipsis;
            white-space: nowrap;
        }
        .url-item .remove-url {
            background: none;
            border: none;
            color: #ef4444;
            cursor: pointer;
            padding: 4px;
            font-size: 16px;
        }
        .url-add-row {
            display: flex;
            gap: 8px;
        }
        .url-add-row .form-input {
            flex: 1;
        }

        /* Tracking Cards */
        .tracking-card {
            background: white;
            border: 1px solid #e5e7eb;
            border-radius: 12px;
            overflow: hidden;
        }
        .tracking-card-header {
            display: flex;
            align-items: center;
            gap: 12px;
            padding: 16px 20px;
            background: #f9fafb;
            border-bottom: 1px solid #e5e7eb;
        }
        .tracking-icon {
            font-size: 24px;
        }
        .tracking-card-header h3 {
            margin: 0;
            font-size: 16px;
            font-weight: 600;
        }
        .tracking-status {
            font-size: 12px;
            padding: 2px 8px;
            border-radius: 4px;
            background: #fef3c7;
            color: #92400e;
        }
        .tracking-status.active,
        .tracking-status.tested,
        .tracking-status.configured {
            background: #d1fae5;
            color: #065f46;
        }
        .tracking-card-body {
            padding: 16px 20px;
        }
        .tracking-card-actions {
            padding: 0 20px 20px 20px;
        }

        /* Plan Card */
        .plan-current-card {
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            border-radius: 12px;
            padding: 24px;
            color: white;
            margin-bottom: 24px;
        }
        .plan-badge {
            display: inline-block;
            background: rgba(255,255,255,0.2);
            padding: 4px 12px;
            border-radius: 20px;
            font-size: 12px;
            font-weight: 600;
            margin-bottom: 8px;
        }
        .plan-current-card h3 {
            margin: 0 0 16px 0;
            font-size: 24px;
        }
        .plan-details {
            display: grid;
            grid-template-columns: repeat(2, 1fr);
            gap: 12px;
        }
        @media (max-width: 500px) {
            .plan-details {
                grid-template-columns: 1fr;
            }
        }
        .plan-detail-row {
            display: flex;
            justify-content: space-between;
            padding: 8px 12px;
            background: rgba(255,255,255,0.1);
            border-radius: 6px;
            font-size: 14px;
        }
        .plan-detail-row span:last-child {
            font-weight: 600;
        }

        /* Security Section Styles */
        .security-status-card {
            background: linear-gradient(135deg, #065f46 0%, #047857 100%);
            border-radius: 12px;
            padding: 24px;
            color: white;
            margin-bottom: 20px;
        }
        .security-status-header {
            display: flex;
            align-items: center;
            gap: 12px;
            margin-bottom: 16px;
        }
        .security-icon {
            font-size: 32px;
        }
        .security-status-header h3 {
            margin: 0;
            font-size: 18px;
            font-weight: 600;
        }
        .security-status-body {
            background: rgba(255,255,255,0.1);
            border-radius: 8px;
            padding: 16px;
            margin-bottom: 16px;
        }
        .security-status-row {
            display: flex;
            justify-content: space-between;
            padding: 8px 0;
        }
        .security-status-row:not(:last-child) {
            border-bottom: 1px solid rgba(255,255,255,0.1);
        }
        .security-status-row span:last-child {
            font-weight: 600;
        }
        .encryption-enabled {
            color: #a7f3d0;
        }
        .encryption-disabled {
            color: #fca5a5;
        }
        .security-description {
            font-size: 14px;
            opacity: 0.9;
            line-height: 1.5;
            margin: 0;
        }
        .security-info-box {
            background: #f0fdf4;
            border: 1px solid #bbf7d0;
            border-radius: 8px;
            padding: 16px;
        }
        .security-info-box h4 {
            margin: 0 0 12px 0;
            color: #065f46;
            font-size: 14px;
        }
        .security-info-box ul {
            margin: 0;
            padding-left: 20px;
            color: #166534;
            font-size: 14px;
        }
        .security-info-box li {
            margin-bottom: 6px;
        }
        .security-info-box li:last-child {
            margin-bottom: 0;
        }

        /* Lead Badges */
        .lead-badge {
            display: inline-block;
            padding: 2px 6px;
            border-radius: 4px;
            font-size: 10px;
            font-weight: 600;
            text-transform: uppercase;
            margin-right: 8px;
            vertical-align: middle;
        }
        .lead-badge-test {
            background: #fef3c7;
            color: #92400e;
        }
        .lead-badge-actual {
            background: #d1fae5;
            color: #065f46;
        }
        .lead-row-test {
            background: #fffbeb;
        }
        .lead-row-test:hover {
            background: #fef3c7;
        }
        .lead-badge-inprogress {
            background: #dbeafe;
            color: #1e40af;
        }
        .lead-row-inprogress {
            background: #eff6ff;
        }
        .lead-row-inprogress:hover {
            background: #dbeafe;
        }

        /* Lead Filter Tabs */
        .leads-filter-tabs {
            display: flex;
            gap: 8px;
            margin-bottom: 16px;
            padding: 4px;
            background: #f3f4f6;
            border-radius: 8px;
            width: fit-content;
        }
        .filter-tab {
            padding: 8px 16px;
            border: none;
            background: transparent;
            border-radius: 6px;
            font-size: 14px;
            font-weight: 500;
            color: #6b7280;
            cursor: pointer;
            transition: all 0.2s;
        }
        .filter-tab:hover {
            color: #374151;
            background: #e5e7eb;
        }
        .filter-tab.active {
            background: white;
            color: #111827;
            box-shadow: 0 1px 3px rgba(0,0,0,0.1);
        }
        .tab-count {
            display: inline-block;
            padding: 1px 6px;
            border-radius: 10px;
            background: #e5e7eb;
            font-size: 11px;
            font-weight: 600;
            margin-left: 4px;
        }
        .filter-tab.active .tab-count {
            background: #f3f4f6;
        }

        /* Webhook Status */
        .status-badge {
            display: inline-flex;
            align-items: center;
            gap: 4px;
            padding: 3px 8px;
            border-radius: 4px;
            font-size: 11px;
            font-weight: 500;
        }
        .status-badge-success {
            background: #d1fae5;
            color: #065f46;
        }
        .status-badge-failed {
            background: #fee2e2;
            color: #991b1b;
        }
        .status-badge-pending {
            background: #fef3c7;
            color: #92400e;
        }
        .status-badge-none {
            background: #f3f4f6;
            color: #6b7280;
        }
        .status-icon {
            width: 12px;
            height: 12px;
        }

        /* Encrypted Data Display */
        .encrypted-email {
            display: inline-flex;
            align-items: center;
            gap: 4px;
            color: #6b7280;
            cursor: help;
        }
        .encrypted-lock {
            color: #9ca3af;
            flex-shrink: 0;
        }
        .encrypted-email:hover .encrypted-lock {
            color: #6b7280;
        }
        .encrypted-indicator {
            display: inline-flex;
            align-items: center;
            vertical-align: middle;
            cursor: help;
        }
        .encrypted-indicator .encrypted-lock {
            color: #10b981;
        }

        /* Delete Confirmation Modal */
        .delete-confirm-overlay {
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: rgba(0, 0, 0, 0.6);
            display: flex;
            align-items: center;
            justify-content: center;
            z-index: 2000;
            opacity: 0;
            visibility: hidden;
            transition: opacity 0.2s, visibility 0.2s;
        }
        .delete-confirm-overlay.active {
            opacity: 1;
            visibility: visible;
        }
        .delete-confirm-modal {
            background: white;
            border-radius: 12px;
            max-width: 420px;
            width: 90%;
            box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.2);
            transform: scale(0.95);
            transition: transform 0.2s;
        }
        .delete-confirm-overlay.active .delete-confirm-modal {
            transform: scale(1);
        }
        .delete-confirm-header {
            padding: 20px 24px 0;
        }
        .delete-confirm-header h3 {
            margin: 0;
            font-size: 18px;
            color: #dc2626;
        }
        .delete-confirm-body {
            padding: 16px 24px;
        }
        .delete-confirm-body p {
            margin: 0 0 12px;
            color: #374151;
        }
        .delete-confirm-warning {
            color: #dc2626 !important;
            font-weight: 500;
            font-size: 14px;
        }
        .delete-confirm-input-group {
            margin-top: 16px;
        }
        .delete-confirm-input-group label {
            display: block;
            margin-bottom: 8px;
            font-size: 14px;
            color: #6b7280;
        }
        .delete-confirm-input-group strong {
            color: #dc2626;
            font-family: monospace;
            background: #fee2e2;
            padding: 2px 6px;
            border-radius: 4px;
        }
        .delete-confirm-input-group input {
            width: 100%;
            box-sizing: border-box;
        }
        .delete-confirm-countdown {
            margin-top: 12px;
            font-size: 14px;
            color: #6b7280;
            text-align: center;
            min-height: 20px;
        }
        .delete-confirm-countdown.ready {
            color: #059669;
            font-weight: 500;
        }
        .delete-confirm-actions {
            display: flex;
            gap: 12px;
            padding: 16px 24px 24px;
            justify-content: flex-end;
        }
        .delete-confirm-actions .btn-danger {
            background: #dc2626;
            color: white;
        }
        .delete-confirm-actions .btn-danger:hover:not(:disabled) {
            background: #b91c1c;
        }
        .delete-confirm-actions .btn-danger:disabled {
            background: #fca5a5;
            cursor: not-allowed;
        }

        /* Lead Details Modal */
        .lead-modal-overlay {
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: rgba(0, 0, 0, 0.5);
            display: flex;
            align-items: center;
            justify-content: center;
            z-index: 1000;
            opacity: 0;
            visibility: hidden;
            transition: opacity 0.2s, visibility 0.2s;
        }
        .lead-modal-overlay.active {
            opacity: 1;
            visibility: visible;
        }
        .lead-modal {
            background: white;
            border-radius: 12px;
            max-width: 600px;
            width: 90%;
            max-height: 80vh;
            overflow-y: auto;
            box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
            transform: scale(0.95);
            transition: transform 0.2s;
        }
        .lead-modal-overlay.active .lead-modal {
            transform: scale(1);
        }
        .lead-modal-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 20px 24px;
            border-bottom: 1px solid #e5e7eb;
            position: sticky;
            top: 0;
            background: white;
            z-index: 10;
        }
        .lead-modal-header h3 {
            margin: 0;
            font-size: 18px;
            font-weight: 600;
        }
        .lead-modal-close {
            background: none;
            border: none;
            cursor: pointer;
            padding: 4px;
            color: #6b7280;
        }
        .lead-modal-close:hover {
            color: #111827;
        }
        .lead-modal-body {
            padding: 24px;
        }
        .lead-detail-section {
            margin-bottom: 24px;
        }
        .lead-detail-section:last-child {
            margin-bottom: 0;
        }
        .lead-delete-section {
            margin-top: 32px;
            padding-top: 24px;
            border-top: 1px solid #e5e7eb;
        }
        .lead-detail-section h4 {
            font-size: 12px;
            font-weight: 600;
            text-transform: uppercase;
            letter-spacing: 0.05em;
            color: #6b7280;
            margin: 0 0 12px 0;
        }
        .lead-detail-grid {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 12px;
        }
        .lead-detail-item {
            background: #f9fafb;
            padding: 12px;
            border-radius: 8px;
        }
        .lead-detail-item.full-width {
            grid-column: 1 / -1;
        }
        .lead-detail-label {
            font-size: 11px;
            color: #6b7280;
            margin-bottom: 4px;
        }
        .lead-detail-value {
            font-size: 14px;
            color: #111827;
            word-break: break-word;
        }
        .lead-answers-list {
            display: flex;
            flex-direction: column;
            gap: 8px;
        }
        .lead-answer-item {
            background: #f9fafb;
            padding: 12px;
            border-radius: 8px;
        }
        .lead-answer-question {
            font-size: 13px;
            color: #374151;
            margin-bottom: 4px;
        }
        .lead-answer-value {
            font-size: 14px;
            color: #111827;
            font-weight: 500;
        }
        .webhook-log-item {
            background: #f9fafb;
            padding: 12px;
            border-radius: 8px;
            margin-bottom: 8px;
        }
        .webhook-log-item:last-child {
            margin-bottom: 0;
        }
        .webhook-log-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 4px;
        }
        .webhook-log-name {
            font-weight: 500;
            font-size: 14px;
        }
        .webhook-log-status {
            font-size: 12px;
            padding: 2px 8px;
            border-radius: 4px;
        }
        .webhook-log-status.success {
            background: #d1fae5;
            color: #065f46;
        }
        .webhook-log-status.failed {
            background: #fee2e2;
            color: #991b1b;
        }
        .webhook-log-status.pending {
            background: #f3f4f6;
            color: #6b7280;
        }
        .webhook-log-time {
            font-size: 12px;
            color: #6b7280;
        }
        .webhook-log-actions {
            display: flex;
            align-items: center;
            gap: 8px;
        }
        .webhook-log-error {
            font-size: 12px;
            color: #991b1b;
            background: #fee2e2;
            padding: 4px 8px;
            border-radius: 4px;
            margin-top: 6px;
        }
        .webhook-history {
            margin-top: 8px;
            padding-top: 8px;
            border-top: 1px solid #f3f4f6;
        }
        .webhook-history-entry {
            display: flex;
            align-items: center;
            gap: 12px;
            padding: 4px 0;
            font-size: 13px;
        }
        .webhook-history-label {
            color: #6b7280;
            min-width: 50px;
        }
        .webhook-history-time {
            color: #374151;
            flex: 1;
        }
        .btn-ghost {
            background: transparent;
            border: 1px solid #d1d5db;
            color: #6b7280;
        }
        .btn-ghost:hover {
            background: #f3f4f6;
        }
        .btn-full {
            width: 100%;
        }

        /* Conversion log styles (for FB pixel events) */
        .conversion-log-item {
            background: #f0f9ff;
            padding: 12px;
            border-radius: 8px;
            margin-bottom: 8px;
            border-left: 3px solid #3b82f6;
        }
        .conversion-log-item:last-child {
            margin-bottom: 0;
        }
        .conversion-log-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 4px;
        }
        .conversion-log-name {
            font-weight: 500;
            font-size: 14px;
        }
        .conversion-log-status {
            font-size: 12px;
            padding: 2px 8px;
            border-radius: 4px;
        }
        .conversion-log-status.success {
            background: #d1fae5;
            color: #065f46;
        }
        .conversion-log-status.failed {
            background: #fee2e2;
            color: #991b1b;
        }
        .conversion-log-time {
            font-size: 12px;
            color: #6b7280;
        }
        .conversion-log-eventid {
            font-size: 11px;
            color: #6b7280;
            font-family: monospace;
            margin-top: 4px;
        }
        .conversion-log-error {
            font-size: 12px;
            color: #991b1b;
            background: #fee2e2;
            padding: 4px 8px;
            border-radius: 4px;
            margin-top: 6px;
        }

        /* Custom Domain Modal Styles */
        .modal-medium {
            max-width: 500px;
        }
        .domain-input-section {
            margin-bottom: 24px;
        }
        .domain-dns-section {
            background: var(--color-bg);
            border-radius: 8px;
            padding: 20px;
            margin-top: 20px;
        }
        .domain-dns-section h3 {
            font-size: 14px;
            font-weight: 600;
            margin: 0 0 8px 0;
            color: var(--color-text);
        }
        .domain-dns-section h3:not(:first-child) {
            margin-top: 20px;
        }
        .domain-dns-section p {
            font-size: 13px;
            color: var(--color-text-light);
            margin: 0 0 12px 0;
        }
        .dns-record-table {
            width: 100%;
            border-collapse: collapse;
            font-size: 13px;
            margin-bottom: 12px;
        }
        .dns-record-table th {
            text-align: left;
            padding: 8px 12px;
            background: var(--color-surface);
            border: 1px solid var(--color-border);
            font-weight: 500;
            color: var(--color-text-light);
        }
        .dns-record-table td {
            padding: 10px 12px;
            border: 1px solid var(--color-border);
            background: white;
        }
        .dns-record-table code {
            background: #f3f4f6;
            padding: 2px 6px;
            border-radius: 4px;
            font-family: 'SF Mono', Monaco, Consolas, monospace;
            font-size: 12px;
            color: #1f2937;
        }
        .domain-verify-status {
            margin-top: 16px;
            padding: 12px 16px;
            border-radius: 8px;
            font-size: 13px;
        }
        .domain-verify-status.success {
            background: #d1fae5;
            color: #065f46;
        }
        .domain-verify-status.error {
            background: #fee2e2;
            color: #991b1b;
        }
        .domain-verify-status.checking {
            background: #e0e7ff;
            color: #3730a3;
        }
        .dns-copy-btn {
            font-size: 11px;
            padding: 2px 8px;
            margin-left: 8px;
            background: var(--color-primary);
            color: white;
            border: none;
            border-radius: 4px;
            cursor: pointer;
            transition: all 0.2s;
        }
        .dns-copy-btn:hover {
            background: var(--color-primary-dark, #5a67d8);
        }
        .dns-copy-btn.copied {
            background: #10b981;
        }
        /* Current funnel display */
        .domain-current-funnel {
            background: #f0fdf4;
            border: 1px solid #bbf7d0;
            border-radius: 8px;
            padding: 12px 16px;
            margin-bottom: 20px;
            display: flex;
            align-items: center;
            gap: 8px;
        }
        .domain-label {
            font-size: 13px;
            color: #166534;
        }
        .domain-funnel-url {
            font-family: 'SF Mono', Monaco, Consolas, monospace;
            font-size: 14px;
            font-weight: 600;
            color: #15803d;
        }
        /* Connection visual */
        .domain-connection-visual {
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 16px;
            margin: 20px 0;
            padding: 16px;
            background: linear-gradient(135deg, #eff6ff 0%, #f0fdf4 100%);
            border-radius: 12px;
        }
        .connection-box {
            background: white;
            border-radius: 8px;
            padding: 12px 16px;
            text-align: center;
            min-width: 140px;
            box-shadow: 0 2px 8px rgba(0,0,0,0.08);
        }
        .connection-from {
            border: 2px solid #3b82f6;
        }
        .connection-to {
            border: 2px solid #22c55e;
        }
        .connection-label {
            display: block;
            font-size: 11px;
            text-transform: uppercase;
            letter-spacing: 0.5px;
            color: #6b7280;
            margin-bottom: 4px;
        }
        .connection-url {
            font-family: 'SF Mono', Monaco, Consolas, monospace;
            font-size: 12px;
            font-weight: 600;
            color: #1f2937;
            word-break: break-all;
        }
        .connection-arrow {
            font-size: 24px;
            color: #9ca3af;
        }
        .dns-tips {
            margin-top: 16px;
            padding: 12px;
            background: #fef3c7;
            border: 1px solid #fcd34d;
            border-radius: 6px;
        }
        .dns-tips p {
            margin: 0;
            font-size: 13px;
            color: #92400e;
        }
        .dns-tips .form-hint {
            margin-top: 8px;
            color: #a16207;
        }
