/* ─── Remove Line Breaks — Brand-Consistent Stylesheet ──────────────────
   Scoped entirely to #fu-remove-line-breaks.
   Uses only standard design system variables (--fu-*).
   ─────────────────────────────────────────────────────────────────────────── */

#fu-remove-line-breaks .fu-rlb-wrapper {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

#fu-remove-line-breaks .fu-rlb-main-panel,
#fu-remove-line-breaks .fu-rlb-output-panel {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* Premium Textarea Overrides */
#fu-remove-line-breaks .fu-textarea {
    background: var(--fu-input-bg);
    border: 1px solid var(--fu-border);
    border-radius: var(--fu-radius);
    padding: 0.875rem;
    font-family: var(--fu-font-family);
    font-size: 1rem;
    line-height: 1.6;
    color: var(--fu-text);
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.04);
    transition: border-color var(--fu-transition), box-shadow var(--fu-transition);
    box-sizing: border-box;
    min-height: 180px;
}

#fu-remove-line-breaks .fu-textarea:focus {
    outline: none;
    border-color: var(--fu-accent);
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.04), 0 0 0 3px var(--fu-accent-light);
}

/* Custom Scrollbars */
#fu-remove-line-breaks .fu-textarea::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

#fu-remove-line-breaks .fu-textarea::-webkit-scrollbar-track {
    background: transparent;
}

#fu-remove-line-breaks .fu-textarea::-webkit-scrollbar-thumb {
    background: var(--fu-border);
    border-radius: var(--fu-radius-sm);
}

#fu-remove-line-breaks .fu-textarea::-webkit-scrollbar-thumb:hover {
    background: var(--fu-border-focus);
}

/* Options area at the bottom of Card 1 */
#fu-remove-line-breaks .fu-rlb-options-section {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    border-top: 1px dashed var(--fu-border);
    margin-top: 0.5rem;
    padding-top: 1.25rem;
}

#fu-remove-line-breaks .fu-rlb-options-row {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem 2rem;
    align-items: flex-start;
}

#fu-remove-line-breaks .fu-rlb-mode-col {
    flex: 0 1 auto;
    min-width: 320px;
}

#fu-remove-line-breaks .fu-rlb-replace-col {
    flex: 1 1 200px;
    max-width: 300px;
}

#fu-remove-line-breaks .fu-rlb-setting-col {
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
}

/* Pills */
#fu-remove-line-breaks .fu-rlb-pills {
    display: flex;
    flex-wrap: nowrap;
    gap: 0.375rem;
    overflow-x: auto;
    padding-bottom: 2px;
}

/* Hide scrollbar for pills container but allow swiping on mobile */
#fu-remove-line-breaks .fu-rlb-pills::-webkit-scrollbar {
    display: none;
}
#fu-remove-line-breaks .fu-rlb-pills {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

#fu-remove-line-breaks .fu-rlb-pill {
    display: inline-flex;
    align-items: center;
    padding: 0.4rem 0.875rem;
    border-radius: 9999px;
    border: 1.5px solid var(--fu-border);
    background: transparent;
    font-size: 0.775rem;
    font-weight: 500;
    color: var(--fu-text-muted);
    cursor: pointer;
    transition: border-color var(--fu-transition), color var(--fu-transition),
                background var(--fu-transition);
    line-height: 1;
    white-space: nowrap;
}

#fu-remove-line-breaks .fu-rlb-pill:hover {
    border-color: var(--fu-accent);
    color: var(--fu-accent);
    background: var(--fu-accent-light);
}

#fu-remove-line-breaks .fu-rlb-pill.active {
    background: var(--fu-accent);
    border-color: var(--fu-accent);
    color: var(--fu-btn-primary-text);
    font-weight: 600;
}

/* Custom Sliding Toggle Switches (iOS-style) arranged horizontally */
#fu-remove-line-breaks .fu-rlb-switches {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 0.75rem 2rem;
    border-top: 1px dashed var(--fu-border);
    padding-top: 1.25rem;
}

#fu-remove-line-breaks .fu-rlb-switch-container {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    cursor: pointer;
    user-select: none;
    width: fit-content;
}

#fu-remove-line-breaks .fu-rlb-switch {
    position: relative;
    display: inline-block;
    width: 2.125rem;
    height: 1.125rem;
    flex-shrink: 0;
}

#fu-remove-line-breaks .fu-rlb-switch input {
    opacity: 0;
    width: 0;
    height: 0;
    margin: 0;
}

#fu-remove-line-breaks .fu-rlb-switch-slider {
    position: absolute;
    cursor: pointer;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: var(--fu-border);
    transition: var(--fu-transition);
    border-radius: 9999px;
}

#fu-remove-line-breaks .fu-rlb-switch-slider::before {
    position: absolute;
    content: "";
    height: 0.85rem;
    width: 0.85rem;
    left: 0.15rem;
    bottom: 0.13rem;
    background-color: white;
    transition: var(--fu-transition);
    border-radius: 50%;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
}

#fu-remove-line-breaks .fu-rlb-switch input:checked + .fu-rlb-switch-slider {
    background-color: var(--fu-accent);
}

#fu-remove-line-breaks .fu-rlb-switch input:checked + .fu-rlb-switch-slider::before {
    transform: translateX(0.95rem);
}

#fu-remove-line-breaks .fu-rlb-switch input:focus-visible + .fu-rlb-switch-slider {
    outline: 2px solid var(--fu-accent);
    outline-offset: 2px;
}

#fu-remove-line-breaks .fu-rlb-switch-label {
    font-size: 0.825rem;
    font-weight: 500;
    color: var(--fu-text);
}

#fu-remove-line-breaks .fu-rlb-switch-label small {
    color: var(--fu-text-muted);
    font-weight: 400;
    margin-left: 0.25rem;
}

/* Sleek Inline Stats Bar */
#fu-remove-line-breaks .fu-rlb-stats-bar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem 1rem;
    font-size: 0.825rem;
    color: var(--fu-text-muted);
    border-top: 1px dashed var(--fu-border);
    margin-top: 0.5rem;
    padding-top: 1.25rem;
    line-height: 1.4;
}

#fu-remove-line-breaks .fu-rlb-stats-bar strong {
    color: var(--fu-text);
    font-weight: 600;
}

#fu-remove-line-breaks .fu-rlb-dot {
    color: var(--fu-border);
    font-size: 1.2rem;
    font-weight: bold;
    user-select: none;
    line-height: 1;
}

/* Custom Spacing & Helper Classes */
#fu-remove-line-breaks .fu-mt-1 {
    margin-top: 0.5rem;
}

#fu-remove-line-breaks .fu-rlb-separator-controls {
    display: flex;
    flex-direction: column;
}

#fu-remove-line-breaks .fu-select {
    display: inline-flex;
    align-items: center;
    padding: 0.4rem 2rem 0.4rem 0.875rem;
    border-radius: 9999px;
    border: 1.5px solid var(--fu-border);
    background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23888888' stroke-width='2.5'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M19.5 8.25l-7.5 7.5-7.5-7.5'/%3E%3C/svg%3E") no-repeat right 0.75rem center;
    background-size: 0.75rem;
    font-family: var(--fu-font-family);
    font-size: 0.775rem;
    font-weight: 500;
    color: var(--fu-text);
    cursor: pointer;
    line-height: 1;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    transition: border-color var(--fu-transition), box-shadow var(--fu-transition);
    width: auto;
    max-width: 180px;
}

#fu-remove-line-breaks .fu-select:focus {
    outline: none;
    border-color: var(--fu-accent);
    box-shadow: 0 0 0 3px var(--fu-accent-light);
}

/* Responsive Overrides */
@media (max-width: 640px) {
    #fu-remove-line-breaks .fu-rlb-switches {
        flex-direction: column;
        gap: 0.75rem;
    }
    #fu-remove-line-breaks .fu-rlb-options-row {
        flex-direction: column;
        gap: 1rem;
    }
    #fu-remove-line-breaks .fu-rlb-mode-col,
    #fu-remove-line-breaks .fu-rlb-replace-col {
        width: 100%;
        max-width: 100%;
    }
    #fu-remove-line-breaks .fu-rlb-pills {
        flex-wrap: wrap;
    }
}
