/* Custom Feed Attribute Dropdown Button Styling */
.rex-feed-attr-btn-area.custom-attr-dropdown-btn,
.custom-attr-dropdown-btn {
    display: flex;
    gap: 10px;
    align-items: center;
    font-family: "Roboto";
    font-style: normal;
    font-weight: 500;
    font-size: 15px;
    line-height: 1.2;
    letter-spacing: 0.2px;
    color: #333333;
    cursor: pointer;
    padding: 6px 5px 6px 25px;
    text-align: center;
    white-space: nowrap;
    vertical-align: middle;
    user-select: none;
    background-color: transparent;
    text-transform: capitalize;
    transition: all 0.2s ease-in-out;
    border: 1px solid #206DEF;
    border-radius: 10px;
    touch-action: manipulation;
}
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background: #ffffff;
}

/* =========================================
   WELCOME STEP (centered card layout)
   ========================================= */

.welcome-app {
    min-height: 100vh;
    background: #f6f4ff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
}

.welcome-wrapper {
    width: 100%;
    max-width: 1170px;
}

.welcome-exit {
    text-align: right;
    font-size: 14px;
    color: #76708c;
    cursor: pointer;
    margin-bottom: 8px;
}

.welcome-card {
    background: white;
    border: 1px solid #e8e1ff;
    box-shadow: 0px 10px 70px rgba(25, 10, 99, 0.1);
    padding: 60px 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 60px;
}

.welcome-logo {
    width: 88px;
    height: auto;
}

.welcome-logo img {
    width: 100%;
    height: 100%;
}

.welcome-content {
    text-align: center;
    max-width: 752px;
}

.welcome-content h1 {
    font-size: 32px;
    font-weight: 600;
    color: #201cfe;
    margin: 0 0 10px;
}

.welcome-description {
    font-size: 16px;
    color: #76708c;
    line-height: 30px;
    margin: 0;
}

.primary-btn {
    background: #201cfe;
    border: none;
    padding: 16px 35px;
    color: white;
    font-size: 18px;
    font-family: 'Inter', sans-serif;
    cursor: pointer;
    transition: opacity 0.2s;
}

.primary-btn:hover {
    opacity: 0.9;
}

.consent {
    display: flex;
    gap: 12px;
    max-width: 542px;
    align-items: flex-start;
    cursor: pointer;
    margin-top: 8px;
}

.consent input {
    display: none;
}

.custom-checkbox {
    width: 20px;
    height: 20px;
    min-width: 20px;
    border-radius: 4px;
    background: #ffffff;
    border: 2px solid #d0c9e8;
    position: relative;
    flex-shrink: 0;
    margin-top: 2px;
    transition: all 0.2s ease;
}

.consent:hover .custom-checkbox {
    border-color: #201cfe;
}

.consent input:checked + .custom-checkbox {
    background: #201cfe;
    border-color: #201cfe;
}

.consent input:checked + .custom-checkbox::after {
    content: "";
    position: absolute;
    left: 6px;
    top: 2px;
    width: 4px;
    height: 9px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.consent-text {
    font-size: 14px;
    color: #76708c;
    line-height: 1.5;
}

/* =========================================
   SIDEBAR LAYOUT (steps 2, 3, 4, 5)
   ========================================= */

/* Onboarding app container layout */
#onboarding-app {
    min-height: 100vh;
    position: relative;
}

/* Container for steps with sidebar (steps 2-5) */
#onboarding-app.sidebar-visible {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 0 20px;
    background: #f6f4ff;
    max-width: 1170px;
    margin: 40px auto;
    box-shadow: 0px 10px 70px rgba(25, 10, 99, 0.1);
    background: white;
}

/* LEFT SIDEBAR - Relative positioning within container */
.sidebar {
    width: 250px;
    min-width: 250px;
    background: white;
    border-right: 1px solid #f1eeff;
    padding: 60px 20px;
    display: none;
    flex-direction: column;
    gap: 28px;
}

/* Show sidebar when sidebar-visible class is added */
#onboarding-app.sidebar-visible .sidebar {
    display: flex;
}

.sidebar-logo {
    width: 88px;
    height: auto;
    margin-bottom: 40px;
}

.sidebar-logo img {
    width: 100%;
    height: 100%;
}

/* NAV ITEMS IN SIDEBAR */
.nav-steps {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 5px;
    color: #76708c;
    font-size: 14px;
    font-weight: 400;
    cursor: pointer;
    transition: all 0.2s;
    border-radius: 8px;
    white-space: nowrap;
}

.nav-item:hover {
    background: #f6f4ff;
}

.nav-item.active {
    color: #201cfe;
    font-weight: 500;
    background: #FFF;
    padding: 10px;
    border: 1px solid #F1EEFF;
    border-radius: 30px;
    margin-left: -15px;
    width: 90%;
}

.nav-item.completed {
    color: #239654;
}

/* Circle indicators for nav items */
.nav-item .nav-circle {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #ede9ff;
    color: #0e003c;
    font-size: 12px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.nav-item.active .nav-circle {
    background: #201cfe;
    color: white;
    font-weight: 700;
}

.nav-item.completed .nav-circle {
    background: #239654;
    color: white;
    font-size: 14px;
}

.nav-item.completed .nav-circle svg,
.nav-item.active .nav-circle svg {
    width: 11px;
    height: 7px;
}

.nav-item.completed .nav-circle svg path,
.nav-item.active .nav-circle svg path {
    fill: white;
    stroke: white;
}

/* STEP SECTIONS */
.step {
    display: none;
}

.step.active {
    display: block;
}

/* RIGHT CONTENT AREA */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
    min-height: 100vh;
}

/* Content area when sidebar is visible */
#onboarding-app.sidebar-visible .main-content {
    padding: 60px;
    min-height: auto;
    position: relative;
}

.exit {
    display: block;
    width: 100%;
    text-align: right;
    font-family: 'Inter', sans-serif;
    font-weight: 400;
    font-size: 14px;
    color: #76708c;
    cursor: pointer;
    margin-bottom: 8px;
    transition: color 0.2s;
}

#wizardExit {
    display: none;
    position: absolute;
    top: 0;
    right: 0;
    transform: translateY(calc(-100% - 10px));
    width: auto;
    margin-bottom: 0;
    z-index: 20;
}

.exit:hover {
    color: #201cfe;
}

.card {
    flex: 1;
    background: white;
    padding: 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 24px;
}

/* Card styling when sidebar is visible */
#onboarding-app.sidebar-visible .card {
    background: transparent;
    box-shadow: none;
}

/* =========================================
   MERCHANT SELECT STEP
   ========================================= */

/* SECTION TITLES */
.section-title {
    font-size: 16px;
    font-weight: 600;
    color: #0e003c;
    margin: 0 0 16px;
}

/* POPULAR SECTION */
.popular-section {
    margin-top: 24px;
}

.popular-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 16px;
    margin-bottom: 24px;    padding: 4px;}

/* MERCHANTS INFO BANNER */
.merchants-info-banner {
    display: flex;
    gap: 16px;
    padding: 20px 24px;
    background: linear-gradient(135deg, #f0edff 0%, #fbfaff 100%);
    border: 1px solid #e8e1ff;
    border-radius: 12px;
    align-items: flex-start;
    margin-top: 24px;
}

.info-icon {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    background: white;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.info-content {
    flex: 1;
}

.info-title {
    font-size: 15px;
    font-weight: 600;
    color: #0e003c;
    margin: 0 0 4px;
}

.info-description {
    font-size: 14px;
    color: #76708c;
    margin: 0;
    line-height: 1.5;
}

/* SEARCH BOX */
.search-box {
    position: relative;
    display: flex;
    align-items: center;
    margin-bottom: 16px;
}

.search-icon {
    position: absolute;
    left: 16px;
    pointer-events: none;
}

.search-box input {
    width: 100%;
    padding: 14px 16px 14px 44px;
    border: 1px solid #e8e1ff;
    border-radius: 10px;
    font-family: Inter, sans-serif;
    font-size: 15px;
    color: #0e003c;
    outline: none;
    transition: border-color 0.2s;
    background: #fbfaff;
}

.search-box input::placeholder {
    color: #76708c;
}

.search-box input:focus {
    border-color: #201cfe;
    background: white;
}

/* SEARCH RESULTS CONTAINER */
.search-results-container {
    margin-bottom: 24px;
}

/* SEARCH RESULTS GRID */
.search-results-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 16px;
    max-height: 400px;
    overflow-y: auto;
    padding: 4px;
}

.search-results-grid::-webkit-scrollbar {
    width: 6px;
}

.search-results-grid::-webkit-scrollbar-track {
    background: #f6f4ff;
    border-radius: 3px;
}

.search-results-grid::-webkit-scrollbar-thumb {
    background: #e8e1ff;
    border-radius: 3px;
}

.search-results-grid::-webkit-scrollbar-thumb:hover {
    background: #d4ccff;
}

.search-empty {
    grid-column: 1 / -1;
    text-align: center;
    padding: 48px 20px;
    color: #76708c;
    font-size: 14px;
}

/* MERCHANT CARDS - POPULAR */
.popular-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 20px 16px;
    border: 2px solid #e8e1ff;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
    background: white;
    position: relative;
}

.popular-card:hover {
    border-color: #201cfe;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(63, 4, 254, 0.1);
}

.popular-card.selected {
    border-color: #201cfe;
    background: #f0edff;
    box-shadow: 0 4px 12px rgba(63, 4, 254, 0.15);
}

.merchant-logo {
    width: 56px;
    height: 56px;
    border-radius: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 22px;
    font-weight: 600;
    color: white;
    text-transform: uppercase;
    object-fit: contain;
}

.popular-card .merchant-name {
    font-size: 14px;
    font-weight: 500;
    color: #0e003c;
    text-align: center;
    line-height: 1.3;
}

.popular-card .merchant-check {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #201cfe;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    opacity: 0;
    transform: scale(0.5);
    transition: all 0.2s;
}

.popular-card.selected .merchant-check {
    opacity: 1;
    transform: scale(1);
}

.popular-card .merchant-check svg {
    width: 12px;
    height: 12px;
}

/* MERCHANT CARDS - SEARCH RESULTS (matching popular style) */
.result-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 20px 16px;
    border: 2px solid #e8e1ff;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
    background: white;
    position: relative;
}

.result-card:hover:not(.disabled) {
    border-color: #201cfe;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(63, 4, 254, 0.1);
}

.result-card.selected {
    border-color: #201cfe;
    background: #f0edff;
    box-shadow: 0 4px 12px rgba(63, 4, 254, 0.15);
}

.result-card.disabled {
    cursor: not-allowed;
    opacity: 0.6;
    background: #f9f9f9;
}

.result-card.disabled:hover {
    transform: none;
    box-shadow: none;
}

/* Monogram Avatar - Squircle Style */
.merchant-monogram {
    width: 56px;
    height: 56px;
    border-radius: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 22px;
    font-weight: 600;
    color: white;
    text-transform: uppercase;
}

/* Monogram color variations - Modern palette */
.monogram-color-1 { background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); }
.monogram-color-2 { background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%); }
.monogram-color-3 { background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%); }
.monogram-color-4 { background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%); }
.monogram-color-5 { background: linear-gradient(135deg, #fa709a 0%, #fee140 100%); }
.monogram-color-6 { background: linear-gradient(135deg, #30cfd0 0%, #330867 100%); }
.monogram-color-7 { background: linear-gradient(135deg, #a8edea 0%, #fed6e3 100%); }
.monogram-color-8 { background: linear-gradient(135deg, #ff9a56 0%, #ff6a88 100%); }
.monogram-color-9 { background: linear-gradient(135deg, #ffecd2 0%, #fcb69f 100%); }
.monogram-color-10 { background: linear-gradient(135deg, #ff6e7f 0%, #bfe9ff 100%); }

.result-card .merchant-name {
    font-size: 14px;
    font-weight: 500;
    color: #0e003c;
    text-align: center;
    line-height: 1.3;
    width: 100%;
}

.result-card .merchant-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    padding: 4px 8px;
    background: #206DF0;
    color: white;
    font-size: 10px;
    font-weight: 700;
    border-radius: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.result-card .merchant-check {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #201cfe;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    opacity: 0;
    transform: scale(0.5);
    transition: all 0.2s;
}

.result-card.selected .merchant-check {
    opacity: 1;
    transform: scale(1);
}

.result-card .merchant-check svg {
    width: 12px;
    height: 12px;
}

/* Responsive adjustments */
@media (max-width: 1200px) {
    .popular-grid,
    .search-results-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .popular-grid,
    .search-results-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* =========================================
   CREATE FEED STEP
   ========================================= */

#feedSettingsForm {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    font-weight: 500;
    color: #0e003c;
}

.form-label svg {
    color: #201cfe;
}

.form-input {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid #e8e1ff;
    border-radius: 10px;
    font-family: Inter, sans-serif;
    font-size: 15px;
    color: #0e003c;
    background: #fbfaff;
    outline: none;
    transition: border-color 0.2s;
}

.form-input::placeholder {
    color: #76708c;
}

.form-input:focus {
    border-color: #201cfe;
}

.select-wrapper {
    position: relative;
}

.form-select {
    width: 100%;
    padding: 14px 40px 14px 16px;
    border: 1px solid #e8e1ff;
    border-radius: 10px;
    font-family: Inter, sans-serif;
    font-size: 15px;
    font-weight: 500;
    color: #0e003c;
    background: #fbfaff;
    outline: none;
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
    transition: border-color 0.2s;
}

.form-select:focus {
    border-color: #201cfe;
}

.select-arrow {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
}

.form-hint {
    font-size: 13px;
    color: #76708c;
}

/* =========================================
   COMPLETE STEP (Upsell Layout)
   ========================================= */

.complete-upsell-app {
    min-height: 100vh;
    background: #f6f4ff;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 60px 20px;
}

.complete-upsell-wrapper {
    width: 100%;
    max-width: 740px;
}

/* Header */
.complete-upsell-header {
    text-align: center;
    margin-bottom: 28px;
}

/* Feed info card */
.feed-info-card {
    background: white;
    border: 1px solid #e8e1ff;
    border-radius: 12px;
    padding: 20px 24px;
    margin-top: 16px;
    margin-bottom: 24px;
}

.feed-info-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 600;
    color: #6b6b8a;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 8px;
}

.feed-info-label svg {
    flex-shrink: 0;
    color: #201cfe;
}

.feed-info-format-badge {
    background: #ede9fe;
    color: #201cfe;
    font-size: 10px;
    font-weight: 700;
    padding: 1px 7px;
    border-radius: 20px;
    letter-spacing: 0.05em;
}

.feed-info-url-wrap {
    display: flex;
    align-items: center;
    gap: 6px;
}

.feed-info-url-input {
    flex: 1;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 9px 12px;
    font-size: 13px;
    color: #374151;
    background: #f8fafc;
    outline: none;
    min-width: 0;
    font-family: monospace;
}

.feed-info-url-input:focus {
    border-color: #201cfe;
    background: white;
}

.feed-info-actions {
    display: flex;
    gap: 4px;
    flex-shrink: 0;
}

.feed-info-icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    background: white;
    color: #6b6b8a;
    text-decoration: none;
    transition: background 0.15s, border-color 0.15s, color 0.15s;
}

.feed-info-icon-btn:hover {
    background: #f1f0ff;
    border-color: #201cfe;
    color: #201cfe;
}


.complete-upsell-title {
    font-size: 26px;
    font-weight: 700;
    color: #0e003c;
    line-height: 1.35;
    margin: 0 0 16px;
}

.complete-upsell-title-blue {
    color: #201cfe;
}

.complete-upsell-desc {
    font-size: 14px;
    color: #76708c;
    line-height: 1.7;
    margin: 0;
}

.complete-upsell-desc strong {
    color: #0e003c;
    font-weight: 600;
}

/* Plugin cards list */
.upsell-plugins-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 32px;
}

/* Base plugin card */
.upsell-plugin-card {
    background: white;
    border: 1px solid #e8e1ff;
    border-radius: 12px;
    padding: 24px;
    position: relative;
}

/* Featured / highlighted card */
.upsell-plugin-featured {
    border-color: #e8e1ff;
    box-shadow: 0 4px 20px rgba(32, 28, 254, 0.06);
}

/* HIGHLY RECOMMENDED badge */
.upsell-badge {
    position: absolute;
    top: 0;
    right: 16px;
    transform: translateY(-50%);
    background: #201cfe;
    color: white;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.6px;
    padding: 4px 10px;
    border-radius: 20px;
    text-transform: uppercase;
}

/* Card header row (icon + titles) */
.upsell-plugin-header-row {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 14px;
}

.upsell-plugin-icon-wrap {
    flex-shrink: 0;
    width: 56px;
    height: 56px;
    background: #f6f4ff;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.upsell-plugin-icon-img {
    width: 36px;
    height: 36px;
    object-fit: contain;
}

.upsell-plugin-titles {
    flex: 1;
}

.upsell-plugin-name {
    font-size: 16px;
    font-weight: 600;
    color: #0e003c;
    margin: 0 0 4px;
}

.upsell-plugin-brand {
    font-size: 13px;
    color: #201cfe;
    margin: 0;
    font-weight: 500;
}

.upsell-plugin-desc {
    font-size: 13px;
    color: #76708c;
    line-height: 1.6;
    margin: 0 0 20px;
}

.upsell-plugin-desc strong {
    color: #0e003c;
    font-weight: 600;
}

/* Featured card footer (button + stats) */
.upsell-plugin-footer-row {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: nowrap;
}

.upsell-install-btn {
    display: inline-flex;
    align-items: center;
    padding: 12px 28px;
    font-size: 14px;
    white-space: nowrap;
    flex-shrink: 0;
}

.upsell-install-btn.is-installed,
.upsell-install-btn.is-installed:disabled {
    background: #239654;
    color: white;
    cursor: default;
    opacity: 1;
}

/* Card is already active — add green accent border */
.upsell-plugin-card.is-already-active {
    border-color: #239654;
}

.upsell-plugin-card.is-already-active .upsell-plugin-brand {
    display: flex;
    align-items: center;
    gap: 6px;
}

.upsell-plugin-card.is-already-active .upsell-plugin-brand::after {
    content: 'Active';
    font-size: 11px;
    font-weight: 600;
    color: #239654;
    background: #dcfce7;
    border: 1px solid #86efac;
    border-radius: 20px;
    padding: 1px 8px;
    line-height: 1.6;
}

.upsell-plugin-stats {
    font-size: 12px;
    color: #76708c;
    line-height: 1.5;
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
}

/* Cart Lift card - horizontal body row */
.upsell-plugin-body-row {
    display: flex;
    align-items: center;
    gap: 14px;
}

.upsell-plugin-body-row .upsell-plugin-titles {
    flex: 1;
}

.upsell-plugin-body-row .upsell-plugin-desc {
    margin: 0;
}

.upsell-cartlift-action {
    flex-shrink: 0;
    margin-left: auto;
}

/* Muted brand variant (Cart Lift) */
.upsell-plugin-brand--muted {
    color: #76708c;
}

/* Cart Lift install button — same shape as WPFunnels, secondary color */
.upsell-secondary-btn {
    display: inline-flex;
    align-items: center;
    padding: 12px 28px;
    font-family: Inter, sans-serif;
    font-size: 14px;
    font-weight: 500;
    color: #201cfe;
    background: white;
    border: 1px solid #e8e1ff;
    border-radius: 8px;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s;
    flex-shrink: 0;
}

.upsell-secondary-btn:hover {
    border-color: #201cfe;
}

.upsell-secondary-btn:disabled {
    color: #76708c;
    border-color: #e8e1ff;
    cursor: not-allowed;
    opacity: 0.6;
}

.upsell-secondary-btn.is-installed {
    color: #239654;
    border-color: #239654;
    background: white;
    cursor: default;
    opacity: 1;
}

/* Skip for now / final actions row */
.complete-skip-row {
    text-align: center;
}

/* Final actions (shown after at least one plugin installed) */
.upsell-final-actions {
    display: flex;
    justify-content: center;
    gap: 16px;
}

.complete-skip-btn {
    background: none;
    border: none;
    font-family: Inter, sans-serif;
    font-size: 14px;
    color: #76708c;
    cursor: pointer;
    padding: 0;
    transition: color 0.2s;
}

.complete-skip-btn:hover {
    color: #201cfe;
}

.complete-skip-btn:disabled {
    cursor: not-allowed;
    opacity: 0.6;
}

/* =========================================
   SHARED NAVIGATION BUTTONS
   ========================================= */

.nav-buttons {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 8px;
}


.btn {
    font-family: Inter, sans-serif;
    font-size: 15px;
    font-weight: 500;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-back {
    padding: 10px 24px;
    background: white;
    border: 1px solid #e8e1ff;
    color: #0e003c;
}

.btn-back:hover {
    border-color: #201cfe;
    color: #201cfe;
}

.btn-continue {
    padding: 12px 32px;
    background: #201cfe;
    border: none;
    color: white;
    border-radius: 8px;
}

.btn-continue:disabled {
    background: #ede9ff;
    color: #76708c;
    cursor: not-allowed;
}

.btn-continue:not(:disabled):hover {
    opacity: 0.9;
}

.btn-publish {
    padding: 12px 32px;
    background: #201cfe;
    border: none;
    color: white;
    border-radius: 8px;
}

.btn-publish:disabled {
    background: #ede9ff;
    color: #76708c;
    cursor: not-allowed;
}

.btn-publish:not(:disabled):hover {
    opacity: 0.9;
}

.btn-secondary {
    padding: 14px 32px;
    background: white;
    border: 1px solid #e8e1ff;
    color: #0e003c;
}

.btn-secondary:hover {
    border-color: #201cfe;
    color: #201cfe;
}

.btn-primary {
    padding: 14px 32px;
    background: #201cfe;
    border: none;
    color: white;
    border-radius: 8px;
}

.btn-primary:hover {
    opacity: 0.9;
}

/* =========================================
   ATTRIBUTE MAPPING STEP
   ========================================= */

.mapping-header {
    margin-bottom: 32px;
}

.mapping-title {
    font-size: 24px;
    font-weight: 600;
    color: #0e003c;
    margin-bottom: 12px;
}

.mapping-description {
    font-size: 14px;
    color: #76708c;
    line-height: 1.6;
}

.mapping-table-wrapper {
    margin-bottom: 32px;
    border: 1px solid #e8e1ff;
    border-radius: 8px;
    overflow-x: auto;
    overflow-y: auto;
    max-height: 500px;
    -webkit-overflow-scrolling: touch;
}

.mapping-table {
    width: 100%;
    min-width: 560px;
    border-collapse: collapse;
    font-size: 14px;
    table-layout: fixed;
}

/* Column widths */
.mapping-table th:nth-child(1),
.mapping-table td:nth-child(1) {
    width: 38%;
}

.mapping-table th:nth-child(2),
.mapping-table td:nth-child(2) {
    width: 160px;
}

.mapping-table th:nth-child(3),
.mapping-table td:nth-child(3) {
    width: auto;
}

.mapping-table th:nth-child(4),
.mapping-table td:nth-child(4) {
    width: 52px;
    text-align: center;
}

.mapping-table thead {
    background: #f8f6ff;
    position: sticky;
    top: 0;
    z-index: 1;
}

.mapping-table th {
    padding: 16px;
    text-align: left;
    font-weight: 600;
    color: #0e003c;
    border-bottom: 1px solid #e8e1ff;
}

.mapping-table td {
    padding: 16px;
    color: #0e003c;
    border-bottom: 1px solid #f3f1ff;
}

.mapping-table tbody tr:last-child td {
    border-bottom: none;
}

.mapping-table tbody tr:hover {
    background: #fafafe;
}

.type-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

.type-badge.type-meta {
    background: #e6f4ea;
    color: #1e8e3e;
}

.type-badge.type-static {
    background: #fef7e0;
    color: #f9ab00;
}

.loading-row td {
    text-align: center;
    padding: 40px;
}

/* Mapping table dropdowns and inputs */
.mapping-select {
    width: 100%;
    max-width: 100%;
    padding: 8px 32px 8px 12px;
    border: 1px solid #e8e1ff;
    border-radius: 6px;
    font-size: 14px;
    color: #0e003c;
    background: white url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%2376708c' stroke-width='1.5' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 12px center;
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
    transition: border-color 0.2s;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    box-sizing: border-box;
}

.mapping-select:hover {
    border-color: #201cfe;
}

.mapping-select:focus {
    outline: none;
    border-color: #201cfe;
    box-shadow: 0 0 0 3px rgba(63, 4, 254, 0.1);
}

select.mapping-select.type-select {
    width: 140px;
}

.mapping-input {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #e8e1ff;
    border-radius: 6px;
    font-size: 14px;
    color: #0e003c;
    transition: border-color 0.2s;
}

.mapping-input:hover {
    border-color: #201cfe;
}

.mapping-input:focus {
    outline: none;
    border-color: #201cfe;
    box-shadow: 0 0 0 3px rgba(63, 4, 254, 0.1);
}

.btn-delete-mapping {
    background: #fff;
    border: 1px solid #e8e1ff;
    color: #d63638;
    width: 32px;
    height: 32px;
    border-radius: 6px;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-delete-mapping:hover {
    background: #d63638;
    color: white;
    border-color: #d63638;
}

/* ==========================================================================
   NEW 3-STEP WIZARD STYLES  (pfm- prefix — wizard-only)
   ========================================================================== */

/* ── Reset for wizard body ── */
#pfm-wizard-app * { box-sizing: border-box; }
#pfm-wizard-app { font-family: 'Inter', sans-serif; background: #f6f4ff; min-height: 100vh; }

/* ── Step visibility ── */
.pfm-wizard-step          { display: none; }
.pfm-wizard-step.active   { display: block; }

/* ── Shared: step indicator dots ── */
.pfm-step-indicator {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 24px;
}
.pfm-step-dots { display: flex; gap: 6px; }
.pfm-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #d0c9e8;
    transition: background 0.2s;
}
.pfm-dot-active { background: #201cfe; }
.pfm-dot-done   { background: #239654; }
.pfm-step-label { font-size: 13px; color: #76708c; font-weight: 500; }

/* ── Shared: merchant cards ── */
.pfm-merchant-logo {
    width: 56px;
    height: 56px;
    object-fit: contain;
    border-radius: 11px;
    flex-shrink: 0;
}
.pfm-merchant-monogram {
    width: 56px;
    height: 56px;
    border-radius: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    font-weight: 700;
    color: white;
    flex-shrink: 0;
    text-transform: uppercase;
}
.pfm-merchant-name  { font-size: 13px; font-weight: 500; color: #0e003c; text-align: center; line-height: 1.3; }
.pfm-merchant-check {
    position: absolute;
    top: 10px; right: 10px;
    width: 20px; height: 20px;
    border-radius: 50%;
    background: #201cfe;
    display: flex; align-items: center; justify-content: center;
    opacity: 0; transform: scale(0.5);
    transition: opacity 0.2s, transform 0.2s;
    pointer-events: none;
}
.pfm-popular-card.selected .pfm-merchant-check,
.pfm-result-card.selected  .pfm-merchant-check { opacity: 1; transform: scale(1); }

.pfm-merchant-badge {
    position: absolute; top: 7px; right: 7px;
    padding: 3px 7px;
    background: #206DF0; color: white;
    font-size: 10px; font-weight: 700;
    border-radius: 6px; text-transform: uppercase; letter-spacing: 0.5px;
}

/* ── Shared: buttons ── */
.pfm-btn-primary {
    display: inline-flex; align-items: center; justify-content: center;
    padding: 12px 28px;
    background: #201cfe; color: white;
    border: none; border-radius: 8px;
    font-family: 'Inter', sans-serif; font-size: 15px; font-weight: 500;
    cursor: pointer; transition: opacity 0.2s; text-decoration: none;
}
.pfm-btn-primary:hover:not(:disabled) { opacity: 0.9; }
.pfm-btn-primary:disabled             { background: #ede9ff; color: #76708c; cursor: not-allowed; }
.pfm-btn-primary.pfm-btn-lg           { padding: 14px 36px; font-size: 16px; }

.pfm-btn-back {
    display: inline-flex; align-items: center;
    padding: 10px 22px;
    background: white; color: #0e003c;
    border: 1px solid #e8e1ff; border-radius: 8px;
    font-family: 'Inter', sans-serif; font-size: 14px; font-weight: 500;
    cursor: pointer; transition: border-color 0.2s, color 0.2s;
}
.pfm-btn-back:hover { border-color: #201cfe; color: #201cfe; }

.pfm-btn-outline {
    display: inline-flex; align-items: center; justify-content: center;
    padding: 10px 22px;
    background: white; color: #201cfe;
    border: 1px solid #e8e1ff; border-radius: 8px;
    font-family: 'Inter', sans-serif; font-size: 14px; font-weight: 500;
    cursor: pointer; transition: border-color 0.2s;
}
.pfm-btn-outline:hover { border-color: #201cfe; }

.pfm-btn-text-link {
    background: none; border: none;
    font-family: 'Inter', sans-serif; font-size: 14px; color: #76708c;
    cursor: pointer; padding: 0; transition: color 0.2s;
}
.pfm-btn-text-link:hover { color: #201cfe; }

/* ── Step 1 layout ── */
.pfm-s1-wrap {
    min-height: 100vh;
    display: flex; flex-direction: column; align-items: center;
    padding: 48px 24px 32px;
    max-width: 760px; margin: 0 auto;
}
.pfm-s1-logo { margin-bottom: 24px; }
.pfm-s1-logo img { width: 72px; }
.pfm-s1-title {
    font-size: 28px; font-weight: 700; color: #0e003c;
    text-align: center; margin: 0 0 8px;
}
.pfm-s1-subtitle {
    font-size: 15px; color: #76708c; text-align: center; margin: 0 0 28px;
}
.pfm-popular-label {
    font-size: 13px; font-weight: 600; color: #76708c;
    text-transform: uppercase; letter-spacing: 0.06em;
    margin-bottom: 12px; align-self: flex-start;
}

/* Popular grid: 5 columns */
.pfm-popular-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 12px;
    width: 100%;
    margin-bottom: 20px;
}
.pfm-popular-card {
    display: flex; flex-direction: column; align-items: center; gap: 10px;
    padding: 18px 12px;
    border: 2px solid #e8e1ff; border-radius: 12px;
    cursor: pointer; transition: all 0.2s;
    background: white; position: relative;
}
.pfm-popular-card:hover { border-color: #201cfe; transform: translateY(-2px); box-shadow: 0 4px 12px rgba(32,28,254,0.1); }
.pfm-popular-card.selected { border-color: #201cfe; background: #f0edff; box-shadow: 0 4px 12px rgba(32,28,254,0.15); }

/* Search */
.pfm-search-wrap { width: 100%; margin-bottom: 24px; }
.pfm-search-inner {
    position: relative;
    display: flex; align-items: center;
}
.pfm-search-icon { position: absolute; left: 14px; pointer-events: none; }
.pfm-search-inner input {
    width: 100%;
    padding: 13px 16px 13px 44px;
    border: 1px solid #e8e1ff; border-radius: 10px;
    font-family: 'Inter', sans-serif; font-size: 14px; color: #0e003c;
    background: #fbfaff; outline: none; transition: border-color 0.2s;
}
.pfm-search-inner input::placeholder { color: #76708c; }
.pfm-search-inner input:focus { border-color: #201cfe; background: white; }

.pfm-search-results-wrap { margin-top: 8px; }
.pfm-search-results-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 12px;
    max-height: 360px;
    overflow-y: auto;
    padding: 4px;
}
.pfm-search-empty { grid-column: 1/-1; text-align: center; padding: 32px; color: #76708c; font-size: 14px; }

.pfm-result-card {
    display: flex; flex-direction: column; align-items: center; gap: 10px;
    padding: 18px 12px;
    border: 2px solid #e8e1ff; border-radius: 12px;
    cursor: pointer; transition: all 0.2s;
    background: white; position: relative;
}
.pfm-result-card:hover:not(.disabled) { border-color: #201cfe; transform: translateY(-2px); box-shadow: 0 4px 12px rgba(32,28,254,0.1); }
.pfm-result-card.selected { border-color: #201cfe; background: #f0edff; }
.pfm-result-card.disabled { cursor: not-allowed; opacity: 0.6; }

/* Step 1 footer */
.pfm-s1-footer {
    display: flex; flex-direction: column; align-items: center; gap: 16px;
    margin-top: auto; padding-top: 24px;
    border-top: 1px solid #f1eeff;
    width: 100%;
}
.pfm-remind-later {
    font-size: 13px; color: #76708c; text-decoration: none;
    transition: color 0.2s;
}
.pfm-remind-later:hover { color: #201cfe; }

/* ── Step 2 layout ── */
.pfm-s2-wrap {
    min-height: 100vh;
    max-width: 600px; margin: 0 auto;
    padding: 48px 24px;
    background: white;
}
.pfm-s2-title { font-size: 22px; font-weight: 600; color: #0e003c; margin: 0 0 24px; }

.pfm-field-group { margin-bottom: 24px; }
.pfm-field-label { display: block; font-size: 14px; font-weight: 500; color: #0e003c; margin-bottom: 6px; }
.pfm-field-input {
    width: 100%; padding: 12px 16px;
    border: 1px solid #e8e1ff; border-radius: 10px;
    font-family: 'Inter', sans-serif; font-size: 15px; color: #0e003c;
    background: #fbfaff; outline: none; transition: border-color 0.2s;
}
.pfm-field-input:focus { border-color: #201cfe; background: white; }

.pfm-autoconfig-section { margin-bottom: 24px; }
.pfm-autoconfig-intro   { font-size: 13px; color: #76708c; margin: 0 0 12px; }
.pfm-autoconfig-item {
    display: flex; align-items: center; gap: 10px;
    padding: 10px 14px; margin-bottom: 8px;
    background: #f6fff9; border: 1px solid #d4f5e1; border-radius: 8px;
    font-size: 14px; color: #0e003c;
}
.pfm-autoconfig-check { flex-shrink: 0; display: flex; align-items: center; }

/* Mapping progress */
.pfm-mapping-section { margin-bottom: 32px; }
.pfm-mapping-status {
    font-size: 14px; color: #0e003c; margin: 0 0 10px;
    display: flex; align-items: center; gap: 6px;
}
.pfm-mapping-bar-track {
    height: 8px; background: #ede9ff; border-radius: 4px; overflow: hidden; margin-bottom: 8px;
}
.pfm-mapping-bar-fill {
    height: 100%; width: 0%; background: linear-gradient(90deg, #201cfe, #6366f1);
    border-radius: 4px; transition: width 0.3s ease;
}
.pfm-mapping-detail { font-size: 13px; color: #76708c; margin: 0; }

.pfm-nav-row { display: flex; justify-content: space-between; align-items: center; margin-top: 8px; }

/* ── Step 3 layout ── */
.pfm-s3-wrap {
    max-width: 620px; margin: 0 auto;
    padding: 48px 24px 40px;
    background: white;
    min-height: 100vh;
}

/* Aha hero */
.pfm-aha-hero { text-align: center; margin-bottom: 24px; }
.pfm-aha-checkmark { margin-bottom: 16px; }
.pfm-aha-title {
    font-size: 24px; font-weight: 700; color: #0e003c; margin: 0 0 6px;
}
.pfm-aha-feed-name { font-size: 14px; color: #76708c; margin: 0; }

/* Feed URL card */
.pfm-feed-url-card {
    border: 1px solid #e8e1ff; border-radius: 12px;
    padding: 16px 18px; margin-bottom: 16px;
}
.pfm-feed-url-label {
    display: flex; align-items: center; gap: 6px;
    font-size: 11px; font-weight: 600; color: #6b6b8a;
    text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 8px;
}
.pfm-feed-url-row { display: flex; align-items: center; gap: 8px; }
.pfm-feed-url-input {
    flex: 1; padding: 9px 12px;
    border: 1px solid #e2e8f0; border-radius: 8px;
    font-family: monospace; font-size: 13px; color: #374151;
    background: #f8fafc; outline: none; min-width: 0;
}
.pfm-feed-url-actions { display: flex; gap: 6px; flex-shrink: 0; }
.pfm-url-btn {
    display: inline-flex; align-items: center; justify-content: center;
    padding: 8px 14px;
    border: 1px solid #e2e8f0; border-radius: 8px;
    background: white; color: #6b6b8a;
    font-family: 'Inter', sans-serif; font-size: 13px; font-weight: 500;
    cursor: pointer; text-decoration: none; transition: all 0.15s;
}
.pfm-url-btn:hover { background: #f1f0ff; border-color: #201cfe; color: #201cfe; }
.pfm-url-open-btn  { text-decoration: none; }

/* Propagation notice */
.pfm-propagation-notice {
    display: flex; align-items: flex-start; gap: 8px;
    padding: 12px 14px;
    background: #eff6ff; border: 1px solid #bfdbfe; border-radius: 8px;
    margin-bottom: 20px;
    font-size: 13px; color: #1e40af; line-height: 1.5;
}
.pfm-propagation-notice svg { flex-shrink: 0; margin-top: 1px; }

/* Divider */
.pfm-divider { border: none; border-top: 1px solid #f1eeff; margin: 20px 0; }

/* Consent */
.pfm-consent-row {
    display: flex; align-items: flex-start; gap: 12px;
    cursor: pointer; margin-bottom: 24px;
}
.pfm-consent-row input { display: none; }
.pfm-consent-box {
    width: 20px; height: 20px; min-width: 20px;
    border: 2px solid #d0c9e8; border-radius: 4px;
    background: white; position: relative;
    flex-shrink: 0; margin-top: 2px;
    transition: all 0.2s;
}
.pfm-consent-row:hover .pfm-consent-box { border-color: #201cfe; }
.pfm-consent-row input:checked + .pfm-consent-box {
    background: #201cfe; border-color: #201cfe;
}
.pfm-consent-row input:checked + .pfm-consent-box::after {
    content: '';
    position: absolute; left: 5px; top: 1px;
    width: 5px; height: 9px;
    border: solid white; border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}
.pfm-consent-text { font-size: 14px; color: #76708c; line-height: 1.5; }

/* Aha CTAs */
.pfm-aha-ctas {
    display: flex; align-items: center; gap: 20px;
    flex-wrap: wrap; margin-bottom: 8px;
}

/* Upsells */
.pfm-upsell-section { margin-top: 4px; }
.pfm-upsell-header-row {
    font-size: 13px; font-weight: 600; color: #76708c;
    margin-bottom: 14px;
}
.pfm-upsell-cards { display: flex; flex-direction: column; gap: 14px; }

.pfm-upsell-card {
    background: white; border: 1px solid #e8e1ff;
    border-radius: 12px; padding: 20px;
    position: relative;
}
.pfm-upsell-featured { box-shadow: 0 4px 18px rgba(32,28,254,0.06); }
.pfm-upsell-badge {
    position: absolute; top: 0; right: 16px;
    transform: translateY(-50%);
    background: #201cfe; color: white;
    font-size: 10px; font-weight: 700; letter-spacing: 0.6px;
    padding: 3px 10px; border-radius: 20px; text-transform: uppercase;
}
.pfm-upsell-card-header {
    display: flex; align-items: flex-start; gap: 12px;
    margin-bottom: 12px;
}
.pfm-upsell-icon-wrap {
    width: 48px; height: 48px; flex-shrink: 0;
    background: #f6f4ff; border-radius: 10px;
    display: flex; align-items: center; justify-content: center; overflow: hidden;
}
.pfm-upsell-icon-img { width: 32px; height: 32px; object-fit: contain; }
.pfm-upsell-name  { font-size: 15px; font-weight: 600; color: #0e003c; margin: 0 0 3px; }
.pfm-upsell-brand { font-size: 13px; color: #201cfe; margin: 0; font-weight: 500; }
.pfm-upsell-brand-muted { color: #76708c; }
.pfm-upsell-desc  { font-size: 13px; color: #76708c; line-height: 1.5; margin: 0 0 16px; }
.pfm-upsell-card-footer { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.pfm-upsell-install-btn { font-size: 14px; padding: 10px 22px; white-space: nowrap; }
.pfm-upsell-install-btn.is-installed { background: #239654 !important; color: white !important; cursor: default; }
.pfm-upsell-stats {
    font-size: 12px; color: #76708c; display: inline-flex; align-items: center;
}
.pfm-upsell-body-row { display: flex; align-items: center; gap: 12px; }
.pfm-upsell-body-row .pfm-upsell-titles { flex: 1; }
.pfm-upsell-body-row .pfm-upsell-desc   { margin: 4px 0 0; }
.pfm-upsell-cl-action { flex-shrink: 0; margin-left: auto; }
.pfm-upsell-card.is-already-active { border-color: #239654; }

/* Responsive */
@media (max-width: 640px) {
    .pfm-popular-grid, .pfm-search-results-grid { grid-template-columns: repeat(3, 1fr); }
    .pfm-s1-wrap, .pfm-s2-wrap, .pfm-s3-wrap { padding: 32px 16px; }
    .pfm-aha-ctas { flex-direction: column; align-items: stretch; }
}
@media (max-width: 380px) {
    .pfm-popular-grid, .pfm-search-results-grid { grid-template-columns: repeat(2, 1fr); }
}
